@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
|
@@ -21,6 +21,7 @@ import {
|
|
|
21
21
|
LegalSlotContext,
|
|
22
22
|
LegalText,
|
|
23
23
|
legalOperatorText,
|
|
24
|
+
resolveLegalRefs,
|
|
24
25
|
useLegalLabels,
|
|
25
26
|
warnLegalOnce,
|
|
26
27
|
} from "./legal";
|
|
@@ -351,8 +352,24 @@ export interface LegalPageProps {
|
|
|
351
352
|
*
|
|
352
353
|
* An app that records which terms someone accepted (keksdose) stores the terms page's
|
|
353
354
|
* date: it is the version the reader saw.
|
|
355
|
+
*
|
|
356
|
+
* The kit's sections are part of the page, so the date moves with their words too: a
|
|
357
|
+
* kit release that changes them says so in its adoption note ("Legal wording"), and
|
|
358
|
+
* the app sets the page's date to the day it ships that bump (§2, decision 10).
|
|
354
359
|
*/
|
|
355
360
|
updated?: string;
|
|
361
|
+
/**
|
|
362
|
+
* 0.51.4: a plain-language summary before the first section (legal benchmark, Marcel
|
|
363
|
+
* 2026-10-29) — the app's three to six points, each a sentence. The kit draws them as a
|
|
364
|
+
* list under `legal.summary.title` ("In short", "Das Wichtigste in Kürze") and adds
|
|
365
|
+
* `legal.summary.note`: the summary orients, only the full text binds. Worded without
|
|
366
|
+
* "below", because on a translated page the text below is a translation too.
|
|
367
|
+
*
|
|
368
|
+
* A string point is running text with its `{ref:key}` resolved, as in a section:
|
|
369
|
+
* "You can delete your account at any time (section {ref:ending})." Unnumbered, with
|
|
370
|
+
* the id `summary`; the sections' numbers do not count it. Left out or empty, nothing.
|
|
371
|
+
*/
|
|
372
|
+
summary?: readonly ReactNode[];
|
|
356
373
|
/**
|
|
357
374
|
* 0.28.1: switches the app to the operator's `bindingLanguage` — the button after the
|
|
358
375
|
* translation note on a page read in another language. Without it the note stands
|
|
@@ -446,7 +463,9 @@ function slotSections(
|
|
|
446
463
|
const number = numbered ? count : undefined;
|
|
447
464
|
if (section.key !== undefined) {
|
|
448
465
|
if (targets.has(section.key)) {
|
|
449
|
-
warnLegalOnce(
|
|
466
|
+
warnLegalOnce(
|
|
467
|
+
`two sections of the ${page} page share the key "${section.key}"; {ref:${section.key}} names the first.`,
|
|
468
|
+
);
|
|
450
469
|
} else {
|
|
451
470
|
targets.set(section.key, { number, heading: section.heading });
|
|
452
471
|
}
|
|
@@ -471,6 +490,7 @@ function slotSections(
|
|
|
471
490
|
* What it adds to the column:
|
|
472
491
|
* - the title, from `legal.titles`, and "← Back to home" pointing at `homeHref`;
|
|
473
492
|
* - the as-of line under the title, from `updated` (0.51.3);
|
|
493
|
+
* - the plain-language summary before the sections, from `summary` (0.51.4);
|
|
474
494
|
* - the default notice per page — the beta notice, or the privacy notice on the privacy
|
|
475
495
|
* policy, whose technical sections describe running code (§3.2, §7.3);
|
|
476
496
|
* - numbers: the privacy and terms sections are "N. Title" in render order, the
|
|
@@ -492,6 +512,7 @@ export function LegalPage({
|
|
|
492
512
|
homeHref = "/",
|
|
493
513
|
notice,
|
|
494
514
|
updated,
|
|
515
|
+
summary,
|
|
495
516
|
onShowBindingLanguage,
|
|
496
517
|
locale: localeProp,
|
|
497
518
|
headingAs = "h1",
|
|
@@ -519,8 +540,7 @@ export function LegalPage({
|
|
|
519
540
|
targets,
|
|
520
541
|
};
|
|
521
542
|
const Main = landmark ? "main" : "div";
|
|
522
|
-
const shownNotice =
|
|
523
|
-
notice !== undefined ? notice : page === "privacy" ? labels.notice.privacy : labels.notice.beta;
|
|
543
|
+
const shownNotice = notice !== undefined ? notice : page === "privacy" ? labels.notice.privacy : labels.notice.beta;
|
|
524
544
|
// 0.28.1 (Marcel): one language is binding and the lawyer reviews that one; a page read
|
|
525
545
|
// in any other says so, with a way to the binding version.
|
|
526
546
|
const translated =
|
|
@@ -531,7 +551,13 @@ export function LegalPage({
|
|
|
531
551
|
{onShowBindingLanguage && (
|
|
532
552
|
<>
|
|
533
553
|
{" "}
|
|
534
|
-
<Button
|
|
554
|
+
<Button
|
|
555
|
+
type="button"
|
|
556
|
+
variant="link"
|
|
557
|
+
size="sm"
|
|
558
|
+
className="h-auto p-0 align-baseline"
|
|
559
|
+
onClick={onShowBindingLanguage}
|
|
560
|
+
>
|
|
535
561
|
{labels.translation.show(operatorText)}
|
|
536
562
|
</Button>
|
|
537
563
|
</>
|
|
@@ -550,6 +576,27 @@ export function LegalPage({
|
|
|
550
576
|
{(labels.updated ?? DEFAULT_LEGAL_LABELS.updated!)(formatDate(updated, "long", { locale }))}
|
|
551
577
|
</time>
|
|
552
578
|
) : undefined;
|
|
579
|
+
const summaryLabels = labels.summary ?? DEFAULT_LEGAL_LABELS.summary!;
|
|
580
|
+
const SummaryHeading = context.sectionHeading;
|
|
581
|
+
const summaryBox =
|
|
582
|
+
summary !== undefined && summary.length > 0 ? (
|
|
583
|
+
<section id="summary" className="rounded-lg border border-subtle bg-surface p-4 sm:p-5">
|
|
584
|
+
<SummaryHeading className="text-lg font-semibold break-words text-primary">
|
|
585
|
+
{summaryLabels.title}
|
|
586
|
+
</SummaryHeading>
|
|
587
|
+
<ul className="mt-3 space-y-2">
|
|
588
|
+
{summary.map((point, i) => (
|
|
589
|
+
<li key={i} className="flex gap-2.5 text-sm leading-relaxed text-secondary">
|
|
590
|
+
<span aria-hidden className="mt-2 size-1.5 shrink-0 rounded-full bg-brand" />
|
|
591
|
+
<span className="min-w-0 break-words">
|
|
592
|
+
{typeof point === "string" ? resolveLegalRefs(point, context) : point}
|
|
593
|
+
</span>
|
|
594
|
+
</li>
|
|
595
|
+
))}
|
|
596
|
+
</ul>
|
|
597
|
+
<p className="mt-3 text-xs text-muted">{summaryLabels.note}</p>
|
|
598
|
+
</section>
|
|
599
|
+
) : undefined;
|
|
553
600
|
|
|
554
601
|
return (
|
|
555
602
|
<UiKitProvider labels={overrides}>
|
|
@@ -567,6 +614,7 @@ export function LegalPage({
|
|
|
567
614
|
notice={shownNotice}
|
|
568
615
|
updated={updatedLine}
|
|
569
616
|
translationNote={translationNote}
|
|
617
|
+
summary={summaryBox}
|
|
570
618
|
headingAs={headingAs}
|
|
571
619
|
>
|
|
572
620
|
{nodes}
|
|
@@ -581,8 +629,10 @@ export function LegalPage({
|
|
|
581
629
|
|
|
582
630
|
// ── Terms acceptance (§3.4) ───────────────────────────────────────────────────
|
|
583
631
|
|
|
584
|
-
export interface LegalAcceptCheckboxProps
|
|
585
|
-
|
|
632
|
+
export interface LegalAcceptCheckboxProps extends Omit<
|
|
633
|
+
CheckboxProps,
|
|
634
|
+
"label" | "checked" | "onCheckedChange" | "required"
|
|
635
|
+
> {
|
|
586
636
|
checked: boolean;
|
|
587
637
|
onCheckedChange: (checked: boolean) => void;
|
|
588
638
|
/** Default `/terms`. */
|
package/src/components/legal.tsx
CHANGED
|
@@ -44,6 +44,11 @@ export const LEGAL_HREFS: Readonly<Record<LegalPageKey, string>> = Object.freeze
|
|
|
44
44
|
terms: "/terms",
|
|
45
45
|
});
|
|
46
46
|
|
|
47
|
+
/** 0.51.4: the two public pages an app MAY have beside the legal ones, linked after
|
|
48
|
+
* them in the footer (§3.3) — keksdose's /security and /accessibility. Not legal pages:
|
|
49
|
+
* an app draws them with `PublicPage`, in its own words, at routes of its choosing. */
|
|
50
|
+
export type LegalInfoPageKey = "security" | "accessibility";
|
|
51
|
+
|
|
47
52
|
/**
|
|
48
53
|
* Who runs the app — the values the kit's legal sections are filled in with (§5).
|
|
49
54
|
*
|
|
@@ -179,8 +184,11 @@ export interface LegalFramedSectionLabels {
|
|
|
179
184
|
export interface LegalLabels {
|
|
180
185
|
/** The accessible name of {@link LegalLinks}' and {@link LegalFooter}'s `<nav>`. */
|
|
181
186
|
navLabel: string;
|
|
182
|
-
/** The short labels of the three links, everywhere the links appear (§3.3)
|
|
183
|
-
|
|
187
|
+
/** The short labels of the three links, everywhere the links appear (§3.3), and since
|
|
188
|
+
* 0.51.4 of the two optional public pages after them (`securityHref`,
|
|
189
|
+
* `accessibilityHref` on {@link LegalLinks}) — optional keys, as every key added to a
|
|
190
|
+
* namespace an app may annotate: left out, the provider's, then English. */
|
|
191
|
+
links: Record<LegalPageKey, string> & Partial<Record<LegalInfoPageKey, string>>;
|
|
184
192
|
/** The pages' titles — the `<h1>`, and the links of the terms checkbox. */
|
|
185
193
|
titles: Record<LegalPageKey, string>;
|
|
186
194
|
/** The back link above the title: "← Back to home". */
|
|
@@ -215,6 +223,15 @@ export interface LegalLabels {
|
|
|
215
223
|
* the provider's, then English.
|
|
216
224
|
*/
|
|
217
225
|
updated?: (date: string) => string;
|
|
226
|
+
/**
|
|
227
|
+
* 0.51.4: the plain-language summary at the top of a page ({@link LegalPage}'s
|
|
228
|
+
* `summary`, §3.2) — its heading, and the line under the points saying that only the
|
|
229
|
+
* full text binds. Optional, as `updated`.
|
|
230
|
+
*/
|
|
231
|
+
summary?: {
|
|
232
|
+
title: string;
|
|
233
|
+
note: string;
|
|
234
|
+
};
|
|
218
235
|
/** The kit's sections (§4.3), by page and section key. */
|
|
219
236
|
sections: {
|
|
220
237
|
impressum: {
|
|
@@ -363,6 +380,15 @@ export interface LegalLinksProps {
|
|
|
363
380
|
/** Default (0.28): the three routes, `/impressum`, `/privacy` and `/terms`, with the
|
|
364
381
|
* kit's short link labels (`legal.links`), in the contract's order. */
|
|
365
382
|
links?: readonly LegalLink[];
|
|
383
|
+
/**
|
|
384
|
+
* 0.51.4: the app's security page — a "Security" link after the others, with the kit's
|
|
385
|
+
* label (`legal.links.security`). Left out, no link: only an app that has the page
|
|
386
|
+
* names its route.
|
|
387
|
+
*/
|
|
388
|
+
securityHref?: string;
|
|
389
|
+
/** 0.51.4: the app's accessibility statement — "Accessibility", last. As
|
|
390
|
+
* `securityHref`. */
|
|
391
|
+
accessibilityHref?: string;
|
|
366
392
|
/** The page being shown; its link is marked `aria-current="page"`. Usually the
|
|
367
393
|
* router's pathname. */
|
|
368
394
|
currentHref?: string;
|
|
@@ -387,6 +413,14 @@ function defaultLinks(labels: LegalLabels): LegalLink[] {
|
|
|
387
413
|
}));
|
|
388
414
|
}
|
|
389
415
|
|
|
416
|
+
/** The optional pages after them, each only where the app named its route. */
|
|
417
|
+
function infoLinks(labels: LegalLabels, hrefs: Partial<Record<LegalInfoPageKey, string>>): LegalLink[] {
|
|
418
|
+
return (["security", "accessibility"] as const).flatMap((page) => {
|
|
419
|
+
const href = hrefs[page];
|
|
420
|
+
return href ? [{ href, label: labels.links[page] ?? DEFAULT_LEGAL_LABELS.links[page] }] : [];
|
|
421
|
+
});
|
|
422
|
+
}
|
|
423
|
+
|
|
390
424
|
/**
|
|
391
425
|
* The legal pages as a row of quiet links, the one you are on marked (kastlan's
|
|
392
426
|
* `LegalLinks`). Wraps on a phone.
|
|
@@ -398,6 +432,8 @@ function defaultLinks(labels: LegalLabels): LegalLink[] {
|
|
|
398
432
|
*/
|
|
399
433
|
export function LegalLinks({
|
|
400
434
|
links,
|
|
435
|
+
securityHref,
|
|
436
|
+
accessibilityHref,
|
|
401
437
|
currentHref,
|
|
402
438
|
nav = true,
|
|
403
439
|
onLinkClick,
|
|
@@ -405,9 +441,18 @@ export function LegalLinks({
|
|
|
405
441
|
className,
|
|
406
442
|
}: LegalLinksProps) {
|
|
407
443
|
const labels = useLegalLabels(labelsProp);
|
|
408
|
-
const shown =
|
|
444
|
+
const shown = [
|
|
445
|
+
...(links ?? defaultLinks(labels)),
|
|
446
|
+
...infoLinks(labels, { security: securityHref, accessibility: accessibilityHref }),
|
|
447
|
+
];
|
|
409
448
|
const items = shown.flatMap((link, i) => [
|
|
410
|
-
...(i > 0
|
|
449
|
+
...(i > 0
|
|
450
|
+
? [
|
|
451
|
+
<span key={`sep-${link.href}`} aria-hidden="true">
|
|
452
|
+
·
|
|
453
|
+
</span>,
|
|
454
|
+
]
|
|
455
|
+
: []),
|
|
411
456
|
<TextLink key={link.href} href={link.href} tone="muted" current={link.href === currentHref} onClick={onLinkClick}>
|
|
412
457
|
{link.label}
|
|
413
458
|
</TextLink>,
|
|
@@ -429,6 +474,10 @@ export interface LegalFooterProps {
|
|
|
429
474
|
children?: ReactNode;
|
|
430
475
|
/** Default: the three routes with the kit's link labels — see {@link LegalLinks}. */
|
|
431
476
|
links?: readonly LegalLink[];
|
|
477
|
+
/** 0.51.4: "Security" after the others — see {@link LegalLinksProps.securityHref}. */
|
|
478
|
+
securityHref?: string;
|
|
479
|
+
/** 0.51.4: "Accessibility", last — see {@link LegalLinksProps.accessibilityHref}. */
|
|
480
|
+
accessibilityHref?: string;
|
|
432
481
|
/** Marks that link `aria-current="page"`. {@link LegalPage}'s default footer passes
|
|
433
482
|
* its own page. */
|
|
434
483
|
currentHref?: string;
|
|
@@ -454,14 +503,29 @@ export interface LegalFooterProps {
|
|
|
454
503
|
* landing, auth, legal and 404 pages; kastlan and Kurvenschmiede had them on some pages
|
|
455
504
|
* only. Its palette classes (`border-slate-200 bg-white dark:…`) became the surface and
|
|
456
505
|
* border tokens, so it follows the theme like the rest of the kit.
|
|
506
|
+
*
|
|
507
|
+
* 0.51.4: an app with a security page or an accessibility statement passes their routes
|
|
508
|
+
* (`securityHref`, `accessibilityHref`) and the row goes on with "Security · Accessibility"
|
|
509
|
+
* in the kit's words, so the footer reads the same in every app that has them.
|
|
457
510
|
*/
|
|
458
|
-
export function LegalFooter({
|
|
511
|
+
export function LegalFooter({
|
|
512
|
+
children,
|
|
513
|
+
links,
|
|
514
|
+
securityHref,
|
|
515
|
+
accessibilityHref,
|
|
516
|
+
currentHref,
|
|
517
|
+
landmark = true,
|
|
518
|
+
className,
|
|
519
|
+
labels,
|
|
520
|
+
}: LegalFooterProps) {
|
|
459
521
|
const Root = landmark ? "footer" : "div";
|
|
460
522
|
return (
|
|
461
523
|
<Root className={cn("border-t border-subtle bg-surface", className)}>
|
|
462
524
|
<div className="mx-auto max-w-5xl px-4 py-8 text-sm text-muted">
|
|
463
525
|
<LegalLinks
|
|
464
526
|
links={links}
|
|
527
|
+
securityHref={securityHref}
|
|
528
|
+
accessibilityHref={accessibilityHref}
|
|
465
529
|
currentHref={currentHref}
|
|
466
530
|
labels={labels}
|
|
467
531
|
className="justify-center gap-y-2 text-sm"
|
|
@@ -515,9 +579,7 @@ export function LegalSection({ heading, body, children, id: idProp, headingAs }:
|
|
|
515
579
|
{heading}
|
|
516
580
|
</Heading>
|
|
517
581
|
<LegalSlotContext.Provider value={null}>
|
|
518
|
-
{body !== undefined &&
|
|
519
|
-
<LegalText text={body} className="mt-2 text-sm leading-relaxed text-secondary" />
|
|
520
|
-
)}
|
|
582
|
+
{body !== undefined && <LegalText text={body} className="mt-2 text-sm leading-relaxed text-secondary" />}
|
|
521
583
|
{children !== undefined && (
|
|
522
584
|
<div className="mt-2 text-sm leading-relaxed break-words text-secondary">
|
|
523
585
|
{typeof children === "string" ? resolveLegalRefs(children, page) : children}
|
|
@@ -547,6 +609,8 @@ export interface LegalLayoutProps {
|
|
|
547
609
|
/** 0.28.1: under the title, before the notice — {@link LegalPage}'s note that this
|
|
548
610
|
* page is a translation and which language is binding. */
|
|
549
611
|
translationNote?: ReactNode;
|
|
612
|
+
/** 0.51.4: before the sections — {@link LegalPage}'s plain-language summary. */
|
|
613
|
+
summary?: ReactNode;
|
|
550
614
|
/** The sections — {@link LegalSection}s. */
|
|
551
615
|
children: ReactNode;
|
|
552
616
|
/** The three pages, linked at the end of the column with the current one marked.
|
|
@@ -566,6 +630,7 @@ export function LegalLayout({
|
|
|
566
630
|
notice,
|
|
567
631
|
updated,
|
|
568
632
|
translationNote,
|
|
633
|
+
summary,
|
|
569
634
|
children,
|
|
570
635
|
links,
|
|
571
636
|
currentHref,
|
|
@@ -584,9 +649,17 @@ export function LegalLayout({
|
|
|
584
649
|
{notice}
|
|
585
650
|
</AlertBanner>
|
|
586
651
|
)}
|
|
587
|
-
<div className="mt-8 space-y-8">
|
|
652
|
+
<div className="mt-8 space-y-8">
|
|
653
|
+
{summary}
|
|
654
|
+
{children}
|
|
655
|
+
</div>
|
|
588
656
|
{links !== undefined && links.length > 0 && (
|
|
589
|
-
<LegalLinks
|
|
657
|
+
<LegalLinks
|
|
658
|
+
links={links}
|
|
659
|
+
currentHref={currentHref}
|
|
660
|
+
labels={labels}
|
|
661
|
+
className="mt-12 border-t border-subtle pt-4"
|
|
662
|
+
/>
|
|
590
663
|
)}
|
|
591
664
|
</article>
|
|
592
665
|
);
|
|
@@ -310,9 +310,7 @@ export function Lightbox({
|
|
|
310
310
|
fetched={fetched}
|
|
311
311
|
alt={item.alt}
|
|
312
312
|
labels={imageLabels}
|
|
313
|
-
wrapperClassName={
|
|
314
|
-
zoomed ? "max-w-none shrink-0" : "flex h-full w-full items-center justify-center"
|
|
315
|
-
}
|
|
313
|
+
wrapperClassName={zoomed ? "max-w-none shrink-0" : "flex h-full w-full items-center justify-center"}
|
|
316
314
|
className={cn(
|
|
317
315
|
zoomed ? "max-w-none cursor-zoom-out" : "max-h-full max-w-full object-contain",
|
|
318
316
|
!zoomed && zoomEnabled && "cursor-zoom-in",
|
|
@@ -114,7 +114,10 @@ export interface LineItemsColumn<T> {
|
|
|
114
114
|
* class, handlers. A `data-*` attribute is typed so `{ "data-tour": "rule-condition" }`
|
|
115
115
|
* needs no cast.
|
|
116
116
|
*/
|
|
117
|
-
export type LineItemsRowProps = Omit<
|
|
117
|
+
export type LineItemsRowProps = Omit<
|
|
118
|
+
HTMLAttributes<HTMLDivElement>,
|
|
119
|
+
"children" | "dangerouslySetInnerHTML" | "role"
|
|
120
|
+
> & {
|
|
118
121
|
[key: `data-${string}`]: string | number | boolean | undefined;
|
|
119
122
|
};
|
|
120
123
|
|
|
@@ -289,7 +292,6 @@ export function LineItems<T>({
|
|
|
289
292
|
const canRemove = Boolean(onRemove) && !disabled && items.length > minItems;
|
|
290
293
|
const hasError = hasContent(error);
|
|
291
294
|
|
|
292
|
-
|
|
293
295
|
// Focus after the list has re-rendered with the new rows — a layout effect, so the
|
|
294
296
|
// caret is where it belongs before paint.
|
|
295
297
|
useLayoutEffect(() => {
|
|
@@ -351,10 +353,7 @@ export function LineItems<T>({
|
|
|
351
353
|
const headerCell = (column: LineItemsColumn<T>) => (
|
|
352
354
|
<span
|
|
353
355
|
key={column.key}
|
|
354
|
-
className={cn(
|
|
355
|
-
"min-w-0 truncate text-xs font-medium text-muted",
|
|
356
|
-
column.align === "end" && "text-end",
|
|
357
|
-
)}
|
|
356
|
+
className={cn("min-w-0 truncate text-xs font-medium text-muted", column.align === "end" && "text-end")}
|
|
358
357
|
>
|
|
359
358
|
{floats(column) ? null : column.header}
|
|
360
359
|
</span>
|
|
@@ -548,10 +547,7 @@ export function LineItems<T>({
|
|
|
548
547
|
)}
|
|
549
548
|
|
|
550
549
|
{summary && (
|
|
551
|
-
<div
|
|
552
|
-
data-line-items-summary=""
|
|
553
|
-
className="flex flex-wrap items-center gap-x-3 gap-y-1 text-sm text-primary"
|
|
554
|
-
>
|
|
550
|
+
<div data-line-items-summary="" className="flex flex-wrap items-center gap-x-3 gap-y-1 text-sm text-primary">
|
|
555
551
|
{/* With no value the line is a state of its own, and the label takes the
|
|
556
552
|
tone — the only place left to carry it. */}
|
|
557
553
|
<span
|
|
@@ -586,11 +582,7 @@ export function LineItems<T>({
|
|
|
586
582
|
</div>
|
|
587
583
|
)}
|
|
588
584
|
|
|
589
|
-
{hasError &&
|
|
590
|
-
<p className="text-caption leading-tight text-danger">
|
|
591
|
-
{error}
|
|
592
|
-
</p>
|
|
593
|
-
)}
|
|
585
|
+
{hasError && <p className="text-caption leading-tight text-danger">{error}</p>}
|
|
594
586
|
|
|
595
587
|
{onAdd && (
|
|
596
588
|
<Button
|
package/src/components/list.tsx
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { createContext, useContext, useId, useState } from "react";
|
|
1
|
+
import { Children, createContext, useContext, useId, useState } from "react";
|
|
2
2
|
import type { ComponentPropsWithoutRef, HTMLAttributes, MouseEvent, ReactElement, ReactNode, Ref } from "react";
|
|
3
3
|
import { ChevronDown, ExternalLink } from "lucide-react";
|
|
4
4
|
import type { LucideIcon } from "lucide-react";
|
|
@@ -14,6 +14,7 @@ import { pickLinkRenderer } from "./text-link";
|
|
|
14
14
|
import { LockedReason, mergeDescribedBy, useLockReason, type DisabledReasonDisplay } from "./field-parts";
|
|
15
15
|
import type { CommitScope } from "./write-lock";
|
|
16
16
|
import { DEFAULT_LIST_LABELS } from "./list-labels";
|
|
17
|
+
import { Button } from "./button";
|
|
17
18
|
|
|
18
19
|
/* ── Labels ───────────────────────────────────────────────────────────────── */
|
|
19
20
|
|
|
@@ -22,6 +23,12 @@ export interface ListLabels {
|
|
|
22
23
|
unread: string;
|
|
23
24
|
/** Read after an external row's title: the row leaves the app in a new tab. */
|
|
24
25
|
opensInNewTab: string;
|
|
26
|
+
/** 0.51.4: the row under a {@link ListProps.limit}ed list that opens the rest, with
|
|
27
|
+
* the WHOLE list's count — "Show all (12)". Optional, as every key added to a
|
|
28
|
+
* namespace an app may annotate: left out, the provider's, then English. */
|
|
29
|
+
showAll?: (count: number) => string;
|
|
30
|
+
/** 0.51.4: the same row once the list is open, folding it back. */
|
|
31
|
+
showFewer?: string;
|
|
25
32
|
}
|
|
26
33
|
|
|
27
34
|
// Defined in ./list-labels, which holds no component code (0.34, KS U8).
|
|
@@ -53,8 +60,26 @@ export interface ListProps extends Omit<ComponentPropsWithoutRef<"ul">, "role">
|
|
|
53
60
|
/** The `<ul>` (or `<ol>`). A React 19 ref prop since 0.34 (MOD-4, refactor audit
|
|
54
61
|
* 2026-10); it was `forwardRef`. */
|
|
55
62
|
ref?: Ref<HTMLUListElement>;
|
|
63
|
+
/**
|
|
64
|
+
* Show the first `limit` rows, then a "Show all (n)" row that opens the rest and turns
|
|
65
|
+
* into "Show fewer" (0.51.4, keksdose run 89: a long "Placed only roughly" list on its
|
|
66
|
+
* Matching report could only fold as a whole, so it opened as nothing or everything).
|
|
67
|
+
* A list of `limit` rows or fewer draws them all, with no such row. Rows are counted as
|
|
68
|
+
* `Children` counts them: one per `ListItem`, a fragment as one.
|
|
69
|
+
*
|
|
70
|
+
* The row is a button with `aria-expanded`, controlling the list; it sits in the list
|
|
71
|
+
* as `role="none"`, so a reader still hears "list, 5 items" for five rows.
|
|
72
|
+
*/
|
|
73
|
+
limit?: number;
|
|
56
74
|
}
|
|
57
75
|
|
|
76
|
+
/** The show-all row's inset, in step with each density's row padding (`PAD`). */
|
|
77
|
+
const MORE_PAD: Record<ListDensity, string> = {
|
|
78
|
+
compact: "px-2 py-1",
|
|
79
|
+
default: "px-3 py-1.5",
|
|
80
|
+
comfortable: "px-4 py-2",
|
|
81
|
+
};
|
|
82
|
+
|
|
58
83
|
/**
|
|
59
84
|
* The list of {@link ListItem}s.
|
|
60
85
|
*
|
|
@@ -67,15 +92,23 @@ export function List({
|
|
|
67
92
|
as = "ul",
|
|
68
93
|
density = "default",
|
|
69
94
|
separator = "gap",
|
|
95
|
+
limit,
|
|
70
96
|
className,
|
|
71
97
|
children,
|
|
72
98
|
...rest
|
|
73
99
|
}: ListProps) {
|
|
74
100
|
const Tag = as;
|
|
101
|
+
const labels = useKitLabels("list", DEFAULT_LIST_LABELS);
|
|
102
|
+
const [open, setOpen] = useState(false);
|
|
103
|
+
const generatedId = useId();
|
|
104
|
+
const id = rest.id ?? generatedId;
|
|
105
|
+
const rows = limit === undefined ? null : Children.toArray(children);
|
|
106
|
+
const folds = rows !== null && rows.length > Math.max(0, limit!);
|
|
75
107
|
return (
|
|
76
108
|
<ListContext.Provider value={{ density, separator }}>
|
|
77
109
|
<Tag
|
|
78
110
|
{...rest}
|
|
111
|
+
id={folds ? id : rest.id}
|
|
79
112
|
ref={ref as Ref<HTMLUListElement & HTMLOListElement>}
|
|
80
113
|
role="list"
|
|
81
114
|
className={cn(
|
|
@@ -84,7 +117,24 @@ export function List({
|
|
|
84
117
|
className,
|
|
85
118
|
)}
|
|
86
119
|
>
|
|
87
|
-
{children}
|
|
120
|
+
{folds && !open ? rows.slice(0, Math.max(0, limit!)) : children}
|
|
121
|
+
{folds && (
|
|
122
|
+
<li role="none" className={MORE_PAD[density]}>
|
|
123
|
+
<Button
|
|
124
|
+
type="button"
|
|
125
|
+
variant="link"
|
|
126
|
+
size="sm"
|
|
127
|
+
className="h-auto p-0"
|
|
128
|
+
aria-expanded={open}
|
|
129
|
+
aria-controls={id}
|
|
130
|
+
onClick={() => setOpen((was) => !was)}
|
|
131
|
+
>
|
|
132
|
+
{open
|
|
133
|
+
? (labels.showFewer ?? DEFAULT_LIST_LABELS.showFewer)
|
|
134
|
+
: (labels.showAll ?? DEFAULT_LIST_LABELS.showAll!)(rows.length)}
|
|
135
|
+
</Button>
|
|
136
|
+
</li>
|
|
137
|
+
)}
|
|
88
138
|
</Tag>
|
|
89
139
|
</ListContext.Provider>
|
|
90
140
|
);
|
|
@@ -109,14 +159,30 @@ export interface ListItemLinkProps {
|
|
|
109
159
|
[key: `data-${string}`]: unknown;
|
|
110
160
|
}
|
|
111
161
|
|
|
112
|
-
const PAD: Record<
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
162
|
+
const PAD: Record<ListDensity, { target: string; actions: string; leadingActions: string; gap: string; body: string }> =
|
|
163
|
+
{
|
|
164
|
+
compact: {
|
|
165
|
+
target: "gap-2 px-2 py-1.5",
|
|
166
|
+
actions: "pe-1.5",
|
|
167
|
+
leadingActions: "ps-1.5",
|
|
168
|
+
gap: "gap-0.5",
|
|
169
|
+
body: "px-2 pb-1.5",
|
|
170
|
+
},
|
|
171
|
+
default: {
|
|
172
|
+
target: "gap-3 px-3 py-2.5",
|
|
173
|
+
actions: "pe-2",
|
|
174
|
+
leadingActions: "ps-2",
|
|
175
|
+
gap: "gap-1",
|
|
176
|
+
body: "px-3 pb-2.5",
|
|
177
|
+
},
|
|
178
|
+
comfortable: {
|
|
179
|
+
target: "gap-3 px-4 py-3",
|
|
180
|
+
actions: "pe-3",
|
|
181
|
+
leadingActions: "ps-3",
|
|
182
|
+
gap: "gap-1",
|
|
183
|
+
body: "px-4 pb-3",
|
|
184
|
+
},
|
|
185
|
+
};
|
|
120
186
|
|
|
121
187
|
/** {@link ListItemBaseProps.trailingTone}: a {@link TextTone}, or `inherit` — no
|
|
122
188
|
* colour of the slot's own, so an element's colour (or the row's) stands. */
|
|
@@ -534,12 +600,7 @@ export function ListItem({
|
|
|
534
600
|
|
|
535
601
|
const body = (
|
|
536
602
|
<>
|
|
537
|
-
{Icon && (
|
|
538
|
-
<Icon
|
|
539
|
-
className={cn("size-4 shrink-0 text-muted", align === "start" && "mt-0.5")}
|
|
540
|
-
aria-hidden
|
|
541
|
-
/>
|
|
542
|
-
)}
|
|
603
|
+
{Icon && <Icon className={cn("size-4 shrink-0 text-muted", align === "start" && "mt-0.5")} aria-hidden />}
|
|
543
604
|
{leading}
|
|
544
605
|
{/* With a trailing slot, a basis at Large: below it the trailing chip or figure
|
|
545
606
|
wraps under the text (the target wraps, see `target`) rather than squeezing the
|
|
@@ -602,9 +663,8 @@ export function ListItem({
|
|
|
602
663
|
{loading ? (
|
|
603
664
|
<Spinner label={null} className="size-3.5 shrink-0" />
|
|
604
665
|
) : (
|
|
605
|
-
external &&
|
|
606
|
-
|
|
607
|
-
)
|
|
666
|
+
external &&
|
|
667
|
+
href !== undefined && <ExternalLink className="size-3.5 shrink-0 text-muted rtl:-scale-x-100" aria-hidden />
|
|
608
668
|
)}
|
|
609
669
|
{mark}
|
|
610
670
|
{expandable && (
|
|
@@ -653,9 +713,7 @@ export function ListItem({
|
|
|
653
713
|
className: target,
|
|
654
714
|
"aria-current": selected ? "true" : undefined,
|
|
655
715
|
"aria-busy": loading || undefined,
|
|
656
|
-
onClick: loading
|
|
657
|
-
? (e) => e.preventDefault()
|
|
658
|
-
: (onClick as ListItemLinkProps["onClick"]),
|
|
716
|
+
onClick: loading ? (e) => e.preventDefault() : (onClick as ListItemLinkProps["onClick"]),
|
|
659
717
|
onAuxClick,
|
|
660
718
|
children: body,
|
|
661
719
|
};
|
|
@@ -745,11 +803,7 @@ export function ListItem({
|
|
|
745
803
|
stacked ? "flex-col" : "items-center",
|
|
746
804
|
// See `renderRow`: the wrapper may be inline, the row is not.
|
|
747
805
|
renderRow && "w-full",
|
|
748
|
-
selected
|
|
749
|
-
? "border-brand bg-surface-2"
|
|
750
|
-
: bordered
|
|
751
|
-
? "border-subtle"
|
|
752
|
-
: "border-transparent",
|
|
806
|
+
selected ? "border-brand bg-surface-2" : bordered ? "border-subtle" : "border-transparent",
|
|
753
807
|
!stacked && interactive && !inert && !selected && "hover:bg-hover",
|
|
754
808
|
(disabled || locked) && "opacity-50",
|
|
755
809
|
className,
|
|
@@ -181,8 +181,7 @@ export function useMeasuredRows(
|
|
|
181
181
|
return { cells, setCells, rows, setRows, ready, problems, props };
|
|
182
182
|
}
|
|
183
183
|
|
|
184
|
-
export interface MeasuredGridProps
|
|
185
|
-
extends Omit<ComponentPropsWithRef<"div">, "children" | "onChange"> {
|
|
184
|
+
export interface MeasuredGridProps extends Omit<ComponentPropsWithRef<"div">, "children" | "onChange"> {
|
|
186
185
|
/** What the table is — shown above it, and the grid's accessible name. */
|
|
187
186
|
label: string;
|
|
188
187
|
/** A note under the table (which columns a layout expects, say). Also the grid's
|
|
@@ -393,9 +392,7 @@ function CellGrid({
|
|
|
393
392
|
useEffect(() => {
|
|
394
393
|
const target = pending.current;
|
|
395
394
|
if (!target) return;
|
|
396
|
-
const element = scrollRef.current?.querySelector<HTMLElement>(
|
|
397
|
-
`[data-cell="${target.row}:${target.column}"]`,
|
|
398
|
-
);
|
|
395
|
+
const element = scrollRef.current?.querySelector<HTMLElement>(`[data-cell="${target.row}:${target.column}"]`);
|
|
399
396
|
if (!element) return;
|
|
400
397
|
pending.current = null;
|
|
401
398
|
// `preventScroll`: `reveal` already scrolled the row clear of the sticky header,
|
|
@@ -595,26 +592,12 @@ function CellGrid({
|
|
|
595
592
|
#
|
|
596
593
|
</div>
|
|
597
594
|
{columns.map((column, index) => (
|
|
598
|
-
<div
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
className="min-w-0 border-s border-subtle px-2 py-1 text-end"
|
|
602
|
-
>
|
|
603
|
-
<span className="block truncate font-medium text-primary">
|
|
604
|
-
{column.label}
|
|
605
|
-
</span>
|
|
606
|
-
{column.unit && (
|
|
607
|
-
<span className="block truncate text-micro text-muted">
|
|
608
|
-
{column.unit}
|
|
609
|
-
</span>
|
|
610
|
-
)}
|
|
595
|
+
<div key={index} role="columnheader" className="min-w-0 border-s border-subtle px-2 py-1 text-end">
|
|
596
|
+
<span className="block truncate font-medium text-primary">{column.label}</span>
|
|
597
|
+
{column.unit && <span className="block truncate text-micro text-muted">{column.unit}</span>}
|
|
611
598
|
</div>
|
|
612
599
|
))}
|
|
613
|
-
<div
|
|
614
|
-
role="columnheader"
|
|
615
|
-
aria-label={labels.rowActions}
|
|
616
|
-
className="border-s border-subtle"
|
|
617
|
-
/>
|
|
600
|
+
<div role="columnheader" aria-label={labels.rowActions} className="border-s border-subtle" />
|
|
618
601
|
</div>
|
|
619
602
|
</div>
|
|
620
603
|
{/* Only the rows in the window are mounted — a swept linkage is thousands of
|
|
@@ -711,10 +694,7 @@ function CellGrid({
|
|
|
711
694
|
</div>
|
|
712
695
|
);
|
|
713
696
|
})}
|
|
714
|
-
<div
|
|
715
|
-
role="gridcell"
|
|
716
|
-
className="flex items-center justify-center border-s border-subtle"
|
|
717
|
-
>
|
|
697
|
+
<div role="gridcell" className="flex items-center justify-center border-s border-subtle">
|
|
718
698
|
<button
|
|
719
699
|
type="button"
|
|
720
700
|
data-cell={`${index}:${width}`}
|
|
@@ -776,9 +756,7 @@ function CellGrid({
|
|
|
776
756
|
{/* bdi: an LTR label ("3 points") in an RTL grid would reorder to "points 3". */}
|
|
777
757
|
<bdi>{labels.points(filled.length)}</bdi>
|
|
778
758
|
</span>
|
|
779
|
-
{problems > 0 && (
|
|
780
|
-
<span className="text-caption text-danger">{labels.problems(problems)}</span>
|
|
781
|
-
)}
|
|
759
|
+
{problems > 0 && <span className="text-caption text-danger">{labels.problems(problems)}</span>}
|
|
782
760
|
<span className="ms-auto flex items-center gap-1 text-caption text-muted">
|
|
783
761
|
<ClipboardPaste aria-hidden className="size-3.5" /> {labels.pasteHint}
|
|
784
762
|
</span>
|
|
@@ -224,9 +224,7 @@ export function MenuItem({
|
|
|
224
224
|
// dimmed") rather than greyed to the point some browsers stop exposing it.
|
|
225
225
|
aria-disabled={disabled || undefined}
|
|
226
226
|
onClick={
|
|
227
|
-
disabled
|
|
228
|
-
? (e) => e.preventDefault()
|
|
229
|
-
: (onClick as ((event: MouseEvent<HTMLButtonElement>) => void) | undefined)
|
|
227
|
+
disabled ? (e) => e.preventDefault() : (onClick as ((event: MouseEvent<HTMLButtonElement>) => void) | undefined)
|
|
230
228
|
}
|
|
231
229
|
className={look}
|
|
232
230
|
>
|