diff --git a/src/ToggleSwitch.tsx b/src/ToggleSwitch.tsx index d3c73daa5..2d866f493 100644 --- a/src/ToggleSwitch.tsx +++ b/src/ToggleSwitch.tsx @@ -30,6 +30,7 @@ export namespace ToggleSwitchProps { labelPosition?: "left" | "right"; classes?: Partial>; style?: CSSProperties; + name?: string; }; export type Uncontrolled = Common & { @@ -64,6 +65,7 @@ export const ToggleSwitch = memo( onChange, inputTitle, style, + name, ...rest } = props; @@ -121,6 +123,7 @@ export const ToggleSwitch = memo( id={inputId} title={inputTitle} checked={props_checked ?? checked} + name={name} />