File tree Expand file tree Collapse file tree 1 file changed +11
-5
lines changed
packages/maps/src/components Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -21,11 +21,17 @@ const MapCircle: React.FC<React.PropsWithChildren<MapCircleProps>> = ({
2121 strokeColor = theme . colors . primary ,
2222 ...rest
2323} ) => {
24- // Web maps by default uses a lower opacity for the circle, native needs an extra step
25- const fillColor =
26- Platform . OS === "web"
27- ? fillColorProp
28- : Color ( fillColorProp ) . alpha ( 0.3 ) . rgb ( ) . string ( ) ;
24+ const parsedColor = Color ( fillColorProp ) ;
25+
26+ let fillColor ;
27+ if ( parsedColor . alpha ( ) === 0 ) {
28+ fillColor = "transparent" ;
29+ } else if ( Platform . OS !== "web" ) {
30+ // Web maps by default uses a lower opacity for the circle, native needs this extra step
31+ fillColor = parsedColor . alpha ( 0.3 ) . rgb ( ) . string ( ) ;
32+ } else {
33+ fillColor = fillColorProp ;
34+ }
2935
3036 return (
3137 < MapCircleComponent
You can’t perform that action at this time.
0 commit comments