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

function IconArrowClockwiseComponent(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 || 'hkgai';
    const loadingKls = spin ? ` ${prefix}-icon-loading` : '';
    return <svg className={`${prefix}-icon ${prefix}-icon-ArrowClockwise${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 20 20" fill={useCurrentColor ? 'currentColor' : '#000'} xmlns="http://www.w3.org/2000/svg" {...rest} ref={ref}><path d="M19.0626 4.37496V8.12496C19.0626 8.3736 18.9638 8.61205 18.788 8.78787C18.6122 8.96369 18.3737 9.06246 18.1251 9.06246H14.3751C14.1265 9.06246 13.888 8.96369 13.7122 8.78787C13.5364 8.61205 13.4376 8.3736 13.4376 8.12496C13.4376 7.87632 13.5364 7.63786 13.7122 7.46204C13.888 7.28623 14.1265 7.18746 14.3751 7.18746H15.711L14.2267 5.82964C14.2165 5.82027 14.2063 5.81089 14.197 5.80074C13.5087 5.11289 12.6619 4.60474 11.7312 4.321C10.8004 4.03726 9.81415 3.98663 8.85922 4.17355C7.90428 4.36048 7.00992 4.77923 6.25483 5.39297C5.49974 6.00671 4.90706 6.79663 4.52893 7.69321C4.15081 8.5898 3.99884 9.56558 4.08639 10.5347C4.17394 11.5038 4.49833 12.4365 5.03101 13.2508C5.5637 14.0651 6.28835 14.7361 7.14121 15.2045C7.99407 15.673 8.949 15.9247 9.92197 15.9375H10.0001C11.5157 15.9411 12.9745 15.3615 14.0743 14.3187C14.2551 14.1479 14.4963 14.0558 14.745 14.0629C14.9936 14.0699 15.2293 14.1754 15.4001 14.3562C15.5709 14.537 15.663 14.7782 15.6559 15.0269C15.6489 15.2755 15.5434 15.5112 15.3626 15.682C13.9149 17.0542 11.9948 17.817 10.0001 17.8125H9.89307C8.6142 17.7944 7.35931 17.4627 6.2386 16.8464C5.11789 16.2301 4.16562 15.3481 3.46542 14.2778C2.76523 13.2075 2.33851 11.9816 2.22274 10.7079C2.10698 9.43412 2.3057 8.15143 2.80147 6.97243C3.29724 5.79343 4.07489 4.75417 5.06613 3.94592C6.05737 3.13767 7.23189 2.58514 8.48656 2.33686C9.74122 2.08857 11.0377 2.15211 12.262 2.52191C13.4864 2.89171 14.6012 3.55645 15.5087 4.45777L17.1876 5.99371V4.37496C17.1876 4.12632 17.2864 3.88786 17.4622 3.71204C17.638 3.53623 17.8765 3.43746 18.1251 3.43746C18.3737 3.43746 18.6122 3.53623 18.788 3.71204C18.9638 3.88786 19.0626 4.12632 19.0626 4.37496Z"/></svg>;
}

const IconArrowClockwise = React.forwardRef(IconArrowClockwiseComponent);
export default IconArrowClockwise;
