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

function IconCaretBottomComponent(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 || 'hkgai';
    const loadingKls = spin ? ` ${prefix}-icon-loading` : '';
    return <svg className={`${prefix}-icon ${prefix}-icon-CaretBottom${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 16 16" fill={useCurrentColor ? 'currentColor' : '#000'} xmlns="http://www.w3.org/2000/svg" {...rest} ref={ref}><path d="M8.14634 10.8535L3.14634 5.85351C3.07634 5.78358 3.02866 5.69445 3.00933 5.59741C2.99 5.50037 2.99991 5.39977 3.03778 5.30836C3.07566 5.21695 3.13981 5.13883 3.2221 5.0839C3.3044 5.02896 3.40115 4.99968 3.50009 4.99976L13.5001 4.99976C13.599 4.99968 13.6958 5.02896 13.7781 5.0839C13.8604 5.13883 13.9245 5.21695 13.9624 5.30836C14.0003 5.39977 14.0102 5.50037 13.9909 5.59741C13.9715 5.69445 13.9239 5.78358 13.8538 5.85351L8.85384 10.8535C8.80741 10.9 8.75226 10.9369 8.69156 10.962C8.63087 10.9872 8.5658 11.0001 8.50009 11.0001C8.43439 11.0001 8.36932 10.9872 8.30862 10.962C8.24793 10.9369 8.19278 10.9 8.14634 10.8535Z" fillOpacity="1"/></svg>;
}

const IconCaretBottom = React.forwardRef(IconCaretBottomComponent);
export default IconCaretBottom;
