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

function IconSwapAltComponent(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-swap-alt${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 48 48" fill={useCurrentColor ? 'currentColor' : '#000'} xmlns="http://www.w3.org/2000/svg" {...rest} ref={ref}><path fillRule="evenodd" clipRule="evenodd" d="M6 31.25a1 1 0 001 1l22.075.001-.001 6.149a.6.6 0 00.968.473l11.43-8.894a.997.997 0 00.25-.283.998.998 0 00-.718-1.696H7a1 1 0 00-1 1v2.25zm.179-11.67a1 1 0 00.814.42h34.005a1 1 0 001-1v-2.25a1 1 0 00-1-1l-22.075-.001V9.6a.6.6 0 00-.968-.473L6.525 18.02a.996.996 0 00-.249.283.998.998 0 00-.097 1.276z"/></svg>;
}

const IconSwapAlt = React.forwardRef(IconSwapAltComponent);
export default IconSwapAlt;
