@usefragments/ui 1.6.0 → 1.7.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 +4 -4
- package/dist/assets/fragments-wordmark.cjs +2 -2
- package/dist/assets/fragments-wordmark.d.ts.map +1 -1
- package/dist/assets/fragments-wordmark.js +2 -2
- package/dist/assets/ui.css +4720 -4159
- package/dist/chart.cjs +24 -6
- package/dist/chart.js +24 -6
- package/dist/codeblock.cjs +55 -29
- package/dist/codeblock.js +55 -29
- package/dist/colorpicker.cjs +3 -1
- package/dist/colorpicker.js +3 -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 +15 -12
- package/dist/components/Alert/Alert.module.scss.js +15 -12
- package/dist/components/Alert/index.cjs +7 -1
- package/dist/components/Alert/index.d.ts +12 -6
- package/dist/components/Alert/index.d.ts.map +1 -1
- package/dist/components/Alert/index.js +7 -1
- package/dist/components/AppShell/AppShell.module.scss.cjs +14 -14
- package/dist/components/AppShell/AppShell.module.scss.js +14 -14
- package/dist/components/Avatar/Avatar.module.scss.cjs +14 -14
- package/dist/components/Avatar/Avatar.module.scss.js +14 -14
- 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/Box/index.cjs +64 -75
- package/dist/components/Box/index.d.ts +16 -16
- package/dist/components/Box/index.d.ts.map +1 -1
- package/dist/components/Box/index.js +64 -75
- 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/Card/Card.module.scss.cjs +29 -17
- package/dist/components/Card/Card.module.scss.js +30 -18
- package/dist/components/Card/index.cjs +8 -0
- package/dist/components/Card/index.d.ts +12 -2
- package/dist/components/Card/index.d.ts.map +1 -1
- package/dist/components/Card/index.js +8 -0
- 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.map +1 -1
- package/dist/components/Checkbox/Checkbox.module.scss.cjs +9 -9
- package/dist/components/Checkbox/Checkbox.module.scss.js +9 -9
- package/dist/components/Checkbox/index.cjs +2 -2
- package/dist/components/Checkbox/index.d.ts.map +1 -1
- package/dist/components/Checkbox/index.js +2 -2
- 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 +2 -1
- package/dist/components/Chip/index.d.ts.map +1 -1
- package/dist/components/Chip/index.js +2 -1
- package/dist/components/CodeBlock/CodeBlock.module.scss.cjs +26 -23
- package/dist/components/CodeBlock/CodeBlock.module.scss.js +26 -23
- package/dist/components/CodeBlock/css-variables-theme.cjs +98 -0
- package/dist/components/CodeBlock/css-variables-theme.d.ts +27 -0
- package/dist/components/CodeBlock/css-variables-theme.d.ts.map +1 -0
- package/dist/components/CodeBlock/css-variables-theme.js +98 -0
- package/dist/components/CodeBlock/index.d.ts +17 -3
- package/dist/components/CodeBlock/index.d.ts.map +1 -1
- package/dist/components/Collapsible/Collapsible.module.scss.cjs +9 -9
- package/dist/components/Collapsible/Collapsible.module.scss.js +9 -9
- package/dist/components/ColorPicker/ColorPicker.module.scss.cjs +14 -14
- package/dist/components/ColorPicker/ColorPicker.module.scss.js +14 -14
- package/dist/components/ColorPicker/index.d.ts.map +1 -1
- package/dist/components/Combobox/Combobox.module.scss.cjs +21 -21
- package/dist/components/Combobox/Combobox.module.scss.js +21 -21
- package/dist/components/Combobox/index.cjs +17 -1
- package/dist/components/Combobox/index.d.ts.map +1 -1
- package/dist/components/Combobox/index.js +17 -1
- package/dist/components/Command/Command.module.scss.cjs +11 -11
- package/dist/components/Command/Command.module.scss.js +11 -11
- package/dist/components/Command/index.cjs +26 -15
- package/dist/components/Command/index.d.ts +2 -2
- package/dist/components/Command/index.d.ts.map +1 -1
- package/dist/components/Command/index.js +26 -15
- package/dist/components/ConversationList/ConversationList.module.scss.cjs +10 -10
- package/dist/components/ConversationList/ConversationList.module.scss.js +10 -10
- package/dist/components/DataTable/DataTable.icons.cjs +6 -33
- package/dist/components/DataTable/DataTable.icons.d.ts.map +1 -1
- package/dist/components/DataTable/DataTable.icons.js +6 -33
- package/dist/components/DataTable/DataTable.module.scss.cjs +27 -27
- package/dist/components/DataTable/DataTable.module.scss.js +27 -27
- 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/Dialog/index.cjs +11 -14
- package/dist/components/Dialog/index.d.ts +7 -7
- package/dist/components/Dialog/index.d.ts.map +1 -1
- package/dist/components/Dialog/index.js +11 -14
- package/dist/components/Drawer/Drawer.module.scss.cjs +29 -29
- package/dist/components/Drawer/Drawer.module.scss.js +29 -29
- package/dist/components/Editor/Editor.module.scss.cjs +17 -17
- package/dist/components/Editor/Editor.module.scss.js +17 -17
- package/dist/components/Editor/index.d.ts +10 -10
- package/dist/components/Editor/index.d.ts.map +1 -1
- package/dist/components/EmptyState/EmptyState.module.scss.cjs +11 -8
- package/dist/components/EmptyState/EmptyState.module.scss.js +11 -8
- package/dist/components/EmptyState/index.cjs +8 -6
- package/dist/components/EmptyState/index.d.ts +9 -4
- package/dist/components/EmptyState/index.d.ts.map +1 -1
- package/dist/components/EmptyState/index.js +8 -6
- package/dist/components/Field/Field.module.scss.cjs +5 -5
- package/dist/components/Field/Field.module.scss.js +5 -5
- package/dist/components/Field/index.cjs +9 -1
- package/dist/components/Field/index.d.ts.map +1 -1
- package/dist/components/Field/index.js +9 -1
- package/dist/components/Fieldset/Fieldset.module.scss.cjs +3 -3
- package/dist/components/Fieldset/Fieldset.module.scss.js +3 -3
- package/dist/components/Grid/index.cjs +1 -1
- package/dist/components/Grid/index.js +1 -1
- 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 +17 -38
- package/dist/components/Header/index.d.ts +15 -11
- package/dist/components/Header/index.d.ts.map +1 -1
- package/dist/components/Header/index.js +17 -38
- package/dist/components/Icon/Icon.module.scss.cjs +15 -15
- package/dist/components/Icon/Icon.module.scss.js +15 -15
- package/dist/components/IconButton/IconButton.module.scss.cjs +8 -8
- package/dist/components/IconButton/IconButton.module.scss.js +8 -8
- package/dist/components/IconButton/index.cjs +2 -1
- package/dist/components/IconButton/index.d.ts.map +1 -1
- package/dist/components/IconButton/index.js +2 -1
- package/dist/components/Image/Image.module.scss.cjs +27 -27
- package/dist/components/Image/Image.module.scss.js +27 -27
- package/dist/components/Input/Input.module.scss.cjs +17 -17
- package/dist/components/Input/Input.module.scss.js +17 -17
- package/dist/components/Link/Link.module.scss.cjs +14 -10
- package/dist/components/Link/Link.module.scss.js +14 -10
- package/dist/components/Link/index.d.ts +1 -1
- package/dist/components/Link/index.d.ts.map +1 -1
- package/dist/components/List/List.module.scss.cjs +19 -19
- package/dist/components/List/List.module.scss.js +19 -19
- package/dist/components/Listbox/Listbox.module.scss.cjs +8 -8
- package/dist/components/Listbox/Listbox.module.scss.js +8 -8
- package/dist/components/Loading/Loading.module.scss.cjs +34 -34
- package/dist/components/Loading/Loading.module.scss.js +34 -34
- package/dist/components/Loading/index.cjs +1 -1
- package/dist/components/Loading/index.js +1 -1
- package/dist/components/Markdown/Markdown.module.scss.cjs +1 -1
- package/dist/components/Markdown/Markdown.module.scss.js +1 -1
- package/dist/components/Markdown/index.d.ts +2 -2
- package/dist/components/Markdown/index.d.ts.map +1 -1
- package/dist/components/Menu/Menu.module.scss.cjs +14 -14
- package/dist/components/Menu/Menu.module.scss.js +14 -14
- package/dist/components/Message/Message.module.scss.cjs +18 -18
- package/dist/components/Message/Message.module.scss.js +18 -18
- package/dist/components/NavigationMenu/NavigationMenu.module.scss.cjs +34 -31
- package/dist/components/NavigationMenu/NavigationMenu.module.scss.js +34 -31
- package/dist/components/NavigationMenu/index.cjs +32 -15
- package/dist/components/NavigationMenu/index.d.ts +12 -6
- package/dist/components/NavigationMenu/index.d.ts.map +1 -1
- package/dist/components/NavigationMenu/index.js +32 -15
- package/dist/components/Pagination/Pagination.module.scss.cjs +10 -10
- package/dist/components/Pagination/Pagination.module.scss.js +10 -10
- 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 +25 -25
- package/dist/components/Progress/Progress.module.scss.js +25 -25
- package/dist/components/Prompt/Prompt.module.scss.cjs +28 -28
- package/dist/components/Prompt/Prompt.module.scss.js +28 -28
- package/dist/components/RadioGroup/RadioGroup.module.scss.cjs +15 -15
- package/dist/components/RadioGroup/RadioGroup.module.scss.js +15 -15
- package/dist/components/ScrollArea/ScrollArea.module.scss.cjs +5 -5
- package/dist/components/ScrollArea/ScrollArea.module.scss.js +5 -5
- package/dist/components/ScrollArea/index.d.ts +4 -4
- package/dist/components/ScrollArea/index.d.ts.map +1 -1
- package/dist/components/ScrollArea/scroll-state.d.ts +5 -5
- package/dist/components/Select/Select.module.scss.cjs +21 -21
- package/dist/components/Select/Select.module.scss.js +21 -21
- package/dist/components/Separator/Separator.module.scss.cjs +11 -11
- package/dist/components/Separator/Separator.module.scss.js +11 -11
- 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 +12 -35
- package/dist/components/Sidebar/index.d.ts +19 -19
- package/dist/components/Sidebar/index.d.ts.map +1 -1
- package/dist/components/Sidebar/index.js +12 -35
- package/dist/components/Skeleton/Skeleton.module.scss.cjs +50 -46
- package/dist/components/Skeleton/Skeleton.module.scss.js +50 -46
- 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 -25
- package/dist/components/Stack/Stack.module.scss.js +25 -25
- package/dist/components/Stack/index.cjs +1 -1
- package/dist/components/Stack/index.js +1 -1
- package/dist/components/Switch/Switch.module.scss.cjs +9 -9
- package/dist/components/Switch/Switch.module.scss.js +9 -9
- package/dist/components/Table/Table.module.scss.cjs +19 -19
- package/dist/components/Table/Table.module.scss.js +19 -19
- package/dist/components/TableOfContents/TableOfContents.module.scss.cjs +15 -15
- package/dist/components/TableOfContents/TableOfContents.module.scss.js +15 -15
- package/dist/components/TableOfContents/index.cjs +13 -9
- package/dist/components/TableOfContents/index.d.ts +5 -3
- package/dist/components/TableOfContents/index.d.ts.map +1 -1
- package/dist/components/TableOfContents/index.js +13 -9
- 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 +26 -6
- package/dist/components/Tabs/index.d.ts.map +1 -1
- package/dist/components/Tabs/index.js +26 -6
- package/dist/components/Text/Text.module.scss.cjs +87 -75
- package/dist/components/Text/Text.module.scss.js +87 -75
- package/dist/components/Text/index.cjs +49 -41
- package/dist/components/Text/index.d.ts +12 -11
- package/dist/components/Text/index.d.ts.map +1 -1
- package/dist/components/Text/index.js +49 -41
- package/dist/components/Textarea/Textarea.module.scss.cjs +24 -24
- package/dist/components/Textarea/Textarea.module.scss.js +24 -24
- package/dist/components/Theme/index.cjs +2 -1
- package/dist/components/Theme/index.d.ts.map +1 -1
- package/dist/components/Theme/index.js +2 -1
- package/dist/components/ThemeToggle/ThemeToggle.module.scss.cjs +9 -6
- package/dist/components/ThemeToggle/ThemeToggle.module.scss.js +9 -6
- package/dist/components/ThemeToggle/index.cjs +31 -6
- package/dist/components/ThemeToggle/index.d.ts +7 -2
- package/dist/components/ThemeToggle/index.d.ts.map +1 -1
- package/dist/components/ThemeToggle/index.js +32 -7
- package/dist/components/ThinkingIndicator/ThinkingIndicator.module.scss.cjs +13 -13
- package/dist/components/ThinkingIndicator/ThinkingIndicator.module.scss.js +13 -13
- package/dist/components/Toast/Toast.module.scss.cjs +20 -20
- package/dist/components/Toast/Toast.module.scss.js +20 -20
- package/dist/components/ToggleGroup/ToggleGroup.module.scss.cjs +17 -17
- package/dist/components/ToggleGroup/ToggleGroup.module.scss.js +17 -17
- package/dist/components/Tooltip/Tooltip.module.scss.cjs +3 -3
- package/dist/components/Tooltip/Tooltip.module.scss.js +3 -3
- package/dist/components/Tooltip/index.cjs +24 -40
- package/dist/components/Tooltip/index.d.ts +4 -4
- package/dist/components/Tooltip/index.d.ts.map +1 -1
- package/dist/components/Tooltip/index.js +24 -40
- package/dist/components/VisuallyHidden/index.d.ts +2 -2
- package/dist/data-table.cjs +2 -1
- package/dist/data-table.js +2 -1
- package/dist/datepicker.cjs +3 -2
- package/dist/datepicker.js +3 -2
- package/dist/editor.cjs +68 -28
- package/dist/editor.js +68 -28
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -2
- package/dist/markdown.cjs +21 -29
- package/dist/markdown.js +21 -29
- package/dist/measurements/generated.cjs +9 -1
- package/dist/measurements/generated.d.ts +7 -0
- package/dist/measurements/generated.d.ts.map +1 -1
- package/dist/measurements/generated.js +9 -1
- package/dist/utils/a11y.cjs +5 -2
- package/dist/utils/a11y.d.ts +5 -5
- package/dist/utils/a11y.d.ts.map +1 -1
- package/dist/utils/a11y.js +5 -2
- package/dist/utils/canonical-stamp.cjs +2 -8
- package/dist/utils/canonical-stamp.d.ts.map +1 -1
- package/dist/utils/canonical-stamp.js +1 -7
- package/dist/utils/css-warning.cjs +1 -1
- package/dist/utils/css-warning.js +1 -1
- package/dist/utils/env.cjs +17 -0
- package/dist/utils/env.d.ts +3 -0
- package/dist/utils/env.d.ts.map +1 -0
- package/dist/utils/env.js +17 -0
- package/dist/utils/keyboard-shortcuts.cjs +3 -10
- package/dist/utils/keyboard-shortcuts.d.ts +4 -4
- package/dist/utils/keyboard-shortcuts.d.ts.map +1 -1
- package/dist/utils/keyboard-shortcuts.js +3 -10
- package/dist/utils/seed-derivation.cjs +10 -6
- package/dist/utils/seed-derivation.d.ts.map +1 -1
- package/dist/utils/seed-derivation.js +10 -6
- package/fragments.json +1 -1
- package/package.json +6 -4
- package/src/assets/fragments-logo.tsx +2 -2
- package/src/assets/fragments-wordmark.tsx +4 -2
- package/src/components/Accordion/Accordion.contract.json +24 -48
- package/src/components/Alert/Alert.contract.json +37 -53
- package/src/components/Alert/Alert.module.scss +24 -0
- package/src/components/Alert/index.tsx +55 -29
- package/src/components/AppShell/AppShell.contract.json +34 -51
- package/src/components/AppShell/AppShell.module.scss +53 -40
- package/src/components/Avatar/Avatar.contract.json +31 -48
- package/src/components/Avatar/Avatar.module.scss +4 -1
- package/src/components/Badge/Badge.contract.json +37 -42
- package/src/components/Badge/Badge.module.scss +9 -2
- package/src/components/BentoGrid/BentoGrid.contract.json +21 -45
- package/src/components/Box/Box.contract.json +40 -148
- package/src/components/Box/index.tsx +92 -99
- package/src/components/Breadcrumbs/Breadcrumbs.contract.json +21 -34
- package/src/components/Breadcrumbs/Breadcrumbs.module.scss +12 -7
- package/src/components/Button/Button.module.scss +8 -7
- package/src/components/ButtonGroup/ButtonGroup.contract.json +32 -47
- package/src/components/Card/Card.module.scss +82 -1
- package/src/components/Card/index.tsx +21 -2
- package/src/components/Chart/Chart.contract.json +21 -29
- package/src/components/Chart/index.tsx +36 -6
- package/src/components/Checkbox/Checkbox.contract.json +24 -24
- package/src/components/Checkbox/Checkbox.module.scss +32 -23
- package/src/components/Checkbox/index.tsx +4 -2
- package/src/components/Chip/Chip.contract.json +33 -40
- package/src/components/Chip/Chip.module.scss +2 -2
- package/src/components/Chip/index.tsx +2 -1
- package/src/components/CodeBlock/CodeBlock.contract.json +46 -76
- package/src/components/CodeBlock/CodeBlock.module.scss +40 -15
- package/src/components/CodeBlock/css-variables-theme.ts +102 -0
- package/src/components/CodeBlock/index.tsx +91 -35
- package/src/components/Collapsible/Collapsible.contract.json +21 -36
- package/src/components/ColorPicker/ColorPicker.contract.json +29 -48
- package/src/components/ColorPicker/ColorPicker.module.scss +15 -12
- package/src/components/ColorPicker/index.tsx +5 -1
- package/src/components/Combobox/Combobox.contract.json +36 -37
- package/src/components/Combobox/Combobox.module.scss +1 -1
- package/src/components/Combobox/index.tsx +31 -5
- package/src/components/Command/Command.contract.json +21 -43
- package/src/components/Command/index.tsx +58 -47
- package/src/components/ConversationList/ConversationList.contract.json +27 -32
- package/src/components/DataTable/DataTable.icons.tsx +4 -21
- package/src/components/DataTable/DataTable.module.scss +12 -8
- package/src/components/DataTable/index.tsx +8 -7
- package/src/components/DatePicker/DatePicker.contract.json +27 -28
- package/src/components/DatePicker/DatePicker.module.scss +12 -5
- package/src/components/DatePicker/index.tsx +5 -2
- package/src/components/Dialog/Dialog.module.scss +3 -3
- package/src/components/Dialog/index.tsx +47 -37
- package/src/components/Drawer/Drawer.contract.json +22 -36
- package/src/components/Editor/Editor.contract.json +31 -48
- package/src/components/Editor/Editor.module.scss +36 -14
- package/src/components/Editor/index.tsx +240 -179
- package/src/components/EmptyState/EmptyState.contract.json +31 -43
- package/src/components/EmptyState/EmptyState.module.scss +8 -0
- package/src/components/EmptyState/index.tsx +48 -23
- package/src/components/Field/Field.contract.json +28 -46
- package/src/components/Field/index.tsx +5 -1
- package/src/components/Fieldset/Fieldset.contract.json +21 -38
- package/src/components/Fieldset/Fieldset.module.scss +10 -3
- package/src/components/Form/Form.contract.json +20 -20
- package/src/components/Grid/Grid.contract.json +28 -64
- package/src/components/Grid/index.tsx +10 -10
- package/src/components/Header/Header.contract.json +31 -67
- package/src/components/Header/Header.module.scss +36 -21
- package/src/components/Header/index.tsx +134 -122
- package/src/components/Icon/Icon.contract.json +22 -62
- package/src/components/IconButton/IconButton.contract.json +34 -18
- package/src/components/IconButton/IconButton.module.scss +6 -7
- package/src/components/IconButton/index.tsx +2 -1
- package/src/components/Image/Image.contract.json +23 -56
- package/src/components/Input/Input.contract.json +26 -32
- package/src/components/Input/Input.module.scss +3 -2
- package/src/components/Link/Link.contract.json +32 -52
- package/src/components/Link/Link.module.scss +23 -6
- package/src/components/Link/index.tsx +1 -1
- package/src/components/List/List.contract.json +23 -52
- package/src/components/List/List.module.scss +1 -1
- package/src/components/Listbox/Listbox.contract.json +21 -37
- package/src/components/Loading/Loading.contract.json +37 -61
- package/src/components/Loading/Loading.module.scss +10 -7
- package/src/components/Loading/index.tsx +2 -2
- package/src/components/Main/Main.contract.json +17 -9
- package/src/components/Markdown/Markdown.contract.json +22 -43
- package/src/components/Markdown/Markdown.module.scss +43 -5
- package/src/components/Markdown/index.tsx +48 -49
- package/src/components/Menu/Menu.contract.json +25 -41
- package/src/components/Menu/Menu.module.scss +23 -8
- package/src/components/Message/Message.contract.json +29 -52
- package/src/components/Message/Message.module.scss +12 -5
- package/src/components/NavigationMenu/NavigationMenu.contract.json +36 -45
- package/src/components/NavigationMenu/NavigationMenu.module.scss +64 -19
- package/src/components/NavigationMenu/index.tsx +105 -81
- package/src/components/Pagination/Pagination.contract.json +22 -40
- package/src/components/Pagination/Pagination.module.scss +2 -2
- package/src/components/Popover/Popover.contract.json +24 -46
- package/src/components/Popover/Popover.module.scss +6 -5
- package/src/components/Progress/Progress.contract.json +32 -28
- package/src/components/Progress/Progress.module.scss +3 -2
- package/src/components/Prompt/Prompt.contract.json +31 -47
- package/src/components/Prompt/Prompt.module.scss +13 -5
- package/src/components/RadioGroup/RadioGroup.contract.json +23 -24
- package/src/components/RadioGroup/RadioGroup.module.scss +13 -14
- package/src/components/ScrollArea/ScrollArea.contract.json +18 -19
- package/src/components/ScrollArea/ScrollArea.module.scss +15 -15
- package/src/components/ScrollArea/index.tsx +16 -16
- package/src/components/ScrollArea/scroll-state.ts +24 -24
- package/src/components/Select/Select.module.scss +2 -2
- package/src/components/Separator/Separator.contract.json +24 -48
- package/src/components/Sidebar/Sidebar.contract.json +35 -67
- package/src/components/Sidebar/Sidebar.module.scss +22 -13
- package/src/components/Sidebar/index.tsx +164 -164
- package/src/components/Skeleton/Skeleton.contract.json +28 -54
- package/src/components/Skeleton/Skeleton.module.scss +27 -10
- package/src/components/Slider/Slider.contract.json +27 -39
- package/src/components/Slider/Slider.module.scss +3 -3
- package/src/components/Stack/Stack.contract.json +29 -56
- package/src/components/Stack/Stack.module.scss +13 -12
- package/src/components/Stack/index.tsx +3 -3
- package/src/components/Switch/Switch.contract.json +33 -46
- package/src/components/Switch/Switch.module.scss +64 -26
- package/src/components/Table/Table.contract.json +28 -46
- package/src/components/Table/Table.module.scss +15 -3
- package/src/components/TableOfContents/TableOfContents.contract.json +34 -21
- package/src/components/TableOfContents/TableOfContents.module.scss +15 -5
- package/src/components/TableOfContents/index.tsx +26 -9
- package/src/components/Tabs/Tabs.contract.json +24 -45
- package/src/components/Tabs/Tabs.module.scss +1 -1
- package/src/components/Tabs/index.tsx +15 -3
- package/src/components/Text/Text.contract.json +30 -72
- package/src/components/Text/Text.module.scss +21 -4
- package/src/components/Text/index.tsx +113 -75
- package/src/components/Textarea/Textarea.contract.json +25 -43
- package/src/components/Textarea/Textarea.module.scss +2 -4
- package/src/components/Theme/Theme.contract.json +32 -51
- package/src/components/Theme/index.tsx +2 -1
- package/src/components/ThemeToggle/ThemeToggle.module.scss +23 -7
- package/src/components/ThemeToggle/index.tsx +43 -7
- package/src/components/ThinkingIndicator/ThinkingIndicator.contract.json +23 -40
- package/src/components/Toast/Toast.contract.json +30 -40
- package/src/components/Toast/Toast.module.scss +1 -1
- package/src/components/ToggleGroup/ToggleGroup.contract.json +29 -30
- package/src/components/ToggleGroup/ToggleGroup.module.scss +38 -5
- package/src/components/Tooltip/Tooltip.contract.json +31 -52
- package/src/components/Tooltip/index.tsx +19 -24
- package/src/components/VisuallyHidden/VisuallyHidden.contract.json +22 -44
- package/src/components/VisuallyHidden/index.tsx +5 -5
- package/src/index.ts +2 -2
- package/src/measurements/generated.ts +9 -2
- package/src/measurements/measurements.json +7 -0
- package/src/recipes/_boolean-range.scss +3 -11
- package/src/recipes/_field.scss +5 -1
- package/src/recipes/_layout.scss +14 -7
- package/src/recipes/_popup.scss +12 -2
- package/src/recipes/_prose.scss +13 -5
- package/src/recipes/_table-chrome.scss +16 -2
- package/src/scss.d.ts +1 -1
- package/src/styles/globals.scss +20 -19
- package/src/tokens/_computed.scss +5 -16
- package/src/tokens/_derive.scss +112 -210
- package/src/tokens/_measurements.catalog.generated.css +6 -1
- package/src/tokens/_measurements.generated.scss +14 -1
- package/src/tokens/_mixins.scss +7 -8
- package/src/tokens/_palettes.scss +39 -167
- package/src/tokens/_seeds.scss +20 -20
- package/src/tokens/_variables.scss +183 -38
- package/src/utils/a11y.tsx +69 -69
- package/src/utils/aria.ts +3 -3
- package/src/utils/canonical-stamp.ts +2 -12
- package/src/utils/css-warning.ts +7 -7
- package/src/utils/env.ts +25 -0
- package/src/utils/keyboard-shortcuts.ts +131 -126
- package/src/utils/seed-derivation.ts +10 -6
- package/src/components/Button/Button.contract.json +0 -218
- package/src/components/Card/Card.contract.json +0 -175
- package/src/components/DataTable/DataTable.contract.json +0 -302
- package/src/components/Dialog/Dialog.contract.json +0 -159
- package/src/components/Select/Select.contract.json +0 -259
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import * as React from
|
|
2
|
-
import { type ScrollOrientation } from
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { type ScrollOrientation } from "./scroll-state";
|
|
3
3
|
export interface ScrollAreaProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
4
4
|
children: React.ReactNode;
|
|
5
5
|
/** Scroll direction */
|
|
6
6
|
orientation?: ScrollOrientation;
|
|
7
7
|
/** Scrollbar visibility behavior */
|
|
8
|
-
scrollbarVisibility?:
|
|
9
|
-
/** Whether to show fade indicators at scroll edges */
|
|
8
|
+
scrollbarVisibility?: "auto" | "always" | "hover";
|
|
9
|
+
/** Whether to show fade indicators at scroll edges. Defaults to false. */
|
|
10
10
|
showFades?: boolean;
|
|
11
11
|
/** Additional class name */
|
|
12
12
|
className?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/ScrollArea/index.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAIL,KAAK,iBAAiB,EACvB,MAAM,gBAAgB,CAAC;AAMxB,MAAM,WAAW,eAAgB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC3E,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,uBAAuB;IACvB,WAAW,CAAC,EAAE,iBAAiB,CAAC;IAChC,oCAAoC;IACpC,mBAAmB,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,CAAC;IAClD,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/ScrollArea/index.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAIL,KAAK,iBAAiB,EACvB,MAAM,gBAAgB,CAAC;AAMxB,MAAM,WAAW,eAAgB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC3E,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,uBAAuB;IACvB,WAAW,CAAC,EAAE,iBAAiB,CAAC;IAChC,oCAAoC;IACpC,mBAAmB,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,CAAC;IAClD,0EAA0E;IAC1E,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,4BAA4B;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAMD;;;;;GAKG;AACH,iBAAS,cAAc,CAAC,EACtB,QAAQ,EACR,WAAwB,EACxB,mBAA4B,EAC5B,SAAiB,EACjB,SAAS,EACT,GAAG,EACH,GAAG,SAAS,EACb,EAAE,eAAe,2CAsFjB;AAMD,eAAO,MAAM,UAAU;;CAErB,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export type ScrollOrientation =
|
|
2
|
-
export type ScrollEdgeState =
|
|
3
|
-
export type RtlScrollModel =
|
|
1
|
+
export type ScrollOrientation = "horizontal" | "vertical" | "both";
|
|
2
|
+
export type ScrollEdgeState = "none" | "start" | "end" | "both";
|
|
3
|
+
export type RtlScrollModel = "negative" | "positive-descending" | "positive-ascending";
|
|
4
4
|
export interface ScrollAxesState {
|
|
5
5
|
x: ScrollEdgeState;
|
|
6
6
|
y: ScrollEdgeState;
|
|
@@ -8,9 +8,9 @@ export interface ScrollAxesState {
|
|
|
8
8
|
export declare const SCROLL_EDGE_EPSILON_PX = 1;
|
|
9
9
|
/** Detect the browser's RTL scrollLeft model without retaining probe elements. */
|
|
10
10
|
export declare function detectRtlScrollModel(document: Document): RtlScrollModel;
|
|
11
|
-
export declare function readScrollAxes(element: Pick<HTMLElement,
|
|
11
|
+
export declare function readScrollAxes(element: Pick<HTMLElement, "clientWidth" | "clientHeight" | "scrollWidth" | "scrollHeight" | "scrollLeft" | "scrollTop">, options: {
|
|
12
12
|
orientation: ScrollOrientation;
|
|
13
|
-
direction:
|
|
13
|
+
direction: "ltr" | "rtl";
|
|
14
14
|
rtlModel?: RtlScrollModel;
|
|
15
15
|
}): ScrollAxesState;
|
|
16
16
|
//# sourceMappingURL=scroll-state.d.ts.map
|
|
@@ -1,26 +1,26 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const wrapper = "
|
|
4
|
-
const label = "
|
|
5
|
-
const helper = "
|
|
6
|
-
const helperError = "
|
|
7
|
-
const errorMessage = "
|
|
8
|
-
const trigger = "
|
|
9
|
-
const triggerSm = "
|
|
10
|
-
const triggerLg = "
|
|
11
|
-
const triggerGhost = "
|
|
12
|
-
const wrapperGhost = "
|
|
13
|
-
const triggerIcon = "
|
|
14
|
-
const value = "
|
|
15
|
-
const placeholder = "
|
|
16
|
-
const hint = "
|
|
17
|
-
const icon = "
|
|
18
|
-
const positioner = "
|
|
19
|
-
const popup = "
|
|
20
|
-
const item = "
|
|
21
|
-
const itemIndicator = "
|
|
22
|
-
const group = "
|
|
23
|
-
const groupLabel = "
|
|
3
|
+
const wrapper = "_wrapper_aykjj_1";
|
|
4
|
+
const label = "_label_aykjj_8";
|
|
5
|
+
const helper = "_helper_aykjj_17";
|
|
6
|
+
const helperError = "_helperError_aykjj_27";
|
|
7
|
+
const errorMessage = "_errorMessage_aykjj_28";
|
|
8
|
+
const trigger = "_trigger_aykjj_38";
|
|
9
|
+
const triggerSm = "_triggerSm_aykjj_92";
|
|
10
|
+
const triggerLg = "_triggerLg_aykjj_104";
|
|
11
|
+
const triggerGhost = "_triggerGhost_aykjj_116";
|
|
12
|
+
const wrapperGhost = "_wrapperGhost_aykjj_142";
|
|
13
|
+
const triggerIcon = "_triggerIcon_aykjj_147";
|
|
14
|
+
const value = "_value_aykjj_155";
|
|
15
|
+
const placeholder = "_placeholder_aykjj_168";
|
|
16
|
+
const hint = "_hint_aykjj_172";
|
|
17
|
+
const icon = "_icon_aykjj_178";
|
|
18
|
+
const positioner = "_positioner_aykjj_206";
|
|
19
|
+
const popup = "_popup_aykjj_211";
|
|
20
|
+
const item = "_item_aykjj_262";
|
|
21
|
+
const itemIndicator = "_itemIndicator_aykjj_293";
|
|
22
|
+
const group = "_group_aykjj_307";
|
|
23
|
+
const groupLabel = "_groupLabel_aykjj_315";
|
|
24
24
|
const styles = {
|
|
25
25
|
wrapper,
|
|
26
26
|
label,
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
const wrapper = "
|
|
2
|
-
const label = "
|
|
3
|
-
const helper = "
|
|
4
|
-
const helperError = "
|
|
5
|
-
const errorMessage = "
|
|
6
|
-
const trigger = "
|
|
7
|
-
const triggerSm = "
|
|
8
|
-
const triggerLg = "
|
|
9
|
-
const triggerGhost = "
|
|
10
|
-
const wrapperGhost = "
|
|
11
|
-
const triggerIcon = "
|
|
12
|
-
const value = "
|
|
13
|
-
const placeholder = "
|
|
14
|
-
const hint = "
|
|
15
|
-
const icon = "
|
|
16
|
-
const positioner = "
|
|
17
|
-
const popup = "
|
|
18
|
-
const item = "
|
|
19
|
-
const itemIndicator = "
|
|
20
|
-
const group = "
|
|
21
|
-
const groupLabel = "
|
|
1
|
+
const wrapper = "_wrapper_aykjj_1";
|
|
2
|
+
const label = "_label_aykjj_8";
|
|
3
|
+
const helper = "_helper_aykjj_17";
|
|
4
|
+
const helperError = "_helperError_aykjj_27";
|
|
5
|
+
const errorMessage = "_errorMessage_aykjj_28";
|
|
6
|
+
const trigger = "_trigger_aykjj_38";
|
|
7
|
+
const triggerSm = "_triggerSm_aykjj_92";
|
|
8
|
+
const triggerLg = "_triggerLg_aykjj_104";
|
|
9
|
+
const triggerGhost = "_triggerGhost_aykjj_116";
|
|
10
|
+
const wrapperGhost = "_wrapperGhost_aykjj_142";
|
|
11
|
+
const triggerIcon = "_triggerIcon_aykjj_147";
|
|
12
|
+
const value = "_value_aykjj_155";
|
|
13
|
+
const placeholder = "_placeholder_aykjj_168";
|
|
14
|
+
const hint = "_hint_aykjj_172";
|
|
15
|
+
const icon = "_icon_aykjj_178";
|
|
16
|
+
const positioner = "_positioner_aykjj_206";
|
|
17
|
+
const popup = "_popup_aykjj_211";
|
|
18
|
+
const item = "_item_aykjj_262";
|
|
19
|
+
const itemIndicator = "_itemIndicator_aykjj_293";
|
|
20
|
+
const group = "_group_aykjj_307";
|
|
21
|
+
const groupLabel = "_groupLabel_aykjj_315";
|
|
22
22
|
const styles = {
|
|
23
23
|
wrapper,
|
|
24
24
|
label,
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const separator = "
|
|
4
|
-
const horizontal = "
|
|
5
|
-
const line = "
|
|
6
|
-
const vertical = "
|
|
7
|
-
const withLabel = "
|
|
8
|
-
const label = "
|
|
9
|
-
const spacingNone = "
|
|
10
|
-
const spacingSm = "
|
|
11
|
-
const spacingMd = "
|
|
12
|
-
const spacingLg = "
|
|
13
|
-
const soft = "
|
|
3
|
+
const separator = "_separator_ddx8o_1";
|
|
4
|
+
const horizontal = "_horizontal_ddx8o_6";
|
|
5
|
+
const line = "_line_ddx8o_9";
|
|
6
|
+
const vertical = "_vertical_ddx8o_16";
|
|
7
|
+
const withLabel = "_withLabel_ddx8o_27";
|
|
8
|
+
const label = "_label_ddx8o_40";
|
|
9
|
+
const spacingNone = "_spacingNone_ddx8o_51";
|
|
10
|
+
const spacingSm = "_spacingSm_ddx8o_55";
|
|
11
|
+
const spacingMd = "_spacingMd_ddx8o_62";
|
|
12
|
+
const spacingLg = "_spacingLg_ddx8o_69";
|
|
13
|
+
const soft = "_soft_ddx8o_76";
|
|
14
14
|
const styles = {
|
|
15
15
|
separator,
|
|
16
16
|
horizontal,
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
const separator = "
|
|
2
|
-
const horizontal = "
|
|
3
|
-
const line = "
|
|
4
|
-
const vertical = "
|
|
5
|
-
const withLabel = "
|
|
6
|
-
const label = "
|
|
7
|
-
const spacingNone = "
|
|
8
|
-
const spacingSm = "
|
|
9
|
-
const spacingMd = "
|
|
10
|
-
const spacingLg = "
|
|
11
|
-
const soft = "
|
|
1
|
+
const separator = "_separator_ddx8o_1";
|
|
2
|
+
const horizontal = "_horizontal_ddx8o_6";
|
|
3
|
+
const line = "_line_ddx8o_9";
|
|
4
|
+
const vertical = "_vertical_ddx8o_16";
|
|
5
|
+
const withLabel = "_withLabel_ddx8o_27";
|
|
6
|
+
const label = "_label_ddx8o_40";
|
|
7
|
+
const spacingNone = "_spacingNone_ddx8o_51";
|
|
8
|
+
const spacingSm = "_spacingSm_ddx8o_55";
|
|
9
|
+
const spacingMd = "_spacingMd_ddx8o_62";
|
|
10
|
+
const spacingLg = "_spacingLg_ddx8o_69";
|
|
11
|
+
const soft = "_soft_ddx8o_76";
|
|
12
12
|
const styles = {
|
|
13
13
|
separator,
|
|
14
14
|
horizontal,
|
|
@@ -1,48 +1,48 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
-
const root = "
|
|
4
|
-
const mobile = "
|
|
5
|
-
const positionRight = "
|
|
6
|
-
const collapsed = "
|
|
7
|
-
const header = "
|
|
8
|
-
const nav = "
|
|
9
|
-
const footer = "
|
|
10
|
-
const sectionLabel = "
|
|
11
|
-
const itemLabel = "
|
|
12
|
-
const itemBadge = "
|
|
13
|
-
const itemChevron = "
|
|
14
|
-
const item = "
|
|
15
|
-
const itemIcon = "
|
|
16
|
-
const collapseToggle = "
|
|
17
|
-
const collapsedNoIcons = "
|
|
18
|
-
const offcanvasCollapsed = "
|
|
19
|
-
const collapseToggleFloating = "
|
|
20
|
-
const rail = "
|
|
21
|
-
const navScrollArea = "
|
|
22
|
-
const section = "
|
|
23
|
-
const sectionHeader = "
|
|
24
|
-
const sectionTrigger = "
|
|
25
|
-
const sectionActionWrapper = "
|
|
26
|
-
const sectionAction = "
|
|
27
|
-
const sectionList = "
|
|
28
|
-
const submenu = "
|
|
29
|
-
const sectionCollapsible = "
|
|
30
|
-
const itemWrapper = "
|
|
31
|
-
const subItemWrapper = "
|
|
32
|
-
const submenuWrapper = "
|
|
33
|
-
const itemDisabled = "
|
|
34
|
-
const itemActive = "
|
|
35
|
-
const subItemDisabled = "
|
|
36
|
-
const itemMultiline = "
|
|
37
|
-
const itemExpanded = "
|
|
38
|
-
const subItem = "
|
|
39
|
-
const subItemActive = "
|
|
40
|
-
const trigger = "
|
|
41
|
-
const overlay = "
|
|
42
|
-
const railCollapsed = "
|
|
43
|
-
const menuSkeleton = "
|
|
44
|
-
const skeletonItem = "
|
|
45
|
-
const skeletonLabel = "
|
|
3
|
+
const root = "_root_17sht_1";
|
|
4
|
+
const mobile = "_mobile_17sht_51";
|
|
5
|
+
const positionRight = "_positionRight_17sht_57";
|
|
6
|
+
const collapsed = "_collapsed_17sht_62";
|
|
7
|
+
const header = "_header_17sht_65";
|
|
8
|
+
const nav = "_nav_17sht_66";
|
|
9
|
+
const footer = "_footer_17sht_67";
|
|
10
|
+
const sectionLabel = "_sectionLabel_17sht_74";
|
|
11
|
+
const itemLabel = "_itemLabel_17sht_85";
|
|
12
|
+
const itemBadge = "_itemBadge_17sht_86";
|
|
13
|
+
const itemChevron = "_itemChevron_17sht_87";
|
|
14
|
+
const item = "_item_17sht_85";
|
|
15
|
+
const itemIcon = "_itemIcon_17sht_95";
|
|
16
|
+
const collapseToggle = "_collapseToggle_17sht_98";
|
|
17
|
+
const collapsedNoIcons = "_collapsedNoIcons_17sht_102";
|
|
18
|
+
const offcanvasCollapsed = "_offcanvasCollapsed_17sht_105";
|
|
19
|
+
const collapseToggleFloating = "_collapseToggleFloating_17sht_111";
|
|
20
|
+
const rail = "_rail_17sht_125";
|
|
21
|
+
const navScrollArea = "_navScrollArea_17sht_166";
|
|
22
|
+
const section = "_section_17sht_74";
|
|
23
|
+
const sectionHeader = "_sectionHeader_17sht_175";
|
|
24
|
+
const sectionTrigger = "_sectionTrigger_17sht_205";
|
|
25
|
+
const sectionActionWrapper = "_sectionActionWrapper_17sht_219";
|
|
26
|
+
const sectionAction = "_sectionAction_17sht_219";
|
|
27
|
+
const sectionList = "_sectionList_17sht_303";
|
|
28
|
+
const submenu = "_submenu_17sht_304";
|
|
29
|
+
const sectionCollapsible = "_sectionCollapsible_17sht_313";
|
|
30
|
+
const itemWrapper = "_itemWrapper_17sht_361";
|
|
31
|
+
const subItemWrapper = "_subItemWrapper_17sht_362";
|
|
32
|
+
const submenuWrapper = "_submenuWrapper_17sht_363";
|
|
33
|
+
const itemDisabled = "_itemDisabled_17sht_436";
|
|
34
|
+
const itemActive = "_itemActive_17sht_445";
|
|
35
|
+
const subItemDisabled = "_subItemDisabled_17sht_530";
|
|
36
|
+
const itemMultiline = "_itemMultiline_17sht_586";
|
|
37
|
+
const itemExpanded = "_itemExpanded_17sht_613";
|
|
38
|
+
const subItem = "_subItem_17sht_362";
|
|
39
|
+
const subItemActive = "_subItemActive_17sht_712";
|
|
40
|
+
const trigger = "_trigger_17sht_730";
|
|
41
|
+
const overlay = "_overlay_17sht_797";
|
|
42
|
+
const railCollapsed = "_railCollapsed_17sht_945";
|
|
43
|
+
const menuSkeleton = "_menuSkeleton_17sht_949";
|
|
44
|
+
const skeletonItem = "_skeletonItem_17sht_956";
|
|
45
|
+
const skeletonLabel = "_skeletonLabel_17sht_985";
|
|
46
46
|
const styles = {
|
|
47
47
|
root,
|
|
48
48
|
mobile,
|
|
@@ -1,46 +1,46 @@
|
|
|
1
|
-
const root = "
|
|
2
|
-
const mobile = "
|
|
3
|
-
const positionRight = "
|
|
4
|
-
const collapsed = "
|
|
5
|
-
const header = "
|
|
6
|
-
const nav = "
|
|
7
|
-
const footer = "
|
|
8
|
-
const sectionLabel = "
|
|
9
|
-
const itemLabel = "
|
|
10
|
-
const itemBadge = "
|
|
11
|
-
const itemChevron = "
|
|
12
|
-
const item = "
|
|
13
|
-
const itemIcon = "
|
|
14
|
-
const collapseToggle = "
|
|
15
|
-
const collapsedNoIcons = "
|
|
16
|
-
const offcanvasCollapsed = "
|
|
17
|
-
const collapseToggleFloating = "
|
|
18
|
-
const rail = "
|
|
19
|
-
const navScrollArea = "
|
|
20
|
-
const section = "
|
|
21
|
-
const sectionHeader = "
|
|
22
|
-
const sectionTrigger = "
|
|
23
|
-
const sectionActionWrapper = "
|
|
24
|
-
const sectionAction = "
|
|
25
|
-
const sectionList = "
|
|
26
|
-
const submenu = "
|
|
27
|
-
const sectionCollapsible = "
|
|
28
|
-
const itemWrapper = "
|
|
29
|
-
const subItemWrapper = "
|
|
30
|
-
const submenuWrapper = "
|
|
31
|
-
const itemDisabled = "
|
|
32
|
-
const itemActive = "
|
|
33
|
-
const subItemDisabled = "
|
|
34
|
-
const itemMultiline = "
|
|
35
|
-
const itemExpanded = "
|
|
36
|
-
const subItem = "
|
|
37
|
-
const subItemActive = "
|
|
38
|
-
const trigger = "
|
|
39
|
-
const overlay = "
|
|
40
|
-
const railCollapsed = "
|
|
41
|
-
const menuSkeleton = "
|
|
42
|
-
const skeletonItem = "
|
|
43
|
-
const skeletonLabel = "
|
|
1
|
+
const root = "_root_17sht_1";
|
|
2
|
+
const mobile = "_mobile_17sht_51";
|
|
3
|
+
const positionRight = "_positionRight_17sht_57";
|
|
4
|
+
const collapsed = "_collapsed_17sht_62";
|
|
5
|
+
const header = "_header_17sht_65";
|
|
6
|
+
const nav = "_nav_17sht_66";
|
|
7
|
+
const footer = "_footer_17sht_67";
|
|
8
|
+
const sectionLabel = "_sectionLabel_17sht_74";
|
|
9
|
+
const itemLabel = "_itemLabel_17sht_85";
|
|
10
|
+
const itemBadge = "_itemBadge_17sht_86";
|
|
11
|
+
const itemChevron = "_itemChevron_17sht_87";
|
|
12
|
+
const item = "_item_17sht_85";
|
|
13
|
+
const itemIcon = "_itemIcon_17sht_95";
|
|
14
|
+
const collapseToggle = "_collapseToggle_17sht_98";
|
|
15
|
+
const collapsedNoIcons = "_collapsedNoIcons_17sht_102";
|
|
16
|
+
const offcanvasCollapsed = "_offcanvasCollapsed_17sht_105";
|
|
17
|
+
const collapseToggleFloating = "_collapseToggleFloating_17sht_111";
|
|
18
|
+
const rail = "_rail_17sht_125";
|
|
19
|
+
const navScrollArea = "_navScrollArea_17sht_166";
|
|
20
|
+
const section = "_section_17sht_74";
|
|
21
|
+
const sectionHeader = "_sectionHeader_17sht_175";
|
|
22
|
+
const sectionTrigger = "_sectionTrigger_17sht_205";
|
|
23
|
+
const sectionActionWrapper = "_sectionActionWrapper_17sht_219";
|
|
24
|
+
const sectionAction = "_sectionAction_17sht_219";
|
|
25
|
+
const sectionList = "_sectionList_17sht_303";
|
|
26
|
+
const submenu = "_submenu_17sht_304";
|
|
27
|
+
const sectionCollapsible = "_sectionCollapsible_17sht_313";
|
|
28
|
+
const itemWrapper = "_itemWrapper_17sht_361";
|
|
29
|
+
const subItemWrapper = "_subItemWrapper_17sht_362";
|
|
30
|
+
const submenuWrapper = "_submenuWrapper_17sht_363";
|
|
31
|
+
const itemDisabled = "_itemDisabled_17sht_436";
|
|
32
|
+
const itemActive = "_itemActive_17sht_445";
|
|
33
|
+
const subItemDisabled = "_subItemDisabled_17sht_530";
|
|
34
|
+
const itemMultiline = "_itemMultiline_17sht_586";
|
|
35
|
+
const itemExpanded = "_itemExpanded_17sht_613";
|
|
36
|
+
const subItem = "_subItem_17sht_362";
|
|
37
|
+
const subItemActive = "_subItemActive_17sht_712";
|
|
38
|
+
const trigger = "_trigger_17sht_730";
|
|
39
|
+
const overlay = "_overlay_17sht_797";
|
|
40
|
+
const railCollapsed = "_railCollapsed_17sht_945";
|
|
41
|
+
const menuSkeleton = "_menuSkeleton_17sht_949";
|
|
42
|
+
const skeletonItem = "_skeletonItem_17sht_956";
|
|
43
|
+
const skeletonLabel = "_skeletonLabel_17sht_985";
|
|
44
44
|
const styles = {
|
|
45
45
|
root,
|
|
46
46
|
mobile,
|
|
@@ -206,11 +206,7 @@ function SidebarProvider({
|
|
|
206
206
|
defaultCollapsed,
|
|
207
207
|
onCollapsedChange
|
|
208
208
|
);
|
|
209
|
-
const [open, setOpen] = useControllableState(
|
|
210
|
-
controlledOpen,
|
|
211
|
-
defaultOpen,
|
|
212
|
-
onOpenChange
|
|
213
|
-
);
|
|
209
|
+
const [open, setOpen] = useControllableState(controlledOpen, defaultOpen, onOpenChange);
|
|
214
210
|
const toggleSidebar = React__namespace.useCallback(() => {
|
|
215
211
|
if (collapsible === "none") return;
|
|
216
212
|
if (isMobile) {
|
|
@@ -272,7 +268,7 @@ function SidebarRoot({
|
|
|
272
268
|
width = "240px",
|
|
273
269
|
collapsedWidth = "var(--fui-navigation-sidebar-collapsed-width, 56px)",
|
|
274
270
|
position = "left",
|
|
275
|
-
collapsible
|
|
271
|
+
collapsible,
|
|
276
272
|
activeIndicator = "start",
|
|
277
273
|
className,
|
|
278
274
|
style: styleProp,
|
|
@@ -291,14 +287,15 @@ function SidebarRoot({
|
|
|
291
287
|
defaultOpen,
|
|
292
288
|
onOpenChange
|
|
293
289
|
);
|
|
294
|
-
const
|
|
295
|
-
const
|
|
290
|
+
const isCollapsedControlled = controlledCollapsed !== void 0;
|
|
291
|
+
const collapsed = isCollapsedControlled || !existingContext ? internalCollapsed : existingContext.collapsed;
|
|
292
|
+
const setCollapsed = isCollapsedControlled || !existingContext ? setInternalCollapsed : existingContext.setCollapsed;
|
|
296
293
|
const open = existingContext ? existingContext.open : internalOpen;
|
|
297
294
|
const setOpen = existingContext ? existingContext.setOpen : setInternalOpen;
|
|
298
295
|
const resolvedPosition = existingContext ? existingContext.position : position;
|
|
299
296
|
const resolvedWidth = existingContext ? existingContext.width : width;
|
|
300
297
|
const resolvedCollapsedWidth = existingContext ? existingContext.collapsedWidth : collapsedWidth;
|
|
301
|
-
const resolvedCollapsible = existingContext ? existingContext.collapsible :
|
|
298
|
+
const resolvedCollapsible = collapsible ?? (existingContext ? existingContext.collapsible : "icon");
|
|
302
299
|
const hasIcons = React__namespace.useMemo(() => hasSidebarItemIcons(children), [children]);
|
|
303
300
|
const shouldCollapseToZero = !isMobile && resolvedCollapsible === "icon" && collapsed && !hasIcons;
|
|
304
301
|
const isOffcanvasCollapsed = !isMobile && resolvedCollapsible === "offcanvas" && collapsed;
|
|
@@ -382,6 +379,7 @@ function SidebarRoot({
|
|
|
382
379
|
role: isMobile ? "dialog" : void 0,
|
|
383
380
|
"aria-modal": isMobile && open ? true : void 0,
|
|
384
381
|
"aria-hidden": isMobile && !open ? true : void 0,
|
|
382
|
+
inert: isMobile && !open ? true : void 0,
|
|
385
383
|
"aria-label": isMobile ? ariaLabel || "Sidebar navigation" : ariaLabel,
|
|
386
384
|
"data-state": isMobile ? open ? "open" : "closed" : collapsed ? "collapsed" : "expanded",
|
|
387
385
|
"data-position": resolvedPosition,
|
|
@@ -424,10 +422,7 @@ function SidebarSection({
|
|
|
424
422
|
...htmlProps
|
|
425
423
|
}) {
|
|
426
424
|
const { collapsed, isMobile } = useSidebarContext();
|
|
427
|
-
const classes = [
|
|
428
|
-
Sidebar_module.default.section,
|
|
429
|
-
className
|
|
430
|
-
].filter(Boolean).join(" ");
|
|
425
|
+
const classes = [Sidebar_module.default.section, className].filter(Boolean).join(" ");
|
|
431
426
|
const showLabel = label && (!collapsed || isMobile);
|
|
432
427
|
const showAction = action && (!collapsed || isMobile);
|
|
433
428
|
const isCollapsible = isCollapsibleProp && showLabel;
|
|
@@ -442,14 +437,7 @@ function SidebarSection({
|
|
|
442
437
|
}
|
|
443
438
|
return /* @__PURE__ */ jsxRuntime.jsx("div", { ...htmlProps, className: classes, role: "group", "aria-label": label, children: /* @__PURE__ */ jsxRuntime.jsxs(index$1.Collapsible, { defaultOpen, className: Sidebar_module.default.sectionCollapsible, children: [
|
|
444
439
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: Sidebar_module.default.sectionHeader, children: [
|
|
445
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
446
|
-
index$1.Collapsible.Trigger,
|
|
447
|
-
{
|
|
448
|
-
className: Sidebar_module.default.sectionTrigger,
|
|
449
|
-
chevronPosition: "end",
|
|
450
|
-
children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: Sidebar_module.default.sectionLabel, children: label })
|
|
451
|
-
}
|
|
452
|
-
),
|
|
440
|
+
/* @__PURE__ */ jsxRuntime.jsx(index$1.Collapsible.Trigger, { className: Sidebar_module.default.sectionTrigger, chevronPosition: "end", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: Sidebar_module.default.sectionLabel, children: label }) }),
|
|
453
441
|
showAction && /* @__PURE__ */ jsxRuntime.jsx("div", { className: Sidebar_module.default.sectionActionWrapper, children: action })
|
|
454
442
|
] }),
|
|
455
443
|
/* @__PURE__ */ jsxRuntime.jsx(index$1.Collapsible.Content, { className: Sidebar_module.default.sectionContent, children: /* @__PURE__ */ jsxRuntime.jsx("ul", { className: Sidebar_module.default.sectionList, children }) })
|
|
@@ -562,10 +550,7 @@ function SidebarItem({
|
|
|
562
550
|
itemElement = /* @__PURE__ */ jsxRuntime.jsx("button", { ...itemProps, ...rest, type: "button", children: itemContent });
|
|
563
551
|
}
|
|
564
552
|
const wrappedItem = isCollapsed ? /* @__PURE__ */ jsxRuntime.jsx(index$4.Tooltip, { content: labelText || children, side: "right", delay: 100, children: itemElement }) : itemElement;
|
|
565
|
-
const wrapperClasses = [
|
|
566
|
-
Sidebar_module.default.itemWrapper,
|
|
567
|
-
expanded && Sidebar_module.default.itemExpanded
|
|
568
|
-
].filter(Boolean).join(" ");
|
|
553
|
+
const wrapperClasses = [Sidebar_module.default.itemWrapper, expanded && Sidebar_module.default.itemExpanded].filter(Boolean).join(" ");
|
|
569
554
|
return /* @__PURE__ */ jsxRuntime.jsx("li", { className: wrapperClasses, children: wrappedItem });
|
|
570
555
|
}
|
|
571
556
|
function SidebarSubItem({
|
|
@@ -665,11 +650,7 @@ function SidebarCollapseToggle({
|
|
|
665
650
|
return null;
|
|
666
651
|
}
|
|
667
652
|
const shouldFloat = collapsed && (collapsible === "icon" && !hasIcons || collapsible === "offcanvas");
|
|
668
|
-
const classes = [
|
|
669
|
-
Sidebar_module.default.collapseToggle,
|
|
670
|
-
shouldFloat && Sidebar_module.default.collapseToggleFloating,
|
|
671
|
-
className
|
|
672
|
-
].filter(Boolean).join(" ");
|
|
653
|
+
const classes = [Sidebar_module.default.collapseToggle, shouldFloat && Sidebar_module.default.collapseToggleFloating, className].filter(Boolean).join(" ");
|
|
673
654
|
const label = ariaLabel || (collapsed ? "Expand sidebar" : "Collapse sidebar");
|
|
674
655
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
675
656
|
"button",
|
|
@@ -694,11 +675,7 @@ function SidebarRail({
|
|
|
694
675
|
if (isMobile || collapsible === "none") {
|
|
695
676
|
return null;
|
|
696
677
|
}
|
|
697
|
-
const classes = [
|
|
698
|
-
Sidebar_module.default.rail,
|
|
699
|
-
collapsed && Sidebar_module.default.railCollapsed,
|
|
700
|
-
className
|
|
701
|
-
].filter(Boolean).join(" ");
|
|
678
|
+
const classes = [Sidebar_module.default.rail, collapsed && Sidebar_module.default.railCollapsed, className].filter(Boolean).join(" ");
|
|
702
679
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
703
680
|
"button",
|
|
704
681
|
{
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import * as React from
|
|
1
|
+
import * as React from "react";
|
|
2
2
|
/** Collapse behavior mode */
|
|
3
|
-
export type SidebarCollapsible =
|
|
3
|
+
export type SidebarCollapsible = "icon" | "offcanvas" | "none";
|
|
4
4
|
export interface SidebarProviderProps {
|
|
5
5
|
children: React.ReactNode;
|
|
6
6
|
/** Icon-only mode (desktop) - controlled */
|
|
@@ -20,7 +20,7 @@ export interface SidebarProviderProps {
|
|
|
20
20
|
/** Width when collapsed */
|
|
21
21
|
collapsedWidth?: string;
|
|
22
22
|
/** Sidebar position */
|
|
23
|
-
position?:
|
|
23
|
+
position?: "left" | "right";
|
|
24
24
|
/** Collapse behavior: 'icon' (default), 'offcanvas', or 'none' */
|
|
25
25
|
collapsible?: SidebarCollapsible;
|
|
26
26
|
/** Enable Cmd/Ctrl+B keyboard shortcut to toggle sidebar */
|
|
@@ -45,14 +45,14 @@ export interface SidebarProps extends React.HTMLAttributes<HTMLElement> {
|
|
|
45
45
|
/** Width when collapsed */
|
|
46
46
|
collapsedWidth?: string;
|
|
47
47
|
/** Sidebar position */
|
|
48
|
-
position?:
|
|
48
|
+
position?: "left" | "right";
|
|
49
49
|
/** Collapse behavior: 'icon' (default), 'offcanvas', or 'none' */
|
|
50
50
|
collapsible?: SidebarCollapsible;
|
|
51
51
|
/**
|
|
52
52
|
* Where the active-item affordance paints. `start` is the default rail;
|
|
53
53
|
* `end` is a trailing status dot for product shells that prefer that language.
|
|
54
54
|
*/
|
|
55
|
-
activeIndicator?:
|
|
55
|
+
activeIndicator?: "start" | "end";
|
|
56
56
|
}
|
|
57
57
|
export interface SidebarHeaderProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
58
58
|
children: React.ReactNode;
|
|
@@ -62,7 +62,7 @@ export interface SidebarHeaderProps extends React.HTMLAttributes<HTMLDivElement>
|
|
|
62
62
|
export interface SidebarNavProps extends React.HTMLAttributes<HTMLElement> {
|
|
63
63
|
children: React.ReactNode;
|
|
64
64
|
/** Accessible label for navigation */
|
|
65
|
-
|
|
65
|
+
"aria-label"?: string;
|
|
66
66
|
}
|
|
67
67
|
export interface SidebarSectionProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
68
68
|
children: React.ReactNode;
|
|
@@ -75,14 +75,14 @@ export interface SidebarSectionProps extends React.HTMLAttributes<HTMLDivElement
|
|
|
75
75
|
/** Default expanded state (only applies when collapsible is true) */
|
|
76
76
|
defaultOpen?: boolean;
|
|
77
77
|
}
|
|
78
|
-
export interface SidebarSectionActionProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>,
|
|
78
|
+
export interface SidebarSectionActionProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, "onClick"> {
|
|
79
79
|
children: React.ReactNode;
|
|
80
80
|
/** Click handler */
|
|
81
81
|
onClick?: React.MouseEventHandler<HTMLButtonElement>;
|
|
82
82
|
/** Accessible label */
|
|
83
|
-
|
|
83
|
+
"aria-label"?: string;
|
|
84
84
|
}
|
|
85
|
-
export interface SidebarItemProps extends Omit<React.HTMLAttributes<HTMLElement>,
|
|
85
|
+
export interface SidebarItemProps extends Omit<React.HTMLAttributes<HTMLElement>, "onClick"> {
|
|
86
86
|
children: React.ReactNode;
|
|
87
87
|
/** Icon element (required for collapsed mode visibility) */
|
|
88
88
|
icon?: React.ReactNode;
|
|
@@ -115,7 +115,7 @@ export interface SidebarItemProps extends Omit<React.HTMLAttributes<HTMLElement>
|
|
|
115
115
|
*/
|
|
116
116
|
asChild?: boolean;
|
|
117
117
|
}
|
|
118
|
-
export interface SidebarSubItemProps extends Omit<React.HTMLAttributes<HTMLElement>,
|
|
118
|
+
export interface SidebarSubItemProps extends Omit<React.HTMLAttributes<HTMLElement>, "onClick"> {
|
|
119
119
|
children: React.ReactNode;
|
|
120
120
|
/** Whether item is currently active/selected */
|
|
121
121
|
active?: boolean;
|
|
@@ -133,12 +133,12 @@ export interface SidebarTriggerProps extends React.ButtonHTMLAttributes<HTMLButt
|
|
|
133
133
|
/** Custom trigger element (uses render prop pattern) */
|
|
134
134
|
children?: React.ReactNode;
|
|
135
135
|
/** Accessible label */
|
|
136
|
-
|
|
136
|
+
"aria-label"?: string;
|
|
137
137
|
}
|
|
138
138
|
export type SidebarOverlayProps = React.HTMLAttributes<HTMLDivElement>;
|
|
139
139
|
export interface SidebarCollapseToggleProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
|
|
140
140
|
/** Accessible label */
|
|
141
|
-
|
|
141
|
+
"aria-label"?: string;
|
|
142
142
|
}
|
|
143
143
|
export type SidebarRailProps = React.ButtonHTMLAttributes<HTMLButtonElement>;
|
|
144
144
|
export interface SidebarMenuSkeletonProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
@@ -153,7 +153,7 @@ interface SidebarContextValue {
|
|
|
153
153
|
open: boolean;
|
|
154
154
|
setOpen: (open: boolean) => void;
|
|
155
155
|
isMobile: boolean;
|
|
156
|
-
position:
|
|
156
|
+
position: "left" | "right";
|
|
157
157
|
width: string;
|
|
158
158
|
collapsedWidth: string;
|
|
159
159
|
collapsible: SidebarCollapsible;
|
|
@@ -189,21 +189,21 @@ declare function useSidebarContext(): SidebarContextValue;
|
|
|
189
189
|
* This enables external triggers and keyboard shortcuts.
|
|
190
190
|
*/
|
|
191
191
|
declare function SidebarProvider({ children, collapsed: controlledCollapsed, defaultCollapsed, onCollapsedChange, open: controlledOpen, defaultOpen, onOpenChange, width, collapsedWidth, position, collapsible, enableKeyboardShortcut, }: SidebarProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
192
|
-
declare function SidebarRoot({ children, collapsed: controlledCollapsed, defaultCollapsed, onCollapsedChange, open: controlledOpen, defaultOpen, onOpenChange, width, collapsedWidth, position, collapsible, activeIndicator, className, style: styleProp,
|
|
192
|
+
declare function SidebarRoot({ children, collapsed: controlledCollapsed, defaultCollapsed, onCollapsedChange, open: controlledOpen, defaultOpen, onOpenChange, width, collapsedWidth, position, collapsible, activeIndicator, className, style: styleProp, "aria-label": ariaLabel, ...htmlProps }: SidebarProps): import("react/jsx-runtime").JSX.Element;
|
|
193
193
|
declare function SidebarHeader({ children, collapsedContent, className, ...htmlProps }: SidebarHeaderProps): import("react/jsx-runtime").JSX.Element;
|
|
194
|
-
declare function SidebarNav({ children,
|
|
194
|
+
declare function SidebarNav({ children, "aria-label": ariaLabel, className, ...htmlProps }: SidebarNavProps): import("react/jsx-runtime").JSX.Element;
|
|
195
195
|
declare function SidebarSection({ children, label, action, collapsible: isCollapsibleProp, defaultOpen, className, ...htmlProps }: SidebarSectionProps): import("react/jsx-runtime").JSX.Element;
|
|
196
|
-
declare function SidebarSectionAction({ children, onClick,
|
|
196
|
+
declare function SidebarSectionAction({ children, onClick, "aria-label": ariaLabel, className, ...htmlProps }: SidebarSectionActionProps): import("react/jsx-runtime").JSX.Element;
|
|
197
197
|
declare function SidebarItem({ children, icon, active, disabled, badge, href, onClick, multiline, hasSubmenu, expanded: controlledExpanded, defaultExpanded, onExpandedChange, asChild, className, ...rest }: SidebarItemProps): import("react/jsx-runtime").JSX.Element;
|
|
198
198
|
declare function SidebarSubItem({ children, active, disabled, href, onClick, className, ...rest }: SidebarSubItemProps): import("react/jsx-runtime").JSX.Element | null;
|
|
199
199
|
declare function SidebarSubmenu({ children }: {
|
|
200
200
|
children: React.ReactNode;
|
|
201
201
|
}): import("react/jsx-runtime").JSX.Element;
|
|
202
202
|
declare function SidebarFooter({ children, className, ...htmlProps }: SidebarFooterProps): import("react/jsx-runtime").JSX.Element;
|
|
203
|
-
declare function SidebarTrigger({ children,
|
|
203
|
+
declare function SidebarTrigger({ children, "aria-label": ariaLabel, className, onClick, ...htmlProps }: SidebarTriggerProps): import("react/jsx-runtime").JSX.Element | null;
|
|
204
204
|
declare function SidebarOverlay({ className, onClick, ...htmlProps }: SidebarOverlayProps): import("react/jsx-runtime").JSX.Element | null;
|
|
205
|
-
declare function SidebarCollapseToggle({
|
|
206
|
-
declare function SidebarRail({ className, onClick, title,
|
|
205
|
+
declare function SidebarCollapseToggle({ "aria-label": ariaLabel, className, onClick, ...htmlProps }: SidebarCollapseToggleProps): import("react/jsx-runtime").JSX.Element | null;
|
|
206
|
+
declare function SidebarRail({ className, onClick, title, "aria-label": ariaLabel, ...htmlProps }: SidebarRailProps): import("react/jsx-runtime").JSX.Element | null;
|
|
207
207
|
declare function SidebarMenuSkeleton({ count, showIcon, className, ...htmlProps }: SidebarMenuSkeletonProps): import("react/jsx-runtime").JSX.Element;
|
|
208
208
|
export declare const Sidebar: typeof SidebarRoot & {
|
|
209
209
|
Header: typeof SidebarHeader;
|