import { useId, type SVGProps } from 'react';

export type TogglebuttonIconProps = SVGProps<SVGSVGElement> & {
  /** Accessibility title for the icon, set aria-hidden="true" if the icon is purely decorative. */
  title?: string;
  /**
   * The size of the icon.
   * It sets the font-size, possible as the width and height is `1em`. If not set, the icon will inherit the font size of its parent.
   */
  size?: '2xl' | 'xl' | 'large' | 'medium' | 'small';
  /**
   * The color of the icon.
   * @default 'inherit'
   */
  color?: 'inherit' | 'primary' | 'gray' | 'black' | 'white';
};

export const TogglebuttonIcon = ({ title, size, color, ...props }: TogglebuttonIconProps) => {
  const titleId = useId();
  return (
    <svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24" focusable='false' role='img' width='1em' height='1em'  aria-labelledby={title ? titleId : undefined} data-size={size} data-color={color} {...props}>{title ? <title id={titleId}>{title}</title> : null}<path fillRule="evenodd" d="M6.261 6.262a1.746 1.746 0 1 0 0 3.493 1.746 1.746 0 0 0 0-3.493M3.015 8.008a3.246 3.246 0 1 1 6.492 0 3.246 3.246 0 0 1-6.492 0m16.227.75h-7.24v-1.5h7.24zm-1.498 5.492a1.746 1.746 0 1 0 0 3.493 1.746 1.746 0 0 0 0-3.493m-3.246 1.747a3.246 3.246 0 1 1 6.493 0 3.246 3.246 0 0 1-6.493 0m-9.735-.75h7.24v1.5h-7.24z" clipRule="evenodd" /></svg>
  );
};