Skip to content

Commit 008d842

Browse files
committed
hover states for icons
1 parent 119a689 commit 008d842

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

proxy/js/styles.mjs

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1092,8 +1092,18 @@ const imageLayerWithOutline = (id, spriteExpression, layer) => [
10921092
id: `${id}_outline`,
10931093
...layer,
10941094
paint: {
1095-
'icon-halo-color': 'white',
1096-
'icon-halo-width': 2.0,
1095+
'icon-halo-color': ['case',
1096+
['boolean', ['feature-state', 'hover'], false], colors.hover.textHalo,
1097+
'white',
1098+
],
1099+
'icon-halo-blur': ['case',
1100+
['boolean', ['feature-state', 'hover'], false], 1.0,
1101+
0.0,
1102+
],
1103+
'icon-halo-width': ['case',
1104+
['boolean', ['feature-state', 'hover'], false], 3.0,
1105+
2.0,
1106+
],
10971107
},
10981108
layout: {
10991109
...(layer.layout || {}),

0 commit comments

Comments
 (0)