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

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

    const prefix = prefixFromProps || prefixFromContext || 'hiagent';
    const loadingKls = spin ? ` ${prefix}-icon-loading` : '';
    return <svg className={`${prefix}-icon ${prefix}-icon-done-alt${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 48 48" fill={useCurrentColor ? 'currentColor' : '#000'} xmlns="http://www.w3.org/2000/svg" {...rest} ref={ref}><path fillRule="evenodd" clipRule="evenodd" d="M24 3c11.598 0 21 9.402 21 21s-9.402 21-21 21H5.1A2.1 2.1 0 013 42.9V24C3 12.402 12.402 3 24 3zm0 4C14.611 7 7 14.611 7 24v17h17c9.389 0 17-7.611 17-17S33.389 7 24 7zm6.728 12.354l1.414 1.414a1 1 0 010 1.414l-9.9 9.9a1 1 0 01-1.326.077l-.087-.077-5.657-5.657a1 1 0 010-1.414l1.414-1.415a1 1 0 011.414 0l3.536 3.536 7.778-7.778a1 1 0 011.414 0z"/></svg>;
}

const IconDoneAlt = React.forwardRef(IconDoneAltComponent);
export default IconDoneAlt;
