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

function IconVariableAggregationComponent(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-variable-aggregation${loadingKls} ${className}`} width={width} height={height} xmlns="http://www.w3.org/2000/svg" fill={useCurrentColor ? 'currentColor' : 'none'} viewBox="0 0 20 20" {...rest} ref={ref}><rect width="20" height="20" fill={useCurrentColor ? 'currentColor' : '#61C78A'} rx="6"/><path fill={useCurrentColor ? 'currentColor' : '#fff'} d="M11.1906 4.43945C11.7768 3.85348 12.7273 3.85355 13.3136 4.43945L17.5607 8.68652C18.1467 9.27279 18.1467 10.2233 17.5607 10.8096L13.3136 15.0566C12.7273 15.6425 11.7768 15.6426 11.1906 15.0566L10.5304 14.3965L9.34096 15.5869C8.75463 16.1732 7.80326 16.1732 7.21693 15.5869L2.43959 10.8096C1.85351 10.2233 1.85351 9.2728 2.43959 8.68652L6.68666 4.43945C7.27294 3.85357 8.22348 3.85347 8.80971 4.43945L10.0001 5.62988L11.1906 4.43945ZM3.50111 9.74805L8.27846 14.5254L9.46889 13.334L6.94447 10.8096C6.35815 10.2232 6.35815 9.27284 6.94447 8.68652L8.93764 6.6914L7.74818 5.50195L3.50111 9.74805ZM11.0617 6.6914L13.5871 9.2168C14.1734 9.80311 14.1734 10.7545 13.5871 11.3408L11.5929 13.335L12.2521 13.9941L16.4992 9.74805L12.2521 5.50195L11.0617 6.6914ZM8.006 9.74805L10.5304 12.2725L12.5255 10.2793L10.0001 7.7539L8.006 9.74805Z"/></svg>;
}

const IconVariableAggregation = React.forwardRef(IconVariableAggregationComponent);
export default IconVariableAggregation;
