Commit 7da6476 1 parent 52b04e1 commit 7da6476 Copy full SHA for 7da6476
File tree 2 files changed +12
-3
lines changed
2 files changed +12
-3
lines changed Original file line number Diff line number Diff line change @@ -59,7 +59,9 @@ export function MaterialIcons(
59
59
}
60
60
61
61
return iconId =>
62
- createSpan ( materialIconsClasses [ optionsWithDefaults . style ] , iconId ) ;
62
+ createSpan ( materialIconsClasses [ optionsWithDefaults . style ] , iconId , {
63
+ fontSize : 'calc(15px * var(--marker-scale, 1.0))'
64
+ } ) ;
63
65
}
64
66
65
67
export function PlaceIcons ( ) : IconProvider {
@@ -74,13 +76,20 @@ export function PlaceIcons(): IconProvider {
74
76
*
75
77
* @param className
76
78
* @param content
79
+ * @param styles
77
80
*/
78
- function createSpan ( className : string , content : string ) : HTMLElement {
81
+ function createSpan (
82
+ className : string ,
83
+ content : string ,
84
+ styles : Record < string , string | number > | null = null
85
+ ) : HTMLElement {
79
86
const el = document . createElement ( 'span' ) ;
80
87
81
88
el . className = className ;
82
89
el . textContent = content ;
83
90
91
+ Object . assign ( el . style , styles ) ;
92
+
84
93
return el ;
85
94
}
86
95
Original file line number Diff line number Diff line change @@ -281,7 +281,7 @@ export class Marker<TUserData = unknown> {
281
281
this . updateGlyph_ ( attrs ) ;
282
282
}
283
283
284
- if ( content && this . markerView_ . element ) {
284
+ if ( this . markerView_ . element ) {
285
285
const el = this . markerView_ . element as HTMLElement ;
286
286
const {
287
287
color = null ,
You can’t perform that action at this time.
0 commit comments