import { RcIcon } from '@ringcentral/juno'; import { InfoBorder } from '@ringcentral/juno-icon'; import clsx from 'clsx'; import type { FunctionComponent } from 'react'; import React from 'react'; import IconLine from '../IconLine'; import { Tooltip } from '../Rcui/Tooltip'; import Switch from '../Switch'; import type { SwitchLineItemProps } from './SettingsPanel.interface'; import i18n from './i18n'; import styles from './styles.scss'; export const SwitchLineItem: FunctionComponent = ({ show, name, customTitle, switchTitle, currentLocale, dataSign, disabled, checked, onChange, tooltip, children, }) => { if (!show) { return null; } return ( } > {/* @ts-expect-error TS(2345): Argument of type 'string | undefined' is not assig... Remove this comment to see the full error message */} {customTitle || i18n.getString(name, currentLocale)} {tooltip ? ( <>   ) : null} {children} ); };