UNPKG

@snowball-tech/fractal

Version:

Fractal's (Snowball's design system) React component library based on RadixUI and PandaCSS

30 lines (27 loc) 1.02 kB
import { ToggleGroupMultipleProps, ToggleGroupItemProps as ToggleGroupItemProps$1 } from '@radix-ui/react-toggle-group'; import { ReactNode } from 'react'; import { Variants } from '../Toggle/Toggle.constants.js'; interface ToggleGroupProps extends Omit<ToggleGroupMultipleProps, 'defaultValue' | 'type' | 'value'> { children: ReactNode; defaultValue?: string | Array<string>; disabled?: boolean; fullWidth?: boolean; label?: string; multiple?: boolean; orientation?: ToggleGroupMultipleProps['orientation']; value?: string | Array<string>; variant?: `${Variants}`; onValueChange?: (value: string | Array<string>) => void; } interface ToggleGroupItemProps extends ToggleGroupItemProps$1 { value: string; children?: ReactNode; disabled?: boolean; fullWidth?: boolean; icon?: ReactNode; iconOnly?: boolean; label?: string; labelAsDiv?: boolean; onToggle?: (toggled: boolean) => void; } export type { ToggleGroupItemProps, ToggleGroupProps };