import React from 'react'; import { usePropsConfig, useToken } from '../../../theme'; import styled from 'styled-components'; import { color, space, typography } from 'styled-system'; import Svg, { G, Path, Circle } from 'react-native-svg'; import type { IIconProps } from './props'; const SVG = styled(Svg)(color, space, typography); const SVGIcon = ({ viewBox, color: colorProp, stroke, strokeWidth, children, focusable, size, style, }: IIconProps) => { const newProps = usePropsConfig('Icon', { size }); let strokeColor = useToken('colors', stroke || ''); return ( {React.Children.count(children) > 0 ? ( {React.Children.map(children, ({ props: childProps, type }: any) => type.name === 'Path' ? : null )} ) : ( getDefaultIcon() )} ); }; const ChildPath = ({ fill, stroke: pathStroke, ...remainingProps }: any) => { let pathStrokeColor = useToken('colors', pathStroke || ''); let fillColor = useToken('colors', fill || ''); return ( ); }; const getDefaultIcon = () => { return ( ); }; export { SVGIcon };