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

function IconShareComponent(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-share${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}><g fillRule="evenodd" clipRule="evenodd"><path d="M2.06055 8.40308C2.06055 7.15124 3.07537 6.13642 4.32721 6.13642 5.57906 6.13642 6.59388 7.15124 6.59388 8.40308 6.59388 9.65493 5.57906 10.6698 4.32721 10.6698 3.07537 10.6698 2.06055 9.65493 2.06055 8.40308zM5.39388 8.40308C5.39388 7.81398 4.91632 7.33642 4.32721 7.33642 3.73811 7.33642 3.26055 7.81398 3.26055 8.40308 3.26055 8.99219 3.73811 9.46975 4.32721 9.46975 4.91632 9.46975 5.39388 8.99219 5.39388 8.40308zM9.40625 4.01936C9.40625 2.76752 10.4211 1.7527 11.6729 1.7527 12.9248 1.7527 13.9396 2.76752 13.9396 4.01936 13.9396 5.27121 12.9248 6.28603 11.6729 6.28603 10.4211 6.28603 9.40625 5.27121 9.40625 4.01936zM12.7396 4.01936C12.7396 3.43026 12.262 2.9527 11.6729 2.9527 11.0838 2.9527 10.6063 3.43026 10.6063 4.01936 10.6063 4.60847 11.0838 5.08603 11.6729 5.08603 12.262 5.08603 12.7396 4.60847 12.7396 4.01936zM9.19922 11.9806C9.19922 10.7288 10.214 9.71397 11.4659 9.71397 12.7177 9.71397 13.7326 10.7288 13.7326 11.9806 13.7326 13.2325 12.7177 14.2473 11.4659 14.2473 10.214 14.2473 9.19922 13.2325 9.19922 11.9806zM12.5326 11.9806C12.5326 11.3915 12.055 10.914 11.4659 10.914 10.8768 10.914 10.3992 11.3915 10.3992 11.9806 10.3992 12.5697 10.8768 13.0473 11.4659 13.0473 12.055 13.0473 12.5326 12.5697 12.5326 11.9806z"/><path d="M10.5159 4.58434C10.6905 4.86596 10.6038 5.23583 10.3222 5.41045L6.15846 7.99228C5.87684 8.1669 5.50698 8.08017 5.33235 7.79855 5.15772 7.51692 5.24445 7.14706 5.52608 6.97243L9.68976 4.39061C9.97139 4.21598 10.3413 4.30272 10.5159 4.58434zM5.34702 9.00417C5.50239 8.71148 5.86562 8.60017 6.15831 8.75554L9.95715 10.7722C10.2498 10.9276 10.3611 11.2908 10.2058 11.5835 10.0504 11.8762 9.68717 11.9875 9.39448 11.8321L5.59564 9.81545C5.30296 9.66008 5.19164 9.29685 5.34702 9.00417z"/></g></svg>;
}

const IconShare = React.forwardRef(IconShareComponent);
export default IconShare;
