import React from "react";
import PropTypes from "prop-types";
import { withTheme } from "styled-components";
import { getObjectValue } from "../utils/util";
import IconWrapper from "../IconWrapper";

const VariantsIcon = props => {
  return (
    <IconWrapper {...props}>
      <svg
        width="24"
        height="24"
        viewBox="0 0 24 24"
        fill="none"
        xmlns="http://www.w3.org/2000/svg"
      >
        <path
          d="M6.29529 16.2722C6.29529 17.711 22 17.711 22 16.2722V3.19782C22 1.79391 6.29529 1.41853 6.29529 3.19782V16.2722Z"
          fill="white"
          stroke={getObjectValue(
            props.theme.colors,
            props.iconColor,
            props.theme.colors.grey.deep,
          )}
          strokeWidth="1.66667"
          strokeLinecap="round"
          strokeLinejoin="round"
        />
        <path
          d="M2 20.9209C2 22.3597 17.7047 22.3597 17.7047 20.9209V7.8465C17.7047 6.4426 2 6.06721 2 7.8465V20.9209Z"
          fill="white"
          stroke={getObjectValue(
            props.theme.colors,
            props.iconColor,
            props.theme.colors.grey.deep,
          )}
          strokeWidth="1.66667"
          strokeLinecap="round"
          strokeLinejoin="round"
        />
      </svg>
    </IconWrapper>
  );
};

VariantsIcon.propTypes = {
  iconColor: PropTypes.string,
};

export default withTheme(VariantsIcon);
