import { FC } from 'react'

import Svg, { Path } from 'react-native-svg'

import { useTheme } from '../../../../providers/native'
import { SvgIconProps } from '../types'

const DevicesIcon: FC<SvgIconProps> = ({
  isActive = false,
  color,
  width = '18',
  height = '17',
  ...props
}) => {
  const { colors } = useTheme()

  const defaultColor = color ?? colors.object.high
  const svgColor = isActive ? colors.primary.high : defaultColor

  return (
    <Svg width={width} height={height} viewBox="0 0 18 17" color={svgColor} fill="none" {...props}>
      <Path
        fillRule="evenodd"
        clipRule="evenodd"
        d="M2.19255 12.1088C2.14762 12.1088 2.11077 12.1457 2.11077 12.1906V13.0084C2.11077 13.0534 2.14762 13.0902 2.19255 13.0902H11.0865C11.493 13.0902 11.8225 13.4198 11.8225 13.8263C11.8225 14.2328 11.493 14.5623 11.0865 14.5623H2.19255C1.3346 14.5623 0.638672 13.8664 0.638672 13.0084V12.1906C0.638672 11.3326 1.3346 10.6367 2.19255 10.6367H11.0865C11.493 10.6367 11.8225 10.9663 11.8225 11.3728C11.8225 11.7793 11.493 12.1088 11.0865 12.1088H2.19255Z"
        fill="currentColor"
      />
      <Path
        fillRule="evenodd"
        clipRule="evenodd"
        d="M1.45605 2.37562C1.45605 1.06541 2.51756 0.00390625 3.82777 0.00390625H14.4596C15.7698 0.00390625 16.8313 1.06541 16.8313 2.37562C16.8313 2.78213 16.5018 3.11167 16.0953 3.11167C15.6887 3.11167 15.3592 2.78213 15.3592 2.37562C15.3592 1.87842 14.9568 1.476 14.4596 1.476H3.82777C3.33057 1.476 2.92815 1.87842 2.92815 2.37562V11.3718C2.92815 11.7783 2.59861 12.1078 2.1921 12.1078C1.7856 12.1078 1.45605 11.7783 1.45605 11.3718V2.37562Z"
        fill="currentColor"
      />
      <Path
        fillRule="evenodd"
        clipRule="evenodd"
        d="M12.7223 5.56585C12.2251 5.56585 11.8227 5.96827 11.8227 6.46546V13.826C11.8227 14.3232 12.2251 14.7256 12.7223 14.7256H16.0959C16.5931 14.7256 16.9955 14.3232 16.9955 13.826V6.46546C16.9955 5.96827 16.5931 5.56585 16.0959 5.56585H12.7223ZM10.3506 6.46546C10.3506 5.15525 11.4121 4.09375 12.7223 4.09375H16.0959C17.4061 4.09375 18.4676 5.15525 18.4676 6.46546V13.826C18.4676 15.1362 17.4061 16.1977 16.0959 16.1977H12.7223C11.4121 16.1977 10.3506 15.1362 10.3506 13.826V6.46546Z"
        fill="currentColor"
      />
      <Path
        fillRule="evenodd"
        clipRule="evenodd"
        d="M16.0954 1.63867C16.5019 1.63867 16.8315 1.96821 16.8315 2.37472V4.82822C16.8315 5.23473 16.5019 5.56427 16.0954 5.56427C15.6889 5.56427 15.3594 5.23473 15.3594 4.82822V2.37472C15.3594 1.96821 15.6889 1.63867 16.0954 1.63867Z"
        fill="currentColor"
      />
      <Path
        fillRule="evenodd"
        clipRule="evenodd"
        d="M12.9551 13.6208C12.9551 13.2143 13.2846 12.8848 13.6911 12.8848H15.1223C15.5288 12.8848 15.8584 13.2143 15.8584 13.6208C15.8584 14.0273 15.5288 14.3569 15.1223 14.3569H13.6911C13.2846 14.3569 12.9551 14.0273 12.9551 13.6208Z"
        fill="currentColor"
      />
    </Svg>
  )
}

export default DevicesIcon
