@ciridae/ui 0.17.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +17 -12
- package/dist/chat/chat-api-error.d.ts +14 -0
- package/dist/chat/chat-api-error.js +11 -0
- package/dist/chat/chat-client.d.ts +37 -0
- package/dist/chat/chat-client.js +66 -0
- package/dist/chat/chat-hooks.d.ts +4 -0
- package/dist/chat/chat-hooks.js +4 -0
- package/dist/chat/chat-query-keys.d.ts +10 -0
- package/dist/chat/chat-query-keys.js +8 -0
- package/dist/chat/contract.d.ts +488 -0
- package/dist/chat/contract.js +223 -0
- package/dist/chat/conversation-items-query-options.d.ts +382 -0
- package/dist/chat/conversation-items-query-options.js +15 -0
- package/dist/chat/describe-tool-call.d.ts +5 -0
- package/dist/chat/describe-tool-call.js +33 -0
- package/dist/chat/fetch-new-conversation-items.d.ts +10 -0
- package/dist/chat/fetch-new-conversation-items.js +38 -0
- package/dist/chat/message-group-position.d.ts +17 -0
- package/dist/chat/message-group-position.js +25 -0
- package/dist/chat/message-text.d.ts +23 -0
- package/dist/chat/message-text.js +118 -0
- package/dist/chat/mock-chat-client.d.ts +97 -0
- package/dist/chat/mock-chat-client.js +566 -0
- package/dist/chat/use-chat-conversation.d.ts +43 -0
- package/dist/chat/use-chat-conversation.js +156 -0
- package/dist/chat/use-conversation-list.d.ts +32 -0
- package/dist/chat/use-conversation-list.js +19 -0
- package/dist/ciridae.css +60 -479
- package/dist/components/activity-feed.d.ts +80 -0
- package/dist/components/activity-feed.js +373 -0
- package/dist/components/agent-work.d.ts +76 -0
- package/dist/components/agent-work.js +224 -0
- package/dist/components/app-navigation.d.ts +66 -0
- package/dist/components/app-navigation.js +102 -0
- package/dist/components/badge.d.ts +14 -0
- package/dist/components/badge.js +107 -0
- package/dist/components/brand-icons.d.ts +17 -0
- package/dist/components/brand-icons.js +21 -0
- package/dist/components/breakpoint.d.ts +7 -0
- package/dist/components/breakpoint.js +16 -0
- package/dist/components/bulk-action-bar.d.ts +15 -0
- package/dist/components/bulk-action-bar.js +45 -0
- package/dist/components/button.d.ts +52 -0
- package/dist/components/button.js +272 -0
- package/dist/components/calendar.d.ts +14 -0
- package/dist/components/calendar.js +158 -0
- package/dist/components/centered-page.d.ts +21 -0
- package/dist/components/centered-page.js +55 -0
- package/dist/components/chart.d.ts +22 -0
- package/dist/components/chart.js +116 -0
- package/dist/components/chat-page.d.ts +34 -0
- package/dist/components/chat-page.js +171 -0
- package/dist/components/chat-sheet-controller.d.ts +50 -0
- package/dist/components/chat-sheet-controller.js +133 -0
- package/dist/components/chat-sheet.d.ts +80 -0
- package/dist/components/chat-sheet.js +544 -0
- package/dist/components/chat.d.ts +135 -0
- package/dist/components/chat.js +545 -0
- package/dist/components/checkbox-item.d.ts +11 -0
- package/dist/components/checkbox-item.js +45 -0
- package/dist/components/checkbox-list.d.ts +51 -0
- package/dist/components/checkbox-list.js +167 -0
- package/dist/components/chip.d.ts +17 -0
- package/dist/components/chip.js +43 -0
- package/dist/components/collapsible.d.ts +8 -0
- package/dist/components/collapsible.js +41 -0
- package/dist/components/color-theme.d.ts +40 -0
- package/dist/components/color-theme.js +109 -0
- package/dist/components/column-settings.d.ts +22 -0
- package/dist/components/column-settings.js +112 -0
- package/dist/components/command-match.d.ts +7 -0
- package/dist/components/command-match.js +50 -0
- package/dist/components/command-menu.d.ts +43 -0
- package/dist/components/command-menu.js +339 -0
- package/dist/components/command-palette.d.ts +36 -0
- package/dist/components/command-palette.js +77 -0
- package/dist/components/controllable-state.d.ts +5 -0
- package/dist/components/controllable-state.js +15 -0
- package/dist/components/copyable-id.d.ts +37 -0
- package/dist/components/copyable-id.js +136 -0
- package/dist/components/data-display.d.ts +47 -0
- package/dist/components/data-display.js +221 -0
- package/dist/components/data-grid.d.ts +170 -0
- package/dist/components/data-grid.js +829 -0
- package/dist/components/date-range-picker.d.ts +44 -0
- package/dist/components/date-range-picker.js +153 -0
- package/dist/components/date-time.d.ts +11 -0
- package/dist/components/date-time.js +44 -0
- package/dist/components/dialog-height-context.d.ts +2 -0
- package/dist/components/dialog-height-context.js +3 -0
- package/dist/components/document-viewer.d.ts +62 -0
- package/dist/components/document-viewer.js +419 -0
- package/dist/components/drawer.d.ts +44 -0
- package/dist/components/drawer.js +236 -0
- package/dist/components/dropzone.d.ts +47 -0
- package/dist/components/dropzone.js +370 -0
- package/dist/components/editable-field.d.ts +99 -0
- package/dist/components/editable-field.js +422 -0
- package/dist/components/email-input.d.ts +12 -0
- package/dist/components/email-input.js +83 -0
- package/dist/components/environment-frame.d.ts +13 -0
- package/dist/components/environment-frame.js +42 -0
- package/dist/components/expandable-text.d.ts +9 -0
- package/dist/components/expandable-text.js +48 -0
- package/dist/components/feedback-screenshot.d.ts +19 -0
- package/dist/components/feedback-screenshot.js +162 -0
- package/dist/components/feedback-sheet.d.ts +80 -0
- package/dist/components/feedback-sheet.js +475 -0
- package/dist/components/field-context.d.ts +23 -0
- package/dist/components/field-context.js +15 -0
- package/dist/components/filter-bar.d.ts +77 -0
- package/dist/components/filter-bar.js +350 -0
- package/dist/components/form-controls.d.ts +53 -0
- package/dist/components/form-controls.js +123 -0
- package/dist/components/form-layout.d.ts +32 -0
- package/dist/components/form-layout.js +72 -0
- package/dist/components/hotkeys.d.ts +27 -0
- package/dist/components/hotkeys.js +70 -0
- package/dist/components/icon.d.ts +58 -0
- package/dist/components/icon.js +42 -0
- package/dist/components/input.d.ts +36 -0
- package/dist/components/input.js +249 -0
- package/dist/components/keyboard-shortcuts.d.ts +10 -0
- package/dist/components/keyboard-shortcuts.js +91 -0
- package/dist/components/keycap.d.ts +12 -0
- package/dist/components/keycap.js +45 -0
- package/dist/components/layout.d.ts +174 -0
- package/dist/components/layout.js +282 -0
- package/dist/components/lightbox.d.ts +14 -0
- package/dist/components/lightbox.js +117 -0
- package/dist/components/link.d.ts +13 -0
- package/dist/components/link.js +37 -0
- package/dist/components/locale.d.ts +463 -0
- package/dist/components/locale.js +501 -0
- package/dist/components/log-list.d.ts +20 -0
- package/dist/components/log-list.js +92 -0
- package/dist/components/mention-input.d.ts +50 -0
- package/dist/components/mention-input.js +503 -0
- package/dist/components/menu.d.ts +76 -0
- package/dist/components/menu.js +112 -0
- package/dist/components/meter.d.ts +14 -0
- package/dist/components/meter.js +44 -0
- package/dist/components/navigation.d.ts +21 -0
- package/dist/components/navigation.js +75 -0
- package/dist/components/notification-tray.d.ts +47 -0
- package/dist/components/notification-tray.js +218 -0
- package/dist/components/overlays.d.ts +107 -0
- package/dist/components/overlays.js +240 -0
- package/dist/components/page-frame.d.ts +65 -0
- package/dist/components/page-frame.js +94 -0
- package/dist/components/panel.d.ts +24 -0
- package/dist/components/panel.js +107 -0
- package/dist/components/profile-header.d.ts +15 -0
- package/dist/components/profile-header.js +40 -0
- package/dist/components/progress.d.ts +5 -0
- package/dist/components/progress.js +18 -0
- package/dist/components/project-avatar.d.ts +12 -0
- package/dist/components/project-avatar.js +22 -0
- package/dist/components/radio-card.d.ts +22 -0
- package/dist/components/radio-card.js +66 -0
- package/dist/components/recent-items.d.ts +28 -0
- package/dist/components/recent-items.js +63 -0
- package/dist/components/record.d.ts +95 -0
- package/dist/components/record.js +282 -0
- package/dist/components/scroll-area.d.ts +16 -0
- package/dist/components/scroll-area.js +50 -0
- package/dist/components/secret-dialog.d.ts +10 -0
- package/dist/components/secret-dialog.js +12 -0
- package/dist/components/segmented-bar.d.ts +23 -0
- package/dist/components/segmented-bar.js +75 -0
- package/dist/components/select.d.ts +84 -0
- package/dist/components/select.js +374 -0
- package/dist/components/settings.d.ts +34 -0
- package/dist/components/settings.js +56 -0
- package/dist/components/shell-skeleton.d.ts +7 -0
- package/dist/components/shell-skeleton.js +15 -0
- package/dist/components/shell.d.ts +62 -0
- package/dist/components/shell.js +415 -0
- package/dist/components/side-panel.d.ts +36 -0
- package/dist/components/side-panel.js +184 -0
- package/dist/components/sidebar.d.ts +35 -0
- package/dist/components/sidebar.js +207 -0
- package/dist/components/site-banner.d.ts +25 -0
- package/dist/components/site-banner.js +30 -0
- package/dist/components/skeleton.d.ts +15 -0
- package/dist/components/skeleton.js +61 -0
- package/dist/components/skeletons.d.ts +28 -0
- package/dist/components/skeletons.js +60 -0
- package/dist/components/stages.d.ts +97 -0
- package/dist/components/stages.js +365 -0
- package/dist/components/stat-card.d.ts +34 -0
- package/dist/components/stat-card.js +117 -0
- package/dist/components/status-banner.d.ts +17 -0
- package/dist/components/status-banner.js +132 -0
- package/dist/components/status.d.ts +32 -0
- package/dist/components/status.js +93 -0
- package/dist/components/steps.d.ts +17 -0
- package/dist/components/steps.js +51 -0
- package/dist/components/switch.d.ts +6 -0
- package/dist/components/switch.js +39 -0
- package/dist/components/tabs.d.ts +48 -0
- package/dist/components/tabs.js +247 -0
- package/dist/components/theme-customizer.d.ts +53 -0
- package/dist/components/theme-customizer.js +116 -0
- package/dist/components/toast.d.ts +23 -0
- package/dist/components/toast.js +140 -0
- package/dist/components/user-chip.d.ts +66 -0
- package/dist/components/user-chip.js +174 -0
- package/dist/components/wizard.d.ts +33 -0
- package/dist/components/wizard.js +91 -0
- package/dist/feedback/client.d.ts +37 -0
- package/dist/feedback/client.js +125 -0
- package/dist/feedback/comment-types.d.ts +17 -0
- package/dist/feedback/contract.d.ts +252 -0
- package/dist/feedback/contract.js +32 -0
- package/dist/feedback/feedback-cache.d.ts +6 -0
- package/dist/feedback/feedback-cache.js +58 -0
- package/dist/feedback/feedback-center-model.d.ts +8 -0
- package/dist/feedback/feedback-center-model.js +37 -0
- package/dist/feedback/feedback-composer-types.d.ts +11 -0
- package/dist/feedback/feedback-controller.d.ts +56 -0
- package/dist/feedback/feedback-controller.js +181 -0
- package/dist/feedback/feedback-tracking-types.d.ts +14 -0
- package/dist/feedback/generated/index.d.ts +1 -0
- package/dist/feedback/generated/index.js +2 -0
- package/dist/feedback/generated/types.gen.d.ts +737 -0
- package/dist/feedback/generated/types.gen.js +2 -0
- package/dist/feedback/generated/zod.gen.d.ts +738 -0
- package/dist/feedback/generated/zod.gen.js +293 -0
- package/dist/feedback/get-response-error-id.d.ts +1 -0
- package/dist/feedback/get-response-error-id.js +7 -0
- package/dist/feedback/operator-client.d.ts +21 -0
- package/dist/feedback/operator-client.js +96 -0
- package/dist/feedback/operator-contract.d.ts +111 -0
- package/dist/feedback/operator-contract.js +22 -0
- package/dist/feedback/operator-controller.d.ts +80 -0
- package/dist/feedback/operator-controller.js +43 -0
- package/dist/feedback/require-config.d.ts +2 -0
- package/dist/feedback/require-config.js +7 -0
- package/dist/feedback/submit-feedback-with-attachments.d.ts +10 -0
- package/dist/feedback/submit-feedback-with-attachments.js +10 -0
- package/dist/format/compact-number.d.ts +2 -0
- package/dist/format/compact-number.js +8 -0
- package/dist/format/money.d.ts +13 -0
- package/dist/format/money.js +21 -0
- package/dist/format/usd.d.ts +2 -0
- package/dist/format/usd.js +16 -0
- package/dist/preset.d.ts +18 -0
- package/dist/preset.js +470 -0
- package/dist/styled-system/css/conditions.mjs +1 -1
- package/dist/styled-system/css/css.mjs +3 -3
- package/dist/styled-system/patterns/box.d.ts +1 -1
- package/dist/styled-system/patterns/container.d.ts +1 -1
- package/dist/styled-system/patterns/link-overlay.d.ts +1 -1
- package/dist/styled-system/patterns/visually-hidden.d.ts +1 -1
- package/dist/styled-system/styles.css +7834 -458
- package/dist/styled-system/tokens/index.mjs +1465 -677
- package/dist/styled-system/tokens/tokens.d.ts +32 -26
- package/dist/styled-system/types/conditions.d.ts +11 -1
- package/dist/styled-system/types/prop-type.d.ts +12 -23
- package/dist/styled-system/types/style-props.d.ts +25 -24
- package/dist/styles.css +60 -479
- package/dist/theme/breakpoints.d.ts +15 -0
- package/dist/theme/breakpoints.js +12 -0
- package/dist/theme/color.d.ts +2 -0
- package/dist/theme/color.js +27 -0
- package/dist/theme/derive.d.ts +5 -0
- package/dist/theme/derive.js +43 -0
- package/dist/theme/index.d.ts +4 -0
- package/dist/theme/index.js +9 -0
- package/dist/theme/options.d.ts +32 -0
- package/dist/theme/options.js +9 -0
- package/dist/theme/palettes.d.ts +60 -0
- package/dist/theme/palettes.js +185 -0
- package/dist/theme/tokens.d.ts +29 -0
- package/dist/theme/tokens.js +188 -0
- package/package.json +475 -68
- package/dist/assets/ciridae/brand-background-dark.webp +0 -0
- package/dist/assets/ciridae/brand-background-light.webp +0 -0
- package/dist/assets/ciridae/ciridae-black.svg +0 -17
- package/dist/assets/ciridae/ciridae-brand-assets.d.ts +0 -25
- package/dist/assets/ciridae/ciridae-brand-assets.js +0 -25
- package/dist/assets/ciridae/ciridae-icon-black.png +0 -0
- package/dist/assets/ciridae/ciridae-icon-white.png +0 -0
- package/dist/assets/ciridae/ciridae-ui-wordmark-black.png +0 -0
- package/dist/assets/ciridae/ciridae-ui-wordmark-white.png +0 -0
- package/dist/assets/ciridae/ciridae-white.svg +0 -17
- package/dist/assets/ciridae/ciridae-wordmark-black.png +0 -0
- package/dist/assets/ciridae/ciridae-wordmark-white.png +0 -0
- package/dist/assets/ciridae/favicon.ico +0 -0
- package/dist/assets/ciridae/logo-white.png +0 -0
- package/dist/assets/ciridae/sign-in-screenshot.png +0 -0
- package/dist/components/blocks/admin-users-table.d.ts +0 -22
- package/dist/components/blocks/admin-users-table.js +0 -115
- package/dist/components/blocks/comment-composer.d.ts +0 -18
- package/dist/components/blocks/comment-composer.js +0 -137
- package/dist/components/blocks/comment-item.d.ts +0 -8
- package/dist/components/blocks/comment-item.js +0 -45
- package/dist/components/blocks/comment-thread.d.ts +0 -19
- package/dist/components/blocks/comment-thread.js +0 -37
- package/dist/components/blocks/comment-types.d.ts +0 -18
- package/dist/components/blocks/comment-types.js +0 -11
- package/dist/components/blocks/copy-field.d.ts +0 -18
- package/dist/components/blocks/copy-field.js +0 -61
- package/dist/components/blocks/feedback-center-comments.d.ts +0 -16
- package/dist/components/blocks/feedback-center-comments.js +0 -61
- package/dist/components/blocks/feedback-center-footer.d.ts +0 -12
- package/dist/components/blocks/feedback-center-footer.js +0 -10
- package/dist/components/blocks/feedback-center-sheet-parts.d.ts +0 -40
- package/dist/components/blocks/feedback-center-sheet-parts.js +0 -39
- package/dist/components/blocks/feedback-center-sheet.d.ts +0 -28
- package/dist/components/blocks/feedback-center-sheet.js +0 -106
- package/dist/components/blocks/feedback-composer-parts.d.ts +0 -16
- package/dist/components/blocks/feedback-composer-parts.js +0 -43
- package/dist/components/blocks/feedback-composer-types.d.ts +0 -12
- package/dist/components/blocks/feedback-composer.d.ts +0 -24
- package/dist/components/blocks/feedback-composer.js +0 -82
- package/dist/components/blocks/feedback-date-format.d.ts +0 -5
- package/dist/components/blocks/feedback-date-format.js +0 -11
- package/dist/components/blocks/feedback-detail-sheet.d.ts +0 -15
- package/dist/components/blocks/feedback-detail-sheet.js +0 -59
- package/dist/components/blocks/feedback-emergency-fields.d.ts +0 -17
- package/dist/components/blocks/feedback-emergency-fields.js +0 -32
- package/dist/components/blocks/feedback-metrics.d.ts +0 -6
- package/dist/components/blocks/feedback-metrics.js +0 -15
- package/dist/components/blocks/feedback-sheet.d.ts +0 -8
- package/dist/components/blocks/feedback-sheet.js +0 -29
- package/dist/components/blocks/feedback-status-badge.d.ts +0 -6
- package/dist/components/blocks/feedback-status-badge.js +0 -15
- package/dist/components/blocks/feedback-table-row.d.ts +0 -6
- package/dist/components/blocks/feedback-table-row.js +0 -27
- package/dist/components/blocks/feedback-table-sort.d.ts +0 -11
- package/dist/components/blocks/feedback-table-sort.js +0 -82
- package/dist/components/blocks/feedback-table.d.ts +0 -16
- package/dist/components/blocks/feedback-table.js +0 -45
- package/dist/components/blocks/feedback-tracking-types.d.ts +0 -102
- package/dist/components/blocks/feedback-tracking-types.js +0 -54
- package/dist/components/blocks/feedback-triage-timeline.d.ts +0 -11
- package/dist/components/blocks/feedback-triage-timeline.js +0 -17
- package/dist/components/blocks/feedback-type-badge.d.ts +0 -11
- package/dist/components/blocks/feedback-type-badge.js +0 -18
- package/dist/components/blocks/feedback-unread-badge.d.ts +0 -6
- package/dist/components/blocks/feedback-unread-badge.js +0 -9
- package/dist/components/blocks/feedback-user-detail.d.ts +0 -11
- package/dist/components/blocks/feedback-user-detail.js +0 -63
- package/dist/components/blocks/feedback-user-list.d.ts +0 -11
- package/dist/components/blocks/feedback-user-list.js +0 -41
- package/dist/components/blocks/generated-connect-link.d.ts +0 -22
- package/dist/components/blocks/generated-connect-link.js +0 -68
- package/dist/components/blocks/invite-user-sheet.d.ts +0 -20
- package/dist/components/blocks/invite-user-sheet.js +0 -72
- package/dist/components/blocks/kanban-board-parts.d.ts +0 -26
- package/dist/components/blocks/kanban-board-parts.js +0 -83
- package/dist/components/blocks/kanban-board-utils.d.ts +0 -58
- package/dist/components/blocks/kanban-board-utils.js +0 -140
- package/dist/components/blocks/kanban-board.d.ts +0 -16
- package/dist/components/blocks/kanban-board.js +0 -35
- package/dist/components/blocks/kanban-card.d.ts +0 -10
- package/dist/components/blocks/kanban-card.js +0 -34
- package/dist/components/blocks/kanban-column.d.ts +0 -17
- package/dist/components/blocks/kanban-column.js +0 -34
- package/dist/components/blocks/kanban-detail-sheet.d.ts +0 -17
- package/dist/components/blocks/kanban-detail-sheet.js +0 -34
- package/dist/components/blocks/kanban-types.d.ts +0 -24
- package/dist/components/blocks/mcp-access-grouped-tool-picker.d.ts +0 -19
- package/dist/components/blocks/mcp-access-grouped-tool-picker.js +0 -116
- package/dist/components/blocks/mcp-access-tool-picker-internals.d.ts +0 -35
- package/dist/components/blocks/mcp-access-tool-picker-internals.js +0 -24
- package/dist/components/blocks/mcp-access-tool-picker.d.ts +0 -22
- package/dist/components/blocks/mcp-access-tool-picker.js +0 -33
- package/dist/components/blocks/mcp-access-types.d.ts +0 -42
- package/dist/components/blocks/mcp-access-types.js +0 -7
- package/dist/components/blocks/mcp-client-setup.d.ts +0 -29
- package/dist/components/blocks/mcp-client-setup.js +0 -58
- package/dist/components/blocks/mcp-connect-clients.d.ts +0 -43
- package/dist/components/blocks/mcp-connect-clients.js +0 -66
- package/dist/components/blocks/mcp-plan-choice.d.ts +0 -17
- package/dist/components/blocks/mcp-plan-choice.js +0 -28
- package/dist/components/blocks/submit-feedback-composer.d.ts +0 -5
- package/dist/components/blocks/submit-feedback-composer.js +0 -40
- package/dist/components/blocks/timestamp-format.d.ts +0 -14
- package/dist/components/blocks/timestamp-format.js +0 -72
- package/dist/components/blocks/use-feedback-composer-state.d.ts +0 -27
- package/dist/components/blocks/use-feedback-composer-state.js +0 -60
- package/dist/components/blocks/use-reveal-thread-end.d.ts +0 -11
- package/dist/components/blocks/use-reveal-thread-end.js +0 -25
- package/dist/components/pages/admin-users-page.d.ts +0 -11
- package/dist/components/pages/admin-users-page.js +0 -30
- package/dist/components/pages/feedback-stakeholder-page-parts.d.ts +0 -18
- package/dist/components/pages/feedback-stakeholder-page-parts.js +0 -36
- package/dist/components/pages/feedback-stakeholder-page.d.ts +0 -9
- package/dist/components/pages/feedback-stakeholder-page.js +0 -66
- package/dist/components/pages/kanban-page.d.ts +0 -13
- package/dist/components/pages/kanban-page.js +0 -68
- package/dist/components/ui/accordion.d.ts +0 -7
- package/dist/components/ui/accordion.js +0 -17
- package/dist/components/ui/alert-dialog.d.ts +0 -22
- package/dist/components/ui/alert-dialog.js +0 -51
- package/dist/components/ui/alert.d.ts +0 -9
- package/dist/components/ui/alert.js +0 -24
- package/dist/components/ui/app-shell-page.d.ts +0 -22
- package/dist/components/ui/app-shell-page.js +0 -21
- package/dist/components/ui/app-shell.d.ts +0 -45
- package/dist/components/ui/app-shell.js +0 -44
- package/dist/components/ui/aspect-ratio.d.ts +0 -3
- package/dist/components/ui/aspect-ratio.js +0 -7
- package/dist/components/ui/avatar.d.ts +0 -11
- package/dist/components/ui/avatar.js +0 -22
- package/dist/components/ui/badge-variants.d.ts +0 -100
- package/dist/components/ui/badge-variants.js +0 -140
- package/dist/components/ui/badge.d.ts +0 -6
- package/dist/components/ui/badge.js +0 -9
- package/dist/components/ui/breadcrumb.d.ts +0 -11
- package/dist/components/ui/breadcrumb.js +0 -27
- package/dist/components/ui/button-group-variants.d.ts +0 -6
- package/dist/components/ui/button-group-variants.js +0 -13
- package/dist/components/ui/button-group.d.ts +0 -8
- package/dist/components/ui/button-group.js +0 -16
- package/dist/components/ui/button-variants.d.ts +0 -133
- package/dist/components/ui/button-variants.js +0 -170
- package/dist/components/ui/button.d.ts +0 -8
- package/dist/components/ui/button.js +0 -59
- package/dist/components/ui/calendar.d.ts +0 -10
- package/dist/components/ui/calendar.js +0 -99
- package/dist/components/ui/card.d.ts +0 -14
- package/dist/components/ui/card.js +0 -28
- package/dist/components/ui/carousel.d.ts +0 -19
- package/dist/components/ui/carousel.js +0 -104
- package/dist/components/ui/chart-context.d.ts +0 -33
- package/dist/components/ui/chart-context.js +0 -36
- package/dist/components/ui/chart-panel.d.ts +0 -11
- package/dist/components/ui/chart-panel.js +0 -6
- package/dist/components/ui/chart-tooltip.d.ts +0 -13
- package/dist/components/ui/chart-tooltip.js +0 -84
- package/dist/components/ui/chart.d.ts +0 -23
- package/dist/components/ui/chart.js +0 -52
- package/dist/components/ui/checkbox.d.ts +0 -4
- package/dist/components/ui/checkbox.js +0 -9
- package/dist/components/ui/ciridae-ui-provider.d.ts +0 -8
- package/dist/components/ui/ciridae-ui-provider.js +0 -14
- package/dist/components/ui/collapsible.d.ts +0 -5
- package/dist/components/ui/collapsible.js +0 -12
- package/dist/components/ui/color-theme-context.d.ts +0 -28
- package/dist/components/ui/color-theme-context.js +0 -3
- package/dist/components/ui/color-theme.d.ts +0 -5
- package/dist/components/ui/color-theme.js +0 -147
- package/dist/components/ui/combobox-anchor.d.ts +0 -3
- package/dist/components/ui/combobox-anchor.js +0 -5
- package/dist/components/ui/combobox.d.ts +0 -24
- package/dist/components/ui/combobox.js +0 -54
- package/dist/components/ui/command.d.ts +0 -19
- package/dist/components/ui/command.js +0 -38
- package/dist/components/ui/context-menu.d.ts +0 -30
- package/dist/components/ui/context-menu.js +0 -63
- package/dist/components/ui/data-table-column-settings.d.ts +0 -23
- package/dist/components/ui/data-table-column-settings.js +0 -170
- package/dist/components/ui/data-table-context.d.ts +0 -8
- package/dist/components/ui/data-table-context.js +0 -53
- package/dist/components/ui/data-table-controls.d.ts +0 -9
- package/dist/components/ui/data-table-controls.js +0 -30
- package/dist/components/ui/data-table-facet-filter.d.ts +0 -39
- package/dist/components/ui/data-table-facet-filter.js +0 -65
- package/dist/components/ui/data-table-grid.d.ts +0 -10
- package/dist/components/ui/data-table-grid.js +0 -34
- package/dist/components/ui/data-table-pagination.d.ts +0 -17
- package/dist/components/ui/data-table-pagination.js +0 -89
- package/dist/components/ui/data-table-search-input.d.ts +0 -14
- package/dist/components/ui/data-table-search-input.js +0 -15
- package/dist/components/ui/data-table-state.d.ts +0 -19
- package/dist/components/ui/data-table-state.js +0 -8
- package/dist/components/ui/data-table-tanstack.d.ts +0 -99
- package/dist/components/ui/data-table-tanstack.js +0 -128
- package/dist/components/ui/data-table.d.ts +0 -19
- package/dist/components/ui/data-table.js +0 -35
- package/dist/components/ui/dialog.d.ts +0 -23
- package/dist/components/ui/dialog.js +0 -48
- package/dist/components/ui/direction-context.d.ts +0 -3
- package/dist/components/ui/direction-context.js +0 -3
- package/dist/components/ui/direction.d.ts +0 -6
- package/dist/components/ui/direction.js +0 -7
- package/dist/components/ui/drawer.d.ts +0 -18
- package/dist/components/ui/drawer.js +0 -47
- package/dist/components/ui/dropdown-menu.d.ts +0 -30
- package/dist/components/ui/dropdown-menu.js +0 -63
- package/dist/components/ui/empty.d.ts +0 -11
- package/dist/components/ui/empty.js +0 -33
- package/dist/components/ui/expandable-data-table.d.ts +0 -24
- package/dist/components/ui/expandable-data-table.js +0 -62
- package/dist/components/ui/field.d.ts +0 -26
- package/dist/components/ui/field.js +0 -74
- package/dist/components/ui/file-upload-field-parts.d.ts +0 -21
- package/dist/components/ui/file-upload-field-parts.js +0 -55
- package/dist/components/ui/file-upload-field.d.ts +0 -16
- package/dist/components/ui/file-upload-field.js +0 -85
- package/dist/components/ui/form-context.d.ts +0 -23
- package/dist/components/ui/form-context.js +0 -35
- package/dist/components/ui/form-sheet.d.ts +0 -22
- package/dist/components/ui/form-sheet.js +0 -74
- package/dist/components/ui/form.d.ts +0 -12
- package/dist/components/ui/form.js +0 -38
- package/dist/components/ui/hover-card.d.ts +0 -10
- package/dist/components/ui/hover-card.js +0 -22
- package/dist/components/ui/input-group.d.ts +0 -16
- package/dist/components/ui/input-group.js +0 -62
- package/dist/components/ui/input-otp.d.ts +0 -11
- package/dist/components/ui/input-otp.js +0 -21
- package/dist/components/ui/input.d.ts +0 -3
- package/dist/components/ui/input.js +0 -6
- package/dist/components/ui/item.d.ts +0 -24
- package/dist/components/ui/item.js +0 -73
- package/dist/components/ui/kbd.d.ts +0 -3
- package/dist/components/ui/kbd.js +0 -9
- package/dist/components/ui/label.d.ts +0 -4
- package/dist/components/ui/label.js +0 -7
- package/dist/components/ui/loading-state.d.ts +0 -27
- package/dist/components/ui/loading-state.js +0 -44
- package/dist/components/ui/menubar.d.ts +0 -30
- package/dist/components/ui/menubar.js +0 -63
- package/dist/components/ui/metrics-strip.d.ts +0 -7
- package/dist/components/ui/metrics-strip.js +0 -18
- package/dist/components/ui/native-select.d.ts +0 -7
- package/dist/components/ui/native-select.js +0 -13
- package/dist/components/ui/navigation-menu-variants.d.ts +0 -2
- package/dist/components/ui/navigation-menu-variants.js +0 -3
- package/dist/components/ui/navigation-menu.d.ts +0 -13
- package/dist/components/ui/navigation-menu.js +0 -30
- package/dist/components/ui/page-header.d.ts +0 -33
- package/dist/components/ui/page-header.js +0 -54
- package/dist/components/ui/pagination.d.ts +0 -13
- package/dist/components/ui/pagination.js +0 -29
- package/dist/components/ui/popover.d.ts +0 -14
- package/dist/components/ui/popover.js +0 -34
- package/dist/components/ui/progress.d.ts +0 -4
- package/dist/components/ui/progress.js +0 -8
- package/dist/components/ui/property-list.d.ts +0 -6
- package/dist/components/ui/property-list.js +0 -15
- package/dist/components/ui/radio-group.d.ts +0 -5
- package/dist/components/ui/radio-group.js +0 -11
- package/dist/components/ui/registry-docs-api.d.ts +0 -11
- package/dist/components/ui/registry-docs-api.js +0 -9
- package/dist/components/ui/registry-docs-code.d.ts +0 -19
- package/dist/components/ui/registry-docs-code.js +0 -78
- package/dist/components/ui/registry-docs-showcase.d.ts +0 -11
- package/dist/components/ui/registry-docs-showcase.js +0 -27
- package/dist/components/ui/registry-docs.d.ts +0 -27
- package/dist/components/ui/registry-docs.js +0 -32
- package/dist/components/ui/resizable.d.ts +0 -14
- package/dist/components/ui/resizable.js +0 -15
- package/dist/components/ui/scroll-area.d.ts +0 -7
- package/dist/components/ui/scroll-area.js +0 -10
- package/dist/components/ui/select.d.ts +0 -15
- package/dist/components/ui/select.js +0 -38
- package/dist/components/ui/separator.d.ts +0 -4
- package/dist/components/ui/separator.js +0 -7
- package/dist/components/ui/sheet.d.ts +0 -21
- package/dist/components/ui/sheet.js +0 -62
- package/dist/components/ui/sidebar/context.d.ts +0 -27
- package/dist/components/ui/sidebar/context.js +0 -23
- package/dist/components/ui/sidebar/group.d.ts +0 -10
- package/dist/components/ui/sidebar/group.js +0 -18
- package/dist/components/ui/sidebar/layout.d.ts +0 -17
- package/dist/components/ui/sidebar/layout.js +0 -78
- package/dist/components/ui/sidebar/menu.d.ts +0 -30
- package/dist/components/ui/sidebar/menu.js +0 -64
- package/dist/components/ui/sidebar/provider.d.ts +0 -7
- package/dist/components/ui/sidebar/provider.js +0 -53
- package/dist/components/ui/sidebar/rail.d.ts +0 -3
- package/dist/components/ui/sidebar/rail.js +0 -12
- package/dist/components/ui/sidebar/trigger.d.ts +0 -4
- package/dist/components/ui/sidebar/trigger.js +0 -16
- package/dist/components/ui/sidebar-account-menu-theme.d.ts +0 -7
- package/dist/components/ui/sidebar-account-menu-theme.js +0 -32
- package/dist/components/ui/sidebar-account-menu.d.ts +0 -16
- package/dist/components/ui/sidebar-account-menu.js +0 -51
- package/dist/components/ui/sidebar.d.ts +0 -7
- package/dist/components/ui/sidebar.js +0 -7
- package/dist/components/ui/skeleton.d.ts +0 -2
- package/dist/components/ui/skeleton.js +0 -15
- package/dist/components/ui/slider.d.ts +0 -4
- package/dist/components/ui/slider.js +0 -9
- package/dist/components/ui/sonner.d.ts +0 -3
- package/dist/components/ui/sonner.js +0 -33
- package/dist/components/ui/spinner.d.ts +0 -2
- package/dist/components/ui/spinner.js +0 -16
- package/dist/components/ui/switch.d.ts +0 -6
- package/dist/components/ui/switch.js +0 -7
- package/dist/components/ui/table.d.ts +0 -21
- package/dist/components/ui/table.js +0 -34
- package/dist/components/ui/tabs-variants.d.ts +0 -6
- package/dist/components/ui/tabs-variants.js +0 -13
- package/dist/components/ui/tabs.d.ts +0 -8
- package/dist/components/ui/tabs.js +0 -17
- package/dist/components/ui/textarea.d.ts +0 -3
- package/dist/components/ui/textarea.js +0 -6
- package/dist/components/ui/toggle-group.d.ts +0 -9
- package/dist/components/ui/toggle-group.js +0 -24
- package/dist/components/ui/toggle-variants.d.ts +0 -7
- package/dist/components/ui/toggle-variants.js +0 -19
- package/dist/components/ui/toggle.d.ts +0 -5
- package/dist/components/ui/toggle.js +0 -9
- package/dist/components/ui/tooltip.d.ts +0 -14
- package/dist/components/ui/tooltip.js +0 -25
- package/dist/components/ui/use-color-theme.d.ts +0 -2
- package/dist/components/ui/use-color-theme.js +0 -10
- package/dist/components/ui/workflow-timeline.d.ts +0 -20
- package/dist/components/ui/workflow-timeline.js +0 -92
- package/dist/components/walkthrough/presentation/WalkthroughCoach.d.ts +0 -14
- package/dist/components/walkthrough/presentation/WalkthroughCoach.js +0 -32
- package/dist/components/walkthrough/presentation/WalkthroughHighlight.d.ts +0 -5
- package/dist/components/walkthrough/presentation/WalkthroughHighlight.js +0 -9
- package/dist/components/walkthrough/presentation/WalkthroughOverlay.d.ts +0 -1
- package/dist/components/walkthrough/presentation/WalkthroughOverlay.js +0 -70
- package/dist/components/walkthrough/presentation/positionWalkthroughCoach.d.ts +0 -11
- package/dist/components/walkthrough/presentation/positionWalkthroughCoach.js +0 -24
- package/dist/components/walkthrough/presentation/useWalkthroughCoachPosition.d.ts +0 -4
- package/dist/components/walkthrough/presentation/useWalkthroughCoachPosition.js +0 -17
- package/dist/components/walkthrough/runtime/WalkthroughContextDefinition.d.ts +0 -20
- package/dist/components/walkthrough/runtime/WalkthroughContextDefinition.js +0 -2
- package/dist/components/walkthrough/runtime/WalkthroughProvider.d.ts +0 -12
- package/dist/components/walkthrough/runtime/WalkthroughProvider.js +0 -190
- package/dist/components/walkthrough/runtime/useWalkthrough.d.ts +0 -1
- package/dist/components/walkthrough/runtime/useWalkthrough.js +0 -8
- package/dist/components/walkthrough/runtime/walkthroughEvents.d.ts +0 -3
- package/dist/components/walkthrough/runtime/walkthroughEvents.js +0 -55
- package/dist/components/walkthrough/runtime/walkthroughLocation.d.ts +0 -2
- package/dist/components/walkthrough/runtime/walkthroughLocation.js +0 -27
- package/dist/components/walkthrough/runtime/walkthroughStorage.d.ts +0 -3
- package/dist/components/walkthrough/runtime/walkthroughStorage.js +0 -54
- package/dist/components/walkthrough/runtime/walkthroughTypes.d.ts +0 -32
- package/dist/components/walkthrough/targeting/listenForOutsideWalkthroughInteraction.d.ts +0 -2
- package/dist/components/walkthrough/targeting/listenForOutsideWalkthroughInteraction.js +0 -19
- package/dist/components/walkthrough/targeting/useWalkthroughTargetRect.d.ts +0 -15
- package/dist/components/walkthrough/targeting/useWalkthroughTargetRect.js +0 -54
- package/dist/components/walkthrough/targeting/walkthroughTarget.d.ts +0 -6
- package/dist/components/walkthrough/targeting/walkthroughTarget.js +0 -24
- package/dist/components/walkthrough.d.ts +0 -4
- package/dist/components/walkthrough.js +0 -2
- package/dist/entries/accordion.d.ts +0 -1
- package/dist/entries/accordion.js +0 -1
- package/dist/entries/admin-users-page.d.ts +0 -1
- package/dist/entries/admin-users-page.js +0 -1
- package/dist/entries/admin-users-table.d.ts +0 -1
- package/dist/entries/admin-users-table.js +0 -1
- package/dist/entries/alert-dialog.d.ts +0 -1
- package/dist/entries/alert-dialog.js +0 -1
- package/dist/entries/alert.d.ts +0 -1
- package/dist/entries/alert.js +0 -1
- package/dist/entries/app-shell-page.d.ts +0 -1
- package/dist/entries/app-shell-page.js +0 -1
- package/dist/entries/app-shell.d.ts +0 -1
- package/dist/entries/app-shell.js +0 -1
- package/dist/entries/aspect-ratio.d.ts +0 -1
- package/dist/entries/aspect-ratio.js +0 -1
- package/dist/entries/avatar.d.ts +0 -1
- package/dist/entries/avatar.js +0 -1
- package/dist/entries/badge-variants.d.ts +0 -1
- package/dist/entries/badge-variants.js +0 -1
- package/dist/entries/badge.d.ts +0 -1
- package/dist/entries/badge.js +0 -1
- package/dist/entries/breadcrumb.d.ts +0 -1
- package/dist/entries/breadcrumb.js +0 -1
- package/dist/entries/button-group-variants.d.ts +0 -1
- package/dist/entries/button-group-variants.js +0 -1
- package/dist/entries/button-group.d.ts +0 -1
- package/dist/entries/button-group.js +0 -1
- package/dist/entries/button-variants.d.ts +0 -1
- package/dist/entries/button-variants.js +0 -1
- package/dist/entries/button.d.ts +0 -1
- package/dist/entries/button.js +0 -1
- package/dist/entries/calendar.d.ts +0 -1
- package/dist/entries/calendar.js +0 -1
- package/dist/entries/card.d.ts +0 -1
- package/dist/entries/card.js +0 -1
- package/dist/entries/carousel.d.ts +0 -1
- package/dist/entries/carousel.js +0 -1
- package/dist/entries/chart-context.d.ts +0 -1
- package/dist/entries/chart-context.js +0 -1
- package/dist/entries/chart-panel.d.ts +0 -1
- package/dist/entries/chart-panel.js +0 -1
- package/dist/entries/chart-tooltip.d.ts +0 -1
- package/dist/entries/chart-tooltip.js +0 -1
- package/dist/entries/chart.d.ts +0 -1
- package/dist/entries/chart.js +0 -1
- package/dist/entries/checkbox.d.ts +0 -1
- package/dist/entries/checkbox.js +0 -1
- package/dist/entries/ciridae-brand-assets.d.ts +0 -1
- package/dist/entries/ciridae-brand-assets.js +0 -1
- package/dist/entries/ciridae-ui-provider.d.ts +0 -1
- package/dist/entries/ciridae-ui-provider.js +0 -1
- package/dist/entries/collapsible.d.ts +0 -1
- package/dist/entries/collapsible.js +0 -1
- package/dist/entries/color-theme-context.d.ts +0 -1
- package/dist/entries/color-theme-context.js +0 -1
- package/dist/entries/color-theme.d.ts +0 -1
- package/dist/entries/color-theme.js +0 -1
- package/dist/entries/combobox-anchor.d.ts +0 -1
- package/dist/entries/combobox-anchor.js +0 -1
- package/dist/entries/combobox.d.ts +0 -1
- package/dist/entries/combobox.js +0 -1
- package/dist/entries/command.d.ts +0 -1
- package/dist/entries/command.js +0 -1
- package/dist/entries/comment-composer.d.ts +0 -1
- package/dist/entries/comment-composer.js +0 -1
- package/dist/entries/comment-item.d.ts +0 -1
- package/dist/entries/comment-item.js +0 -1
- package/dist/entries/comment-thread.d.ts +0 -1
- package/dist/entries/comment-thread.js +0 -1
- package/dist/entries/comment-types.d.ts +0 -1
- package/dist/entries/comment-types.js +0 -1
- package/dist/entries/context-menu.d.ts +0 -1
- package/dist/entries/context-menu.js +0 -1
- package/dist/entries/copy-field.d.ts +0 -1
- package/dist/entries/copy-field.js +0 -1
- package/dist/entries/data-table-column-settings.d.ts +0 -1
- package/dist/entries/data-table-column-settings.js +0 -1
- package/dist/entries/data-table-context.d.ts +0 -1
- package/dist/entries/data-table-context.js +0 -1
- package/dist/entries/data-table-controls.d.ts +0 -1
- package/dist/entries/data-table-controls.js +0 -1
- package/dist/entries/data-table-facet-filter.d.ts +0 -1
- package/dist/entries/data-table-facet-filter.js +0 -1
- package/dist/entries/data-table-grid.d.ts +0 -1
- package/dist/entries/data-table-grid.js +0 -1
- package/dist/entries/data-table-pagination.d.ts +0 -1
- package/dist/entries/data-table-pagination.js +0 -1
- package/dist/entries/data-table-search-input.d.ts +0 -1
- package/dist/entries/data-table-search-input.js +0 -1
- package/dist/entries/data-table-state.d.ts +0 -1
- package/dist/entries/data-table-state.js +0 -1
- package/dist/entries/data-table-tanstack.d.ts +0 -1
- package/dist/entries/data-table-tanstack.js +0 -1
- package/dist/entries/data-table.d.ts +0 -1
- package/dist/entries/data-table.js +0 -1
- package/dist/entries/dialog.d.ts +0 -1
- package/dist/entries/dialog.js +0 -1
- package/dist/entries/direction-context.d.ts +0 -1
- package/dist/entries/direction-context.js +0 -1
- package/dist/entries/direction.d.ts +0 -1
- package/dist/entries/direction.js +0 -1
- package/dist/entries/drawer.d.ts +0 -1
- package/dist/entries/drawer.js +0 -1
- package/dist/entries/dropdown-menu.d.ts +0 -1
- package/dist/entries/dropdown-menu.js +0 -1
- package/dist/entries/empty.d.ts +0 -1
- package/dist/entries/empty.js +0 -1
- package/dist/entries/expandable-data-table.d.ts +0 -1
- package/dist/entries/expandable-data-table.js +0 -1
- package/dist/entries/feedback-center-comments.d.ts +0 -1
- package/dist/entries/feedback-center-comments.js +0 -1
- package/dist/entries/feedback-center-footer.d.ts +0 -1
- package/dist/entries/feedback-center-footer.js +0 -1
- package/dist/entries/feedback-center-sheet-parts.d.ts +0 -1
- package/dist/entries/feedback-center-sheet-parts.js +0 -1
- package/dist/entries/feedback-center-sheet.d.ts +0 -1
- package/dist/entries/feedback-center-sheet.js +0 -1
- package/dist/entries/feedback-composer-parts.d.ts +0 -1
- package/dist/entries/feedback-composer-parts.js +0 -1
- package/dist/entries/feedback-composer-types.d.ts +0 -1
- package/dist/entries/feedback-composer-types.js +0 -1
- package/dist/entries/feedback-composer.d.ts +0 -1
- package/dist/entries/feedback-composer.js +0 -1
- package/dist/entries/feedback-date-format.d.ts +0 -1
- package/dist/entries/feedback-date-format.js +0 -1
- package/dist/entries/feedback-detail-sheet.d.ts +0 -1
- package/dist/entries/feedback-detail-sheet.js +0 -1
- package/dist/entries/feedback-emergency-fields.d.ts +0 -1
- package/dist/entries/feedback-emergency-fields.js +0 -1
- package/dist/entries/feedback-metrics.d.ts +0 -1
- package/dist/entries/feedback-metrics.js +0 -1
- package/dist/entries/feedback-sheet.d.ts +0 -1
- package/dist/entries/feedback-sheet.js +0 -1
- package/dist/entries/feedback-stakeholder-page-parts.d.ts +0 -1
- package/dist/entries/feedback-stakeholder-page-parts.js +0 -1
- package/dist/entries/feedback-stakeholder-page.d.ts +0 -1
- package/dist/entries/feedback-stakeholder-page.js +0 -1
- package/dist/entries/feedback-status-badge.d.ts +0 -1
- package/dist/entries/feedback-status-badge.js +0 -1
- package/dist/entries/feedback-table-row.d.ts +0 -1
- package/dist/entries/feedback-table-row.js +0 -1
- package/dist/entries/feedback-table-sort.d.ts +0 -1
- package/dist/entries/feedback-table-sort.js +0 -1
- package/dist/entries/feedback-table.d.ts +0 -1
- package/dist/entries/feedback-table.js +0 -1
- package/dist/entries/feedback-tracking-types.d.ts +0 -1
- package/dist/entries/feedback-tracking-types.js +0 -1
- package/dist/entries/feedback-triage-timeline.d.ts +0 -1
- package/dist/entries/feedback-triage-timeline.js +0 -1
- package/dist/entries/feedback-type-badge.d.ts +0 -1
- package/dist/entries/feedback-type-badge.js +0 -1
- package/dist/entries/feedback-unread-badge.d.ts +0 -1
- package/dist/entries/feedback-unread-badge.js +0 -1
- package/dist/entries/feedback-user-detail.d.ts +0 -1
- package/dist/entries/feedback-user-detail.js +0 -1
- package/dist/entries/feedback-user-list.d.ts +0 -1
- package/dist/entries/feedback-user-list.js +0 -1
- package/dist/entries/field.d.ts +0 -1
- package/dist/entries/field.js +0 -1
- package/dist/entries/file-upload-field-parts.d.ts +0 -1
- package/dist/entries/file-upload-field-parts.js +0 -1
- package/dist/entries/file-upload-field.d.ts +0 -1
- package/dist/entries/file-upload-field.js +0 -1
- package/dist/entries/form-context.d.ts +0 -1
- package/dist/entries/form-context.js +0 -1
- package/dist/entries/form-sheet.d.ts +0 -1
- package/dist/entries/form-sheet.js +0 -1
- package/dist/entries/form.d.ts +0 -1
- package/dist/entries/form.js +0 -1
- package/dist/entries/generated-connect-link.d.ts +0 -1
- package/dist/entries/generated-connect-link.js +0 -1
- package/dist/entries/hover-card.d.ts +0 -1
- package/dist/entries/hover-card.js +0 -1
- package/dist/entries/input-group.d.ts +0 -1
- package/dist/entries/input-group.js +0 -1
- package/dist/entries/input-otp.d.ts +0 -1
- package/dist/entries/input-otp.js +0 -1
- package/dist/entries/input.d.ts +0 -1
- package/dist/entries/input.js +0 -1
- package/dist/entries/invite-user-sheet.d.ts +0 -1
- package/dist/entries/invite-user-sheet.js +0 -1
- package/dist/entries/item.d.ts +0 -1
- package/dist/entries/item.js +0 -1
- package/dist/entries/kanban-board-parts.d.ts +0 -1
- package/dist/entries/kanban-board-parts.js +0 -1
- package/dist/entries/kanban-board-utils.d.ts +0 -1
- package/dist/entries/kanban-board-utils.js +0 -1
- package/dist/entries/kanban-board.d.ts +0 -1
- package/dist/entries/kanban-board.js +0 -1
- package/dist/entries/kanban-card.d.ts +0 -1
- package/dist/entries/kanban-card.js +0 -1
- package/dist/entries/kanban-column.d.ts +0 -1
- package/dist/entries/kanban-column.js +0 -1
- package/dist/entries/kanban-detail-sheet.d.ts +0 -1
- package/dist/entries/kanban-detail-sheet.js +0 -1
- package/dist/entries/kanban-page.d.ts +0 -1
- package/dist/entries/kanban-page.js +0 -1
- package/dist/entries/kanban-types.d.ts +0 -1
- package/dist/entries/kanban-types.js +0 -1
- package/dist/entries/kbd.d.ts +0 -1
- package/dist/entries/kbd.js +0 -1
- package/dist/entries/label.d.ts +0 -1
- package/dist/entries/label.js +0 -1
- package/dist/entries/loading-state.d.ts +0 -1
- package/dist/entries/loading-state.js +0 -1
- package/dist/entries/mcp-access-grouped-tool-picker.d.ts +0 -1
- package/dist/entries/mcp-access-grouped-tool-picker.js +0 -1
- package/dist/entries/mcp-access-tool-picker.d.ts +0 -1
- package/dist/entries/mcp-access-tool-picker.js +0 -1
- package/dist/entries/mcp-access-types.d.ts +0 -1
- package/dist/entries/mcp-access-types.js +0 -1
- package/dist/entries/mcp-client-setup.d.ts +0 -1
- package/dist/entries/mcp-client-setup.js +0 -1
- package/dist/entries/mcp-connect-clients.d.ts +0 -1
- package/dist/entries/mcp-connect-clients.js +0 -1
- package/dist/entries/mcp-plan-choice.d.ts +0 -1
- package/dist/entries/mcp-plan-choice.js +0 -1
- package/dist/entries/menubar.d.ts +0 -1
- package/dist/entries/menubar.js +0 -1
- package/dist/entries/metrics-strip.d.ts +0 -1
- package/dist/entries/metrics-strip.js +0 -1
- package/dist/entries/native-select.d.ts +0 -1
- package/dist/entries/native-select.js +0 -1
- package/dist/entries/navigation-menu-variants.d.ts +0 -1
- package/dist/entries/navigation-menu-variants.js +0 -1
- package/dist/entries/navigation-menu.d.ts +0 -1
- package/dist/entries/navigation-menu.js +0 -1
- package/dist/entries/page-header.d.ts +0 -1
- package/dist/entries/page-header.js +0 -1
- package/dist/entries/pagination.d.ts +0 -1
- package/dist/entries/pagination.js +0 -1
- package/dist/entries/palette.d.ts +0 -2
- package/dist/entries/palette.js +0 -2
- package/dist/entries/popover.d.ts +0 -1
- package/dist/entries/popover.js +0 -1
- package/dist/entries/progress.d.ts +0 -1
- package/dist/entries/progress.js +0 -1
- package/dist/entries/property-list.d.ts +0 -1
- package/dist/entries/property-list.js +0 -1
- package/dist/entries/radio-group.d.ts +0 -1
- package/dist/entries/radio-group.js +0 -1
- package/dist/entries/registry-docs-api.d.ts +0 -1
- package/dist/entries/registry-docs-api.js +0 -1
- package/dist/entries/registry-docs-code.d.ts +0 -1
- package/dist/entries/registry-docs-code.js +0 -1
- package/dist/entries/registry-docs-showcase.d.ts +0 -1
- package/dist/entries/registry-docs-showcase.js +0 -1
- package/dist/entries/registry-docs.d.ts +0 -1
- package/dist/entries/registry-docs.js +0 -1
- package/dist/entries/resizable.d.ts +0 -1
- package/dist/entries/resizable.js +0 -1
- package/dist/entries/scroll-area.d.ts +0 -1
- package/dist/entries/scroll-area.js +0 -1
- package/dist/entries/select.d.ts +0 -1
- package/dist/entries/select.js +0 -1
- package/dist/entries/separator.d.ts +0 -1
- package/dist/entries/separator.js +0 -1
- package/dist/entries/sheet.d.ts +0 -1
- package/dist/entries/sheet.js +0 -1
- package/dist/entries/sidebar/context.d.ts +0 -1
- package/dist/entries/sidebar/context.js +0 -1
- package/dist/entries/sidebar/group.d.ts +0 -1
- package/dist/entries/sidebar/group.js +0 -1
- package/dist/entries/sidebar/layout.d.ts +0 -1
- package/dist/entries/sidebar/layout.js +0 -1
- package/dist/entries/sidebar/menu.d.ts +0 -1
- package/dist/entries/sidebar/menu.js +0 -1
- package/dist/entries/sidebar/provider.d.ts +0 -1
- package/dist/entries/sidebar/provider.js +0 -1
- package/dist/entries/sidebar/rail.d.ts +0 -1
- package/dist/entries/sidebar/rail.js +0 -1
- package/dist/entries/sidebar/trigger.d.ts +0 -1
- package/dist/entries/sidebar/trigger.js +0 -1
- package/dist/entries/sidebar-account-menu-theme.d.ts +0 -1
- package/dist/entries/sidebar-account-menu-theme.js +0 -1
- package/dist/entries/sidebar-account-menu.d.ts +0 -1
- package/dist/entries/sidebar-account-menu.js +0 -1
- package/dist/entries/sidebar.d.ts +0 -1
- package/dist/entries/sidebar.js +0 -1
- package/dist/entries/skeleton.d.ts +0 -1
- package/dist/entries/skeleton.js +0 -1
- package/dist/entries/slider.d.ts +0 -1
- package/dist/entries/slider.js +0 -1
- package/dist/entries/sonner.d.ts +0 -1
- package/dist/entries/sonner.js +0 -1
- package/dist/entries/spinner.d.ts +0 -1
- package/dist/entries/spinner.js +0 -1
- package/dist/entries/submit-feedback-composer.d.ts +0 -1
- package/dist/entries/submit-feedback-composer.js +0 -1
- package/dist/entries/switch.d.ts +0 -1
- package/dist/entries/switch.js +0 -1
- package/dist/entries/table.d.ts +0 -1
- package/dist/entries/table.js +0 -1
- package/dist/entries/tabs-variants.d.ts +0 -1
- package/dist/entries/tabs-variants.js +0 -1
- package/dist/entries/tabs.d.ts +0 -1
- package/dist/entries/tabs.js +0 -1
- package/dist/entries/textarea.d.ts +0 -1
- package/dist/entries/textarea.js +0 -1
- package/dist/entries/timestamp-format.d.ts +0 -1
- package/dist/entries/timestamp-format.js +0 -1
- package/dist/entries/toggle-group.d.ts +0 -1
- package/dist/entries/toggle-group.js +0 -1
- package/dist/entries/toggle-variants.d.ts +0 -1
- package/dist/entries/toggle-variants.js +0 -1
- package/dist/entries/toggle.d.ts +0 -1
- package/dist/entries/toggle.js +0 -1
- package/dist/entries/tooltip.d.ts +0 -1
- package/dist/entries/tooltip.js +0 -1
- package/dist/entries/use-color-theme.d.ts +0 -1
- package/dist/entries/use-color-theme.js +0 -1
- package/dist/entries/use-feedback-composer-state.d.ts +0 -1
- package/dist/entries/use-feedback-composer-state.js +0 -1
- package/dist/entries/use-mobile.d.ts +0 -1
- package/dist/entries/use-mobile.js +0 -1
- package/dist/entries/utils.d.ts +0 -1
- package/dist/entries/utils.js +0 -1
- package/dist/entries/walkthrough.d.ts +0 -1
- package/dist/entries/walkthrough.js +0 -1
- package/dist/entries/workflow-timeline.d.ts +0 -1
- package/dist/entries/workflow-timeline.js +0 -1
- package/dist/hooks/use-mobile.d.ts +0 -1
- package/dist/hooks/use-mobile.js +0 -17
- package/dist/lib/browser-storage.d.ts +0 -12
- package/dist/lib/browser-storage.js +0 -42
- package/dist/lib/palette-presets.d.ts +0 -17
- package/dist/lib/palette-presets.js +0 -42
- package/dist/lib/palette-tokens.d.ts +0 -39
- package/dist/lib/palette-tokens.js +0 -133
- package/dist/lib/palette.d.ts +0 -83
- package/dist/lib/palette.js +0 -151
- package/dist/lib/utils.d.ts +0 -5
- package/dist/lib/utils.js +0 -8
- package/dist/style-imports.d.ts +0 -3
- /package/dist/{components/blocks/feedback-composer-types.js → feedback/comment-types.js} +0 -0
- /package/dist/{components/blocks/kanban-types.js → feedback/feedback-composer-types.js} +0 -0
- /package/dist/{components/walkthrough/runtime/walkthroughTypes.js → feedback/feedback-tracking-types.js} +0 -0
|
@@ -0,0 +1,475 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
/*
|
|
3
|
+
* The feedback sheet. New: what it is about, where it was sent from, what happened, whether to
|
|
4
|
+
* attach a screenshot, with numbered pointers and notes on it, and files dropped on the form,
|
|
5
|
+
* picked or pasted; the form owns its validation and the sending, sent and failed states.
|
|
6
|
+
* Sent: everything the person filed, and each item's conversation with the Ciridae team as a
|
|
7
|
+
* thread they can reply in, with the item's actions, such as withdrawing it, behind its menu.
|
|
8
|
+
* The sheet is presentational: the caller owns the requests behind `onSubmit`, `items`, `item`,
|
|
9
|
+
* `onReply` and `onWithdraw`.
|
|
10
|
+
*/
|
|
11
|
+
import { ArrowClockwiseIcon, ArrowLeftIcon, ChatCircleTextIcon, DotsThreeIcon, SquaresFourIcon, } from "@phosphor-icons/react";
|
|
12
|
+
import { createContext, useContext, useId, useState } from "react";
|
|
13
|
+
import { css, cx } from "#primitives/css";
|
|
14
|
+
import { feedbackAttachmentLimits, } from "../feedback/contract.js";
|
|
15
|
+
import { Button, IconButton } from "./button.js";
|
|
16
|
+
import { ChatComposer, ChatThread } from "./chat.js";
|
|
17
|
+
import { DateTime } from "./date-time.js";
|
|
18
|
+
import { Drawer, DrawerBody, DrawerField, DrawerFooter, DrawerForm } from "./drawer.js";
|
|
19
|
+
import { Dropzone, DropzoneFileList, DropzonePad } from "./dropzone.js";
|
|
20
|
+
import { FeedbackScreenshot, } from "./feedback-screenshot.js";
|
|
21
|
+
import { Checkbox, Textarea } from "./form-controls.js";
|
|
22
|
+
import { directional, icon, Spinner } from "./icon.js";
|
|
23
|
+
import { Eyebrow } from "./layout.js";
|
|
24
|
+
import { useCiridaeLocale } from "./locale.js";
|
|
25
|
+
import { Menu } from "./menu.js";
|
|
26
|
+
import { Select } from "./select.js";
|
|
27
|
+
import { Skeleton } from "./skeleton.js";
|
|
28
|
+
import { Status } from "./status.js";
|
|
29
|
+
import { StatusBanner } from "./status-banner.js";
|
|
30
|
+
import { TabsList, TabsRoot, TabsTab } from "./tabs.js";
|
|
31
|
+
/** The sheet's `labels` over the locale's, for every part of the sheet. */
|
|
32
|
+
const FeedbackLabelsContext = createContext(undefined);
|
|
33
|
+
function useFeedbackLabels() {
|
|
34
|
+
return { ...useCiridaeLocale().labels.feedback, ...useContext(FeedbackLabelsContext) };
|
|
35
|
+
}
|
|
36
|
+
const FEEDBACK_KINDS = ["wrong", "idea", "question"];
|
|
37
|
+
function kindOptions(labels) {
|
|
38
|
+
const kindLabels = {
|
|
39
|
+
wrong: labels.kindWrong,
|
|
40
|
+
idea: labels.kindIdea,
|
|
41
|
+
question: labels.kindQuestion,
|
|
42
|
+
};
|
|
43
|
+
return FEEDBACK_KINDS.map((value) => ({ value, label: kindLabels[value] }));
|
|
44
|
+
}
|
|
45
|
+
function isFeedbackKind(value) {
|
|
46
|
+
return FEEDBACK_KINDS.some((kind) => kind === value);
|
|
47
|
+
}
|
|
48
|
+
function typeLabel(type, labels) {
|
|
49
|
+
return { bug: labels.typeBug, feature: labels.typeFeature, general: labels.typeGeneral }[type];
|
|
50
|
+
}
|
|
51
|
+
function statusDisplay(status, labels) {
|
|
52
|
+
const display = {
|
|
53
|
+
received: { label: labels.statusReceived, variant: "pending" },
|
|
54
|
+
in_progress: { label: labels.statusInProgress, variant: "running" },
|
|
55
|
+
discussion_required: { label: labels.statusNeedsReply, variant: "needs-review" },
|
|
56
|
+
completed: { label: labels.statusDone, variant: "healthy" },
|
|
57
|
+
no_action: { label: labels.statusClosed, variant: "default" },
|
|
58
|
+
withdrawn: { label: labels.statusWithdrawn, variant: "archived" },
|
|
59
|
+
};
|
|
60
|
+
return display[status];
|
|
61
|
+
}
|
|
62
|
+
const body = css({
|
|
63
|
+
display: "flex",
|
|
64
|
+
flexDirection: "column",
|
|
65
|
+
gap: "layout.clusterGap",
|
|
66
|
+
});
|
|
67
|
+
const where = css({
|
|
68
|
+
display: "flex",
|
|
69
|
+
alignItems: "center",
|
|
70
|
+
gap: "layout.controlGap",
|
|
71
|
+
padding: "panel.default",
|
|
72
|
+
border: "1px solid token(colors.border.control)",
|
|
73
|
+
borderRadius: "action",
|
|
74
|
+
background: "bg.field",
|
|
75
|
+
color: "fg.primary",
|
|
76
|
+
textDecoration: "none",
|
|
77
|
+
"& svg": { flexShrink: "0", color: "fg.muted" },
|
|
78
|
+
});
|
|
79
|
+
const whereCopy = css({ display: "grid", flex: "1", gap: "layout.tightGap", minWidth: "0" });
|
|
80
|
+
const whereLabel = css({
|
|
81
|
+
fontSize: "body",
|
|
82
|
+
fontWeight: "medium",
|
|
83
|
+
letterSpacing: "compact",
|
|
84
|
+
lineHeight: "tight",
|
|
85
|
+
});
|
|
86
|
+
const whereDetail = css({
|
|
87
|
+
overflow: "hidden",
|
|
88
|
+
textOverflow: "ellipsis",
|
|
89
|
+
whiteSpace: "nowrap",
|
|
90
|
+
color: "fg.muted",
|
|
91
|
+
fontSize: "code",
|
|
92
|
+
fontWeight: "medium",
|
|
93
|
+
letterSpacing: "compact",
|
|
94
|
+
lineHeight: "tight",
|
|
95
|
+
});
|
|
96
|
+
const message = css({ minHeight: "132px" });
|
|
97
|
+
const screenshotRow = css({
|
|
98
|
+
display: "flex",
|
|
99
|
+
alignItems: "flex-start",
|
|
100
|
+
justifyContent: "space-between",
|
|
101
|
+
gap: "layout.contentGap",
|
|
102
|
+
});
|
|
103
|
+
const screenshotCopy = css({
|
|
104
|
+
display: "grid",
|
|
105
|
+
gap: "layout.tightGap",
|
|
106
|
+
fontSize: "body",
|
|
107
|
+
fontWeight: "medium",
|
|
108
|
+
letterSpacing: "compact",
|
|
109
|
+
lineHeight: "tight",
|
|
110
|
+
});
|
|
111
|
+
const screenshotPreview = css({
|
|
112
|
+
display: "grid",
|
|
113
|
+
placeItems: "center",
|
|
114
|
+
flexShrink: "0",
|
|
115
|
+
width: "96px",
|
|
116
|
+
height: "60px",
|
|
117
|
+
border: "1px solid token(colors.border.control)",
|
|
118
|
+
borderRadius: "keycap",
|
|
119
|
+
background: "bg.field",
|
|
120
|
+
color: "fg.muted",
|
|
121
|
+
fontSize: "code",
|
|
122
|
+
fontWeight: "medium",
|
|
123
|
+
});
|
|
124
|
+
const sent = css({
|
|
125
|
+
display: "flex",
|
|
126
|
+
flex: "1",
|
|
127
|
+
flexDirection: "column",
|
|
128
|
+
alignItems: "center",
|
|
129
|
+
justifyContent: "center",
|
|
130
|
+
gap: "layout.clusterGap",
|
|
131
|
+
maxWidth: "320px",
|
|
132
|
+
marginInline: "auto",
|
|
133
|
+
textAlign: "center",
|
|
134
|
+
});
|
|
135
|
+
const sentIcon = css({
|
|
136
|
+
display: "grid",
|
|
137
|
+
placeItems: "center",
|
|
138
|
+
width: "48px",
|
|
139
|
+
height: "48px",
|
|
140
|
+
border: "1px solid token(colors.border.control)",
|
|
141
|
+
borderRadius: "round",
|
|
142
|
+
background: "bg.field",
|
|
143
|
+
});
|
|
144
|
+
const sentTitle = css({
|
|
145
|
+
fontSize: "body",
|
|
146
|
+
fontWeight: "medium",
|
|
147
|
+
letterSpacing: "compact",
|
|
148
|
+
lineHeight: "tight",
|
|
149
|
+
});
|
|
150
|
+
const sentActions = css({ display: "flex", gap: "layout.controlGap" });
|
|
151
|
+
/* The Sent list: flush rows, the subject over its type and when it last moved, the status after. */
|
|
152
|
+
const sentList = css({ display: "grid", margin: "none", padding: "none", listStyle: "none" });
|
|
153
|
+
const sentRow = css({
|
|
154
|
+
display: "grid",
|
|
155
|
+
gridTemplateColumns: "minmax(0, 1fr) auto",
|
|
156
|
+
alignItems: "center",
|
|
157
|
+
gap: "layout.contentGap",
|
|
158
|
+
width: "100%",
|
|
159
|
+
paddingBlock: "panel.default",
|
|
160
|
+
paddingInline: "panel.comfortable",
|
|
161
|
+
border: "0",
|
|
162
|
+
borderBottom: "1px solid token(colors.border.subtle)",
|
|
163
|
+
background: "transparent",
|
|
164
|
+
color: "fg.primary",
|
|
165
|
+
font: "inherit",
|
|
166
|
+
textAlign: "start",
|
|
167
|
+
cursor: "pointer",
|
|
168
|
+
_hover: { background: "bg.rowHover" },
|
|
169
|
+
_focusVisible: { focusRing: "inset" },
|
|
170
|
+
});
|
|
171
|
+
const sentRowCopy = css({ display: "grid", gap: "layout.tightGap", minWidth: "0" });
|
|
172
|
+
const sentRowSubject = css({
|
|
173
|
+
display: "flex",
|
|
174
|
+
alignItems: "center",
|
|
175
|
+
gap: "control.iconGap",
|
|
176
|
+
minWidth: "0",
|
|
177
|
+
fontSize: "body",
|
|
178
|
+
letterSpacing: "compact",
|
|
179
|
+
lineHeight: "tight",
|
|
180
|
+
"& > span": { overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap" },
|
|
181
|
+
// Needs a reply: the row reads unread, with the dot that marks one.
|
|
182
|
+
"[data-needs-reply] &": { fontWeight: "medium" },
|
|
183
|
+
});
|
|
184
|
+
const needsReplyDot = css({
|
|
185
|
+
flexShrink: "0",
|
|
186
|
+
width: "indicator.live",
|
|
187
|
+
height: "indicator.live",
|
|
188
|
+
borderRadius: "round",
|
|
189
|
+
background: "accent.red",
|
|
190
|
+
});
|
|
191
|
+
const sentRowMeta = css({
|
|
192
|
+
overflow: "hidden",
|
|
193
|
+
textOverflow: "ellipsis",
|
|
194
|
+
whiteSpace: "nowrap",
|
|
195
|
+
color: "fg.muted",
|
|
196
|
+
fontSize: "code",
|
|
197
|
+
fontWeight: "medium",
|
|
198
|
+
letterSpacing: "compact",
|
|
199
|
+
});
|
|
200
|
+
const sentEmpty = css({
|
|
201
|
+
padding: "panel.roomy",
|
|
202
|
+
color: "fg.muted",
|
|
203
|
+
fontSize: "caption",
|
|
204
|
+
fontWeight: "medium",
|
|
205
|
+
textAlign: "center",
|
|
206
|
+
});
|
|
207
|
+
const padded = css({ padding: "panel.comfortable" });
|
|
208
|
+
/* An item: its subject and status pinned over the thread, which scrolls; the reply below. */
|
|
209
|
+
const itemHeader = css({
|
|
210
|
+
position: "sticky",
|
|
211
|
+
top: "0",
|
|
212
|
+
zIndex: "raised",
|
|
213
|
+
display: "flex",
|
|
214
|
+
alignItems: "flex-start",
|
|
215
|
+
gap: "layout.controlGap",
|
|
216
|
+
paddingBlock: "panel.default",
|
|
217
|
+
paddingInline: "panel.default",
|
|
218
|
+
borderBottom: "1px solid token(colors.border.subtle)",
|
|
219
|
+
background: "bg.surface",
|
|
220
|
+
});
|
|
221
|
+
const itemTitle = css({
|
|
222
|
+
display: "grid",
|
|
223
|
+
flex: "1",
|
|
224
|
+
gap: "layout.tightGap",
|
|
225
|
+
minWidth: "0",
|
|
226
|
+
paddingBlockStart: "control.iconGap",
|
|
227
|
+
});
|
|
228
|
+
const itemSubject = css({
|
|
229
|
+
fontSize: "body",
|
|
230
|
+
fontWeight: "medium",
|
|
231
|
+
letterSpacing: "compact",
|
|
232
|
+
lineHeight: "tight",
|
|
233
|
+
overflowWrap: "anywhere",
|
|
234
|
+
});
|
|
235
|
+
const itemStatus = css({ flexShrink: "0", paddingBlockStart: "control.iconGap" });
|
|
236
|
+
const itemFoot = css({
|
|
237
|
+
display: "grid",
|
|
238
|
+
flexShrink: "0",
|
|
239
|
+
gap: "layout.controlGap",
|
|
240
|
+
padding: "panel.default",
|
|
241
|
+
borderTop: "1px solid token(colors.border.control)",
|
|
242
|
+
});
|
|
243
|
+
const placeholderLines = css({ display: "grid", gap: "layout.controlGap" });
|
|
244
|
+
/**
|
|
245
|
+
* The description to file: what happened, then each screenshot pointer's note, numbered, with
|
|
246
|
+
* where it sits on the image, for a backend that takes no annotations of its own.
|
|
247
|
+
*/
|
|
248
|
+
export function formatFeedbackDescription({ whatHappened, annotations }) {
|
|
249
|
+
if (annotations.length === 0)
|
|
250
|
+
return whatHappened;
|
|
251
|
+
const percent = (fraction) => `${Math.round(fraction * 100)}%`;
|
|
252
|
+
const lines = annotations.map((pointer, index) => {
|
|
253
|
+
const at = `(${percent(pointer.x)}, ${percent(pointer.y)})`;
|
|
254
|
+
return `${index + 1}. ${pointer.note ? `${pointer.note} ${at}` : at}`;
|
|
255
|
+
});
|
|
256
|
+
return `${whatHappened}\n\nScreenshot pointers:\n${lines.join("\n")}`;
|
|
257
|
+
}
|
|
258
|
+
/** The page's address as the reporter knows it: host, path and hash, without the scheme. */
|
|
259
|
+
function linkText(href) {
|
|
260
|
+
return href.replace(/^[a-z]+:\/\//i, "");
|
|
261
|
+
}
|
|
262
|
+
/** The sheet's form, body and footer, for a `Drawer` that holds more than the form. */
|
|
263
|
+
export function FeedbackForm({ where: about, screenshot, onSubmit, errorDetail, onClose, }) {
|
|
264
|
+
const { formatFileSize, labels: locale } = useCiridaeLocale();
|
|
265
|
+
const labels = useFeedbackLabels();
|
|
266
|
+
const [kind, setKind] = useState("wrong");
|
|
267
|
+
const [whatHappened, setWhatHappened] = useState("");
|
|
268
|
+
const [includeScreenshot, setIncludeScreenshot] = useState(true);
|
|
269
|
+
const [pointers, setPointers] = useState([]);
|
|
270
|
+
const [attachments, setAttachments] = useState([]);
|
|
271
|
+
const [attachmentError, setAttachmentError] = useState(null);
|
|
272
|
+
const [validation, setValidation] = useState(null);
|
|
273
|
+
const [sendState, setSendState] = useState({ status: "idle" });
|
|
274
|
+
const messageErrorId = useId();
|
|
275
|
+
const submitting = sendState.status === "submitting";
|
|
276
|
+
const reset = () => {
|
|
277
|
+
setKind("wrong");
|
|
278
|
+
setWhatHappened("");
|
|
279
|
+
setIncludeScreenshot(true);
|
|
280
|
+
setPointers([]);
|
|
281
|
+
setAttachments([]);
|
|
282
|
+
setAttachmentError(null);
|
|
283
|
+
setValidation(null);
|
|
284
|
+
setSendState({ status: "idle" });
|
|
285
|
+
};
|
|
286
|
+
// Keeps what fits the limits and names the first file or limit that did not.
|
|
287
|
+
const addAttachments = (files) => {
|
|
288
|
+
const { count, bytes } = feedbackAttachmentLimits;
|
|
289
|
+
const empty = files.find((file) => file.size === 0);
|
|
290
|
+
const oversize = files.find((file) => file.size > bytes);
|
|
291
|
+
const fitting = files.filter((file) => file.size > 0 && file.size <= bytes);
|
|
292
|
+
const added = fitting.slice(0, Math.max(0, count - attachments.length));
|
|
293
|
+
setAttachments([...attachments, ...added]);
|
|
294
|
+
setAttachmentError(oversize
|
|
295
|
+
? labels.fileTooLarge(oversize.name, formatFileSize(bytes))
|
|
296
|
+
: empty
|
|
297
|
+
? labels.fileEmpty(empty.name)
|
|
298
|
+
: added.length < fitting.length
|
|
299
|
+
? labels.tooManyFiles(count)
|
|
300
|
+
: null);
|
|
301
|
+
};
|
|
302
|
+
const removeAttachment = (removed) => {
|
|
303
|
+
setAttachments(attachments.filter((file) => file !== removed));
|
|
304
|
+
setAttachmentError(null);
|
|
305
|
+
};
|
|
306
|
+
const send = async () => {
|
|
307
|
+
if (!whatHappened.trim()) {
|
|
308
|
+
setValidation(labels.needsWords);
|
|
309
|
+
return;
|
|
310
|
+
}
|
|
311
|
+
setValidation(null);
|
|
312
|
+
setSendState({ status: "submitting" });
|
|
313
|
+
try {
|
|
314
|
+
const { reference } = await onSubmit({
|
|
315
|
+
kind,
|
|
316
|
+
whatHappened: whatHappened.trim(),
|
|
317
|
+
includeScreenshot,
|
|
318
|
+
annotations: includeScreenshot
|
|
319
|
+
? pointers.map((pointer) => ({ x: pointer.x, y: pointer.y, note: pointer.note.trim() }))
|
|
320
|
+
: [],
|
|
321
|
+
attachments,
|
|
322
|
+
});
|
|
323
|
+
setSendState({ status: "sent", reference });
|
|
324
|
+
}
|
|
325
|
+
catch (error) {
|
|
326
|
+
setSendState({ status: "error", error });
|
|
327
|
+
}
|
|
328
|
+
};
|
|
329
|
+
if (sendState.status === "sent") {
|
|
330
|
+
return (_jsx(DrawerBody, { className: body, children: _jsxs("div", { className: sent, children: [_jsx("span", { className: sentIcon, children: _jsx(ChatCircleTextIcon, { className: icon({ size: "medium" }) }) }), _jsxs("div", { className: css({ display: "grid", gap: "layout.controlGap" }), children: [_jsx("span", { className: sentTitle, children: labels.sent }), _jsx(Eyebrow, { children: sendState.reference })] }), _jsxs("span", { className: sentActions, children: [_jsx(Button, { size: "medium", variant: "secondary", onClick: reset, children: labels.sendAnother }), _jsx(Button, { size: "medium", onClick: onClose, children: locale.common.done })] })] }) }));
|
|
331
|
+
}
|
|
332
|
+
const whereContent = (_jsxs(_Fragment, { children: [about.icon ?? _jsx(SquaresFourIcon, { className: icon({ size: "small" }) }), _jsxs("span", { className: whereCopy, children: [_jsx("span", { className: whereLabel, children: about.label }), about.detail && _jsx("span", { className: whereDetail, children: about.detail }), about.href && _jsx("span", { className: whereDetail, children: linkText(about.href) })] })] }));
|
|
333
|
+
return (_jsxs(DrawerForm, { noValidate: true, onSubmit: (event) => {
|
|
334
|
+
event.preventDefault();
|
|
335
|
+
void send();
|
|
336
|
+
}, children: [_jsxs(Dropzone, { render: _jsx(DrawerBody, { className: body }), disabled: submitting, onFiles: addAttachments, children: [sendState.status === "error" && (_jsx(FailedNotice, { title: labels.sendFailed, children: errorDetail?.(sendState.error) })), _jsx(DrawerField, { label: labels.type, children: _jsx(Select, { label: labels.type, size: "medium", options: kindOptions(labels), value: kind, disabled: submitting, onValueChange: (value) => isFeedbackKind(value) && setKind(value) }) }), _jsx(DrawerField, { label: labels.where, children: _jsx("div", { className: where, children: whereContent }) }), _jsx(DrawerField, { label: labels.whatHappened, error: validation, children: _jsx(Textarea, { className: message, value: whatHappened, placeholder: labels.whatHappenedPlaceholder, "aria-invalid": validation ? true : undefined, "aria-describedby": validation ? messageErrorId : undefined, disabled: submitting, onChange: (event) => setWhatHappened(event.target.value) }) }), _jsxs("div", { className: screenshotRow, children: [_jsx(Checkbox, { checked: includeScreenshot, disabled: submitting, onCheckedChange: (checked) => setIncludeScreenshot(checked), children: _jsx("span", { className: screenshotCopy, children: labels.includeScreenshot }) }), screenshot ? (_jsx(FeedbackScreenshot, { src: screenshot, pointers: pointers, onPointersChange: setPointers, disabled: submitting || !includeScreenshot })) : (_jsx("span", { className: screenshotPreview, children: labels.preview }))] }), _jsxs(DrawerField, { label: labels.attachments, error: attachmentError, children: [_jsx(DropzoneFileList, { files: attachments, pending: submitting, disabled: submitting, onRemove: removeAttachment }), _jsx(DropzonePad, {})] })] }), _jsxs(DrawerFooter, { children: [_jsx(Button, { size: "medium", variant: "secondary", disabled: submitting, onClick: onClose, children: locale.common.cancel }), _jsx(Button, { type: "submit", size: "medium", loading: submitting, icon: sendState.status === "error" ? (_jsx(ArrowClockwiseIcon, { className: icon({ size: "small" }) })) : undefined, children: submitting
|
|
337
|
+
? labels.sending
|
|
338
|
+
: sendState.status === "error"
|
|
339
|
+
? locale.common.tryAgain
|
|
340
|
+
: labels.send })] })] }));
|
|
341
|
+
}
|
|
342
|
+
/** A failed request's notice: its title, then what the caller adds, such as the error ID. */
|
|
343
|
+
function FailedNotice({ title, children, action, }) {
|
|
344
|
+
return _jsx(StatusBanner, { tone: "danger", title: title, description: children, action: action });
|
|
345
|
+
}
|
|
346
|
+
/** The floating feedback sheet. Closing it drops the draft and the open item. */
|
|
347
|
+
export function FeedbackSheet({ labels, ...props }) {
|
|
348
|
+
return (_jsx(FeedbackLabelsContext, { value: labels, children: _jsx(FeedbackSheetContent, { ...props }) }));
|
|
349
|
+
}
|
|
350
|
+
function FeedbackSheetContent({ open, onOpenChange, actions, sent, errorDetail, ...formProps }) {
|
|
351
|
+
const labels = useFeedbackLabels();
|
|
352
|
+
const [tab, setTab] = useState("new");
|
|
353
|
+
const [openItemId, setOpenItemId] = useState(null);
|
|
354
|
+
const showSent = tab === "sent" && sent !== undefined;
|
|
355
|
+
const close = () => {
|
|
356
|
+
onOpenChange(false);
|
|
357
|
+
setOpenItemId(null);
|
|
358
|
+
};
|
|
359
|
+
return (_jsx(Drawer, { open: open, onOpenChange: (next) => (next ? onOpenChange(true) : close()), title: showSent ? labels.sentTitle : labels.sendTitle, icon: _jsx(ChatCircleTextIcon, { className: icon({ size: "small" }), weight: "fill" }), actions: _jsxs(_Fragment, { children: [sent && (_jsx(TabsRoot, { value: tab, onValueChange: (value) => {
|
|
360
|
+
setTab(value);
|
|
361
|
+
setOpenItemId(null);
|
|
362
|
+
}, children: _jsxs(TabsList, { variant: "contained", children: [_jsx(TabsTab, { value: "new", children: labels.newTab }), _jsx(TabsTab, { value: "sent", children: labels.sentTab })] }) })), actions] }), children: !showSent ? (_jsx(FeedbackForm, { ...formProps, errorDetail: errorDetail, onClose: close })) : openItemId === null ? (_jsx(SentList, { items: sent.items, errorDetail: errorDetail, onOpen: (feedbackId) => {
|
|
363
|
+
sent.onOpenItem(feedbackId);
|
|
364
|
+
setOpenItemId(feedbackId);
|
|
365
|
+
} })) : (_jsx(SentItem, { feedbackId: openItemId, item: sent.item, errorDetail: errorDetail, onReply: sent.onReply, onWithdraw: sent.onWithdraw, onBack: () => setOpenItemId(null) }, openItemId)) }));
|
|
366
|
+
}
|
|
367
|
+
const placeholderWidths = ["58%", "42%", "50%"];
|
|
368
|
+
function SentList({ items, errorDetail, onOpen, }) {
|
|
369
|
+
const labels = useFeedbackLabels();
|
|
370
|
+
const { common } = useCiridaeLocale().labels;
|
|
371
|
+
if (items.status === "error") {
|
|
372
|
+
return (_jsx(DrawerBody, { children: _jsx(FailedNotice, { title: labels.loadListFailed, action: _jsx("button", { type: "button", onClick: items.retry, children: common.tryAgain }), children: errorDetail?.(items.error) }) }));
|
|
373
|
+
}
|
|
374
|
+
if (items.status === "loading") {
|
|
375
|
+
return (_jsx(DrawerBody, { flush: true, children: _jsx("ul", { className: sentList, "aria-busy": "true", children: placeholderWidths.map((width) => (_jsxs("li", { className: sentRow, children: [_jsxs("span", { className: sentRowCopy, children: [_jsx(Skeleton, { shape: "text", style: { width } }), _jsx(Skeleton, { shape: "text", style: { width: "30%" } })] }), _jsx(Skeleton, { shape: "text", style: { width: 64 } })] }, width))) }) }));
|
|
376
|
+
}
|
|
377
|
+
if (items.data.length === 0) {
|
|
378
|
+
return (_jsx(DrawerBody, { flush: true, children: _jsx("p", { className: sentEmpty, children: labels.noneSent }) }));
|
|
379
|
+
}
|
|
380
|
+
return (_jsx(DrawerBody, { flush: true, children: _jsx("ul", { className: sentList, children: items.data.map((item) => {
|
|
381
|
+
const needsReply = item.status === "discussion_required";
|
|
382
|
+
return (_jsx("li", { children: _jsxs("button", { type: "button", className: sentRow, "data-needs-reply": needsReply ? "" : undefined, onClick: () => onOpen(item.id), children: [_jsxs("span", { className: sentRowCopy, children: [_jsxs("span", { className: sentRowSubject, children: [needsReply && _jsx("span", { className: needsReplyDot, "aria-hidden": "true" }), _jsx("span", { children: item.subject })] }), _jsxs("span", { className: sentRowMeta, children: [typeLabel(item.type, labels), " \u00B7", " ", _jsx(DateTime, { value: item.updatedAt_epoch_milliseconds })] })] }), _jsx(Status, { variant: statusDisplay(item.status, labels).variant, children: statusDisplay(item.status, labels).label })] }) }, item.id));
|
|
383
|
+
}) }) }));
|
|
384
|
+
}
|
|
385
|
+
/* What the thread shows in time order: the description, each status change, each message. */
|
|
386
|
+
function listThreadEntries(item, labels) {
|
|
387
|
+
const entries = [
|
|
388
|
+
{
|
|
389
|
+
kind: "message",
|
|
390
|
+
id: "description",
|
|
391
|
+
side: "user",
|
|
392
|
+
at: item.createdAt_epoch_milliseconds,
|
|
393
|
+
body: item.description,
|
|
394
|
+
attachments: item.attachments,
|
|
395
|
+
},
|
|
396
|
+
...item.statusTimeline.map((event) => ({
|
|
397
|
+
kind: "line",
|
|
398
|
+
id: event.id,
|
|
399
|
+
at: event.createdAt_epoch_milliseconds,
|
|
400
|
+
text: (_jsxs(_Fragment, { children: [statusDisplay(event.status, labels).label, " \u00B7", " ", _jsx(DateTime, { value: event.createdAt_epoch_milliseconds })] })),
|
|
401
|
+
})),
|
|
402
|
+
...item.messages.map((message) => {
|
|
403
|
+
const fromReporter = message.author.role === "reporter";
|
|
404
|
+
return {
|
|
405
|
+
kind: "message",
|
|
406
|
+
id: message.id,
|
|
407
|
+
side: fromReporter ? "user" : "assistant",
|
|
408
|
+
at: message.createdAt_epoch_milliseconds,
|
|
409
|
+
body: message.body,
|
|
410
|
+
author: fromReporter ? undefined : { name: message.author.name },
|
|
411
|
+
};
|
|
412
|
+
}),
|
|
413
|
+
];
|
|
414
|
+
return entries.sort((earlier, later) => earlier.at - later.at);
|
|
415
|
+
}
|
|
416
|
+
function SentItem({ feedbackId, item, errorDetail, onReply, onWithdraw, onBack, }) {
|
|
417
|
+
const labels = useFeedbackLabels();
|
|
418
|
+
const { common } = useCiridaeLocale().labels;
|
|
419
|
+
const [draft, setDraft] = useState("");
|
|
420
|
+
const [reply, setReply] = useState({ status: "idle" });
|
|
421
|
+
const [withdraw, setWithdraw] = useState({ status: "idle" });
|
|
422
|
+
// The item the caller last opened is this one only once its load carries this id.
|
|
423
|
+
const loaded = item?.status === "loaded" && item.data.id === feedbackId ? item.data : null;
|
|
424
|
+
const entries = loaded ? listThreadEntries(loaded, labels) : [];
|
|
425
|
+
if (reply.status === "sending") {
|
|
426
|
+
entries.push({
|
|
427
|
+
kind: "message",
|
|
428
|
+
id: "sending",
|
|
429
|
+
side: "user",
|
|
430
|
+
at: reply.at,
|
|
431
|
+
body: reply.body,
|
|
432
|
+
sending: true,
|
|
433
|
+
});
|
|
434
|
+
}
|
|
435
|
+
const back = (_jsx(IconButton, { "aria-label": labels.back, variant: "ghost", size: "small", onClick: onBack, children: _jsx(ArrowLeftIcon, { className: cx(icon({ size: "small" }), directional) }) }));
|
|
436
|
+
const actions = [
|
|
437
|
+
{ label: labels.copyId, onSelect: () => void navigator.clipboard.writeText(feedbackId) },
|
|
438
|
+
];
|
|
439
|
+
if (loaded?.canWithdraw) {
|
|
440
|
+
actions.push({
|
|
441
|
+
label: labels.withdraw,
|
|
442
|
+
variant: "danger",
|
|
443
|
+
disabled: reply.status === "sending",
|
|
444
|
+
onSelect: () => void sendWithdraw(),
|
|
445
|
+
});
|
|
446
|
+
}
|
|
447
|
+
const sendReply = async (body) => {
|
|
448
|
+
setReply({ status: "sending", body, at: Date.now() });
|
|
449
|
+
try {
|
|
450
|
+
await onReply(feedbackId, body);
|
|
451
|
+
setReply({ status: "idle" });
|
|
452
|
+
}
|
|
453
|
+
catch (error) {
|
|
454
|
+
setDraft(body);
|
|
455
|
+
setReply({ status: "failed", error });
|
|
456
|
+
}
|
|
457
|
+
};
|
|
458
|
+
const sendWithdraw = async () => {
|
|
459
|
+
setWithdraw({ status: "pending" });
|
|
460
|
+
try {
|
|
461
|
+
await onWithdraw(feedbackId);
|
|
462
|
+
setWithdraw({ status: "idle" });
|
|
463
|
+
}
|
|
464
|
+
catch (error) {
|
|
465
|
+
setWithdraw({ status: "failed", error });
|
|
466
|
+
}
|
|
467
|
+
};
|
|
468
|
+
if (item?.status === "error") {
|
|
469
|
+
return (_jsxs(DrawerBody, { flush: true, children: [_jsx("div", { className: itemHeader, children: back }), _jsx("div", { className: padded, children: _jsx(FailedNotice, { title: labels.loadItemFailed, action: _jsx("button", { type: "button", onClick: item.retry, children: common.tryAgain }), children: errorDetail?.(item.error) }) })] }));
|
|
470
|
+
}
|
|
471
|
+
if (!loaded) {
|
|
472
|
+
return (_jsxs(DrawerBody, { flush: true, "aria-busy": "true", children: [_jsxs("div", { className: itemHeader, children: [back, _jsxs("span", { className: itemTitle, children: [_jsx(Skeleton, { shape: "text", style: { width: "60%" } }), _jsx(Skeleton, { shape: "text", style: { width: "30%" } })] })] }), _jsx("div", { className: padded, children: _jsxs("span", { className: placeholderLines, children: [_jsx(Skeleton, { shape: "text" }), _jsx(Skeleton, { shape: "text", style: { width: "80%" } }), _jsx(Skeleton, { shape: "text", style: { width: "50%" } })] }) })] }));
|
|
473
|
+
}
|
|
474
|
+
return (_jsxs(_Fragment, { children: [_jsxs(DrawerBody, { flush: true, children: [_jsxs("div", { className: itemHeader, children: [back, _jsxs("span", { className: itemTitle, children: [_jsx("span", { className: itemSubject, children: loaded.subject }), _jsxs("span", { className: sentRowMeta, children: [typeLabel(loaded.type, labels), " \u00B7", " ", _jsx(DateTime, { value: loaded.createdAt_epoch_milliseconds })] })] }), _jsx(Status, { className: itemStatus, variant: statusDisplay(loaded.status, labels).variant, children: statusDisplay(loaded.status, labels).label }), _jsx(Menu, { align: "end", items: actions, trigger: _jsx(IconButton, { "aria-label": labels.actions, variant: "ghost", size: "small", disabled: withdraw.status === "pending", children: withdraw.status === "pending" ? (_jsx(Spinner, { label: labels.withdrawing })) : (_jsx(DotsThreeIcon, { className: icon({ size: "small" }) })) }) })] }), _jsx(ChatThread, { entries: entries })] }), (loaded.canReply || reply.status === "failed" || withdraw.status === "failed") && (_jsxs("div", { className: itemFoot, children: [reply.status === "failed" && (_jsx(FailedNotice, { title: labels.replyFailed, children: errorDetail?.(reply.error) })), withdraw.status === "failed" && (_jsx(FailedNotice, { title: labels.withdrawFailed, children: errorDetail?.(withdraw.error) })), loaded.canReply && (_jsx(ChatComposer, { variant: "sheet", placeholder: labels.reply, ariaLabel: labels.reply, submitLabel: labels.sendReply, value: draft, onValueChange: setDraft, sendDisabled: reply.status === "sending", onSend: (body) => void sendReply(body.trim()) }))] }))] }));
|
|
475
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What a labelled field tells the control inside it: the id its `<label htmlFor>` points at, the
|
|
3
|
+
* id of the helper or error under it, and whether it is invalid. `Input`, `Textarea`, `Select` and
|
|
4
|
+
* `Combobox` read it, so a field's label, help and error reach assistive tech with no wiring.
|
|
5
|
+
*/
|
|
6
|
+
export type FieldControl = {
|
|
7
|
+
controlId: string;
|
|
8
|
+
descriptionId?: string;
|
|
9
|
+
invalid: boolean;
|
|
10
|
+
};
|
|
11
|
+
export declare const FieldControlContext: import("@types/react").Context<FieldControl | null>;
|
|
12
|
+
/** The ids and state a control takes from its field; its own props win. */
|
|
13
|
+
export declare function useFieldControl(own: {
|
|
14
|
+
id?: string;
|
|
15
|
+
"aria-describedby"?: string;
|
|
16
|
+
"aria-invalid"?: boolean | "true" | "false" | "grammar" | "spelling";
|
|
17
|
+
}): {
|
|
18
|
+
id: string | undefined;
|
|
19
|
+
"aria-describedby": string | undefined;
|
|
20
|
+
"aria-invalid": boolean | "true" | "false" | "grammar" | "spelling" | undefined;
|
|
21
|
+
};
|
|
22
|
+
/** Whether the control sits in a labelled field, so it leaves its own fallback name off. */
|
|
23
|
+
export declare function useInField(): boolean;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { createContext, useContext } from "react";
|
|
2
|
+
export const FieldControlContext = createContext(null);
|
|
3
|
+
/** The ids and state a control takes from its field; its own props win. */
|
|
4
|
+
export function useFieldControl(own) {
|
|
5
|
+
const field = useContext(FieldControlContext);
|
|
6
|
+
return {
|
|
7
|
+
id: own.id ?? field?.controlId,
|
|
8
|
+
"aria-describedby": own["aria-describedby"] ?? field?.descriptionId,
|
|
9
|
+
"aria-invalid": own["aria-invalid"] ?? (field?.invalid || undefined),
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
/** Whether the control sits in a labelled field, so it leaves its own fallback name off. */
|
|
13
|
+
export function useInField() {
|
|
14
|
+
return useContext(FieldControlContext) !== null;
|
|
15
|
+
}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { type ComponentProps, type ReactNode } from "react";
|
|
2
|
+
import { useCiridaeLocale } from "./locale.js";
|
|
3
|
+
export type FilterFieldKind = "text" | "select" | "multi" | "date" | "number";
|
|
4
|
+
export type FilterOperator = "is" | "is_not" | "is_any_of" | "is_none_of" | "contains" | "does_not_contain" | "equals" | "greater_than" | "less_than" | "between" | "before" | "after";
|
|
5
|
+
export type FilterOption = {
|
|
6
|
+
value: string;
|
|
7
|
+
label: string;
|
|
8
|
+
icon?: ReactNode;
|
|
9
|
+
count?: ReactNode;
|
|
10
|
+
};
|
|
11
|
+
/** A field a list can be filtered by. Dates are `yyyy-mm-dd` strings. */
|
|
12
|
+
export type FilterField = {
|
|
13
|
+
key: string;
|
|
14
|
+
label: string;
|
|
15
|
+
icon?: ReactNode;
|
|
16
|
+
kind: FilterFieldKind;
|
|
17
|
+
/** The values to pick from; a `number` or `date` field with options picks one of them. */
|
|
18
|
+
options?: readonly FilterOption[];
|
|
19
|
+
/** The operators the builder offers, the first the default; each kind has its own by default. */
|
|
20
|
+
operators?: readonly FilterOperator[];
|
|
21
|
+
/** The heading the builder's field list groups this field under. */
|
|
22
|
+
group?: string;
|
|
23
|
+
};
|
|
24
|
+
/** A filter set on a field. An empty `values` sets nothing. */
|
|
25
|
+
export type FilterValue = {
|
|
26
|
+
field: string;
|
|
27
|
+
operator: FilterOperator;
|
|
28
|
+
values: readonly string[];
|
|
29
|
+
};
|
|
30
|
+
export declare const defaultFilterOperators: Record<FilterFieldKind, readonly FilterOperator[]>;
|
|
31
|
+
export declare function operatorsOf(field: FilterField): readonly FilterOperator[];
|
|
32
|
+
/** `filters` with `filter` in its field's place, or without that field when it sets nothing. */
|
|
33
|
+
export declare function replaceFilter(filters: readonly FilterValue[], filter: FilterValue): FilterValue[];
|
|
34
|
+
/**
|
|
35
|
+
* Whether one value passes a filter: a string or number, a list of them (any may match), or a
|
|
36
|
+
* `yyyy-mm-dd` date. A filter without values passes everything.
|
|
37
|
+
*/
|
|
38
|
+
export declare function matchesFilter(value: string | number | readonly (string | number)[] | null | undefined, filter: FilterValue): boolean;
|
|
39
|
+
/** How a filter reads on its chip: the operator, then its values by their labels. */
|
|
40
|
+
export declare function describeFilter(field: FilterField, filter: FilterValue, locale: Pick<ReturnType<typeof useCiridaeLocale>, "labels" | "formatDate">): {
|
|
41
|
+
operator: string;
|
|
42
|
+
values: string;
|
|
43
|
+
};
|
|
44
|
+
/** One set filter: the field and operator muted, its values in full; the text reopens it. */
|
|
45
|
+
export declare function FilterChip({ label, icon: fieldIcon, operator, values, onEdit, onRemove, className, ...props }: Omit<ComponentProps<"span">, "children"> & {
|
|
46
|
+
label: string;
|
|
47
|
+
icon?: ReactNode;
|
|
48
|
+
operator: ReactNode;
|
|
49
|
+
values: ReactNode;
|
|
50
|
+
onEdit?: () => void;
|
|
51
|
+
onRemove: () => void;
|
|
52
|
+
}): import("@types/react").JSX.Element;
|
|
53
|
+
/**
|
|
54
|
+
* The set filters as chips, Clear all, and the Add filter builder: pick a field, then its operator
|
|
55
|
+
* and values, which apply as they are picked. Pressing a chip reopens the builder on its field.
|
|
56
|
+
* `children` sit after Add filter, such as the list's search. Controlled with `value` /
|
|
57
|
+
* `onValueChange`, and the builder's `open` / `onOpenChange` when the page opens it too.
|
|
58
|
+
*/
|
|
59
|
+
export declare function FilterBar({ fields, value, defaultValue, onValueChange, open: ownOpen, onOpenChange, children, className, ...props }: Omit<ComponentProps<"div">, "defaultValue"> & {
|
|
60
|
+
fields: readonly FilterField[];
|
|
61
|
+
value?: readonly FilterValue[];
|
|
62
|
+
defaultValue?: readonly FilterValue[];
|
|
63
|
+
onValueChange?: (value: FilterValue[]) => void;
|
|
64
|
+
open?: boolean;
|
|
65
|
+
onOpenChange?: (open: boolean) => void;
|
|
66
|
+
}): import("@types/react").JSX.Element;
|
|
67
|
+
/**
|
|
68
|
+
* One field's operator and values, reporting every change so the list follows along. `onBack`
|
|
69
|
+
* adds the way back to the builder's field list; without it the field is fixed, as under a
|
|
70
|
+
* column head.
|
|
71
|
+
*/
|
|
72
|
+
export declare function FilterValueEditor({ field, value, onChange, onBack, }: {
|
|
73
|
+
field: FilterField;
|
|
74
|
+
value: FilterValue | undefined;
|
|
75
|
+
onChange: (filter: FilterValue) => void;
|
|
76
|
+
onBack?: () => void;
|
|
77
|
+
}): import("@types/react").JSX.Element;
|