import { forwardRef, useMemo } from 'react';
import { IconProps } from './types';

export const IconPieChart16 = forwardRef<SVGSVGElement, IconProps>(
    ({ color = 'currentColor', title, ...props }, svgRef) => {
        const titleId = useMemo(
            () =>
                title
                    ? 'title-' + Math.random().toString(36).substr(2, 9)
                    : undefined,
            [title]
        );
        return (
            <svg
                xmlns="http://www.w3.org/2000/svg"
                width={16}
                height={16}
                fill="none"
                viewBox="0 0 16 16"
                aria-hidden={!title}
                ref={svgRef}
                aria-labelledby={titleId}
                {...props}
            >
                {title ? <title id={titleId}>{title}</title> : null}
                <g fill={color}>
                    <path
                        fillRule="evenodd"
                        d="M7.75.05a.7.7 0 00-.7.7v7.5a.7.7 0 00.7.7h7.5a.7.7 0 00.7-.7 8.2 8.2 0 00-8.2-8.2zm.7 7.5V1.486a6.8 6.8 0 016.064 6.064H8.45z"
                        clipRule="evenodd"
                    />
                    <path d="M5.118 2.172A.75.75 0 004.452.828a8 8 0 1010.72 10.72.75.75 0 00-1.344-.666 6.5 6.5 0 11-8.71-8.71z" />
                </g>
            </svg>
        );
    }
);
