import React from 'react';
import styled from 'styled-components';

import type { IconProps } from '@redocly/theme/icons/types';

const Icon = (props: IconProps) => (
  <svg
    width="16"
    height="16"
    viewBox="0 0 16 16"
    fill="none"
    xmlns="http://www.w3.org/2000/svg"
    {...props}
  >
    <path d="M7.99956 15V8.0001L2 11.4999L7.99956 15Z" fill="#939393" />
    <path d="M14 4.49979L7.99956 15V8.0001L14 4.49979Z" fill="#E3E3E3" />
    <path d="M2 4.49979H14L7.99956 8.0001L2 4.49979Z" fill="white" />
    <path d="M8.00025 1V4.49995L14 4.49979L8.00025 1Z" fill="#444444" />
    <path
      d="M2 4.49979L8.00025 4.49995V1L2 4.49979ZM13.9999 11.4998L10.9999 9.74987L7.99956 15L13.9999 11.4998Z"
      fill="#939393"
    />
    <path
      d="M14 4.49979L10.9999 9.74987L13.9999 11.4998L14 4.49979ZM7.99956 8.0001L2 11.4999V4.49979L7.99956 8.0001Z"
      fill="#444444"
    />
  </svg>
);

export const CursorIcon = styled(Icon).attrs(() => ({
  'data-component-name': 'icons/CursorIcon/CursorIcon',
}))<IconProps>`
  height: ${({ size }) => size || '16px'};
  width: ${({ size }) => size || '16px'};
`;
