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

function IconArtifactsSearchComponent(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-artifacts-search${loadingKls} ${className}`} width={width} height={height} xmlns="http://www.w3.org/2000/svg" fill={useCurrentColor ? 'currentColor' : '#000'} viewBox="0 0 16 16" {...rest} ref={ref}><path fillRule="evenodd" d="M7.536 2.273a5.067 5.067 0 1 0 0 10.134 5.067 5.067 0 0 0 0-10.134ZM1.27 7.34a6.267 6.267 0 1 1 12.533 0 6.267 6.267 0 0 1-12.533 0Z" clipRule="evenodd"/><path fillRule="evenodd" d="M7.515 4.095a.533.533 0 0 1 .548.408c.167.695.42 1.082.762 1.383.362.319.84.56 1.551.918l.067.033a.533.533 0 0 1-.024.964c-1.085.482-1.572.944-1.835 1.317a2.846 2.846 0 0 0-.302.569l-.056.138c-.06.151-.131.328-.211.479a.533.533 0 0 1-.998-.167c-.091-.573-.455-1.145-.927-1.59-.487-.459-.983-.686-1.251-.701a.533.533 0 0 1-.059-1.059c.581-.098 1.118-.451 1.534-.913.421-.468.658-.98.701-1.314a.533.533 0 0 1 .5-.465Zm.027 1.925a4.578 4.578 0 0 1-.436.568 4.32 4.32 0 0 1-.846.73A4.665 4.665 0 0 1 7.584 8.7c.039-.064.081-.13.128-.195.282-.401.692-.802 1.331-1.191a5.31 5.31 0 0 1-.922-.627 3.177 3.177 0 0 1-.579-.667Zm3.578 5.22a.6.6 0 0 1 .849.019l2.54 2.653a.6.6 0 1 1-.867.83l-2.54-2.654a.6.6 0 0 1 .018-.848Z" clipRule="evenodd"/></svg>;
}

const IconArtifactsSearch = React.forwardRef(IconArtifactsSearchComponent);
export default IconArtifactsSearch;
