maplibre-react-native icon indicating copy to clipboard operation
maplibre-react-native copied to clipboard

Symbol Layer Icon Color

Open danish-danial opened this issue 1 year ago • 1 comments

Hey everyone,

I can't seem to change the color of the Symbol Layer icon. I refer to the StackOverflow on how to convert the icon and etc. It seem the icon still white even though I assign the iconColor in style.

Here are the line of the code:

 <SymbolLayer
                    key={index}
                    id={`vector-layer-${index}`}
                    style={{
                      iconImage: pointMarker,
                      iconSize: 0.05,
                      iconOpacity: vector.hidden ? 0 : 1,
                      iconColor: vector.color,
                    }}
/>

image

Can you give me a guidance on how can I color the Symbol Layer?

Thanks.

danish-danial avatar Jun 13 '24 01:06 danish-danial

Is your icon in SDF format?

caspg avatar Jun 21 '24 08:06 caspg

Hi @danish-danial , could you please share how did you make the SDF icon work?

Buthrakaur avatar Jan 28 '25 13:01 Buthrakaur