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

function IconFunctionCallComponent(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-function_call${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 14 14" fill={useCurrentColor ? 'currentColor' : '#000'} xmlns="http://www.w3.org/2000/svg" {...rest} ref={ref}><path d="M10.299 1.80803C11.3619 1.80818 12.2238 2.67075 12.2238 3.73381V10.267C12.2236 11.3299 11.3619 12.1917 10.299 12.1918H3.76575C2.70269 12.1918 1.84012 11.33 1.83997 10.267V3.73381C1.83997 2.67066 2.7026 1.80803 3.76575 1.80803H10.299ZM3.76575 2.85881C3.2825 2.85881 2.89075 3.25056 2.89075 3.73381V10.267C2.8909 10.7501 3.2826 11.142 3.76575 11.142H10.299C10.782 11.1419 11.1738 10.75 11.174 10.267V3.73381C11.174 3.25065 10.7821 2.85896 10.299 2.85881H3.76575ZM7.57043 3.47112C7.8081 3.41236 8.03472 3.4144 8.24231 3.48088C8.4498 3.54733 8.60932 3.6688 8.72668 3.8051C8.95056 4.06511 9.03673 4.39277 9.06946 4.59319C9.10819 4.83151 8.94647 5.05622 8.70813 5.09514C8.46978 5.13391 8.24515 4.97217 8.20618 4.73381C8.18455 4.60121 8.1349 4.45933 8.0636 4.37639C8.03338 4.34129 8.00482 4.32324 7.97571 4.31389C7.94678 4.30462 7.8874 4.29426 7.7804 4.32072C7.73326 4.33238 7.60665 4.41229 7.44641 4.72893C7.32723 4.9645 7.22152 5.26902 7.12805 5.61272H7.92395C8.16556 5.61272 8.36145 5.80857 8.36145 6.05022C8.36145 6.29183 8.16557 6.48772 7.92395 6.48772H6.92883C6.83391 6.98099 6.76438 7.4621 6.70911 7.84514C6.68583 8.00672 6.6647 8.15173 6.64563 8.2719C6.589 8.62761 6.4473 9.15447 6.22473 9.60393C6.11365 9.82816 5.97133 10.0568 5.79016 10.2348C5.60775 10.4139 5.35387 10.5707 5.03625 10.5707C4.82259 10.5707 4.54284 10.5244 4.29114 10.2905C4.05628 10.072 3.89837 9.73742 3.79407 9.28362C3.73995 9.04812 3.88671 8.81333 4.12219 8.7592C4.35755 8.70523 4.59239 8.85203 4.64661 9.08733C4.73262 9.46161 4.83481 9.60133 4.88684 9.64983C4.9219 9.68238 4.9554 9.69568 5.03625 9.69572C5.04721 9.69572 5.09303 9.69215 5.17688 9.60979C5.26179 9.52636 5.3535 9.39305 5.44153 9.21526C5.61725 8.86039 5.73561 8.4217 5.78137 8.1342C5.79779 8.03098 5.8163 7.90024 5.83801 7.74944C5.88747 7.40608 5.9541 6.95791 6.04016 6.48772H5.21106C4.96961 6.48751 4.77356 6.2917 4.77356 6.05022C4.77356 5.8087 4.96961 5.61293 5.21106 5.61272H6.22375C6.33645 5.15653 6.47895 4.70138 6.66516 4.33342C6.84605 3.97592 7.12751 3.58069 7.57043 3.47112ZM9.45129 7.2133C9.61039 7.03155 9.8867 7.01319 10.0685 7.17229C10.2501 7.33145 10.2686 7.60773 10.1095 7.78947L9.43274 8.56194L10.1095 9.3344C10.2685 9.51617 10.2501 9.79245 10.0685 9.95158C9.88667 10.1106 9.6104 10.0922 9.45129 9.91057L8.85168 9.226L8.25305 9.91057C8.0939 10.0923 7.81764 10.1107 7.63586 9.95158C7.45415 9.79249 7.43578 9.51622 7.59485 9.3344L8.27063 8.56194L7.59485 7.78947C7.43578 7.60767 7.45426 7.33139 7.63586 7.17229C7.81774 7.01316 8.09397 7.0315 8.25305 7.2133L8.85168 7.8969L9.45129 7.2133Z"/></svg>;
}

const IconFunctionCall = React.forwardRef(IconFunctionCallComponent);
export default IconFunctionCall;
