I am facing a little problem, I wish I can get some help here!
I have a Picto Icon like this :
const PictoIcon = ({ color, size }) => (
<StyledSvg xmlns="http://www.w3.org/2000/svg" size={size} viewBox="0 0 24 24">
<Path fill={color} d="M12,2L4.5,20.3L5.2,21l6.8-3l6.8,3l0.7-0.7L12,2z" transform="rotate(45)" />
</StyledSvg>
);
The Picto is inside a Map Marker : ( this won't help in my example, thje code above has to be enough )
<Marker
style={isAndroid ? rotation : {}}
tracksViewChanges={showPicto}
key={id}
onPress={handleOnClickMark(marker)}
coordinate={coordinate}
identifier={id}
>
{showPicto && <View style={{backgroundColor: 'red'}}><PictoIcon size={30} color={color}/></View>}
{!showPicto && (isPoint ? <PointWrapper /> : <MarkerIcon size={50} color={color} />)}
</Marker>
I need my marker to be rotated based on the cap variable, but it is not doing good in IOS, so I want that in IOS I rotate the SVG .. But the rotation is based on the starting point of the icon, not its center
Why I am having a problem ? it because my View is a square ( I see that because the backgroudnColor I set there ), and when my svg is rotated by 90 degree for example, it comes off the view, and I don't know why part of it start disappering ( looks like overflow hidden effect in css )
Any help would be mucch appreciated.