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

function IconOpenaiComponent(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 || 'hiagent';
    const loadingKls = spin ? ` ${prefix}-icon-loading` : '';
    return <svg className={`${prefix}-icon ${prefix}-icon-openai${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 14 14" fill={useCurrentColor ? 'currentColor' : 'none'} xmlns="http://www.w3.org/2000/svg" {...rest} ref={ref}><g clipPath="url(#svg_2c6ee24b09__clip0_7915_3258)"><path d="M12.4175 5.84706C12.5574 5.41982 12.606 4.96794 12.5601 4.52072C12.5142 4.0735 12.3748 3.64092 12.151 3.25101C11.8131 2.6654 11.2986 2.20167 10.6812 1.92615C10.0637 1.65063 9.37497 1.57743 8.71342 1.71703C8.11859 1.04527 7.24323 0.669983 6.33598 0.669983C5.66045 0.67022 5.00219 0.883402 4.45478 1.27922C3.90737 1.67504 3.49867 2.23336 3.28678 2.87479C2.84618 2.96531 2.42996 3.14881 2.06593 3.41301C1.7019 3.67722 1.39843 4.01606 1.17579 4.4069C0.840096 4.99189 0.69722 5.66778 0.76745 6.33858C0.83768 7.00939 1.11745 7.64103 1.56703 8.14381C1.42908 8.5722 1.38285 9.02483 1.43135 9.47226C1.47984 9.91969 1.62197 10.3519 1.84849 10.7408C2.18421 11.3289 2.69877 11.7946 3.31735 12.0701C3.93592 12.3456 4.62626 12.4167 5.28799 12.2729C5.588 12.6061 5.95444 12.8728 6.36373 13.0559C6.77303 13.239 7.21612 13.3344 7.66449 13.3359C8.34002 13.3357 8.99828 13.1225 9.54569 12.7267C10.0931 12.3308 10.5018 11.7725 10.7137 11.1311C11.1543 11.0406 11.5705 10.8571 11.9345 10.5929C12.2986 10.3287 12.602 9.98982 12.8247 9.59898C13.162 9.0107 13.3043 8.33072 13.2313 7.65654C13.1584 6.98236 12.8738 6.3486 12.4184 5.84612L12.4175 5.84706ZM7.66355 12.5084C7.10888 12.5131 6.57092 12.3187 6.1474 11.9605C6.16335 11.9445 6.21026 11.9286 6.22621 11.9136L8.74344 10.4593C8.80577 10.4225 8.8573 10.3699 8.89287 10.3068C8.92844 10.2437 8.9468 10.1724 8.94609 10.1V6.55072L10.01 7.16056C10.025 7.16056 10.025 7.17557 10.025 7.19152V10.131C10.0282 10.4426 9.9693 10.7518 9.85191 11.0406C9.73453 11.3293 9.56094 11.5919 9.34123 11.813C9.12152 12.0341 8.86008 12.2093 8.57207 12.3286C8.28407 12.4478 7.97525 12.5086 7.66355 12.5075V12.5084ZM2.56623 10.3345C2.28476 9.84949 2.19094 9.28656 2.28476 8.73958C2.30071 8.75459 2.33167 8.77148 2.36357 8.78649L4.8808 10.2407C4.94162 10.2791 5.01204 10.2994 5.08393 10.2994C5.15582 10.2994 5.22624 10.2791 5.28705 10.2407L8.36721 8.45811V9.6928C8.36721 9.70969 8.36721 9.7247 8.3522 9.7247L5.80307 11.193C4.67721 11.8498 3.22298 11.4595 2.56623 10.3336V10.3345ZM1.91041 4.83097C2.19188 4.35248 2.62721 3.98282 3.14511 3.78298V6.78527C3.14511 6.92601 3.22392 7.06674 3.3487 7.14461L6.4298 8.92722L5.36586 9.53706C5.35085 9.53706 5.3349 9.55301 5.3349 9.53706L2.78577 8.06688C2.51382 7.91373 2.27506 7.708 2.08342 7.46166C1.89177 7.21531 1.75107 6.9333 1.66951 6.63203C1.58796 6.33077 1.56717 6.01629 1.60837 5.70691C1.64956 5.39754 1.75192 5.09945 1.90948 4.83003H1.91041V4.83097ZM10.6668 6.86408L7.58662 5.08147L8.64962 4.47163C8.66557 4.47163 8.68152 4.45568 8.68152 4.47163L11.2297 5.94088C11.6203 6.16534 11.9386 6.49685 12.1469 6.89628C12.3552 7.29572 12.445 7.74641 12.4055 8.19518C12.3661 8.64396 12.1991 9.07208 11.9242 9.42904C11.6494 9.786 11.2782 10.0569 10.8544 10.2098V7.22436C10.8596 7.15295 10.8448 7.08151 10.8116 7.01804C10.7785 6.95458 10.7283 6.90159 10.6668 6.86502V6.86408ZM11.7148 5.26912C11.691 5.25007 11.6648 5.23429 11.6369 5.22221L9.11873 3.7661C9.05787 3.72787 8.98747 3.70759 8.9156 3.70759C8.84374 3.70759 8.77333 3.72787 8.71248 3.7661L5.63138 5.5487V4.31401C5.63138 4.29806 5.63138 4.28211 5.64733 4.28211L8.19552 2.81287C8.46524 2.65667 8.76321 2.55538 9.07225 2.51486C9.38129 2.47433 9.69529 2.49535 9.99617 2.57672C10.297 2.65809 10.5788 2.79819 10.8253 2.98895C11.0718 3.17972 11.2781 3.41737 11.4324 3.68822C11.7138 4.15733 11.8077 4.72026 11.7138 5.26818L11.7148 5.26912ZM5.05344 7.45704L3.98856 6.8472C3.97355 6.8472 3.97355 6.83125 3.97355 6.8153V3.8768C3.97355 3.56468 4.03506 3.25562 4.15456 2.96728C4.27406 2.67894 4.44921 2.41698 4.67 2.19636C4.89079 1.97575 5.15289 1.8008 5.44132 1.68153C5.72976 1.56226 6.03887 1.501 6.35099 1.50124C6.90554 1.49628 7.44349 1.69035 7.86715 2.04822C7.84344 2.06733 7.81724 2.08311 7.78927 2.09513L5.27204 3.54843C5.20954 3.58517 5.15782 3.63773 5.12208 3.70081C5.08634 3.76389 5.06784 3.83527 5.06845 3.90777V7.45704H5.0525H5.05344ZM5.63138 6.20639L7.0068 5.40891L8.38316 6.20639V7.78541L7.0068 8.58289L5.63138 7.78541V6.20639Z" fill={useCurrentColor ? 'currentColor' : '#000'}/></g><defs><clipPath id="svg_2c6ee24b09__clip0_7915_3258"><path fill={useCurrentColor ? 'currentColor' : '#fff'} d="M0 0H14V14H0z"/></clipPath></defs></svg>;
}

const IconOpenai = React.forwardRef(IconOpenaiComponent);
export default IconOpenai;
