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

function IconTakeoverComponent(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-takeover${loadingKls} ${className}`} width={width} height={height} xmlns="http://www.w3.org/2000/svg" fill={useCurrentColor ? 'currentColor' : '#000'} viewBox="0 0 24 24" {...rest} ref={ref}><g clipPath="url(#svg_26dedb51f7__a)"><path d="m6.29 23.098 3.29-1.978c.808.15 1.612.226 2.419.226 6.504 0 11.835-4.567 11.835-10.285C23.835 5.34 18.504.775 12 .775S.165 5.34.165 11.06c0 3.243 1.738 6.216 4.602 8.137l-.04 3.002a1.032 1.032 0 0 0 1.563.898ZM18 12.586a1.5 1.5 0 1 1 0-2.999 1.5 1.5 0 0 1 0 3Zm-12 0a1.5 1.5 0 1 1 0-2.999 1.5 1.5 0 0 1 0 3Zm6 0a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3Z"/></g><defs><clipPath id="svg_26dedb51f7__a"><path d="M0 0h24v24H0z"/></clipPath></defs></svg>;
}

const IconTakeover = React.forwardRef(IconTakeoverComponent);
export default IconTakeover;
