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

function IconModelTrainingComponent(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-model_training${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 22 22" fill={useCurrentColor ? 'currentColor' : '#000'} xmlns="http://www.w3.org/2000/svg" {...rest} ref={ref}><path d="M14.9244 1.8335C15.2473 1.8335 15.469 2.15884 15.3512 2.45947L14.5524 4.49756H14.5514V6.65381L17.649 12.895L17.6569 12.9116L19.6432 16.9136C19.7957 17.2209 19.8746 17.5577 19.8746 17.8989C19.8746 19.1514 18.8301 20.1665 17.5416 20.1665H4.45959C4.10754 20.1665 3.75985 20.089 3.44299 19.9399C2.28322 19.3942 1.79761 18.038 2.359 16.9106L4.34826 12.9175L4.35119 12.9106L7.4674 6.65283V4.49756H7.46057L6.66174 2.45947C6.54393 2.15893 6.76575 1.83368 7.08849 1.8335H14.9244ZM14.774 11.353C13.5382 11.0761 12.106 10.8691 10.5983 12.0903C9.60409 12.8956 8.51427 12.9118 7.59728 12.6938C7.24152 12.6093 6.95578 12.5335 6.69787 12.4194L4.47131 17.1021C4.24015 17.5886 4.59474 18.1498 5.13342 18.1499H16.8639C17.4034 18.1498 17.758 17.5868 17.525 17.1001L14.774 11.353ZM13.2916 13.7505C14.051 13.7505 14.6666 14.3661 14.6666 15.1255C14.6664 15.8847 14.0509 16.5005 13.2916 16.5005C12.5324 16.5004 11.9168 15.8847 11.9166 15.1255C11.9166 14.3662 12.5323 13.7506 13.2916 13.7505Z"/></svg>;
}

const IconModelTraining = React.forwardRef(IconModelTrainingComponent);
export default IconModelTraining;
