UNPKG

@trellixio/roaster-coffee

Version:
26 lines 1.25 kB
import * as React from 'react'; export interface SwitchProps { /** The HTML ID attribute to be applied to the switch element (optional). */ id?: string; /** The name attribute to be applied to the switch element (optional). */ name?: string; /** Whether the switch toggle should be disabled (optional). */ disabled?: boolean; /** The default checked state of the switch toggle (optional). */ defaultChecked?: boolean; /** * A function that is called when the state of the switch toggle changes (optional). * This function accepts the new state of the switch toggle as input. */ onChange?(value: boolean): void; /** The label to be displayed next to the switch toggle (optional). */ label?: React.ReactNode; /** The help text to be displayed below the switch toggle (optional). */ helpText?: React.ReactNode; /** CSS class names to be applied to the label element (optional). */ labelClassName?: string; /** CSS class names to be applied to the switch input element (optional). */ inputClassName?: string; } export declare const Switch: React.ForwardRefExoticComponent<SwitchProps & React.RefAttributes<HTMLInputElement>>; //# sourceMappingURL=Switch.d.ts.map