@tfn-design/design-system 0.3.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/accordion/accordion.d.ts +1 -1
- package/dist/accordion/accordion.js +1 -1
- package/dist/accordion/web/ds-accordion.js +5 -4
- package/dist/account-password-field/account-password-field.js +1 -1
- package/dist/account-switcher/account-switcher.d.ts +11 -4
- package/dist/account-switcher/account-switcher.js +2 -1
- package/dist/account-switcher/web/ds-account-switcher.js +12 -4
- package/dist/ai-attachment/ai-attachment.d.ts +1 -1
- package/dist/ai-attachment/ai-attachment.js +1 -1
- package/dist/ai-attachment/web/ds-ai-attachment.js +1 -1
- package/dist/ai-branch-switcher/web/ds-ai-branch-switcher.js +2 -2
- package/dist/ai-composer/ai-composer.d.ts +1 -1
- package/dist/ai-composer/ai-composer.js +1 -1
- package/dist/ai-composer/native/ds-ai-composer.js +4 -2
- package/dist/ai-composer/web/ds-ai-composer.js +2 -3
- package/dist/ai-confirmation/ai-confirmation.d.ts +19 -3
- package/dist/ai-confirmation/ai-confirmation.js +18 -3
- package/dist/ai-confirmation/native/ds-ai-confirmation.js +18 -13
- package/dist/ai-confirmation/web/ds-ai-confirmation.d.ts +1 -1
- package/dist/ai-confirmation/web/ds-ai-confirmation.js +22 -11
- package/dist/ai-context-scope/ai-context-scope.d.ts +10 -2
- package/dist/ai-context-scope/ai-context-scope.js +11 -2
- package/dist/ai-context-scope/native/ds-ai-context-scope.js +4 -3
- package/dist/ai-context-scope/web/ds-ai-context-scope.js +19 -5
- package/dist/ai-conversation-list/ai-conversation-list.d.ts +16 -0
- package/dist/ai-conversation-list/ai-conversation-list.js +8 -0
- package/dist/ai-conversation-list/web/ds-ai-conversation-list.d.ts +10 -6
- package/dist/ai-conversation-list/web/ds-ai-conversation-list.js +89 -47
- package/dist/ai-diff/ai-diff.d.ts +13 -1
- package/dist/ai-diff/ai-diff.js +12 -1
- package/dist/ai-diff/native/ds-ai-diff.d.ts +1 -1
- package/dist/ai-diff/native/ds-ai-diff.js +4 -6
- package/dist/ai-diff/web/ds-ai-diff.d.ts +0 -4
- package/dist/ai-diff/web/ds-ai-diff.js +16 -9
- package/dist/ai-draft-panel/ai-draft-panel.d.ts +2 -0
- package/dist/ai-draft-panel/ai-draft-panel.js +5 -0
- package/dist/ai-draft-panel/web/ds-ai-draft-panel.d.ts +3 -1
- package/dist/ai-draft-panel/web/ds-ai-draft-panel.js +4 -4
- package/dist/ai-empty-state/native/ds-ai-empty-state.js +2 -2
- package/dist/ai-empty-state/web/ds-ai-empty-state.js +3 -1
- package/dist/ai-error-state/ai-error-state.d.ts +2 -2
- package/dist/ai-error-state/ai-error-state.js +2 -2
- package/dist/ai-error-state/native/ds-ai-error-state.d.ts +5 -1
- package/dist/ai-error-state/native/ds-ai-error-state.js +2 -1
- package/dist/ai-error-state/web/ds-ai-error-state.d.ts +5 -1
- package/dist/ai-error-state/web/ds-ai-error-state.js +3 -2
- package/dist/ai-label/native/ds-ai-label.js +2 -1
- package/dist/ai-label/web/ds-ai-label.js +1 -1
- package/dist/ai-message/ai-message.d.ts +1 -1
- package/dist/ai-message/ai-message.js +1 -1
- package/dist/ai-message/native/ds-ai-message.js +4 -3
- package/dist/ai-message/web/ds-ai-message-markdown.js +3 -3
- package/dist/ai-message/web/ds-ai-message.js +4 -3
- package/dist/ai-message-actions/ai-message-actions.d.ts +1 -1
- package/dist/ai-message-actions/ai-message-actions.js +1 -1
- package/dist/ai-message-actions/native/ds-ai-message-actions.js +1 -1
- package/dist/ai-message-actions/web/ds-ai-message-actions.js +1 -1
- package/dist/ai-plan/ai-plan.d.ts +1 -1
- package/dist/ai-plan/ai-plan.js +1 -1
- package/dist/ai-plan/web/ds-ai-plan.js +2 -2
- package/dist/ai-side-nav/web/ds-ai-side-nav.js +4 -3
- package/dist/ai-summary-card/native/ds-ai-summary-card.js +2 -1
- package/dist/ai-summary-card/web/ds-ai-summary-card.js +2 -1
- package/dist/ai-thread/web/ds-ai-thread.js +1 -1
- package/dist/ai-tool-call/ai-tool-call.d.ts +1 -1
- package/dist/ai-tool-call/ai-tool-call.js +1 -1
- package/dist/ai-tool-call/native/ds-ai-tool-call.js +3 -2
- package/dist/ai-tool-call/web/ds-ai-tool-call.js +4 -3
- package/dist/alert/native/ds-alert.js +4 -4
- package/dist/alert/web/ds-alert.js +5 -5
- package/dist/ambient-gradient/ambient-gradient.d.ts +1 -1
- package/dist/amount/amount.d.ts +1 -1
- package/dist/amount/amount.js +3 -2
- package/dist/amount/native/ds-amount.js +1 -1
- package/dist/amount/web/ds-amount.js +1 -1
- package/dist/amount-cell/amount-cell.d.ts +5 -2
- package/dist/amount-cell/web/ds-amount-cell.d.ts +1 -1
- package/dist/amount-cell/web/ds-amount-cell.js +7 -1
- package/dist/amount-entry/amount-entry.d.ts +28 -2
- package/dist/amount-entry/amount-entry.js +19 -12
- package/dist/amount-entry/native/ds-amount-entry.d.ts +1 -1
- package/dist/amount-entry/native/ds-amount-entry.js +5 -4
- package/dist/amount-entry/web/ds-amount-entry.d.ts +1 -1
- package/dist/amount-entry/web/ds-amount-entry.js +5 -4
- package/dist/app-shell/app-shell.d.ts +2 -0
- package/dist/app-shell/web/ds-app-shell.js +26 -3
- package/dist/approval-chain/approval-chain.d.ts +6 -2
- package/dist/approval-chain/approval-chain.js +4 -4
- package/dist/approval-chain/native/ds-approval-chain.js +16 -9
- package/dist/approval-chain/web/ds-approval-chain.d.ts +7 -1
- package/dist/approval-chain/web/ds-approval-chain.js +12 -11
- package/dist/auth-shell/web/ds-auth-shell.d.ts +5 -1
- package/dist/auth-shell/web/ds-auth-shell.js +5 -2
- package/dist/balance-header/balance-header.d.ts +8 -4
- package/dist/balance-header/native/ds-balance-header.d.ts +3 -3
- package/dist/balance-header/native/ds-balance-header.js +11 -4
- package/dist/balance-header/web/ds-balance-header.d.ts +1 -1
- package/dist/balance-header/web/ds-balance-header.js +7 -4
- package/dist/bar-chart/bar-chart.d.ts +46 -5
- package/dist/bar-chart/bar-chart.js +64 -6
- package/dist/bar-chart/web/ds-bar-chart.d.ts +21 -4
- package/dist/bar-chart/web/ds-bar-chart.js +121 -50
- package/dist/bottom-nav/bottom-nav.d.ts +8 -3
- package/dist/bottom-nav/bottom-nav.js +2 -2
- package/dist/bottom-nav/web/ds-bottom-nav.js +2 -2
- package/dist/box-plot/box-plot.d.ts +150 -0
- package/dist/box-plot/box-plot.js +124 -0
- package/dist/box-plot/web/ds-box-plot.d.ts +8 -0
- package/dist/box-plot/web/ds-box-plot.js +57 -0
- package/dist/brand-lockup/native/ds-brand-lockup.js +1 -1
- package/dist/brand-provider/brand-provider.d.ts +29 -0
- package/dist/brand-provider/brand-provider.js +9 -0
- package/dist/brand-provider/native/ds-brand-provider.d.ts +11 -0
- package/dist/brand-provider/native/ds-brand-provider.js +18 -0
- package/dist/brand-provider/web/ds-brand-provider.d.ts +10 -0
- package/dist/brand-provider/web/ds-brand-provider.js +20 -0
- package/dist/bullet-chart/bullet-chart.d.ts +12 -7
- package/dist/bullet-chart/bullet-chart.js +5 -4
- package/dist/bullet-chart/web/ds-bullet-chart.d.ts +1 -1
- package/dist/bullet-chart/web/ds-bullet-chart.js +9 -4
- package/dist/button/button.d.ts +1 -1
- package/dist/button/native/ds-button.js +2 -2
- package/dist/button/web/ds-button.js +1 -1
- package/dist/button-group/button-group.d.ts +1 -1
- package/dist/button-group/web/ds-button-group.d.ts +2 -2
- package/dist/calendar/calendar.d.ts +13 -2
- package/dist/calendar/calendar.js +4 -3
- package/dist/calendar/web/ds-calendar.d.ts +1 -1
- package/dist/calendar/web/ds-calendar.js +6 -5
- package/dist/card-carousel/native/ds-card-carousel.js +1 -1
- package/dist/card-carousel/web/ds-card-carousel.js +2 -2
- package/dist/chart/chart.d.ts +180 -64
- package/dist/chart/chart.js +367 -118
- package/dist/chart/web/ds-chart.d.ts +17 -7
- package/dist/chart/web/ds-chart.js +85 -108
- package/dist/check-option/check-option.d.ts +1 -1
- package/dist/check-option/check-option.js +1 -1
- package/dist/check-option/web/ds-check-option.d.ts +6 -1
- package/dist/check-option/web/ds-check-option.js +10 -6
- package/dist/checkbox/checkbox.d.ts +2 -2
- package/dist/checkbox/checkbox.js +2 -2
- package/dist/checkbox/native/ds-checkbox.js +1 -1
- package/dist/checkbox/web/checkbox-mark.js +1 -1
- package/dist/checkbox/web/ds-checkbox.d.ts +2 -2
- package/dist/checkbox/web/ds-checkbox.js +17 -6
- package/dist/chip/chip.d.ts +11 -11
- package/dist/chip/chip.js +5 -3
- package/dist/chip/native/ds-chip.js +1 -1
- package/dist/chip/web/ds-chip.js +6 -6
- package/dist/code-block/web/ds-code-block.js +3 -3
- package/dist/column-picker/web/ds-column-picker.js +2 -1
- package/dist/combobox/combobox.d.ts +2 -2
- package/dist/combobox/web/ds-combobox.js +4 -2
- package/dist/command-palette/command-palette.d.ts +4 -0
- package/dist/comment-thread/comment-thread.d.ts +2 -2
- package/dist/comment-thread/comment-thread.js +2 -2
- package/dist/comment-thread/native/ds-comment-thread.js +10 -9
- package/dist/comment-thread/web/ds-comment-thread.js +11 -10
- package/dist/condition-builder/condition-builder.d.ts +96 -4
- package/dist/condition-builder/condition-builder.js +68 -28
- package/dist/condition-builder/web/ds-condition-builder.d.ts +4 -2
- package/dist/condition-builder/web/ds-condition-builder.js +97 -57
- package/dist/context-switcher/context-switcher.d.ts +10 -1
- package/dist/context-switcher/context-switcher.js +5 -2
- package/dist/context-switcher/web/ds-context-switcher.d.ts +1 -1
- package/dist/context-switcher/web/ds-context-switcher.js +4 -3
- package/dist/coordinate-field/coordinate-field.d.ts +46 -5
- package/dist/coordinate-field/coordinate-field.js +35 -18
- package/dist/coordinate-field/native/ds-coordinate-field.d.ts +1 -1
- package/dist/coordinate-field/native/ds-coordinate-field.js +9 -8
- package/dist/coordinate-field/web/ds-coordinate-field.d.ts +1 -1
- package/dist/coordinate-field/web/ds-coordinate-field.js +10 -9
- package/dist/copy-field/copy-field.d.ts +23 -9
- package/dist/copy-field/copy-field.js +11 -6
- package/dist/copy-field/web/ds-copy-field.d.ts +1 -1
- package/dist/copy-field/web/ds-copy-field.js +6 -5
- package/dist/copy.d.ts +8 -0
- package/dist/copy.js +7 -0
- package/dist/count-badge/web/ds-count-badge.js +1 -1
- package/dist/countdown/native/ds-countdown.js +1 -1
- package/dist/countdown/web/ds-countdown.js +1 -1
- package/dist/dashboard-shell/dashboard-shell.d.ts +4 -2
- package/dist/data-table/web/data-table-theme.css +340 -52
- package/dist/data-table/web/ds-data-table.d.ts +43 -1
- package/dist/data-table/web/ds-data-table.js +165 -17
- package/dist/date-field/web/ds-date-field.d.ts +1 -1
- package/dist/date-field/web/ds-date-field.js +6 -5
- package/dist/date-input/date-input.d.ts +26 -5
- package/dist/date-input/date-input.js +34 -2
- package/dist/date-input/web/ds-date-input.js +13 -4
- package/dist/date-picker/date-picker.d.ts +38 -67
- package/dist/date-picker/date-picker.js +26 -60
- package/dist/date-picker/web/ds-date-picker.d.ts +13 -6
- package/dist/date-picker/web/ds-date-picker.js +41 -10
- package/dist/date-range-picker/web/ds-date-range-picker.d.ts +10 -4
- package/dist/date-range-picker/web/ds-date-range-picker.js +8 -5
- package/dist/day-picker/day-picker.d.ts +1 -1
- package/dist/day-picker/web/ds-day-picker.js +1 -1
- package/dist/delta/delta.d.ts +15 -1
- package/dist/delta/delta.js +20 -0
- package/dist/delta/native/ds-delta.d.ts +5 -2
- package/dist/delta/native/ds-delta.js +4 -3
- package/dist/delta/web/ds-delta.d.ts +5 -2
- package/dist/delta/web/ds-delta.js +4 -3
- package/dist/description-list/description-list.d.ts +4 -2
- package/dist/description-list/native/ds-description-list.d.ts +2 -2
- package/dist/description-list/native/ds-description-list.js +49 -27
- package/dist/description-list/web/ds-description-list.d.ts +2 -2
- package/dist/description-list/web/ds-description-list.js +40 -17
- package/dist/dialog/dialog.d.ts +12 -1
- package/dist/dialog/web/ds-dialog.d.ts +1 -1
- package/dist/dialog/web/ds-dialog.js +5 -3
- package/dist/diverging-bar-chart/diverging-bar-chart.d.ts +2 -1
- package/dist/diverging-bar-chart/diverging-bar-chart.js +2 -1
- package/dist/diverging-bar-chart/web/ds-diverging-bar-chart.d.ts +1 -1
- package/dist/diverging-bar-chart/web/ds-diverging-bar-chart.js +28 -5
- package/dist/donut-chart/donut-chart.d.ts +7 -1
- package/dist/donut-chart/donut-chart.js +4 -0
- package/dist/donut-chart/web/ds-donut-chart.d.ts +4 -1
- package/dist/donut-chart/web/ds-donut-chart.js +43 -24
- package/dist/drawer/drawer.d.ts +42 -5
- package/dist/drawer/drawer.js +10 -4
- package/dist/drawer/native/ds-drawer.d.ts +1 -1
- package/dist/drawer/native/ds-drawer.js +17 -7
- package/dist/drawer/web/ds-drawer.d.ts +1 -1
- package/dist/drawer/web/ds-drawer.js +32 -17
- package/dist/dropdown-menu/dropdown-menu.d.ts +10 -5
- package/dist/dropdown-menu/dropdown-menu.js +13 -4
- package/dist/dropdown-menu/web/ds-dropdown-menu-surface.d.ts +4 -2
- package/dist/dropdown-menu/web/ds-dropdown-menu-surface.js +6 -6
- package/dist/dropdown-menu/web/ds-dropdown-menu.d.ts +5 -2
- package/dist/dropdown-menu/web/ds-dropdown-menu.js +2 -2
- package/dist/dumbbell-chart/dumbbell-chart.d.ts +10 -9
- package/dist/dumbbell-chart/dumbbell-chart.js +18 -4
- package/dist/dumbbell-chart/web/ds-dumbbell-chart.d.ts +4 -1
- package/dist/dumbbell-chart/web/ds-dumbbell-chart.js +13 -3
- package/dist/editable-row/editable-row.d.ts +5 -1
- package/dist/editable-row/editable-row.js +7 -1
- package/dist/editable-row/web/ds-editable-row.js +7 -5
- package/dist/empty-state/empty-state.d.ts +39 -0
- package/dist/empty-state/empty-state.js +21 -0
- package/dist/empty-state/web/ds-empty-state.d.ts +19 -8
- package/dist/empty-state/web/ds-empty-state.js +15 -3
- package/dist/environment-banner/environment-banner.d.ts +1 -1
- package/dist/environment-banner/environment-banner.js +1 -1
- package/dist/environment-banner/web/ds-environment-banner.js +3 -3
- package/dist/evaluation-trace/evaluation-trace.d.ts +1 -1
- package/dist/evaluation-trace/evaluation-trace.js +1 -1
- package/dist/evaluation-trace/web/ds-evaluation-trace.js +1 -1
- package/dist/event-row/web/ds-event-row.d.ts +1 -1
- package/dist/event-row/web/ds-event-row.js +2 -1
- package/dist/facet-button/facet-button.d.ts +9 -1
- package/dist/facet-button/facet-button.js +2 -2
- package/dist/facet-button/web/ds-facet-button.d.ts +1 -1
- package/dist/facet-button/web/ds-facet-button.js +9 -5
- package/dist/facet-menu/facet-menu.d.ts +1 -1
- package/dist/facet-menu/facet-menu.js +2 -1
- package/dist/facet-menu/web/ds-facet-menu.js +1 -1
- package/dist/fact/native/ds-fact.d.ts +4 -1
- package/dist/file-dropzone/file-dropzone.d.ts +54 -5
- package/dist/file-dropzone/file-dropzone.js +38 -20
- package/dist/file-dropzone/web/ds-file-dropzone.d.ts +1 -1
- package/dist/file-dropzone/web/ds-file-dropzone.js +16 -15
- package/dist/file-field/file-field.d.ts +26 -5
- package/dist/file-field/file-field.js +18 -8
- package/dist/file-field/web/ds-file-field.d.ts +5 -2
- package/dist/file-field/web/ds-file-field.js +6 -5
- package/dist/file-import/file-import.d.ts +50 -4
- package/dist/file-import/file-import.js +30 -11
- package/dist/file-import/web/ds-file-import.d.ts +7 -3
- package/dist/file-import/web/ds-file-import.js +11 -10
- package/dist/file-upload/file-upload.d.ts +64 -15
- package/dist/file-upload/file-upload.js +44 -30
- package/dist/file-upload/web/ds-file-upload.d.ts +11 -2
- package/dist/file-upload/web/ds-file-upload.js +17 -12
- package/dist/filter-bar/web/ds-filter-bar.js +1 -1
- package/dist/filter-button/filter-button.d.ts +5 -4
- package/dist/filter-button/filter-button.js +1 -1
- package/dist/filter-chip/web/ds-filter-chip.js +2 -2
- package/dist/filter-popover/web/ds-filter-popover.js +2 -1
- package/dist/form-field-group/form-field-group.d.ts +7 -2
- package/dist/form-field-group/form-field-group.js +2 -0
- package/dist/form-field-group/web/ds-form-field-group.js +2 -1
- package/dist/form-section/form-section.d.ts +4 -2
- package/dist/form-section/form-section.js +1 -1
- package/dist/funnel/funnel.d.ts +2 -1
- package/dist/funnel/web/ds-funnel.d.ts +1 -1
- package/dist/funnel/web/ds-funnel.js +22 -12
- package/dist/gauge/gauge.d.ts +6 -1
- package/dist/gauge/gauge.js +9 -1
- package/dist/gauge/web/ds-gauge.d.ts +8 -3
- package/dist/gauge/web/ds-gauge.js +26 -15
- package/dist/geo/geo.d.ts +15 -0
- package/dist/geo/geo.js +112 -0
- package/dist/geofence-editor/geofence-editor.d.ts +14 -5
- package/dist/geofence-editor/geofence-editor.js +32 -7
- package/dist/geofence-editor/web/ds-geofence-editor.d.ts +18 -3
- package/dist/geofence-editor/web/ds-geofence-editor.js +28 -13
- package/dist/group-header/web/ds-group-header.d.ts +1 -1
- package/dist/heatmap/heatmap-calendar.d.ts +95 -0
- package/dist/heatmap/heatmap-calendar.js +130 -0
- package/dist/heatmap/heatmap.d.ts +35 -8
- package/dist/heatmap/heatmap.js +61 -7
- package/dist/heatmap/web/ds-heatmap-calendar.d.ts +22 -0
- package/dist/heatmap/web/ds-heatmap-calendar.js +33 -0
- package/dist/heatmap/web/ds-heatmap.d.ts +21 -1
- package/dist/heatmap/web/ds-heatmap.js +59 -31
- package/dist/helper-text/native/ds-helper-text.js +2 -2
- package/dist/helper-text/web/ds-helper-text.js +2 -2
- package/dist/histogram/histogram.d.ts +2 -3
- package/dist/histogram/web/ds-histogram.d.ts +1 -1
- package/dist/histogram/web/ds-histogram.js +8 -2
- package/dist/icon/icon.d.ts +11 -0
- package/dist/icon/icon.js +52 -0
- package/dist/icon/native/ds-icon-provider.d.ts +6 -1
- package/dist/icon/native/ds-icon-provider.js +4 -2
- package/dist/icon/native/icon-direction.d.ts +10 -0
- package/dist/icon/native/icon-direction.js +6 -0
- package/dist/icon/native/use-icon-size.d.ts +6 -0
- package/dist/icon/native/use-icon-size.js +12 -0
- package/dist/icon/web/ds-icon-provider.d.ts +3 -1
- package/dist/icon/web/ds-icon-provider.js +1 -0
- package/dist/icon/web/icon-direction.css +45 -0
- package/dist/icon-button/icon-button.d.ts +6 -0
- package/dist/icon-button/native/ds-icon-button.d.ts +1 -1
- package/dist/icon-button/native/ds-icon-button.js +2 -1
- package/dist/icon-button/web/ds-icon-button.d.ts +1 -1
- package/dist/icon-button/web/ds-icon-button.js +8 -5
- package/dist/icon-frame/icon-frame.d.ts +2 -2
- package/dist/icon-frame/native/ds-icon-frame.js +3 -3
- package/dist/icon-frame/web/ds-icon-frame.js +3 -3
- package/dist/ident/ident.d.ts +2 -0
- package/dist/ident/ident.js +5 -0
- package/dist/ident/native/ds-ident.d.ts +30 -0
- package/dist/ident/native/ds-ident.js +13 -0
- package/dist/index.d.ts +88 -65
- package/dist/index.js +47 -36
- package/dist/inline-edit/inline-edit.d.ts +34 -4
- package/dist/inline-edit/inline-edit.js +19 -7
- package/dist/inline-edit/web/ds-inline-edit.d.ts +1 -1
- package/dist/inline-edit/web/ds-inline-edit.js +13 -8
- package/dist/input/input.d.ts +18 -5
- package/dist/input/input.js +17 -13
- package/dist/input/native/ds-input.js +1 -1
- package/dist/input/web/ds-input.d.ts +7 -1
- package/dist/input/web/ds-input.js +11 -9
- package/dist/interaction.d.ts +7 -5
- package/dist/interaction.js +1 -1
- package/dist/json-viewer/web/ds-json-viewer.js +1 -1
- package/dist/key-value-editor/key-value-editor.d.ts +57 -3
- package/dist/key-value-editor/key-value-editor.js +56 -26
- package/dist/key-value-editor/web/ds-key-value-editor.d.ts +1 -1
- package/dist/key-value-editor/web/ds-key-value-editor.js +15 -16
- package/dist/keypad/keypad.d.ts +21 -11
- package/dist/keypad/keypad.js +16 -10
- package/dist/keypad/native/ds-keypad.d.ts +1 -1
- package/dist/keypad/native/ds-keypad.js +10 -8
- package/dist/keypad/web/ds-keypad.d.ts +1 -1
- package/dist/keypad/web/ds-keypad.js +5 -4
- package/dist/label-picker/label-picker.d.ts +34 -4
- package/dist/label-picker/label-picker.js +28 -17
- package/dist/label-picker/native/ds-label-picker.d.ts +1 -1
- package/dist/label-picker/native/ds-label-picker.js +11 -10
- package/dist/label-picker/web/ds-label-picker.d.ts +1 -1
- package/dist/label-picker/web/ds-label-picker.js +11 -10
- package/dist/labeled-field/labeled-field.d.ts +17 -2
- package/dist/labeled-field/labeled-field.js +7 -5
- package/dist/labeled-field/web/ds-labeled-field.d.ts +1 -1
- package/dist/labeled-field/web/ds-labeled-field.js +6 -2
- package/dist/leaderboard/leaderboard.d.ts +4 -3
- package/dist/leaderboard/leaderboard.js +4 -1
- package/dist/leaderboard/web/ds-leaderboard.d.ts +1 -1
- package/dist/leaderboard/web/ds-leaderboard.js +8 -3
- package/dist/legend/legend.d.ts +4 -0
- package/dist/legend/legend.js +1 -0
- package/dist/legend/web/ds-legend.js +18 -11
- package/dist/lib/chart-context.d.ts +23 -3
- package/dist/lib/chart-context.js +9 -3
- package/dist/lib/chart-finish.d.ts +13 -6
- package/dist/lib/chart-finish.js +8 -2
- package/dist/lib/chart-library.d.ts +1 -1
- package/dist/lib/chart-series.d.ts +7 -4
- package/dist/lib/chart-series.js +2 -4
- package/dist/lib/chart-ticks.d.ts +11 -0
- package/dist/lib/chart-ticks.js +11 -0
- package/dist/lib/chart-value.d.ts +1 -1
- package/dist/lib/chart-value.js +3 -1
- package/dist/lib/cn.d.ts +1 -0
- package/dist/lib/cn.js +7 -2
- package/dist/lib/time-of-day.d.ts +21 -0
- package/dist/lib/time-of-day.js +37 -0
- package/dist/lib/web/chart-finish.d.ts +1 -1
- package/dist/lib/web/chart-finish.js +1 -1
- package/dist/lib/web/density.d.ts +1 -0
- package/dist/lib/web/density.js +7 -0
- package/dist/lib/web/focus-habits.js +20 -8
- package/dist/lib/web/focus-trap.d.ts +10 -0
- package/dist/lib/web/focus-trap.js +4 -1
- package/dist/lib/web/live-announcer.d.ts +2 -0
- package/dist/lib/web/live-announcer.js +2 -1
- package/dist/lib/web/touch-target.d.ts +4 -4
- package/dist/lib/web/touch-target.js +3 -3
- package/dist/lib/web/use-anchored-surface.js +3 -2
- package/dist/lib/web/use-overlay.js +7 -1
- package/dist/list-page/list-page.d.ts +2 -1
- package/dist/list-page/web/ds-list-page.js +1 -5
- package/dist/list-row/list-row.d.ts +6 -6
- package/dist/list-row/list-row.js +4 -5
- package/dist/list-row/native/ds-list-row.js +7 -2
- package/dist/list-row/web/ds-list-row-group.d.ts +6 -2
- package/dist/list-row/web/ds-list-row-group.js +4 -2
- package/dist/list-row/web/ds-list-row.js +9 -9
- package/dist/loading-screen/native/ds-loading-screen.js +1 -1
- package/dist/log-viewer/log-viewer.d.ts +2 -2
- package/dist/log-viewer/log-viewer.js +1 -1
- package/dist/log-viewer/web/ds-log-viewer.js +6 -5
- package/dist/map/map.d.ts +5 -0
- package/dist/map/map.js +2 -0
- package/dist/map/web/ds-map.js +9 -3
- package/dist/map-banner/native/ds-map-banner.js +3 -3
- package/dist/map-banner/web/ds-map-banner.js +4 -4
- package/dist/map-controls/map-controls.d.ts +3 -5
- package/dist/map-controls/map-controls.js +4 -4
- package/dist/map-controls/native/ds-map-controls.js +1 -1
- package/dist/map-controls/web/ds-map-controls.js +1 -1
- package/dist/map-draw-toolbar/web/ds-map-draw-toolbar.js +3 -2
- package/dist/map-heatmap-layer/map-heatmap-layer.d.ts +1 -1
- package/dist/map-layers/map-layers.d.ts +1 -1
- package/dist/map-layers/map-layers.js +1 -1
- package/dist/map-layers/native/ds-map-layers.d.ts +4 -2
- package/dist/map-layers/native/ds-map-layers.js +5 -4
- package/dist/map-layers/web/ds-map-layers.js +4 -4
- package/dist/map-list/map-list.d.ts +2 -1
- package/dist/map-list/web/ds-map-list.d.ts +1 -1
- package/dist/map-list/web/ds-map-list.js +19 -16
- package/dist/map-marker/map-marker.d.ts +5 -0
- package/dist/map-marker/map-marker.js +6 -0
- package/dist/map-marker/web/ds-map-marker.d.ts +12 -3
- package/dist/map-marker/web/ds-map-marker.js +18 -8
- package/dist/map-search/map-search.d.ts +9 -0
- package/dist/map-search/map-search.js +13 -0
- package/dist/map-search/native/ds-map-search.d.ts +10 -3
- package/dist/map-search/native/ds-map-search.js +32 -19
- package/dist/map-search/web/ds-map-search.d.ts +8 -3
- package/dist/map-search/web/ds-map-search.js +37 -27
- package/dist/map-search-area/native/ds-map-search-area.js +2 -1
- package/dist/map-search-area/web/ds-map-search-area.js +2 -1
- package/dist/map-sheet/native/ds-map-sheet.js +1 -1
- package/dist/map-sheet/web/ds-map-sheet.js +2 -2
- package/dist/map-summary/map-summary.d.ts +2 -1
- package/dist/map-summary/web/ds-map-summary.d.ts +2 -2
- package/dist/map-summary/web/ds-map-summary.js +18 -9
- package/dist/mention-input/mention-input.d.ts +23 -2
- package/dist/mention-input/mention-input.js +15 -8
- package/dist/mention-input/native/ds-mention-input.d.ts +1 -1
- package/dist/mention-input/native/ds-mention-input.js +6 -9
- package/dist/mention-input/web/ds-mention-input.d.ts +1 -1
- package/dist/mention-input/web/ds-mention-input.js +6 -5
- package/dist/menu-button/web/ds-menu-button.d.ts +2 -2
- package/dist/menu-button/web/ds-menu-button.js +9 -4
- package/dist/meter/meter.d.ts +5 -2
- package/dist/meter/meter.js +2 -1
- package/dist/meter/native/ds-meter.d.ts +2 -2
- package/dist/meter/native/ds-meter.js +13 -3
- package/dist/meter/web/ds-meter.d.ts +1 -1
- package/dist/meter/web/ds-meter.js +16 -9
- package/dist/metric/metric.d.ts +13 -9
- package/dist/metric/native/ds-metric.d.ts +1 -1
- package/dist/metric/native/ds-metric.js +26 -16
- package/dist/metric/web/ds-metric.d.ts +1 -1
- package/dist/metric/web/ds-metric.js +21 -5
- package/dist/metric-card/metric-card.d.ts +4 -3
- package/dist/metric-card/web/ds-metric-card.d.ts +1 -1
- package/dist/metric-card/web/ds-metric-card.js +4 -2
- package/dist/month-picker/web/ds-month-picker.js +2 -1
- package/dist/month-strip/web/ds-month-strip.js +1 -1
- package/dist/motion.d.ts +18 -3
- package/dist/motion.js +3 -1
- package/dist/multi-select/multi-select.d.ts +39 -9
- package/dist/multi-select/multi-select.js +35 -22
- package/dist/multi-select/web/ds-multi-select.d.ts +1 -1
- package/dist/multi-select/web/ds-multi-select.js +42 -24
- package/dist/native.d.ts +12 -0
- package/dist/native.js +8 -0
- package/dist/notification-list/native/ds-notification-list.d.ts +1 -1
- package/dist/notification-list/native/ds-notification-list.js +14 -7
- package/dist/notification-list/notification-list.d.ts +2 -1
- package/dist/notification-list/web/ds-notification-list.d.ts +1 -1
- package/dist/notification-list/web/ds-notification-list.js +10 -4
- package/dist/number-field/native/ds-number-field.js +1 -1
- package/dist/number-field/web/ds-number-field.js +1 -1
- package/dist/otp/native/ds-otp-field.js +3 -21
- package/dist/otp/native/ds-otp.js +3 -3
- package/dist/otp/otp.d.ts +3 -3
- package/dist/otp/web/ds-otp.js +3 -3
- package/dist/overflow-menu/web/ds-overflow-menu.js +7 -2
- package/dist/page-head/web/ds-page-head.js +2 -2
- package/dist/panel/native/ds-panel.js +1 -1
- package/dist/panel/panel.d.ts +1 -1
- package/dist/panel/web/ds-panel.d.ts +3 -1
- package/dist/panel/web/ds-panel.js +3 -2
- package/dist/password-feedback/web/ds-password-feedback.d.ts +1 -1
- package/dist/password-feedback/web/ds-password-feedback.js +3 -3
- package/dist/password-input/web/ds-password-input.d.ts +7 -2
- package/dist/password-input/web/ds-password-input.js +28 -3
- package/dist/password-requirements/password-requirements.d.ts +12 -2
- package/dist/password-requirements/password-requirements.js +6 -8
- package/dist/password-requirements/web/ds-password-requirements.js +5 -5
- package/dist/password-strength/web/ds-password-strength.js +2 -2
- package/dist/payment-card/native/ds-payment-card.d.ts +1 -1
- package/dist/payment-card/native/ds-payment-card.js +1 -1
- package/dist/payment-card/web/ds-payment-card.d.ts +1 -1
- package/dist/payment-card/web/ds-payment-card.js +1 -1
- package/dist/people-cell/people-cell.d.ts +5 -2
- package/dist/people-cell/web/ds-people-cell.d.ts +1 -1
- package/dist/people-cell/web/ds-people-cell.js +6 -2
- package/dist/person-cell/person-cell.d.ts +5 -2
- package/dist/person-cell/web/ds-person-cell.d.ts +1 -1
- package/dist/person-cell/web/ds-person-cell.js +11 -1
- package/dist/phone-field/native/ds-phone-field.js +2 -2
- package/dist/phone-field/phone-field.d.ts +35 -0
- package/dist/phone-field/phone-field.js +38 -0
- package/dist/phone-field/web/ds-phone-field.d.ts +31 -3
- package/dist/phone-field/web/ds-phone-field.js +45 -8
- package/dist/place-card/native/ds-place-card.d.ts +7 -3
- package/dist/place-card/native/ds-place-card.js +32 -21
- package/dist/place-card/place-card.d.ts +12 -6
- package/dist/place-card/place-card.js +6 -3
- package/dist/place-card/web/ds-place-card.d.ts +5 -3
- package/dist/place-card/web/ds-place-card.js +39 -27
- package/dist/plan-chart/plan-chart.d.ts +2 -3
- package/dist/plan-chart/web/ds-plan-chart.d.ts +1 -1
- package/dist/plan-chart/web/ds-plan-chart.js +34 -6
- package/dist/popover/popover.d.ts +7 -3
- package/dist/popover/web/ds-popover.d.ts +5 -1
- package/dist/popover/web/ds-popover.js +4 -2
- package/dist/priority-indicator/native/ds-priority-indicator.js +4 -4
- package/dist/priority-indicator/priority-indicator.d.ts +3 -3
- package/dist/priority-indicator/priority-indicator.js +3 -3
- package/dist/priority-indicator/web/ds-priority-indicator.js +4 -4
- package/dist/profile-card/profile-card.d.ts +2 -1
- package/dist/profile-card/web/ds-profile-card.d.ts +2 -2
- package/dist/profile-card/web/ds-profile-card.js +16 -3
- package/dist/progress-bar/native/ds-progress-bar.js +2 -1
- package/dist/progress-bar/web/ds-progress-bar.js +2 -1
- package/dist/progress-cell/progress-cell.d.ts +8 -3
- package/dist/progress-cell/progress-cell.js +1 -1
- package/dist/progress-cell/web/ds-progress-cell.d.ts +5 -2
- package/dist/progress-cell/web/ds-progress-cell.js +6 -2
- package/dist/progress-ring/native/ds-progress-ring.js +16 -11
- package/dist/progress-ring/progress-ring.d.ts +8 -4
- package/dist/progress-ring/progress-ring.js +7 -3
- package/dist/progress-ring/web/ds-progress-ring.js +16 -10
- package/dist/proportion-bar/native/ds-proportion-bar.d.ts +2 -2
- package/dist/proportion-bar/native/ds-proportion-bar.js +18 -7
- package/dist/proportion-bar/proportion-bar.d.ts +10 -3
- package/dist/proportion-bar/proportion-bar.js +6 -1
- package/dist/proportion-bar/web/ds-proportion-bar.d.ts +1 -1
- package/dist/proportion-bar/web/ds-proportion-bar.js +21 -14
- package/dist/quick-actions/native/ds-quick-actions.js +17 -2
- package/dist/quick-actions/quick-actions.d.ts +32 -2
- package/dist/quick-actions/quick-actions.js +9 -1
- package/dist/quick-actions/web/ds-quick-actions.js +20 -6
- package/dist/radar-chart/radar-chart.d.ts +11 -3
- package/dist/radar-chart/radar-chart.js +21 -3
- package/dist/radar-chart/web/ds-radar-chart.d.ts +1 -1
- package/dist/radar-chart/web/ds-radar-chart.js +34 -22
- package/dist/radial-progress/native/ds-radial-progress.d.ts +6 -2
- package/dist/radial-progress/native/ds-radial-progress.js +34 -11
- package/dist/radial-progress/radial-progress.d.ts +11 -2
- package/dist/radial-progress/radial-progress.js +9 -0
- package/dist/radial-progress/web/ds-radial-progress.d.ts +6 -2
- package/dist/radial-progress/web/ds-radial-progress.js +24 -10
- package/dist/radio/radio.d.ts +4 -4
- package/dist/radio/radio.js +4 -4
- package/dist/radio/web/ds-radio.d.ts +6 -2
- package/dist/radio/web/ds-radio.js +22 -10
- package/dist/radio-group/radio-group.d.ts +41 -5
- package/dist/radio-group/radio-group.js +5 -0
- package/dist/radio-group/web/ds-radio-group.d.ts +1 -1
- package/dist/radio-group/web/ds-radio-group.js +7 -2
- package/dist/rating-badge/rating-badge.d.ts +8 -2
- package/dist/rating-badge/rating-badge.js +5 -0
- package/dist/rating-badge/web/ds-rating-badge.d.ts +2 -2
- package/dist/rating-badge/web/ds-rating-badge.js +6 -4
- package/dist/recipient-select/recipient-select.d.ts +7 -0
- package/dist/recipient-select/recipient-select.js +3 -0
- package/dist/recipient-select/web/ds-recipient-select.js +4 -4
- package/dist/record-panel/record-panel.d.ts +17 -2
- package/dist/record-panel/web/ds-record-panel.d.ts +48 -13
- package/dist/record-panel/web/ds-record-panel.js +27 -18
- package/dist/reorder-list/reorder-list.d.ts +3 -0
- package/dist/reorder-list/web/ds-reorder-list.d.ts +6 -1
- package/dist/reorder-list/web/ds-reorder-list.js +6 -4
- package/dist/resend-control/native/ds-resend-control.d.ts +24 -0
- package/dist/resend-control/native/ds-resend-control.js +73 -0
- package/dist/resend-control/resend-control.d.ts +2 -0
- package/dist/resend-control/resend-control.js +2 -0
- package/dist/resend-control/web/ds-resend-control.js +3 -3
- package/dist/route-fields/route-fields.d.ts +79 -0
- package/dist/route-fields/route-fields.js +71 -0
- package/dist/route-fields/web/ds-route-fields.d.ts +5 -0
- package/dist/route-fields/web/ds-route-fields.js +83 -0
- package/dist/route-line/web/ds-route-line.js +2 -2
- package/dist/save-bar/save-bar.d.ts +1 -1
- package/dist/save-bar/save-bar.js +1 -1
- package/dist/save-bar/web/ds-save-bar.js +2 -2
- package/dist/scanner/scanner.d.ts +1 -1
- package/dist/scanner/scanner.js +2 -1
- package/dist/scatter-chart/scatter-chart.d.ts +2 -3
- package/dist/scatter-chart/web/ds-scatter-chart.d.ts +1 -1
- package/dist/scatter-chart/web/ds-scatter-chart.js +13 -4
- package/dist/schedule-chart/schedule-chart.d.ts +187 -0
- package/dist/schedule-chart/schedule-chart.js +285 -0
- package/dist/schedule-chart/web/ds-schedule-chart.d.ts +24 -0
- package/dist/schedule-chart/web/ds-schedule-chart.js +143 -0
- package/dist/segmented-control/native/ds-segmented-control.d.ts +1 -1
- package/dist/segmented-control/native/ds-segmented-control.js +1 -1
- package/dist/segmented-control/segmented-control.d.ts +7 -0
- package/dist/segmented-control/web/ds-segmented-control.d.ts +1 -1
- package/dist/segmented-control/web/ds-segmented-control.js +4 -3
- package/dist/select/native/ds-select.js +6 -3
- package/dist/select/select.d.ts +5 -0
- package/dist/select/web/ds-select.d.ts +14 -1
- package/dist/select/web/ds-select.js +22 -12
- package/dist/settings-directory/native/ds-settings-directory.js +1 -1
- package/dist/settings-directory/web/ds-settings-directory.js +1 -1
- package/dist/settings-row/web/ds-settings-row.d.ts +3 -1
- package/dist/settings-row/web/ds-settings-row.js +2 -2
- package/dist/sheet/web/ds-sheet.js +3 -3
- package/dist/side-nav/side-nav.d.ts +2 -1
- package/dist/side-nav/web/ds-side-nav-collapse.d.ts +4 -1
- package/dist/side-nav/web/ds-side-nav-collapse.js +6 -3
- package/dist/side-nav/web/ds-side-nav-header.js +1 -1
- package/dist/side-nav/web/ds-side-nav-primary.js +1 -1
- package/dist/side-nav/web/ds-side-nav-profile.js +1 -1
- package/dist/side-nav/web/ds-side-nav.d.ts +1 -1
- package/dist/side-nav/web/ds-side-nav.js +3 -3
- package/dist/skeleton/skeleton.d.ts +20 -0
- package/dist/skeleton/skeleton.js +4 -0
- package/dist/slider/native/ds-slider.js +1 -1
- package/dist/small-multiples/small-multiples.d.ts +3 -4
- package/dist/small-multiples/small-multiples.js +2 -1
- package/dist/small-multiples/web/ds-small-multiples.d.ts +1 -1
- package/dist/small-multiples/web/ds-small-multiples.js +8 -2
- package/dist/sparkline/sparkline.d.ts +19 -7
- package/dist/sparkline/sparkline.js +42 -17
- package/dist/sparkline/web/ds-sparkline.d.ts +1 -1
- package/dist/sparkline/web/ds-sparkline.js +4 -3
- package/dist/split-pane/web/ds-split-pane.js +2 -2
- package/dist/stat-tile/native/ds-stat-tile.d.ts +3 -3
- package/dist/stat-tile/native/ds-stat-tile.js +14 -7
- package/dist/stat-tile/stat-tile.d.ts +14 -8
- package/dist/stat-tile/web/ds-stat-tile.d.ts +4 -2
- package/dist/stat-tile/web/ds-stat-tile.js +8 -5
- package/dist/state-message/web/ds-state-message.d.ts +6 -2
- package/dist/state-message/web/ds-state-message.js +5 -2
- package/dist/status-badge/native/ds-status-badge.js +3 -3
- package/dist/status-badge/status-badge.d.ts +3 -3
- package/dist/status-badge/status-badge.js +1 -1
- package/dist/status-badge/web/ds-status-badge.js +4 -4
- package/dist/status-cell/status-cell.d.ts +5 -2
- package/dist/status-cell/web/ds-status-cell.d.ts +6 -2
- package/dist/status-cell/web/ds-status-cell.js +7 -2
- package/dist/status-control/web/ds-status-control.js +3 -3
- package/dist/status-dot/native/ds-status-dot.js +1 -1
- package/dist/status-dot/status-dot.d.ts +2 -2
- package/dist/status-dot/status-dot.js +2 -2
- package/dist/status-dot/web/ds-status-dot.js +2 -2
- package/dist/stepper-form/stepper-form.d.ts +27 -4
- package/dist/stepper-form/stepper-form.js +17 -9
- package/dist/stepper-form/web/ds-stepper-form.d.ts +1 -1
- package/dist/stepper-form/web/ds-stepper-form.js +7 -5
- package/dist/stick-chart/stick-chart.d.ts +2 -1
- package/dist/stick-chart/stick-chart.js +2 -1
- package/dist/stick-chart/web/ds-stick-chart.d.ts +1 -1
- package/dist/stick-chart/web/ds-stick-chart.js +17 -3
- package/dist/switch/native/ds-switch.js +1 -1
- package/dist/system-state/native/ds-system-state.d.ts +29 -0
- package/dist/system-state/native/ds-system-state.js +68 -0
- package/dist/system-state/system-state.js +4 -3
- package/dist/system-state/web/ds-system-state.js +2 -2
- package/dist/table-toolbar/web/ds-table-toolbar.js +1 -1
- package/dist/tabs/tabs.d.ts +5 -0
- package/dist/tabs/tabs.js +2 -0
- package/dist/tabs/web/ds-tabs.js +2 -2
- package/dist/task-shell/task-shell.d.ts +15 -6
- package/dist/task-shell/task-shell.js +5 -2
- package/dist/task-shell/web/ds-task-shell.d.ts +21 -6
- package/dist/task-shell/web/ds-task-shell.js +52 -18
- package/dist/text/native/ds-text.js +1 -1
- package/dist/text/text.d.ts +1 -1
- package/dist/text/text.js +1 -1
- package/dist/text/web/ds-text.js +1 -1
- package/dist/textarea/native/ds-textarea.d.ts +1 -1
- package/dist/textarea/native/ds-textarea.js +9 -8
- package/dist/textarea/web/ds-textarea.d.ts +1 -1
- package/dist/textarea/web/ds-textarea.js +8 -7
- package/dist/time-field/time-field.d.ts +37 -0
- package/dist/time-field/time-field.js +23 -0
- package/dist/time-field/web/ds-time-field.d.ts +8 -0
- package/dist/time-field/web/ds-time-field.js +28 -0
- package/dist/time-range/time-range.d.ts +35 -26
- package/dist/time-range/time-range.js +28 -46
- package/dist/time-range/web/ds-time-range.d.ts +1 -1
- package/dist/time-range/web/ds-time-range.js +9 -6
- package/dist/timeline/native/ds-timeline.d.ts +2 -2
- package/dist/timeline/native/ds-timeline.js +21 -7
- package/dist/timeline/timeline.d.ts +2 -1
- package/dist/timeline/web/ds-timeline.d.ts +2 -2
- package/dist/timeline/web/ds-timeline.js +18 -9
- package/dist/toast/native/ds-toast.js +1 -1
- package/dist/toggle-group/native/ds-toggle-group.js +1 -1
- package/dist/token-roles.d.ts +1 -1
- package/dist/token-roles.js +18 -0
- package/dist/tone.d.ts +4 -4
- package/dist/tone.js +1 -5
- package/dist/toolbar/toolbar.d.ts +19 -7
- package/dist/toolbar/toolbar.js +4 -3
- package/dist/toolbar/web/ds-toolbar.d.ts +5 -2
- package/dist/toolbar/web/ds-toolbar.js +3 -3
- package/dist/track-bars/track-bars.d.ts +3 -4
- package/dist/track-bars/web/ds-track-bars.d.ts +1 -1
- package/dist/track-bars/web/ds-track-bars.js +9 -3
- package/dist/tree/tree.d.ts +1 -1
- package/dist/tree/tree.js +1 -1
- package/dist/tree/web/ds-tree.js +2 -2
- package/dist/treemap/treemap.d.ts +2 -3
- package/dist/treemap/web/ds-treemap.d.ts +1 -1
- package/dist/treemap/web/ds-treemap.js +14 -3
- package/dist/two-line-cell/two-line-cell.d.ts +5 -2
- package/dist/two-line-cell/web/ds-two-line-cell.d.ts +1 -1
- package/dist/two-line-cell/web/ds-two-line-cell.js +5 -1
- package/dist/vehicle-marker/vehicle-marker.d.ts +5 -4
- package/dist/vehicle-marker/vehicle-marker.js +3 -3
- package/dist/vehicle-marker/web/ds-vehicle-marker.js +9 -6
- package/dist/waterfall-chart/waterfall-chart.d.ts +10 -5
- package/dist/waterfall-chart/waterfall-chart.js +17 -12
- package/dist/waterfall-chart/web/ds-waterfall-chart.d.ts +7 -2
- package/dist/waterfall-chart/web/ds-waterfall-chart.js +49 -11
- package/dist/web.d.ts +20 -5
- package/dist/web.js +10 -2
- package/dist/week-schedule/web/ds-week-schedule.d.ts +1 -1
- package/dist/week-schedule/web/ds-week-schedule.js +4 -4
- package/dist/week-schedule/week-schedule.d.ts +23 -4
- package/dist/week-schedule/week-schedule.js +19 -13
- package/forced-colors.css +8 -5
- package/package.json +10 -15
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type ComponentProps } from 'react';
|
|
2
2
|
import { type CheckboxContract, type CheckboxValueContract } from '../checkbox';
|
|
3
|
-
export type DSCheckboxProps = Omit<ComponentProps<'input'>, 'type' | 'size' | 'checked'> & CheckboxContract & {
|
|
3
|
+
export type DSCheckboxProps = Omit<ComponentProps<'input'>, 'type' | 'size' | 'checked' | 'aria-readonly'> & CheckboxContract & {
|
|
4
4
|
[K in keyof CheckboxValueContract]?: CheckboxValueContract[K] | undefined;
|
|
5
5
|
};
|
|
6
6
|
/** A control that toggles between checked and not checked. */
|
|
7
|
-
export declare function DSCheckbox({ size, control, invalid, indeterminate, disabled, checked: isChecked, defaultChecked, onChange, onCheckedChange, className, ref, 'aria-invalid': ariaInvalid, ...props }: DSCheckboxProps): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare function DSCheckbox({ size, control, invalid, indeterminate, disabled, readOnly, checked: isChecked, defaultChecked, onChange, onClick, onCheckedChange, className, ref, 'aria-invalid': ariaInvalid, ...props }: DSCheckboxProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -13,7 +13,7 @@ const SURFACE = {
|
|
|
13
13
|
const BORDER = {
|
|
14
14
|
input: 'border border-input',
|
|
15
15
|
primary: 'border border-primary',
|
|
16
|
-
|
|
16
|
+
error: 'border border-error',
|
|
17
17
|
'disabled-border': 'border border-disabled-border',
|
|
18
18
|
};
|
|
19
19
|
const MARK = {
|
|
@@ -40,7 +40,7 @@ const CHECKED_SURFACE = {
|
|
|
40
40
|
const CHECKED_BORDER = {
|
|
41
41
|
input: 'checked:border-input indeterminate:border-input',
|
|
42
42
|
primary: 'checked:border-primary indeterminate:border-primary',
|
|
43
|
-
|
|
43
|
+
error: 'checked:border-error indeterminate:border-error',
|
|
44
44
|
'disabled-border': 'checked:border-disabled-border indeterminate:border-disabled-border',
|
|
45
45
|
};
|
|
46
46
|
const RADIO_CHECKED_SURFACE = {
|
|
@@ -51,16 +51,21 @@ const RADIO_CHECKED_SURFACE = {
|
|
|
51
51
|
const RADIO_CHECKED_BORDER = {
|
|
52
52
|
input: 'checked:border-input',
|
|
53
53
|
primary: 'checked:border-primary',
|
|
54
|
-
|
|
54
|
+
error: 'checked:border-error',
|
|
55
55
|
'disabled-border': 'checked:border-disabled-border',
|
|
56
56
|
};
|
|
57
57
|
const DISABLED = cn('disabled:cursor-not-allowed', 'disabled:bg-disabled disabled:border-disabled-border', 'disabled:checked:bg-disabled disabled:checked:border-disabled-border', 'disabled:indeterminate:bg-disabled disabled:indeterminate:border-disabled-border');
|
|
58
58
|
const DISABLED_MARK = 'peer-disabled:text-disabled-foreground';
|
|
59
|
+
const READ_ONLY = 'cursor-default border-dashed checked:bg-card indeterminate:bg-card';
|
|
60
|
+
const READ_ONLY_RADIO = 'cursor-default border-dashed checked:bg-card';
|
|
61
|
+
const READ_ONLY_EDGE = 'checked:border-input indeterminate:border-input';
|
|
62
|
+
const READ_ONLY_MARK = 'text-foreground';
|
|
59
63
|
const HOVER = 'cursor-pointer enabled:hover:not-checked:not-indeterminate:border-muted-foreground';
|
|
60
|
-
export function DSCheckbox({ size = 'md', control = 'checkbox', invalid = false, indeterminate = false, disabled, checked: isChecked, defaultChecked, onChange, onCheckedChange, className, ref, 'aria-invalid': ariaInvalid, ...props }) {
|
|
64
|
+
export function DSCheckbox({ size = 'md', control = 'checkbox', invalid = false, indeterminate = false, disabled, readOnly = false, checked: isChecked, defaultChecked, onChange, onClick, onCheckedChange, className, ref, 'aria-invalid': ariaInvalid, ...props }) {
|
|
61
65
|
const isRadio = control === 'radio';
|
|
62
66
|
const isInvalid = invalid || ariaInvalid === true || ariaInvalid === 'true';
|
|
63
67
|
const isIndeterminate = indeterminate && !isRadio;
|
|
68
|
+
const isReadOnly = readOnly && disabled !== true;
|
|
64
69
|
const resting = checkboxSpec(size, isInvalid ? 'invalid' : 'unchecked');
|
|
65
70
|
const checked = checkboxSpec(size, 'checked', { invalid: isInvalid });
|
|
66
71
|
const setRef = useCallback((node) => {
|
|
@@ -68,8 +73,14 @@ export function DSCheckbox({ size = 'md', control = 'checkbox', invalid = false,
|
|
|
68
73
|
node.indeterminate = isIndeterminate;
|
|
69
74
|
assignRef(ref, node);
|
|
70
75
|
}, [ref, isIndeterminate]);
|
|
71
|
-
return (_jsxs("span", { className: "relative inline-flex shrink-0 items-center justify-center", children: [_jsx("input", { ref: setRef, type: control, "aria-invalid": isInvalid || undefined, disabled: disabled, ...(isChecked === undefined ? { defaultChecked } : { checked: isChecked }), onChange: (event) => {
|
|
76
|
+
return (_jsxs("span", { className: "relative inline-flex shrink-0 items-center justify-center", children: [_jsx("input", { ref: setRef, type: control, "aria-invalid": isInvalid || undefined, "aria-readonly": (isReadOnly && !isRadio) || undefined, disabled: disabled, ...(isChecked === undefined ? { defaultChecked } : { checked: isChecked }), onChange: (event) => {
|
|
77
|
+
if (isReadOnly)
|
|
78
|
+
return;
|
|
72
79
|
onChange?.(event);
|
|
73
80
|
onCheckedChange?.(event.currentTarget.checked);
|
|
74
|
-
},
|
|
81
|
+
}, onClick: (event) => {
|
|
82
|
+
if (isReadOnly && isChecked === undefined)
|
|
83
|
+
event.preventDefault();
|
|
84
|
+
onClick?.(event);
|
|
85
|
+
}, "data-forced-colors": "check", className: cn('peer relative appearance-none transition-control focusable', SMALL_CONTROL_HIT_AREA, BOX[resting.box], isRadio ? RADIUS.full : RADIUS[resting.radius], SURFACE[resting.surface], BORDER[resting.border], isRadio ? RADIO_CHECKED_BORDER[checked.border] : CHECKED_BORDER[checked.border], isRadio ? RADIO_CHECKED_SURFACE[checked.surface] : CHECKED_SURFACE[checked.surface], resting.border === 'input' && !isReadOnly && HOVER, isReadOnly && (isRadio ? READ_ONLY_RADIO : READ_ONLY), isReadOnly && !isInvalid && READ_ONLY_EDGE, DISABLED, className), ...props }), isRadio ? (_jsx("span", { "aria-hidden": true, className: cn('pointer-events-none absolute hidden size-1.5 rounded-full bg-current peer-checked:block', MARK[checked.mark], isReadOnly && READ_ONLY_MARK, DISABLED_MARK) })) : (_jsxs(_Fragment, { children: [_jsx(Check, { "aria-hidden": true, className: cn('pointer-events-none absolute hidden size-3 peer-checked:block peer-indeterminate:hidden', MARK[checked.mark], isReadOnly && READ_ONLY_MARK, DISABLED_MARK) }), _jsx(Minus, { "aria-hidden": true, className: cn('pointer-events-none absolute hidden size-3 peer-indeterminate:block', MARK[checked.mark], isReadOnly && READ_ONLY_MARK, DISABLED_MARK) })] }))] }));
|
|
75
86
|
}
|
package/dist/chip/chip.d.ts
CHANGED
|
@@ -11,8 +11,9 @@ export interface ChipToneSpec {
|
|
|
11
11
|
border: TokenRole;
|
|
12
12
|
/** The word's own ink. */
|
|
13
13
|
ink: TokenRole;
|
|
14
|
-
/** The
|
|
15
|
-
|
|
14
|
+
/** The tint under a pointer, as a percent of `CHIP_TOGGLE_HOVER_INK`, laid
|
|
15
|
+
* over whatever the chip stands on. Off only. */
|
|
16
|
+
hoverTint?: typeof CHIP_TOGGLE_HOVER_TINT;
|
|
16
17
|
}
|
|
17
18
|
/** An off toggle's edge: the structural control edge. */
|
|
18
19
|
export declare const CHIP_TOGGLE_OFF_BORDER = "input";
|
|
@@ -25,20 +26,20 @@ export declare const CHIP_TOGGLE_REST_INK = "foreground";
|
|
|
25
26
|
/** An on toggle's word: the brand ink. */
|
|
26
27
|
export declare const CHIP_TOGGLE_ON_INK = "selected-foreground";
|
|
27
28
|
/** An on toggle's fill: the brand tint. */
|
|
28
|
-
export declare const CHIP_TOGGLE_ON_SURFACE = "
|
|
29
|
-
/**
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
export declare const
|
|
29
|
+
export declare const CHIP_TOGGLE_ON_SURFACE = "surface-selected";
|
|
30
|
+
/** The ink an off toggle's pointer tint is mixed from. */
|
|
31
|
+
export declare const CHIP_TOGGLE_HOVER_INK = "foreground";
|
|
32
|
+
/** An off toggle under a pointer: the navigation rule's lighter tint, per cent. */
|
|
33
|
+
export declare const CHIP_TOGGLE_HOVER_TINT = 4;
|
|
33
34
|
/** `off` and `on`, for `variant: 'toggle'` only. `label` has one visual state. */
|
|
34
35
|
export declare const CHIP_TOGGLE_SPECS: {
|
|
35
36
|
readonly off: {
|
|
36
37
|
readonly border: "input";
|
|
37
38
|
readonly ink: "foreground";
|
|
38
|
-
readonly
|
|
39
|
+
readonly hoverTint: 4;
|
|
39
40
|
};
|
|
40
41
|
readonly on: {
|
|
41
|
-
readonly surface: "
|
|
42
|
+
readonly surface: "surface-selected";
|
|
42
43
|
readonly border: "selected-foreground";
|
|
43
44
|
readonly ink: "selected-foreground";
|
|
44
45
|
};
|
|
@@ -50,7 +51,6 @@ export declare const CHIP_LABEL_SPEC: {
|
|
|
50
51
|
readonly ink: "foreground";
|
|
51
52
|
};
|
|
52
53
|
export type ChipSurfaceRole = (typeof CHIP_LABEL_SPEC)['surface'] | (typeof CHIP_TOGGLE_SPECS)['on']['surface'];
|
|
53
|
-
export type ChipHoverSurfaceRole = (typeof CHIP_TOGGLE_SPECS)['off']['hoverSurface'];
|
|
54
54
|
export type ChipBorderRole = (typeof CHIP_TOGGLE_SPECS)[keyof typeof CHIP_TOGGLE_SPECS]['border'] | (typeof CHIP_LABEL_SPEC)['border'];
|
|
55
55
|
export type ChipInkRole = (typeof CHIP_TOGGLE_SPECS)[keyof typeof CHIP_TOGGLE_SPECS]['ink'] | (typeof CHIP_LABEL_SPEC)['ink'];
|
|
56
56
|
export interface ChipResolvedSpec {
|
|
@@ -58,7 +58,7 @@ export interface ChipResolvedSpec {
|
|
|
58
58
|
surface?: ChipSurfaceRole;
|
|
59
59
|
border: ChipBorderRole;
|
|
60
60
|
ink: ChipInkRole;
|
|
61
|
-
|
|
61
|
+
hoverTint?: typeof CHIP_TOGGLE_HOVER_TINT;
|
|
62
62
|
}
|
|
63
63
|
/**
|
|
64
64
|
* The toggle's touch floor, from the source's `min-height: var(--size-target)`. `label` has no
|
package/dist/chip/chip.js
CHANGED
|
@@ -1,15 +1,17 @@
|
|
|
1
|
+
import { NAV_HOVER_TINT_PERCENT, NAV_TINT_INK } from '../interaction';
|
|
1
2
|
export const CHIP_VARIANTS = ['toggle', 'label'];
|
|
2
3
|
export const CHIP_TOGGLE_OFF_BORDER = 'input';
|
|
3
4
|
export const CHIP_TOGGLE_ON_BORDER = 'selected-foreground';
|
|
4
5
|
export const CHIP_TOGGLE_REST_INK = 'foreground';
|
|
5
6
|
export const CHIP_TOGGLE_ON_INK = 'selected-foreground';
|
|
6
|
-
export const CHIP_TOGGLE_ON_SURFACE = '
|
|
7
|
-
export const
|
|
7
|
+
export const CHIP_TOGGLE_ON_SURFACE = 'surface-selected';
|
|
8
|
+
export const CHIP_TOGGLE_HOVER_INK = NAV_TINT_INK;
|
|
9
|
+
export const CHIP_TOGGLE_HOVER_TINT = NAV_HOVER_TINT_PERCENT;
|
|
8
10
|
export const CHIP_TOGGLE_SPECS = {
|
|
9
11
|
off: {
|
|
10
12
|
border: CHIP_TOGGLE_OFF_BORDER,
|
|
11
13
|
ink: CHIP_TOGGLE_REST_INK,
|
|
12
|
-
|
|
14
|
+
hoverTint: CHIP_TOGGLE_HOVER_TINT,
|
|
13
15
|
},
|
|
14
16
|
on: {
|
|
15
17
|
surface: CHIP_TOGGLE_ON_SURFACE,
|
|
@@ -8,7 +8,7 @@ import { useThemeEpoch } from '../../lib/use-theme-epoch';
|
|
|
8
8
|
import { DSText } from '../../text/native/ds-text';
|
|
9
9
|
const SURFACE = {
|
|
10
10
|
background: 'bg-background',
|
|
11
|
-
|
|
11
|
+
'surface-selected': 'bg-surface-selected',
|
|
12
12
|
};
|
|
13
13
|
const INK = {
|
|
14
14
|
foreground: 'text-foreground',
|
package/dist/chip/web/ds-chip.js
CHANGED
|
@@ -25,7 +25,7 @@ function removeWithFallback(cross, onRemove) {
|
|
|
25
25
|
}
|
|
26
26
|
const SURFACE = {
|
|
27
27
|
background: 'bg-background',
|
|
28
|
-
|
|
28
|
+
'surface-selected': 'bg-surface-selected',
|
|
29
29
|
};
|
|
30
30
|
const INK = {
|
|
31
31
|
foreground: 'text-foreground',
|
|
@@ -36,15 +36,15 @@ const BORDER = {
|
|
|
36
36
|
input: 'border-input',
|
|
37
37
|
'selected-foreground': 'border-selected-foreground',
|
|
38
38
|
};
|
|
39
|
-
const
|
|
40
|
-
|
|
39
|
+
const HOVER_TINT = {
|
|
40
|
+
4: 'state-layer state-layer-tint',
|
|
41
41
|
};
|
|
42
42
|
const DISABLED_PILL = 'bg-disabled text-disabled-foreground border-disabled-border';
|
|
43
43
|
const REMOVE_INK = {
|
|
44
44
|
'muted-foreground': 'text-muted-foreground',
|
|
45
45
|
};
|
|
46
46
|
const REMOVE_HOVER_SURFACE = {
|
|
47
|
-
muted: 'hover:bg-muted
|
|
47
|
+
muted: 'hover:bg-muted state-layer-press',
|
|
48
48
|
};
|
|
49
49
|
const REMOVE_HOVER_INK = {
|
|
50
50
|
foreground: 'hover:text-foreground',
|
|
@@ -53,7 +53,7 @@ export function DSChip({ label, variant = 'label', pressed = false, disabled, on
|
|
|
53
53
|
const spec = chipSpec(variant, pressed);
|
|
54
54
|
const isDisabled = disabled === true;
|
|
55
55
|
const labelText = (_jsx("span", { className: "min-w-0 truncate", title: label, children: label }));
|
|
56
|
-
const pill = cn('inline-flex max-w-full items-center gap-2 whitespace-nowrap rounded-full border text-body-sm focusable', pressed ? 'font-semibold' : 'font-normal', isDisabled
|
|
56
|
+
const pill = cn('inline-flex w-fit max-w-full items-center gap-2 whitespace-nowrap rounded-full border text-body-sm focusable', pressed ? 'font-semibold' : 'font-normal', isDisabled
|
|
57
57
|
? DISABLED_PILL
|
|
58
58
|
: cn(spec.surface === undefined ? undefined : SURFACE[spec.surface], INK[spec.ink], BORDER[spec.border], spec.surface === undefined
|
|
59
59
|
? 'chip-rest-toggle'
|
|
@@ -63,7 +63,7 @@ export function DSChip({ label, variant = 'label', pressed = false, disabled, on
|
|
|
63
63
|
if (variant === 'toggle') {
|
|
64
64
|
return (_jsxs("button", { type: "button", "aria-pressed": pressed, disabled: isDisabled, onClick: () => {
|
|
65
65
|
onPressedChange?.(!pressed);
|
|
66
|
-
}, className: cn(pill, 'relative cursor-pointer px-3 py-1.75 transition-control before:absolute before:inset-x-0 before:-inset-y-1.5', 'state-layer-press'
|
|
66
|
+
}, className: cn(pill, 'relative cursor-pointer px-3 py-1.75 transition-control before:absolute before:inset-x-0 before:-inset-y-1.5', spec.hoverTint === undefined ? 'state-layer-press' : HOVER_TINT[spec.hoverTint], 'disabled:cursor-not-allowed', className), ...props, children: [pressed && _jsx(Check, { "aria-hidden": true, className: "size-3.5 shrink-0" }), labelText] }));
|
|
67
67
|
}
|
|
68
68
|
return (_jsxs("span", { className: cn(pill, 'py-1.75 pl-3', onRemove ? 'pr-2' : 'pr-3', className), ...(isDisabled ? { 'aria-disabled': true } : {}), ...props, children: [labelText, onRemove && (_jsx("button", { type: "button", "aria-label": removeLabel, "data-chip-remove": "", onClick: (event) => {
|
|
69
69
|
removeWithFallback(event.currentTarget, onRemove);
|
|
@@ -28,11 +28,11 @@ const COPY_GLYPH = {
|
|
|
28
28
|
copied: Check,
|
|
29
29
|
failed: TriangleAlert,
|
|
30
30
|
};
|
|
31
|
-
const HEADER_RING = '
|
|
31
|
+
const HEADER_RING = 'focusable-inset';
|
|
32
32
|
const COPY_INK = {
|
|
33
33
|
idle: undefined,
|
|
34
34
|
copied: 'text-success hover:text-success',
|
|
35
|
-
failed: 'text-
|
|
35
|
+
failed: 'text-error hover:text-error',
|
|
36
36
|
};
|
|
37
37
|
export function DSCodeBlock({ code, language, filename, lineNumbers = true, highlightLines, dimUnhighlighted = false, maxLines, wrapLabel = CODE_BLOCK_WRAP_LABEL, className, ...props }) {
|
|
38
38
|
const [wrap, setWrap] = useState(false);
|
|
@@ -51,7 +51,7 @@ export function DSCodeBlock({ code, language, filename, lineNumbers = true, high
|
|
|
51
51
|
setWrap(!wrap);
|
|
52
52
|
} }), _jsx(DSIconButton, { variant: "ghost", size: "sm", label: codeBlockCopyLabel(name), icon: _jsx(Glyph, { "aria-hidden": true }), onClick: () => {
|
|
53
53
|
void copy(code);
|
|
54
|
-
}, className: cn(HEADER_RING, COPY_INK[copyState]) })] }), _jsx("span", { "aria-live": "polite", className: "sr-only", children: said ?? '' })] }), _jsx("div", { role: "region", "aria-label": `${name}, code`, tabIndex: 0, className: cn('focusable
|
|
54
|
+
}, className: cn(HEADER_RING, COPY_INK[copyState]) })] }), _jsx("span", { "aria-live": "polite", className: "sr-only", children: said ?? '' })] }), _jsx("div", { role: "region", "aria-label": `${name}, code`, tabIndex: 0, className: cn('focusable-inset', wrap ? 'overflow-x-hidden' : 'overflow-x-auto'), children: _jsx("pre", { className: "py-3 font-mono text-body-sm", children: _jsx("code", { id: codeId, className: cn('block', !wrap && 'w-max min-w-full'), children: lines.slice(0, visible.shown).map((tokens, index) => {
|
|
55
55
|
const n = index + 1;
|
|
56
56
|
const isHighlighted = highlighted.has(n);
|
|
57
57
|
return (_jsxs("span", { "data-line": n, ...(isHighlighted
|
|
@@ -3,6 +3,7 @@ import { useState } from 'react';
|
|
|
3
3
|
import { Columns3 } from 'lucide-react';
|
|
4
4
|
import { columnPickerAllShown, columnPickerKeep, columnPickerToggle, } from '../column-picker';
|
|
5
5
|
import { DSButton } from '../../button/web/ds-button';
|
|
6
|
+
import { cn } from '../../lib/cn';
|
|
6
7
|
import { DSCheckOption } from '../../check-option/web/ds-check-option';
|
|
7
8
|
import { DSFormFieldGroup } from '../../form-field-group/web/ds-form-field-group';
|
|
8
9
|
import { DSPopover } from '../../popover/web/ds-popover';
|
|
@@ -10,7 +11,7 @@ export function DSColumnPicker({ columns, shown, onShownChange, disabled = false
|
|
|
10
11
|
const [open, setOpen] = useState(false);
|
|
11
12
|
return (_jsx(DSPopover, { open: open, label: "Choose columns", onRequestClose: () => {
|
|
12
13
|
setOpen(false);
|
|
13
|
-
}, trigger: _jsxs(DSButton, { variant: "outline", className:
|
|
14
|
+
}, trigger: _jsxs(DSButton, { variant: "outline", className: cn('min-h-10.5', columnPickerAllShown(columns, shown) ? 'text-foreground' : 'bg-accent text-accent-foreground'), "aria-haspopup": "dialog", "aria-expanded": open, disabled: disabled, onClick: () => {
|
|
14
15
|
setOpen((was) => !was);
|
|
15
16
|
}, children: [_jsx(Columns3, { "aria-hidden": true, className: "size-4" }), "Columns"] }), footer: _jsx(DSButton, { variant: "ghost", size: "sm", disabled: columnPickerAllShown(columns, shown), onClick: () => {
|
|
16
17
|
onShownChange(columns);
|
|
@@ -66,8 +66,8 @@ interface ComboboxBase {
|
|
|
66
66
|
label: string;
|
|
67
67
|
placeholder?: Forwarded<string>;
|
|
68
68
|
/** Whether choosing a row closes the list. Off for a field that picks several in a row,
|
|
69
|
-
* as
|
|
70
|
-
* away. Default true. */
|
|
69
|
+
* such as the line items on an invoice: the list stays open, the query clears, the
|
|
70
|
+
* next is a key away. Default true. */
|
|
71
71
|
closeOnSelect?: Forwarded<boolean>;
|
|
72
72
|
/** Whether the list is open. The field holds this itself when it is omitted. */
|
|
73
73
|
open?: Forwarded<boolean>;
|
|
@@ -47,6 +47,8 @@ export function DSCombobox({ options, query, onQueryChange, onSelect, onCreate,
|
|
|
47
47
|
function commit(index) {
|
|
48
48
|
const result = comboboxCommit(options, query, index, keys);
|
|
49
49
|
if (result.kind === 'select') {
|
|
50
|
+
if (result.option.disabled === true)
|
|
51
|
+
return;
|
|
50
52
|
onSelect(result.option);
|
|
51
53
|
if (closeOnSelect)
|
|
52
54
|
setOpen(false);
|
|
@@ -153,11 +155,11 @@ export function DSCombobox({ options, query, onQueryChange, onSelect, onCreate,
|
|
|
153
155
|
const plain = option.labelColour === undefined &&
|
|
154
156
|
option.labels === undefined &&
|
|
155
157
|
option.hint === undefined;
|
|
156
|
-
return (_jsxs("button", { type: "button", id: rowId(index), role: "option", "aria-selected": index === active, tabIndex: -1, onMouseEnter: () => {
|
|
158
|
+
return (_jsxs("button", { type: "button", id: rowId(index), role: "option", "aria-selected": index === active, "aria-disabled": option.disabled === true || undefined, tabIndex: -1, onMouseEnter: () => {
|
|
157
159
|
setActive(index);
|
|
158
160
|
}, onClick: () => {
|
|
159
161
|
commit(index);
|
|
160
|
-
}, className: cn(plain ? 'block' : 'flex items-center gap-2', 'w-full cursor-pointer rounded-field px-3 py-2 text-left text-body-sm pointer-coarse:min-h-touch', index === active && OPTION_ACTIVE[spec.optionActiveSurface]), children: [option.labelColour !== undefined && (_jsx(DSSelectOptionLabelDot, { colour: option.labelColour })), plain ? (option.label) : option.hint === undefined ? (_jsx("span", { className: "min-w-0", children: option.label })) : (_jsxs("span", { className: "flex min-w-0 flex-col", children: [_jsx("span", { children: option.label }), _jsx(DSText, { as: "span", variant: "body-sm", className: cn(NONE_INK[spec.noneInk]), children: option.hint })] })), option.labels !== undefined && (_jsx(DSSelectOptionLabels, { labels: option.labels }))] }, option.value));
|
|
162
|
+
}, className: cn(plain ? 'block' : 'flex items-center gap-2', 'w-full cursor-pointer rounded-field px-3 py-2 text-left text-body-sm pointer-coarse:min-h-touch', 'aria-disabled:cursor-not-allowed aria-disabled:text-muted-foreground', index === active && OPTION_ACTIVE[spec.optionActiveSurface]), children: [option.labelColour !== undefined && (_jsx(DSSelectOptionLabelDot, { colour: option.labelColour })), plain ? (option.label) : option.hint === undefined ? (_jsx("span", { className: "min-w-0", children: option.label })) : (_jsxs("span", { className: "flex min-w-0 flex-col", children: [_jsx("span", { children: option.label }), _jsx(DSText, { as: "span", variant: "body-sm", className: cn(NONE_INK[spec.noneInk]), children: option.hint })] })), option.labels !== undefined && (_jsx(DSSelectOptionLabels, { labels: option.labels }))] }, option.value));
|
|
161
163
|
});
|
|
162
164
|
return entry.group === undefined ? (_jsx(Fragment, { children: rowsOfGroup }, `ungrouped-${String(groupIndex)}`)) : (_jsxs("div", { role: "group", "aria-labelledby": heading, children: [_jsx(DSText, { as: "p", variant: "caps", id: heading, className: cn('mb-1 mt-3 px-3 uppercase first:mt-0', GROUP_INK[spec.groupInk]), children: entry.group }), rowsOfGroup] }, entry.group));
|
|
163
165
|
}), showCreate && (_jsxs("button", { type: "button", id: rowId(visible.length), role: "option", "aria-selected": visible.length === active, tabIndex: -1, onMouseEnter: () => {
|
|
@@ -138,7 +138,9 @@ export declare const COMMAND_PALETTE_INK = "foreground";
|
|
|
138
138
|
export declare const COMMAND_PALETTE_QUIET_INK = "muted-foreground";
|
|
139
139
|
export declare const COMMAND_PALETTE_ACTIVE_SURFACE = "accent";
|
|
140
140
|
export declare const COMMAND_PALETTE_ACTIVE_INK = "accent-foreground";
|
|
141
|
+
/** @deprecated Not painted. The key caps are `DSKbd`, which brings its own fill. */
|
|
141
142
|
export declare const COMMAND_PALETTE_KEY_SURFACE = "muted";
|
|
143
|
+
/** @deprecated Not painted. The key caps are `DSKbd`, which brings its own ink. */
|
|
142
144
|
export declare const COMMAND_PALETTE_KEY_INK = "muted-foreground";
|
|
143
145
|
export declare const COMMAND_PALETTE_DESTRUCTIVE_INK = "destructive";
|
|
144
146
|
export declare const COMMAND_PALETTE_DESTRUCTIVE_ACTIVE_SURFACE = "destructive-surface";
|
|
@@ -158,7 +160,9 @@ export interface CommandPaletteResolvedSpec {
|
|
|
158
160
|
/** The option the arrows are on, a fill and an ink measured as a pair. */
|
|
159
161
|
activeSurface: typeof COMMAND_PALETTE_ACTIVE_SURFACE;
|
|
160
162
|
activeInk: typeof COMMAND_PALETTE_ACTIVE_INK;
|
|
163
|
+
/** @deprecated Not painted. The key caps are `DSKbd`, which brings its own fill. */
|
|
161
164
|
keySurface: typeof COMMAND_PALETTE_KEY_SURFACE;
|
|
165
|
+
/** @deprecated Not painted. The key caps are `DSKbd`, which brings its own ink. */
|
|
162
166
|
keyInk: typeof COMMAND_PALETTE_KEY_INK;
|
|
163
167
|
/** A destructive command's label and glyph, on the panel surface. */
|
|
164
168
|
destructiveInk: typeof COMMAND_PALETTE_DESTRUCTIVE_INK;
|
|
@@ -93,10 +93,10 @@ export declare const COMMENT_THREAD_AUTHOR_INK = "foreground";
|
|
|
93
93
|
export declare const COMMENT_THREAD_BODY_INK = "foreground";
|
|
94
94
|
export declare const COMMENT_THREAD_META_INK = "muted-foreground";
|
|
95
95
|
export declare const COMMENT_THREAD_MENTION_INK = "link";
|
|
96
|
-
export declare const COMMENT_THREAD_FAILED_INK = "
|
|
96
|
+
export declare const COMMENT_THREAD_FAILED_INK = "error";
|
|
97
97
|
export declare const COMMENT_THREAD_CARD_SURFACE = "card";
|
|
98
98
|
export declare const COMMENT_THREAD_CARD_EDGE = "border-subtle";
|
|
99
|
-
export declare const COMMENT_THREAD_QUOTE_SURFACE = "
|
|
99
|
+
export declare const COMMENT_THREAD_QUOTE_SURFACE = "nested-1";
|
|
100
100
|
export declare const COMMENT_THREAD_QUOTE_EDGE = "border-subtle";
|
|
101
101
|
export type CommentThreadAuthorInkRole = typeof COMMENT_THREAD_AUTHOR_INK;
|
|
102
102
|
export type CommentThreadBodyInkRole = typeof COMMENT_THREAD_BODY_INK;
|
|
@@ -144,9 +144,9 @@ export const COMMENT_THREAD_AUTHOR_INK = 'foreground';
|
|
|
144
144
|
export const COMMENT_THREAD_BODY_INK = 'foreground';
|
|
145
145
|
export const COMMENT_THREAD_META_INK = 'muted-foreground';
|
|
146
146
|
export const COMMENT_THREAD_MENTION_INK = 'link';
|
|
147
|
-
export const COMMENT_THREAD_FAILED_INK = '
|
|
147
|
+
export const COMMENT_THREAD_FAILED_INK = 'error';
|
|
148
148
|
export const COMMENT_THREAD_CARD_SURFACE = 'card';
|
|
149
149
|
export const COMMENT_THREAD_CARD_EDGE = 'border-subtle';
|
|
150
|
-
export const COMMENT_THREAD_QUOTE_SURFACE = '
|
|
150
|
+
export const COMMENT_THREAD_QUOTE_SURFACE = 'nested-1';
|
|
151
151
|
export const COMMENT_THREAD_QUOTE_EDGE = 'border-subtle';
|
|
152
152
|
export const COMMENT_THREAD_LABELS_MAX = 3;
|
|
@@ -17,6 +17,7 @@ import { DSTextarea } from '../../textarea/native/ds-textarea';
|
|
|
17
17
|
import { DSLabelGroup } from '../../label/native/ds-label-group';
|
|
18
18
|
import { cn } from '../../lib/cn';
|
|
19
19
|
import { DSText } from '../../text/native/ds-text';
|
|
20
|
+
import { COMMON_COPY } from '../../copy';
|
|
20
21
|
const ICON = { className: { target: 'style', nativeStyleMapping: { color: 'color' } } };
|
|
21
22
|
const AlertIcon = styled(TriangleAlert, ICON);
|
|
22
23
|
const ResolvedIcon = styled(CircleCheck, ICON);
|
|
@@ -72,7 +73,7 @@ function Blocks({ blocks, context }) {
|
|
|
72
73
|
case 'table':
|
|
73
74
|
return (_jsx(View, { className: "gap-1", children: [block.header, ...block.rows].map((row, r) => (_jsx(DSText, { variant: "body-sm", className: cn('text-foreground', r === 0 && 'font-semibold'), children: row.map((cell, c) => (_jsxs(Text, { className: "font-sans", children: [c > 0 ? ' · ' : '', _jsx(Inline, { nodes: cell, context: context })] }, c))) }, r))) }, i));
|
|
74
75
|
case 'blockquote':
|
|
75
|
-
return (_jsx(View, { className: "gap-1 rounded-control border border-border-subtle bg-
|
|
76
|
+
return (_jsx(View, { className: "gap-1 rounded-control border border-border-subtle bg-nested-1 px-3 py-2", children: _jsx(Blocks, { blocks: block.children, context: context }) }, i));
|
|
76
77
|
}
|
|
77
78
|
});
|
|
78
79
|
}
|
|
@@ -96,20 +97,20 @@ export function DSCommentThread({ comments, now, currentUserId, label, draft, on
|
|
|
96
97
|
id: comment.id,
|
|
97
98
|
body: mentionInputApplyEdit(editing.body, text),
|
|
98
99
|
});
|
|
99
|
-
}, autoFocus: true }), _jsxs(View, { className: "flex-row gap-2", children: [_jsx(DSButton, { size: "sm",
|
|
100
|
-
onEdit(comment.id, editing.body);
|
|
101
|
-
}, children: "Save" }), _jsx(DSButton, { size: "sm", variant: "ghost", onPress: () => {
|
|
100
|
+
}, autoFocus: true }), _jsxs(View, { className: "flex-row justify-end gap-2", children: [_jsx(DSButton, { size: "sm", variant: "secondary", onPress: () => {
|
|
102
101
|
onEditingChange(undefined);
|
|
103
|
-
}, children:
|
|
102
|
+
}, children: COMMON_COPY.cancel }), _jsx(DSButton, { size: "sm", disabled: !commentThreadCanPost(editing.body), onPress: () => {
|
|
103
|
+
onEdit(comment.id, editing.body);
|
|
104
|
+
}, children: "Save" })] })] })) : (_jsx(Body, { body: comment.body, onMentionPress: onMentionPress })), statusText !== undefined && (_jsxs(View, { className: "flex-row flex-wrap items-center gap-2", children: [status === 'failed' && _jsx(AlertIcon, { size: 16, className: "text-error" }), _jsx(DSText, { variant: "body-sm", className: cn('', status === 'failed' ? 'text-error' : 'text-muted-foreground'), children: statusText }), status === 'failed' && (_jsxs(_Fragment, { children: [_jsx(DSButton, { size: "sm", variant: "outline", onPress: () => {
|
|
104
105
|
onRetry(comment.id);
|
|
105
106
|
}, children: "Retry" }), _jsx(DSButton, { size: "sm", variant: "ghost", onPress: () => {
|
|
106
107
|
onDiscard(comment.id);
|
|
107
|
-
}, children: "Discard" })] }))] })), confirming === comment.id ? (_jsxs(View, { accessibilityRole: "alert", className: "gap-2", children: [_jsx(DSText, { variant: "body-sm", className: "text-foreground", children: "Delete this comment? This cannot be undone." }), _jsxs(View, { className: "flex-row gap-2", children: [_jsx(DSButton, { size: "sm", variant: "
|
|
108
|
+
}, children: "Discard" })] }))] })), confirming === comment.id ? (_jsxs(View, { accessibilityRole: "alert", className: "gap-2", children: [_jsx(DSText, { variant: "body-sm", className: "text-foreground", children: "Delete this comment? This cannot be undone." }), _jsxs(View, { className: "flex-row gap-2", children: [_jsx(DSButton, { size: "sm", variant: "secondary", onPress: () => {
|
|
108
109
|
setConfirming(undefined);
|
|
109
|
-
|
|
110
|
-
}, children: "Delete" }), _jsx(DSButton, { size: "sm", variant: "ghost", onPress: () => {
|
|
110
|
+
}, children: "Keep comment" }), _jsx(DSButton, { size: "sm", variant: "destructive", onPress: () => {
|
|
111
111
|
setConfirming(undefined);
|
|
112
|
-
|
|
112
|
+
onDelete(comment.id);
|
|
113
|
+
}, children: "Delete" })] })] })) : (!isEditing &&
|
|
113
114
|
acts.length > 0 && (_jsxs(View, { className: "flex-row flex-wrap gap-1", children: [acts.includes('reply') && (_jsx(DSButton, { size: "sm", variant: "ghost", onPress: () => {
|
|
114
115
|
onReplyToChange(commentThreadReplyTarget(comments, comment.id) ?? comment.id);
|
|
115
116
|
}, children: "Reply" })), acts.includes('edit') && (_jsx(DSButton, { size: "sm", variant: "ghost", onPress: () => {
|
|
@@ -18,11 +18,12 @@ import { indexAfterRemoval } from '../../lib/focus-order';
|
|
|
18
18
|
import { useEscapeEntry, useFocusFallback } from '../../lib/web/focus-habits';
|
|
19
19
|
import { useLiveFocusWithin } from '../../lib/web/use-live-focus-within';
|
|
20
20
|
import { DSText } from '../../text/web/ds-text';
|
|
21
|
+
import { COMMON_COPY } from '../../copy';
|
|
21
22
|
const META = {
|
|
22
23
|
'muted-foreground': 'text-muted-foreground',
|
|
23
24
|
};
|
|
24
25
|
const MENTION = { link: 'text-link' };
|
|
25
|
-
const FAILED = {
|
|
26
|
+
const FAILED = { error: 'text-error' };
|
|
26
27
|
const CARD_SURFACE = { card: 'bg-card' };
|
|
27
28
|
const CARD_EDGE = {
|
|
28
29
|
'border-subtle': 'border-border-subtle',
|
|
@@ -30,7 +31,7 @@ const CARD_EDGE = {
|
|
|
30
31
|
const DIVIDE = {
|
|
31
32
|
'border-subtle': 'divide-border-subtle',
|
|
32
33
|
};
|
|
33
|
-
const QUOTE_SURFACE = {
|
|
34
|
+
const QUOTE_SURFACE = { 'nested-1': 'bg-nested-1' };
|
|
34
35
|
const QUOTE_EDGE = {
|
|
35
36
|
'border-subtle': 'border-border-subtle',
|
|
36
37
|
};
|
|
@@ -199,12 +200,12 @@ export function DSCommentThread({ comments, now, currentUserId, label, draft, on
|
|
|
199
200
|
}, people: people, records: records, rows: 2, fieldRef: editorRef, onSubmit: () => {
|
|
200
201
|
if (commentThreadCanPost(editing.body))
|
|
201
202
|
onEdit(comment.id, editing.body);
|
|
202
|
-
} }), _jsxs("div", { className: "flex gap-2", children: [_jsx(DSButton, { size: "sm",
|
|
203
|
+
} }), _jsxs("div", { className: "flex justify-end gap-2", children: [_jsx(DSButton, { size: "sm", variant: "secondary", onClick: () => {
|
|
204
|
+
cancelEdit(comment.id);
|
|
205
|
+
}, children: COMMON_COPY.cancel }), _jsx(DSButton, { size: "sm", disabled: !commentThreadCanPost(editing.body), onClick: () => {
|
|
203
206
|
onEdit(comment.id, editing.body);
|
|
204
207
|
focusNext.current = () => moreRefs.current.get(comment.id)?.focus();
|
|
205
|
-
}, children: "Save" }), _jsx(DSButton, { size: "sm", variant: "
|
|
206
|
-
cancelEdit(comment.id);
|
|
207
|
-
}, children: "Cancel" })] })] })) : (_jsx(Body, { body: comment.body, mentionHref: mentionHref })), statusText !== undefined && (_jsxs("div", { className: cn('flex flex-wrap items-center gap-2 text-body-sm', status === 'failed' ? FAILED.destructive : META['muted-foreground']), children: [status === 'failed' && _jsx(TriangleAlert, { "aria-hidden": true, className: "size-4" }), _jsx("span", { children: statusText }), status === 'failed' && (_jsxs(_Fragment, { children: [_jsx(DSButton, { size: "sm", variant: "outline", onClick: (event) => {
|
|
208
|
+
}, children: "Save" })] })] })) : (_jsx(Body, { body: comment.body, mentionHref: mentionHref })), statusText !== undefined && (_jsxs("div", { className: cn('flex flex-wrap items-center gap-2 text-body-sm', status === 'failed' ? FAILED.error : META['muted-foreground']), children: [status === 'failed' && _jsx(TriangleAlert, { "aria-hidden": true, className: "size-4" }), _jsx("span", { children: statusText }), status === 'failed' && (_jsxs(_Fragment, { children: [_jsx(DSButton, { size: "sm", variant: "outline", onClick: (event) => {
|
|
208
209
|
retried.current = comment.id;
|
|
209
210
|
retryPressed(event);
|
|
210
211
|
onRetry(comment.id);
|
|
@@ -212,14 +213,14 @@ export function DSCommentThread({ comments, now, currentUserId, label, draft, on
|
|
|
212
213
|
discardTarget.current = afterDiscard(comment.id);
|
|
213
214
|
discardPressed(event);
|
|
214
215
|
onDiscard(comment.id);
|
|
215
|
-
}, children: "Discard" })] }))] })), confirming === comment.id ? (_jsxs("div", { role: "group", "aria-label": "Delete this comment?", className: "flex flex-wrap items-center gap-2 text-body-sm", ...confirmFocus.props, children: [_jsx("span", { className: "text-foreground", children: "Delete this comment? This cannot be undone." }), _jsx(DSButton, { size: "sm", variant: "
|
|
216
|
+
}, children: "Discard" })] }))] })), confirming === comment.id ? (_jsxs("div", { role: "group", "aria-label": "Delete this comment?", className: "flex flex-wrap items-center gap-2 text-body-sm", ...confirmFocus.props, children: [_jsx("span", { className: "text-foreground", children: "Delete this comment? This cannot be undone." }), _jsx(DSButton, { ref: cancelRef, size: "sm", variant: "secondary", onClick: () => {
|
|
217
|
+
keepComment(comment.id);
|
|
218
|
+
}, children: "Keep comment" }), _jsx(DSButton, { size: "sm", variant: "destructive", onClick: () => {
|
|
216
219
|
setConfirming(undefined);
|
|
217
220
|
setSaid('Comment deleted');
|
|
218
221
|
onDelete(comment.id);
|
|
219
222
|
focusNext.current = () => listRef.current?.focus();
|
|
220
|
-
}, children: "Delete" })
|
|
221
|
-
keepComment(comment.id);
|
|
222
|
-
}, children: "Keep comment" })] })) : (!isEditing &&
|
|
223
|
+
}, children: "Delete" })] })) : (!isEditing &&
|
|
223
224
|
acts.length > 0 && (_jsxs("div", { className: "-ms-2 flex items-center gap-1", children: [acts.includes('reply') && (_jsx(DSButton, { size: "sm", variant: "ghost", "aria-describedby": authorId, onClick: () => {
|
|
224
225
|
act(comment, 'reply');
|
|
225
226
|
}, children: "Reply" })), menuActs.length > 0 && (_jsxs(_Fragment, { children: [_jsx(DSIconButton, { ref: (node) => {
|
|
@@ -209,7 +209,7 @@ export declare function canAddGroup(tree: ConditionGroup, groupId: string): bool
|
|
|
209
209
|
export declare function conditionCount(tree: ConditionGroup): number;
|
|
210
210
|
export declare function conditionPositions(tree: ConditionGroup): ReadonlyMap<string, string>;
|
|
211
211
|
/** A node's name as its controls are labelled, "Condition 2", "Group 3", "Condition 3.1". */
|
|
212
|
-
export declare function nodeLabel(tree: ConditionGroup, id: string): string;
|
|
212
|
+
export declare function nodeLabel(tree: ConditionGroup, id: string, copy?: ConditionBuilderCopy): string;
|
|
213
213
|
export declare function createCondition(id: string): ConditionRule;
|
|
214
214
|
export declare function createGroup(id: string, conjunction: ConditionConjunction, children?: readonly ConditionNode[]): ConditionGroup;
|
|
215
215
|
export declare function oppositeConjunction(conjunction: ConditionConjunction): ConditionConjunction;
|
|
@@ -282,12 +282,96 @@ export declare const CONDITION_CONJUNCTION_LABELS: {
|
|
|
282
282
|
};
|
|
283
283
|
/** The small word drawn between rows: "and" in an all-group, "or" in an any-group. */
|
|
284
284
|
export declare function conditionJoinWord(conjunction: ConditionConjunction): 'and' | 'or';
|
|
285
|
+
/** The words the builder draws itself, so a screen can swap any of them.
|
|
286
|
+
* Defaults are English, held here and not in the adapter. A name passed to a
|
|
287
|
+
* function is a row's name as `condition`, `group` or `allConditions` gave it. */
|
|
288
|
+
export interface ConditionBuilderCopy {
|
|
289
|
+
/** What an empty group says in place of its rows, when no `emptyLabel` is given. */
|
|
290
|
+
empty: string;
|
|
291
|
+
/** The root group's name in what the builder says. */
|
|
292
|
+
allConditions: string;
|
|
293
|
+
/** A condition's name, given its position, "2.1". */
|
|
294
|
+
condition: (position: string) => string;
|
|
295
|
+
/** A group's name, given its position. */
|
|
296
|
+
group: (position: string) => string;
|
|
297
|
+
/** The conjunction picker's word for `all`. */
|
|
298
|
+
all: string;
|
|
299
|
+
/** The conjunction picker's word for `any`. */
|
|
300
|
+
any: string;
|
|
301
|
+
/** Drawn between rows in an all-group. */
|
|
302
|
+
and: string;
|
|
303
|
+
/** Drawn between rows in an any-group. */
|
|
304
|
+
or: string;
|
|
305
|
+
/** Drawn before the first row of a group. */
|
|
306
|
+
where: string;
|
|
307
|
+
/** Leads the root group's header. */
|
|
308
|
+
match: string;
|
|
309
|
+
/** Leads a nested group's header, given its name. */
|
|
310
|
+
groupMatch: (name: string) => string;
|
|
311
|
+
/** Follows the conjunction picker in a group's header. */
|
|
312
|
+
ofTheFollowing: string;
|
|
313
|
+
/** A group's accessible name, given its name and the conjunction's word. */
|
|
314
|
+
groupLabel: (name: string, conjunction: string) => string;
|
|
315
|
+
/** Names the conjunction picker, given the group's name. */
|
|
316
|
+
matchLabel: (name: string) => string;
|
|
317
|
+
/** Names the field picker, given the row's name. */
|
|
318
|
+
fieldLabel: (name: string) => string;
|
|
319
|
+
/** Names the comparison picker, given the row's name. */
|
|
320
|
+
comparisonLabel: (name: string) => string;
|
|
321
|
+
/** Names the value editor, given the row's name. */
|
|
322
|
+
valueLabel: (name: string) => string;
|
|
323
|
+
/** Names the first field of a range, given the row's name. */
|
|
324
|
+
fromLabel: (name: string) => string;
|
|
325
|
+
/** Names the second field of a range, given the row's name. */
|
|
326
|
+
toLabel: (name: string) => string;
|
|
327
|
+
/** Adds a unit or currency to a field's name. */
|
|
328
|
+
inUnit: (label: string, unit: string) => string;
|
|
329
|
+
/** Names the date button once a day is chosen, given its name and the day. */
|
|
330
|
+
dateLabel: (label: string, date: string) => string;
|
|
331
|
+
/** Writes a chosen day, given it as an ISO date. */
|
|
332
|
+
date: (iso: string) => string;
|
|
333
|
+
/** The words for a comparison in its picker. */
|
|
334
|
+
operator: (operator: ConditionOperator) => string;
|
|
335
|
+
/** The field picker's placeholder. */
|
|
336
|
+
chooseField: string;
|
|
337
|
+
/** The comparison picker's placeholder. */
|
|
338
|
+
comparison: string;
|
|
339
|
+
/** An option picker's placeholder. */
|
|
340
|
+
choose: string;
|
|
341
|
+
/** Between the two fields of a number or date range. */
|
|
342
|
+
rangeAnd: string;
|
|
343
|
+
/** Between the two fields of a time range. */
|
|
344
|
+
rangeTo: string;
|
|
345
|
+
/** Names a row's copy button, given its name. */
|
|
346
|
+
duplicate: (name: string) => string;
|
|
347
|
+
/** Names a row's remove button, given its name. */
|
|
348
|
+
remove: (name: string) => string;
|
|
349
|
+
/** The add condition button. */
|
|
350
|
+
addCondition: string;
|
|
351
|
+
/** Names a nested group's add condition button, given its name. */
|
|
352
|
+
addConditionTo: (name: string) => string;
|
|
353
|
+
/** The add group button. */
|
|
354
|
+
addGroup: string;
|
|
355
|
+
/** Names a nested group's add group button, given its name. */
|
|
356
|
+
addGroupTo: (name: string) => string;
|
|
357
|
+
/** Said when a row is added, given its name and the nested group it went into. */
|
|
358
|
+
added: (name: string, parent: string | undefined) => string;
|
|
359
|
+
/** Said after `added` when the new row is a group, given the conjunction's word. */
|
|
360
|
+
groupMatches: (conjunction: string) => string;
|
|
361
|
+
/** Said when a row is removed, given its name. */
|
|
362
|
+
removed: (name: string) => string;
|
|
363
|
+
/** Said when a row is removed and its group goes with it. */
|
|
364
|
+
removedWithGroup: (name: string, group: string) => string;
|
|
365
|
+
/** Said when a row is copied, given its name and the copy's. */
|
|
366
|
+
copied: (name: string, copy: string) => string;
|
|
367
|
+
}
|
|
368
|
+
export declare const CONDITION_BUILDER_COPY: ConditionBuilderCopy;
|
|
285
369
|
/** A group's accessible name, "Group 3, match any of". */
|
|
286
|
-
export declare function conditionGroupLabel(tree: ConditionGroup, groupId: string, rootLabel: string): string;
|
|
370
|
+
export declare function conditionGroupLabel(tree: ConditionGroup, groupId: string, rootLabel: string, copy?: ConditionBuilderCopy): string;
|
|
287
371
|
export declare const CONDITION_CHANGE_KINDS: readonly ["added", "removed", "duplicated"];
|
|
288
372
|
export type ConditionChangeKind = (typeof CONDITION_CHANGE_KINDS)[number];
|
|
289
373
|
/** What the live region says after a node is added, removed or copied, such as "Condition 2.3 added to group 2." */
|
|
290
|
-
export declare function conditionChangeAnnouncement(kind: ConditionChangeKind, before: ConditionGroup, after: ConditionGroup, id: string): string;
|
|
374
|
+
export declare function conditionChangeAnnouncement(kind: ConditionChangeKind, before: ConditionGroup, after: ConditionGroup, id: string, words?: ConditionBuilderCopy): string;
|
|
291
375
|
export declare const CONDITION_GROUP_SURFACES: {
|
|
292
376
|
readonly 1: "background";
|
|
293
377
|
readonly 2: "muted";
|
|
@@ -295,7 +379,10 @@ export declare const CONDITION_GROUP_SURFACES: {
|
|
|
295
379
|
};
|
|
296
380
|
export declare const CONDITION_GROUP_BORDER = "border";
|
|
297
381
|
export declare const CONDITION_JOIN_INK = "muted-foreground";
|
|
298
|
-
|
|
382
|
+
/** @deprecated Not read by the renderer. A row's error is drawn by
|
|
383
|
+
* `DSHelperText` in its error tone, which owns the ink; use that. Kept because
|
|
384
|
+
* the package exports it. */
|
|
385
|
+
export declare const CONDITION_ERROR_INK = "error";
|
|
299
386
|
export type ConditionGroupSurfaceRole = (typeof CONDITION_GROUP_SURFACES)[1 | 2 | 3];
|
|
300
387
|
export type ConditionGroupBorderRole = typeof CONDITION_GROUP_BORDER;
|
|
301
388
|
export type ConditionJoinInkRole = typeof CONDITION_JOIN_INK;
|
|
@@ -314,4 +401,9 @@ export interface ConditionBuilderContract {
|
|
|
314
401
|
label: string;
|
|
315
402
|
/** Prevents every change and dims the controls. */
|
|
316
403
|
disabled?: Forwarded<boolean>;
|
|
404
|
+
/** Replaces any of the words the builder draws itself (see `ConditionBuilderCopy`). */
|
|
405
|
+
copy?: Partial<ConditionBuilderCopy>;
|
|
406
|
+
/** Shows the rule to read, in full ink, with nothing to change: every
|
|
407
|
+
* control is read-only and Add, Duplicate and Remove are not drawn. */
|
|
408
|
+
readOnly?: Forwarded<boolean>;
|
|
317
409
|
}
|