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

function IconHandComponent(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-hand${loadingKls} ${className}`} width={width} height={height} xmlns="http://www.w3.org/2000/svg" fill={useCurrentColor ? 'currentColor' : '#000'} viewBox="0 0 24 25" {...rest} ref={ref}><path fillRule="evenodd" d="M18.826 5.927c.23-1.212-.514-2.491-1.812-2.75a2.315 2.315 0 0 0-2.143.686l.009-.545A2.318 2.318 0 0 0 12.607.962a2.318 2.318 0 0 0-2.354 2.25l-.062.961c-.45-.788-1.366-1.23-2.249-1.166-1.357.098-2.185 1.341-2.1 2.529l.002.02.8 8.389.004.029c.043.262.077.572.077.828a1.053 1.053 0 0 1-.034-.031l-2.062-2.14-.018-.017a2.623 2.623 0 0 0-3.694.105C-.197 13.73-.3 15.45.751 16.542c-.012-.014.236.267.71.788.449.494 1.064 1.164 1.728 1.864.661.697 1.374 1.43 2.02 2.05.6.576 1.206 1.114 1.667 1.41a8.962 8.962 0 0 0 5.321 1.907 6.904 6.904 0 0 0 6.691-4.699l.017-.051.038-.168 3-9.076a2.362 2.362 0 0 0-1.414-2.98l-.012-.004-.012-.005a2.346 2.346 0 0 0-1.963.187l.284-1.838Zm-2.98 7.33.003-.005c-.006.014-.009.017-.002.005ZM11.64 11.72l.549-8.425V3.27a.38.38 0 0 1 .384-.37.38.38 0 0 1 .37.384v.004l-.115 8.506a1.048 1.048 0 0 0 .696.998 1.013 1.013 0 0 0 .813-.059.996.996 0 0 0 .514-.713l1.323-6.62a.4.4 0 0 1 .461-.322c.17.034.34.236.288.493l-.005.02-1.225 7.87v.068c-.01.151.012.303.061.446a.982.982 0 0 0 1.727.298 1.27 1.27 0 0 0 .186-.353l1.69-4.277.006-.017a.384.384 0 0 1 .483-.223c.249.1.331.34.264.531l-.007.017-3.034 9.18-.034.165a4.968 4.968 0 0 1-4.805 3.329 7.028 7.028 0 0 1-4.2-1.526l-.045-.034-.046-.03c-.266-.162-.754-.579-1.389-1.189a58.655 58.655 0 0 1-1.957-1.985c-.83-.876-1.647-1.764-2.45-2.664-.257-.27-.27-.74.086-1.053l.037-.032.033-.034a.687.687 0 0 1 .972-.062l2.026 2.102c.386.397.883.685 1.447.723a1.797 1.797 0 0 0 1.467-.607c.196-.212.328-.475.384-.758.05-.222.064-.456.066-.658a7.347 7.347 0 0 0-.096-1.114l-.792-8.316a.49.49 0 0 1 .099-.326.29.29 0 0 1 .21-.123c.12-.01.24.026.335.1a.291.291 0 0 1 .12.208l.004.038 1.002 6.63.004.013c.035.2.122.39.252.547a1.022 1.022 0 0 0 1.745-.23 1.17 1.17 0 0 0 .096-.525Z" clipRule="evenodd"/></svg>;
}

const IconHand = React.forwardRef(IconHandComponent);
export default IconHand;
