@eifi1/ui-kit 0.28.1 → 0.29.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 +21 -3
- package/dist/auth/accept-invitation.d.ts +90 -0
- package/dist/auth/accept-invitation.js +117 -0
- package/dist/auth/accept-invitation.js.map +1 -0
- package/dist/auth/auth-errors.d.ts +60 -0
- package/dist/auth/auth-errors.js +32 -0
- package/dist/auth/auth-errors.js.map +1 -0
- package/dist/auth/complete-name-dialog.d.ts +71 -0
- package/dist/auth/complete-name-dialog.js +168 -0
- package/dist/auth/complete-name-dialog.js.map +1 -0
- package/dist/auth/email-tag.d.ts +60 -0
- package/dist/auth/email-tag.js +23 -0
- package/dist/auth/email-tag.js.map +1 -0
- package/dist/auth/forgot-password-form.d.ts +79 -0
- package/dist/auth/forgot-password-form.js +120 -0
- package/dist/auth/forgot-password-form.js.map +1 -0
- package/dist/auth/form-rules.d.ts +27 -0
- package/dist/auth/form-rules.js +23 -0
- package/dist/auth/form-rules.js.map +1 -0
- package/dist/auth/new-password-fields.d.ts +38 -0
- package/dist/auth/new-password-fields.js +54 -0
- package/dist/auth/new-password-fields.js.map +1 -0
- package/dist/auth/not-found-page.d.ts +57 -0
- package/dist/auth/not-found-page.js +40 -0
- package/dist/auth/not-found-page.js.map +1 -0
- package/dist/auth/register-form.d.ts +86 -0
- package/dist/auth/register-form.js +268 -0
- package/dist/auth/register-form.js.map +1 -0
- package/dist/auth/reset-password-form.d.ts +124 -0
- package/dist/auth/reset-password-form.js +164 -0
- package/dist/auth/reset-password-form.js.map +1 -0
- package/dist/auth/sign-in-form.d.ts +243 -0
- package/dist/auth/sign-in-form.js +345 -0
- package/dist/auth/sign-in-form.js.map +1 -0
- package/dist/auth/status-parts.d.ts +78 -0
- package/dist/auth/status-parts.js +83 -0
- package/dist/auth/status-parts.js.map +1 -0
- package/dist/auth/verify-email.d.ts +121 -0
- package/dist/auth/verify-email.js +207 -0
- package/dist/auth/verify-email.js.map +1 -0
- package/dist/chart.d.ts +17 -2
- package/dist/components/amount-input.d.ts +18 -2
- package/dist/components/button-group.d.ts +18 -2
- package/dist/components/calculator.d.ts +18 -2
- package/dist/components/confirm-dialog.d.ts +18 -2
- package/dist/components/copy-button.d.ts +18 -2
- package/dist/components/danger-confirm.d.ts +18 -2
- package/dist/components/facing-pair.d.ts +18 -2
- package/dist/components/file-button.d.ts +18 -2
- package/dist/components/file-dropzone.d.ts +18 -2
- package/dist/components/form-actions.d.ts +18 -2
- package/dist/components/iban-input.d.ts +18 -2
- package/dist/components/language-select.d.ts +18 -9
- package/dist/components/legal-page.d.ts +18 -2
- package/dist/components/legal.d.ts +18 -2
- package/dist/components/money-field.d.ts +18 -2
- package/dist/components/number-field.d.ts +18 -2
- package/dist/components/number-input.d.ts +18 -2
- package/dist/components/numpad-sheet.d.ts +18 -2
- package/dist/components/phone-input.d.ts +18 -2
- package/dist/components/series-chart.d.ts +18 -2
- package/dist/components/settings-fields.d.ts +15 -2
- package/dist/components/share-card.d.ts +18 -2
- package/dist/components/text-link.d.ts +18 -2
- package/dist/components/time-input.d.ts +18 -2
- package/dist/components/ui.d.ts +17 -1
- package/dist/components/user-avatar.d.ts +16 -2
- package/dist/components/user-avatar.js +7 -3
- package/dist/components/user-avatar.js.map +1 -1
- package/dist/feedback/feedback-attachment.d.ts +18 -2
- package/dist/feedback/feedback-context.d.ts +18 -2
- package/dist/feedback/feedback-crash.d.ts +18 -2
- package/dist/feedback/feedback-dialog.d.ts +18 -2
- package/dist/feedback/feedback-inbox.d.ts +18 -2
- package/dist/feedback/feedback-labels.d.ts +18 -2
- package/dist/feedback/feedback-menu.d.ts +18 -2
- package/dist/feedback/feedback-record.d.ts +18 -2
- package/dist/feedback/feedback-row-detail.d.ts +18 -2
- package/dist/feedback/feedback-status-undo.d.ts +18 -2
- package/dist/feedback/feedback-submit.d.ts +18 -2
- package/dist/feedback/feedback-swipe.d.ts +18 -2
- package/dist/feedback/feedback-table.d.ts +18 -2
- package/dist/feedback/feedback-thread.d.ts +18 -2
- package/dist/feedback.d.ts +18 -2
- package/dist/hooks/use-file-drop.d.ts +18 -2
- package/dist/i18n/defaults.d.ts +18 -2
- package/dist/i18n/defaults.js +18 -0
- package/dist/i18n/defaults.js.map +1 -1
- package/dist/i18n/german.d.ts +18 -2
- package/dist/i18n/german.js +137 -0
- package/dist/i18n/german.js.map +1 -1
- package/dist/i18n/kit-labels.d.ts +18 -2
- package/dist/i18n/kit-labels.js.map +1 -1
- package/dist/i18n/languages.d.ts +13 -201
- package/dist/i18n/locales/de-CH.d.ts +18 -2
- package/dist/i18n/locales/en.d.ts +18 -2
- package/dist/i18n/locales/es.d.ts +18 -2
- package/dist/i18n/locales/es.js +137 -1
- package/dist/i18n/locales/es.js.map +1 -1
- package/dist/i18n/locales/fr.d.ts +18 -2
- package/dist/i18n/locales/fr.js +139 -0
- package/dist/i18n/locales/fr.js.map +1 -1
- package/dist/i18n/locales/hu.d.ts +18 -2
- package/dist/i18n/locales/hu.js +139 -1
- package/dist/i18n/locales/hu.js.map +1 -1
- package/dist/i18n/locales/it.d.ts +18 -2
- package/dist/i18n/locales/it.js +137 -0
- package/dist/i18n/locales/it.js.map +1 -1
- package/dist/i18n/locales/zh.d.ts +18 -2
- package/dist/i18n/locales/zh.js +137 -0
- package/dist/i18n/locales/zh.js.map +1 -1
- package/dist/i18n/review.d.ts +18 -2
- package/dist/i18n/review.js +9 -1
- package/dist/i18n/review.js.map +1 -1
- package/dist/index.d.ts +13 -2
- package/dist/index.js +36 -0
- package/dist/index.js.map +1 -1
- package/dist/lib/person-name.d.ts +69 -0
- package/dist/lib/person-name.js +65 -0
- package/dist/lib/person-name.js.map +1 -0
- package/dist/{kit-labels-Du0uHBq4.d.ts → register-form-V1OeNlMr.d.ts} +383 -2
- package/dist/rhf/fields.d.ts +18 -2
- package/dist/rhf/form.d.ts +18 -2
- package/dist/rhf.d.ts +18 -2
- package/dist/shell/app-shell.d.ts +18 -2
- package/dist/shell/company-switcher.d.ts +59 -0
- package/dist/shell/company-switcher.js +85 -0
- package/dist/shell/company-switcher.js.map +1 -0
- package/dist/shell/top-bar-brand.d.ts +18 -2
- package/dist/shell/topbar-action-menu.d.ts +1 -0
- package/dist/shell.d.ts +12 -2
- package/dist/wizard/stepper-nav.d.ts +18 -2
- package/dist/wizard.d.ts +18 -2
- package/package.json +1 -1
- package/src/auth/accept-invitation.tsx +227 -0
- package/src/auth/auth-errors.ts +105 -0
- package/src/auth/complete-name-dialog.tsx +253 -0
- package/src/auth/email-tag.ts +75 -0
- package/src/auth/forgot-password-form.tsx +213 -0
- package/src/auth/form-rules.ts +40 -0
- package/src/auth/new-password-fields.tsx +85 -0
- package/src/auth/not-found-page.tsx +98 -0
- package/src/auth/register-form.tsx +459 -0
- package/src/auth/reset-password-form.tsx +337 -0
- package/src/auth/sign-in-form.tsx +687 -0
- package/src/auth/status-parts.tsx +138 -0
- package/src/auth/verify-email.tsx +358 -0
- package/src/components/user-avatar.tsx +22 -4
- package/src/i18n/defaults.ts +18 -0
- package/src/i18n/german.ts +143 -0
- package/src/i18n/kit-labels.tsx +27 -0
- package/src/i18n/locales/es.ts +144 -1
- package/src/i18n/locales/fr.ts +147 -0
- package/src/i18n/locales/hu.ts +147 -1
- package/src/i18n/locales/it.ts +143 -0
- package/src/i18n/locales/zh.ts +138 -0
- package/src/i18n/review.ts +8 -0
- package/src/index.ts +53 -0
- package/src/lib/person-name.ts +157 -0
- package/src/shell/company-switcher.tsx +140 -0
|
@@ -2,7 +2,7 @@ import * as react from 'react';
|
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
3
|
import { CalculatorButtonLabels } from './calculator.js';
|
|
4
4
|
import { NumberPadSheetLabels } from './numpad-sheet.js';
|
|
5
|
-
import '../
|
|
5
|
+
import '../register-form-V1OeNlMr.js';
|
|
6
6
|
import '../data-table-labels-DUELeXpa.js';
|
|
7
7
|
import './data-table-sort.js';
|
|
8
8
|
import './swipeable-row.js';
|
|
@@ -15,6 +15,7 @@ import './field-sync.js';
|
|
|
15
15
|
import './tooltip.js';
|
|
16
16
|
import '../hooks/use-anchored-rect.js';
|
|
17
17
|
import '../lib/clipping.js';
|
|
18
|
+
import './field-parts.js';
|
|
18
19
|
import '../wizard/types.js';
|
|
19
20
|
import '../tour/tour.js';
|
|
20
21
|
import '../search/command-palette.js';
|
|
@@ -36,6 +37,7 @@ import './modal.js';
|
|
|
36
37
|
import '../hooks/use-search-param-state.js';
|
|
37
38
|
import './measured-grid.js';
|
|
38
39
|
import './user-avatar.js';
|
|
40
|
+
import '../lib/person-name.js';
|
|
39
41
|
import './status-dot.js';
|
|
40
42
|
import './progress-bar.js';
|
|
41
43
|
import './signed-amount.js';
|
|
@@ -55,6 +57,15 @@ import './authed-image.js';
|
|
|
55
57
|
import './image-grid.js';
|
|
56
58
|
import './lightbox.js';
|
|
57
59
|
import './write-lock.js';
|
|
60
|
+
import '../auth/sign-in-form.js';
|
|
61
|
+
import '../auth/complete-name-dialog.js';
|
|
62
|
+
import '../auth/forgot-password-form.js';
|
|
63
|
+
import '../auth/status-parts.js';
|
|
64
|
+
import '../auth/reset-password-form.js';
|
|
65
|
+
import '../auth/verify-email.js';
|
|
66
|
+
import '../auth/not-found-page.js';
|
|
67
|
+
import '../auth/accept-invitation.js';
|
|
68
|
+
import '../shell/company-switcher.js';
|
|
58
69
|
import './account-chips.js';
|
|
59
70
|
import '../lib/format.js';
|
|
60
71
|
import './reauth-dialog.js';
|
|
@@ -70,7 +81,12 @@ import './sign-chip.js';
|
|
|
70
81
|
import './column-mapper.js';
|
|
71
82
|
import '../lib/column-mapping.js';
|
|
72
83
|
import '../lib/table-text.js';
|
|
73
|
-
import '
|
|
84
|
+
import '../shell/topbar-controls.js';
|
|
85
|
+
import '../theme/palette-presets.js';
|
|
86
|
+
import '../theme/chart-palette.js';
|
|
87
|
+
import '../theme/theme-store.js';
|
|
88
|
+
import 'zustand/middleware';
|
|
89
|
+
import 'zustand';
|
|
74
90
|
|
|
75
91
|
interface NumberInputProps {
|
|
76
92
|
/** The text, DOT-decimal ("1234.5", or a calculation being typed: "12+5"), as
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
-
import { bB as CalculatorLabels } from '../
|
|
3
|
+
import { bB as CalculatorLabels } from '../register-form-V1OeNlMr.js';
|
|
4
4
|
import '../data-table-labels-DUELeXpa.js';
|
|
5
5
|
import './data-table-sort.js';
|
|
6
6
|
import './swipeable-row.js';
|
|
@@ -13,6 +13,7 @@ import './field-sync.js';
|
|
|
13
13
|
import './tooltip.js';
|
|
14
14
|
import '../hooks/use-anchored-rect.js';
|
|
15
15
|
import '../lib/clipping.js';
|
|
16
|
+
import './field-parts.js';
|
|
16
17
|
import '../wizard/types.js';
|
|
17
18
|
import '../tour/tour.js';
|
|
18
19
|
import '../search/command-palette.js';
|
|
@@ -34,6 +35,7 @@ import './modal.js';
|
|
|
34
35
|
import '../hooks/use-search-param-state.js';
|
|
35
36
|
import './measured-grid.js';
|
|
36
37
|
import './user-avatar.js';
|
|
38
|
+
import '../lib/person-name.js';
|
|
37
39
|
import './status-dot.js';
|
|
38
40
|
import './progress-bar.js';
|
|
39
41
|
import './signed-amount.js';
|
|
@@ -53,6 +55,15 @@ import './authed-image.js';
|
|
|
53
55
|
import './image-grid.js';
|
|
54
56
|
import './lightbox.js';
|
|
55
57
|
import './write-lock.js';
|
|
58
|
+
import '../auth/sign-in-form.js';
|
|
59
|
+
import '../auth/complete-name-dialog.js';
|
|
60
|
+
import '../auth/forgot-password-form.js';
|
|
61
|
+
import '../auth/status-parts.js';
|
|
62
|
+
import '../auth/reset-password-form.js';
|
|
63
|
+
import '../auth/verify-email.js';
|
|
64
|
+
import '../auth/not-found-page.js';
|
|
65
|
+
import '../auth/accept-invitation.js';
|
|
66
|
+
import '../shell/company-switcher.js';
|
|
56
67
|
import './account-chips.js';
|
|
57
68
|
import '../lib/format.js';
|
|
58
69
|
import './reauth-dialog.js';
|
|
@@ -68,7 +79,12 @@ import './sign-chip.js';
|
|
|
68
79
|
import './column-mapper.js';
|
|
69
80
|
import '../lib/column-mapping.js';
|
|
70
81
|
import '../lib/table-text.js';
|
|
71
|
-
import '
|
|
82
|
+
import '../shell/topbar-controls.js';
|
|
83
|
+
import '../theme/palette-presets.js';
|
|
84
|
+
import '../theme/chart-palette.js';
|
|
85
|
+
import '../theme/theme-store.js';
|
|
86
|
+
import 'zustand/middleware';
|
|
87
|
+
import 'zustand';
|
|
72
88
|
|
|
73
89
|
/**
|
|
74
90
|
* A full calculator keypad rendered as a bottom sheet — the mobile counterpart to
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import 'react';
|
|
2
2
|
import '../lib/phone.js';
|
|
3
|
-
export { cp as DEFAULT_PHONE_INPUT_LABELS,
|
|
3
|
+
export { cp as DEFAULT_PHONE_INPUT_LABELS, dO as PhoneInput, dP as PhoneInputLabels, dQ as PhoneInputProps } from '../register-form-V1OeNlMr.js';
|
|
4
4
|
import '../data-table-labels-DUELeXpa.js';
|
|
5
5
|
import './data-table-sort.js';
|
|
6
6
|
import './swipeable-row.js';
|
|
@@ -13,6 +13,7 @@ import './field-sync.js';
|
|
|
13
13
|
import './tooltip.js';
|
|
14
14
|
import '../hooks/use-anchored-rect.js';
|
|
15
15
|
import '../lib/clipping.js';
|
|
16
|
+
import './field-parts.js';
|
|
16
17
|
import '../wizard/types.js';
|
|
17
18
|
import '../tour/tour.js';
|
|
18
19
|
import '../search/command-palette.js';
|
|
@@ -34,6 +35,7 @@ import './modal.js';
|
|
|
34
35
|
import '../hooks/use-search-param-state.js';
|
|
35
36
|
import './measured-grid.js';
|
|
36
37
|
import './user-avatar.js';
|
|
38
|
+
import '../lib/person-name.js';
|
|
37
39
|
import './status-dot.js';
|
|
38
40
|
import './progress-bar.js';
|
|
39
41
|
import './signed-amount.js';
|
|
@@ -53,6 +55,15 @@ import './authed-image.js';
|
|
|
53
55
|
import './image-grid.js';
|
|
54
56
|
import './lightbox.js';
|
|
55
57
|
import './write-lock.js';
|
|
58
|
+
import '../auth/sign-in-form.js';
|
|
59
|
+
import '../auth/complete-name-dialog.js';
|
|
60
|
+
import '../auth/forgot-password-form.js';
|
|
61
|
+
import '../auth/status-parts.js';
|
|
62
|
+
import '../auth/reset-password-form.js';
|
|
63
|
+
import '../auth/verify-email.js';
|
|
64
|
+
import '../auth/not-found-page.js';
|
|
65
|
+
import '../auth/accept-invitation.js';
|
|
66
|
+
import '../shell/company-switcher.js';
|
|
56
67
|
import './account-chips.js';
|
|
57
68
|
import '../lib/format.js';
|
|
58
69
|
import './reauth-dialog.js';
|
|
@@ -67,4 +78,9 @@ import './sign-chip.js';
|
|
|
67
78
|
import './column-mapper.js';
|
|
68
79
|
import '../lib/column-mapping.js';
|
|
69
80
|
import '../lib/table-text.js';
|
|
70
|
-
import '
|
|
81
|
+
import '../shell/topbar-controls.js';
|
|
82
|
+
import '../theme/palette-presets.js';
|
|
83
|
+
import '../theme/chart-palette.js';
|
|
84
|
+
import '../theme/theme-store.js';
|
|
85
|
+
import 'zustand/middleware';
|
|
86
|
+
import 'zustand';
|
|
@@ -5,7 +5,7 @@ import { LegendEntry } from './toggle-legend.js';
|
|
|
5
5
|
import { SeriesChartLabels } from './series-chart-labels.js';
|
|
6
6
|
import { TimeTickUnit } from './series-chart-ticks.js';
|
|
7
7
|
import { SeriesChartAxisBudget } from './series-chart-budget.js';
|
|
8
|
-
import { bU as ChartTooltipPlacement } from '../
|
|
8
|
+
import { bU as ChartTooltipPlacement } from '../register-form-V1OeNlMr.js';
|
|
9
9
|
import 'recharts';
|
|
10
10
|
import '../data-table-labels-DUELeXpa.js';
|
|
11
11
|
import './data-table-sort.js';
|
|
@@ -19,6 +19,7 @@ import './field-sync.js';
|
|
|
19
19
|
import './tooltip.js';
|
|
20
20
|
import '../hooks/use-anchored-rect.js';
|
|
21
21
|
import '../lib/clipping.js';
|
|
22
|
+
import './field-parts.js';
|
|
22
23
|
import '../wizard/types.js';
|
|
23
24
|
import '../tour/tour.js';
|
|
24
25
|
import '../search/command-palette.js';
|
|
@@ -39,6 +40,7 @@ import './modal.js';
|
|
|
39
40
|
import '../hooks/use-search-param-state.js';
|
|
40
41
|
import './measured-grid.js';
|
|
41
42
|
import './user-avatar.js';
|
|
43
|
+
import '../lib/person-name.js';
|
|
42
44
|
import './status-dot.js';
|
|
43
45
|
import './progress-bar.js';
|
|
44
46
|
import './signed-amount.js';
|
|
@@ -58,6 +60,15 @@ import './authed-image.js';
|
|
|
58
60
|
import './image-grid.js';
|
|
59
61
|
import './lightbox.js';
|
|
60
62
|
import './write-lock.js';
|
|
63
|
+
import '../auth/sign-in-form.js';
|
|
64
|
+
import '../auth/complete-name-dialog.js';
|
|
65
|
+
import '../auth/forgot-password-form.js';
|
|
66
|
+
import '../auth/status-parts.js';
|
|
67
|
+
import '../auth/reset-password-form.js';
|
|
68
|
+
import '../auth/verify-email.js';
|
|
69
|
+
import '../auth/not-found-page.js';
|
|
70
|
+
import '../auth/accept-invitation.js';
|
|
71
|
+
import '../shell/company-switcher.js';
|
|
61
72
|
import './account-chips.js';
|
|
62
73
|
import '../lib/format.js';
|
|
63
74
|
import './reauth-dialog.js';
|
|
@@ -73,7 +84,12 @@ import './sign-chip.js';
|
|
|
73
84
|
import './column-mapper.js';
|
|
74
85
|
import '../lib/column-mapping.js';
|
|
75
86
|
import '../lib/table-text.js';
|
|
76
|
-
import '
|
|
87
|
+
import '../shell/topbar-controls.js';
|
|
88
|
+
import '../theme/palette-presets.js';
|
|
89
|
+
import '../theme/chart-palette.js';
|
|
90
|
+
import '../theme/theme-store.js';
|
|
91
|
+
import 'zustand/middleware';
|
|
92
|
+
import 'zustand';
|
|
77
93
|
|
|
78
94
|
interface SeriesChartSeries {
|
|
79
95
|
/** The row key this line reads — and the `--color-<key>` it is painted with, so it
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
-
import {
|
|
3
|
+
import { dY as SelectProps } from '../register-form-V1OeNlMr.js';
|
|
4
4
|
import { ThemePreference } from '../theme/theme-store.js';
|
|
5
5
|
import '../data-table-labels-DUELeXpa.js';
|
|
6
6
|
import './data-table-sort.js';
|
|
@@ -14,6 +14,7 @@ import './field-sync.js';
|
|
|
14
14
|
import './tooltip.js';
|
|
15
15
|
import '../hooks/use-anchored-rect.js';
|
|
16
16
|
import '../lib/clipping.js';
|
|
17
|
+
import './field-parts.js';
|
|
17
18
|
import '../wizard/types.js';
|
|
18
19
|
import '../tour/tour.js';
|
|
19
20
|
import '../search/command-palette.js';
|
|
@@ -35,6 +36,7 @@ import './modal.js';
|
|
|
35
36
|
import '../hooks/use-search-param-state.js';
|
|
36
37
|
import './measured-grid.js';
|
|
37
38
|
import './user-avatar.js';
|
|
39
|
+
import '../lib/person-name.js';
|
|
38
40
|
import './status-dot.js';
|
|
39
41
|
import './progress-bar.js';
|
|
40
42
|
import './signed-amount.js';
|
|
@@ -54,6 +56,15 @@ import './authed-image.js';
|
|
|
54
56
|
import './image-grid.js';
|
|
55
57
|
import './lightbox.js';
|
|
56
58
|
import './write-lock.js';
|
|
59
|
+
import '../auth/sign-in-form.js';
|
|
60
|
+
import '../auth/complete-name-dialog.js';
|
|
61
|
+
import '../auth/forgot-password-form.js';
|
|
62
|
+
import '../auth/status-parts.js';
|
|
63
|
+
import '../auth/reset-password-form.js';
|
|
64
|
+
import '../auth/verify-email.js';
|
|
65
|
+
import '../auth/not-found-page.js';
|
|
66
|
+
import '../auth/accept-invitation.js';
|
|
67
|
+
import '../shell/company-switcher.js';
|
|
57
68
|
import './account-chips.js';
|
|
58
69
|
import '../lib/format.js';
|
|
59
70
|
import './reauth-dialog.js';
|
|
@@ -69,7 +80,9 @@ import './sign-chip.js';
|
|
|
69
80
|
import './column-mapper.js';
|
|
70
81
|
import '../lib/column-mapping.js';
|
|
71
82
|
import '../lib/table-text.js';
|
|
72
|
-
import '
|
|
83
|
+
import '../shell/topbar-controls.js';
|
|
84
|
+
import '../theme/palette-presets.js';
|
|
85
|
+
import '../theme/chart-palette.js';
|
|
73
86
|
import 'zustand/middleware';
|
|
74
87
|
import 'zustand';
|
|
75
88
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import 'react';
|
|
2
2
|
import './account-chips.js';
|
|
3
3
|
import './dialog-frame.js';
|
|
4
|
-
export {
|
|
4
|
+
export { cs as DEFAULT_SHARE_CARD_LABELS, dZ as ShareAddRequest, d_ as ShareCandidate, d$ as ShareCard, e0 as ShareCardLabels, e1 as ShareCardProps, e2 as ShareDialog, e3 as ShareDialogProps, e4 as ShareGrantee, e5 as SharePanel, e6 as SharePanelProps, e7 as SharePendingGrant, e8 as ShareRole } from '../register-form-V1OeNlMr.js';
|
|
5
5
|
import 'lucide-react';
|
|
6
6
|
import '../lib/format.js';
|
|
7
7
|
import './chip.js';
|
|
@@ -17,6 +17,7 @@ import './field-sync.js';
|
|
|
17
17
|
import './tooltip.js';
|
|
18
18
|
import '../hooks/use-anchored-rect.js';
|
|
19
19
|
import '../lib/clipping.js';
|
|
20
|
+
import './field-parts.js';
|
|
20
21
|
import '../wizard/types.js';
|
|
21
22
|
import '../tour/tour.js';
|
|
22
23
|
import '../search/command-palette.js';
|
|
@@ -35,6 +36,7 @@ import './tile-radio.js';
|
|
|
35
36
|
import './icon-picker.js';
|
|
36
37
|
import './measured-grid.js';
|
|
37
38
|
import './user-avatar.js';
|
|
39
|
+
import '../lib/person-name.js';
|
|
38
40
|
import './status-dot.js';
|
|
39
41
|
import './progress-bar.js';
|
|
40
42
|
import './signed-amount.js';
|
|
@@ -54,6 +56,15 @@ import './authed-image.js';
|
|
|
54
56
|
import './image-grid.js';
|
|
55
57
|
import './lightbox.js';
|
|
56
58
|
import './write-lock.js';
|
|
59
|
+
import '../auth/sign-in-form.js';
|
|
60
|
+
import '../auth/complete-name-dialog.js';
|
|
61
|
+
import '../auth/forgot-password-form.js';
|
|
62
|
+
import '../auth/status-parts.js';
|
|
63
|
+
import '../auth/reset-password-form.js';
|
|
64
|
+
import '../auth/verify-email.js';
|
|
65
|
+
import '../auth/not-found-page.js';
|
|
66
|
+
import '../auth/accept-invitation.js';
|
|
67
|
+
import '../shell/company-switcher.js';
|
|
57
68
|
import './reauth-dialog.js';
|
|
58
69
|
import './server-wake.js';
|
|
59
70
|
import '../lib/server-wake.js';
|
|
@@ -67,4 +78,9 @@ import './sign-chip.js';
|
|
|
67
78
|
import './column-mapper.js';
|
|
68
79
|
import '../lib/column-mapping.js';
|
|
69
80
|
import '../lib/table-text.js';
|
|
70
|
-
import '
|
|
81
|
+
import '../shell/topbar-controls.js';
|
|
82
|
+
import '../theme/palette-presets.js';
|
|
83
|
+
import '../theme/chart-palette.js';
|
|
84
|
+
import '../theme/theme-store.js';
|
|
85
|
+
import 'zustand/middleware';
|
|
86
|
+
import 'zustand';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactElement, ComponentPropsWithoutRef, ReactNode, Ref, MouseEvent, KeyboardEvent } from 'react';
|
|
3
3
|
import { LucideIcon } from 'lucide-react';
|
|
4
|
-
import {
|
|
4
|
+
import { dp as KitLinkComponent } from '../register-form-V1OeNlMr.js';
|
|
5
5
|
import '../data-table-labels-DUELeXpa.js';
|
|
6
6
|
import './data-table-sort.js';
|
|
7
7
|
import './swipeable-row.js';
|
|
@@ -13,6 +13,7 @@ import './field-sync.js';
|
|
|
13
13
|
import './tooltip.js';
|
|
14
14
|
import '../hooks/use-anchored-rect.js';
|
|
15
15
|
import '../lib/clipping.js';
|
|
16
|
+
import './field-parts.js';
|
|
16
17
|
import '../wizard/types.js';
|
|
17
18
|
import '../tour/tour.js';
|
|
18
19
|
import '../search/command-palette.js';
|
|
@@ -34,6 +35,7 @@ import './modal.js';
|
|
|
34
35
|
import '../hooks/use-search-param-state.js';
|
|
35
36
|
import './measured-grid.js';
|
|
36
37
|
import './user-avatar.js';
|
|
38
|
+
import '../lib/person-name.js';
|
|
37
39
|
import './status-dot.js';
|
|
38
40
|
import './progress-bar.js';
|
|
39
41
|
import './signed-amount.js';
|
|
@@ -53,6 +55,15 @@ import './authed-image.js';
|
|
|
53
55
|
import './image-grid.js';
|
|
54
56
|
import './lightbox.js';
|
|
55
57
|
import './write-lock.js';
|
|
58
|
+
import '../auth/sign-in-form.js';
|
|
59
|
+
import '../auth/complete-name-dialog.js';
|
|
60
|
+
import '../auth/forgot-password-form.js';
|
|
61
|
+
import '../auth/status-parts.js';
|
|
62
|
+
import '../auth/reset-password-form.js';
|
|
63
|
+
import '../auth/verify-email.js';
|
|
64
|
+
import '../auth/not-found-page.js';
|
|
65
|
+
import '../auth/accept-invitation.js';
|
|
66
|
+
import '../shell/company-switcher.js';
|
|
56
67
|
import './account-chips.js';
|
|
57
68
|
import '../lib/format.js';
|
|
58
69
|
import './reauth-dialog.js';
|
|
@@ -68,7 +79,12 @@ import './sign-chip.js';
|
|
|
68
79
|
import './column-mapper.js';
|
|
69
80
|
import '../lib/column-mapping.js';
|
|
70
81
|
import '../lib/table-text.js';
|
|
71
|
-
import '
|
|
82
|
+
import '../shell/topbar-controls.js';
|
|
83
|
+
import '../theme/palette-presets.js';
|
|
84
|
+
import '../theme/chart-palette.js';
|
|
85
|
+
import '../theme/theme-store.js';
|
|
86
|
+
import 'zustand/middleware';
|
|
87
|
+
import 'zustand';
|
|
72
88
|
|
|
73
89
|
/**
|
|
74
90
|
* An `href` that leaves the app: a scheme (`https:`, `mailto:`, `tel:`) or a
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { di as InputProps } from '../register-form-V1OeNlMr.js';
|
|
3
3
|
import '../data-table-labels-DUELeXpa.js';
|
|
4
4
|
import './data-table-sort.js';
|
|
5
5
|
import './swipeable-row.js';
|
|
@@ -12,6 +12,7 @@ import './field-sync.js';
|
|
|
12
12
|
import './tooltip.js';
|
|
13
13
|
import '../hooks/use-anchored-rect.js';
|
|
14
14
|
import '../lib/clipping.js';
|
|
15
|
+
import './field-parts.js';
|
|
15
16
|
import '../wizard/types.js';
|
|
16
17
|
import '../tour/tour.js';
|
|
17
18
|
import '../search/command-palette.js';
|
|
@@ -33,6 +34,7 @@ import './modal.js';
|
|
|
33
34
|
import '../hooks/use-search-param-state.js';
|
|
34
35
|
import './measured-grid.js';
|
|
35
36
|
import './user-avatar.js';
|
|
37
|
+
import '../lib/person-name.js';
|
|
36
38
|
import './status-dot.js';
|
|
37
39
|
import './progress-bar.js';
|
|
38
40
|
import './signed-amount.js';
|
|
@@ -52,6 +54,15 @@ import './authed-image.js';
|
|
|
52
54
|
import './image-grid.js';
|
|
53
55
|
import './lightbox.js';
|
|
54
56
|
import './write-lock.js';
|
|
57
|
+
import '../auth/sign-in-form.js';
|
|
58
|
+
import '../auth/complete-name-dialog.js';
|
|
59
|
+
import '../auth/forgot-password-form.js';
|
|
60
|
+
import '../auth/status-parts.js';
|
|
61
|
+
import '../auth/reset-password-form.js';
|
|
62
|
+
import '../auth/verify-email.js';
|
|
63
|
+
import '../auth/not-found-page.js';
|
|
64
|
+
import '../auth/accept-invitation.js';
|
|
65
|
+
import '../shell/company-switcher.js';
|
|
55
66
|
import './account-chips.js';
|
|
56
67
|
import '../lib/format.js';
|
|
57
68
|
import './reauth-dialog.js';
|
|
@@ -67,7 +78,12 @@ import './sign-chip.js';
|
|
|
67
78
|
import './column-mapper.js';
|
|
68
79
|
import '../lib/column-mapping.js';
|
|
69
80
|
import '../lib/table-text.js';
|
|
70
|
-
import '
|
|
81
|
+
import '../shell/topbar-controls.js';
|
|
82
|
+
import '../theme/palette-presets.js';
|
|
83
|
+
import '../theme/chart-palette.js';
|
|
84
|
+
import '../theme/theme-store.js';
|
|
85
|
+
import 'zustand/middleware';
|
|
86
|
+
import 'zustand';
|
|
71
87
|
|
|
72
88
|
/**
|
|
73
89
|
* A time of day, as a `"HH:mm"` string (`"HH:mm:ss"` once `step` asks for seconds).
|
package/dist/components/ui.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import 'react';
|
|
2
2
|
import './tooltip.js';
|
|
3
|
-
export { bu as Button, bv as ButtonClassesOptions, bw as ButtonLinkProps, bx as ButtonProps, by as ButtonSize, bz as ButtonTone, bA as ButtonVariant, bC as Card, bD as CardAction, bE as CardActionProps, bF as CardContent, bG as CardContentProps, bH as CardDensity, bI as CardDescription, bJ as CardDescriptionProps, bK as CardFooter, bL as CardFooterProps, bM as CardHeader, bN as CardHeaderProps, bO as CardProps, bP as CardTitle, bQ as CardTitleLevel, bR as CardTitleProps, bS as CardTone, bT as CharacterCountLabels, ca as DEFAULT_CHARACTER_COUNT_LABELS, co as DEFAULT_PASSWORD_REVEAL_LABELS,
|
|
3
|
+
export { bu as Button, bv as ButtonClassesOptions, bw as ButtonLinkProps, bx as ButtonProps, by as ButtonSize, bz as ButtonTone, bA as ButtonVariant, bC as Card, bD as CardAction, bE as CardActionProps, bF as CardContent, bG as CardContentProps, bH as CardDensity, bI as CardDescription, bJ as CardDescriptionProps, bK as CardFooter, bL as CardFooterProps, bM as CardHeader, bN as CardHeaderProps, bO as CardProps, bP as CardTitle, bQ as CardTitleLevel, bR as CardTitleProps, bS as CardTone, bT as CharacterCountLabels, ca as DEFAULT_CHARACTER_COUNT_LABELS, co as DEFAULT_PASSWORD_REVEAL_LABELS, cu as DEFAULT_TABS_LABELS, cC as EmptyState, cD as EmptyStateProps, cE as FIELD_BASE, cF as FIELD_DISPLAY, cG as FIELD_FLOATING_PAD, cH as FIELD_INVALID, cI as FIELD_TRIGGER, cJ as FIELD_WRITABLE_LOOK, cK as FLOATING_INPUT_CLASS, cL as FLOATING_LABEL_CLASS, cM as FieldChevron, cN as FieldChevronProps, cO as FieldHint, cP as FieldHintProps, cX as FloatingField, cY as FloatingFieldProps, d9 as IconButton, da as IconButtonGlyphSize, db as IconButtonLinkProps, dc as IconButtonProps, dd as IconButtonSize, de as IconButtonTone, df as IconButtonToneColor, dg as IconButtonVariant, dh as Input, di as InputProps, ds as Label, du as LabelProps, dM as PHONE_QUERY, dN as PasswordRevealLabels, dX as Select, dY as SelectProps, e9 as Spinner, ea as SpinnerProps, ec as TabItem, ed as Tabs, ee as TabsLabels, ef as TabsProps, eg as Textarea, eh as TextareaProps, et as buttonClasses, eD as resolvePasswordRevealLabels } from '../register-form-V1OeNlMr.js';
|
|
4
4
|
export { FLOATING_LABEL_STATIC, FieldLabel, FieldLabelProps } from './field-parts.js';
|
|
5
5
|
import '../hooks/use-anchored-rect.js';
|
|
6
6
|
import '../lib/clipping.js';
|
|
@@ -34,6 +34,7 @@ import './modal.js';
|
|
|
34
34
|
import '../hooks/use-search-param-state.js';
|
|
35
35
|
import './measured-grid.js';
|
|
36
36
|
import './user-avatar.js';
|
|
37
|
+
import '../lib/person-name.js';
|
|
37
38
|
import './status-dot.js';
|
|
38
39
|
import './progress-bar.js';
|
|
39
40
|
import './signed-amount.js';
|
|
@@ -53,6 +54,15 @@ import './authed-image.js';
|
|
|
53
54
|
import './image-grid.js';
|
|
54
55
|
import './lightbox.js';
|
|
55
56
|
import './write-lock.js';
|
|
57
|
+
import '../auth/sign-in-form.js';
|
|
58
|
+
import '../auth/complete-name-dialog.js';
|
|
59
|
+
import '../auth/forgot-password-form.js';
|
|
60
|
+
import '../auth/status-parts.js';
|
|
61
|
+
import '../auth/reset-password-form.js';
|
|
62
|
+
import '../auth/verify-email.js';
|
|
63
|
+
import '../auth/not-found-page.js';
|
|
64
|
+
import '../auth/accept-invitation.js';
|
|
65
|
+
import '../shell/company-switcher.js';
|
|
56
66
|
import './account-chips.js';
|
|
57
67
|
import '../lib/format.js';
|
|
58
68
|
import './reauth-dialog.js';
|
|
@@ -68,3 +78,9 @@ import './sign-chip.js';
|
|
|
68
78
|
import './column-mapper.js';
|
|
69
79
|
import '../lib/column-mapping.js';
|
|
70
80
|
import '../lib/table-text.js';
|
|
81
|
+
import '../shell/topbar-controls.js';
|
|
82
|
+
import '../theme/palette-presets.js';
|
|
83
|
+
import '../theme/chart-palette.js';
|
|
84
|
+
import '../theme/theme-store.js';
|
|
85
|
+
import 'zustand/middleware';
|
|
86
|
+
import 'zustand';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ComponentPropsWithoutRef, ReactNode } from 'react';
|
|
3
|
+
import { PersonName } from '../lib/person-name.js';
|
|
3
4
|
import { StatusDotTone } from './status-dot.js';
|
|
4
5
|
import './progress-bar.js';
|
|
5
6
|
import './signed-amount.js';
|
|
@@ -33,10 +34,23 @@ interface UserAvatarBadge {
|
|
|
33
34
|
tone?: StatusDotTone;
|
|
34
35
|
}
|
|
35
36
|
/** A `<span>`'s props, minus `children`: the content is the initials this computes
|
|
36
|
-
* from `name`/`email`, so there is nothing for a caller to put inside. */
|
|
37
|
+
* from `person`/`name`/`email`, so there is nothing for a caller to put inside. */
|
|
37
38
|
interface UserAvatarProps extends Omit<ComponentPropsWithoutRef<"span">, "children"> {
|
|
38
39
|
name?: string | null;
|
|
39
40
|
email?: string | null;
|
|
41
|
+
/**
|
|
42
|
+
* The person's first and last name (0.29.0, docs/auth-harmonization.md §3.2) —
|
|
43
|
+
* preferred over `name` whenever either part is filled in. The initials follow the
|
|
44
|
+
* READER's language, the provider's `locale`: "AE" for Ada Example, "EA" in Hungarian
|
|
45
|
+
* (family name first), the family name's first character alone in Chinese. See
|
|
46
|
+
* {@link personInitials}.
|
|
47
|
+
*
|
|
48
|
+
* `name` stays the fallback for an API that still sends only `display_name`, and
|
|
49
|
+
* `email` after it: a person whose two parts are both blank falls through to them.
|
|
50
|
+
* A migrated user (the whole old display name in `first`, no `last`, §3.3) keeps the
|
|
51
|
+
* initials they had.
|
|
52
|
+
*/
|
|
53
|
+
person?: PersonName | null;
|
|
40
54
|
size?: keyof typeof AVATAR_SIZES;
|
|
41
55
|
/**
|
|
42
56
|
* A status dot in the top-end corner (the top-right in LTR, top-left in RTL), ringed
|
|
@@ -53,6 +67,6 @@ interface UserAvatarProps extends Omit<ComponentPropsWithoutRef<"span">, "childr
|
|
|
53
67
|
* A round initials avatar — the common user chip shared across apps (feedback
|
|
54
68
|
* #333). Purely presentational; wrap it in a button for the account menu trigger.
|
|
55
69
|
*/
|
|
56
|
-
declare function UserAvatar({ name, email, size, badge, className, ...rest }: UserAvatarProps): react.JSX.Element;
|
|
70
|
+
declare function UserAvatar({ name, email, person, size, badge, className, ...rest }: UserAvatarProps): react.JSX.Element;
|
|
57
71
|
|
|
58
72
|
export { UserAvatar, type UserAvatarBadge, type UserAvatarProps, avatarInitials };
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { cn } from "../lib/cn.js";
|
|
4
|
+
import { personInitials } from "../lib/person-name.js";
|
|
5
|
+
import { useKitLocale } from "../i18n/kit-labels.js";
|
|
4
6
|
import { StatusDot } from "./status-dot.js";
|
|
5
7
|
function avatarInitials(name, email) {
|
|
6
8
|
const source = [name, email].map((s) => s?.trim()).find(Boolean) ?? "?";
|
|
@@ -15,7 +17,9 @@ const AVATAR_SIZES = {
|
|
|
15
17
|
};
|
|
16
18
|
const CHIP = "inline-flex shrink-0 items-center justify-center rounded-full bg-[var(--bg-inverse)] font-semibold text-[var(--text-inverse)]";
|
|
17
19
|
const BADGE_SIZES = { sm: "sm", md: "md", lg: "lg" };
|
|
18
|
-
function UserAvatar({ name, email, size = "md", badge, className, ...rest }) {
|
|
20
|
+
function UserAvatar({ name, email, person, size = "md", badge, className, ...rest }) {
|
|
21
|
+
const locale = useKitLocale();
|
|
22
|
+
const initials = (person ? personInitials(person, locale) : "") || avatarInitials(name, email);
|
|
19
23
|
if (badge) {
|
|
20
24
|
return /* @__PURE__ */ jsxs("span", { ...rest, className: "relative inline-flex shrink-0", children: [
|
|
21
25
|
/* @__PURE__ */ jsx(
|
|
@@ -27,7 +31,7 @@ function UserAvatar({ name, email, size = "md", badge, className, ...rest }) {
|
|
|
27
31
|
AVATAR_SIZES[size],
|
|
28
32
|
className
|
|
29
33
|
),
|
|
30
|
-
children:
|
|
34
|
+
children: initials
|
|
31
35
|
}
|
|
32
36
|
),
|
|
33
37
|
/* @__PURE__ */ jsx(
|
|
@@ -52,7 +56,7 @@ function UserAvatar({ name, email, size = "md", badge, className, ...rest }) {
|
|
|
52
56
|
AVATAR_SIZES[size],
|
|
53
57
|
className
|
|
54
58
|
),
|
|
55
|
-
children:
|
|
59
|
+
children: initials
|
|
56
60
|
}
|
|
57
61
|
);
|
|
58
62
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/components/user-avatar.tsx"],"sourcesContent":["import type { ComponentPropsWithoutRef, ReactNode } from \"react\";\nimport { cn } from \"../lib/cn\";\nimport { StatusDot } from \"./status-dot\";\nimport type { StatusDotSize, StatusDotTone } from \"./status-dot\";\n\n/** Initials from a display name (first + last) or, failing that, an email —\n * e.g. \"Marcel Eifert\" → \"ME\", \"marcel@x.com\" → \"MA\". App-agnostic.\n *\n * \"Failing that\" means BLANK, not merely absent. This was `name ?? email ?? \"?\"`,\n * and `??` falls through on null/undefined alone — so an empty or whitespace-only\n * display name short-circuited the email it had in hand and landed on the guard\n * below, returning \"?\" for a user whose address says \"MA\" perfectly well. Keksdose\n * cannot reach it (its `display_name` has `min_length=1`), but this is exported as\n * app-agnostic, and any consumer whose profile name is optional free text got a wall\n * of \"?\" chips. The guard is what shows the empty case was foreseen; it just\n * answered it at the wrong end. */\nexport function avatarInitials(name?: string | null, email?: string | null): string {\n const source = [name, email].map((s) => s?.trim()).find(Boolean) ?? \"?\";\n const parts = source.split(/\\s+/).filter(Boolean);\n if (parts.length >= 2) return (parts[0][0] + parts[1][0]).toUpperCase();\n return source.slice(0, 2).toUpperCase();\n}\n\nconst AVATAR_SIZES = {\n sm: \"size-7 text-[11px]\",\n md: \"size-8 text-xs\",\n lg: \"size-12 text-base\",\n} as const;\n\nconst CHIP =\n \"inline-flex shrink-0 items-center justify-center rounded-full bg-[var(--bg-inverse)] font-semibold text-[var(--text-inverse)]\";\n\n/** The dot grows with the avatar: 8px on `sm`, 10px on `md` (keksdose's), 12px on `lg`. */\nconst BADGE_SIZES: Record<keyof typeof AVATAR_SIZES, StatusDotSize> = { sm: \"sm\", md: \"md\", lg: \"lg\" };\n\n/** A status dot in the avatar's top corner — an unread count, presence. */\nexport interface UserAvatarBadge {\n /** What the dot MEANS, for a screen reader (\"3 unread\"). Required: a coloured circle\n * says nothing to someone who cannot see it. */\n label: ReactNode;\n /** Default `danger`, the unread dot both apps draw by hand. */\n tone?: StatusDotTone;\n}\n\n/** A `<span>`'s props, minus `children`: the content is the initials this computes\n * from `name`/`email`, so there is nothing for a caller to put inside. */\nexport interface UserAvatarProps extends Omit<ComponentPropsWithoutRef<\"span\">, \"children\"> {\n name?: string | null;\n email?: string | null;\n size?: keyof typeof AVATAR_SIZES;\n /**\n * A status dot in the top-end corner (the top-right in LTR, top-left in RTL), ringed\n * in the surface colour so it reads as its own mark (keksdose account-menu ~385,\n * top-bar :152). Its `label` is read as text where the dot sits — inside a button\n * named by its content it joins that name. In `TopBarActionMenu`'s `trigger` the\n * button is named by the menu's `ariaLabel` followed by this label: \"Account menu\n * 3 unread\". The initials stay hidden either way, so the person's name is NOT part\n * of it — put it in `ariaLabel` (\"Marcel Eifert, account menu\") if it should be.\n */\n badge?: UserAvatarBadge | null;\n}\n\n/**\n * A round initials avatar — the common user chip shared across apps (feedback\n * #333). Purely presentational; wrap it in a button for the account menu trigger.\n */\nexport function UserAvatar({ name, email, size = \"md\", badge, className, ...rest }: UserAvatarProps) {\n if (badge) {\n // A wrapper, because the chip itself is `aria-hidden` and the badge label must not\n // be. `className` stays on the chip (a size override still sizes the circle); the\n // other attributes go on the wrapper, which is what a caller addresses. `relative`\n // also contains the sr-only text.\n return (\n <span {...rest} className=\"relative inline-flex shrink-0\">\n <span\n aria-hidden\n className={cn(\n CHIP,\n AVATAR_SIZES[size],\n className,\n )}\n >\n {
|
|
1
|
+
{"version":3,"sources":["../../src/components/user-avatar.tsx"],"sourcesContent":["import type { ComponentPropsWithoutRef, ReactNode } from \"react\";\nimport { cn } from \"../lib/cn\";\nimport { personInitials } from \"../lib/person-name\";\nimport type { PersonName } from \"../lib/person-name\";\nimport { useKitLocale } from \"../i18n/kit-labels\";\nimport { StatusDot } from \"./status-dot\";\nimport type { StatusDotSize, StatusDotTone } from \"./status-dot\";\n\n/** Initials from a display name (first + last) or, failing that, an email —\n * e.g. \"Marcel Eifert\" → \"ME\", \"marcel@x.com\" → \"MA\". App-agnostic.\n *\n * \"Failing that\" means BLANK, not merely absent. This was `name ?? email ?? \"?\"`,\n * and `??` falls through on null/undefined alone — so an empty or whitespace-only\n * display name short-circuited the email it had in hand and landed on the guard\n * below, returning \"?\" for a user whose address says \"MA\" perfectly well. Keksdose\n * cannot reach it (its `display_name` has `min_length=1`), but this is exported as\n * app-agnostic, and any consumer whose profile name is optional free text got a wall\n * of \"?\" chips. The guard is what shows the empty case was foreseen; it just\n * answered it at the wrong end. */\nexport function avatarInitials(name?: string | null, email?: string | null): string {\n const source = [name, email].map((s) => s?.trim()).find(Boolean) ?? \"?\";\n const parts = source.split(/\\s+/).filter(Boolean);\n if (parts.length >= 2) return (parts[0][0] + parts[1][0]).toUpperCase();\n return source.slice(0, 2).toUpperCase();\n}\n\nconst AVATAR_SIZES = {\n sm: \"size-7 text-[11px]\",\n md: \"size-8 text-xs\",\n lg: \"size-12 text-base\",\n} as const;\n\nconst CHIP =\n \"inline-flex shrink-0 items-center justify-center rounded-full bg-[var(--bg-inverse)] font-semibold text-[var(--text-inverse)]\";\n\n/** The dot grows with the avatar: 8px on `sm`, 10px on `md` (keksdose's), 12px on `lg`. */\nconst BADGE_SIZES: Record<keyof typeof AVATAR_SIZES, StatusDotSize> = { sm: \"sm\", md: \"md\", lg: \"lg\" };\n\n/** A status dot in the avatar's top corner — an unread count, presence. */\nexport interface UserAvatarBadge {\n /** What the dot MEANS, for a screen reader (\"3 unread\"). Required: a coloured circle\n * says nothing to someone who cannot see it. */\n label: ReactNode;\n /** Default `danger`, the unread dot both apps draw by hand. */\n tone?: StatusDotTone;\n}\n\n/** A `<span>`'s props, minus `children`: the content is the initials this computes\n * from `person`/`name`/`email`, so there is nothing for a caller to put inside. */\nexport interface UserAvatarProps extends Omit<ComponentPropsWithoutRef<\"span\">, \"children\"> {\n name?: string | null;\n email?: string | null;\n /**\n * The person's first and last name (0.29.0, docs/auth-harmonization.md §3.2) —\n * preferred over `name` whenever either part is filled in. The initials follow the\n * READER's language, the provider's `locale`: \"AE\" for Ada Example, \"EA\" in Hungarian\n * (family name first), the family name's first character alone in Chinese. See\n * {@link personInitials}.\n *\n * `name` stays the fallback for an API that still sends only `display_name`, and\n * `email` after it: a person whose two parts are both blank falls through to them.\n * A migrated user (the whole old display name in `first`, no `last`, §3.3) keeps the\n * initials they had.\n */\n person?: PersonName | null;\n size?: keyof typeof AVATAR_SIZES;\n /**\n * A status dot in the top-end corner (the top-right in LTR, top-left in RTL), ringed\n * in the surface colour so it reads as its own mark (keksdose account-menu ~385,\n * top-bar :152). Its `label` is read as text where the dot sits — inside a button\n * named by its content it joins that name. In `TopBarActionMenu`'s `trigger` the\n * button is named by the menu's `ariaLabel` followed by this label: \"Account menu\n * 3 unread\". The initials stay hidden either way, so the person's name is NOT part\n * of it — put it in `ariaLabel` (\"Marcel Eifert, account menu\") if it should be.\n */\n badge?: UserAvatarBadge | null;\n}\n\n/**\n * A round initials avatar — the common user chip shared across apps (feedback\n * #333). Purely presentational; wrap it in a button for the account menu trigger.\n */\nexport function UserAvatar({ name, email, person, size = \"md\", badge, className, ...rest }: UserAvatarProps) {\n const locale = useKitLocale();\n const initials = (person ? personInitials(person, locale) : \"\") || avatarInitials(name, email);\n if (badge) {\n // A wrapper, because the chip itself is `aria-hidden` and the badge label must not\n // be. `className` stays on the chip (a size override still sizes the circle); the\n // other attributes go on the wrapper, which is what a caller addresses. `relative`\n // also contains the sr-only text.\n return (\n <span {...rest} className=\"relative inline-flex shrink-0\">\n <span\n aria-hidden\n className={cn(\n CHIP,\n AVATAR_SIZES[size],\n className,\n )}\n >\n {initials}\n </span>\n <StatusDot\n ring\n tone={badge.tone ?? \"danger\"}\n size={BADGE_SIZES[size]}\n className=\"absolute -end-0.5 -top-0.5\"\n />\n <span className=\"sr-only\">{badge.label}</span>\n </span>\n );\n }\n return (\n <span\n // `aria-hidden` sits BEFORE the spread, unlike the structural attributes on the\n // other components here, because it is a DEFAULT rather than an invariant. The\n // avatar is decorative next to the name it belongs to — which is where all three\n // apps render it — so hiding it stops a screen reader saying \"ME\" after the word\n // \"Marcel Eifert\". A caller who renders one ALONE (an assignee column, a\n // presence dot) needs the opposite, and now has it: `aria-hidden={false}` plus an\n // `aria-label` arrives through `...rest` and wins.\n aria-hidden\n {...rest}\n className={cn(\n CHIP,\n AVATAR_SIZES[size],\n className,\n )}\n >\n {initials}\n </span>\n );\n}\n"],"mappings":";AA2FM,SACE,KADF;AA1FN,SAAS,UAAU;AACnB,SAAS,sBAAsB;AAE/B,SAAS,oBAAoB;AAC7B,SAAS,iBAAiB;AAcnB,SAAS,eAAe,MAAsB,OAA+B;AAClF,QAAM,SAAS,CAAC,MAAM,KAAK,EAAE,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC,EAAE,KAAK,OAAO,KAAK;AACpE,QAAM,QAAQ,OAAO,MAAM,KAAK,EAAE,OAAO,OAAO;AAChD,MAAI,MAAM,UAAU,EAAG,SAAQ,MAAM,CAAC,EAAE,CAAC,IAAI,MAAM,CAAC,EAAE,CAAC,GAAG,YAAY;AACtE,SAAO,OAAO,MAAM,GAAG,CAAC,EAAE,YAAY;AACxC;AAEA,MAAM,eAAe;AAAA,EACnB,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AACN;AAEA,MAAM,OACJ;AAGF,MAAM,cAAgE,EAAE,IAAI,MAAM,IAAI,MAAM,IAAI,KAAK;AA8C9F,SAAS,WAAW,EAAE,MAAM,OAAO,QAAQ,OAAO,MAAM,OAAO,WAAW,GAAG,KAAK,GAAoB;AAC3G,QAAM,SAAS,aAAa;AAC5B,QAAM,YAAY,SAAS,eAAe,QAAQ,MAAM,IAAI,OAAO,eAAe,MAAM,KAAK;AAC7F,MAAI,OAAO;AAKT,WACE,qBAAC,UAAM,GAAG,MAAM,WAAU,iCACxB;AAAA;AAAA,QAAC;AAAA;AAAA,UACC,eAAW;AAAA,UACX,WAAW;AAAA,YACT;AAAA,YACA,aAAa,IAAI;AAAA,YACjB;AAAA,UACF;AAAA,UAEC;AAAA;AAAA,MACH;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,MAAI;AAAA,UACJ,MAAM,MAAM,QAAQ;AAAA,UACpB,MAAM,YAAY,IAAI;AAAA,UACtB,WAAU;AAAA;AAAA,MACZ;AAAA,MACA,oBAAC,UAAK,WAAU,WAAW,gBAAM,OAAM;AAAA,OACzC;AAAA,EAEJ;AACA,SACE;AAAA,IAAC;AAAA;AAAA,MAQC,eAAW;AAAA,MACV,GAAG;AAAA,MACJ,WAAW;AAAA,QACT;AAAA,QACA,aAAa,IAAI;AAAA,QACjB;AAAA,MACF;AAAA,MAEC;AAAA;AAAA,EACH;AAEJ;","names":[]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import 'react';
|
|
2
|
-
export { D as DEFAULT_ATTACHMENT_ACCEPT, e as DEFAULT_FEEDBACK_ATTACHMENT_LABELS, p as DEFAULT_MAX_ATTACHMENTS, q as DEFAULT_MAX_ATTACHMENT_BYTES, A as FeedbackAttachmentError, B as FeedbackAttachmentErrorInfo, E as FeedbackAttachmentField, G as FeedbackAttachmentFieldLabels, H as FeedbackAttachmentFieldMultipleProps, I as FeedbackAttachmentFieldProps, J as FeedbackAttachmentFieldRefsProps, K as FeedbackAttachmentFieldSingleProps, M as FeedbackAttachmentRef, N as FeedbackAttachmentRefsError, be as pastedName } from '../
|
|
2
|
+
export { D as DEFAULT_ATTACHMENT_ACCEPT, e as DEFAULT_FEEDBACK_ATTACHMENT_LABELS, p as DEFAULT_MAX_ATTACHMENTS, q as DEFAULT_MAX_ATTACHMENT_BYTES, A as FeedbackAttachmentError, B as FeedbackAttachmentErrorInfo, E as FeedbackAttachmentField, G as FeedbackAttachmentFieldLabels, H as FeedbackAttachmentFieldMultipleProps, I as FeedbackAttachmentFieldProps, J as FeedbackAttachmentFieldRefsProps, K as FeedbackAttachmentFieldSingleProps, M as FeedbackAttachmentRef, N as FeedbackAttachmentRefsError, be as pastedName } from '../register-form-V1OeNlMr.js';
|
|
3
3
|
import '../data-table-labels-DUELeXpa.js';
|
|
4
4
|
import '../components/data-table-sort.js';
|
|
5
5
|
import '../components/swipeable-row.js';
|
|
@@ -12,6 +12,7 @@ import '../components/field-sync.js';
|
|
|
12
12
|
import '../components/tooltip.js';
|
|
13
13
|
import '../hooks/use-anchored-rect.js';
|
|
14
14
|
import '../lib/clipping.js';
|
|
15
|
+
import '../components/field-parts.js';
|
|
15
16
|
import '../wizard/types.js';
|
|
16
17
|
import '../tour/tour.js';
|
|
17
18
|
import '../search/command-palette.js';
|
|
@@ -33,6 +34,7 @@ import '../components/modal.js';
|
|
|
33
34
|
import '../hooks/use-search-param-state.js';
|
|
34
35
|
import '../components/measured-grid.js';
|
|
35
36
|
import '../components/user-avatar.js';
|
|
37
|
+
import '../lib/person-name.js';
|
|
36
38
|
import '../components/status-dot.js';
|
|
37
39
|
import '../components/progress-bar.js';
|
|
38
40
|
import '../components/signed-amount.js';
|
|
@@ -52,6 +54,15 @@ import '../components/authed-image.js';
|
|
|
52
54
|
import '../components/image-grid.js';
|
|
53
55
|
import '../components/lightbox.js';
|
|
54
56
|
import '../components/write-lock.js';
|
|
57
|
+
import '../auth/sign-in-form.js';
|
|
58
|
+
import '../auth/complete-name-dialog.js';
|
|
59
|
+
import '../auth/forgot-password-form.js';
|
|
60
|
+
import '../auth/status-parts.js';
|
|
61
|
+
import '../auth/reset-password-form.js';
|
|
62
|
+
import '../auth/verify-email.js';
|
|
63
|
+
import '../auth/not-found-page.js';
|
|
64
|
+
import '../auth/accept-invitation.js';
|
|
65
|
+
import '../shell/company-switcher.js';
|
|
55
66
|
import '../components/account-chips.js';
|
|
56
67
|
import '../lib/format.js';
|
|
57
68
|
import '../components/reauth-dialog.js';
|
|
@@ -67,4 +78,9 @@ import '../components/sign-chip.js';
|
|
|
67
78
|
import '../components/column-mapper.js';
|
|
68
79
|
import '../lib/column-mapping.js';
|
|
69
80
|
import '../lib/table-text.js';
|
|
70
|
-
import '../
|
|
81
|
+
import '../shell/topbar-controls.js';
|
|
82
|
+
import '../theme/palette-presets.js';
|
|
83
|
+
import '../theme/chart-palette.js';
|
|
84
|
+
import '../theme/theme-store.js';
|
|
85
|
+
import 'zustand/middleware';
|
|
86
|
+
import 'zustand';
|