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

function IconAppToolsComponent(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-app-tools${loadingKls} ${className}`} width={width} height={height} xmlns="http://www.w3.org/2000/svg" fill={useCurrentColor ? 'currentColor' : 'none'} viewBox="0 0 16 16" {...rest} ref={ref}><rect width="6" height="6" x="1.333" y="1.333" fill={useCurrentColor ? 'currentColor' : '#7BA6F9'} rx=".667"/><rect width="6" height="6" x="8.666" y="8.667" fill={useCurrentColor ? 'currentColor' : '#7BA6F9'} rx=".667"/><rect width="4.776" height="4.776" x=".986" y="11.521" fill={useCurrentColor ? 'currentColor' : '#7BA6F9'} rx=".667" transform="rotate(-45 .986 11.52)"/><circle cx="11.666" cy="4.333" r="3" fill={useCurrentColor ? 'currentColor' : '#7BA6F9'} opacity=".5"/></svg>;
}

const IconAppTools = React.forwardRef(IconAppToolsComponent);
export default IconAppTools;
