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

function IconSystemVoiceComponent(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-system_voice${loadingKls} ${className}`} width={width} height={height} xmlns="http://www.w3.org/2000/svg" fill={useCurrentColor ? 'currentColor' : '#000'} viewBox="0 0 20 20" {...rest} ref={ref}><path d="M16.333 2.333a2 2 0 0 1 2 2v9.5a2 2 0 0 1-2 2h-3.836a1 1 0 0 0-.707.293L10 17.917l-1.79-1.791a1.002 1.002 0 0 0-.708-.293H3.667a2 2 0 0 1-2-2v-9.5a2 2 0 0 1 2-2h12.666Zm-8 2.467a.75.75 0 0 0-.75.75v7.162a.75.75 0 0 0 1.5 0V5.55a.75.75 0 0 0-.75-.75ZM5 6.335a.75.75 0 0 0-.75.75v4.093a.75.75 0 0 0 1.5 0V7.085a.75.75 0 0 0-.75-.75Zm10 0a.75.75 0 0 0-.75.75v4.093a.75.75 0 0 0 1.5 0V7.085a.75.75 0 0 0-.75-.75Zm-3.333 1.022a.75.75 0 0 0-.75.75v2.046a.75.75 0 0 0 1.5 0V8.107a.75.75 0 0 0-.75-.75Z"/></svg>;
}

const IconSystemVoice = React.forwardRef(IconSystemVoiceComponent);
export default IconSystemVoice;
