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

function IconContainsComponent(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-Contains${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 18 18" fill={useCurrentColor ? 'currentColor' : '#000'} xmlns="http://www.w3.org/2000/svg" {...rest} ref={ref}><path fillRule="evenodd" clipRule="evenodd" d="M5.46668 6.67427C5.84635 7.11711 6.03203 7.73524 6.03203 8.48551V14.3736H4.77953V14.0115C4.45155 14.3375 4.03805 14.4947 3.54953 14.4947C2.92884 14.4947 2.42499 14.2822 2.0703 13.8152L2.06764 13.8117C1.73588 13.355 1.56653 12.7278 1.56653 11.9528C1.56653 11.2127 1.76827 10.5947 2.16145 10.1537C2.55682 9.71028 3.12305 9.48649 3.83303 9.48649H4.72553V8.44009C4.72553 8.02802 4.64273 7.75938 4.50799 7.594C4.37626 7.43233 4.165 7.33312 3.83303 7.33312C3.55042 7.33312 3.34399 7.42339 3.1962 7.57451C3.06011 7.74162 2.98103 7.95931 2.98103 8.27354V8.60495H1.74203V8.2584C1.74203 7.57573 1.93222 7.01556 2.32885 6.60493C2.72121 6.19874 3.22891 6.0041 3.84653 6.0041C4.53337 6.0041 5.07094 6.23036 5.46411 6.67132L5.46668 6.67427ZM4.47543 12.8735C4.64006 12.6642 4.73903 12.3553 4.73903 11.9376V10.6944H3.94103C3.55298 10.6944 3.29639 10.8063 3.13458 10.9951C2.97142 11.1855 2.87303 11.4907 2.87303 11.9528C2.87303 12.4144 2.95744 12.7204 3.09656 12.9088C3.22991 13.0894 3.43921 13.196 3.76553 13.196C4.08447 13.196 4.31364 13.0791 4.47543 12.8735ZM8.12554 14.3736H6.83649V3.50586H8.12949V6.49601C8.43618 6.17516 8.8208 6.0041 9.27849 6.0041C9.88394 6.0041 10.3822 6.25569 10.757 6.74328C11.1354 7.23556 11.3155 7.95966 11.3155 8.87917V11.6197C11.3155 12.5538 11.1356 13.2781 10.757 13.7707C10.3805 14.2605 9.88113 14.4947 9.29199 14.4947C8.82816 14.4947 8.43826 14.3409 8.13207 14.0295L8.12554 14.3736ZM9.77554 12.8122C9.92596 12.5832 10.009 12.1599 10.009 11.4985V9.0003C10.009 8.39592 9.91919 7.97922 9.76652 7.71921C9.62286 7.47456 9.41188 7.34827 9.10299 7.34827C8.7847 7.34827 8.55933 7.48283 8.39332 7.74196C8.23302 8.01335 8.12949 8.43585 8.12949 9.01544V11.5137C8.12949 12.0963 8.23409 12.5164 8.39208 12.7701C8.55522 13.0258 8.77844 13.1506 9.10299 13.1506C9.41937 13.1506 9.62817 13.0365 9.77554 12.8122ZM13.4351 7.69437C13.5961 7.47898 13.8359 7.34827 14.194 7.34827C14.5307 7.34827 14.7537 7.464 14.8985 7.66547C15.0494 7.87551 15.1405 8.21332 15.1405 8.71262V9.13488H16.4335V8.71262C16.4335 7.84552 16.2364 7.16674 15.8434 6.69207L15.841 6.68922L15.8385 6.68646C15.4307 6.229 14.8652 6.0041 14.167 6.0041C13.4658 6.0041 12.9006 6.24615 12.4942 6.7181C12.0654 7.20007 11.887 7.94909 11.887 8.87917V11.6197C11.887 12.5643 12.0651 13.3136 12.4942 13.7959C12.9036 14.2713 13.4847 14.4947 14.194 14.4947C14.8773 14.4947 15.4315 14.2858 15.8409 13.8096L15.8434 13.8068C16.2366 13.3318 16.4335 12.6527 16.4335 11.7711V11.3639H15.1405V11.7862C15.1405 12.2923 15.0463 12.6292 14.8932 12.8371C14.7457 13.0373 14.519 13.1506 14.1805 13.1506C13.8308 13.1506 13.5949 13.0315 13.4366 12.8066L13.4335 12.8023C13.2764 12.5909 13.18 12.1734 13.18 11.4985V9.0003C13.18 8.34582 13.2748 7.92396 13.4351 7.69437Z"/></svg>;
}

const IconContains = React.forwardRef(IconContainsComponent);
export default IconContains;
