@thalavaisankar/atoms 0.0.0-stage → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +24 -0
- package/README.md +196 -2
- package/THIRD_PARTY_NOTICES.md +275 -0
- package/dist/blocks/index.d.mts +2 -0
- package/dist/blocks/index.mjs +1 -0
- package/dist/blocks/index.mjs.map +1 -0
- package/dist/components/ui/accordion/accordion.mjs +194 -0
- package/dist/components/ui/accordion/accordion.mjs.map +1 -0
- package/dist/components/ui/accordion/index.mjs +15 -0
- package/dist/components/ui/accordion/index.mjs.map +1 -0
- package/dist/components/ui/activity-feed/activity-feed.mjs +287 -0
- package/dist/components/ui/activity-feed/activity-feed.mjs.map +1 -0
- package/dist/components/ui/activity-feed/index.mjs +39 -0
- package/dist/components/ui/activity-feed/index.mjs.map +1 -0
- package/dist/components/ui/alert/alert.mjs +128 -0
- package/dist/components/ui/alert/alert.mjs.map +1 -0
- package/dist/components/ui/alert/index.mjs +17 -0
- package/dist/components/ui/alert/index.mjs.map +1 -0
- package/dist/components/ui/animated-label/animated-label.mjs +89 -0
- package/dist/components/ui/animated-label/animated-label.mjs.map +1 -0
- package/dist/components/ui/animated-label/index.mjs +9 -0
- package/dist/components/ui/animated-label/index.mjs.map +1 -0
- package/dist/components/ui/animated-number/animated-number.mjs +101 -0
- package/dist/components/ui/animated-number/animated-number.mjs.map +1 -0
- package/dist/components/ui/animated-number/index.mjs +5 -0
- package/dist/components/ui/animated-number/index.mjs.map +1 -0
- package/dist/components/ui/avatar/avatar.mjs +130 -0
- package/dist/components/ui/avatar/avatar.mjs.map +1 -0
- package/dist/components/ui/avatar/index.mjs +17 -0
- package/dist/components/ui/avatar/index.mjs.map +1 -0
- package/dist/components/ui/avatar-group/avatar-group.mjs +49 -0
- package/dist/components/ui/avatar-group/avatar-group.mjs.map +1 -0
- package/dist/components/ui/avatar-group/index.mjs +5 -0
- package/dist/components/ui/avatar-group/index.mjs.map +1 -0
- package/dist/components/ui/badge/badge-motion.mjs +108 -0
- package/dist/components/ui/badge/badge-motion.mjs.map +1 -0
- package/dist/components/ui/badge/badge.mjs +314 -0
- package/dist/components/ui/badge/badge.mjs.map +1 -0
- package/dist/components/ui/badge/index.mjs +27 -0
- package/dist/components/ui/badge/index.mjs.map +1 -0
- package/dist/components/ui/badge/readable-ink.mjs +36 -0
- package/dist/components/ui/badge/readable-ink.mjs.map +1 -0
- package/dist/components/ui/badge-group/badge-group.mjs +132 -0
- package/dist/components/ui/badge-group/badge-group.mjs.map +1 -0
- package/dist/components/ui/badge-group/index.mjs +5 -0
- package/dist/components/ui/badge-group/index.mjs.map +1 -0
- package/dist/components/ui/breadcrumb/breadcrumb.mjs +108 -0
- package/dist/components/ui/breadcrumb/breadcrumb.mjs.map +1 -0
- package/dist/components/ui/breadcrumb/index.mjs +19 -0
- package/dist/components/ui/breadcrumb/index.mjs.map +1 -0
- package/dist/components/ui/button/button-variants.mjs +80 -0
- package/dist/components/ui/button/button-variants.mjs.map +1 -0
- package/dist/components/ui/button/button.mjs +74 -0
- package/dist/components/ui/button/button.mjs.map +1 -0
- package/dist/components/ui/button/index.mjs +17 -0
- package/dist/components/ui/button/index.mjs.map +1 -0
- package/dist/components/ui/button/social-button.mjs +45 -0
- package/dist/components/ui/button/social-button.mjs.map +1 -0
- package/dist/components/ui/button/social-logos.mjs +179 -0
- package/dist/components/ui/button/social-logos.mjs.map +1 -0
- package/dist/components/ui/button/split-button.mjs +72 -0
- package/dist/components/ui/button/split-button.mjs.map +1 -0
- package/dist/components/ui/button-group/button-group.mjs +58 -0
- package/dist/components/ui/button-group/button-group.mjs.map +1 -0
- package/dist/components/ui/button-group/index.mjs +11 -0
- package/dist/components/ui/button-group/index.mjs.map +1 -0
- package/dist/components/ui/card/card.mjs +131 -0
- package/dist/components/ui/card/card.mjs.map +1 -0
- package/dist/components/ui/card/index.mjs +23 -0
- package/dist/components/ui/card/index.mjs.map +1 -0
- package/dist/components/ui/chart/bar-list.mjs +87 -0
- package/dist/components/ui/chart/bar-list.mjs.map +1 -0
- package/dist/components/ui/chart/chart-colors.mjs +68 -0
- package/dist/components/ui/chart/chart-colors.mjs.map +1 -0
- package/dist/components/ui/chart/chart-geometry.mjs +152 -0
- package/dist/components/ui/chart/chart-geometry.mjs.map +1 -0
- package/dist/components/ui/chart/chart-specialized.mjs +194 -0
- package/dist/components/ui/chart/chart-specialized.mjs.map +1 -0
- package/dist/components/ui/chart/chart.mjs +648 -0
- package/dist/components/ui/chart/chart.mjs.map +1 -0
- package/dist/components/ui/chart/index.mjs +88 -0
- package/dist/components/ui/chart/index.mjs.map +1 -0
- package/dist/components/ui/chart/radial-meter.mjs +142 -0
- package/dist/components/ui/chart/radial-meter.mjs.map +1 -0
- package/dist/components/ui/chart/types.mjs +1 -0
- package/dist/components/ui/chart/types.mjs.map +1 -0
- package/dist/components/ui/checkbox/checkbox.mjs +183 -0
- package/dist/components/ui/checkbox/checkbox.mjs.map +1 -0
- package/dist/components/ui/checkbox/index.mjs +11 -0
- package/dist/components/ui/checkbox/index.mjs.map +1 -0
- package/dist/components/ui/checklist/checklist.mjs +353 -0
- package/dist/components/ui/checklist/checklist.mjs.map +1 -0
- package/dist/components/ui/checklist/index.mjs +33 -0
- package/dist/components/ui/checklist/index.mjs.map +1 -0
- package/dist/components/ui/chip/chip.mjs +202 -0
- package/dist/components/ui/chip/chip.mjs.map +1 -0
- package/dist/components/ui/chip/index.mjs +13 -0
- package/dist/components/ui/chip/index.mjs.map +1 -0
- package/dist/components/ui/chip-group/chip-group.mjs +204 -0
- package/dist/components/ui/chip-group/chip-group.mjs.map +1 -0
- package/dist/components/ui/chip-group/index.mjs +11 -0
- package/dist/components/ui/chip-group/index.mjs.map +1 -0
- package/dist/components/ui/code-snippet/code-highlighter.mjs +16 -0
- package/dist/components/ui/code-snippet/code-highlighter.mjs.map +1 -0
- package/dist/components/ui/code-snippet/code-snippet.mjs +437 -0
- package/dist/components/ui/code-snippet/code-snippet.mjs.map +1 -0
- package/dist/components/ui/code-snippet/index.mjs +17 -0
- package/dist/components/ui/code-snippet/index.mjs.map +1 -0
- package/dist/components/ui/code-snippet/labels.mjs +16 -0
- package/dist/components/ui/code-snippet/labels.mjs.map +1 -0
- package/dist/components/ui/code-snippet/tokenize.mjs +715 -0
- package/dist/components/ui/code-snippet/tokenize.mjs.map +1 -0
- package/dist/components/ui/code-snippet/types.mjs +1 -0
- package/dist/components/ui/code-snippet/types.mjs.map +1 -0
- package/dist/components/ui/collapsible/collapsible.mjs +85 -0
- package/dist/components/ui/collapsible/collapsible.mjs.map +1 -0
- package/dist/components/ui/collapsible/index.mjs +15 -0
- package/dist/components/ui/collapsible/index.mjs.map +1 -0
- package/dist/components/ui/color-picker/color-picker.mjs +852 -0
- package/dist/components/ui/color-picker/color-picker.mjs.map +1 -0
- package/dist/components/ui/color-picker/index.mjs +47 -0
- package/dist/components/ui/color-picker/index.mjs.map +1 -0
- package/dist/components/ui/combobox/combobox.mjs +745 -0
- package/dist/components/ui/combobox/combobox.mjs.map +1 -0
- package/dist/components/ui/combobox/index.mjs +27 -0
- package/dist/components/ui/combobox/index.mjs.map +1 -0
- package/dist/components/ui/command/command.mjs +439 -0
- package/dist/components/ui/command/command.mjs.map +1 -0
- package/dist/components/ui/command/index.mjs +31 -0
- package/dist/components/ui/command/index.mjs.map +1 -0
- package/dist/components/ui/compare-slider/compare-slider.mjs +335 -0
- package/dist/components/ui/compare-slider/compare-slider.mjs.map +1 -0
- package/dist/components/ui/compare-slider/index.mjs +17 -0
- package/dist/components/ui/compare-slider/index.mjs.map +1 -0
- package/dist/components/ui/context-menu/context-menu.mjs +184 -0
- package/dist/components/ui/context-menu/context-menu.mjs.map +1 -0
- package/dist/components/ui/context-menu/index.mjs +37 -0
- package/dist/components/ui/context-menu/index.mjs.map +1 -0
- package/dist/components/ui/data-table/active-filters.mjs +69 -0
- package/dist/components/ui/data-table/active-filters.mjs.map +1 -0
- package/dist/components/ui/data-table/body-row.mjs +118 -0
- package/dist/components/ui/data-table/body-row.mjs.map +1 -0
- package/dist/components/ui/data-table/cards.mjs +76 -0
- package/dist/components/ui/data-table/cards.mjs.map +1 -0
- package/dist/components/ui/data-table/data-table.mjs +680 -0
- package/dist/components/ui/data-table/data-table.mjs.map +1 -0
- package/dist/components/ui/data-table/empty.mjs +26 -0
- package/dist/components/ui/data-table/empty.mjs.map +1 -0
- package/dist/components/ui/data-table/expand.mjs +70 -0
- package/dist/components/ui/data-table/expand.mjs.map +1 -0
- package/dist/components/ui/data-table/faceted-filter.mjs +112 -0
- package/dist/components/ui/data-table/faceted-filter.mjs.map +1 -0
- package/dist/components/ui/data-table/features.mjs +96 -0
- package/dist/components/ui/data-table/features.mjs.map +1 -0
- package/dist/components/ui/data-table/grip.mjs +37 -0
- package/dist/components/ui/data-table/grip.mjs.map +1 -0
- package/dist/components/ui/data-table/header-cell.mjs +85 -0
- package/dist/components/ui/data-table/header-cell.mjs.map +1 -0
- package/dist/components/ui/data-table/index.mjs +55 -0
- package/dist/components/ui/data-table/index.mjs.map +1 -0
- package/dist/components/ui/data-table/labels.mjs +55 -0
- package/dist/components/ui/data-table/labels.mjs.map +1 -0
- package/dist/components/ui/data-table/load-more.mjs +56 -0
- package/dist/components/ui/data-table/load-more.mjs.map +1 -0
- package/dist/components/ui/data-table/move-item.mjs +11 -0
- package/dist/components/ui/data-table/move-item.mjs.map +1 -0
- package/dist/components/ui/data-table/persist.mjs +65 -0
- package/dist/components/ui/data-table/persist.mjs.map +1 -0
- package/dist/components/ui/data-table/selection-bar.mjs +51 -0
- package/dist/components/ui/data-table/selection-bar.mjs.map +1 -0
- package/dist/components/ui/data-table/tabs.mjs +48 -0
- package/dist/components/ui/data-table/tabs.mjs.map +1 -0
- package/dist/components/ui/data-table/toolbar.mjs +92 -0
- package/dist/components/ui/data-table/toolbar.mjs.map +1 -0
- package/dist/components/ui/data-table/use-reorder.mjs +239 -0
- package/dist/components/ui/data-table/use-reorder.mjs.map +1 -0
- package/dist/components/ui/data-table/use-reveal.mjs +24 -0
- package/dist/components/ui/data-table/use-reveal.mjs.map +1 -0
- package/dist/components/ui/data-table/use-table-state.mjs +38 -0
- package/dist/components/ui/data-table/use-table-state.mjs.map +1 -0
- package/dist/components/ui/data-table/view-options.mjs +66 -0
- package/dist/components/ui/data-table/view-options.mjs.map +1 -0
- package/dist/components/ui/date-picker/calendar.mjs +466 -0
- package/dist/components/ui/date-picker/calendar.mjs.map +1 -0
- package/dist/components/ui/date-picker/date-picker.mjs +366 -0
- package/dist/components/ui/date-picker/date-picker.mjs.map +1 -0
- package/dist/components/ui/date-picker/index.mjs +17 -0
- package/dist/components/ui/date-picker/index.mjs.map +1 -0
- package/dist/components/ui/date-picker/presets.mjs +49 -0
- package/dist/components/ui/date-picker/presets.mjs.map +1 -0
- package/dist/components/ui/description-list/description-list.mjs +40 -0
- package/dist/components/ui/description-list/description-list.mjs.map +1 -0
- package/dist/components/ui/description-list/index.mjs +15 -0
- package/dist/components/ui/description-list/index.mjs.map +1 -0
- package/dist/components/ui/dialog/dialog-stepper.mjs +23 -0
- package/dist/components/ui/dialog/dialog-stepper.mjs.map +1 -0
- package/dist/components/ui/dialog/dialog.mjs +343 -0
- package/dist/components/ui/dialog/dialog.mjs.map +1 -0
- package/dist/components/ui/dialog/focus-return.mjs +21 -0
- package/dist/components/ui/dialog/focus-return.mjs.map +1 -0
- package/dist/components/ui/dialog/index.mjs +33 -0
- package/dist/components/ui/dialog/index.mjs.map +1 -0
- package/dist/components/ui/divider/divider.mjs +130 -0
- package/dist/components/ui/divider/divider.mjs.map +1 -0
- package/dist/components/ui/divider/index.mjs +6 -0
- package/dist/components/ui/divider/index.mjs.map +1 -0
- package/dist/components/ui/dock/dock.mjs +444 -0
- package/dist/components/ui/dock/dock.mjs.map +1 -0
- package/dist/components/ui/dock/index.mjs +19 -0
- package/dist/components/ui/dock/index.mjs.map +1 -0
- package/dist/components/ui/document-editor/block-actions.mjs +118 -0
- package/dist/components/ui/document-editor/block-actions.mjs.map +1 -0
- package/dist/components/ui/document-editor/block-commands.mjs +182 -0
- package/dist/components/ui/document-editor/block-commands.mjs.map +1 -0
- package/dist/components/ui/document-editor/block-handle.mjs +387 -0
- package/dist/components/ui/document-editor/block-handle.mjs.map +1 -0
- package/dist/components/ui/document-editor/block-morph.mjs +95 -0
- package/dist/components/ui/document-editor/block-morph.mjs.map +1 -0
- package/dist/components/ui/document-editor/block-selection.mjs +81 -0
- package/dist/components/ui/document-editor/block-selection.mjs.map +1 -0
- package/dist/components/ui/document-editor/blocks.mjs +30 -0
- package/dist/components/ui/document-editor/blocks.mjs.map +1 -0
- package/dist/components/ui/document-editor/bubble-menu.mjs +120 -0
- package/dist/components/ui/document-editor/bubble-menu.mjs.map +1 -0
- package/dist/components/ui/document-editor/code-block.mjs +89 -0
- package/dist/components/ui/document-editor/code-block.mjs.map +1 -0
- package/dist/components/ui/document-editor/collaboration-types.mjs +9 -0
- package/dist/components/ui/document-editor/collaboration-types.mjs.map +1 -0
- package/dist/components/ui/document-editor/collaboration.mjs +198 -0
- package/dist/components/ui/document-editor/collaboration.mjs.map +1 -0
- package/dist/components/ui/document-editor/columns.mjs +52 -0
- package/dist/components/ui/document-editor/columns.mjs.map +1 -0
- package/dist/components/ui/document-editor/contents.mjs +60 -0
- package/dist/components/ui/document-editor/contents.mjs.map +1 -0
- package/dist/components/ui/document-editor/date-chip.mjs +115 -0
- package/dist/components/ui/document-editor/date-chip.mjs.map +1 -0
- package/dist/components/ui/document-editor/date-words.mjs +101 -0
- package/dist/components/ui/document-editor/date-words.mjs.map +1 -0
- package/dist/components/ui/document-editor/doc-labels.mjs +19 -0
- package/dist/components/ui/document-editor/doc-labels.mjs.map +1 -0
- package/dist/components/ui/document-editor/document-editor.mjs +496 -0
- package/dist/components/ui/document-editor/document-editor.mjs.map +1 -0
- package/dist/components/ui/document-editor/emoji-suggest.mjs +81 -0
- package/dist/components/ui/document-editor/emoji-suggest.mjs.map +1 -0
- package/dist/components/ui/document-editor/focus-mode.mjs +32 -0
- package/dist/components/ui/document-editor/focus-mode.mjs.map +1 -0
- package/dist/components/ui/document-editor/geometry.mjs +35 -0
- package/dist/components/ui/document-editor/geometry.mjs.map +1 -0
- package/dist/components/ui/document-editor/ghost-text.mjs +154 -0
- package/dist/components/ui/document-editor/ghost-text.mjs.map +1 -0
- package/dist/components/ui/document-editor/gliding-caret.mjs +118 -0
- package/dist/components/ui/document-editor/gliding-caret.mjs.map +1 -0
- package/dist/components/ui/document-editor/headings.mjs +64 -0
- package/dist/components/ui/document-editor/headings.mjs.map +1 -0
- package/dist/components/ui/document-editor/image.mjs +318 -0
- package/dist/components/ui/document-editor/image.mjs.map +1 -0
- package/dist/components/ui/document-editor/index.mjs +131 -0
- package/dist/components/ui/document-editor/index.mjs.map +1 -0
- package/dist/components/ui/document-editor/labels.mjs +96 -0
- package/dist/components/ui/document-editor/labels.mjs.map +1 -0
- package/dist/components/ui/document-editor/link-card.mjs +138 -0
- package/dist/components/ui/document-editor/link-card.mjs.map +1 -0
- package/dist/components/ui/document-editor/mentions.mjs +105 -0
- package/dist/components/ui/document-editor/mentions.mjs.map +1 -0
- package/dist/components/ui/document-editor/outline.mjs +138 -0
- package/dist/components/ui/document-editor/outline.mjs.map +1 -0
- package/dist/components/ui/document-editor/section-fold.mjs +124 -0
- package/dist/components/ui/document-editor/section-fold.mjs.map +1 -0
- package/dist/components/ui/document-editor/slash-command.mjs +210 -0
- package/dist/components/ui/document-editor/slash-command.mjs.map +1 -0
- package/dist/components/ui/document-editor/suggest-list.mjs +187 -0
- package/dist/components/ui/document-editor/suggest-list.mjs.map +1 -0
- package/dist/components/ui/document-editor/table.mjs +242 -0
- package/dist/components/ui/document-editor/table.mjs.map +1 -0
- package/dist/components/ui/document-editor/templates.mjs +66 -0
- package/dist/components/ui/document-editor/templates.mjs.map +1 -0
- package/dist/components/ui/document-editor/toggle.mjs +176 -0
- package/dist/components/ui/document-editor/toggle.mjs.map +1 -0
- package/dist/components/ui/document-editor/typography-rules.mjs +8 -0
- package/dist/components/ui/document-editor/typography-rules.mjs.map +1 -0
- package/dist/components/ui/document-editor/use-editor-value.mjs +34 -0
- package/dist/components/ui/document-editor/use-editor-value.mjs.map +1 -0
- package/dist/components/ui/drawer/drawer-nav.mjs +153 -0
- package/dist/components/ui/drawer/drawer-nav.mjs.map +1 -0
- package/dist/components/ui/drawer/drawer.mjs +334 -0
- package/dist/components/ui/drawer/drawer.mjs.map +1 -0
- package/dist/components/ui/drawer/index.mjs +37 -0
- package/dist/components/ui/drawer/index.mjs.map +1 -0
- package/dist/components/ui/drawer/use-swipe-to-close.mjs +77 -0
- package/dist/components/ui/drawer/use-swipe-to-close.mjs.map +1 -0
- package/dist/components/ui/dropdown-menu/dropdown-menu.mjs +567 -0
- package/dist/components/ui/dropdown-menu/dropdown-menu.mjs.map +1 -0
- package/dist/components/ui/dropdown-menu/index.mjs +43 -0
- package/dist/components/ui/dropdown-menu/index.mjs.map +1 -0
- package/dist/components/ui/editable-text/editable-text.mjs +148 -0
- package/dist/components/ui/editable-text/editable-text.mjs.map +1 -0
- package/dist/components/ui/editable-text/index.mjs +6 -0
- package/dist/components/ui/editable-text/index.mjs.map +1 -0
- package/dist/components/ui/emoji-picker/emoji-data.mjs +469 -0
- package/dist/components/ui/emoji-picker/emoji-data.mjs.map +1 -0
- package/dist/components/ui/emoji-picker/emoji-picker.mjs +464 -0
- package/dist/components/ui/emoji-picker/emoji-picker.mjs.map +1 -0
- package/dist/components/ui/emoji-picker/index.mjs +19 -0
- package/dist/components/ui/emoji-picker/index.mjs.map +1 -0
- package/dist/components/ui/empty-state/empty-state.mjs +110 -0
- package/dist/components/ui/empty-state/empty-state.mjs.map +1 -0
- package/dist/components/ui/empty-state/index.mjs +17 -0
- package/dist/components/ui/empty-state/index.mjs.map +1 -0
- package/dist/components/ui/event-calendar/calendar-math.mjs +256 -0
- package/dist/components/ui/event-calendar/calendar-math.mjs.map +1 -0
- package/dist/components/ui/event-calendar/context.mjs +51 -0
- package/dist/components/ui/event-calendar/context.mjs.map +1 -0
- package/dist/components/ui/event-calendar/editor.mjs +292 -0
- package/dist/components/ui/event-calendar/editor.mjs.map +1 -0
- package/dist/components/ui/event-calendar/event-block.mjs +55 -0
- package/dist/components/ui/event-calendar/event-block.mjs.map +1 -0
- package/dist/components/ui/event-calendar/event-calendar.mjs +438 -0
- package/dist/components/ui/event-calendar/event-calendar.mjs.map +1 -0
- package/dist/components/ui/event-calendar/event-keys.mjs +41 -0
- package/dist/components/ui/event-calendar/event-keys.mjs.map +1 -0
- package/dist/components/ui/event-calendar/index.mjs +37 -0
- package/dist/components/ui/event-calendar/index.mjs.map +1 -0
- package/dist/components/ui/event-calendar/month-grid.mjs +207 -0
- package/dist/components/ui/event-calendar/month-grid.mjs.map +1 -0
- package/dist/components/ui/event-calendar/narrow.mjs +193 -0
- package/dist/components/ui/event-calendar/narrow.mjs.map +1 -0
- package/dist/components/ui/event-calendar/time-grid.mjs +534 -0
- package/dist/components/ui/event-calendar/time-grid.mjs.map +1 -0
- package/dist/components/ui/expandable-search/expandable-search.mjs +174 -0
- package/dist/components/ui/expandable-search/expandable-search.mjs.map +1 -0
- package/dist/components/ui/expandable-search/index.mjs +6 -0
- package/dist/components/ui/expandable-search/index.mjs.map +1 -0
- package/dist/components/ui/field/field.mjs +444 -0
- package/dist/components/ui/field/field.mjs.map +1 -0
- package/dist/components/ui/field/index.mjs +21 -0
- package/dist/components/ui/field/index.mjs.map +1 -0
- package/dist/components/ui/file-card/file-card.mjs +198 -0
- package/dist/components/ui/file-card/file-card.mjs.map +1 -0
- package/dist/components/ui/file-card/file-icon.mjs +66 -0
- package/dist/components/ui/file-card/file-icon.mjs.map +1 -0
- package/dist/components/ui/file-card/file-types.mjs +70 -0
- package/dist/components/ui/file-card/file-types.mjs.map +1 -0
- package/dist/components/ui/file-card/index.mjs +32 -0
- package/dist/components/ui/file-card/index.mjs.map +1 -0
- package/dist/components/ui/file-preview/context.mjs +77 -0
- package/dist/components/ui/file-preview/context.mjs.map +1 -0
- package/dist/components/ui/file-preview/file-preview.mjs +865 -0
- package/dist/components/ui/file-preview/file-preview.mjs.map +1 -0
- package/dist/components/ui/file-preview/index.mjs +56 -0
- package/dist/components/ui/file-preview/index.mjs.map +1 -0
- package/dist/components/ui/file-preview/pdf.mjs +250 -0
- package/dist/components/ui/file-preview/pdf.mjs.map +1 -0
- package/dist/components/ui/file-preview/renderers.mjs +257 -0
- package/dist/components/ui/file-preview/renderers.mjs.map +1 -0
- package/dist/components/ui/file-upload/file-upload.mjs +633 -0
- package/dist/components/ui/file-upload/file-upload.mjs.map +1 -0
- package/dist/components/ui/file-upload/index.mjs +42 -0
- package/dist/components/ui/file-upload/index.mjs.map +1 -0
- package/dist/components/ui/file-upload/validate.mjs +111 -0
- package/dist/components/ui/file-upload/validate.mjs.map +1 -0
- package/dist/components/ui/flag/flag.mjs +39 -0
- package/dist/components/ui/flag/flag.mjs.map +1 -0
- package/dist/components/ui/flag/index.mjs +7 -0
- package/dist/components/ui/flag/index.mjs.map +1 -0
- package/dist/components/ui/floating-window/floating-window.mjs +255 -0
- package/dist/components/ui/floating-window/floating-window.mjs.map +1 -0
- package/dist/components/ui/floating-window/index.mjs +11 -0
- package/dist/components/ui/floating-window/index.mjs.map +1 -0
- package/dist/components/ui/form/form-section.mjs +87 -0
- package/dist/components/ui/form/form-section.mjs.map +1 -0
- package/dist/components/ui/form/form.mjs +205 -0
- package/dist/components/ui/form/form.mjs.map +1 -0
- package/dist/components/ui/form/index.mjs +29 -0
- package/dist/components/ui/form/index.mjs.map +1 -0
- package/dist/components/ui/globe/globe-data.mjs +9 -0
- package/dist/components/ui/globe/globe-data.mjs.map +1 -0
- package/dist/components/ui/globe/globe-math.mjs +269 -0
- package/dist/components/ui/globe/globe-math.mjs.map +1 -0
- package/dist/components/ui/globe/globe.mjs +719 -0
- package/dist/components/ui/globe/globe.mjs.map +1 -0
- package/dist/components/ui/globe/index.mjs +13 -0
- package/dist/components/ui/globe/index.mjs.map +1 -0
- package/dist/components/ui/highlight-match/highlight-children.mjs +13 -0
- package/dist/components/ui/highlight-match/highlight-children.mjs.map +1 -0
- package/dist/components/ui/highlight-match/highlight-match-variants.mjs +17 -0
- package/dist/components/ui/highlight-match/highlight-match-variants.mjs.map +1 -0
- package/dist/components/ui/highlight-match/highlight-match.mjs +37 -0
- package/dist/components/ui/highlight-match/highlight-match.mjs.map +1 -0
- package/dist/components/ui/highlight-match/index.mjs +15 -0
- package/dist/components/ui/highlight-match/index.mjs.map +1 -0
- package/dist/components/ui/highlight-match/match-ranges.mjs +50 -0
- package/dist/components/ui/highlight-match/match-ranges.mjs.map +1 -0
- package/dist/components/ui/histogram-slider/histogram-slider.mjs +83 -0
- package/dist/components/ui/histogram-slider/histogram-slider.mjs.map +1 -0
- package/dist/components/ui/histogram-slider/index.mjs +6 -0
- package/dist/components/ui/histogram-slider/index.mjs.map +1 -0
- package/dist/components/ui/hold-button/hold-button.mjs +258 -0
- package/dist/components/ui/hold-button/hold-button.mjs.map +1 -0
- package/dist/components/ui/hold-button/index.mjs +6 -0
- package/dist/components/ui/hold-button/index.mjs.map +1 -0
- package/dist/components/ui/hover-card/hover-card.mjs +111 -0
- package/dist/components/ui/hover-card/hover-card.mjs.map +1 -0
- package/dist/components/ui/hover-card/index.mjs +21 -0
- package/dist/components/ui/hover-card/index.mjs.map +1 -0
- package/dist/components/ui/ink-tray/index.mjs +29 -0
- package/dist/components/ui/ink-tray/index.mjs.map +1 -0
- package/dist/components/ui/ink-tray/ink-tray-art.mjs +68 -0
- package/dist/components/ui/ink-tray/ink-tray-art.mjs.map +1 -0
- package/dist/components/ui/ink-tray/ink-tray.mjs +350 -0
- package/dist/components/ui/ink-tray/ink-tray.mjs.map +1 -0
- package/dist/components/ui/input/index.mjs +41 -0
- package/dist/components/ui/input/index.mjs.map +1 -0
- package/dist/components/ui/input/input.mjs +268 -0
- package/dist/components/ui/input/input.mjs.map +1 -0
- package/dist/components/ui/input/number-input.mjs +272 -0
- package/dist/components/ui/input/number-input.mjs.map +1 -0
- package/dist/components/ui/input/password-input.mjs +49 -0
- package/dist/components/ui/input/password-input.mjs.map +1 -0
- package/dist/components/ui/input/phone-input-countries.mjs +216 -0
- package/dist/components/ui/input/phone-input-countries.mjs.map +1 -0
- package/dist/components/ui/input/phone-input.mjs +326 -0
- package/dist/components/ui/input/phone-input.mjs.map +1 -0
- package/dist/components/ui/input/use-controllable-state.mjs +24 -0
- package/dist/components/ui/input/use-controllable-state.mjs.map +1 -0
- package/dist/components/ui/input/use-hold-repeat.mjs +35 -0
- package/dist/components/ui/input/use-hold-repeat.mjs.map +1 -0
- package/dist/components/ui/input-group/index.mjs +11 -0
- package/dist/components/ui/input-group/index.mjs.map +1 -0
- package/dist/components/ui/input-group/input-group.mjs +78 -0
- package/dist/components/ui/input-group/input-group.mjs.map +1 -0
- package/dist/components/ui/island/index.mjs +23 -0
- package/dist/components/ui/island/index.mjs.map +1 -0
- package/dist/components/ui/island/island.mjs +328 -0
- package/dist/components/ui/island/island.mjs.map +1 -0
- package/dist/components/ui/kbd/index.mjs +6 -0
- package/dist/components/ui/kbd/index.mjs.map +1 -0
- package/dist/components/ui/kbd/kbd.mjs +73 -0
- package/dist/components/ui/kbd/kbd.mjs.map +1 -0
- package/dist/components/ui/keypad/index.mjs +23 -0
- package/dist/components/ui/keypad/index.mjs.map +1 -0
- package/dist/components/ui/keypad/keypad.mjs +345 -0
- package/dist/components/ui/keypad/keypad.mjs.map +1 -0
- package/dist/components/ui/label/index.mjs +7 -0
- package/dist/components/ui/label/index.mjs.map +1 -0
- package/dist/components/ui/label/label.mjs +117 -0
- package/dist/components/ui/label/label.mjs.map +1 -0
- package/dist/components/ui/lightbox/index.mjs +47 -0
- package/dist/components/ui/lightbox/index.mjs.map +1 -0
- package/dist/components/ui/lightbox/labels.mjs +23 -0
- package/dist/components/ui/lightbox/labels.mjs.map +1 -0
- package/dist/components/ui/lightbox/lightbox.mjs +1359 -0
- package/dist/components/ui/lightbox/lightbox.mjs.map +1 -0
- package/dist/components/ui/link/index.mjs +6 -0
- package/dist/components/ui/link/index.mjs.map +1 -0
- package/dist/components/ui/link/link.mjs +64 -0
- package/dist/components/ui/link/link.mjs.map +1 -0
- package/dist/components/ui/list/index.mjs +35 -0
- package/dist/components/ui/list/index.mjs.map +1 -0
- package/dist/components/ui/list/list.mjs +505 -0
- package/dist/components/ui/list/list.mjs.map +1 -0
- package/dist/components/ui/load-more/index.mjs +23 -0
- package/dist/components/ui/load-more/index.mjs.map +1 -0
- package/dist/components/ui/load-more/load-more.mjs +409 -0
- package/dist/components/ui/load-more/load-more.mjs.map +1 -0
- package/dist/components/ui/map/index.mjs +27 -0
- package/dist/components/ui/map/index.mjs.map +1 -0
- package/dist/components/ui/map/map-style.mjs +169 -0
- package/dist/components/ui/map/map-style.mjs.map +1 -0
- package/dist/components/ui/map/map.mjs +624 -0
- package/dist/components/ui/map/map.mjs.map +1 -0
- package/dist/components/ui/map-pin/index.mjs +6 -0
- package/dist/components/ui/map-pin/index.mjs.map +1 -0
- package/dist/components/ui/map-pin/map-pin.mjs +55 -0
- package/dist/components/ui/map-pin/map-pin.mjs.map +1 -0
- package/dist/components/ui/mention/index.mjs +29 -0
- package/dist/components/ui/mention/index.mjs.map +1 -0
- package/dist/components/ui/mention/mention.mjs +262 -0
- package/dist/components/ui/mention/mention.mjs.map +1 -0
- package/dist/components/ui/mention/split-mentions.mjs +24 -0
- package/dist/components/ui/mention/split-mentions.mjs.map +1 -0
- package/dist/components/ui/menubar/index.mjs +39 -0
- package/dist/components/ui/menubar/index.mjs.map +1 -0
- package/dist/components/ui/menubar/menubar.mjs +222 -0
- package/dist/components/ui/menubar/menubar.mjs.map +1 -0
- package/dist/components/ui/meter/index.mjs +21 -0
- package/dist/components/ui/meter/index.mjs.map +1 -0
- package/dist/components/ui/meter/meter.mjs +167 -0
- package/dist/components/ui/meter/meter.mjs.map +1 -0
- package/dist/components/ui/multi-select/index.mjs +25 -0
- package/dist/components/ui/multi-select/index.mjs.map +1 -0
- package/dist/components/ui/multi-select/multi-select.mjs +285 -0
- package/dist/components/ui/multi-select/multi-select.mjs.map +1 -0
- package/dist/components/ui/navigation-menu/index.mjs +41 -0
- package/dist/components/ui/navigation-menu/index.mjs.map +1 -0
- package/dist/components/ui/navigation-menu/navigation-menu.mjs +396 -0
- package/dist/components/ui/navigation-menu/navigation-menu.mjs.map +1 -0
- package/dist/components/ui/notebook-page/index.mjs +15 -0
- package/dist/components/ui/notebook-page/index.mjs.map +1 -0
- package/dist/components/ui/notebook-page/notebook-page.mjs +162 -0
- package/dist/components/ui/notebook-page/notebook-page.mjs.map +1 -0
- package/dist/components/ui/notification-inbox/index.mjs +47 -0
- package/dist/components/ui/notification-inbox/index.mjs.map +1 -0
- package/dist/components/ui/notification-inbox/notification-inbox.mjs +422 -0
- package/dist/components/ui/notification-inbox/notification-inbox.mjs.map +1 -0
- package/dist/components/ui/number-field/index.mjs +24 -0
- package/dist/components/ui/number-field/index.mjs.map +1 -0
- package/dist/components/ui/number-field/number-field.mjs +460 -0
- package/dist/components/ui/number-field/number-field.mjs.map +1 -0
- package/dist/components/ui/number-field/number-format.mjs +48 -0
- package/dist/components/ui/number-field/number-format.mjs.map +1 -0
- package/dist/components/ui/otp-input/index.mjs +9 -0
- package/dist/components/ui/otp-input/index.mjs.map +1 -0
- package/dist/components/ui/otp-input/otp-input.mjs +285 -0
- package/dist/components/ui/otp-input/otp-input.mjs.map +1 -0
- package/dist/components/ui/pager/index.mjs +7 -0
- package/dist/components/ui/pager/index.mjs.map +1 -0
- package/dist/components/ui/pager/pager.mjs +86 -0
- package/dist/components/ui/pager/pager.mjs.map +1 -0
- package/dist/components/ui/pagination/index.mjs +23 -0
- package/dist/components/ui/pagination/index.mjs.map +1 -0
- package/dist/components/ui/pagination/pagination.mjs +210 -0
- package/dist/components/ui/pagination/pagination.mjs.map +1 -0
- package/dist/components/ui/password-strength/index.mjs +21 -0
- package/dist/components/ui/password-strength/index.mjs.map +1 -0
- package/dist/components/ui/password-strength/password-rules.mjs +25 -0
- package/dist/components/ui/password-strength/password-rules.mjs.map +1 -0
- package/dist/components/ui/password-strength/password-strength.mjs +125 -0
- package/dist/components/ui/password-strength/password-strength.mjs.map +1 -0
- package/dist/components/ui/popover/index.mjs +31 -0
- package/dist/components/ui/popover/index.mjs.map +1 -0
- package/dist/components/ui/popover/popover.mjs +574 -0
- package/dist/components/ui/popover/popover.mjs.map +1 -0
- package/dist/components/ui/progress/index.mjs +15 -0
- package/dist/components/ui/progress/index.mjs.map +1 -0
- package/dist/components/ui/progress/progress.mjs +224 -0
- package/dist/components/ui/progress/progress.mjs.map +1 -0
- package/dist/components/ui/prose/index.mjs +6 -0
- package/dist/components/ui/prose/index.mjs.map +1 -0
- package/dist/components/ui/prose/prose.mjs +89 -0
- package/dist/components/ui/prose/prose.mjs.map +1 -0
- package/dist/components/ui/radio-group/index.mjs +15 -0
- package/dist/components/ui/radio-group/index.mjs.map +1 -0
- package/dist/components/ui/radio-group/radio-group.mjs +88 -0
- package/dist/components/ui/radio-group/radio-group.mjs.map +1 -0
- package/dist/components/ui/rating/index.mjs +6 -0
- package/dist/components/ui/rating/index.mjs.map +1 -0
- package/dist/components/ui/rating/rating.mjs +119 -0
- package/dist/components/ui/rating/rating.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/bubble-menu.mjs +120 -0
- package/dist/components/ui/rich-text-editor/bubble-menu.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/image-links.mjs +63 -0
- package/dist/components/ui/rich-text-editor/image-links.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/index.mjs +37 -0
- package/dist/components/ui/rich-text-editor/index.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/labels.mjs +27 -0
- package/dist/components/ui/rich-text-editor/labels.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/rich-text-editor.mjs +149 -0
- package/dist/components/ui/rich-text-editor/rich-text-editor.mjs.map +1 -0
- package/dist/components/ui/rich-text-editor/toolbar.mjs +325 -0
- package/dist/components/ui/rich-text-editor/toolbar.mjs.map +1 -0
- package/dist/components/ui/save-bar/index.mjs +13 -0
- package/dist/components/ui/save-bar/index.mjs.map +1 -0
- package/dist/components/ui/save-bar/save-bar.mjs +59 -0
- package/dist/components/ui/save-bar/save-bar.mjs.map +1 -0
- package/dist/components/ui/scroll-area/index.mjs +6 -0
- package/dist/components/ui/scroll-area/index.mjs.map +1 -0
- package/dist/components/ui/scroll-area/scroll-area.mjs +148 -0
- package/dist/components/ui/scroll-area/scroll-area.mjs.map +1 -0
- package/dist/components/ui/scroll-area/use-drag-scroll.mjs +134 -0
- package/dist/components/ui/scroll-area/use-drag-scroll.mjs.map +1 -0
- package/dist/components/ui/select/index.mjs +23 -0
- package/dist/components/ui/select/index.mjs.map +1 -0
- package/dist/components/ui/select/select.mjs +216 -0
- package/dist/components/ui/select/select.mjs.map +1 -0
- package/dist/components/ui/sheet/index.mjs +23 -0
- package/dist/components/ui/sheet/index.mjs.map +1 -0
- package/dist/components/ui/sheet/sheet.mjs +292 -0
- package/dist/components/ui/sheet/sheet.mjs.map +1 -0
- package/dist/components/ui/sidebar/index.mjs +122 -0
- package/dist/components/ui/sidebar/index.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-group.mjs +75 -0
- package/dist/components/ui/sidebar/sidebar-group.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-item.mjs +199 -0
- package/dist/components/ui/sidebar/sidebar-item.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-panels.mjs +182 -0
- package/dist/components/ui/sidebar/sidebar-panels.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-peek.mjs +324 -0
- package/dist/components/ui/sidebar/sidebar-peek.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-rich.mjs +65 -0
- package/dist/components/ui/sidebar/sidebar-rich.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar-tree.mjs +224 -0
- package/dist/components/ui/sidebar/sidebar-tree.mjs.map +1 -0
- package/dist/components/ui/sidebar/sidebar.mjs +205 -0
- package/dist/components/ui/sidebar/sidebar.mjs.map +1 -0
- package/dist/components/ui/sidebar/variants.mjs +396 -0
- package/dist/components/ui/sidebar/variants.mjs.map +1 -0
- package/dist/components/ui/signature/index.mjs +6 -0
- package/dist/components/ui/signature/index.mjs.map +1 -0
- package/dist/components/ui/signature/signature.mjs +145 -0
- package/dist/components/ui/signature/signature.mjs.map +1 -0
- package/dist/components/ui/signature-pad/index.mjs +19 -0
- package/dist/components/ui/signature-pad/index.mjs.map +1 -0
- package/dist/components/ui/signature-pad/signature-pad.mjs +210 -0
- package/dist/components/ui/signature-pad/signature-pad.mjs.map +1 -0
- package/dist/components/ui/signature-pad/strokes.mjs +68 -0
- package/dist/components/ui/signature-pad/strokes.mjs.map +1 -0
- package/dist/components/ui/skeleton/index.mjs +9 -0
- package/dist/components/ui/skeleton/index.mjs.map +1 -0
- package/dist/components/ui/skeleton/skeleton.mjs +58 -0
- package/dist/components/ui/skeleton/skeleton.mjs.map +1 -0
- package/dist/components/ui/slide/index.mjs +25 -0
- package/dist/components/ui/slide/index.mjs.map +1 -0
- package/dist/components/ui/slide/slide.mjs +159 -0
- package/dist/components/ui/slide/slide.mjs.map +1 -0
- package/dist/components/ui/slider/index.mjs +21 -0
- package/dist/components/ui/slider/index.mjs.map +1 -0
- package/dist/components/ui/slider/slider-input.mjs +449 -0
- package/dist/components/ui/slider/slider-input.mjs.map +1 -0
- package/dist/components/ui/slider/slider.mjs +235 -0
- package/dist/components/ui/slider/slider.mjs.map +1 -0
- package/dist/components/ui/slides/index.mjs +31 -0
- package/dist/components/ui/slides/index.mjs.map +1 -0
- package/dist/components/ui/slides/slides.mjs +890 -0
- package/dist/components/ui/slides/slides.mjs.map +1 -0
- package/dist/components/ui/smooth-anchors/index.mjs +17 -0
- package/dist/components/ui/smooth-anchors/index.mjs.map +1 -0
- package/dist/components/ui/smooth-anchors/smooth-anchors.mjs +75 -0
- package/dist/components/ui/smooth-anchors/smooth-anchors.mjs.map +1 -0
- package/dist/components/ui/smooth-anchors/smooth-scroll.mjs +87 -0
- package/dist/components/ui/smooth-anchors/smooth-scroll.mjs.map +1 -0
- package/dist/components/ui/spinner/index.mjs +6 -0
- package/dist/components/ui/spinner/index.mjs.map +1 -0
- package/dist/components/ui/spinner/spinner.mjs +49 -0
- package/dist/components/ui/spinner/spinner.mjs.map +1 -0
- package/dist/components/ui/stat/index.mjs +29 -0
- package/dist/components/ui/stat/index.mjs.map +1 -0
- package/dist/components/ui/stat/stat.mjs +226 -0
- package/dist/components/ui/stat/stat.mjs.map +1 -0
- package/dist/components/ui/status-bar/index.mjs +17 -0
- package/dist/components/ui/status-bar/index.mjs.map +1 -0
- package/dist/components/ui/status-bar/status-bar.mjs +96 -0
- package/dist/components/ui/status-bar/status-bar.mjs.map +1 -0
- package/dist/components/ui/stepper/index.mjs +25 -0
- package/dist/components/ui/stepper/index.mjs.map +1 -0
- package/dist/components/ui/stepper/stepper.mjs +235 -0
- package/dist/components/ui/stepper/stepper.mjs.map +1 -0
- package/dist/components/ui/steps/index.mjs +9 -0
- package/dist/components/ui/steps/index.mjs.map +1 -0
- package/dist/components/ui/steps/steps.mjs +70 -0
- package/dist/components/ui/steps/steps.mjs.map +1 -0
- package/dist/components/ui/swatch-grid/index.mjs +7 -0
- package/dist/components/ui/swatch-grid/index.mjs.map +1 -0
- package/dist/components/ui/swatch-grid/swatch-grid.mjs +110 -0
- package/dist/components/ui/swatch-grid/swatch-grid.mjs.map +1 -0
- package/dist/components/ui/switch/index.mjs +7 -0
- package/dist/components/ui/switch/index.mjs.map +1 -0
- package/dist/components/ui/switch/switch.mjs +79 -0
- package/dist/components/ui/switch/switch.mjs.map +1 -0
- package/dist/components/ui/tab-strip/index.mjs +13 -0
- package/dist/components/ui/tab-strip/index.mjs.map +1 -0
- package/dist/components/ui/tab-strip/tab-strip.mjs +244 -0
- package/dist/components/ui/tab-strip/tab-strip.mjs.map +1 -0
- package/dist/components/ui/table/index.mjs +27 -0
- package/dist/components/ui/table/index.mjs.map +1 -0
- package/dist/components/ui/table/table.mjs +290 -0
- package/dist/components/ui/table/table.mjs.map +1 -0
- package/dist/components/ui/table-of-contents/index.mjs +20 -0
- package/dist/components/ui/table-of-contents/index.mjs.map +1 -0
- package/dist/components/ui/table-of-contents/scroll-spy.mjs +60 -0
- package/dist/components/ui/table-of-contents/scroll-spy.mjs.map +1 -0
- package/dist/components/ui/table-of-contents/table-of-contents.mjs +371 -0
- package/dist/components/ui/table-of-contents/table-of-contents.mjs.map +1 -0
- package/dist/components/ui/table-of-contents/use-headings.mjs +40 -0
- package/dist/components/ui/table-of-contents/use-headings.mjs.map +1 -0
- package/dist/components/ui/tablet-frame/index.mjs +7 -0
- package/dist/components/ui/tablet-frame/index.mjs.map +1 -0
- package/dist/components/ui/tablet-frame/tablet-frame.mjs +48 -0
- package/dist/components/ui/tablet-frame/tablet-frame.mjs.map +1 -0
- package/dist/components/ui/tabs/index.mjs +25 -0
- package/dist/components/ui/tabs/index.mjs.map +1 -0
- package/dist/components/ui/tabs/tabs.mjs +382 -0
- package/dist/components/ui/tabs/tabs.mjs.map +1 -0
- package/dist/components/ui/tabs/use-tabs-indicator.mjs +90 -0
- package/dist/components/ui/tabs/use-tabs-indicator.mjs.map +1 -0
- package/dist/components/ui/tags-input/index.mjs +9 -0
- package/dist/components/ui/tags-input/index.mjs.map +1 -0
- package/dist/components/ui/tags-input/split.mjs +38 -0
- package/dist/components/ui/tags-input/split.mjs.map +1 -0
- package/dist/components/ui/tags-input/tags-input.mjs +328 -0
- package/dist/components/ui/tags-input/tags-input.mjs.map +1 -0
- package/dist/components/ui/terminal/index.mjs +41 -0
- package/dist/components/ui/terminal/index.mjs.map +1 -0
- package/dist/components/ui/terminal/terminal.mjs +287 -0
- package/dist/components/ui/terminal/terminal.mjs.map +1 -0
- package/dist/components/ui/textarea/index.mjs +21 -0
- package/dist/components/ui/textarea/index.mjs.map +1 -0
- package/dist/components/ui/textarea/textarea.mjs +244 -0
- package/dist/components/ui/textarea/textarea.mjs.map +1 -0
- package/dist/components/ui/theme-provider/index.mjs +6 -0
- package/dist/components/ui/theme-provider/index.mjs.map +1 -0
- package/dist/components/ui/theme-provider/theme-provider.mjs +70 -0
- package/dist/components/ui/theme-provider/theme-provider.mjs.map +1 -0
- package/dist/components/ui/toast/index.mjs +19 -0
- package/dist/components/ui/toast/index.mjs.map +1 -0
- package/dist/components/ui/toast/store.mjs +96 -0
- package/dist/components/ui/toast/store.mjs.map +1 -0
- package/dist/components/ui/toast/toast.mjs +395 -0
- package/dist/components/ui/toast/toast.mjs.map +1 -0
- package/dist/components/ui/toggle/index.mjs +13 -0
- package/dist/components/ui/toggle/index.mjs.map +1 -0
- package/dist/components/ui/toggle/toggle.mjs +123 -0
- package/dist/components/ui/toggle/toggle.mjs.map +1 -0
- package/dist/components/ui/toggle-group/index.mjs +11 -0
- package/dist/components/ui/toggle-group/index.mjs.map +1 -0
- package/dist/components/ui/toggle-group/toggle-group.mjs +243 -0
- package/dist/components/ui/toggle-group/toggle-group.mjs.map +1 -0
- package/dist/components/ui/toggletip/index.mjs +6 -0
- package/dist/components/ui/toggletip/index.mjs.map +1 -0
- package/dist/components/ui/toggletip/toggletip.mjs +95 -0
- package/dist/components/ui/toggletip/toggletip.mjs.map +1 -0
- package/dist/components/ui/toolbar/index.mjs +21 -0
- package/dist/components/ui/toolbar/index.mjs.map +1 -0
- package/dist/components/ui/toolbar/toolbar.mjs +130 -0
- package/dist/components/ui/toolbar/toolbar.mjs.map +1 -0
- package/dist/components/ui/tooltip/index.mjs +29 -0
- package/dist/components/ui/tooltip/index.mjs.map +1 -0
- package/dist/components/ui/tooltip/tooltip.mjs +640 -0
- package/dist/components/ui/tooltip/tooltip.mjs.map +1 -0
- package/dist/components/ui/tree/index.mjs +11 -0
- package/dist/components/ui/tree/index.mjs.map +1 -0
- package/dist/components/ui/tree/tree.mjs +450 -0
- package/dist/components/ui/tree/tree.mjs.map +1 -0
- package/dist/index.d.mts +19397 -0
- package/dist/index.mjs +157 -0
- package/dist/index.mjs.map +1 -0
- package/dist/lib/color.mjs +78 -0
- package/dist/lib/color.mjs.map +1 -0
- package/dist/lib/create-context.mjs +31 -0
- package/dist/lib/create-context.mjs.map +1 -0
- package/dist/lib/date.mjs +116 -0
- package/dist/lib/date.mjs.map +1 -0
- package/dist/lib/density.mjs +79 -0
- package/dist/lib/density.mjs.map +1 -0
- package/dist/lib/field-context.mjs +13 -0
- package/dist/lib/field-context.mjs.map +1 -0
- package/dist/lib/filter.mjs +28 -0
- package/dist/lib/filter.mjs.map +1 -0
- package/dist/lib/gesture.mjs +38 -0
- package/dist/lib/gesture.mjs.map +1 -0
- package/dist/lib/hit-area.mjs +14 -0
- package/dist/lib/hit-area.mjs.map +1 -0
- package/dist/lib/labels.mjs +27 -0
- package/dist/lib/labels.mjs.map +1 -0
- package/dist/lib/morph-box.mjs +56 -0
- package/dist/lib/morph-box.mjs.map +1 -0
- package/dist/lib/motion.mjs +70 -0
- package/dist/lib/motion.mjs.map +1 -0
- package/dist/lib/pulse.mjs +69 -0
- package/dist/lib/pulse.mjs.map +1 -0
- package/dist/lib/roving-focus.mjs +74 -0
- package/dist/lib/roving-focus.mjs.map +1 -0
- package/dist/lib/theme.mjs +67 -0
- package/dist/lib/theme.mjs.map +1 -0
- package/dist/lib/tv.mjs +11 -0
- package/dist/lib/tv.mjs.map +1 -0
- package/dist/lib/utils.mjs +82 -0
- package/dist/lib/utils.mjs.map +1 -0
- package/dist/styles.css +2 -0
- package/package.json +133 -4
|
@@ -0,0 +1,534 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
+
import * as React from "react";
|
|
4
|
+
import { cn } from "../../../lib/utils.mjs";
|
|
5
|
+
import {
|
|
6
|
+
atMinutes,
|
|
7
|
+
busyRanges,
|
|
8
|
+
clamp,
|
|
9
|
+
durationMinutes,
|
|
10
|
+
eventOnDay,
|
|
11
|
+
eventSize,
|
|
12
|
+
formatEventLabel,
|
|
13
|
+
formatHour,
|
|
14
|
+
formatTime,
|
|
15
|
+
formatTimeRange,
|
|
16
|
+
gapAround,
|
|
17
|
+
isSameDay,
|
|
18
|
+
isWeekend,
|
|
19
|
+
layoutDay,
|
|
20
|
+
minutesOfDay,
|
|
21
|
+
snap,
|
|
22
|
+
snapFlush,
|
|
23
|
+
sortEvents,
|
|
24
|
+
startOfDay
|
|
25
|
+
} from "./calendar-math.mjs";
|
|
26
|
+
import { useEventCalendar } from "./context.mjs";
|
|
27
|
+
import { eventBlockVariants, tintStyle } from "./event-block.mjs";
|
|
28
|
+
import { onEventKeyDown } from "./event-keys.mjs";
|
|
29
|
+
const DRAG_THRESHOLD = 4;
|
|
30
|
+
const EDGE = 6;
|
|
31
|
+
const AUTOSCROLL_ZONE = 40;
|
|
32
|
+
const DAY_MS = 864e5;
|
|
33
|
+
const LONG_PRESS = 450;
|
|
34
|
+
const TOUCH_SLOP = 8;
|
|
35
|
+
function TimeGrid() {
|
|
36
|
+
const cal = useEventCalendar("EventCalendarBody");
|
|
37
|
+
const { days, hourHeight, startHour, endHour, snapMinutes, locale, now, labels } = cal;
|
|
38
|
+
const pxPerMin = hourHeight / 60;
|
|
39
|
+
const lo = startHour * 60;
|
|
40
|
+
const hi = endHour * 60;
|
|
41
|
+
const scrollerRef = React.useRef(null);
|
|
42
|
+
const gesture = React.useRef(null);
|
|
43
|
+
const lastPoint = React.useRef(null);
|
|
44
|
+
const frame = React.useRef(0);
|
|
45
|
+
const [drag, setDrag] = React.useState(null);
|
|
46
|
+
const [sweep, setSweep] = React.useState(null);
|
|
47
|
+
React.useLayoutEffect(() => {
|
|
48
|
+
const scroller = scrollerRef.current;
|
|
49
|
+
if (scroller) scroller.scrollTop = Math.max(0, (cal.scrollToHour - startHour) * hourHeight);
|
|
50
|
+
}, [cal.scrollToHour, startHour, hourHeight]);
|
|
51
|
+
const pointAt = (x, y) => {
|
|
52
|
+
const columns = Array.from(
|
|
53
|
+
scrollerRef.current?.querySelectorAll("[data-slot=event-calendar-column]") ?? []
|
|
54
|
+
);
|
|
55
|
+
if (!columns.length) return null;
|
|
56
|
+
const rects = columns.map((c) => c.getBoundingClientRect());
|
|
57
|
+
let index = rects.findIndex((r) => x >= r.left && x < r.right);
|
|
58
|
+
if (index === -1) {
|
|
59
|
+
const leftmost = rects.reduce((a, r, i) => r.left < rects[a].left ? i : a, 0);
|
|
60
|
+
const rightmost = rects.reduce((a, r, i) => r.right > rects[a].right ? i : a, 0);
|
|
61
|
+
index = x < rects[leftmost].left ? leftmost : rightmost;
|
|
62
|
+
}
|
|
63
|
+
return {
|
|
64
|
+
day: new Date(Number(columns[index].dataset.day)),
|
|
65
|
+
minutes: (y - rects[index].top) / pxPerMin + lo
|
|
66
|
+
};
|
|
67
|
+
};
|
|
68
|
+
const update = (x, y, shift = false, alt = false) => {
|
|
69
|
+
const g = gesture.current;
|
|
70
|
+
const point = pointAt(x, y);
|
|
71
|
+
if (!g || !point) return;
|
|
72
|
+
const smart = cal.smartFill && !alt;
|
|
73
|
+
if (g.kind === "sweep") {
|
|
74
|
+
const to = clamp(snap(point.minutes, snapMinutes), lo, hi);
|
|
75
|
+
const from = Math.min(g.from, to);
|
|
76
|
+
const end = Math.max(g.from, to) === from ? from + snapMinutes : Math.max(g.from, to);
|
|
77
|
+
g.span = [from, end];
|
|
78
|
+
setSweep({ day: g.day, from, to: end });
|
|
79
|
+
return;
|
|
80
|
+
}
|
|
81
|
+
const ev = g.event;
|
|
82
|
+
let next;
|
|
83
|
+
if (g.mode === "move") {
|
|
84
|
+
const length = durationMinutes(ev.start, ev.end);
|
|
85
|
+
let startMin = clamp(snap(point.minutes - g.grab, snapMinutes), lo, Math.max(lo, hi - Math.min(length, hi - lo)));
|
|
86
|
+
let endMin = startMin + length;
|
|
87
|
+
const busy = smart ? busyRanges(cal.events, point.day, ev.id) : [];
|
|
88
|
+
const gap = smart && shift ? gapAround(busy, point.minutes, lo, hi) : null;
|
|
89
|
+
if (gap) [startMin, endMin] = gap;
|
|
90
|
+
else if (smart) [startMin, endMin] = snapFlush([startMin, endMin], busy, "move");
|
|
91
|
+
const start = atMinutes(point.day, startMin);
|
|
92
|
+
next = { ...ev, start, end: gap ? atMinutes(point.day, endMin) : new Date(start.getTime() + length * 6e4) };
|
|
93
|
+
} else {
|
|
94
|
+
const day = startOfDay(ev.start);
|
|
95
|
+
const startMin = minutesOfDay(ev.start);
|
|
96
|
+
const endMin = isSameDay(ev.start, ev.end) ? minutesOfDay(ev.end) : 24 * 60;
|
|
97
|
+
let range = g.mode === "end" ? [startMin, clamp(snap(point.minutes, snapMinutes), startMin + snapMinutes, hi)] : [clamp(snap(point.minutes, snapMinutes), lo, endMin - snapMinutes), endMin];
|
|
98
|
+
if (smart) range = snapFlush(range, busyRanges(cal.events, day, ev.id), g.mode);
|
|
99
|
+
next = { ...ev, start: atMinutes(day, range[0]), end: atMinutes(day, range[1]) };
|
|
100
|
+
}
|
|
101
|
+
g.preview = next;
|
|
102
|
+
setDrag({ id: ev.id, preview: next });
|
|
103
|
+
};
|
|
104
|
+
const tick = () => {
|
|
105
|
+
const scroller = scrollerRef.current;
|
|
106
|
+
const point = lastPoint.current;
|
|
107
|
+
if (!scroller || !point || !gesture.current?.active) {
|
|
108
|
+
frame.current = 0;
|
|
109
|
+
return;
|
|
110
|
+
}
|
|
111
|
+
const r = scroller.getBoundingClientRect();
|
|
112
|
+
let dy = 0;
|
|
113
|
+
if (point.y < r.top + AUTOSCROLL_ZONE) dy = -Math.ceil((r.top + AUTOSCROLL_ZONE - point.y) / 4);
|
|
114
|
+
else if (point.y > r.bottom - AUTOSCROLL_ZONE) dy = Math.ceil((point.y - (r.bottom - AUTOSCROLL_ZONE)) / 4);
|
|
115
|
+
if (dy) {
|
|
116
|
+
scroller.scrollTop += dy;
|
|
117
|
+
update(point.x, point.y, point.shift, point.alt);
|
|
118
|
+
}
|
|
119
|
+
frame.current = requestAnimationFrame(tick);
|
|
120
|
+
};
|
|
121
|
+
const finish = (commit) => {
|
|
122
|
+
const g = gesture.current;
|
|
123
|
+
gesture.current = null;
|
|
124
|
+
if (g?.timer) clearTimeout(g.timer);
|
|
125
|
+
cancelAnimationFrame(frame.current);
|
|
126
|
+
frame.current = 0;
|
|
127
|
+
setDrag(null);
|
|
128
|
+
setSweep(null);
|
|
129
|
+
if (!g || !commit) return;
|
|
130
|
+
if (g.kind === "event") {
|
|
131
|
+
if (!g.active) cal.openEvent(g.event);
|
|
132
|
+
else if (g.preview && (g.preview.start.getTime() !== g.event.start.getTime() || g.preview.end.getTime() !== g.event.end.getTime())) {
|
|
133
|
+
cal.changeEvent(g.preview);
|
|
134
|
+
}
|
|
135
|
+
return;
|
|
136
|
+
}
|
|
137
|
+
if (g.active && g.span) {
|
|
138
|
+
cal.createAt({ start: atMinutes(g.day, g.span[0]), end: atMinutes(g.day, g.span[1]), allDay: false });
|
|
139
|
+
} else if (!g.active && !g.touch) cal.setSelectedEventId(null);
|
|
140
|
+
};
|
|
141
|
+
const onEscape = React.useEffectEvent((event) => {
|
|
142
|
+
if (event.key !== "Escape" || !gesture.current) return;
|
|
143
|
+
event.preventDefault();
|
|
144
|
+
event.stopPropagation();
|
|
145
|
+
finish(false);
|
|
146
|
+
});
|
|
147
|
+
const gesturing = drag !== null || sweep !== null;
|
|
148
|
+
React.useEffect(() => {
|
|
149
|
+
if (!gesturing) return;
|
|
150
|
+
window.addEventListener("keydown", onEscape, true);
|
|
151
|
+
return () => window.removeEventListener("keydown", onEscape, true);
|
|
152
|
+
}, [gesturing]);
|
|
153
|
+
React.useEffect(() => () => cancelAnimationFrame(frame.current), []);
|
|
154
|
+
const onPointerMove = (e) => {
|
|
155
|
+
const g = gesture.current;
|
|
156
|
+
if (!g || g.pointerId !== e.pointerId) return;
|
|
157
|
+
lastPoint.current = { x: e.clientX, y: e.clientY, shift: e.shiftKey, alt: e.altKey };
|
|
158
|
+
if (!g.active) {
|
|
159
|
+
const moved = Math.hypot(e.clientX - g.x, e.clientY - g.y);
|
|
160
|
+
if (g.touch) {
|
|
161
|
+
if (moved > TOUCH_SLOP) finish(false);
|
|
162
|
+
return;
|
|
163
|
+
}
|
|
164
|
+
if (moved < DRAG_THRESHOLD || !cal.editable) return;
|
|
165
|
+
g.active = true;
|
|
166
|
+
frame.current = requestAnimationFrame(tick);
|
|
167
|
+
}
|
|
168
|
+
update(e.clientX, e.clientY, e.shiftKey, e.altKey);
|
|
169
|
+
};
|
|
170
|
+
const longPress = () => {
|
|
171
|
+
const g = gesture.current;
|
|
172
|
+
if (!g || g.active || !cal.editable) return;
|
|
173
|
+
navigator.vibrate?.(10);
|
|
174
|
+
if (g.kind === "sweep") {
|
|
175
|
+
gesture.current = null;
|
|
176
|
+
cal.createAt(
|
|
177
|
+
{ start: atMinutes(g.day, g.from), end: atMinutes(g.day, g.from + cal.defaultDuration), allDay: false },
|
|
178
|
+
{ fit: true }
|
|
179
|
+
);
|
|
180
|
+
return;
|
|
181
|
+
}
|
|
182
|
+
g.active = true;
|
|
183
|
+
g.preview = g.event;
|
|
184
|
+
setDrag({ id: g.event.id, preview: g.event });
|
|
185
|
+
frame.current = requestAnimationFrame(tick);
|
|
186
|
+
};
|
|
187
|
+
React.useEffect(() => {
|
|
188
|
+
const scroller = scrollerRef.current;
|
|
189
|
+
if (!scroller) return;
|
|
190
|
+
const onTouchMove = (event) => {
|
|
191
|
+
if (gesture.current?.active && gesture.current.touch) event.preventDefault();
|
|
192
|
+
};
|
|
193
|
+
scroller.addEventListener("touchmove", onTouchMove, { passive: false });
|
|
194
|
+
return () => scroller.removeEventListener("touchmove", onTouchMove);
|
|
195
|
+
}, []);
|
|
196
|
+
const gestureHandlers = {
|
|
197
|
+
onPointerMove,
|
|
198
|
+
onPointerUp: (e) => {
|
|
199
|
+
if (gesture.current?.pointerId === e.pointerId) finish(true);
|
|
200
|
+
},
|
|
201
|
+
onPointerCancel: () => finish(false),
|
|
202
|
+
onLostPointerCapture: () => {
|
|
203
|
+
if (gesture.current) finish(false);
|
|
204
|
+
}
|
|
205
|
+
};
|
|
206
|
+
const startEventGesture = (e, event) => {
|
|
207
|
+
if (e.button !== 0) return;
|
|
208
|
+
e.stopPropagation();
|
|
209
|
+
const el = e.currentTarget;
|
|
210
|
+
const r = el.getBoundingClientRect();
|
|
211
|
+
let mode = "move";
|
|
212
|
+
if (cal.editable && r.height >= 24) {
|
|
213
|
+
if (e.clientY - r.top < EDGE) mode = "start";
|
|
214
|
+
else if (r.bottom - e.clientY < EDGE) mode = "end";
|
|
215
|
+
}
|
|
216
|
+
const point = pointAt(e.clientX, e.clientY);
|
|
217
|
+
const dayOffset = point ? Math.round((point.day.getTime() - startOfDay(event.start).getTime()) / DAY_MS) : 0;
|
|
218
|
+
const grab = point ? point.minutes + dayOffset * 1440 - minutesOfDay(event.start) : 0;
|
|
219
|
+
const touch = e.pointerType === "touch";
|
|
220
|
+
if (!touch) el.setPointerCapture(e.pointerId);
|
|
221
|
+
gesture.current = {
|
|
222
|
+
kind: "event",
|
|
223
|
+
pointerId: e.pointerId,
|
|
224
|
+
x: e.clientX,
|
|
225
|
+
y: e.clientY,
|
|
226
|
+
event,
|
|
227
|
+
mode: touch ? "move" : mode,
|
|
228
|
+
grab,
|
|
229
|
+
active: false,
|
|
230
|
+
preview: null,
|
|
231
|
+
touch,
|
|
232
|
+
timer: touch ? setTimeout(longPress, LONG_PRESS) : void 0
|
|
233
|
+
};
|
|
234
|
+
};
|
|
235
|
+
const startSweep = (e, day) => {
|
|
236
|
+
if (e.button !== 0 || e.target.closest("[data-slot=event-calendar-event]")) return;
|
|
237
|
+
const point = pointAt(e.clientX, e.clientY);
|
|
238
|
+
if (!point) return;
|
|
239
|
+
const touch = e.pointerType === "touch";
|
|
240
|
+
if (!touch) e.currentTarget.setPointerCapture(e.pointerId);
|
|
241
|
+
gesture.current = {
|
|
242
|
+
kind: "sweep",
|
|
243
|
+
touch,
|
|
244
|
+
timer: touch ? setTimeout(longPress, LONG_PRESS) : void 0,
|
|
245
|
+
pointerId: e.pointerId,
|
|
246
|
+
x: e.clientX,
|
|
247
|
+
y: e.clientY,
|
|
248
|
+
day,
|
|
249
|
+
from: clamp(Math.floor(point.minutes / snapMinutes) * snapMinutes, lo, hi - snapMinutes),
|
|
250
|
+
active: false,
|
|
251
|
+
span: null
|
|
252
|
+
};
|
|
253
|
+
};
|
|
254
|
+
const createByDoubleClick = (e, day) => {
|
|
255
|
+
if (e.target.closest("[data-slot=event-calendar-event]")) return;
|
|
256
|
+
const point = pointAt(e.clientX, e.clientY);
|
|
257
|
+
if (!point) return;
|
|
258
|
+
const startMin = clamp(Math.floor(point.minutes / 30) * 30, lo, hi - cal.defaultDuration);
|
|
259
|
+
cal.createAt(
|
|
260
|
+
{ start: atMinutes(day, startMin), end: atMinutes(day, startMin + cal.defaultDuration), allDay: false },
|
|
261
|
+
{ fit: true }
|
|
262
|
+
);
|
|
263
|
+
};
|
|
264
|
+
const showNow = now !== null && days.some((d) => isSameDay(d, now));
|
|
265
|
+
const nowMin = now ? minutesOfDay(now) : 0;
|
|
266
|
+
const nowVisible = showNow && nowMin >= lo && nowMin <= hi;
|
|
267
|
+
const nowTop = (nowMin - lo) * pxPerMin;
|
|
268
|
+
const hours = Array.from({ length: endHour - startHour }, (_, i) => startHour + i);
|
|
269
|
+
const allDay = (day) => cal.events.filter((e) => e.allDay && eventOnDay(e, day)).sort(sortEvents);
|
|
270
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
271
|
+
/* @__PURE__ */ jsxs(
|
|
272
|
+
"div",
|
|
273
|
+
{
|
|
274
|
+
"data-slot": "event-calendar-day-heads",
|
|
275
|
+
className: "flex overflow-hidden border-b border-border [scrollbar-gutter:stable]",
|
|
276
|
+
children: [
|
|
277
|
+
/* @__PURE__ */ jsx("div", { className: "w-16 shrink-0" }),
|
|
278
|
+
days.map((day) => /* @__PURE__ */ jsx(DayHead, { day }, day.getTime()))
|
|
279
|
+
]
|
|
280
|
+
}
|
|
281
|
+
),
|
|
282
|
+
/* @__PURE__ */ jsxs(
|
|
283
|
+
"div",
|
|
284
|
+
{
|
|
285
|
+
"data-slot": "event-calendar-all-day",
|
|
286
|
+
className: "flex overflow-hidden border-b border-border [scrollbar-gutter:stable]",
|
|
287
|
+
children: [
|
|
288
|
+
/* @__PURE__ */ jsx("div", { className: "flex w-16 shrink-0 items-start justify-end py-1.5 pr-2 text-xs text-muted-foreground", children: labels.allDay }),
|
|
289
|
+
days.map((day) => /* @__PURE__ */ jsx(
|
|
290
|
+
"div",
|
|
291
|
+
{
|
|
292
|
+
"data-weekend": isWeekend(day) ? "" : void 0,
|
|
293
|
+
className: "flex min-h-8 min-w-0 flex-1 flex-col gap-0.5 border-l border-border p-0.5 data-[weekend]:bg-muted/40",
|
|
294
|
+
onDoubleClick: (e) => {
|
|
295
|
+
if (e.target.closest("[data-slot=event-calendar-event]")) return;
|
|
296
|
+
cal.createAt({ start: startOfDay(day), end: startOfDay(day), allDay: true });
|
|
297
|
+
},
|
|
298
|
+
children: allDay(day).map((event) => /* @__PURE__ */ jsx(AllDayBar, { event, day }, event.id))
|
|
299
|
+
},
|
|
300
|
+
day.getTime()
|
|
301
|
+
))
|
|
302
|
+
]
|
|
303
|
+
}
|
|
304
|
+
),
|
|
305
|
+
/* @__PURE__ */ jsx(
|
|
306
|
+
"div",
|
|
307
|
+
{
|
|
308
|
+
ref: scrollerRef,
|
|
309
|
+
"data-slot": "event-calendar-scroller",
|
|
310
|
+
className: "relative min-h-0 flex-1 overflow-y-auto overscroll-contain [scrollbar-gutter:stable]",
|
|
311
|
+
children: /* @__PURE__ */ jsxs("div", { className: "relative flex", style: { height: (hi - lo) * pxPerMin }, children: [
|
|
312
|
+
/* @__PURE__ */ jsxs("div", { "aria-hidden": true, className: "relative w-16 shrink-0", children: [
|
|
313
|
+
hours.slice(1).map((hour) => /* @__PURE__ */ jsx(
|
|
314
|
+
"span",
|
|
315
|
+
{
|
|
316
|
+
className: "absolute right-2 -translate-y-1/2 text-xs whitespace-nowrap text-muted-foreground tabular-nums",
|
|
317
|
+
style: { top: (hour - startHour) * hourHeight },
|
|
318
|
+
children: formatHour(hour, locale)
|
|
319
|
+
},
|
|
320
|
+
hour
|
|
321
|
+
)),
|
|
322
|
+
nowVisible && now ? /* @__PURE__ */ jsx(
|
|
323
|
+
"span",
|
|
324
|
+
{
|
|
325
|
+
className: "absolute right-1 z-20 -translate-y-1/2 bg-(--surface) px-1 text-xs font-medium whitespace-nowrap text-primary tabular-nums",
|
|
326
|
+
style: { top: nowTop },
|
|
327
|
+
children: formatTime(now, locale)
|
|
328
|
+
}
|
|
329
|
+
) : null
|
|
330
|
+
] }),
|
|
331
|
+
days.map((day) => {
|
|
332
|
+
const positioned = layoutDay(cal.events, day);
|
|
333
|
+
const isToday = now !== null && isSameDay(day, now);
|
|
334
|
+
const previewHere = drag && !drag.preview.allDay && isSameDay(drag.preview.start, day) ? drag.preview : null;
|
|
335
|
+
return /* @__PURE__ */ jsxs(
|
|
336
|
+
"div",
|
|
337
|
+
{
|
|
338
|
+
"data-slot": "event-calendar-column",
|
|
339
|
+
"data-day": day.getTime(),
|
|
340
|
+
"data-weekend": isWeekend(day) ? "" : void 0,
|
|
341
|
+
"data-today": isToday ? "" : void 0,
|
|
342
|
+
className: cn(
|
|
343
|
+
"relative min-w-0 flex-1 touch-pan-y border-l border-border select-none data-[weekend]:bg-muted/40",
|
|
344
|
+
"[background-image:linear-gradient(to_bottom,var(--border)_1px,transparent_1px)] [background-size:100%_var(--hour)]"
|
|
345
|
+
),
|
|
346
|
+
style: { "--hour": `${hourHeight}px` },
|
|
347
|
+
onPointerDown: (e) => startSweep(e, day),
|
|
348
|
+
onDoubleClick: (e) => createByDoubleClick(e, day),
|
|
349
|
+
...gestureHandlers,
|
|
350
|
+
children: [
|
|
351
|
+
positioned.map((p) => /* @__PURE__ */ jsx(
|
|
352
|
+
TimedEvent,
|
|
353
|
+
{
|
|
354
|
+
positioned: p,
|
|
355
|
+
ghost: drag?.id === p.event.id,
|
|
356
|
+
onPointerDown: (e) => startEventGesture(e, p.event),
|
|
357
|
+
gestureHandlers
|
|
358
|
+
},
|
|
359
|
+
p.event.id
|
|
360
|
+
)),
|
|
361
|
+
previewHere ? /* @__PURE__ */ jsx(
|
|
362
|
+
TimedEvent,
|
|
363
|
+
{
|
|
364
|
+
positioned: {
|
|
365
|
+
event: previewHere,
|
|
366
|
+
startMin: minutesOfDay(previewHere.start),
|
|
367
|
+
endMin: isSameDay(previewHere.start, previewHere.end) ? minutesOfDay(previewHere.end) : 1440,
|
|
368
|
+
left: 0,
|
|
369
|
+
width: 1
|
|
370
|
+
},
|
|
371
|
+
dragging: true
|
|
372
|
+
}
|
|
373
|
+
) : null,
|
|
374
|
+
sweep && isSameDay(sweep.day, day) ? /* @__PURE__ */ jsx(
|
|
375
|
+
"div",
|
|
376
|
+
{
|
|
377
|
+
"data-slot": "event-calendar-sweep",
|
|
378
|
+
"aria-hidden": true,
|
|
379
|
+
className: "pointer-events-none absolute inset-x-0.5 z-20 rounded-sm bg-primary/15 px-2 py-1 text-xs font-medium text-primary tabular-nums ring-1 ring-primary/40",
|
|
380
|
+
style: { top: (sweep.from - lo) * pxPerMin, height: (sweep.to - sweep.from) * pxPerMin - 1 },
|
|
381
|
+
children: formatTimeRange(atMinutes(day, sweep.from), atMinutes(day, sweep.to), locale)
|
|
382
|
+
}
|
|
383
|
+
) : null,
|
|
384
|
+
nowVisible ? /* @__PURE__ */ jsx(
|
|
385
|
+
"div",
|
|
386
|
+
{
|
|
387
|
+
"aria-hidden": true,
|
|
388
|
+
"data-slot": "event-calendar-now",
|
|
389
|
+
className: cn(
|
|
390
|
+
"pointer-events-none absolute inset-x-0 z-20 -translate-y-1/2",
|
|
391
|
+
isToday ? "h-0.5 bg-primary before:absolute before:top-1/2 before:-left-1 before:size-2 before:-translate-y-1/2 before:rounded-full before:bg-primary" : "h-px bg-primary/35"
|
|
392
|
+
),
|
|
393
|
+
style: { top: nowTop }
|
|
394
|
+
}
|
|
395
|
+
) : null
|
|
396
|
+
]
|
|
397
|
+
},
|
|
398
|
+
day.getTime()
|
|
399
|
+
);
|
|
400
|
+
})
|
|
401
|
+
] })
|
|
402
|
+
}
|
|
403
|
+
)
|
|
404
|
+
] });
|
|
405
|
+
}
|
|
406
|
+
function DayHead({ day }) {
|
|
407
|
+
const cal = useEventCalendar("EventCalendarBody");
|
|
408
|
+
const isToday = cal.now !== null && isSameDay(day, cal.now);
|
|
409
|
+
const weekday = new Intl.DateTimeFormat(cal.locale, { weekday: "short" }).format(day);
|
|
410
|
+
const full = new Intl.DateTimeFormat(cal.locale, { weekday: "long", month: "long", day: "numeric" }).format(day);
|
|
411
|
+
const canOpen = cal.view === "week" && cal.views.includes("day");
|
|
412
|
+
const content = /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
413
|
+
/* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: weekday }),
|
|
414
|
+
/* @__PURE__ */ jsx(
|
|
415
|
+
"span",
|
|
416
|
+
{
|
|
417
|
+
className: cn(
|
|
418
|
+
"inline-flex size-7 items-center justify-center rounded-full text-sm font-semibold tabular-nums",
|
|
419
|
+
isToday && "bg-primary text-primary-foreground"
|
|
420
|
+
),
|
|
421
|
+
children: day.getDate()
|
|
422
|
+
}
|
|
423
|
+
)
|
|
424
|
+
] });
|
|
425
|
+
const className = cn(
|
|
426
|
+
"flex min-w-0 flex-1 flex-col items-center gap-0.5 border-l border-border py-1.5 data-[weekend]:bg-muted/40",
|
|
427
|
+
canOpen && "cursor-pointer outline-none transition-[background-color] duration-fast hover:bg-accent focus-visible:ring-2 focus-visible:ring-focus focus-visible:ring-inset"
|
|
428
|
+
);
|
|
429
|
+
if (!canOpen) {
|
|
430
|
+
return /* @__PURE__ */ jsx("div", { "data-slot": "event-calendar-day-head", "data-weekend": isWeekend(day) ? "" : void 0, "aria-label": full, className, children: content });
|
|
431
|
+
}
|
|
432
|
+
return /* @__PURE__ */ jsx(
|
|
433
|
+
"button",
|
|
434
|
+
{
|
|
435
|
+
type: "button",
|
|
436
|
+
"data-slot": "event-calendar-day-head",
|
|
437
|
+
"data-weekend": isWeekend(day) ? "" : void 0,
|
|
438
|
+
"aria-label": full,
|
|
439
|
+
"aria-current": isToday ? "date" : void 0,
|
|
440
|
+
className,
|
|
441
|
+
onClick: () => {
|
|
442
|
+
cal.setDate(day);
|
|
443
|
+
cal.setView("day");
|
|
444
|
+
},
|
|
445
|
+
children: content
|
|
446
|
+
}
|
|
447
|
+
);
|
|
448
|
+
}
|
|
449
|
+
function TimedEvent({
|
|
450
|
+
positioned,
|
|
451
|
+
ghost,
|
|
452
|
+
dragging,
|
|
453
|
+
onPointerDown,
|
|
454
|
+
gestureHandlers
|
|
455
|
+
}) {
|
|
456
|
+
const cal = useEventCalendar("EventCalendarBody");
|
|
457
|
+
const { event, startMin, endMin, left, width } = positioned;
|
|
458
|
+
const pxPerMin = cal.hourHeight / 60;
|
|
459
|
+
const lo = cal.startHour * 60;
|
|
460
|
+
const top = (Math.max(startMin, lo) - lo) * pxPerMin;
|
|
461
|
+
const height = Math.max((Math.min(endMin, cal.endHour * 60) - Math.max(startMin, lo)) * pxPerMin - 2, 14);
|
|
462
|
+
const size = eventSize(durationMinutes(event.start, event.end));
|
|
463
|
+
const selected = cal.selectedEventId === event.id;
|
|
464
|
+
return /* @__PURE__ */ jsxs(
|
|
465
|
+
"div",
|
|
466
|
+
{
|
|
467
|
+
role: dragging ? void 0 : "button",
|
|
468
|
+
tabIndex: dragging ? void 0 : 0,
|
|
469
|
+
"aria-hidden": dragging || void 0,
|
|
470
|
+
"aria-label": formatEventLabel(event, cal.locale, cal.labels.newEvent),
|
|
471
|
+
"aria-description": cal.editable ? cal.labels.eventKeys : void 0,
|
|
472
|
+
"data-slot": "event-calendar-event",
|
|
473
|
+
"data-event-id": dragging ? void 0 : event.id,
|
|
474
|
+
"data-size": size,
|
|
475
|
+
"data-selected": selected && !ghost ? "" : void 0,
|
|
476
|
+
"data-ghost": ghost ? "" : void 0,
|
|
477
|
+
"data-dragging": dragging ? "" : void 0,
|
|
478
|
+
className: cn(
|
|
479
|
+
eventBlockVariants({ kind: "timed" }),
|
|
480
|
+
size === "xs" && "flex-row items-center gap-1 py-0",
|
|
481
|
+
cal.editable && !dragging && "touch-pan-y pointer-fine:touch-none"
|
|
482
|
+
),
|
|
483
|
+
style: {
|
|
484
|
+
...tintStyle(event.color),
|
|
485
|
+
top,
|
|
486
|
+
height,
|
|
487
|
+
left: `calc(${left * 100}% + 2px)`,
|
|
488
|
+
width: `calc(${width * 100}% - 4px)`
|
|
489
|
+
},
|
|
490
|
+
onPointerDown,
|
|
491
|
+
onKeyDown: dragging ? void 0 : (e) => onEventKeyDown(cal, event, e, "time"),
|
|
492
|
+
...gestureHandlers,
|
|
493
|
+
children: [
|
|
494
|
+
cal.editable && !dragging ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
495
|
+
/* @__PURE__ */ jsx("span", { "aria-hidden": true, className: "absolute inset-x-0 top-0 h-1.5 cursor-ns-resize" }),
|
|
496
|
+
/* @__PURE__ */ jsx("span", { "aria-hidden": true, className: "absolute inset-x-0 bottom-0 h-1.5 cursor-ns-resize" })
|
|
497
|
+
] }) : null,
|
|
498
|
+
size === "xs" ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
499
|
+
/* @__PURE__ */ jsx("span", { className: "min-w-0 truncate font-medium", children: event.title || cal.labels.newEvent }),
|
|
500
|
+
/* @__PURE__ */ jsx("span", { className: "shrink-0 tabular-nums opacity-80 @max-[6rem]/event:hidden", children: formatTime(event.start, cal.locale) })
|
|
501
|
+
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
502
|
+
/* @__PURE__ */ jsx("span", { className: cn("font-medium", size === "sm" ? "truncate" : size === "md" ? "line-clamp-2" : "line-clamp-3"), children: event.title || cal.labels.newEvent }),
|
|
503
|
+
/* @__PURE__ */ jsx("span", { className: "truncate tabular-nums opacity-80", children: formatTimeRange(event.start, event.end, cal.locale) }),
|
|
504
|
+
size === "lg" && event.location ? /* @__PURE__ */ jsx("span", { className: "truncate opacity-80", children: event.location }) : null
|
|
505
|
+
] })
|
|
506
|
+
]
|
|
507
|
+
}
|
|
508
|
+
);
|
|
509
|
+
}
|
|
510
|
+
function AllDayBar({ event, day }) {
|
|
511
|
+
const cal = useEventCalendar("EventCalendarBody");
|
|
512
|
+
const starts = isSameDay(event.start, day) || day.getTime() === cal.days[0].getTime();
|
|
513
|
+
return /* @__PURE__ */ jsx(
|
|
514
|
+
"div",
|
|
515
|
+
{
|
|
516
|
+
role: "button",
|
|
517
|
+
tabIndex: starts ? 0 : -1,
|
|
518
|
+
"aria-label": formatEventLabel(event, cal.locale, cal.labels.newEvent),
|
|
519
|
+
...{ "aria-description": cal.editable ? cal.labels.monthEventKeys : void 0 },
|
|
520
|
+
"data-slot": "event-calendar-event",
|
|
521
|
+
"data-event-id": starts ? event.id : void 0,
|
|
522
|
+
"data-selected": cal.selectedEventId === event.id ? "" : void 0,
|
|
523
|
+
className: eventBlockVariants({ kind: "bar" }),
|
|
524
|
+
style: tintStyle(event.color),
|
|
525
|
+
onClick: () => cal.openEvent(event),
|
|
526
|
+
onKeyDown: (e) => onEventKeyDown(cal, event, e, "day-cell"),
|
|
527
|
+
children: /* @__PURE__ */ jsx("span", { className: cn("truncate", !starts && "opacity-0"), children: event.title || cal.labels.newEvent })
|
|
528
|
+
}
|
|
529
|
+
);
|
|
530
|
+
}
|
|
531
|
+
export {
|
|
532
|
+
TimeGrid
|
|
533
|
+
};
|
|
534
|
+
//# sourceMappingURL=time-grid.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../src/components/ui/event-calendar/time-grid.tsx"],"sourcesContent":["\"use client\"\n\nimport * as React from \"react\"\n\nimport { cn } from \"../../../lib/utils.mjs\"\n\nimport {\n atMinutes,\n busyRanges,\n clamp,\n durationMinutes,\n eventOnDay,\n eventSize,\n formatEventLabel,\n formatHour,\n formatTime,\n formatTimeRange,\n gapAround,\n isSameDay,\n isWeekend,\n layoutDay,\n minutesOfDay,\n snap,\n snapFlush,\n sortEvents,\n startOfDay,\n type CalendarEvent,\n type PositionedEvent,\n} from \"./calendar-math.mjs\"\nimport { useEventCalendar } from \"./context.mjs\"\nimport { eventBlockVariants, tintStyle } from \"./event-block.mjs\"\nimport { onEventKeyDown } from \"./event-keys.mjs\"\n\nconst DRAG_THRESHOLD = 4\n/** The strip at the top and bottom of a block that resizes instead of moving. */\nconst EDGE = 6\n/** How close to the scroller's edge a drag starts scrolling it. */\nconst AUTOSCROLL_ZONE = 40\nconst DAY_MS = 86400000\n/** How long a touch holds still before it lifts an event or makes one. */\nconst LONG_PRESS = 450\n/** How far a touch may wander before the long press gives way to scrolling. */\nconst TOUCH_SLOP = 8\n\ntype Gesture =\n | {\n kind: \"event\"\n pointerId: number\n x: number\n y: number\n event: CalendarEvent\n mode: \"move\" | \"start\" | \"end\"\n /** Minutes between the event's start and the point it was grabbed at. */\n grab: number\n active: boolean\n preview: CalendarEvent | null\n touch: boolean\n timer?: ReturnType<typeof setTimeout>\n }\n | {\n kind: \"sweep\"\n pointerId: number\n x: number\n y: number\n day: Date\n from: number\n active: boolean\n span: [number, number] | null\n touch: boolean\n timer?: ReturnType<typeof setTimeout>\n }\n\n/** The week and day views: day heads, the all-day row, then the scrolling hours. */\nexport function TimeGrid() {\n const cal = useEventCalendar(\"EventCalendarBody\")\n const { days, hourHeight, startHour, endHour, snapMinutes, locale, now, labels } = cal\n const pxPerMin = hourHeight / 60\n const lo = startHour * 60\n const hi = endHour * 60\n\n const scrollerRef = React.useRef<HTMLDivElement | null>(null)\n const gesture = React.useRef<Gesture | null>(null)\n const lastPoint = React.useRef<{ x: number; y: number; shift: boolean; alt: boolean } | null>(null)\n const frame = React.useRef(0)\n const [drag, setDrag] = React.useState<{ id: string; preview: CalendarEvent } | null>(null)\n const [sweep, setSweep] = React.useState<{ day: Date; from: number; to: number } | null>(null)\n\n // Open at the working morning, once per period.\n React.useLayoutEffect(() => {\n const scroller = scrollerRef.current\n if (scroller) scroller.scrollTop = Math.max(0, (cal.scrollToHour - startHour) * hourHeight)\n }, [cal.scrollToHour, startHour, hourHeight])\n\n /** The day column under x (clamped to the first or last) and the minute under y. */\n const pointAt = (x: number, y: number) => {\n const columns = Array.from(\n scrollerRef.current?.querySelectorAll<HTMLElement>(\"[data-slot=event-calendar-column]\") ?? [],\n )\n if (!columns.length) return null\n const rects = columns.map((c) => c.getBoundingClientRect())\n let index = rects.findIndex((r) => x >= r.left && x < r.right)\n if (index === -1) {\n const leftmost = rects.reduce((a, r, i) => (r.left < rects[a].left ? i : a), 0)\n const rightmost = rects.reduce((a, r, i) => (r.right > rects[a].right ? i : a), 0)\n index = x < rects[leftmost].left ? leftmost : rightmost\n }\n return {\n day: new Date(Number(columns[index].dataset.day)),\n minutes: (y - rects[index].top) / pxPerMin + lo,\n }\n }\n\n const update = (x: number, y: number, shift = false, alt = false) => {\n const g = gesture.current\n const point = pointAt(x, y)\n if (!g || !point) return\n const smart = cal.smartFill && !alt\n if (g.kind === \"sweep\") {\n const to = clamp(snap(point.minutes, snapMinutes), lo, hi)\n const from = Math.min(g.from, to)\n const end = Math.max(g.from, to) === from ? from + snapMinutes : Math.max(g.from, to)\n g.span = [from, end]\n setSweep({ day: g.day, from, to: end })\n return\n }\n const ev = g.event\n let next: CalendarEvent\n if (g.mode === \"move\") {\n const length = durationMinutes(ev.start, ev.end)\n let startMin = clamp(snap(point.minutes - g.grab, snapMinutes), lo, Math.max(lo, hi - Math.min(length, hi - lo)))\n let endMin = startMin + length\n const busy = smart ? busyRanges(cal.events, point.day, ev.id) : []\n const gap = smart && shift ? gapAround(busy, point.minutes, lo, hi) : null\n // Shift fills the free gap under the pointer; otherwise a graze snaps flush.\n if (gap) [startMin, endMin] = gap\n else if (smart) [startMin, endMin] = snapFlush([startMin, endMin], busy, \"move\")\n const start = atMinutes(point.day, startMin)\n next = { ...ev, start, end: gap ? atMinutes(point.day, endMin) : new Date(start.getTime() + length * 60000) }\n } else {\n const day = startOfDay(ev.start)\n const startMin = minutesOfDay(ev.start)\n const endMin = isSameDay(ev.start, ev.end) ? minutesOfDay(ev.end) : 24 * 60\n let range: [number, number] =\n g.mode === \"end\"\n ? [startMin, clamp(snap(point.minutes, snapMinutes), startMin + snapMinutes, hi)]\n : [clamp(snap(point.minutes, snapMinutes), lo, endMin - snapMinutes), endMin]\n if (smart) range = snapFlush(range, busyRanges(cal.events, day, ev.id), g.mode)\n next = { ...ev, start: atMinutes(day, range[0]), end: atMinutes(day, range[1]) }\n }\n g.preview = next\n setDrag({ id: ev.id, preview: next })\n }\n\n // Near the scroller's top or bottom edge, a drag scrolls it and follows along.\n const tick = () => {\n const scroller = scrollerRef.current\n const point = lastPoint.current\n if (!scroller || !point || !gesture.current?.active) {\n frame.current = 0\n return\n }\n const r = scroller.getBoundingClientRect()\n let dy = 0\n if (point.y < r.top + AUTOSCROLL_ZONE) dy = -Math.ceil((r.top + AUTOSCROLL_ZONE - point.y) / 4)\n else if (point.y > r.bottom - AUTOSCROLL_ZONE) dy = Math.ceil((point.y - (r.bottom - AUTOSCROLL_ZONE)) / 4)\n if (dy) {\n scroller.scrollTop += dy\n update(point.x, point.y, point.shift, point.alt)\n }\n frame.current = requestAnimationFrame(tick)\n }\n\n const finish = (commit: boolean) => {\n const g = gesture.current\n gesture.current = null\n if (g?.timer) clearTimeout(g.timer)\n cancelAnimationFrame(frame.current)\n frame.current = 0\n setDrag(null)\n setSweep(null)\n if (!g || !commit) return\n if (g.kind === \"event\") {\n if (!g.active) cal.openEvent(g.event)\n else if (\n g.preview &&\n (g.preview.start.getTime() !== g.event.start.getTime() || g.preview.end.getTime() !== g.event.end.getTime())\n ) {\n cal.changeEvent(g.preview)\n }\n return\n }\n if (g.active && g.span) {\n cal.createAt({ start: atMinutes(g.day, g.span[0]), end: atMinutes(g.day, g.span[1]), allDay: false })\n } else if (!g.active && !g.touch) cal.setSelectedEventId(null)\n }\n\n const onEscape = React.useEffectEvent((event: KeyboardEvent) => {\n if (event.key !== \"Escape\" || !gesture.current) return\n event.preventDefault()\n event.stopPropagation()\n finish(false)\n })\n const gesturing = drag !== null || sweep !== null\n React.useEffect(() => {\n if (!gesturing) return\n window.addEventListener(\"keydown\", onEscape, true)\n return () => window.removeEventListener(\"keydown\", onEscape, true)\n }, [gesturing])\n\n React.useEffect(() => () => cancelAnimationFrame(frame.current), [])\n\n const onPointerMove = (e: React.PointerEvent) => {\n const g = gesture.current\n if (!g || g.pointerId !== e.pointerId) return\n lastPoint.current = { x: e.clientX, y: e.clientY, shift: e.shiftKey, alt: e.altKey }\n if (!g.active) {\n const moved = Math.hypot(e.clientX - g.x, e.clientY - g.y)\n // A touch waits for its long press; wandering first means the finger is scrolling.\n if (g.touch) {\n if (moved > TOUCH_SLOP) finish(false)\n return\n }\n if (moved < DRAG_THRESHOLD || !cal.editable) return\n g.active = true\n frame.current = requestAnimationFrame(tick)\n }\n update(e.clientX, e.clientY, e.shiftKey, e.altKey)\n }\n\n /** After a still long press: lift the event, or make one where the finger is. */\n const longPress = () => {\n const g = gesture.current\n if (!g || g.active || !cal.editable) return\n navigator.vibrate?.(10)\n if (g.kind === \"sweep\") {\n gesture.current = null\n cal.createAt(\n { start: atMinutes(g.day, g.from), end: atMinutes(g.day, g.from + cal.defaultDuration), allDay: false },\n { fit: true },\n )\n return\n }\n g.active = true\n g.preview = g.event\n setDrag({ id: g.event.id, preview: g.event })\n frame.current = requestAnimationFrame(tick)\n }\n\n // Once a touch has lifted an event, the finger drags it instead of scrolling the grid.\n React.useEffect(() => {\n const scroller = scrollerRef.current\n if (!scroller) return\n const onTouchMove = (event: TouchEvent) => {\n if (gesture.current?.active && gesture.current.touch) event.preventDefault()\n }\n scroller.addEventListener(\"touchmove\", onTouchMove, { passive: false })\n return () => scroller.removeEventListener(\"touchmove\", onTouchMove)\n }, [])\n\n const gestureHandlers = {\n onPointerMove,\n onPointerUp: (e: React.PointerEvent) => {\n if (gesture.current?.pointerId === e.pointerId) finish(true)\n },\n onPointerCancel: () => finish(false),\n onLostPointerCapture: () => {\n if (gesture.current) finish(false)\n },\n }\n\n const startEventGesture = (e: React.PointerEvent<HTMLElement>, event: CalendarEvent) => {\n if (e.button !== 0) return\n e.stopPropagation()\n const el = e.currentTarget\n const r = el.getBoundingClientRect()\n let mode: \"move\" | \"start\" | \"end\" = \"move\"\n if (cal.editable && r.height >= 24) {\n if (e.clientY - r.top < EDGE) mode = \"start\"\n else if (r.bottom - e.clientY < EDGE) mode = \"end\"\n }\n const point = pointAt(e.clientX, e.clientY)\n const dayOffset = point ? Math.round((point.day.getTime() - startOfDay(event.start).getTime()) / DAY_MS) : 0\n const grab = point ? point.minutes + dayOffset * 1440 - minutesOfDay(event.start) : 0\n const touch = e.pointerType === \"touch\"\n if (!touch) el.setPointerCapture(e.pointerId)\n gesture.current = {\n kind: \"event\",\n pointerId: e.pointerId,\n x: e.clientX,\n y: e.clientY,\n event,\n mode: touch ? \"move\" : mode,\n grab,\n active: false,\n preview: null,\n touch,\n timer: touch ? setTimeout(longPress, LONG_PRESS) : undefined,\n }\n }\n\n const startSweep = (e: React.PointerEvent<HTMLElement>, day: Date) => {\n if (e.button !== 0 || (e.target as HTMLElement).closest(\"[data-slot=event-calendar-event]\")) return\n const point = pointAt(e.clientX, e.clientY)\n if (!point) return\n const touch = e.pointerType === \"touch\"\n if (!touch) e.currentTarget.setPointerCapture(e.pointerId)\n gesture.current = {\n kind: \"sweep\",\n touch,\n timer: touch ? setTimeout(longPress, LONG_PRESS) : undefined,\n pointerId: e.pointerId,\n x: e.clientX,\n y: e.clientY,\n day,\n from: clamp(Math.floor(point.minutes / snapMinutes) * snapMinutes, lo, hi - snapMinutes),\n active: false,\n span: null,\n }\n }\n\n const createByDoubleClick = (e: React.MouseEvent<HTMLElement>, day: Date) => {\n if ((e.target as HTMLElement).closest(\"[data-slot=event-calendar-event]\")) return\n const point = pointAt(e.clientX, e.clientY)\n if (!point) return\n const startMin = clamp(Math.floor(point.minutes / 30) * 30, lo, hi - cal.defaultDuration)\n cal.createAt(\n { start: atMinutes(day, startMin), end: atMinutes(day, startMin + cal.defaultDuration), allDay: false },\n { fit: true },\n )\n }\n\n const showNow = now !== null && days.some((d) => isSameDay(d, now))\n const nowMin = now ? minutesOfDay(now) : 0\n const nowVisible = showNow && nowMin >= lo && nowMin <= hi\n const nowTop = (nowMin - lo) * pxPerMin\n const hours = Array.from({ length: endHour - startHour }, (_, i) => startHour + i)\n const allDay = (day: Date) => cal.events.filter((e) => e.allDay && eventOnDay(e, day)).sort(sortEvents)\n\n return (\n <>\n {/* Day heads */}\n <div\n data-slot=\"event-calendar-day-heads\"\n className=\"flex overflow-hidden border-b border-border [scrollbar-gutter:stable]\"\n >\n <div className=\"w-16 shrink-0\" />\n {days.map((day) => (\n <DayHead key={day.getTime()} day={day} />\n ))}\n </div>\n\n {/* All-day row */}\n <div\n data-slot=\"event-calendar-all-day\"\n className=\"flex overflow-hidden border-b border-border [scrollbar-gutter:stable]\"\n >\n <div className=\"flex w-16 shrink-0 items-start justify-end py-1.5 pr-2 text-xs text-muted-foreground\">\n {labels.allDay}\n </div>\n {days.map((day) => (\n <div\n key={day.getTime()}\n data-weekend={isWeekend(day) ? \"\" : undefined}\n className=\"flex min-h-8 min-w-0 flex-1 flex-col gap-0.5 border-l border-border p-0.5 data-[weekend]:bg-muted/40\"\n onDoubleClick={(e) => {\n if ((e.target as HTMLElement).closest(\"[data-slot=event-calendar-event]\")) return\n cal.createAt({ start: startOfDay(day), end: startOfDay(day), allDay: true })\n }}\n >\n {allDay(day).map((event) => (\n <AllDayBar key={event.id} event={event} day={day} />\n ))}\n </div>\n ))}\n </div>\n\n {/* Hours */}\n <div\n ref={scrollerRef}\n data-slot=\"event-calendar-scroller\"\n className=\"relative min-h-0 flex-1 overflow-y-auto overscroll-contain [scrollbar-gutter:stable]\"\n >\n <div className=\"relative flex\" style={{ height: (hi - lo) * pxPerMin }}>\n <div aria-hidden className=\"relative w-16 shrink-0\">\n {hours.slice(1).map((hour) => (\n <span\n key={hour}\n className=\"absolute right-2 -translate-y-1/2 text-xs whitespace-nowrap text-muted-foreground tabular-nums\"\n style={{ top: (hour - startHour) * hourHeight }}\n >\n {formatHour(hour, locale)}\n </span>\n ))}\n {nowVisible && now ? (\n <span\n className=\"absolute right-1 z-20 -translate-y-1/2 bg-(--surface) px-1 text-xs font-medium whitespace-nowrap text-primary tabular-nums\"\n style={{ top: nowTop }}\n >\n {formatTime(now, locale)}\n </span>\n ) : null}\n </div>\n\n {days.map((day) => {\n const positioned = layoutDay(cal.events, day)\n const isToday = now !== null && isSameDay(day, now)\n const previewHere = drag && !drag.preview.allDay && isSameDay(drag.preview.start, day) ? drag.preview : null\n return (\n <div\n key={day.getTime()}\n data-slot=\"event-calendar-column\"\n data-day={day.getTime()}\n data-weekend={isWeekend(day) ? \"\" : undefined}\n data-today={isToday ? \"\" : undefined}\n className={cn(\n \"relative min-w-0 flex-1 touch-pan-y border-l border-border select-none data-[weekend]:bg-muted/40\",\n \"[background-image:linear-gradient(to_bottom,var(--border)_1px,transparent_1px)] [background-size:100%_var(--hour)]\",\n )}\n style={{ \"--hour\": `${hourHeight}px` } as React.CSSProperties}\n onPointerDown={(e) => startSweep(e, day)}\n onDoubleClick={(e) => createByDoubleClick(e, day)}\n {...gestureHandlers}\n >\n {positioned.map((p) => (\n <TimedEvent\n key={p.event.id}\n positioned={p}\n ghost={drag?.id === p.event.id}\n onPointerDown={(e) => startEventGesture(e, p.event)}\n gestureHandlers={gestureHandlers}\n />\n ))}\n {previewHere ? (\n <TimedEvent\n positioned={{\n event: previewHere,\n startMin: minutesOfDay(previewHere.start),\n endMin: isSameDay(previewHere.start, previewHere.end) ? minutesOfDay(previewHere.end) : 1440,\n left: 0,\n width: 1,\n }}\n dragging\n />\n ) : null}\n {sweep && isSameDay(sweep.day, day) ? (\n <div\n data-slot=\"event-calendar-sweep\"\n aria-hidden\n className=\"pointer-events-none absolute inset-x-0.5 z-20 rounded-sm bg-primary/15 px-2 py-1 text-xs font-medium text-primary tabular-nums ring-1 ring-primary/40\"\n style={{ top: (sweep.from - lo) * pxPerMin, height: (sweep.to - sweep.from) * pxPerMin - 1 }}\n >\n {formatTimeRange(atMinutes(day, sweep.from), atMinutes(day, sweep.to), locale)}\n </div>\n ) : null}\n {nowVisible ? (\n <div\n aria-hidden\n data-slot=\"event-calendar-now\"\n className={cn(\n \"pointer-events-none absolute inset-x-0 z-20 -translate-y-1/2\",\n isToday\n ? \"h-0.5 bg-primary before:absolute before:top-1/2 before:-left-1 before:size-2 before:-translate-y-1/2 before:rounded-full before:bg-primary\"\n : \"h-px bg-primary/35\",\n )}\n style={{ top: nowTop }}\n />\n ) : null}\n </div>\n )\n })}\n </div>\n </div>\n </>\n )\n}\n\n/* ─── Parts ───────────────────────────────────────────────────────────────── */\n\nfunction DayHead({ day }: { day: Date }) {\n const cal = useEventCalendar(\"EventCalendarBody\")\n const isToday = cal.now !== null && isSameDay(day, cal.now)\n const weekday = new Intl.DateTimeFormat(cal.locale, { weekday: \"short\" }).format(day)\n const full = new Intl.DateTimeFormat(cal.locale, { weekday: \"long\", month: \"long\", day: \"numeric\" }).format(day)\n const canOpen = cal.view === \"week\" && cal.views.includes(\"day\")\n const content = (\n <>\n <span className=\"text-xs text-muted-foreground\">{weekday}</span>\n <span\n className={cn(\n \"inline-flex size-7 items-center justify-center rounded-full text-sm font-semibold tabular-nums\",\n isToday && \"bg-primary text-primary-foreground\",\n )}\n >\n {day.getDate()}\n </span>\n </>\n )\n const className = cn(\n \"flex min-w-0 flex-1 flex-col items-center gap-0.5 border-l border-border py-1.5 data-[weekend]:bg-muted/40\",\n canOpen &&\n \"cursor-pointer outline-none transition-[background-color] duration-fast hover:bg-accent focus-visible:ring-2 focus-visible:ring-focus focus-visible:ring-inset\",\n )\n if (!canOpen) {\n return (\n <div data-slot=\"event-calendar-day-head\" data-weekend={isWeekend(day) ? \"\" : undefined} aria-label={full} className={className}>\n {content}\n </div>\n )\n }\n return (\n <button\n type=\"button\"\n data-slot=\"event-calendar-day-head\"\n data-weekend={isWeekend(day) ? \"\" : undefined}\n aria-label={full}\n aria-current={isToday ? \"date\" : undefined}\n className={className}\n onClick={() => {\n cal.setDate(day)\n cal.setView(\"day\")\n }}\n >\n {content}\n </button>\n )\n}\n\nfunction TimedEvent({\n positioned,\n ghost,\n dragging,\n onPointerDown,\n gestureHandlers,\n}: {\n positioned: PositionedEvent\n ghost?: boolean\n dragging?: boolean\n onPointerDown?: (e: React.PointerEvent<HTMLElement>) => void\n gestureHandlers?: Record<string, (e: React.PointerEvent) => void>\n}) {\n const cal = useEventCalendar(\"EventCalendarBody\")\n const { event, startMin, endMin, left, width } = positioned\n const pxPerMin = cal.hourHeight / 60\n const lo = cal.startHour * 60\n const top = (Math.max(startMin, lo) - lo) * pxPerMin\n const height = Math.max((Math.min(endMin, cal.endHour * 60) - Math.max(startMin, lo)) * pxPerMin - 2, 14)\n const size = eventSize(durationMinutes(event.start, event.end))\n const selected = cal.selectedEventId === event.id\n\n return (\n <div\n role={dragging ? undefined : \"button\"}\n tabIndex={dragging ? undefined : 0}\n aria-hidden={dragging || undefined}\n aria-label={formatEventLabel(event, cal.locale, cal.labels.newEvent)}\n aria-description={cal.editable ? cal.labels.eventKeys : undefined}\n data-slot=\"event-calendar-event\"\n data-event-id={dragging ? undefined : event.id}\n data-size={size}\n data-selected={selected && !ghost ? \"\" : undefined}\n data-ghost={ghost ? \"\" : undefined}\n data-dragging={dragging ? \"\" : undefined}\n className={cn(\n eventBlockVariants({ kind: \"timed\" }),\n size === \"xs\" && \"flex-row items-center gap-1 py-0\",\n cal.editable && !dragging && \"touch-pan-y pointer-fine:touch-none\",\n )}\n style={{\n ...tintStyle(event.color),\n top,\n height,\n left: `calc(${left * 100}% + 2px)`,\n width: `calc(${width * 100}% - 4px)`,\n }}\n onPointerDown={onPointerDown}\n onKeyDown={dragging ? undefined : (e) => onEventKeyDown(cal, event, e, \"time\")}\n {...gestureHandlers}\n >\n {cal.editable && !dragging ? (\n <>\n <span aria-hidden className=\"absolute inset-x-0 top-0 h-1.5 cursor-ns-resize\" />\n <span aria-hidden className=\"absolute inset-x-0 bottom-0 h-1.5 cursor-ns-resize\" />\n </>\n ) : null}\n {size === \"xs\" ? (\n <>\n <span className=\"min-w-0 truncate font-medium\">{event.title || cal.labels.newEvent}</span>\n <span className=\"shrink-0 tabular-nums opacity-80 @max-[6rem]/event:hidden\">{formatTime(event.start, cal.locale)}</span>\n </>\n ) : (\n <>\n <span className={cn(\"font-medium\", size === \"sm\" ? \"truncate\" : size === \"md\" ? \"line-clamp-2\" : \"line-clamp-3\")}>\n {event.title || cal.labels.newEvent}\n </span>\n <span className=\"truncate tabular-nums opacity-80\">{formatTimeRange(event.start, event.end, cal.locale)}</span>\n {size === \"lg\" && event.location ? <span className=\"truncate opacity-80\">{event.location}</span> : null}\n </>\n )}\n </div>\n )\n}\n\nfunction AllDayBar({ event, day }: { event: CalendarEvent; day: Date }) {\n const cal = useEventCalendar(\"EventCalendarBody\")\n const starts = isSameDay(event.start, day) || day.getTime() === cal.days[0].getTime()\n return (\n <div\n role=\"button\"\n tabIndex={starts ? 0 : -1}\n aria-label={formatEventLabel(event, cal.locale, cal.labels.newEvent)}\n // aria-description is a global ARIA 1.3 attribute; the lint rule predates it.\n {...{ \"aria-description\": cal.editable ? cal.labels.monthEventKeys : undefined }}\n data-slot=\"event-calendar-event\"\n data-event-id={starts ? event.id : undefined}\n data-selected={cal.selectedEventId === event.id ? \"\" : undefined}\n className={eventBlockVariants({ kind: \"bar\" })}\n style={tintStyle(event.color)}\n onClick={() => cal.openEvent(event)}\n onKeyDown={(e) => onEventKeyDown(cal, event, e, \"day-cell\")}\n >\n <span className={cn(\"truncate\", !starts && \"opacity-0\")}>{event.title || cal.labels.newEvent}</span>\n </div>\n )\n}\n"],"mappings":";AAmVI,mBAMI,KAJF,YAFF;AAjVJ,YAAY,WAAW;AAEvB,SAAS,UAAU;AAEnB;AAAA,EACE;AAA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