@eifi1/ui-kit 0.51.3 → 0.51.5
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 +6 -6
- package/dist/account/account-settings-labels.js.map +1 -1
- package/dist/account/account-settings.js +11 -9
- package/dist/account/account-settings.js.map +1 -1
- package/dist/account/delete-account-setting.js +56 -65
- package/dist/account/delete-account-setting.js.map +1 -1
- package/dist/account/email-change-setting-labels.js.map +1 -1
- package/dist/account/email-change-setting.js.map +1 -1
- package/dist/account/passkeys-setting.js.map +1 -1
- package/dist/account/sessions-setting.js.map +1 -1
- package/dist/admin/admin-action-confirm.js +1 -3
- package/dist/admin/admin-action-confirm.js.map +1 -1
- package/dist/admin/admin-action-log.js.map +1 -1
- package/dist/admin/admin-area-labels.js +4 -1
- package/dist/admin/admin-area-labels.js.map +1 -1
- package/dist/admin/admin-overview.js +19 -11
- package/dist/admin/admin-overview.js.map +1 -1
- package/dist/admin/admin-sections.js.map +1 -1
- package/dist/admin/admin-tool-links.d.ts +1 -1
- package/dist/admin/admin-tool-links.js +7 -1
- package/dist/admin/admin-tool-links.js.map +1 -1
- package/dist/admin/invitations-panel.js +2 -13
- package/dist/admin/invitations-panel.js.map +1 -1
- package/dist/admin/mail-test-card.js.map +1 -1
- package/dist/admin/reviewer-scope-editor.js +4 -11
- package/dist/admin/reviewer-scope-editor.js.map +1 -1
- package/dist/admin/role-select.js.map +1 -1
- package/dist/admin/user-roster.js +1 -9
- package/dist/admin/user-roster.js.map +1 -1
- package/dist/auth/accept-invitation.js.map +1 -1
- package/dist/auth/auth-errors.js.map +1 -1
- package/dist/auth/forgot-password-form.js +23 -31
- package/dist/auth/forgot-password-form.js.map +1 -1
- package/dist/auth/register-form.js.map +1 -1
- package/dist/auth/reset-password-form.js.map +1 -1
- package/dist/auth/sign-in-form.js +13 -5
- package/dist/auth/sign-in-form.js.map +1 -1
- package/dist/auth/verify-email.js +1 -8
- package/dist/auth/verify-email.js.map +1 -1
- package/dist/billing/billing-banner.js.map +1 -1
- package/dist/billing/billing-labels.js.map +1 -1
- package/dist/billing/checkout-processing.js.map +1 -1
- package/dist/billing/plan-card.js +91 -85
- package/dist/billing/plan-card.js.map +1 -1
- package/dist/billing/plan-limit-toast.js.map +1 -1
- package/dist/billing/plan-limit.js.map +1 -1
- package/dist/billing/plan-price.js.map +1 -1
- package/dist/billing/plan-switch.js.map +1 -1
- package/dist/billing/subscription-actions.js.map +1 -1
- package/dist/bin/eifi1-pay-page.mjs +6 -1
- package/dist/components/account-chips.js.map +1 -1
- package/dist/components/alert-banner.js +1 -5
- package/dist/components/alert-banner.js.map +1 -1
- package/dist/components/amount-input.js +29 -12
- package/dist/components/amount-input.js.map +1 -1
- package/dist/components/authed-image.js.map +1 -1
- package/dist/components/autocomplete.js.map +1 -1
- package/dist/components/bulk-action-bar.js +1 -4
- package/dist/components/bulk-action-bar.js.map +1 -1
- package/dist/components/button-group.js.map +1 -1
- package/dist/components/button-look.js.map +1 -1
- package/dist/components/button.js +1 -7
- package/dist/components/button.js.map +1 -1
- package/dist/components/calculator.js +5 -5
- package/dist/components/calculator.js.map +1 -1
- package/dist/components/calendar-heatmap.js +4 -10
- package/dist/components/calendar-heatmap.js.map +1 -1
- package/dist/components/card.js +1 -8
- package/dist/components/card.js.map +1 -1
- package/dist/components/chart-zoom-core.js +3 -17
- package/dist/components/chart-zoom-core.js.map +1 -1
- package/dist/components/chart.d.ts +1 -1
- package/dist/components/chart.js +4 -22
- package/dist/components/chart.js.map +1 -1
- package/dist/components/checkbox-group.js +1 -4
- package/dist/components/checkbox-group.js.map +1 -1
- package/dist/components/chip-input.js +4 -1
- package/dist/components/chip-input.js.map +1 -1
- package/dist/components/chip.js +10 -5
- package/dist/components/chip.js.map +1 -1
- package/dist/components/choice-card.js +58 -74
- package/dist/components/choice-card.js.map +1 -1
- package/dist/components/column-mapper-labels.js.map +1 -1
- package/dist/components/column-mapper.js +167 -227
- package/dist/components/column-mapper.js.map +1 -1
- package/dist/components/combobox-core.js +5 -9
- package/dist/components/combobox-core.js.map +1 -1
- package/dist/components/combobox.js +1 -4
- package/dist/components/combobox.js.map +1 -1
- package/dist/components/confirm-dialog.js.map +1 -1
- package/dist/components/copy-button.js.map +1 -1
- package/dist/components/country-select.d.ts +5 -4
- package/dist/components/country-select.js +3 -19
- package/dist/components/country-select.js.map +1 -1
- package/dist/components/currency-option-list.js +13 -11
- package/dist/components/currency-option-list.js.map +1 -1
- package/dist/components/currency-select.js +1 -6
- package/dist/components/currency-select.js.map +1 -1
- package/dist/components/danger-confirm.js.map +1 -1
- package/dist/components/data-table-cells.js.map +1 -1
- package/dist/components/data-table-column-settings.js.map +1 -1
- package/dist/components/data-table-filter-popover.js +2 -18
- package/dist/components/data-table-filter-popover.js.map +1 -1
- package/dist/components/data-table-filters.js.map +1 -1
- package/dist/components/data-table-fit.js +7 -5
- package/dist/components/data-table-fit.js.map +1 -1
- package/dist/components/data-table-groups.js +3 -1
- package/dist/components/data-table-groups.js.map +1 -1
- package/dist/components/data-table-head.js +49 -57
- package/dist/components/data-table-head.js.map +1 -1
- package/dist/components/data-table-mobile.js +31 -44
- package/dist/components/data-table-mobile.js.map +1 -1
- package/dist/components/data-table-pagination.js.map +1 -1
- package/dist/components/data-table-row-actions.js +19 -16
- package/dist/components/data-table-row-actions.js.map +1 -1
- package/dist/components/data-table-row.js.map +1 -1
- package/dist/components/data-table-shared.js.map +1 -1
- package/dist/components/data-table-sort.js.map +1 -1
- package/dist/components/data-table-virtual.js +4 -1
- package/dist/components/data-table-virtual.js.map +1 -1
- package/dist/components/data-table.d.ts +8 -0
- package/dist/components/data-table.js +30 -39
- package/dist/components/data-table.js.map +1 -1
- package/dist/components/date-picker.js +1 -6
- package/dist/components/date-picker.js.map +1 -1
- package/dist/components/date-range-picker.js.map +1 -1
- package/dist/components/description-list.js +10 -10
- package/dist/components/description-list.js.map +1 -1
- package/dist/components/dialog-frame.js +9 -2
- package/dist/components/dialog-frame.js.map +1 -1
- package/dist/components/disclosure.js +17 -27
- package/dist/components/disclosure.js.map +1 -1
- package/dist/components/dropdown.js +25 -35
- package/dist/components/dropdown.js.map +1 -1
- package/dist/components/empty-state.js.map +1 -1
- package/dist/components/entity-combobox.js.map +1 -1
- package/dist/components/error-boundary.js.map +1 -1
- package/dist/components/field-base.js +5 -5
- package/dist/components/field-base.js.map +1 -1
- package/dist/components/field-parts.d.ts +1 -1
- package/dist/components/field-parts.js +10 -14
- package/dist/components/field-parts.js.map +1 -1
- package/dist/components/field-sync.js +8 -10
- package/dist/components/field-sync.js.map +1 -1
- package/dist/components/file-button.js.map +1 -1
- package/dist/components/file-dropzone.js.map +1 -1
- package/dist/components/floating-panel.js +4 -1
- package/dist/components/floating-panel.js.map +1 -1
- package/dist/components/focus-ring.js.map +1 -1
- package/dist/components/form-actions.js.map +1 -1
- package/dist/components/grouped-picker.js +11 -12
- package/dist/components/grouped-picker.js.map +1 -1
- package/dist/components/hover-menu.js +1 -4
- package/dist/components/hover-menu.js.map +1 -1
- package/dist/components/iban-input-labels.js.map +1 -1
- package/dist/components/icon-button.js +4 -1
- package/dist/components/icon-button.js.map +1 -1
- package/dist/components/icon-picker.js +6 -10
- package/dist/components/icon-picker.js.map +1 -1
- package/dist/components/image-grid.js +41 -50
- package/dist/components/image-grid.js.map +1 -1
- package/dist/components/inline-edit-field.js.map +1 -1
- package/dist/components/inline-entity-combobox.js +6 -12
- package/dist/components/inline-entity-combobox.js.map +1 -1
- package/dist/components/input.js +14 -2
- package/dist/components/input.js.map +1 -1
- package/dist/components/jump-calendar.js +1 -7
- package/dist/components/jump-calendar.js.map +1 -1
- package/dist/components/legal-labels.js +8 -2
- package/dist/components/legal-labels.js.map +1 -1
- package/dist/components/legal-page.d.ts +18 -1
- package/dist/components/legal-page.js +27 -2
- package/dist/components/legal-page.js.map +1 -1
- package/dist/components/legal.d.ts +40 -5
- package/dist/components/legal.js +41 -5
- package/dist/components/legal.js.map +1 -1
- package/dist/components/lightbox.js.map +1 -1
- package/dist/components/line-items.js +26 -36
- package/dist/components/line-items.js.map +1 -1
- package/dist/components/list-labels.js +3 -1
- package/dist/components/list-labels.js.map +1 -1
- package/dist/components/list.d.ts +18 -1
- package/dist/components/list.js +54 -13
- package/dist/components/list.js.map +1 -1
- package/dist/components/measured-grid.js +29 -53
- package/dist/components/measured-grid.js.map +1 -1
- package/dist/components/menu-item.js.map +1 -1
- package/dist/components/mini-calendar.js +13 -31
- package/dist/components/mini-calendar.js.map +1 -1
- package/dist/components/money-field.js.map +1 -1
- package/dist/components/month-picker.js +10 -21
- package/dist/components/month-picker.js.map +1 -1
- package/dist/components/multi-entity-combobox.js +3 -16
- package/dist/components/multi-entity-combobox.js.map +1 -1
- package/dist/components/multi-select.js.map +1 -1
- package/dist/components/nav-pills.js +10 -1
- package/dist/components/nav-pills.js.map +1 -1
- package/dist/components/number-field.js.map +1 -1
- package/dist/components/number-input.js +1 -7
- package/dist/components/number-input.js.map +1 -1
- package/dist/components/numpad-sheet.js +1 -4
- package/dist/components/numpad-sheet.js.map +1 -1
- package/dist/components/one-time-code-input.js +1 -7
- package/dist/components/one-time-code-input.js.map +1 -1
- package/dist/components/page-contents.js +13 -22
- package/dist/components/page-contents.js.map +1 -1
- package/dist/components/page-header.js +1 -11
- package/dist/components/page-header.js.map +1 -1
- package/dist/components/password-strength-labels.js.map +1 -1
- package/dist/components/password-strength.js +2 -8
- package/dist/components/password-strength.js.map +1 -1
- package/dist/components/phone-input.js +42 -57
- package/dist/components/phone-input.js.map +1 -1
- package/dist/components/picker-sheet.js.map +1 -1
- package/dist/components/pie-chart.js +1 -8
- package/dist/components/pie-chart.js.map +1 -1
- package/dist/components/popover.js.map +1 -1
- package/dist/components/progress-bar.js +16 -9
- package/dist/components/progress-bar.js.map +1 -1
- package/dist/components/qr-code.js +1 -8
- package/dist/components/qr-code.js.map +1 -1
- package/dist/components/row-actions.js +5 -1
- package/dist/components/row-actions.js.map +1 -1
- package/dist/components/search-field.js.map +1 -1
- package/dist/components/select.js +28 -38
- package/dist/components/select.js.map +1 -1
- package/dist/components/separator.js +1 -5
- package/dist/components/separator.js.map +1 -1
- package/dist/components/series-chart-axes.js +4 -1
- package/dist/components/series-chart-axes.js.map +1 -1
- package/dist/components/series-chart-budget.js.map +1 -1
- package/dist/components/series-chart-ticks.js.map +1 -1
- package/dist/components/series-chart.js +29 -45
- package/dist/components/series-chart.js.map +1 -1
- package/dist/components/settings-fields.js +21 -17
- package/dist/components/settings-fields.js.map +1 -1
- package/dist/components/share-card.js +4 -9
- package/dist/components/share-card.js.map +1 -1
- package/dist/components/sign-chip.js.map +1 -1
- package/dist/components/signature-pad.js +4 -13
- package/dist/components/signature-pad.js.map +1 -1
- package/dist/components/signed-amount.js +12 -5
- package/dist/components/signed-amount.js.map +1 -1
- package/dist/components/skeleton.js +2 -17
- package/dist/components/skeleton.js.map +1 -1
- package/dist/components/slider.js +13 -36
- package/dist/components/slider.js.map +1 -1
- package/dist/components/sparkline.js.map +1 -1
- package/dist/components/stat-tile.js +14 -10
- package/dist/components/stat-tile.js.map +1 -1
- package/dist/components/swatch-picker.js +14 -4
- package/dist/components/swatch-picker.js.map +1 -1
- package/dist/components/swipeable-row.d.ts +1 -1
- package/dist/components/swipeable-row.js +1 -8
- package/dist/components/swipeable-row.js.map +1 -1
- package/dist/components/table-skeleton.js +4 -1
- package/dist/components/table-skeleton.js.map +1 -1
- package/dist/components/table.js +12 -9
- package/dist/components/table.js.map +1 -1
- package/dist/components/tabs.js +5 -24
- package/dist/components/tabs.js.map +1 -1
- package/dist/components/text-link.js.map +1 -1
- package/dist/components/text.js.map +1 -1
- package/dist/components/tile-radio.js +1 -7
- package/dist/components/tile-radio.js.map +1 -1
- package/dist/components/time-input.js.map +1 -1
- package/dist/components/toast.js.map +1 -1
- package/dist/components/toggle-group.js +6 -1
- package/dist/components/toggle-group.js.map +1 -1
- package/dist/components/toggle-legend.js +2 -11
- package/dist/components/toggle-legend.js.map +1 -1
- package/dist/components/tooltip.js +2 -22
- package/dist/components/tooltip.js.map +1 -1
- package/dist/components/translation-review-editor.js +1 -4
- package/dist/components/translation-review-editor.js.map +1 -1
- package/dist/components/translation-review-parts.d.ts +1 -1
- package/dist/components/translation-review-parts.js +7 -1
- package/dist/components/translation-review-parts.js.map +1 -1
- package/dist/components/translation-review.js +18 -7
- package/dist/components/translation-review.js.map +1 -1
- package/dist/components/tree-view.js +14 -10
- package/dist/components/tree-view.js.map +1 -1
- package/dist/components/treemap.js +1 -13
- package/dist/components/treemap.js.map +1 -1
- package/dist/components/trigger-aria.js.map +1 -1
- package/dist/components/use-table-state.js +14 -11
- package/dist/components/use-table-state.js.map +1 -1
- package/dist/components/user-avatar.js +3 -26
- package/dist/components/user-avatar.js.map +1 -1
- package/dist/demo/demo-start.js +8 -4
- package/dist/demo/demo-start.js.map +1 -1
- package/dist/eslint/index.js +1 -1
- package/dist/feedback/feedback-attachment-labels.js.map +1 -1
- package/dist/feedback/feedback-attachment.js +1 -8
- package/dist/feedback/feedback-attachment.js.map +1 -1
- package/dist/feedback/feedback-capture.d.ts +1 -1
- package/dist/feedback/feedback-capture.js +3 -1
- package/dist/feedback/feedback-capture.js.map +1 -1
- package/dist/feedback/feedback-comment-thread.js +27 -13
- package/dist/feedback/feedback-comment-thread.js.map +1 -1
- package/dist/feedback/feedback-context.js +1 -4
- package/dist/feedback/feedback-context.js.map +1 -1
- package/dist/feedback/feedback-dialog.js.map +1 -1
- package/dist/feedback/feedback-inbox.js.map +1 -1
- package/dist/feedback/feedback-public-list.js +7 -1
- package/dist/feedback/feedback-public-list.js.map +1 -1
- package/dist/feedback/feedback-record.js +1 -5
- package/dist/feedback/feedback-record.js.map +1 -1
- package/dist/feedback/feedback-replies.js +25 -10
- package/dist/feedback/feedback-replies.js.map +1 -1
- package/dist/feedback/feedback-row-detail.js.map +1 -1
- package/dist/feedback/feedback-status-undo.js.map +1 -1
- package/dist/feedback/feedback-submit-dialog.js.map +1 -1
- package/dist/feedback/feedback-table.d.ts +3 -1
- package/dist/feedback/feedback-table.js +22 -5
- package/dist/feedback/feedback-table.js.map +1 -1
- package/dist/feedback/feedback-thread.js +2 -13
- package/dist/feedback/feedback-thread.js.map +1 -1
- package/dist/feedback/feedback-vocabulary.js.map +1 -1
- package/dist/feedback/feedback-vote-button.js.map +1 -1
- package/dist/hooks/use-anchored-rect.js.map +1 -1
- package/dist/hooks/use-document-title.js.map +1 -1
- package/dist/hooks/use-file-drop.js.map +1 -1
- package/dist/hooks/use-file-picker-labels.js.map +1 -1
- package/dist/hooks/use-file-picker.js.map +1 -1
- package/dist/hooks/use-focus-trap.js.map +1 -1
- package/dist/hooks/use-overlay-history.js +10 -5
- package/dist/hooks/use-overlay-history.js.map +1 -1
- package/dist/hooks/use-row-swipe.d.ts +1 -1
- package/dist/hooks/use-row-swipe.js +1 -6
- package/dist/hooks/use-row-swipe.js.map +1 -1
- package/dist/i18n/defaults.js +1 -4
- package/dist/i18n/defaults.js.map +1 -1
- package/dist/i18n/german.js +15 -4
- package/dist/i18n/german.js.map +1 -1
- package/dist/i18n/kit-labels.js +2 -8
- package/dist/i18n/kit-labels.js.map +1 -1
- package/dist/i18n/languages.js.map +1 -1
- package/dist/i18n/locales/en.js +19 -4
- package/dist/i18n/locales/en.js.map +2 -2
- package/dist/i18n/locales/es.js +15 -4
- package/dist/i18n/locales/es.js.map +1 -1
- package/dist/i18n/locales/fr.js +15 -4
- package/dist/i18n/locales/fr.js.map +1 -1
- package/dist/i18n/locales/hu.js +15 -4
- package/dist/i18n/locales/hu.js.map +1 -1
- package/dist/i18n/locales/it.js +15 -4
- package/dist/i18n/locales/it.js.map +1 -1
- package/dist/i18n/locales/zh.js +11 -3
- package/dist/i18n/locales/zh.js.map +1 -1
- package/dist/i18n/plurals.js.map +1 -1
- package/dist/i18n/review.js +15 -7
- package/dist/i18n/review.js.map +1 -1
- package/dist/i18n/shared-labels.js.map +1 -1
- package/dist/index.d.ts +17 -17
- package/dist/index.js +40 -23
- package/dist/index.js.map +1 -1
- package/dist/landing/access.js +1 -4
- package/dist/landing/access.js.map +1 -1
- package/dist/landing/landing-sections.js +35 -38
- package/dist/landing/landing-sections.js.map +1 -1
- package/dist/landing/page-seo.js.map +1 -1
- package/dist/lib/calc.js.map +1 -1
- package/dist/lib/clipboard-minus.js.map +1 -1
- package/dist/lib/dates.js.map +1 -1
- package/dist/lib/decimal-marks.js.map +1 -1
- package/dist/lib/device-settings.js +2 -1
- package/dist/lib/device-settings.js.map +1 -1
- package/dist/lib/direction.js.map +1 -1
- package/dist/lib/iban.js.map +1 -1
- package/dist/lib/logger.js +1 -5
- package/dist/lib/logger.js.map +1 -1
- package/dist/lib/person-name.js.map +1 -1
- package/dist/lib/phone.js.map +1 -1
- package/dist/lib/qr-encode.js +344 -8
- package/dist/lib/qr-encode.js.map +1 -1
- package/dist/lib/session-refresh.js.map +1 -1
- package/dist/lib/table-text.js +15 -3
- package/dist/lib/table-text.js.map +1 -1
- package/dist/lib/text-match.d.ts +20 -0
- package/dist/lib/text-match.js +11 -1
- package/dist/lib/text-match.js.map +1 -1
- package/dist/lib/translation-review.js.map +1 -1
- package/dist/notifications/notification-inbox.js +63 -44
- package/dist/notifications/notification-inbox.js.map +1 -1
- package/dist/notifications/notification-parts.js.map +1 -1
- package/dist/notifications/notification-types-setting.js.map +1 -1
- package/dist/notifications/notifications-labels.js.map +1 -1
- package/dist/notifications/push-device-setting.js +6 -1
- package/dist/notifications/push-device-setting.js.map +1 -1
- package/dist/notifications/push-devices-setting.js.map +1 -1
- package/dist/notifications/push-worker.js.map +1 -1
- package/dist/notifications/quiet-hours-setting.js.map +1 -1
- package/dist/notifications/use-push-device.js +4 -1
- package/dist/notifications/use-push-device.js.map +1 -1
- package/dist/offline/pwa-update-prompt.d.ts +1 -1
- package/dist/offline/pwa-update-prompt.js +7 -1
- package/dist/offline/pwa-update-prompt.js.map +1 -1
- package/dist/offline/query-persistence.js.map +1 -1
- package/dist/offline.d.ts +1 -1
- package/dist/offline.js +6 -1
- package/dist/offline.js.map +1 -1
- package/dist/pay/pay.css +8 -1
- package/dist/rhf/fields.d.ts +1 -2
- package/dist/rhf/fields.js +1 -10
- package/dist/rhf/fields.js.map +1 -1
- package/dist/rhf/form-core.js +1 -4
- package/dist/rhf/form-core.js.map +1 -1
- package/dist/rhf/line-items.js.map +1 -1
- package/dist/rhf/use-rhf-wizard-step.js.map +1 -1
- package/dist/search/command-palette.js +71 -62
- package/dist/search/command-palette.js.map +1 -1
- package/dist/search/global-search.js +34 -5
- package/dist/search/global-search.js.map +1 -1
- package/dist/search/search-index.js.map +1 -1
- package/dist/settings/device-reset-setting.js +1 -6
- package/dist/settings/device-reset-setting.js.map +1 -1
- package/dist/settings/settings-heading.js.map +1 -1
- package/dist/settings/settings-layout.js +9 -20
- package/dist/settings/settings-layout.js.map +1 -1
- package/dist/settings/use-settings-focus.d.ts +7 -0
- package/dist/settings/use-settings-focus.js +2 -0
- package/dist/settings/use-settings-focus.js.map +1 -1
- package/dist/settings/use-settings-route.js.map +1 -1
- package/dist/shell/app-shell.js +62 -31
- package/dist/shell/app-shell.js.map +1 -1
- package/dist/shell/auth-layout.js +1 -10
- package/dist/shell/auth-layout.js.map +1 -1
- package/dist/shell/dev-menu.d.ts +5 -0
- package/dist/shell/dev-menu.js +14 -7
- package/dist/shell/dev-menu.js.map +1 -1
- package/dist/shell/option-switcher-menu.js.map +1 -1
- package/dist/shell/sync-status-indicator.js +7 -6
- package/dist/shell/sync-status-indicator.js.map +1 -1
- package/dist/shell/top-bar-parts-labels.js.map +1 -1
- package/dist/shell/topbar-action-menu.d.ts +14 -1
- package/dist/shell/topbar-action-menu.js +85 -34
- package/dist/shell/topbar-action-menu.js.map +1 -1
- package/dist/shell/topbar-controls.js +1 -10
- package/dist/shell/topbar-controls.js.map +1 -1
- package/dist/shell/tour-menu.js +9 -1
- package/dist/shell/tour-menu.js.map +1 -1
- package/dist/shell.d.ts +1 -1
- package/dist/shell.js +2 -1
- package/dist/shell.js.map +1 -1
- package/dist/sync/db.js.map +1 -1
- package/dist/sync/engine.js +24 -6
- package/dist/sync/engine.js.map +1 -1
- package/dist/sync.d.ts +2 -2
- package/dist/sync.js +7 -1
- package/dist/sync.js.map +1 -1
- package/dist/testing/css-variables.js.map +1 -1
- package/dist/testing/index.d.ts +1 -1
- package/dist/testing/index.js +1 -3
- package/dist/testing/index.js.map +1 -1
- package/dist/testing/react.js.map +1 -1
- package/dist/testing/viewport.js +7 -4
- package/dist/testing/viewport.js.map +1 -1
- package/dist/theme/contrast-tokens.js +13 -2
- package/dist/theme/contrast-tokens.js.map +1 -1
- package/dist/theme/palette-derive.d.ts +1 -1
- package/dist/theme/palette-derive.js +18 -29
- package/dist/theme/palette-derive.js.map +1 -1
- package/dist/theme/palette-presets.js.map +1 -1
- package/dist/theme/palette-store.js.map +1 -1
- package/dist/theme/text-size.js.map +1 -1
- package/dist/theme/theme-store.js +1 -3
- package/dist/theme/theme-store.js.map +1 -1
- package/dist/tour/tour-catalogue.js.map +1 -1
- package/dist/tour/tour-dock.js +5 -1
- package/dist/tour/tour-dock.js.map +1 -1
- package/dist/tour/tour-engine.js +1 -4
- package/dist/tour/tour-engine.js.map +1 -1
- package/dist/tour/tour.js +21 -12
- package/dist/tour/tour.js.map +1 -1
- package/dist/tour/use-tour-progress.js.map +1 -1
- package/dist/tour/use-tour-url-sync.js.map +1 -1
- package/dist/wizard/stepper-nav.js +3 -24
- package/dist/wizard/stepper-nav.js.map +1 -1
- package/dist/wizard/types.js.map +1 -1
- package/dist/wizard/use-wizard.js +24 -28
- package/dist/wizard/use-wizard.js.map +1 -1
- package/dist/wizard/validation.js.map +1 -1
- package/dist/wizard/wizard-context.js.map +1 -1
- package/dist/wizard/wizard-step.d.ts +1 -1
- package/dist/wizard/wizard-step.js +1 -8
- package/dist/wizard/wizard-step.js.map +1 -1
- package/dist/wizard/wizard-summary.js.map +1 -1
- package/package.json +5 -2
- package/src/account/account-settings-labels.ts +1 -2
- package/src/account/account-settings.tsx +11 -17
- package/src/account/delete-account-setting.tsx +1 -6
- package/src/account/email-change-setting-labels.ts +1 -2
- package/src/account/email-change-setting.tsx +3 -1
- package/src/account/passkeys-setting.tsx +1 -3
- package/src/account/sessions-setting.tsx +4 -2
- package/src/admin/admin-action-confirm.tsx +4 -7
- package/src/admin/admin-action-log.tsx +29 -29
- package/src/admin/admin-area-labels.ts +4 -1
- package/src/admin/admin-overview.tsx +8 -2
- package/src/admin/admin-sections.tsx +3 -1
- package/src/admin/admin-tool-links.tsx +7 -1
- package/src/admin/invitations-panel.tsx +5 -11
- package/src/admin/mail-test-card.tsx +1 -2
- package/src/admin/reviewer-scope-editor.tsx +4 -9
- package/src/admin/role-select.tsx +4 -2
- package/src/admin/user-roster.tsx +2 -11
- package/src/auth/accept-invitation.tsx +1 -7
- package/src/auth/auth-errors.ts +1 -6
- package/src/auth/forgot-password-form.tsx +2 -7
- package/src/auth/register-form.tsx +7 -8
- package/src/auth/reset-password-form.tsx +2 -5
- package/src/auth/sign-in-form.tsx +15 -14
- package/src/auth/verify-email.tsx +2 -7
- package/src/billing/billing-banner.tsx +3 -7
- package/src/billing/billing-labels.ts +6 -4
- package/src/billing/checkout-processing.ts +0 -1
- package/src/billing/plan-card.tsx +9 -8
- package/src/billing/plan-limit-toast.tsx +1 -2
- package/src/billing/plan-limit.ts +1 -2
- package/src/billing/plan-price.ts +1 -4
- package/src/billing/plan-switch.tsx +1 -2
- package/src/billing/subscription-actions.tsx +5 -2
- package/src/components/account-chips.tsx +1 -7
- package/src/components/alert-banner.tsx +2 -8
- package/src/components/amount-input.tsx +206 -178
- package/src/components/authed-image.tsx +7 -4
- package/src/components/autocomplete.tsx +7 -9
- package/src/components/bulk-action-bar.tsx +2 -7
- package/src/components/button-group.tsx +1 -2
- package/src/components/button-look.ts +6 -17
- package/src/components/button.tsx +1 -4
- package/src/components/calculator.tsx +6 -9
- package/src/components/calendar-heatmap.tsx +5 -10
- package/src/components/card.tsx +9 -13
- package/src/components/chart-zoom-core.tsx +6 -33
- package/src/components/chart.tsx +8 -31
- package/src/components/checkbox-group.tsx +1 -4
- package/src/components/chip-input.tsx +6 -6
- package/src/components/chip.tsx +14 -26
- package/src/components/choice-card.tsx +4 -18
- package/src/components/column-mapper-labels.ts +3 -10
- package/src/components/column-mapper.tsx +33 -122
- package/src/components/combobox-core.tsx +17 -47
- package/src/components/combobox.tsx +2 -6
- package/src/components/confirm-dialog.tsx +1 -3
- package/src/components/copy-button.tsx +2 -4
- package/src/components/country-select.tsx +9 -21
- package/src/components/currency-option-list.tsx +16 -18
- package/src/components/currency-select.tsx +2 -7
- package/src/components/danger-confirm.tsx +8 -9
- package/src/components/data-table-cells.tsx +1 -2
- package/src/components/data-table-column-settings.tsx +1 -3
- package/src/components/data-table-filter-popover.tsx +5 -19
- package/src/components/data-table-filters.ts +1 -6
- package/src/components/data-table-fit.ts +7 -7
- package/src/components/data-table-groups.tsx +3 -1
- package/src/components/data-table-head.tsx +32 -46
- package/src/components/data-table-mobile.tsx +99 -108
- package/src/components/data-table-pagination.tsx +2 -6
- package/src/components/data-table-row-actions.tsx +25 -24
- package/src/components/data-table-row.tsx +16 -17
- package/src/components/data-table-shared.tsx +10 -16
- package/src/components/data-table-sort.ts +1 -2
- package/src/components/data-table-virtual.ts +9 -4
- package/src/components/data-table.tsx +497 -501
- package/src/components/date-picker.tsx +1 -7
- package/src/components/date-range-picker.tsx +3 -13
- package/src/components/description-list.tsx +7 -13
- package/src/components/dialog-frame.tsx +12 -3
- package/src/components/disclosure.tsx +8 -12
- package/src/components/dropdown.tsx +3 -11
- package/src/components/empty-state.tsx +1 -3
- package/src/components/entity-combobox.tsx +2 -6
- package/src/components/error-boundary.tsx +7 -7
- package/src/components/field-base.tsx +8 -14
- package/src/components/field-parts.tsx +12 -23
- package/src/components/field-sync.tsx +7 -11
- package/src/components/file-button.tsx +7 -3
- package/src/components/file-dropzone.tsx +7 -12
- package/src/components/floating-panel.tsx +44 -51
- package/src/components/focus-ring.ts +1 -2
- package/src/components/form-actions.tsx +1 -4
- package/src/components/grouped-picker.tsx +21 -16
- package/src/components/hover-menu.tsx +1 -4
- package/src/components/iban-input-labels.ts +1 -2
- package/src/components/icon-button.tsx +46 -48
- package/src/components/icon-picker.tsx +9 -20
- package/src/components/image-grid.tsx +1 -6
- package/src/components/inline-edit-field.tsx +1 -5
- package/src/components/inline-entity-combobox.tsx +11 -25
- package/src/components/input.tsx +14 -2
- package/src/components/jump-calendar.tsx +2 -6
- package/src/components/legal-labels.ts +8 -3
- package/src/components/legal-page.tsx +56 -6
- package/src/components/legal.tsx +83 -10
- package/src/components/lightbox.tsx +1 -3
- package/src/components/line-items.tsx +7 -15
- package/src/components/list-labels.ts +2 -0
- package/src/components/list.tsx +81 -27
- package/src/components/measured-grid.tsx +8 -30
- package/src/components/menu-item.tsx +1 -3
- package/src/components/mini-calendar.tsx +129 -159
- package/src/components/money-field.tsx +4 -2
- package/src/components/month-picker.tsx +14 -21
- package/src/components/multi-entity-combobox.tsx +6 -26
- package/src/components/multi-select.tsx +5 -9
- package/src/components/nav-pills.tsx +10 -2
- package/src/components/number-field.tsx +18 -15
- package/src/components/number-input.tsx +3 -19
- package/src/components/numpad-sheet.tsx +9 -13
- package/src/components/one-time-code-input.tsx +6 -11
- package/src/components/page-contents.tsx +2 -9
- package/src/components/page-header.tsx +5 -10
- package/src/components/password-strength-labels.ts +1 -2
- package/src/components/password-strength.tsx +6 -9
- package/src/components/phone-input.tsx +2 -13
- package/src/components/picker-sheet.tsx +2 -5
- package/src/components/pie-chart.tsx +6 -12
- package/src/components/popover.tsx +2 -1
- package/src/components/progress-bar.tsx +16 -25
- package/src/components/qr-code.tsx +2 -9
- package/src/components/row-actions.tsx +9 -1
- package/src/components/search-field.tsx +4 -5
- package/src/components/select.tsx +2 -10
- package/src/components/separator.tsx +1 -5
- package/src/components/series-chart-axes.ts +5 -5
- package/src/components/series-chart-budget.ts +1 -4
- package/src/components/series-chart-ticks.ts +1 -4
- package/src/components/series-chart.tsx +43 -83
- package/src/components/settings-fields.tsx +20 -15
- package/src/components/share-card.tsx +6 -14
- package/src/components/sign-chip.tsx +16 -16
- package/src/components/signature-pad.tsx +21 -13
- package/src/components/signed-amount.tsx +6 -14
- package/src/components/skeleton.tsx +2 -13
- package/src/components/slider.tsx +9 -20
- package/src/components/sparkline.tsx +2 -13
- package/src/components/stat-tile.tsx +13 -24
- package/src/components/swatch-picker.tsx +8 -3
- package/src/components/swipeable-row.tsx +2 -11
- package/src/components/table-skeleton.tsx +4 -1
- package/src/components/table.tsx +12 -8
- package/src/components/tabs.tsx +24 -39
- package/src/components/text-link.tsx +6 -6
- package/src/components/text.tsx +1 -2
- package/src/components/tile-radio.tsx +6 -19
- package/src/components/time-input.tsx +4 -5
- package/src/components/toast.tsx +3 -12
- package/src/components/toggle-group.tsx +9 -9
- package/src/components/toggle-legend.tsx +4 -16
- package/src/components/tooltip.tsx +9 -48
- package/src/components/translation-review-editor.tsx +4 -4
- package/src/components/translation-review-parts.tsx +7 -1
- package/src/components/translation-review.tsx +15 -16
- package/src/components/tree-view.tsx +17 -20
- package/src/components/treemap.tsx +3 -15
- package/src/components/trigger-aria.ts +1 -4
- package/src/components/use-table-state.ts +16 -17
- package/src/components/user-avatar.tsx +4 -21
- package/src/demo/demo-start.tsx +8 -4
- package/src/feedback/feedback-attachment-labels.ts +2 -1
- package/src/feedback/feedback-attachment.tsx +16 -29
- package/src/feedback/feedback-capture.ts +3 -1
- package/src/feedback/feedback-comment-thread.tsx +9 -6
- package/src/feedback/feedback-context.tsx +1 -4
- package/src/feedback/feedback-dialog.tsx +3 -4
- package/src/feedback/feedback-inbox.tsx +3 -9
- package/src/feedback/feedback-public-list.tsx +7 -1
- package/src/feedback/feedback-record.ts +6 -14
- package/src/feedback/feedback-replies.tsx +10 -5
- package/src/feedback/feedback-row-detail.tsx +2 -5
- package/src/feedback/feedback-status-undo.ts +1 -4
- package/src/feedback/feedback-submit-dialog.tsx +4 -4
- package/src/feedback/feedback-table.tsx +29 -9
- package/src/feedback/feedback-thread.tsx +4 -16
- package/src/feedback/feedback-vocabulary.ts +72 -82
- package/src/feedback/feedback-vote-button.tsx +9 -8
- package/src/hooks/use-anchored-rect.ts +1 -4
- package/src/hooks/use-document-title.ts +3 -1
- package/src/hooks/use-file-drop.ts +1 -3
- package/src/hooks/use-file-picker-labels.ts +1 -2
- package/src/hooks/use-file-picker.tsx +1 -5
- package/src/hooks/use-focus-trap.ts +1 -2
- package/src/hooks/use-overlay-history.ts +10 -5
- package/src/hooks/use-row-swipe.ts +1 -6
- package/src/i18n/defaults.ts +1 -4
- package/src/i18n/german.ts +42 -50
- package/src/i18n/kit-labels.tsx +5 -20
- package/src/i18n/languages.ts +2 -8
- package/src/i18n/locales/en.ts +15 -31
- package/src/i18n/locales/es.ts +44 -50
- package/src/i18n/locales/fr.ts +43 -52
- package/src/i18n/locales/hu.ts +35 -38
- package/src/i18n/locales/it.ts +44 -53
- package/src/i18n/locales/zh.ts +23 -33
- package/src/i18n/plurals.ts +4 -1
- package/src/i18n/review.ts +20 -7
- package/src/i18n/shared-labels.ts +1 -2
- package/src/index.ts +107 -32
- package/src/landing/access.ts +2 -7
- package/src/landing/landing-sections.tsx +14 -15
- package/src/landing/page-seo.ts +1 -3
- package/src/lib/calc.ts +4 -1
- package/src/lib/clipboard-minus.ts +4 -1
- package/src/lib/dates.ts +2 -10
- package/src/lib/decimal-marks.ts +1 -3
- package/src/lib/device-settings.ts +2 -1
- package/src/lib/direction.ts +1 -3
- package/src/lib/iban.ts +89 -9
- package/src/lib/logger.ts +1 -5
- package/src/lib/person-name.ts +1 -3
- package/src/lib/phone.ts +5 -8
- package/src/lib/qr-encode.ts +32 -8
- package/src/lib/session-refresh.ts +5 -6
- package/src/lib/table-text.ts +24 -6
- package/src/lib/text-match.ts +43 -1
- package/src/lib/translation-review.ts +1 -3
- package/src/notifications/notification-inbox.tsx +17 -4
- package/src/notifications/notification-parts.tsx +1 -2
- package/src/notifications/notification-types-setting.tsx +19 -18
- package/src/notifications/notifications-labels.ts +1 -2
- package/src/notifications/push-device-setting.tsx +7 -1
- package/src/notifications/push-devices-setting.tsx +7 -3
- package/src/notifications/push-worker.ts +10 -2
- package/src/notifications/quiet-hours-setting.tsx +4 -1
- package/src/notifications/use-push-device.ts +4 -1
- package/src/offline/pwa-update-prompt.tsx +7 -1
- package/src/offline/query-persistence.ts +9 -6
- package/src/offline.ts +6 -1
- package/src/rhf/fields.tsx +50 -19
- package/src/rhf/form-core.tsx +2 -6
- package/src/rhf/line-items.tsx +5 -7
- package/src/rhf/use-rhf-wizard-step.ts +3 -12
- package/src/search/command-palette.tsx +15 -23
- package/src/search/global-search.tsx +38 -8
- package/src/search/search-index.ts +5 -1
- package/src/settings/device-reset-setting.tsx +5 -8
- package/src/settings/settings-heading.tsx +3 -1
- package/src/settings/settings-layout.tsx +6 -13
- package/src/settings/use-settings-focus.ts +8 -0
- package/src/settings/use-settings-route.ts +4 -3
- package/src/shell/app-shell.tsx +48 -24
- package/src/shell/auth-layout.tsx +1 -6
- package/src/shell/dev-menu.tsx +18 -6
- package/src/shell/option-switcher-menu.tsx +1 -3
- package/src/shell/sync-status-indicator.tsx +14 -12
- package/src/shell/top-bar-parts-labels.ts +1 -3
- package/src/shell/topbar-action-menu.tsx +130 -45
- package/src/shell/topbar-controls.tsx +5 -19
- package/src/shell/tour-menu.tsx +9 -1
- package/src/shell.ts +1 -1
- package/src/sync/db.ts +5 -1
- package/src/sync/engine.ts +44 -12
- package/src/sync.ts +16 -2
- package/src/testing/css-variables.ts +1 -2
- package/src/testing/index.ts +1 -6
- package/src/testing/react.ts +1 -2
- package/src/testing/viewport.ts +9 -9
- package/src/theme/contrast-tokens.ts +13 -2
- package/src/theme/palette-derive.ts +24 -50
- package/src/theme/palette-presets.ts +0 -1
- package/src/theme/palette-store.ts +1 -4
- package/src/theme/text-size.ts +1 -1
- package/src/theme/theme-store.ts +2 -6
- package/src/tour/tour-catalogue.tsx +4 -2
- package/src/tour/tour-dock.ts +5 -1
- package/src/tour/tour-engine.ts +2 -6
- package/src/tour/tour.tsx +28 -12
- package/src/tour/use-tour-progress.ts +8 -2
- package/src/tour/use-tour-url-sync.ts +3 -1
- package/src/vite-env.d.ts +1 -4
- package/src/wizard/stepper-nav.tsx +10 -35
- package/src/wizard/types.ts +1 -4
- package/src/wizard/use-wizard.ts +28 -43
- package/src/wizard/validation.ts +1 -5
- package/src/wizard/wizard-context.tsx +2 -6
- package/src/wizard/wizard-step.tsx +1 -8
- package/src/wizard/wizard-summary.tsx +2 -6
- package/tokens.css +393 -152
|
@@ -67,7 +67,14 @@ import {
|
|
|
67
67
|
} from "./chart-zoom-core";
|
|
68
68
|
import { STEP_DASH, strokeDash, type LegendEntry } from "./toggle-legend";
|
|
69
69
|
import { DEFAULT_SERIES_CHART_LABELS, type SeriesChartLabels } from "./series-chart-labels";
|
|
70
|
-
import {
|
|
70
|
+
import {
|
|
71
|
+
categoryTicks,
|
|
72
|
+
integerTicks,
|
|
73
|
+
niceTicks,
|
|
74
|
+
tickTarget,
|
|
75
|
+
timeTicksWithUnit,
|
|
76
|
+
type TimeTickUnit,
|
|
77
|
+
} from "./series-chart-ticks";
|
|
71
78
|
// The tick module stays internal; the one type of it a public prop names is re-exported.
|
|
72
79
|
export type { TimeTickUnit } from "./series-chart-ticks";
|
|
73
80
|
import { autoAxisBudget, axisUnit, budgetedAxes, type SeriesChartAxisBudget } from "./series-chart-budget";
|
|
@@ -233,9 +240,7 @@ export type SeriesChartXValue = number | string | Date;
|
|
|
233
240
|
|
|
234
241
|
/** Ticks a caller decides — a list, or a function of the domain on show, so a zoom
|
|
235
242
|
* window gets ticks from the same rule instead of none. */
|
|
236
|
-
export type SeriesChartTickValues<T> =
|
|
237
|
-
| readonly T[]
|
|
238
|
-
| ((domain: [number, number]) => readonly T[] | undefined);
|
|
243
|
+
export type SeriesChartTickValues<T> = readonly T[] | ((domain: [number, number]) => readonly T[] | undefined);
|
|
239
244
|
|
|
240
245
|
interface SeriesChartAxisShape {
|
|
241
246
|
id: string;
|
|
@@ -312,8 +317,7 @@ interface SeriesChartAxisShape {
|
|
|
312
317
|
* pair, whose neighbour already said it). A HIDDEN axis scales its lines and draws
|
|
313
318
|
* nothing, so there is nowhere for a title to go.
|
|
314
319
|
*/
|
|
315
|
-
export type SeriesChartAxis = SeriesChartAxisShape &
|
|
316
|
-
({ title: string; hide?: false } | { title?: string; hide: true });
|
|
320
|
+
export type SeriesChartAxis = SeriesChartAxisShape & ({ title: string; hide?: false } | { title?: string; hide: true });
|
|
317
321
|
|
|
318
322
|
/**
|
|
319
323
|
* What a tick or the tooltip heading of the abscissa is handed besides its position —
|
|
@@ -408,7 +412,6 @@ export interface SeriesChartX {
|
|
|
408
412
|
/** Where the tooltip goes — see {@link SeriesChartTooltip.placement}. */
|
|
409
413
|
export type SeriesChartTooltipPlacement = ChartTooltipPlacement;
|
|
410
414
|
|
|
411
|
-
|
|
412
415
|
/**
|
|
413
416
|
* The placement a chart actually uses: its own, else the provider's, else `"cursor"`;
|
|
414
417
|
* `"auto"` is `"above"` on a phone (`phone`: below `sm`) and `"cursor"` from `sm` up.
|
|
@@ -479,15 +482,7 @@ export interface SeriesChartSpan {
|
|
|
479
482
|
/** The colours a reference or a marker can take by name — the kit's semantic tokens,
|
|
480
483
|
* so a threshold reads the same on every chart and flips with the theme. */
|
|
481
484
|
export type SeriesChartTone =
|
|
482
|
-
| "
|
|
483
|
-
| "brand"
|
|
484
|
-
| "income"
|
|
485
|
-
| "expense"
|
|
486
|
-
| "net"
|
|
487
|
-
| "success"
|
|
488
|
-
| "warning"
|
|
489
|
-
| "danger"
|
|
490
|
-
| "info";
|
|
485
|
+
"muted" | "brand" | "income" | "expense" | "net" | "success" | "warning" | "danger" | "info";
|
|
491
486
|
|
|
492
487
|
const TONE_COLOR: Record<SeriesChartTone, string> = {
|
|
493
488
|
muted: "var(--text-muted)",
|
|
@@ -806,9 +801,7 @@ interface PointStop {
|
|
|
806
801
|
function focusedBarShape(index: number) {
|
|
807
802
|
return function FocusedBar(props: BarShapeProps) {
|
|
808
803
|
const focused = props.originalDataIndex === index;
|
|
809
|
-
return (
|
|
810
|
-
<Rectangle {...props} {...(focused ? { stroke: "var(--text-primary)", strokeWidth: 2 } : {})} />
|
|
811
|
-
);
|
|
804
|
+
return <Rectangle {...props} {...(focused ? { stroke: "var(--text-primary)", strokeWidth: 2 } : {})} />;
|
|
812
805
|
};
|
|
813
806
|
}
|
|
814
807
|
|
|
@@ -826,13 +819,7 @@ const REFERENCE_LABEL_SIZE = 10;
|
|
|
826
819
|
* the card — "over the c" on a phone. The width is measured once drawn; the first
|
|
827
820
|
* frame (and a DOM without layout) uses a 0.6em-per-character estimate, which errs wide.
|
|
828
821
|
*/
|
|
829
|
-
function MarkerLabel({
|
|
830
|
-
viewBox,
|
|
831
|
-
value,
|
|
832
|
-
}: {
|
|
833
|
-
viewBox?: { x?: number; y?: number; width?: number };
|
|
834
|
-
value?: ReactNode;
|
|
835
|
-
}) {
|
|
822
|
+
function MarkerLabel({ viewBox, value }: { viewBox?: { x?: number; y?: number; width?: number }; value?: ReactNode }) {
|
|
836
823
|
const plot = usePlotArea();
|
|
837
824
|
const ref = useRef<SVGTextElement>(null);
|
|
838
825
|
const [measured, setMeasured] = useState<number>();
|
|
@@ -1060,12 +1047,7 @@ function SeriesPlot({
|
|
|
1060
1047
|
? []
|
|
1061
1048
|
: budgetedAxes(
|
|
1062
1049
|
afterCap,
|
|
1063
|
-
autoAxisBudget(
|
|
1064
|
-
afterCap,
|
|
1065
|
-
width,
|
|
1066
|
-
(axis) => axisBandWidth(axis.width, Boolean(axis.title), scale),
|
|
1067
|
-
scale,
|
|
1068
|
-
),
|
|
1050
|
+
autoAxisBudget(afterCap, width, (axis) => axisBandWidth(axis.width, Boolean(axis.title), scale), scale),
|
|
1069
1051
|
);
|
|
1070
1052
|
const budgeted = [...capped, ...auto];
|
|
1071
1053
|
const budgetKey = budgeted.join("\n");
|
|
@@ -1108,15 +1090,8 @@ function SeriesPlot({
|
|
|
1108
1090
|
// the moment a legend entry was switched off.
|
|
1109
1091
|
if (!model.source.length || !series.length) {
|
|
1110
1092
|
return (
|
|
1111
|
-
<div
|
|
1112
|
-
|
|
1113
|
-
style={heightStyle}
|
|
1114
|
-
>
|
|
1115
|
-
{empty !== undefined ? (
|
|
1116
|
-
empty
|
|
1117
|
-
) : (
|
|
1118
|
-
<p className="text-xs text-muted">{labels.empty}</p>
|
|
1119
|
-
)}
|
|
1093
|
+
<div className={cn("flex w-full items-center justify-center px-2 text-center", heightClass)} style={heightStyle}>
|
|
1094
|
+
{empty !== undefined ? empty : <p className="text-xs text-muted">{labels.empty}</p>}
|
|
1120
1095
|
</div>
|
|
1121
1096
|
);
|
|
1122
1097
|
}
|
|
@@ -1137,9 +1112,7 @@ function SeriesPlot({
|
|
|
1137
1112
|
const drawnAxes = budgeted.length
|
|
1138
1113
|
? axes.map((axis) => (budgeted.includes(axis.id) ? { ...axis, hide: true as const } : axis))
|
|
1139
1114
|
: axes;
|
|
1140
|
-
const lostUnit = new Map(
|
|
1141
|
-
axes.filter((axis) => budgeted.includes(axis.id)).map((axis) => [axis.id, axisUnit(axis)]),
|
|
1142
|
-
);
|
|
1115
|
+
const lostUnit = new Map(axes.filter((axis) => budgeted.includes(axis.id)).map((axis) => [axis.id, axisUnit(axis)]));
|
|
1143
1116
|
const config: ChartConfig = Object.fromEntries(
|
|
1144
1117
|
series.map((entry, index) => [
|
|
1145
1118
|
entry.key,
|
|
@@ -1185,14 +1158,11 @@ function SeriesPlot({
|
|
|
1185
1158
|
(model.kind === "category"
|
|
1186
1159
|
? [-0.5, rows.length - 0.5]
|
|
1187
1160
|
: padBand(
|
|
1188
|
-
...(extend(
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
...(markers ?? []).map((marker) => xPos(marker.x)),
|
|
1194
|
-
],
|
|
1195
|
-
) ?? [Infinity, -Infinity]),
|
|
1161
|
+
...(extend(undefined, [
|
|
1162
|
+
...allPlotted.map((row) => finite(row[xKey])),
|
|
1163
|
+
...xRefs.map((ref) => xPos(ref.value)),
|
|
1164
|
+
...(markers ?? []).map((marker) => xPos(marker.x)),
|
|
1165
|
+
]) ?? [Infinity, -Infinity]),
|
|
1196
1166
|
));
|
|
1197
1167
|
|
|
1198
1168
|
const timeUnit = model.kind === "time" ? timeTicksWithUnit(fittedX, ticksAim) : undefined;
|
|
@@ -1222,11 +1192,7 @@ function SeriesPlot({
|
|
|
1222
1192
|
...(timeUnit?.unit === "hour" ? { timeStyle: "short" } : {}),
|
|
1223
1193
|
});
|
|
1224
1194
|
const categoryText = (value: SeriesChartXValue) =>
|
|
1225
|
-
value instanceof Date
|
|
1226
|
-
? dateFormat.format(value)
|
|
1227
|
-
: typeof value === "number"
|
|
1228
|
-
? number(value)
|
|
1229
|
-
: String(value ?? "");
|
|
1195
|
+
value instanceof Date ? dateFormat.format(value) : typeof value === "number" ? number(value) : String(value ?? "");
|
|
1230
1196
|
const tickAt = (position: number): SeriesChartXTick => ({
|
|
1231
1197
|
value: model.valueAt(position),
|
|
1232
1198
|
...(model.kind === "category" ? { index: Math.round(position) } : {}),
|
|
@@ -1240,13 +1206,15 @@ function SeriesPlot({
|
|
|
1240
1206
|
: number(position);
|
|
1241
1207
|
const format = x.format ?? defaultFormat;
|
|
1242
1208
|
const xFormat = (position: number) => format(position, tickAt(position));
|
|
1243
|
-
const label =
|
|
1244
|
-
x.label ??
|
|
1245
|
-
(model.kind === "time" ? (position: number) => dateFormat.format(position) : format);
|
|
1209
|
+
const label = x.label ?? (model.kind === "time" ? (position: number) => dateFormat.format(position) : format);
|
|
1246
1210
|
const xLabel = (position: number) => label(position, tickAt(position));
|
|
1247
1211
|
|
|
1248
1212
|
const tickAngle = x.ticks === false ? 0 : (x.tickAngle ?? 0);
|
|
1249
|
-
const tickBand = tiltedTickBand(
|
|
1213
|
+
const tickBand = tiltedTickBand(
|
|
1214
|
+
(xTicks ?? []).map((tick) => xFormat(tick)),
|
|
1215
|
+
tickAngle,
|
|
1216
|
+
scale,
|
|
1217
|
+
);
|
|
1250
1218
|
|
|
1251
1219
|
const source: ZoomFitSource = {
|
|
1252
1220
|
rows: allPlotted,
|
|
@@ -1257,9 +1225,7 @@ function SeriesPlot({
|
|
|
1257
1225
|
// An axis a bar or an area stands on is read from zero (see `includeZero`).
|
|
1258
1226
|
const anchored = (axis: SeriesChartAxis) =>
|
|
1259
1227
|
axis.includeZero ??
|
|
1260
|
-
series.some(
|
|
1261
|
-
(entry) => (entry.axis ?? DEFAULT_Y_AXIS) === axis.id && (entry.type ?? "line") !== "line",
|
|
1262
|
-
);
|
|
1228
|
+
series.some((entry) => (entry.axis ?? DEFAULT_Y_AXIS) === axis.id && (entry.type ?? "line") !== "line");
|
|
1263
1229
|
// Whole-number ticks on an axis whose values are all whole — see
|
|
1264
1230
|
// `SeriesChartAxis.integerTicks`. A stack of whole layers sums to a whole number, so
|
|
1265
1231
|
// the layers are enough to look at.
|
|
@@ -1317,7 +1283,9 @@ function SeriesPlot({
|
|
|
1317
1283
|
const [low, high] = fittedX ?? [-Infinity, Infinity];
|
|
1318
1284
|
const placed = plotted
|
|
1319
1285
|
.map((row, index) => ({ index, at: model.kind === "category" ? index : finite(row[xKey]) }))
|
|
1320
|
-
.filter(
|
|
1286
|
+
.filter(
|
|
1287
|
+
(slot): slot is { index: number; at: number } => slot.at !== undefined && slot.at >= low && slot.at <= high,
|
|
1288
|
+
)
|
|
1321
1289
|
.sort((a, b) => a.at - b.at);
|
|
1322
1290
|
placed.forEach(({ index, at }, k) => {
|
|
1323
1291
|
const from = k > 0 ? (placed[k - 1].at + at) / 2 : low;
|
|
@@ -1449,28 +1417,19 @@ function SeriesPlot({
|
|
|
1449
1417
|
// other tick, keeping the last, gives 4 8 12 — still an even ruler.
|
|
1450
1418
|
interval="equidistantPreserveEnd"
|
|
1451
1419
|
tick={x.ticks === false ? false : undefined}
|
|
1452
|
-
{...(tickAngle
|
|
1453
|
-
? { angle: tickAngle, textAnchor: tickAngle < 0 ? "end" : "start" }
|
|
1454
|
-
: {})}
|
|
1420
|
+
{...(tickAngle ? { angle: tickAngle, textAnchor: tickAngle < 0 ? "end" : "start" } : {})}
|
|
1455
1421
|
// With neither ticks nor title there is nothing to reserve the band for, and
|
|
1456
1422
|
// recharts' own 30 px would leave a gap under every chart of a stack.
|
|
1457
1423
|
height={x.ticks === false && !x.title ? 4 : tickBand}
|
|
1458
1424
|
tickFormatter={(value: number) => xFormat(Number(value))}
|
|
1459
1425
|
>
|
|
1460
1426
|
{x.title && (
|
|
1461
|
-
<Label
|
|
1462
|
-
value={x.title}
|
|
1463
|
-
position="insideBottom"
|
|
1464
|
-
offset={-grow(12)}
|
|
1465
|
-
className="fill-muted text-caption"
|
|
1466
|
-
/>
|
|
1427
|
+
<Label value={x.title} position="insideBottom" offset={-grow(12)} className="fill-muted text-caption" />
|
|
1467
1428
|
)}
|
|
1468
1429
|
</XAxis>
|
|
1469
1430
|
{drawnAxes.map((axis) => {
|
|
1470
1431
|
const domain = fittedY(axis);
|
|
1471
|
-
const zoomed = anchored(axis)
|
|
1472
|
-
? zoom?.xDomain !== undefined
|
|
1473
|
-
: zoom?.yDomains[axis.id] !== undefined;
|
|
1432
|
+
const zoomed = anchored(axis) ? zoom?.xDomain !== undefined : zoom?.yDomains[axis.id] !== undefined;
|
|
1474
1433
|
return (
|
|
1475
1434
|
<YAxis
|
|
1476
1435
|
key={axis.id}
|
|
@@ -1577,7 +1536,12 @@ function SeriesPlot({
|
|
|
1577
1536
|
radius={entry.stack === undefined ? BAR_RADIUS : 0}
|
|
1578
1537
|
// Read off the row rather than recharts' `value`: in a stack that is the
|
|
1579
1538
|
// layer's running top, which a hole has too — and a hole gets no stub.
|
|
1580
|
-
{...(stub
|
|
1539
|
+
{...(stub
|
|
1540
|
+
? {
|
|
1541
|
+
minPointSize: (_value: unknown, index: number) =>
|
|
1542
|
+
finite(plotted[index]?.[entry.key]) === undefined ? 0 : stub,
|
|
1543
|
+
}
|
|
1544
|
+
: {})}
|
|
1581
1545
|
// Only the focused stop's series swaps its shape, and only for as long
|
|
1582
1546
|
// as it has focus: every other bar keeps recharts' own.
|
|
1583
1547
|
{...(focusedStop?.key === entry.key ? { shape: focusedBarShape(focusedStop.index) } : {})}
|
|
@@ -1692,11 +1656,7 @@ function SeriesPlot({
|
|
|
1692
1656
|
stroke="var(--bg-surface)"
|
|
1693
1657
|
strokeWidth={1.5}
|
|
1694
1658
|
ifOverflow="discard"
|
|
1695
|
-
label={
|
|
1696
|
-
marker.label
|
|
1697
|
-
? { value: marker.label, position: "top", content: <MarkerLabel /> }
|
|
1698
|
-
: undefined
|
|
1699
|
-
}
|
|
1659
|
+
label={marker.label ? { value: marker.label, position: "top", content: <MarkerLabel /> } : undefined}
|
|
1700
1660
|
/>
|
|
1701
1661
|
);
|
|
1702
1662
|
})}
|
|
@@ -34,8 +34,7 @@ import type { KitLanguageCode } from "../i18n/languages";
|
|
|
34
34
|
* The `Select` half of {@link ThemeSettingProps}; until 0.34 it carried that name, which
|
|
35
35
|
* left the toggle out of the type the component is documented by (API-9).
|
|
36
36
|
*/
|
|
37
|
-
export interface ThemeSettingSelectProps
|
|
38
|
-
extends Omit<SelectProps, "value" | "onChange" | "children"> {
|
|
37
|
+
export interface ThemeSettingSelectProps extends Omit<SelectProps, "value" | "onChange" | "children"> {
|
|
39
38
|
/** The `Select` (default). See {@link ThemeSettingToggleProps} for `"toggle"`. */
|
|
40
39
|
variant?: "select";
|
|
41
40
|
value: ThemePreference;
|
|
@@ -63,8 +62,7 @@ export interface ThemeSettingSelectProps
|
|
|
63
62
|
* system-dark device a control bound to the mode shows "dark" and cannot say "follow the
|
|
64
63
|
* system" (keksdose's control, §8).
|
|
65
64
|
*/
|
|
66
|
-
export interface ThemeSettingToggleProps
|
|
67
|
-
extends Omit<ToggleGroupBaseProps<ThemePreference>, "options" | "label"> {
|
|
65
|
+
export interface ThemeSettingToggleProps extends Omit<ToggleGroupBaseProps<ThemePreference>, "options" | "label"> {
|
|
68
66
|
variant: "toggle";
|
|
69
67
|
value: ThemePreference;
|
|
70
68
|
onChange: (value: ThemePreference) => void;
|
|
@@ -106,13 +104,7 @@ export function ThemeSetting(props: ThemeSettingProps) {
|
|
|
106
104
|
}
|
|
107
105
|
const { variant: _variant, value, onChange, label, optionLabels, id, ...rest } = props;
|
|
108
106
|
return (
|
|
109
|
-
<Select
|
|
110
|
-
{...rest}
|
|
111
|
-
id={id}
|
|
112
|
-
label={label}
|
|
113
|
-
value={value}
|
|
114
|
-
onChange={(e) => onChange(e.target.value as ThemePreference)}
|
|
115
|
-
>
|
|
107
|
+
<Select {...rest} id={id} label={label} value={value} onChange={(e) => onChange(e.target.value as ThemePreference)}>
|
|
116
108
|
<option value="system">{optionLabels.system}</option>
|
|
117
109
|
<option value="light">{optionLabels.light}</option>
|
|
118
110
|
<option value="dark">{optionLabels.dark}</option>
|
|
@@ -122,8 +114,7 @@ export function ThemeSetting(props: ThemeSettingProps) {
|
|
|
122
114
|
|
|
123
115
|
/** See {@link ThemeSettingSelectProps}: a `Select`'s props with the value and the change
|
|
124
116
|
* handler re-typed to the language CODE the caller stores. */
|
|
125
|
-
export interface LanguageSettingProps
|
|
126
|
-
extends Omit<SelectProps, "value" | "onChange" | "children" | "multiple"> {
|
|
117
|
+
export interface LanguageSettingProps extends Omit<SelectProps, "value" | "onChange" | "children" | "multiple"> {
|
|
127
118
|
/** The reader's language: one of the rows' codes — or any tag, shown as the row it
|
|
128
119
|
* resolves to ({@link LanguageSelect}'s rule). */
|
|
129
120
|
value: string;
|
|
@@ -190,7 +181,14 @@ export type TextSizeSettingProps = AppearanceToggleProps<TextSize>;
|
|
|
190
181
|
* phone the group has 240 px, and "Extra large" cut to "Extra l…" would be the one
|
|
191
182
|
* setting that cannot read its own value.
|
|
192
183
|
*/
|
|
193
|
-
export function TextSizeSetting({
|
|
184
|
+
export function TextSizeSetting({
|
|
185
|
+
value,
|
|
186
|
+
onChange,
|
|
187
|
+
label,
|
|
188
|
+
labels: labelsProp,
|
|
189
|
+
overflow = "wrap",
|
|
190
|
+
...rest
|
|
191
|
+
}: TextSizeSettingProps) {
|
|
194
192
|
const labels = useAppearanceLabels(labelsProp);
|
|
195
193
|
const named = label !== undefined && label !== null && label !== false;
|
|
196
194
|
return (
|
|
@@ -215,7 +213,14 @@ export type ContrastSettingProps = AppearanceToggleProps<ContrastMode>;
|
|
|
215
213
|
* "More" and could not say "follow the device" (the theme's lesson, §8 of the settings
|
|
216
214
|
* contract). `useAccountAppearance().contrast` is that mode.
|
|
217
215
|
*/
|
|
218
|
-
export function ContrastSetting({
|
|
216
|
+
export function ContrastSetting({
|
|
217
|
+
value,
|
|
218
|
+
onChange,
|
|
219
|
+
label,
|
|
220
|
+
labels: labelsProp,
|
|
221
|
+
overflow = "wrap",
|
|
222
|
+
...rest
|
|
223
|
+
}: ContrastSettingProps) {
|
|
219
224
|
const labels = useAppearanceLabels(labelsProp);
|
|
220
225
|
const named = label !== undefined && label !== null && label !== false;
|
|
221
226
|
return (
|
|
@@ -385,10 +385,7 @@ export function SharePanel({
|
|
|
385
385
|
{canAdd && (
|
|
386
386
|
<div className="space-y-2">
|
|
387
387
|
<div
|
|
388
|
-
className={cn(
|
|
389
|
-
"grid grid-cols-1 gap-2",
|
|
390
|
-
choosable && "sm:grid-cols-[minmax(0,1fr)_auto] sm:items-start",
|
|
391
|
-
)}
|
|
388
|
+
className={cn("grid grid-cols-1 gap-2", choosable && "sm:grid-cols-[minmax(0,1fr)_auto] sm:items-start")}
|
|
392
389
|
>
|
|
393
390
|
<Autocomplete<string>
|
|
394
391
|
label={addWithoutEmail ? labels.emailOptional : labels.email}
|
|
@@ -434,9 +431,7 @@ export function SharePanel({
|
|
|
434
431
|
value={newRole}
|
|
435
432
|
onChange={setNewRole}
|
|
436
433
|
disabled={busy !== null}
|
|
437
|
-
caption={
|
|
438
|
-
roles.some((r) => r.description) ? (key: string) => roleOf(key)?.description : undefined
|
|
439
|
-
}
|
|
434
|
+
caption={roles.some((r) => r.description) ? (key: string) => roleOf(key)?.description : undefined}
|
|
440
435
|
// Level with the floating field beside it, as the two apps do by hand.
|
|
441
436
|
optionClassName="sm:min-h-10"
|
|
442
437
|
/>
|
|
@@ -520,7 +515,8 @@ export function SharePanel({
|
|
|
520
515
|
if (next === g.role) return;
|
|
521
516
|
// A raise under a lock that allows only lowerings: refused,
|
|
522
517
|
// and the tooltip round the choice says why.
|
|
523
|
-
if (roleLock.raise !== undefined && roles.findIndex((r) => r.key === next) > rank)
|
|
518
|
+
if (roleLock.raise !== undefined && roles.findIndex((r) => r.key === next) > rank)
|
|
519
|
+
return;
|
|
524
520
|
void run(`role:${g.id}`, () => onRoleChange(g, next));
|
|
525
521
|
}}
|
|
526
522
|
/>
|
|
@@ -570,10 +566,7 @@ export function SharePanel({
|
|
|
570
566
|
<div className="min-w-0 flex-1 basis-40">
|
|
571
567
|
<div
|
|
572
568
|
data-private={p.email ? true : undefined}
|
|
573
|
-
className={cn(
|
|
574
|
-
"truncate-until-large text-sm",
|
|
575
|
-
p.email ? "text-primary" : "text-muted",
|
|
576
|
-
)}
|
|
569
|
+
className={cn("truncate-until-large text-sm", p.email ? "text-primary" : "text-muted")}
|
|
577
570
|
>
|
|
578
571
|
{name}
|
|
579
572
|
</div>
|
|
@@ -648,8 +641,7 @@ export function ShareCard({ title, variant = "outline", className, ...panel }: S
|
|
|
648
641
|
}
|
|
649
642
|
|
|
650
643
|
export interface ShareDialogProps
|
|
651
|
-
extends SharePanelProps,
|
|
652
|
-
Pick<DialogFrameProps, "open" | "onClose" | "size" | "className"> {
|
|
644
|
+
extends SharePanelProps, Pick<DialogFrameProps, "open" | "onClose" | "size" | "className"> {
|
|
653
645
|
/** The heading. Default {@link ShareCardLabels.dialogTitle}. */
|
|
654
646
|
title?: ReactNode;
|
|
655
647
|
/** Under the heading — what is being shared (Kurvenschmiede passes its name). */
|
|
@@ -86,23 +86,23 @@ export function SignChip({ negative, onNegativeChange, disabled, labels: labelsP
|
|
|
86
86
|
// and the bubble that said only that goes.
|
|
87
87
|
const large = useLargeText();
|
|
88
88
|
const chip = (
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
89
|
+
<Chip
|
|
90
|
+
size="lg"
|
|
91
|
+
tone={negative ? "expense" : "income"}
|
|
92
|
+
icon={negative ? Minus : Plus}
|
|
93
|
+
onClick={() => onNegativeChange(!negative)}
|
|
94
|
+
disabled={disabled}
|
|
95
|
+
aria-label={name}
|
|
96
|
+
// `gap-1.5 px-3`: the chip's narrower body, because on a 375px screen every
|
|
97
|
+
// pixel of it is taken from the figure beside it (#430). `md:py-2.5` with the
|
|
98
|
+
// hairline border is the 42px a labelled field measures (#431).
|
|
99
|
+
className={cn("shrink-0 gap-1.5 whitespace-nowrap px-3 font-medium md:min-h-0 md:py-2.5", !large && className)}
|
|
100
|
+
>
|
|
101
|
+
{current}
|
|
102
|
+
{/* The swap arrows after the word, in the label's own row: decoration (the
|
|
103
103
|
name already says what a press does), set a little apart from the word. */}
|
|
104
|
-
|
|
105
|
-
|
|
104
|
+
<ArrowUpDown className="ms-1.5 inline size-3.5 align-[-0.2em] opacity-60" aria-hidden />
|
|
105
|
+
</Chip>
|
|
106
106
|
);
|
|
107
107
|
if (!large) {
|
|
108
108
|
return (
|
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
import { useCallback, useEffect, useId, useImperativeHandle, useLayoutEffect, useRef, useState } from "react";
|
|
2
|
-
import type {
|
|
2
|
+
import type {
|
|
3
|
+
ComponentPropsWithoutRef,
|
|
4
|
+
ComponentPropsWithRef,
|
|
5
|
+
PointerEvent as ReactPointerEvent,
|
|
6
|
+
ReactNode,
|
|
7
|
+
Ref,
|
|
8
|
+
} from "react";
|
|
3
9
|
import { Eraser, Keyboard, PenLine, Undo2 } from "lucide-react";
|
|
4
10
|
import { cn } from "../lib/cn";
|
|
5
11
|
import { hasContent } from "../lib/presence";
|
|
@@ -430,7 +436,10 @@ export function SignaturePad({
|
|
|
430
436
|
|
|
431
437
|
/* ── Pointer ── */
|
|
432
438
|
|
|
433
|
-
const toPoint = (
|
|
439
|
+
const toPoint = (
|
|
440
|
+
e: { clientX: number; clientY: number; pressure: number; pointerType: string },
|
|
441
|
+
rect: DOMRect,
|
|
442
|
+
): Point => {
|
|
434
443
|
const scale = refWidth.current > 0 && rect.width > 0 ? rect.width / refWidth.current : 1;
|
|
435
444
|
return {
|
|
436
445
|
x: (e.clientX - rect.left) / scale,
|
|
@@ -605,13 +614,12 @@ export function SignaturePad({
|
|
|
605
614
|
{labels.clear}
|
|
606
615
|
</Button>
|
|
607
616
|
{allowTypedName && (
|
|
608
|
-
<Button
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
{typed ? <PenLine aria-hidden="true" className="size-4" /> : <Keyboard aria-hidden="true" className="size-4" />}
|
|
617
|
+
<Button type="button" variant="secondary" onClick={switchMode} disabled={disabled}>
|
|
618
|
+
{typed ? (
|
|
619
|
+
<PenLine aria-hidden="true" className="size-4" />
|
|
620
|
+
) : (
|
|
621
|
+
<Keyboard aria-hidden="true" className="size-4" />
|
|
622
|
+
)}
|
|
615
623
|
{typed ? labels.useDrawn : labels.useTyped}
|
|
616
624
|
</Button>
|
|
617
625
|
)}
|
|
@@ -696,7 +704,9 @@ export function SignatureView({
|
|
|
696
704
|
data-empty={kind === "empty" || undefined}
|
|
697
705
|
>
|
|
698
706
|
{captioned && (
|
|
699
|
-
<figcaption id={captionId} className="block text-sm font-medium text-primary">
|
|
707
|
+
<figcaption id={captionId} className="block text-sm font-medium text-primary">
|
|
708
|
+
{caption}
|
|
709
|
+
</figcaption>
|
|
700
710
|
)}
|
|
701
711
|
<div
|
|
702
712
|
className={cn(
|
|
@@ -725,9 +735,7 @@ export function SignatureView({
|
|
|
725
735
|
{name}
|
|
726
736
|
</span>
|
|
727
737
|
)}
|
|
728
|
-
{kind === "empty" &&
|
|
729
|
-
<span className="relative text-xs text-muted">{labels.viewEmpty}</span>
|
|
730
|
-
)}
|
|
738
|
+
{kind === "empty" && <span className="relative text-xs text-muted">{labels.viewEmpty}</span>}
|
|
731
739
|
{/* The signing line, as on the pad. Decoration only. */}
|
|
732
740
|
<div
|
|
733
741
|
aria-hidden="true"
|
|
@@ -20,16 +20,7 @@ import { DEFAULT_SIGNED_AMOUNT_LABELS } from "./signed-amount-labels";
|
|
|
20
20
|
* Colour is never the only carrier: pair a verdict with an arrow, a word, or a sign.
|
|
21
21
|
*/
|
|
22
22
|
export type TextTone =
|
|
23
|
-
| "
|
|
24
|
-
| "muted"
|
|
25
|
-
| "brand"
|
|
26
|
-
| "income"
|
|
27
|
-
| "expense"
|
|
28
|
-
| "net"
|
|
29
|
-
| "success"
|
|
30
|
-
| "warning"
|
|
31
|
-
| "danger"
|
|
32
|
-
| "info";
|
|
23
|
+
"default" | "muted" | "brand" | "income" | "expense" | "net" | "success" | "warning" | "danger" | "info";
|
|
33
24
|
|
|
34
25
|
const TEXT_TONE: Record<TextTone, string> = {
|
|
35
26
|
default: "text-primary",
|
|
@@ -166,9 +157,7 @@ function signedToneClass(
|
|
|
166
157
|
|
|
167
158
|
const ARROW = { up: ArrowUp, down: ArrowDown, flat: Minus } as const;
|
|
168
159
|
|
|
169
|
-
export interface SignedAmountProps
|
|
170
|
-
extends SignedFormatProps,
|
|
171
|
-
Omit<ComponentPropsWithRef<"span">, "children"> {
|
|
160
|
+
export interface SignedAmountProps extends SignedFormatProps, Omit<ComponentPropsWithRef<"span">, "children"> {
|
|
172
161
|
value: number;
|
|
173
162
|
/** See {@link SignedAmountTone}. Default `signed`, or `verdict` with `goodDirection`. */
|
|
174
163
|
tone?: SignedAmountTone;
|
|
@@ -324,7 +313,10 @@ export function Delta({
|
|
|
324
313
|
data-direction={dir}
|
|
325
314
|
className={cn("relative inline-flex flex-wrap items-center gap-x-1.5 tabular-nums", className)}
|
|
326
315
|
>
|
|
327
|
-
<span
|
|
316
|
+
<span
|
|
317
|
+
data-private={sensitive ? "" : undefined}
|
|
318
|
+
className={cn("inline-flex items-center gap-0.5 font-medium", tone)}
|
|
319
|
+
>
|
|
328
320
|
{arrow && <Icon className="size-[1em] shrink-0" aria-hidden />}
|
|
329
321
|
{/* The figure at zero too, beside the flat dash (kastlan feedback #48). Before
|
|
330
322
|
this a flat delta with an arrow drew the dash ALONE, as a StatTile does — so
|
|
@@ -71,21 +71,10 @@ function SkeletonFill({ shape = "line", lines, className, ...rest }: Omit<Skelet
|
|
|
71
71
|
return (
|
|
72
72
|
<div {...rest} aria-hidden className={cn("flex flex-col gap-2", className)} data-skeleton="lines">
|
|
73
73
|
{Array.from({ length: lines }, (_, i) => (
|
|
74
|
-
<div
|
|
75
|
-
key={i}
|
|
76
|
-
className={cn(SKELETON_CLASS, SHAPE.line, i === lines - 1 && "w-2/3")}
|
|
77
|
-
data-skeleton="line"
|
|
78
|
-
/>
|
|
74
|
+
<div key={i} className={cn(SKELETON_CLASS, SHAPE.line, i === lines - 1 && "w-2/3")} data-skeleton="line" />
|
|
79
75
|
))}
|
|
80
76
|
</div>
|
|
81
77
|
);
|
|
82
78
|
}
|
|
83
|
-
return (
|
|
84
|
-
<div
|
|
85
|
-
{...rest}
|
|
86
|
-
aria-hidden
|
|
87
|
-
data-skeleton={shape}
|
|
88
|
-
className={cn(SKELETON_CLASS, SHAPE[shape], className)}
|
|
89
|
-
/>
|
|
90
|
-
);
|
|
79
|
+
return <div {...rest} aria-hidden data-skeleton={shape} className={cn(SKELETON_CLASS, SHAPE[shape], className)} />;
|
|
91
80
|
}
|
|
@@ -120,10 +120,11 @@ export interface SliderMark {
|
|
|
120
120
|
}
|
|
121
121
|
|
|
122
122
|
export interface SliderProps
|
|
123
|
-
extends
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
123
|
+
extends
|
|
124
|
+
Omit<
|
|
125
|
+
InputHTMLAttributes<HTMLInputElement>,
|
|
126
|
+
"type" | "value" | "defaultValue" | "onChange" | "min" | "max" | "step" | "children"
|
|
127
|
+
>,
|
|
127
128
|
FieldHelpProps {
|
|
128
129
|
/** The value. On a log scale this is the real value, not the track position. */
|
|
129
130
|
value: number;
|
|
@@ -235,8 +236,7 @@ export function Slider({
|
|
|
235
236
|
// digits; it is not formatting, and `formatValue` is how to get a locale.
|
|
236
237
|
const valueText = formatValue
|
|
237
238
|
? formatValue(value)
|
|
238
|
-
: (rest["aria-valuetext"] ??
|
|
239
|
-
(log || outOfRange ? String(Number(value.toPrecision(4))) : undefined));
|
|
239
|
+
: (rest["aria-valuetext"] ?? (log || outOfRange ? String(Number(value.toPrecision(4))) : undefined));
|
|
240
240
|
|
|
241
241
|
const handleChange = (e: ChangeEvent<HTMLInputElement>) => {
|
|
242
242
|
const raw = Number(e.target.value);
|
|
@@ -280,21 +280,13 @@ export function Slider({
|
|
|
280
280
|
// drops to a line of its own, still at the end, only when the two don't fit.
|
|
281
281
|
<div className="flex flex-wrap items-center gap-x-2 gap-y-0.5">
|
|
282
282
|
{label !== undefined && (
|
|
283
|
-
<label
|
|
284
|
-
htmlFor={inputId}
|
|
285
|
-
className="min-w-0 select-none text-xs font-medium text-secondary"
|
|
286
|
-
>
|
|
283
|
+
<label htmlFor={inputId} className="min-w-0 select-none text-xs font-medium text-secondary">
|
|
287
284
|
{label}
|
|
288
285
|
</label>
|
|
289
286
|
)}
|
|
290
287
|
{labelHint !== undefined && <span className="flex shrink-0 items-center">{labelHint}</span>}
|
|
291
288
|
{readout !== undefined && (
|
|
292
|
-
<span
|
|
293
|
-
className={cn(
|
|
294
|
-
"ms-auto max-w-full text-xs tabular-nums text-primary",
|
|
295
|
-
plainReadout && "select-none",
|
|
296
|
-
)}
|
|
297
|
-
>
|
|
289
|
+
<span className={cn("ms-auto max-w-full text-xs tabular-nums text-primary", plainReadout && "select-none")}>
|
|
298
290
|
{readout}
|
|
299
291
|
</span>
|
|
300
292
|
)}
|
|
@@ -323,10 +315,7 @@ export function Slider({
|
|
|
323
315
|
// `min`, not under the track's rounded end. Each tick is a zero-width column
|
|
324
316
|
// centred on its point, which centres its label on it in either direction
|
|
325
317
|
// without a `translate` that would need flipping for right-to-left.
|
|
326
|
-
<div
|
|
327
|
-
aria-hidden
|
|
328
|
-
className={cn("relative mx-2 -mt-1.5", MARKS_LARGE, hasMarkLabels ? "h-5" : "h-1.5")}
|
|
329
|
-
>
|
|
318
|
+
<div aria-hidden className={cn("relative mx-2 -mt-1.5", MARKS_LARGE, hasMarkLabels ? "h-5" : "h-1.5")}>
|
|
330
319
|
{normalizedMarks.map((m) => (
|
|
331
320
|
<span
|
|
332
321
|
key={m.value}
|
|
@@ -39,17 +39,7 @@ export { DEFAULT_SPARKLINE_LABELS };
|
|
|
39
39
|
* own value, a line or area takes the colour of its LAST value (where it ended up).
|
|
40
40
|
*/
|
|
41
41
|
export type SparklineTone =
|
|
42
|
-
| "
|
|
43
|
-
| "brand"
|
|
44
|
-
| "muted"
|
|
45
|
-
| "income"
|
|
46
|
-
| "expense"
|
|
47
|
-
| "net"
|
|
48
|
-
| "signed"
|
|
49
|
-
| "success"
|
|
50
|
-
| "warning"
|
|
51
|
-
| "danger"
|
|
52
|
-
| "info";
|
|
42
|
+
"chart" | "brand" | "muted" | "income" | "expense" | "net" | "signed" | "success" | "warning" | "danger" | "info";
|
|
53
43
|
|
|
54
44
|
// `color`, not `stroke`/`fill`: every mark paints with `currentColor`, so one class
|
|
55
45
|
// per element is enough and a signed bar chart needs no second lookup table.
|
|
@@ -70,8 +60,7 @@ const signedClass = (v: number) => (v < 0 ? TONE_CLASS.expense : TONE_CLASS.inco
|
|
|
70
60
|
|
|
71
61
|
/** `children` is the marks and `width`/`height` are numbers here (or `fluid`), so
|
|
72
62
|
* those three are the sparkline's own; everything else lands on the `<svg>`. */
|
|
73
|
-
export interface SparklineProps
|
|
74
|
-
extends Omit<ComponentPropsWithRef<"svg">, "children" | "width" | "height"> {
|
|
63
|
+
export interface SparklineProps extends Omit<ComponentPropsWithRef<"svg">, "children" | "width" | "height"> {
|
|
75
64
|
/** The series, oldest first. `null`/`undefined`/`NaN` is a GAP — the line breaks
|
|
76
65
|
* there rather than drawing a zero or bridging across the missing point. */
|
|
77
66
|
data: ReadonlyArray<number | null | undefined>;
|