@nadicodeai/ui 12.1.96 → 12.1.97
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/AGENTS.md +5 -1
- package/dist/components/accordion.d.ts +13 -0
- package/dist/components/accordion.d.ts.map +1 -1
- package/dist/components/accordion.js +13 -0
- package/dist/components/account-menu.d.ts +62 -18
- package/dist/components/account-menu.d.ts.map +1 -1
- package/dist/components/account-menu.js +32 -8
- package/dist/components/action-menu.d.ts +61 -5
- package/dist/components/action-menu.d.ts.map +1 -1
- package/dist/components/action-menu.js +31 -2
- package/dist/components/action-status.d.ts +13 -3
- package/dist/components/action-status.d.ts.map +1 -1
- package/dist/components/action-status.js +13 -3
- package/dist/components/activity-calendar.d.ts +14 -0
- package/dist/components/activity-calendar.d.ts.map +1 -1
- package/dist/components/activity-calendar.js +14 -0
- package/dist/components/activity-feed.d.ts +62 -0
- package/dist/components/activity-feed.d.ts.map +1 -0
- package/dist/components/activity-feed.js +54 -0
- package/dist/components/agent-card.d.ts +15 -0
- package/dist/components/agent-card.d.ts.map +1 -1
- package/dist/components/agent-card.js +15 -0
- package/dist/components/agent-list-row.d.ts +11 -7
- package/dist/components/agent-list-row.d.ts.map +1 -1
- package/dist/components/agent-list-row.js +10 -8
- package/dist/components/agent-orb.d.ts +16 -0
- package/dist/components/agent-orb.d.ts.map +1 -1
- package/dist/components/agent-orb.js +16 -0
- package/dist/components/agent-profile.d.ts +39 -10
- package/dist/components/agent-profile.d.ts.map +1 -1
- package/dist/components/agent-profile.js +39 -10
- package/dist/components/alert-dialog.d.ts +14 -0
- package/dist/components/alert-dialog.d.ts.map +1 -1
- package/dist/components/alert-dialog.js +14 -0
- package/dist/components/alert.d.ts +14 -0
- package/dist/components/alert.d.ts.map +1 -1
- package/dist/components/alert.js +14 -0
- package/dist/components/app-mark.d.ts +14 -4
- package/dist/components/app-mark.d.ts.map +1 -1
- package/dist/components/app-mark.js +13 -3
- package/dist/components/approval-row.d.ts +15 -2
- package/dist/components/approval-row.d.ts.map +1 -1
- package/dist/components/approval-row.js +15 -2
- package/dist/components/aspect-ratio.d.ts +10 -0
- package/dist/components/aspect-ratio.d.ts.map +1 -1
- package/dist/components/aspect-ratio.js +10 -0
- package/dist/components/avatar.d.ts +15 -0
- package/dist/components/avatar.d.ts.map +1 -1
- package/dist/components/avatar.js +15 -0
- package/dist/components/badge.d.ts +11 -1
- package/dist/components/badge.d.ts.map +1 -1
- package/dist/components/badge.js +10 -5
- package/dist/components/brand-field.d.ts +10 -0
- package/dist/components/brand-field.d.ts.map +1 -1
- package/dist/components/brand-field.js +10 -0
- package/dist/components/brand.d.ts +14 -0
- package/dist/components/brand.d.ts.map +1 -1
- package/dist/components/brand.js +14 -0
- package/dist/components/breadcrumb.d.ts +20 -2
- package/dist/components/breadcrumb.d.ts.map +1 -1
- package/dist/components/breadcrumb.js +13 -3
- package/dist/components/button-group.d.ts +21 -0
- package/dist/components/button-group.d.ts.map +1 -1
- package/dist/components/button-group.js +21 -0
- package/dist/components/button.d.ts +20 -0
- package/dist/components/button.d.ts.map +1 -1
- package/dist/components/button.js +20 -0
- package/dist/components/calendar.d.ts +15 -0
- package/dist/components/calendar.d.ts.map +1 -1
- package/dist/components/calendar.js +15 -0
- package/dist/components/card-row.d.ts +15 -5
- package/dist/components/card-row.d.ts.map +1 -1
- package/dist/components/card-row.js +15 -5
- package/dist/components/card.d.ts +16 -0
- package/dist/components/card.d.ts.map +1 -1
- package/dist/components/card.js +16 -0
- package/dist/components/carousel.d.ts +12 -0
- package/dist/components/carousel.d.ts.map +1 -1
- package/dist/components/carousel.js +12 -0
- package/dist/components/catalog-drawer.d.ts +29 -0
- package/dist/components/catalog-drawer.d.ts.map +1 -0
- package/dist/components/catalog-drawer.js +31 -0
- package/dist/components/catalog-entry.d.ts +49 -26
- package/dist/components/catalog-entry.d.ts.map +1 -1
- package/dist/components/catalog-entry.js +5 -27
- package/dist/components/channel-view.d.ts +23 -0
- package/dist/components/channel-view.d.ts.map +1 -1
- package/dist/components/channel-view.js +13 -4
- package/dist/components/chart-area-stacked.d.ts +11 -1
- package/dist/components/chart-area-stacked.d.ts.map +1 -1
- package/dist/components/chart-area-stacked.js +12 -2
- package/dist/components/chart-bar-horizontal.d.ts +11 -1
- package/dist/components/chart-bar-horizontal.d.ts.map +1 -1
- package/dist/components/chart-bar-horizontal.js +12 -2
- package/dist/components/chart-bar-multiple.d.ts +9 -4
- package/dist/components/chart-bar-multiple.d.ts.map +1 -1
- package/dist/components/chart-bar-multiple.js +10 -5
- package/dist/components/chart-bar-stacked.d.ts +11 -1
- package/dist/components/chart-bar-stacked.d.ts.map +1 -1
- package/dist/components/chart-bar-stacked.js +12 -2
- package/dist/components/chart-card.d.ts +33 -20
- package/dist/components/chart-card.d.ts.map +1 -1
- package/dist/components/chart-card.js +18 -4
- package/dist/components/chart-date-range-control.d.ts +15 -10
- package/dist/components/chart-date-range-control.d.ts.map +1 -1
- package/dist/components/chart-date-range-control.js +14 -10
- package/dist/components/chart-date-range.d.ts.map +1 -1
- package/dist/components/chart-entity-colors.d.ts +7 -0
- package/dist/components/chart-entity-colors.d.ts.map +1 -1
- package/dist/components/chart-entity-colors.js +7 -0
- package/dist/components/chart-sparkline.d.ts +10 -0
- package/dist/components/chart-sparkline.d.ts.map +1 -1
- package/dist/components/chart-sparkline.js +8 -7
- package/dist/components/chart.d.ts +10 -0
- package/dist/components/chart.d.ts.map +1 -1
- package/dist/components/chart.js +10 -0
- package/dist/components/checkbox.d.ts +15 -0
- package/dist/components/checkbox.d.ts.map +1 -1
- package/dist/components/checkbox.js +15 -0
- package/dist/components/code-block.d.ts +15 -0
- package/dist/components/code-block.d.ts.map +1 -1
- package/dist/components/code-block.js +15 -0
- package/dist/components/collapsible.d.ts +12 -0
- package/dist/components/collapsible.d.ts.map +1 -1
- package/dist/components/collapsible.js +12 -0
- package/dist/components/collection-filters.d.ts +15 -2
- package/dist/components/collection-filters.d.ts.map +1 -1
- package/dist/components/collection-filters.js +13 -1
- package/dist/components/collection-page.d.ts +29 -115
- package/dist/components/collection-page.d.ts.map +1 -1
- package/dist/components/collection-page.js +24 -140
- package/dist/components/collection-search.d.ts +14 -0
- package/dist/components/collection-search.d.ts.map +1 -1
- package/dist/components/collection-search.js +14 -0
- package/dist/components/collection-sort.d.ts +13 -3
- package/dist/components/collection-sort.d.ts.map +1 -1
- package/dist/components/collection-sort.js +13 -3
- package/dist/components/collection-toolbar.d.ts +13 -0
- package/dist/components/collection-toolbar.d.ts.map +1 -1
- package/dist/components/collection-toolbar.js +13 -0
- package/dist/components/combobox.d.ts +17 -0
- package/dist/components/combobox.d.ts.map +1 -1
- package/dist/components/combobox.js +17 -0
- package/dist/components/command.d.ts +16 -0
- package/dist/components/command.d.ts.map +1 -1
- package/dist/components/command.js +16 -0
- package/dist/components/company-card.d.ts +16 -4
- package/dist/components/company-card.d.ts.map +1 -1
- package/dist/components/company-card.js +16 -4
- package/dist/components/confirm-dialog.d.ts +24 -14
- package/dist/components/confirm-dialog.d.ts.map +1 -1
- package/dist/components/confirm-dialog.js +16 -10
- package/dist/components/context-menu.d.ts +10 -0
- package/dist/components/context-menu.d.ts.map +1 -1
- package/dist/components/context-menu.js +10 -0
- package/dist/components/copy-button.d.ts +10 -0
- package/dist/components/copy-button.d.ts.map +1 -1
- package/dist/components/copy-button.js +10 -0
- package/dist/components/dashboard-shell.d.ts +14 -0
- package/dist/components/dashboard-shell.d.ts.map +1 -1
- package/dist/components/dashboard-shell.js +14 -0
- package/dist/components/data-table.d.ts +20 -0
- package/dist/components/data-table.d.ts.map +1 -1
- package/dist/components/data-table.js +23 -2
- package/dist/components/desktop-shell.d.ts +15 -0
- package/dist/components/desktop-shell.d.ts.map +1 -1
- package/dist/components/desktop-shell.js +15 -0
- package/dist/components/dialog.d.ts +16 -0
- package/dist/components/dialog.d.ts.map +1 -1
- package/dist/components/dialog.js +16 -0
- package/dist/components/diff-count.d.ts +11 -0
- package/dist/components/diff-count.d.ts.map +1 -1
- package/dist/components/diff-count.js +11 -0
- package/dist/components/disclosure-row.d.ts +12 -0
- package/dist/components/disclosure-row.d.ts.map +1 -1
- package/dist/components/disclosure-row.js +12 -0
- package/dist/components/disclosure.d.ts +15 -5
- package/dist/components/disclosure.d.ts.map +1 -1
- package/dist/components/disclosure.js +15 -5
- package/dist/components/drawer.d.ts +13 -0
- package/dist/components/drawer.d.ts.map +1 -1
- package/dist/components/drawer.js +13 -0
- package/dist/components/dropdown-menu.d.ts +17 -5
- package/dist/components/dropdown-menu.d.ts.map +1 -1
- package/dist/components/dropdown-menu.js +20 -7
- package/dist/components/empty-art.d.ts +1 -1
- package/dist/components/empty-art.d.ts.map +1 -1
- package/dist/components/empty-art.js +6 -0
- package/dist/components/empty-state.d.ts +24 -10
- package/dist/components/empty-state.d.ts.map +1 -1
- package/dist/components/empty-state.js +23 -1
- package/dist/components/entry-scene.d.ts +33 -20
- package/dist/components/entry-scene.d.ts.map +1 -1
- package/dist/components/entry-scene.js +34 -7
- package/dist/components/expandable-block.d.ts +10 -0
- package/dist/components/expandable-block.d.ts.map +1 -1
- package/dist/components/expandable-block.js +10 -0
- package/dist/components/field.d.ts +17 -0
- package/dist/components/field.d.ts.map +1 -1
- package/dist/components/field.js +17 -0
- package/dist/components/file-diff.d.ts +12 -0
- package/dist/components/file-diff.d.ts.map +1 -1
- package/dist/components/file-diff.js +12 -0
- package/dist/components/file-type-icon.d.ts +12 -0
- package/dist/components/file-type-icon.d.ts.map +1 -1
- package/dist/components/file-type-icon.js +12 -0
- package/dist/components/footer.d.ts +14 -0
- package/dist/components/footer.d.ts.map +1 -1
- package/dist/components/footer.js +14 -0
- package/dist/components/form-dialog.d.ts +10 -0
- package/dist/components/form-dialog.d.ts.map +1 -1
- package/dist/components/form-dialog.js +10 -0
- package/dist/components/form-drawer.d.ts +24 -11
- package/dist/components/form-drawer.d.ts.map +1 -1
- package/dist/components/form-drawer.js +13 -3
- package/dist/components/form.d.ts +17 -0
- package/dist/components/form.d.ts.map +1 -1
- package/dist/components/form.js +17 -0
- package/dist/components/glass-control.d.ts +13 -0
- package/dist/components/glass-control.d.ts.map +1 -1
- package/dist/components/glass-control.js +13 -0
- package/dist/components/hive-scene.d.ts +14 -0
- package/dist/components/hive-scene.d.ts.map +1 -1
- package/dist/components/hive-scene.js +14 -0
- package/dist/components/house-icons.d.ts +15 -0
- package/dist/components/house-icons.d.ts.map +1 -1
- package/dist/components/house-icons.js +15 -0
- package/dist/components/hover-card.d.ts +15 -0
- package/dist/components/hover-card.d.ts.map +1 -1
- package/dist/components/hover-card.js +15 -0
- package/dist/components/identity-mark.d.ts +55 -0
- package/dist/components/identity-mark.d.ts.map +1 -0
- package/dist/components/identity-mark.js +66 -0
- package/dist/components/input-group.d.ts +16 -0
- package/dist/components/input-group.d.ts.map +1 -1
- package/dist/components/input-group.js +16 -0
- package/dist/components/input-otp.d.ts +15 -0
- package/dist/components/input-otp.d.ts.map +1 -1
- package/dist/components/input-otp.js +15 -0
- package/dist/components/input.d.ts +15 -0
- package/dist/components/input.d.ts.map +1 -1
- package/dist/components/input.js +15 -0
- package/dist/components/item.d.ts +16 -0
- package/dist/components/item.d.ts.map +1 -1
- package/dist/components/item.js +16 -0
- package/dist/components/kbd.d.ts +14 -0
- package/dist/components/kbd.d.ts.map +1 -1
- package/dist/components/kbd.js +14 -0
- package/dist/components/kpi-card.d.ts +21 -13
- package/dist/components/kpi-card.d.ts.map +1 -1
- package/dist/components/kpi-card.js +14 -3
- package/dist/components/label-system.d.ts +12 -0
- package/dist/components/label-system.d.ts.map +1 -1
- package/dist/components/label-system.js +12 -0
- package/dist/components/label.d.ts +15 -0
- package/dist/components/label.d.ts.map +1 -1
- package/dist/components/label.js +15 -0
- package/dist/components/library-shelf.d.ts +35 -0
- package/dist/components/library-shelf.d.ts.map +1 -0
- package/dist/components/library-shelf.js +40 -0
- package/dist/components/memory-item.d.ts +12 -0
- package/dist/components/memory-item.d.ts.map +1 -1
- package/dist/components/memory-item.js +12 -0
- package/dist/components/menu-choice-row.d.ts +13 -5
- package/dist/components/menu-choice-row.d.ts.map +1 -1
- package/dist/components/menu-choice-row.js +12 -6
- package/dist/components/menubar.d.ts +13 -0
- package/dist/components/menubar.d.ts.map +1 -1
- package/dist/components/menubar.js +13 -0
- package/dist/components/message-notice.d.ts +16 -0
- package/dist/components/message-notice.d.ts.map +1 -1
- package/dist/components/message-notice.js +18 -2
- package/dist/components/model-identity.d.ts +16 -3
- package/dist/components/model-identity.d.ts.map +1 -1
- package/dist/components/model-identity.js +16 -3
- package/dist/components/model-mark.d.ts +15 -2
- package/dist/components/model-mark.d.ts.map +1 -1
- package/dist/components/model-mark.js +15 -2
- package/dist/components/nadia-presence.d.ts +10 -4
- package/dist/components/nadia-presence.d.ts.map +1 -1
- package/dist/components/nadia-presence.js +10 -4
- package/dist/components/native-select.d.ts +16 -0
- package/dist/components/native-select.d.ts.map +1 -1
- package/dist/components/native-select.js +16 -0
- package/dist/components/navigation-menu.d.ts +14 -0
- package/dist/components/navigation-menu.d.ts.map +1 -1
- package/dist/components/navigation-menu.js +14 -0
- package/dist/components/notice-banner.d.ts +10 -3
- package/dist/components/notice-banner.d.ts.map +1 -1
- package/dist/components/notice-banner.js +9 -3
- package/dist/components/numbered-steps.d.ts +33 -0
- package/dist/components/numbered-steps.d.ts.map +1 -0
- package/dist/components/numbered-steps.js +23 -0
- package/dist/components/object-page.d.ts +37 -0
- package/dist/components/object-page.d.ts.map +1 -0
- package/dist/components/object-page.js +19 -0
- package/dist/components/object-workspace.d.ts +26 -36
- package/dist/components/object-workspace.d.ts.map +1 -1
- package/dist/components/object-workspace.js +27 -24
- package/dist/components/overview-page.d.ts +24 -0
- package/dist/components/overview-page.d.ts.map +1 -0
- package/dist/components/overview-page.js +26 -0
- package/dist/components/page-actions.d.ts +28 -23
- package/dist/components/page-actions.d.ts.map +1 -1
- package/dist/components/page-actions.js +20 -14
- package/dist/components/page-header.d.ts +11 -5
- package/dist/components/page-header.d.ts.map +1 -1
- package/dist/components/page-header.js +11 -5
- package/dist/components/pagination.d.ts +15 -0
- package/dist/components/pagination.d.ts.map +1 -1
- package/dist/components/pagination.js +15 -0
- package/dist/components/pairing-code.d.ts +15 -4
- package/dist/components/pairing-code.d.ts.map +1 -1
- package/dist/components/pairing-code.js +15 -4
- package/dist/components/pending-label.d.ts +12 -4
- package/dist/components/pending-label.d.ts.map +1 -1
- package/dist/components/pending-label.js +12 -4
- package/dist/components/picture-label.d.ts +15 -7
- package/dist/components/picture-label.d.ts.map +1 -1
- package/dist/components/picture-label.js +15 -7
- package/dist/components/platform-mark.d.ts +12 -3
- package/dist/components/platform-mark.d.ts.map +1 -1
- package/dist/components/platform-mark.js +12 -3
- package/dist/components/plugin-slot-boundary.d.ts +15 -0
- package/dist/components/plugin-slot-boundary.d.ts.map +1 -1
- package/dist/components/plugin-slot-boundary.js +15 -0
- package/dist/components/popover.d.ts +15 -0
- package/dist/components/popover.d.ts.map +1 -1
- package/dist/components/popover.js +15 -0
- package/dist/components/portal-sidebar-frame.d.ts +26 -12
- package/dist/components/portal-sidebar-frame.d.ts.map +1 -1
- package/dist/components/portal-sidebar-frame.js +26 -0
- package/dist/components/progress.d.ts +10 -8
- package/dist/components/progress.d.ts.map +1 -1
- package/dist/components/progress.js +11 -9
- package/dist/components/qr-code.d.ts +9 -3
- package/dist/components/qr-code.d.ts.map +1 -1
- package/dist/components/qr-code.js +9 -3
- package/dist/components/radio-group.d.ts +15 -0
- package/dist/components/radio-group.d.ts.map +1 -1
- package/dist/components/radio-group.js +15 -0
- package/dist/components/reading-column.d.ts +11 -0
- package/dist/components/reading-column.d.ts.map +1 -1
- package/dist/components/reading-column.js +11 -0
- package/dist/components/record-identity.d.ts +12 -7
- package/dist/components/record-identity.d.ts.map +1 -1
- package/dist/components/record-identity.js +11 -7
- package/dist/components/record-list.d.ts +119 -0
- package/dist/components/record-list.d.ts.map +1 -0
- package/dist/components/record-list.js +161 -0
- package/dist/components/record-sheet.d.ts +36 -0
- package/dist/components/record-sheet.d.ts.map +1 -0
- package/dist/components/record-sheet.js +19 -0
- package/dist/components/record-time.d.ts +27 -11
- package/dist/components/record-time.d.ts.map +1 -1
- package/dist/components/record-time.js +34 -12
- package/dist/components/resizable.d.ts +10 -0
- package/dist/components/resizable.d.ts.map +1 -1
- package/dist/components/resizable.js +10 -0
- package/dist/components/row-edit-form.d.ts +8 -5
- package/dist/components/row-edit-form.d.ts.map +1 -1
- package/dist/components/row-edit-form.js +8 -5
- package/dist/components/run-timeline.d.ts +24 -11
- package/dist/components/run-timeline.d.ts.map +1 -1
- package/dist/components/run-timeline.js +13 -6
- package/dist/components/scope-switcher.d.ts +11 -0
- package/dist/components/scope-switcher.d.ts.map +1 -1
- package/dist/components/scope-switcher.js +20 -9
- package/dist/components/scroll-area.d.ts +12 -0
- package/dist/components/scroll-area.d.ts.map +1 -1
- package/dist/components/scroll-area.js +12 -0
- package/dist/components/select.d.ts +16 -0
- package/dist/components/select.d.ts.map +1 -1
- package/dist/components/select.js +16 -0
- package/dist/components/separator.d.ts +11 -0
- package/dist/components/separator.d.ts.map +1 -1
- package/dist/components/separator.js +11 -0
- package/dist/components/settings-facts.d.ts +18 -1
- package/dist/components/settings-facts.d.ts.map +1 -1
- package/dist/components/settings-facts.js +20 -1
- package/dist/components/settings-page.d.ts +20 -0
- package/dist/components/settings-page.d.ts.map +1 -0
- package/dist/components/settings-page.js +16 -0
- package/dist/components/settings-section.d.ts +38 -8
- package/dist/components/settings-section.d.ts.map +1 -1
- package/dist/components/settings-section.js +33 -7
- package/dist/components/sheet.d.ts +16 -0
- package/dist/components/sheet.d.ts.map +1 -1
- package/dist/components/sheet.js +16 -0
- package/dist/components/sidebar-sections.d.ts +40 -0
- package/dist/components/sidebar-sections.d.ts.map +1 -0
- package/dist/components/sidebar-sections.js +35 -0
- package/dist/components/sidebar.d.ts +14 -1
- package/dist/components/sidebar.d.ts.map +1 -1
- package/dist/components/sidebar.js +13 -2
- package/dist/components/skeleton.d.ts +10 -0
- package/dist/components/skeleton.d.ts.map +1 -1
- package/dist/components/skeleton.js +11 -1
- package/dist/components/slider.d.ts +14 -0
- package/dist/components/slider.d.ts.map +1 -1
- package/dist/components/slider.js +14 -0
- package/dist/components/sonner.d.ts +18 -0
- package/dist/components/sonner.d.ts.map +1 -1
- package/dist/components/sonner.js +18 -0
- package/dist/components/status-badge.d.ts +13 -2
- package/dist/components/status-badge.d.ts.map +1 -1
- package/dist/components/status-badge.js +21 -9
- package/dist/components/status-dot.d.ts +12 -0
- package/dist/components/status-dot.d.ts.map +1 -1
- package/dist/components/status-dot.js +12 -0
- package/dist/components/status-row.d.ts +14 -0
- package/dist/components/status-row.d.ts.map +1 -1
- package/dist/components/status-row.js +14 -0
- package/dist/components/switch.d.ts +15 -0
- package/dist/components/switch.d.ts.map +1 -1
- package/dist/components/switch.js +15 -0
- package/dist/components/table-card.d.ts +16 -3
- package/dist/components/table-card.d.ts.map +1 -1
- package/dist/components/table-card.js +16 -3
- package/dist/components/table-value.d.ts +24 -2
- package/dist/components/table-value.d.ts.map +1 -1
- package/dist/components/table-value.js +25 -3
- package/dist/components/table.d.ts +16 -0
- package/dist/components/table.d.ts.map +1 -1
- package/dist/components/table.js +17 -1
- package/dist/components/tabs.d.ts +27 -0
- package/dist/components/tabs.d.ts.map +1 -1
- package/dist/components/tabs.js +27 -0
- package/dist/components/tag.d.ts +12 -2
- package/dist/components/tag.d.ts.map +1 -1
- package/dist/components/tag.js +12 -2
- package/dist/components/text-link.d.ts +17 -0
- package/dist/components/text-link.d.ts.map +1 -1
- package/dist/components/text-link.js +17 -0
- package/dist/components/textarea.d.ts +14 -0
- package/dist/components/textarea.d.ts.map +1 -1
- package/dist/components/textarea.js +14 -0
- package/dist/components/theme-mode-switcher.d.ts +21 -0
- package/dist/components/theme-mode-switcher.d.ts.map +1 -1
- package/dist/components/theme-mode-switcher.js +23 -1
- package/dist/components/toggle-group.d.ts +13 -0
- package/dist/components/toggle-group.d.ts.map +1 -1
- package/dist/components/toggle-group.js +13 -0
- package/dist/components/toggle.d.ts +14 -0
- package/dist/components/toggle.d.ts.map +1 -1
- package/dist/components/toggle.js +14 -0
- package/dist/components/tool-icon.d.ts +14 -4
- package/dist/components/tool-icon.d.ts.map +1 -1
- package/dist/components/tool-icon.js +27 -42
- package/dist/components/tooltip.d.ts +15 -0
- package/dist/components/tooltip.d.ts.map +1 -1
- package/dist/components/tooltip.js +15 -0
- package/dist/components/trend-badge.d.ts +16 -1
- package/dist/components/trend-badge.d.ts.map +1 -1
- package/dist/components/trend-badge.js +16 -7
- package/dist/components/update-card.d.ts +36 -0
- package/dist/components/update-card.d.ts.map +1 -0
- package/dist/components/update-card.js +28 -0
- package/dist/components/usage-meter.d.ts +15 -0
- package/dist/components/usage-meter.d.ts.map +1 -1
- package/dist/components/usage-meter.js +15 -0
- package/dist/components/waiting-line.d.ts +13 -10
- package/dist/components/waiting-line.d.ts.map +1 -1
- package/dist/components/waiting-line.js +13 -10
- package/dist/eslint/index.js +8 -0
- package/dist/eslint/rules/empty-state-owner.js +145 -0
- package/dist/eslint/rules/menu-owner.js +75 -0
- package/dist/eslint/rules/no-decorative-icon.js +164 -0
- package/dist/eslint/rules/page-composition.js +232 -0
- package/dist/eslint/rules/rendered-import.js +121 -0
- package/dist/eslint/strict-design-system.js +1 -1
- package/dist/hooks/use-hydrated.d.ts +2 -0
- package/dist/hooks/use-hydrated.d.ts.map +1 -0
- package/dist/hooks/use-hydrated.js +7 -0
- package/dist/index.d.ts +15 -10
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +15 -10
- package/dist/internal/catalog-list.d.ts +14 -0
- package/dist/internal/catalog-list.d.ts.map +1 -0
- package/dist/internal/catalog-list.js +53 -0
- package/dist/internal/empty.d.ts +6 -9
- package/dist/internal/empty.d.ts.map +1 -1
- package/dist/internal/empty.js +24 -22
- package/dist/internal/footer-strip.d.ts +0 -4
- package/dist/internal/footer-strip.d.ts.map +1 -1
- package/dist/internal/footer-strip.js +0 -4
- package/dist/internal/record-menu-items.d.ts +19 -0
- package/dist/internal/record-menu-items.d.ts.map +1 -0
- package/dist/internal/record-menu-items.js +20 -0
- package/dist/internal/settings-save.d.ts +43 -0
- package/dist/internal/settings-save.d.ts.map +1 -0
- package/dist/internal/settings-save.js +147 -0
- package/dist/lib/theme-mode.d.ts +1 -1
- package/dist/lib/theme-mode.js +1 -1
- package/dist/showcase/assets.d.ts +8 -0
- package/dist/showcase/assets.d.ts.map +1 -0
- package/dist/showcase/assets.js +13 -0
- package/dist/showcase/foundations.d.ts +2 -0
- package/dist/showcase/foundations.d.ts.map +1 -0
- package/dist/showcase/foundations.js +61 -0
- package/dist/showcase/samples.d.ts +21 -0
- package/dist/showcase/samples.d.ts.map +1 -0
- package/dist/showcase/samples.js +48 -0
- package/dist/showcase/showcase.d.ts +10 -0
- package/dist/showcase/showcase.d.ts.map +1 -0
- package/dist/showcase/showcase.js +44 -0
- package/dist/showcase/specimens/actions.d.ts +7 -0
- package/dist/showcase/specimens/actions.d.ts.map +1 -0
- package/dist/showcase/specimens/actions.js +15 -0
- package/dist/showcase/specimens/charts.d.ts +17 -0
- package/dist/showcase/specimens/charts.d.ts.map +1 -0
- package/dist/showcase/specimens/charts.js +104 -0
- package/dist/showcase/specimens/choices.d.ts +21 -0
- package/dist/showcase/specimens/choices.d.ts.map +1 -0
- package/dist/showcase/specimens/choices.js +68 -0
- package/dist/showcase/specimens/compositions.d.ts +39 -0
- package/dist/showcase/specimens/compositions.d.ts.map +1 -0
- package/dist/showcase/specimens/compositions.js +270 -0
- package/dist/showcase/specimens/data.d.ts +31 -0
- package/dist/showcase/specimens/data.d.ts.map +1 -0
- package/dist/showcase/specimens/data.js +111 -0
- package/dist/showcase/specimens/feedback.d.ts +23 -0
- package/dist/showcase/specimens/feedback.d.ts.map +1 -0
- package/dist/showcase/specimens/feedback.js +64 -0
- package/dist/showcase/specimens/index.d.ts +164 -0
- package/dist/showcase/specimens/index.d.ts.map +1 -0
- package/dist/showcase/specimens/index.js +24 -0
- package/dist/showcase/specimens/inputs.d.ts +22 -0
- package/dist/showcase/specimens/inputs.d.ts.map +1 -0
- package/dist/showcase/specimens/inputs.js +60 -0
- package/dist/showcase/specimens/menus.d.ts +20 -0
- package/dist/showcase/specimens/menus.d.ts.map +1 -0
- package/dist/showcase/specimens/menus.js +65 -0
- package/dist/showcase/specimens/navigation.d.ts +22 -0
- package/dist/showcase/specimens/navigation.d.ts.map +1 -0
- package/dist/showcase/specimens/navigation.js +103 -0
- package/dist/showcase/specimens/other.d.ts +26 -0
- package/dist/showcase/specimens/other.d.ts.map +1 -0
- package/dist/showcase/specimens/other.js +73 -0
- package/dist/showcase/specimens/specimen.d.ts +5 -0
- package/dist/showcase/specimens/specimen.d.ts.map +1 -0
- package/dist/showcase/specimens/specimen.js +1 -0
- package/dist/showcase/specimens/status.d.ts +22 -0
- package/dist/showcase/specimens/status.d.ts.map +1 -0
- package/dist/showcase/specimens/status.js +44 -0
- package/dist/showcase/usage.generated.d.ts +16 -0
- package/dist/showcase/usage.generated.d.ts.map +1 -0
- package/dist/showcase/usage.generated.js +1788 -0
- package/dist/standalone/index.js +1 -1
- package/dist/styles/components.css +21 -0
- package/package.json +8 -3
- package/dist/components/automation-section.d.ts +0 -78
- package/dist/components/automation-section.d.ts.map +0 -1
- package/dist/components/automation-section.js +0 -75
- package/dist/components/catalog-tile.d.ts +0 -19
- package/dist/components/catalog-tile.d.ts.map +0 -1
- package/dist/components/catalog-tile.js +0 -13
- package/dist/components/feedback-state.d.ts +0 -14
- package/dist/components/feedback-state.d.ts.map +0 -1
- package/dist/components/feedback-state.js +0 -65
- package/dist/components/installer-shell.d.ts +0 -25
- package/dist/components/installer-shell.d.ts.map +0 -1
- package/dist/components/installer-shell.js +0 -32
- package/dist/components/settings-form.d.ts +0 -9
- package/dist/components/settings-form.d.ts.map +0 -1
- package/dist/components/settings-form.js +0 -83
|
@@ -38,7 +38,19 @@ function FilterPicker({ facets, copy, initialField, returnFocus, children, }) {
|
|
|
38
38
|
}
|
|
39
39
|
}, children: [_jsx(CommandInput, { ref: input, "aria-label": facet ? `${copy.searchValues}: ${facet.label}` : copy.searchFields, placeholder: facet ? copy.searchValues : copy.searchFields, value: search, onValueChange: setSearch }), _jsxs(CommandList, { label: facet?.label ?? copy.searchFields, children: [_jsx(CommandEmpty, { children: copy.empty }), _jsx(CommandGroup, { heading: facet?.label, children: facet ? (_jsxs(_Fragment, { children: [facet.value ? (_jsx(CommandItem, { value: facet.allLabel, onSelect: () => commit(""), children: facet.allLabel })) : null, facet.options.map((option) => (_jsxs(CommandItem, { value: option.value, keywords: [option.label], "data-checked": option.value === facet.value, onSelect: () => commit(option.value), children: [option.icon, _jsx("span", { className: option.mono ? "truncate font-label-mono text-label-mono" : "truncate", children: option.label })] }, option.value)))] })) : (facets.map((item) => (_jsx(CommandItem, { value: item.label, onSelect: () => changeField(item.label), children: item.label }, item.label)))) })] })] }, field ?? "fields")] })] }));
|
|
40
40
|
}
|
|
41
|
-
|
|
41
|
+
/**
|
|
42
|
+
* The filters in a collection's toolbar: one Add filter button, a chip for
|
|
43
|
+
* each facet in force, and the facets most often narrowed to waiting as
|
|
44
|
+
* dashed chips.
|
|
45
|
+
*
|
|
46
|
+
* @family Compositions
|
|
47
|
+
* @when A collection or a feed a person narrows by a property its records share: a status, an owner, a kind. It stands in the toolbar after the search and before the sort.
|
|
48
|
+
* @instead Finding one record by its name is the search. Changing the order is the sort. Switching between sibling collections is the page's tabs.
|
|
49
|
+
* @behaviour Add filter opens a picker of the facets, then of a facet's values, each searchable; Backspace in an empty search goes back to the facets. A facet in force is a chip that reopens its values, with a button that removes it. A suggested value waits as a dashed chip while its facet is unset and applies in one click. Focus returns to Add filter when a facet is removed. The product keeps each facet's value, in the URL where it has one.
|
|
50
|
+
* @words Every string is the product's: `copy` names Add filter, the two searches, the empty result, Back and Remove; each facet names itself, its values and its "All" choice.
|
|
51
|
+
* @access Each chip is a group named by its facet; its remove button reads Remove with the facet's name. The pickers are searchable lists named by what they search.
|
|
52
|
+
*/
|
|
53
|
+
export function CollectionFilters({ facets, copy }) {
|
|
42
54
|
const addTrigger = React.useRef(null);
|
|
43
55
|
if (!facets.length)
|
|
44
56
|
return null;
|
|
@@ -1,125 +1,39 @@
|
|
|
1
1
|
import type { RowData } from "@tanstack/react-table";
|
|
2
|
-
import {
|
|
2
|
+
import type { ReactElement } from "react";
|
|
3
|
+
import { type CollectionFiltersProps } from "./collection-filters.js";
|
|
4
|
+
import { type CollectionSearchProps } from "./collection-search.js";
|
|
3
5
|
import { type CollectionSortProps } from "./collection-sort.js";
|
|
4
|
-
import {
|
|
5
|
-
import { type EmptyStateProps } from "./empty-state.js";
|
|
6
|
+
import type { EmptyStateKind } from "./empty-state.js";
|
|
6
7
|
import { type PageActionsProps } from "./page-actions.js";
|
|
7
|
-
import { type
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
label: string;
|
|
12
|
-
/** Its name for assistive technology when the label alone does not say what it does: "Let Sofia use Gmail". */
|
|
13
|
-
accessibleName?: string;
|
|
14
|
-
icon: ReactElement;
|
|
15
|
-
onSelect: () => void;
|
|
16
|
-
destructive?: boolean;
|
|
17
|
-
disabled?: boolean;
|
|
18
|
-
/** Why the command cannot run now, read after its name. */
|
|
19
|
-
reason?: ReactNode;
|
|
20
|
-
};
|
|
21
|
-
export type { RowMessage };
|
|
22
|
-
export type CollectionPageProps<TRecord extends RowData> = {
|
|
23
|
-
/** Names the collection for assistive technology: "Skills". */
|
|
24
|
-
label: string;
|
|
25
|
-
/** The page's title, when the collection is the page; a section titled by its shell leaves it out. */
|
|
8
|
+
import { type RecordListProps } from "./record-list.js";
|
|
9
|
+
export type { RowMessage } from "./record-list.js";
|
|
10
|
+
export type CollectionPageProps<TRecord extends RowData> = Omit<RecordListProps<TRecord>, "heading" | "noMatch"> & {
|
|
11
|
+
/** The page's title, when the product's chrome does not draw it. */
|
|
26
12
|
title?: string;
|
|
27
|
-
/** The title
|
|
28
|
-
actions?: PageActionsProps
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
};
|
|
13
|
+
/** The title row: secondary, primary, then the three dots. A `primary` equal to `empty.action` shows only once there are records. */
|
|
14
|
+
actions?: Omit<PageActionsProps, "period">;
|
|
15
|
+
/** The page's sibling collections, under the title row: `TabsNav variant="line"`. */
|
|
16
|
+
tabs?: ReactElement;
|
|
17
|
+
search?: CollectionSearchProps;
|
|
18
|
+
filters?: CollectionFiltersProps;
|
|
34
19
|
sort?: CollectionSortProps;
|
|
35
|
-
/**
|
|
36
|
-
|
|
37
|
-
/**
|
|
38
|
-
|
|
39
|
-
/** The
|
|
40
|
-
|
|
41
|
-
kind: "failed";
|
|
42
|
-
}>;
|
|
43
|
-
/** There are no records at all; a collection shown only when it has records leaves it out. */
|
|
44
|
-
empty?: Extract<EmptyStateProps, {
|
|
45
|
-
kind: "firstUse" | "nothingYet";
|
|
46
|
-
}>;
|
|
47
|
-
/** The search matched nothing; a collection without one leaves it out. */
|
|
48
|
-
noMatch?: Omit<Extract<EmptyStateProps, {
|
|
49
|
-
kind: "noResults";
|
|
50
|
-
}>, "kind">;
|
|
51
|
-
getId: (record: TRecord) => string;
|
|
52
|
-
/** The record's name, and one line saying what it is or where it comes from. */
|
|
53
|
-
name: (record: TRecord) => {
|
|
54
|
-
name: ReactNode;
|
|
55
|
-
detail?: ReactNode;
|
|
56
|
-
mark?: ReactNode;
|
|
57
|
-
};
|
|
58
|
-
/** The name is the record's whole text, such as a memory, and wraps in full instead of ending in an ellipsis. */
|
|
59
|
-
wraps?: boolean;
|
|
60
|
-
/**
|
|
61
|
-
* Facts of one kind each, a column apiece after the name, every value saying
|
|
62
|
-
* what it is by its own word or mark: "Skills: price-quotes", a commit. A fact
|
|
63
|
-
* holds one line at its own width; `prose` is a phrase that takes the row's spare width.
|
|
64
|
-
*/
|
|
65
|
-
facts?: readonly {
|
|
66
|
-
id: string;
|
|
67
|
-
label: string;
|
|
68
|
-
of: (record: TRecord) => ReactNode;
|
|
69
|
-
prose?: boolean;
|
|
70
|
-
}[];
|
|
71
|
-
/** A status only when it tells this record apart from the others; `null` for the usual case. */
|
|
72
|
-
status?: {
|
|
73
|
-
label: string;
|
|
74
|
-
of: (record: TRecord) => {
|
|
75
|
-
label: string;
|
|
76
|
-
tone: StatusBadgeTone;
|
|
77
|
-
} | null;
|
|
78
|
-
};
|
|
79
|
-
/** When something happened to the record, in its verb's sentence. */
|
|
80
|
-
time?: {
|
|
81
|
-
label: string;
|
|
82
|
-
of: (record: TRecord) => Date | number | string | null | undefined;
|
|
83
|
-
phrase: (when: string) => string;
|
|
84
|
-
/** What a screen reader hears where a record has no time, beside the muted dash. */
|
|
85
|
-
missing: string;
|
|
86
|
-
locale?: string;
|
|
87
|
-
};
|
|
88
|
-
/**
|
|
89
|
-
* What a person can do to the record: one command is a button in the row; two or
|
|
90
|
-
* more, or a destructive one, open the row's menu, the destructive last.
|
|
91
|
-
*/
|
|
92
|
-
commands?: (record: TRecord) => readonly RecordCommand[];
|
|
93
|
-
/**
|
|
94
|
-
* The row's one outline button that starts what the record is not doing yet,
|
|
95
|
-
* "Connect", with what it is waiting for; its commands then stay in the menu after it.
|
|
96
|
-
*/
|
|
97
|
-
start?: (record: TRecord) => ReactNode;
|
|
98
|
-
commandsLabel?: (record: TRecord) => string;
|
|
99
|
-
/** Names the commands column for assistive technology: "Actions". */
|
|
100
|
-
commandsHeader?: string;
|
|
101
|
-
/** The record opens its own page; the row shows the way in. A record that opens nothing has no `href`. */
|
|
102
|
-
open?: {
|
|
103
|
-
href: (record: TRecord) => string | null;
|
|
104
|
-
label: (record: TRecord) => string;
|
|
105
|
-
/** Draws the row's link, for a router that opens it itself. */
|
|
106
|
-
renderLink?: (props: DataTableRowLinkProps) => ReactNode;
|
|
107
|
-
};
|
|
108
|
-
/** The record's own action failed or cannot run: its message, inside the row. */
|
|
109
|
-
state?: (record: TRecord) => RowMessage | null;
|
|
110
|
-
/** The record being edited, and its `RowEditForm`, drawn inside its row. */
|
|
111
|
-
editor?: {
|
|
112
|
-
id: string;
|
|
113
|
-
render: (record: TRecord) => ReactNode;
|
|
114
|
-
};
|
|
20
|
+
/** glass only where the rows scroll under the toolbar. */
|
|
21
|
+
toolbarSurface?: "plain" | "glass";
|
|
22
|
+
/** The search or the filters matched nothing. */
|
|
23
|
+
noMatch?: Omit<EmptyStateKind<"noResults">, "kind">;
|
|
24
|
+
/** The records of a new search, filter or sort are being read; the rows shown are the last ones. */
|
|
25
|
+
pending?: boolean;
|
|
115
26
|
};
|
|
116
27
|
/**
|
|
117
|
-
*
|
|
118
|
-
*
|
|
119
|
-
*
|
|
120
|
-
*
|
|
121
|
-
*
|
|
122
|
-
*
|
|
28
|
+
* A page whose job is a list of records: its title with the page's actions on
|
|
29
|
+
* one row, its sibling collections, one toolbar, then one line per record.
|
|
30
|
+
*
|
|
31
|
+
* @family Compositions
|
|
32
|
+
* @when A list of records a person finds one of and acts on: Customers, Agents, Skills, Apps, MCP servers, Mailboxes.
|
|
33
|
+
* @instead Figures compared across records are a DataTable with headings; a list inside another page's section is a RecordList with its heading.
|
|
34
|
+
* @behaviour Nothing sits under the title. The title row holds at most one secondary, the primary, then the three dots, which open only for two commands or more. A primary that is also the first use's action waits until there are records; while a different primary stays, the first use's action is an outline button. One toolbar holds the search, which grows, then the filters, then the sort; it shows while there are records or a search or filter is set, and is glass only where the rows scroll under it. While a new search, filter or sort is read, the toolbar is busy and, after a second, shows the one waiting line, while the last rows stay. The rows, their states and their loading are the RecordList's; no match is offered only while a search or filter is set.
|
|
35
|
+
* @words Every string is the product's. The title names the collection in the plural ("Agents"); the search says what it finds ("Find a skill"); no match says what found nothing and offers to clear it ("Clear search", "Clear filters").
|
|
36
|
+
* @access The title is the page's h1 when the composition draws it. The toolbar is named by `label` and busy while `pending`; the rows are the RecordList's table, named by `label`.
|
|
123
37
|
*/
|
|
124
38
|
export declare function CollectionPage<TRecord extends RowData>(props: CollectionPageProps<TRecord>): import("react").JSX.Element;
|
|
125
39
|
//# sourceMappingURL=collection-page.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collection-page.d.ts","sourceRoot":"","sources":["../../src/components/collection-page.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"collection-page.d.ts","sourceRoot":"","sources":["../../src/components/collection-page.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AACrD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,OAAO,CAAC;AAE1C,OAAO,EAAqB,KAAK,sBAAsB,EAAE,MAAM,iCAAiC,CAAC;AACjG,OAAO,EAAoB,KAAK,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AAC9F,OAAO,EAAkB,KAAK,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AAExF,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EAGL,KAAK,gBAAgB,EACtB,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EAAc,KAAK,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAG5E,YAAY,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AAE3D,MAAM,MAAM,mBAAmB,CAAC,OAAO,SAAS,OAAO,IAAI,IAAI,CAC7D,eAAe,CAAC,OAAO,CAAC,EACxB,SAAS,GAAG,SAAS,CACtB,GAAG;IACF,oEAAoE;IACpE,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,qIAAqI;IACrI,OAAO,CAAC,EAAE,IAAI,CAAC,gBAAgB,EAAE,QAAQ,CAAC,CAAC;IAC3C,qFAAqF;IACrF,IAAI,CAAC,EAAE,YAAY,CAAC;IACpB,MAAM,CAAC,EAAE,qBAAqB,CAAC;IAC/B,OAAO,CAAC,EAAE,sBAAsB,CAAC;IACjC,IAAI,CAAC,EAAE,mBAAmB,CAAC;IAC3B,0DAA0D;IAC1D,cAAc,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC;IACnC,iDAAiD;IACjD,OAAO,CAAC,EAAE,IAAI,CAAC,cAAc,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC,CAAC;IACpD,oGAAoG;IACpG,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB,CAAC;AAEF;;;;;;;;;;GAUG;AACH,wBAAgB,cAAc,CAAC,OAAO,SAAS,OAAO,EAAE,KAAK,EAAE,mBAAmB,CAAC,OAAO,CAAC,+BA0C1F"}
|
|
@@ -1,150 +1,34 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
-
import {
|
|
4
|
-
import { createContext, useContext } from "react";
|
|
5
|
-
import { ActionMenu } from "./action-menu.js";
|
|
6
|
-
import { Button } from "./button.js";
|
|
3
|
+
import { CollectionFilters } from "./collection-filters.js";
|
|
7
4
|
import { CollectionSearch } from "./collection-search.js";
|
|
8
5
|
import { CollectionSort } from "./collection-sort.js";
|
|
9
6
|
import { CollectionToolbar } from "./collection-toolbar.js";
|
|
10
|
-
import {
|
|
11
|
-
import { DropdownMenuCommand, DropdownMenuSeparator } from "./dropdown-menu.js";
|
|
12
|
-
import { EmptyState } from "./empty-state.js";
|
|
13
|
-
import { PageActions } from "./page-actions.js";
|
|
7
|
+
import { PageActions, PageActionsHostProvider, } from "./page-actions.js";
|
|
14
8
|
import { PageHeader } from "./page-header.js";
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import { TableValue } from "./table-value.js";
|
|
18
|
-
import { Skeleton } from "./skeleton.js";
|
|
19
|
-
import { StatusBadge } from "./status-badge.js";
|
|
20
|
-
import { TableCard } from "./table-card.js";
|
|
21
|
-
import { RowMessageActions, RowMessageLine } from "../internal/row-message.js";
|
|
22
|
-
const ShownCollection = createContext(undefined);
|
|
23
|
-
function useShownCollection() {
|
|
24
|
-
// SAFETY: the one ShownCollection provider is CollectionPage's render, which passes its own props, and these cells render only inside that page's table of the same TRecord.
|
|
25
|
-
return useContext(ShownCollection);
|
|
26
|
-
}
|
|
27
|
-
/*
|
|
28
|
-
* Each cell is one component for the page's whole life: TanStack renders a
|
|
29
|
-
* column's `cell` as a component, so a function made anew on each render would
|
|
30
|
-
* remount every row's cells on every render, closing a row's open menu when
|
|
31
|
-
* the records are read again. The cells read the page's current props instead.
|
|
32
|
-
*/
|
|
33
|
-
function NameCell({ row }) {
|
|
34
|
-
const props = useShownCollection();
|
|
35
|
-
const shown = props.name(row.original);
|
|
36
|
-
const state = props.state?.(row.original);
|
|
37
|
-
return (_jsx(RecordIdentity, { detail: state ? _jsx(RowMessageLine, { state: state }) : shown.detail, mark: shown.mark, name: shown.name, wraps: props.wraps }));
|
|
38
|
-
}
|
|
39
|
-
function FactCell({ column, row }) {
|
|
40
|
-
const fact = useShownCollection().facts?.find((each) => each.id === column.id);
|
|
41
|
-
return _jsx(_Fragment, { children: fact?.of(row.original) });
|
|
42
|
-
}
|
|
43
|
-
function StatusCell({ row }) {
|
|
44
|
-
const shown = useShownCollection().status?.of(row.original);
|
|
45
|
-
return shown ? _jsx(StatusBadge, { label: shown.label, tone: shown.tone }) : null;
|
|
46
|
-
}
|
|
47
|
-
function TimeCell({ row }) {
|
|
48
|
-
const time = useShownCollection().time;
|
|
49
|
-
if (!time)
|
|
50
|
-
return null;
|
|
51
|
-
const at = recordDate(time.of(row.original));
|
|
52
|
-
return (_jsx(TableValue, { missingLabel: time.missing, value: at ? _jsx(RecordTime, { at: at, locale: time.locale, phrase: time.phrase }) : null }));
|
|
53
|
-
}
|
|
54
|
-
function CommandsCell({ row }) {
|
|
55
|
-
const props = useShownCollection();
|
|
56
|
-
const state = props.state?.(row.original);
|
|
57
|
-
const commands = props.commands?.(row.original) ?? [];
|
|
58
|
-
const way = commands.length > 0 ? (_jsx(Commands, { commands: commands, label: props.commandsLabel?.(row.original) ?? props.label, menu: props.start !== undefined })) : props.open?.href(row.original) && !state ? (_jsx(ChevronRight, { "aria-hidden": "true", className: "size-4 text-muted-foreground" })) : null;
|
|
59
|
-
if (!props.start && !state)
|
|
60
|
-
return way;
|
|
61
|
-
return (_jsxs("div", { className: "flex items-center justify-end gap-2", children: [props.start?.(row.original), state ? _jsx(RowMessageActions, { state: state }) : null, way] }));
|
|
62
|
-
}
|
|
63
|
-
function LoadingRecords({ label }) {
|
|
64
|
-
return (_jsx("div", { "aria-busy": "true", "aria-label": label, className: "divide-y divide-border", role: "status", children: Array.from({ length: 3 }, (_, index) => (_jsxs("div", { className: "flex h-16 items-center gap-3 px-4", children: [_jsxs("div", { className: "grid gap-1.5", children: [_jsx(Skeleton, { className: "h-4 w-40 max-w-full" }), _jsx(Skeleton, { className: "h-3 w-56 max-w-full" })] }), _jsx(Skeleton, { className: "ml-auto h-4 w-28" })] }, index))) }));
|
|
65
|
-
}
|
|
66
|
-
function Commands({ commands, label, menu, }) {
|
|
67
|
-
const [only] = commands;
|
|
68
|
-
if (!only)
|
|
69
|
-
return null;
|
|
70
|
-
if (commands.length === 1 && !only.destructive && !menu) {
|
|
71
|
-
return (_jsx(Button, { "aria-label": only.accessibleName, disabled: only.disabled, onClick: only.onSelect, type: "button", variant: "outline", children: only.label }));
|
|
72
|
-
}
|
|
73
|
-
const kept = commands.filter((command) => !command.destructive);
|
|
74
|
-
const destructive = commands.filter((command) => command.destructive);
|
|
75
|
-
return (_jsxs(ActionMenu, { label: label, children: [kept.map((command) => (_jsx(DropdownMenuCommand, { "aria-label": command.accessibleName, disabled: command.disabled, icon: command.icon, onClick: command.onSelect, reason: command.reason, children: command.label }, command.label))), kept.length > 0 && destructive.length > 0 ? _jsx(DropdownMenuSeparator, {}) : null, destructive.map((command) => (_jsx(DropdownMenuCommand, { "aria-label": command.accessibleName, disabled: command.disabled, icon: command.icon, onClick: command.onSelect, reason: command.reason, variant: "destructive", children: command.label }, command.label)))] }));
|
|
76
|
-
}
|
|
9
|
+
import { RecordList } from "./record-list.js";
|
|
10
|
+
import { WaitingLine } from "./waiting-line.js";
|
|
77
11
|
/**
|
|
78
|
-
*
|
|
79
|
-
*
|
|
80
|
-
*
|
|
81
|
-
*
|
|
82
|
-
*
|
|
83
|
-
*
|
|
12
|
+
* A page whose job is a list of records: its title with the page's actions on
|
|
13
|
+
* one row, its sibling collections, one toolbar, then one line per record.
|
|
14
|
+
*
|
|
15
|
+
* @family Compositions
|
|
16
|
+
* @when A list of records a person finds one of and acts on: Customers, Agents, Skills, Apps, MCP servers, Mailboxes.
|
|
17
|
+
* @instead Figures compared across records are a DataTable with headings; a list inside another page's section is a RecordList with its heading.
|
|
18
|
+
* @behaviour Nothing sits under the title. The title row holds at most one secondary, the primary, then the three dots, which open only for two commands or more. A primary that is also the first use's action waits until there are records; while a different primary stays, the first use's action is an outline button. One toolbar holds the search, which grows, then the filters, then the sort; it shows while there are records or a search or filter is set, and is glass only where the rows scroll under it. While a new search, filter or sort is read, the toolbar is busy and, after a second, shows the one waiting line, while the last rows stay. The rows, their states and their loading are the RecordList's; no match is offered only while a search or filter is set.
|
|
19
|
+
* @words Every string is the product's. The title names the collection in the plural ("Agents"); the search says what it finds ("Find a skill"); no match says what found nothing and offers to clear it ("Clear search", "Clear filters").
|
|
20
|
+
* @access The title is the page's h1 when the composition draws it. The toolbar is named by `label` and busy while `pending`; the rows are the RecordList's table, named by `label`.
|
|
84
21
|
*/
|
|
85
22
|
export function CollectionPage(props) {
|
|
86
|
-
const {
|
|
87
|
-
const hasRecords = records !== undefined && records.length > 0;
|
|
88
|
-
const
|
|
89
|
-
const
|
|
90
|
-
const
|
|
91
|
-
const
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
header: fact.label,
|
|
98
|
-
meta: fact.prose ? { prose: true } : { narrow: true },
|
|
99
|
-
cell: FactCell,
|
|
100
|
-
});
|
|
101
|
-
}
|
|
102
|
-
if (props.status) {
|
|
103
|
-
columns.push({
|
|
104
|
-
id: "status",
|
|
105
|
-
header: props.status.label,
|
|
106
|
-
meta: { narrow: true },
|
|
107
|
-
cell: StatusCell,
|
|
108
|
-
});
|
|
109
|
-
}
|
|
110
|
-
if (props.time) {
|
|
111
|
-
columns.push({ id: "time", header: props.time.label, meta: { narrow: true }, cell: TimeCell });
|
|
112
|
-
}
|
|
113
|
-
if (props.commands || props.open || props.state || props.start) {
|
|
114
|
-
columns.push({
|
|
115
|
-
id: "commands",
|
|
116
|
-
header: props.commandsHeader ?? label,
|
|
117
|
-
meta: { narrow: true },
|
|
118
|
-
cell: CommandsCell,
|
|
119
|
-
});
|
|
120
|
-
}
|
|
121
|
-
const primaryColumns = columns.map((column) => String(column.id));
|
|
122
|
-
let body;
|
|
123
|
-
if (props.failed) {
|
|
124
|
-
body = _jsx(EmptyState, { ...props.failed });
|
|
125
|
-
}
|
|
126
|
-
else if (records === undefined) {
|
|
127
|
-
body = _jsx(LoadingRecords, { label: props.loadingLabel ?? label });
|
|
128
|
-
}
|
|
129
|
-
else if (!hasRecords && searching && props.noMatch) {
|
|
130
|
-
body = _jsx(EmptyState, { kind: "noResults", ...props.noMatch });
|
|
131
|
-
}
|
|
132
|
-
else if (!hasRecords) {
|
|
133
|
-
body = props.empty ? _jsx(EmptyState, { ...props.empty }) : null;
|
|
134
|
-
}
|
|
135
|
-
else {
|
|
136
|
-
const table = {
|
|
137
|
-
columns,
|
|
138
|
-
data: [...records],
|
|
139
|
-
embedded: true,
|
|
140
|
-
empty: { kind: "nothingYet", message: label },
|
|
141
|
-
getRowId: props.getId,
|
|
142
|
-
primaryColumns,
|
|
143
|
-
showColumnHeaders: false,
|
|
144
|
-
rowEditor: props.editor ? { rowId: props.editor.id, render: props.editor.render } : undefined,
|
|
145
|
-
tableLabel: label,
|
|
146
|
-
};
|
|
147
|
-
body = props.open ? (_jsx(DataTable, { ...table, primaryColumnId: "name", renderRowLink: props.open.renderLink, rowHref: props.open.href, rowLabel: props.open.label })) : (_jsx(DataTable, { ...table }));
|
|
148
|
-
}
|
|
149
|
-
return (_jsxs("div", { className: "grid min-w-0 gap-4", "data-slot": "collection-page", children: [title ? _jsx(PageHeader, { title: title }) : null, shownActions ? _jsx(PageActions, { ...shownActions }) : null, search && (hasRecords || searching) ? (_jsx(CollectionToolbar, { actions: sort ? _jsx(CollectionSort, { ...sort }) : undefined, label: label, search: _jsx(CollectionSearch, { ...search }), surface: "plain" })) : null, _jsx(TableCard, { children: _jsx(ShownCollection.Provider, { value: props, children: body }) })] }));
|
|
23
|
+
const { title, actions, tabs, search, filters, sort, toolbarSurface, noMatch, pending, ...list } = props;
|
|
24
|
+
const hasRecords = list.records !== undefined && list.records.length > 0;
|
|
25
|
+
const narrowed = Boolean(search?.value) || (filters?.facets.some((facet) => facet.value) ?? false);
|
|
26
|
+
const { primary, ...withoutPrimary } = actions ?? {};
|
|
27
|
+
const addsFirst = primary !== undefined && list.empty?.kind === "firstUse" && list.empty.action === primary;
|
|
28
|
+
const shownActions = addsFirst && !hasRecords && !narrowed ? withoutPrimary : actions;
|
|
29
|
+
const empty = list.empty?.kind === "firstUse" && list.empty.action && primary !== undefined && !addsFirst
|
|
30
|
+
? { ...list.empty, actionVariant: "outline" }
|
|
31
|
+
: list.empty;
|
|
32
|
+
const page = (_jsxs("div", { className: "grid min-w-0 gap-4", "data-slot": "collection-page", children: [title ? _jsx(PageHeader, { title: title }) : null, shownActions ? _jsx(PageActions, { ...shownActions }) : null, tabs, (search || filters || sort) && (hasRecords || narrowed) ? (_jsx(CollectionToolbar, { actions: filters || sort ? (_jsxs(_Fragment, { children: [filters ? _jsx(CollectionFilters, { ...filters }) : null, sort ? _jsx(CollectionSort, { ...sort }) : null] })) : undefined, "aria-busy": pending || undefined, label: list.label, search: search ? _jsx(CollectionSearch, { ...search }) : undefined, status: pending ? _jsx(WaitingLine, { className: "w-24", decorative: true }) : null, surface: toolbarSurface ?? "plain" })) : null, _jsx(RecordList, { ...list, empty: empty, noMatch: narrowed ? noMatch : undefined })] }));
|
|
33
|
+
return title ? _jsx(PageActionsHostProvider, { children: page }) : page;
|
|
150
34
|
}
|
|
@@ -6,5 +6,19 @@ export type CollectionSearchProps = {
|
|
|
6
6
|
disabled?: boolean;
|
|
7
7
|
};
|
|
8
8
|
/** The search a collection toolbar fills its row with. */
|
|
9
|
+
/**
|
|
10
|
+
* The search a collection toolbar fills its row with.
|
|
11
|
+
*
|
|
12
|
+
* @family Inputs
|
|
13
|
+
* @when Finding a record inside one collection, at the start of its toolbar.
|
|
14
|
+
* @instead Finding anything across the product is `CommandDialog`. Narrowing by a facet is
|
|
15
|
+
* `CollectionFilters`. A free value in a form is `Input`.
|
|
16
|
+
* @behaviour Results stay on screen while a search updates. Escape clears only while the box holds
|
|
17
|
+
* the interaction and has a value; otherwise it closes the overlay as usual.
|
|
18
|
+
* @words The search's label is what it finds, also shown as its placeholder: *Find a skill*,
|
|
19
|
+
* *Search the hub*.
|
|
20
|
+
* @access The input carries `aria-label` from `label` and `type="search"`; the search mark is
|
|
21
|
+
* decorative.
|
|
22
|
+
*/
|
|
9
23
|
export declare function CollectionSearch({ label, value, onValueChange, disabled }: CollectionSearchProps): import("react").JSX.Element;
|
|
10
24
|
//# sourceMappingURL=collection-search.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collection-search.d.ts","sourceRoot":"","sources":["../../src/components/collection-search.tsx"],"names":[],"mappings":"AAMA,MAAM,MAAM,qBAAqB,GAAG;IAClC,2FAA2F;IAC3F,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACvC,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF,0DAA0D;AAC1D,wBAAgB,gBAAgB,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,aAAa,EAAE,QAAQ,EAAE,EAAE,qBAAqB,+BAgBhG"}
|
|
1
|
+
{"version":3,"file":"collection-search.d.ts","sourceRoot":"","sources":["../../src/components/collection-search.tsx"],"names":[],"mappings":"AAMA,MAAM,MAAM,qBAAqB,GAAG;IAClC,2FAA2F;IAC3F,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACvC,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF,0DAA0D;AAC1D;;;;;;;;;;;;;GAaG;AACH,wBAAgB,gBAAgB,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,aAAa,EAAE,QAAQ,EAAE,EAAE,qBAAqB,+BAgBhG"}
|
|
@@ -3,6 +3,20 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
3
3
|
import { Search } from "lucide-react";
|
|
4
4
|
import { InputGroup, InputGroupAddon, InputGroupInput } from "./input-group.js";
|
|
5
5
|
/** The search a collection toolbar fills its row with. */
|
|
6
|
+
/**
|
|
7
|
+
* The search a collection toolbar fills its row with.
|
|
8
|
+
*
|
|
9
|
+
* @family Inputs
|
|
10
|
+
* @when Finding a record inside one collection, at the start of its toolbar.
|
|
11
|
+
* @instead Finding anything across the product is `CommandDialog`. Narrowing by a facet is
|
|
12
|
+
* `CollectionFilters`. A free value in a form is `Input`.
|
|
13
|
+
* @behaviour Results stay on screen while a search updates. Escape clears only while the box holds
|
|
14
|
+
* the interaction and has a value; otherwise it closes the overlay as usual.
|
|
15
|
+
* @words The search's label is what it finds, also shown as its placeholder: *Find a skill*,
|
|
16
|
+
* *Search the hub*.
|
|
17
|
+
* @access The input carries `aria-label` from `label` and `type="search"`; the search mark is
|
|
18
|
+
* decorative.
|
|
19
|
+
*/
|
|
6
20
|
export function CollectionSearch({ label, value, onValueChange, disabled }) {
|
|
7
21
|
return (_jsxs(InputGroup, { children: [_jsx(InputGroupAddon, { children: _jsx(Search, { "aria-hidden": "true" }) }), _jsx(InputGroupInput, { "aria-label": label, disabled: disabled, onChange: (event) => onValueChange(event.target.value), placeholder: label, type: "search", value: value })] }));
|
|
8
22
|
}
|
|
@@ -10,9 +10,19 @@ export type CollectionSortProps = {
|
|
|
10
10
|
onValueChange: (value: string) => void;
|
|
11
11
|
};
|
|
12
12
|
/**
|
|
13
|
-
* The order a collection's rows are read in, at the toolbar's trailing edge
|
|
14
|
-
*
|
|
15
|
-
*
|
|
13
|
+
* The order a collection's rows are read in, at the toolbar's trailing edge.
|
|
14
|
+
*
|
|
15
|
+
* @family Choices
|
|
16
|
+
* @when A collection whose rows can be read in more than one order: newest, name, cost.
|
|
17
|
+
* @instead Sorting by a column of a comparison table is `DataTable`'s own header. Narrowing rows is
|
|
18
|
+
* `CollectionFilters`.
|
|
19
|
+
* @behaviour An outline button names the order in force; its menu offers the others as radio rows
|
|
20
|
+
* with the current one checked. Choosing the current order changes nothing. It renders nothing
|
|
21
|
+
* without options.
|
|
22
|
+
* @words The label says what the control does (*Sort by*); each option names an order: *Newest
|
|
23
|
+
* first*, *Name*.
|
|
24
|
+
* @access The trigger reads the label and the current order: *Sort by: Newest first*. The options
|
|
25
|
+
* are menu radio items.
|
|
16
26
|
*/
|
|
17
27
|
export declare function CollectionSort({ label, value, options, onValueChange }: CollectionSortProps): import("react").JSX.Element | null;
|
|
18
28
|
//# sourceMappingURL=collection-sort.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collection-sort.d.ts","sourceRoot":"","sources":["../../src/components/collection-sort.tsx"],"names":[],"mappings":"AAeA,MAAM,MAAM,oBAAoB,GAAG;IACjC,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,MAAM,MAAM,mBAAmB,GAAG;IAChC,yEAAyE;IACzE,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,SAAS,oBAAoB,EAAE,CAAC;IACzC,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACxC,CAAC;AAEF
|
|
1
|
+
{"version":3,"file":"collection-sort.d.ts","sourceRoot":"","sources":["../../src/components/collection-sort.tsx"],"names":[],"mappings":"AAeA,MAAM,MAAM,oBAAoB,GAAG;IACjC,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,MAAM,MAAM,mBAAmB,GAAG;IAChC,yEAAyE;IACzE,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,SAAS,oBAAoB,EAAE,CAAC;IACzC,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACxC,CAAC;AAEF;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,cAAc,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,aAAa,EAAE,EAAE,mBAAmB,sCAkC3F"}
|
|
@@ -4,9 +4,19 @@ import { ArrowUpDown } from "lucide-react";
|
|
|
4
4
|
import { Button } from "./button.js";
|
|
5
5
|
import { DropdownMenu, DropdownMenuContent, DropdownMenuGroup, DropdownMenuLabel, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuTrigger, } from "./dropdown-menu.js";
|
|
6
6
|
/**
|
|
7
|
-
* The order a collection's rows are read in, at the toolbar's trailing edge
|
|
8
|
-
*
|
|
9
|
-
*
|
|
7
|
+
* The order a collection's rows are read in, at the toolbar's trailing edge.
|
|
8
|
+
*
|
|
9
|
+
* @family Choices
|
|
10
|
+
* @when A collection whose rows can be read in more than one order: newest, name, cost.
|
|
11
|
+
* @instead Sorting by a column of a comparison table is `DataTable`'s own header. Narrowing rows is
|
|
12
|
+
* `CollectionFilters`.
|
|
13
|
+
* @behaviour An outline button names the order in force; its menu offers the others as radio rows
|
|
14
|
+
* with the current one checked. Choosing the current order changes nothing. It renders nothing
|
|
15
|
+
* without options.
|
|
16
|
+
* @words The label says what the control does (*Sort by*); each option names an order: *Newest
|
|
17
|
+
* first*, *Name*.
|
|
18
|
+
* @access The trigger reads the label and the current order: *Sort by: Newest first*. The options
|
|
19
|
+
* are menu radio items.
|
|
10
20
|
*/
|
|
11
21
|
export function CollectionSort({ label, value, options, onValueChange }) {
|
|
12
22
|
const current = options.find((option) => option.value === value) ?? options[0];
|
|
@@ -12,5 +12,18 @@ export type CollectionToolbarProps = Omit<ComponentPropsWithoutRef<"div">, "chil
|
|
|
12
12
|
*/
|
|
13
13
|
surface?: "glass" | "plain";
|
|
14
14
|
};
|
|
15
|
+
/**
|
|
16
|
+
* A collection's control bar: its filters, its search and its sort, over its own rows.
|
|
17
|
+
*
|
|
18
|
+
* @family Compositions
|
|
19
|
+
* @when The row above a collection's rows that holds its search, filters, sort and status.
|
|
20
|
+
* @instead A page action never sits here: it is `PageActions` on the title's row. Finding across
|
|
21
|
+
* the product is `CommandDialog`.
|
|
22
|
+
* @behaviour Glass on the floating height, held at the top of the scrolling content while the rows
|
|
23
|
+
* pass under it; inside a titled `TableCard`, or with `surface="plain"`, the plain row. A search
|
|
24
|
+
* alone is always the plain row.
|
|
25
|
+
* @words The label names the collection's tools: *Customer filters*.
|
|
26
|
+
* @access `role="toolbar"` named by `label`.
|
|
27
|
+
*/
|
|
15
28
|
export declare function CollectionToolbar({ label, controls, search, actions, status, surface, ...props }: CollectionToolbarProps): import("react").JSX.Element;
|
|
16
29
|
//# sourceMappingURL=collection-toolbar.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collection-toolbar.d.ts","sourceRoot":"","sources":["../../src/components/collection-toolbar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,wBAAwB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEjE,MAAM,MAAM,sBAAsB,GAAG,IAAI,CACvC,wBAAwB,CAAC,KAAK,CAAC,EAC/B,UAAU,GAAG,WAAW,CACzB,GAAG;IACF,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC;CAC7B,CAAC;AAeF,wBAAgB,iBAAiB,CAAC,EAChC,KAAK,EACL,QAAQ,EACR,MAAM,EACN,OAAO,EACP,MAAM,EACN,OAAiB,EACjB,GAAG,KAAK,EACT,EAAE,sBAAsB,+BAwCxB"}
|
|
1
|
+
{"version":3,"file":"collection-toolbar.d.ts","sourceRoot":"","sources":["../../src/components/collection-toolbar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,wBAAwB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEjE,MAAM,MAAM,sBAAsB,GAAG,IAAI,CACvC,wBAAwB,CAAC,KAAK,CAAC,EAC/B,UAAU,GAAG,WAAW,CACzB,GAAG;IACF,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC;CAC7B,CAAC;AAeF;;;;;;;;;;;;GAYG;AACH,wBAAgB,iBAAiB,CAAC,EAChC,KAAK,EACL,QAAQ,EACR,MAAM,EACN,OAAO,EACP,MAAM,EACN,OAAiB,EACjB,GAAG,KAAK,EACT,EAAE,sBAAsB,+BAwCxB"}
|
|
@@ -10,6 +10,19 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
10
10
|
const ON_PAGE = "sticky top-3 z-20 mb-3 rounded-lg p-2 nc-glass nc-elevation-floating";
|
|
11
11
|
const PLAIN = "relative mb-3";
|
|
12
12
|
const IN_CARD = "[[data-slot=table-card-toolbar]_&]:relative [[data-slot=table-card-toolbar]_&]:z-auto [[data-slot=table-card-toolbar]_&]:mb-0 [[data-slot=table-card-toolbar]_&]:rounded-none [[data-slot=table-card-toolbar]_&]:p-0 [[data-slot=table-card-toolbar]_&]:pb-4 [[data-slot=table-card-toolbar]_&]:[background:none] [[data-slot=table-card-toolbar]_&]:[backdrop-filter:none] [[data-slot=table-card-toolbar]_&]:[box-shadow:none]";
|
|
13
|
+
/**
|
|
14
|
+
* A collection's control bar: its filters, its search and its sort, over its own rows.
|
|
15
|
+
*
|
|
16
|
+
* @family Compositions
|
|
17
|
+
* @when The row above a collection's rows that holds its search, filters, sort and status.
|
|
18
|
+
* @instead A page action never sits here: it is `PageActions` on the title's row. Finding across
|
|
19
|
+
* the product is `CommandDialog`.
|
|
20
|
+
* @behaviour Glass on the floating height, held at the top of the scrolling content while the rows
|
|
21
|
+
* pass under it; inside a titled `TableCard`, or with `surface="plain"`, the plain row. A search
|
|
22
|
+
* alone is always the plain row.
|
|
23
|
+
* @words The label names the collection's tools: *Customer filters*.
|
|
24
|
+
* @access `role="toolbar"` named by `label`.
|
|
25
|
+
*/
|
|
13
26
|
export function CollectionToolbar({ label, controls, search, actions, status, surface = "glass", ...props }) {
|
|
14
27
|
// A search alone is the plain row: a search box never stands in a box of its
|
|
15
28
|
// own (DESIGN.md "Menus and commands").
|
|
@@ -1,5 +1,22 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { Combobox as ComboboxPrimitive } from "@base-ui/react/combobox";
|
|
3
|
+
/**
|
|
4
|
+
* Type to find one value, or several, in a known set.
|
|
5
|
+
*
|
|
6
|
+
* @family Choices
|
|
7
|
+
* @when Typing to find in a known set: assign an Agent, choose a time zone, add several Agents at
|
|
8
|
+
* once with `multiple`.
|
|
9
|
+
* @instead A short fixed list is a `Select`. Free text is an `Input`. Narrowing a collection is
|
|
10
|
+
* `CollectionFilters`.
|
|
11
|
+
* @behaviour Typing filters the list. Loading and no match are different states; the chosen value
|
|
12
|
+
* stays while results load. Enter picks the highlighted row and never submits the form around it.
|
|
13
|
+
* Clear empties the box and keeps focus there. With `multiple`, each choice is a chip with its own
|
|
14
|
+
* remove; Backspace in an empty box removes the last.
|
|
15
|
+
* @words The hint is scoped: *Find an Agent*. No match quotes the query: *No Agent matches “Xy”.* A
|
|
16
|
+
* chip reads as the record's name.
|
|
17
|
+
* @access A visible label; combobox and listbox roles; each chip's remove is named: *Remove Acme
|
|
18
|
+
* Quotes*. An Agent's orb in a row is a decorative mark beside her name.
|
|
19
|
+
*/
|
|
3
20
|
declare const Combobox: typeof ComboboxPrimitive.Root;
|
|
4
21
|
declare function ComboboxValue({ ...props }: ComboboxPrimitive.Value.Props): React.JSX.Element;
|
|
5
22
|
declare function ComboboxTrigger({ className, children, ...props }: ComboboxPrimitive.Trigger.Props): React.JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"combobox.d.ts","sourceRoot":"","sources":["../../src/components/combobox.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,QAAQ,IAAI,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAaxE,QAAA,MAAM,QAAQ,+BAAyB,CAAC;AAExC,iBAAS,aAAa,CAAC,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,qBAEjE;AAED,iBAAS,eAAe,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,OAAO,CAAC,KAAK,qBAW1F;AAeD,iBAAS,aAAa,CAAC,EACrB,SAAS,EACT,QAAQ,EACR,QAAgB,EAChB,WAAkB,EAClB,SAAiB,EACjB,GAAG,KAAK,EACT,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,GAAG;IACjC,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,qBAoBA;AAED,iBAAS,eAAe,CAAC,EACvB,SAAS,EACT,IAAe,EACf,UAAc,EACd,KAAe,EACf,WAAe,EACf,MAAM,EACN,GAAG,KAAK,EACT,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,GAC9B,IAAI,CACF,iBAAiB,CAAC,UAAU,CAAC,KAAK,EAClC,MAAM,GAAG,OAAO,GAAG,YAAY,GAAG,aAAa,GAAG,QAAQ,CAC3D,qBAwBF;AAED,iBAAS,YAAY,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,IAAI,CAAC,KAAK,qBAW1E;AAED,iBAAS,YAAY,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,IAAI,CAAC,KAAK,qBAoBpF;AAED,iBAAS,aAAa,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,qBAI5E;AAED,iBAAS,aAAa,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,UAAU,CAAC,KAAK,qBAQjF;AAED,iBAAS,kBAAkB,CAAC,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,UAAU,CAAC,KAAK,qBAE3E;AAED,iBAAS,aAAa,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,qBAW5E;AAED,iBAAS,iBAAiB,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,SAAS,CAAC,KAAK,qBAQpF;AAED,iBAAS,aAAa,CAAC,EACrB,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,qBAAqB,CAAC,OAAO,iBAAiB,CAAC,KAAK,CAAC,GAAG,iBAAiB,CAAC,KAAK,CAAC,KAAK,qBAW7F;AAED,iBAAS,YAAY,CAAC,EACpB,SAAS,EACT,QAAQ,EACR,UAAiB,EACjB,GAAG,KAAK,EACT,EAAE,iBAAiB,CAAC,IAAI,CAAC,KAAK,GAAG;IAChC,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB,qBAsBA;AAED,iBAAS,kBAAkB,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,qBAQjF;AAED,iBAAS,iBAAiB,2CAEzB;AAED,OAAO,EACL,QAAQ,EACR,aAAa,EACb,eAAe,EACf,YAAY,EACZ,YAAY,EACZ,aAAa,EACb,aAAa,EACb,kBAAkB,EAClB,aAAa,EACb,iBAAiB,EACjB,aAAa,EACb,YAAY,EACZ,kBAAkB,EAClB,eAAe,EACf,aAAa,EACb,iBAAiB,GAClB,CAAC"}
|
|
1
|
+
{"version":3,"file":"combobox.d.ts","sourceRoot":"","sources":["../../src/components/combobox.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,QAAQ,IAAI,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAaxE;;;;;;;;;;;;;;;;GAgBG;AACH,QAAA,MAAM,QAAQ,+BAAyB,CAAC;AAExC,iBAAS,aAAa,CAAC,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,qBAEjE;AAED,iBAAS,eAAe,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,OAAO,CAAC,KAAK,qBAW1F;AAeD,iBAAS,aAAa,CAAC,EACrB,SAAS,EACT,QAAQ,EACR,QAAgB,EAChB,WAAkB,EAClB,SAAiB,EACjB,GAAG,KAAK,EACT,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,GAAG;IACjC,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,qBAoBA;AAED,iBAAS,eAAe,CAAC,EACvB,SAAS,EACT,IAAe,EACf,UAAc,EACd,KAAe,EACf,WAAe,EACf,MAAM,EACN,GAAG,KAAK,EACT,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,GAC9B,IAAI,CACF,iBAAiB,CAAC,UAAU,CAAC,KAAK,EAClC,MAAM,GAAG,OAAO,GAAG,YAAY,GAAG,aAAa,GAAG,QAAQ,CAC3D,qBAwBF;AAED,iBAAS,YAAY,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,IAAI,CAAC,KAAK,qBAW1E;AAED,iBAAS,YAAY,CAAC,EAAE,SAAS,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,IAAI,CAAC,KAAK,qBAoBpF;AAED,iBAAS,aAAa,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,qBAI5E;AAED,iBAAS,aAAa,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,UAAU,CAAC,KAAK,qBAQjF;AAED,iBAAS,kBAAkB,CAAC,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,UAAU,CAAC,KAAK,qBAE3E;AAED,iBAAS,aAAa,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,qBAW5E;AAED,iBAAS,iBAAiB,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,SAAS,CAAC,KAAK,qBAQpF;AAED,iBAAS,aAAa,CAAC,EACrB,SAAS,EACT,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,qBAAqB,CAAC,OAAO,iBAAiB,CAAC,KAAK,CAAC,GAAG,iBAAiB,CAAC,KAAK,CAAC,KAAK,qBAW7F;AAED,iBAAS,YAAY,CAAC,EACpB,SAAS,EACT,QAAQ,EACR,UAAiB,EACjB,GAAG,KAAK,EACT,EAAE,iBAAiB,CAAC,IAAI,CAAC,KAAK,GAAG;IAChC,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB,qBAsBA;AAED,iBAAS,kBAAkB,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,iBAAiB,CAAC,KAAK,CAAC,KAAK,qBAQjF;AAED,iBAAS,iBAAiB,2CAEzB;AAED,OAAO,EACL,QAAQ,EACR,aAAa,EACb,eAAe,EACf,YAAY,EACZ,YAAY,EACZ,aAAa,EACb,aAAa,EACb,kBAAkB,EAClB,aAAa,EACb,iBAAiB,EACjB,aAAa,EACb,YAAY,EACZ,kBAAkB,EAClB,eAAe,EACf,aAAa,EACb,iBAAiB,GAClB,CAAC"}
|
|
@@ -6,6 +6,23 @@ import { cn } from "../lib/utils.js";
|
|
|
6
6
|
import { Button } from "./button.js";
|
|
7
7
|
import { InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, } from "./input-group.js";
|
|
8
8
|
import { ChevronDownIcon, XIcon, CheckIcon } from "lucide-react";
|
|
9
|
+
/**
|
|
10
|
+
* Type to find one value, or several, in a known set.
|
|
11
|
+
*
|
|
12
|
+
* @family Choices
|
|
13
|
+
* @when Typing to find in a known set: assign an Agent, choose a time zone, add several Agents at
|
|
14
|
+
* once with `multiple`.
|
|
15
|
+
* @instead A short fixed list is a `Select`. Free text is an `Input`. Narrowing a collection is
|
|
16
|
+
* `CollectionFilters`.
|
|
17
|
+
* @behaviour Typing filters the list. Loading and no match are different states; the chosen value
|
|
18
|
+
* stays while results load. Enter picks the highlighted row and never submits the form around it.
|
|
19
|
+
* Clear empties the box and keeps focus there. With `multiple`, each choice is a chip with its own
|
|
20
|
+
* remove; Backspace in an empty box removes the last.
|
|
21
|
+
* @words The hint is scoped: *Find an Agent*. No match quotes the query: *No Agent matches “Xy”.* A
|
|
22
|
+
* chip reads as the record's name.
|
|
23
|
+
* @access A visible label; combobox and listbox roles; each chip's remove is named: *Remove Acme
|
|
24
|
+
* Quotes*. An Agent's orb in a row is a decorative mark beside her name.
|
|
25
|
+
*/
|
|
9
26
|
const Combobox = ComboboxPrimitive.Root;
|
|
10
27
|
function ComboboxValue({ ...props }) {
|
|
11
28
|
return _jsx(ComboboxPrimitive.Value, { "data-slot": "combobox-value", ...props });
|
|
@@ -2,6 +2,22 @@ import * as React from "react";
|
|
|
2
2
|
import { Command as CommandPrimitive } from "cmdk";
|
|
3
3
|
import { Dialog } from "./dialog.js";
|
|
4
4
|
declare function Command({ className, ...props }: React.ComponentProps<typeof CommandPrimitive>): React.JSX.Element;
|
|
5
|
+
/**
|
|
6
|
+
* Find anything across the product and go there.
|
|
7
|
+
*
|
|
8
|
+
* @family Navigation
|
|
9
|
+
* @when Finding anything across the product and going there: an Agent, a customer, a page, a
|
|
10
|
+
* creation command. Opened by ⌘K or the sidebar's Find.
|
|
11
|
+
* @instead One record's commands are its `ActionMenu`. Search inside one collection is
|
|
12
|
+
* `CollectionSearch`. Choosing the page's scope is `ScopeSwitcher`.
|
|
13
|
+
* @behaviour Opens instantly, a third of the way down, on glass at 12 px corners. Arrows move the
|
|
14
|
+
* highlight, Enter goes, Esc closes and returns focus to the trigger. An empty query shows useful
|
|
15
|
+
* defaults; no match says so.
|
|
16
|
+
* @words Groups are plural nouns (*Agents*, *Go to*). Items are names, or verb and noun for a
|
|
17
|
+
* command (*New Agent*). No match quotes the query.
|
|
18
|
+
* @access A dialog with a screen-reader title and description; the field is a combobox over a
|
|
19
|
+
* listbox; the highlighted item is `aria-selected`.
|
|
20
|
+
*/
|
|
5
21
|
declare function CommandDialog({ title, description, children, className, showCloseButton, ...props }: Omit<React.ComponentProps<typeof Dialog>, "children"> & {
|
|
6
22
|
title?: string;
|
|
7
23
|
description?: string;
|