@usefragments/ui 1.5.4 → 1.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/assets/ui.css +8808 -5810
- package/dist/chart.cjs +7 -20
- package/dist/chart.js +7 -20
- package/dist/colorpicker.cjs +2 -1
- package/dist/colorpicker.js +2 -1
- package/dist/components/Accordion/Accordion.module.scss.cjs +8 -8
- package/dist/components/Accordion/Accordion.module.scss.js +8 -8
- package/dist/components/Alert/Alert.module.scss.cjs +12 -12
- package/dist/components/Alert/Alert.module.scss.js +12 -12
- package/dist/components/AppShell/AppShell.module.scss.cjs +14 -14
- package/dist/components/AppShell/AppShell.module.scss.js +14 -14
- package/dist/components/AppShell/index.cjs +5 -3
- package/dist/components/AppShell/index.d.ts +4 -2
- package/dist/components/AppShell/index.d.ts.map +1 -1
- package/dist/components/AppShell/index.js +5 -3
- package/dist/components/Avatar/Avatar.module.scss.cjs +17 -14
- package/dist/components/Avatar/Avatar.module.scss.js +17 -14
- package/dist/components/Avatar/index.cjs +100 -118
- package/dist/components/Avatar/index.d.ts +7 -5
- package/dist/components/Avatar/index.d.ts.map +1 -1
- package/dist/components/Avatar/index.js +100 -118
- package/dist/components/Badge/Badge.module.scss.cjs +19 -19
- package/dist/components/Badge/Badge.module.scss.js +19 -19
- package/dist/components/BentoGrid/BentoGrid.module.scss.cjs +14 -14
- package/dist/components/BentoGrid/BentoGrid.module.scss.js +14 -14
- package/dist/components/Box/Box.module.scss.cjs +152 -152
- package/dist/components/Box/Box.module.scss.js +152 -152
- package/dist/components/Breadcrumbs/Breadcrumbs.module.scss.cjs +8 -8
- package/dist/components/Breadcrumbs/Breadcrumbs.module.scss.js +8 -8
- package/dist/components/Button/Button.module.scss.cjs +14 -14
- package/dist/components/Button/Button.module.scss.js +14 -14
- package/dist/components/ButtonGroup/ButtonGroup.module.scss.cjs +15 -15
- package/dist/components/ButtonGroup/ButtonGroup.module.scss.js +15 -15
- package/dist/components/Card/Card.module.scss.cjs +18 -18
- package/dist/components/Card/Card.module.scss.js +18 -18
- package/dist/components/Chart/Chart.module.scss.cjs +15 -15
- package/dist/components/Chart/Chart.module.scss.js +15 -15
- package/dist/components/Chart/index.d.ts +7 -7
- package/dist/components/Chart/index.d.ts.map +1 -1
- package/dist/components/Checkbox/Checkbox.module.scss.cjs +9 -15
- package/dist/components/Checkbox/Checkbox.module.scss.js +9 -15
- package/dist/components/Checkbox/index.cjs +4 -6
- package/dist/components/Checkbox/index.d.ts.map +1 -1
- package/dist/components/Checkbox/index.js +4 -6
- package/dist/components/Chip/Chip.module.scss.cjs +15 -15
- package/dist/components/Chip/Chip.module.scss.js +15 -15
- package/dist/components/Chip/index.cjs +4 -5
- package/dist/components/Chip/index.d.ts +1 -1
- package/dist/components/Chip/index.d.ts.map +1 -1
- package/dist/components/Chip/index.js +2 -3
- package/dist/components/CodeBlock/CodeBlock.module.scss.cjs +22 -22
- package/dist/components/CodeBlock/CodeBlock.module.scss.js +22 -22
- package/dist/components/Collapsible/Collapsible.module.scss.cjs +9 -12
- package/dist/components/Collapsible/Collapsible.module.scss.js +9 -12
- package/dist/components/Collapsible/index.cjs +3 -2
- package/dist/components/Collapsible/index.d.ts +3 -3
- package/dist/components/Collapsible/index.d.ts.map +1 -1
- package/dist/components/Collapsible/index.js +3 -2
- package/dist/components/ColorPicker/ColorPicker.module.scss.cjs +16 -16
- package/dist/components/ColorPicker/ColorPicker.module.scss.js +16 -16
- package/dist/components/ColorPicker/index.d.ts.map +1 -1
- package/dist/components/Combobox/Combobox.module.scss.cjs +21 -27
- package/dist/components/Combobox/Combobox.module.scss.js +21 -27
- package/dist/components/Combobox/index.cjs +4 -4
- package/dist/components/Combobox/index.d.ts.map +1 -1
- package/dist/components/Combobox/index.js +4 -4
- package/dist/components/Command/Command.module.scss.cjs +11 -11
- package/dist/components/Command/Command.module.scss.js +11 -11
- package/dist/components/ConversationList/ConversationList.module.scss.cjs +11 -14
- package/dist/components/ConversationList/ConversationList.module.scss.js +11 -14
- package/dist/components/ConversationList/index.cjs +40 -44
- package/dist/components/ConversationList/index.d.ts +3 -3
- package/dist/components/ConversationList/index.d.ts.map +1 -1
- package/dist/components/ConversationList/index.js +40 -44
- package/dist/components/DataTable/DataTable.module.scss.cjs +32 -56
- package/dist/components/DataTable/DataTable.module.scss.js +32 -56
- package/dist/components/DataTable/index.d.ts +5 -4
- package/dist/components/DataTable/index.d.ts.map +1 -1
- package/dist/components/DatePicker/DatePicker.module.scss.cjs +33 -33
- package/dist/components/DatePicker/DatePicker.module.scss.js +33 -33
- package/dist/components/DatePicker/index.d.ts.map +1 -1
- package/dist/components/Dialog/Dialog.module.scss.cjs +14 -14
- package/dist/components/Dialog/Dialog.module.scss.js +14 -14
- package/dist/components/Drawer/Drawer.module.scss.cjs +31 -28
- package/dist/components/Drawer/Drawer.module.scss.js +31 -28
- package/dist/components/Drawer/index.cjs +1 -1
- package/dist/components/Drawer/index.js +1 -1
- package/dist/components/Editor/Editor.module.scss.cjs +23 -23
- package/dist/components/Editor/Editor.module.scss.js +23 -23
- package/dist/components/EmptyState/EmptyState.module.scss.cjs +12 -12
- package/dist/components/EmptyState/EmptyState.module.scss.js +12 -12
- package/dist/components/Field/Field.module.scss.cjs +8 -5
- package/dist/components/Field/Field.module.scss.js +8 -5
- package/dist/components/Field/index.cjs +10 -1
- package/dist/components/Field/index.d.ts +9 -2
- package/dist/components/Field/index.d.ts.map +1 -1
- package/dist/components/Field/index.js +10 -1
- package/dist/components/Fieldset/Fieldset.module.scss.cjs +3 -3
- package/dist/components/Fieldset/Fieldset.module.scss.js +3 -3
- package/dist/components/Form/Form.module.scss.cjs +5 -2
- package/dist/components/Form/Form.module.scss.js +5 -2
- package/dist/components/Form/index.cjs +6 -1
- package/dist/components/Form/index.d.ts +8 -3
- package/dist/components/Form/index.d.ts.map +1 -1
- package/dist/components/Form/index.js +6 -1
- package/dist/components/Grid/Grid.module.scss.cjs +54 -72
- package/dist/components/Grid/Grid.module.scss.js +54 -72
- package/dist/components/Grid/index.cjs +57 -77
- package/dist/components/Grid/index.d.ts +11 -11
- package/dist/components/Grid/index.d.ts.map +1 -1
- package/dist/components/Grid/index.js +57 -77
- package/dist/components/Header/Header.module.scss.cjs +33 -33
- package/dist/components/Header/Header.module.scss.js +33 -33
- package/dist/components/Header/index.cjs +2 -1
- package/dist/components/Header/index.d.ts.map +1 -1
- package/dist/components/Header/index.js +2 -1
- package/dist/components/Icon/Icon.module.scss.cjs +29 -8
- package/dist/components/Icon/Icon.module.scss.js +30 -9
- package/dist/components/Icon/index.cjs +30 -48
- package/dist/components/Icon/index.d.ts +6 -6
- package/dist/components/Icon/index.d.ts.map +1 -1
- package/dist/components/Icon/index.js +30 -48
- package/dist/components/IconButton/IconButton.module.scss.cjs +8 -8
- package/dist/components/IconButton/IconButton.module.scss.js +8 -8
- package/dist/components/Input/Input.module.scss.cjs +19 -25
- package/dist/components/Input/Input.module.scss.js +19 -25
- package/dist/components/Input/index.cjs +1 -2
- package/dist/components/Input/index.d.ts.map +1 -1
- package/dist/components/Input/index.js +1 -2
- package/dist/components/Link/Link.module.scss.cjs +10 -10
- package/dist/components/Link/Link.module.scss.js +10 -10
- package/dist/components/List/List.module.scss.cjs +19 -19
- package/dist/components/List/List.module.scss.js +19 -19
- package/dist/components/List/index.cjs +4 -7
- package/dist/components/List/index.d.ts.map +1 -1
- package/dist/components/List/index.js +4 -7
- package/dist/components/Listbox/Listbox.module.scss.cjs +9 -9
- package/dist/components/Listbox/Listbox.module.scss.js +9 -9
- package/dist/components/Loading/Loading.module.scss.cjs +30 -30
- package/dist/components/Loading/Loading.module.scss.js +30 -30
- package/dist/components/Loading/index.cjs +39 -67
- package/dist/components/Loading/index.d.ts +6 -6
- package/dist/components/Loading/index.d.ts.map +1 -1
- package/dist/components/Loading/index.js +39 -67
- package/dist/components/Main/Main.module.scss.cjs +7 -7
- package/dist/components/Main/Main.module.scss.js +7 -7
- package/dist/components/Markdown/Markdown.module.scss.cjs +1 -1
- package/dist/components/Markdown/Markdown.module.scss.js +1 -1
- package/dist/components/Menu/Menu.module.scss.cjs +16 -16
- package/dist/components/Menu/Menu.module.scss.js +16 -16
- package/dist/components/Menu/index.cjs +19 -61
- package/dist/components/Menu/index.d.ts +10 -10
- package/dist/components/Menu/index.d.ts.map +1 -1
- package/dist/components/Menu/index.js +19 -61
- package/dist/components/Message/Message.module.scss.cjs +18 -21
- package/dist/components/Message/Message.module.scss.js +18 -21
- package/dist/components/Message/index.cjs +15 -2
- package/dist/components/Message/index.d.ts.map +1 -1
- package/dist/components/Message/index.js +15 -2
- package/dist/components/NavigationMenu/NavigationMenu.module.scss.cjs +28 -28
- package/dist/components/NavigationMenu/NavigationMenu.module.scss.js +28 -28
- package/dist/components/Pagination/Pagination.module.scss.cjs +18 -9
- package/dist/components/Pagination/Pagination.module.scss.js +19 -10
- package/dist/components/Pagination/index.cjs +5 -2
- package/dist/components/Pagination/index.d.ts +3 -1
- package/dist/components/Pagination/index.d.ts.map +1 -1
- package/dist/components/Pagination/index.js +5 -2
- package/dist/components/Popover/Popover.module.scss.cjs +10 -10
- package/dist/components/Popover/Popover.module.scss.js +10 -10
- package/dist/components/Progress/Progress.module.scss.cjs +29 -32
- package/dist/components/Progress/Progress.module.scss.js +29 -32
- package/dist/components/Progress/geometry.cjs +30 -0
- package/dist/components/Progress/geometry.d.ts +8 -0
- package/dist/components/Progress/geometry.d.ts.map +1 -0
- package/dist/components/Progress/geometry.js +30 -0
- package/dist/components/Progress/index.cjs +40 -29
- package/dist/components/Progress/index.d.ts +4 -3
- package/dist/components/Progress/index.d.ts.map +1 -1
- package/dist/components/Progress/index.js +40 -29
- package/dist/components/Prompt/Prompt.module.scss.cjs +29 -29
- package/dist/components/Prompt/Prompt.module.scss.js +29 -29
- package/dist/components/Prompt/index.cjs +5 -4
- package/dist/components/Prompt/index.d.ts.map +1 -1
- package/dist/components/Prompt/index.js +5 -4
- package/dist/components/RadioGroup/RadioGroup.module.scss.cjs +15 -21
- package/dist/components/RadioGroup/RadioGroup.module.scss.js +15 -21
- package/dist/components/RadioGroup/index.cjs +7 -6
- package/dist/components/RadioGroup/index.d.ts.map +1 -1
- package/dist/components/RadioGroup/index.js +7 -6
- package/dist/components/ScrollArea/ScrollArea.module.scss.cjs +7 -22
- package/dist/components/ScrollArea/ScrollArea.module.scss.js +7 -22
- package/dist/components/ScrollArea/index.cjs +66 -42
- package/dist/components/ScrollArea/index.d.ts +3 -2
- package/dist/components/ScrollArea/index.d.ts.map +1 -1
- package/dist/components/ScrollArea/index.js +66 -42
- package/dist/components/ScrollArea/scroll-state.cjs +58 -0
- package/dist/components/ScrollArea/scroll-state.d.ts +16 -0
- package/dist/components/ScrollArea/scroll-state.d.ts.map +1 -0
- package/dist/components/ScrollArea/scroll-state.js +58 -0
- package/dist/components/Select/Select.module.scss.cjs +21 -21
- package/dist/components/Select/Select.module.scss.js +21 -21
- package/dist/components/Select/index.cjs +3 -2
- package/dist/components/Select/index.d.ts.map +1 -1
- package/dist/components/Select/index.js +3 -2
- package/dist/components/Separator/Separator.module.scss.cjs +13 -10
- package/dist/components/Separator/Separator.module.scss.js +13 -10
- package/dist/components/Separator/index.cjs +37 -38
- package/dist/components/Separator/index.d.ts +4 -4
- package/dist/components/Separator/index.d.ts.map +1 -1
- package/dist/components/Separator/index.js +37 -38
- package/dist/components/Sidebar/Sidebar.module.scss.cjs +43 -43
- package/dist/components/Sidebar/Sidebar.module.scss.js +43 -43
- package/dist/components/Sidebar/index.cjs +5 -3
- package/dist/components/Sidebar/index.d.ts +6 -1
- package/dist/components/Sidebar/index.d.ts.map +1 -1
- package/dist/components/Sidebar/index.js +5 -3
- package/dist/components/Skeleton/Skeleton.module.scss.cjs +50 -38
- package/dist/components/Skeleton/Skeleton.module.scss.js +50 -38
- package/dist/components/Skeleton/index.cjs +41 -55
- package/dist/components/Skeleton/index.d.ts +7 -7
- package/dist/components/Skeleton/index.d.ts.map +1 -1
- package/dist/components/Skeleton/index.js +41 -55
- package/dist/components/Slider/Slider.module.scss.cjs +12 -12
- package/dist/components/Slider/Slider.module.scss.js +12 -12
- package/dist/components/Stack/Stack.module.scss.cjs +25 -45
- package/dist/components/Stack/Stack.module.scss.js +25 -45
- package/dist/components/Stack/index.cjs +106 -101
- package/dist/components/Stack/index.d.ts +7 -7
- package/dist/components/Stack/index.d.ts.map +1 -1
- package/dist/components/Stack/index.js +106 -101
- package/dist/components/Switch/Switch.module.scss.cjs +32 -0
- package/dist/components/Switch/Switch.module.scss.js +32 -0
- package/dist/components/{Toggle → Switch}/index.cjs +9 -14
- package/dist/components/Switch/index.d.ts +37 -1
- package/dist/components/Switch/index.d.ts.map +1 -1
- package/dist/components/{Toggle → Switch}/index.js +5 -10
- package/dist/components/Table/Table.module.scss.cjs +18 -27
- package/dist/components/Table/Table.module.scss.js +18 -27
- package/dist/components/Table/index.d.ts +6 -5
- package/dist/components/Table/index.d.ts.map +1 -1
- package/dist/components/TableOfContents/TableOfContents.module.scss.cjs +15 -15
- package/dist/components/TableOfContents/TableOfContents.module.scss.js +15 -15
- package/dist/components/Tabs/Tabs.module.scss.cjs +12 -12
- package/dist/components/Tabs/Tabs.module.scss.js +12 -12
- package/dist/components/Tabs/index.cjs +2 -2
- package/dist/components/Tabs/index.js +2 -2
- package/dist/components/Text/Text.module.scss.cjs +93 -57
- package/dist/components/Text/Text.module.scss.js +93 -57
- package/dist/components/Text/index.cjs +14 -6
- package/dist/components/Text/index.d.ts +25 -15
- package/dist/components/Text/index.d.ts.map +1 -1
- package/dist/components/Text/index.js +14 -6
- package/dist/components/Textarea/Textarea.module.scss.cjs +26 -23
- package/dist/components/Textarea/Textarea.module.scss.js +26 -23
- package/dist/components/Textarea/index.cjs +5 -10
- package/dist/components/Textarea/index.d.ts.map +1 -1
- package/dist/components/Textarea/index.js +5 -10
- package/dist/components/Theme/context.cjs +39 -0
- package/dist/components/Theme/context.d.ts +21 -0
- package/dist/components/Theme/context.d.ts.map +1 -0
- package/dist/components/Theme/context.js +22 -0
- package/dist/components/Theme/index.cjs +14 -209
- package/dist/components/Theme/index.d.ts +4 -37
- package/dist/components/Theme/index.d.ts.map +1 -1
- package/dist/components/Theme/index.js +9 -204
- package/dist/components/{Theme → ThemeToggle}/ThemeToggle.module.scss.cjs +6 -6
- package/dist/components/ThemeToggle/ThemeToggle.module.scss.js +23 -0
- package/dist/components/ThemeToggle/index.cjs +115 -0
- package/dist/components/ThemeToggle/index.d.ts +21 -0
- package/dist/components/ThemeToggle/index.d.ts.map +1 -0
- package/dist/components/ThemeToggle/index.js +115 -0
- package/dist/components/ThinkingIndicator/ThinkingIndicator.module.scss.cjs +13 -13
- package/dist/components/ThinkingIndicator/ThinkingIndicator.module.scss.js +13 -13
- package/dist/components/ThinkingIndicator/index.cjs +34 -41
- package/dist/components/ThinkingIndicator/index.d.ts +4 -4
- package/dist/components/ThinkingIndicator/index.d.ts.map +1 -1
- package/dist/components/ThinkingIndicator/index.js +34 -41
- package/dist/components/Toast/Toast.module.scss.cjs +20 -20
- package/dist/components/Toast/Toast.module.scss.js +20 -20
- package/dist/components/Toggle/index.d.ts +2 -42
- package/dist/components/Toggle/index.d.ts.map +1 -1
- package/dist/components/ToggleGroup/ToggleGroup.module.scss.cjs +20 -20
- package/dist/components/ToggleGroup/ToggleGroup.module.scss.js +20 -20
- package/dist/components/ToggleGroup/index.cjs +3 -2
- package/dist/components/ToggleGroup/index.d.ts +2 -1
- package/dist/components/ToggleGroup/index.d.ts.map +1 -1
- package/dist/components/ToggleGroup/index.js +3 -2
- package/dist/components/Tooltip/Tooltip.module.scss.cjs +3 -3
- package/dist/components/Tooltip/Tooltip.module.scss.js +3 -3
- package/dist/components/VisuallyHidden/VisuallyHidden.module.scss.cjs +1 -1
- package/dist/components/VisuallyHidden/VisuallyHidden.module.scss.js +1 -1
- package/dist/data-table.cjs +12 -9
- package/dist/data-table.js +12 -9
- package/dist/datepicker.cjs +2 -1
- package/dist/datepicker.js +2 -1
- package/dist/index.cjs +100 -98
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -2
- package/dist/markdown.cjs +1 -1
- package/dist/markdown.js +2 -2
- package/dist/measurements/generated.cjs +296 -0
- package/dist/measurements/generated.d.ts +261 -0
- package/dist/measurements/generated.d.ts.map +1 -0
- package/dist/measurements/generated.js +296 -0
- package/dist/measurements/index.d.ts +2 -0
- package/dist/measurements/index.d.ts.map +1 -0
- package/dist/measurements.cjs +6 -0
- package/dist/measurements.js +6 -0
- package/dist/recipes/popup.cjs +14 -0
- package/dist/recipes/popup.d.ts +4 -0
- package/dist/recipes/popup.d.ts.map +1 -0
- package/dist/recipes/popup.js +14 -0
- package/dist/recipes/table-chrome.cjs +18 -0
- package/dist/recipes/table-chrome.d.ts +10 -0
- package/dist/recipes/table-chrome.d.ts.map +1 -0
- package/dist/recipes/table-chrome.js +18 -0
- package/dist/table.cjs +5 -2
- package/dist/table.js +5 -2
- package/dist/utils/layout-spacing.cjs +27 -0
- package/dist/utils/layout-spacing.d.ts +5 -0
- package/dist/utils/layout-spacing.d.ts.map +1 -0
- package/dist/utils/layout-spacing.js +27 -0
- package/dist/utils/seed-derivation.cjs +4 -42
- package/dist/utils/seed-derivation.d.ts +4 -3
- package/dist/utils/seed-derivation.d.ts.map +1 -1
- package/dist/utils/seed-derivation.js +4 -42
- package/dist/utils/theme-presets.cjs +1 -0
- package/dist/utils/theme-presets.d.ts +3 -2
- package/dist/utils/theme-presets.d.ts.map +1 -1
- package/dist/utils/theme-presets.js +1 -0
- package/fragments.json +1 -1
- package/package.json +23 -4
- package/src/components/Accordion/Accordion.module.scss +31 -52
- package/src/components/Alert/Alert.module.scss +28 -44
- package/src/components/AppShell/AppShell.module.scss +6 -3
- package/src/components/AppShell/index.tsx +8 -4
- package/src/components/Avatar/Avatar.module.scss +22 -60
- package/src/components/Avatar/index.tsx +152 -146
- package/src/components/Badge/Badge.module.scss +51 -46
- package/src/components/BentoGrid/BentoGrid.module.scss +11 -32
- package/src/components/Box/Box.module.scss +253 -81
- package/src/components/Breadcrumbs/Breadcrumbs.module.scss +10 -11
- package/src/components/Button/Button.module.scss +52 -57
- package/src/components/ButtonGroup/ButtonGroup.module.scss +5 -5
- package/src/components/Card/Card.consumer-fixture.module.scss +8 -0
- package/src/components/Card/Card.module.scss +211 -175
- package/src/components/Chart/Chart.module.scss +28 -29
- package/src/components/Chart/index.tsx +40 -53
- package/src/components/Checkbox/Checkbox.module.scss +43 -64
- package/src/components/Checkbox/index.tsx +4 -9
- package/src/components/Chip/Chip.contract.json +4 -3
- package/src/components/Chip/Chip.module.scss +23 -34
- package/src/components/Chip/index.tsx +3 -4
- package/src/components/CodeBlock/CodeBlock.module.scss +102 -215
- package/src/components/Collapsible/Collapsible.module.scss +29 -63
- package/src/components/Collapsible/index.tsx +22 -26
- package/src/components/ColorPicker/ColorPicker.module.scss +42 -24
- package/src/components/ColorPicker/index.tsx +2 -1
- package/src/components/Combobox/Combobox.module.scss +60 -73
- package/src/components/Combobox/index.tsx +7 -5
- package/src/components/Command/Command.module.scss +47 -77
- package/src/components/ConversationList/ConversationList.module.scss +20 -78
- package/src/components/ConversationList/index.tsx +55 -59
- package/src/components/DataTable/DataTable.module.scss +76 -216
- package/src/components/DataTable/index.tsx +20 -25
- package/src/components/DatePicker/DatePicker.module.scss +54 -33
- package/src/components/DatePicker/index.tsx +2 -1
- package/src/components/Dialog/Dialog.module.scss +42 -66
- package/src/components/Drawer/Drawer.module.scss +93 -99
- package/src/components/Drawer/index.tsx +1 -1
- package/src/components/Editor/Editor.module.scss +115 -220
- package/src/components/EmptyState/EmptyState.module.scss +38 -85
- package/src/components/Field/Field.contract.json +2 -1
- package/src/components/Field/Field.module.scss +9 -11
- package/src/components/Field/index.tsx +27 -1
- package/src/components/Fieldset/Fieldset.module.scss +14 -6
- package/src/components/Form/Form.contract.json +10 -23
- package/src/components/Form/Form.module.scss +9 -4
- package/src/components/Form/index.tsx +22 -7
- package/src/components/Grid/Grid.module.scss +159 -63
- package/src/components/Grid/index.tsx +107 -126
- package/src/components/Header/Header.module.scss +25 -32
- package/src/components/Header/index.tsx +2 -1
- package/src/components/Icon/Icon.module.scss +16 -0
- package/src/components/Icon/index.tsx +74 -86
- package/src/components/IconButton/IconButton.module.scss +11 -21
- package/src/components/Input/Input.module.scss +67 -55
- package/src/components/Input/index.tsx +1 -2
- package/src/components/Link/Link.module.scss +8 -9
- package/src/components/List/List.module.scss +16 -21
- package/src/components/List/index.tsx +4 -10
- package/src/components/Listbox/Listbox.module.scss +26 -54
- package/src/components/Loading/Loading.module.scss +23 -33
- package/src/components/Loading/index.tsx +68 -97
- package/src/components/Main/Main.module.scss +3 -5
- package/src/components/Markdown/Markdown.module.scss +36 -184
- package/src/components/Markdown/index.tsx +2 -2
- package/src/components/Menu/Menu.module.scss +48 -133
- package/src/components/Menu/index.tsx +57 -89
- package/src/components/Message/Message.module.scss +52 -142
- package/src/components/Message/index.tsx +16 -6
- package/src/components/NavigationMenu/NavigationMenu.module.scss +59 -52
- package/src/components/Pagination/Pagination.module.scss +32 -25
- package/src/components/Pagination/index.tsx +7 -2
- package/src/components/Popover/Popover.module.scss +37 -73
- package/src/components/Progress/Progress.module.scss +61 -41
- package/src/components/Progress/geometry.ts +41 -0
- package/src/components/Progress/index.tsx +44 -30
- package/src/components/Prompt/Prompt.module.scss +45 -82
- package/src/components/Prompt/index.tsx +6 -5
- package/src/components/RadioGroup/RadioGroup.module.scss +50 -69
- package/src/components/RadioGroup/index.tsx +7 -9
- package/src/components/ScrollArea/ScrollArea.contract.json +8 -24
- package/src/components/ScrollArea/ScrollArea.module.scss +122 -96
- package/src/components/ScrollArea/index.tsx +78 -60
- package/src/components/ScrollArea/scroll-state.ts +87 -0
- package/src/components/Select/Select.module.scss +53 -41
- package/src/components/Select/index.tsx +6 -2
- package/src/components/Separator/Separator.module.scss +29 -19
- package/src/components/Separator/index.tsx +55 -51
- package/src/components/Sidebar/Sidebar.contract.json +12 -0
- package/src/components/Sidebar/Sidebar.module.scss +101 -99
- package/src/components/Sidebar/index.tsx +10 -3
- package/src/components/Skeleton/Skeleton.module.scss +26 -26
- package/src/components/Skeleton/index.tsx +65 -72
- package/src/components/Slider/Slider.module.scss +31 -25
- package/src/components/Stack/Stack.module.scss +101 -30
- package/src/components/Stack/index.tsx +157 -127
- package/src/components/{Toggle/Toggle.contract.json → Switch/Switch.contract.json} +1 -1
- package/src/components/{Toggle/Toggle.module.scss → Switch/Switch.module.scss} +55 -82
- package/src/components/{Toggle → Switch}/index.tsx +5 -21
- package/src/components/Table/Table.module.scss +38 -129
- package/src/components/Table/index.tsx +13 -6
- package/src/components/TableOfContents/TableOfContents.module.scss +20 -177
- package/src/components/Tabs/Tabs.module.scss +27 -22
- package/src/components/Tabs/index.tsx +2 -2
- package/src/components/Text/Text.module.scss +22 -3
- package/src/components/Text/index.tsx +56 -21
- package/src/components/Textarea/Textarea.module.scss +59 -39
- package/src/components/Textarea/index.tsx +5 -12
- package/src/components/Theme/context.ts +42 -0
- package/src/components/Theme/index.tsx +14 -309
- package/src/components/ThemeToggle/ThemeToggle.module.scss +73 -0
- package/src/components/ThemeToggle/index.tsx +144 -0
- package/src/components/ThinkingIndicator/ThinkingIndicator.module.scss +24 -19
- package/src/components/ThinkingIndicator/index.tsx +44 -54
- package/src/components/Toast/Toast.contract.json +5 -21
- package/src/components/Toast/Toast.module.scss +61 -138
- package/src/components/Toggle/index.ts +7 -0
- package/src/components/ToggleGroup/ToggleGroup.contract.json +12 -39
- package/src/components/ToggleGroup/ToggleGroup.module.scss +132 -88
- package/src/components/ToggleGroup/index.tsx +5 -3
- package/src/components/Tooltip/Tooltip.module.scss +23 -39
- package/src/components/VisuallyHidden/VisuallyHidden.module.scss +3 -0
- package/src/index.ts +2 -1
- package/src/measurements/MeasurementTargets.module.scss +229 -0
- package/src/measurements/generated.ts +317 -0
- package/src/measurements/index.ts +8 -0
- package/src/measurements/measurements.json +361 -0
- package/src/recipes/_action.scss +138 -0
- package/src/recipes/_boolean-range.scss +124 -0
- package/src/recipes/_feedback.scss +171 -0
- package/src/recipes/_field.scss +98 -0
- package/src/recipes/_layout.scss +67 -0
- package/src/recipes/_navigation.scss +110 -0
- package/src/recipes/_overlay.scss +191 -0
- package/src/recipes/_popup.scss +92 -0
- package/src/recipes/_prose.scss +174 -0
- package/src/recipes/_representation.scss +193 -0
- package/src/recipes/_segmented.scss +26 -0
- package/src/recipes/_surface.scss +13 -0
- package/src/recipes/_table-chrome.scss +105 -0
- package/src/recipes/_target.scss +31 -0
- package/src/recipes/_typography.scss +38 -0
- package/src/recipes/popup.ts +12 -0
- package/src/recipes/table-chrome.ts +30 -0
- package/src/styles/globals.scss +2 -2
- package/src/tokens/_component-properties.scss +2 -2
- package/src/tokens/_computed.scss +9 -9
- package/src/tokens/_density.scss +41 -132
- package/src/tokens/_measurements.catalog.generated.css +91 -0
- package/src/tokens/_measurements.generated.scss +604 -0
- package/src/tokens/_mixins.scss +0 -276
- package/src/tokens/_property-registrations.scss +96 -92
- package/src/tokens/_radius.scss +16 -70
- package/src/tokens/_seeds.scss +8 -7
- package/src/tokens/_variables.scss +163 -148
- package/src/utils/layout-spacing.ts +31 -0
- package/src/utils/seed-derivation.ts +134 -172
- package/src/utils/theme-presets.ts +58 -30
- package/dist/components/Theme/ThemeToggle.module.scss.js +0 -23
- package/dist/components/Toggle/Toggle.module.scss.cjs +0 -44
- package/dist/components/Toggle/Toggle.module.scss.js +0 -44
- package/src/components/Switch/index.ts +0 -3
- package/src/components/Theme/ThemeToggle.module.scss +0 -91
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
const thinkingIndicator = "
|
|
2
|
-
const main = "
|
|
3
|
-
const label = "
|
|
4
|
-
const elapsed = "
|
|
5
|
-
const steps = "
|
|
6
|
-
const step = "
|
|
7
|
-
const stepIndicator = "
|
|
8
|
-
const stepDot = "
|
|
9
|
-
const stepLabel = "
|
|
10
|
-
const stepPending = "
|
|
11
|
-
const stepActive = "
|
|
12
|
-
const stepComplete = "
|
|
13
|
-
const stepError = "
|
|
1
|
+
const thinkingIndicator = "_thinkingIndicator_4ldts_1";
|
|
2
|
+
const main = "_main_4ldts_8";
|
|
3
|
+
const label = "_label_4ldts_14";
|
|
4
|
+
const elapsed = "_elapsed_4ldts_23";
|
|
5
|
+
const steps = "_steps_4ldts_33";
|
|
6
|
+
const step = "_step_4ldts_33";
|
|
7
|
+
const stepIndicator = "_stepIndicator_4ldts_54";
|
|
8
|
+
const stepDot = "_stepDot_4ldts_68";
|
|
9
|
+
const stepLabel = "_stepLabel_4ldts_76";
|
|
10
|
+
const stepPending = "_stepPending_4ldts_80";
|
|
11
|
+
const stepActive = "_stepActive_4ldts_84";
|
|
12
|
+
const stepComplete = "_stepComplete_4ldts_91";
|
|
13
|
+
const stepError = "_stepError_4ldts_98";
|
|
14
14
|
const styles = {
|
|
15
15
|
thinkingIndicator,
|
|
16
16
|
main,
|
|
@@ -26,7 +26,9 @@ const ThinkingIndicatorContext = React__namespace.createContext(null);
|
|
|
26
26
|
function useThinkingIndicatorContext() {
|
|
27
27
|
const context = React__namespace.useContext(ThinkingIndicatorContext);
|
|
28
28
|
if (!context) {
|
|
29
|
-
throw new Error(
|
|
29
|
+
throw new Error(
|
|
30
|
+
"ThinkingIndicator compound components must be used within a ThinkingIndicator"
|
|
31
|
+
);
|
|
30
32
|
}
|
|
31
33
|
return context;
|
|
32
34
|
}
|
|
@@ -56,8 +58,6 @@ function CheckIcon() {
|
|
|
56
58
|
"svg",
|
|
57
59
|
{
|
|
58
60
|
xmlns: "http://www.w3.org/2000/svg",
|
|
59
|
-
width: "12",
|
|
60
|
-
height: "12",
|
|
61
61
|
viewBox: "0 0 24 24",
|
|
62
62
|
fill: "none",
|
|
63
63
|
stroke: "currentColor",
|
|
@@ -74,8 +74,6 @@ function ErrorIcon() {
|
|
|
74
74
|
"svg",
|
|
75
75
|
{
|
|
76
76
|
xmlns: "http://www.w3.org/2000/svg",
|
|
77
|
-
width: "12",
|
|
78
|
-
height: "12",
|
|
79
77
|
viewBox: "0 0 24 24",
|
|
80
78
|
fill: "none",
|
|
81
79
|
stroke: "currentColor",
|
|
@@ -94,12 +92,7 @@ function ThinkingSteps({ children, className, ...htmlProps }) {
|
|
|
94
92
|
const classes = [ThinkingIndicator_module.default.steps, className].filter(Boolean).join(" ");
|
|
95
93
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { ...htmlProps, className: classes, children });
|
|
96
94
|
}
|
|
97
|
-
function ThinkingStep({
|
|
98
|
-
label,
|
|
99
|
-
status = "pending",
|
|
100
|
-
className,
|
|
101
|
-
...htmlProps
|
|
102
|
-
}) {
|
|
95
|
+
function ThinkingStep({ label, status = "pending", className, ...htmlProps }) {
|
|
103
96
|
const classes = [
|
|
104
97
|
ThinkingIndicator_module.default.step,
|
|
105
98
|
ThinkingIndicator_module.default[`step${status.charAt(0).toUpperCase() + status.slice(1)}`],
|
|
@@ -109,7 +102,17 @@ function ThinkingStep({
|
|
|
109
102
|
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: ThinkingIndicator_module.default.stepIndicator, children: [
|
|
110
103
|
status === "complete" && /* @__PURE__ */ jsxRuntime.jsx(CheckIcon, {}),
|
|
111
104
|
status === "error" && /* @__PURE__ */ jsxRuntime.jsx(ErrorIcon, {}),
|
|
112
|
-
status === "active" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
105
|
+
status === "active" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
106
|
+
index.Loading,
|
|
107
|
+
{
|
|
108
|
+
size: "sm",
|
|
109
|
+
variant: "spinner",
|
|
110
|
+
color: "current",
|
|
111
|
+
label: "",
|
|
112
|
+
role: "presentation",
|
|
113
|
+
"aria-hidden": "true"
|
|
114
|
+
}
|
|
115
|
+
),
|
|
113
116
|
status === "pending" && /* @__PURE__ */ jsxRuntime.jsx("span", { className: ThinkingIndicator_module.default.stepDot })
|
|
114
117
|
] }),
|
|
115
118
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: ThinkingIndicator_module.default.stepLabel, children: label })
|
|
@@ -130,36 +133,26 @@ function ThinkingIndicatorRoot({
|
|
|
130
133
|
variant
|
|
131
134
|
};
|
|
132
135
|
if (!active) return null;
|
|
133
|
-
const classes = [
|
|
134
|
-
ThinkingIndicator_module.default.thinkingIndicator,
|
|
135
|
-
className
|
|
136
|
-
].filter(Boolean).join(" ");
|
|
136
|
+
const classes = [ThinkingIndicator_module.default.thinkingIndicator, className].filter(Boolean).join(" ");
|
|
137
137
|
const loadingVariant = variant === "dots" ? "dots" : variant === "pulse" ? "pulse" : "spinner";
|
|
138
|
-
return /* @__PURE__ */ jsxRuntime.jsx(ThinkingIndicatorContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
139
|
-
"div",
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
status: step.status
|
|
157
|
-
},
|
|
158
|
-
step.id
|
|
159
|
-
)) })
|
|
160
|
-
]
|
|
161
|
-
}
|
|
162
|
-
) });
|
|
138
|
+
return /* @__PURE__ */ jsxRuntime.jsx(ThinkingIndicatorContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { ...htmlProps, className: classes, role: "status", "aria-label": label, "aria-live": "polite", children: [
|
|
139
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: ThinkingIndicator_module.default.main, children: [
|
|
140
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
141
|
+
index.Loading,
|
|
142
|
+
{
|
|
143
|
+
size: "sm",
|
|
144
|
+
variant: loadingVariant,
|
|
145
|
+
color: "muted",
|
|
146
|
+
label: "",
|
|
147
|
+
role: "presentation",
|
|
148
|
+
"aria-hidden": "true"
|
|
149
|
+
}
|
|
150
|
+
),
|
|
151
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: ThinkingIndicator_module.default.label, children: label }),
|
|
152
|
+
showElapsed && elapsedTime && /* @__PURE__ */ jsxRuntime.jsx("span", { className: ThinkingIndicator_module.default.elapsed, children: elapsedTime })
|
|
153
|
+
] }),
|
|
154
|
+
steps && steps.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(ThinkingSteps, { children: steps.map((step) => /* @__PURE__ */ jsxRuntime.jsx(ThinkingStep, { label: step.label, status: step.status }, step.id)) })
|
|
155
|
+
] }) });
|
|
163
156
|
}
|
|
164
157
|
const ThinkingIndicator = Object.assign(ThinkingIndicatorRoot, {
|
|
165
158
|
Steps: ThinkingSteps,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import * as React from
|
|
2
|
-
export type ThinkingVariant =
|
|
3
|
-
export type StepStatus =
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export type ThinkingVariant = "dots" | "pulse" | "spinner";
|
|
3
|
+
export type StepStatus = "pending" | "active" | "complete" | "error";
|
|
4
4
|
export interface ThinkingStep {
|
|
5
5
|
id: string;
|
|
6
6
|
label: string;
|
|
@@ -39,6 +39,6 @@ export declare const ThinkingIndicator: typeof ThinkingIndicatorRoot & {
|
|
|
39
39
|
Steps: typeof ThinkingSteps;
|
|
40
40
|
Step: typeof ThinkingStep;
|
|
41
41
|
};
|
|
42
|
-
export { ThinkingIndicatorRoot, ThinkingSteps, ThinkingStep
|
|
42
|
+
export { ThinkingIndicatorRoot, ThinkingSteps, ThinkingStep };
|
|
43
43
|
export { useThinkingIndicatorContext };
|
|
44
44
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/ThinkingIndicator/index.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAQ/B,MAAM,MAAM,eAAe,GAAG,MAAM,GAAG,OAAO,GAAG,SAAS,CAAC;AAC3D,MAAM,MAAM,UAAU,GAAG,SAAS,GAAG,QAAQ,GAAG,UAAU,GAAG,OAAO,CAAC;AAErE,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,UAAU,CAAC;CACrB;AAED,MAAM,WAAW,sBAAuB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAClF,iCAAiC;IACjC,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,kBAAkB;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,sBAAsB;IACtB,OAAO,CAAC,EAAE,eAAe,CAAC;IAC1B,wBAAwB;IACxB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,0BAA0B;IAC1B,KAAK,CAAC,EAAE,YAAY,EAAE,CAAC;CACxB;AAED,MAAM,WAAW,kBAAmB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC9E,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED,MAAM,WAAW,iBAAkB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC7E,iBAAiB;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,kBAAkB;IAClB,MAAM,CAAC,EAAE,UAAU,CAAC;CACrB;AAMD,UAAU,6BAA6B;IACrC,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,eAAe,CAAC;CAC1B;AAID,iBAAS,2BAA2B,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/ThinkingIndicator/index.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAQ/B,MAAM,MAAM,eAAe,GAAG,MAAM,GAAG,OAAO,GAAG,SAAS,CAAC;AAC3D,MAAM,MAAM,UAAU,GAAG,SAAS,GAAG,QAAQ,GAAG,UAAU,GAAG,OAAO,CAAC;AAErE,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,UAAU,CAAC;CACrB;AAED,MAAM,WAAW,sBAAuB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAClF,iCAAiC;IACjC,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,kBAAkB;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,sBAAsB;IACtB,OAAO,CAAC,EAAE,eAAe,CAAC;IAC1B,wBAAwB;IACxB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,0BAA0B;IAC1B,KAAK,CAAC,EAAE,YAAY,EAAE,CAAC;CACxB;AAED,MAAM,WAAW,kBAAmB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC9E,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED,MAAM,WAAW,iBAAkB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC7E,iBAAiB;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,kBAAkB;IAClB,MAAM,CAAC,EAAE,UAAU,CAAC;CACrB;AAMD,UAAU,6BAA6B;IACrC,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,eAAe,CAAC;CAC1B;AAID,iBAAS,2BAA2B,kCAQnC;AA6ED,iBAAS,aAAa,CAAC,EAAE,QAAQ,EAAE,SAAS,EAAE,GAAG,SAAS,EAAE,EAAE,kBAAkB,2CAQ/E;AAED,iBAAS,YAAY,CAAC,EAAE,KAAK,EAAE,MAAkB,EAAE,SAAS,EAAE,GAAG,SAAS,EAAE,EAAE,iBAAiB,2CA6B9F;AAMD,iBAAS,qBAAqB,CAAC,EAC7B,MAAa,EACb,KAAqB,EACrB,OAAgB,EAChB,WAAmB,EACnB,KAAK,EACL,SAAS,EACT,GAAG,SAAS,EACb,EAAE,sBAAsB,kDAyCxB;AAMD,eAAO,MAAM,iBAAiB;;;CAG5B,CAAC;AAEH,OAAO,EAAE,qBAAqB,EAAE,aAAa,EAAE,YAAY,EAAE,CAAC;AAE9D,OAAO,EAAE,2BAA2B,EAAE,CAAC"}
|
|
@@ -7,7 +7,9 @@ const ThinkingIndicatorContext = React.createContext(null);
|
|
|
7
7
|
function useThinkingIndicatorContext() {
|
|
8
8
|
const context = React.useContext(ThinkingIndicatorContext);
|
|
9
9
|
if (!context) {
|
|
10
|
-
throw new Error(
|
|
10
|
+
throw new Error(
|
|
11
|
+
"ThinkingIndicator compound components must be used within a ThinkingIndicator"
|
|
12
|
+
);
|
|
11
13
|
}
|
|
12
14
|
return context;
|
|
13
15
|
}
|
|
@@ -37,8 +39,6 @@ function CheckIcon() {
|
|
|
37
39
|
"svg",
|
|
38
40
|
{
|
|
39
41
|
xmlns: "http://www.w3.org/2000/svg",
|
|
40
|
-
width: "12",
|
|
41
|
-
height: "12",
|
|
42
42
|
viewBox: "0 0 24 24",
|
|
43
43
|
fill: "none",
|
|
44
44
|
stroke: "currentColor",
|
|
@@ -55,8 +55,6 @@ function ErrorIcon() {
|
|
|
55
55
|
"svg",
|
|
56
56
|
{
|
|
57
57
|
xmlns: "http://www.w3.org/2000/svg",
|
|
58
|
-
width: "12",
|
|
59
|
-
height: "12",
|
|
60
58
|
viewBox: "0 0 24 24",
|
|
61
59
|
fill: "none",
|
|
62
60
|
stroke: "currentColor",
|
|
@@ -75,12 +73,7 @@ function ThinkingSteps({ children, className, ...htmlProps }) {
|
|
|
75
73
|
const classes = [styles.steps, className].filter(Boolean).join(" ");
|
|
76
74
|
return /* @__PURE__ */ jsx("div", { ...htmlProps, className: classes, children });
|
|
77
75
|
}
|
|
78
|
-
function ThinkingStep({
|
|
79
|
-
label,
|
|
80
|
-
status = "pending",
|
|
81
|
-
className,
|
|
82
|
-
...htmlProps
|
|
83
|
-
}) {
|
|
76
|
+
function ThinkingStep({ label, status = "pending", className, ...htmlProps }) {
|
|
84
77
|
const classes = [
|
|
85
78
|
styles.step,
|
|
86
79
|
styles[`step${status.charAt(0).toUpperCase() + status.slice(1)}`],
|
|
@@ -90,7 +83,17 @@ function ThinkingStep({
|
|
|
90
83
|
/* @__PURE__ */ jsxs("span", { className: styles.stepIndicator, children: [
|
|
91
84
|
status === "complete" && /* @__PURE__ */ jsx(CheckIcon, {}),
|
|
92
85
|
status === "error" && /* @__PURE__ */ jsx(ErrorIcon, {}),
|
|
93
|
-
status === "active" && /* @__PURE__ */ jsx(
|
|
86
|
+
status === "active" && /* @__PURE__ */ jsx(
|
|
87
|
+
Loading,
|
|
88
|
+
{
|
|
89
|
+
size: "sm",
|
|
90
|
+
variant: "spinner",
|
|
91
|
+
color: "current",
|
|
92
|
+
label: "",
|
|
93
|
+
role: "presentation",
|
|
94
|
+
"aria-hidden": "true"
|
|
95
|
+
}
|
|
96
|
+
),
|
|
94
97
|
status === "pending" && /* @__PURE__ */ jsx("span", { className: styles.stepDot })
|
|
95
98
|
] }),
|
|
96
99
|
/* @__PURE__ */ jsx("span", { className: styles.stepLabel, children: label })
|
|
@@ -111,36 +114,26 @@ function ThinkingIndicatorRoot({
|
|
|
111
114
|
variant
|
|
112
115
|
};
|
|
113
116
|
if (!active) return null;
|
|
114
|
-
const classes = [
|
|
115
|
-
styles.thinkingIndicator,
|
|
116
|
-
className
|
|
117
|
-
].filter(Boolean).join(" ");
|
|
117
|
+
const classes = [styles.thinkingIndicator, className].filter(Boolean).join(" ");
|
|
118
118
|
const loadingVariant = variant === "dots" ? "dots" : variant === "pulse" ? "pulse" : "spinner";
|
|
119
|
-
return /* @__PURE__ */ jsx(ThinkingIndicatorContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsxs(
|
|
120
|
-
"div",
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
status: step.status
|
|
138
|
-
},
|
|
139
|
-
step.id
|
|
140
|
-
)) })
|
|
141
|
-
]
|
|
142
|
-
}
|
|
143
|
-
) });
|
|
119
|
+
return /* @__PURE__ */ jsx(ThinkingIndicatorContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsxs("div", { ...htmlProps, className: classes, role: "status", "aria-label": label, "aria-live": "polite", children: [
|
|
120
|
+
/* @__PURE__ */ jsxs("div", { className: styles.main, children: [
|
|
121
|
+
/* @__PURE__ */ jsx(
|
|
122
|
+
Loading,
|
|
123
|
+
{
|
|
124
|
+
size: "sm",
|
|
125
|
+
variant: loadingVariant,
|
|
126
|
+
color: "muted",
|
|
127
|
+
label: "",
|
|
128
|
+
role: "presentation",
|
|
129
|
+
"aria-hidden": "true"
|
|
130
|
+
}
|
|
131
|
+
),
|
|
132
|
+
/* @__PURE__ */ jsx("span", { className: styles.label, children: label }),
|
|
133
|
+
showElapsed && elapsedTime && /* @__PURE__ */ jsx("span", { className: styles.elapsed, children: elapsedTime })
|
|
134
|
+
] }),
|
|
135
|
+
steps && steps.length > 0 && /* @__PURE__ */ jsx(ThinkingSteps, { children: steps.map((step) => /* @__PURE__ */ jsx(ThinkingStep, { label: step.label, status: step.status }, step.id)) })
|
|
136
|
+
] }) });
|
|
144
137
|
}
|
|
145
138
|
const ThinkingIndicator = Object.assign(ThinkingIndicatorRoot, {
|
|
146
139
|
Steps: ThinkingSteps,
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const container = "
|
|
4
|
-
const topleft = "
|
|
5
|
-
const topcenter = "
|
|
6
|
-
const topright = "
|
|
7
|
-
const bottomleft = "
|
|
8
|
-
const bottomcenter = "
|
|
9
|
-
const bottomright = "
|
|
10
|
-
const toast = "
|
|
11
|
-
const toastEnter = "
|
|
12
|
-
const description = "
|
|
13
|
-
const icon = "
|
|
14
|
-
const success = "
|
|
15
|
-
const title = "
|
|
16
|
-
const error = "
|
|
17
|
-
const warning = "
|
|
18
|
-
const info = "
|
|
19
|
-
const content = "
|
|
20
|
-
const action = "
|
|
21
|
-
const close = "
|
|
3
|
+
const container = "_container_1qytp_1";
|
|
4
|
+
const topleft = "_topleft_1qytp_14";
|
|
5
|
+
const topcenter = "_topcenter_1qytp_19";
|
|
6
|
+
const topright = "_topright_1qytp_25";
|
|
7
|
+
const bottomleft = "_bottomleft_1qytp_30";
|
|
8
|
+
const bottomcenter = "_bottomcenter_1qytp_36";
|
|
9
|
+
const bottomright = "_bottomright_1qytp_43";
|
|
10
|
+
const toast = "_toast_1qytp_49";
|
|
11
|
+
const toastEnter = "_toastEnter_1qytp_1";
|
|
12
|
+
const description = "_description_1qytp_66";
|
|
13
|
+
const icon = "_icon_1qytp_80";
|
|
14
|
+
const success = "_success_1qytp_84";
|
|
15
|
+
const title = "_title_1qytp_88";
|
|
16
|
+
const error = "_error_1qytp_94";
|
|
17
|
+
const warning = "_warning_1qytp_104";
|
|
18
|
+
const info = "_info_1qytp_114";
|
|
19
|
+
const content = "_content_1qytp_145";
|
|
20
|
+
const action = "_action_1qytp_170";
|
|
21
|
+
const close = "_close_1qytp_234";
|
|
22
22
|
const styles = {
|
|
23
23
|
container,
|
|
24
24
|
topleft,
|
|
@@ -30,7 +30,7 @@ const styles = {
|
|
|
30
30
|
toast,
|
|
31
31
|
toastEnter,
|
|
32
32
|
description,
|
|
33
|
-
"default": "
|
|
33
|
+
"default": "_default_1qytp_80",
|
|
34
34
|
icon,
|
|
35
35
|
success,
|
|
36
36
|
title,
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
const container = "
|
|
2
|
-
const topleft = "
|
|
3
|
-
const topcenter = "
|
|
4
|
-
const topright = "
|
|
5
|
-
const bottomleft = "
|
|
6
|
-
const bottomcenter = "
|
|
7
|
-
const bottomright = "
|
|
8
|
-
const toast = "
|
|
9
|
-
const toastEnter = "
|
|
10
|
-
const description = "
|
|
11
|
-
const icon = "
|
|
12
|
-
const success = "
|
|
13
|
-
const title = "
|
|
14
|
-
const error = "
|
|
15
|
-
const warning = "
|
|
16
|
-
const info = "
|
|
17
|
-
const content = "
|
|
18
|
-
const action = "
|
|
19
|
-
const close = "
|
|
1
|
+
const container = "_container_1qytp_1";
|
|
2
|
+
const topleft = "_topleft_1qytp_14";
|
|
3
|
+
const topcenter = "_topcenter_1qytp_19";
|
|
4
|
+
const topright = "_topright_1qytp_25";
|
|
5
|
+
const bottomleft = "_bottomleft_1qytp_30";
|
|
6
|
+
const bottomcenter = "_bottomcenter_1qytp_36";
|
|
7
|
+
const bottomright = "_bottomright_1qytp_43";
|
|
8
|
+
const toast = "_toast_1qytp_49";
|
|
9
|
+
const toastEnter = "_toastEnter_1qytp_1";
|
|
10
|
+
const description = "_description_1qytp_66";
|
|
11
|
+
const icon = "_icon_1qytp_80";
|
|
12
|
+
const success = "_success_1qytp_84";
|
|
13
|
+
const title = "_title_1qytp_88";
|
|
14
|
+
const error = "_error_1qytp_94";
|
|
15
|
+
const warning = "_warning_1qytp_104";
|
|
16
|
+
const info = "_info_1qytp_114";
|
|
17
|
+
const content = "_content_1qytp_145";
|
|
18
|
+
const action = "_action_1qytp_170";
|
|
19
|
+
const close = "_close_1qytp_234";
|
|
20
20
|
const styles = {
|
|
21
21
|
container,
|
|
22
22
|
topleft,
|
|
@@ -28,7 +28,7 @@ const styles = {
|
|
|
28
28
|
toast,
|
|
29
29
|
toastEnter,
|
|
30
30
|
description,
|
|
31
|
-
"default": "
|
|
31
|
+
"default": "_default_1qytp_80",
|
|
32
32
|
icon,
|
|
33
33
|
success,
|
|
34
34
|
title,
|
|
@@ -1,43 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
* Binary on/off switch for settings and preferences.
|
|
4
|
-
* @see https://usefragments.com/components/switch
|
|
5
|
-
*/
|
|
6
|
-
export interface SwitchProps {
|
|
7
|
-
/** Whether the switch is on */
|
|
8
|
-
checked?: boolean;
|
|
9
|
-
/** Default checked state (uncontrolled) */
|
|
10
|
-
defaultChecked?: boolean;
|
|
11
|
-
/** Called when the switch is toggled */
|
|
12
|
-
onCheckedChange?: (checked: boolean) => void;
|
|
13
|
-
/** Alias for onCheckedChange */
|
|
14
|
-
onChange?: (checked: boolean) => void;
|
|
15
|
-
label?: string;
|
|
16
|
-
/** Helper text shown below the label */
|
|
17
|
-
helperText?: string;
|
|
18
|
-
/** @deprecated Use helperText instead. */
|
|
19
|
-
description?: string;
|
|
20
|
-
disabled?: boolean;
|
|
21
|
-
readOnly?: boolean;
|
|
22
|
-
required?: boolean;
|
|
23
|
-
size?: "sm" | "md" | "lg";
|
|
24
|
-
className?: string;
|
|
25
|
-
name?: string;
|
|
26
|
-
form?: string;
|
|
27
|
-
value?: string;
|
|
28
|
-
uncheckedValue?: string;
|
|
29
|
-
inputRef?: React.Ref<HTMLInputElement>;
|
|
30
|
-
id?: string;
|
|
31
|
-
"aria-label"?: string;
|
|
32
|
-
"aria-labelledby"?: string;
|
|
33
|
-
"aria-describedby"?: string;
|
|
34
|
-
}
|
|
35
|
-
export type ToggleProps = SwitchProps;
|
|
36
|
-
export declare const Switch: React.ForwardRefExoticComponent<SwitchProps & React.RefAttributes<HTMLButtonElement>> & {
|
|
37
|
-
Root: React.ForwardRefExoticComponent<SwitchProps & React.RefAttributes<HTMLButtonElement>>;
|
|
38
|
-
};
|
|
39
|
-
/** @deprecated Use `Switch` instead. */
|
|
40
|
-
export declare const Toggle: React.ForwardRefExoticComponent<SwitchProps & React.RefAttributes<HTMLButtonElement>> & {
|
|
41
|
-
Root: React.ForwardRefExoticComponent<SwitchProps & React.RefAttributes<HTMLButtonElement>>;
|
|
42
|
-
};
|
|
1
|
+
/** @deprecated Import `Switch` from `../Switch` instead. */
|
|
2
|
+
export { Switch, type SwitchProps, Switch as Toggle, type SwitchProps as ToggleProps, } from "../Switch";
|
|
43
3
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Toggle/index.
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Toggle/index.ts"],"names":[],"mappings":"AAAA,4DAA4D;AAC5D,OAAO,EACL,MAAM,EACN,KAAK,WAAW,EAChB,MAAM,IAAI,MAAM,EAChB,KAAK,WAAW,IAAI,WAAW,GAChC,MAAM,WAAW,CAAC"}
|
|
@@ -1,34 +1,34 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const group = "
|
|
4
|
-
const gapXs = "_gap-
|
|
5
|
-
const gapSm = "_gap-
|
|
6
|
-
const item = "
|
|
7
|
-
const selected = "
|
|
8
|
-
const
|
|
9
|
-
const
|
|
10
|
-
const
|
|
11
|
-
const
|
|
12
|
-
const
|
|
13
|
-
const
|
|
3
|
+
const group = "_group_8ifhr_1";
|
|
4
|
+
const gapXs = "_gap-xs_8ifhr_7";
|
|
5
|
+
const gapSm = "_gap-sm_8ifhr_11";
|
|
6
|
+
const item = "_item_8ifhr_15";
|
|
7
|
+
const selected = "_selected_8ifhr_47";
|
|
8
|
+
const disabled = "_disabled_8ifhr_53";
|
|
9
|
+
const sizeSm = "_size-sm_8ifhr_58";
|
|
10
|
+
const sizeMd = "_size-md_8ifhr_97";
|
|
11
|
+
const sizeLg = "_size-lg_8ifhr_136";
|
|
12
|
+
const pills = "_pills_8ifhr_195";
|
|
13
|
+
const outline = "_outline_8ifhr_208";
|
|
14
14
|
const styles = {
|
|
15
15
|
group,
|
|
16
|
-
"gap-xs": "_gap-
|
|
16
|
+
"gap-xs": "_gap-xs_8ifhr_7",
|
|
17
17
|
gapXs,
|
|
18
|
-
"gap-sm": "_gap-
|
|
18
|
+
"gap-sm": "_gap-sm_8ifhr_11",
|
|
19
19
|
gapSm,
|
|
20
|
-
"default": "_default_1nacr_16",
|
|
21
20
|
item,
|
|
22
21
|
selected,
|
|
23
|
-
pills,
|
|
24
|
-
outline,
|
|
25
22
|
disabled,
|
|
26
|
-
"size-sm": "_size-
|
|
23
|
+
"size-sm": "_size-sm_8ifhr_58",
|
|
27
24
|
sizeSm,
|
|
28
|
-
"size-md": "_size-
|
|
25
|
+
"size-md": "_size-md_8ifhr_97",
|
|
29
26
|
sizeMd,
|
|
30
|
-
"size-lg": "_size-
|
|
31
|
-
sizeLg
|
|
27
|
+
"size-lg": "_size-lg_8ifhr_136",
|
|
28
|
+
sizeLg,
|
|
29
|
+
"default": "_default_8ifhr_175",
|
|
30
|
+
pills,
|
|
31
|
+
outline
|
|
32
32
|
};
|
|
33
33
|
exports.default = styles;
|
|
34
34
|
exports.disabled = disabled;
|
|
@@ -1,32 +1,32 @@
|
|
|
1
|
-
const group = "
|
|
2
|
-
const gapXs = "_gap-
|
|
3
|
-
const gapSm = "_gap-
|
|
4
|
-
const item = "
|
|
5
|
-
const selected = "
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
const
|
|
9
|
-
const
|
|
10
|
-
const
|
|
11
|
-
const
|
|
1
|
+
const group = "_group_8ifhr_1";
|
|
2
|
+
const gapXs = "_gap-xs_8ifhr_7";
|
|
3
|
+
const gapSm = "_gap-sm_8ifhr_11";
|
|
4
|
+
const item = "_item_8ifhr_15";
|
|
5
|
+
const selected = "_selected_8ifhr_47";
|
|
6
|
+
const disabled = "_disabled_8ifhr_53";
|
|
7
|
+
const sizeSm = "_size-sm_8ifhr_58";
|
|
8
|
+
const sizeMd = "_size-md_8ifhr_97";
|
|
9
|
+
const sizeLg = "_size-lg_8ifhr_136";
|
|
10
|
+
const pills = "_pills_8ifhr_195";
|
|
11
|
+
const outline = "_outline_8ifhr_208";
|
|
12
12
|
const styles = {
|
|
13
13
|
group,
|
|
14
|
-
"gap-xs": "_gap-
|
|
14
|
+
"gap-xs": "_gap-xs_8ifhr_7",
|
|
15
15
|
gapXs,
|
|
16
|
-
"gap-sm": "_gap-
|
|
16
|
+
"gap-sm": "_gap-sm_8ifhr_11",
|
|
17
17
|
gapSm,
|
|
18
|
-
"default": "_default_1nacr_16",
|
|
19
18
|
item,
|
|
20
19
|
selected,
|
|
21
|
-
pills,
|
|
22
|
-
outline,
|
|
23
20
|
disabled,
|
|
24
|
-
"size-sm": "_size-
|
|
21
|
+
"size-sm": "_size-sm_8ifhr_58",
|
|
25
22
|
sizeSm,
|
|
26
|
-
"size-md": "_size-
|
|
23
|
+
"size-md": "_size-md_8ifhr_97",
|
|
27
24
|
sizeMd,
|
|
28
|
-
"size-lg": "_size-
|
|
29
|
-
sizeLg
|
|
25
|
+
"size-lg": "_size-lg_8ifhr_136",
|
|
26
|
+
sizeLg,
|
|
27
|
+
"default": "_default_8ifhr_175",
|
|
28
|
+
pills,
|
|
29
|
+
outline
|
|
30
30
|
};
|
|
31
31
|
export {
|
|
32
32
|
styles as default,
|
|
@@ -38,7 +38,7 @@ function ToggleGroupRoot({
|
|
|
38
38
|
children,
|
|
39
39
|
variant = "default",
|
|
40
40
|
size: sizeProp,
|
|
41
|
-
gap
|
|
41
|
+
gap,
|
|
42
42
|
selectionMode = "single",
|
|
43
43
|
className,
|
|
44
44
|
...htmlProps
|
|
@@ -46,6 +46,7 @@ function ToggleGroupRoot({
|
|
|
46
46
|
var _a;
|
|
47
47
|
const size = index.useResolvedControlSize(sizeProp);
|
|
48
48
|
const normalizedVariant = variant === "outlined" ? "outline" : variant;
|
|
49
|
+
const resolvedGap = normalizedVariant === "pills" ? gap ?? "xs" : "none";
|
|
49
50
|
const [internalValue, setInternalValue] = React__namespace.useState(defaultValue ?? "");
|
|
50
51
|
const isControlled = value !== void 0;
|
|
51
52
|
const currentValue = isControlled ? value ?? "" : internalValue;
|
|
@@ -63,7 +64,7 @@ function ToggleGroupRoot({
|
|
|
63
64
|
ToggleGroup_module.default.group,
|
|
64
65
|
ToggleGroup_module.default[normalizedVariant],
|
|
65
66
|
ToggleGroup_module.default[`size-${size}`],
|
|
66
|
-
|
|
67
|
+
resolvedGap !== "none" && ToggleGroup_module.default[`gap-${resolvedGap}`],
|
|
67
68
|
className
|
|
68
69
|
].filter(Boolean).join(" ");
|
|
69
70
|
const childItems = React__namespace.Children.toArray(children).filter(
|
|
@@ -21,7 +21,8 @@ export interface ToggleGroupProps extends Omit<React.HTMLAttributes<HTMLDivEleme
|
|
|
21
21
|
/** Size.
|
|
22
22
|
* @default "md" */
|
|
23
23
|
size?: "sm" | "md" | "lg";
|
|
24
|
-
/** Gap between items
|
|
24
|
+
/** Gap between items in the pills variant. Defaults to `xs` for pills and
|
|
25
|
+
* is intentionally removed from connected variants. */
|
|
25
26
|
gap?: "none" | "xs" | "sm";
|
|
26
27
|
/** Selection mode for this control. Currently only single-select is supported.
|
|
27
28
|
* @default "single" */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/ToggleGroup/index.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAQ/B;;;GAGG;AACH,MAAM,WAAW,gBAAiB,SAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,UAAU,CAAC;IAC9F,6BAA6B;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,4CAA4C;IAC5C,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,sCAAsC;IACtC,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACnC,4CAA4C;IAC5C,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,mBAAmB;IACnB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B;;uEAEmE;IACnE,OAAO,CAAC,EAAE,SAAS,GAAG,OAAO,GAAG,SAAS,GAAG,UAAU,CAAC;IACvD;uBACmB;IACnB,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IAC1B
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/ToggleGroup/index.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAQ/B;;;GAGG;AACH,MAAM,WAAW,gBAAiB,SAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,UAAU,CAAC;IAC9F,6BAA6B;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,4CAA4C;IAC5C,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,sCAAsC;IACtC,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACnC,4CAA4C;IAC5C,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,mBAAmB;IACnB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B;;uEAEmE;IACnE,OAAO,CAAC,EAAE,SAAS,GAAG,OAAO,GAAG,SAAS,GAAG,UAAU,CAAC;IACvD;uBACmB;IACnB,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IAC1B;2DACuD;IACvD,GAAG,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI,CAAC;IAC3B;2BACuB;IACvB,aAAa,CAAC,EAAE,QAAQ,CAAC;CAC1B;AAED,MAAM,WAAW,oBAAqB,SAAQ,IAAI,CAChD,KAAK,CAAC,cAAc,CAAC,iBAAiB,CAAC,EACvC,SAAS,CACV;IACC,0BAA0B;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,mBAAmB;IACnB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,qBAAqB;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAMD,UAAU,uBAAuB;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,OAAO,EAAE,SAAS,GAAG,OAAO,GAAG,SAAS,CAAC;IACzC,IAAI,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IACzB,qBAAqB,EAAE,OAAO,CAAC;IAC/B,iBAAiB,EAAE,MAAM,GAAG,IAAI,CAAC;CAClC;AAID,iBAAS,qBAAqB,4BAM7B;AAMD,iBAAS,eAAe,CAAC,EACvB,KAAK,EACL,YAAY,EACZ,QAAQ,EACR,aAAa,EACb,QAAQ,EACR,OAAmB,EACnB,IAAI,EAAE,QAAQ,EACd,GAAG,EACH,aAAwB,EACxB,SAAS,EACT,GAAG,SAAS,EACb,EAAE,gBAAgB,2CAuDlB;AAED,iBAAS,eAAe,CAAC,EACvB,KAAK,EACL,QAAQ,EACR,QAAgB,EAChB,SAAS,EACT,SAAS,EACT,GAAG,SAAS,EACb,EAAE,oBAAoB,2CAwFtB;AAMD,eAAO,MAAM,WAAW;;CAEtB,CAAC;AAEH,OAAO,EAAE,eAAe,EAAE,eAAe,EAAE,qBAAqB,EAAE,CAAC"}
|
|
@@ -19,7 +19,7 @@ function ToggleGroupRoot({
|
|
|
19
19
|
children,
|
|
20
20
|
variant = "default",
|
|
21
21
|
size: sizeProp,
|
|
22
|
-
gap
|
|
22
|
+
gap,
|
|
23
23
|
selectionMode = "single",
|
|
24
24
|
className,
|
|
25
25
|
...htmlProps
|
|
@@ -27,6 +27,7 @@ function ToggleGroupRoot({
|
|
|
27
27
|
var _a;
|
|
28
28
|
const size = useResolvedControlSize(sizeProp);
|
|
29
29
|
const normalizedVariant = variant === "outlined" ? "outline" : variant;
|
|
30
|
+
const resolvedGap = normalizedVariant === "pills" ? gap ?? "xs" : "none";
|
|
30
31
|
const [internalValue, setInternalValue] = React.useState(defaultValue ?? "");
|
|
31
32
|
const isControlled = value !== void 0;
|
|
32
33
|
const currentValue = isControlled ? value ?? "" : internalValue;
|
|
@@ -44,7 +45,7 @@ function ToggleGroupRoot({
|
|
|
44
45
|
styles.group,
|
|
45
46
|
styles[normalizedVariant],
|
|
46
47
|
styles[`size-${size}`],
|
|
47
|
-
|
|
48
|
+
resolvedGap !== "none" && styles[`gap-${resolvedGap}`],
|
|
48
49
|
className
|
|
49
50
|
].filter(Boolean).join(" ");
|
|
50
51
|
const childItems = React.Children.toArray(children).filter(
|