@eifi1/ui-kit 0.29.0 → 0.31.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +65 -6
- package/dist/account/account-parts.d.ts +21 -0
- package/dist/account/account-parts.js +40 -0
- package/dist/account/account-parts.js.map +1 -0
- package/dist/account/data-export-setting.d.ts +73 -0
- package/dist/account/data-export-setting.js +114 -0
- package/dist/account/data-export-setting.js.map +1 -0
- package/dist/account/delete-account-setting.d.ts +95 -0
- package/dist/account/delete-account-setting.js +200 -0
- package/dist/account/delete-account-setting.js.map +1 -0
- package/dist/account/email-change-setting.d.ts +136 -0
- package/dist/account/email-change-setting.js +278 -0
- package/dist/account/email-change-setting.js.map +1 -0
- package/dist/account/sessions-setting.d.ts +110 -0
- package/dist/account/sessions-setting.js +147 -0
- package/dist/account/sessions-setting.js.map +1 -0
- package/dist/admin/admin-action-confirm.d.ts +95 -0
- package/dist/admin/admin-action-confirm.js +276 -0
- package/dist/admin/admin-action-confirm.js.map +1 -0
- package/dist/admin/admin-action-log.d.ts +105 -0
- package/dist/admin/admin-action-log.js +153 -0
- package/dist/admin/admin-action-log.js.map +1 -0
- package/dist/admin/admin-parts.d.ts +40 -0
- package/dist/admin/admin-parts.js +45 -0
- package/dist/admin/admin-parts.js.map +1 -0
- package/dist/admin/invitations-panel.d.ts +95 -0
- package/dist/admin/invitations-panel.js +290 -0
- package/dist/admin/invitations-panel.js.map +1 -0
- package/dist/admin/reviewer-scope-editor.d.ts +95 -0
- package/dist/admin/reviewer-scope-editor.js +134 -0
- package/dist/admin/reviewer-scope-editor.js.map +1 -0
- package/dist/admin/role-select.d.ts +95 -0
- package/dist/admin/role-select.js +128 -0
- package/dist/admin/role-select.js.map +1 -0
- package/dist/admin/transfer-ownership-dialog.d.ts +95 -0
- package/dist/admin/transfer-ownership-dialog.js +83 -0
- package/dist/admin/transfer-ownership-dialog.js.map +1 -0
- package/dist/admin/user-roster.d.ts +95 -0
- package/dist/admin/user-roster.js +285 -0
- package/dist/admin/user-roster.js.map +1 -0
- package/dist/auth/auth-errors.d.ts +103 -6
- package/dist/auth/auth-errors.js +68 -2
- package/dist/auth/auth-errors.js.map +1 -1
- package/dist/auth/forgot-password-form.d.ts +10 -3
- package/dist/auth/forgot-password-form.js +6 -3
- package/dist/auth/forgot-password-form.js.map +1 -1
- package/dist/auth/register-form.d.ts +21 -12
- package/dist/auth/register-form.js +6 -4
- package/dist/auth/register-form.js.map +1 -1
- package/dist/auth/reset-password-form.d.ts +10 -3
- package/dist/auth/reset-password-form.js +6 -3
- package/dist/auth/reset-password-form.js.map +1 -1
- package/dist/auth/sign-in-form.d.ts +75 -9
- package/dist/auth/sign-in-form.js +105 -15
- package/dist/auth/sign-in-form.js.map +1 -1
- package/dist/auth/verify-email.d.ts +7 -2
- package/dist/auth/verify-email.js +44 -8
- package/dist/auth/verify-email.js.map +1 -1
- package/dist/chart.d.ts +20 -11
- package/dist/components/account-chips.d.ts +47 -7
- package/dist/components/account-chips.js +19 -3
- package/dist/components/account-chips.js.map +1 -1
- package/dist/components/account-settings-labels.d.ts +24 -1
- package/dist/components/account-settings-labels.js +6 -2
- package/dist/components/account-settings-labels.js.map +1 -1
- package/dist/components/account-settings.d.ts +69 -8
- package/dist/components/account-settings.js +133 -25
- package/dist/components/account-settings.js.map +1 -1
- package/dist/components/amount-input.d.ts +21 -12
- package/dist/components/button-group.d.ts +21 -12
- package/dist/components/calculator.d.ts +21 -12
- package/dist/components/confirm-dialog.d.ts +21 -12
- package/dist/components/copy-button.d.ts +18 -9
- package/dist/components/danger-confirm.d.ts +21 -12
- package/dist/components/data-table.js +8 -1
- package/dist/components/data-table.js.map +1 -1
- package/dist/components/date-picker.js +9 -4
- package/dist/components/date-picker.js.map +1 -1
- package/dist/components/facing-pair.d.ts +21 -12
- package/dist/components/file-button.d.ts +21 -12
- package/dist/components/file-dropzone.d.ts +21 -12
- package/dist/components/form-actions.d.ts +21 -12
- package/dist/components/iban-input.d.ts +21 -12
- package/dist/components/language-select.d.ts +21 -12
- package/dist/components/legal-page.d.ts +21 -12
- package/dist/components/legal.d.ts +21 -12
- package/dist/components/money-field.d.ts +21 -12
- package/dist/components/number-field.d.ts +21 -12
- package/dist/components/number-input.d.ts +21 -12
- package/dist/components/numpad-sheet.d.ts +21 -12
- package/dist/components/passkeys-setting.js +2 -1
- package/dist/components/passkeys-setting.js.map +1 -1
- package/dist/components/phone-input.d.ts +21 -12
- package/dist/components/series-chart.d.ts +21 -12
- package/dist/components/settings-fields.d.ts +55 -13
- package/dist/components/settings-fields.js +20 -1
- package/dist/components/settings-fields.js.map +1 -1
- package/dist/components/share-card.d.ts +20 -11
- package/dist/components/text-link.d.ts +21 -12
- package/dist/components/time-input.d.ts +21 -12
- package/dist/components/ui.d.ts +17 -8
- package/dist/{register-form-V1OeNlMr.d.ts → delete-account-setting-DCFS5Vof.d.ts} +6612 -5612
- package/dist/demo/demo-banner.d.ts +51 -0
- package/dist/demo/demo-banner.js +97 -0
- package/dist/demo/demo-banner.js.map +1 -0
- package/dist/demo/demo-countdown.d.ts +58 -0
- package/dist/demo/demo-countdown.js +79 -0
- package/dist/demo/demo-countdown.js.map +1 -0
- package/dist/demo/demo-ended.d.ts +45 -0
- package/dist/demo/demo-ended.js +42 -0
- package/dist/demo/demo-ended.js.map +1 -0
- package/dist/demo/demo-labels.d.ts +53 -0
- package/dist/demo/demo-labels.js +29 -0
- package/dist/demo/demo-labels.js.map +1 -0
- package/dist/demo/demo-session.d.ts +30 -0
- package/dist/demo/demo-session.js +8 -0
- package/dist/demo/demo-session.js.map +1 -0
- package/dist/demo/demo-start.d.ts +54 -0
- package/dist/demo/demo-start.js +68 -0
- package/dist/demo/demo-start.js.map +1 -0
- package/dist/feedback/feedback-attachment.d.ts +21 -12
- package/dist/feedback/feedback-context.d.ts +21 -12
- package/dist/feedback/feedback-crash.d.ts +21 -12
- package/dist/feedback/feedback-dialog.d.ts +21 -12
- package/dist/feedback/feedback-inbox.d.ts +21 -12
- package/dist/feedback/feedback-inbox.js +12 -2
- package/dist/feedback/feedback-inbox.js.map +1 -1
- package/dist/feedback/feedback-labels.d.ts +21 -12
- package/dist/feedback/feedback-labels.js +1 -0
- package/dist/feedback/feedback-labels.js.map +1 -1
- package/dist/feedback/feedback-menu.d.ts +21 -12
- package/dist/feedback/feedback-record.d.ts +21 -12
- package/dist/feedback/feedback-record.js +2 -0
- package/dist/feedback/feedback-record.js.map +1 -1
- package/dist/feedback/feedback-row-detail.d.ts +21 -12
- package/dist/feedback/feedback-row-detail.js +7 -0
- package/dist/feedback/feedback-row-detail.js.map +1 -1
- package/dist/feedback/feedback-status-undo.d.ts +21 -12
- package/dist/feedback/feedback-submit.d.ts +21 -12
- package/dist/feedback/feedback-swipe.d.ts +22 -13
- package/dist/feedback/feedback-swipe.js.map +1 -1
- package/dist/feedback/feedback-table.d.ts +18 -9
- package/dist/feedback/feedback-thread.d.ts +21 -12
- package/dist/feedback.d.ts +21 -12
- package/dist/hooks/use-anchored-panel.d.ts +6 -2
- package/dist/hooks/use-anchored-panel.js +2 -1
- package/dist/hooks/use-anchored-panel.js.map +1 -1
- package/dist/hooks/use-file-drop.d.ts +21 -12
- package/dist/i18n/defaults.d.ts +21 -12
- package/dist/i18n/defaults.js +28 -0
- package/dist/i18n/defaults.js.map +1 -1
- package/dist/i18n/german.d.ts +21 -12
- package/dist/i18n/german.js +298 -12
- package/dist/i18n/german.js.map +1 -1
- package/dist/i18n/kit-labels.d.ts +14 -5
- package/dist/i18n/kit-labels.js.map +1 -1
- package/dist/i18n/languages.d.ts +15 -6
- package/dist/i18n/locales/de-CH.d.ts +21 -12
- package/dist/i18n/locales/en.d.ts +21 -12
- package/dist/i18n/locales/es.d.ts +21 -12
- package/dist/i18n/locales/es.js +287 -10
- package/dist/i18n/locales/es.js.map +1 -1
- package/dist/i18n/locales/fr.d.ts +21 -12
- package/dist/i18n/locales/fr.js +290 -7
- package/dist/i18n/locales/fr.js.map +1 -1
- package/dist/i18n/locales/hu.d.ts +21 -12
- package/dist/i18n/locales/hu.js +288 -12
- package/dist/i18n/locales/hu.js.map +1 -1
- package/dist/i18n/locales/it.d.ts +21 -12
- package/dist/i18n/locales/it.js +289 -7
- package/dist/i18n/locales/it.js.map +1 -1
- package/dist/i18n/locales/zh.d.ts +21 -12
- package/dist/i18n/locales/zh.js +279 -7
- package/dist/i18n/locales/zh.js.map +1 -1
- package/dist/i18n/review.d.ts +21 -12
- package/dist/i18n/review.js +50 -1
- package/dist/i18n/review.js.map +1 -1
- package/dist/index.d.ts +31 -4
- package/dist/index.js +148 -0
- package/dist/index.js.map +1 -1
- package/dist/landing/access.d.ts +48 -0
- package/dist/landing/access.js +38 -0
- package/dist/landing/access.js.map +1 -0
- package/dist/landing/landing-actions.d.ts +138 -0
- package/dist/landing/landing-actions.js +39 -0
- package/dist/landing/landing-actions.js.map +1 -0
- package/dist/landing/landing-labels.d.ts +43 -0
- package/dist/landing/landing-labels.js +23 -0
- package/dist/landing/landing-labels.js.map +1 -0
- package/dist/landing/landing-sections.d.ts +218 -0
- package/dist/landing/landing-sections.js +167 -0
- package/dist/landing/landing-sections.js.map +1 -0
- package/dist/landing/page-seo.d.ts +99 -0
- package/dist/landing/page-seo.js +121 -0
- package/dist/landing/page-seo.js.map +1 -0
- package/dist/landing/public-header.d.ts +148 -0
- package/dist/landing/public-header.js +49 -0
- package/dist/landing/public-header.js.map +1 -0
- package/dist/landing/routing.d.ts +218 -0
- package/dist/landing/routing.js +81 -0
- package/dist/landing/routing.js.map +1 -0
- package/dist/rhf/fields.d.ts +21 -12
- package/dist/rhf/form.d.ts +21 -12
- package/dist/rhf.d.ts +21 -12
- package/dist/settings/settings-catalogue.d.ts +84 -0
- package/dist/settings/settings-catalogue.js +47 -0
- package/dist/settings/settings-catalogue.js.map +1 -0
- package/dist/settings/settings-context.d.ts +31 -0
- package/dist/settings/settings-context.js +11 -0
- package/dist/settings/settings-context.js.map +1 -0
- package/dist/settings/settings-heading.d.ts +50 -0
- package/dist/settings/settings-heading.js +27 -0
- package/dist/settings/settings-heading.js.map +1 -0
- package/dist/settings/settings-labels.d.ts +41 -0
- package/dist/settings/settings-labels.js +38 -0
- package/dist/settings/settings-labels.js.map +1 -0
- package/dist/settings/settings-layout.d.ts +77 -0
- package/dist/settings/settings-layout.js +242 -0
- package/dist/settings/settings-layout.js.map +1 -0
- package/dist/settings/settings-section.d.ts +133 -0
- package/dist/settings/settings-section.js +63 -0
- package/dist/settings/settings-section.js.map +1 -0
- package/dist/settings/use-account-language.d.ts +83 -0
- package/dist/settings/use-account-language.js +62 -0
- package/dist/settings/use-account-language.js.map +1 -0
- package/dist/settings/use-settings-focus.d.ts +34 -0
- package/dist/settings/use-settings-focus.js +77 -0
- package/dist/settings/use-settings-focus.js.map +1 -0
- package/dist/settings/use-settings-route.d.ts +118 -0
- package/dist/settings/use-settings-route.js +120 -0
- package/dist/settings/use-settings-route.js.map +1 -0
- package/dist/shell/app-shell.d.ts +27 -12
- package/dist/shell/app-shell.js +3 -2
- package/dist/shell/app-shell.js.map +1 -1
- package/dist/shell/top-bar-brand.d.ts +21 -12
- package/dist/shell.d.ts +25 -6
- package/dist/shell.js +56 -0
- package/dist/shell.js.map +1 -1
- package/dist/wizard/stepper-nav.d.ts +21 -12
- package/dist/wizard.d.ts +21 -12
- package/package.json +2 -1
- package/src/account/account-parts.ts +67 -0
- package/src/account/data-export-setting.tsx +219 -0
- package/src/account/delete-account-setting.tsx +363 -0
- package/src/account/email-change-setting.tsx +454 -0
- package/src/account/sessions-setting.tsx +284 -0
- package/src/admin/admin-action-confirm.tsx +495 -0
- package/src/admin/admin-action-log.tsx +297 -0
- package/src/admin/admin-parts.ts +82 -0
- package/src/admin/invitations-panel.tsx +523 -0
- package/src/admin/reviewer-scope-editor.tsx +234 -0
- package/src/admin/role-select.tsx +286 -0
- package/src/admin/transfer-ownership-dialog.tsx +172 -0
- package/src/admin/user-roster.tsx +573 -0
- package/src/auth/auth-errors.ts +196 -8
- package/src/auth/forgot-password-form.tsx +21 -5
- package/src/auth/register-form.tsx +24 -6
- package/src/auth/reset-password-form.tsx +19 -5
- package/src/auth/sign-in-form.tsx +241 -38
- package/src/auth/verify-email.tsx +59 -8
- package/src/components/account-chips.tsx +64 -7
- package/src/components/account-settings-labels.ts +28 -1
- package/src/components/account-settings.tsx +231 -34
- package/src/components/data-table.tsx +8 -0
- package/src/components/date-picker.tsx +9 -4
- package/src/components/passkeys-setting.tsx +2 -1
- package/src/components/settings-fields.tsx +50 -1
- package/src/demo/demo-banner.tsx +159 -0
- package/src/demo/demo-countdown.ts +141 -0
- package/src/demo/demo-ended.tsx +89 -0
- package/src/demo/demo-labels.ts +78 -0
- package/src/demo/demo-session.ts +32 -0
- package/src/demo/demo-start.tsx +150 -0
- package/src/feedback/feedback-inbox.tsx +21 -8
- package/src/feedback/feedback-labels.ts +2 -1
- package/src/feedback/feedback-record.ts +10 -7
- package/src/feedback/feedback-row-detail.tsx +28 -4
- package/src/feedback/feedback-swipe.tsx +1 -1
- package/src/hooks/use-anchored-panel.ts +14 -3
- package/src/i18n/defaults.ts +28 -0
- package/src/i18n/german.ts +327 -5
- package/src/i18n/kit-labels.tsx +42 -0
- package/src/i18n/locales/es.ts +313 -3
- package/src/i18n/locales/fr.ts +316 -0
- package/src/i18n/locales/hu.ts +308 -5
- package/src/i18n/locales/it.ts +313 -0
- package/src/i18n/locales/zh.ts +286 -0
- package/src/i18n/review.ts +49 -0
- package/src/index.ts +184 -0
- package/src/landing/access.ts +97 -0
- package/src/landing/landing-actions.tsx +92 -0
- package/src/landing/landing-labels.ts +59 -0
- package/src/landing/landing-sections.tsx +337 -0
- package/src/landing/page-seo.ts +251 -0
- package/src/landing/public-header.tsx +120 -0
- package/src/landing/routing.tsx +209 -0
- package/src/settings/settings-catalogue.ts +132 -0
- package/src/settings/settings-context.ts +33 -0
- package/src/settings/settings-heading.tsx +65 -0
- package/src/settings/settings-labels.ts +75 -0
- package/src/settings/settings-layout.tsx +379 -0
- package/src/settings/settings-section.tsx +108 -0
- package/src/settings/use-account-language.ts +146 -0
- package/src/settings/use-settings-focus.ts +120 -0
- package/src/settings/use-settings-route.ts +258 -0
- package/src/shell/app-shell.tsx +10 -2
- package/src/shell.ts +45 -0
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import 'react';
|
|
2
|
+
export { cC as DEFAULT_REVIEWER_SCOPE_LABELS, en as ReviewerScope, eo as ReviewerScopeArea, ep as ReviewerScopeEditor, eq as ReviewerScopeEditorProps, er as ReviewerScopeLabels, es as ReviewerScopeLanguage } from '../delete-account-setting-DCFS5Vof.js';
|
|
3
|
+
import './admin-parts.js';
|
|
4
|
+
import '../components/tooltip.js';
|
|
5
|
+
import '../hooks/use-anchored-rect.js';
|
|
6
|
+
import '../lib/clipping.js';
|
|
7
|
+
import '../data-table-labels-DUELeXpa.js';
|
|
8
|
+
import '../components/data-table-sort.js';
|
|
9
|
+
import '../components/swipeable-row.js';
|
|
10
|
+
import '../components/mini-calendar.js';
|
|
11
|
+
import '../components/calendar-heatmap.js';
|
|
12
|
+
import '../components/popover.js';
|
|
13
|
+
import '../components/chip.js';
|
|
14
|
+
import 'lucide-react';
|
|
15
|
+
import '../components/field-sync.js';
|
|
16
|
+
import '../wizard/types.js';
|
|
17
|
+
import '../tour/tour.js';
|
|
18
|
+
import '../search/command-palette.js';
|
|
19
|
+
import '../search/global-search.js';
|
|
20
|
+
import '../search/search-index.js';
|
|
21
|
+
import '../components/month-picker.js';
|
|
22
|
+
import '../components/page-contents.js';
|
|
23
|
+
import '../components/series-chart-labels.js';
|
|
24
|
+
import '../components/pie-chart-labels.js';
|
|
25
|
+
import '../components/sparkline.js';
|
|
26
|
+
import '../components/stat-tile.js';
|
|
27
|
+
import '../components/signature-pad.js';
|
|
28
|
+
import '../components/password-strength.js';
|
|
29
|
+
import '../components/swatch-picker.js';
|
|
30
|
+
import '../components/tile-radio.js';
|
|
31
|
+
import '../components/icon-picker.js';
|
|
32
|
+
import '../components/dialog-frame.js';
|
|
33
|
+
import '../components/modal.js';
|
|
34
|
+
import '../hooks/use-search-param-state.js';
|
|
35
|
+
import '../components/measured-grid.js';
|
|
36
|
+
import '../components/user-avatar.js';
|
|
37
|
+
import '../lib/person-name.js';
|
|
38
|
+
import '../components/status-dot.js';
|
|
39
|
+
import '../components/progress-bar.js';
|
|
40
|
+
import '../components/signed-amount.js';
|
|
41
|
+
import '../shell/topbar-action-menu.js';
|
|
42
|
+
import '../components/menu-item.js';
|
|
43
|
+
import '../components/floating-panel.js';
|
|
44
|
+
import '../hooks/use-authed-src.js';
|
|
45
|
+
import '../components/account-settings-labels.js';
|
|
46
|
+
import '../components/bulk-action-bar.js';
|
|
47
|
+
import '../components/list.js';
|
|
48
|
+
import '../components/breadcrumbs.js';
|
|
49
|
+
import '../components/toast.js';
|
|
50
|
+
import '../components/description-list.js';
|
|
51
|
+
import '../components/line-items.js';
|
|
52
|
+
import '../components/error-boundary.js';
|
|
53
|
+
import '../components/authed-image.js';
|
|
54
|
+
import '../components/image-grid.js';
|
|
55
|
+
import '../components/lightbox.js';
|
|
56
|
+
import '../components/write-lock.js';
|
|
57
|
+
import '../auth/sign-in-form.js';
|
|
58
|
+
import '../landing/access.js';
|
|
59
|
+
import '../landing/landing-labels.js';
|
|
60
|
+
import '../shell/topbar-controls.js';
|
|
61
|
+
import '../theme/palette-presets.js';
|
|
62
|
+
import '../theme/chart-palette.js';
|
|
63
|
+
import '../theme/theme-store.js';
|
|
64
|
+
import 'zustand/middleware';
|
|
65
|
+
import 'zustand';
|
|
66
|
+
import '../auth/complete-name-dialog.js';
|
|
67
|
+
import '../auth/forgot-password-form.js';
|
|
68
|
+
import '../auth/status-parts.js';
|
|
69
|
+
import '../auth/reset-password-form.js';
|
|
70
|
+
import '../auth/verify-email.js';
|
|
71
|
+
import '../auth/not-found-page.js';
|
|
72
|
+
import '../auth/accept-invitation.js';
|
|
73
|
+
import '../shell/company-switcher.js';
|
|
74
|
+
import '../account/email-change-setting.js';
|
|
75
|
+
import '../account/sessions-setting.js';
|
|
76
|
+
import '../lib/format.js';
|
|
77
|
+
import '../account/data-export-setting.js';
|
|
78
|
+
import '../components/account-chips.js';
|
|
79
|
+
import './admin-action-log.js';
|
|
80
|
+
import '../settings/settings-labels.js';
|
|
81
|
+
import '../demo/demo-labels.js';
|
|
82
|
+
import '../components/reauth-dialog.js';
|
|
83
|
+
import '../components/server-wake.js';
|
|
84
|
+
import '../lib/server-wake.js';
|
|
85
|
+
import '../components/translation-review-labels.js';
|
|
86
|
+
import '../lib/translation-review.js';
|
|
87
|
+
import '../components/country-select.js';
|
|
88
|
+
import '../components/inline-edit-field.js';
|
|
89
|
+
import '../lib/iban.js';
|
|
90
|
+
import '../lib/phone.js';
|
|
91
|
+
import '../components/sign-chip.js';
|
|
92
|
+
import '../components/column-mapper.js';
|
|
93
|
+
import '../lib/column-mapping.js';
|
|
94
|
+
import '../lib/table-text.js';
|
|
95
|
+
import '../components/field-parts.js';
|
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { useState } from "react";
|
|
4
|
+
import { useKitLabels } from "../i18n/kit-labels.js";
|
|
5
|
+
import { KIT_LANGUAGES } from "../i18n/languages.js";
|
|
6
|
+
import { AlertBanner } from "../components/alert-banner.js";
|
|
7
|
+
import { CheckboxGroup } from "../components/checkbox-group.js";
|
|
8
|
+
import { FormActions } from "../components/form-actions.js";
|
|
9
|
+
import { Caption } from "../components/text.js";
|
|
10
|
+
import { hasMessage } from "./admin-parts.js";
|
|
11
|
+
const DEFAULT_REVIEWER_SCOPE_LABELS = {
|
|
12
|
+
languages: "Languages",
|
|
13
|
+
hint: "Tick the languages this person reviews.",
|
|
14
|
+
none: "No language: saving takes the reviewer role away.",
|
|
15
|
+
areas: "Limit to",
|
|
16
|
+
legalOnly: "Only the legal pages",
|
|
17
|
+
legalOnlyHint: "Imprint, Privacy Policy and Terms \u2014 for a lawyer rather than a native speaker.",
|
|
18
|
+
failed: "The reviewer scope couldn\u2019t be saved. Please try again."
|
|
19
|
+
};
|
|
20
|
+
function languageOptions(languages) {
|
|
21
|
+
const rows = languages ?? KIT_LANGUAGES.map((language) => language.code);
|
|
22
|
+
return rows.map((row) => {
|
|
23
|
+
if (typeof row !== "string") return { value: row.value, label: row.label };
|
|
24
|
+
const language = KIT_LANGUAGES.find((entry) => entry.code === row);
|
|
25
|
+
return {
|
|
26
|
+
value: row,
|
|
27
|
+
// Each name in its own language, marked so a screen reader says it so.
|
|
28
|
+
label: language ? /* @__PURE__ */ jsx("span", { lang: language.formatLocale, children: language.nativeName }) : row
|
|
29
|
+
};
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
function sameSet(a, b) {
|
|
33
|
+
if (a.length !== b.length) return false;
|
|
34
|
+
const seen = new Set(a);
|
|
35
|
+
return b.every((x) => seen.has(x));
|
|
36
|
+
}
|
|
37
|
+
function ReviewerScopeEditor({
|
|
38
|
+
value,
|
|
39
|
+
onSave,
|
|
40
|
+
onCancel,
|
|
41
|
+
languages,
|
|
42
|
+
areas: areasProp,
|
|
43
|
+
disabledReason,
|
|
44
|
+
describeError,
|
|
45
|
+
intro,
|
|
46
|
+
columns = 2,
|
|
47
|
+
commit,
|
|
48
|
+
labels: labelsProp
|
|
49
|
+
}) {
|
|
50
|
+
const labels = useKitLabels("reviewerScope", DEFAULT_REVIEWER_SCOPE_LABELS, labelsProp);
|
|
51
|
+
const areaOptions = areasProp ?? [{ value: "legal", label: labels.legalOnly, hint: labels.legalOnlyHint }];
|
|
52
|
+
const savedLocales = [...value.locales ?? []];
|
|
53
|
+
const savedAreas = [...value.areas ?? []];
|
|
54
|
+
const [locales, setLocales] = useState(savedLocales);
|
|
55
|
+
const [areas, setAreas] = useState(savedAreas);
|
|
56
|
+
const [pending, setPending] = useState(false);
|
|
57
|
+
const [failure, setFailure] = useState(null);
|
|
58
|
+
const locked = hasMessage(disabledReason);
|
|
59
|
+
const nextAreas = locales.length === 0 ? [] : areas;
|
|
60
|
+
const dirty = !sameSet(locales, savedLocales) || !sameSet(nextAreas, locales.length === 0 ? [] : savedAreas);
|
|
61
|
+
const save = () => {
|
|
62
|
+
if (pending || locked || !dirty) return;
|
|
63
|
+
const scope = {
|
|
64
|
+
locales,
|
|
65
|
+
areas: locales.length > 0 && areas.length > 0 ? areas : null
|
|
66
|
+
};
|
|
67
|
+
setFailure(null);
|
|
68
|
+
let result;
|
|
69
|
+
try {
|
|
70
|
+
result = onSave(scope);
|
|
71
|
+
} catch (error) {
|
|
72
|
+
setFailure(describeError?.(error) ?? labels.failed);
|
|
73
|
+
return;
|
|
74
|
+
}
|
|
75
|
+
if (!result || typeof result.then !== "function") return;
|
|
76
|
+
setPending(true);
|
|
77
|
+
result.then(
|
|
78
|
+
() => setPending(false),
|
|
79
|
+
(error) => {
|
|
80
|
+
setPending(false);
|
|
81
|
+
const own = describeError?.(error);
|
|
82
|
+
setFailure(hasMessage(own) ? own : labels.failed);
|
|
83
|
+
}
|
|
84
|
+
);
|
|
85
|
+
};
|
|
86
|
+
return /* @__PURE__ */ jsxs("div", { className: "space-y-3", children: [
|
|
87
|
+
intro && /* @__PURE__ */ jsx("div", { className: "text-sm text-[var(--text-secondary)]", children: intro }),
|
|
88
|
+
/* @__PURE__ */ jsx(
|
|
89
|
+
CheckboxGroup,
|
|
90
|
+
{
|
|
91
|
+
legend: labels.languages,
|
|
92
|
+
options: languageOptions(languages),
|
|
93
|
+
value: locales,
|
|
94
|
+
onChange: (next) => {
|
|
95
|
+
setFailure(null);
|
|
96
|
+
setLocales(next);
|
|
97
|
+
},
|
|
98
|
+
columns,
|
|
99
|
+
hint: locked ? void 0 : locales.length === 0 ? labels.none : labels.hint,
|
|
100
|
+
disabledReason
|
|
101
|
+
}
|
|
102
|
+
),
|
|
103
|
+
areaOptions.length > 0 && /* @__PURE__ */ jsx(
|
|
104
|
+
CheckboxGroup,
|
|
105
|
+
{
|
|
106
|
+
legend: labels.areas,
|
|
107
|
+
options: areaOptions.map((area) => ({ value: area.value, label: area.label, hint: area.hint })),
|
|
108
|
+
value: nextAreas,
|
|
109
|
+
onChange: (next) => {
|
|
110
|
+
setFailure(null);
|
|
111
|
+
setAreas(next);
|
|
112
|
+
},
|
|
113
|
+
disabled: locales.length === 0,
|
|
114
|
+
disabledReason
|
|
115
|
+
}
|
|
116
|
+
),
|
|
117
|
+
failure && /* @__PURE__ */ jsx(AlertBanner, { tone: "danger", size: "sm", children: failure }),
|
|
118
|
+
locked ? /* @__PURE__ */ jsx(Caption, { children: disabledReason }) : /* @__PURE__ */ jsx(
|
|
119
|
+
FormActions,
|
|
120
|
+
{
|
|
121
|
+
onSubmit: save,
|
|
122
|
+
onCancel,
|
|
123
|
+
pending,
|
|
124
|
+
submitDisabled: !dirty,
|
|
125
|
+
commit
|
|
126
|
+
}
|
|
127
|
+
)
|
|
128
|
+
] });
|
|
129
|
+
}
|
|
130
|
+
export {
|
|
131
|
+
DEFAULT_REVIEWER_SCOPE_LABELS,
|
|
132
|
+
ReviewerScopeEditor
|
|
133
|
+
};
|
|
134
|
+
//# sourceMappingURL=reviewer-scope-editor.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/admin/reviewer-scope-editor.tsx"],"sourcesContent":["import { useState } from \"react\";\nimport type { ReactNode } from \"react\";\nimport { useKitLabels } from \"../i18n/kit-labels\";\nimport { KIT_LANGUAGES } from \"../i18n/languages\";\nimport type { KitLanguageCode } from \"../i18n/languages\";\nimport { AlertBanner } from \"../components/alert-banner\";\nimport { CheckboxGroup } from \"../components/checkbox-group\";\nimport type { CheckboxGroupOption } from \"../components/checkbox-group\";\nimport { FormActions } from \"../components/form-actions\";\nimport { Caption } from \"../components/text\";\nimport { hasMessage } from \"./admin-parts\";\nimport type { MaybePromise } from \"./admin-parts\";\n\n/**\n * Who may review which translations: the REVIEWER role and its scope, in one editor\n * (docs/user-admin-harmonization.md §4.1 `PUT /admin/users/{id}/reviewer {locales, areas}`,\n * §7). It replaces three: keksdose's `user-reviewer-role.tsx` (a checkbox per language,\n * saved on each click), Kurvenschmiede's `reviewer-dialog.tsx` (a `CheckboxGroup` in a\n * dialog with Save) and kastlan's platform column.\n *\n * - **Languages** are the scope. Ticking none takes the role away — that is how both\n * apps remove a reviewer — and the editor says so under the boxes.\n * - **Areas** narrow it: \"Only the legal pages\" (Imprint, Privacy Policy, Terms) for a\n * lawyer, who reads law, not French. An area only means something beside at least one\n * language, so the areas wait for one. Saved as `areas: null` when none is ticked —\n * server-kit's \"every area\" — never `[]`, which would be \"no area at all\".\n *\n * A draft with Save, not a save per click: keksdose saved every tick, and two quick ticks\n * could land as a set nobody chose; one Save sends the whole scope, in the languages'\n * order (CheckboxGroup's), so the answer equals the request and the row does not\n * reshuffle on refetch. The server keeps its rules (an admin reviews everything already,\n * a customer is not given the role): `disabledReason` says them here.\n */\n\n/** A reviewer's scope — the request body of `PUT …/reviewer`. */\nexport interface ReviewerScope {\n /** Language codes, in the editor's order. Empty: not a reviewer. */\n locales: string[];\n /** The areas the scope is narrowed to; `null` = every area (server-kit's rule). */\n areas: string[] | null;\n}\n\n/** One area the scope can be narrowed to. */\nexport interface ReviewerScopeArea {\n value: string;\n label: ReactNode;\n hint?: ReactNode;\n}\n\n/** One language the editor offers, when the app's list is not the kit's codes. */\nexport interface ReviewerScopeLanguage {\n value: string;\n label: ReactNode;\n}\n\n/** The `reviewerScope` namespace. */\nexport interface ReviewerScopeLabels {\n /** The language group's legend. */\n languages: string;\n /** Under the languages. */\n hint: string;\n /** Under the languages while none is ticked. */\n none: string;\n /** The area group's legend. */\n areas: string;\n /** The default area, `legal`. */\n legalOnly: string;\n legalOnlyHint: string;\n /** A rejected save, unless `describeError` says better. */\n failed: string;\n}\n\nexport const DEFAULT_REVIEWER_SCOPE_LABELS: ReviewerScopeLabels = {\n languages: \"Languages\",\n hint: \"Tick the languages this person reviews.\",\n none: \"No language: saving takes the reviewer role away.\",\n areas: \"Limit to\",\n legalOnly: \"Only the legal pages\",\n legalOnlyHint: \"Imprint, Privacy Policy and Terms — for a lawyer rather than a native speaker.\",\n failed: \"The reviewer scope couldn’t be saved. Please try again.\",\n};\n\nexport interface ReviewerScopeEditorProps {\n /** The scope the server has — the draft starts from it. Key the editor by the\n * account (`key={user.id}`) so another account starts a fresh draft. */\n value: { locales?: readonly string[] | null; areas?: readonly string[] | null };\n /** Sends the scope. A promise keeps the editor busy, and a rejection keeps the draft\n * and shows why. */\n onSave: (scope: ReviewerScope) => MaybePromise;\n /** A Cancel beside Save — a dialog's way out. */\n onCancel?: () => void;\n /**\n * The languages offered: kit codes (named by the kit's registry, each in its own\n * language — \"Deutsch\", \"Français\") or the app's own `{ value, label }` rows. Default:\n * all seven of the kit's.\n */\n languages?: readonly KitLanguageCode[] | readonly ReviewerScopeLanguage[];\n /** The areas the scope can be narrowed to. Default: `legal` alone. `[]` for none. */\n areas?: readonly ReviewerScopeArea[];\n /** Why the scope cannot be changed for this account (\"Administrators review every\n * language already\"). Every box says it; there is no Save. */\n disabledReason?: ReactNode;\n /** The app's words for a failed save. */\n describeError?: (error: unknown) => ReactNode | undefined;\n /** Over the languages: what the role is, in the app's words. */\n intro?: ReactNode;\n /** Columns for the languages from `sm` up. Default 2 (Kurvenschmiede's dialog). */\n columns?: 1 | 2 | 3 | 4;\n /** Save COMMITS: under a locked `WriteLockProvider` it is held with the lock's reason. */\n commit?: boolean;\n labels?: Partial<ReviewerScopeLabels>;\n}\n\nfunction languageOptions(languages: ReviewerScopeEditorProps[\"languages\"]): CheckboxGroupOption[] {\n const rows = languages ?? KIT_LANGUAGES.map((language) => language.code);\n return rows.map((row) => {\n if (typeof row !== \"string\") return { value: row.value, label: row.label };\n const language = KIT_LANGUAGES.find((entry) => entry.code === row);\n return {\n value: row,\n // Each name in its own language, marked so a screen reader says it so.\n label: language ? <span lang={language.formatLocale}>{language.nativeName}</span> : row,\n };\n });\n}\n\n/** The same set, regardless of order. */\nfunction sameSet(a: readonly string[], b: readonly string[]): boolean {\n if (a.length !== b.length) return false;\n const seen = new Set(a);\n return b.every((x) => seen.has(x));\n}\n\nexport function ReviewerScopeEditor({\n value,\n onSave,\n onCancel,\n languages,\n areas: areasProp,\n disabledReason,\n describeError,\n intro,\n columns = 2,\n commit,\n labels: labelsProp,\n}: ReviewerScopeEditorProps) {\n const labels = useKitLabels(\"reviewerScope\", DEFAULT_REVIEWER_SCOPE_LABELS, labelsProp);\n const areaOptions: readonly ReviewerScopeArea[] =\n areasProp ?? [{ value: \"legal\", label: labels.legalOnly, hint: labels.legalOnlyHint }];\n const savedLocales = [...(value.locales ?? [])];\n const savedAreas = [...(value.areas ?? [])];\n const [locales, setLocales] = useState<string[]>(savedLocales);\n const [areas, setAreas] = useState<string[]>(savedAreas);\n const [pending, setPending] = useState(false);\n const [failure, setFailure] = useState<ReactNode>(null);\n const locked = hasMessage(disabledReason);\n\n const nextAreas = locales.length === 0 ? [] : areas;\n const dirty = !sameSet(locales, savedLocales) || !sameSet(nextAreas, locales.length === 0 ? [] : savedAreas);\n\n const save = () => {\n if (pending || locked || !dirty) return;\n const scope: ReviewerScope = {\n locales,\n areas: locales.length > 0 && areas.length > 0 ? areas : null,\n };\n setFailure(null);\n let result: MaybePromise;\n try {\n result = onSave(scope);\n } catch (error) {\n setFailure(describeError?.(error) ?? labels.failed);\n return;\n }\n if (!result || typeof result.then !== \"function\") return;\n setPending(true);\n result.then(\n () => setPending(false),\n (error: unknown) => {\n setPending(false);\n const own = describeError?.(error);\n setFailure(hasMessage(own) ? own : labels.failed);\n },\n );\n };\n\n return (\n <div className=\"space-y-3\">\n {intro && <div className=\"text-sm text-[var(--text-secondary)]\">{intro}</div>}\n <CheckboxGroup\n legend={labels.languages}\n options={languageOptions(languages)}\n value={locales}\n onChange={(next) => {\n setFailure(null);\n setLocales(next);\n }}\n columns={columns}\n hint={locked ? undefined : locales.length === 0 ? labels.none : labels.hint}\n disabledReason={disabledReason}\n />\n {areaOptions.length > 0 && (\n <CheckboxGroup\n legend={labels.areas}\n options={areaOptions.map((area) => ({ value: area.value, label: area.label, hint: area.hint }))}\n value={nextAreas}\n onChange={(next) => {\n setFailure(null);\n setAreas(next);\n }}\n // An area narrows a language scope; with no language there is none to narrow.\n disabled={locales.length === 0}\n disabledReason={disabledReason}\n />\n )}\n {failure && (\n <AlertBanner tone=\"danger\" size=\"sm\">\n {failure}\n </AlertBanner>\n )}\n {locked ? (\n <Caption>{disabledReason}</Caption>\n ) : (\n <FormActions\n onSubmit={save}\n onCancel={onCancel}\n pending={pending}\n submitDisabled={!dirty}\n commit={commit}\n />\n )}\n </div>\n );\n}\n"],"mappings":";AAyHwB,cAkEpB,YAlEoB;AAzHxB,SAAS,gBAAgB;AAEzB,SAAS,oBAAoB;AAC7B,SAAS,qBAAqB;AAE9B,SAAS,mBAAmB;AAC5B,SAAS,qBAAqB;AAE9B,SAAS,mBAAmB;AAC5B,SAAS,eAAe;AACxB,SAAS,kBAAkB;AA8DpB,MAAM,gCAAqD;AAAA,EAChE,WAAW;AAAA,EACX,MAAM;AAAA,EACN,MAAM;AAAA,EACN,OAAO;AAAA,EACP,WAAW;AAAA,EACX,eAAe;AAAA,EACf,QAAQ;AACV;AAiCA,SAAS,gBAAgB,WAAyE;AAChG,QAAM,OAAO,aAAa,cAAc,IAAI,CAAC,aAAa,SAAS,IAAI;AACvE,SAAO,KAAK,IAAI,CAAC,QAAQ;AACvB,QAAI,OAAO,QAAQ,SAAU,QAAO,EAAE,OAAO,IAAI,OAAO,OAAO,IAAI,MAAM;AACzE,UAAM,WAAW,cAAc,KAAK,CAAC,UAAU,MAAM,SAAS,GAAG;AACjE,WAAO;AAAA,MACL,OAAO;AAAA;AAAA,MAEP,OAAO,WAAW,oBAAC,UAAK,MAAM,SAAS,cAAe,mBAAS,YAAW,IAAU;AAAA,IACtF;AAAA,EACF,CAAC;AACH;AAGA,SAAS,QAAQ,GAAsB,GAA+B;AACpE,MAAI,EAAE,WAAW,EAAE,OAAQ,QAAO;AAClC,QA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1
|
+
import 'react';
|
|
2
|
+
import '../components/account-chips.js';
|
|
3
|
+
export { cD as DEFAULT_ROLE_SELECT_LABELS, eu as RoleLock, ev as RoleLockCode, ew as RoleSelect, ex as RoleSelectLabels, ey as RoleSelectProps, ez as RolesEditor, eA as RolesEditorProps } from '../delete-account-setting-DCFS5Vof.js';
|
|
4
|
+
import 'lucide-react';
|
|
5
|
+
import '../lib/format.js';
|
|
6
|
+
import '../components/chip.js';
|
|
7
|
+
import '../data-table-labels-DUELeXpa.js';
|
|
8
|
+
import '../components/data-table-sort.js';
|
|
9
|
+
import '../components/swipeable-row.js';
|
|
10
|
+
import '../components/tooltip.js';
|
|
11
|
+
import '../hooks/use-anchored-rect.js';
|
|
12
|
+
import '../lib/clipping.js';
|
|
13
|
+
import '../components/mini-calendar.js';
|
|
14
|
+
import '../components/calendar-heatmap.js';
|
|
15
|
+
import '../components/popover.js';
|
|
16
|
+
import '../components/field-sync.js';
|
|
17
|
+
import '../wizard/types.js';
|
|
18
|
+
import '../tour/tour.js';
|
|
19
|
+
import '../search/command-palette.js';
|
|
20
|
+
import '../search/global-search.js';
|
|
21
|
+
import '../search/search-index.js';
|
|
22
|
+
import '../components/month-picker.js';
|
|
23
|
+
import '../components/page-contents.js';
|
|
24
|
+
import '../components/series-chart-labels.js';
|
|
25
|
+
import '../components/pie-chart-labels.js';
|
|
26
|
+
import '../components/sparkline.js';
|
|
27
|
+
import '../components/stat-tile.js';
|
|
28
|
+
import '../components/signature-pad.js';
|
|
29
|
+
import '../components/password-strength.js';
|
|
30
|
+
import '../components/swatch-picker.js';
|
|
31
|
+
import '../components/tile-radio.js';
|
|
32
|
+
import '../components/icon-picker.js';
|
|
33
|
+
import '../components/dialog-frame.js';
|
|
34
|
+
import '../components/modal.js';
|
|
35
|
+
import '../hooks/use-search-param-state.js';
|
|
36
|
+
import '../components/measured-grid.js';
|
|
37
|
+
import '../components/user-avatar.js';
|
|
38
|
+
import '../lib/person-name.js';
|
|
39
|
+
import '../components/status-dot.js';
|
|
40
|
+
import '../components/progress-bar.js';
|
|
41
|
+
import '../components/signed-amount.js';
|
|
42
|
+
import '../shell/topbar-action-menu.js';
|
|
43
|
+
import '../components/menu-item.js';
|
|
44
|
+
import '../components/floating-panel.js';
|
|
45
|
+
import '../hooks/use-authed-src.js';
|
|
46
|
+
import '../components/account-settings-labels.js';
|
|
47
|
+
import '../components/bulk-action-bar.js';
|
|
48
|
+
import '../components/list.js';
|
|
49
|
+
import '../components/breadcrumbs.js';
|
|
50
|
+
import '../components/toast.js';
|
|
51
|
+
import '../components/description-list.js';
|
|
52
|
+
import '../components/line-items.js';
|
|
53
|
+
import '../components/error-boundary.js';
|
|
54
|
+
import '../components/authed-image.js';
|
|
55
|
+
import '../components/image-grid.js';
|
|
56
|
+
import '../components/lightbox.js';
|
|
57
|
+
import '../components/write-lock.js';
|
|
58
|
+
import '../auth/sign-in-form.js';
|
|
59
|
+
import '../landing/access.js';
|
|
60
|
+
import '../landing/landing-labels.js';
|
|
61
|
+
import '../shell/topbar-controls.js';
|
|
62
|
+
import '../theme/palette-presets.js';
|
|
63
|
+
import '../theme/chart-palette.js';
|
|
64
|
+
import '../theme/theme-store.js';
|
|
65
|
+
import 'zustand/middleware';
|
|
66
|
+
import 'zustand';
|
|
67
|
+
import '../auth/complete-name-dialog.js';
|
|
68
|
+
import '../auth/forgot-password-form.js';
|
|
69
|
+
import '../auth/status-parts.js';
|
|
70
|
+
import '../auth/reset-password-form.js';
|
|
71
|
+
import '../auth/verify-email.js';
|
|
72
|
+
import '../auth/not-found-page.js';
|
|
73
|
+
import '../auth/accept-invitation.js';
|
|
74
|
+
import '../shell/company-switcher.js';
|
|
75
|
+
import '../account/email-change-setting.js';
|
|
76
|
+
import '../account/sessions-setting.js';
|
|
77
|
+
import '../account/data-export-setting.js';
|
|
78
|
+
import './admin-parts.js';
|
|
79
|
+
import './admin-action-log.js';
|
|
80
|
+
import '../settings/settings-labels.js';
|
|
81
|
+
import '../demo/demo-labels.js';
|
|
82
|
+
import '../components/reauth-dialog.js';
|
|
83
|
+
import '../components/server-wake.js';
|
|
84
|
+
import '../lib/server-wake.js';
|
|
85
|
+
import '../components/translation-review-labels.js';
|
|
86
|
+
import '../lib/translation-review.js';
|
|
87
|
+
import '../components/country-select.js';
|
|
88
|
+
import '../components/inline-edit-field.js';
|
|
89
|
+
import '../lib/iban.js';
|
|
90
|
+
import '../lib/phone.js';
|
|
91
|
+
import '../components/sign-chip.js';
|
|
92
|
+
import '../components/column-mapper.js';
|
|
93
|
+
import '../lib/column-mapping.js';
|
|
94
|
+
import '../lib/table-text.js';
|
|
95
|
+
import '../components/field-parts.js';
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { useKitLabels } from "../i18n/kit-labels.js";
|
|
4
|
+
import { CheckboxGroup } from "../components/checkbox-group.js";
|
|
5
|
+
import { Select } from "../components/ui.js";
|
|
6
|
+
const DEFAULT_ROLE_SELECT_LABELS = {
|
|
7
|
+
label: "Role",
|
|
8
|
+
rolesLegend: "Roles",
|
|
9
|
+
roleOf: (name) => `Role of ${name}`,
|
|
10
|
+
lockedLastAdmin: "The last active administrator keeps this role.",
|
|
11
|
+
lockedSelf: "You can\u2019t change your own role.",
|
|
12
|
+
notForLastAdmin: "not for the last administrator",
|
|
13
|
+
notForSelf: "not for your own account",
|
|
14
|
+
unavailable: (role, reason) => `${role} (${reason})`
|
|
15
|
+
};
|
|
16
|
+
function lockText(reason, labels) {
|
|
17
|
+
if (reason === "last_admin") return labels.lockedLastAdmin;
|
|
18
|
+
if (reason === "self" || reason === "self_action") return labels.lockedSelf;
|
|
19
|
+
return reason;
|
|
20
|
+
}
|
|
21
|
+
function optionReasonText(reason, labels) {
|
|
22
|
+
if (reason === "last_admin") return labels.notForLastAdmin;
|
|
23
|
+
if (reason === "self" || reason === "self_action") return labels.notForSelf;
|
|
24
|
+
return reason;
|
|
25
|
+
}
|
|
26
|
+
function present(node) {
|
|
27
|
+
return node !== void 0 && node !== null && node !== false && node !== "";
|
|
28
|
+
}
|
|
29
|
+
function keysOf(roles) {
|
|
30
|
+
return Object.keys(roles);
|
|
31
|
+
}
|
|
32
|
+
function RoleSelect({
|
|
33
|
+
value,
|
|
34
|
+
roles,
|
|
35
|
+
onChange,
|
|
36
|
+
offered,
|
|
37
|
+
disabledReason,
|
|
38
|
+
optionDisabledReason,
|
|
39
|
+
name,
|
|
40
|
+
labels: labelsProp,
|
|
41
|
+
label,
|
|
42
|
+
...rest
|
|
43
|
+
}) {
|
|
44
|
+
const labels = useKitLabels("roleSelect", DEFAULT_ROLE_SELECT_LABELS, labelsProp);
|
|
45
|
+
const all = keysOf(roles);
|
|
46
|
+
const choosable = new Set(offered ?? all);
|
|
47
|
+
const held = value ?? null;
|
|
48
|
+
const ariaLabel = label === void 0 ? rest["aria-label"] ?? (name ? labels.roleOf(name) : labels.label) : rest["aria-label"];
|
|
49
|
+
return /* @__PURE__ */ jsxs(
|
|
50
|
+
Select,
|
|
51
|
+
{
|
|
52
|
+
...rest,
|
|
53
|
+
label,
|
|
54
|
+
"aria-label": ariaLabel,
|
|
55
|
+
value: held ?? "",
|
|
56
|
+
disabledReason: present(disabledReason) ? lockText(disabledReason, labels) : void 0,
|
|
57
|
+
onChange: (event) => {
|
|
58
|
+
const next = event.target.value;
|
|
59
|
+
if (next && next !== held) onChange(next);
|
|
60
|
+
},
|
|
61
|
+
children: [
|
|
62
|
+
held === null && /* @__PURE__ */ jsx("option", { value: "", disabled: true }),
|
|
63
|
+
all.filter((role) => choosable.has(role) || role === held).map((role) => {
|
|
64
|
+
const word = roles[role].label;
|
|
65
|
+
const reason = role === held ? void 0 : optionDisabledReason?.(role);
|
|
66
|
+
const unavailable = !choosable.has(role) || present(reason);
|
|
67
|
+
return /* @__PURE__ */ jsx("option", { value: role, disabled: unavailable && role !== held, children: reason ? labels.unavailable(word, optionReasonText(reason, labels)) : word }, role);
|
|
68
|
+
}),
|
|
69
|
+
held !== null && !all.includes(held) && /* @__PURE__ */ jsx("option", { value: held, disabled: true, children: held })
|
|
70
|
+
]
|
|
71
|
+
}
|
|
72
|
+
);
|
|
73
|
+
}
|
|
74
|
+
function RolesEditor({
|
|
75
|
+
value,
|
|
76
|
+
roles,
|
|
77
|
+
onChange,
|
|
78
|
+
offered,
|
|
79
|
+
disabledReason,
|
|
80
|
+
optionDisabledReason,
|
|
81
|
+
legend,
|
|
82
|
+
legendVisibility,
|
|
83
|
+
required,
|
|
84
|
+
hint,
|
|
85
|
+
error,
|
|
86
|
+
columns,
|
|
87
|
+
commit,
|
|
88
|
+
className,
|
|
89
|
+
labels: labelsProp
|
|
90
|
+
}) {
|
|
91
|
+
const labels = useKitLabels("roleSelect", DEFAULT_ROLE_SELECT_LABELS, labelsProp);
|
|
92
|
+
const all = keysOf(roles);
|
|
93
|
+
const choosable = new Set(offered ?? all);
|
|
94
|
+
const held = new Set(value);
|
|
95
|
+
const options = all.filter((role) => choosable.has(role) || held.has(role)).map((role) => {
|
|
96
|
+
const reason = optionDisabledReason?.(role);
|
|
97
|
+
const locked = present(reason);
|
|
98
|
+
return {
|
|
99
|
+
value: role,
|
|
100
|
+
label: roles[role].label,
|
|
101
|
+
hint: locked ? lockText(reason, labels) : void 0,
|
|
102
|
+
disabled: locked || !choosable.has(role)
|
|
103
|
+
};
|
|
104
|
+
});
|
|
105
|
+
return /* @__PURE__ */ jsx(
|
|
106
|
+
CheckboxGroup,
|
|
107
|
+
{
|
|
108
|
+
legend: legend ?? labels.rolesLegend,
|
|
109
|
+
legendVisibility,
|
|
110
|
+
options,
|
|
111
|
+
value: [...value],
|
|
112
|
+
onChange,
|
|
113
|
+
required,
|
|
114
|
+
hint,
|
|
115
|
+
error,
|
|
116
|
+
columns,
|
|
117
|
+
commit,
|
|
118
|
+
disabledReason: present(disabledReason) ? lockText(disabledReason, labels) : void 0,
|
|
119
|
+
className
|
|
120
|
+
}
|
|
121
|
+
);
|
|
122
|
+
}
|
|
123
|
+
export {
|
|
124
|
+
DEFAULT_ROLE_SELECT_LABELS,
|
|
125
|
+
RoleSelect,
|
|
126
|
+
RolesEditor
|
|
127
|
+
};
|
|
128
|
+
//# sourceMappingURL=role-select.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/admin/role-select.tsx"],"sourcesContent":["import type { ReactNode } from \"react\";\nimport { useKitLabels } from \"../i18n/kit-labels\";\nimport type { RoleVocabulary } from \"../components/account-chips\";\nimport { CheckboxGroup } from \"../components/checkbox-group\";\nimport type { CheckboxGroupOption } from \"../components/checkbox-group\";\nimport { Select } from \"../components/ui\";\nimport type { SelectProps } from \"../components/ui\";\n\n/**\n * The role of an account, chosen by an admin (docs/user-admin-harmonization.md §3.3,\n * §4.1, §7): {@link RoleSelect} for the apps where an account has ONE role (keksdose,\n * Kurvenschmiede) and {@link RolesEditor} for kastlan, where an account has several per\n * company.\n *\n * Both take the app's {@link RoleVocabulary} — the one `RoleChip` reads — so a role is\n * called the same in the chip, the select and the editor. Neither sends a request: a role\n * change is an `acknowledge` action (§4.2), so the app opens `AdminActionConfirm` from\n * `onChange` and the value stays where the server has it until the server says otherwise.\n *\n * WHY THE REASONS. The server refuses the last active admin's demotion (`last_admin`),\n * your own admin role (`self`), Kurvenschmiede's CUSTOMER for an account that owns work,\n * kastlan's TENANT until a tenant portal exists (§4.1, §9.6). A choice the server will\n * refuse is shown as unavailable, with why, rather than offered and answered with an\n * error after a confirmation dialog — the 0.18 write-lock rule: a control that cannot\n * act says so where it is. `\"last_admin\"` and `\"self\"` are the kit's words in every\n * language; anything else is the app's own sentence.\n */\n\n/** A reason the kit words itself. `self_action` is the server's code for `self` (the\n * account error codes), so a refusal's code can be handed on as it came. */\nexport type RoleLockCode = \"last_admin\" | \"self\" | \"self_action\";\n\n/**\n * Why a role (or the whole control) cannot be changed: one of the kit's\n * {@link RoleLockCode}s, or the app's own words.\n */\nexport type RoleLock = RoleLockCode | (string & {}) | ReactNode;\n\n/** The `roleSelect` namespace — RoleSelect's and RolesEditor's words. */\nexport interface RoleSelectLabels {\n /** The select's name where no `label` is drawn, and RolesEditor's legend. \"Role\". */\n label: string;\n /** RolesEditor's legend. \"Roles\". */\n rolesLegend: string;\n /** The select's accessible name in a roster row — \"Role of Ada Example\". */\n roleOf: (name: string) => string;\n /** The whole control is locked: the account is the last active administrator. */\n lockedLastAdmin: string;\n /** The whole control is locked: it is the admin's own account. */\n lockedSelf: string;\n /** One option is unavailable for the last active administrator — said after the\n * role's name, inside the option. */\n notForLastAdmin: string;\n /** One option is unavailable on the admin's own account. */\n notForSelf: string;\n /** An unavailable option's text: the role's name and why. */\n unavailable: (role: string, reason: string) => string;\n}\n\nexport const DEFAULT_ROLE_SELECT_LABELS: RoleSelectLabels = {\n label: \"Role\",\n rolesLegend: \"Roles\",\n roleOf: (name) => `Role of ${name}`,\n lockedLastAdmin: \"The last active administrator keeps this role.\",\n lockedSelf: \"You can’t change your own role.\",\n notForLastAdmin: \"not for the last administrator\",\n notForSelf: \"not for your own account\",\n unavailable: (role, reason) => `${role} (${reason})`,\n};\n\n/** The whole-control reason, the kit's codes in the kit's words. */\nfunction lockText(reason: RoleLock, labels: RoleSelectLabels): ReactNode {\n if (reason === \"last_admin\") return labels.lockedLastAdmin;\n if (reason === \"self\" || reason === \"self_action\") return labels.lockedSelf;\n return reason;\n}\n\n/** An option's reason as the text a native `<option>` can hold. */\nfunction optionReasonText(reason: string, labels: RoleSelectLabels): string {\n if (reason === \"last_admin\") return labels.notForLastAdmin;\n if (reason === \"self\" || reason === \"self_action\") return labels.notForSelf;\n return reason;\n}\n\nfunction present(node: ReactNode): boolean {\n return node !== undefined && node !== null && node !== false && node !== \"\";\n}\n\n/** The vocabulary's keys, in its own order. */\nfunction keysOf<R extends string>(roles: RoleVocabulary<R>): R[] {\n return Object.keys(roles) as R[];\n}\n\n/* ── RoleSelect ─────────────────────────────────────────────────────────────── */\n\nexport interface RoleSelectProps<R extends string = string>\n extends Omit<SelectProps, \"value\" | \"defaultValue\" | \"onChange\" | \"children\" | \"multiple\" | \"disabledReason\"> {\n /** The role the server has. Controlled: a pick does not move the select until the\n * app's request lands and the row comes back with the new role. */\n value: R | null | undefined;\n /** The app's roles — what `RoleChip` reads. Their order is the list's. */\n roles: RoleVocabulary<R>;\n /** A role other than `value` was picked. The app asks `AdminActionConfirm` (an\n * `acknowledge` action, §4.2) and sends the change. */\n onChange: (role: R) => void;\n /**\n * The roles that may be CHOSEN here, in the vocabulary's order whatever order this is\n * in. Default: all of them. A role the account holds that is not offered (Kurvenschmiede's\n * REVIEWER, given only through the reviewer scope, §9.6) is still shown, unavailable:\n * a select that dropped it would show the account as something it is not.\n */\n offered?: readonly R[];\n /**\n * Why the whole choice is locked for this account: `\"last_admin\"`, `\"self\"`, or the\n * app's own words. The select stays focusable and says so (Select's `disabledReason`).\n */\n disabledReason?: RoleLock;\n /**\n * Why ONE role cannot be chosen for this account: `\"last_admin\"`, `\"self\"`, or the\n * app's own words (Kurvenschmiede: \"owns work\", for CUSTOMER) — a STRING, because a\n * native option holds text only. The option is disabled and reads \"Member (not for the\n * last administrator)\". `undefined` for an available role.\n */\n optionDisabledReason?: (role: R) => string | undefined;\n /** The account's name, for the select's accessible name in a roster row (\"Role of\n * Ada Example\") where no `label` is drawn. */\n name?: string;\n labels?: Partial<RoleSelectLabels>;\n}\n\n/**\n * One role, picked from the app's vocabulary — Kurvenschmiede's roster `Select`\n * (users-panel.tsx), with the reasons it left to the server's toast drawn in place.\n *\n * Unlabelled by default, for a table cell: named \"Role of Ada Example\" (`name`) or\n * \"Role\". Pass `label` for a form field. Every {@link Select} prop passes through\n * (`size`, `commit`, `hint`, `error`, `data-*`).\n */\nexport function RoleSelect<R extends string = string>({\n value,\n roles,\n onChange,\n offered,\n disabledReason,\n optionDisabledReason,\n name,\n labels: labelsProp,\n label,\n ...rest\n}: RoleSelectProps<R>) {\n const labels = useKitLabels(\"roleSelect\", DEFAULT_ROLE_SELECT_LABELS, labelsProp);\n const all = keysOf(roles);\n const choosable = new Set<R>(offered ?? all);\n const held = value ?? null;\n // A cell has no room for a visible label: the select is named for the account it\n // belongs to, so fifty of them in a roster are not fifty \"Role\"s.\n const ariaLabel =\n label === undefined ? (rest[\"aria-label\"] ?? (name ? labels.roleOf(name) : labels.label)) : rest[\"aria-label\"];\n return (\n <Select\n {...rest}\n label={label}\n aria-label={ariaLabel}\n value={held ?? \"\"}\n disabledReason={present(disabledReason) ? lockText(disabledReason, labels) : undefined}\n onChange={(event) => {\n const next = event.target.value as R;\n if (next && next !== held) onChange(next);\n }}\n >\n {held === null && <option value=\"\" disabled />}\n {all\n .filter((role) => choosable.has(role) || role === held)\n .map((role) => {\n const word = roles[role].label;\n const reason = role === held ? undefined : optionDisabledReason?.(role);\n const unavailable = !choosable.has(role) || present(reason);\n return (\n <option key={role} value={role} disabled={unavailable && role !== held}>\n {reason ? labels.unavailable(word, optionReasonText(reason, labels)) : word}\n </option>\n );\n })}\n {/* A role the vocabulary does not know (an older client against a newer API) is\n still the account's role: shown as its key, as RoleChip shows it. */}\n {held !== null && !all.includes(held) && (\n <option value={held} disabled>\n {held}\n </option>\n )}\n </Select>\n );\n}\n\n/* ── RolesEditor ────────────────────────────────────────────────────────────── */\n\nexport interface RolesEditorProps<R extends string = string> {\n /** The roles ticked — the draft the app holds while its dialog is open. */\n value: readonly R[];\n roles: RoleVocabulary<R>;\n /** The new set, in the vocabulary's order (a role the editor does not offer, but the\n * account holds, is kept after the rest — CheckboxGroup's rule). */\n onChange: (roles: R[]) => void;\n /** The roles that may be ticked or unticked here. Default: all. kastlan leaves TENANT\n * out until a tenant portal exists (§4.1). */\n offered?: readonly R[];\n /** Why nothing can be changed: `\"last_admin\"`, `\"self\"` or the app's words. */\n disabledReason?: RoleLock;\n /** Why one role cannot be changed — shown under it, and the box keeps its state:\n * `\"last_admin\"` on the last administrator's ADMIN, say. */\n optionDisabledReason?: (role: R) => RoleLock | undefined;\n /** Default `roleSelect.rolesLegend` — \"Roles\". kastlan names the company: \"Roles in\n * Example Ltd\". */\n legend?: ReactNode;\n legendVisibility?: \"visible\" | \"sr-only\";\n /** At least one role (kastlan's dialog saves none). Draws the required star. */\n required?: boolean;\n hint?: ReactNode;\n error?: ReactNode;\n columns?: 1 | 2 | 3 | 4;\n /** The editor SAVES on change — the write lock's opt-in (CheckboxGroup's `commit`). */\n commit?: boolean;\n className?: string;\n labels?: Partial<RoleSelectLabels>;\n}\n\n/**\n * Several roles at once — kastlan's manage-roles dialog (`ChoiceCardGroup multiple`),\n * which holds an account's roles in the CURRENT company (§4.1: `PUT /admin/users/{id}/roles`).\n * A kit {@link CheckboxGroup} of the vocabulary, with the reasons of {@link RoleSelect}:\n * a role that cannot change keeps its box as it is and says why under it.\n *\n * A field, not a form: the app's dialog holds the draft, and its Save goes through\n * `AdminActionConfirm` (`acknowledge`, §4.2) — which can draw this editor as its\n * `children`, so the roles and the tick are one dialog.\n */\nexport function RolesEditor<R extends string = string>({\n value,\n roles,\n onChange,\n offered,\n disabledReason,\n optionDisabledReason,\n legend,\n legendVisibility,\n required,\n hint,\n error,\n columns,\n commit,\n className,\n labels: labelsProp,\n}: RolesEditorProps<R>) {\n const labels = useKitLabels(\"roleSelect\", DEFAULT_ROLE_SELECT_LABELS, labelsProp);\n const all = keysOf(roles);\n const choosable = new Set<R>(offered ?? all);\n const held = new Set<R>(value);\n const options: CheckboxGroupOption<R>[] = all\n .filter((role) => choosable.has(role) || held.has(role))\n .map((role) => {\n const reason = optionDisabledReason?.(role);\n const locked = present(reason);\n return {\n value: role,\n label: roles[role].label,\n hint: locked ? lockText(reason, labels) : undefined,\n disabled: locked || !choosable.has(role),\n };\n });\n return (\n <CheckboxGroup<R>\n legend={legend ?? labels.rolesLegend}\n legendVisibility={legendVisibility}\n options={options}\n value={[...value]}\n onChange={onChange}\n required={required}\n hint={hint}\n error={error}\n columns={columns}\n commit={commit}\n disabledReason={present(disabledReason) ? lockText(disabledReason, labels) : undefined}\n className={className}\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AC,SAAS,UAAU,IAAI,IAAI,KAAK,KAAK,IAAI,IAAI,CAAC,EACtD,IAAI,CAAC,SAAS;AACb,UAAM,SAAS,uBAAuB,IAAI;AAC1C,UAAM,SAAS,QAAQ,MAAM;AAC7B,WAAO;AAAA,MACL,OAAO;AAAA,MACP,OAAO,MAAM,IAAI,EAAE;AAAA,MACnB,MAAM,SAAS,SAAS,QAAQ,MAAM,IAAI;AAAA,MAC1C,UAAU,UAAU,CAAC,UAAU,IAAI,IAAI;AAAA,IACzC;AAAA,EACF,CAAC;AACH,SACE;AAAA,IAAC;AAAA;AAAA,MACC,QAAQ,UAAU,OAAO;AAAA,MACzB;AAAA,MACA;AAAA,MACA,OAAO,CAAC,GAAG,KAAK;AAAA,MAChB;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,gBAAgB,QAAQ,cAAc,IAAI,SAAS,gBAAgB,MAAM,IAAI;AAAA,MAC7E;AAAA;AAAA,EACF;AAEJ;","names":[]}
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import 'react';
|
|
2
|
+
export { cI as DEFAULT_TRANSFER_OWNERSHIP_LABELS, e_ as TransferCandidate, e$ as TransferOwnershipDialog, f0 as TransferOwnershipDialogProps, f1 as TransferOwnershipLabels, f2 as TransferUnavailable, f3 as TransferValues } from '../delete-account-setting-DCFS5Vof.js';
|
|
3
|
+
import './admin-parts.js';
|
|
4
|
+
import '../components/tooltip.js';
|
|
5
|
+
import '../hooks/use-anchored-rect.js';
|
|
6
|
+
import '../lib/clipping.js';
|
|
7
|
+
import '../data-table-labels-DUELeXpa.js';
|
|
8
|
+
import '../components/data-table-sort.js';
|
|
9
|
+
import '../components/swipeable-row.js';
|
|
10
|
+
import '../components/mini-calendar.js';
|
|
11
|
+
import '../components/calendar-heatmap.js';
|
|
12
|
+
import '../components/popover.js';
|
|
13
|
+
import '../components/chip.js';
|
|
14
|
+
import 'lucide-react';
|
|
15
|
+
import '../components/field-sync.js';
|
|
16
|
+
import '../wizard/types.js';
|
|
17
|
+
import '../tour/tour.js';
|
|
18
|
+
import '../search/command-palette.js';
|
|
19
|
+
import '../search/global-search.js';
|
|
20
|
+
import '../search/search-index.js';
|
|
21
|
+
import '../components/month-picker.js';
|
|
22
|
+
import '../components/page-contents.js';
|
|
23
|
+
import '../components/series-chart-labels.js';
|
|
24
|
+
import '../components/pie-chart-labels.js';
|
|
25
|
+
import '../components/sparkline.js';
|
|
26
|
+
import '../components/stat-tile.js';
|
|
27
|
+
import '../components/signature-pad.js';
|
|
28
|
+
import '../components/password-strength.js';
|
|
29
|
+
import '../components/swatch-picker.js';
|
|
30
|
+
import '../components/tile-radio.js';
|
|
31
|
+
import '../components/icon-picker.js';
|
|
32
|
+
import '../components/dialog-frame.js';
|
|
33
|
+
import '../components/modal.js';
|
|
34
|
+
import '../hooks/use-search-param-state.js';
|
|
35
|
+
import '../components/measured-grid.js';
|
|
36
|
+
import '../components/user-avatar.js';
|
|
37
|
+
import '../lib/person-name.js';
|
|
38
|
+
import '../components/status-dot.js';
|
|
39
|
+
import '../components/progress-bar.js';
|
|
40
|
+
import '../components/signed-amount.js';
|
|
41
|
+
import '../shell/topbar-action-menu.js';
|
|
42
|
+
import '../components/menu-item.js';
|
|
43
|
+
import '../components/floating-panel.js';
|
|
44
|
+
import '../hooks/use-authed-src.js';
|
|
45
|
+
import '../components/account-settings-labels.js';
|
|
46
|
+
import '../components/bulk-action-bar.js';
|
|
47
|
+
import '../components/list.js';
|
|
48
|
+
import '../components/breadcrumbs.js';
|
|
49
|
+
import '../components/toast.js';
|
|
50
|
+
import '../components/description-list.js';
|
|
51
|
+
import '../components/line-items.js';
|
|
52
|
+
import '../components/error-boundary.js';
|
|
53
|
+
import '../components/authed-image.js';
|
|
54
|
+
import '../components/image-grid.js';
|
|
55
|
+
import '../components/lightbox.js';
|
|
56
|
+
import '../components/write-lock.js';
|
|
57
|
+
import '../auth/sign-in-form.js';
|
|
58
|
+
import '../landing/access.js';
|
|
59
|
+
import '../landing/landing-labels.js';
|
|
60
|
+
import '../shell/topbar-controls.js';
|
|
61
|
+
import '../theme/palette-presets.js';
|
|
62
|
+
import '../theme/chart-palette.js';
|
|
63
|
+
import '../theme/theme-store.js';
|
|
64
|
+
import 'zustand/middleware';
|
|
65
|
+
import 'zustand';
|
|
66
|
+
import '../auth/complete-name-dialog.js';
|
|
67
|
+
import '../auth/forgot-password-form.js';
|
|
68
|
+
import '../auth/status-parts.js';
|
|
69
|
+
import '../auth/reset-password-form.js';
|
|
70
|
+
import '../auth/verify-email.js';
|
|
71
|
+
import '../auth/not-found-page.js';
|
|
72
|
+
import '../auth/accept-invitation.js';
|
|
73
|
+
import '../shell/company-switcher.js';
|
|
74
|
+
import '../account/email-change-setting.js';
|
|
75
|
+
import '../account/sessions-setting.js';
|
|
76
|
+
import '../lib/format.js';
|
|
77
|
+
import '../account/data-export-setting.js';
|
|
78
|
+
import '../components/account-chips.js';
|
|
79
|
+
import './admin-action-log.js';
|
|
80
|
+
import '../settings/settings-labels.js';
|
|
81
|
+
import '../demo/demo-labels.js';
|
|
82
|
+
import '../components/reauth-dialog.js';
|
|
83
|
+
import '../components/server-wake.js';
|
|
84
|
+
import '../lib/server-wake.js';
|
|
85
|
+
import '../components/translation-review-labels.js';
|
|
86
|
+
import '../lib/translation-review.js';
|
|
87
|
+
import '../components/country-select.js';
|
|
88
|
+
import '../components/inline-edit-field.js';
|
|
89
|
+
import '../lib/iban.js';
|
|
90
|
+
import '../lib/phone.js';
|
|
91
|
+
import '../components/sign-chip.js';
|
|
92
|
+
import '../components/column-mapper.js';
|
|
93
|
+
import '../lib/column-mapping.js';
|
|
94
|
+
import '../lib/table-text.js';
|
|
95
|
+
import '../components/field-parts.js';
|