import React, { ForwardedRef, useContext } from 'react';
import { OriginIconProps } from '../type';
import { Context } from '../context';

function IconCloseCircleFillComponent(props: OriginIconProps, ref: ForwardedRef<SVGSVGElement>) {
    const { prefix: prefixFromContext } = useContext(Context);
    const { className = '', prefix: prefixFromProps, width = '1em', height = '1em', useCurrentColor = false, spin, ...rest } = props;

    const prefix = prefixFromProps || prefixFromContext || 'hkgai';
    const loadingKls = spin ? ` ${prefix}-icon-loading` : '';
    return <svg className={`${prefix}-icon ${prefix}-icon-close-circle-fill${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 32 33" fill="none" xmlns="http://www.w3.org/2000/svg" {...rest} ref={ref}><path fillRule="evenodd" clipRule="evenodd" d="M2.66675 16.5C2.66675 9.1362 8.63628 3.16667 16.0001 3.16667C23.3639 3.16667 29.3334 9.1362 29.3334 16.5C29.3334 23.8638 23.3639 29.8333 16.0001 29.8333C8.63628 29.8333 2.66675 23.8638 2.66675 16.5ZM10.819 13.2047L14.1188 16.5045L10.819 19.8044L12.7046 21.69L16.0044 18.3902L19.3043 21.69L21.1899 19.8044L17.8901 16.5045L21.1899 13.2047L19.3043 11.3191L16.0044 14.6189L12.7046 11.3191L10.819 13.2047Z" fill={useCurrentColor ? 'currentColor' : '#CB272D'}/></svg>;
}

const IconCloseCircleFill = React.forwardRef(IconCloseCircleFillComponent);
export default IconCloseCircleFill;
