@brett_lamy/ui 2.0.0 → 3.1.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 +12 -5
- package/dist/components/adaptive-pane.d.ts.map +1 -1
- package/dist/components/adaptive-pane.js +30 -0
- package/dist/components/animated-height.d.ts.map +1 -1
- package/dist/components/animated-height.js +82 -0
- package/dist/{templates → components}/artifact-chat-container.d.ts +12 -5
- package/dist/components/artifact-chat-container.d.ts.map +1 -0
- package/dist/components/artifact-chat-container.js +200 -0
- package/dist/components/avatar.js +26 -0
- package/dist/components/badge.js +24 -0
- package/dist/components/button.d.ts.map +1 -1
- package/dist/components/button.js +46 -0
- package/dist/components/card.js +56 -0
- package/dist/components/celebrate.d.ts.map +1 -1
- package/dist/components/celebrate.js +142 -0
- package/dist/components/chat-column.d.ts.map +1 -0
- package/dist/components/chat-column.js +26 -0
- package/dist/components/checkbox.d.ts +2 -2
- package/dist/components/checkbox.d.ts.map +1 -1
- package/dist/components/checkbox.js +55 -0
- package/dist/components/combobox.d.ts +1 -1
- package/dist/components/combobox.d.ts.map +1 -1
- package/dist/components/combobox.js +65 -0
- package/dist/components/command-menu.d.ts.map +1 -1
- package/dist/components/command-menu.js +906 -0
- package/dist/components/composer/annotator.d.ts.map +1 -0
- package/dist/components/composer/annotator.js +17 -0
- package/dist/components/composer/composer-files.d.ts.map +1 -0
- package/dist/components/composer/composer-files.js +91 -0
- package/dist/components/{workbench/wb-popover.d.ts → composer/composer-popover.d.ts} +1 -1
- package/dist/components/composer/composer-popover.d.ts.map +1 -0
- package/dist/components/composer/composer-popover.js +29 -0
- package/dist/components/{workbench → composer}/composer.d.ts +3 -3
- package/dist/components/composer/composer.d.ts.map +1 -0
- package/dist/components/composer/composer.js +1633 -0
- package/dist/components/{workbench/chat.d.ts → conversation.d.ts} +2 -2
- package/dist/components/conversation.d.ts.map +1 -0
- package/dist/components/conversation.js +357 -0
- package/dist/components/credenza.d.ts.map +1 -1
- package/dist/components/credenza.js +294 -0
- package/dist/components/dialog.d.ts +2 -2
- package/dist/components/dialog.d.ts.map +1 -1
- package/dist/components/dialog.js +125 -0
- package/dist/components/disclosure.d.ts.map +1 -1
- package/dist/components/disclosure.js +59 -0
- package/dist/components/dropdown-menu.d.ts +1 -1
- package/dist/components/dropdown-menu.d.ts.map +1 -1
- package/dist/components/dropdown-menu.js +114 -0
- package/dist/components/edge-drawer.js +73 -0
- package/dist/components/edit-bar.d.ts.map +1 -1
- package/dist/components/edit-bar.js +33 -0
- package/dist/components/{chat/floating-chat.d.ts → floating-chat.d.ts} +8 -4
- package/dist/components/floating-chat.d.ts.map +1 -0
- package/dist/components/floating-chat.js +288 -0
- package/dist/components/{chat/floating-sheet.d.ts → floating-sheet.d.ts} +5 -5
- package/dist/components/floating-sheet.d.ts.map +1 -0
- package/dist/components/floating-sheet.js +252 -0
- package/dist/components/form.d.ts.map +1 -1
- package/dist/components/form.js +32 -0
- package/dist/{lib/workbench/icons.d.ts → components/icon-button.d.ts} +5 -5
- package/dist/components/icon-button.d.ts.map +1 -0
- package/dist/components/icon-button.js +31 -0
- package/dist/components/icon-swap.d.ts.map +1 -1
- package/dist/components/icon-swap.js +80 -0
- package/dist/components/index-bar.d.ts +14 -1
- package/dist/components/index-bar.d.ts.map +1 -1
- package/dist/components/index-bar.js +249 -0
- package/dist/components/input.d.ts.map +1 -1
- package/dist/components/input.js +30 -0
- package/dist/components/kbd.d.ts.map +1 -1
- package/dist/components/kbd.js +21 -0
- package/dist/components/label.d.ts.map +1 -1
- package/dist/components/label.js +22 -0
- package/dist/components/list-box.d.ts +1 -3
- package/dist/components/list-box.d.ts.map +1 -1
- package/dist/components/list-box.js +104 -0
- package/dist/components/list.d.ts.map +1 -1
- package/dist/components/list.js +491 -0
- package/dist/components/markdown-editor.d.ts.map +1 -1
- package/dist/components/markdown-editor.js +322 -0
- package/dist/components/{workbench/markdown.d.ts → markdown-view.d.ts} +1 -1
- package/dist/components/markdown-view.d.ts.map +1 -0
- package/dist/components/markdown-view.js +129 -0
- package/dist/components/measure-h.d.ts.map +1 -1
- package/dist/components/measure-h.js +20 -0
- package/dist/components/message-scroller.d.ts.map +1 -0
- package/dist/components/message-scroller.js +247 -0
- package/dist/components/morph.d.ts.map +1 -1
- package/dist/components/morph.js +89 -0
- package/dist/components/navigation-stack.d.ts +14 -0
- package/dist/components/navigation-stack.d.ts.map +1 -1
- package/dist/components/navigation-stack.js +506 -0
- package/dist/components/now-playing-bars.js +38 -0
- package/dist/components/number-morph.d.ts.map +1 -1
- package/dist/components/number-morph.js +123 -0
- package/dist/components/pencilkit/constants.d.ts.map +1 -0
- package/dist/components/pencilkit/constants.js +63 -0
- package/dist/components/pencilkit/pencil-canvas.d.ts +1 -1
- package/dist/components/pencilkit/pencil-canvas.d.ts.map +1 -1
- package/dist/components/pencilkit/pencil-canvas.js +105 -0
- package/dist/components/pencilkit/pencil-toolbar.d.ts +2 -2
- package/dist/components/pencilkit/pencil-toolbar.d.ts.map +1 -1
- package/dist/components/pencilkit/pencil-toolbar.js +186 -0
- package/dist/components/pencilkit/pencilkit-annotator.d.ts +1 -1
- package/dist/components/pencilkit/pencilkit-annotator.d.ts.map +1 -1
- package/dist/components/pencilkit/pencilkit-annotator.js +44 -0
- package/dist/components/pencilkit/stroke-path.d.ts +1 -1
- package/dist/components/pencilkit/stroke-path.d.ts.map +1 -1
- package/dist/components/pencilkit/stroke-path.js +44 -0
- package/dist/components/pencilkit/use-pencil-history.d.ts +2 -2
- package/dist/components/pencilkit/use-pencil-history.d.ts.map +1 -1
- package/dist/components/pencilkit/use-pencil-history.js +25 -0
- package/dist/components/plain-button.d.ts +10 -0
- package/dist/components/plain-button.d.ts.map +1 -0
- package/dist/components/plain-button.js +23 -0
- package/dist/components/popover.d.ts +1 -1
- package/dist/components/popover.d.ts.map +1 -1
- package/dist/components/popover.js +36 -0
- package/dist/components/progress-ring.d.ts.map +1 -1
- package/dist/components/progress-ring.js +195 -0
- package/dist/components/progress-stepper.d.ts.map +1 -0
- package/dist/components/progress-stepper.js +62 -0
- package/dist/components/progress.d.ts.map +1 -1
- package/dist/components/progress.js +54 -0
- package/dist/components/qr-svg.d.ts.map +1 -1
- package/dist/components/qr-svg.js +74 -0
- package/dist/components/radio-group.d.ts +1 -1
- package/dist/components/radio-group.d.ts.map +1 -1
- package/dist/components/radio-group.js +41 -0
- package/dist/components/replay-preview.d.ts +4 -0
- package/dist/components/replay-preview.d.ts.map +1 -0
- package/dist/components/replay-preview.js +3 -0
- package/dist/components/scroll-area.js +23 -0
- package/dist/components/search-field.d.ts.map +1 -1
- package/dist/components/search-field.js +44 -0
- package/dist/components/segmented.d.ts +1 -1
- package/dist/components/segmented.d.ts.map +1 -1
- package/dist/components/segmented.js +32 -0
- package/dist/components/select.d.ts +1 -1
- package/dist/components/select.d.ts.map +1 -1
- package/dist/components/select.js +93 -0
- package/dist/components/separator.d.ts.map +1 -1
- package/dist/components/separator.js +40 -0
- package/dist/components/sheet.d.ts.map +1 -1
- package/dist/components/sheet.js +55 -0
- package/dist/components/side-drawer.d.ts +10 -1
- package/dist/components/side-drawer.d.ts.map +1 -1
- package/dist/components/side-drawer.js +247 -0
- package/dist/components/sidebar.d.ts.map +1 -1
- package/dist/components/sidebar.js +282 -0
- package/dist/components/skeleton.js +48 -0
- package/dist/components/slider.d.ts +1 -1
- package/dist/components/slider.d.ts.map +1 -1
- package/dist/components/slider.js +98 -0
- package/dist/components/snap-sheet.d.ts.map +1 -0
- package/dist/components/snap-sheet.js +100 -0
- package/dist/components/spinner.js +35 -0
- package/dist/components/split-view.d.ts.map +1 -1
- package/dist/components/split-view.js +1060 -0
- package/dist/components/switch.d.ts.map +1 -1
- package/dist/components/switch.js +27 -0
- package/dist/components/syntax-highlighting.d.ts.map +1 -1
- package/dist/components/syntax-highlighting.js +293 -0
- package/dist/components/tab-bar.js +28 -0
- package/dist/components/tab-view.d.ts +1 -1
- package/dist/components/tab-view.d.ts.map +1 -1
- package/dist/components/tab-view.js +307 -0
- package/dist/components/tabs.d.ts +1 -1
- package/dist/components/tabs.d.ts.map +1 -1
- package/dist/components/tabs.js +86 -0
- package/dist/components/text-field.d.ts.map +1 -1
- package/dist/components/text-field.js +29 -0
- package/dist/components/text-morph.d.ts.map +1 -1
- package/dist/components/text-morph.js +131 -0
- package/dist/components/textarea.d.ts.map +1 -1
- package/dist/components/textarea.js +30 -0
- package/dist/components/toast.d.ts +0 -2
- package/dist/components/toast.d.ts.map +1 -1
- package/dist/components/toast.js +302 -0
- package/dist/components/toggle-group.d.ts +1 -1
- package/dist/components/toggle-group.d.ts.map +1 -1
- package/dist/components/toggle-group.js +48 -0
- package/dist/components/toggle.d.ts +1 -1
- package/dist/components/toggle.d.ts.map +1 -1
- package/dist/components/toggle.js +42 -0
- package/dist/components/tooltip.d.ts +1 -1
- package/dist/components/tooltip.d.ts.map +1 -1
- package/dist/components/tooltip.js +42 -0
- package/dist/{lib/workbench/theme.d.ts → components/workbench-theme.d.ts} +2 -2
- package/dist/components/workbench-theme.d.ts.map +1 -0
- package/dist/components/workbench-theme.js +34 -0
- package/dist/index.css +1 -1
- package/dist/index.d.ts +29 -47
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +94 -20350
- package/dist/lib/append-stream.d.ts +43 -0
- package/dist/lib/append-stream.d.ts.map +1 -0
- package/dist/lib/append-stream.js +128 -0
- package/dist/lib/container.d.ts.map +1 -1
- package/dist/lib/container.js +49 -0
- package/dist/lib/durable-streams.d.ts +102 -0
- package/dist/lib/durable-streams.d.ts.map +1 -0
- package/dist/lib/durable-streams.js +280 -0
- package/dist/lib/icon-shapes/chat.js +13 -0
- package/dist/lib/icon-shapes/pencilkit.js +20 -0
- package/dist/lib/icon-shapes/workbench.js +47 -0
- package/dist/lib/icon.d.ts +1 -1
- package/dist/lib/icon.d.ts.map +1 -1
- package/dist/lib/icon.js +1774 -0
- package/dist/lib/motion.d.ts +16 -0
- package/dist/lib/motion.d.ts.map +1 -1
- package/dist/lib/motion.js +104 -0
- package/dist/lib/{chat/persistent-host.d.ts → persistent-host.d.ts} +1 -1
- package/dist/lib/persistent-host.d.ts.map +1 -0
- package/dist/lib/persistent-host.js +41 -0
- package/dist/lib/primitives.js +8 -0
- package/dist/lib/qr.js +552 -0
- package/dist/lib/row-label.d.ts.map +1 -1
- package/dist/lib/row-label.js +10 -0
- package/dist/lib/session-recorder.d.ts +87 -0
- package/dist/lib/session-recorder.d.ts.map +1 -0
- package/dist/lib/session-recorder.js +257 -0
- package/dist/lib/sheet-drag.d.ts +1 -1
- package/dist/lib/sheet-drag.d.ts.map +1 -1
- package/dist/lib/sheet-drag.js +128 -0
- package/dist/lib/syntax.js +204 -0
- package/dist/lib/theme.d.ts +33 -8
- package/dist/lib/theme.d.ts.map +1 -1
- package/dist/lib/theme.js +138 -0
- package/dist/lib/tokens.generated.d.ts +16 -0
- package/dist/lib/tokens.generated.d.ts.map +1 -0
- package/dist/lib/tokens.generated.js +22 -0
- package/dist/lib/utils.d.ts +5 -0
- package/dist/lib/utils.d.ts.map +1 -1
- package/dist/lib/utils.js +18 -0
- package/dist/theme.css +0 -60
- package/package.json +5 -7
- package/dist/components/adaptive-pane.stories.d.ts +0 -7
- package/dist/components/adaptive-pane.stories.d.ts.map +0 -1
- package/dist/components/avatar.stories.d.ts +0 -9
- package/dist/components/avatar.stories.d.ts.map +0 -1
- package/dist/components/badge.stories.d.ts +0 -9
- package/dist/components/badge.stories.d.ts.map +0 -1
- package/dist/components/button.stories.d.ts +0 -11
- package/dist/components/button.stories.d.ts.map +0 -1
- package/dist/components/card.stories.d.ts +0 -9
- package/dist/components/card.stories.d.ts.map +0 -1
- package/dist/components/chat/chat-column.d.ts.map +0 -1
- package/dist/components/chat/chat-column.stories.d.ts +0 -9
- package/dist/components/chat/chat-column.stories.d.ts.map +0 -1
- package/dist/components/chat/floating-chat.d.ts.map +0 -1
- package/dist/components/chat/floating-chat.stories.d.ts +0 -17
- package/dist/components/chat/floating-chat.stories.d.ts.map +0 -1
- package/dist/components/chat/floating-sheet.d.ts.map +0 -1
- package/dist/components/chat/floating-sheet.stories.d.ts +0 -22
- package/dist/components/chat/floating-sheet.stories.d.ts.map +0 -1
- package/dist/components/chat/progress-stepper.d.ts.map +0 -1
- package/dist/components/checkbox.stories.d.ts +0 -11
- package/dist/components/checkbox.stories.d.ts.map +0 -1
- package/dist/components/combobox.stories.d.ts +0 -10
- package/dist/components/combobox.stories.d.ts.map +0 -1
- package/dist/components/command-menu.stories.d.ts +0 -17
- package/dist/components/command-menu.stories.d.ts.map +0 -1
- package/dist/components/credenza.stories.d.ts +0 -8
- package/dist/components/credenza.stories.d.ts.map +0 -1
- package/dist/components/dialog.stories.d.ts +0 -12
- package/dist/components/dialog.stories.d.ts.map +0 -1
- package/dist/components/disclosure.stories.d.ts +0 -10
- package/dist/components/disclosure.stories.d.ts.map +0 -1
- package/dist/components/dropdown-menu.stories.d.ts +0 -11
- package/dist/components/dropdown-menu.stories.d.ts.map +0 -1
- package/dist/components/edge-drawer.stories.d.ts +0 -8
- package/dist/components/edge-drawer.stories.d.ts.map +0 -1
- package/dist/components/edit-bar.stories.d.ts +0 -10
- package/dist/components/edit-bar.stories.d.ts.map +0 -1
- package/dist/components/form.stories.d.ts +0 -9
- package/dist/components/form.stories.d.ts.map +0 -1
- package/dist/components/haptic-indicator.d.ts +0 -11
- package/dist/components/haptic-indicator.d.ts.map +0 -1
- package/dist/components/haptic-indicator.stories.d.ts +0 -8
- package/dist/components/haptic-indicator.stories.d.ts.map +0 -1
- package/dist/components/index-bar.stories.d.ts +0 -12
- package/dist/components/index-bar.stories.d.ts.map +0 -1
- package/dist/components/input.stories.d.ts +0 -10
- package/dist/components/input.stories.d.ts.map +0 -1
- package/dist/components/kbd.stories.d.ts +0 -9
- package/dist/components/kbd.stories.d.ts.map +0 -1
- package/dist/components/label.stories.d.ts +0 -8
- package/dist/components/label.stories.d.ts.map +0 -1
- package/dist/components/list-box.stories.d.ts +0 -9
- package/dist/components/list-box.stories.d.ts.map +0 -1
- package/dist/components/list-row.stories.d.ts +0 -24
- package/dist/components/list-row.stories.d.ts.map +0 -1
- package/dist/components/list.stories.d.ts +0 -27
- package/dist/components/list.stories.d.ts.map +0 -1
- package/dist/components/markdown-editor.stories.d.ts +0 -17
- package/dist/components/markdown-editor.stories.d.ts.map +0 -1
- package/dist/components/morph.stories.d.ts +0 -14
- package/dist/components/morph.stories.d.ts.map +0 -1
- package/dist/components/motion.stories.d.ts +0 -15
- package/dist/components/motion.stories.d.ts.map +0 -1
- package/dist/components/navigation-stack.stories.d.ts +0 -31
- package/dist/components/navigation-stack.stories.d.ts.map +0 -1
- package/dist/components/now-playing-bars.stories.d.ts +0 -12
- package/dist/components/now-playing-bars.stories.d.ts.map +0 -1
- package/dist/components/pencilkit/pencil-canvas.stories.d.ts +0 -18
- package/dist/components/pencilkit/pencil-canvas.stories.d.ts.map +0 -1
- package/dist/components/pencilkit/pencil-toolbar.stories.d.ts +0 -10
- package/dist/components/pencilkit/pencil-toolbar.stories.d.ts.map +0 -1
- package/dist/components/popover.stories.d.ts +0 -9
- package/dist/components/popover.stories.d.ts.map +0 -1
- package/dist/components/progress-ring.stories.d.ts +0 -15
- package/dist/components/progress-ring.stories.d.ts.map +0 -1
- package/dist/components/progress.stories.d.ts +0 -10
- package/dist/components/progress.stories.d.ts.map +0 -1
- package/dist/components/qr-svg.stories.d.ts +0 -16
- package/dist/components/qr-svg.stories.d.ts.map +0 -1
- package/dist/components/radio-group.stories.d.ts +0 -10
- package/dist/components/radio-group.stories.d.ts.map +0 -1
- package/dist/components/scroll-area.stories.d.ts +0 -8
- package/dist/components/scroll-area.stories.d.ts.map +0 -1
- package/dist/components/search-field.stories.d.ts +0 -10
- package/dist/components/search-field.stories.d.ts.map +0 -1
- package/dist/components/segmented.stories.d.ts +0 -8
- package/dist/components/segmented.stories.d.ts.map +0 -1
- package/dist/components/select.stories.d.ts +0 -12
- package/dist/components/select.stories.d.ts.map +0 -1
- package/dist/components/separator.stories.d.ts +0 -9
- package/dist/components/separator.stories.d.ts.map +0 -1
- package/dist/components/sheet.stories.d.ts +0 -12
- package/dist/components/sheet.stories.d.ts.map +0 -1
- package/dist/components/side-drawer.stories.d.ts +0 -8
- package/dist/components/side-drawer.stories.d.ts.map +0 -1
- package/dist/components/sidebar.stories.d.ts +0 -10
- package/dist/components/sidebar.stories.d.ts.map +0 -1
- package/dist/components/skeleton.stories.d.ts +0 -11
- package/dist/components/skeleton.stories.d.ts.map +0 -1
- package/dist/components/slider.stories.d.ts +0 -12
- package/dist/components/slider.stories.d.ts.map +0 -1
- package/dist/components/spinner.stories.d.ts +0 -9
- package/dist/components/spinner.stories.d.ts.map +0 -1
- package/dist/components/split-view.stories.d.ts +0 -58
- package/dist/components/split-view.stories.d.ts.map +0 -1
- package/dist/components/switch.stories.d.ts +0 -9
- package/dist/components/switch.stories.d.ts.map +0 -1
- package/dist/components/syntax-highlighting.stories.d.ts +0 -18
- package/dist/components/syntax-highlighting.stories.d.ts.map +0 -1
- package/dist/components/tab-bar.stories.d.ts +0 -8
- package/dist/components/tab-bar.stories.d.ts.map +0 -1
- package/dist/components/tab-view.stories.d.ts +0 -37
- package/dist/components/tab-view.stories.d.ts.map +0 -1
- package/dist/components/tabs.stories.d.ts +0 -9
- package/dist/components/tabs.stories.d.ts.map +0 -1
- package/dist/components/text-field.stories.d.ts +0 -9
- package/dist/components/text-field.stories.d.ts.map +0 -1
- package/dist/components/toast.stories.d.ts +0 -13
- package/dist/components/toast.stories.d.ts.map +0 -1
- package/dist/components/toggle-group.stories.d.ts +0 -10
- package/dist/components/toggle-group.stories.d.ts.map +0 -1
- package/dist/components/toggle.stories.d.ts +0 -9
- package/dist/components/toggle.stories.d.ts.map +0 -1
- package/dist/components/tooltip.stories.d.ts +0 -11
- package/dist/components/tooltip.stories.d.ts.map +0 -1
- package/dist/components/workbench/annotator.d.ts.map +0 -1
- package/dist/components/workbench/chat.d.ts.map +0 -1
- package/dist/components/workbench/chat.stories.d.ts +0 -13
- package/dist/components/workbench/chat.stories.d.ts.map +0 -1
- package/dist/components/workbench/composer-files.d.ts.map +0 -1
- package/dist/components/workbench/composer.d.ts.map +0 -1
- package/dist/components/workbench/composer.stories.d.ts +0 -35
- package/dist/components/workbench/composer.stories.d.ts.map +0 -1
- package/dist/components/workbench/fixtures.d.ts +0 -38
- package/dist/components/workbench/fixtures.d.ts.map +0 -1
- package/dist/components/workbench/markdown.d.ts.map +0 -1
- package/dist/components/workbench/message-scroller.d.ts.map +0 -1
- package/dist/components/workbench/message-scroller.stories.d.ts +0 -9
- package/dist/components/workbench/message-scroller.stories.d.ts.map +0 -1
- package/dist/components/workbench/model-picker.d.ts +0 -29
- package/dist/components/workbench/model-picker.d.ts.map +0 -1
- package/dist/components/workbench/models.d.ts +0 -32
- package/dist/components/workbench/models.d.ts.map +0 -1
- package/dist/components/workbench/snap-sheet.d.ts.map +0 -1
- package/dist/components/workbench/snap-sheet.stories.d.ts +0 -8
- package/dist/components/workbench/snap-sheet.stories.d.ts.map +0 -1
- package/dist/components/workbench/surfaces.d.ts +0 -67
- package/dist/components/workbench/surfaces.d.ts.map +0 -1
- package/dist/components/workbench/surfaces.stories.d.ts +0 -15
- package/dist/components/workbench/surfaces.stories.d.ts.map +0 -1
- package/dist/components/workbench/terminal.d.ts +0 -51
- package/dist/components/workbench/terminal.d.ts.map +0 -1
- package/dist/components/workbench/terminal.stories.d.ts +0 -8
- package/dist/components/workbench/terminal.stories.d.ts.map +0 -1
- package/dist/components/workbench/wb-popover.d.ts.map +0 -1
- package/dist/components/workbench/workbench-composer.d.ts +0 -26
- package/dist/components/workbench/workbench-composer.d.ts.map +0 -1
- package/dist/demos/delivery/delivery-tracking-demo.d.ts +0 -41
- package/dist/demos/delivery/delivery-tracking-demo.d.ts.map +0 -1
- package/dist/demos/delivery/delivery-tracking-demo.stories.d.ts +0 -13
- package/dist/demos/delivery/delivery-tracking-demo.stories.d.ts.map +0 -1
- package/dist/demos/haptics-playground.d.ts +0 -18
- package/dist/demos/haptics-playground.d.ts.map +0 -1
- package/dist/demos/haptics-playground.stories.d.ts +0 -8
- package/dist/demos/haptics-playground.stories.d.ts.map +0 -1
- package/dist/demos/map-chat/geo.d.ts +0 -46
- package/dist/demos/map-chat/geo.d.ts.map +0 -1
- package/dist/demos/map-chat/map-agent.d.ts +0 -48
- package/dist/demos/map-chat/map-agent.d.ts.map +0 -1
- package/dist/demos/map-chat/map-chat-demo.d.ts +0 -19
- package/dist/demos/map-chat/map-chat-demo.d.ts.map +0 -1
- package/dist/demos/map-chat/map-chat-demo.stories.d.ts +0 -16
- package/dist/demos/map-chat/map-chat-demo.stories.d.ts.map +0 -1
- package/dist/demos/map-chat/map-icons.d.ts +0 -44
- package/dist/demos/map-chat/map-icons.d.ts.map +0 -1
- package/dist/demos/map-chat/places.d.ts +0 -29
- package/dist/demos/map-chat/places.d.ts.map +0 -1
- package/dist/demos/map-chat/tile-map.d.ts +0 -108
- package/dist/demos/map-chat/tile-map.d.ts.map +0 -1
- package/dist/demos/pencilkit/demo-strokes.d.ts +0 -4
- package/dist/demos/pencilkit/demo-strokes.d.ts.map +0 -1
- package/dist/demos/pencilkit/pencilkit-demo.d.ts +0 -17
- package/dist/demos/pencilkit/pencilkit-demo.d.ts.map +0 -1
- package/dist/demos/pencilkit/pencilkit-demo.stories.d.ts +0 -11
- package/dist/demos/pencilkit/pencilkit-demo.stories.d.ts.map +0 -1
- package/dist/demos/sidebar-demo.d.ts +0 -6
- package/dist/demos/sidebar-demo.d.ts.map +0 -1
- package/dist/demos/split-view-demos.d.ts +0 -50
- package/dist/demos/split-view-demos.d.ts.map +0 -1
- package/dist/lib/chat/chat-shell-context.d.ts +0 -20
- package/dist/lib/chat/chat-shell-context.d.ts.map +0 -1
- package/dist/lib/chat/persistent-host.d.ts.map +0 -1
- package/dist/lib/haptics.d.ts +0 -27
- package/dist/lib/haptics.d.ts.map +0 -1
- package/dist/lib/icon.stories.d.ts +0 -15
- package/dist/lib/icon.stories.d.ts.map +0 -1
- package/dist/lib/pencilkit/constants.d.ts.map +0 -1
- package/dist/lib/workbench/haptics.d.ts +0 -3
- package/dist/lib/workbench/haptics.d.ts.map +0 -1
- package/dist/lib/workbench/icons.d.ts.map +0 -1
- package/dist/lib/workbench/motion.d.ts +0 -19
- package/dist/lib/workbench/motion.d.ts.map +0 -1
- package/dist/lib/workbench/press.d.ts +0 -10
- package/dist/lib/workbench/press.d.ts.map +0 -1
- package/dist/lib/workbench/theme.d.ts.map +0 -1
- package/dist/lib/workbench/util.d.ts +0 -8
- package/dist/lib/workbench/util.d.ts.map +0 -1
- package/dist/stories/frame.d.ts +0 -16
- package/dist/stories/frame.d.ts.map +0 -1
- package/dist/stories/primitive-frame.d.ts +0 -20
- package/dist/stories/primitive-frame.d.ts.map +0 -1
- package/dist/templates/artifact-chat-container.d.ts.map +0 -1
- package/dist/templates/artifact-chat-container.stories.d.ts +0 -24
- package/dist/templates/artifact-chat-container.stories.d.ts.map +0 -1
- package/dist/templates/chat-shell.d.ts +0 -87
- package/dist/templates/chat-shell.d.ts.map +0 -1
- package/dist/templates/workbench-shell.d.ts +0 -177
- package/dist/templates/workbench-shell.d.ts.map +0 -1
- package/dist/templates/workbench-shell.stories.d.ts +0 -17
- package/dist/templates/workbench-shell.stories.d.ts.map +0 -1
- /package/dist/components/{chat/chat-column.d.ts → chat-column.d.ts} +0 -0
- /package/dist/components/{workbench → composer}/annotator.d.ts +0 -0
- /package/dist/components/{workbench → composer}/composer-files.d.ts +0 -0
- /package/dist/components/{workbench/message-scroller.d.ts → message-scroller.d.ts} +0 -0
- /package/dist/{lib → components}/pencilkit/constants.d.ts +0 -0
- /package/dist/components/{chat/progress-stepper.d.ts → progress-stepper.d.ts} +0 -0
- /package/dist/components/{workbench/snap-sheet.d.ts → snap-sheet.d.ts} +0 -0
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { cn as e } from "../lib/utils.js";
|
|
3
|
+
import { Popover as t } from "./popover.js";
|
|
4
|
+
import { ListBox as n, ListBoxItem as r, ListBoxSection as i } from "./list-box.js";
|
|
5
|
+
import { Fragment as a, jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
6
|
+
import { Button as c, Select as l, SelectValue as u, composeRenderProps as d } from "react-aria-components";
|
|
7
|
+
import { cva as f } from "class-variance-authority";
|
|
8
|
+
//#region src/components/select.tsx
|
|
9
|
+
function p({ className: t, ...n }) {
|
|
10
|
+
return /* @__PURE__ */ o(l, {
|
|
11
|
+
"data-slot": "select",
|
|
12
|
+
className: d(t, (t) => e("group flex flex-col gap-1.5", t)),
|
|
13
|
+
...n
|
|
14
|
+
});
|
|
15
|
+
}
|
|
16
|
+
var m = f([
|
|
17
|
+
"bl-btn box-border flex w-full cursor-pointer items-center justify-between gap-2 border-0 px-3 text-left [font-family:inherit] text-foreground outline-none",
|
|
18
|
+
"transition-[background-color,box-shadow] duration-spring-snappy ease-spring-snappy data-pressed:bg-secondary-strong",
|
|
19
|
+
"data-focus-visible:ring-[3px] data-focus-visible:ring-ring/45 group-data-open:shadow-[inset_0_0_0_1.5px_var(--primary)]",
|
|
20
|
+
"group-data-invalid:shadow-[inset_0_0_0_1.5px_var(--destructive)] data-disabled:cursor-default data-disabled:opacity-50"
|
|
21
|
+
], {
|
|
22
|
+
variants: {
|
|
23
|
+
variant: {
|
|
24
|
+
default: "bg-input",
|
|
25
|
+
plain: "w-auto justify-end bg-transparent px-1 text-muted-foreground data-pressed:bg-transparent data-pressed:opacity-60 group-data-open:shadow-none"
|
|
26
|
+
},
|
|
27
|
+
size: {
|
|
28
|
+
sm: "h-8 rounded-lg text-subhead",
|
|
29
|
+
default: "h-11 rounded-ctl text-body"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
defaultVariants: {
|
|
33
|
+
variant: "default",
|
|
34
|
+
size: "default"
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
function h() {
|
|
38
|
+
return /* @__PURE__ */ o("svg", {
|
|
39
|
+
viewBox: "0 0 24 24",
|
|
40
|
+
width: 16,
|
|
41
|
+
height: 16,
|
|
42
|
+
"aria-hidden": "true",
|
|
43
|
+
className: "shrink-0 opacity-70",
|
|
44
|
+
children: /* @__PURE__ */ o("path", {
|
|
45
|
+
d: "M8 9.5l4-4 4 4M8 14.5l4 4 4-4",
|
|
46
|
+
fill: "none",
|
|
47
|
+
stroke: "currentColor",
|
|
48
|
+
strokeWidth: 2.2,
|
|
49
|
+
strokeLinecap: "round",
|
|
50
|
+
strokeLinejoin: "round"
|
|
51
|
+
})
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
function g({ className: t, variant: n, size: r, children: i, ...l }) {
|
|
55
|
+
return /* @__PURE__ */ o(c, {
|
|
56
|
+
"data-slot": "select-trigger",
|
|
57
|
+
className: d(t, (t) => e(m({
|
|
58
|
+
variant: n,
|
|
59
|
+
size: r
|
|
60
|
+
}), t)),
|
|
61
|
+
...l,
|
|
62
|
+
children: d(i, (e) => /* @__PURE__ */ s(a, { children: [e ?? /* @__PURE__ */ o(_, {}), /* @__PURE__ */ o(h, {})] }))
|
|
63
|
+
});
|
|
64
|
+
}
|
|
65
|
+
function _({ className: t, ...n }) {
|
|
66
|
+
return /* @__PURE__ */ o(u, {
|
|
67
|
+
"data-slot": "select-value",
|
|
68
|
+
className: d(t, (t) => e("min-w-0 flex-1 truncate data-placeholder:text-tertiary-foreground", t)),
|
|
69
|
+
...n
|
|
70
|
+
});
|
|
71
|
+
}
|
|
72
|
+
function v({ placement: r = "bottom start", popoverClassName: i, className: a, ...s }) {
|
|
73
|
+
return /* @__PURE__ */ o(t, {
|
|
74
|
+
"data-slot": "select-content",
|
|
75
|
+
placement: r,
|
|
76
|
+
className: e("min-w-[max(var(--trigger-width),200px)]", i),
|
|
77
|
+
children: /* @__PURE__ */ o(n, {
|
|
78
|
+
variant: "popup",
|
|
79
|
+
className: a,
|
|
80
|
+
...s
|
|
81
|
+
})
|
|
82
|
+
});
|
|
83
|
+
}
|
|
84
|
+
function y(e) {
|
|
85
|
+
return /* @__PURE__ */ o(r, {
|
|
86
|
+
"data-slot": "select-item",
|
|
87
|
+
variant: "popup",
|
|
88
|
+
...e
|
|
89
|
+
});
|
|
90
|
+
}
|
|
91
|
+
var b = i;
|
|
92
|
+
//#endregion
|
|
93
|
+
export { p as Select, v as SelectContent, y as SelectItem, b as SelectSection, g as SelectTrigger, _ as SelectValue, m as selectTriggerVariants };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"separator.d.ts","sourceRoot":"","sources":["../../src/components/separator.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"separator.d.ts","sourceRoot":"","sources":["../../src/components/separator.tsx"],"names":[],"mappings":"AACA,OAAO,EAA8B,KAAK,cAAc,IAAI,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC9G,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAIlE,eAAO,MAAM,iBAAiB;;;8EAW5B,CAAC;AAEH,MAAM,WAAW,cAAe,SAAQ,IAAI,CAAC,kBAAkB,EAAE,aAAa,CAAC,EAAE,YAAY,CAAC,OAAO,iBAAiB,CAAC;CAAG;AAE1H,wBAAgB,SAAS,CAAC,EAAE,SAAS,EAAE,WAA0B,EAAE,KAAK,EAAE,GAAG,KAAK,EAAE,EAAE,cAAc,2CASnG"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { cn as e } from "../lib/utils.js";
|
|
3
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
4
|
+
import { Separator as n } from "react-aria-components";
|
|
5
|
+
import { cva as r } from "class-variance-authority";
|
|
6
|
+
//#region src/components/separator.tsx
|
|
7
|
+
var i = r("m-0 shrink-0 border-0 bg-border", {
|
|
8
|
+
variants: {
|
|
9
|
+
orientation: {
|
|
10
|
+
horizontal: "h-px w-full",
|
|
11
|
+
vertical: "w-px self-stretch"
|
|
12
|
+
},
|
|
13
|
+
inset: {
|
|
14
|
+
true: "",
|
|
15
|
+
false: ""
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
compoundVariants: [{
|
|
19
|
+
orientation: "horizontal",
|
|
20
|
+
inset: !0,
|
|
21
|
+
className: "ml-4 w-[calc(100%-16px)]"
|
|
22
|
+
}],
|
|
23
|
+
defaultVariants: {
|
|
24
|
+
orientation: "horizontal",
|
|
25
|
+
inset: !1
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
function a({ className: r, orientation: a = "horizontal", inset: o, ...s }) {
|
|
29
|
+
return /* @__PURE__ */ t(n, {
|
|
30
|
+
"data-slot": "separator",
|
|
31
|
+
orientation: a ?? "horizontal",
|
|
32
|
+
className: e(i({
|
|
33
|
+
orientation: a,
|
|
34
|
+
inset: o
|
|
35
|
+
}), r),
|
|
36
|
+
...s
|
|
37
|
+
});
|
|
38
|
+
}
|
|
39
|
+
//#endregion
|
|
40
|
+
export { a as Separator, i as separatorVariants };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sheet.d.ts","sourceRoot":"","sources":["../../src/components/sheet.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"sheet.d.ts","sourceRoot":"","sources":["../../src/components/sheet.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,EACiB,KAAK,WAAW,IAAI,eAAe,EACzD,aAAa,EACQ,KAAK,iBAAiB,EAC5C,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAKlE,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,iBAAiB,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAU/G,mGAAmG;AACnG,eAAO,MAAM,KAAK,sBAAgB,CAAC;AAEnC,eAAO,MAAM,aAAa;;8EAazB,CAAC;AAEF,MAAM,WAAW,iBAAkB,SAAQ,IAAI,CAAC,iBAAiB,EAAE,UAAU,GAAG,WAAW,CAAC,EAAE,YAAY,CAAC,OAAO,aAAa,CAAC;IAC9H,QAAQ,CAAC,EAAE,eAAe,CAAC,UAAU,CAAC,CAAC;IACvC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,wDAAwD;IACxD,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;oFACgF;IAChF,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB;AAED,wBAAgB,YAAY,CAAC,EAC3B,SAAS,EAAE,gBAAgB,EAAE,IAAe,EAAE,QAAQ,EAAE,OAAc,EAAE,aAAa,EAAE,aAAoB,EAAE,YAAY,EAAE,SAAS,EAAE,GAAG,KAAK,EAC/I,EAAE,iBAAiB,2CAwBnB;AAED,gDAAgD;AAChD,wBAAgB,WAAW,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,cAAc,CAAC,KAAK,CAAC,2CAEzE;AAGD,eAAO,MAAM,WAAW,qBAAe,CAAC;AACxC,eAAO,MAAM,UAAU,oBAAc,CAAC;AACtC,eAAO,MAAM,gBAAgB,0BAAoB,CAAC;AAClD,eAAO,MAAM,SAAS,mBAAa,CAAC;AACpC,eAAO,MAAM,UAAU,oBAAc,CAAC"}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { cn as e } from "../lib/utils.js";
|
|
3
|
+
import { AnimatedHeight as t } from "./animated-height.js";
|
|
4
|
+
import { useThemeScopeProps as n } from "../lib/theme.js";
|
|
5
|
+
import { overlayZ as r } from "../lib/primitives.js";
|
|
6
|
+
import { DialogBody as i, DialogClose as a, DialogDescription as o, DialogHeader as s, DialogTitle as c } from "./dialog.js";
|
|
7
|
+
import { jsx as l, jsxs as u } from "react/jsx-runtime";
|
|
8
|
+
import { Dialog as d, DialogTrigger as f, Modal as p, ModalOverlay as m } from "react-aria-components";
|
|
9
|
+
import { cva as h } from "class-variance-authority";
|
|
10
|
+
//#region src/components/sheet.tsx
|
|
11
|
+
var g = f, _ = h("absolute box-border flex flex-col bg-card text-card-foreground shadow-[0_0_40px_black] shadow-black/22 outline-none motion-reduce:data-entering:animate-bl-fade-in motion-reduce:data-exiting:animate-bl-fade-out", {
|
|
12
|
+
variants: { side: {
|
|
13
|
+
bottom: "inset-x-0 bottom-0 max-h-[calc(100%-48px)] rounded-t-card pb-[max(12px,env(safe-area-inset-bottom))] data-entering:animate-bl-sheet-in-bottom data-exiting:animate-bl-sheet-out-bottom",
|
|
14
|
+
top: "inset-x-0 top-0 max-h-[calc(100%-48px)] rounded-b-card pt-(--bl-safe-top) data-entering:animate-bl-sheet-in-top data-exiting:animate-bl-sheet-out-top",
|
|
15
|
+
left: "inset-y-0 left-0 w-[85%] max-w-[360px] rounded-r-card data-entering:animate-bl-sheet-in-left data-exiting:animate-bl-sheet-out-left",
|
|
16
|
+
right: "inset-y-0 right-0 w-[85%] max-w-[360px] rounded-l-card data-entering:animate-bl-sheet-in-right data-exiting:animate-bl-sheet-out-right"
|
|
17
|
+
} },
|
|
18
|
+
defaultVariants: { side: "bottom" }
|
|
19
|
+
});
|
|
20
|
+
function v({ className: i, overlayClassName: a, side: o = "bottom", children: s, grabber: c = !0, animateHeight: f, isDismissable: h = !0, "aria-label": g, ...v }) {
|
|
21
|
+
let y = o ?? "bottom", b = n();
|
|
22
|
+
return /* @__PURE__ */ l(m, {
|
|
23
|
+
"data-slot": "sheet-overlay",
|
|
24
|
+
"data-theme-scope": b["data-theme-scope"],
|
|
25
|
+
isDismissable: h,
|
|
26
|
+
className: e("absolute inset-0 bg-overlay data-entering:animate-bl-fade-in data-exiting:animate-bl-fade-out-slow", r, b.className, a),
|
|
27
|
+
style: b.style,
|
|
28
|
+
...v,
|
|
29
|
+
children: /* @__PURE__ */ u(p, {
|
|
30
|
+
"data-slot": "sheet",
|
|
31
|
+
"data-side": y,
|
|
32
|
+
className: e(_({ side: y }), i),
|
|
33
|
+
children: [y === "bottom" && c ? /* @__PURE__ */ l("span", {
|
|
34
|
+
"data-slot": "sheet-grabber",
|
|
35
|
+
"aria-hidden": "true",
|
|
36
|
+
className: "mx-auto mt-[5px] mb-px block h-[5px] w-9 shrink-0 rounded-full bg-secondary-strong"
|
|
37
|
+
}) : null, /* @__PURE__ */ l(d, {
|
|
38
|
+
"data-slot": "sheet-content",
|
|
39
|
+
"aria-label": g,
|
|
40
|
+
className: "relative flex min-h-0 flex-1 flex-col outline-none",
|
|
41
|
+
children: f ? (e) => /* @__PURE__ */ l(t, { children: typeof s == "function" ? s(e) : s }) : s
|
|
42
|
+
})]
|
|
43
|
+
})
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
function y({ className: t, ...n }) {
|
|
47
|
+
return /* @__PURE__ */ l("div", {
|
|
48
|
+
"data-slot": "sheet-footer",
|
|
49
|
+
className: e("mt-auto flex flex-col gap-2 px-5 pt-3 pb-2", t),
|
|
50
|
+
...n
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
var b = s, x = c, S = o, C = i, w = a;
|
|
54
|
+
//#endregion
|
|
55
|
+
export { g as Sheet, C as SheetBody, w as SheetClose, v as SheetContent, S as SheetDescription, y as SheetFooter, b as SheetHeader, x as SheetTitle, _ as sheetVariants };
|
|
@@ -10,9 +10,18 @@ export interface SideDrawerProps extends VariantProps<typeof sideDrawerVariants>
|
|
|
10
10
|
onClose?: () => void;
|
|
11
11
|
title?: ReactNode;
|
|
12
12
|
width?: number;
|
|
13
|
+
/**
|
|
14
|
+
* Present the overlay as a pushed page (full width, NavigationStack's push, back button, edge swipe to pop).
|
|
15
|
+
* Defaults to whether the host is narrower than `compactBreakpoint`. Ignored in `fixed` mode.
|
|
16
|
+
*/
|
|
17
|
+
compact?: boolean;
|
|
18
|
+
/** Host width below which the overlay becomes a push, when `compact` is unset. Default 520. */
|
|
19
|
+
compactBreakpoint?: number;
|
|
20
|
+
/** The pushed page's back label (what it returns to). Default "Back". */
|
|
21
|
+
backLabel?: ReactNode;
|
|
13
22
|
children?: ReactNode;
|
|
14
23
|
className?: string;
|
|
15
24
|
style?: CSSProperties;
|
|
16
25
|
}
|
|
17
|
-
export declare function SideDrawer({ mode, open, onClose, title, width, children, className, style }: SideDrawerProps): import("react/jsx-runtime").JSX.Element;
|
|
26
|
+
export declare function SideDrawer({ mode, open, onClose, title, width, compact: compactProp, compactBreakpoint, backLabel, children, className, style, }: SideDrawerProps): import("react/jsx-runtime").JSX.Element;
|
|
18
27
|
//# sourceMappingURL=side-drawer.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"side-drawer.d.ts","sourceRoot":"","sources":["../../src/components/side-drawer.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"side-drawer.d.ts","sourceRoot":"","sources":["../../src/components/side-drawer.tsx"],"names":[],"mappings":"AACA,OAAO,EAAkE,KAAK,aAAa,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAE3H,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAelE,qGAAqG;AACrG,eAAO,MAAM,kBAAkB;;8EAO7B,CAAC;AAEH,MAAM,WAAW,eAAgB,SAAQ,YAAY,CAAC,OAAO,kBAAkB,CAAC;IAC9E,IAAI,EAAE,OAAO,GAAG,SAAS,CAAC;IAC1B,IAAI,EAAE,OAAO,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,+FAA+F;IAC/F,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,yEAAyE;IACzE,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,aAAa,CAAC;CACvB;AAED,wBAAgB,UAAU,CAAC,EACzB,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,WAAW,EAAE,iBAAuB,EAAE,SAAkB,EAAE,QAAQ,EAAE,SAAS,EAAE,KAAK,GACjI,EAAE,eAAe,2CAyDjB"}
|
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { cn as e } from "../lib/utils.js";
|
|
3
|
+
import { springCss as t } from "../lib/motion.js";
|
|
4
|
+
import { Icon as n } from "../lib/icon.js";
|
|
5
|
+
import { BLSafeCtx as r } from "../lib/theme.js";
|
|
6
|
+
import { navigationPush as i } from "./navigation-stack.js";
|
|
7
|
+
import { EdgeDrawer as a } from "./edge-drawer.js";
|
|
8
|
+
import { use as o, useCallback as s, useEffect as c, useLayoutEffect as l, useRef as u, useState as d } from "react";
|
|
9
|
+
import { Fragment as f, jsx as p, jsxs as m } from "react/jsx-runtime";
|
|
10
|
+
import { Button as h } from "react-aria-components";
|
|
11
|
+
import { cva as g } from "class-variance-authority";
|
|
12
|
+
//#region src/components/side-drawer.tsx
|
|
13
|
+
var _ = g("", { variants: { mode: {
|
|
14
|
+
fixed: "w-(--side-drawer-w) shrink-0 overflow-hidden bg-background transition-[width] duration-spring-smooth ease-spring-smooth motion-reduce:transition-none",
|
|
15
|
+
overlay: "absolute inset-0 z-350 pointer-events-none"
|
|
16
|
+
} } });
|
|
17
|
+
function v({ mode: t, open: r, onClose: i, title: o, width: c, compact: g, compactBreakpoint: v = 520, backLabel: y = "Back", children: b, className: S, style: C }) {
|
|
18
|
+
c ||= 320;
|
|
19
|
+
let w = u(null), [T, E] = d(null), [D, O] = d(Infinity);
|
|
20
|
+
l(() => {
|
|
21
|
+
if (!T) return;
|
|
22
|
+
let e = (e) => {
|
|
23
|
+
e > 0 && O(e);
|
|
24
|
+
};
|
|
25
|
+
if (e(T.getBoundingClientRect().width), typeof ResizeObserver > "u") return;
|
|
26
|
+
let t = new ResizeObserver((t) => e(t[0].contentRect.width));
|
|
27
|
+
return t.observe(T), () => t.disconnect();
|
|
28
|
+
}, [T]);
|
|
29
|
+
let k = s((e) => {
|
|
30
|
+
w.current = e, E(e);
|
|
31
|
+
}, []), A = t === "overlay" && (g ?? D < v), j = /* @__PURE__ */ m("div", {
|
|
32
|
+
className: "flex shrink-0 items-center justify-between px-[14px] pt-[13px] pb-1.5",
|
|
33
|
+
children: [/* @__PURE__ */ p("span", {
|
|
34
|
+
className: "text-[16.5px] font-bold tracking-[-.2px] whitespace-nowrap",
|
|
35
|
+
children: o
|
|
36
|
+
}), /* @__PURE__ */ p(h, {
|
|
37
|
+
onPress: i,
|
|
38
|
+
"aria-label": "Close " + (typeof o == "string" ? o : "panel"),
|
|
39
|
+
className: "bl-btn grid size-7 cursor-pointer place-items-center rounded-full border-0 bg-secondary p-0 text-muted-foreground",
|
|
40
|
+
children: /* @__PURE__ */ p(n, {
|
|
41
|
+
name: "x",
|
|
42
|
+
size: 14,
|
|
43
|
+
sw: 2.6
|
|
44
|
+
})
|
|
45
|
+
})]
|
|
46
|
+
}), M = /* @__PURE__ */ p("div", {
|
|
47
|
+
className: "bl-scroll min-h-0 flex-1 overflow-y-auto",
|
|
48
|
+
children: b
|
|
49
|
+
}), N = /* @__PURE__ */ m(f, { children: [j, M] });
|
|
50
|
+
return t === "fixed" ? /* @__PURE__ */ p("div", {
|
|
51
|
+
"data-slot": "side-drawer",
|
|
52
|
+
"data-mode": "fixed",
|
|
53
|
+
"aria-hidden": !r,
|
|
54
|
+
className: e(_({ mode: t }), r ? "[border-left:1px_solid_var(--border)]" : "w-0", S),
|
|
55
|
+
style: {
|
|
56
|
+
"--side-drawer-w": c + "px",
|
|
57
|
+
...C
|
|
58
|
+
},
|
|
59
|
+
children: /* @__PURE__ */ p("div", {
|
|
60
|
+
className: "box-border flex h-full w-(--side-drawer-w) flex-col",
|
|
61
|
+
children: N
|
|
62
|
+
})
|
|
63
|
+
}) : /* @__PURE__ */ p("div", {
|
|
64
|
+
ref: k,
|
|
65
|
+
"data-slot": "side-drawer",
|
|
66
|
+
"data-mode": "overlay",
|
|
67
|
+
"data-presentation": A ? "push" : "sheet",
|
|
68
|
+
"data-open": r || void 0,
|
|
69
|
+
className: e(_({ mode: t }), S),
|
|
70
|
+
style: C,
|
|
71
|
+
children: A ? /* @__PURE__ */ p(x, {
|
|
72
|
+
open: r,
|
|
73
|
+
onClose: i,
|
|
74
|
+
title: o,
|
|
75
|
+
backLabel: y,
|
|
76
|
+
host: w,
|
|
77
|
+
hostWidth: D,
|
|
78
|
+
children: M
|
|
79
|
+
}) : /* @__PURE__ */ p(a, {
|
|
80
|
+
side: "right",
|
|
81
|
+
open: r,
|
|
82
|
+
onClose: i,
|
|
83
|
+
zIndex: 0,
|
|
84
|
+
width: `min(${c}px, 88%)`,
|
|
85
|
+
scrimClassName: "bg-overlay",
|
|
86
|
+
className: e("flex flex-col [border-left:1px_solid_var(--border)] bg-background data-[open=false]:translate-x-[106%]", r && "shadow-[-16px_0_48px_black] shadow-black/25"),
|
|
87
|
+
children: /* @__PURE__ */ p("div", {
|
|
88
|
+
className: "contents",
|
|
89
|
+
onKeyDown: (e) => {
|
|
90
|
+
e.key === "Escape" && r && (e.stopPropagation(), i?.());
|
|
91
|
+
},
|
|
92
|
+
children: N
|
|
93
|
+
})
|
|
94
|
+
})
|
|
95
|
+
});
|
|
96
|
+
}
|
|
97
|
+
function y(e) {
|
|
98
|
+
let t = [];
|
|
99
|
+
for (let n = e?.previousElementSibling; n; n = n.previousElementSibling) n instanceof HTMLElement && t.push(n);
|
|
100
|
+
return t;
|
|
101
|
+
}
|
|
102
|
+
var b = () => typeof matchMedia < "u" && matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
103
|
+
function x({ open: a, onClose: s, title: g, backLabel: _, host: v, hostWidth: x, children: S }) {
|
|
104
|
+
let C = o(r), w = u(null), T = u(null), E = u(null), D = u(s);
|
|
105
|
+
D.current = s;
|
|
106
|
+
let [O, k] = d(a);
|
|
107
|
+
c(() => {
|
|
108
|
+
if (a) {
|
|
109
|
+
k(!0);
|
|
110
|
+
return;
|
|
111
|
+
}
|
|
112
|
+
let e = setTimeout(() => k(!1), i.settleMs);
|
|
113
|
+
return () => clearTimeout(e);
|
|
114
|
+
}, [a]);
|
|
115
|
+
let A = u(a);
|
|
116
|
+
l(() => {
|
|
117
|
+
let e = y(v.current), n = A.current !== a && !b();
|
|
118
|
+
A.current = a;
|
|
119
|
+
let r = `${i.underPct / 100 * x}px 0`;
|
|
120
|
+
if (e.forEach((e) => {
|
|
121
|
+
e.style.transition = n ? t("translate", "smooth") : "", e.style.translate = a ? r : "";
|
|
122
|
+
}), !n) return;
|
|
123
|
+
let o = setTimeout(() => e.forEach((e) => {
|
|
124
|
+
e.style.transition = "";
|
|
125
|
+
}), i.settleMs);
|
|
126
|
+
return () => clearTimeout(o);
|
|
127
|
+
}, [
|
|
128
|
+
a,
|
|
129
|
+
x,
|
|
130
|
+
v
|
|
131
|
+
]), l(() => {
|
|
132
|
+
let e = v.current;
|
|
133
|
+
return () => y(e).forEach((e) => {
|
|
134
|
+
e.style.transition = "", e.style.translate = "";
|
|
135
|
+
});
|
|
136
|
+
}, [v]);
|
|
137
|
+
let j = u(null), M = u(a);
|
|
138
|
+
c(() => {
|
|
139
|
+
M.current !== a && (M.current = a, a ? (j.current = document.activeElement instanceof HTMLElement ? document.activeElement : null, w.current?.focus({ preventScroll: !0 })) : w.current?.contains(document.activeElement) && j.current?.focus({ preventScroll: !0 }));
|
|
140
|
+
}, [a]);
|
|
141
|
+
let N = (e) => {
|
|
142
|
+
if (e.button || !a) return;
|
|
143
|
+
let t = w.current?.getBoundingClientRect();
|
|
144
|
+
if (!(!t || e.clientX - t.left > i.edge)) {
|
|
145
|
+
E.current = {
|
|
146
|
+
x0: e.clientX,
|
|
147
|
+
y0: e.clientY,
|
|
148
|
+
w: t.width,
|
|
149
|
+
last: e.clientX,
|
|
150
|
+
lt: performance.now(),
|
|
151
|
+
vel: 0,
|
|
152
|
+
dx: 0,
|
|
153
|
+
on: !1,
|
|
154
|
+
page: y(v.current)
|
|
155
|
+
};
|
|
156
|
+
try {
|
|
157
|
+
w.current?.setPointerCapture(e.pointerId);
|
|
158
|
+
} catch {}
|
|
159
|
+
}
|
|
160
|
+
}, P = (e) => {
|
|
161
|
+
let t = E.current, n = w.current, r = T.current;
|
|
162
|
+
if (!t || !n || !r) return;
|
|
163
|
+
let a = e.clientX - t.x0, o = e.clientY - t.y0;
|
|
164
|
+
if (!t.on) {
|
|
165
|
+
if (a > 8 && a > Math.abs(o) * 1.2) t.on = !0;
|
|
166
|
+
else {
|
|
167
|
+
Math.abs(o) > 14 && (E.current = null);
|
|
168
|
+
return;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
let s = Math.max(0, a);
|
|
172
|
+
t.vel = (e.clientX - t.last) / Math.max(1, performance.now() - t.lt), t.last = e.clientX, t.lt = performance.now(), t.dx = s;
|
|
173
|
+
let c = 1 - s / t.w;
|
|
174
|
+
n.style.transition = "none", n.style.transform = `translateX(${s}px)`, r.style.transition = "none", r.style.opacity = String(i.dim * c), t.page.forEach((e) => {
|
|
175
|
+
e.style.transition = "none", e.style.translate = `${i.underPct / 100 * t.w * c}px 0`;
|
|
176
|
+
});
|
|
177
|
+
}, F = () => {
|
|
178
|
+
let e = E.current;
|
|
179
|
+
E.current = null;
|
|
180
|
+
let n = w.current, r = T.current;
|
|
181
|
+
if (!e || !e.on || !n || !r) return;
|
|
182
|
+
let a = e.dx / e.w > i.commit || e.vel > i.flick;
|
|
183
|
+
n.style.transition = t("transform", "tray"), r.style.transition = t("opacity", "tray"), e.page.forEach((e) => {
|
|
184
|
+
e.style.transition = t("translate", "tray");
|
|
185
|
+
}), a ? (n.style.transform = `translateX(${i.off})`, r.style.opacity = "0", e.page.forEach((e) => {
|
|
186
|
+
e.style.translate = "";
|
|
187
|
+
}), D.current?.()) : (n.style.transform = "translateX(0px)", r.style.opacity = String(i.dim), e.page.forEach((t) => {
|
|
188
|
+
t.style.translate = `${i.underPct / 100 * e.w}px 0`;
|
|
189
|
+
})), setTimeout(() => {
|
|
190
|
+
n.style.transition = "", n.style.transform = "", r.style.transition = "", r.style.opacity = "", e.page.forEach((e) => {
|
|
191
|
+
e.style.transition = "";
|
|
192
|
+
});
|
|
193
|
+
}, 430);
|
|
194
|
+
};
|
|
195
|
+
return /* @__PURE__ */ m(f, { children: [/* @__PURE__ */ p("div", {
|
|
196
|
+
ref: T,
|
|
197
|
+
"data-slot": "side-drawer-dim",
|
|
198
|
+
"aria-hidden": "true",
|
|
199
|
+
className: e("absolute inset-0 bg-black transition-opacity duration-spring-smooth ease-spring-smooth motion-reduce:transition-none", a ? "pointer-events-auto opacity-12" : "pointer-events-none opacity-0")
|
|
200
|
+
}), /* @__PURE__ */ m("div", {
|
|
201
|
+
ref: w,
|
|
202
|
+
"data-slot": "side-drawer-panel",
|
|
203
|
+
role: "dialog",
|
|
204
|
+
tabIndex: -1,
|
|
205
|
+
"aria-label": typeof g == "string" ? g : void 0,
|
|
206
|
+
"aria-hidden": !a,
|
|
207
|
+
inert: !a || void 0,
|
|
208
|
+
onPointerDownCapture: N,
|
|
209
|
+
onPointerMove: P,
|
|
210
|
+
onPointerUp: F,
|
|
211
|
+
onPointerCancel: F,
|
|
212
|
+
onKeyDown: (e) => {
|
|
213
|
+
e.key === "Escape" && a && (e.stopPropagation(), s?.());
|
|
214
|
+
},
|
|
215
|
+
className: e("absolute inset-0 flex touch-pan-y flex-col overflow-hidden bg-background outline-none will-change-transform [transform:translateX(var(--side-drawer-x))] transition-transform duration-spring-smooth ease-spring-smooth motion-reduce:transition-none", a ? "pointer-events-auto" : "pointer-events-none", (a || O) && "shadow-[-10px_0_30px_black] shadow-black/16", !a && !O && "invisible"),
|
|
216
|
+
style: {
|
|
217
|
+
"--side-drawer-x": a ? "0%" : i.off,
|
|
218
|
+
"--side-drawer-bar-h": C + 52 + "px",
|
|
219
|
+
"--side-drawer-safe-top": C + "px"
|
|
220
|
+
},
|
|
221
|
+
children: [/* @__PURE__ */ p("div", {
|
|
222
|
+
"data-slot": "side-drawer-bar",
|
|
223
|
+
className: "relative box-border flex h-(--side-drawer-bar-h) shrink-0 items-end px-1.5 pt-(--side-drawer-safe-top) [border-bottom:1px_solid_var(--border)] bg-background/86 backdrop-blur-[18px] backdrop-saturate-[1.7]",
|
|
224
|
+
children: /* @__PURE__ */ m("div", {
|
|
225
|
+
className: "flex h-toolbar w-full items-center",
|
|
226
|
+
children: [/* @__PURE__ */ m(h, {
|
|
227
|
+
onPress: s,
|
|
228
|
+
"aria-label": typeof _ == "string" ? _ : "Back",
|
|
229
|
+
className: "bl-btn relative z-1 flex max-w-[30%] cursor-pointer items-center border-0 bg-transparent py-1.5 pr-2 pl-0 [font-family:inherit] text-body text-primary",
|
|
230
|
+
children: [/* @__PURE__ */ p(n, {
|
|
231
|
+
name: "chevL",
|
|
232
|
+
size: 24,
|
|
233
|
+
sw: 2.4
|
|
234
|
+
}), /* @__PURE__ */ p("span", {
|
|
235
|
+
className: "truncate",
|
|
236
|
+
children: _
|
|
237
|
+
})]
|
|
238
|
+
}), /* @__PURE__ */ p("div", {
|
|
239
|
+
className: "pointer-events-none absolute left-1/2 max-w-[52%] -translate-x-1/2 truncate text-body font-semibold text-foreground",
|
|
240
|
+
children: g
|
|
241
|
+
})]
|
|
242
|
+
})
|
|
243
|
+
}), S]
|
|
244
|
+
})] });
|
|
245
|
+
}
|
|
246
|
+
//#endregion
|
|
247
|
+
export { v as SideDrawer, _ as sideDrawerVariants };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sidebar.d.ts","sourceRoot":"","sources":["../../src/components/sidebar.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"sidebar.d.ts","sourceRoot":"","sources":["../../src/components/sidebar.tsx"],"names":[],"mappings":"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"}
|