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

function IconKnowledgeGraphComponent(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-knowledge-graph${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 18 18" fill={useCurrentColor ? 'currentColor' : 'none'} xmlns="http://www.w3.org/2000/svg" {...rest} ref={ref}><path opacity=".5" fillRule="evenodd" clipRule="evenodd" d="M5.375 1.75H14.6964C15.5509 1.75 16.25 2.44911 16.25 3.30357V12.625C16.25 13.037 16.0863 13.4322 15.795 13.7235C15.5036 14.0149 15.1085 14.1786 14.6964 14.1786H5.375C4.96297 14.1786 4.56781 14.0149 4.27646 13.7235C3.98511 13.4322 3.82143 13.037 3.82143 12.625V3.30357C3.82143 2.44911 4.52053 1.75 5.375 1.75ZM9.76721 8.31944C9.96917 8.50586 10.2403 8.61461 10.5362 8.61461C11.181 8.61461 11.7006 8.09417 11.7006 7.44944C11.7006 6.8047 11.1802 6.28426 10.5354 6.28426C9.89072 6.28426 9.37027 6.8047 9.37027 7.44944C9.37027 7.51158 9.37804 7.57372 9.38581 7.63586L6.24759 9.44578C6.20099 9.38363 6.13884 9.33703 6.0767 9.29819L6.33226 7.46497V7.4572C6.62666 7.35622 6.84494 7.06881 6.84494 6.73479C6.84494 6.29979 6.49461 5.95801 6.06816 5.95801C5.64015 5.95801 5.29137 6.29979 5.29137 6.73479C5.29286 6.84674 5.31783 6.95713 5.36466 7.05882C5.41149 7.16051 5.47914 7.25125 5.56324 7.32515L5.31467 9.07292C4.70956 9.11176 4.22717 9.6089 4.22717 10.2303C4.22717 10.8673 4.74762 11.3955 5.39235 11.3955C5.68831 11.3955 5.96717 11.279 6.16914 11.0848L7.87962 12.1412C7.84 12.2733 7.81748 12.4139 7.81748 12.5607C7.81748 12.868 7.90859 13.1683 8.0793 13.4238C8.25001 13.6793 8.49264 13.8784 8.77652 13.996C9.0604 14.1136 9.37277 14.1444 9.67413 14.0844C9.9755 14.0245 10.2523 13.8765 10.4696 13.6592C10.6869 13.442 10.8348 13.1651 10.8948 12.8638C10.9547 12.5624 10.9239 12.25 10.8064 11.9662C10.6888 11.6823 10.4896 11.4396 10.2342 11.2689C9.97868 11.0982 9.67832 11.0071 9.37105 11.0071C8.93527 11.0071 8.53989 11.1866 8.26801 11.4732H8.25947L6.54277 10.4012C6.55054 10.3468 6.55831 10.2925 6.55831 10.2303C6.55831 10.207 6.55831 10.1837 6.55054 10.1682L9.76721 8.31944Z" fill={useCurrentColor ? 'currentColor' : '#9E56F6'}/><path fillRule="evenodd" clipRule="evenodd" d="M3.30357 3.82129H12.625C13.4795 3.82129 14.1786 4.5204 14.1786 5.37486V14.6963C14.1786 15.1083 14.0149 15.5035 13.7235 15.7948C13.4322 16.0862 13.037 16.2499 12.625 16.2499H3.30357C2.89154 16.2499 2.49638 16.0862 2.20503 15.7948C1.91368 15.5035 1.75 15.1083 1.75 14.6963V5.37486C1.75 4.5204 2.44911 3.82129 3.30357 3.82129ZM9.76721 8.31944C9.96917 8.50586 10.2403 8.61461 10.5362 8.61461C11.181 8.61461 11.7006 8.09417 11.7006 7.44944C11.7006 6.8047 11.1802 6.28426 10.5354 6.28426C9.89072 6.28426 9.37027 6.8047 9.37027 7.44944C9.37027 7.51158 9.37804 7.57372 9.38581 7.63586L6.24759 9.44578C6.20099 9.38363 6.13884 9.33703 6.0767 9.29819L6.33226 7.46497V7.4572C6.62666 7.35622 6.84494 7.06881 6.84494 6.73479C6.84494 6.29979 6.49461 5.95801 6.06816 5.95801C5.64015 5.95801 5.29137 6.29979 5.29137 6.73479C5.29286 6.84674 5.31783 6.95713 5.36466 7.05882C5.41149 7.16051 5.47914 7.25125 5.56324 7.32515L5.31467 9.07292C4.70956 9.11176 4.22717 9.6089 4.22717 10.2303C4.22717 10.8673 4.74762 11.3955 5.39235 11.3955C5.68831 11.3955 5.96717 11.279 6.16914 11.0848L7.87962 12.1412C7.84 12.2733 7.81748 12.4139 7.81748 12.5607C7.81748 12.868 7.90859 13.1683 8.0793 13.4238C8.25001 13.6793 8.49264 13.8784 8.77652 13.996C9.0604 14.1136 9.37277 14.1444 9.67413 14.0844C9.9755 14.0245 10.2523 13.8765 10.4696 13.6592C10.6869 13.442 10.8348 13.1651 10.8948 12.8638C10.9547 12.5624 10.9239 12.25 10.8064 11.9662C10.6888 11.6823 10.4896 11.4396 10.2342 11.2689C9.97868 11.0982 9.67831 11.0071 9.37105 11.0071C8.93527 11.0071 8.53989 11.1866 8.26801 11.4732H8.25947L6.54277 10.4012C6.55054 10.3468 6.55831 10.2925 6.55831 10.2303C6.55831 10.207 6.55831 10.1837 6.55054 10.1682L9.76721 8.31944Z" fill={useCurrentColor ? 'currentColor' : '#9E56F6'}/></svg>;
}

const IconKnowledgeGraph = React.forwardRef(IconKnowledgeGraphComponent);
export default IconKnowledgeGraph;
