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

function IconLicenceComponent(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-licence${loadingKls} ${className}`} width={width} height={height} xmlns="http://www.w3.org/2000/svg" fill={useCurrentColor ? 'currentColor' : '#000'} viewBox="0 0 36 36" {...rest} ref={ref}><path d="M9.50812 3.6521C8.67969 3.6521 8.00812 4.32367 8.00812 5.1521V8.53658L14.535 5.67048C14.9188 5.50195 15.3555 5.50169 15.7395 5.66976L26.4148 10.3424C26.9608 10.5813 27.3135 11.1201 27.3133 11.7161C27.3129 13.239 27.3123 16.0501 27.3123 16.5447C27.3123 21.7093 25.6411 25.1251 23.4375 27.894H30.75C31.5784 27.894 32.25 27.2224 32.25 26.394V5.1521C32.25 4.32367 31.5784 3.6521 30.75 3.6521H9.50812Z" opacity=".5"/><path d="M15.3489 18.3717C16.3845 18.3717 17.2239 17.5322 17.2239 16.4967C17.2239 15.4612 16.3845 14.6217 15.3489 14.6217C14.3134 14.6217 13.4739 15.4612 13.4739 16.4967C13.4739 17.5322 14.3134 18.3717 15.3489 18.3717Z"/><path fillRule="evenodd" d="M15.7391 5.66639C15.3551 5.49832 14.9183 5.49858 14.5345 5.66711L3.89646 10.3386C3.35148 10.5779 2.99955 11.1164 3 11.7116C3.00045 12.3092 3.00118 12.989 3.00189 13.6566C3.00298 14.6713 3.00404 15.6579 3.00404 16.2852C3.00404 20.9379 4.071 24.4419 6.98987 28.0471C9.87386 31.6088 13.5336 33.0641 14.7347 33.4666C14.997 33.5545 15.2768 33.5503 15.5392 33.4625C18.3573 32.5203 21.2348 30.6015 23.2844 28.0804C25.563 25.2778 27.3118 21.8246 27.3118 16.5413C27.3118 16.0467 27.3125 13.2356 27.3129 11.7128C27.313 11.1168 26.9603 10.578 26.4143 10.339L15.7391 5.66639ZM20.2239 16.4967C20.2239 18.7362 18.7138 20.623 16.6563 21.1944V22.7102H17.7154C18.1296 22.7102 18.4654 23.046 18.4654 23.4602V24.9602C18.4654 25.3744 18.1296 25.7102 17.7154 25.7102H16.6563V26.9967C16.6563 27.4109 16.3205 27.7467 15.9063 27.7467H14.4063C13.9921 27.7467 13.6563 27.4109 13.6563 26.9967V21.0698C11.7983 20.3819 10.4739 18.5939 10.4739 16.4967C10.4739 13.8043 12.6565 11.6217 15.3489 11.6217C18.0413 11.6217 20.2239 13.8043 20.2239 16.4967Z" clipRule="evenodd"/></svg>;
}

const IconLicence = React.forwardRef(IconLicenceComponent);
export default IconLicence;
