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

function IconMindMappingComponent(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-mind-mapping${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 48 48" fill={useCurrentColor ? 'currentColor' : '#000'} xmlns="http://www.w3.org/2000/svg" {...rest} ref={ref}><path fillRule="evenodd" clipRule="evenodd" d="M12.852 7.812A5 5 0 107 15.585L7 36.25l.003.239C7.088 39.424 8.725 42 11.286 42H15a1 1 0 001-1v-2a1 1 0 00-1-1h-3.525l-.03-.038-.068-.101-.072-.132c-.186-.37-.305-.897-.305-1.479V27h4a1 1 0 001-1v-2a1 1 0 00-1-1h-4v-7.416A5.001 5.001 0 0013 8l-.148-.188zM44 39a1 1 0 00-1-1H22a1 1 0 00-1 1v2a1 1 0 001 1h21a1 1 0 001-1v-2zm-1-16a1 1 0 011 1v2a1 1 0 01-1 1H22a1 1 0 01-1-1v-2a1 1 0 011-1h21zm1-13a1 1 0 00-1-1H22a1 1 0 00-1 1v2a1 1 0 001 1h21a1 1 0 001-1v-2z"/></svg>;
}

const IconMindMapping = React.forwardRef(IconMindMappingComponent);
export default IconMindMapping;
