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

function IconCellPhoneComponent(props: OriginIconProps, ref: ForwardedRef<SVGSVGElement>) {
    const { prefix: prefixFromContext } = useContext(Context);
    const { className = '', prefix: prefixFromProps, width = '1em', height = '1em', useCurrentColor = false, spin, ...rest } = props;

    const prefix = prefixFromProps || prefixFromContext || 'hkgai';
    const loadingKls = spin ? ` ${prefix}-icon-loading` : '';
    return <svg className={`${prefix}-icon ${prefix}-icon-cell-phone${loadingKls} ${className}`} width={width} height={height} viewBox="0 0 20 20" fill="none" {...rest} ref={ref}><rect x="3" width="14" height="20" rx="2" fill={useCurrentColor ? 'currentColor' : '#F74'}/><path d="M3 15h14v3a2 2 0 01-2 2H5a2 2 0 01-2-2v-3z" fill={useCurrentColor ? 'currentColor' : '#FA4'}/><path d="M8 17a1 1 0 011-1h1.333a1 1 0 010 2H9a1 1 0 01-1-1z" fill={useCurrentColor ? 'currentColor' : '#fff'}/></svg>;
}

const IconCellPhone = React.forwardRef(IconCellPhoneComponent);
export default IconCellPhone;
