import * as React from 'react';
import Svg, {SvgProps, Rect, Path} from 'react-native-svg';

interface IProps extends SvgProps {
  checked?: boolean;
}

const SvgComponent = ({checked = false, ...rest}: IProps) => (
  <Svg width={16} height={16} fill="none" {...rest}>
    <Rect x={0.5} y={0.5} width={15} height={15} rx={3.5} stroke="#fff" />
    {checked && (
      <Path
        fillRule="evenodd"
        clipRule="evenodd"
        d="M12.189 5.911a.55.55 0 0 1 0 .778l-4.4 4.4a.55.55 0 0 1-.778 0l-2.2-2.2a.55.55 0 0 1 .778-.778L7.4 9.922l4.011-4.01a.55.55 0 0 1 .778 0Z"
        fill="#fff"
        stroke="#fff"
      />
    )}
  </Svg>
);

export default SvgComponent;
