@thalavaisankar/atoms 0.0.0-stage → 0.2.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/LICENSE +24 -0
- package/README.md +196 -2
- package/THIRD_PARTY_NOTICES.md +275 -0
- package/dist/blocks/index.d.mts +2 -0
- package/dist/blocks/index.mjs +1 -0
- package/dist/blocks/index.mjs.map +1 -0
- package/dist/components/ui/accordion/accordion.mjs +194 -0
- package/dist/components/ui/accordion/accordion.mjs.map +1 -0
- package/dist/components/ui/accordion/index.mjs +15 -0
- package/dist/components/ui/accordion/index.mjs.map +1 -0
- package/dist/components/ui/activity-feed/activity-feed.mjs +287 -0
- package/dist/components/ui/activity-feed/activity-feed.mjs.map +1 -0
- package/dist/components/ui/activity-feed/index.mjs +39 -0
- package/dist/components/ui/activity-feed/index.mjs.map +1 -0
- package/dist/components/ui/alert/alert.mjs +128 -0
- package/dist/components/ui/alert/alert.mjs.map +1 -0
- package/dist/components/ui/alert/index.mjs +17 -0
- package/dist/components/ui/alert/index.mjs.map +1 -0
- package/dist/components/ui/animated-label/animated-label.mjs +89 -0
- package/dist/components/ui/animated-label/animated-label.mjs.map +1 -0
- package/dist/components/ui/animated-label/index.mjs +9 -0
- package/dist/components/ui/animated-label/index.mjs.map +1 -0
- package/dist/components/ui/animated-number/animated-number.mjs +101 -0
- package/dist/components/ui/animated-number/animated-number.mjs.map +1 -0
- package/dist/components/ui/animated-number/index.mjs +5 -0
- package/dist/components/ui/animated-number/index.mjs.map +1 -0
- package/dist/components/ui/avatar/avatar.mjs +130 -0
- package/dist/components/ui/avatar/avatar.mjs.map +1 -0
- package/dist/components/ui/avatar/index.mjs +17 -0
- package/dist/components/ui/avatar/index.mjs.map +1 -0
- package/dist/components/ui/avatar-group/avatar-group.mjs +49 -0
- package/dist/components/ui/avatar-group/avatar-group.mjs.map +1 -0
- package/dist/components/ui/avatar-group/index.mjs +5 -0
- package/dist/components/ui/avatar-group/index.mjs.map +1 -0
- package/dist/components/ui/badge/badge-motion.mjs +108 -0
- package/dist/components/ui/badge/badge-motion.mjs.map +1 -0
- package/dist/components/ui/badge/badge.mjs +314 -0
- package/dist/components/ui/badge/badge.mjs.map +1 -0
- package/dist/components/ui/badge/index.mjs +27 -0
- package/dist/components/ui/badge/index.mjs.map +1 -0
- package/dist/components/ui/badge/readable-ink.mjs +36 -0
- package/dist/components/ui/badge/readable-ink.mjs.map +1 -0
- package/dist/components/ui/badge-group/badge-group.mjs +132 -0
- package/dist/components/ui/badge-group/badge-group.mjs.map +1 -0
- package/dist/components/ui/badge-group/index.mjs +5 -0
- package/dist/components/ui/badge-group/index.mjs.map +1 -0
- package/dist/components/ui/breadcrumb/breadcrumb.mjs +108 -0
- package/dist/components/ui/breadcrumb/breadcrumb.mjs.map +1 -0
- package/dist/components/ui/breadcrumb/index.mjs +19 -0
- package/dist/components/ui/breadcrumb/index.mjs.map +1 -0
- package/dist/components/ui/button/button-variants.mjs +80 -0
- package/dist/components/ui/button/button-variants.mjs.map +1 -0
- package/dist/components/ui/button/button.mjs +74 -0
- package/dist/components/ui/button/button.mjs.map +1 -0
- package/dist/components/ui/button/index.mjs +17 -0
- package/dist/components/ui/button/index.mjs.map +1 -0
- package/dist/components/ui/button/social-button.mjs +45 -0
- package/dist/components/ui/button/social-button.mjs.map +1 -0
- package/dist/components/ui/button/social-logos.mjs +179 -0
- package/dist/components/ui/button/social-logos.mjs.map +1 -0
- package/dist/components/ui/button/split-button.mjs +72 -0
- package/dist/components/ui/button/split-button.mjs.map +1 -0
- package/dist/components/ui/button-group/button-group.mjs +58 -0
- package/dist/components/ui/button-group/button-group.mjs.map +1 -0
- package/dist/components/ui/button-group/index.mjs +11 -0
- package/dist/components/ui/button-group/index.mjs.map +1 -0
- package/dist/components/ui/card/card.mjs +131 -0
- package/dist/components/ui/card/card.mjs.map +1 -0
- package/dist/components/ui/card/index.mjs +23 -0
- package/dist/components/ui/card/index.mjs.map +1 -0
- package/dist/components/ui/chart/bar-list.mjs +87 -0
- package/dist/components/ui/chart/bar-list.mjs.map +1 -0
- package/dist/components/ui/chart/chart-colors.mjs +68 -0
- package/dist/components/ui/chart/chart-colors.mjs.map +1 -0
- package/dist/components/ui/chart/chart-geometry.mjs +152 -0
- package/dist/components/ui/chart/chart-geometry.mjs.map +1 -0
- package/dist/components/ui/chart/chart-specialized.mjs +194 -0
- package/dist/components/ui/chart/chart-specialized.mjs.map +1 -0
- package/dist/components/ui/chart/chart.mjs +648 -0
- package/dist/components/ui/chart/chart.mjs.map +1 -0
- package/dist/components/ui/chart/index.mjs +88 -0
- package/dist/components/ui/chart/index.mjs.map +1 -0
- package/dist/components/ui/chart/radial-meter.mjs +142 -0
- package/dist/components/ui/chart/radial-meter.mjs.map +1 -0
- package/dist/components/ui/chart/types.mjs +1 -0
- package/dist/components/ui/chart/types.mjs.map +1 -0
- package/dist/components/ui/checkbox/checkbox.mjs +183 -0
- package/dist/components/ui/checkbox/checkbox.mjs.map +1 -0
- package/dist/components/ui/checkbox/index.mjs +11 -0
- package/dist/components/ui/checkbox/index.mjs.map +1 -0
- package/dist/components/ui/checklist/checklist.mjs +353 -0
- package/dist/components/ui/checklist/checklist.mjs.map +1 -0
- package/dist/components/ui/checklist/index.mjs +33 -0
- package/dist/components/ui/checklist/index.mjs.map +1 -0
- package/dist/components/ui/chip/chip.mjs +202 -0
- package/dist/components/ui/chip/chip.mjs.map +1 -0
- package/dist/components/ui/chip/index.mjs +13 -0
- package/dist/components/ui/chip/index.mjs.map +1 -0
- package/dist/components/ui/chip-group/chip-group.mjs +204 -0
- package/dist/components/ui/chip-group/chip-group.mjs.map +1 -0
- package/dist/components/ui/chip-group/index.mjs +11 -0
- package/dist/components/ui/chip-group/index.mjs.map +1 -0
- package/dist/components/ui/code-snippet/code-highlighter.mjs +16 -0
- package/dist/components/ui/code-snippet/code-highlighter.mjs.map +1 -0
- package/dist/components/ui/code-snippet/code-snippet.mjs +437 -0
- package/dist/components/ui/code-snippet/code-snippet.mjs.map +1 -0
- package/dist/components/ui/code-snippet/index.mjs +17 -0
- package/dist/components/ui/code-snippet/index.mjs.map +1 -0
- package/dist/components/ui/code-snippet/labels.mjs +16 -0
- package/dist/components/ui/code-snippet/labels.mjs.map +1 -0
- package/dist/components/ui/code-snippet/tokenize.mjs +715 -0
- package/dist/components/ui/code-snippet/tokenize.mjs.map +1 -0
- package/dist/components/ui/code-snippet/types.mjs +1 -0
- package/dist/components/ui/code-snippet/types.mjs.map +1 -0
- package/dist/components/ui/collapsible/collapsible.mjs +85 -0
- package/dist/components/ui/collapsible/collapsible.mjs.map +1 -0
- package/dist/components/ui/collapsible/index.mjs +15 -0
- package/dist/components/ui/collapsible/index.mjs.map +1 -0
- package/dist/components/ui/color-picker/color-picker.mjs +852 -0
- package/dist/components/ui/color-picker/color-picker.mjs.map +1 -0
- package/dist/components/ui/color-picker/index.mjs +47 -0
- package/dist/components/ui/color-picker/index.mjs.map +1 -0
- package/dist/components/ui/combobox/combobox.mjs +745 -0
- package/dist/components/ui/combobox/combobox.mjs.map +1 -0
- package/dist/components/ui/combobox/index.mjs +27 -0
- package/dist/components/ui/combobox/index.mjs.map +1 -0
- package/dist/components/ui/command/command.mjs +439 -0
- package/dist/components/ui/command/command.mjs.map +1 -0
- package/dist/components/ui/command/index.mjs +31 -0
- package/dist/components/ui/command/index.mjs.map +1 -0
- package/dist/components/ui/compare-slider/compare-slider.mjs +335 -0
- package/dist/components/ui/compare-slider/compare-slider.mjs.map +1 -0
- package/dist/components/ui/compare-slider/index.mjs +17 -0
- package/dist/components/ui/compare-slider/index.mjs.map +1 -0
- package/dist/components/ui/context-menu/context-menu.mjs +184 -0
- package/dist/components/ui/context-menu/context-menu.mjs.map +1 -0
- package/dist/components/ui/context-menu/index.mjs +37 -0
- package/dist/components/ui/context-menu/index.mjs.map +1 -0
- package/dist/components/ui/data-table/active-filters.mjs +69 -0
- package/dist/components/ui/data-table/active-filters.mjs.map +1 -0
- package/dist/components/ui/data-table/body-row.mjs +118 -0
- package/dist/components/ui/data-table/body-row.mjs.map +1 -0
- package/dist/components/ui/data-table/cards.mjs +76 -0
- package/dist/components/ui/data-table/cards.mjs.map +1 -0
- package/dist/components/ui/data-table/data-table.mjs +680 -0
- package/dist/components/ui/data-table/data-table.mjs.map +1 -0
- package/dist/components/ui/data-table/empty.mjs +26 -0
- package/dist/components/ui/data-table/empty.mjs.map +1 -0
- package/dist/components/ui/data-table/expand.mjs +70 -0
- package/dist/components/ui/data-table/expand.mjs.map +1 -0
- package/dist/components/ui/data-table/faceted-filter.mjs +112 -0
- package/dist/components/ui/data-table/faceted-filter.mjs.map +1 -0
- package/dist/components/ui/data-table/features.mjs +96 -0
- package/dist/components/ui/data-table/features.mjs.map +1 -0
- package/dist/components/ui/data-table/grip.mjs +37 -0
- package/dist/components/ui/data-table/grip.mjs.map +1 -0
- package/dist/components/ui/data-table/header-cell.mjs +85 -0
- package/dist/components/ui/data-table/header-cell.mjs.map +1 -0
- package/dist/components/ui/data-table/index.mjs +55 -0
- package/dist/components/ui/data-table/index.mjs.map +1 -0
- package/dist/components/ui/data-table/labels.mjs +55 -0
- package/dist/components/ui/data-table/labels.mjs.map +1 -0
- package/dist/components/ui/data-table/load-more.mjs +56 -0
- package/dist/components/ui/data-table/load-more.mjs.map +1 -0
- package/dist/components/ui/data-table/move-item.mjs +11 -0
- package/dist/components/ui/data-table/move-item.mjs.map +1 -0
- package/dist/components/ui/data-table/persist.mjs +65 -0
- package/dist/components/ui/data-table/persist.mjs.map +1 -0
- package/dist/components/ui/data-table/selection-bar.mjs +51 -0
- package/dist/components/ui/data-table/selection-bar.mjs.map +1 -0
- package/dist/components/ui/data-table/tabs.mjs +48 -0
- package/dist/components/ui/data-table/tabs.mjs.map +1 -0
- package/dist/components/ui/data-table/toolbar.mjs +92 -0
- package/dist/components/ui/data-table/toolbar.mjs.map +1 -0
- package/dist/components/ui/data-table/use-reorder.mjs +239 -0
- package/dist/components/ui/data-table/use-reorder.mjs.map +1 -0
- package/dist/components/ui/data-table/use-reveal.mjs +24 -0
- package/dist/components/ui/data-table/use-reveal.mjs.map +1 -0
- package/dist/components/ui/data-table/use-table-state.mjs +38 -0
- package/dist/components/ui/data-table/use-table-state.mjs.map +1 -0
- package/dist/components/ui/data-table/view-options.mjs +66 -0
- package/dist/components/ui/data-table/view-options.mjs.map +1 -0
- package/dist/components/ui/date-picker/calendar.mjs +466 -0
- package/dist/components/ui/date-picker/calendar.mjs.map +1 -0
- package/dist/components/ui/date-picker/date-picker.mjs +366 -0
- package/dist/components/ui/date-picker/date-picker.mjs.map +1 -0
- package/dist/components/ui/date-picker/index.mjs +17 -0
- package/dist/components/ui/date-picker/index.mjs.map +1 -0
- package/dist/components/ui/date-picker/presets.mjs +49 -0
- package/dist/components/ui/date-picker/presets.mjs.map +1 -0
- package/dist/components/ui/description-list/description-list.mjs +40 -0
- package/dist/components/ui/description-list/description-list.mjs.map +1 -0
- package/dist/components/ui/description-list/index.mjs +15 -0
- package/dist/components/ui/description-list/index.mjs.map +1 -0
- package/dist/components/ui/dialog/dialog-stepper.mjs +23 -0
- package/dist/components/ui/dialog/dialog-stepper.mjs.map +1 -0
- package/dist/components/ui/dialog/dialog.mjs +343 -0
- package/dist/components/ui/dialog/dialog.mjs.map +1 -0
- package/dist/components/ui/dialog/focus-return.mjs +21 -0
- package/dist/components/ui/dialog/focus-return.mjs.map +1 -0
- package/dist/components/ui/dialog/index.mjs +33 -0
- package/dist/components/ui/dialog/index.mjs.map +1 -0
- package/dist/components/ui/divider/divider.mjs +130 -0
- package/dist/components/ui/divider/divider.mjs.map +1 -0
- package/dist/components/ui/divider/index.mjs +6 -0
- package/dist/components/ui/divider/index.mjs.map +1 -0
- package/dist/components/ui/dock/dock.mjs +444 -0
- package/dist/components/ui/dock/dock.mjs.map +1 -0
- package/dist/components/ui/dock/index.mjs +19 -0
- package/dist/components/ui/dock/index.mjs.map +1 -0
- package/dist/components/ui/document-editor/block-actions.mjs +118 -0
- package/dist/components/ui/document-editor/block-actions.mjs.map +1 -0
- package/dist/components/ui/document-editor/block-commands.mjs +182 -0
- package/dist/components/ui/document-editor/block-commands.mjs.map +1 -0
- package/dist/components/ui/document-editor/block-handle.mjs +387 -0
- package/dist/components/ui/document-editor/block-handle.mjs.map +1 -0
- package/dist/components/ui/document-editor/block-morph.mjs +95 -0
- package/dist/components/ui/document-editor/block-morph.mjs.map +1 -0
- package/dist/components/ui/document-editor/block-selection.mjs +81 -0
- package/dist/components/ui/document-editor/block-selection.mjs.map +1 -0
- package/dist/components/ui/document-editor/blocks.mjs +30 -0
- package/dist/components/ui/document-editor/blocks.mjs.map +1 -0
- package/dist/components/ui/document-editor/bubble-menu.mjs +120 -0
- package/dist/components/ui/document-editor/bubble-menu.mjs.map +1 -0
- package/dist/components/ui/document-editor/code-block.mjs +89 -0
- package/dist/components/ui/document-editor/code-block.mjs.map +1 -0
- package/dist/components/ui/document-editor/collaboration-types.mjs +9 -0
- package/dist/components/ui/document-editor/collaboration-types.mjs.map +1 -0
- package/dist/components/ui/document-editor/collaboration.mjs +198 -0
- package/dist/components/ui/document-editor/collaboration.mjs.map +1 -0
- package/dist/components/ui/document-editor/columns.mjs +52 -0
- package/dist/components/ui/document-editor/columns.mjs.map +1 -0
- package/dist/components/ui/document-editor/contents.mjs +60 -0
- package/dist/components/ui/document-editor/contents.mjs.map +1 -0
- package/dist/components/ui/document-editor/date-chip.mjs +115 -0
- package/dist/components/ui/document-editor/date-chip.mjs.map +1 -0
- package/dist/components/ui/document-editor/date-words.mjs +101 -0
- package/dist/components/ui/document-editor/date-words.mjs.map +1 -0
- package/dist/components/ui/document-editor/doc-labels.mjs +19 -0
- package/dist/components/ui/document-editor/doc-labels.mjs.map +1 -0
- package/dist/components/ui/document-editor/document-editor.mjs +496 -0
- package/dist/components/ui/document-editor/document-editor.mjs.map +1 -0
- package/dist/components/ui/document-editor/emoji-suggest.mjs +81 -0
- package/dist/components/ui/document-editor/emoji-suggest.mjs.map +1 -0
- package/dist/components/ui/document-editor/focus-mode.mjs +32 -0
- package/dist/components/ui/document-editor/focus-mode.mjs.map +1 -0
- package/dist/components/ui/document-editor/geometry.mjs +35 -0
- package/dist/components/ui/document-editor/geometry.mjs.map +1 -0
- package/dist/components/ui/document-editor/ghost-text.mjs +154 -0
- package/dist/components/ui/document-editor/ghost-text.mjs.map +1 -0
- package/dist/components/ui/document-editor/gliding-caret.mjs +118 -0
- package/dist/components/ui/document-editor/gliding-caret.mjs.map +1 -0
- package/dist/components/ui/document-editor/headings.mjs +64 -0
- package/dist/components/ui/document-editor/headings.mjs.map +1 -0
- package/dist/components/ui/document-editor/image.mjs +318 -0
- package/dist/components/ui/document-editor/image.mjs.map +1 -0
- package/dist/components/ui/document-editor/index.mjs +131 -0
- package/dist/components/ui/document-editor/index.mjs.map +1 -0
- package/dist/components/ui/document-editor/labels.mjs +96 -0
- package/dist/components/ui/document-editor/labels.mjs.map +1 -0
- package/dist/components/ui/document-editor/link-card.mjs +138 -0
- package/dist/components/ui/document-editor/link-card.mjs.map +1 -0
- package/dist/components/ui/document-editor/mentions.mjs +105 -0
- package/dist/components/ui/document-editor/mentions.mjs.map +1 -0
- package/dist/components/ui/document-editor/outline.mjs +138 -0
- package/dist/components/ui/document-editor/outline.mjs.map +1 -0
- package/dist/components/ui/document-editor/section-fold.mjs +124 -0
- package/dist/components/ui/document-editor/section-fold.mjs.map +1 -0
- package/dist/components/ui/document-editor/slash-command.mjs +210 -0
- package/dist/components/ui/document-editor/slash-command.mjs.map +1 -0
- package/dist/components/ui/document-editor/suggest-list.mjs +187 -0
- package/dist/components/ui/document-editor/suggest-list.mjs.map +1 -0
- package/dist/components/ui/document-editor/table.mjs +242 -0
- package/dist/components/ui/document-editor/table.mjs.map +1 -0
- package/dist/components/ui/document-editor/templates.mjs +66 -0
- package/dist/components/ui/document-editor/templates.mjs.map +1 -0
- package/dist/components/ui/document-editor/toggle.mjs +176 -0
- package/dist/components/ui/document-editor/toggle.mjs.map +1 -0
- package/dist/components/ui/document-editor/typography-rules.mjs +8 -0
- package/dist/components/ui/document-editor/typography-rules.mjs.map +1 -0
- package/dist/components/ui/document-editor/use-editor-value.mjs +34 -0
- package/dist/components/ui/document-editor/use-editor-value.mjs.map +1 -0
- package/dist/components/ui/drawer/drawer-nav.mjs +153 -0
- package/dist/components/ui/drawer/drawer-nav.mjs.map +1 -0
- package/dist/components/ui/drawer/drawer.mjs +334 -0
- package/dist/components/ui/drawer/drawer.mjs.map +1 -0
- package/dist/components/ui/drawer/index.mjs +37 -0
- package/dist/components/ui/drawer/index.mjs.map +1 -0
- package/dist/components/ui/drawer/use-swipe-to-close.mjs +77 -0
- package/dist/components/ui/drawer/use-swipe-to-close.mjs.map +1 -0
- package/dist/components/ui/dropdown-menu/dropdown-menu.mjs +567 -0
- package/dist/components/ui/dropdown-menu/dropdown-menu.mjs.map +1 -0
- package/dist/components/ui/dropdown-menu/index.mjs +43 -0
- package/dist/components/ui/dropdown-menu/index.mjs.map +1 -0
- package/dist/components/ui/editable-text/editable-text.mjs +148 -0
- package/dist/components/ui/editable-text/editable-text.mjs.map +1 -0
- package/dist/components/ui/editable-text/index.mjs +6 -0
- package/dist/components/ui/editable-text/index.mjs.map +1 -0
- package/dist/components/ui/emoji-picker/emoji-data.mjs +469 -0
- package/dist/components/ui/emoji-picker/emoji-data.mjs.map +1 -0
- package/dist/components/ui/emoji-picker/emoji-picker.mjs +464 -0
- package/dist/components/ui/emoji-picker/emoji-picker.mjs.map +1 -0
- package/dist/components/ui/emoji-picker/index.mjs +19 -0
- package/dist/components/ui/emoji-picker/index.mjs.map +1 -0
- package/dist/components/ui/empty-state/empty-state.mjs +110 -0
- package/dist/components/ui/empty-state/empty-state.mjs.map +1 -0
- package/dist/components/ui/empty-state/index.mjs +17 -0
- package/dist/components/ui/empty-state/index.mjs.map +1 -0
- package/dist/components/ui/event-calendar/calendar-math.mjs +256 -0
- package/dist/components/ui/event-calendar/calendar-math.mjs.map +1 -0
- package/dist/components/ui/event-calendar/context.mjs +51 -0
- package/dist/components/ui/event-calendar/context.mjs.map +1 -0
- package/dist/components/ui/event-calendar/editor.mjs +292 -0
- package/dist/components/ui/event-calendar/editor.mjs.map +1 -0
- package/dist/components/ui/event-calendar/event-block.mjs +55 -0
- package/dist/components/ui/event-calendar/event-block.mjs.map +1 -0
- package/dist/components/ui/event-calendar/event-calendar.mjs +438 -0
- package/dist/components/ui/event-calendar/event-calendar.mjs.map +1 -0
- package/dist/components/ui/event-calendar/event-keys.mjs +41 -0
- package/dist/components/ui/event-calendar/event-keys.mjs.map +1 -0
- package/dist/components/ui/event-calendar/index.mjs +37 -0
- package/dist/components/ui/event-calendar/index.mjs.map +1 -0
- package/dist/components/ui/event-calendar/month-grid.mjs +207 -0
- package/dist/components/ui/event-calendar/month-grid.mjs.map +1 -0
- package/dist/components/ui/event-calendar/narrow.mjs +193 -0
- package/dist/components/ui/event-calendar/narrow.mjs.map +1 -0
- package/dist/components/ui/event-calendar/time-grid.mjs +534 -0
- package/dist/components/ui/event-calendar/time-grid.mjs.map +1 -0
- package/dist/components/ui/expandable-search/expandable-search.mjs +174 -0
- package/dist/components/ui/expandable-search/expandable-search.mjs.map +1 -0
- package/dist/components/ui/expandable-search/index.mjs +6 -0
- package/dist/components/ui/expandable-search/index.mjs.map +1 -0
- package/dist/components/ui/field/field.mjs +444 -0
- package/dist/components/ui/field/field.mjs.map +1 -0
- package/dist/components/ui/field/index.mjs +21 -0
- package/dist/components/ui/field/index.mjs.map +1 -0
- package/dist/components/ui/file-card/file-card.mjs +198 -0
- package/dist/components/ui/file-card/file-card.mjs.map +1 -0
- package/dist/components/ui/file-card/file-icon.mjs +66 -0
- package/dist/components/ui/file-card/file-icon.mjs.map +1 -0
- package/dist/components/ui/file-card/file-types.mjs +70 -0
- package/dist/components/ui/file-card/file-types.mjs.map +1 -0
- package/dist/components/ui/file-card/index.mjs +32 -0
- package/dist/components/ui/file-card/index.mjs.map +1 -0
- package/dist/components/ui/file-preview/context.mjs +77 -0
- package/dist/components/ui/file-preview/context.mjs.map +1 -0
- package/dist/components/ui/file-preview/file-preview.mjs +865 -0
- package/dist/components/ui/file-preview/file-preview.mjs.map +1 -0
- package/dist/components/ui/file-preview/index.mjs +56 -0
- package/dist/components/ui/file-preview/index.mjs.map +1 -0
- package/dist/components/ui/file-preview/pdf.mjs +250 -0
- package/dist/components/ui/file-preview/pdf.mjs.map +1 -0
- package/dist/components/ui/file-preview/renderers.mjs +257 -0
- package/dist/components/ui/file-preview/renderers.mjs.map +1 -0
- package/dist/components/ui/file-upload/file-upload.mjs +633 -0
- package/dist/components/ui/file-upload/file-upload.mjs.map +1 -0
- package/dist/components/ui/file-upload/index.mjs +42 -0
- package/dist/components/ui/file-upload/index.mjs.map +1 -0
- package/dist/components/ui/file-upload/validate.mjs +111 -0
- package/dist/components/ui/file-upload/validate.mjs.map +1 -0
- package/dist/components/ui/flag/flag.mjs +39 -0
- package/dist/components/ui/flag/flag.mjs.map +1 -0
- package/dist/components/ui/flag/index.mjs +7 -0
- package/dist/components/ui/flag/index.mjs.map +1 -0
- package/dist/components/ui/floating-window/floating-window.mjs +255 -0
- package/dist/components/ui/floating-window/floating-window.mjs.map +1 -0
- package/dist/components/ui/floating-window/index.mjs +11 -0
- package/dist/components/ui/floating-window/index.mjs.map +1 -0
- package/dist/components/ui/form/form-section.mjs +87 -0
- package/dist/components/ui/form/form-section.mjs.map +1 -0
- package/dist/components/ui/form/form.mjs +205 -0
- package/dist/components/ui/form/form.mjs.map +1 -0
- package/dist/components/ui/form/index.mjs +29 -0
- package/dist/components/ui/form/index.mjs.map +1 -0
- package/dist/components/ui/globe/globe-data.mjs +9 -0
- package/dist/components/ui/globe/globe-data.mjs.map +1 -0
- package/dist/components/ui/globe/globe-math.mjs +269 -0
- package/dist/components/ui/globe/globe-math.mjs.map +1 -0
- package/dist/components/ui/globe/globe.mjs +719 -0
- package/dist/components/ui/globe/globe.mjs.map +1 -0
- package/dist/components/ui/globe/index.mjs +13 -0
- package/dist/components/ui/globe/index.mjs.map +1 -0
- package/dist/components/ui/highlight-match/highlight-children.mjs +13 -0
- package/dist/components/ui/highlight-match/highlight-children.mjs.map +1 -0
- package/dist/components/ui/highlight-match/highlight-match-variants.mjs +17 -0
- package/dist/components/ui/highlight-match/highlight-match-variants.mjs.map +1 -0
- package/dist/components/ui/highlight-match/highlight-match.mjs +37 -0
- package/dist/components/ui/highlight-match/highlight-match.mjs.map +1 -0
- package/dist/components/ui/highlight-match/index.mjs +15 -0
- package/dist/components/ui/highlight-match/index.mjs.map +1 -0
- package/dist/components/ui/highlight-match/match-ranges.mjs +50 -0
- package/dist/components/ui/highlight-match/match-ranges.mjs.map +1 -0
- package/dist/components/ui/histogram-slider/histogram-slider.mjs +83 -0
- package/dist/components/ui/histogram-slider/histogram-slider.mjs.map +1 -0
- package/dist/components/ui/histogram-slider/index.mjs +6 -0
- package/dist/components/ui/histogram-slider/index.mjs.map +1 -0
- package/dist/components/ui/hold-button/hold-button.mjs +258 -0
- package/dist/components/ui/hold-button/hold-button.mjs.map +1 -0
- package/dist/components/ui/hold-button/index.mjs +6 -0
- package/dist/components/ui/hold-button/index.mjs.map +1 -0
- package/dist/components/ui/hover-card/hover-card.mjs +111 -0
- package/dist/components/ui/hover-card/hover-card.mjs.map +1 -0
- package/dist/components/ui/hover-card/index.mjs +21 -0
- package/dist/components/ui/hover-card/index.mjs.map +1 -0
- package/dist/components/ui/ink-tray/index.mjs +29 -0
- package/dist/components/ui/ink-tray/index.mjs.map +1 -0
- package/dist/components/ui/ink-tray/ink-tray-art.mjs +68 -0
- package/dist/components/ui/ink-tray/ink-tray-art.mjs.map +1 -0
- package/dist/components/ui/ink-tray/ink-tray.mjs +350 -0
- package/dist/components/ui/ink-tray/ink-tray.mjs.map +1 -0
- package/dist/components/ui/input/index.mjs +41 -0
- package/dist/components/ui/input/index.mjs.map +1 -0
- package/dist/components/ui/input/input.mjs +268 -0
- package/dist/components/ui/input/input.mjs.map +1 -0
- package/dist/components/ui/input/number-input.mjs +272 -0
- package/dist/components/ui/input/number-input.mjs.map +1 -0
- package/dist/components/ui/input/password-input.mjs +49 -0
- package/dist/components/ui/input/password-input.mjs.map +1 -0
- package/dist/components/ui/input/phone-input-countries.mjs +216 -0
- package/dist/components/ui/input/phone-input-countries.mjs.map +1 -0
- package/dist/components/ui/input/phone-input.mjs +326 -0
- package/dist/components/ui/input/phone-input.mjs.map +1 -0
- package/dist/components/ui/input/use-controllable-state.mjs +24 -0
- package/dist/components/ui/input/use-controllable-state.mjs.map +1 -0
- package/dist/components/ui/input/use-hold-repeat.mjs +35 -0
- package/dist/components/ui/input/use-hold-repeat.mjs.map +1 -0
- package/dist/components/ui/input-group/index.mjs +11 -0
- package/dist/components/ui/input-group/index.mjs.map +1 -0
- package/dist/components/ui/input-group/input-group.mjs +78 -0
- package/dist/components/ui/input-group/input-group.mjs.map +1 -0
- package/dist/components/ui/island/index.mjs +23 -0
- package/dist/components/ui/island/index.mjs.map +1 -0
- package/dist/components/ui/island/island.mjs +328 -0
- package/dist/components/ui/island/island.mjs.map +1 -0
- package/dist/components/ui/kbd/index.mjs +6 -0
- package/dist/components/ui/kbd/index.mjs.map +1 -0
- package/dist/components/ui/kbd/kbd.mjs +73 -0
- package/dist/components/ui/kbd/kbd.mjs.map +1 -0
- package/dist/components/ui/keypad/index.mjs +23 -0
- package/dist/components/ui/keypad/index.mjs.map +1 -0
- package/dist/components/ui/keypad/keypad.mjs +345 -0
- package/dist/components/ui/keypad/keypad.mjs.map +1 -0
- package/dist/components/ui/label/index.mjs +7 -0
- package/dist/components/ui/label/index.mjs.map +1 -0
- package/dist/components/ui/label/label.mjs +117 -0
- package/dist/components/ui/label/label.mjs.map +1 -0
- package/dist/components/ui/lightbox/index.mjs +47 -0
- package/dist/components/ui/lightbox/index.mjs.map +1 -0
- package/dist/components/ui/lightbox/labels.mjs +23 -0
- package/dist/components/ui/lightbox/labels.mjs.map +1 -0
- package/dist/components/ui/lightbox/lightbox.mjs +1359 -0
- package/dist/components/ui/lightbox/lightbox.mjs.map +1 -0
- package/dist/components/ui/link/index.mjs +6 -0
- package/dist/components/ui/link/index.mjs.map +1 -0
- package/dist/components/ui/link/link.mjs +64 -0
- package/dist/components/ui/link/link.mjs.map +1 -0
- package/dist/components/ui/list/index.mjs +35 -0
- package/dist/components/ui/list/index.mjs.map +1 -0
- package/dist/components/ui/list/list.mjs +505 -0
- package/dist/components/ui/list/list.mjs.map +1 -0
- package/dist/components/ui/load-more/index.mjs +23 -0
- package/dist/components/ui/load-more/index.mjs.map +1 -0
- package/dist/components/ui/load-more/load-more.mjs +409 -0
- package/dist/components/ui/load-more/load-more.mjs.map +1 -0
- package/dist/components/ui/map/index.mjs +27 -0
- package/dist/components/ui/map/index.mjs.map +1 -0
- package/dist/components/ui/map/map-style.mjs +169 -0
- package/dist/components/ui/map/map-style.mjs.map +1 -0
- package/dist/components/ui/map/map.mjs +624 -0
- package/dist/components/ui/map/map.mjs.map +1 -0
- package/dist/components/ui/map-pin/index.mjs +6 -0
- package/dist/components/ui/map-pin/index.mjs.map +1 -0
- package/dist/components/ui/map-pin/map-pin.mjs +55 -0
- package/dist/components/ui/map-pin/map-pin.mjs.map +1 -0
- package/dist/components/ui/mention/index.mjs +29 -0
- package/dist/components/ui/mention/index.mjs.map +1 -0
- package/dist/components/ui/mention/mention.mjs +262 -0
- package/dist/components/ui/mention/mention.mjs.map +1 -0
- package/dist/components/ui/mention/split-mentions.mjs +24 -0
- package/dist/components/ui/mention/split-mentions.mjs.map +1 -0
- package/dist/components/ui/menubar/index.mjs +39 -0
- package/dist/components/ui/menubar/index.mjs.map +1 -0
- package/dist/components/ui/menubar/menubar.mjs +222 -0
- package/dist/components/ui/menubar/menubar.mjs.map +1 -0
- package/dist/components/ui/meter/index.mjs +21 -0
- package/dist/components/ui/meter/index.mjs.map +1 -0
- package/dist/components/ui/meter/meter.mjs +167 -0
- package/dist/components/ui/meter/meter.mjs.map +1 -0
- package/dist/components/ui/multi-select/index.mjs +25 -0
- package/dist/components/ui/multi-select/index.mjs.map +1 -0
- package/dist/components/ui/multi-select/multi-select.mjs +285 -0
- package/dist/components/ui/multi-select/multi-select.mjs.map +1 -0
- package/dist/components/ui/navigation-menu/index.mjs +41 -0
- package/dist/components/ui/navigation-menu/index.mjs.map +1 -0
- package/dist/components/ui/navigation-menu/navigation-menu.mjs +396 -0
- package/dist/components/ui/navigation-menu/navigation-menu.mjs.map +1 -0
- package/dist/components/ui/notebook-page/index.mjs +15 -0
- package/dist/components/ui/notebook-page/index.mjs.map +1 -0
- package/dist/components/ui/notebook-page/notebook-page.mjs +162 -0
- package/dist/components/ui/notebook-page/notebook-page.mjs.map +1 -0
- package/dist/components/ui/notification-inbox/index.mjs +47 -0
- package/dist/components/ui/notification-inbox/index.mjs.map +1 -0
- package/dist/components/ui/notification-inbox/notification-inbox.mjs +422 -0
- package/dist/components/ui/notification-inbox/notification-inbox.mjs.map +1 -0
- package/dist/components/ui/number-field/index.mjs +24 -0
- package/dist/components/ui/number-field/index.mjs.map +1 -0
- package/dist/components/ui/number-field/number-field.mjs +460 -0
- package/dist/components/ui/number-field/number-field.mjs.map +1 -0
- package/dist/components/ui/number-field/number-format.mjs +48 -0
- package/dist/components/ui/number-field/number-format.mjs.map +1 -0
- package/dist/components/ui/otp-input/index.mjs +9 -0
- package/dist/components/ui/otp-input/index.mjs.map +1 -0
- package/dist/components/ui/otp-input/otp-input.mjs +285 -0
- package/dist/components/ui/otp-input/otp-input.mjs.map +1 -0
- package/dist/components/ui/pager/index.mjs +7 -0
- package/dist/components/ui/pager/index.mjs.map +1 -0
- package/dist/components/ui/pager/pager.mjs +86 -0
- package/dist/components/ui/pager/pager.mjs.map +1 -0
- package/dist/components/ui/pagination/index.mjs +23 -0
- package/dist/components/ui/pagination/index.mjs.map +1 -0
- package/dist/components/ui/pagination/pagination.mjs +210 -0
- package/dist/components/ui/pagination/pagination.mjs.map +1 -0
- package/dist/components/ui/password-strength/index.mjs +21 -0
- package/dist/components/ui/password-strength/index.mjs.map +1 -0
- package/dist/components/ui/password-strength/password-rules.mjs +25 -0
- package/dist/components/ui/password-strength/password-rules.mjs.map +1 -0
- package/dist/components/ui/password-strength/password-strength.mjs +125 -0
- package/dist/components/ui/password-strength/password-strength.mjs.map +1 -0
- package/dist/components/ui/popover/index.mjs +31 -0
- package/dist/components/ui/popover/index.mjs.map +1 -0
- package/dist/components/ui/popover/popover.mjs +574 -0
- package/dist/components/ui/popover/popover.mjs.map +1 -0
- package/dist/components/ui/progress/index.mjs +15 -0
- package/dist/components/ui/progress/index.mjs.map +1 -0
- package/dist/components/ui/progress/progress.mjs +224 -0
- package/dist/components/ui/progress/progress.mjs.map +1 -0
- package/dist/components/ui/prose/index.mjs +6 -0
- package/dist/components/ui/prose/index.mjs.map +1 -0
- package/dist/components/ui/prose/prose.mjs +89 -0
- package/dist/components/ui/prose/prose.mjs.map +1 -0
- package/dist/components/ui/radio-group/index.mjs +15 -0
- package/dist/components/ui/radio-group/index.mjs.map +1 -0
- package/dist/components/ui/radio-group/radio-group.mjs +88 -0
- package/dist/components/ui/radio-group/radio-group.mjs.map +1 -0
- package/dist/components/ui/rating/index.mjs +6 -0
- package/dist/components/ui/rating/index.mjs.map +1 -0
- package/dist/components/ui/rating/rating.mjs +119 -0
- package/dist/components/ui/rating/rating.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/bubble-menu.mjs +120 -0
- package/dist/components/ui/rich-text-editor/bubble-menu.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/image-links.mjs +63 -0
- package/dist/components/ui/rich-text-editor/image-links.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/index.mjs +37 -0
- package/dist/components/ui/rich-text-editor/index.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/labels.mjs +27 -0
- package/dist/components/ui/rich-text-editor/labels.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/rich-text-editor.mjs +149 -0
- package/dist/components/ui/rich-text-editor/rich-text-editor.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/toolbar.mjs +325 -0
- package/dist/components/ui/rich-text-editor/toolbar.mjs.map +1 -0
- package/dist/components/ui/save-bar/index.mjs +13 -0
- package/dist/components/ui/save-bar/index.mjs.map +1 -0
- package/dist/components/ui/save-bar/save-bar.mjs +59 -0
- package/dist/components/ui/save-bar/save-bar.mjs.map +1 -0
- package/dist/components/ui/scroll-area/index.mjs +6 -0
- package/dist/components/ui/scroll-area/index.mjs.map +1 -0
- package/dist/components/ui/scroll-area/scroll-area.mjs +148 -0
- package/dist/components/ui/scroll-area/scroll-area.mjs.map +1 -0
- package/dist/components/ui/scroll-area/use-drag-scroll.mjs +134 -0
- package/dist/components/ui/scroll-area/use-drag-scroll.mjs.map +1 -0
- package/dist/components/ui/select/index.mjs +23 -0
- package/dist/components/ui/select/index.mjs.map +1 -0
- package/dist/components/ui/select/select.mjs +216 -0
- package/dist/components/ui/select/select.mjs.map +1 -0
- package/dist/components/ui/sheet/index.mjs +23 -0
- package/dist/components/ui/sheet/index.mjs.map +1 -0
- package/dist/components/ui/sheet/sheet.mjs +292 -0
- package/dist/components/ui/sheet/sheet.mjs.map +1 -0
- package/dist/components/ui/sidebar/index.mjs +122 -0
- package/dist/components/ui/sidebar/index.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-group.mjs +75 -0
- package/dist/components/ui/sidebar/sidebar-group.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-item.mjs +199 -0
- package/dist/components/ui/sidebar/sidebar-item.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-panels.mjs +182 -0
- package/dist/components/ui/sidebar/sidebar-panels.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-peek.mjs +324 -0
- package/dist/components/ui/sidebar/sidebar-peek.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-rich.mjs +65 -0
- package/dist/components/ui/sidebar/sidebar-rich.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-tree.mjs +224 -0
- package/dist/components/ui/sidebar/sidebar-tree.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar.mjs +205 -0
- package/dist/components/ui/sidebar/sidebar.mjs.map +1 -0
- package/dist/components/ui/sidebar/variants.mjs +396 -0
- package/dist/components/ui/sidebar/variants.mjs.map +1 -0
- package/dist/components/ui/signature/index.mjs +6 -0
- package/dist/components/ui/signature/index.mjs.map +1 -0
- package/dist/components/ui/signature/signature.mjs +145 -0
- package/dist/components/ui/signature/signature.mjs.map +1 -0
- package/dist/components/ui/signature-pad/index.mjs +19 -0
- package/dist/components/ui/signature-pad/index.mjs.map +1 -0
- package/dist/components/ui/signature-pad/signature-pad.mjs +210 -0
- package/dist/components/ui/signature-pad/signature-pad.mjs.map +1 -0
- package/dist/components/ui/signature-pad/strokes.mjs +68 -0
- package/dist/components/ui/signature-pad/strokes.mjs.map +1 -0
- package/dist/components/ui/skeleton/index.mjs +9 -0
- package/dist/components/ui/skeleton/index.mjs.map +1 -0
- package/dist/components/ui/skeleton/skeleton.mjs +58 -0
- package/dist/components/ui/skeleton/skeleton.mjs.map +1 -0
- package/dist/components/ui/slide/index.mjs +25 -0
- package/dist/components/ui/slide/index.mjs.map +1 -0
- package/dist/components/ui/slide/slide.mjs +159 -0
- package/dist/components/ui/slide/slide.mjs.map +1 -0
- package/dist/components/ui/slider/index.mjs +21 -0
- package/dist/components/ui/slider/index.mjs.map +1 -0
- package/dist/components/ui/slider/slider-input.mjs +449 -0
- package/dist/components/ui/slider/slider-input.mjs.map +1 -0
- package/dist/components/ui/slider/slider.mjs +235 -0
- package/dist/components/ui/slider/slider.mjs.map +1 -0
- package/dist/components/ui/slides/index.mjs +31 -0
- package/dist/components/ui/slides/index.mjs.map +1 -0
- package/dist/components/ui/slides/slides.mjs +890 -0
- package/dist/components/ui/slides/slides.mjs.map +1 -0
- package/dist/components/ui/smooth-anchors/index.mjs +17 -0
- package/dist/components/ui/smooth-anchors/index.mjs.map +1 -0
- package/dist/components/ui/smooth-anchors/smooth-anchors.mjs +75 -0
- package/dist/components/ui/smooth-anchors/smooth-anchors.mjs.map +1 -0
- package/dist/components/ui/smooth-anchors/smooth-scroll.mjs +87 -0
- package/dist/components/ui/smooth-anchors/smooth-scroll.mjs.map +1 -0
- package/dist/components/ui/spinner/index.mjs +6 -0
- package/dist/components/ui/spinner/index.mjs.map +1 -0
- package/dist/components/ui/spinner/spinner.mjs +49 -0
- package/dist/components/ui/spinner/spinner.mjs.map +1 -0
- package/dist/components/ui/stat/index.mjs +29 -0
- package/dist/components/ui/stat/index.mjs.map +1 -0
- package/dist/components/ui/stat/stat.mjs +226 -0
- package/dist/components/ui/stat/stat.mjs.map +1 -0
- package/dist/components/ui/status-bar/index.mjs +17 -0
- package/dist/components/ui/status-bar/index.mjs.map +1 -0
- package/dist/components/ui/status-bar/status-bar.mjs +96 -0
- package/dist/components/ui/status-bar/status-bar.mjs.map +1 -0
- package/dist/components/ui/stepper/index.mjs +25 -0
- package/dist/components/ui/stepper/index.mjs.map +1 -0
- package/dist/components/ui/stepper/stepper.mjs +235 -0
- package/dist/components/ui/stepper/stepper.mjs.map +1 -0
- package/dist/components/ui/steps/index.mjs +9 -0
- package/dist/components/ui/steps/index.mjs.map +1 -0
- package/dist/components/ui/steps/steps.mjs +70 -0
- package/dist/components/ui/steps/steps.mjs.map +1 -0
- package/dist/components/ui/swatch-grid/index.mjs +7 -0
- package/dist/components/ui/swatch-grid/index.mjs.map +1 -0
- package/dist/components/ui/swatch-grid/swatch-grid.mjs +110 -0
- package/dist/components/ui/swatch-grid/swatch-grid.mjs.map +1 -0
- package/dist/components/ui/switch/index.mjs +7 -0
- package/dist/components/ui/switch/index.mjs.map +1 -0
- package/dist/components/ui/switch/switch.mjs +79 -0
- package/dist/components/ui/switch/switch.mjs.map +1 -0
- package/dist/components/ui/tab-strip/index.mjs +13 -0
- package/dist/components/ui/tab-strip/index.mjs.map +1 -0
- package/dist/components/ui/tab-strip/tab-strip.mjs +244 -0
- package/dist/components/ui/tab-strip/tab-strip.mjs.map +1 -0
- package/dist/components/ui/table/index.mjs +27 -0
- package/dist/components/ui/table/index.mjs.map +1 -0
- package/dist/components/ui/table/table.mjs +290 -0
- package/dist/components/ui/table/table.mjs.map +1 -0
- package/dist/components/ui/table-of-contents/index.mjs +20 -0
- package/dist/components/ui/table-of-contents/index.mjs.map +1 -0
- package/dist/components/ui/table-of-contents/scroll-spy.mjs +60 -0
- package/dist/components/ui/table-of-contents/scroll-spy.mjs.map +1 -0
- package/dist/components/ui/table-of-contents/table-of-contents.mjs +371 -0
- package/dist/components/ui/table-of-contents/table-of-contents.mjs.map +1 -0
- package/dist/components/ui/table-of-contents/use-headings.mjs +40 -0
- package/dist/components/ui/table-of-contents/use-headings.mjs.map +1 -0
- package/dist/components/ui/tablet-frame/index.mjs +7 -0
- package/dist/components/ui/tablet-frame/index.mjs.map +1 -0
- package/dist/components/ui/tablet-frame/tablet-frame.mjs +48 -0
- package/dist/components/ui/tablet-frame/tablet-frame.mjs.map +1 -0
- package/dist/components/ui/tabs/index.mjs +25 -0
- package/dist/components/ui/tabs/index.mjs.map +1 -0
- package/dist/components/ui/tabs/tabs.mjs +382 -0
- package/dist/components/ui/tabs/tabs.mjs.map +1 -0
- package/dist/components/ui/tabs/use-tabs-indicator.mjs +90 -0
- package/dist/components/ui/tabs/use-tabs-indicator.mjs.map +1 -0
- package/dist/components/ui/tags-input/index.mjs +9 -0
- package/dist/components/ui/tags-input/index.mjs.map +1 -0
- package/dist/components/ui/tags-input/split.mjs +38 -0
- package/dist/components/ui/tags-input/split.mjs.map +1 -0
- package/dist/components/ui/tags-input/tags-input.mjs +328 -0
- package/dist/components/ui/tags-input/tags-input.mjs.map +1 -0
- package/dist/components/ui/terminal/index.mjs +41 -0
- package/dist/components/ui/terminal/index.mjs.map +1 -0
- package/dist/components/ui/terminal/terminal.mjs +287 -0
- package/dist/components/ui/terminal/terminal.mjs.map +1 -0
- package/dist/components/ui/textarea/index.mjs +21 -0
- package/dist/components/ui/textarea/index.mjs.map +1 -0
- package/dist/components/ui/textarea/textarea.mjs +244 -0
- package/dist/components/ui/textarea/textarea.mjs.map +1 -0
- package/dist/components/ui/theme-provider/index.mjs +6 -0
- package/dist/components/ui/theme-provider/index.mjs.map +1 -0
- package/dist/components/ui/theme-provider/theme-provider.mjs +70 -0
- package/dist/components/ui/theme-provider/theme-provider.mjs.map +1 -0
- package/dist/components/ui/toast/index.mjs +19 -0
- package/dist/components/ui/toast/index.mjs.map +1 -0
- package/dist/components/ui/toast/store.mjs +96 -0
- package/dist/components/ui/toast/store.mjs.map +1 -0
- package/dist/components/ui/toast/toast.mjs +395 -0
- package/dist/components/ui/toast/toast.mjs.map +1 -0
- package/dist/components/ui/toggle/index.mjs +13 -0
- package/dist/components/ui/toggle/index.mjs.map +1 -0
- package/dist/components/ui/toggle/toggle.mjs +123 -0
- package/dist/components/ui/toggle/toggle.mjs.map +1 -0
- package/dist/components/ui/toggle-group/index.mjs +11 -0
- package/dist/components/ui/toggle-group/index.mjs.map +1 -0
- package/dist/components/ui/toggle-group/toggle-group.mjs +243 -0
- package/dist/components/ui/toggle-group/toggle-group.mjs.map +1 -0
- package/dist/components/ui/toggletip/index.mjs +6 -0
- package/dist/components/ui/toggletip/index.mjs.map +1 -0
- package/dist/components/ui/toggletip/toggletip.mjs +95 -0
- package/dist/components/ui/toggletip/toggletip.mjs.map +1 -0
- package/dist/components/ui/toolbar/index.mjs +21 -0
- package/dist/components/ui/toolbar/index.mjs.map +1 -0
- package/dist/components/ui/toolbar/toolbar.mjs +130 -0
- package/dist/components/ui/toolbar/toolbar.mjs.map +1 -0
- package/dist/components/ui/tooltip/index.mjs +29 -0
- package/dist/components/ui/tooltip/index.mjs.map +1 -0
- package/dist/components/ui/tooltip/tooltip.mjs +640 -0
- package/dist/components/ui/tooltip/tooltip.mjs.map +1 -0
- package/dist/components/ui/tree/index.mjs +11 -0
- package/dist/components/ui/tree/index.mjs.map +1 -0
- package/dist/components/ui/tree/tree.mjs +450 -0
- package/dist/components/ui/tree/tree.mjs.map +1 -0
- package/dist/index.d.mts +19397 -0
- package/dist/index.mjs +157 -0
- package/dist/index.mjs.map +1 -0
- package/dist/lib/color.mjs +78 -0
- package/dist/lib/color.mjs.map +1 -0
- package/dist/lib/create-context.mjs +31 -0
- package/dist/lib/create-context.mjs.map +1 -0
- package/dist/lib/date.mjs +116 -0
- package/dist/lib/date.mjs.map +1 -0
- package/dist/lib/density.mjs +79 -0
- package/dist/lib/density.mjs.map +1 -0
- package/dist/lib/field-context.mjs +13 -0
- package/dist/lib/field-context.mjs.map +1 -0
- package/dist/lib/filter.mjs +28 -0
- package/dist/lib/filter.mjs.map +1 -0
- package/dist/lib/gesture.mjs +38 -0
- package/dist/lib/gesture.mjs.map +1 -0
- package/dist/lib/hit-area.mjs +14 -0
- package/dist/lib/hit-area.mjs.map +1 -0
- package/dist/lib/labels.mjs +27 -0
- package/dist/lib/labels.mjs.map +1 -0
- package/dist/lib/morph-box.mjs +56 -0
- package/dist/lib/morph-box.mjs.map +1 -0
- package/dist/lib/motion.mjs +70 -0
- package/dist/lib/motion.mjs.map +1 -0
- package/dist/lib/pulse.mjs +69 -0
- package/dist/lib/pulse.mjs.map +1 -0
- package/dist/lib/roving-focus.mjs +74 -0
- package/dist/lib/roving-focus.mjs.map +1 -0
- package/dist/lib/theme.mjs +67 -0
- package/dist/lib/theme.mjs.map +1 -0
- package/dist/lib/tv.mjs +11 -0
- package/dist/lib/tv.mjs.map +1 -0
- package/dist/lib/utils.mjs +82 -0
- package/dist/lib/utils.mjs.map +1 -0
- package/dist/styles.css +2 -0
- package/package.json +133 -4
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
+
import * as React from "react";
|
|
4
|
+
import { CaretRight, File } from "atoms-icons";
|
|
5
|
+
import { cn } from "../../../lib/utils.mjs";
|
|
6
|
+
import { useSidebar } from "./sidebar.mjs";
|
|
7
|
+
import { SidebarItem } from "./sidebar-item.mjs";
|
|
8
|
+
import { sidebarItemVariants, sidebarTreeVariants } from "./variants.mjs";
|
|
9
|
+
const TreeContext = React.createContext(null);
|
|
10
|
+
const LevelContext = React.createContext(0);
|
|
11
|
+
function treeItems(children) {
|
|
12
|
+
return React.Children.toArray(children).flatMap((child) => {
|
|
13
|
+
if (!React.isValidElement(child)) return [];
|
|
14
|
+
if (child.type === React.Fragment) return treeItems(child.props.children);
|
|
15
|
+
return child.type === SidebarTreeItem ? [child] : [];
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
function visibleValues(children, expanded) {
|
|
19
|
+
return treeItems(children).flatMap((item) => {
|
|
20
|
+
const kids = treeItems(item.props.children);
|
|
21
|
+
return [item.props.value, ...kids.length && expanded.has(item.props.value) ? visibleValues(item.props.children, expanded) : []];
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
function containsValue(item, value) {
|
|
25
|
+
if (value === void 0) return false;
|
|
26
|
+
return item.props.value === value || treeItems(item.props.children).some((child) => containsValue(child, value));
|
|
27
|
+
}
|
|
28
|
+
function SidebarTree({
|
|
29
|
+
value: valueProp,
|
|
30
|
+
defaultValue,
|
|
31
|
+
onValueChange,
|
|
32
|
+
expandedValues,
|
|
33
|
+
defaultExpandedValues = [],
|
|
34
|
+
onExpandedChange,
|
|
35
|
+
linkAs = "a",
|
|
36
|
+
className,
|
|
37
|
+
children,
|
|
38
|
+
onKeyDown,
|
|
39
|
+
...props
|
|
40
|
+
}) {
|
|
41
|
+
const { collapsed } = useSidebar();
|
|
42
|
+
const [ownValue, setOwnValue] = React.useState(defaultValue);
|
|
43
|
+
const [ownExpanded, setOwnExpanded] = React.useState(defaultExpandedValues);
|
|
44
|
+
const [focused, setFocused] = React.useState(void 0);
|
|
45
|
+
const value = valueProp ?? ownValue;
|
|
46
|
+
const expandedList = expandedValues ?? ownExpanded;
|
|
47
|
+
const expanded = React.useMemo(() => new Set(expandedList), [expandedList]);
|
|
48
|
+
const slots = sidebarTreeVariants({ collapsed });
|
|
49
|
+
const select = (next) => {
|
|
50
|
+
if (valueProp === void 0) setOwnValue(next);
|
|
51
|
+
onValueChange?.(next);
|
|
52
|
+
};
|
|
53
|
+
const toggle = (v) => {
|
|
54
|
+
const next = expanded.has(v) ? expandedList.filter((x) => x !== v) : [...expandedList, v];
|
|
55
|
+
if (expandedValues === void 0) setOwnExpanded(next);
|
|
56
|
+
onExpandedChange?.(next);
|
|
57
|
+
};
|
|
58
|
+
if (collapsed) {
|
|
59
|
+
return /* @__PURE__ */ jsx("ul", { "data-slot": "sidebar-tree", "data-collapsed": "true", className: slots.tree({ className }), ...props, children: treeItems(children).map((item) => {
|
|
60
|
+
const { value: v, label, icon, disabled } = item.props;
|
|
61
|
+
return /* @__PURE__ */ jsx("li", { "data-slot": "sidebar-tree-item", className: "list-none", children: /* @__PURE__ */ jsx(
|
|
62
|
+
SidebarItem,
|
|
63
|
+
{
|
|
64
|
+
active: containsValue(item, value),
|
|
65
|
+
label: typeof label === "string" ? label : void 0,
|
|
66
|
+
disabled,
|
|
67
|
+
onClick: () => select(v),
|
|
68
|
+
children: /* @__PURE__ */ jsx("span", { "data-slot": "sidebar-tree-icon", "aria-hidden": "true", className: slots.icon(), children: icon ?? /* @__PURE__ */ jsx(File, {}) })
|
|
69
|
+
}
|
|
70
|
+
) }, v);
|
|
71
|
+
}) });
|
|
72
|
+
}
|
|
73
|
+
const shown = visibleValues(children, expanded);
|
|
74
|
+
const tabStop = [focused, value].find((v) => v !== void 0 && shown.includes(v)) ?? shown[0];
|
|
75
|
+
const handleKeyDown = (event) => {
|
|
76
|
+
onKeyDown?.(event);
|
|
77
|
+
if (event.defaultPrevented) return;
|
|
78
|
+
const row = event.target;
|
|
79
|
+
if (row.getAttribute("role") !== "treeitem" || row.closest("[role=tree]") !== event.currentTarget) return;
|
|
80
|
+
const rows = [...event.currentTarget.querySelectorAll("[role=treeitem]")].filter(
|
|
81
|
+
(r) => !r.closest("[data-slot=sidebar-tree-group][data-state=closed]") && r.getAttribute("aria-disabled") !== "true"
|
|
82
|
+
);
|
|
83
|
+
const index = rows.indexOf(row);
|
|
84
|
+
const go = (target) => {
|
|
85
|
+
event.preventDefault();
|
|
86
|
+
target?.focus();
|
|
87
|
+
};
|
|
88
|
+
const current = row.dataset.value ?? "";
|
|
89
|
+
const branch = row.dataset.branch === "true";
|
|
90
|
+
const open = row.dataset.expanded === "true";
|
|
91
|
+
switch (event.key) {
|
|
92
|
+
case "ArrowDown":
|
|
93
|
+
return go(rows[index + 1]);
|
|
94
|
+
case "ArrowUp":
|
|
95
|
+
return go(rows[index - 1]);
|
|
96
|
+
case "Home":
|
|
97
|
+
return go(rows[0]);
|
|
98
|
+
case "End":
|
|
99
|
+
return go(rows[rows.length - 1]);
|
|
100
|
+
case "ArrowRight":
|
|
101
|
+
event.preventDefault();
|
|
102
|
+
if (branch && !open) toggle(current);
|
|
103
|
+
else if (branch) rows[index + 1]?.focus();
|
|
104
|
+
return;
|
|
105
|
+
case "ArrowLeft": {
|
|
106
|
+
event.preventDefault();
|
|
107
|
+
if (branch && open) return toggle(current);
|
|
108
|
+
const parent = row.parentElement?.parentElement?.closest("[data-slot=sidebar-tree-item]");
|
|
109
|
+
parent?.querySelector(":scope > [role=treeitem]")?.focus();
|
|
110
|
+
return;
|
|
111
|
+
}
|
|
112
|
+
case "Enter":
|
|
113
|
+
case " ":
|
|
114
|
+
if (event.key === "Enter" && row.hasAttribute("href")) return;
|
|
115
|
+
event.preventDefault();
|
|
116
|
+
row.click();
|
|
117
|
+
return;
|
|
118
|
+
}
|
|
119
|
+
};
|
|
120
|
+
return /* @__PURE__ */ jsx(TreeContext.Provider, { value: { value, expanded, tabStop, select, toggle, setTabStop: setFocused, linkAs }, children: /* @__PURE__ */ jsx("ul", { role: "tree", "data-slot": "sidebar-tree", className: slots.tree({ className }), onKeyDown: handleKeyDown, ...props, children }) });
|
|
121
|
+
}
|
|
122
|
+
function SidebarTreeItem({
|
|
123
|
+
value,
|
|
124
|
+
label,
|
|
125
|
+
icon,
|
|
126
|
+
href,
|
|
127
|
+
actions,
|
|
128
|
+
disabled = false,
|
|
129
|
+
children,
|
|
130
|
+
className,
|
|
131
|
+
style,
|
|
132
|
+
onClick,
|
|
133
|
+
onFocus,
|
|
134
|
+
...props
|
|
135
|
+
}) {
|
|
136
|
+
const ctx = React.useContext(TreeContext);
|
|
137
|
+
if (!ctx) throw new Error("SidebarTreeItem must be used within <SidebarTree>.");
|
|
138
|
+
const level = React.useContext(LevelContext);
|
|
139
|
+
const { density } = useSidebar();
|
|
140
|
+
const branch = treeItems(children).length > 0;
|
|
141
|
+
const open = branch && ctx.expanded.has(value);
|
|
142
|
+
const active = ctx.value === value;
|
|
143
|
+
const groupId = React.useId();
|
|
144
|
+
const slots = sidebarTreeVariants({ branch });
|
|
145
|
+
const [wasOpen, setWasOpen] = React.useState(open);
|
|
146
|
+
const [leaving, setLeaving] = React.useState(false);
|
|
147
|
+
if (wasOpen !== open) {
|
|
148
|
+
setWasOpen(open);
|
|
149
|
+
setLeaving(!open);
|
|
150
|
+
}
|
|
151
|
+
React.useEffect(() => {
|
|
152
|
+
if (!leaving) return;
|
|
153
|
+
const timer = setTimeout(() => setLeaving(false), 400);
|
|
154
|
+
return () => clearTimeout(timer);
|
|
155
|
+
}, [leaving]);
|
|
156
|
+
const Row = href ? ctx.linkAs : "div";
|
|
157
|
+
return /* @__PURE__ */ jsxs("li", { role: "none", "data-slot": "sidebar-tree-item", "data-state": branch ? open ? "open" : "closed" : void 0, className: slots.item(), children: [
|
|
158
|
+
/* @__PURE__ */ jsxs(
|
|
159
|
+
Row,
|
|
160
|
+
{
|
|
161
|
+
role: "treeitem",
|
|
162
|
+
"data-slot": "sidebar-tree-row",
|
|
163
|
+
"data-value": value,
|
|
164
|
+
"data-level": level,
|
|
165
|
+
"data-branch": branch,
|
|
166
|
+
"data-expanded": open,
|
|
167
|
+
"data-active": active || void 0,
|
|
168
|
+
"aria-level": level + 1,
|
|
169
|
+
"aria-expanded": branch ? open : void 0,
|
|
170
|
+
"aria-selected": active,
|
|
171
|
+
"aria-current": active ? "page" : void 0,
|
|
172
|
+
"aria-disabled": disabled || void 0,
|
|
173
|
+
href,
|
|
174
|
+
tabIndex: disabled ? -1 : ctx.tabStop === value ? 0 : -1,
|
|
175
|
+
style: { "--sidebar-tree-level": level, ...style },
|
|
176
|
+
className: cn(sidebarItemVariants({ mode: "list", density }).item(), slots.row(), className),
|
|
177
|
+
onFocus: (event) => {
|
|
178
|
+
onFocus?.(event);
|
|
179
|
+
if (event.target === event.currentTarget) ctx.setTabStop(value);
|
|
180
|
+
},
|
|
181
|
+
onClick: (event) => {
|
|
182
|
+
onClick?.(event);
|
|
183
|
+
if (event.defaultPrevented || disabled) return;
|
|
184
|
+
const target = event.target;
|
|
185
|
+
if (target.closest("[data-slot=sidebar-tree-actions]")) return;
|
|
186
|
+
if (branch && target.closest("[data-slot=sidebar-tree-caret]")) {
|
|
187
|
+
event.preventDefault();
|
|
188
|
+
ctx.toggle(value);
|
|
189
|
+
return;
|
|
190
|
+
}
|
|
191
|
+
ctx.select(value);
|
|
192
|
+
},
|
|
193
|
+
...props,
|
|
194
|
+
children: [
|
|
195
|
+
/* @__PURE__ */ jsxs("span", { "data-slot": "sidebar-tree-lead", className: slots.lead(), children: [
|
|
196
|
+
/* @__PURE__ */ jsx("span", { "data-slot": "sidebar-tree-icon", "aria-hidden": "true", className: slots.icon(), children: icon ?? /* @__PURE__ */ jsx(File, {}) }),
|
|
197
|
+
branch ? /* @__PURE__ */ jsx("span", { "data-slot": "sidebar-tree-caret", "aria-hidden": "true", className: slots.caret(), children: /* @__PURE__ */ jsx(CaretRight, { className: slots.caretGlyph() }) }) : null
|
|
198
|
+
] }),
|
|
199
|
+
/* @__PURE__ */ jsx("span", { "data-slot": "sidebar-tree-label", className: slots.label(), children: label }),
|
|
200
|
+
actions ? /* @__PURE__ */ jsx("span", { "data-slot": "sidebar-tree-actions", className: slots.actions(), children: /* @__PURE__ */ jsx("span", { className: slots.actionsInner(), children: actions }) }) : null
|
|
201
|
+
]
|
|
202
|
+
}
|
|
203
|
+
),
|
|
204
|
+
branch && (open || leaving) ? /* @__PURE__ */ jsx(
|
|
205
|
+
"ul",
|
|
206
|
+
{
|
|
207
|
+
role: "group",
|
|
208
|
+
id: groupId,
|
|
209
|
+
"data-slot": "sidebar-tree-group",
|
|
210
|
+
"data-state": open ? "open" : "closed",
|
|
211
|
+
className: slots.group(),
|
|
212
|
+
onAnimationEnd: (event) => {
|
|
213
|
+
if (event.target === event.currentTarget && !open) setLeaving(false);
|
|
214
|
+
},
|
|
215
|
+
children: /* @__PURE__ */ jsx(LevelContext.Provider, { value: level + 1, children })
|
|
216
|
+
}
|
|
217
|
+
) : null
|
|
218
|
+
] });
|
|
219
|
+
}
|
|
220
|
+
export {
|
|
221
|
+
SidebarTree,
|
|
222
|
+
SidebarTreeItem
|
|
223
|
+
};
|
|
224
|
+
//# sourceMappingURL=sidebar-tree.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../src/components/ui/sidebar/sidebar-tree.tsx"],"sourcesContent":["\"use client\"\n\nimport * as React from \"react\"\nimport { CaretRight, File } from \"atoms-icons\"\n\nimport { cn } from \"../../../lib/utils.mjs\"\nimport { useSidebar } from \"./sidebar.mjs\"\nimport { SidebarItem } from \"./sidebar-item.mjs\"\nimport { sidebarItemVariants, sidebarTreeVariants } from \"./variants.mjs\"\n\n/*\n * A workspace's page tree: pages nest without limit, a branch folds from its caret, and a click on\n * the row opens the page. It's a WAI-ARIA tree with one tab stop; the arrow keys walk the rows on\n * show. In the icon rail it shrinks to the top-level pages, each lit while the current page is\n * anywhere beneath it.\n */\n\ninterface TreeContextValue {\n value: string | undefined\n expanded: Set<string>\n tabStop: string | undefined\n select: (value: string) => void\n toggle: (value: string) => void\n setTabStop: (value: string) => void\n linkAs: React.ElementType\n}\n\nconst TreeContext = React.createContext<TreeContextValue | null>(null)\nconst LevelContext = React.createContext(0)\n\ntype ItemElement = React.ReactElement<SidebarTreeItemProps>\n\n/** The SidebarTreeItems among some children, looking through fragments and arrays. */\nfunction treeItems(children: React.ReactNode): ItemElement[] {\n return React.Children.toArray(children).flatMap((child) => {\n if (!React.isValidElement(child)) return []\n if (child.type === React.Fragment) return treeItems((child.props as { children?: React.ReactNode }).children)\n return child.type === SidebarTreeItem ? [child as ItemElement] : []\n })\n}\n\n/** The rows on show, top to bottom: a closed branch hides its subtree. */\nfunction visibleValues(children: React.ReactNode, expanded: Set<string>): string[] {\n return treeItems(children).flatMap((item) => {\n const kids = treeItems(item.props.children)\n return [item.props.value, ...(kids.length && expanded.has(item.props.value) ? visibleValues(item.props.children, expanded) : [])]\n })\n}\n\nfunction containsValue(item: ItemElement, value: string | undefined): boolean {\n if (value === undefined) return false\n return item.props.value === value || treeItems(item.props.children).some((child) => containsValue(child, value))\n}\n\nexport interface SidebarTreeProps extends Omit<React.ComponentProps<\"ul\">, \"defaultValue\"> {\n /** The current page (controlled): its row takes the active chip and aria-current. */\n value?: string\n defaultValue?: string\n /** Called with the page opened by a click, Enter or Space. */\n onValueChange?: (value: string) => void\n /** The open branches (controlled). */\n expandedValues?: string[]\n defaultExpandedValues?: string[]\n onExpandedChange?: (values: string[]) => void\n /** What a page with an href renders as: pass Next's Link for client routing. */\n linkAs?: React.ElementType\n}\n\nexport function SidebarTree({\n value: valueProp,\n defaultValue,\n onValueChange,\n expandedValues,\n defaultExpandedValues = [],\n onExpandedChange,\n linkAs = \"a\",\n className,\n children,\n onKeyDown,\n ...props\n}: SidebarTreeProps) {\n const { collapsed } = useSidebar()\n const [ownValue, setOwnValue] = React.useState(defaultValue)\n const [ownExpanded, setOwnExpanded] = React.useState(defaultExpandedValues)\n const [focused, setFocused] = React.useState<string | undefined>(undefined)\n const value = valueProp ?? ownValue\n const expandedList = expandedValues ?? ownExpanded\n const expanded = React.useMemo(() => new Set(expandedList), [expandedList])\n const slots = sidebarTreeVariants({ collapsed })\n\n const select = (next: string) => {\n if (valueProp === undefined) setOwnValue(next)\n onValueChange?.(next)\n }\n const toggle = (v: string) => {\n const next = expanded.has(v) ? expandedList.filter((x) => x !== v) : [...expandedList, v]\n if (expandedValues === undefined) setOwnExpanded(next)\n onExpandedChange?.(next)\n }\n\n if (collapsed) {\n // The icon rail keeps the top-level pages; each one lights while the current page is under it.\n return (\n <ul data-slot=\"sidebar-tree\" data-collapsed=\"true\" className={slots.tree({ className })} {...props}>\n {treeItems(children).map((item) => {\n const { value: v, label, icon, disabled } = item.props\n return (\n <li key={v} data-slot=\"sidebar-tree-item\" className=\"list-none\">\n <SidebarItem\n active={containsValue(item, value)}\n label={typeof label === \"string\" ? label : undefined}\n disabled={disabled}\n onClick={() => select(v)}\n >\n <span data-slot=\"sidebar-tree-icon\" aria-hidden=\"true\" className={slots.icon()}>\n {icon ?? <File />}\n </span>\n </SidebarItem>\n </li>\n )\n })}\n </ul>\n )\n }\n\n // One tab stop: the row last focused, else the current page, else the first row on show.\n const shown = visibleValues(children, expanded)\n const tabStop = [focused, value].find((v) => v !== undefined && shown.includes(v)) ?? shown[0]\n\n const handleKeyDown = (event: React.KeyboardEvent<HTMLUListElement>) => {\n onKeyDown?.(event)\n if (event.defaultPrevented) return\n const row = event.target as HTMLElement\n // Keys pressed on a row's own buttons (its menu) stay theirs.\n if (row.getAttribute(\"role\") !== \"treeitem\" || row.closest(\"[role=tree]\") !== event.currentTarget) return\n const rows = [...event.currentTarget.querySelectorAll<HTMLElement>(\"[role=treeitem]\")].filter(\n (r) => !r.closest(\"[data-slot=sidebar-tree-group][data-state=closed]\") && r.getAttribute(\"aria-disabled\") !== \"true\",\n )\n const index = rows.indexOf(row)\n const go = (target: HTMLElement | undefined) => {\n event.preventDefault()\n target?.focus()\n }\n const current = row.dataset.value ?? \"\"\n const branch = row.dataset.branch === \"true\"\n const open = row.dataset.expanded === \"true\"\n switch (event.key) {\n case \"ArrowDown\":\n return go(rows[index + 1])\n case \"ArrowUp\":\n return go(rows[index - 1])\n case \"Home\":\n return go(rows[0])\n case \"End\":\n return go(rows[rows.length - 1])\n case \"ArrowRight\":\n event.preventDefault()\n if (branch && !open) toggle(current)\n else if (branch) rows[index + 1]?.focus()\n return\n case \"ArrowLeft\": {\n event.preventDefault()\n if (branch && open) return toggle(current)\n const parent = row.parentElement?.parentElement?.closest<HTMLElement>(\"[data-slot=sidebar-tree-item]\")\n parent?.querySelector<HTMLElement>(\":scope > [role=treeitem]\")?.focus()\n return\n }\n case \"Enter\":\n case \" \":\n // A link row follows its href on Enter by itself; Space and plain rows open here.\n if (event.key === \"Enter\" && row.hasAttribute(\"href\")) return\n event.preventDefault()\n row.click()\n return\n }\n }\n\n return (\n <TreeContext.Provider value={{ value, expanded, tabStop, select, toggle, setTabStop: setFocused, linkAs }}>\n <ul role=\"tree\" data-slot=\"sidebar-tree\" className={slots.tree({ className })} onKeyDown={handleKeyDown} {...props}>\n {children}\n </ul>\n </TreeContext.Provider>\n )\n}\n\nexport interface SidebarTreeItemProps extends Omit<React.ComponentProps<\"div\">, \"children\"> {\n /** Stable identity for navigation and expansion. */\n value: string\n /** The page title; a string also names the glyph in the icon rail. */\n label: React.ReactNode\n /** The page's emoji or glyph. Falls back to a page glyph so every row keeps its column. */\n icon?: React.ReactNode\n /** Makes the row a real link, rendered with the tree's linkAs. */\n href?: string\n /** Trailing SidebarItemActions, revealed on hover or keyboard focus. */\n actions?: React.ReactNode\n disabled?: boolean\n /** Nested SidebarTreeItems: its subpages. */\n children?: React.ReactNode\n}\n\n/** A page, recursive: nest SidebarTreeItems for subpages. The row opens the page; the caret folds it. */\nexport function SidebarTreeItem({\n value,\n label,\n icon,\n href,\n actions,\n disabled = false,\n children,\n className,\n style,\n onClick,\n onFocus,\n ...props\n}: SidebarTreeItemProps) {\n const ctx = React.useContext(TreeContext)\n if (!ctx) throw new Error(\"SidebarTreeItem must be used within <SidebarTree>.\")\n const level = React.useContext(LevelContext)\n const { density } = useSidebar()\n const branch = treeItems(children).length > 0\n const open = branch && ctx.expanded.has(value)\n const active = ctx.value === value\n const groupId = React.useId()\n const slots = sidebarTreeVariants({ branch })\n\n // The sub-list stays for its fold, then leaves the DOM.\n const [wasOpen, setWasOpen] = React.useState(open)\n const [leaving, setLeaving] = React.useState(false)\n if (wasOpen !== open) {\n setWasOpen(open)\n setLeaving(!open)\n }\n React.useEffect(() => {\n if (!leaving) return\n // animationend never comes with reduced motion or in a background tab.\n const timer = setTimeout(() => setLeaving(false), 400)\n return () => clearTimeout(timer)\n }, [leaving])\n\n const Row: React.ElementType = href ? ctx.linkAs : \"div\"\n\n return (\n <li role=\"none\" data-slot=\"sidebar-tree-item\" data-state={branch ? (open ? \"open\" : \"closed\") : undefined} className={slots.item()}>\n <Row\n role=\"treeitem\"\n data-slot=\"sidebar-tree-row\"\n data-value={value}\n data-level={level}\n data-branch={branch}\n data-expanded={open}\n data-active={active || undefined}\n aria-level={level + 1}\n aria-expanded={branch ? open : undefined}\n aria-selected={active}\n aria-current={active ? \"page\" : undefined}\n aria-disabled={disabled || undefined}\n href={href}\n tabIndex={disabled ? -1 : ctx.tabStop === value ? 0 : -1}\n style={{ \"--sidebar-tree-level\": level, ...style } as React.CSSProperties}\n className={cn(sidebarItemVariants({ mode: \"list\", density }).item(), slots.row(), className)}\n onFocus={(event: React.FocusEvent<HTMLElement>) => {\n onFocus?.(event as React.FocusEvent<HTMLDivElement>)\n if (event.target === event.currentTarget) ctx.setTabStop(value)\n }}\n onClick={(event: React.MouseEvent<HTMLElement>) => {\n onClick?.(event as React.MouseEvent<HTMLDivElement>)\n if (event.defaultPrevented || disabled) return\n const target = event.target as HTMLElement\n if (target.closest(\"[data-slot=sidebar-tree-actions]\")) return\n if (branch && target.closest(\"[data-slot=sidebar-tree-caret]\")) {\n event.preventDefault()\n ctx.toggle(value)\n return\n }\n ctx.select(value)\n }}\n {...props}\n >\n <span data-slot=\"sidebar-tree-lead\" className={slots.lead()}>\n <span data-slot=\"sidebar-tree-icon\" aria-hidden=\"true\" className={slots.icon()}>\n {icon ?? <File />}\n </span>\n {branch ? (\n <span data-slot=\"sidebar-tree-caret\" aria-hidden=\"true\" className={slots.caret()}>\n <CaretRight className={slots.caretGlyph()} />\n </span>\n ) : null}\n </span>\n <span data-slot=\"sidebar-tree-label\" className={slots.label()}>\n {label}\n </span>\n {actions ? (\n <span data-slot=\"sidebar-tree-actions\" className={slots.actions()}>\n <span className={slots.actionsInner()}>{actions}</span>\n </span>\n ) : null}\n </Row>\n {branch && (open || leaving) ? (\n <ul\n role=\"group\"\n id={groupId}\n data-slot=\"sidebar-tree-group\"\n data-state={open ? \"open\" : \"closed\"}\n className={slots.group()}\n onAnimationEnd={(event) => {\n if (event.target === event.currentTarget && !open) setLeaving(false)\n }}\n >\n <LevelContext.Provider value={level + 1}>{children}</LevelContext.Provider>\n </ul>\n ) : null}\n </li>\n )\n}\n"],"mappings":";AAmH2B,cAqKnB,YArKmB;AAjH3B,YAAY,WAAW;AACvB,SAAS,YAAY,YAAY;AAEjC,SAAS,UAAU;AACnB,SAAS,kBAAkB;AAC3B,SAAS,mBAAmB;AAC5B,SAAS,qBAAqB,2BAA2B;AAmBzD,MAAM,cAAc,MAAM,cAAuC,IAAI;AACrE,MAAM,eAAe,MAAM,cAAc,CAAC;AAK1C,SAAS,UAAU,UAA0C;AAC3D,SAAO,MAAM,SAAS,QAAQ,QAAQ,EAAE,QAAQ,CAAC,UAAU;AACzD,QAAI,CAAC,MAAM,eAAe,KAAK,EAAG,QAAO,CAAC;AAC1C,QAAI,MAAM,SAAS,MAAM,SAAU,QAAO,UAAW,MAAM,MAAyC,QAAQ;AAC5G,WAAO,MAAM,SAAS,kBAAkB,CAAC,KAAoB,IAAI,CAAC;AAAA,EACpE,CAAC;AACH;AAGA,SAAS,cAAc,UAA2B,UAAiC;AACjF,SAAO,UAAU,QAAQ,EAAE,QAAQ,CAAC,SAAS;AAC3C,UAAM,OAAO,UAAU,KAAK,MAAM,QAAQ;AAC1C,WAAO,CAAC,KAAK,MAAM,OAAO,GAAI,KAAK,UAAU,SAAS,IAAI,KAAK,MAA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AAU;AACzB,cAAI,MAAM,WAAW,MAAM,iBAAiB,CAAC,KAAM,YAAW,KAAK;AAAA,QACrE;AAAA,QAEA,8BAAC,aAAa,UAAb,EAAsB,OAAO,QAAQ,GAAI,UAAS;AAAA;AAAA,IACrD,IACE;AAAA,KACN;AAEJ;","names":[]}
|
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
+
import * as React from "react";
|
|
4
|
+
import { CaretUpDown } from "atoms-icons";
|
|
5
|
+
import { ControlSizeProvider, useDensity } from "../../../lib/density.mjs";
|
|
6
|
+
import { sidebarVariants } from "./variants.mjs";
|
|
7
|
+
const SidebarContext = React.createContext({
|
|
8
|
+
collapsed: false,
|
|
9
|
+
layout: "list",
|
|
10
|
+
tile: true,
|
|
11
|
+
density: "compact",
|
|
12
|
+
side: "left",
|
|
13
|
+
indicator: false,
|
|
14
|
+
peek: false
|
|
15
|
+
});
|
|
16
|
+
function useSidebar() {
|
|
17
|
+
return React.useContext(SidebarContext);
|
|
18
|
+
}
|
|
19
|
+
const SidebarShellContext = React.createContext(null);
|
|
20
|
+
function Sidebar({
|
|
21
|
+
className,
|
|
22
|
+
collapsed: collapsedProp,
|
|
23
|
+
layout = "list",
|
|
24
|
+
tile = true,
|
|
25
|
+
indicator = false,
|
|
26
|
+
side = "left",
|
|
27
|
+
floating = false,
|
|
28
|
+
docked: dockedProp,
|
|
29
|
+
density: densityProp,
|
|
30
|
+
...props
|
|
31
|
+
}) {
|
|
32
|
+
const shell = React.useContext(SidebarShellContext);
|
|
33
|
+
const collapsed = collapsedProp ?? shell?.collapsed ?? false;
|
|
34
|
+
const docked = (dockedProp ?? shell?.docked ?? false) && !floating;
|
|
35
|
+
const density = useDensity(densityProp);
|
|
36
|
+
const peek = collapsed && (shell?.peek ?? false);
|
|
37
|
+
const context = React.useMemo(
|
|
38
|
+
() => ({ collapsed, layout, tile, density, side, indicator, peek }),
|
|
39
|
+
[collapsed, layout, tile, density, side, indicator, peek]
|
|
40
|
+
);
|
|
41
|
+
return /* @__PURE__ */ jsx(SidebarContext.Provider, { value: context, children: /* @__PURE__ */ jsx(
|
|
42
|
+
"aside",
|
|
43
|
+
{
|
|
44
|
+
"data-slot": "sidebar",
|
|
45
|
+
"data-layout": layout,
|
|
46
|
+
"data-collapsed": collapsed || void 0,
|
|
47
|
+
"data-docked": docked || void 0,
|
|
48
|
+
"data-floating": floating || void 0,
|
|
49
|
+
className: sidebarVariants({ collapsed: collapsed || layout === "stacked", stacked: layout === "stacked", density, side: floating ? void 0 : side, floating, docked }).root({
|
|
50
|
+
className
|
|
51
|
+
}),
|
|
52
|
+
...props
|
|
53
|
+
}
|
|
54
|
+
) });
|
|
55
|
+
}
|
|
56
|
+
function useRail() {
|
|
57
|
+
const { collapsed, layout, density } = useSidebar();
|
|
58
|
+
return { collapsed: collapsed || layout === "stacked", stacked: layout === "stacked", density };
|
|
59
|
+
}
|
|
60
|
+
function SidebarHeader({ className, ...props }) {
|
|
61
|
+
return /* @__PURE__ */ jsx("div", { "data-slot": "sidebar-header", className: sidebarVariants(useRail()).header({ className }), ...props });
|
|
62
|
+
}
|
|
63
|
+
function indicatorTarget(content) {
|
|
64
|
+
const actives = [...content.querySelectorAll("[data-slot=sidebar-item][data-active=true]")];
|
|
65
|
+
const active = actives.find((row) => !row.parentElement?.matches("[data-slot=sidebar-collapsible]")) ?? actives[0];
|
|
66
|
+
if (!active) return null;
|
|
67
|
+
const folding = active.closest("[data-slot=sidebar-sub][data-state=closed]");
|
|
68
|
+
if (active.offsetParent !== null && !folding) return active;
|
|
69
|
+
let branch = active.closest("[data-slot=sidebar-collapsible]");
|
|
70
|
+
while (branch) {
|
|
71
|
+
const trigger = branch.querySelector(":scope > [data-slot=sidebar-item]");
|
|
72
|
+
if (trigger && trigger.offsetParent !== null) return trigger;
|
|
73
|
+
branch = branch.parentElement?.closest("[data-slot=sidebar-collapsible]") ?? null;
|
|
74
|
+
}
|
|
75
|
+
return null;
|
|
76
|
+
}
|
|
77
|
+
function SidebarContent({ className, children, ...props }) {
|
|
78
|
+
const { indicator } = useSidebar();
|
|
79
|
+
const rail = useRail();
|
|
80
|
+
const collapsed = rail.collapsed;
|
|
81
|
+
const contentRef = React.useRef(null);
|
|
82
|
+
const pillRef = React.useRef(null);
|
|
83
|
+
const glides = indicator && !collapsed;
|
|
84
|
+
React.useLayoutEffect(() => {
|
|
85
|
+
const content = contentRef.current;
|
|
86
|
+
const pill = pillRef.current;
|
|
87
|
+
if (!glides || !content || !pill) return;
|
|
88
|
+
let first = true;
|
|
89
|
+
const place = () => {
|
|
90
|
+
const target = indicatorTarget(content);
|
|
91
|
+
if (!target) {
|
|
92
|
+
pill.style.opacity = "0";
|
|
93
|
+
return;
|
|
94
|
+
}
|
|
95
|
+
const box = content.getBoundingClientRect();
|
|
96
|
+
const row = target.getBoundingClientRect();
|
|
97
|
+
if (first) pill.style.transition = "none";
|
|
98
|
+
pill.style.opacity = "1";
|
|
99
|
+
pill.style.height = `${row.height}px`;
|
|
100
|
+
pill.style.width = `${row.width}px`;
|
|
101
|
+
pill.style.transform = `translate(${row.left - box.left}px, ${row.top - box.top + content.scrollTop}px)`;
|
|
102
|
+
if (first) {
|
|
103
|
+
void pill.offsetHeight;
|
|
104
|
+
pill.style.transition = "";
|
|
105
|
+
first = false;
|
|
106
|
+
}
|
|
107
|
+
};
|
|
108
|
+
place();
|
|
109
|
+
const mutations = new MutationObserver(place);
|
|
110
|
+
mutations.observe(content, { subtree: true, attributes: true, attributeFilter: ["data-active", "data-state"], childList: true });
|
|
111
|
+
const resize = new ResizeObserver(place);
|
|
112
|
+
resize.observe(content);
|
|
113
|
+
return () => {
|
|
114
|
+
mutations.disconnect();
|
|
115
|
+
resize.disconnect();
|
|
116
|
+
};
|
|
117
|
+
}, [glides]);
|
|
118
|
+
return /* @__PURE__ */ jsxs(
|
|
119
|
+
"div",
|
|
120
|
+
{
|
|
121
|
+
ref: contentRef,
|
|
122
|
+
"data-slot": "sidebar-content",
|
|
123
|
+
"data-indicator": glides || void 0,
|
|
124
|
+
className: sidebarVariants(rail).content({
|
|
125
|
+
className: [glides && "[&_[data-slot=sidebar-item][data-active=true]]:bg-transparent", className]
|
|
126
|
+
}),
|
|
127
|
+
...props,
|
|
128
|
+
children: [
|
|
129
|
+
glides ? /* @__PURE__ */ jsx(
|
|
130
|
+
"div",
|
|
131
|
+
{
|
|
132
|
+
ref: pillRef,
|
|
133
|
+
"aria-hidden": "true",
|
|
134
|
+
"data-slot": "sidebar-indicator",
|
|
135
|
+
className: "pointer-events-none absolute top-0 left-0 rounded-md bg-accent opacity-0 transition-[transform,height,width,opacity] duration-base ease-out motion-reduce-fade"
|
|
136
|
+
}
|
|
137
|
+
) : null,
|
|
138
|
+
children
|
|
139
|
+
]
|
|
140
|
+
}
|
|
141
|
+
);
|
|
142
|
+
}
|
|
143
|
+
function SidebarFooter({ className, ...props }) {
|
|
144
|
+
return /* @__PURE__ */ jsx("div", { "data-slot": "sidebar-footer", className: sidebarVariants(useRail()).footer({ className }), ...props });
|
|
145
|
+
}
|
|
146
|
+
function SidebarActions({ className, size = "sm", children, ...props }) {
|
|
147
|
+
const { collapsed } = useRail();
|
|
148
|
+
return /* @__PURE__ */ jsx(
|
|
149
|
+
"div",
|
|
150
|
+
{
|
|
151
|
+
"data-slot": "sidebar-actions",
|
|
152
|
+
"data-control-size": size,
|
|
153
|
+
className: sidebarVariants({ collapsed }).actions({ className }),
|
|
154
|
+
...props,
|
|
155
|
+
children: /* @__PURE__ */ jsx(ControlSizeProvider, { size, children })
|
|
156
|
+
}
|
|
157
|
+
);
|
|
158
|
+
}
|
|
159
|
+
function SidebarSwitcher({
|
|
160
|
+
className,
|
|
161
|
+
title,
|
|
162
|
+
subtitle,
|
|
163
|
+
leading,
|
|
164
|
+
caret = true,
|
|
165
|
+
variant = "default",
|
|
166
|
+
type = "button",
|
|
167
|
+
...props
|
|
168
|
+
}) {
|
|
169
|
+
const { collapsed, stacked, density } = useRail();
|
|
170
|
+
const { peek } = useSidebar();
|
|
171
|
+
const slots = sidebarVariants({ collapsed, stacked, density, switcherVariant: variant });
|
|
172
|
+
return /* @__PURE__ */ jsxs(
|
|
173
|
+
"button",
|
|
174
|
+
{
|
|
175
|
+
type,
|
|
176
|
+
"data-slot": "sidebar-switcher",
|
|
177
|
+
"aria-label": collapsed && !peek && typeof title === "string" ? title : void 0,
|
|
178
|
+
className: slots.switcher({ className }),
|
|
179
|
+
...props,
|
|
180
|
+
children: [
|
|
181
|
+
leading,
|
|
182
|
+
/* @__PURE__ */ jsxs("span", { "data-slot": "sidebar-switcher-text", className: slots.switcherText(), children: [
|
|
183
|
+
/* @__PURE__ */ jsx("span", { className: slots.switcherTitle(), children: title }),
|
|
184
|
+
subtitle ? /* @__PURE__ */ jsx("span", { className: slots.switcherSubtitle(), children: subtitle }) : null
|
|
185
|
+
] }),
|
|
186
|
+
caret ? /* @__PURE__ */ jsx(CaretUpDown, { "aria-hidden": "true", "data-slot": "sidebar-switcher-caret", className: slots.switcherCaret() }) : null
|
|
187
|
+
]
|
|
188
|
+
}
|
|
189
|
+
);
|
|
190
|
+
}
|
|
191
|
+
function SidebarSeparator({ className, ...props }) {
|
|
192
|
+
return /* @__PURE__ */ jsx("div", { role: "separator", "data-slot": "sidebar-separator", className: sidebarVariants().separator({ className }), ...props });
|
|
193
|
+
}
|
|
194
|
+
export {
|
|
195
|
+
Sidebar,
|
|
196
|
+
SidebarActions,
|
|
197
|
+
SidebarContent,
|
|
198
|
+
SidebarFooter,
|
|
199
|
+
SidebarHeader,
|
|
200
|
+
SidebarSeparator,
|
|
201
|
+
SidebarShellContext,
|
|
202
|
+
SidebarSwitcher,
|
|
203
|
+
useSidebar
|
|
204
|
+
};
|
|
205
|
+
//# sourceMappingURL=sidebar.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../src/components/ui/sidebar/sidebar.tsx"],"sourcesContent":["\"use client\"\n\nimport * as React from \"react\"\nimport { CaretUpDown } from \"atoms-icons\"\n\nimport { ControlSizeProvider, useDensity, type ButtonSize, type Density } from \"../../../lib/density.mjs\"\nimport { sidebarVariants } from \"./variants.mjs\"\n\n/*\n * The application navigation rail: an <aside> landmark on the card surface with a header and a\n * footer pinned around a scrolling content zone. Every part reads one context, so a single\n * `collapsed` turns the whole rail into a 48px icon column and a single `density` steps every row.\n */\n\nexport interface SidebarContextValue {\n collapsed: boolean\n layout: \"list\" | \"stacked\"\n tile: boolean\n density: Density\n side: \"left\" | \"right\"\n indicator: boolean\n /** Inside an expand-mode SidebarPeekPanel: the icon rail keeps its labels for the panel to reveal. */\n peek: boolean\n}\n\nconst SidebarContext = React.createContext<SidebarContextValue>({\n collapsed: false,\n layout: \"list\",\n tile: true,\n density: \"compact\",\n side: \"left\",\n indicator: false,\n peek: false,\n})\n\nexport function useSidebar() {\n return React.useContext(SidebarContext)\n}\n\n/**\n * What an app shell hands its rail: a LayoutSidebar provides `docked` and `collapsed`, so a rail\n * nested in it docks on its own. Explicit props on Sidebar still win.\n */\nexport const SidebarShellContext = React.createContext<{ docked?: boolean; collapsed?: boolean; peek?: boolean } | null>(null)\n\nexport interface SidebarProps extends React.ComponentProps<\"aside\"> {\n /** A 48px icon-only column. Inherited from an enclosing shell; an explicit value wins. */\n collapsed?: boolean\n /** stacked is the labeled icon rail: a 64px column, each glyph in a tile over a short label. */\n layout?: \"list\" | \"stacked\"\n /** The stacked rail's selection tile. Off, the rail goes bare and the bar marks the current row. */\n tile?: boolean\n /** One highlight that glides to the active row instead of a chip per row. */\n indicator?: boolean\n side?: \"left\" | \"right\"\n /** Detaches the rail into a rounded card with a full outline and shadow. */\n floating?: boolean\n /** Sits the rail on the app canvas: no fill, no hairline. Inherited from an enclosing shell. */\n docked?: boolean\n density?: Density\n}\n\nexport function Sidebar({\n className,\n collapsed: collapsedProp,\n layout = \"list\",\n tile = true,\n indicator = false,\n side = \"left\",\n floating = false,\n docked: dockedProp,\n density: densityProp,\n ...props\n}: SidebarProps) {\n const shell = React.useContext(SidebarShellContext)\n const collapsed = collapsedProp ?? shell?.collapsed ?? false\n // A floating rail keeps its card even inside a shell: that pair is the rail in the gutter.\n const docked = (dockedProp ?? shell?.docked ?? false) && !floating\n const density = useDensity(densityProp)\n const peek = collapsed && (shell?.peek ?? false)\n const context = React.useMemo<SidebarContextValue>(\n () => ({ collapsed, layout, tile, density, side, indicator, peek }),\n [collapsed, layout, tile, density, side, indicator, peek],\n )\n return (\n <SidebarContext.Provider value={context}>\n <aside\n data-slot=\"sidebar\"\n data-layout={layout}\n data-collapsed={collapsed || undefined}\n data-docked={docked || undefined}\n data-floating={floating || undefined}\n className={sidebarVariants({ collapsed: collapsed || layout === \"stacked\", stacked: layout === \"stacked\", density, side: floating ? undefined : side, floating, docked }).root({\n className,\n })}\n {...props}\n />\n </SidebarContext.Provider>\n )\n}\n\n/** The rail, the stacked rail included, lays its zones out as the icon rail does. */\nfunction useRail() {\n const { collapsed, layout, density } = useSidebar()\n return { collapsed: collapsed || layout === \"stacked\", stacked: layout === \"stacked\", density }\n}\n\nexport function SidebarHeader({ className, ...props }: React.ComponentProps<\"div\">) {\n return (\n <div data-slot=\"sidebar-header\" className={sidebarVariants(useRail()).header({ className })} {...props} />\n )\n}\n\n/**\n * The row the indicator should sit on: the active row, or, when it's folded away inside a closed\n * SidebarCollapsible, that branch's parent row (the first row still on show).\n */\nfunction indicatorTarget(content: HTMLElement): HTMLElement | null {\n const actives = [...content.querySelectorAll<HTMLElement>(\"[data-slot=sidebar-item][data-active=true]\")]\n // A parent row is lit alongside its current child: the child, the deepest one, is the target.\n const active = actives.find((row) => !row.parentElement?.matches(\"[data-slot=sidebar-collapsible]\")) ?? actives[0]\n if (!active) return null\n // A sub-list that's closing still paints while its exit plays; the pill moves as the fold starts.\n const folding = active.closest(\"[data-slot=sidebar-sub][data-state=closed]\")\n if (active.offsetParent !== null && !folding) return active\n let branch = active.closest<HTMLElement>(\"[data-slot=sidebar-collapsible]\")\n while (branch) {\n const trigger = branch.querySelector<HTMLElement>(\":scope > [data-slot=sidebar-item]\")\n if (trigger && trigger.offsetParent !== null) return trigger\n branch = branch.parentElement?.closest<HTMLElement>(\"[data-slot=sidebar-collapsible]\") ?? null\n }\n return null\n}\n\nexport function SidebarContent({ className, children, ...props }: React.ComponentProps<\"div\">) {\n const { indicator } = useSidebar()\n const rail = useRail()\n const collapsed = rail.collapsed\n const contentRef = React.useRef<HTMLDivElement | null>(null)\n const pillRef = React.useRef<HTMLDivElement | null>(null)\n const glides = indicator && !collapsed\n\n // One highlight that glides to the current row. It's positioned with direct style writes, so a\n // route change or a fold moves it without re-rendering the rail.\n React.useLayoutEffect(() => {\n const content = contentRef.current\n const pill = pillRef.current\n if (!glides || !content || !pill) return\n let first = true\n const place = () => {\n const target = indicatorTarget(content)\n if (!target) {\n pill.style.opacity = \"0\"\n return\n }\n const box = content.getBoundingClientRect()\n const row = target.getBoundingClientRect()\n if (first) pill.style.transition = \"none\"\n pill.style.opacity = \"1\"\n pill.style.height = `${row.height}px`\n pill.style.width = `${row.width}px`\n pill.style.transform = `translate(${row.left - box.left}px, ${row.top - box.top + content.scrollTop}px)`\n if (first) {\n void pill.offsetHeight\n pill.style.transition = \"\"\n first = false\n }\n }\n place()\n const mutations = new MutationObserver(place)\n mutations.observe(content, { subtree: true, attributes: true, attributeFilter: [\"data-active\", \"data-state\"], childList: true })\n const resize = new ResizeObserver(place)\n resize.observe(content)\n return () => {\n mutations.disconnect()\n resize.disconnect()\n }\n }, [glides])\n\n return (\n <div\n ref={contentRef}\n data-slot=\"sidebar-content\"\n data-indicator={glides || undefined}\n className={sidebarVariants(rail).content({\n className: [glides && \"[&_[data-slot=sidebar-item][data-active=true]]:bg-transparent\", className],\n })}\n {...props}\n >\n {glides ? (\n <div\n ref={pillRef}\n aria-hidden=\"true\"\n data-slot=\"sidebar-indicator\"\n className=\"pointer-events-none absolute top-0 left-0 rounded-md bg-accent opacity-0 transition-[transform,height,width,opacity] duration-base ease-out motion-reduce-fade\"\n />\n ) : null}\n {children}\n </div>\n )\n}\n\nexport function SidebarFooter({ className, ...props }: React.ComponentProps<\"div\">) {\n return (\n <div data-slot=\"sidebar-footer\" className={sidebarVariants(useRail()).footer({ className })} {...props} />\n )\n}\n\nexport interface SidebarActionsProps extends React.ComponentProps<\"div\"> {\n /** The height every control in the cluster takes. */\n size?: ButtonSize\n}\n\n/** Icon buttons beside a switcher, pushed to the zone's far edge; they stack under the mark when collapsed. */\nexport function SidebarActions({ className, size = \"sm\", children, ...props }: SidebarActionsProps) {\n const { collapsed } = useRail()\n return (\n <div\n data-slot=\"sidebar-actions\"\n data-control-size={size}\n className={sidebarVariants({ collapsed }).actions({ className })}\n {...props}\n >\n <ControlSizeProvider size={size}>{children}</ControlSizeProvider>\n </div>\n )\n}\n\nexport interface SidebarSwitcherProps extends Omit<React.ComponentProps<\"button\">, \"title\"> {\n /** The workspace or profile name. */\n title: React.ReactNode\n /** Plan, email or role. */\n subtitle?: React.ReactNode\n /** An Avatar, a logo tile or an icon. */\n leading?: React.ReactNode\n /** The trailing up and down caret. */\n caret?: boolean\n /** default is the compact trigger; full the roomier identity row. */\n variant?: \"default\" | \"full\"\n}\n\n/** The identity row for the workspace or profile switcher: a real button for DropdownMenuTrigger asChild. */\nexport function SidebarSwitcher({\n className,\n title,\n subtitle,\n leading,\n caret = true,\n variant = \"default\",\n type = \"button\",\n ...props\n}: SidebarSwitcherProps) {\n const { collapsed, stacked, density } = useRail()\n const { peek } = useSidebar()\n const slots = sidebarVariants({ collapsed, stacked, density, switcherVariant: variant })\n return (\n <button\n type={type}\n data-slot=\"sidebar-switcher\"\n aria-label={collapsed && !peek && typeof title === \"string\" ? title : undefined}\n className={slots.switcher({ className })}\n {...props}\n >\n {leading}\n <span data-slot=\"sidebar-switcher-text\" className={slots.switcherText()}>\n <span className={slots.switcherTitle()}>{title}</span>\n {subtitle ? <span className={slots.switcherSubtitle()}>{subtitle}</span> : null}\n </span>\n {caret ? <CaretUpDown aria-hidden=\"true\" data-slot=\"sidebar-switcher-caret\" className={slots.switcherCaret()} /> : null}\n </button>\n )\n}\n\nexport function SidebarSeparator({ className, ...props }: React.ComponentProps<\"div\">) {\n return <div role=\"separator\" data-slot=\"sidebar-separator\" className={sidebarVariants().separator({ className })} {...props} />\n}\n"],"mappings":";AAsFM,cA8FF,YA9FE;AApFN,YAAY,WAAW;AACvB,SAAS,mBAAmB;AAE5B,SAAS,qBAAqB,kBAAiD;AAC/E,SAAS,uBAAuB;AAmBhC,MAAM,iBAAiB,MAAM,cAAmC;AAAA,EAC9D,WAAW;AAAA,EACX,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,SAAS;AAAA,EACT,MAAM;AAAA,EACN,WAAW;AAAA,EACX,MAAM;AACR,CAAC;AAEM,SAAS,aAAa;AAC3B,SAAO,MAAM,WAAW,cAAc;AACxC;AAMO,MAAM,sBAAsB,MAAM,cAAgF,IAAI;AAmBtH,SAAS,QAAQ;AAAA,EACtB;AAAA,EACA,WAAW;AAAA,EACX,SAAS;AAAA,EACT,OAAO;AAAA,EACP,YAAY;AAAA,EACZ,OAAO;AAAA,EACP,WAAW;AAAA,EACX,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,GAAG;AACL,GAAiB;AACf,QAAM,QAAQ,MAAM,WAAW,mBAAmB;AAClD,QAAM,YAAY,iBAAiB,OAAO,aAAa;AAEvD,QAAM,UAAU,cAAc,OAAO,UAAU,UAAU,CAAC;AAC1D,QAAM,UAAU,WAAW,WAAW;AACtC,QAAM,OAAO,cAAc,OAAO,QAAQ;AAC1C,QAAM,UAAU,MAAM;AAAA,IACpB,OAAO,EAAE,WAAW,QAAQ,MAAM,SAAS,MAAM,WAAW,KAAK;AAAA,IACjE,CAAC,WAAW,QAAQ,MAAM,SAAS,MAAM,WAAW,IAAI;AAAA,EAC1D;AACA,SACE,oBAAC,eAAe,UAAf,EAAwB,OAAO,SAC9B;AAAA,IAAC;AAAA;AAAA,MACC,aAAU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