Skip to main content

Switch

Props

NameTypeDefaultDescription
labelstring-The label for the input field.
namestring-The name of component being registered.
tooltipstring-Tooltip content to display additional information about the field.
isDisabledboolean-Disables the input field when true.
dataTestIdstring''A data-testid attribute for testing purposes.

Config example

const switchConfig = {
type: 'switch',
data: {
name: 'notifications',
label: 'Enable Notifications',
tooltip: 'Turn on to receive notifications about updates and alerts.',
}
}