@womp/kookie-ui 0.24.0 → 0.25.1
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 +3 -3
- package/components.css +12859 -11868
- package/dist/cjs/components/_internal/base-button.d.ts.map +1 -1
- package/dist/cjs/components/_internal/base-button.js +2 -1
- package/dist/cjs/components/_internal/base-button.js.map +4 -4
- package/dist/cjs/components/_internal/base-button.props.js +1 -0
- package/dist/cjs/components/_internal/base-button.props.js.map +2 -2
- package/dist/cjs/components/_internal/base-checkbox.props.js +1 -0
- package/dist/cjs/components/_internal/base-checkbox.props.js.map +1 -1
- package/dist/cjs/components/_internal/base-menu.props.js +1 -0
- package/dist/cjs/components/_internal/base-menu.props.js.map +1 -1
- package/dist/cjs/components/_internal/base-menu.utils.js +1 -0
- package/dist/cjs/components/_internal/base-menu.utils.js.map +1 -1
- package/dist/cjs/components/_internal/base-radio.props.js +1 -0
- package/dist/cjs/components/_internal/base-radio.props.js.map +1 -1
- package/dist/cjs/components/_internal/base-tab-list.props.js +1 -0
- package/dist/cjs/components/_internal/base-tab-list.props.js.map +1 -1
- package/dist/cjs/components/_internal/dropdown-menu-drill-down.d.ts +19 -7
- package/dist/cjs/components/_internal/dropdown-menu-drill-down.d.ts.map +1 -1
- package/dist/cjs/components/_internal/dropdown-menu-drill-down.js +2 -1
- package/dist/cjs/components/_internal/dropdown-menu-drill-down.js.map +3 -3
- package/dist/cjs/components/_internal/menu-context.d.ts +10 -0
- package/dist/cjs/components/_internal/menu-context.d.ts.map +1 -1
- package/dist/cjs/components/_internal/menu-context.js +2 -1
- package/dist/cjs/components/_internal/menu-context.js.map +3 -3
- package/dist/cjs/components/_internal/pane-chrome.d.ts +3 -1
- package/dist/cjs/components/_internal/pane-chrome.d.ts.map +1 -1
- package/dist/cjs/components/_internal/pane-chrome.js +2 -1
- package/dist/cjs/components/_internal/pane-chrome.js.map +3 -3
- package/dist/cjs/components/_internal/shell-bottom.d.ts +1 -1
- package/dist/cjs/components/_internal/shell-bottom.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-bottom.js +2 -1
- package/dist/cjs/components/_internal/shell-bottom.js.map +3 -3
- package/dist/cjs/components/_internal/shell-handles.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-handles.js +2 -1
- package/dist/cjs/components/_internal/shell-handles.js.map +3 -3
- package/dist/cjs/components/_internal/shell-inspector.d.ts +1 -1
- package/dist/cjs/components/_internal/shell-inspector.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-inspector.js +2 -1
- package/dist/cjs/components/_internal/shell-inspector.js.map +3 -3
- package/dist/cjs/components/_internal/shell-pane.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-pane.js +2 -1
- package/dist/cjs/components/_internal/shell-pane.js.map +3 -3
- package/dist/cjs/components/_internal/shell-resizable.d.ts +6 -0
- package/dist/cjs/components/_internal/shell-resizable.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-resizable.js +2 -1
- package/dist/cjs/components/_internal/shell-resizable.js.map +3 -3
- package/dist/cjs/components/_internal/shell-resize.js +1 -0
- package/dist/cjs/components/_internal/shell-resize.js.map +1 -1
- package/dist/cjs/components/_internal/shell-rest.js +1 -0
- package/dist/cjs/components/_internal/shell-rest.js.map +1 -1
- package/dist/cjs/components/_internal/shell-sidebar.d.ts +1 -1
- package/dist/cjs/components/_internal/shell-sidebar.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-sidebar.js +2 -1
- package/dist/cjs/components/_internal/shell-sidebar.js.map +3 -3
- package/dist/cjs/components/_internal/shell-store.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-store.js +2 -1
- package/dist/cjs/components/_internal/shell-store.js.map +3 -3
- package/dist/cjs/components/accessible-icon.js +1 -0
- package/dist/cjs/components/accessible-icon.js.map +1 -1
- package/dist/cjs/components/accordion.d.ts.map +1 -1
- package/dist/cjs/components/accordion.js +2 -1
- package/dist/cjs/components/accordion.js.map +4 -4
- package/dist/cjs/components/accordion.props.js +1 -0
- package/dist/cjs/components/accordion.props.js.map +1 -1
- package/dist/cjs/components/alert-dialog.d.ts.map +1 -1
- package/dist/cjs/components/alert-dialog.js +2 -1
- package/dist/cjs/components/alert-dialog.js.map +4 -4
- package/dist/cjs/components/alert-dialog.props.js +1 -0
- package/dist/cjs/components/alert-dialog.props.js.map +1 -1
- package/dist/cjs/components/avatar.d.ts.map +1 -1
- package/dist/cjs/components/avatar.js +2 -1
- package/dist/cjs/components/avatar.js.map +4 -4
- package/dist/cjs/components/avatar.props.js +1 -0
- package/dist/cjs/components/avatar.props.js.map +1 -1
- package/dist/cjs/components/blockquote.js +1 -0
- package/dist/cjs/components/blockquote.js.map +1 -1
- package/dist/cjs/components/blockquote.props.js +1 -0
- package/dist/cjs/components/blockquote.props.js.map +1 -1
- package/dist/cjs/components/box.js +1 -0
- package/dist/cjs/components/box.js.map +1 -1
- package/dist/cjs/components/box.props.js +1 -0
- package/dist/cjs/components/box.props.js.map +1 -1
- package/dist/cjs/components/button.d.ts.map +1 -1
- package/dist/cjs/components/button.js +2 -1
- package/dist/cjs/components/button.js.map +4 -4
- package/dist/cjs/components/button.props.js +1 -0
- package/dist/cjs/components/button.props.js.map +2 -2
- package/dist/cjs/components/card.js +2 -1
- package/dist/cjs/components/card.js.map +4 -4
- package/dist/cjs/components/card.props.js +1 -0
- package/dist/cjs/components/card.props.js.map +1 -1
- package/dist/cjs/components/chatbar.d.ts.map +1 -1
- package/dist/cjs/components/chatbar.js +2 -1
- package/dist/cjs/components/chatbar.js.map +4 -4
- package/dist/cjs/components/checkbox-group.js +2 -1
- package/dist/cjs/components/checkbox-group.js.map +4 -4
- package/dist/cjs/components/checkbox-group.primitive.js +1 -0
- package/dist/cjs/components/checkbox-group.primitive.js.map +1 -1
- package/dist/cjs/components/checkbox-group.props.js +1 -0
- package/dist/cjs/components/checkbox-group.props.js.map +1 -1
- package/dist/cjs/components/checkbox.js +2 -1
- package/dist/cjs/components/checkbox.js.map +4 -4
- package/dist/cjs/components/checkbox.props.js +1 -0
- package/dist/cjs/components/checkbox.props.js.map +1 -1
- package/dist/cjs/components/chip.js +2 -1
- package/dist/cjs/components/chip.js.map +4 -4
- package/dist/cjs/components/chip.props.js +1 -0
- package/dist/cjs/components/chip.props.js.map +1 -1
- package/dist/cjs/components/code.js +1 -0
- package/dist/cjs/components/code.js.map +1 -1
- package/dist/cjs/components/code.props.js +1 -0
- package/dist/cjs/components/code.props.js.map +1 -1
- package/dist/cjs/components/combobox.d.ts.map +1 -1
- package/dist/cjs/components/combobox.js +2 -1
- package/dist/cjs/components/combobox.js.map +4 -4
- package/dist/cjs/components/combobox.props.js +1 -0
- package/dist/cjs/components/combobox.props.js.map +1 -1
- package/dist/cjs/components/context-menu.d.ts +1 -2
- package/dist/cjs/components/context-menu.d.ts.map +1 -1
- package/dist/cjs/components/context-menu.js +2 -1
- package/dist/cjs/components/context-menu.js.map +4 -4
- package/dist/cjs/components/context-menu.props.js +1 -0
- package/dist/cjs/components/context-menu.props.js.map +1 -1
- package/dist/cjs/components/dialog.js +2 -1
- package/dist/cjs/components/dialog.js.map +4 -4
- package/dist/cjs/components/dialog.props.js +1 -0
- package/dist/cjs/components/dialog.props.js.map +1 -1
- package/dist/cjs/components/dropdown-menu.d.ts +1 -2
- package/dist/cjs/components/dropdown-menu.d.ts.map +1 -1
- package/dist/cjs/components/dropdown-menu.js +2 -1
- package/dist/cjs/components/dropdown-menu.js.map +4 -4
- package/dist/cjs/components/dropdown-menu.props.js +1 -0
- package/dist/cjs/components/dropdown-menu.props.js.map +1 -1
- package/dist/cjs/components/flex.js +1 -0
- package/dist/cjs/components/flex.js.map +2 -2
- package/dist/cjs/components/flex.props.js +1 -0
- package/dist/cjs/components/flex.props.js.map +2 -2
- package/dist/cjs/components/grid.js +1 -0
- package/dist/cjs/components/grid.js.map +2 -2
- package/dist/cjs/components/grid.props.js +1 -0
- package/dist/cjs/components/grid.props.js.map +2 -2
- package/dist/cjs/components/heading.d.ts +2 -2
- package/dist/cjs/components/heading.d.ts.map +1 -1
- package/dist/cjs/components/heading.js +2 -1
- package/dist/cjs/components/heading.js.map +2 -2
- package/dist/cjs/components/heading.props.d.ts +1 -1
- package/dist/cjs/components/heading.props.js +2 -1
- package/dist/cjs/components/heading.props.js.map +2 -2
- package/dist/cjs/components/icons.js +1 -0
- package/dist/cjs/components/icons.js.map +1 -1
- package/dist/cjs/components/image.d.ts +9 -2
- package/dist/cjs/components/image.d.ts.map +1 -1
- package/dist/cjs/components/image.js +2 -1
- package/dist/cjs/components/image.js.map +3 -3
- package/dist/cjs/components/image.props.js +1 -0
- package/dist/cjs/components/image.props.js.map +1 -1
- package/dist/cjs/components/index.d.ts +1 -1
- package/dist/cjs/components/index.d.ts.map +1 -1
- package/dist/cjs/components/index.js +3 -2
- package/dist/cjs/components/index.js.map +4 -4
- package/dist/cjs/components/kbd.js +1 -0
- package/dist/cjs/components/kbd.js.map +1 -1
- package/dist/cjs/components/kbd.props.js +1 -0
- package/dist/cjs/components/kbd.props.js.map +1 -1
- package/dist/cjs/components/link.js +1 -0
- package/dist/cjs/components/link.js.map +1 -1
- package/dist/cjs/components/link.props.js +1 -0
- package/dist/cjs/components/link.props.js.map +1 -1
- package/dist/cjs/components/message-scroller.d.ts +2 -2
- package/dist/cjs/components/message-scroller.d.ts.map +1 -1
- package/dist/cjs/components/message-scroller.js +2 -1
- package/dist/cjs/components/message-scroller.js.map +4 -4
- package/dist/cjs/components/navbar.js +2 -1
- package/dist/cjs/components/navbar.js.map +4 -4
- package/dist/cjs/components/navbar.props.js +1 -0
- package/dist/cjs/components/navbar.props.js.map +1 -1
- package/dist/cjs/components/notice.js +2 -1
- package/dist/cjs/components/notice.js.map +4 -4
- package/dist/cjs/components/popover.d.ts +3 -1
- package/dist/cjs/components/popover.d.ts.map +1 -1
- package/dist/cjs/components/popover.js +2 -1
- package/dist/cjs/components/popover.js.map +4 -4
- package/dist/cjs/components/popover.props.js +1 -0
- package/dist/cjs/components/popover.props.js.map +1 -1
- package/dist/cjs/components/portal.js +1 -0
- package/dist/cjs/components/portal.js.map +1 -1
- package/dist/cjs/components/progress.d.ts.map +1 -1
- package/dist/cjs/components/progress.js +2 -1
- package/dist/cjs/components/progress.js.map +3 -3
- package/dist/cjs/components/progress.props.js +1 -0
- package/dist/cjs/components/progress.props.js.map +1 -1
- package/dist/cjs/components/radio-group.js +2 -1
- package/dist/cjs/components/radio-group.js.map +4 -4
- package/dist/cjs/components/radio-group.props.js +1 -0
- package/dist/cjs/components/radio-group.props.js.map +1 -1
- package/dist/cjs/components/radio.js +2 -1
- package/dist/cjs/components/radio.js.map +4 -4
- package/dist/cjs/components/radio.props.js +1 -0
- package/dist/cjs/components/radio.props.js.map +1 -1
- package/dist/cjs/components/reset.js +1 -0
- package/dist/cjs/components/reset.js.map +1 -1
- package/dist/cjs/components/schemas/base-button.schema.js +1 -0
- package/dist/cjs/components/schemas/base-button.schema.js.map +1 -1
- package/dist/cjs/components/schemas/button.schema.js +1 -0
- package/dist/cjs/components/schemas/button.schema.js.map +1 -1
- package/dist/cjs/components/schemas/index.js +1 -0
- package/dist/cjs/components/schemas/index.js.map +1 -1
- package/dist/cjs/components/schemas/shell.schema.js +1 -0
- package/dist/cjs/components/schemas/shell.schema.js.map +1 -1
- package/dist/cjs/components/schemas/toggle.schema.js +1 -0
- package/dist/cjs/components/schemas/toggle.schema.js.map +1 -1
- package/dist/cjs/components/scroll-area.js +1 -0
- package/dist/cjs/components/scroll-area.js.map +1 -1
- package/dist/cjs/components/scroll-area.props.js +1 -0
- package/dist/cjs/components/scroll-area.props.js.map +1 -1
- package/dist/cjs/components/segmented-control.d.ts.map +1 -1
- package/dist/cjs/components/segmented-control.js +2 -1
- package/dist/cjs/components/segmented-control.js.map +4 -4
- package/dist/cjs/components/segmented-control.props.d.ts +0 -1
- package/dist/cjs/components/segmented-control.props.d.ts.map +1 -1
- package/dist/cjs/components/segmented-control.props.js +2 -1
- package/dist/cjs/components/segmented-control.props.js.map +2 -2
- package/dist/cjs/components/select.d.ts.map +1 -1
- package/dist/cjs/components/select.js +2 -1
- package/dist/cjs/components/select.js.map +4 -4
- package/dist/cjs/components/select.props.js +1 -0
- package/dist/cjs/components/select.props.js.map +1 -1
- package/dist/cjs/components/separator.d.ts.map +1 -1
- package/dist/cjs/components/separator.js +2 -1
- package/dist/cjs/components/separator.js.map +4 -4
- package/dist/cjs/components/separator.props.d.ts +1 -1
- package/dist/cjs/components/separator.props.js +2 -1
- package/dist/cjs/components/separator.props.js.map +2 -2
- package/dist/cjs/components/sheet.d.ts +1 -1
- package/dist/cjs/components/sheet.d.ts.map +1 -1
- package/dist/cjs/components/sheet.js +2 -1
- package/dist/cjs/components/sheet.js.map +4 -4
- package/dist/cjs/components/shell.context.js +2 -1
- package/dist/cjs/components/shell.context.js.map +3 -3
- package/dist/cjs/components/shell.d.ts +5 -2
- package/dist/cjs/components/shell.d.ts.map +1 -1
- package/dist/cjs/components/shell.hooks.js +2 -1
- package/dist/cjs/components/shell.hooks.js.map +3 -3
- package/dist/cjs/components/shell.js +2 -1
- package/dist/cjs/components/shell.js.map +4 -4
- package/dist/cjs/components/shell.types.js +1 -0
- package/dist/cjs/components/shell.types.js.map +1 -1
- package/dist/cjs/components/sidebar.d.ts.map +1 -1
- package/dist/cjs/components/sidebar.js +2 -1
- package/dist/cjs/components/sidebar.js.map +4 -4
- package/dist/cjs/components/slider.d.ts.map +1 -1
- package/dist/cjs/components/slider.js +2 -1
- package/dist/cjs/components/slider.js.map +4 -4
- package/dist/cjs/components/slider.props.d.ts +0 -2
- package/dist/cjs/components/slider.props.d.ts.map +1 -1
- package/dist/cjs/components/slider.props.js +2 -1
- package/dist/cjs/components/slider.props.js.map +2 -2
- package/dist/cjs/components/slot.js +1 -0
- package/dist/cjs/components/slot.js.map +1 -1
- package/dist/cjs/components/spinner.d.ts.map +1 -1
- package/dist/cjs/components/spinner.js +2 -1
- package/dist/cjs/components/spinner.js.map +2 -2
- package/dist/cjs/components/spinner.props.js +1 -0
- package/dist/cjs/components/spinner.props.js.map +1 -1
- package/dist/cjs/components/switch.js +2 -1
- package/dist/cjs/components/switch.js.map +4 -4
- package/dist/cjs/components/switch.props.js +1 -0
- package/dist/cjs/components/switch.props.js.map +1 -1
- package/dist/cjs/components/table.d.ts.map +1 -1
- package/dist/cjs/components/table.js +2 -1
- package/dist/cjs/components/table.js.map +4 -4
- package/dist/cjs/components/table.props.d.ts +0 -2
- package/dist/cjs/components/table.props.d.ts.map +1 -1
- package/dist/cjs/components/table.props.js +2 -1
- package/dist/cjs/components/table.props.js.map +3 -3
- package/dist/cjs/components/tabs.d.ts.map +1 -1
- package/dist/cjs/components/tabs.js +2 -1
- package/dist/cjs/components/tabs.js.map +4 -4
- package/dist/cjs/components/tabs.props.js +1 -0
- package/dist/cjs/components/tabs.props.js.map +1 -1
- package/dist/cjs/components/text-area.d.ts.map +1 -1
- package/dist/cjs/components/text-area.js +2 -1
- package/dist/cjs/components/text-area.js.map +4 -4
- package/dist/cjs/components/text-area.props.js +1 -0
- package/dist/cjs/components/text-area.props.js.map +1 -1
- package/dist/cjs/components/text-field.d.ts.map +1 -1
- package/dist/cjs/components/text-field.js +3 -2
- package/dist/cjs/components/text-field.js.map +4 -4
- package/dist/cjs/components/text-field.props.js +1 -0
- package/dist/cjs/components/text-field.props.js.map +2 -2
- package/dist/cjs/components/text.js +1 -0
- package/dist/cjs/components/text.js.map +1 -1
- package/dist/cjs/components/text.props.js +1 -0
- package/dist/cjs/components/text.props.js.map +1 -1
- package/dist/cjs/components/theme.d.ts.map +1 -1
- package/dist/cjs/components/theme.js +2 -1
- package/dist/cjs/components/theme.js.map +4 -4
- package/dist/cjs/components/theme.props.js +1 -0
- package/dist/cjs/components/theme.props.js.map +1 -1
- package/dist/cjs/components/toggle.js +2 -1
- package/dist/cjs/components/toggle.js.map +4 -4
- package/dist/cjs/components/toolbar.d.ts +4 -1
- package/dist/cjs/components/toolbar.d.ts.map +1 -1
- package/dist/cjs/components/toolbar.js +2 -1
- package/dist/cjs/components/toolbar.js.map +4 -4
- package/dist/cjs/components/toolbar.props.js +1 -0
- package/dist/cjs/components/toolbar.props.js.map +1 -1
- package/dist/cjs/components/tooltip.d.ts +13 -2
- package/dist/cjs/components/tooltip.d.ts.map +1 -1
- package/dist/cjs/components/tooltip.js +2 -1
- package/dist/cjs/components/tooltip.js.map +4 -4
- package/dist/cjs/components/tooltip.props.js +1 -0
- package/dist/cjs/components/tooltip.props.js.map +1 -1
- package/dist/cjs/components/virtual-menu.d.ts +19 -12
- package/dist/cjs/components/virtual-menu.d.ts.map +1 -1
- package/dist/cjs/components/virtual-menu.js +2 -1
- package/dist/cjs/components/virtual-menu.js.map +3 -3
- package/dist/cjs/components/visually-hidden.js +1 -0
- package/dist/cjs/components/visually-hidden.js.map +1 -1
- package/dist/cjs/helpers/get-margin-styles.d.ts.map +1 -1
- package/dist/cjs/helpers/get-margin-styles.js +1 -1
- package/dist/cjs/helpers/get-margin-styles.js.map +3 -3
- package/dist/cjs/helpers/index.d.ts +1 -0
- package/dist/cjs/helpers/index.d.ts.map +1 -1
- package/dist/cjs/helpers/index.js +3 -3
- package/dist/cjs/helpers/index.js.map +3 -3
- package/dist/cjs/helpers/theme-size.d.ts +8 -30
- package/dist/cjs/helpers/theme-size.d.ts.map +1 -1
- package/dist/cjs/helpers/theme-size.js +1 -1
- package/dist/cjs/helpers/theme-size.js.map +3 -3
- package/dist/cjs/hooks/index.js +5 -4
- package/dist/cjs/hooks/index.js.map +3 -3
- package/dist/cjs/hooks/theme-size.d.ts +32 -0
- package/dist/cjs/hooks/theme-size.d.ts.map +1 -0
- package/dist/cjs/hooks/theme-size.js +3 -0
- package/dist/cjs/hooks/theme-size.js.map +7 -0
- package/dist/cjs/hooks/use-appearance.d.ts.map +1 -1
- package/dist/cjs/hooks/use-appearance.js +4 -3
- package/dist/cjs/hooks/use-appearance.js.map +3 -3
- package/dist/cjs/hooks/use-body-pointer-events-cleanup.d.ts +1 -1
- package/dist/cjs/hooks/use-body-pointer-events-cleanup.d.ts.map +1 -1
- package/dist/cjs/hooks/use-body-pointer-events-cleanup.js +2 -1
- package/dist/cjs/hooks/use-body-pointer-events-cleanup.js.map +3 -3
- package/dist/cjs/hooks/use-breakpoint.js +1 -0
- package/dist/cjs/hooks/use-breakpoint.js.map +1 -1
- package/dist/cjs/hooks/use-live-announcer.js +1 -0
- package/dist/cjs/hooks/use-live-announcer.js.map +1 -1
- package/dist/cjs/hooks/use-prop-synced-state.js +1 -0
- package/dist/cjs/hooks/use-prop-synced-state.js.map +1 -1
- package/dist/cjs/hooks/use-scroll-edges.js +1 -0
- package/dist/cjs/hooks/use-scroll-edges.js.map +1 -1
- package/dist/cjs/hooks/use-thumb-sync.js +1 -0
- package/dist/cjs/hooks/use-thumb-sync.js.map +1 -1
- package/dist/cjs/hooks/use-toggle-state.js +1 -0
- package/dist/cjs/hooks/use-toggle-state.js.map +1 -1
- package/dist/cjs/hooks/use-tooltip-wrapper.js +1 -0
- package/dist/cjs/hooks/use-tooltip-wrapper.js.map +1 -1
- package/dist/cjs/index.js +6 -5
- package/dist/cjs/index.js.map +4 -4
- package/dist/cjs/props/gap.props.d.ts +4 -4
- package/dist/cjs/props/gap.props.js.map +1 -1
- package/dist/cjs/props/index.js +1 -1
- package/dist/cjs/props/index.js.map +4 -4
- package/dist/esm/chunk-2IU5XPR2.js +3 -0
- package/dist/esm/chunk-2IU5XPR2.js.map +7 -0
- package/dist/esm/{chunk-JYQGCXXI.js → chunk-2VSRZ4IT.js} +2 -1
- package/dist/esm/{chunk-JYQGCXXI.js.map → chunk-2VSRZ4IT.js.map} +1 -1
- package/dist/esm/{chunk-GNTNGLYR.js → chunk-2Z2I27ZS.js} +3 -2
- package/dist/esm/{chunk-GNTNGLYR.js.map → chunk-2Z2I27ZS.js.map} +1 -1
- package/dist/esm/chunk-3B25RLWX.js +3 -0
- package/dist/esm/chunk-3B25RLWX.js.map +7 -0
- package/dist/esm/chunk-3CY6H4TE.js +3 -0
- package/dist/esm/chunk-3CY6H4TE.js.map +7 -0
- package/dist/esm/{chunk-MPTTUBFU.js → chunk-3H23GRNQ.js} +3 -2
- package/dist/esm/{chunk-MPTTUBFU.js.map → chunk-3H23GRNQ.js.map} +2 -2
- package/dist/esm/chunk-3L2MDOYC.js +3 -0
- package/dist/esm/chunk-3L2MDOYC.js.map +7 -0
- package/dist/esm/chunk-3LIF53YY.js +13 -0
- package/dist/esm/chunk-3LIF53YY.js.map +7 -0
- package/dist/esm/chunk-3QWGSRYC.js +3 -0
- package/dist/esm/chunk-3QWGSRYC.js.map +7 -0
- package/dist/esm/{chunk-IAEAXIBI.js → chunk-4J7QDLKI.js} +3 -2
- package/dist/esm/{chunk-IAEAXIBI.js.map → chunk-4J7QDLKI.js.map} +1 -1
- package/dist/esm/chunk-5CFSNNYS.js +3 -0
- package/dist/esm/chunk-5CFSNNYS.js.map +7 -0
- package/dist/esm/chunk-5EBJOOXE.js +3 -0
- package/dist/esm/chunk-5EBJOOXE.js.map +7 -0
- package/dist/esm/chunk-5EP3UTM7.js +3 -0
- package/dist/esm/{chunk-Q4IA622Q.js.map → chunk-5EP3UTM7.js.map} +1 -1
- package/dist/esm/chunk-5JYSYTHA.js +3 -0
- package/dist/esm/chunk-5JYSYTHA.js.map +7 -0
- package/dist/esm/{chunk-FWB47YCH.js → chunk-5KMEUZWN.js} +2 -1
- package/dist/esm/{chunk-FWB47YCH.js.map → chunk-5KMEUZWN.js.map} +1 -1
- package/dist/esm/{chunk-7MC7N4BC.js → chunk-5KQCG7AV.js} +2 -1
- package/dist/esm/{chunk-7MC7N4BC.js.map → chunk-5KQCG7AV.js.map} +1 -1
- package/dist/esm/chunk-5L4DZ2D3.js +3 -0
- package/dist/esm/chunk-5L4DZ2D3.js.map +7 -0
- package/dist/esm/chunk-5ON3XLRD.js +3 -0
- package/dist/esm/chunk-5ON3XLRD.js.map +7 -0
- package/dist/esm/chunk-5RFDCAKC.js +3 -0
- package/dist/esm/{chunk-SKOYHBIE.js.map → chunk-5RFDCAKC.js.map} +1 -1
- package/dist/esm/chunk-5TJH35TF.js +3 -0
- package/dist/esm/chunk-5TJH35TF.js.map +7 -0
- package/dist/esm/{chunk-BIITGC3Z.js → chunk-5WTSKXAE.js} +3 -2
- package/dist/esm/{chunk-BIITGC3Z.js.map → chunk-5WTSKXAE.js.map} +1 -1
- package/dist/esm/chunk-5XR5PTDR.js +3 -0
- package/dist/esm/chunk-5XR5PTDR.js.map +7 -0
- package/dist/esm/{chunk-4BU4R7UM.js → chunk-63MUJFVF.js} +3 -2
- package/dist/esm/chunk-63MUJFVF.js.map +7 -0
- package/dist/esm/{chunk-OSSNMF5U.js → chunk-647DRBXQ.js} +3 -2
- package/dist/esm/{chunk-OSSNMF5U.js.map → chunk-647DRBXQ.js.map} +1 -1
- package/dist/esm/{chunk-KKMOGHIY.js → chunk-64EFWPHI.js} +3 -2
- package/dist/esm/{chunk-KKMOGHIY.js.map → chunk-64EFWPHI.js.map} +1 -1
- package/dist/esm/{chunk-BWLCTTTN.js → chunk-65KD6WS6.js} +3 -2
- package/dist/esm/{chunk-BWLCTTTN.js.map → chunk-65KD6WS6.js.map} +2 -2
- package/dist/esm/{chunk-RWTSGUVJ.js → chunk-6AMWYEM7.js} +3 -2
- package/dist/esm/{chunk-RWTSGUVJ.js.map → chunk-6AMWYEM7.js.map} +1 -1
- package/dist/esm/chunk-6AUIIXXE.js +2 -0
- package/dist/esm/chunk-6AUIIXXE.js.map +7 -0
- package/dist/esm/{chunk-ELAW7ZUG.js → chunk-6FLLFCBU.js} +2 -2
- package/dist/esm/{chunk-4QKZYCCH.js → chunk-6RJQ5LLP.js} +3 -2
- package/dist/esm/{chunk-4QKZYCCH.js.map → chunk-6RJQ5LLP.js.map} +1 -1
- package/dist/esm/{chunk-4P6TKZCA.js → chunk-6UZT3ZLO.js} +3 -2
- package/dist/esm/{chunk-4P6TKZCA.js.map → chunk-6UZT3ZLO.js.map} +1 -1
- package/dist/esm/{chunk-I4FLQELQ.js → chunk-7B3XDZXZ.js} +3 -2
- package/dist/esm/chunk-7B3XDZXZ.js.map +7 -0
- package/dist/esm/chunk-7N2Q5WOM.js +3 -0
- package/dist/esm/chunk-7N2Q5WOM.js.map +7 -0
- package/dist/esm/{chunk-25FNCKUM.js → chunk-7ROKZHH2.js} +3 -2
- package/dist/esm/{chunk-25FNCKUM.js.map → chunk-7ROKZHH2.js.map} +1 -1
- package/dist/esm/chunk-7VJF6EXN.js +3 -0
- package/dist/esm/chunk-7VJF6EXN.js.map +7 -0
- package/dist/esm/chunk-7X7VWR3F.js +3 -0
- package/dist/esm/chunk-7X7VWR3F.js.map +7 -0
- package/dist/esm/chunk-7XHE6TOA.js +6 -0
- package/dist/esm/chunk-7XHE6TOA.js.map +7 -0
- package/dist/esm/chunk-A2OMWZI7.js +2 -0
- package/dist/esm/chunk-AQ7VUGQQ.js +3 -0
- package/dist/esm/chunk-AQ7VUGQQ.js.map +7 -0
- package/dist/esm/{chunk-XEZXKPLE.js → chunk-AXODGYRY.js} +2 -1
- package/dist/esm/{chunk-XEZXKPLE.js.map → chunk-AXODGYRY.js.map} +1 -1
- package/dist/esm/chunk-AYKOOEZR.js +2 -0
- package/dist/esm/{chunk-YHYPIJCR.js → chunk-AZHSPPBV.js} +3 -2
- package/dist/esm/{chunk-YHYPIJCR.js.map → chunk-AZHSPPBV.js.map} +1 -1
- package/dist/esm/{chunk-ERNM3KVF.js → chunk-B6YGNB3V.js} +2 -1
- package/dist/esm/{chunk-ERNM3KVF.js.map → chunk-B6YGNB3V.js.map} +1 -1
- package/dist/esm/chunk-BMKUGZ4I.js +3 -0
- package/dist/esm/{chunk-VPSMETY2.js.map → chunk-BMKUGZ4I.js.map} +1 -1
- package/dist/esm/chunk-BOLSK63X.js +3 -0
- package/dist/esm/{chunk-X4A3XRBY.js.map → chunk-BOLSK63X.js.map} +1 -1
- package/dist/esm/chunk-BVFHJP5E.js +3 -0
- package/dist/esm/chunk-BVFHJP5E.js.map +7 -0
- package/dist/esm/{chunk-H5BYPX6V.js → chunk-BXZSJKWA.js} +3 -2
- package/dist/esm/chunk-BXZSJKWA.js.map +7 -0
- package/dist/esm/{chunk-IDOZJVO6.js → chunk-CAAEEHGQ.js} +3 -2
- package/dist/esm/{chunk-IDOZJVO6.js.map → chunk-CAAEEHGQ.js.map} +1 -1
- package/dist/esm/{chunk-3QZBWH2A.js → chunk-CKJXTEVO.js} +3 -2
- package/dist/esm/chunk-CKJXTEVO.js.map +7 -0
- package/dist/esm/chunk-CLJ6SEGP.js +3 -0
- package/dist/esm/chunk-CLJ6SEGP.js.map +7 -0
- package/dist/esm/{chunk-UY6WJUNA.js → chunk-CQG4U5BR.js} +3 -2
- package/dist/esm/{chunk-UY6WJUNA.js.map → chunk-CQG4U5BR.js.map} +2 -2
- package/dist/esm/chunk-CR65RYGM.js +3 -0
- package/dist/esm/chunk-CR65RYGM.js.map +7 -0
- package/dist/esm/chunk-CV7QQTI3.js +3 -0
- package/dist/esm/chunk-CV7QQTI3.js.map +7 -0
- package/dist/esm/chunk-CYTPMHSJ.js +3 -0
- package/dist/esm/chunk-CYTPMHSJ.js.map +7 -0
- package/dist/esm/{chunk-GYP66ZK2.js → chunk-D4P7332M.js} +3 -2
- package/dist/esm/{chunk-GYP66ZK2.js.map → chunk-D4P7332M.js.map} +1 -1
- package/dist/esm/{chunk-OY5NT7VT.js → chunk-DVXDFCCV.js} +3 -2
- package/dist/esm/{chunk-OY5NT7VT.js.map → chunk-DVXDFCCV.js.map} +1 -1
- package/dist/esm/chunk-EAIQIW23.js +3 -0
- package/dist/esm/{chunk-4ZOVV3TY.js.map → chunk-EAIQIW23.js.map} +3 -3
- package/dist/esm/{chunk-RAVZ7F5L.js → chunk-EY6TCYGG.js} +3 -2
- package/dist/esm/{chunk-RAVZ7F5L.js.map → chunk-EY6TCYGG.js.map} +1 -1
- package/dist/esm/chunk-FFJE25TJ.js +3 -0
- package/dist/esm/chunk-FFJE25TJ.js.map +7 -0
- package/dist/esm/chunk-FI32HA4X.js +3 -0
- package/dist/esm/{chunk-YXLDRDHW.js.map → chunk-FI32HA4X.js.map} +3 -3
- package/dist/esm/{chunk-NA237RHQ.js → chunk-FJLYSZV3.js} +1 -1
- package/dist/esm/{chunk-NA237RHQ.js.map → chunk-FJLYSZV3.js.map} +1 -1
- package/dist/esm/{chunk-DNOQ6E3W.js → chunk-FM3GBCX5.js} +3 -2
- package/dist/esm/{chunk-DNOQ6E3W.js.map → chunk-FM3GBCX5.js.map} +1 -1
- package/dist/esm/chunk-FPGBCCML.js +3 -0
- package/dist/esm/chunk-FPGBCCML.js.map +7 -0
- package/dist/esm/{chunk-TBZO22XK.js → chunk-G66WDIIV.js} +3 -2
- package/dist/esm/{chunk-TBZO22XK.js.map → chunk-G66WDIIV.js.map} +1 -1
- package/dist/esm/{chunk-PN3RQFSU.js → chunk-GHUAUFG7.js} +2 -1
- package/dist/esm/{chunk-PN3RQFSU.js.map → chunk-GHUAUFG7.js.map} +1 -1
- package/dist/esm/chunk-GHWEXMF6.js +3 -0
- package/dist/esm/chunk-GHWEXMF6.js.map +7 -0
- package/dist/esm/{chunk-62ZGP4ET.js → chunk-GKDGNPBD.js} +2 -1
- package/dist/esm/{chunk-62ZGP4ET.js.map → chunk-GKDGNPBD.js.map} +1 -1
- package/dist/esm/{chunk-W6BN5QLH.js → chunk-GNPTPIL7.js} +3 -2
- package/dist/esm/{chunk-W6BN5QLH.js.map → chunk-GNPTPIL7.js.map} +1 -1
- package/dist/esm/chunk-HBWBPBSA.js +3 -0
- package/dist/esm/chunk-HBWBPBSA.js.map +7 -0
- package/dist/esm/{chunk-FDJV5RXX.js → chunk-HHSFAOIO.js} +3 -2
- package/dist/esm/chunk-HHSFAOIO.js.map +7 -0
- package/dist/esm/chunk-I3SRUPUP.js +3 -0
- package/dist/esm/chunk-I3SRUPUP.js.map +7 -0
- package/dist/esm/{chunk-3XHTJZNP.js → chunk-I6SMGWS5.js} +3 -2
- package/dist/esm/{chunk-3XHTJZNP.js.map → chunk-I6SMGWS5.js.map} +1 -1
- package/dist/esm/chunk-ILWS2JUE.js +3 -0
- package/dist/esm/chunk-ILWS2JUE.js.map +7 -0
- package/dist/esm/{chunk-QWDCLL6R.js → chunk-IN2WND4B.js} +3 -2
- package/dist/esm/{chunk-QWDCLL6R.js.map → chunk-IN2WND4B.js.map} +1 -1
- package/dist/esm/chunk-IO43RGNR.js +3 -0
- package/dist/esm/chunk-IO43RGNR.js.map +7 -0
- package/dist/esm/{chunk-DCNHG6VN.js → chunk-IZIDRDQW.js} +3 -2
- package/dist/esm/{chunk-DCNHG6VN.js.map → chunk-IZIDRDQW.js.map} +1 -1
- package/dist/esm/{chunk-7FTUTUMD.js → chunk-IZXML75Y.js} +2 -2
- package/dist/esm/chunk-J3QIUJ6F.js +2 -0
- package/dist/esm/{chunk-PBFSBHBS.js → chunk-JUY7CBSL.js} +2 -2
- package/dist/esm/chunk-JZ5Z53MN.js +2 -0
- package/dist/esm/{chunk-IWCFJJBI.js → chunk-KOAWATCI.js} +2 -1
- package/dist/esm/{chunk-IWCFJJBI.js.map → chunk-KOAWATCI.js.map} +1 -1
- package/dist/esm/chunk-KRFXTPEW.js +3 -0
- package/dist/esm/{chunk-63PQNLFJ.js.map → chunk-KRFXTPEW.js.map} +1 -1
- package/dist/esm/chunk-KSYHZCLD.js +3 -0
- package/dist/esm/{chunk-EZYXYLR2.js.map → chunk-KSYHZCLD.js.map} +1 -1
- package/dist/esm/{chunk-VW46DG7H.js → chunk-L4NF3Q2T.js} +3 -2
- package/dist/esm/{chunk-VW46DG7H.js.map → chunk-L4NF3Q2T.js.map} +1 -1
- package/dist/esm/chunk-L54FWKJE.js +3 -0
- package/dist/esm/chunk-L54FWKJE.js.map +7 -0
- package/dist/esm/{chunk-XTDXXQTB.js → chunk-L66IUPDW.js} +3 -2
- package/dist/esm/{chunk-XTDXXQTB.js.map → chunk-L66IUPDW.js.map} +1 -1
- package/dist/esm/chunk-LPLW7OWA.js +3 -0
- package/dist/esm/chunk-LPLW7OWA.js.map +7 -0
- package/dist/esm/chunk-M37GE2TE.js +3 -0
- package/dist/esm/{chunk-UONSKZQT.js.map → chunk-M37GE2TE.js.map} +1 -1
- package/dist/esm/{chunk-5YLKKQFK.js → chunk-MAA6LEE2.js} +2 -1
- package/dist/esm/{chunk-5YLKKQFK.js.map → chunk-MAA6LEE2.js.map} +1 -1
- package/dist/esm/chunk-MQEWEAH5.js +3 -0
- package/dist/esm/chunk-MQEWEAH5.js.map +7 -0
- package/dist/esm/chunk-MXIVYALY.js +3 -0
- package/dist/esm/chunk-MXIVYALY.js.map +7 -0
- package/dist/esm/chunk-N3QLHFHB.js +3 -0
- package/dist/esm/chunk-N3QLHFHB.js.map +7 -0
- package/dist/esm/{chunk-VVWYAVHM.js → chunk-N5H7C3PZ.js} +3 -2
- package/dist/esm/chunk-N5H7C3PZ.js.map +7 -0
- package/dist/esm/{chunk-LXTGEI62.js → chunk-NBVCQQSY.js} +3 -2
- package/dist/esm/{chunk-LXTGEI62.js.map → chunk-NBVCQQSY.js.map} +1 -1
- package/dist/esm/chunk-NG54K6FL.js +2 -0
- package/dist/esm/chunk-OAJ5DARR.js +3 -0
- package/dist/esm/chunk-OAJ5DARR.js.map +7 -0
- package/dist/esm/chunk-OKQAVYW4.js +3 -0
- package/dist/esm/chunk-OKQAVYW4.js.map +7 -0
- package/dist/esm/chunk-OQWD63AI.js +3 -0
- package/dist/esm/chunk-OQWD63AI.js.map +7 -0
- package/dist/esm/chunk-PCLO3ZZY.js +3 -0
- package/dist/esm/chunk-PCLO3ZZY.js.map +7 -0
- package/dist/esm/chunk-PHWT772P.js +3 -0
- package/dist/esm/{chunk-XZQSSRTG.js.map → chunk-PHWT772P.js.map} +1 -1
- package/dist/esm/{chunk-FNAE6HUI.js → chunk-PT45Q47V.js} +3 -2
- package/dist/esm/{chunk-FNAE6HUI.js.map → chunk-PT45Q47V.js.map} +1 -1
- package/dist/esm/{chunk-HCBR74BW.js → chunk-PT4KBXXP.js} +3 -2
- package/dist/esm/{chunk-HCBR74BW.js.map → chunk-PT4KBXXP.js.map} +1 -1
- package/dist/esm/{chunk-CHPT42BY.js → chunk-PZ6Z7WTR.js} +3 -2
- package/dist/esm/{chunk-CHPT42BY.js.map → chunk-PZ6Z7WTR.js.map} +1 -1
- package/dist/esm/{chunk-PSPENFPH.js → chunk-PZCQDZVJ.js} +3 -2
- package/dist/esm/{chunk-PSPENFPH.js.map → chunk-PZCQDZVJ.js.map} +1 -1
- package/dist/esm/chunk-PZZJH2LR.js +3 -0
- package/dist/esm/chunk-PZZJH2LR.js.map +7 -0
- package/dist/esm/{chunk-I53SGTKV.js → chunk-QH64BDXO.js} +3 -2
- package/dist/esm/{chunk-I53SGTKV.js.map → chunk-QH64BDXO.js.map} +1 -1
- package/dist/esm/chunk-QKCNGEX4.js +3 -0
- package/dist/esm/chunk-QKCNGEX4.js.map +7 -0
- package/dist/esm/{chunk-LUNWI377.js → chunk-QQY4WFJL.js} +3 -2
- package/dist/esm/{chunk-LUNWI377.js.map → chunk-QQY4WFJL.js.map} +1 -1
- package/dist/esm/{chunk-PM6QY3JO.js → chunk-R4PGFURL.js} +3 -2
- package/dist/esm/chunk-R4PGFURL.js.map +7 -0
- package/dist/esm/chunk-RB5VHWAW.js +3 -0
- package/dist/esm/chunk-RB5VHWAW.js.map +7 -0
- package/dist/esm/{chunk-BE7LMBBC.js → chunk-RIHTVZVJ.js} +3 -2
- package/dist/esm/{chunk-BE7LMBBC.js.map → chunk-RIHTVZVJ.js.map} +1 -1
- package/dist/esm/{chunk-3XZOE2IQ.js → chunk-RVPLXLRA.js} +3 -2
- package/dist/esm/{chunk-3XZOE2IQ.js.map → chunk-RVPLXLRA.js.map} +1 -1
- package/dist/esm/{chunk-GS2QSZUR.js → chunk-SCIFT27R.js} +2 -1
- package/dist/esm/{chunk-GS2QSZUR.js.map → chunk-SCIFT27R.js.map} +1 -1
- package/dist/esm/chunk-SGJKXIWG.js +3 -0
- package/dist/esm/{chunk-DFGY2NZB.js.map → chunk-SGJKXIWG.js.map} +1 -1
- package/dist/esm/chunk-SHLERRO3.js +3 -0
- package/dist/esm/chunk-SHLERRO3.js.map +7 -0
- package/dist/esm/chunk-SV3CYQY5.js +3 -0
- package/dist/esm/{chunk-LVCUY2OS.js.map → chunk-SV3CYQY5.js.map} +2 -2
- package/dist/esm/chunk-TDT2CNES.js +2 -0
- package/dist/esm/chunk-TDT2CNES.js.map +7 -0
- package/dist/esm/chunk-TGRHRMQI.js +3 -0
- package/dist/esm/chunk-TGRHRMQI.js.map +7 -0
- package/dist/esm/{chunk-HIEGLLY7.js → chunk-TGUWRU7N.js} +2 -1
- package/dist/esm/{chunk-HIEGLLY7.js.map → chunk-TGUWRU7N.js.map} +1 -1
- package/dist/esm/{chunk-7ZOGH5NT.js → chunk-U5GQ3IFS.js} +2 -1
- package/dist/esm/{chunk-7ZOGH5NT.js.map → chunk-U5GQ3IFS.js.map} +1 -1
- package/dist/esm/chunk-VPRAXHLL.js +3 -0
- package/dist/esm/chunk-VPRAXHLL.js.map +7 -0
- package/dist/esm/{chunk-OS3FCYZY.js → chunk-VQPANPMI.js} +2 -1
- package/dist/esm/chunk-VRQEWMC6.js +3 -0
- package/dist/esm/chunk-VRQEWMC6.js.map +7 -0
- package/dist/esm/chunk-VVBSYWUA.js +3 -0
- package/dist/esm/chunk-VVBSYWUA.js.map +7 -0
- package/dist/esm/{chunk-RKZVXVBN.js → chunk-W4MQ6TEK.js} +3 -2
- package/dist/esm/chunk-W4MQ6TEK.js.map +7 -0
- package/dist/esm/chunk-WCGQ4IDE.js +3 -0
- package/dist/esm/{chunk-H3IAGAEL.js.map → chunk-WCGQ4IDE.js.map} +1 -1
- package/dist/esm/{chunk-HWQ3NTJP.js → chunk-WEBNIUEX.js} +2 -1
- package/dist/esm/{chunk-HWQ3NTJP.js.map → chunk-WEBNIUEX.js.map} +1 -1
- package/dist/esm/chunk-WH7PQSSG.js +2 -0
- package/dist/esm/{chunk-PALE5UWK.js → chunk-WJ4H2O2G.js} +3 -2
- package/dist/esm/{chunk-PALE5UWK.js.map → chunk-WJ4H2O2G.js.map} +1 -1
- package/dist/esm/chunk-WMODMXEU.js +3 -0
- package/dist/esm/chunk-WMODMXEU.js.map +7 -0
- package/dist/esm/{chunk-KL73COYX.js → chunk-WMZLMZHB.js} +2 -1
- package/dist/esm/{chunk-KL73COYX.js.map → chunk-WMZLMZHB.js.map} +1 -1
- package/dist/esm/{chunk-GBQZ4Z2H.js → chunk-WN3WMFAM.js} +3 -2
- package/dist/esm/{chunk-GBQZ4Z2H.js.map → chunk-WN3WMFAM.js.map} +1 -1
- package/dist/esm/{chunk-ETQNRMHU.js → chunk-WT2SYGTU.js} +3 -2
- package/dist/esm/{chunk-ETQNRMHU.js.map → chunk-WT2SYGTU.js.map} +1 -1
- package/dist/esm/{chunk-SUPFDIJL.js → chunk-WTP2KIK3.js} +2 -1
- package/dist/esm/{chunk-SUPFDIJL.js.map → chunk-WTP2KIK3.js.map} +1 -1
- package/dist/esm/{chunk-AGAQC4HH.js → chunk-WUCBFB25.js} +2 -1
- package/dist/esm/{chunk-AGAQC4HH.js.map → chunk-WUCBFB25.js.map} +1 -1
- package/dist/esm/chunk-WZKSLTBH.js +3 -0
- package/dist/esm/{chunk-BJUCBOGU.js.map → chunk-WZKSLTBH.js.map} +1 -1
- package/dist/esm/{chunk-CN6F4REJ.js → chunk-XH2CRCXR.js} +2 -1
- package/dist/esm/{chunk-CN6F4REJ.js.map → chunk-XH2CRCXR.js.map} +1 -1
- package/dist/esm/{chunk-KZEZDBE7.js → chunk-XL5OHW6Z.js} +3 -2
- package/dist/esm/{chunk-KZEZDBE7.js.map → chunk-XL5OHW6Z.js.map} +1 -1
- package/dist/esm/chunk-XMHNOIPB.js +3 -0
- package/dist/esm/{chunk-3BUQ7ADW.js.map → chunk-XMHNOIPB.js.map} +1 -1
- package/dist/esm/{chunk-YEHM3FZN.js → chunk-XPVRXQSW.js} +3 -2
- package/dist/esm/chunk-XPVRXQSW.js.map +7 -0
- package/dist/esm/chunk-XU74PNM2.js +3 -0
- package/dist/esm/chunk-XU74PNM2.js.map +7 -0
- package/dist/esm/{chunk-3J6AUDID.js → chunk-XUCR7L4G.js} +2 -1
- package/dist/esm/{chunk-3J6AUDID.js.map → chunk-XUCR7L4G.js.map} +1 -1
- package/dist/esm/chunk-XVDT6DQZ.js +3 -0
- package/dist/esm/{chunk-TZTUPQYK.js.map → chunk-XVDT6DQZ.js.map} +1 -1
- package/dist/esm/chunk-Y2BTPKK6.js +3 -0
- package/dist/esm/chunk-Y2BTPKK6.js.map +7 -0
- package/dist/esm/{chunk-2N2AQNJH.js → chunk-Y2DBXOLT.js} +2 -1
- package/dist/esm/{chunk-2N2AQNJH.js.map → chunk-Y2DBXOLT.js.map} +1 -1
- package/dist/esm/chunk-YD2D73LF.js +3 -0
- package/dist/esm/chunk-YD2D73LF.js.map +7 -0
- package/dist/esm/chunk-YOSCUA6Z.js +3 -0
- package/dist/esm/chunk-YOSCUA6Z.js.map +7 -0
- package/dist/esm/chunk-YOSLXJI5.js +3 -0
- package/dist/esm/chunk-YOSLXJI5.js.map +7 -0
- package/dist/esm/chunk-YWG476GC.js +3 -0
- package/dist/esm/{chunk-MGQ4A2FI.js.map → chunk-YWG476GC.js.map} +1 -1
- package/dist/esm/chunk-YZZMQ457.js +3 -0
- package/dist/esm/{chunk-S6GWR6EZ.js.map → chunk-YZZMQ457.js.map} +1 -1
- package/dist/esm/chunk-Z27REN6T.js +3 -0
- package/dist/esm/chunk-Z27REN6T.js.map +7 -0
- package/dist/esm/chunk-Z563IAE3.js +3 -0
- package/dist/esm/chunk-Z563IAE3.js.map +7 -0
- package/dist/esm/{chunk-THUBY6L2.js → chunk-ZDSY6CJL.js} +3 -2
- package/dist/esm/chunk-ZDSY6CJL.js.map +7 -0
- package/dist/esm/{chunk-FVY44PTM.js → chunk-ZFDHZEWN.js} +3 -2
- package/dist/esm/{chunk-FVY44PTM.js.map → chunk-ZFDHZEWN.js.map} +1 -1
- package/dist/esm/chunk-ZPWKWESI.js +3 -0
- package/dist/esm/chunk-ZPWKWESI.js.map +7 -0
- package/dist/esm/chunk-ZYKJTNAT.js +3 -0
- package/dist/esm/chunk-ZYKJTNAT.js.map +7 -0
- package/dist/esm/components/_internal/base-button.d.ts.map +1 -1
- package/dist/esm/components/_internal/base-button.js +2 -1
- package/dist/esm/components/_internal/base-button.props.js +2 -1
- package/dist/esm/components/_internal/base-checkbox.props.js +2 -1
- package/dist/esm/components/_internal/base-menu.props.js +2 -1
- package/dist/esm/components/_internal/base-menu.utils.js +2 -1
- package/dist/esm/components/_internal/base-radio.props.js +2 -1
- package/dist/esm/components/_internal/base-tab-list.props.js +2 -1
- package/dist/esm/components/_internal/dropdown-menu-drill-down.d.ts +19 -7
- package/dist/esm/components/_internal/dropdown-menu-drill-down.d.ts.map +1 -1
- package/dist/esm/components/_internal/dropdown-menu-drill-down.js +2 -1
- package/dist/esm/components/_internal/menu-context.d.ts +10 -0
- package/dist/esm/components/_internal/menu-context.d.ts.map +1 -1
- package/dist/esm/components/_internal/menu-context.js +2 -1
- package/dist/esm/components/_internal/pane-chrome.d.ts +3 -1
- package/dist/esm/components/_internal/pane-chrome.d.ts.map +1 -1
- package/dist/esm/components/_internal/pane-chrome.js +2 -1
- package/dist/esm/components/_internal/shell-bottom.d.ts +1 -1
- package/dist/esm/components/_internal/shell-bottom.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-bottom.js +2 -1
- package/dist/esm/components/_internal/shell-handles.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-handles.js +2 -1
- package/dist/esm/components/_internal/shell-inspector.d.ts +1 -1
- package/dist/esm/components/_internal/shell-inspector.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-inspector.js +2 -1
- package/dist/esm/components/_internal/shell-pane.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-pane.js +2 -1
- package/dist/esm/components/_internal/shell-resizable.d.ts +6 -0
- package/dist/esm/components/_internal/shell-resizable.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-resizable.js +2 -1
- package/dist/esm/components/_internal/shell-resize.js +2 -1
- package/dist/esm/components/_internal/shell-rest.js +2 -1
- package/dist/esm/components/_internal/shell-sidebar.d.ts +1 -1
- package/dist/esm/components/_internal/shell-sidebar.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-sidebar.js +2 -1
- package/dist/esm/components/_internal/shell-store.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-store.js +2 -1
- package/dist/esm/components/accessible-icon.js +2 -1
- package/dist/esm/components/accordion.d.ts.map +1 -1
- package/dist/esm/components/accordion.js +2 -1
- package/dist/esm/components/accordion.props.js +2 -1
- package/dist/esm/components/alert-dialog.d.ts.map +1 -1
- package/dist/esm/components/alert-dialog.js +2 -1
- package/dist/esm/components/alert-dialog.props.js +2 -1
- package/dist/esm/components/avatar.d.ts.map +1 -1
- package/dist/esm/components/avatar.js +2 -1
- package/dist/esm/components/avatar.props.js +2 -1
- package/dist/esm/components/blockquote.js +2 -1
- package/dist/esm/components/blockquote.props.js +2 -1
- package/dist/esm/components/box.js +2 -1
- package/dist/esm/components/box.props.js +2 -1
- package/dist/esm/components/button.d.ts.map +1 -1
- package/dist/esm/components/button.js +2 -1
- package/dist/esm/components/button.props.js +2 -1
- package/dist/esm/components/card.js +2 -1
- package/dist/esm/components/card.props.js +2 -1
- package/dist/esm/components/chatbar.d.ts.map +1 -1
- package/dist/esm/components/chatbar.js +2 -1
- package/dist/esm/components/checkbox-group.js +2 -1
- package/dist/esm/components/checkbox-group.primitive.js +2 -1
- package/dist/esm/components/checkbox-group.props.js +2 -1
- package/dist/esm/components/checkbox.js +2 -1
- package/dist/esm/components/checkbox.props.js +2 -1
- package/dist/esm/components/chip.js +2 -1
- package/dist/esm/components/chip.props.js +2 -1
- package/dist/esm/components/code.js +2 -1
- package/dist/esm/components/code.props.js +2 -1
- package/dist/esm/components/combobox.d.ts.map +1 -1
- package/dist/esm/components/combobox.js +2 -1
- package/dist/esm/components/combobox.props.js +2 -1
- package/dist/esm/components/context-menu.d.ts +1 -2
- package/dist/esm/components/context-menu.d.ts.map +1 -1
- package/dist/esm/components/context-menu.js +2 -1
- package/dist/esm/components/context-menu.props.js +2 -1
- package/dist/esm/components/dialog.js +2 -1
- package/dist/esm/components/dialog.props.js +2 -1
- package/dist/esm/components/dropdown-menu.d.ts +1 -2
- package/dist/esm/components/dropdown-menu.d.ts.map +1 -1
- package/dist/esm/components/dropdown-menu.js +2 -1
- package/dist/esm/components/dropdown-menu.props.js +2 -1
- package/dist/esm/components/flex.js +2 -1
- package/dist/esm/components/flex.props.js +2 -1
- package/dist/esm/components/grid.js +2 -1
- package/dist/esm/components/grid.props.js +2 -1
- package/dist/esm/components/heading.d.ts +2 -2
- package/dist/esm/components/heading.d.ts.map +1 -1
- package/dist/esm/components/heading.js +2 -1
- package/dist/esm/components/heading.props.d.ts +1 -1
- package/dist/esm/components/heading.props.js +2 -1
- package/dist/esm/components/icons.js +2 -1
- package/dist/esm/components/image.d.ts +9 -2
- package/dist/esm/components/image.d.ts.map +1 -1
- package/dist/esm/components/image.js +2 -1
- package/dist/esm/components/image.props.js +2 -1
- package/dist/esm/components/index.d.ts +1 -1
- package/dist/esm/components/index.d.ts.map +1 -1
- package/dist/esm/components/index.js +2 -1
- package/dist/esm/components/kbd.js +2 -1
- package/dist/esm/components/kbd.props.js +2 -1
- package/dist/esm/components/link.js +2 -1
- package/dist/esm/components/link.props.js +2 -1
- package/dist/esm/components/message-scroller.d.ts +2 -2
- package/dist/esm/components/message-scroller.d.ts.map +1 -1
- package/dist/esm/components/message-scroller.js +2 -1
- package/dist/esm/components/navbar.js +2 -1
- package/dist/esm/components/navbar.props.js +2 -1
- package/dist/esm/components/notice.js +2 -1
- package/dist/esm/components/popover.d.ts +3 -1
- package/dist/esm/components/popover.d.ts.map +1 -1
- package/dist/esm/components/popover.js +2 -1
- package/dist/esm/components/popover.props.js +2 -1
- package/dist/esm/components/portal.js +2 -1
- package/dist/esm/components/progress.d.ts.map +1 -1
- package/dist/esm/components/progress.js +2 -1
- package/dist/esm/components/progress.props.js +2 -1
- package/dist/esm/components/radio-group.js +2 -1
- package/dist/esm/components/radio-group.props.js +2 -1
- package/dist/esm/components/radio.js +2 -1
- package/dist/esm/components/radio.props.js +2 -1
- package/dist/esm/components/reset.js +2 -1
- package/dist/esm/components/schemas/base-button.schema.js +2 -1
- package/dist/esm/components/schemas/button.schema.js +2 -1
- package/dist/esm/components/schemas/index.js +2 -1
- package/dist/esm/components/schemas/index.js.map +1 -1
- package/dist/esm/components/schemas/shell.schema.js +2 -1
- package/dist/esm/components/schemas/toggle.schema.js +2 -1
- package/dist/esm/components/scroll-area.js +2 -1
- package/dist/esm/components/scroll-area.props.js +2 -1
- package/dist/esm/components/segmented-control.d.ts.map +1 -1
- package/dist/esm/components/segmented-control.js +2 -1
- package/dist/esm/components/segmented-control.props.d.ts +0 -1
- package/dist/esm/components/segmented-control.props.d.ts.map +1 -1
- package/dist/esm/components/segmented-control.props.js +2 -1
- package/dist/esm/components/select.d.ts.map +1 -1
- package/dist/esm/components/select.js +2 -1
- package/dist/esm/components/select.props.js +2 -1
- package/dist/esm/components/separator.d.ts.map +1 -1
- package/dist/esm/components/separator.js +2 -1
- package/dist/esm/components/separator.props.d.ts +1 -1
- package/dist/esm/components/separator.props.js +2 -1
- package/dist/esm/components/sheet.d.ts +1 -1
- package/dist/esm/components/sheet.d.ts.map +1 -1
- package/dist/esm/components/sheet.js +2 -1
- package/dist/esm/components/shell.context.js +2 -1
- package/dist/esm/components/shell.d.ts +5 -2
- package/dist/esm/components/shell.d.ts.map +1 -1
- package/dist/esm/components/shell.hooks.js +2 -1
- package/dist/esm/components/shell.js +2 -1
- package/dist/esm/components/shell.types.js +2 -1
- package/dist/esm/components/sidebar.d.ts.map +1 -1
- package/dist/esm/components/sidebar.js +2 -1
- package/dist/esm/components/slider.d.ts.map +1 -1
- package/dist/esm/components/slider.js +2 -1
- package/dist/esm/components/slider.props.d.ts +0 -2
- package/dist/esm/components/slider.props.d.ts.map +1 -1
- package/dist/esm/components/slider.props.js +2 -1
- package/dist/esm/components/slot.js +2 -1
- package/dist/esm/components/spinner.d.ts.map +1 -1
- package/dist/esm/components/spinner.js +2 -1
- package/dist/esm/components/spinner.props.js +2 -1
- package/dist/esm/components/switch.js +2 -1
- package/dist/esm/components/switch.props.js +2 -1
- package/dist/esm/components/table.d.ts.map +1 -1
- package/dist/esm/components/table.js +2 -1
- package/dist/esm/components/table.props.d.ts +0 -2
- package/dist/esm/components/table.props.d.ts.map +1 -1
- package/dist/esm/components/table.props.js +2 -1
- package/dist/esm/components/tabs.d.ts.map +1 -1
- package/dist/esm/components/tabs.js +2 -1
- package/dist/esm/components/tabs.props.js +2 -1
- package/dist/esm/components/text-area.d.ts.map +1 -1
- package/dist/esm/components/text-area.js +2 -1
- package/dist/esm/components/text-area.props.js +2 -1
- package/dist/esm/components/text-field.d.ts.map +1 -1
- package/dist/esm/components/text-field.js +2 -1
- package/dist/esm/components/text-field.props.js +2 -1
- package/dist/esm/components/text.js +2 -1
- package/dist/esm/components/text.props.js +2 -1
- package/dist/esm/components/theme.d.ts.map +1 -1
- package/dist/esm/components/theme.js +2 -1
- package/dist/esm/components/theme.props.js +2 -1
- package/dist/esm/components/toggle.js +2 -1
- package/dist/esm/components/toolbar.d.ts +4 -1
- package/dist/esm/components/toolbar.d.ts.map +1 -1
- package/dist/esm/components/toolbar.js +2 -1
- package/dist/esm/components/toolbar.props.js +2 -1
- package/dist/esm/components/tooltip.d.ts +13 -2
- package/dist/esm/components/tooltip.d.ts.map +1 -1
- package/dist/esm/components/tooltip.js +2 -1
- package/dist/esm/components/tooltip.props.js +2 -1
- package/dist/esm/components/virtual-menu.d.ts +19 -12
- package/dist/esm/components/virtual-menu.d.ts.map +1 -1
- package/dist/esm/components/virtual-menu.js +2 -1
- package/dist/esm/components/visually-hidden.js +2 -1
- package/dist/esm/helpers/compile-prop-defs.js +1 -1
- package/dist/esm/helpers/extract-margin-props.js +1 -1
- package/dist/esm/helpers/extract-props.js +1 -1
- package/dist/esm/helpers/font-config.js +1 -1
- package/dist/esm/helpers/get-margin-styles.d.ts.map +1 -1
- package/dist/esm/helpers/get-margin-styles.js +1 -1
- package/dist/esm/helpers/get-matching-gray-color.js +1 -1
- package/dist/esm/helpers/get-responsive-styles.js +1 -1
- package/dist/esm/helpers/get-subtree.js +1 -1
- package/dist/esm/helpers/has-own-property.js +1 -1
- package/dist/esm/helpers/index.d.ts +1 -0
- package/dist/esm/helpers/index.d.ts.map +1 -1
- package/dist/esm/helpers/index.js +1 -1
- package/dist/esm/helpers/index.js.map +4 -4
- package/dist/esm/helpers/inert.js +1 -1
- package/dist/esm/helpers/inert.js.map +1 -1
- package/dist/esm/helpers/is-responsive-object.js +1 -1
- package/dist/esm/helpers/map-prop-values.js +1 -1
- package/dist/esm/helpers/merge-styles.js +1 -1
- package/dist/esm/helpers/normalize-to-px.js +1 -1
- package/dist/esm/helpers/require-react-element.js +1 -1
- package/dist/esm/helpers/theme-size.d.ts +8 -30
- package/dist/esm/helpers/theme-size.d.ts.map +1 -1
- package/dist/esm/helpers/theme-size.js +1 -1
- package/dist/esm/helpers/warn-deprecated.js +1 -1
- package/dist/esm/helpers/warn-deprecated.js.map +4 -4
- package/dist/esm/hooks/appearance-script.js +11 -1
- package/dist/esm/hooks/appearance-script.js.map +4 -4
- package/dist/esm/hooks/index.js +2 -1
- package/dist/esm/hooks/theme-size.d.ts +32 -0
- package/dist/esm/hooks/theme-size.d.ts.map +1 -0
- package/dist/esm/hooks/theme-size.js +3 -0
- package/dist/esm/hooks/use-appearance.d.ts.map +1 -1
- package/dist/esm/hooks/use-appearance.js +2 -1
- package/dist/esm/hooks/use-body-pointer-events-cleanup.d.ts +1 -1
- package/dist/esm/hooks/use-body-pointer-events-cleanup.d.ts.map +1 -1
- package/dist/esm/hooks/use-body-pointer-events-cleanup.js +2 -1
- package/dist/esm/hooks/use-breakpoint.js +2 -1
- package/dist/esm/hooks/use-live-announcer.js +2 -1
- package/dist/esm/hooks/use-prop-synced-state.js +2 -1
- package/dist/esm/hooks/use-scroll-edges.js +2 -1
- package/dist/esm/hooks/use-thumb-sync.js +2 -1
- package/dist/esm/hooks/use-toggle-state.js +2 -1
- package/dist/esm/hooks/use-tooltip-wrapper.js +2 -1
- package/dist/esm/index.js +2 -1
- package/dist/esm/props/as-child.prop.js +1 -1
- package/dist/esm/props/color.prop.js +1 -1
- package/dist/esm/props/emphasis.prop.js +1 -1
- package/dist/esm/props/font-family.prop.js +1 -1
- package/dist/esm/props/font-family.prop.js.map +4 -4
- package/dist/esm/props/gap.props.d.ts +4 -4
- package/dist/esm/props/gap.props.js +1 -1
- package/dist/esm/props/height.props.js +1 -1
- package/dist/esm/props/index.js +1 -1
- package/dist/esm/props/index.js.map +3 -3
- package/dist/esm/props/layout.props.js +1 -1
- package/dist/esm/props/leading-trim.prop.js +1 -1
- package/dist/esm/props/margin.props.js +1 -1
- package/dist/esm/props/padding.props.js +1 -1
- package/dist/esm/props/prop-def.js +1 -1
- package/dist/esm/props/radius.prop.js +1 -1
- package/dist/esm/props/shadow.props.js +1 -1
- package/dist/esm/props/text-align.prop.js +1 -1
- package/dist/esm/props/text-wrap.prop.js +1 -1
- package/dist/esm/props/truncate.prop.js +1 -1
- package/dist/esm/props/weight.prop.js +1 -1
- package/dist/esm/props/width.props.js +1 -1
- package/layout/utilities.css +2 -2
- package/layout.css +2 -2
- package/package.json +3 -7
- package/src/components/_internal/base-button.css +24 -6
- package/src/components/_internal/base-button.props.ts +1 -1
- package/src/components/_internal/base-button.tsx +101 -42
- package/src/components/_internal/base-checkbox.css +23 -0
- package/src/components/_internal/base-menu.css +9 -3
- package/src/components/_internal/base-radio.css +22 -0
- package/src/components/_internal/base-tab-list.css +5 -0
- package/src/components/_internal/dropdown-menu-drill-down.tsx +45 -26
- package/src/components/_internal/menu-context.tsx +36 -1
- package/src/components/_internal/pane-chrome.tsx +8 -6
- package/src/components/_internal/shell-bottom.tsx +2 -0
- package/src/components/_internal/shell-handles.tsx +10 -1
- package/src/components/_internal/shell-inspector.tsx +6 -1
- package/src/components/_internal/shell-pane.tsx +5 -4
- package/src/components/_internal/shell-resizable.tsx +30 -8
- package/src/components/_internal/shell-sidebar.tsx +6 -1
- package/src/components/_internal/shell-store.tsx +2 -1
- package/src/components/accordion.css +55 -69
- package/src/components/accordion.tsx +1 -27
- package/src/components/alert-dialog.tsx +5 -1
- package/src/components/avatar.css +6 -2
- package/src/components/avatar.tsx +37 -4
- package/src/components/blockquote.css +2 -2
- package/src/components/button.tsx +12 -5
- package/src/components/card.css +14 -3
- package/src/components/card.tsx +1 -1
- package/src/components/chatbar.css +20 -3
- package/src/components/chatbar.tsx +15 -12
- package/src/components/checkbox-group.css +1 -5
- package/src/components/checkbox-group.tsx +1 -1
- package/src/components/checkbox.css +1 -5
- package/src/components/checkbox.tsx +1 -1
- package/src/components/chip.css +0 -3
- package/src/components/combobox.tsx +26 -27
- package/src/components/context-menu.tsx +48 -28
- package/src/components/dialog.tsx +1 -1
- package/src/components/dropdown-menu.css +0 -6
- package/src/components/dropdown-menu.tsx +72 -35
- package/src/components/heading.props.tsx +1 -1
- package/src/components/heading.tsx +4 -4
- package/src/components/image.css +5 -0
- package/src/components/image.tsx +29 -3
- package/src/components/index.tsx +1 -1
- package/src/components/kbd.css +6 -5
- package/src/components/link.css +1 -5
- package/src/components/message-scroller.tsx +15 -26
- package/src/components/navbar.css +9 -1
- package/src/components/navbar.tsx +1 -1
- package/src/components/notice.tsx +1 -1
- package/src/components/popover.css +18 -12
- package/src/components/popover.tsx +14 -12
- package/src/components/progress.css +33 -6
- package/src/components/progress.tsx +5 -3
- package/src/components/radio-group.tsx +1 -1
- package/src/components/radio.tsx +1 -1
- package/src/components/scroll-area.css +34 -4
- package/src/components/segmented-control.css +178 -148
- package/src/components/segmented-control.props.tsx +1 -1
- package/src/components/segmented-control.tsx +89 -64
- package/src/components/select.css +16 -29
- package/src/components/select.tsx +5 -16
- package/src/components/separator.css +8 -1
- package/src/components/separator.props.tsx +1 -1
- package/src/components/separator.tsx +22 -4
- package/src/components/sheet.css +8 -7
- package/src/components/sheet.tsx +4 -2
- package/src/components/shell.css +148 -21
- package/src/components/shell.tsx +19 -2
- package/src/components/sidebar.css +1 -135
- package/src/components/sidebar.tsx +194 -161
- package/src/components/slider.css +90 -21
- package/src/components/slider.props.tsx +2 -2
- package/src/components/slider.tsx +79 -92
- package/src/components/spinner.css +10 -2
- package/src/components/spinner.tsx +5 -1
- package/src/components/switch.css +40 -8
- package/src/components/switch.tsx +1 -1
- package/src/components/table.css +5 -1
- package/src/components/table.props.tsx +0 -9
- package/src/components/table.tsx +3 -2
- package/src/components/tabs.tsx +11 -4
- package/src/components/text-area.css +17 -2
- package/src/components/text-area.tsx +21 -17
- package/src/components/text-field.css +51 -36
- package/src/components/text-field.tsx +101 -50
- package/src/components/theme.tsx +15 -45
- package/src/components/toolbar.tsx +52 -16
- package/src/components/tooltip.css +8 -1
- package/src/components/tooltip.tsx +30 -3
- package/src/components/virtual-menu.css +80 -0
- package/src/components/virtual-menu.tsx +103 -62
- package/src/helpers/get-margin-styles.ts +8 -10
- package/src/helpers/index.ts +3 -0
- package/src/helpers/theme-size.ts +8 -46
- package/src/hooks/theme-size.ts +50 -0
- package/src/hooks/use-appearance.ts +32 -19
- package/src/hooks/use-body-pointer-events-cleanup.ts +123 -124
- package/src/props/gap.props.ts +4 -4
- package/src/styles/tokens/color.css +3 -0
- package/src/styles/utilities/margin.css +2 -2
- package/src/styles/utilities/text-align.css +8 -0
- package/styles.css +1837 -808
- package/tokens/base.css +2 -0
- package/tokens.css +2 -0
- package/utilities.css +38 -2
- package/dist/esm/chunk-2E4P5XQL.js +0 -2
- package/dist/esm/chunk-2E4P5XQL.js.map +0 -7
- package/dist/esm/chunk-2KZ4NI3X.js +0 -1
- package/dist/esm/chunk-3BUQ7ADW.js +0 -2
- package/dist/esm/chunk-3PTKPDSA.js +0 -2
- package/dist/esm/chunk-3PTKPDSA.js.map +0 -7
- package/dist/esm/chunk-3QZBWH2A.js.map +0 -7
- package/dist/esm/chunk-3VTS4C63.js +0 -2
- package/dist/esm/chunk-3VTS4C63.js.map +0 -7
- package/dist/esm/chunk-3WE4E2WQ.js +0 -2
- package/dist/esm/chunk-3WE4E2WQ.js.map +0 -7
- package/dist/esm/chunk-3XUY5WFA.js +0 -2
- package/dist/esm/chunk-3XUY5WFA.js.map +0 -7
- package/dist/esm/chunk-3YLYGKFB.js +0 -2
- package/dist/esm/chunk-3YLYGKFB.js.map +0 -7
- package/dist/esm/chunk-432YLNB3.js +0 -2
- package/dist/esm/chunk-432YLNB3.js.map +0 -7
- package/dist/esm/chunk-4BU4R7UM.js.map +0 -7
- package/dist/esm/chunk-4R5EMVB3.js +0 -2
- package/dist/esm/chunk-4R5EMVB3.js.map +0 -7
- package/dist/esm/chunk-4ZOVV3TY.js +0 -2
- package/dist/esm/chunk-5ROQAZ7J.js +0 -2
- package/dist/esm/chunk-5ROQAZ7J.js.map +0 -7
- package/dist/esm/chunk-63PQNLFJ.js +0 -2
- package/dist/esm/chunk-6DWDNKLS.js +0 -1
- package/dist/esm/chunk-7CUQMU3T.js +0 -2
- package/dist/esm/chunk-7CUQMU3T.js.map +0 -7
- package/dist/esm/chunk-BGAJ2MDF.js +0 -2
- package/dist/esm/chunk-BGAJ2MDF.js.map +0 -7
- package/dist/esm/chunk-BJUCBOGU.js +0 -2
- package/dist/esm/chunk-CLZW2IDD.js +0 -2
- package/dist/esm/chunk-CLZW2IDD.js.map +0 -7
- package/dist/esm/chunk-CMHUK7OG.js +0 -2
- package/dist/esm/chunk-CMHUK7OG.js.map +0 -7
- package/dist/esm/chunk-DFGY2NZB.js +0 -2
- package/dist/esm/chunk-DUTZUWZP.js +0 -2
- package/dist/esm/chunk-DUTZUWZP.js.map +0 -7
- package/dist/esm/chunk-EZYXYLR2.js +0 -2
- package/dist/esm/chunk-FDHWAC6W.js +0 -2
- package/dist/esm/chunk-FDHWAC6W.js.map +0 -7
- package/dist/esm/chunk-FDJV5RXX.js.map +0 -7
- package/dist/esm/chunk-G2JD52O5.js +0 -2
- package/dist/esm/chunk-G2JD52O5.js.map +0 -7
- package/dist/esm/chunk-G4ETY2NP.js +0 -2
- package/dist/esm/chunk-G4ETY2NP.js.map +0 -7
- package/dist/esm/chunk-GPOCLDBR.js +0 -2
- package/dist/esm/chunk-GPOCLDBR.js.map +0 -7
- package/dist/esm/chunk-H3IAGAEL.js +0 -2
- package/dist/esm/chunk-H5BYPX6V.js.map +0 -7
- package/dist/esm/chunk-H5G7UECV.js +0 -2
- package/dist/esm/chunk-H5G7UECV.js.map +0 -7
- package/dist/esm/chunk-HT7RFHLW.js +0 -2
- package/dist/esm/chunk-HT7RFHLW.js.map +0 -7
- package/dist/esm/chunk-I4FLQELQ.js.map +0 -7
- package/dist/esm/chunk-IUER6BNH.js +0 -12
- package/dist/esm/chunk-IUER6BNH.js.map +0 -7
- package/dist/esm/chunk-IVQHRM33.js +0 -2
- package/dist/esm/chunk-IVQHRM33.js.map +0 -7
- package/dist/esm/chunk-KA5UE2VN.js +0 -2
- package/dist/esm/chunk-KA5UE2VN.js.map +0 -7
- package/dist/esm/chunk-KEGCX5VM.js +0 -2
- package/dist/esm/chunk-KEGCX5VM.js.map +0 -7
- package/dist/esm/chunk-KT2CMUS5.js +0 -2
- package/dist/esm/chunk-KT2CMUS5.js.map +0 -7
- package/dist/esm/chunk-KVHKPUZ2.js +0 -2
- package/dist/esm/chunk-KVHKPUZ2.js.map +0 -7
- package/dist/esm/chunk-LVCUY2OS.js +0 -2
- package/dist/esm/chunk-M7I6ISPL.js +0 -2
- package/dist/esm/chunk-M7I6ISPL.js.map +0 -7
- package/dist/esm/chunk-MGQ4A2FI.js +0 -2
- package/dist/esm/chunk-MHANZINI.js +0 -2
- package/dist/esm/chunk-MHANZINI.js.map +0 -7
- package/dist/esm/chunk-MYYXOFU5.js +0 -1
- package/dist/esm/chunk-N3WBEQWL.js +0 -5
- package/dist/esm/chunk-N3WBEQWL.js.map +0 -7
- package/dist/esm/chunk-NC3CJUE3.js +0 -2
- package/dist/esm/chunk-NC3CJUE3.js.map +0 -7
- package/dist/esm/chunk-OA7C34MJ.js +0 -1
- package/dist/esm/chunk-P2MV6HLA.js +0 -2
- package/dist/esm/chunk-P2MV6HLA.js.map +0 -7
- package/dist/esm/chunk-PDMCLVYT.js +0 -2
- package/dist/esm/chunk-PDMCLVYT.js.map +0 -7
- package/dist/esm/chunk-PJR6GRZC.js +0 -2
- package/dist/esm/chunk-PJR6GRZC.js.map +0 -7
- package/dist/esm/chunk-PM6QY3JO.js.map +0 -7
- package/dist/esm/chunk-PPZY7PJA.js +0 -2
- package/dist/esm/chunk-PPZY7PJA.js.map +0 -7
- package/dist/esm/chunk-Q4IA622Q.js +0 -2
- package/dist/esm/chunk-RKZVXVBN.js.map +0 -7
- package/dist/esm/chunk-S6GWR6EZ.js +0 -2
- package/dist/esm/chunk-SKOYHBIE.js +0 -2
- package/dist/esm/chunk-STPMPY3X.js +0 -1
- package/dist/esm/chunk-THUBY6L2.js.map +0 -7
- package/dist/esm/chunk-TXQZ5HLV.js +0 -2
- package/dist/esm/chunk-TXQZ5HLV.js.map +0 -7
- package/dist/esm/chunk-TZTUPQYK.js +0 -2
- package/dist/esm/chunk-UICSVJ3B.js +0 -1
- package/dist/esm/chunk-UKASIY6M.js +0 -2
- package/dist/esm/chunk-UKASIY6M.js.map +0 -7
- package/dist/esm/chunk-UONSKZQT.js +0 -2
- package/dist/esm/chunk-V5O3TF57.js +0 -2
- package/dist/esm/chunk-V5O3TF57.js.map +0 -7
- package/dist/esm/chunk-VCV7RACK.js +0 -2
- package/dist/esm/chunk-VCV7RACK.js.map +0 -7
- package/dist/esm/chunk-VPSMETY2.js +0 -2
- package/dist/esm/chunk-VUNCI6A6.js +0 -2
- package/dist/esm/chunk-VUNCI6A6.js.map +0 -7
- package/dist/esm/chunk-VUPIJNG2.js +0 -2
- package/dist/esm/chunk-VUPIJNG2.js.map +0 -7
- package/dist/esm/chunk-VVWYAVHM.js.map +0 -7
- package/dist/esm/chunk-VXQQ6KXI.js +0 -2
- package/dist/esm/chunk-VXQQ6KXI.js.map +0 -7
- package/dist/esm/chunk-WG5ORTIW.js +0 -2
- package/dist/esm/chunk-WG5ORTIW.js.map +0 -7
- package/dist/esm/chunk-WMVR2XBR.js +0 -2
- package/dist/esm/chunk-WMVR2XBR.js.map +0 -7
- package/dist/esm/chunk-WOR3JCLX.js +0 -1
- package/dist/esm/chunk-WX7SX5BN.js +0 -2
- package/dist/esm/chunk-WX7SX5BN.js.map +0 -7
- package/dist/esm/chunk-X4A3XRBY.js +0 -2
- package/dist/esm/chunk-XOACTIBL.js +0 -2
- package/dist/esm/chunk-XOACTIBL.js.map +0 -7
- package/dist/esm/chunk-XZQSSRTG.js +0 -2
- package/dist/esm/chunk-YEHM3FZN.js.map +0 -7
- package/dist/esm/chunk-YIK4ACXS.js +0 -2
- package/dist/esm/chunk-YIK4ACXS.js.map +0 -7
- package/dist/esm/chunk-YXLDRDHW.js +0 -2
- /package/dist/esm/{chunk-ELAW7ZUG.js.map → chunk-6FLLFCBU.js.map} +0 -0
- /package/dist/esm/{chunk-2KZ4NI3X.js.map → chunk-A2OMWZI7.js.map} +0 -0
- /package/dist/esm/{chunk-6DWDNKLS.js.map → chunk-AYKOOEZR.js.map} +0 -0
- /package/dist/esm/{chunk-7FTUTUMD.js.map → chunk-IZXML75Y.js.map} +0 -0
- /package/dist/esm/{chunk-MYYXOFU5.js.map → chunk-J3QIUJ6F.js.map} +0 -0
- /package/dist/esm/{chunk-PBFSBHBS.js.map → chunk-JUY7CBSL.js.map} +0 -0
- /package/dist/esm/{chunk-OA7C34MJ.js.map → chunk-JZ5Z53MN.js.map} +0 -0
- /package/dist/esm/{chunk-OS3FCYZY.js.map → chunk-NG54K6FL.js.map} +0 -0
- /package/dist/esm/{chunk-STPMPY3X.js.map → chunk-VQPANPMI.js.map} +0 -0
- /package/dist/esm/{chunk-UICSVJ3B.js.map → chunk-WH7PQSSG.js.map} +0 -0
- /package/dist/esm/{chunk-WOR3JCLX.js.map → hooks/theme-size.js.map} +0 -0
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
var h=["initial","xs","sm","md","lg","xl"],g=new Set(h);function y(t,e){return Object.prototype.hasOwnProperty.call(t,e)}var b=new Set(["initial","xs","sm","md","lg","xl"]);function d(t){if(typeof t!="object"||t===null)return!1;for(let e in t)if(b.has(e))return!0;return!1}function c(t,e,s){return e!==void 0?e.has(s):t.includes(s)}function v({className:t,customProperties:e,...s}){let l=m({allowArbitraryValues:!0,className:t,...s}),f=T({customProperties:e,...s});return[l,f]}function m({allowArbitraryValues:t,value:e,className:s,propValues:l,propValueSet:f,parseValue:o=r=>r}){if(e){if(typeof e=="string")return c(l,f,e)?R(s,e,o):t?s:void 0;if(d(e)){let r=e,p=[];for(let i in r){if(!y(r,i)||!g.has(i))continue;let n=r[i];if(n!==void 0){if(c(l,f,n)){let a=R(s,n,o),u=i==="initial"?a:`${i}:${a}`;p.push(u)}else if(t){let a=i==="initial"?s:`${i}:${s}`;p.push(a)}}}return p.length>0?p.join(" "):""}if(t)return s}}function R(t,e,s){let l=t?"-":"",f=s(e),o=f?.startsWith("-"),r=o?"-":"",p=o?f?.substring(1):f;return`${r}${t}${l}${p}`}function T({customProperties:t,value:e,propValues:s,propValueSet:l,parseValue:f=o=>o}){if(!e||typeof e=="string"&&c(s,l,e))return;let o;if(typeof e=="string"){let r=f(e);o={};for(let p of t)o[p]=r;return o}if(d(e)){let r=e;for(let p in r){if(!y(r,p)||!g.has(p))continue;let i=r[p];if(i===void 0||c(s,l,i))continue;let n=f(i);o??(o={});for(let a of t){let u=p==="initial"?a:`${a}-${p}`;o[u]=n}}}return o??{}}function P(...t){let e;for(let s of t)s&&(e===void 0&&(e={}),Object.assign(e,s));return e}import k from"classnames";var N=[],C=new Set;function V(t){let e=Object.assign({},...t),s=[],l=[],f=new Set;for(let o in e){let r=e[o],p=r.values??N,i={key:o,type:r.type,default:r.default,hasDefault:r.default!==void 0,responsive:"responsive"in r,className:r.className,customProperties:r.customProperties,parseValue:r.parseValue,values:p,valueSet:p.length>0?new Set(p):C,enumValueSet:r.type==="enum"?new Set([r.default,...p]):void 0};r.className?(s.push(i),f.add(o)):(i.hasDefault||r.type==="enum")&&l.push(i)}return{styling:s,passthrough:l,stylingKeys:f}}var x={children:new WeakMap};function S(t){let e=x;for(let s=0;s<t.length;s++){let l=t[s],f=e.children.get(l);f===void 0&&(f={children:new WeakMap},e.children.set(l,f)),e=f}return e.compiled??(e.compiled=V(t))}function O(t,e){let s=t.initial,l=!1;return e.hasDefault&&s===void 0&&(s=e.default,l=!0),e.enumValueSet!==void 0&&!e.enumValueSet.has(s)&&(s=e.default,l=!0),l?{...t,initial:s}:t}function _(t,...e){let{styling:s,passthrough:l,stylingKeys:f}=S(e),o={};for(let i in t)f.has(i)||(o[i]=t[i]);for(let i=0;i<l.length;i++){let n=l[i],a=o[n.key];if(a===void 0){n.hasDefault&&(o[n.key]=n.default);continue}n.enumValueSet!==void 0&&!n.enumValueSet.has(a)&&!d(a)&&(o[n.key]=n.default)}let r,p=[];for(let i=0;i<s.length;i++){let n=s[i],a=t[n.key];if(a===void 0&&n.hasDefault&&(a=n.default),n.enumValueSet!==void 0&&!n.enumValueSet.has(a)&&!d(a)&&(a=n.default),!!a){if(d(a)){if(!n.responsive)continue;a=O(a,n)}if(n.type==="enum"){let u=m({allowArbitraryValues:!1,value:a,className:n.className,propValues:n.values,propValueSet:n.valueSet,parseValue:n.parseValue});u&&p.push(u);continue}if(n.type==="string"||n.type==="enum | string"){let[u,D]=v({className:n.className,customProperties:n.customProperties,propValues:n.type==="string"?[]:n.values,propValueSet:n.type==="string"?void 0:n.valueSet,parseValue:n.parseValue,value:a});D&&(r=P(r,D)),u&&p.push(u);continue}if(n.type==="boolean"){p.push(n.className);continue}}}return o.className=k(p.length>0?p.join(" "):void 0,t.className),o.style=P(r,t.style),o}export{m as a,P as b,_ as c};
|
|
3
|
+
//# sourceMappingURL=chunk-OKQAVYW4.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/props/prop-def.ts", "../../src/helpers/has-own-property.ts", "../../src/helpers/is-responsive-object.ts", "../../src/helpers/get-responsive-styles.ts", "../../src/helpers/merge-styles.ts", "../../src/helpers/extract-props.ts", "../../src/helpers/compile-prop-defs.ts"],
|
|
4
|
+
"sourcesContent": ["import type React from 'react';\n\n// Creates a union type of string literals with strings, but retains intellisense for the literals.\n// Union<string, 'foo' | 'bar'> => string | Omit<string, 'foo' | 'bar'>\ntype Union<S = string, T extends string | number = string> = T | Omit<S, T>;\n\nconst breakpoints = ['initial', 'xs', 'sm', 'md', 'lg', 'xl'] as const;\nconst breakpointSet: Set<string> = new Set(breakpoints);\ntype Breakpoint = (typeof breakpoints)[number];\ntype Responsive<T> = T | Partial<Record<Breakpoint, T>>;\n\ntype BooleanPropDef = {\n type: 'boolean';\n default?: boolean;\n required?: boolean;\n className?: string;\n};\ntype StringPropDef = {\n type: 'string';\n default?: string;\n required?: boolean;\n};\ntype ReactNodePropDef = {\n type: 'ReactNode';\n default?: React.ReactNode;\n required?: boolean;\n};\ntype EnumPropDef<T> = {\n type: 'enum';\n values: readonly T[];\n default?: T;\n required?: boolean;\n};\ntype EnumOrStringPropDef<T> = {\n type: 'enum | string';\n values: readonly T[];\n default?: T | string;\n required?: boolean;\n};\n\ntype NonStylingPropDef = {\n className?: never;\n customProperties?: never;\n parseValue?: never;\n};\n\ntype StylingPropDef = {\n className: string;\n parseValue?: (value: string) => string | undefined;\n};\n\ntype ArbitraryStylingPropDef = {\n className: string;\n customProperties: `--${string}`[];\n parseValue?: (value: string) => string | undefined;\n};\n\ntype RegularPropDef<T> =\n | ReactNodePropDef\n | BooleanPropDef\n | (StringPropDef & ArbitraryStylingPropDef)\n | (StringPropDef & NonStylingPropDef)\n | (EnumPropDef<T> & StylingPropDef)\n | (EnumPropDef<T> & NonStylingPropDef)\n | (EnumOrStringPropDef<T> & ArbitraryStylingPropDef)\n | (EnumOrStringPropDef<T> & NonStylingPropDef);\ntype ResponsivePropDef<T = any> = RegularPropDef<T> & { responsive: true };\ntype PropDef<T = any> = RegularPropDef<T> | ResponsivePropDef<T>;\n\n// prettier-ignore\ntype GetPropDefType<Def> =\n Def extends BooleanPropDef ? (Def extends ResponsivePropDef ? Responsive<boolean> : boolean)\n : Def extends StringPropDef ? (Def extends ResponsivePropDef ? Responsive<string> : string)\n : Def extends ReactNodePropDef ? (Def extends ResponsivePropDef ? Responsive<React.ReactNode> : React.ReactNode)\n : Def extends EnumOrStringPropDef<infer Type> ?\n Def extends ResponsivePropDef<infer Type extends string> ? Responsive<Union<string, Type>> : Type\n : Def extends EnumPropDef<infer Type> ? (Def extends ResponsivePropDef<infer Type> ? Responsive<Type> : Type)\n : never;\n\ntype GetPropDefTypes<P> = {\n [K in keyof P]?: GetPropDefType<P[K]>;\n};\n\nexport { breakpoints, breakpointSet };\nexport type {\n PropDef,\n GetPropDefTypes,\n ResponsivePropDef,\n //\n Breakpoint,\n Responsive,\n Union,\n};\n", "/** A util to check whether the object has a key, while inferring the correct key type */\nfunction hasOwnProperty<K extends string | number | symbol>(\n obj: Record<K, unknown>,\n key: string | number | symbol\n): key is K {\n return Object.prototype.hasOwnProperty.call(obj, key);\n}\n\nexport { hasOwnProperty };\n", "import type { Responsive, Breakpoint } from '../props/prop-def.js';\n\n// Use a Set for O(1) lookup instead of array.includes() which is O(n)\nconst breakpointSet = new Set<string>(['initial', 'xs', 'sm', 'md', 'lg', 'xl']);\n\nexport function isResponsiveObject<Value extends string>(\n obj: Responsive<Value | Omit<string, Value>> | undefined\n): obj is Record<Breakpoint, string> {\n if (typeof obj !== 'object' || obj === null) {\n return false;\n }\n // Use for...in to avoid Object.keys() array allocation\n for (const key in obj) {\n if (breakpointSet.has(key)) {\n return true;\n }\n }\n return false;\n}\n", "import { breakpointSet } from '../props/prop-def.js';\nimport { hasOwnProperty } from './has-own-property.js';\nimport { isResponsiveObject } from './is-responsive-object.js';\n\nimport type { Responsive, Union } from '../props/prop-def.js';\n\n/**\n * Membership test against a prop def's enum values. Callers that already hold a\n * compiled prop def pass `propValueSet` for an O(1) lookup; the handful of call\n * sites that build options inline fall back to scanning the array.\n */\nfunction includesValue(propValues: string[] | readonly string[], propValueSet: ReadonlySet<string> | undefined, value: string): boolean {\n return propValueSet !== undefined ? propValueSet.has(value) : propValues.includes(value);\n}\n\ninterface GetResponsiveStylesOptions {\n className: string;\n customProperties: `--${string}`[];\n value: Responsive<Union> | Responsive<string> | undefined;\n propValues: string[] | readonly string[];\n propValueSet?: ReadonlySet<string>;\n parseValue?: (value: string) => string | undefined;\n}\n\nfunction getResponsiveStyles({ className, customProperties, ...args }: GetResponsiveStylesOptions) {\n const responsiveClassNames = getResponsiveClassNames({\n allowArbitraryValues: true,\n className,\n ...args,\n });\n\n const responsiveCustomProperties = getResponsiveCustomProperties({ customProperties, ...args });\n return [responsiveClassNames, responsiveCustomProperties] as const;\n}\n\ninterface GetResponsiveClassNamesOptions {\n allowArbitraryValues?: boolean;\n className: string;\n value: Responsive<Union> | Responsive<string> | undefined;\n propValues: string[] | readonly string[];\n propValueSet?: ReadonlySet<string>;\n parseValue?: (value: string) => string | undefined;\n}\n\nfunction getResponsiveClassNames({ allowArbitraryValues, value, className, propValues, propValueSet, parseValue = (value) => value }: GetResponsiveClassNamesOptions): string | undefined {\n if (!value) {\n return undefined;\n }\n\n if (typeof value === 'string') {\n if (includesValue(propValues, propValueSet, value)) {\n return getBaseClassName(className, value, parseValue);\n }\n return allowArbitraryValues ? className : undefined;\n }\n\n if (isResponsiveObject(value)) {\n const object = value;\n const classNames: string[] = [];\n\n for (const bp in object) {\n // Make sure we are not iterating over keys that aren't breakpoints\n if (!hasOwnProperty(object, bp) || !breakpointSet.has(bp)) {\n continue;\n }\n\n const value = object[bp];\n\n if (value !== undefined) {\n if (includesValue(propValues, propValueSet, value)) {\n const baseClassName = getBaseClassName(className, value, parseValue);\n const bpClassName = bp === 'initial' ? baseClassName : `${bp}:${baseClassName}`;\n classNames.push(bpClassName);\n } else if (allowArbitraryValues) {\n const bpClassName = bp === 'initial' ? className : `${bp}:${className}`;\n classNames.push(bpClassName);\n }\n }\n }\n\n return classNames.length > 0 ? classNames.join(' ') : '';\n }\n\n if (allowArbitraryValues) {\n return className;\n }\n}\n\nfunction getBaseClassName(className: string, value: string, parseValue: (value: string) => string | undefined): string {\n const delimiter = className ? '-' : '';\n const matchedValue = parseValue(value);\n const isNegative = matchedValue?.startsWith('-');\n const minus = isNegative ? '-' : '';\n const absoluteValue = isNegative ? matchedValue?.substring(1) : matchedValue;\n return `${minus}${className}${delimiter}${absoluteValue}`;\n}\n\ninterface GetResponsiveCustomPropertiesOptions {\n customProperties: `--${string}`[];\n value: Responsive<Union> | Responsive<string> | undefined;\n propValues: string[] | readonly string[];\n propValueSet?: ReadonlySet<string>;\n parseValue?: (value: string) => string | undefined;\n}\n\nfunction getResponsiveCustomProperties({ customProperties, value, propValues, propValueSet, parseValue = (value) => value }: GetResponsiveCustomPropertiesOptions) {\n // Don't generate custom properties if the value is not arbitrary\n if (!value || (typeof value === 'string' && includesValue(propValues, propValueSet, value))) {\n return undefined;\n }\n\n let styles: Record<string, string | undefined> | undefined;\n\n if (typeof value === 'string') {\n const parsed = parseValue(value);\n styles = {};\n for (const customProperty of customProperties) {\n styles[customProperty] = parsed;\n }\n return styles;\n }\n\n if (isResponsiveObject(value)) {\n const object = value;\n\n for (const bp in object) {\n // Make sure we are not iterating over keys that aren't breakpoints\n if (!hasOwnProperty(object, bp) || !breakpointSet.has(bp)) {\n continue;\n }\n\n const value = object[bp];\n\n // Don't generate a custom property if the value is not arbitrary\n if (value === undefined || includesValue(propValues, propValueSet, value)) {\n continue;\n }\n\n const parsed = parseValue(value);\n styles ??= {};\n for (const customProperty of customProperties) {\n const bpProperty = bp === 'initial' ? customProperty : `${customProperty}-${bp}`;\n styles[bpProperty] = parsed;\n }\n }\n }\n\n return styles ?? {};\n}\n\nexport { getResponsiveStyles, getResponsiveCustomProperties, getResponsiveClassNames };\n", "type InlineStyle =\n | React.CSSProperties\n | Record<string, string | number | null | undefined>\n | undefined;\n\n// Merges CSS styles like `classNames` merges CSS classes\n// Optimized to avoid object spread in loop - uses Object.assign for in-place mutation\nexport function mergeStyles(...styles: Array<InlineStyle>): InlineStyle {\n let result: Record<string, string | number | null | undefined> | undefined;\n\n for (const style of styles) {\n if (style) {\n if (result === undefined) {\n // First non-empty style - create result object\n result = {};\n }\n Object.assign(result, style);\n }\n }\n\n return result;\n}\n", "import classNames from 'classnames';\n\nimport { getCompiledPropDefs } from './compile-prop-defs.js';\nimport { getResponsiveClassNames, getResponsiveStyles } from './get-responsive-styles.js';\nimport { isResponsiveObject } from './is-responsive-object.js';\nimport { mergeStyles } from './merge-styles.js';\n\nimport type { CompiledPropDef } from './compile-prop-defs.js';\nimport type * as React from 'react';\nimport type { PropDef } from '../props/prop-def.js';\n\ntype PropDefsWithClassName<T> = T extends Record<string, PropDef> ? { [K in keyof T]: T[K] extends { className: string } ? K : never }[keyof T] : never;\n\ntype ResponsiveValue = Record<string, string | undefined>;\n\n/**\n * Fills in the `initial` breakpoint of a responsive value from the prop def's\n * default, and coerces an invalid `initial` enum value back to that default.\n *\n * Returns the value untouched when nothing needs changing, and a copy otherwise\n * \u2014 callers routinely hoist responsive objects to module scope, so mutating the\n * caller's object would corrupt it for every later render.\n */\nfunction normalizeResponsiveValue(value: ResponsiveValue, propDef: CompiledPropDef) {\n let initial = value.initial;\n let changed = false;\n\n if (propDef.hasDefault && initial === undefined) {\n initial = propDef.default as string | undefined;\n changed = true;\n }\n\n if (propDef.enumValueSet !== undefined && !propDef.enumValueSet.has(initial)) {\n initial = propDef.default as string | undefined;\n changed = true;\n }\n\n return changed ? { ...value, initial } : value;\n}\n\n/**\n * Takes props, checks them against prop defs that have a `className` on them,\n * adds necessary CSS classes and inline styles, and returns the props without\n * the corresponding prop defs that were used to formulate the new `className`\n * and `style` values. Also applies prop def defaults to every prop.\n */\nfunction extractProps<P extends { className?: string; style?: React.CSSProperties; [key: string]: any }, T extends Record<string, PropDef>[]>(\n props: P,\n ...propDefs: T\n): Omit<P & { className?: string; style?: React.CSSProperties }, PropDefsWithClassName<T[number]>> {\n const { styling, passthrough, stylingKeys } = getCompiledPropDefs(propDefs);\n\n // Copy the props that survive to the element rather than spreading and then\n // deleting the styling keys. Deleting off a spread demotes the object to\n // dictionary mode in V8, and this object is on the render path of every\n // component in the library.\n const extractedProps: Record<string, any> = {};\n for (const key in props) {\n if (stylingKeys.has(key)) continue;\n extractedProps[key] = props[key];\n }\n\n for (let i = 0; i < passthrough.length; i++) {\n const propDef = passthrough[i];\n const value = extractedProps[propDef.key];\n\n if (value === undefined) {\n if (propDef.hasDefault) extractedProps[propDef.key] = propDef.default;\n continue;\n }\n\n // Fall back to the default when the value is not a valid enum value\n if (propDef.enumValueSet !== undefined && !propDef.enumValueSet.has(value) && !isResponsiveObject(value)) {\n extractedProps[propDef.key] = propDef.default;\n }\n }\n\n let style: ReturnType<typeof mergeStyles>;\n const classes: string[] = [];\n\n for (let i = 0; i < styling.length; i++) {\n const propDef = styling[i];\n let value = props[propDef.key];\n\n // Apply prop def defaults\n if (value === undefined && propDef.hasDefault) {\n value = propDef.default;\n }\n\n // Apply the default value if the value is not a valid enum value\n if (propDef.enumValueSet !== undefined && !propDef.enumValueSet.has(value) && !isResponsiveObject(value)) {\n value = propDef.default;\n }\n\n if (!value) continue;\n\n if (isResponsiveObject(value)) {\n // Make sure we are not threading through responsive values for non-responsive prop defs\n if (!propDef.responsive) continue;\n value = normalizeResponsiveValue(value, propDef);\n }\n\n if (propDef.type === 'enum') {\n const propClassName = getResponsiveClassNames({\n allowArbitraryValues: false,\n value,\n className: propDef.className!,\n propValues: propDef.values,\n propValueSet: propDef.valueSet,\n parseValue: propDef.parseValue,\n });\n\n if (propClassName) classes.push(propClassName);\n continue;\n }\n\n if (propDef.type === 'string' || propDef.type === 'enum | string') {\n const [propClassNames, propCustomProperties] = getResponsiveStyles({\n className: propDef.className!,\n customProperties: propDef.customProperties!,\n // `string` prop defs have no enum values, so every value is arbitrary\n propValues: propDef.type === 'string' ? [] : propDef.values,\n propValueSet: propDef.type === 'string' ? undefined : propDef.valueSet,\n parseValue: propDef.parseValue,\n value,\n });\n\n if (propCustomProperties) style = mergeStyles(style, propCustomProperties);\n if (propClassNames) classes.push(propClassNames);\n continue;\n }\n\n if (propDef.type === 'boolean') {\n // TODO handle responsive boolean props\n classes.push(propDef.className!);\n continue;\n }\n }\n\n extractedProps.className = classNames(classes.length > 0 ? classes.join(' ') : undefined, props.className);\n extractedProps.style = mergeStyles(style, props.style);\n return extractedProps as ReturnType<typeof extractProps<P, T>>;\n}\n\nexport { extractProps };\n", "import type { PropDef } from '../props/prop-def.js';\n\n/**\n * A prop def pre-processed into the exact shape `extractProps` needs at render\n * time. Everything that can be derived from the static prop def \u2014 enum\n * membership sets, whether the def is responsive, whether it carries a default\n * \u2014 is computed once here instead of on every render.\n */\ninterface CompiledPropDef {\n key: string;\n type: PropDef['type'];\n default: unknown;\n hasDefault: boolean;\n responsive: boolean;\n className?: string;\n customProperties?: `--${string}`[];\n parseValue?: (value: string) => string | undefined;\n /** The prop def's own enum values, kept for the responsive class name helpers. */\n values: readonly string[];\n /** O(1) membership for `values`. */\n valueSet: ReadonlySet<string>;\n /**\n * `values` plus the default, used to coerce invalid enum values back to the\n * default. Only present for `type: 'enum'` \u2014 `'enum | string'` props accept\n * arbitrary strings and must not be coerced.\n */\n enumValueSet?: ReadonlySet<unknown>;\n}\n\ninterface CompiledPropDefs {\n /** Defs that contribute a class name and/or custom properties. */\n styling: CompiledPropDef[];\n /**\n * Defs that pass through to the element but still need a default applied or\n * an invalid enum value coerced. Defs that can do neither are omitted\n * entirely \u2014 they are already correct as passed.\n */\n passthrough: CompiledPropDef[];\n /** Keys consumed by `styling`, so they can be skipped when copying props. */\n stylingKeys: ReadonlySet<string>;\n}\n\nconst EMPTY_VALUES: readonly string[] = [];\nconst EMPTY_SET: ReadonlySet<string> = new Set();\n\nfunction compile(propDefs: readonly Record<string, PropDef>[]): CompiledPropDefs {\n const merged: Record<string, PropDef> = Object.assign({}, ...propDefs);\n const styling: CompiledPropDef[] = [];\n const passthrough: CompiledPropDef[] = [];\n const stylingKeys = new Set<string>();\n\n for (const key in merged) {\n // The PropDef union is narrowed per-field below; reading the optional\n // members off the union directly is what the runtime actually needs.\n const def = merged[key] as PropDef & {\n default?: unknown;\n values?: readonly string[];\n className?: string;\n customProperties?: `--${string}`[];\n parseValue?: (value: string) => string | undefined;\n responsive?: true;\n };\n\n const values = def.values ?? EMPTY_VALUES;\n const compiled: CompiledPropDef = {\n key,\n type: def.type,\n default: def.default,\n hasDefault: def.default !== undefined,\n responsive: 'responsive' in def,\n className: def.className,\n customProperties: def.customProperties,\n parseValue: def.parseValue,\n values,\n valueSet: values.length > 0 ? new Set(values) : EMPTY_SET,\n enumValueSet: def.type === 'enum' ? new Set<unknown>([def.default, ...values]) : undefined,\n };\n\n if (def.className) {\n styling.push(compiled);\n stylingKeys.add(key);\n } else if (compiled.hasDefault || def.type === 'enum') {\n // Anything else is copied through untouched, so there is nothing to do.\n passthrough.push(compiled);\n }\n }\n\n return { styling, passthrough, stylingKeys };\n}\n\ninterface CacheNode {\n children: WeakMap<object, CacheNode>;\n compiled?: CompiledPropDefs;\n}\n\nconst cacheRoot: CacheNode = { children: new WeakMap() };\n\n/**\n * Compiles a set of prop defs, memoized on the identity of the prop def objects\n * themselves. Components always pass the same module-level constants, so after\n * the first render of a given component this is a couple of WeakMap lookups\n * instead of merging 50-odd prop defs into a fresh object.\n */\nfunction getCompiledPropDefs(propDefs: readonly Record<string, PropDef>[]): CompiledPropDefs {\n let node = cacheRoot;\n\n for (let i = 0; i < propDefs.length; i++) {\n const propDef = propDefs[i];\n let child = node.children.get(propDef);\n if (child === undefined) {\n child = { children: new WeakMap() };\n node.children.set(propDef, child);\n }\n node = child;\n }\n\n return (node.compiled ??= compile(propDefs));\n}\n\nexport { getCompiledPropDefs };\nexport type { CompiledPropDef, CompiledPropDefs };\n"],
|
|
5
|
+
"mappings": ";AAMA,IAAMA,EAAc,CAAC,UAAW,KAAM,KAAM,KAAM,KAAM,IAAI,EACtDC,EAA6B,IAAI,IAAID,CAAW,ECNtD,SAASE,EACPC,EACAC,EACU,CACV,OAAO,OAAO,UAAU,eAAe,KAAKD,EAAKC,CAAG,CACtD,CCHA,IAAMC,EAAgB,IAAI,IAAY,CAAC,UAAW,KAAM,KAAM,KAAM,KAAM,IAAI,CAAC,EAExE,SAASC,EACdC,EACmC,CACnC,GAAI,OAAOA,GAAQ,UAAYA,IAAQ,KACrC,MAAO,GAGT,QAAWC,KAAOD,EAChB,GAAIF,EAAc,IAAIG,CAAG,EACvB,MAAO,GAGX,MAAO,EACT,CCPA,SAASC,EAAcC,EAA0CC,EAA+CC,EAAwB,CACtI,OAAOD,IAAiB,OAAYA,EAAa,IAAIC,CAAK,EAAIF,EAAW,SAASE,CAAK,CACzF,CAWA,SAASC,EAAoB,CAAE,UAAAC,EAAW,iBAAAC,EAAkB,GAAGC,CAAK,EAA+B,CACjG,IAAMC,EAAuBC,EAAwB,CACnD,qBAAsB,GACtB,UAAAJ,EACA,GAAGE,CACL,CAAC,EAEKG,EAA6BC,EAA8B,CAAE,iBAAAL,EAAkB,GAAGC,CAAK,CAAC,EAC9F,MAAO,CAACC,EAAsBE,CAA0B,CAC1D,CAWA,SAASD,EAAwB,CAAE,qBAAAG,EAAsB,MAAAT,EAAO,UAAAE,EAAW,WAAAJ,EAAY,aAAAC,EAAc,WAAAW,EAAcV,GAAUA,CAAM,EAAuD,CACxL,GAAKA,EAIL,IAAI,OAAOA,GAAU,SACnB,OAAIH,EAAcC,EAAYC,EAAcC,CAAK,EACxCW,EAAiBT,EAAWF,EAAOU,CAAU,EAE/CD,EAAuBP,EAAY,OAG5C,GAAIU,EA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cA,EAAQ,OAAS,SAAW,OAAYA,EAAQ,SAC9D,WAAYA,EAAQ,WACpB,MAAAD,CACF,CAAC,EAEGmB,IAAsBL,EAAQO,EAAYP,EAAOK,CAAoB,GACrED,GAAgBH,EAAQ,KAAKG,CAAc,EAC/C,QACF,CAEA,GAAIjB,EAAQ,OAAS,UAAW,CAE9Bc,EAAQ,KAAKd,EAAQ,SAAU,EAC/B,QACF,EACF,CAEA,OAAAU,EAAe,UAAYW,EAAWP,EAAQ,OAAS,EAAIA,EAAQ,KAAK,GAAG,EAAI,OAAWV,EAAM,SAAS,EACzGM,EAAe,MAAQU,EAAYP,EAAOT,EAAM,KAAK,EAC9CM,CACT",
|
|
6
|
+
"names": ["breakpoints", "breakpointSet", "hasOwnProperty", "obj", "key", "breakpointSet", "isResponsiveObject", "obj", "key", "includesValue", "propValues", "propValueSet", "value", "getResponsiveStyles", "className", "customProperties", "args", "responsiveClassNames", "getResponsiveClassNames", "responsiveCustomProperties", "getResponsiveCustomProperties", "allowArbitraryValues", "parseValue", "getBaseClassName", "isResponsiveObject", "object", "classNames", "bp", "hasOwnProperty", "breakpointSet", "baseClassName", "bpClassName", "delimiter", "matchedValue", "isNegative", "minus", "absoluteValue", "styles", "parsed", "customProperty", "bpProperty", "mergeStyles", "styles", "result", "style", "classNames", "EMPTY_VALUES", "EMPTY_SET", "compile", "propDefs", "merged", "styling", "passthrough", "stylingKeys", "key", "def", "values", "compiled", "cacheRoot", "getCompiledPropDefs", "node", "i", "propDef", "child", "normalizeResponsiveValue", "value", "propDef", "initial", "changed", "extractProps", "props", "propDefs", "styling", "passthrough", "stylingKeys", "getCompiledPropDefs", "extractedProps", "key", "isResponsiveObject", "style", "classes", "propClassName", "getResponsiveClassNames", "propClassNames", "propCustomProperties", "getResponsiveStyles", "mergeStyles", "classNames"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import{a as p,b as P,c as b}from"./chunk-FI32HA4X.js";import{a as T}from"./chunk-RVPLXLRA.js";import{c as R}from"./chunk-5ON3XLRD.js";import{a as m,c as s}from"./chunk-OKQAVYW4.js";import{a as k}from"./chunk-VQPANPMI.js";var x={};k(x,{Body:()=>f,Cell:()=>y,ColumnHeaderCell:()=>u,Header:()=>i,Root:()=>c,Row:()=>C,RowHeaderCell:()=>w});import*as e from"react";import t from"classnames";var c=e.forwardRef((o,l)=>{let a=R(o,p.size),{layout:r,...H}=p,{className:N,children:h,layout:E,"aria-label":d,"aria-labelledby":n,"aria-describedby":v,...D}=s(a,H),B=m({value:E,className:p.layout.className,propValues:p.layout.values});return e.createElement("div",{ref:l,className:t("kui-TableRoot",N),...D},e.createElement(T,{"aria-label":d,"aria-labelledby":n},e.createElement("table",{className:t("kui-TableRootTable",B),"aria-label":d,"aria-labelledby":n,"aria-describedby":v},h)))});c.displayName="Table.Root";var i=e.forwardRef(({className:o,...l},a)=>e.createElement("thead",{...l,ref:a,className:t("kui-TableHeader",o)}));i.displayName="Table.Header";var f=e.forwardRef(({className:o,...l},a)=>e.createElement("tbody",{...l,ref:a,className:t("kui-TableBody",o)}));f.displayName="Table.Body";var C=e.forwardRef((o,l)=>{let{className:a,...r}=s(o,P);return e.createElement("tr",{...r,ref:l,className:t("kui-TableRow",a)})});C.displayName="Table.Row";var y=e.forwardRef((o,l)=>{let{className:a,...r}=s(o,b);return e.createElement("td",{className:t("kui-TableCell",a),ref:l,...r})});y.displayName="Table.Cell";var u=e.forwardRef((o,l)=>{let{className:a,...r}=s(o,b);return e.createElement("th",{className:t("kui-TableCell","kui-TableColumnHeaderCell",a),scope:"col",ref:l,...r})});u.displayName="Table.ColumnHeaderCell";var w=e.forwardRef((o,l)=>{let{className:a,...r}=s(o,b);return e.createElement("th",{className:t("kui-TableCell","kui-TableRowHeaderCell",a),scope:"row",ref:l,...r})});w.displayName="Table.RowHeaderCell";export{c as a,i as b,f as c,C as d,y as e,u as f,w as g,x as h};
|
|
3
|
+
//# sourceMappingURL=chunk-OQWD63AI.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/components/table.tsx"],
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nimport classNames from 'classnames';\n\nimport { tableRootPropDefs, tableRowPropDefs, tableCellPropDefs } from './table.props.js';\nimport { extractProps } from '../helpers/extract-props.js';\nimport { useThemeSizeProps } from '../hooks/theme-size.js';\nimport { getResponsiveClassNames } from '../helpers/get-responsive-styles.js';\nimport { ScrollArea } from './scroll-area.js';\n\nimport type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js';\nimport type { GetPropDefTypes } from '../props/prop-def.js';\n\ntype TableRootElement = React.ElementRef<'div'>;\ntype TableRootOwnProps = GetPropDefTypes<typeof tableRootPropDefs>;\ninterface TableRootProps\n extends ComponentPropsWithout<'div', RemovedProps>,\n TableRootOwnProps {}\nconst TableRoot = React.forwardRef<TableRootElement, TableRootProps>((ownProps, forwardedRef) => {\n const props = useThemeSizeProps(ownProps, tableRootPropDefs.size);\n const { layout: layoutPropDef, ...rootPropDefs } = tableRootPropDefs;\n const {\n className,\n children,\n layout,\n // The table is what gets named, not the scroll wrapper around it.\n 'aria-label': ariaLabel,\n 'aria-labelledby': ariaLabelledBy,\n 'aria-describedby': ariaDescribedBy,\n ...rootProps\n } = extractProps(props, rootPropDefs);\n const tableLayoutClassNames = getResponsiveClassNames({\n value: layout,\n className: tableRootPropDefs.layout.className,\n propValues: tableRootPropDefs.layout.values,\n });\n return (\n <div ref={forwardedRef} className={classNames('kui-TableRoot', className)} {...rootProps}>\n {/* An overflowing scroller is a tab stop, so it carries the table's name and reads as a region. */}\n <ScrollArea aria-label={ariaLabel} aria-labelledby={ariaLabelledBy}>\n <table\n className={classNames('kui-TableRootTable', tableLayoutClassNames)}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n aria-describedby={ariaDescribedBy}\n >\n {children}\n </table>\n </ScrollArea>\n </div>\n );\n});\nTableRoot.displayName = 'Table.Root';\n\ntype TableHeaderElement = React.ElementRef<'thead'>;\ninterface TableHeaderProps extends ComponentPropsWithout<'thead', RemovedProps> {}\nconst TableHeader = React.forwardRef<TableHeaderElement, TableHeaderProps>(\n ({ className, ...props }, forwardedRef) => (\n <thead {...props} ref={forwardedRef} className={classNames('kui-TableHeader', className)} />\n )\n);\nTableHeader.displayName = 'Table.Header';\n\ntype TableBodyElement = React.ElementRef<'tbody'>;\ninterface TableBodyProps extends ComponentPropsWithout<'tbody', RemovedProps> {}\nconst TableBody = React.forwardRef<TableBodyElement, TableBodyProps>(\n ({ className, ...props }, forwardedRef) => (\n <tbody {...props} ref={forwardedRef} className={classNames('kui-TableBody', className)} />\n )\n);\nTableBody.displayName = 'Table.Body';\n\ntype TableRowElement = React.ElementRef<'tr'>;\ntype TableRowOwnProps = GetPropDefTypes<typeof tableRowPropDefs>;\ninterface TableRowProps extends ComponentPropsWithout<'tr', RemovedProps>, TableRowOwnProps {}\nconst TableRow = React.forwardRef<TableRowElement, TableRowProps>((props, forwardedRef) => {\n const { className, ...rowProps } = extractProps(props, tableRowPropDefs);\n return <tr {...rowProps} ref={forwardedRef} className={classNames('kui-TableRow', className)} />;\n});\nTableRow.displayName = 'Table.Row';\n\ntype TableCellElement = React.ElementRef<'td'>;\ntype TableCellOwnProps = GetPropDefTypes<typeof tableCellPropDefs>;\ninterface TableCellProps\n extends ComponentPropsWithout<'td', RemovedProps | 'width'>,\n TableCellOwnProps {}\nconst TableCell = React.forwardRef<TableCellElement, TableCellProps>((props, forwardedRef) => {\n const { className, ...cellProps } = extractProps(props, tableCellPropDefs);\n return <td className={classNames('kui-TableCell', className)} ref={forwardedRef} {...cellProps} />;\n});\nTableCell.displayName = 'Table.Cell';\n\ntype TableColumnHeaderCellElement = React.ElementRef<'th'>;\ninterface TableColumnHeaderCellProps\n extends ComponentPropsWithout<'th', RemovedProps>,\n TableCellOwnProps {}\nconst TableColumnHeaderCell = React.forwardRef<\n TableColumnHeaderCellElement,\n TableColumnHeaderCellProps\n>((props, forwardedRef) => {\n const { className, ...cellProps } = extractProps(props, tableCellPropDefs);\n return (\n <th\n className={classNames('kui-TableCell', 'kui-TableColumnHeaderCell', className)}\n scope=\"col\"\n ref={forwardedRef}\n {...cellProps}\n />\n );\n});\nTableColumnHeaderCell.displayName = 'Table.ColumnHeaderCell';\n\ntype TableRowHeaderCellElement = React.ElementRef<'th'>;\ninterface TableRowHeaderCellProps\n extends ComponentPropsWithout<'th', RemovedProps>,\n TableCellOwnProps {}\nconst TableRowHeaderCell = React.forwardRef<TableRowHeaderCellElement, TableRowHeaderCellProps>(\n (props, forwardedRef) => {\n const { className, ...cellProps } = extractProps(props, tableCellPropDefs);\n return (\n <th\n className={classNames('kui-TableCell', 'kui-TableRowHeaderCell', className)}\n scope=\"row\"\n ref={forwardedRef}\n {...cellProps}\n />\n );\n }\n);\nTableRowHeaderCell.displayName = 'Table.RowHeaderCell';\n\nexport {\n TableRoot as Root,\n TableHeader as Header,\n TableBody as Body,\n TableRow as Row,\n TableCell as Cell,\n TableColumnHeaderCell as ColumnHeaderCell,\n TableRowHeaderCell as RowHeaderCell,\n};\n\nexport type {\n TableRootProps as RootProps,\n TableHeaderProps as HeaderProps,\n TableBodyProps as BodyProps,\n TableRowProps as RowProps,\n TableCellProps as CellProps,\n TableColumnHeaderCellProps as ColumnHeaderCellProps,\n TableRowHeaderCellProps as RowHeaderCellProps,\n};\n"],
|
|
5
|
+
"mappings": ";6NAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,UAAAE,EAAA,SAAAC,EAAA,qBAAAC,EAAA,WAAAC,EAAA,SAAAC,EAAA,QAAAC,EAAA,kBAAAC,IAAA,UAAYC,MAAW,QACvB,OAAOC,MAAgB,aAgBvB,IAAMC,EAAkB,aAA6C,CAACC,EAAUC,IAAiB,CAC/F,IAAMC,EAAQC,EAAkBH,EAAUI,EAAkB,IAAI,EAC1D,CAAE,OAAQC,EAAe,GAAGC,CAAa,E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AAaZ,EAAOwB,CAAiB,EACzE,OAAO,gBAAC,MAAG,UAAWT,EAAW,gBAAiBV,CAAS,EAAG,IAAKN,EAAe,GAAGwB,EAAW,CAClG,CAAC,EACDD,EAAU,YAAc,aAMxB,IAAMG,EAA8B,aAGlC,CAACzB,EAAOD,IAAiB,CACzB,GAAM,CAAE,UAAAM,EAAW,GAAGkB,CAAU,EAAIX,EAAaZ,EAAOwB,CAAiB,EACzE,OACE,gBAAC,MACC,UAAWT,EAAW,gBAAiB,4BAA6BV,CAAS,EAC7E,MAAM,MACN,IAAKN,EACJ,GAAGwB,EACN,CAEJ,CAAC,EACDE,EAAsB,YAAc,yBAMpC,IAAMC,EAA2B,aAC/B,CAAC1B,EAAOD,IAAiB,CACvB,GAAM,CAAE,UAAAM,EAAW,GAAGkB,CAAU,EAAIX,EAAaZ,EAAOwB,CAAiB,EACzE,OACE,gBAAC,MACC,UAAWT,EAAW,gBAAiB,yBAA0BV,CAAS,EAC1E,MAAM,MACN,IAAKN,EACJ,GAAGwB,EACN,CAEJ,CACF,EACAG,EAAmB,YAAc",
|
|
6
|
+
"names": ["table_exports", "__export", "TableBody", "TableCell", "TableColumnHeaderCell", "TableHeader", "TableRoot", "TableRow", "TableRowHeaderCell", "React", "classNames", "TableRoot", "ownProps", "forwardedRef", "props", "useThemeSizeProps", "tableRootPropDefs", "layoutPropDef", "rootPropDefs", "className", "children", "layout", "ariaLabel", "ariaLabelledBy", "ariaDescribedBy", "rootProps", "extractProps", "tableLayoutClassNames", "getResponsiveClassNames", "classNames", "ScrollArea", "TableHeader", "TableBody", "TableRow", "rowProps", "tableRowPropDefs", "TableCell", "cellProps", "tableCellPropDefs", "TableColumnHeaderCell", "TableRowHeaderCell"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import{a as g}from"./chunk-WMZLMZHB.js";import{a as X,b as oo,c as eo,e as W,f as to,i as ro,l as no}from"./chunk-5L4DZ2D3.js";import{a as B}from"./chunk-5TJH35TF.js";import{a as Q}from"./chunk-6UZT3ZLO.js";import{g as J}from"./chunk-EAIQIW23.js";import{a as q}from"./chunk-7N2Q5WOM.js";import{b as L}from"./chunk-5ON3XLRD.js";import{c as U}from"./chunk-OKQAVYW4.js";import*as o from"react";import{useLayoutEffect as D}from"radix-ui/internal";import x from"classnames";import{Toolbar as N}from"radix-ui";var E=o.createContext(null),F=o.createContext(null),M=o.createContext(!1);function Bo(){return o.useContext(M)}var H=o.forwardRef((e,t)=>{let r=J(),a=L(e.size??r??void 0,g.size),s=e.orientation??g.orientation.default,{className:i,orientation:n,backdrop:l=!1,children:p,...d}=U({...e,size:a},g,q),u=o.useMemo(()=>({size:a,orientation:s,backdrop:l}),[a,s,l]);return o.createElement(N.Root,{...d,ref:t,orientation:s,"data-backdrop":l||void 0,className:x("kui-Toolbar",i)},o.createElement(E.Provider,{value:u},p))});H.displayName="Toolbar";var so=o.forwardRef(({className:e,disabled:t=!1,children:r,...a},s)=>{let i=o.useContext(E),n=o.useContext(M),l=o.useMemo(()=>({disabled:t}),[t]);return n?o.createElement(to,{...a,ref:s,className:e},o.createElement(F.Provider,{value:l},r)):o.createElement("div",{role:"group","data-orientation":i?.orientation??"horizontal","data-disabled":t||void 0,...a,ref:s,className:x("kui-ToolbarGroup",e)},o.createElement(F.Provider,{value:l},r))});so.displayName="Toolbar.Group";var bo=new Set(["id","className","style","title"]);function ao(e){return e===!0||e==="true"}function To(e){return o.isValidElement(e)&&e.type==="button"}var j=o.forwardRef((e,t)=>{let r=o.useContext(E),a=o.useContext(F),s=o.useContext(M),{iconOnly:i,size:n,variant:l,emphasis:p,color:d,disabled:u,asChild:v,onKeyDown:y,...w}=e,h=u||a?.disabled||void 0;if(s){let T={};for(let m of Object.keys(w))(/^on[A-Z]/.test(m)||m.startsWith("aria-")||m.startsWith("data-")||bo.has(m))&&(T[m]=w[m]);return y&&(T.onKeyDown=y),o.createElement(io,{...T,ref:t,asChild:v,iconOnly:i,disabled:h,color:d,pressed:e["aria-pressed"]===void 0?void 0:ao(e["aria-pressed"])},w.children)}let O=r?.orientation==="vertical"&&y?T=>{T.key==="ArrowDown"||T.key==="ArrowUp"||y(T)}:y,I=ao(e["aria-pressed"]),c="data-state"in e||e["aria-pressed"]===void 0?{}:{"data-state":I?"on":"off"},f={size:n??r?.size,...p!==void 0?{emphasis:p}:{variant:l??(a?"ghost":r?.backdrop?"raised":"soft")},color:d??(l||p?void 0:"gray"),...c},b={...w,...i?{iconOnly:!0}:{},...v?{asChild:!0}:{},...O?{onKeyDown:O}:{},...f};return r?v&&!To(w.children)?o.createElement(N.Link,{asChild:!0,ref:t},o.createElement(B,{...b,disabled:h})):o.createElement(N.Button,{asChild:!0,ref:t,disabled:h},o.createElement(B,{...b})):o.createElement(B,{...b,ref:t,disabled:h})});j.displayName="Toolbar.Button";var io=o.forwardRef(({asChild:e,iconOnly:t,disabled:r,color:a,pressed:s,children:i,"aria-label":n,...l},p)=>{let d=t?n:void 0,u={...l,...t?{}:n?{"aria-label":n}:{},disabled:r,...a?{color:a}:{}};if(e&&o.isValidElement(i)){let v=d?o.cloneElement(i,void 0,i.props.children,o.createElement("span",null,d)):i;return o.createElement(W,{...u,ref:p,asChild:!0},v)}return s!==void 0?o.createElement(ro,{...u,ref:p,checked:s},i,d):o.createElement(W,{...u,ref:p},i,d)});io.displayName="Toolbar.OverflowItem";function mo(){return o.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentcolor","aria-hidden":!0,xmlns:"http://www.w3.org/2000/svg"},o.createElement("circle",{cx:"3.25",cy:"8",r:"1.25"}),o.createElement("circle",{cx:"8",cy:"8",r:"1.25"}),o.createElement("circle",{cx:"12.75",cy:"8",r:"1.25"}))}var lo=o.forwardRef(({label:e="More",className:t,children:r,...a},s)=>{let i=o.Children.toArray(r),n=i.length,l=o.useRef(null),p=o.useRef([]),d=o.useRef(0),[u,v]=o.useState(n),[y,w]=o.useState(0),[h,O]=o.useState(n);h!==n&&(O(n),v(n)),D(()=>{p.current=[]},[n]),D(()=>{let c=l.current;if(!c)return;let f=Array.from(c.children),b=Math.min(u,n);for(let P=0;P<b;P++){let R=f[P];R&&(p.current[P]=R.offsetWidth)}let T=f[b];T&&(d.current=T.offsetWidth);let m=Number.parseFloat(getComputedStyle(c).columnGap)||0,K=c.clientWidth,V=0,_=0;for(let P=0;P<n;P++){let R=p.current[P];if(R===void 0)return;R!==0&&(V+=R+(_>0?m:0),_+=1)}let k=n;if(V>K){let P=K-(d.current||c.clientHeight)-m,R=0,Y=0;k=0;for(let G=0;G<n;G++){let Z=p.current[G];if(Z>0){let $=Z+(Y>0?m:0);if(R+$>P)break;R+=$,Y+=1}k+=1}}k!==u&&v(k)},[u,n,y]),o.useEffect(()=>{let c=l.current;if(!c||typeof ResizeObserver>"u")return;let f=new ResizeObserver(()=>w(b=>b+1));f.observe(c);for(let b of Array.from(c.children))f.observe(b);return()=>f.disconnect()},[u,n]);let I=o.useCallback(c=>{l.current=c,typeof s=="function"?s(c):s&&(s.current=c)},[s]);return o.createElement("div",{...a,ref:I,className:x("kui-ToolbarOverflow",t)},i.slice(0,u).map((c,f)=>o.createElement("div",{key:f,className:"kui-ToolbarOverflowSeat"},c)),u<n?o.createElement(X,null,o.createElement(oo,null,o.createElement(j,{iconOnly:!0,"aria-label":e},o.createElement(mo,null))),o.createElement(eo,{align:"end"},o.createElement(M.Provider,{value:!0},i.slice(u)))):null)});lo.displayName="Toolbar.Overflow";var A=[],S=new Map,z=new Set,C=new Map;function Po(e){return z.add(e),()=>{z.delete(e)}}function Ro(e,t,r){let a=S.get(e)??A,i=a.findIndex(n=>n.id===t)===-1?[...a,{id:t,node:r}]:a.map(n=>n.id===t?{id:t,node:r}:n);S.set(e,i),z.forEach(n=>n())}function vo(e,t){let r=S.get(e);if(!r)return;let a=r.filter(s=>s.id!==t);a.length===0?S.delete(e):S.set(e,a),z.forEach(s=>s())}function co({name:e="default"}){D(()=>{let r=(C.get(e)??0)+1;return C.set(e,r),r>1,()=>{let a=(C.get(e)??1)-1;a>0?C.set(e,a):C.delete(e)}},[e]);let t=o.useSyncExternalStore(Po,()=>S.get(e)??A,()=>A);return o.createElement(o.Fragment,null,t.map(r=>o.createElement(o.Fragment,{key:r.id},r.node)))}co.displayName="Toolbar.Slot";function uo({name:e="default",children:t}){let r=o.useId();return D(()=>{Ro(e,r,t)},[e,r,t]),D(()=>()=>vo(e,r),[e,r]),null}uo.displayName="Toolbar.Fill";var po=o.forwardRef(({className:e,...t},r)=>{let a=o.useContext(E);return o.useContext(M)?o.createElement(no,{...t,ref:r,className:e}):a?o.createElement(N.Separator,{...t,ref:r,className:x("kui-ToolbarSeparator",e)}):o.createElement("div",{role:"separator","aria-orientation":"vertical","data-orientation":"vertical",...t,ref:r,className:x("kui-ToolbarSeparator",e)})});po.displayName="Toolbar.Separator";var yo={1:"2",2:"3",3:"4",4:"5"},fo=o.forwardRef(({className:e,children:t,style:r,id:a},s)=>{let i=o.useContext(E),n=L(void 0,g.size),l=i?.size??n;return t==null||t===!1?null:o.createElement(Q,{ref:s,as:"span",size:yo[l],weight:"medium",truncate:!0,id:a,style:r,className:x("kui-ToolbarTitle",e)},t)});fo.displayName="Toolbar.Title";var No=Object.assign(H,{Root:H,Group:so,Button:j,Separator:po,Title:fo,Overflow:lo,Slot:co,Fill:uo});export{Bo as a,H as b,so as c,j as d,lo as e,co as f,uo as g,po as h,fo as i,No as j};
|
|
3
|
+
//# sourceMappingURL=chunk-PCLO3ZZY.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/components/toolbar.tsx"],
|
|
4
|
+
"sourcesContent": ["'use client';\n\nimport * as React from 'react';\nimport { useLayoutEffect } from 'radix-ui/internal';\nimport classNames from 'classnames';\nimport { Toolbar as ToolbarPrimitive } from 'radix-ui';\n\nimport { toolbarRootPropDefs } from './toolbar.props.js';\nimport { Button } from './button.js';\nimport * as DropdownMenu from './dropdown-menu.js';\nimport { Text } from './text.js';\nimport { extractProps } from '../helpers/extract-props.js';\nimport { useThemeSize } from '../hooks/theme-size.js';\nimport { layoutPropDefs } from '../props/layout.props.js';\nimport { usePaneBandSize } from './_internal/pane-chrome.js';\n\nimport type { ButtonProps } from './button.js';\nimport type { LayoutProps } from '../props/layout.props.js';\nimport type { TextProps } from './text.js';\nimport type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js';\nimport type { GetPropDefTypes } from '../props/prop-def.js';\nimport type { ButtonRankProps } from './button.js';\n\n/*\n * Toolbar takes Kookie UI v2's contract (v2: components/toolbar), built on Radix instead of\n * Base UI. A toolbar is a row of controls with ONE tab stop: `role=\"toolbar\"`, and the arrow\n * keys move focus between its controls. That keyboard is the reason it is a component.\n *\n * Its `size` reaches every control inside it that does not state its own. The row itself paints\n * nothing; a `ToolbarGroup` draws a quiet well around controls that belong together, and a\n * `ToolbarSeparator` draws a gray hairline between clusters. Use a `Flex` to cluster controls\n * without a well: the row spaces the clusters with `space-between`.\n */\n\ntype ToolbarSize = NonNullable<GetPropDefTypes<typeof toolbarRootPropDefs>['size']>;\ntype ToolbarOrientation = NonNullable<GetPropDefTypes<typeof toolbarRootPropDefs>['orientation']>;\n\ninterface ToolbarContextValue {\n size: ToolbarSize;\n orientation: ToolbarOrientation;\n backdrop: boolean;\n}\n\nconst ToolbarContext = React.createContext<ToolbarContextValue | null>(null);\n\n/** Set by a `ToolbarGroup`: its children rest quiet, and `disabled` turns them all off. */\nconst ToolbarGroupContext = React.createContext<{ disabled: boolean } | null>(null);\n\n/**\n * True while a subtree is drawn into a `ToolbarOverflow`'s menu instead of into the row (v2\n * `InOverflow`). The parts answer it themselves: a `ToolbarButton` renders a menu item, a\n * `ToolbarGroup` a menu group, a `ToolbarSeparator` a menu separator.\n */\nconst InOverflowContext = React.createContext(false);\n\n/**\n * True while this subtree is drawn into a `ToolbarOverflow`'s \"More\" menu instead of the row.\n *\n * The toolbar's own parts handle this already. Use it in your own component inside a\n * `ToolbarOverflow` to render a different form in the menu.\n */\nfunction useToolbarOverflow(): boolean {\n return React.useContext(InOverflowContext);\n}\n\n// ============================================================================\n// Toolbar (root)\n// ============================================================================\n\ntype ToolbarOwnProps = GetPropDefTypes<typeof toolbarRootPropDefs>;\n\ninterface ToolbarProps\n extends ComponentPropsWithout<typeof ToolbarPrimitive.Root, RemovedProps | 'orientation'>,\n ToolbarOwnProps,\n LayoutProps {\n /**\n * Gives every control a surface of its own, for a row that content passes behind, such as\n * `Shell.PaneHeader float`. Buttons rest `raised` instead of `soft`, and a group's well is\n * solid and raised.\n */\n backdrop?: boolean;\n}\n\n/**\n * A row of controls with one keyboard tab stop. The arrow keys move focus between the controls.\n *\n * Give it an `aria-label` (or `aria-labelledby`) that says what the controls act on.\n *\n * @example\n * ```tsx\n * <Toolbar aria-label=\"Formatting\">\n * <ToolbarGroup>\n * <ToolbarButton iconOnly aria-label=\"Bold\" aria-pressed={bold} onClick={toggleBold}>\n * <HugeiconsIcon icon={TextBoldIcon} strokeWidth={1.75} />\n * </ToolbarButton>\n * </ToolbarGroup>\n * <ToolbarSeparator />\n * <ToolbarButton>Share</ToolbarButton>\n * </Toolbar>\n * ```\n */\nconst ToolbarRoot = React.forwardRef<HTMLDivElement, ToolbarProps>((props, forwardedRef) => {\n // Inside a Shell (a pane's header or footer, or the content area), a toolbar with no size\n // rests one step above the Shell's. A pane's scrolling list has no band.\n const band = usePaneBandSize();\n // Elsewhere it takes the nearest Theme's size.\n const size: ToolbarSize = useThemeSize(props.size ?? band ?? undefined, toolbarRootPropDefs.size);\n const orientation: ToolbarOrientation = props.orientation ?? toolbarRootPropDefs.orientation.default;\n const { className, orientation: _orientation, backdrop = false, children, ...rootProps } = extractProps(\n { ...props, size },\n toolbarRootPropDefs,\n layoutPropDefs,\n );\n\n const context = React.useMemo(() => ({ size, orientation, backdrop }), [size, orientation, backdrop]);\n\n return (\n <ToolbarPrimitive.Root\n {...rootProps}\n ref={forwardedRef}\n orientation={orientation}\n data-backdrop={backdrop || undefined}\n className={classNames('kui-Toolbar', className)}\n >\n <ToolbarContext.Provider value={context}>{children}</ToolbarContext.Provider>\n </ToolbarPrimitive.Root>\n );\n});\nToolbarRoot.displayName = 'Toolbar';\n\n// ============================================================================\n// ToolbarGroup\n// ============================================================================\n\ninterface ToolbarGroupProps extends ComponentPropsWithout<'div', RemovedProps> {\n /** Turns every control in the group off at once. */\n disabled?: boolean;\n}\n\n/**\n * Controls that belong together, drawn as one quiet well that stands level with a button\n * beside it. Buttons inside it rest as `ghost` unless they state a `variant`.\n * To cluster controls without a well, use a `Flex`.\n *\n * In a `ToolbarOverflow`'s menu it is a menu group. Outside a `Toolbar` (rendered through a\n * portal, for example) it still draws its well, as a horizontal group.\n */\nconst ToolbarGroup = React.forwardRef<HTMLDivElement, ToolbarGroupProps>(\n ({ className, disabled = false, children, ...props }, forwardedRef) => {\n const toolbar = React.useContext(ToolbarContext);\n const overflow = React.useContext(InOverflowContext);\n const group = React.useMemo(() => ({ disabled }), [disabled]);\n\n if (overflow) {\n return (\n <DropdownMenu.Group {...props} ref={forwardedRef} className={className}>\n <ToolbarGroupContext.Provider value={group}>{children}</ToolbarGroupContext.Provider>\n </DropdownMenu.Group>\n );\n }\n\n return (\n <div\n role=\"group\"\n data-orientation={toolbar?.orientation ?? 'horizontal'}\n data-disabled={disabled || undefined}\n {...props}\n ref={forwardedRef}\n className={classNames('kui-ToolbarGroup', className)}\n >\n <ToolbarGroupContext.Provider value={group}>{children}</ToolbarGroupContext.Provider>\n </div>\n );\n },\n);\nToolbarGroup.displayName = 'Toolbar.Group';\n\n// ============================================================================\n// ToolbarButton\n// ============================================================================\n\ntype ToolbarButtonBaseProps = Omit<ButtonProps, 'as' | 'variant' | 'emphasis'>;\n\n/** A labelled button: takes every `Button` prop. */\ntype ToolbarTextButtonProps = ToolbarButtonBaseProps &\n ButtonRankProps & {\n iconOnly?: false;\n};\n\n/** An icon-only button: renders `Button iconOnly`, and the type requires an `aria-label`. */\ntype ToolbarIconButtonProps = Omit<ToolbarButtonBaseProps, 'aria-label' | 'aria-labelledby' | 'fullWidth'> &\n ButtonRankProps & {\n iconOnly: true;\n /** The control's accessible name. An icon has no words of its own, so this is required. */\n 'aria-label': string;\n};\n\ntype ToolbarButtonProps = ToolbarTextButtonProps | ToolbarIconButtonProps;\n\n/** The plain DOM props, besides handlers, ARIA and data attributes, a menu row takes from a ToolbarButton. */\nconst OVERFLOW_ITEM_KEYS = new Set(['id', 'className', 'style', 'title']);\n\nfunction isPressed(value: React.AriaAttributes['aria-pressed']) {\n return value === true || value === 'true';\n}\n\n/** Does an `asChild` child render a native `<button>`? Only then is it a Radix Toolbar.Button. */\nfunction isButtonElement(children: React.ReactNode) {\n return React.isValidElement(children) && children.type === 'button';\n}\n\n/**\n * A `Button` that joins the toolbar's keyboard navigation, so a row of them is one tab stop.\n *\n * Set `iconOnly` (with an `aria-label`) for a symbol-only control. Set `aria-pressed` for a\n * control that toggles; a pressed button wears Button's pressed look. Set `asChild` to render\n * your own element, such as a link: `<ToolbarButton asChild><a href=\"/docs\">Docs</a></ToolbarButton>`.\n * A link stays in the arrow-key row and gets no `type` attribute.\n *\n * It takes the toolbar's `size`, and rests as a gray `soft` button (`raised` in a toolbar with\n * `backdrop`, gray `ghost` inside a `ToolbarGroup`). A stated `size`, `variant` or `color` wins; a\n * stated `variant` without a `color` takes Button's own default colour.\n *\n * In a `ToolbarOverflow`'s menu it renders a menu item; an icon-only button uses its\n * `aria-label` as the item's text. Outside a `Toolbar` (rendered through a React portal, for\n * example) it renders a plain Button with the same rest look, as its own tab stop. Use\n * `ToolbarSlot` and `ToolbarFill` for a control that should join the row's arrow keys.\n */\nconst ToolbarButton = React.forwardRef<HTMLButtonElement, ToolbarButtonProps>((props, forwardedRef) => {\n const toolbar = React.useContext(ToolbarContext);\n const group = React.useContext(ToolbarGroupContext);\n const overflow = React.useContext(InOverflowContext);\n const { iconOnly, size, variant, emphasis, color, disabled, asChild, onKeyDown, ...rest } = props;\n const off = disabled || group?.disabled || undefined;\n\n if (overflow) {\n // Only what a menu row means comes across: handlers, ARIA, data attributes, id, class and\n // style. Button's box props (size, loading, tooltip, fullWidth and the rest) would land on the\n // DOM as unknown attributes. A wrapping menu trigger hands its open handlers (onPointerDown,\n // onKeyDown), aria-expanded/haspopup/controls and data-state in through these, so it still\n // opens from the row.\n const passed: Record<string, unknown> = {};\n for (const key of Object.keys(rest)) {\n if (/^on[A-Z]/.test(key) || key.startsWith('aria-') || key.startsWith('data-') || OVERFLOW_ITEM_KEYS.has(key)) {\n passed[key] = (rest as Record<string, unknown>)[key];\n }\n }\n if (onKeyDown) passed.onKeyDown = onKeyDown;\n return (\n <ToolbarOverflowItem\n {...(passed as React.ComponentPropsWithoutRef<'div'>)}\n ref={forwardedRef as unknown as React.Ref<HTMLDivElement>}\n asChild={asChild}\n iconOnly={iconOnly}\n disabled={off}\n color={color}\n pressed={props['aria-pressed'] === undefined ? undefined : isPressed(props['aria-pressed'])}\n >\n {rest.children}\n </ToolbarOverflowItem>\n );\n }\n\n // In a vertical toolbar, Up and Down belong to the toolbar. A menu trigger rendering this\n // hands its open-on-arrow handler in through `onKeyDown`; those two keys skip it (v2).\n const handleKeyDown =\n toolbar?.orientation === 'vertical' && onKeyDown\n ? (event: React.KeyboardEvent<HTMLButtonElement>) => {\n if (event.key === 'ArrowDown' || event.key === 'ArrowUp') return;\n onKeyDown(event);\n }\n : onKeyDown;\n\n const pressed = isPressed(props['aria-pressed']);\n const stateProps =\n 'data-state' in props || props['aria-pressed'] === undefined ? {} : { 'data-state': pressed ? 'on' : 'off' };\n\n const shared = {\n size: size ?? toolbar?.size,\n // A caller states the look by `variant` or the rank by `emphasis`, never both.\n ...(emphasis !== undefined\n ? { emphasis }\n : { variant: variant ?? (group ? 'ghost' : toolbar?.backdrop ? 'raised' : 'soft') }),\n // The gray rest is a pair with the default variant: a caller who states a variant or an\n // emphasis gets Button's own colour for it unless they state a colour too.\n color: color ?? (variant || emphasis ? undefined : 'gray'),\n ...stateProps,\n } as const;\n\n // The text and icon-only branches share every prop but the name; one Button renders both.\n const buttonProps = {\n ...rest,\n ...(iconOnly ? { iconOnly: true } : {}),\n ...(asChild ? { asChild: true } : {}),\n ...(handleKeyDown ? { onKeyDown: handleKeyDown } : {}),\n ...shared,\n } as ButtonProps;\n\n // Outside a toolbar there is no row to join: a plain Button, not a throw.\n if (!toolbar) {\n return <Button {...buttonProps} ref={forwardedRef} disabled={off} />;\n }\n\n // A link (or any non-button child) joins the row as a Radix Toolbar.Link, which sets no\n // `type`. Toolbar.Button would stamp `type=\"button\"` on it.\n if (asChild && !isButtonElement(rest.children)) {\n return (\n <ToolbarPrimitive.Link asChild ref={forwardedRef as unknown as React.Ref<HTMLAnchorElement>}>\n <Button {...buttonProps} disabled={off} />\n </ToolbarPrimitive.Link>\n );\n }\n\n return (\n <ToolbarPrimitive.Button asChild ref={forwardedRef} disabled={off}>\n <Button {...buttonProps} />\n </ToolbarPrimitive.Button>\n );\n});\nToolbarButton.displayName = 'Toolbar.Button';\n\ninterface ToolbarOverflowItemProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'onSelect' | 'color'> {\n asChild?: boolean;\n iconOnly?: boolean;\n disabled?: boolean;\n color?: ButtonProps['color'];\n /** A toggle's pressed state. A toggle becomes a checkbox item, so the menu still says whether it is on. */\n pressed?: boolean;\n}\n\n/**\n * A ToolbarButton drawn into the overflow menu: the same element, as a menu item. An icon-only\n * button's `aria-label` becomes the item's text beside its icon, since a menu row has room for\n * words. What prices a box (size, variant, emphasis, iconOnly) does not come across.\n */\nconst ToolbarOverflowItem = React.forwardRef<HTMLDivElement, ToolbarOverflowItemProps>(\n ({ asChild, iconOnly, disabled, color, pressed, children, 'aria-label': label, ...props }, forwardedRef) => {\n const words = iconOnly ? label : undefined;\n const itemProps = {\n ...props,\n ...(iconOnly ? {} : label ? { 'aria-label': label } : {}),\n disabled,\n ...(color ? { color: color as DropdownMenu.ItemProps['color'] } : {}),\n };\n if (asChild && React.isValidElement<{ children?: React.ReactNode }>(children)) {\n const child = words\n ? React.cloneElement(children, undefined, children.props.children, <span>{words}</span>)\n : children;\n return (\n <DropdownMenu.Item {...itemProps} ref={forwardedRef} asChild>\n {child}\n </DropdownMenu.Item>\n );\n }\n if (pressed !== undefined) {\n return (\n <DropdownMenu.CheckboxItem {...itemProps} ref={forwardedRef} checked={pressed}>\n {children}\n {words}\n </DropdownMenu.CheckboxItem>\n );\n }\n return (\n <DropdownMenu.Item {...itemProps} ref={forwardedRef}>\n {children}\n {words}\n </DropdownMenu.Item>\n );\n },\n);\nToolbarOverflowItem.displayName = 'Toolbar.OverflowItem';\n\n// ============================================================================\n// ToolbarOverflow\n// ============================================================================\n\ninterface ToolbarOverflowProps extends ComponentPropsWithout<'div', RemovedProps> {\n /** The accessible name of the \"More\" button. Defaults to `More`. */\n label?: string;\n /** The controls in the cluster, in order. The ones that don't fit move into the \"More\" menu. */\n children?: React.ReactNode;\n}\n\n/** Three filled dots for the \"More\" button. Internal, so the library carries no icon set. */\nfunction MoreIcon() {\n return (\n <svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"currentcolor\" aria-hidden xmlns=\"http://www.w3.org/2000/svg\">\n <circle cx=\"3.25\" cy=\"8\" r=\"1.25\" />\n <circle cx=\"8\" cy=\"8\" r=\"1.25\" />\n <circle cx=\"12.75\" cy=\"8\" r=\"1.25\" />\n </svg>\n );\n}\n\n/**\n * A cluster of controls that collapses into a \"More\" menu when the row runs out of room.\n *\n * It takes the room the row leaves, and when its controls don't fit, they move into the menu\n * from the end of the cluster. A `ToolbarButton` shows as a menu item there, and a\n * `ToolbarGroup` as a menu group. Use `useToolbarOverflow()` in your own components to render a\n * different form in the menu.\n *\n * It measures on mount and on resize (v2 ToolbarOverflow): each control's width is cached while\n * it is in the row, since a hidden control has no width to measure.\n */\nconst ToolbarOverflow = React.forwardRef<HTMLDivElement, ToolbarOverflowProps>(\n ({ label = 'More', className, children, ...props }, forwardedRef) => {\n const items = React.Children.toArray(children);\n const count = items.length;\n\n const rootRef = React.useRef<HTMLDivElement | null>(null);\n const widths = React.useRef<number[]>([]);\n const triggerWidth = React.useRef(0);\n const [shown, setShown] = React.useState(count);\n const [tick, setTick] = React.useState(0);\n\n // A different set of children is a different set of widths: show them all and measure again.\n const [measuredCount, setMeasuredCount] = React.useState(count);\n if (measuredCount !== count) {\n setMeasuredCount(count);\n setShown(count);\n }\n useLayoutEffect(() => {\n widths.current = [];\n }, [count]);\n\n useLayoutEffect(() => {\n const root = rootRef.current;\n if (!root) return;\n\n // The root's children are one seat per visible child, then the trigger.\n const kids = Array.from(root.children) as HTMLElement[];\n const visible = Math.min(shown, count);\n for (let i = 0; i < visible; i++) {\n const el = kids[i];\n if (el) widths.current[i] = el.offsetWidth;\n }\n const trigger = kids[visible];\n if (trigger) triggerWidth.current = trigger.offsetWidth;\n\n const gap = Number.parseFloat(getComputedStyle(root).columnGap) || 0;\n const available = root.clientWidth;\n\n let total = 0;\n let counted = 0;\n for (let i = 0; i < count; i++) {\n const width = widths.current[i];\n // Never seen in the row, so there is nothing to decide with yet.\n if (width === undefined) return;\n // An empty seat leaves the layout, so it spends no gap.\n if (width === 0) continue;\n total += width + (counted > 0 ? gap : 0);\n counted += 1;\n }\n\n let next = count;\n if (total > available) {\n // Before the trigger exists, the row's height stands in for its width: an icon-only\n // button is square. The next pass, before paint, corrects it.\n const budget = available - (triggerWidth.current || root.clientHeight) - gap;\n let used = 0;\n let drawn = 0;\n next = 0;\n for (let i = 0; i < count; i++) {\n const own = widths.current[i]!;\n if (own > 0) {\n const width = own + (drawn > 0 ? gap : 0);\n if (used + width > budget) break;\n used += width;\n drawn += 1;\n }\n next += 1;\n }\n }\n if (next !== shown) setShown(next);\n }, [shown, count, tick]);\n\n // Watch the row and every seat in it: a control whose content changes (a page's actions\n // arriving after navigation) changes its width without the row's width changing.\n React.useEffect(() => {\n const root = rootRef.current;\n if (!root || typeof ResizeObserver === 'undefined') return;\n const observer = new ResizeObserver(() => setTick((n) => n + 1));\n observer.observe(root);\n for (const seat of Array.from(root.children)) observer.observe(seat);\n return () => observer.disconnect();\n }, [shown, count]);\n\n const attach = React.useCallback(\n (node: HTMLDivElement | null) => {\n rootRef.current = node;\n if (typeof forwardedRef === 'function') forwardedRef(node);\n else if (forwardedRef) forwardedRef.current = node;\n },\n [forwardedRef],\n );\n\n return (\n <div {...props} ref={attach} className={classNames('kui-ToolbarOverflow', className)}>\n {items.slice(0, shown).map((item, i) => (\n // The seat is a position in the row, so its key is the index.\n <div key={i} className=\"kui-ToolbarOverflowSeat\">\n {item}\n </div>\n ))}\n {shown < count ? (\n <DropdownMenu.Root>\n <DropdownMenu.Trigger>\n <ToolbarButton iconOnly aria-label={label}>\n <MoreIcon />\n </ToolbarButton>\n </DropdownMenu.Trigger>\n <DropdownMenu.Content align=\"end\">\n <InOverflowContext.Provider value>{items.slice(shown)}</InOverflowContext.Provider>\n </DropdownMenu.Content>\n </DropdownMenu.Root>\n ) : null}\n </div>\n );\n },\n);\nToolbarOverflow.displayName = 'Toolbar.Overflow';\n\n// ============================================================================\n// ToolbarSlot and ToolbarFill\n// ============================================================================\n\ntype SlotEntry = { id: string; node: React.ReactNode };\n\nconst EMPTY_ENTRIES: readonly SlotEntry[] = [];\nconst slotEntries = new Map<string, readonly SlotEntry[]>();\nconst slotListeners = new Set<() => void>();\n/** How many ToolbarSlots of each name are mounted, to warn when one Fill would render twice. */\nconst mountedSlots = new Map<string, number>();\n\nfunction subscribeSlots(listener: () => void) {\n slotListeners.add(listener);\n return () => {\n slotListeners.delete(listener);\n };\n}\n\nfunction setSlotEntry(name: string, id: string, node: React.ReactNode) {\n const list = slotEntries.get(name) ?? EMPTY_ENTRIES;\n const index = list.findIndex((entry) => entry.id === id);\n const next = index === -1 ? [...list, { id, node }] : list.map((entry) => (entry.id === id ? { id, node } : entry));\n slotEntries.set(name, next);\n slotListeners.forEach((listener) => listener());\n}\n\nfunction removeSlotEntry(name: string, id: string) {\n const list = slotEntries.get(name);\n if (!list) return;\n const next = list.filter((entry) => entry.id !== id);\n if (next.length === 0) slotEntries.delete(name);\n else slotEntries.set(name, next);\n slotListeners.forEach((listener) => listener());\n}\n\ninterface ToolbarSlotProps {\n /**\n * Which `ToolbarFill` renders here. Defaults to `default`. Names are global to the page: mount one\n * slot per name, or the fill renders in each of them (development builds warn).\n */\n name?: string;\n}\n\n/**\n * A place in a toolbar that content elsewhere in the app fills, such as a page adding its own\n * actions to a header toolbar the layout owns.\n *\n * It renders whatever the `ToolbarFill` with the same `name` holds, as if it were written here:\n * the controls take the toolbar's size and join its arrow-key row. It adds no element.\n */\nfunction ToolbarSlot({ name = 'default' }: ToolbarSlotProps) {\n useLayoutEffect(() => {\n const count = (mountedSlots.get(name) ?? 0) + 1;\n mountedSlots.set(name, count);\n if (count > 1 && process.env.NODE_ENV !== 'production') {\n console.warn(`[kookie-ui] ToolbarSlot: ${count} slots named \"${name}\" are mounted. Each renders the ToolbarFill's controls, so they appear more than once. Give each slot its own name.`);\n }\n return () => {\n const left = (mountedSlots.get(name) ?? 1) - 1;\n if (left > 0) mountedSlots.set(name, left);\n else mountedSlots.delete(name);\n };\n }, [name]);\n const entries = React.useSyncExternalStore(\n subscribeSlots,\n () => slotEntries.get(name) ?? EMPTY_ENTRIES,\n () => EMPTY_ENTRIES,\n );\n return (\n <>\n {entries.map((entry) => (\n <React.Fragment key={entry.id}>{entry.node}</React.Fragment>\n ))}\n </>\n );\n}\nToolbarSlot.displayName = 'Toolbar.Slot';\n\ninterface ToolbarFillProps {\n /** The `ToolbarSlot` to render into. Defaults to `default`. */\n name?: string;\n /** The controls to show in the slot, such as `ToolbarButton`s. */\n children?: React.ReactNode;\n}\n\n/**\n * Sends its children to the `ToolbarSlot` with the same `name`, and renders nothing where it\n * is written. Use it instead of a React portal: a portal keeps the page's React tree, so a\n * ToolbarButton in it can't join the toolbar's arrow keys.\n *\n * The children render inside the toolbar, so they read the toolbar's context, not the page's.\n * They appear after the page mounts on the client, not in server-rendered HTML.\n */\nfunction ToolbarFill({ name = 'default', children }: ToolbarFillProps) {\n const id = React.useId();\n useLayoutEffect(() => {\n setSlotEntry(name, id, children);\n }, [name, id, children]);\n useLayoutEffect(() => () => removeSlotEntry(name, id), [name, id]);\n return null;\n}\nToolbarFill.displayName = 'Toolbar.Fill';\n\n// ============================================================================\n// ToolbarSeparator\n// ============================================================================\n\ntype ToolbarSeparatorProps = ComponentPropsWithout<typeof ToolbarPrimitive.Separator, RemovedProps | 'orientation'>;\n\n/**\n * A gray hairline between two clusters, announced as a separator. Its direction is always\n * opposite to the toolbar's. In a `ToolbarOverflow`'s menu it is a menu separator.\n */\nconst ToolbarSeparator = React.forwardRef<HTMLDivElement, ToolbarSeparatorProps>(\n ({ className, ...props }, forwardedRef) => {\n const toolbar = React.useContext(ToolbarContext);\n const overflow = React.useContext(InOverflowContext);\n if (overflow) return <DropdownMenu.Separator {...props} ref={forwardedRef} className={className} />;\n if (!toolbar) {\n return (\n <div\n role=\"separator\"\n aria-orientation=\"vertical\"\n data-orientation=\"vertical\"\n {...props}\n ref={forwardedRef}\n className={classNames('kui-ToolbarSeparator', className)}\n />\n );\n }\n return (\n <ToolbarPrimitive.Separator\n {...props}\n ref={forwardedRef}\n className={classNames('kui-ToolbarSeparator', className)}\n />\n );\n },\n);\nToolbarSeparator.displayName = 'Toolbar.Separator';\n\n// ============================================================================\n// ToolbarTitle\n// ============================================================================\n\n/** The title's text step: one step above the label of a button at the same size. */\nconst TITLE_SIZE = { '1': '2', '2': '3', '3': '4', '4': '5' } as const satisfies Record<ToolbarSize, TextProps['size']>;\n\ninterface ToolbarTitleProps {\n /** The title text. With none, the title renders nothing. */\n children?: React.ReactNode;\n className?: string;\n style?: React.CSSProperties;\n /** The id of the title, so that the toolbar's `aria-labelledby` can point at it. */\n id?: string;\n}\n\n/**\n * What the row is about, at its leading edge. One line: it truncates rather than wrapping.\n * Its text step follows the toolbar's `size`, and it takes more air from the controls beside it\n * than they take from each other.\n */\nconst ToolbarTitle = React.forwardRef<HTMLSpanElement, ToolbarTitleProps>(\n ({ className, children, style, id }, forwardedRef) => {\n const toolbar = React.useContext(ToolbarContext);\n const themeSize = useThemeSize<ToolbarSize>(undefined, toolbarRootPropDefs.size);\n const size = toolbar?.size ?? themeSize;\n if (children === undefined || children === null || children === false) return null;\n return (\n <Text\n ref={forwardedRef}\n as=\"span\"\n size={TITLE_SIZE[size]}\n weight=\"medium\"\n truncate\n id={id}\n style={style}\n className={classNames('kui-ToolbarTitle', className)}\n >\n {children}\n </Text>\n );\n },\n);\nToolbarTitle.displayName = 'Toolbar.Title';\n\n// ============================================================================\n// Exports\n// ============================================================================\n\nconst Toolbar = Object.assign(ToolbarRoot, {\n Root: ToolbarRoot,\n Group: ToolbarGroup,\n Button: ToolbarButton,\n Separator: ToolbarSeparator,\n Title: ToolbarTitle,\n Overflow: ToolbarOverflow,\n Slot: ToolbarSlot,\n Fill: ToolbarFill,\n});\n\nexport {\n Toolbar,\n ToolbarGroup,\n ToolbarButton,\n ToolbarSeparator,\n ToolbarTitle,\n ToolbarOverflow,\n ToolbarSlot,\n ToolbarFill,\n useToolbarOverflow,\n ToolbarRoot as Root,\n ToolbarGroup as Group,\n ToolbarButton as Button,\n ToolbarSeparator as Separator,\n ToolbarTitle as Title,\n ToolbarOverflow as Overflow,\n ToolbarSlot as Slot,\n ToolbarFill as Fill,\n};\nexport type {\n ToolbarProps,\n ToolbarGroupProps,\n ToolbarButtonProps,\n ToolbarSeparatorProps,\n ToolbarTitleProps,\n ToolbarOverflowProps,\n ToolbarSlotProps,\n ToolbarFillProps,\n ToolbarProps as RootProps,\n ToolbarGroupProps as GroupProps,\n ToolbarButtonProps as ButtonProps,\n ToolbarSeparatorProps as SeparatorProps,\n ToolbarTitleProps as TitleProps,\n ToolbarOverflowProps as OverflowProps,\n ToolbarSlotProps as SlotProps,\n ToolbarFillProps as FillProps,\n};\n"],
|
|
5
|
+
"mappings": ";+WAEA,UAAYA,MAAW,QACvB,OAAS,mB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0B,OAAWC,EAAoB,IAAI,EACzEF,EAAOgB,GAAS,MAAQ6F,EAC9B,OAA8BtG,GAAa,MAAQA,IAAa,GAAc,KAE5E,gBAACuG,EAAA,CACC,IAAKjH,EACL,GAAG,OACH,KAAM6G,GAAW1G,CAAI,EACrB,OAAO,SACP,SAAQ,GACR,GAAIgG,EACJ,MAAOY,EACP,UAAW/F,EAAW,mBAAoBT,CAAS,GAElDG,CACH,CAEJ,CACF,EACAoG,GAAa,YAAc,gBAM3B,IAAMI,GAAU,OAAO,OAAOpH,EAAa,CACzC,KAAMA,EACN,MAAOmB,GACP,OAAQU,EACR,UAAWgF,GACX,MAAOG,GACP,SAAUzD,GACV,KAAMkD,GACN,KAAMG,EACR,CAAC",
|
|
6
|
+
"names": ["React", "useLayoutEffect", "classNames", "ToolbarPrimitive", "ToolbarContext", "ToolbarGroupContext", "InOverflowContext", "useToolbarOverflow", "ToolbarRoot", "props", "forwardedRef", "band", "usePaneBandSize", "size", "useThemeSize", "toolbarRootPropDefs", "orientation", "className", "_orientation", "backdrop", "children", "rootProps", "extractProps", "layoutPropDefs", "context", "ToolbarPrimitive", "classNames", "ToolbarGroup", "disabled", "toolbar", "overflow", "group", "DropdownMenuGroup", "OVERFLOW_ITEM_KEYS", "isPressed", "value", "isButtonElement", "ToolbarButton", "iconOnly", "variant", "emphasis", "color", "asChild", "onKeyDown", "rest", "off", "passed", "key", "ToolbarOverflowItem", "handleKeyDown", "event", "pressed", "stateProps", "shared", "buttonProps", "Button", "label", "words", "itemProps", "child", "DropdownMenuItem", "DropdownMenuCheckboxItem", "MoreIcon", "ToolbarOverflow", "items", "count", "rootRef", "widths", "triggerWidth", "shown", "setShown", "tick", "setTick", "measuredCount", "setMeasuredCount", "useLayoutEffect", "root", "kids", "visible", "i", "el", "trigger", "gap", "available", "total", "counted", "width", "next", "budget", "used", "drawn", "own", "observer", "n", "seat", "attach", "node", "item", "DropdownMenuRoot", "DropdownMenuTrigger", "DropdownMenuContent", "EMPTY_ENTRIES", "slotEntries", "slotListeners", "mountedSlots", "subscribeSlots", "listener", "setSlotEntry", "name", "id", "list", "entry", "removeSlotEntry", "ToolbarSlot", "left", "entries", "ToolbarFill", "ToolbarSeparator", "DropdownMenuSeparator", "TITLE_SIZE", "ToolbarTitle", "style", "themeSize", "Text", "Toolbar"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import{a as s,b as m}from"./chunk-IO43RGNR.js";import{a as p}from"./chunk-SHLERRO3.js";import{a as r}from"./chunk-MXIVYALY.js";import{a as t,b as f,c as i}from"./chunk-Z27REN6T.js";import{a as o}from"./chunk-CLJ6SEGP.js";import{c as e}from"./chunk-HBWBPBSA.js";var a=["span","div","label","p"],n=["1","2","3","4","5","6","7","8","9"],x={as:{type:"enum",values:a,default:"span"},...o,size:{type:"enum",className:"kui-r-size",values:n,responsive:!0},...m,...i,...s,...p,...f,...t,...e,...r};export{x as a};
|
|
3
|
+
//# sourceMappingURL=chunk-PHWT772P.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/components/text.props.tsx"],
|
|
4
4
|
"sourcesContent": ["import { asChildPropDef } from '../props/as-child.prop.js';\nimport { colorPropDef } from '../props/color.prop.js';\nimport { emphasisPropDef } from '../props/emphasis.prop.js';\nimport { leadingTrimPropDef } from '../props/leading-trim.prop.js';\nimport { textAlignPropDef } from '../props/text-align.prop.js';\nimport { textWrapPropDef } from '../props/text-wrap.prop.js';\nimport { truncatePropDef } from '../props/truncate.prop.js';\nimport { fontFamilyPropDef } from '../props/font-family.prop.js';\nimport { weightPropDef } from '../props/weight.prop.js';\n\nimport type { PropDef } from '../props/prop-def.js';\n\nconst as = ['span', 'div', 'label', 'p'] as const;\nconst sizes = ['1', '2', '3', '4', '5', '6', '7', '8', '9'] as const;\n\nconst textPropDefs = {\n as: { type: 'enum', values: as, default: 'span' },\n ...asChildPropDef,\n size: {\n type: 'enum',\n className: 'kui-r-size',\n values: sizes,\n responsive: true,\n },\n ...fontFamilyPropDef,\n ...weightPropDef,\n ...textAlignPropDef,\n ...leadingTrimPropDef,\n ...truncatePropDef,\n ...textWrapPropDef,\n ...colorPropDef,\n ...emphasisPropDef,\n} satisfies {\n as: PropDef<(typeof as)[number]>;\n size: PropDef<(typeof sizes)[number]>;\n};\n\nexport { textPropDefs };\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";qQAYA,IAAMA,EAAK,CAAC,OAAQ,MAAO,QAAS,GAAG,EACjCC,EAAQ,CAAC,IAAK,IAAK,IAAK,IAAK,IAAK,IAAK,IAAK,IAAK,GAAG,EAEpDC,EAAe,CACnB,GAAI,CAAE,KAAM,OAAQ,OAAQF,EAAI,QAAS,MAAO,EAChD,GAAGG,EACH,KAAM,CACJ,KAAM,OACN,UAAW,aACX,OAAQF,EACR,WAAY,EACd,EACA,GAAGG,EACH,GAAGC,EACH,GAAGC,EACH,GAAGC,EACH,GAAGC,EACH,GAAGC,EACH,GAAGC,EACH,GAAGC,CACL",
|
|
6
6
|
"names": ["as", "sizes", "textPropDefs", "asChildPropDef", "fontFamilyPropDef", "weightPropDef", "textAlignPropDef", "leadingTrimPropDef", "truncatePropDef", "textWrapPropDef", "colorPropDef", "emphasisPropDef"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{a as o}from"./chunk-LPLW7OWA.js";import{a as e}from"./chunk-L54FWKJE.js";import{a as t}from"./chunk-CLJ6SEGP.js";var i=["1","2","3","4"],n={...t,align:{type:"enum",className:"kui-r-align",values:["start","center"],default:"center"},size:{type:"enum",className:"kui-r-size",values:i,default:"2",responsive:!0},width:e.width,minWidth:e.minWidth,maxWidth:e.maxWidth,...o};export{n as a};
|
|
3
|
+
//# sourceMappingURL=chunk-PT45Q47V.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/components/dialog.props.tsx"],
|
|
4
4
|
"sourcesContent": ["import { asChildPropDef } from '../props/as-child.prop.js';\nimport { widthPropDefs } from '../props/width.props.js';\nimport { heightPropDefs } from '../props/height.props.js';\n\nimport type { PropDef, GetPropDefTypes } from '../props/prop-def.js';\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nconst alignValues = ['start', 'center'] as const;\nconst contentSizes = ['1', '2', '3', '4'] as const;\n\nconst dialogContentPropDefs = {\n ...asChildPropDef,\n align: {\n type: 'enum',\n className: 'kui-r-align',\n values: ['start', 'center'],\n default: 'center',\n },\n size: {\n type: 'enum',\n className: 'kui-r-size',\n values: contentSizes,\n default: '2',\n responsive: true,\n },\n width: widthPropDefs.width,\n minWidth: widthPropDefs.minWidth,\n // No default: the size's --overlay-w is the max width until a maxWidth is given.\n maxWidth: widthPropDefs.maxWidth,\n ...heightPropDefs,\n} satisfies {\n align: PropDef<(typeof alignValues)[number]>;\n size: PropDef<(typeof contentSizes)[number]>;\n width: PropDef<string>;\n minWidth: PropDef<string>;\n maxWidth: PropDef<string>;\n};\n\ntype DialogContentOwnProps = GetPropDefTypes<\n typeof dialogContentPropDefs & typeof asChildPropDef & typeof widthPropDefs\n>;\n\nexport { dialogContentPropDefs };\nexport type { DialogContentOwnProps };\n"],
|
|
5
|
-
"mappings": "wHAQA,IAAMA,EAAe,CAAC,IAAK,IAAK,IAAK,GAAG,EAElCC,EAAwB,CAC5B,GAAGC,EACH,MAAO,CACL,KAAM,OACN,UAAW,cACX,OAAQ,CAAC,QAAS,QAAQ,EAC1B,QAAS,QACX,EACA,KAAM,CACJ,KAAM,OACN,UAAW,aACX,OAAQF,EACR,QAAS,IACT,WAAY,EACd,EACA,MAAOG,EAAc,MACrB,SAAUA,EAAc,SAExB,SAAUA,EAAc,SACxB,GAAGC,CACL",
|
|
5
|
+
"mappings": ";wHAQA,IAAMA,EAAe,CAAC,IAAK,IAAK,IAAK,GAAG,EAElCC,EAAwB,CAC5B,GAAGC,EACH,MAAO,CACL,KAAM,OACN,UAAW,cACX,OAAQ,CAAC,QAAS,QAAQ,EAC1B,QAAS,QACX,EACA,KAAM,CACJ,KAAM,OACN,UAAW,aACX,OAAQF,EACR,QAAS,IACT,WAAY,EACd,EACA,MAAOG,EAAc,MACrB,SAAUA,EAAc,SAExB,SAAUA,EAAc,SACxB,GAAGC,CACL",
|
|
6
6
|
"names": ["contentSizes", "dialogContentPropDefs", "asChildPropDef", "widthPropDefs", "heightPropDefs"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{b as o}from"./chunk-XU74PNM2.js";import{c as e}from"./chunk-HBWBPBSA.js";var r=["1","2","3","4"],p={size:{type:"enum",className:"kui-r-size",values:r,default:"2",responsive:!0}},s=["raised","surface","soft","outline","ghost"],i={variant:{type:"enum",className:"kui-variant",values:s,default:"raised"},error:{type:"boolean"},loading:{type:"boolean"},disabled:{type:"boolean"},readOnly:{type:"boolean"},...e,...o,placeholder:{type:"ReactNode"}},n={...e};export{p as a,i as b,n as c};
|
|
3
|
+
//# sourceMappingURL=chunk-PT4KBXXP.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/components/select.props.tsx"],
|
|
4
4
|
"sourcesContent": ["import type React from 'react';\n\nimport { colorPropDef } from '../props/color.prop.js';\nimport { radiusPropDef } from '../props/radius.prop.js';\n\nimport type { PropDef } from '../props/prop-def.js';\n\nconst sizes = ['1', '2', '3', '4'] as const;\n\nconst selectRootPropDefs = {\n size: { type: 'enum', className: 'kui-r-size', values: sizes, default: '2', responsive: true },\n} satisfies {\n size: PropDef<(typeof sizes)[number]>;\n};\n\nconst triggerVariants = ['raised', 'surface', 'soft', 'outline', 'ghost'] as const;\n\nconst selectTriggerPropDefs = {\n variant: { type: 'enum', className: 'kui-variant', values: triggerVariants, default: 'raised' },\n error: { type: 'boolean' },\n loading: { type: 'boolean' },\n disabled: { type: 'boolean' },\n readOnly: { type: 'boolean' },\n ...colorPropDef,\n ...radiusPropDef,\n placeholder: { type: 'ReactNode' },\n} satisfies {\n variant: PropDef<(typeof triggerVariants)[number]>;\n error: PropDef<boolean>;\n loading: PropDef<boolean>;\n disabled: PropDef<boolean>;\n readOnly: PropDef<boolean>;\n placeholder: PropDef<React.ReactNode>;\n};\n\n\nconst selectContentPropDefs = {\n ...colorPropDef,\n} satisfies {\n};\n\nexport { selectRootPropDefs, selectTriggerPropDefs, selectContentPropDefs };\n"],
|
|
5
|
-
"mappings": "gFAOA,IAAMA,EAAQ,CAAC,IAAK,IAAK,IAAK,GAAG,EAE3BC,EAAqB,CACzB,KAAM,CAAE,KAAM,OAAQ,UAAW,aAAc,OAAQD,EAAO,QAAS,IAAK,WAAY,EAAK,CAC/F,EAIME,EAAkB,CAAC,SAAU,UAAW,OAAQ,UAAW,OAAO,EAElEC,EAAwB,CAC5B,QAAS,CAAE,KAAM,OAAQ,UAAW,cAAe,OAAQD,EAAiB,QAAS,QAAS,EAC9F,MAAO,CAAE,KAAM,SAAU,EACzB,QAAS,CAAE,KAAM,SAAU,EAC3B,SAAU,CAAE,KAAM,SAAU,EAC5B,SAAU,CAAE,KAAM,SAAU,EAC5B,GAAGE,EACH,GAAGC,EACH,YAAa,CAAE,KAAM,WAAY,CACnC,EAUMC,EAAwB,CAC5B,GAAGF,CACL",
|
|
5
|
+
"mappings": ";gFAOA,IAAMA,EAAQ,CAAC,IAAK,IAAK,IAAK,GAAG,EAE3BC,EAAqB,CACzB,KAAM,CAAE,KAAM,OAAQ,UAAW,aAAc,OAAQD,EAAO,QAAS,IAAK,WAAY,EAAK,CAC/F,EAIME,EAAkB,CAAC,SAAU,UAAW,OAAQ,UAAW,OAAO,EAElEC,EAAwB,CAC5B,QAAS,CAAE,KAAM,OAAQ,UAAW,cAAe,OAAQD,EAAiB,QAAS,QAAS,EAC9F,MAAO,CAAE,KAAM,SAAU,EACzB,QAAS,CAAE,KAAM,SAAU,EAC3B,SAAU,CAAE,KAAM,SAAU,EAC5B,SAAU,CAAE,KAAM,SAAU,EAC5B,GAAGE,EACH,GAAGC,EACH,YAAa,CAAE,KAAM,WAAY,CACnC,EAUMC,EAAwB,CAC5B,GAAGF,CACL",
|
|
6
6
|
"names": ["sizes", "selectRootPropDefs", "triggerVariants", "selectTriggerPropDefs", "colorPropDef", "radiusPropDef", "selectContentPropDefs"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{b as s}from"./chunk-XU74PNM2.js";import{a as e}from"./chunk-CLJ6SEGP.js";import{a as t,e as a}from"./chunk-HBWBPBSA.js";var o=["1","2","3","4","5","6","7","8","9"],r=["raised","solid","soft","surface","outline"],n=["cover","contain","fill","scale-down","none"],p={...e,size:{type:"enum",className:"kui-r-size",values:o,default:"2",responsive:!0},variant:{type:"enum",className:"kui-variant",values:r,default:"raised"},...a,...s,fallback:{type:"ReactNode",required:!0},status:{type:"enum",values:t,default:void 0},statusLabel:{type:"string",default:void 0},badge:{type:"ReactNode",default:void 0},fit:{type:"enum",className:"kui-r-fit",values:n,default:"cover",responsive:!0}};export{p as a};
|
|
3
|
+
//# sourceMappingURL=chunk-PZ6Z7WTR.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/components/avatar.props.tsx"],
|
|
4
4
|
"sourcesContent": ["import { asChildPropDef } from '../props/as-child.prop.js';\nimport { grayAccentColorPropDef, accentColors } from '../props/color.prop.js';\nimport { radiusPropDef } from '../props/radius.prop.js';\n\nimport type { PropDef } from '../props/prop-def.js';\n\nconst sizes = ['1', '2', '3', '4', '5', '6', '7', '8', '9'] as const;\nconst variants = ['raised', 'solid', 'soft', 'surface', 'outline'] as const;\nconst objectFitValues = ['cover', 'contain', 'fill', 'scale-down', 'none'] as const;\n\nconst avatarPropDefs = {\n ...asChildPropDef,\n size: { type: 'enum', className: 'kui-r-size', values: sizes, default: '2', responsive: true },\n variant: { type: 'enum', className: 'kui-variant', values: variants, default: 'raised' },\n ...grayAccentColorPropDef,\n ...radiusPropDef,\n fallback: { type: 'ReactNode', required: true },\n /**\n * Status indicator color. Renders a small colored dot at the bottom-right corner.\n * Cannot be used together with `badge`.\n */\n status: { type: 'enum', values: accentColors, default: undefined },\n /**\n * The words the status dot stands for, such as \"Online\". A screen reader reads them with the\n * avatar. Without it the dot is hidden from screen readers.\n */\n statusLabel: { type: 'string', default: undefined },\n /**\n * Custom badge content. Renders at the bottom-right corner.\n * Cannot be used together with `status`.\n */\n badge: { type: 'ReactNode', default: undefined },\n /**\n * Controls how the avatar image should be resized to fit its container.\n * Defaults to 'cover' which crops the image to fill the avatar.\n * Use 'contain' to show the full image without cropping.\n */\n fit: { type: 'enum', className: 'kui-r-fit', values: objectFitValues, default: 'cover', responsive: true },\n} satisfies {\n size: PropDef<(typeof sizes)[number]>;\n variant: PropDef<(typeof variants)[number]>;\n fallback: PropDef<React.ReactNode>;\n status: PropDef<(typeof accentColors)[number] | undefined>;\n statusLabel: PropDef<string | undefined>;\n badge: PropDef<React.ReactNode>;\n fit: PropDef<(typeof objectFitValues)[number]>;\n};\n\nexport { avatarPropDefs };\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": ";+HAMA,IAAMA,EAAQ,CAAC,IAAK,IAAK,IAAK,IAAK,IAAK,IAAK,IAAK,IAAK,GAAG,EACpDC,EAAW,CAAC,SAAU,QAAS,OAAQ,UAAW,SAAS,EAC3DC,EAAkB,CAAC,QAAS,UAAW,OAAQ,aAAc,MAAM,EAEnEC,EAAiB,CACrB,GAAGC,EACH,KAAM,CAAE,KAAM,OAAQ,UAAW,aAAc,OAAQJ,EAAO,QAAS,IAAK,WAAY,EAAK,EAC7F,QAAS,CAAE,KAAM,OAAQ,UAAW,cAAe,OAAQC,EAAU,QAAS,QAAS,EACvF,GAAGI,EACH,GAAGC,EACH,SAAU,CAAE,KAAM,YAAa,SAAU,EAAK,EAK9C,OAAQ,CAAE,KAAM,OAAQ,OAAQC,EAAc,QAAS,MAAU,EAKjE,YAAa,CAAE,KAAM,SAAU,QAAS,MAAU,EAKlD,MAAO,CAAE,KAAM,YAAa,QAAS,MAAU,EAM/C,IAAK,CAAE,KAAM,OAAQ,UAAW,YAAa,OAAQL,EAAiB,QAAS,QAAS,WAAY,EAAK,CAC3G",
|
|
6
6
|
"names": ["sizes", "variants", "objectFitValues", "avatarPropDefs", "asChildPropDef", "grayAccentColorPropDef", "radiusPropDef", "accentColors"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{a as t}from"./chunk-XMHNOIPB.js";import{a as p}from"./chunk-6UZT3ZLO.js";import{c as r}from"./chunk-OKQAVYW4.js";import*as e from"react";import c from"classnames";var l=e.forwardRef((s,n)=>{let{children:o,className:i,color:m,asChild:a,...f}=r(s,t);return e.createElement(p,{...f,"data-accent-color":m,ref:n,asChild:!0,className:c("kui-reset","kui-Link",i)},a?o:e.createElement("a",null,o))});l.displayName="Link";export{l as a};
|
|
3
|
+
//# sourceMappingURL=chunk-PZCQDZVJ.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/components/link.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nimport classNames from 'classnames';\n\nimport { Text } from './text.js';\nimport { extractProps } from '../helpers/extract-props.js';\nimport { linkPropDefs } from './link.props.js';\n\nimport type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js';\nimport type { GetPropDefTypes } from '../props/prop-def.js';\n\ntype LinkElement = React.ElementRef<'a'>;\ntype LinkOwnProps = GetPropDefTypes<typeof linkPropDefs>;\ninterface LinkProps extends ComponentPropsWithout<'a', RemovedProps>, LinkOwnProps {}\nconst Link = React.forwardRef<LinkElement, LinkProps>((props, forwardedRef) => {\n const { children, className, color, asChild, ...linkProps } = extractProps(props, linkPropDefs);\n return (\n <Text\n {...linkProps}\n data-accent-color={color}\n ref={forwardedRef}\n asChild\n className={classNames('kui-reset', 'kui-Link', className)}\n >\n {asChild ? (\n children\n ) : (\n // eslint-disable-next-line jsx-a11y/anchor-is-valid\n <a>{children}</a>\n )}\n </Text>\n );\n});\nLink.displayName = 'Link';\n\nexport { Link };\nexport type { LinkProps };\n"],
|
|
5
|
-
"mappings": "wHAAA,UAAYA,MAAW,QACvB,OAAOC,MAAgB,aAYvB,IAAMC,EAAa,aAAmC,CAACC,EAAOC,IAAiB,CAC7E,GAAM,CAAE,SAAAC,EAAU,UAAAC,EAAW,MAAAC,EAAO,QAAAC,EAAS,GAAGC,CAAU,EAAIC,EAAaP,EAAOQ,CAAY,EAC9F,OACE,gBAACC,EAAA,CACE,GAAGH,EACJ,oBAAmBF,EACnB,IAAKH,EACL,QAAO,GACP,UAAWS,EAAW,YAAa,WAAYP,CAAS,GAEvDE,EACCH,EAGA,gBAAC,SAAGA,CAAS,CAEjB,CAEJ,CAAC,EACDH,EAAK,YAAc",
|
|
5
|
+
"mappings": ";wHAAA,UAAYA,MAAW,QACvB,OAAOC,MAAgB,aAYvB,IAAMC,EAAa,aAAmC,CAACC,EAAOC,IAAiB,CAC7E,GAAM,CAAE,SAAAC,EAAU,UAAAC,EAAW,MAAAC,EAAO,QAAAC,EAAS,GAAGC,CAAU,EAAIC,EAAaP,EAAOQ,CAAY,EAC9F,OACE,gBAACC,EAAA,CACE,GAAGH,EACJ,oBAAmBF,EACnB,IAAKH,EACL,QAAO,GACP,UAAWS,EAAW,YAAa,WAAYP,CAAS,GAEvDE,EACCH,EAGA,gBAAC,SAAGA,CAAS,CAEjB,CAEJ,CAAC,EACDH,EAAK,YAAc",
|
|
6
6
|
"names": ["React", "classNames", "Link", "props", "forwardedRef", "children", "className", "color", "asChild", "linkProps", "extractProps", "linkPropDefs", "Text", "classNames"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import{a as p,b as i}from"./chunk-GKDGNPBD.js";import{c as s}from"./chunk-5ON3XLRD.js";import{a as o}from"./chunk-FM3GBCX5.js";import{c}from"./chunk-OKQAVYW4.js";import*as e from"react";import b from"classnames";import{Checkbox as h}from"radix-ui";import{useControllableState as P}from"radix-ui/internal";var u=e.forwardRef((a,k)=>{let m=s(a,o.size),{className:n,color:C,checked:d,defaultChecked:t,onCheckedChange:f,...l}=c(m,o),[r,x]=P({prop:d,defaultProp:t??!1,onChange:f});return e.createElement(h.Root,{"data-accent-color":C,...l,defaultChecked:t,checked:r,onCheckedChange:x,asChild:!1,ref:k,className:b("kui-reset","kui-BaseCheckboxRoot","kui-CheckboxRoot",n)},e.createElement(h.Indicator,{asChild:!0,className:"kui-BaseCheckboxIndicator kui-CheckboxIndicator"},r==="indeterminate"?e.createElement(p,null):e.createElement(i,null)))});u.displayName="Checkbox";export{u as a};
|
|
3
|
+
//# sourceMappingURL=chunk-PZZJH2LR.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/components/checkbox.tsx"],
|
|
4
|
+
"sourcesContent": ["'use client';\n\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport { Checkbox as CheckboxPrimitive } from 'radix-ui';\nimport { useControllableState } from 'radix-ui/internal';\n\nimport { checkboxPropDefs } from './checkbox.props.js';\nimport { ThickCheckIcon, ThickDividerHorizontalIcon } from './icons.js';\nimport { extractProps } from '../helpers/extract-props.js';\nimport { useThemeSizeProps } from '../hooks/theme-size.js';\n\nimport type { ComponentPropsWithout } from '../helpers/component-props.js';\nimport type { GetPropDefTypes } from '../props/prop-def.js';\n\ntype CheckboxElement = React.ElementRef<typeof CheckboxPrimitive.Root>;\ntype CheckboxOwnProps = GetPropDefTypes<typeof checkboxPropDefs>;\ninterface CheckboxProps\n extends ComponentPropsWithout<\n typeof CheckboxPrimitive.Root,\n 'asChild' | 'color' | 'defaultValue' | 'children'\n >,\n CheckboxOwnProps {}\nconst Checkbox = React.forwardRef<CheckboxElement, CheckboxProps>((ownProps, forwardedRef) => {\n const props = useThemeSizeProps(ownProps, checkboxPropDefs.size);\n const {\n className,\n color,\n checked: checkedProp,\n defaultChecked: defaultCheckedProp,\n onCheckedChange,\n ...checkboxProps\n } = extractProps(props, checkboxPropDefs);\n\n const [checked, setChecked] = useControllableState({\n prop: checkedProp,\n defaultProp: defaultCheckedProp ?? false,\n onChange: onCheckedChange,\n });\n\n return (\n <CheckboxPrimitive.Root\n data-accent-color={color}\n {...checkboxProps}\n defaultChecked={defaultCheckedProp}\n checked={checked}\n onCheckedChange={setChecked}\n asChild={false}\n ref={forwardedRef}\n className={classNames('kui-reset', 'kui-BaseCheckboxRoot', 'kui-CheckboxRoot', className)}\n >\n <CheckboxPrimitive.Indicator\n asChild\n className=\"kui-BaseCheckboxIndicator kui-CheckboxIndicator\"\n >\n {checked === 'indeterminate' ? <ThickDividerHorizontalIcon /> : <ThickCheckIcon />}\n </CheckboxPrimitive.Indicator>\n </CheckboxPrimitive.Root>\n );\n});\nCheckbox.displayName = 'Checkbox';\n\nexport { Checkbox };\nexport type { CheckboxProps };\n"],
|
|
5
|
+
"mappings": ";kKAEA,UAAYA,MAAW,QACvB,OAAOC,MAAgB,aACvB,OAAS,YAAYC,MAAyB,WAC9C,OAAS,wBAAAC,MAA4B,oBAkBrC,IAAMC,EAAiB,aAA2C,CAACC,EAAUC,IAAiB,CAC5F,IAAMC,EAAQC,EAAkBH,EAAUI,EAAiB,IAAI,EACzD,CACJ,UAAAC,EACA,MAAAC,EACA,QAASC,EACT,eAAgBC,EAChB,gBAAAC,EACA,GAAGC,CACL,EAAIC,EAAaT,EAAOE,CAAgB,EAElC,CAACQ,EAASC,CAAU,EAAIC,EAAqB,CACjD,KAAMP,EACN,YAAaC,GAAsB,GACnC,SAAUC,CACZ,CAAC,EAED,OACE,gBAACM,EAAkB,KAAlB,CACC,oBAAmBT,EAClB,GAAGI,EACJ,eAAgBF,EAChB,QAASI,EACT,gBAAiBC,EACjB,QAAS,GACT,IAAKZ,EACL,UAAWe,EAAW,YAAa,uBAAwB,mBAAoBX,CAAS,GAExF,gBAACU,EAAkB,UAAlB,CACC,QAAO,GACP,UAAU,mDAETH,IAAY,gBAAkB,gBAACK,EAAA,IAA2B,EAAK,gBAACC,EAAA,IAAe,CAClF,CACF,CAEJ,CAAC,EACDnB,EAAS,YAAc",
|
|
6
|
+
"names": ["React", "classNames", "CheckboxPrimitive", "useControllableState", "Checkbox", "ownProps", "forwardedRef", "props", "useThemeSizeProps", "baseCheckboxPropDefs", "className", "color", "checkedProp", "defaultCheckedProp", "onCheckedChange", "checkboxProps", "extractProps", "checked", "setChecked", "useControllableState", "CheckboxPrimitive", "classNames", "ThickDividerHorizontalIcon", "ThickCheckIcon"]
|
|
7
|
+
}
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{h as p,i as b,k as M}from"./chunk-GHWEXMF6.js";import{b as P}from"./chunk-G66WDIIV.js";import*as o from"react";var S=e=>e===void 0?void 0:e==="closed"?"collapsed":"expanded",f=e=>e==="collapsed"?"closed":"open",s=e=>e===void 0||e==="closed"?"collapsed":"expanded",l=e=>e==="left"?"rail":e;function v(e){let d=o.useCallback(r=>p(e,r),[e]);return o.useSyncExternalStore(d,()=>e.version,()=>0)}function V(){let e=M("useSidebarMode"),d=o.useCallback(t=>p(e,t),[e]),r=o.useSyncExternalStore(d,()=>e.entries.get("sidebar")?.value,()=>{}),i=o.useCallback(t=>{e.entries.get("sidebar")?.setValue(f(t),"toggle")},[e]);return{sidebarMode:S(r)??"expanded",setSidebarMode:i}}var g=()=>{};function x(){let e=M("useShell");o.useEffect(()=>{},[]),v(e);let{breakpoint:d,ready:r}=P(),i=o.useMemo(()=>{let n=a=>m=>e.entries.get(a)?.setValue(m==="collapsed"?"closed":"open","toggle"),u=a=>b(e,a===null?null:l(a));return{setLeftMode:n("rail"),setPanelMode:n("panel"),setInspectorMode:n("inspector"),setBottomMode:n("bottom"),setSidebarMode:a=>e.entries.get("sidebar")?.setValue(f(a),"toggle"),setPeekTarget:u,peekPane:a=>u(a),clearPeek:()=>u(null),setHasLeft:g,setHasSidebar:g,togglePane:a=>e.entries.get(l(a))?.toggle("toggle"),expandPane:a=>e.entries.get(l(a))?.setValue("open","toggle"),collapsePane:a=>e.entries.get(l(a))?.setValue("closed","toggle")}},[e]),t=n=>e.entries.get(n)?.value,c=e.entries.get("rail");return{leftMode:s(t("rail")),leftControlledOpen:c?.value===void 0?void 0:c.value!=="closed",panelMode:s(t("panel")),sidebarMode:S(t("sidebar"))??"expanded",inspectorMode:s(t("inspector")),bottomMode:s(t("bottom")),peekTarget:e.peek,hasLeft:e.entries.has("rail"),hasSidebar:e.entries.has("sidebar"),currentBreakpoint:d,currentBreakpointReady:r,leftResolvedPresentation:c?.presentation,...i}}export{V as a,x as b};
|
|
3
|
+
//# sourceMappingURL=chunk-QH64BDXO.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/components/shell.context.tsx"],
|
|
4
4
|
"sourcesContent": ["'use client';\n\n/**\n * Since 0.8.0 the Shell has two contexts: the pane registry (the store) and\n * the inset set. They live in `_internal/shell-store.tsx`. This module keeps\n * the two hooks consumers can reach: `useSidebarMode`, and the deprecated\n * `useShell`.\n */\nimport * as React from 'react';\nimport { useBreakpoint } from '../hooks/use-breakpoint.js';\nimport type { Breakpoint, PaneMode, PaneName, PaneTarget, PresentationValue, SidebarMode } from './shell.types.js';\nimport { setShellPeek, subscribeShellStore, useShellStore, warnOnce, type PaneValue, type ShellStore } from './_internal/shell-store.js';\n\nconst toSidebarMode = (value: PaneValue | undefined): SidebarMode | undefined => (value === undefined ? undefined : value === 'closed' ? 'collapsed' : 'expanded');\n\nconst fromSidebarMode = (mode: SidebarMode): PaneValue => (mode === 'collapsed' ? 'closed' : 'open');\n\nconst toPaneMode = (value: PaneValue | undefined): PaneMode => (value === undefined || value === 'closed' ? 'collapsed' : 'expanded');\n\nconst paneName = (target: PaneTarget): PaneName => (target === 'left' ? 'rail' : target);\n\n/** Re-renders on every change to the registry. For the deprecated whole-shell reader only. */\nfunction useStoreVersion(store: ShellStore) {\n const subscribe = React.useCallback((listener: () => void) => subscribeShellStore(store, listener), [store]);\n return React.useSyncExternalStore(\n subscribe,\n () => store.version,\n () => 0,\n );\n}\n\n/**\n * The Sidebar's mode, and a setter. The setter is a user action: it reports\n * through the Sidebar's `onStateChange` the way a Trigger does.\n */\nexport function useSidebarMode(): { sidebarMode: SidebarMode; setSidebarMode: (mode: SidebarMode) => void } {\n const store = useShellStore('useSidebarMode');\n const subscribe = React.useCallback((listener: () => void) => subscribeShellStore(store, listener), [store]);\n const value = React.useSyncExternalStore(\n subscribe,\n () => store.entries.get('sidebar')?.value,\n () => undefined,\n );\n const setSidebarMode = React.useCallback(\n (mode: SidebarMode) => {\n store.entries.get('sidebar')?.setValue(fromSidebarMode(mode), 'toggle');\n },\n [store],\n );\n return { sidebarMode: toSidebarMode(value) ?? 'expanded', setSidebarMode };\n}\n\nexport interface ShellContextValue {\n leftMode: PaneMode;\n setLeftMode: (mode: PaneMode) => void;\n /** The Rail's open state, resolved, when it is controlled. */\n leftControlledOpen?: boolean;\n panelMode: PaneMode;\n setPanelMode: (mode: PaneMode) => void;\n sidebarMode: SidebarMode;\n setSidebarMode: (mode: SidebarMode) => void;\n inspectorMode: PaneMode;\n setInspectorMode: (mode: PaneMode) => void;\n bottomMode: PaneMode;\n setBottomMode: (mode: PaneMode) => void;\n peekTarget: PaneTarget | null;\n setPeekTarget: (target: PaneTarget | null) => void;\n peekPane: (target: PaneTarget) => void;\n clearPeek: () => void;\n /** Whether a Rail is mounted. */\n hasLeft: boolean;\n /** No effect since 0.8.0: the registry knows which panes are mounted. */\n setHasLeft: (has: boolean) => void;\n /** Whether a Sidebar is mounted. */\n hasSidebar: boolean;\n /** No effect since 0.8.0: the registry knows which panes are mounted. */\n setHasSidebar: (has: boolean) => void;\n currentBreakpoint: Breakpoint;\n currentBreakpointReady: boolean;\n /** The Rail's presentation at the current breakpoint, when known. */\n leftResolvedPresentation?: PresentationValue;\n togglePane: (target: PaneTarget) => void;\n expandPane: (target: PaneTarget) => void;\n collapsePane: (target: PaneTarget) => void;\n}\n\nconst noop = () => {};\n\n/**\n * @deprecated The whole-shell reader re-renders its consumer on every change\n * to any pane. Use `Shell.Trigger` to drive a pane, `Shell.useSidebarMode`\n * for the Sidebar, and each pane's `open`/`onOpenChange` for its state.\n * Removed in 1.0.\n *\n * Keeps 0.7's shape. The setters act as a user would: they report through\n * the pane's own callback with `reason: 'toggle'`, and a controlled pane\n * changes only when the app passes the new value.\n */\nexport function useShell(): ShellContextValue {\n const store = useShellStore('useShell');\n React.useEffect(() => {\n warnOnce(\"Shell.useShell is deprecated and is removed in 1.0. Use Shell.Trigger, Shell.useSidebarMode, or a pane's own open/onOpenChange.\");\n }, []);\n useStoreVersion(store);\n const { breakpoint, ready } = useBreakpoint();\n const actions = React.useMemo(() => {\n const setMode = (name: PaneName) => (mode: PaneMode) => store.entries.get(name)?.setValue(mode === 'collapsed' ? 'closed' : 'open', 'toggle');\n const setPeekTarget = (target: PaneTarget | null) => setShellPeek(store, target === null ? null : paneName(target));\n return {\n setLeftMode: setMode('rail'),\n setPanelMode: setMode('panel'),\n setInspectorMode: setMode('inspector'),\n setBottomMode: setMode('bottom'),\n setSidebarMode: (mode: SidebarMode) => store.entries.get('sidebar')?.setValue(fromSidebarMode(mode), 'toggle'),\n setPeekTarget,\n peekPane: (target: PaneTarget) => setPeekTarget(target),\n clearPeek: () => setPeekTarget(null),\n setHasLeft: noop,\n setHasSidebar: noop,\n togglePane: (target: PaneTarget) => store.entries.get(paneName(target))?.toggle('toggle'),\n expandPane: (target: PaneTarget) => store.entries.get(paneName(target))?.setValue('open', 'toggle'),\n collapsePane: (target: PaneTarget) => store.entries.get(paneName(target))?.setValue('closed', 'toggle'),\n };\n }, [store]);\n const value = (name: PaneName) => store.entries.get(name)?.value;\n const rail = store.entries.get('rail');\n return {\n leftMode: toPaneMode(value('rail')),\n leftControlledOpen: rail?.value === undefined ? undefined : rail.value !== 'closed',\n panelMode: toPaneMode(value('panel')),\n sidebarMode: toSidebarMode(value('sidebar')) ?? 'expanded',\n inspectorMode: toPaneMode(value('inspector')),\n bottomMode: toPaneMode(value('bottom')),\n peekTarget: store.peek,\n hasLeft: store.entries.has('rail'),\n hasSidebar: store.entries.has('sidebar'),\n currentBreakpoint: breakpoint,\n currentBreakpointReady: ready,\n leftResolvedPresentation: rail?.presentation,\n ...actions,\n };\n}\n"],
|
|
5
|
-
"mappings": "8FAQA,UAAYA,MAAW,QAKvB,IAAMC,EAAiBC,GAA2DA,IAAU,OAAY,OAAYA,IAAU,SAAW,YAAc,WAEjJC,EAAmBC,GAAkCA,IAAS,YAAc,SAAW,OAEvFC,EAAcH,GAA4CA,IAAU,QAAaA,IAAU,SAAW,YAAc,WAEpHI,EAAYC,GAAkCA,IAAW,OAAS,OAASA,EAGjF,SAASC,EAAgBC,EAAmB,CAC1C,IAAMC,EAAkB,cAAaC,GAAyBC,EAAoBH,EAAOE,CAAQ,EAAG,CAACF,CAAK,CAAC,EAC3G,OAAa,uBACXC,EACA,IAAMD,EAAM,QACZ,IAAM,CACR,CACF,CAMO,SAASI,GAA4F,CAC1G,IAAMJ,EAAQK,EAAc,gBAAgB,EACtCJ,EAAkB,cAAaC,GAAyBC,EAAoBH,EAAOE,CAAQ,EAAG,CAACF,CAAK,CAAC,EACrGP,EAAc,uBAClBQ,EACA,IAAMD,EAAM,QAAQ,IAAI,SAAS,GAAG,MACpC,IAAG,EACL,EACMM,EAAuB,cAC1BX,GAAsB,CACrBK,EAAM,QAAQ,IAAI,SAAS,GAAG,SAASN,EAAgB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MAAM,CAAC,EAClC,mBAAoBwB,GAAM,QAAU,OAAY,OAAYA,EAAK,QAAU,SAC3E,UAAWrB,EAAWH,EAAM,OAAO,CAAC,EACpC,YAAaD,EAAcC,EAAM,SAAS,CAAC,GAAK,WAChD,cAAeG,EAAWH,EAAM,WAAW,CAAC,EAC5C,WAAYG,EAAWH,EAAM,QAAQ,CAAC,EACtC,WAAYO,EAAM,KAClB,QAASA,EAAM,QAAQ,IAAI,MAAM,EACjC,WAAYA,EAAM,QAAQ,IAAI,SAAS,EACvC,kBAAmBS,EACnB,uBAAwBC,EACxB,yBAA0BO,GAAM,aAChC,GAAGL,CACL,CACF",
|
|
6
6
|
"names": ["React", "toSidebarMode", "value", "fromSidebarMode", "mode", "toPaneMode", "paneName", "target", "useStoreVersion", "store", "subscribe", "listener", "subscribeShellStore", "useSidebarMode", "useShellStore", "setSidebarMode", "noop", "useShell", "breakpoint", "ready", "useBreakpoint", "actions", "setMode", "name", "setPeekTarget", "setShellPeek", "rail"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import*as t from"react";import{useLayoutEffect as h}from"radix-ui/internal";function I(e,o="horizontal"){if(e==null)return;if(typeof e=="number"&&Number.isFinite(e))return e;let i=String(e).trim();if(!i)return;if(i.endsWith("px"))return Number.parseFloat(i);if(i.endsWith("rem")){let u=Number.parseFloat(getComputedStyle(document.documentElement).fontSize||"16")||16;return Number.parseFloat(i)*u}if(i.endsWith("%")){let u=Number.parseFloat(i),a=o==="horizontal"?document.documentElement.clientWidth||window.innerWidth||0:document.documentElement.clientHeight||window.innerHeight||0;return u/100*a}let l=Number.parseFloat(i);return Number.isFinite(l)?l:void 0}var S=(e,o,i)=>Math.max(o??e,Math.min(i??e,e));function D(e,o,i,l){let[u]=t.useState(()=>{let a=e??o;return typeof a=="number"&&Number.isFinite(a)?`${S(a,i,l)}px`:void 0});return u}function H(e){let{name:o,elementRef:i,cssVarName:l,orientation:u,minSize:a,maxSize:m,resizable:x,size:g,defaultSize:C,paneId:y,persistence:q}=e,s=t.useRef(e);h(()=>{s.current=e});let b=t.useRef(null),P=t.useRef(0);t.useEffect(()=>()=>{b.current&&clearTimeout(b.current)},[]);let p=t.useCallback((n,r)=>{let{onSizeChange:c,sizeUpdate:d,sizeUpdateMs:R}=s.current;if(c){if(d==="debounce"){b.current&&clearTimeout(b.current),b.current=setTimeout(()=>{b.current=null,s.current.onSizeChange?.(n,r)},R);return}if(d==="throttle"){let V=Date.now();if(V-P.current<R)return;P.current=V}c(n,r)}},[]),w=t.useCallback(n=>I(n,u==="vertical"?"horizontal":"vertical"),[u]),N=t.useRef(!1),f=t.useCallback((n,r)=>{let c=i.current;if(c){c.style.setProperty(l,`${n}px`);for(let d of c.querySelectorAll(":scope > .kui-ShellResizer"))d.setAttribute("aria-valuenow",String(Math.round(n)));r&&(N.current=!0)}},[i,l]);h(()=>{N.current||f(e.expandedSize,!1)},[e.expandedSize,f]),h(()=>{if(g!==void 0||C===void 0)return;let n=w(C);if(typeof n!="number"||!Number.isFinite(n))return;let r=S(n,a,m);f(r,!0),p(r,{reason:"init"})},[]),h(()=>{if(g===void 0||s.current.overlayingNow())return;let n=w(g);if(typeof n!="number"||!Number.isFinite(n))return;let r=S(n,a,m);f(r,!0),p(r,{reason:"controlled"})},[g,a,m,e.overlaying,w,f,p]);let T=q!==void 0,z=t.useMemo(()=>{if(T)return{load:()=>s.current.persistence?.load?.(),save:r=>s.current.persistence?.save?.(r)};if(!y)return;let n=`kookie-ui:shell:${o}:${y}`;return{load:()=>{if(!(typeof window>"u"))try{let r=window.localStorage.getItem(n);return r?Number(r):void 0}catch{return}},save:r=>{if(!(typeof window>"u"))try{window.localStorage.setItem(n,String(r))}catch{}}}},[o,y,T]);h(()=>{if(!x||!z?.load||s.current.overlayingNow())return;let n=!0,r=d=>{if(!n||typeof d!="number"||!Number.isFinite(d))return;let R=S(d,a,m);f(R,!0),s.current.onResize?.(R)},c=z.load();return c instanceof Promise?c.then(r).catch(d=>{}):r(c),()=>{n=!1}},[x,z,e.overlaying,f,a,m,o]);let E=t.useCallback(n=>s.current.onResize?.(n),[]),v=t.useCallback(n=>{N.current=!0,s.current.onResizeStart?.(n)},[]),k=t.useCallback(n=>{s.current.onResizeEnd?.(n),p(n,{reason:"resize"}),z?.save?.(n)},[p,z]),F=t.useCallback(()=>s.current.requestCollapse(),[]),M=t.useCallback(()=>s.current.requestToggle(),[]);return t.useMemo(()=>({containerRef:i,controls:e.elementId,cssVarName:l,minSize:a,maxSize:m,defaultSize:e.expandedSize,orientation:u,edge:e.edge,growth:e.growth,onResize:E,onResizeStart:v,onResizeEnd:k,target:o,collapsible:e.collapsible,snapPoints:e.snapPoints,snapTolerance:e.snapTolerance??8,collapseThreshold:e.collapseThreshold,requestCollapse:F,requestToggle:M}),[i,e.elementId,l,a,m,e.expandedSize,u,e.edge,e.growth,E,v,k,o,e.collapsible,e.snapPoints,e.snapTolerance,e.collapseThreshold,F,M])}function U(e,o){let i=t.Children.toArray(e),l=i.filter(a=>t.isValidElement(a)&&a.type===o),u=i.filter(a=>!(t.isValidElement(a)&&a.type===o));return{handles:l,content:u}}export{D as a,H as b,U as c};
|
|
3
|
+
//# sourceMappingURL=chunk-QKCNGEX4.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/components/_internal/shell-resizable.tsx", "../../src/helpers/normalize-to-px.ts"],
|
|
4
|
+
"sourcesContent": ["'use client';\n\nimport * as React from 'react';\nimport { useLayoutEffect } from 'radix-ui/internal';\nimport { normalizeToPx } from '../../helpers/normalize-to-px.js';\nimport type { PaneName, PaneSizePersistence } from '../shell.types.js';\nimport type { PaneResizeContextValue } from './shell-resize.js';\n\nexport type SizeChangeMeta = { reason: 'init' | 'resize' | 'controlled' };\n\nexport type ResizableOptions = {\n name: PaneName;\n /** The pane's element id, which the handle names in `aria-controls`. */\n elementId: string;\n elementRef: React.RefObject<HTMLElement | null>;\n cssVarName: string;\n orientation: 'vertical' | 'horizontal';\n edge: 'start' | 'end';\n growth: (isRtl: boolean) => 1 | -1;\n expandedSize: number;\n minSize: number;\n maxSize: number;\n resizable: boolean;\n collapsible: boolean;\n size: number | string | undefined;\n defaultSize: number | string | undefined;\n onSizeChange: ((size: number, meta: SizeChangeMeta) => void) | undefined;\n sizeUpdate: 'throttle' | 'debounce' | undefined;\n sizeUpdateMs: number;\n onResize: ((size: number) => void) | undefined;\n onResizeStart: ((size: number) => void) | undefined;\n onResizeEnd: ((size: number) => void) | undefined;\n snapPoints: number[] | undefined;\n snapTolerance: number | undefined;\n collapseThreshold: number | undefined;\n paneId: string | undefined;\n persistence: PaneSizePersistence | undefined;\n /** Whether the pane is presented as an overlay right now. An overlay keeps its designed size and persists nothing. */\n overlaying: boolean;\n /** The same question asked at effect time, for a pane whose presentation is learnt after its first render. */\n overlayingNow: () => boolean;\n requestCollapse: () => void;\n requestToggle: () => void;\n};\n\n/**\n * Clamps to [min, max]. When the two cross (an app passing a maximum computed\n * from a narrow window below its fixed minimum), the minimum wins, as it did\n * in 0.7.\n */\nconst clampTo = (value: number, min: number | undefined, max: number | undefined) => Math.max(min ?? value, Math.min(max ?? value, value));\n\n/**\n * The pane's starting size for the first render, so the server HTML already has it and the first\n * paint is right. Only a number can be known before the pane exists (a percentage needs the\n * Shell's width); the effects below still own the size after mount.\n */\nexport function useInitialPaneSize(size: number | string | undefined, defaultSize: number | string | undefined, minSize: number, maxSize: number) {\n const [initial] = React.useState(() => {\n const value = size ?? defaultSize;\n return typeof value === 'number' && Number.isFinite(value) ? `${clampTo(value, minSize, maxSize)}px` : undefined;\n });\n return initial;\n}\n\n/** Everything a resizable pane shares: size props, persistence, and the handle's context. */\nexport function useResizablePane(options: ResizableOptions): PaneResizeContextValue {\n const { name, elementRef, cssVarName, orientation, minSize, maxSize, resizable, size, defaultSize, paneId, persistence } = options;\n\n // The latest callbacks, so the size emitter does not change identity when a\n // consumer passes an inline function. A controlled `size` is reported again\n // only when the size, the minimum or the maximum changes.\n const latest = React.useRef(options);\n useLayoutEffect(() => {\n latest.current = options;\n });\n\n const debounceRef = React.useRef<ReturnType<typeof setTimeout> | null>(null);\n const throttleRef = React.useRef(0);\n React.useEffect(\n () => () => {\n if (debounceRef.current) clearTimeout(debounceRef.current);\n },\n [],\n );\n const emitSizeChange = React.useCallback((value: number, meta: SizeChangeMeta) => {\n const { onSizeChange, sizeUpdate, sizeUpdateMs } = latest.current;\n if (!onSizeChange) return;\n if (sizeUpdate === 'debounce') {\n if (debounceRef.current) clearTimeout(debounceRef.current);\n debounceRef.current = setTimeout(() => {\n debounceRef.current = null;\n latest.current.onSizeChange?.(value, meta);\n }, sizeUpdateMs);\n return;\n }\n if (sizeUpdate === 'throttle') {\n const now = Date.now();\n if (now - throttleRef.current < sizeUpdateMs) return;\n throttleRef.current = now;\n }\n onSizeChange(value, meta);\n }, []);\n\n const toPx = React.useCallback((value: number | string | undefined) => normalizeToPx(value, orientation === 'vertical' ? 'horizontal' : 'vertical'), [orientation]);\n\n /**\n * The one way a size reaches the pane: the size variable, and the value\n * every handle of this pane announces. Once anything but `expandedSize` has\n * written a size (a default, a controlled value, a persisted value or a\n * resize), the pane owns that size and a new `expandedSize` leaves it alone.\n */\n const ownedRef = React.useRef(false);\n const writeSize = React.useCallback(\n (value: number, own: boolean) => {\n const el = elementRef.current;\n if (!el) return;\n el.style.setProperty(cssVarName, `${value}px`);\n for (const handle of el.querySelectorAll(':scope > .kui-ShellResizer')) handle.setAttribute('aria-valuenow', String(Math.round(value)));\n if (own) ownedRef.current = true;\n },\n [elementRef, cssVarName],\n );\n\n // expandedSize: the size until something else sets one. Declared first, so\n // the effects below win on mount.\n useLayoutEffect(() => {\n if (!ownedRef.current) writeSize(options.expandedSize, false);\n }, [options.expandedSize, writeSize]);\n\n // defaultSize: applied once, on mount.\n useLayoutEffect(() => {\n if (size !== undefined || defaultSize === undefined) return;\n const px = toPx(defaultSize);\n if (typeof px !== 'number' || !Number.isFinite(px)) return;\n const clamped = clampTo(px, minSize, maxSize);\n writeSize(clamped, true);\n emitSizeChange(clamped, { reason: 'init' });\n // An uncontrolled initial value: applied on mount and never re-applied.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n // Controlled size. A drag stands until the app passes a different value.\n // Not while the pane is an overlay: an overlay keeps its designed size, and\n // an app's frame-sized limits (a maximum taken from the window) would\n // otherwise squeeze the drawer and report the squeezed size back. The size\n // is applied again when the pane returns to the frame.\n useLayoutEffect(() => {\n if (size === undefined || latest.current.overlayingNow()) return;\n const px = toPx(size);\n if (typeof px !== 'number' || !Number.isFinite(px)) return;\n const clamped = clampTo(px, minSize, maxSize);\n writeSize(clamped, true);\n emitSizeChange(clamped, { reason: 'controlled' });\n }, [size, minSize, maxSize, options.overlaying, toPx, writeSize, emitSizeChange]);\n\n // A persistence adapter from `paneId` when none is given. A given one is read through\n // `latest`, so an inline object (the documented shape) does not reload the size every render.\n const hasPersistence = persistence !== undefined;\n const adapter = React.useMemo<PaneSizePersistence | undefined>(() => {\n if (hasPersistence) {\n return {\n load: () => latest.current.persistence?.load?.(),\n save: (value: number) => latest.current.persistence?.save?.(value),\n };\n }\n if (!paneId) return undefined;\n const key = `kookie-ui:shell:${name}:${paneId}`;\n return {\n load: () => {\n if (typeof window === 'undefined') return undefined;\n try {\n const stored = window.localStorage.getItem(key);\n return stored ? Number(stored) : undefined;\n } catch (err) {\n if (process.env.NODE_ENV !== 'production') console.warn(`Shell.${name}: failed to load persisted size`, err);\n return undefined;\n }\n },\n save: (value: number) => {\n if (typeof window === 'undefined') return;\n try {\n window.localStorage.setItem(key, String(value));\n } catch (err) {\n if (process.env.NODE_ENV !== 'production') console.warn(`Shell.${name}: failed to save persisted size`, err);\n }\n },\n };\n }, [name, paneId, hasPersistence]);\n\n // Persisted size, loaded in a layout effect and clamped, so a reload does\n // not paint the default and then jump. Only where the pane is in the frame:\n // an overlay keeps its designed size.\n useLayoutEffect(() => {\n if (!resizable || !adapter?.load || latest.current.overlayingNow()) return undefined;\n let mounted = true;\n const apply = (value: number | undefined) => {\n if (!mounted || typeof value !== 'number' || !Number.isFinite(value)) return;\n const clamped = clampTo(value, minSize, maxSize);\n writeSize(clamped, true);\n latest.current.onResize?.(clamped);\n };\n const loaded = adapter.load();\n if (loaded instanceof Promise) {\n loaded.then(apply).catch((err) => {\n if (process.env.NODE_ENV !== 'production') console.warn(`Shell.${name}: failed to load persisted size`, err);\n });\n } else {\n apply(loaded);\n }\n return () => {\n mounted = false;\n };\n }, [resizable, adapter, options.overlaying, writeSize, minSize, maxSize, name]);\n\n const onResize = React.useCallback((value: number) => latest.current.onResize?.(value), []);\n const onResizeStart = React.useCallback((value: number) => {\n // A resize makes the size the user's: a new expandedSize no longer moves it.\n ownedRef.current = true;\n latest.current.onResizeStart?.(value);\n }, []);\n const onResizeEnd = React.useCallback(\n (value: number) => {\n latest.current.onResizeEnd?.(value);\n emitSizeChange(value, { reason: 'resize' });\n adapter?.save?.(value);\n },\n [emitSizeChange, adapter],\n );\n const requestCollapse = React.useCallback(() => latest.current.requestCollapse(), []);\n const requestToggle = React.useCallback(() => latest.current.requestToggle(), []);\n\n return React.useMemo(\n () => ({\n containerRef: elementRef,\n controls: options.elementId,\n cssVarName,\n minSize,\n maxSize,\n defaultSize: options.expandedSize,\n orientation,\n edge: options.edge,\n growth: options.growth,\n onResize,\n onResizeStart,\n onResizeEnd,\n target: name,\n collapsible: options.collapsible,\n snapPoints: options.snapPoints,\n snapTolerance: options.snapTolerance ?? 8,\n collapseThreshold: options.collapseThreshold,\n requestCollapse,\n requestToggle,\n }),\n [\n elementRef,\n options.elementId,\n cssVarName,\n minSize,\n maxSize,\n options.expandedSize,\n orientation,\n options.edge,\n options.growth,\n onResize,\n onResizeStart,\n onResizeEnd,\n name,\n options.collapsible,\n options.snapPoints,\n options.snapTolerance,\n options.collapseThreshold,\n requestCollapse,\n requestToggle,\n ],\n );\n}\n\n/** Splits a pane's children into its handles and the rest. */\nexport function splitHandles(children: React.ReactNode, handleType: React.ElementType) {\n const all = React.Children.toArray(children);\n const handles = all.filter((el) => React.isValidElement(el) && el.type === handleType) as React.ReactElement[];\n const content = all.filter((el) => !(React.isValidElement(el) && el.type === handleType));\n return { handles, content };\n}\n", "/**\n * Normalize CSS length values to pixels.\n * Supports: px, rem, %, and bare numbers.\n *\n * @param value - The value to normalize (number, string, or undefined)\n * @param orientation - 'horizontal' for width-based % or 'vertical' for height-based %\n * @returns The value in pixels, or undefined if invalid\n */\nexport function normalizeToPx(\n value: number | string | undefined,\n orientation: 'horizontal' | 'vertical' = 'horizontal',\n): number | undefined {\n if (value == null) return undefined;\n if (typeof value === 'number' && Number.isFinite(value)) return value;\n\n const str = String(value).trim();\n if (!str) return undefined;\n\n // px: direct parse\n if (str.endsWith('px')) return Number.parseFloat(str);\n\n // rem: multiply by root font size\n if (str.endsWith('rem')) {\n const rem = Number.parseFloat(getComputedStyle(document.documentElement).fontSize || '16') || 16;\n return Number.parseFloat(str) * rem;\n }\n\n // %: calculate based on viewport dimension\n if (str.endsWith('%')) {\n const pct = Number.parseFloat(str);\n const base =\n orientation === 'horizontal'\n ? document.documentElement.clientWidth || window.innerWidth || 0\n : document.documentElement.clientHeight || window.innerHeight || 0;\n return (pct / 100) * base;\n }\n\n // Bare number-like string\n const n = Number.parseFloat(str);\n return Number.isFinite(n) ? n : undefined;\n}\n\n"],
|
|
5
|
+
"mappings": ";AAEA,UAAYA,MAAW,QACvB,OAAS,mBAAAC,MAAuB,oBCKzB,SAASC,EACdC,EACAC,EAAyC,aACrB,CACpB,GAAID,GAAS,KAAM,OACnB,GAAI,OAAOA,GAAU,UAAY,OAAO,SAASA,CAAK,EAAG,OAAOA,EAEhE,IAAME,EAAM,OAAOF,CAAK,EAAE,KAAK,EAC/B,GAAI,CAACE,EAAK,OAGV,GAAIA,EAAI,SAAS,IAAI,EAAG,OAAO,OAAO,WAAWA,CAAG,EAGpD,GAAIA,EAAI,SAAS,KA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,WAAYA,EAAQ,WACpB,cAAeA,EAAQ,eAAiB,EACxC,kBAAmBA,EAAQ,kBAC3B,gBAAAsC,EACA,cAAAC,CACF,GACA,CACErC,EACAF,EAAQ,UACRG,EACAP,EACAC,EACAG,EAAQ,aACRI,EACAJ,EAAQ,KACRA,EAAQ,OACRmC,EACAC,EACAC,EACApC,EACAD,EAAQ,YACRA,EAAQ,WACRA,EAAQ,cACRA,EAAQ,kBACRsC,EACAC,CACF,CACF,CACF,CAGO,SAASC,EAAaC,EAA2BC,EAA+B,CACrF,IAAMC,EAAY,WAAS,QAAQF,CAAQ,EACrCG,EAAUD,EAAI,OAAQpB,GAAa,iBAAeA,CAAE,GAAKA,EAAG,OAASmB,CAAU,EAC/EG,EAAUF,EAAI,OAAQpB,GAAO,EAAQ,iBAAeA,CAAE,GAAKA,EAAG,OAASmB,EAAW,EACxF,MAAO,CAAE,QAAAE,EAAS,QAAAC,CAAQ,CAC5B",
|
|
6
|
+
"names": ["React", "useLayoutEffect", "normalizeToPx", "value", "orientation", "str", "rem", "pct", "base", "n", "clampTo", "value", "min", "max", "useInitialPaneSize", "size", "defaultSize", "minSize", "maxSize", "initial", "useResizablePane", "options", "name", "elementRef", "cssVarName", "orientation", "resizable", "paneId", "persistence", "latest", "useLayoutEffect", "debounceRef", "throttleRef", "emitSizeChange", "meta", "onSizeChange", "sizeUpdate", "sizeUpdateMs", "now", "toPx", "normalizeToPx", "ownedRef", "writeSize", "own", "el", "handle", "px", "clamped", "hasPersistence", "adapter", "key", "stored", "mounted", "apply", "loaded", "err", "onResize", "onResizeStart", "onResizeEnd", "requestCollapse", "requestToggle", "splitHandles", "children", "handleType", "all", "handles", "content"]
|
|
7
|
+
}
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{b as r}from"./chunk-XU74PNM2.js";import{c as e}from"./chunk-HBWBPBSA.js";var s=["1","2","3","4"],a=["raised","surface","soft","outline","ghost"],o=["none","vertical","horizontal","both"],n={size:{type:"enum",className:"kui-r-size",values:s,default:"2",responsive:!0},variant:{type:"enum",className:"kui-variant",values:a,default:"raised"},resize:{type:"enum",className:"kui-r-resize",values:o,responsive:!0},error:{type:"boolean",default:!1},errorMessage:{type:"string",default:void 0},required:{type:"boolean",default:!1},"aria-describedby":{type:"string",default:void 0},"aria-labelledby":{type:"string",default:void 0},...e,...r};export{n as a};
|
|
3
|
+
//# sourceMappingURL=chunk-QQY4WFJL.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/components/text-area.props.tsx"],
|
|
4
4
|
"sourcesContent": ["import { colorPropDef } from '../props/color.prop.js';\nimport { radiusPropDef } from '../props/radius.prop.js';\n\nimport type { PropDef } from '../props/prop-def.js';\n\nconst sizes = ['1', '2', '3', '4'] as const;\nconst variants = ['raised', 'surface', 'soft', 'outline', 'ghost'] as const;\nconst resizeValues = ['none', 'vertical', 'horizontal', 'both'] as const;\n\n// prettier-ignore\nconst textAreaPropDefs = {\n size: { type: 'enum', className: 'kui-r-size', values: sizes, default: '2', responsive: true },\n variant: { type: 'enum', className: 'kui-variant', values: variants, default: 'raised' },\n resize: { type: 'enum', className: 'kui-r-resize', values: resizeValues, responsive: true },\n // Error and validation props\n error: { type: 'boolean', default: false },\n errorMessage: { type: 'string', default: undefined },\n required: { type: 'boolean', default: false },\n // Accessibility props\n 'aria-describedby': { type: 'string', default: undefined },\n 'aria-labelledby': { type: 'string', default: undefined },\n ...colorPropDef,\n ...radiusPropDef,\n} satisfies {\n size: PropDef<(typeof sizes)[number]>;\n variant: PropDef<(typeof variants)[number]>;\n resize: PropDef<(typeof resizeValues)[number]>;\n error: PropDef<boolean>;\n errorMessage: PropDef<string | undefined>;\n required: PropDef<boolean>;\n 'aria-describedby': PropDef<string | undefined>;\n 'aria-labelledby': PropDef<string | undefined>;\n};\n\nexport { textAreaPropDefs };\n"],
|
|
5
|
-
"mappings": "gFAKA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AM,SAAU,QAAS,MAAU,EACxD,GAAGE,EACH,GAAGC,CACL",
|
|
6
6
|
"names": ["sizes", "variants", "resizeValues", "textAreaPropDefs", "colorPropDef", "radiusPropDef"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{a as d}from"./chunk-5TJH35TF.js";import{a as m}from"./chunk-XH2CRCXR.js";import{a as E}from"./chunk-VQPANPMI.js";var L={};E(L,{Button:()=>R,Content:()=>M,Item:()=>P,Root:()=>S,Viewport:()=>g,useMessageScroller:()=>f,useMessageScrollerScrollable:()=>V,useMessageScrollerVisibility:()=>N});import*as e from"react";import c from"classnames";import{MessageScroller as a,useMessageScroller as f,useMessageScrollerScrollable as V,useMessageScrollerVisibility as N}from"@shadcn/react/message-scroller";import{useComposedRefs as T}from"radix-ui/internal";var S=e.forwardRef(({autoScroll:o=!0,defaultScrollPosition:t="end",scrollEdgeThreshold:r,scrollMargin:s,className:n,children:i,...l},u)=>e.createElement(a.Provider,{autoScroll:o,defaultScrollPosition:t,...r!=null?{scrollEdgeThreshold:r}:{},...s!=null?{scrollMargin:s}:{}},e.createElement(a.Root,{...l,ref:u,className:c("kui-MessageScrollerRoot",n)},i)));S.displayName="MessageScroller.Root";var g=e.forwardRef(({className:o,"aria-label":t,fade:r=!0,...s},n)=>{let i=m(r),l=T(n,i);return e.createElement(a.Viewport,{"aria-label":t??"",...s,ref:l,"data-fade":r?"":void 0,className:c("kui-MessageScrollerViewport",o)})});g.displayName="MessageScroller.Viewport";var M=e.forwardRef(({className:o,...t},r)=>e.createElement(a.Content,{...t,ref:r,className:c("kui-MessageScrollerContent",o)}));M.displayName="MessageScroller.Content";var P=e.forwardRef(({className:o,...t},r)=>e.createElement(a.Item,{...t,ref:r,className:c("kui-MessageScrollerItem",o)}));P.displayName="MessageScroller.Item";var R=e.forwardRef(({direction:o="end",behavior:t="auto",className:r,children:s,size:n,variant:i="surface",emphasis:l,color:u="gray",radius:v="full","aria-label":b,onClick:y,...B},w)=>{let{scrollToEnd:h,scrollToStart:C}=f(),k=p=>{if(y?.(p),p.defaultPrevented)return;p.preventDefault(),p.currentTarget.closest(".kui-MessageScrollerRoot")?.querySelector(".kui-MessageScrollerViewport")?.focus({preventScroll:!0}),o==="start"?C({behavior:t}):h({behavior:t})};return e.createElement(a.Button,{direction:o,behavior:t,onClick:k,render:e.createElement(d,{iconOnly:!0,...B,ref:w,size:n,...l?{emphasis:l}:{variant:i},color:u,radius:v,"aria-label":b??(o==="end"?"Jump to the latest":"Jump to the first"),className:c("kui-MessageScrollerButton",r),"data-direction":o},s??e.createElement("svg",{width:"15",height:"15",viewBox:"0 0 15 15",fill:"none","aria-hidden":!0,style:o==="start"?{transform:"rotate(180deg)"}:void 0},e.createElement("path",{d:"M7.5 2.5v10M3.5 8.5l4 4 4-4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})))})});R.displayName="MessageScroller.Button";export{f as a,V as b,N as c,S as d,g as e,M as f,P as g,R as h,L as i};
|
|
3
|
+
//# sourceMappingURL=chunk-R4PGFURL.js.map
|