UNPKG

@codegouvfr/react-dsfr

Version:

French State Design System React integration library

22 lines (21 loc) 1.22 kB
import React from "react"; import type { ToggleSwitchProps } from "./ToggleSwitch"; export type ToggleSwitchGroupProps = { className?: string; /** Default: true */ showCheckedHint?: ToggleSwitchProps["showCheckedHint"]; /** Default: right */ labelPosition?: ToggleSwitchProps["labelPosition"]; classes?: Partial<Record<"root" | "li", string>>; /** Needs at least one ToggleSwitch */ toggles: [ToggleSwitchPropsWithoutSharedProps, ...ToggleSwitchPropsWithoutSharedProps[]]; }; /** @see <https://react-dsfr-components.etalab.studio/?path=/docs/components-toggleswitchgroup> */ export declare const ToggleSwitchGroup: React.NamedExoticComponent<ToggleSwitchGroupProps>; export default ToggleSwitchGroup; type ToggleSwitchPropsWithoutSharedProps = ToggleSwitchPropsWithoutSharedProps.Controlled | ToggleSwitchPropsWithoutSharedProps.Uncontrolled; declare namespace ToggleSwitchPropsWithoutSharedProps { type Common = Omit<ToggleSwitchProps, "showCheckedHint" | "labelPosition">; type Uncontrolled = Common & Omit<ToggleSwitchProps.Uncontrolled, keyof ToggleSwitchProps.Common>; type Controlled = Common & Omit<ToggleSwitchProps.Controlled, keyof ToggleSwitchProps.Common>; }