import React from 'react'; import { StyleProp, ViewStyle, TextStyle, PressableProps } from 'react-native'; export type Ux4gSwitchSize = 's' | 'm' | 'l' | 'small' | 'medium' | 'large'; export type Ux4gSwitchLabelPosition = 'noLabel' | 'left' | 'right' | 'bothSides'; export interface Ux4gSwitchProps extends Omit { /** * Whether the switch is checked/on (`true`) or unchecked/off (`false`). */ checked?: boolean; /** * Alias for `checked` for standard React Native form compatibility. */ value?: boolean; /** * Callback fired when the checked state toggles. */ onCheckedChange?: (checked: boolean) => void; /** * Alias for `onCheckedChange` for consistent form component patterns (`Checkbox`, `RadioButton`). */ onChanged?: (checked: boolean) => void; /** * Primary label text displayed next to the switch. */ label?: string; /** * Supporting description text below the primary label. */ description?: string; /** * Size of the switch (`s`/`small`, `m`/`medium` default, or `l`/`large`). * @default 'm' */ size?: Ux4gSwitchSize; /** * Position of the label relative to the switch (`noLabel`, `left`, `right` default, or `bothSides`). * @default 'right' */ labelPosition?: Ux4gSwitchLabelPosition; /** * Whether the switch is enabled (`true` default) or disabled (`false`). * @default true */ enabled?: boolean; /** * Whether to display a required red asterisk (`*`) next to the primary label. * @default false */ isRequired?: boolean; /** * Optional trailing icon displayed next to the primary label text. */ icon?: React.ReactNode; /** * Custom typography style override for the primary label text. */ labelStyle?: StyleProp; /** * Custom typography style override for the description text. */ descriptionStyle?: StyleProp; /** * Secondary label text used when `labelPosition = 'bothSides'`. */ secondaryLabel?: string; /** * Whether to display a required red asterisk (`*`) next to the secondary label (`bothSides`). * @default false */ isSecondaryRequired?: boolean; /** * Optional trailing icon displayed next to the secondary label text (`bothSides`). */ secondaryIcon?: React.ReactNode; /** * Optional description status variant (`helper`, `error`, `warning`, `success`) for dynamic coloring and icons. */ descriptionVariant?: 'helper' | 'error' | 'warning' | 'success'; /** * Optional custom status icon to display before the description text when `descriptionVariant` is set. */ descriptionIcon?: React.ReactNode; /** * Additional style attributes for the root container (`View` or `Pressable`). */ style?: StyleProp; /** * Optional testID for automated testing. */ testID?: string; } /** * **Ux4gSwitch** (`Switch`) * * Full React Native port of Flutter `toggle.dart` (`Ux4gSwitch`), supporting multiple sizes (`s`, `m`, `l`), * configurable label positioning (`left`, `right`, `bothSides`, `noLabel`), secondary labels, icons, status variants, * required asterisks (`*`), and smooth native thumb animations. */ export declare const Ux4gSwitch: React.FC; //# sourceMappingURL=Switch.d.ts.map