UNPKG

@selfcommunity/react-ui

Version:

React UI Components to integrate a Community created with SelfCommunity Platform.

40 lines (39 loc) 1.07 kB
import { SCLanguageType } from '@selfcommunity/types'; import { SelectProps } from '@mui/material/Select/Select'; import { TypographyProps } from '@mui/material/Typography/Typography'; export interface LanguageSwitcherProps { /** * Overrides or extends the styles applied to the component. * @default null */ className?: string; /** * Props to apply to Label component * @default {} */ LabelComponentProps?: TypographyProps; /** * Props to apply to Select component * @default {} */ SelectComponentProps?: SelectProps; /** * Locales * @default [SCLanguageType.EN, SCLanguageType.IT] */ languages?: SCLanguageType[]; /** * Handles language switch callback * @param provider */ handleLanguageSwitch?: (language: any) => Promise<any>; /** * Minimized version */ minimized?: boolean; /** * Any other properties */ [p: string]: any; } export default function LanguageSwitcher(inProps: LanguageSwitcherProps): JSX.Element;