@wssto2/vue-core 0.12.1 → 0.13.1
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/CHANGELOG.md +33 -0
- package/README.md +4 -2
- package/dist/{AccessGate.vue_vue_type_script_setup_true_lang-CzQbD2Pc.js → AccessGate.vue_vue_type_script_setup_true_lang-DEzXovsY.js} +1 -1
- package/dist/{Activity-CdkJW68R.js → Activity-ChfxdvXf.js} +24 -23
- package/dist/{AdaptivePageShell.vue_vue_type_script_setup_true_lang-D5i77H6S.js → AdaptivePageShell.vue_vue_type_script_setup_true_lang-lPj9hPqV.js} +33 -33
- package/dist/{Changes-DxK_QfiB.js → Changes-BCa43_mO.js} +18 -17
- package/dist/{CollectionPage.vue_vue_type_script_setup_true_lang-x0jyJ01f.js → CollectionPage.vue_vue_type_script_setup_true_lang-C1GCvyZx.js} +6 -6
- package/dist/{DataTable.vue_vue_type_script_setup_true_lang-C_ZytnW-.js → DataTable.vue_vue_type_script_setup_true_lang-B9r9M5Gt.js} +1 -1
- package/dist/{DateField.vue_vue_type_script_setup_true_lang-CeNwBbJT.js → DateField.vue_vue_type_script_setup_true_lang-B5UUY1OO.js} +2 -2
- package/dist/{DeadLetters-DnA7LP1w.js → DeadLetters-wFTqhISU.js} +5 -5
- package/dist/{General-2matxl2Y.js → General-jW7u4MjH.js} +16 -15
- package/dist/{IncidentRecord-Bt3G4HlX.js → IncidentRecord-zTemLz2R.js} +6 -6
- package/dist/{IncidentsList-2iwgqp9J.js → IncidentsList-yu0xSMrH.js} +6 -6
- package/dist/{NewRolePage-DhGFwvk3.js → NewRolePage-CQ5UVaHs.js} +3 -3
- package/dist/{NumberField.vue_vue_type_script_setup_true_lang-B3UrXNqH.js → NumberField.vue_vue_type_script_setup_true_lang-YVgf5CP6.js} +1 -1
- package/dist/{PersonAccess.vue_vue_type_script_setup_true_lang-DbGZSNQc.js → PersonAccess.vue_vue_type_script_setup_true_lang-CWCt9_dM.js} +2 -2
- package/dist/{ProfilePage-CpuyDBAv.js → ProfilePage-Ca3x3UAH.js} +79 -77
- package/dist/{RecordHeader.vue_vue_type_script_setup_true_lang-DqGc3Jyo.js → RecordHeader.vue_vue_type_script_setup_true_lang-Do_ATJwT.js} +1 -1
- package/dist/{ResourcePage.vue_vue_type_script_setup_true_lang-DljhsTU4.js → ResourcePage.vue_vue_type_script_setup_true_lang-Coz91xht.js} +1 -1
- package/dist/{RoleEditor.vue_vue_type_script_setup_true_lang-C0FIotFA.js → RoleEditor.vue_vue_type_script_setup_true_lang-d_aaeXTT.js} +2 -2
- package/dist/{RolePage-DaNv049g.js → RolePage-BUj1w1m1.js} +5 -5
- package/dist/{RolesPage-6hlzJes_.js → RolesPage-NKzBUsrM.js} +3 -3
- package/dist/{SectionNavigator.vue_vue_type_script_setup_true_lang-Dh3sXUt_.js → SectionNavigator.vue_vue_type_script_setup_true_lang-DfKEhTFv.js} +2 -2
- package/dist/{ServiceAccountDialog.vue_vue_type_script_setup_true_lang-FJbWxME_.js → ServiceAccountDialog.vue_vue_type_script_setup_true_lang-4nbhEpv_.js} +10 -9
- package/dist/{ServiceAccountRecord-0-JF5lRx.js → ServiceAccountRecord-ClbyeLhL.js} +8 -8
- package/dist/{ServiceAccountsList-DcsnOcf-.js → ServiceAccountsList-B2VDnYxD.js} +5 -5
- package/dist/{Sessions-DgWhpk-i.js → Sessions-BjkciyHH.js} +23 -21
- package/dist/{SettingsPage-BXPWATYU.js → SettingsPage-Csb14qsx.js} +7 -7
- package/dist/{SignIn-DPoUwHZd.js → SignIn-DPFMv4C7.js} +14 -12
- package/dist/{SignInPage-OyrVemro.js → SignInPage-DukoFqkt.js} +2 -2
- package/dist/{SignIns-BMDrZVVp.js → SignIns-DvdpNkiS.js} +23 -22
- package/dist/{TimeField.vue_vue_type_script_setup_true_lang-D-Em4glH.js → TimeField.vue_vue_type_script_setup_true_lang-DpDXHH7u.js} +2 -2
- package/dist/{Timestamp.vue_vue_type_script_setup_true_lang-ClZAAUMd.js → Timestamp.vue_vue_type_script_setup_true_lang-DlEUKWra.js} +1 -1
- package/dist/{UserRecord-BW-gdCqi.js → UserRecord-B9SeSWQh.js} +57 -55
- package/dist/{UsersList-B3ZF_1Dj.js → UsersList-CREG8q3l.js} +4 -4
- package/dist/access/index.js +4 -4
- package/dist/app/application.d.ts +14 -6
- package/dist/app/current.d.ts +11 -0
- package/dist/app/environment.d.ts +8 -0
- package/dist/app/index.d.ts +1 -0
- package/dist/app/index.js +14 -12
- package/dist/application-DomS6sbx.js +435 -0
- package/dist/collection/http.d.ts +16 -1
- package/dist/collection/index.d.ts +1 -1
- package/dist/collection/index.js +34 -32
- package/dist/content/Money.vue.d.ts +1 -1
- package/dist/content/index.js +151 -158
- package/dist/{contributions-CeG4bszd.js → contributions-obnyn03x.js} +1 -1
- package/dist/current-B0lHKTWr.js +17 -0
- package/dist/form/DateField.vue.d.ts +2 -2
- package/dist/form/DateTimeField.vue.d.ts +2 -2
- package/dist/form/MoneyField.vue.d.ts +1 -1
- package/dist/form/NumberField.vue.d.ts +1 -1
- package/dist/form/date/MonthYearPanel.vue.d.ts +1 -1
- package/dist/form/date/days.d.ts +3 -3
- package/dist/form/index.d.ts +2 -0
- package/dist/form/index.js +1111 -1081
- package/dist/form/zodErrorMap.d.ts +35 -0
- package/dist/format/format.d.ts +51 -6
- package/dist/format/index.d.ts +1 -1
- package/dist/format/index.js +1 -1
- package/dist/format-DoKs29bZ.js +118 -0
- package/dist/{guards-Biv_SlGn.js → guards-DGcSfTEh.js} +1 -1
- package/dist/http-DOEfFCDA.js +107 -0
- package/dist/i18n/index.js +15 -15
- package/dist/identity/index.d.ts +2 -0
- package/dist/identity/index.js +43 -40
- package/dist/identity/usePreferences.d.ts +19 -0
- package/dist/incidents/clientErrorReporter.d.ts +2 -1
- package/dist/incidents/index.js +1 -1
- package/dist/{index-kEHY7hcG.js → index-Be9Q1PB_.js} +78 -76
- package/dist/{index-Cq9TuOqH.js → index-DZikGJ8L.js} +457 -511
- package/dist/{index-ClJeyW3F.js → index-D_yyd4C2.js} +4 -4
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/internal/intlLocale.d.ts +5 -2
- package/dist/modules/identity/entities.d.ts +4 -0
- package/dist/modules/identity/routes.d.ts +5 -2
- package/dist/modules/identity/schemas.d.ts +6 -2
- package/dist/modules/incident/routes.d.ts +2 -0
- package/dist/modules/incident/schemas.d.ts +2 -0
- package/dist/{navigation-TnVFYRaX.js → navigation-CctcxT51.js} +1 -1
- package/dist/{neighbors-OyvGi233.js → neighbors-Csfan8Ho.js} +1 -1
- package/dist/notifications/index.js +1 -1
- package/dist/onboarding/Tip.vue.d.ts +41 -0
- package/dist/onboarding/index.d.ts +1 -0
- package/dist/onboarding/index.js +145 -0
- package/dist/onboarding/tips.d.ts +5 -0
- package/dist/page/index.js +3 -3
- package/dist/phone/index.js +74 -74
- package/dist/phone/phone.d.ts +3 -3
- package/dist/platform/httpSession.d.ts +1 -1
- package/dist/platform/index.d.ts +2 -0
- package/dist/platform/index.js +16 -13
- package/dist/platform/preferences.d.ts +35 -0
- package/dist/platform/session.d.ts +6 -1
- package/dist/platform-DtISOEt7.js +284 -0
- package/dist/playwright/session.d.ts +2 -0
- package/dist/preferences-hYhrw8Uy.js +91 -0
- package/dist/resource/index.d.ts +1 -0
- package/dist/resource/index.js +24 -8
- package/dist/resource/read.d.ts +16 -0
- package/dist/router/index.js +3 -3
- package/dist/{rowLayout-BsKEzEME.js → rowLayout-y1IB_h2r.js} +2 -2
- package/dist/{sections-CvUwZ-S1.js → sections-fkW_IJLc.js} +1 -1
- package/dist/{serverMessages-B6GHgi40.js → serverMessages-Ddghrewh.js} +1 -1
- package/dist/shell/darkMode.d.ts +13 -8
- package/dist/shell/index.js +396 -384
- package/dist/{state-6KSYsVw0.js → state-CXMexi0l.js} +1 -1
- package/dist/styles.css +1 -1
- package/dist/testing/app.d.ts +11 -0
- package/dist/testing/format.d.ts +4 -2
- package/dist/testing/index.d.ts +1 -1
- package/dist/testing/index.js +96 -89
- package/dist/testing/platform.d.ts +2 -0
- package/dist/usePreferences-B8LIZp_f.js +47 -0
- package/dist/{useTypedEntry-C_Bk4sI0.js → useTypedEntry-DKs8I1yP.js} +279 -280
- package/package.json +6 -2
- package/src/styles/components.css +17 -0
- package/dist/application-CuzT-0vW.js +0 -420
- package/dist/format-D8KUBmbS.js +0 -87
- package/dist/http-Dm0uXY9O.js +0 -95
- package/dist/intlLocale-CeRU44qJ.js +0 -4
- package/dist/platform-BQOX_Ntw.js +0 -283
package/dist/form/index.js
CHANGED
|
@@ -1,58 +1,57 @@
|
|
|
1
|
-
import { a as
|
|
2
|
-
import { E as
|
|
3
|
-
import { f as
|
|
4
|
-
import { _ as
|
|
5
|
-
import { ref as P, computed as h, defineComponent as
|
|
6
|
-
import { a as
|
|
7
|
-
import { M as
|
|
8
|
-
import { _ as
|
|
9
|
-
import { u as
|
|
10
|
-
import { _ as
|
|
11
|
-
import { u as
|
|
12
|
-
import { d as
|
|
1
|
+
import { a as ot, _ as We, c as nt, f as st } from "../FormGroup.vue_vue_type_script_setup_true_lang-D6jYfNjW.js";
|
|
2
|
+
import { E as Bo, b as Lo, d as To, p as qo, r as zo, u as Vo, e as Do, g as Ro } from "../FormGroup.vue_vue_type_script_setup_true_lang-D6jYfNjW.js";
|
|
3
|
+
import { f as qe } from "../useCommand-Ch_nx1AQ.js";
|
|
4
|
+
import { _ as Io, a as jo, u as Oo } from "../useCommand-Ch_nx1AQ.js";
|
|
5
|
+
import { ref as P, computed as h, defineComponent as G, openBlock as d, createBlock as R, mergeProps as J, unref as s, createSlots as Z, withCtx as f, createElementVNode as p, normalizeClass as j, createElementBlock as y, Fragment as de, renderList as $e, createVNode as I, createCommentVNode as q, toDisplayString as C, renderSlot as S, mergeDefaults as ce, useModel as re, useId as Re, withKeys as Se, withModifiers as pe, createTextVNode as H, mergeModels as le, useTemplateRef as U, shallowRef as Ne, watch as ge, normalizeProps as ze, guardReactiveProps as Ve, nextTick as xe, provide as rt, inject as Je, onBeforeUnmount as Ze, getCurrentScope as it, onScopeDispose as ut, toValue as dt, shallowReactive as Ae, normalizeStyle as ct, resolveDynamicComponent as ft } from "vue";
|
|
6
|
+
import { a as Xe } from "../leaveGuard-Cc8yeLxM.js";
|
|
7
|
+
import { M as No, c as Ao, i as Go, l as Ko, u as Po } from "../leaveGuard-Cc8yeLxM.js";
|
|
8
|
+
import { _ as Uo } from "../LeaveGuardRoot.vue_vue_type_script_setup_true_lang-CIwW7y4j.js";
|
|
9
|
+
import { u as Wo } from "../useResourceForm-Dl6YFYyz.js";
|
|
10
|
+
import { _ as X } from "../Icon.vue_vue_type_script_lang-BhhsFYwp.js";
|
|
11
|
+
import { u as Qe, _ as ye, f as fe, b as me, a as et, e as Me, g as mt, j as vt, k as pt } from "../options-B48UiYsG.js";
|
|
12
|
+
import { d as Zo, h as Xo, m as Qo } from "../options-B48UiYsG.js";
|
|
13
13
|
import { useI18n as oe } from "vue-i18n";
|
|
14
|
-
import { b as
|
|
15
|
-
import { a as
|
|
16
|
-
import { _ as
|
|
17
|
-
import { u as
|
|
18
|
-
import { r as
|
|
19
|
-
import { s as
|
|
20
|
-
import { u as
|
|
21
|
-
import { _ as
|
|
22
|
-
import { _ as
|
|
23
|
-
import { u as
|
|
24
|
-
import { u as
|
|
14
|
+
import { b as bt } from "../controlSurface-t7OEFESJ.js";
|
|
15
|
+
import { a as gt } from "../TextField.vue_vue_type_script_setup_true_lang-CWIeeZRE.js";
|
|
16
|
+
import { _ as tn } from "../TextField.vue_vue_type_script_setup_true_lang-CWIeeZRE.js";
|
|
17
|
+
import { u as yt, l as ht } from "../suggestions-q_v3M7G6.js";
|
|
18
|
+
import { r as ln } from "../suggestions-q_v3M7G6.js";
|
|
19
|
+
import { s as _e, u as Ge, i as kt, o as Ce, e as Fe, k as xt, _ as wt, l as $t, c as _t, b as Ct, t as Te, g as St, q as Ft } from "../useTypedEntry-DKs8I1yP.js";
|
|
20
|
+
import { u as Bt, a as Lt, s as Tt } from "../DateField.vue_vue_type_script_setup_true_lang-B5UUY1OO.js";
|
|
21
|
+
import { _ as nn } from "../DateField.vue_vue_type_script_setup_true_lang-B5UUY1OO.js";
|
|
22
|
+
import { _ as tt } from "../DateButton.vue_vue_type_script_setup_true_lang-CovKG5lN.js";
|
|
23
|
+
import { u as at } from "../format-DoKs29bZ.js";
|
|
24
|
+
import { u as Ie } from "../mediaQuery-CygcXmFW.js";
|
|
25
25
|
import { _ as je } from "../Popover.vue_vue_type_script_setup_true_lang-C20Hf3Hl.js";
|
|
26
|
-
import { u as
|
|
27
|
-
import { _ as
|
|
26
|
+
import { u as qt } from "../TimeField.vue_vue_type_script_setup_true_lang-DpDXHH7u.js";
|
|
27
|
+
import { _ as rn } from "../TimeField.vue_vue_type_script_setup_true_lang-DpDXHH7u.js";
|
|
28
28
|
import { _ as be } from "../Button.vue_vue_type_script_setup_true_lang-C74hcb0N.js";
|
|
29
|
-
import { _ as
|
|
30
|
-
import { i as Tt } from "../intlLocale-CeRU44qJ.js";
|
|
29
|
+
import { _ as dn } from "../FormView.vue_vue_type_script_setup_true_lang-DvbPEiNQ.js";
|
|
31
30
|
import { a as zt } from "../environment-Dva-SG8D.js";
|
|
32
|
-
import { _ as Vt } from "../NumberField.vue_vue_type_script_setup_true_lang-
|
|
33
|
-
import { _ as
|
|
34
|
-
import { b as
|
|
35
|
-
import { _ as
|
|
36
|
-
import { _ as
|
|
37
|
-
import { _ as
|
|
38
|
-
import { _ as
|
|
39
|
-
import { _ as
|
|
40
|
-
import { _ as
|
|
41
|
-
import { _ as
|
|
42
|
-
import { _ as
|
|
43
|
-
import { p as
|
|
44
|
-
import { u as
|
|
45
|
-
import { u as
|
|
46
|
-
import { matchedRouteKey as
|
|
47
|
-
function
|
|
31
|
+
import { _ as Vt } from "../NumberField.vue_vue_type_script_setup_true_lang-YVgf5CP6.js";
|
|
32
|
+
import { _ as Dt } from "../Sheet.vue_vue_type_script_setup_true_lang-B91aRD_y.js";
|
|
33
|
+
import { b as Rt, a as Ke } from "../SelectField.vue_vue_type_script_setup_true_lang-BZwdANL3.js";
|
|
34
|
+
import { _ as fn, u as mn } from "../SelectField.vue_vue_type_script_setup_true_lang-BZwdANL3.js";
|
|
35
|
+
import { _ as pn, b as bn, a as gn, u as yn } from "../useGroupSheet-CPjHydQV.js";
|
|
36
|
+
import { _ as Pe } from "../PhotoViewer.vue_vue_type_script_setup_true_lang-Bqxj_uJ5.js";
|
|
37
|
+
import { _ as kn } from "../SegmentedField.vue_vue_type_script_setup_true_lang-zv_AxpBn.js";
|
|
38
|
+
import { _ as wn } from "../SwitchField.vue_vue_type_script_setup_true_lang-Ds4q0bbl.js";
|
|
39
|
+
import { _ as _n } from "../TextareaField.vue_vue_type_script_setup_true_lang-D2j4s96s.js";
|
|
40
|
+
import { _ as Mt } from "../AdaptivePageShell.vue_vue_type_script_setup_true_lang-lPj9hPqV.js";
|
|
41
|
+
import { _ as It, a as jt } from "../SectionList.vue_vue_type_script_setup_true_lang-DR0_NsqC.js";
|
|
42
|
+
import { p as Ot } from "../sectionIndex-BS0ic5W7.js";
|
|
43
|
+
import { u as Et } from "../useSaveChrome-7huA3FzR.js";
|
|
44
|
+
import { u as Sn } from "../useRecordDialog-DdkauXnU.js";
|
|
45
|
+
import { matchedRouteKey as Nt, onBeforeRouteLeave as At } from "vue-router";
|
|
46
|
+
function Gt(l) {
|
|
48
47
|
const a = P(null);
|
|
49
48
|
return {
|
|
50
|
-
isDirty: h(() => a.value !== null && JSON.stringify(
|
|
51
|
-
markClean: () => a.value = JSON.stringify(
|
|
49
|
+
isDirty: h(() => a.value !== null && JSON.stringify(l()) !== a.value),
|
|
50
|
+
markClean: () => a.value = JSON.stringify(l())
|
|
52
51
|
};
|
|
53
52
|
}
|
|
54
|
-
function no(
|
|
55
|
-
const a = P(!1), e =
|
|
53
|
+
function no(l) {
|
|
54
|
+
const a = P(!1), e = Gt(l), { confirmDiscard: t } = Xe(() => a.value && e.isDirty.value);
|
|
56
55
|
return {
|
|
57
56
|
/** The sheet was just filled: its current values are the baseline. */
|
|
58
57
|
opened: () => {
|
|
@@ -65,16 +64,46 @@ function no(o) {
|
|
|
65
64
|
beforeDismiss: t
|
|
66
65
|
};
|
|
67
66
|
}
|
|
68
|
-
const
|
|
67
|
+
const He = (l, a) => {
|
|
68
|
+
const e = Number(a);
|
|
69
|
+
if (Number.isInteger(e) && Math.abs(e) < 1e4) return String(e);
|
|
70
|
+
const t = Number.isInteger(e) ? 0 : 2;
|
|
71
|
+
return l.number(e, { minimumFractionDigits: t, maximumFractionDigits: t });
|
|
72
|
+
};
|
|
73
|
+
function so({ i18n: l, format: a }) {
|
|
74
|
+
const { t: e, te: t } = l.global, o = (r) => `validation_errors.${r}`, n = (r) => `core.validation_errors.${r}`, u = (r, m) => ({ message: e(t(o(r)) ? o(r) : n(r), m) });
|
|
75
|
+
return (r) => {
|
|
76
|
+
switch (r.code) {
|
|
77
|
+
case "invalid_type":
|
|
78
|
+
return u("required");
|
|
79
|
+
case "too_small":
|
|
80
|
+
return r.origin === "string" ? Number(r.minimum) === 1 ? u("required") : u("min", { min: Number(r.minimum) }) : r.origin === "number" ? u("min_value", { min: He(a, r.minimum) }) : void 0;
|
|
81
|
+
case "too_big":
|
|
82
|
+
return r.origin === "string" ? u("max", { max: Number(r.maximum) }) : r.origin === "number" ? u("max_value", { max: He(a, r.maximum) }) : void 0;
|
|
83
|
+
case "invalid_format":
|
|
84
|
+
return r.format !== void 0 && ["email", "url", "date", "datetime"].includes(r.format) ? u(r.format) : void 0;
|
|
85
|
+
case "custom": {
|
|
86
|
+
const m = r.params?.code;
|
|
87
|
+
if (typeof m != "string") return;
|
|
88
|
+
if (m === "required") return u("required");
|
|
89
|
+
const k = t(o(m)) ? o(m) : t(n(m)) ? n(m) : null;
|
|
90
|
+
return k === null ? void 0 : { message: e(k) };
|
|
91
|
+
}
|
|
92
|
+
default:
|
|
93
|
+
return;
|
|
94
|
+
}
|
|
95
|
+
};
|
|
96
|
+
}
|
|
97
|
+
const Kt = ["id", "aria-label", "aria-describedby", "aria-invalid"], Pt = ["name", "value", "checked", "disabled", "onChange"], Ht = { class: "min-w-0 flex-1" }, Ut = { class: "block text-body font-semibold text-content-strong" }, Yt = {
|
|
69
98
|
key: 0,
|
|
70
99
|
class: "mt-0.5 block text-footnote text-content-muted"
|
|
71
|
-
},
|
|
100
|
+
}, Wt = {
|
|
72
101
|
key: 1,
|
|
73
102
|
class: "flex size-5 shrink-0 items-center justify-center rounded-full bg-control-on text-white",
|
|
74
103
|
"aria-hidden": "true"
|
|
75
|
-
},
|
|
104
|
+
}, ro = /* @__PURE__ */ G({
|
|
76
105
|
__name: "CardSelectField",
|
|
77
|
-
props: /* @__PURE__ */
|
|
106
|
+
props: /* @__PURE__ */ ce({
|
|
78
107
|
label: {},
|
|
79
108
|
labelHidden: { type: Boolean },
|
|
80
109
|
hint: {},
|
|
@@ -88,88 +117,88 @@ const Gt = ["id", "aria-label", "aria-describedby", "aria-invalid"], Kt = ["name
|
|
|
88
117
|
modelValue: {},
|
|
89
118
|
options: {},
|
|
90
119
|
columns: {}
|
|
91
|
-
}, { ...
|
|
120
|
+
}, { ...me, modelValue: null, columns: 2 }),
|
|
92
121
|
emits: ["update:modelValue"],
|
|
93
|
-
setup(
|
|
94
|
-
const e =
|
|
95
|
-
return (
|
|
122
|
+
setup(l, { emit: a }) {
|
|
123
|
+
const e = l, t = a, { editable: o } = Qe(e), n = { 1: "grid-cols-1", 2: "grid-cols-2", 3: "grid-cols-3", 4: "grid-cols-4" }, u = h(() => n[e.columns]);
|
|
124
|
+
return (r, m) => (d(), R(ye, J(s(fe)(e), {
|
|
96
125
|
value: e.options.find((k) => k.value === e.modelValue)?.label ?? null,
|
|
97
126
|
"row-layout": "stacked"
|
|
98
|
-
}),
|
|
99
|
-
default: f(({ id: k, describedby:
|
|
100
|
-
|
|
127
|
+
}), Z({
|
|
128
|
+
default: f(({ id: k, describedby: x, invalid: $ }) => [
|
|
129
|
+
p("div", {
|
|
101
130
|
id: k,
|
|
102
131
|
role: "radiogroup",
|
|
103
132
|
"aria-label": e.label,
|
|
104
|
-
"aria-describedby":
|
|
133
|
+
"aria-describedby": x,
|
|
105
134
|
"aria-invalid": $ || void 0,
|
|
106
|
-
class:
|
|
135
|
+
class: j(["grid w-full gap-2.5", u.value]),
|
|
107
136
|
"data-test": "card-select"
|
|
108
137
|
}, [
|
|
109
|
-
(
|
|
110
|
-
key:
|
|
111
|
-
class:
|
|
138
|
+
(d(!0), y(de, null, $e(e.options, (i) => (d(), y("label", {
|
|
139
|
+
key: i.value,
|
|
140
|
+
class: j(["relative flex items-center gap-3 rounded-group bg-fill p-3.5 transition-colors duration-motion-fast focus-within:outline-2 focus-within:outline-offset-2 focus-within:outline-border-focus", [i.value === e.modelValue ? "bg-tint-soft ring-[1.5px] ring-inset ring-border-selected" : "hover:bg-fill-strong", e.disabled || !s(o) || i.disabled ? "cursor-not-allowed opacity-60" : "cursor-pointer"]])
|
|
112
141
|
}, [
|
|
113
|
-
|
|
142
|
+
p("input", {
|
|
114
143
|
type: "radio",
|
|
115
144
|
class: "sr-only",
|
|
116
145
|
name: e.name ?? k,
|
|
117
|
-
value:
|
|
118
|
-
checked:
|
|
119
|
-
disabled: e.disabled || !
|
|
120
|
-
onChange: (
|
|
121
|
-
}, null, 40,
|
|
122
|
-
|
|
146
|
+
value: i.value,
|
|
147
|
+
checked: i.value === e.modelValue,
|
|
148
|
+
disabled: e.disabled || !s(o) || i.disabled,
|
|
149
|
+
onChange: (v) => t("update:modelValue", i.value)
|
|
150
|
+
}, null, 40, Pt),
|
|
151
|
+
i.icon ? (d(), y("span", {
|
|
123
152
|
key: 0,
|
|
124
|
-
class:
|
|
153
|
+
class: j(["flex size-9 shrink-0 items-center justify-center rounded-control", i.value === e.modelValue ? "bg-control-on text-white" : "bg-fill-strong text-content-muted"])
|
|
125
154
|
}, [
|
|
126
|
-
|
|
127
|
-
name:
|
|
155
|
+
I(s(X), {
|
|
156
|
+
name: i.icon,
|
|
128
157
|
size: 18
|
|
129
158
|
}, null, 8, ["name"])
|
|
130
|
-
], 2)) :
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
159
|
+
], 2)) : q("", !0),
|
|
160
|
+
p("span", Ht, [
|
|
161
|
+
p("span", Ut, C(i.label), 1),
|
|
162
|
+
i.description ? (d(), y("span", Yt, C(i.description), 1)) : q("", !0)
|
|
134
163
|
]),
|
|
135
|
-
|
|
136
|
-
|
|
164
|
+
i.value === e.modelValue ? (d(), y("span", Wt, [
|
|
165
|
+
I(s(X), {
|
|
137
166
|
name: "checkCustom",
|
|
138
167
|
size: 12
|
|
139
168
|
})
|
|
140
|
-
])) :
|
|
169
|
+
])) : q("", !0)
|
|
141
170
|
], 2))), 128))
|
|
142
|
-
], 10,
|
|
171
|
+
], 10, Kt)
|
|
143
172
|
]),
|
|
144
173
|
_: 2
|
|
145
174
|
}, [
|
|
146
|
-
|
|
175
|
+
r.$slots.trailing ? {
|
|
147
176
|
name: "trailing",
|
|
148
177
|
fn: f(() => [
|
|
149
|
-
|
|
178
|
+
S(r.$slots, "trailing")
|
|
150
179
|
]),
|
|
151
180
|
key: "0"
|
|
152
181
|
} : void 0,
|
|
153
|
-
|
|
182
|
+
r.$slots.labelTrailing ? {
|
|
154
183
|
name: "labelTrailing",
|
|
155
184
|
fn: f(() => [
|
|
156
|
-
|
|
185
|
+
S(r.$slots, "labelTrailing")
|
|
157
186
|
]),
|
|
158
187
|
key: "1"
|
|
159
188
|
} : void 0,
|
|
160
|
-
|
|
189
|
+
r.$slots.readonly ? {
|
|
161
190
|
name: "readonly",
|
|
162
191
|
fn: f(() => [
|
|
163
|
-
|
|
192
|
+
S(r.$slots, "readonly")
|
|
164
193
|
]),
|
|
165
194
|
key: "2"
|
|
166
195
|
} : void 0
|
|
167
196
|
]), 1040, ["value"]));
|
|
168
197
|
}
|
|
169
|
-
}),
|
|
198
|
+
}), Jt = ["data-field-error"], Zt = ["aria-checked", "aria-disabled", "aria-describedby", "aria-invalid", "tabindex", "onKeydown"], Xt = { class: "flex min-w-0 flex-1 flex-col items-start" }, Qt = {
|
|
170
199
|
key: 0,
|
|
171
200
|
class: "flex shrink-0 items-center gap-2.5"
|
|
172
|
-
},
|
|
201
|
+
}, ea = ["id"], io = /* @__PURE__ */ G({
|
|
173
202
|
__name: "CheckboxField",
|
|
174
203
|
props: /* @__PURE__ */ le({
|
|
175
204
|
label: {},
|
|
@@ -182,77 +211,77 @@ const Gt = ["id", "aria-label", "aria-describedby", "aria-invalid"], Kt = ["name
|
|
|
182
211
|
modelModifiers: {}
|
|
183
212
|
}),
|
|
184
213
|
emits: ["update:modelValue"],
|
|
185
|
-
setup(
|
|
186
|
-
const a =
|
|
214
|
+
setup(l) {
|
|
215
|
+
const a = l, e = re(l, "modelValue"), t = !!et(), o = Re(), n = () => {
|
|
187
216
|
a.disabled || (e.value = !e.value);
|
|
188
217
|
};
|
|
189
|
-
return (
|
|
218
|
+
return (u, r) => (d(), y("div", {
|
|
190
219
|
"data-field-error": a.error ? "true" : void 0
|
|
191
220
|
}, [
|
|
192
|
-
|
|
221
|
+
p("div", {
|
|
193
222
|
role: "checkbox",
|
|
194
223
|
"aria-checked": e.value,
|
|
195
224
|
"aria-disabled": a.disabled || void 0,
|
|
196
|
-
"aria-describedby": a.error ? `${
|
|
225
|
+
"aria-describedby": a.error ? `${s(o)}-error` : void 0,
|
|
197
226
|
"aria-invalid": a.error ? !0 : void 0,
|
|
198
227
|
tabindex: a.disabled ? -1 : 0,
|
|
199
228
|
"data-test": "checkbox",
|
|
200
|
-
class:
|
|
229
|
+
class: j(["group/check flex items-center transition-colors duration-motion-fast focus-visible:outline-2 focus-visible:outline-border-focus", [a.variant === "row" ? "gap-3 pl-row-inset focus-visible:-outline-offset-2" : "gap-2.5 rounded-control px-2 py-1.5 focus-visible:outline-offset-1", t && a.variant === "row" ? "first:rounded-t-group last:rounded-b-group" : "", a.disabled ? "cursor-not-allowed" : a.variant === "row" ? "cursor-pointer hover:bg-fill/60 active:bg-fill" : "cursor-pointer hover:bg-fill"]]),
|
|
201
230
|
onClick: n,
|
|
202
231
|
onKeydown: [
|
|
203
|
-
|
|
204
|
-
|
|
232
|
+
Se(pe(n, ["prevent"]), ["space"]),
|
|
233
|
+
Se(pe(n, ["prevent"]), ["enter"])
|
|
205
234
|
]
|
|
206
235
|
}, [
|
|
207
|
-
|
|
208
|
-
class:
|
|
236
|
+
p("span", {
|
|
237
|
+
class: j(["flex shrink-0 items-center justify-center rounded-full border-2", [a.variant === "row" ? "size-5.5" : "size-5", e.value ? a.disabled ? "border-content-disabled bg-content-disabled text-white" : "border-control-on bg-control-on text-white" : "border-border-control"]]),
|
|
209
238
|
"aria-hidden": "true"
|
|
210
239
|
}, [
|
|
211
|
-
e.value ? (
|
|
240
|
+
e.value ? (d(), R(s(X), {
|
|
212
241
|
key: 0,
|
|
213
242
|
name: "checkCustom",
|
|
214
243
|
size: 12
|
|
215
|
-
})) :
|
|
244
|
+
})) : q("", !0)
|
|
216
245
|
], 2),
|
|
217
|
-
|
|
218
|
-
class:
|
|
246
|
+
p("div", {
|
|
247
|
+
class: j(["flex min-w-0 flex-1 items-center gap-3", a.variant === "row" ? "min-h-row border-t border-border-separator py-2 pr-row-inset group-first/check:border-t-0" : ""])
|
|
219
248
|
}, [
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
class:
|
|
223
|
-
},
|
|
224
|
-
a.description ? (
|
|
249
|
+
p("div", Xt, [
|
|
250
|
+
p("p", {
|
|
251
|
+
class: j(["w-full text-body", [a.variant === "row" ? "break-words" : "truncate", a.disabled ? "text-content-muted" : e.value ? "text-content-strong" : "text-content"]])
|
|
252
|
+
}, C(a.label), 3),
|
|
253
|
+
a.description ? (d(), y("p", {
|
|
225
254
|
key: 0,
|
|
226
|
-
class:
|
|
227
|
-
},
|
|
228
|
-
|
|
255
|
+
class: j(["tabular-nums text-content-muted", a.variant === "row" ? "text-footnote" : "text-xs"])
|
|
256
|
+
}, C(a.description), 3)) : q("", !0),
|
|
257
|
+
S(u.$slots, "default")
|
|
229
258
|
]),
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
])) :
|
|
259
|
+
u.$slots.trailing ? (d(), y("div", Qt, [
|
|
260
|
+
S(u.$slots, "trailing")
|
|
261
|
+
])) : q("", !0)
|
|
233
262
|
], 2)
|
|
234
|
-
], 42,
|
|
235
|
-
a.error ? (
|
|
263
|
+
], 42, Zt),
|
|
264
|
+
a.error ? (d(), y("p", {
|
|
236
265
|
key: 0,
|
|
237
|
-
id: `${
|
|
266
|
+
id: `${s(o)}-error`,
|
|
238
267
|
role: "alert",
|
|
239
268
|
class: "flex items-start gap-1.5 px-2 pt-1 text-footnote text-content-destructive"
|
|
240
269
|
}, [
|
|
241
|
-
|
|
270
|
+
I(s(X), {
|
|
242
271
|
name: "alertTriangle",
|
|
243
272
|
size: 14,
|
|
244
273
|
class: "mt-px shrink-0"
|
|
245
274
|
}),
|
|
246
|
-
H(" " +
|
|
247
|
-
], 8,
|
|
248
|
-
], 8,
|
|
275
|
+
H(" " + C(a.error), 1)
|
|
276
|
+
], 8, ea)) : q("", !0)
|
|
277
|
+
], 8, Jt));
|
|
249
278
|
}
|
|
250
|
-
}),
|
|
279
|
+
}), ta = {
|
|
251
280
|
key: 0,
|
|
252
281
|
class: "text-body text-content-muted"
|
|
253
|
-
},
|
|
282
|
+
}, aa = ["id", "aria-label", "aria-describedby", "aria-invalid"], la = ["aria-pressed", "disabled", "onClick"], uo = /* @__PURE__ */ G({
|
|
254
283
|
__name: "ChoiceChips",
|
|
255
|
-
props: /* @__PURE__ */ le(/* @__PURE__ */
|
|
284
|
+
props: /* @__PURE__ */ le(/* @__PURE__ */ ce({
|
|
256
285
|
label: {},
|
|
257
286
|
labelHidden: { type: Boolean },
|
|
258
287
|
hint: {},
|
|
@@ -264,77 +293,77 @@ const Gt = ["id", "aria-label", "aria-describedby", "aria-invalid"], Kt = ["name
|
|
|
264
293
|
presentation: {},
|
|
265
294
|
name: {},
|
|
266
295
|
options: {}
|
|
267
|
-
}, { ...
|
|
296
|
+
}, { ...me }), {
|
|
268
297
|
modelValue: { default: () => [] },
|
|
269
298
|
modelModifiers: {}
|
|
270
299
|
}),
|
|
271
300
|
emits: ["update:modelValue"],
|
|
272
|
-
setup(
|
|
273
|
-
const a =
|
|
274
|
-
return (
|
|
275
|
-
value: a.options.filter((
|
|
301
|
+
setup(l) {
|
|
302
|
+
const a = l, e = re(l, "modelValue"), t = (o) => e.value = e.value.includes(o) ? e.value.filter((n) => n !== o) : [...e.value, o];
|
|
303
|
+
return (o, n) => (d(), R(ye, J(s(fe)(a), {
|
|
304
|
+
value: a.options.filter((u) => e.value.includes(u.value)).map((u) => u.label).join(", ") || null,
|
|
276
305
|
"row-layout": "stacked"
|
|
277
|
-
}),
|
|
278
|
-
default: f(({ id:
|
|
279
|
-
a.options.length === 0 ? (
|
|
306
|
+
}), Z({
|
|
307
|
+
default: f(({ id: u, describedby: r, invalid: m }) => [
|
|
308
|
+
a.options.length === 0 ? (d(), y("span", ta, "—")) : (d(), y("div", {
|
|
280
309
|
key: 1,
|
|
281
|
-
id:
|
|
310
|
+
id: u,
|
|
282
311
|
role: "group",
|
|
283
312
|
"aria-label": a.label,
|
|
284
|
-
"aria-describedby":
|
|
285
|
-
"aria-invalid":
|
|
313
|
+
"aria-describedby": r,
|
|
314
|
+
"aria-invalid": m || void 0,
|
|
286
315
|
class: "flex flex-wrap gap-1.5 py-1",
|
|
287
316
|
"data-test": "choice-chips"
|
|
288
317
|
}, [
|
|
289
|
-
(
|
|
318
|
+
(d(!0), y(de, null, $e(a.options, (k) => (d(), y("button", {
|
|
290
319
|
key: k.value,
|
|
291
320
|
type: "button",
|
|
292
321
|
"aria-pressed": e.value.includes(k.value),
|
|
293
322
|
disabled: a.disabled || k.disabled,
|
|
294
|
-
class:
|
|
295
|
-
onClick: (
|
|
323
|
+
class: j(["inline-flex min-h-8 cursor-pointer items-center gap-1.5 rounded-full px-3 text-subheadline transition-colors duration-motion-fast focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-border-focus disabled:cursor-not-allowed disabled:opacity-60", e.value.includes(k.value) ? "bg-tint-soft font-semibold text-content-link" : "bg-fill font-medium text-content-strong hover:bg-fill-strong"]),
|
|
324
|
+
onClick: (x) => t(k.value)
|
|
296
325
|
}, [
|
|
297
|
-
e.value.includes(k.value) ? (
|
|
326
|
+
e.value.includes(k.value) ? (d(), R(s(X), {
|
|
298
327
|
key: 0,
|
|
299
328
|
name: "checkCustom",
|
|
300
329
|
size: 12
|
|
301
|
-
})) :
|
|
302
|
-
H(" " +
|
|
303
|
-
], 10,
|
|
304
|
-
], 8,
|
|
330
|
+
})) : q("", !0),
|
|
331
|
+
H(" " + C(k.label), 1)
|
|
332
|
+
], 10, la))), 128))
|
|
333
|
+
], 8, aa))
|
|
305
334
|
]),
|
|
306
335
|
_: 2
|
|
307
336
|
}, [
|
|
308
|
-
|
|
337
|
+
o.$slots.trailing ? {
|
|
309
338
|
name: "trailing",
|
|
310
339
|
fn: f(() => [
|
|
311
|
-
|
|
340
|
+
S(o.$slots, "trailing")
|
|
312
341
|
]),
|
|
313
342
|
key: "0"
|
|
314
343
|
} : void 0,
|
|
315
|
-
|
|
344
|
+
o.$slots.labelTrailing ? {
|
|
316
345
|
name: "labelTrailing",
|
|
317
346
|
fn: f(() => [
|
|
318
|
-
|
|
347
|
+
S(o.$slots, "labelTrailing")
|
|
319
348
|
]),
|
|
320
349
|
key: "1"
|
|
321
350
|
} : void 0,
|
|
322
|
-
|
|
351
|
+
o.$slots.readonly ? {
|
|
323
352
|
name: "readonly",
|
|
324
353
|
fn: f(() => [
|
|
325
|
-
|
|
354
|
+
S(o.$slots, "readonly")
|
|
326
355
|
]),
|
|
327
356
|
key: "2"
|
|
328
357
|
} : void 0
|
|
329
358
|
]), 1040, ["value"]));
|
|
330
359
|
}
|
|
331
|
-
}),
|
|
360
|
+
}), oa = {
|
|
332
361
|
key: 0,
|
|
333
362
|
class: "flex shrink-0 items-center",
|
|
334
363
|
"data-test": "field-value"
|
|
335
|
-
},
|
|
364
|
+
}, na = ["id", "value", "name", "placeholder", "disabled", "required", "aria-expanded", "aria-controls", "aria-activedescendant", "aria-required", "aria-invalid", "aria-describedby"], sa = { class: "block break-words text-body text-content-strong" }, co = /* @__PURE__ */ G({
|
|
336
365
|
__name: "ComboField",
|
|
337
|
-
props: /* @__PURE__ */ le(/* @__PURE__ */
|
|
366
|
+
props: /* @__PURE__ */ le(/* @__PURE__ */ ce({
|
|
338
367
|
label: {},
|
|
339
368
|
labelHidden: { type: Boolean },
|
|
340
369
|
hint: {},
|
|
@@ -355,104 +384,104 @@ const Gt = ["id", "aria-label", "aria-describedby", "aria-invalid"], Kt = ["name
|
|
|
355
384
|
recents: {},
|
|
356
385
|
width: {},
|
|
357
386
|
rowLayout: {}
|
|
358
|
-
}, { ...
|
|
387
|
+
}, { ...me, options: void 0, search: void 0, selected: null, placeholder: void 0, minLength: 1, debounce: 300, limit: 30, recents: void 0, width: "md", rowLayout: void 0 }), {
|
|
359
388
|
modelValue: { default: null },
|
|
360
389
|
modelModifiers: {}
|
|
361
390
|
}),
|
|
362
391
|
emits: /* @__PURE__ */ le(["picked", "focus", "blur"], ["update:modelValue"]),
|
|
363
|
-
setup(
|
|
364
|
-
const t =
|
|
392
|
+
setup(l, { expose: a, emit: e }) {
|
|
393
|
+
const t = l, o = re(l, "modelValue"), n = e, { t: u } = oe(), r = !!et(), m = Me("text", () => t.error ? "error" : t.disabled ? "locked" : "rest"), k = h(() => t.rowLayout === "stacked"), x = h(() => r && !k.value ? bt(t.width) : "w-full"), $ = U("input"), i = U("anchor"), v = Ne(null), g = Ne(""), T = yt({
|
|
365
394
|
source: () => t.search ?? t.options,
|
|
366
395
|
minLength: () => t.minLength,
|
|
367
396
|
debounce: () => t.debounce,
|
|
368
397
|
limit: () => t.limit,
|
|
369
398
|
listAllWhenEmpty: !0,
|
|
370
399
|
recents: () => t.recents
|
|
371
|
-
}), { items:
|
|
372
|
-
const
|
|
373
|
-
return
|
|
400
|
+
}), { items: w, open: F, status: O, highlighted: E, showingRecent: N } = T, V = h(() => {
|
|
401
|
+
const z = o.value;
|
|
402
|
+
return z === null ? null : [v.value, t.selected, ...t.options ?? []].find((A) => A?.value === z) ?? null;
|
|
374
403
|
});
|
|
375
|
-
|
|
376
|
-
|
|
404
|
+
ge(V, (z) => {
|
|
405
|
+
F.value || (g.value = z?.label ?? "");
|
|
377
406
|
}, { immediate: !0 });
|
|
378
|
-
function
|
|
379
|
-
|
|
407
|
+
function Q(z) {
|
|
408
|
+
g.value = z.target.value, T.ask(g.value), g.value === "" && (o.value = null, v.value = null);
|
|
380
409
|
}
|
|
381
|
-
function
|
|
382
|
-
n("focus",
|
|
410
|
+
function ee(z) {
|
|
411
|
+
n("focus", z), t.disabled || T.show("");
|
|
383
412
|
}
|
|
384
|
-
function
|
|
385
|
-
|
|
413
|
+
function ne(z) {
|
|
414
|
+
T.close(), T.remember(z), v.value = z, o.value = z.value, g.value = z.label, n("picked", z);
|
|
386
415
|
}
|
|
387
|
-
function
|
|
388
|
-
|
|
416
|
+
function ie(z) {
|
|
417
|
+
T.close(), g.value = V.value?.label ?? "", n("blur", z);
|
|
389
418
|
}
|
|
390
|
-
const
|
|
391
|
-
return a({ focus: () => $.value?.focus() }), (
|
|
392
|
-
value:
|
|
419
|
+
const ue = h(() => ht(F.value, w.value.length, O.value, !0));
|
|
420
|
+
return a({ focus: () => $.value?.focus() }), (z, A) => (d(), R(ye, J(s(fe)(t), {
|
|
421
|
+
value: V.value?.label ?? null,
|
|
393
422
|
"row-layout": t.rowLayout
|
|
394
|
-
}),
|
|
395
|
-
default: f(({ id:
|
|
396
|
-
|
|
423
|
+
}), Z({
|
|
424
|
+
default: f(({ id: K, describedby: te, invalid: Y }) => [
|
|
425
|
+
p("div", {
|
|
397
426
|
ref_key: "anchor",
|
|
398
|
-
ref:
|
|
399
|
-
class:
|
|
427
|
+
ref: i,
|
|
428
|
+
class: j(["flex items-center gap-1.5", [s(m), x.value]])
|
|
400
429
|
}, [
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
option:
|
|
430
|
+
z.$slots.value && V.value ? (d(), y("span", oa, [
|
|
431
|
+
S(z.$slots, "value", {
|
|
432
|
+
option: V.value
|
|
404
433
|
})
|
|
405
|
-
])) :
|
|
406
|
-
|
|
407
|
-
id:
|
|
434
|
+
])) : q("", !0),
|
|
435
|
+
p("input", {
|
|
436
|
+
id: K,
|
|
408
437
|
ref_key: "input",
|
|
409
438
|
ref: $,
|
|
410
439
|
role: "combobox",
|
|
411
440
|
type: "text",
|
|
412
441
|
autocomplete: "off",
|
|
413
|
-
value:
|
|
442
|
+
value: g.value,
|
|
414
443
|
name: t.name,
|
|
415
444
|
placeholder: t.placeholder,
|
|
416
445
|
disabled: t.disabled,
|
|
417
446
|
required: t.required,
|
|
418
447
|
"aria-autocomplete": "list",
|
|
419
|
-
"aria-expanded":
|
|
420
|
-
"aria-controls": `${
|
|
421
|
-
"aria-activedescendant":
|
|
448
|
+
"aria-expanded": ue.value,
|
|
449
|
+
"aria-controls": `${K}-list`,
|
|
450
|
+
"aria-activedescendant": ue.value && s(w).length > 0 ? `${K}-option-${s(E)}` : void 0,
|
|
422
451
|
"aria-required": t.required || void 0,
|
|
423
|
-
"aria-invalid":
|
|
424
|
-
"aria-describedby":
|
|
425
|
-
class:
|
|
426
|
-
onInput:
|
|
427
|
-
onFocus:
|
|
428
|
-
onBlur:
|
|
429
|
-
onKeydown:
|
|
430
|
-
}, null, 42,
|
|
431
|
-
|
|
452
|
+
"aria-invalid": Y || void 0,
|
|
453
|
+
"aria-describedby": te,
|
|
454
|
+
class: j(["block w-full min-w-0 border-0 bg-transparent px-0 py-1 text-body text-content-strong placeholder:text-content-disabled focus:outline-none focus:ring-0 disabled:cursor-not-allowed", r && !k.value ? "compact:text-right" : ""]),
|
|
455
|
+
onInput: Q,
|
|
456
|
+
onFocus: ee,
|
|
457
|
+
onBlur: ie,
|
|
458
|
+
onKeydown: A[0] || (A[0] = (se) => s(T).keydown(se, { pick: ne, enterNeedsMove: !1 }))
|
|
459
|
+
}, null, 42, na),
|
|
460
|
+
I(s(X), {
|
|
432
461
|
name: "search",
|
|
433
462
|
size: 14,
|
|
434
463
|
class: "shrink-0 text-content-muted"
|
|
435
464
|
})
|
|
436
465
|
], 2),
|
|
437
|
-
|
|
438
|
-
id:
|
|
439
|
-
anchor:
|
|
440
|
-
open:
|
|
441
|
-
items:
|
|
442
|
-
highlighted:
|
|
443
|
-
query:
|
|
444
|
-
status:
|
|
445
|
-
recent:
|
|
466
|
+
I(gt, {
|
|
467
|
+
id: K,
|
|
468
|
+
anchor: i.value,
|
|
469
|
+
open: s(F),
|
|
470
|
+
items: s(w),
|
|
471
|
+
highlighted: s(E),
|
|
472
|
+
query: g.value,
|
|
473
|
+
status: s(O),
|
|
474
|
+
recent: s(N),
|
|
446
475
|
"empty-message": !0,
|
|
447
|
-
selected:
|
|
448
|
-
hint:
|
|
449
|
-
onPick:
|
|
450
|
-
onHover:
|
|
451
|
-
},
|
|
452
|
-
|
|
476
|
+
selected: o.value,
|
|
477
|
+
hint: s(u)("core.form.suggestions.keys_pick"),
|
|
478
|
+
onPick: ne,
|
|
479
|
+
onHover: A[1] || (A[1] = (se) => s(T).highlight(se))
|
|
480
|
+
}, Z({ _: 2 }, [
|
|
481
|
+
z.$slots.option ? {
|
|
453
482
|
name: "option",
|
|
454
|
-
fn: f((
|
|
455
|
-
|
|
483
|
+
fn: f((se) => [
|
|
484
|
+
S(z.$slots, "option", ze(Ve(se)))
|
|
456
485
|
]),
|
|
457
486
|
key: "0"
|
|
458
487
|
} : void 0
|
|
@@ -460,32 +489,32 @@ const Gt = ["id", "aria-label", "aria-describedby", "aria-invalid"], Kt = ["name
|
|
|
460
489
|
]),
|
|
461
490
|
_: 2
|
|
462
491
|
}, [
|
|
463
|
-
|
|
492
|
+
z.$slots.trailing ? {
|
|
464
493
|
name: "trailing",
|
|
465
494
|
fn: f(() => [
|
|
466
|
-
|
|
495
|
+
S(z.$slots, "trailing")
|
|
467
496
|
]),
|
|
468
497
|
key: "0"
|
|
469
498
|
} : void 0,
|
|
470
|
-
|
|
499
|
+
z.$slots.labelTrailing ? {
|
|
471
500
|
name: "labelTrailing",
|
|
472
501
|
fn: f(() => [
|
|
473
|
-
|
|
502
|
+
S(z.$slots, "labelTrailing")
|
|
474
503
|
]),
|
|
475
504
|
key: "1"
|
|
476
505
|
} : void 0,
|
|
477
|
-
|
|
506
|
+
z.$slots.readonly ? {
|
|
478
507
|
name: "readonly",
|
|
479
508
|
fn: f(() => [
|
|
480
|
-
|
|
509
|
+
S(z.$slots, "readonly")
|
|
481
510
|
]),
|
|
482
511
|
key: "2"
|
|
483
|
-
} :
|
|
512
|
+
} : z.$slots.value && V.value ? {
|
|
484
513
|
name: "readonly",
|
|
485
514
|
fn: f(() => [
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
option:
|
|
515
|
+
p("span", sa, [
|
|
516
|
+
S(z.$slots, "value", {
|
|
517
|
+
option: V.value
|
|
489
518
|
})
|
|
490
519
|
])
|
|
491
520
|
]),
|
|
@@ -493,18 +522,18 @@ const Gt = ["id", "aria-label", "aria-describedby", "aria-invalid"], Kt = ["name
|
|
|
493
522
|
} : void 0
|
|
494
523
|
]), 1040, ["value", "row-layout"]));
|
|
495
524
|
}
|
|
496
|
-
}),
|
|
525
|
+
}), ra = {
|
|
497
526
|
key: 0,
|
|
498
527
|
class: "whitespace-normal"
|
|
499
|
-
},
|
|
528
|
+
}, ia = { class: "whitespace-nowrap" }, ua = { class: "whitespace-nowrap" }, da = ["id", "name", "value", "placeholder", "disabled", "required", "aria-required", "aria-invalid", "aria-describedby"], ca = ["aria-label", "onClick"], fa = {
|
|
500
529
|
class: "-m-3 flex",
|
|
501
530
|
"data-test": "date-time-popover"
|
|
502
|
-
},
|
|
531
|
+
}, ma = { class: "flex w-75 flex-col gap-2.5 border-r border-border-separator p-3.5" }, va = {
|
|
503
532
|
key: 0,
|
|
504
533
|
class: "border-t border-border-separator pt-2.5"
|
|
505
|
-
},
|
|
534
|
+
}, pa = { class: "flex w-48 flex-col gap-2.5 px-3 py-3.5" }, ba = ["for"], ga = ["id", "value", "placeholder", "aria-invalid"], ya = ["onClick"], fo = /* @__PURE__ */ G({
|
|
506
535
|
__name: "DateTimeField",
|
|
507
|
-
props: /* @__PURE__ */ le(/* @__PURE__ */
|
|
536
|
+
props: /* @__PURE__ */ le(/* @__PURE__ */ ce({
|
|
508
537
|
label: {},
|
|
509
538
|
labelHidden: { type: Boolean },
|
|
510
539
|
hint: {},
|
|
@@ -521,190 +550,190 @@ const Gt = ["id", "aria-label", "aria-describedby", "aria-invalid"], Kt = ["name
|
|
|
521
550
|
openOn: {},
|
|
522
551
|
minuteStep: {},
|
|
523
552
|
quickPicks: {}
|
|
524
|
-
}, { ...
|
|
553
|
+
}, { ...me, min: void 0, max: void 0, disabledDates: void 0, openOn: void 0, minuteStep: 1, quickPicks: void 0 }), {
|
|
525
554
|
modelValue: { default: null },
|
|
526
555
|
modelModifiers: {}
|
|
527
556
|
}),
|
|
528
557
|
emits: /* @__PURE__ */ le(["focus", "blur"], ["update:modelValue"]),
|
|
529
|
-
setup(
|
|
530
|
-
const t =
|
|
531
|
-
function
|
|
532
|
-
const { date:
|
|
533
|
-
if (!
|
|
534
|
-
let
|
|
535
|
-
if (
|
|
536
|
-
const
|
|
537
|
-
if ("error" in
|
|
538
|
-
|
|
558
|
+
setup(l, { expose: a, emit: e }) {
|
|
559
|
+
const t = l, o = re(l, "modelValue"), n = e, { t: u } = oe(), r = at(), m = Ie(), k = U("input"), x = U("popover"), $ = U("calendar"), i = U("sheet"), v = h(() => ({ min: t.min?.slice(0, 10), max: t.max?.slice(0, 10), disabled: t.disabledDates })), g = h(() => t.min && t.min.length === 10 ? `${t.min}T00:00` : t.min), T = h(() => t.max && t.max.length === 10 ? `${t.max}T23:59` : t.max), w = (_, c) => !St(c, { disabled: t.disabledDates }) && (!g.value || _ >= g.value) && (!T.value || _ <= T.value), F = Bt(() => v.value), O = qt(() => t.minuteStep), E = h(() => _e(o.value));
|
|
560
|
+
function N(_) {
|
|
561
|
+
const { date: c, time: B } = Tt(_), M = c === null ? E.value.day ?? Fe() : F.parse(c);
|
|
562
|
+
if (!M) return { error: F.invalidMessage() };
|
|
563
|
+
let b = E.value.time ?? Te(t.minuteStep);
|
|
564
|
+
if (B !== null) {
|
|
565
|
+
const L = O.parse(B);
|
|
566
|
+
if ("error" in L) return L;
|
|
567
|
+
b = L.value;
|
|
539
568
|
}
|
|
540
|
-
const
|
|
541
|
-
return
|
|
569
|
+
const D = Ce(M, b);
|
|
570
|
+
return w(D, M) ? { value: D } : { error: F.unavailableMessage() };
|
|
542
571
|
}
|
|
543
|
-
const
|
|
544
|
-
get: () =>
|
|
545
|
-
set: (
|
|
546
|
-
|
|
572
|
+
const V = Ge({ model: o, display: (_) => `${r.date(_e(_).day)} ${_e(_).time ?? ""}`.trim(), parse: N }), Q = h({
|
|
573
|
+
get: () => E.value.time,
|
|
574
|
+
set: (_) => {
|
|
575
|
+
_ && kt(_) && (o.value = Ce(E.value.day ?? Fe(), _));
|
|
547
576
|
}
|
|
548
|
-
}),
|
|
549
|
-
const
|
|
550
|
-
return
|
|
551
|
-
}),
|
|
552
|
-
function
|
|
553
|
-
|
|
577
|
+
}), ee = Ge({ model: Q, display: (_) => _, parse: O.parse }), ne = Lt(() => t.quickPicks ?? (m.value ? void 0 : []), () => m.value, () => v.value), ie = h(() => t.error || V.message.value || ee.message.value), ue = h(() => o.value ? r.dateTime(o.value) : null), z = Me("date", () => ie.value ? "error" : t.disabled ? "locked" : "rest"), A = h(() => {
|
|
578
|
+
const _ = V.typed.value;
|
|
579
|
+
return _ ? _e(_).day ?? null : null;
|
|
580
|
+
}), K = h(() => A.value ?? (xt(E.value.day) ? E.value.day : null)), te = h(() => V.typed.value ? _e(V.typed.value).time : E.value.time);
|
|
581
|
+
function Y(_) {
|
|
582
|
+
_ && V.set(Ce(_, E.value.time ?? Te(t.minuteStep)));
|
|
554
583
|
}
|
|
555
|
-
function
|
|
556
|
-
|
|
584
|
+
function se(_) {
|
|
585
|
+
_ && V.set(Ce(E.value.day ?? Fe(), _));
|
|
557
586
|
}
|
|
558
|
-
function
|
|
559
|
-
|
|
587
|
+
function he(_) {
|
|
588
|
+
V.set(Ce(Fe(), Te(t.minuteStep))), _();
|
|
560
589
|
}
|
|
561
|
-
const we =
|
|
562
|
-
async function
|
|
563
|
-
t.disabled || (
|
|
590
|
+
const we = Re();
|
|
591
|
+
async function ke(_) {
|
|
592
|
+
t.disabled || (x.value?.present(), _ && (await xe(), await xe(), $.value?.focus()));
|
|
564
593
|
}
|
|
565
|
-
function
|
|
566
|
-
|
|
594
|
+
function ae(_) {
|
|
595
|
+
_.key === "Enter" ? (V.commit(), x.value?.dismiss()) : _.key === "ArrowDown" && (_.preventDefault(), ke(!0));
|
|
567
596
|
}
|
|
568
|
-
return a({ focus: () => k.value?.focus() }), (
|
|
569
|
-
value:
|
|
597
|
+
return a({ focus: () => k.value?.focus() }), (_, c) => (d(), R(ye, J({ ...s(fe)(t), error: ie.value }, {
|
|
598
|
+
value: ue.value,
|
|
570
599
|
"value-style": "numeric"
|
|
571
|
-
}),
|
|
572
|
-
default: f(({ id:
|
|
573
|
-
|
|
574
|
-
|
|
600
|
+
}), Z({
|
|
601
|
+
default: f(({ id: B, describedby: M, invalid: b }) => [
|
|
602
|
+
s(m) ? (d(), y(de, { key: 0 }, [
|
|
603
|
+
I(tt, J({ id: B, "aria-describedby": M }, {
|
|
575
604
|
disabled: t.disabled,
|
|
576
|
-
invalid:
|
|
577
|
-
placeholder:
|
|
578
|
-
onClick:
|
|
605
|
+
invalid: b,
|
|
606
|
+
placeholder: s(u)("core.form.select.choose"),
|
|
607
|
+
onClick: c[0] || (c[0] = (D) => i.value?.present())
|
|
579
608
|
}), {
|
|
580
609
|
default: f(() => [
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
])) :
|
|
610
|
+
o.value ? (d(), y("span", ra, [
|
|
611
|
+
p("span", ia, C(s(r).date(E.value.day)), 1),
|
|
612
|
+
c[8] || (c[8] = H(C(" "), -1)),
|
|
613
|
+
p("span", ua, C(E.value.time), 1)
|
|
614
|
+
])) : q("", !0)
|
|
586
615
|
]),
|
|
587
616
|
_: 1
|
|
588
617
|
}, 16, ["disabled", "invalid", "placeholder"]),
|
|
589
|
-
|
|
618
|
+
I(wt, {
|
|
590
619
|
ref_key: "sheet",
|
|
591
|
-
ref:
|
|
592
|
-
title: t.label ??
|
|
620
|
+
ref: i,
|
|
621
|
+
title: t.label ?? s(u)("core.form.date.calendar"),
|
|
593
622
|
mode: "datetime",
|
|
594
|
-
"model-value":
|
|
595
|
-
min:
|
|
596
|
-
max:
|
|
623
|
+
"model-value": o.value,
|
|
624
|
+
min: v.value.min,
|
|
625
|
+
max: v.value.max,
|
|
597
626
|
"disabled-dates": t.disabledDates,
|
|
598
627
|
"open-on": t.openOn,
|
|
599
|
-
shortcuts:
|
|
628
|
+
shortcuts: s(ne),
|
|
600
629
|
step: t.minuteStep,
|
|
601
630
|
clearable: !t.required,
|
|
602
|
-
"onUpdate:modelValue":
|
|
631
|
+
"onUpdate:modelValue": s(V).set
|
|
603
632
|
}, null, 8, ["title", "model-value", "min", "max", "disabled-dates", "open-on", "shortcuts", "step", "clearable", "onUpdate:modelValue"])
|
|
604
|
-
], 64)) : (
|
|
633
|
+
], 64)) : (d(), R(je, {
|
|
605
634
|
key: 1,
|
|
606
635
|
ref_key: "popover",
|
|
607
|
-
ref:
|
|
608
|
-
label: t.label ??
|
|
636
|
+
ref: x,
|
|
637
|
+
label: t.label ?? s(u)("core.form.date.calendar"),
|
|
609
638
|
width: "auto",
|
|
610
639
|
placement: "bottom-start",
|
|
611
640
|
arrow: !1,
|
|
612
641
|
autofocus: !1
|
|
613
642
|
}, {
|
|
614
|
-
trigger: f(({ attrs:
|
|
615
|
-
|
|
616
|
-
class:
|
|
643
|
+
trigger: f(({ attrs: D, presented: L }) => [
|
|
644
|
+
p("div", {
|
|
645
|
+
class: j(["inline-flex max-w-full items-center gap-2", s(z)])
|
|
617
646
|
}, [
|
|
618
|
-
|
|
619
|
-
id:
|
|
647
|
+
p("input", J({
|
|
648
|
+
id: B,
|
|
620
649
|
ref_key: "input",
|
|
621
650
|
ref: k
|
|
622
|
-
},
|
|
651
|
+
}, D, {
|
|
623
652
|
type: "text",
|
|
624
653
|
role: "combobox",
|
|
625
654
|
autocomplete: "off",
|
|
626
655
|
size: "20",
|
|
627
656
|
name: t.name,
|
|
628
|
-
value:
|
|
629
|
-
placeholder:
|
|
657
|
+
value: s(V).text.value,
|
|
658
|
+
placeholder: s(F).placeholder.value,
|
|
630
659
|
disabled: t.disabled,
|
|
631
660
|
required: t.required,
|
|
632
661
|
"aria-required": t.required || void 0,
|
|
633
|
-
"aria-invalid":
|
|
634
|
-
"aria-describedby":
|
|
662
|
+
"aria-invalid": b || void 0,
|
|
663
|
+
"aria-describedby": M,
|
|
635
664
|
class: "block min-h-7 min-w-0 border-0 bg-transparent py-1 pl-2.5 text-body tabular-nums text-content-strong placeholder:text-content-disabled focus:outline-none focus:ring-0 disabled:cursor-not-allowed",
|
|
636
|
-
onInput:
|
|
637
|
-
onFocus:
|
|
638
|
-
onBlur:
|
|
639
|
-
|
|
665
|
+
onInput: c[1] || (c[1] = (W) => s(V).input(W.target.value)),
|
|
666
|
+
onFocus: c[2] || (c[2] = (W) => n("focus", W)),
|
|
667
|
+
onBlur: c[3] || (c[3] = (W) => {
|
|
668
|
+
s(V).commit(), n("blur", W);
|
|
640
669
|
}),
|
|
641
|
-
onKeydown:
|
|
642
|
-
onClick:
|
|
643
|
-
}), null, 16,
|
|
644
|
-
t.disabled ?
|
|
670
|
+
onKeydown: ae,
|
|
671
|
+
onClick: c[4] || (c[4] = (W) => ke(!1))
|
|
672
|
+
}), null, 16, da),
|
|
673
|
+
t.disabled ? q("", !0) : (d(), y("button", {
|
|
645
674
|
key: 0,
|
|
646
675
|
type: "button",
|
|
647
676
|
tabindex: "-1",
|
|
648
|
-
"aria-label":
|
|
677
|
+
"aria-label": s(u)("core.form.date.open"),
|
|
649
678
|
class: "mr-2 flex shrink-0 cursor-pointer items-center text-content-link",
|
|
650
|
-
onClick: (
|
|
679
|
+
onClick: (W) => L ? x.value?.dismiss() : ke(!0)
|
|
651
680
|
}, [
|
|
652
|
-
|
|
681
|
+
I(s(X), {
|
|
653
682
|
name: "calendarLine",
|
|
654
683
|
size: 18
|
|
655
684
|
})
|
|
656
|
-
], 8,
|
|
685
|
+
], 8, ca))
|
|
657
686
|
], 2)
|
|
658
687
|
]),
|
|
659
|
-
default: f(({ dismiss:
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
688
|
+
default: f(({ dismiss: D }) => [
|
|
689
|
+
p("div", fa, [
|
|
690
|
+
p("div", ma, [
|
|
691
|
+
I($t, {
|
|
663
692
|
ref_key: "calendar",
|
|
664
693
|
ref: $,
|
|
665
|
-
"model-value":
|
|
666
|
-
min:
|
|
667
|
-
max:
|
|
694
|
+
"model-value": K.value,
|
|
695
|
+
min: v.value.min,
|
|
696
|
+
max: v.value.max,
|
|
668
697
|
"disabled-dates": t.disabledDates,
|
|
669
698
|
"open-on": t.openOn,
|
|
670
|
-
"onUpdate:modelValue":
|
|
699
|
+
"onUpdate:modelValue": Y
|
|
671
700
|
}, null, 8, ["model-value", "min", "max", "disabled-dates", "open-on"]),
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
items:
|
|
675
|
-
selected:
|
|
676
|
-
onPick:
|
|
701
|
+
s(ne).length > 0 ? (d(), y("div", va, [
|
|
702
|
+
I(_t, {
|
|
703
|
+
items: s(ne),
|
|
704
|
+
selected: K.value,
|
|
705
|
+
onPick: Y
|
|
677
706
|
}, null, 8, ["items", "selected"])
|
|
678
|
-
])) :
|
|
707
|
+
])) : q("", !0)
|
|
679
708
|
]),
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
for:
|
|
709
|
+
p("div", pa, [
|
|
710
|
+
p("label", {
|
|
711
|
+
for: s(we),
|
|
683
712
|
class: "text-footnote font-semibold text-content-muted"
|
|
684
|
-
},
|
|
685
|
-
|
|
686
|
-
id:
|
|
713
|
+
}, C(s(u)("core.form.time.label")), 9, ba),
|
|
714
|
+
p("input", {
|
|
715
|
+
id: s(we),
|
|
687
716
|
type: "text",
|
|
688
717
|
autocomplete: "off",
|
|
689
718
|
inputmode: "numeric",
|
|
690
|
-
value:
|
|
691
|
-
placeholder:
|
|
692
|
-
"aria-invalid":
|
|
719
|
+
value: s(ee).text.value,
|
|
720
|
+
placeholder: s(O).placeholder.value,
|
|
721
|
+
"aria-invalid": s(ee).message.value ? !0 : void 0,
|
|
693
722
|
class: "rounded-control bg-fill p-1.5 text-center text-[20px] font-semibold tabular-nums text-content-strong placeholder:text-base placeholder:font-normal placeholder:text-content-disabled focus:outline-2 focus:outline-border-focus",
|
|
694
|
-
onInput:
|
|
695
|
-
onBlur:
|
|
696
|
-
onKeydown:
|
|
697
|
-
}, null, 40,
|
|
698
|
-
|
|
699
|
-
"model-value":
|
|
723
|
+
onInput: c[5] || (c[5] = (L) => s(ee).input(L.target.value)),
|
|
724
|
+
onBlur: c[6] || (c[6] = (L) => s(ee).commit()),
|
|
725
|
+
onKeydown: c[7] || (c[7] = Se(pe((L) => s(ee).commit(), ["prevent"]), ["enter"]))
|
|
726
|
+
}, null, 40, ga),
|
|
727
|
+
I(Ct, {
|
|
728
|
+
"model-value": te.value,
|
|
700
729
|
step: t.minuteStep,
|
|
701
|
-
"onUpdate:modelValue":
|
|
730
|
+
"onUpdate:modelValue": se
|
|
702
731
|
}, null, 8, ["model-value", "step"]),
|
|
703
|
-
|
|
732
|
+
p("button", {
|
|
704
733
|
type: "button",
|
|
705
734
|
class: "cursor-pointer self-start rounded-full bg-tint-soft px-2.5 py-1.5 text-footnote font-medium text-content-link focus-visible:outline-2 focus-visible:outline-border-focus",
|
|
706
|
-
onClick: (
|
|
707
|
-
},
|
|
735
|
+
onClick: (L) => he(D)
|
|
736
|
+
}, C(s(u)("core.form.time.now")), 9, ya)
|
|
708
737
|
])
|
|
709
738
|
])
|
|
710
739
|
]),
|
|
@@ -713,51 +742,51 @@ const Gt = ["id", "aria-label", "aria-describedby", "aria-invalid"], Kt = ["name
|
|
|
713
742
|
]),
|
|
714
743
|
_: 2
|
|
715
744
|
}, [
|
|
716
|
-
|
|
745
|
+
_.$slots.trailing ? {
|
|
717
746
|
name: "trailing",
|
|
718
747
|
fn: f(() => [
|
|
719
|
-
|
|
748
|
+
S(_.$slots, "trailing")
|
|
720
749
|
]),
|
|
721
750
|
key: "0"
|
|
722
751
|
} : void 0,
|
|
723
|
-
|
|
752
|
+
_.$slots.labelTrailing ? {
|
|
724
753
|
name: "labelTrailing",
|
|
725
754
|
fn: f(() => [
|
|
726
|
-
|
|
755
|
+
S(_.$slots, "labelTrailing")
|
|
727
756
|
]),
|
|
728
757
|
key: "1"
|
|
729
758
|
} : void 0,
|
|
730
|
-
|
|
759
|
+
_.$slots.readonly ? {
|
|
731
760
|
name: "readonly",
|
|
732
761
|
fn: f(() => [
|
|
733
|
-
|
|
762
|
+
S(_.$slots, "readonly")
|
|
734
763
|
]),
|
|
735
764
|
key: "2"
|
|
736
765
|
} : void 0
|
|
737
766
|
]), 1040, ["value"]));
|
|
738
767
|
}
|
|
739
768
|
});
|
|
740
|
-
function
|
|
769
|
+
function lt(l, a = {}) {
|
|
741
770
|
const e = a.accept ?? [];
|
|
742
771
|
if (e.length > 0) {
|
|
743
|
-
const t =
|
|
744
|
-
if (!e.some((
|
|
745
|
-
const
|
|
746
|
-
return
|
|
772
|
+
const t = l.name.lastIndexOf("."), o = t === -1 ? "" : l.name.slice(t).toLowerCase(), n = l.type.toLowerCase();
|
|
773
|
+
if (!e.some((r) => {
|
|
774
|
+
const m = r.trim().toLowerCase();
|
|
775
|
+
return m.startsWith(".") ? m === o : m.endsWith("/*") ? n.startsWith(m.slice(0, -1)) : m === n;
|
|
747
776
|
})) return "invalid_type";
|
|
748
777
|
}
|
|
749
|
-
return (a.maxSize ?? 0) > 0 &&
|
|
778
|
+
return (a.maxSize ?? 0) > 0 && l.size > (a.maxSize ?? 0) ? "too_large" : null;
|
|
750
779
|
}
|
|
751
|
-
function
|
|
752
|
-
return
|
|
780
|
+
function Be(l) {
|
|
781
|
+
return l < 1024 ? `${l} B` : l < 1024 * 1024 ? `${Math.round(l / 1024)} KB` : `${(l / (1024 * 1024)).toFixed(l % (1024 * 1024) === 0 ? 0 : 1)} MB`;
|
|
753
782
|
}
|
|
754
|
-
const
|
|
783
|
+
const ha = { class: "w-full" }, ka = ["id", "accept", "disabled", "aria-describedby", "aria-invalid"], xa = {
|
|
755
784
|
key: 0,
|
|
756
785
|
class: "flex items-center gap-3 rounded-group bg-fill p-3",
|
|
757
786
|
"data-test": "file-selected"
|
|
758
|
-
},
|
|
787
|
+
}, wa = { class: "min-w-0 flex-1" }, $a = { class: "truncate text-body font-medium text-content-strong" }, _a = { class: "text-footnote text-content-muted" }, Ca = ["disabled", "aria-label", "title"], Sa = ["aria-disabled"], Fa = { class: "font-semibold text-content-link" }, Ba = { class: "text-content-muted" }, mo = /* @__PURE__ */ G({
|
|
759
788
|
__name: "FileField",
|
|
760
|
-
props: /* @__PURE__ */ le(/* @__PURE__ */
|
|
789
|
+
props: /* @__PURE__ */ le(/* @__PURE__ */ ce({
|
|
761
790
|
label: {},
|
|
762
791
|
labelHidden: { type: Boolean },
|
|
763
792
|
hint: {},
|
|
@@ -771,35 +800,35 @@ const ga = { class: "w-full" }, ha = ["id", "accept", "disabled", "aria-describe
|
|
|
771
800
|
variant: {},
|
|
772
801
|
accept: {},
|
|
773
802
|
maxSize: {}
|
|
774
|
-
}, { ...
|
|
803
|
+
}, { ...me, variant: "button", accept: () => [], maxSize: 0 }), {
|
|
775
804
|
modelValue: { default: null },
|
|
776
805
|
modelModifiers: {}
|
|
777
806
|
}),
|
|
778
807
|
emits: ["update:modelValue"],
|
|
779
|
-
setup(
|
|
780
|
-
const e =
|
|
808
|
+
setup(l, { expose: a }) {
|
|
809
|
+
const e = l, t = re(l, "modelValue"), { t: o } = oe(), n = U("chooser"), u = P(!1), r = P(null), m = h(() => {
|
|
781
810
|
if (e.hint) return e.hint;
|
|
782
811
|
const $ = [];
|
|
783
|
-
return e.accept.length && $.push(
|
|
812
|
+
return e.accept.length && $.push(o("core.form.file.allowed", { formats: e.accept.map((i) => i.replace(/^\./, "").toUpperCase()).join(", ") })), e.maxSize > 0 && $.push(o("core.form.file.max_size", { size: Be(e.maxSize) })), $.join(" · ") || void 0;
|
|
784
813
|
});
|
|
785
814
|
function k($) {
|
|
786
815
|
if (!$) return;
|
|
787
|
-
const
|
|
788
|
-
|
|
816
|
+
const i = lt($, { accept: e.accept, maxSize: e.maxSize });
|
|
817
|
+
i ? (r.value = i === "invalid_type" ? o("core.form.file.invalid_type") : o("core.form.file.too_large", { size: Be(e.maxSize) }), t.value = null) : (r.value = null, t.value = $);
|
|
789
818
|
}
|
|
790
|
-
function
|
|
791
|
-
t.value = null,
|
|
819
|
+
function x() {
|
|
820
|
+
t.value = null, r.value = null;
|
|
792
821
|
}
|
|
793
|
-
return
|
|
822
|
+
return ge(t, ($) => {
|
|
794
823
|
!$ && n.value && (n.value.value = "");
|
|
795
|
-
}), a({ clear:
|
|
824
|
+
}), a({ clear: x }), ($, i) => (d(), R(ye, J({ ...s(fe)(e), hint: m.value, error: r.value ?? e.error }, {
|
|
796
825
|
value: t.value?.name ?? null,
|
|
797
826
|
"row-layout": "stacked"
|
|
798
|
-
}),
|
|
799
|
-
default: f(({ id:
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
id:
|
|
827
|
+
}), Z({
|
|
828
|
+
default: f(({ id: v, describedby: g, invalid: T }) => [
|
|
829
|
+
p("div", ha, [
|
|
830
|
+
p("input", {
|
|
831
|
+
id: v,
|
|
803
832
|
ref_key: "chooser",
|
|
804
833
|
ref: n,
|
|
805
834
|
type: "file",
|
|
@@ -807,55 +836,55 @@ const ga = { class: "w-full" }, ha = ["id", "accept", "disabled", "aria-describe
|
|
|
807
836
|
tabindex: "-1",
|
|
808
837
|
accept: e.accept.join(",") || void 0,
|
|
809
838
|
disabled: e.disabled,
|
|
810
|
-
"aria-describedby":
|
|
811
|
-
"aria-invalid":
|
|
812
|
-
onChange:
|
|
813
|
-
}, null, 40,
|
|
814
|
-
t.value ? (
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
839
|
+
"aria-describedby": g,
|
|
840
|
+
"aria-invalid": T || void 0,
|
|
841
|
+
onChange: i[0] || (i[0] = (w) => k(w.target.files?.[0]))
|
|
842
|
+
}, null, 40, ka),
|
|
843
|
+
t.value ? (d(), y("div", xa, [
|
|
844
|
+
p("div", wa, [
|
|
845
|
+
p("p", $a, C(t.value.name), 1),
|
|
846
|
+
p("p", _a, C(s(Be)(t.value.size)), 1)
|
|
818
847
|
]),
|
|
819
|
-
|
|
848
|
+
p("button", {
|
|
820
849
|
type: "button",
|
|
821
850
|
disabled: e.disabled,
|
|
822
|
-
"aria-label":
|
|
823
|
-
title:
|
|
851
|
+
"aria-label": s(o)("core.form.file.remove"),
|
|
852
|
+
title: s(o)("core.form.file.remove"),
|
|
824
853
|
class: "flex size-7 shrink-0 cursor-pointer items-center justify-center rounded-full text-content-muted hover:bg-fill-strong focus-visible:outline-2 focus-visible:outline-border-focus disabled:cursor-not-allowed",
|
|
825
|
-
onClick:
|
|
854
|
+
onClick: x
|
|
826
855
|
}, [
|
|
827
|
-
|
|
856
|
+
I(s(X), {
|
|
828
857
|
name: "close",
|
|
829
858
|
size: 14
|
|
830
859
|
})
|
|
831
|
-
], 8,
|
|
832
|
-
])) : e.variant === "dropzone" ? (
|
|
860
|
+
], 8, Ca)
|
|
861
|
+
])) : e.variant === "dropzone" ? (d(), y("div", {
|
|
833
862
|
key: 1,
|
|
834
863
|
role: "button",
|
|
835
864
|
tabindex: "0",
|
|
836
865
|
"data-test": "file-dropzone",
|
|
837
866
|
"aria-disabled": e.disabled || void 0,
|
|
838
|
-
class:
|
|
839
|
-
onClick:
|
|
867
|
+
class: j(["cursor-pointer rounded-group border-2 border-dashed p-6 text-center text-body transition-colors duration-motion-fast focus-visible:outline-2 focus-visible:outline-border-focus", u.value ? "border-border-focus bg-tint-soft" : "border-border-control hover:bg-fill"]),
|
|
868
|
+
onClick: i[1] || (i[1] = (w) => !e.disabled && n.value?.click()),
|
|
840
869
|
onKeydown: [
|
|
841
|
-
|
|
842
|
-
|
|
870
|
+
i[2] || (i[2] = Se(pe((w) => !e.disabled && n.value?.click(), ["prevent"]), ["enter"])),
|
|
871
|
+
i[3] || (i[3] = Se(pe((w) => !e.disabled && n.value?.click(), ["prevent"]), ["space"]))
|
|
843
872
|
],
|
|
844
|
-
onDragover:
|
|
845
|
-
onDragleave:
|
|
846
|
-
onDrop:
|
|
847
|
-
|
|
873
|
+
onDragover: i[4] || (i[4] = pe((w) => u.value = !0, ["prevent"])),
|
|
874
|
+
onDragleave: i[5] || (i[5] = pe((w) => u.value = !1, ["prevent"])),
|
|
875
|
+
onDrop: i[6] || (i[6] = pe((w) => {
|
|
876
|
+
u.value = !1, e.disabled || k(w.dataTransfer?.files?.[0]);
|
|
848
877
|
}, ["prevent"]))
|
|
849
878
|
}, [
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
], 42,
|
|
879
|
+
p("span", Fa, C(s(o)("core.form.file.choose")), 1),
|
|
880
|
+
p("span", Ba, C(" " + s(o)("core.form.file.drop")), 1)
|
|
881
|
+
], 42, Sa)) : (d(), R(be, {
|
|
853
882
|
key: 2,
|
|
854
883
|
disabled: e.disabled,
|
|
855
|
-
onClick:
|
|
884
|
+
onClick: i[7] || (i[7] = (w) => n.value?.click())
|
|
856
885
|
}, {
|
|
857
886
|
default: f(() => [
|
|
858
|
-
H(
|
|
887
|
+
H(C(s(o)("core.form.file.choose")), 1)
|
|
859
888
|
]),
|
|
860
889
|
_: 1
|
|
861
890
|
}, 8, ["disabled"]))
|
|
@@ -866,27 +895,27 @@ const ga = { class: "w-full" }, ha = ["id", "accept", "disabled", "aria-describe
|
|
|
866
895
|
$.$slots.trailing ? {
|
|
867
896
|
name: "trailing",
|
|
868
897
|
fn: f(() => [
|
|
869
|
-
|
|
898
|
+
S($.$slots, "trailing")
|
|
870
899
|
]),
|
|
871
900
|
key: "0"
|
|
872
901
|
} : void 0,
|
|
873
902
|
$.$slots.labelTrailing ? {
|
|
874
903
|
name: "labelTrailing",
|
|
875
904
|
fn: f(() => [
|
|
876
|
-
|
|
905
|
+
S($.$slots, "labelTrailing")
|
|
877
906
|
]),
|
|
878
907
|
key: "1"
|
|
879
908
|
} : void 0,
|
|
880
909
|
$.$slots.readonly ? {
|
|
881
910
|
name: "readonly",
|
|
882
911
|
fn: f(() => [
|
|
883
|
-
|
|
912
|
+
S($.$slots, "readonly")
|
|
884
913
|
]),
|
|
885
914
|
key: "2"
|
|
886
915
|
} : void 0
|
|
887
916
|
]), 1040, ["value"]));
|
|
888
917
|
}
|
|
889
|
-
}),
|
|
918
|
+
}), La = ["disabled"], vo = /* @__PURE__ */ G({
|
|
890
919
|
__name: "FormGroupButton",
|
|
891
920
|
props: {
|
|
892
921
|
label: {},
|
|
@@ -894,18 +923,18 @@ const ga = { class: "w-full" }, ha = ["id", "accept", "disabled", "aria-describe
|
|
|
894
923
|
disabled: { type: Boolean, default: !1 }
|
|
895
924
|
},
|
|
896
925
|
emits: ["click"],
|
|
897
|
-
setup(
|
|
898
|
-
const e =
|
|
899
|
-
return (
|
|
926
|
+
setup(l, { emit: a }) {
|
|
927
|
+
const e = l, t = a;
|
|
928
|
+
return (o, n) => (d(), R(ot, null, {
|
|
900
929
|
default: f(() => [
|
|
901
|
-
|
|
930
|
+
I(mt, { layout: "stacked" }, {
|
|
902
931
|
default: f(() => [
|
|
903
|
-
|
|
932
|
+
p("button", {
|
|
904
933
|
type: "button",
|
|
905
934
|
disabled: e.disabled,
|
|
906
|
-
class:
|
|
907
|
-
onClick: n[0] || (n[0] = (
|
|
908
|
-
},
|
|
935
|
+
class: j(["w-full py-1 text-center text-body focus-visible:outline-2 focus-visible:outline-border-focus disabled:text-content-disabled", e.tone === "critical" ? "text-content-destructive" : "text-content-link"]),
|
|
936
|
+
onClick: n[0] || (n[0] = (u) => t("click"))
|
|
937
|
+
}, C(e.label), 11, La)
|
|
909
938
|
]),
|
|
910
939
|
_: 1
|
|
911
940
|
})
|
|
@@ -913,31 +942,31 @@ const ga = { class: "w-full" }, ha = ["id", "accept", "disabled", "aria-describe
|
|
|
913
942
|
_: 1
|
|
914
943
|
}));
|
|
915
944
|
}
|
|
916
|
-
}),
|
|
945
|
+
}), po = /* @__PURE__ */ G({
|
|
917
946
|
__name: "FormIndent",
|
|
918
|
-
setup(
|
|
919
|
-
return
|
|
947
|
+
setup(l) {
|
|
948
|
+
return rt(vt, pt() + 1), (a, e) => S(a.$slots, "default");
|
|
920
949
|
}
|
|
921
950
|
});
|
|
922
|
-
function
|
|
923
|
-
return a.filter((e) => (
|
|
951
|
+
function Ta(l, a) {
|
|
952
|
+
return a.filter((e) => (l?.[e] ?? "").trim() === "");
|
|
924
953
|
}
|
|
925
|
-
const
|
|
954
|
+
const qa = ["id", "aria-labelledby"], za = ["id", "value", "lang", "name", "rows", "placeholder", "maxlength", "disabled", "aria-required", "aria-invalid", "aria-describedby"], Va = ["id", "value", "lang", "name", "placeholder", "maxlength", "disabled", "aria-required", "aria-invalid", "aria-describedby"], Da = {
|
|
926
955
|
key: 0,
|
|
927
956
|
class: "mt-1.5 flex items-center gap-2"
|
|
928
|
-
},
|
|
957
|
+
}, Ra = {
|
|
929
958
|
key: 0,
|
|
930
959
|
class: "flex-1 text-footnote text-status-warning-content",
|
|
931
960
|
"data-test": "i18n-missing"
|
|
932
|
-
},
|
|
961
|
+
}, Ma = {
|
|
933
962
|
key: 1,
|
|
934
963
|
class: "flex-1"
|
|
935
|
-
},
|
|
964
|
+
}, Ia = ["aria-label"], ja = ["id", "aria-selected", "tabindex", "aria-controls", "aria-label", "title", "onClick", "onKeydown"], Oa = ["data-state"], Ea = { class: "w-full" }, Na = { class: "whitespace-pre-line break-words text-body text-content-strong" }, Aa = ["aria-expanded"], Ga = { class: "flex-1" }, Ka = {
|
|
936
965
|
key: 0,
|
|
937
966
|
class: "mt-1 flex flex-col gap-1.5"
|
|
938
|
-
},
|
|
967
|
+
}, Pa = ["title"], bo = /* @__PURE__ */ G({
|
|
939
968
|
__name: "I18nField",
|
|
940
|
-
props: /* @__PURE__ */ le(/* @__PURE__ */
|
|
969
|
+
props: /* @__PURE__ */ le(/* @__PURE__ */ ce({
|
|
941
970
|
label: {},
|
|
942
971
|
labelHidden: { type: Boolean },
|
|
943
972
|
hint: {},
|
|
@@ -955,213 +984,213 @@ const Ta = ["id", "aria-labelledby"], za = ["id", "value", "lang", "name", "rows
|
|
|
955
984
|
rows: {},
|
|
956
985
|
placeholder: {},
|
|
957
986
|
maxLength: {}
|
|
958
|
-
}, { ...
|
|
987
|
+
}, { ...me, locales: void 0, defaultLocale: void 0, requiredLocales: () => [], multiline: !1, rows: 3, placeholder: void 0, maxLength: void 0 }), {
|
|
959
988
|
modelValue: { default: () => ({}) },
|
|
960
989
|
modelModifiers: {}
|
|
961
990
|
}),
|
|
962
991
|
emits: ["update:modelValue"],
|
|
963
|
-
setup(
|
|
964
|
-
const e =
|
|
965
|
-
function
|
|
992
|
+
setup(l, { expose: a }) {
|
|
993
|
+
const e = l, t = re(l, "modelValue"), { t: o, locale: n, availableLocales: u } = oe(), r = at(), m = Je(zt, null), k = Re(), x = U("field"), $ = U("root"), { editable: i } = Qe(e), v = Me(e.multiline ? "area" : "text", () => e.error || Y.value ? "error" : e.disabled ? "locked" : "rest"), g = h(() => e.locales ?? m?.locales ?? u), T = h(() => e.defaultLocale ?? g.value[0] ?? ""), w = h(() => g.value.includes(T.value) ? [T.value, ...g.value.filter((b) => b !== T.value)] : g.value), F = P(null), O = h(() => F.value !== null && w.value.includes(F.value) ? F.value : w.value.includes(n.value) ? n.value : T.value), E = (b) => t.value[b] ?? "", N = (b) => E(b).trim() !== "", V = (b) => b.toUpperCase();
|
|
994
|
+
function Q(b) {
|
|
966
995
|
try {
|
|
967
|
-
return new Intl.DisplayNames([
|
|
996
|
+
return new Intl.DisplayNames([r.intlLocale], { type: "language" }).of(b) ?? V(b);
|
|
968
997
|
} catch {
|
|
969
|
-
return
|
|
998
|
+
return V(b);
|
|
970
999
|
}
|
|
971
1000
|
}
|
|
972
|
-
const
|
|
973
|
-
function
|
|
974
|
-
t.value = { ...t.value, [
|
|
1001
|
+
const ee = (b) => b.map(Q).join(", ");
|
|
1002
|
+
function ne(b, D) {
|
|
1003
|
+
t.value = { ...t.value, [b]: D };
|
|
975
1004
|
}
|
|
976
|
-
const
|
|
977
|
-
function
|
|
978
|
-
|
|
1005
|
+
const ie = (b) => `${k}-tab-${b}`;
|
|
1006
|
+
function ue(b, D) {
|
|
1007
|
+
F.value = b, D && xe(() => x.value?.focus());
|
|
979
1008
|
}
|
|
980
|
-
function
|
|
981
|
-
const
|
|
982
|
-
if (
|
|
983
|
-
|
|
984
|
-
const
|
|
985
|
-
|
|
1009
|
+
function z(b, D) {
|
|
1010
|
+
const L = w.value.length - 1, W = { ArrowRight: D + 1, ArrowLeft: D - 1, Home: 0, End: L }[b.key];
|
|
1011
|
+
if (W === void 0) return;
|
|
1012
|
+
b.preventDefault();
|
|
1013
|
+
const ve = w.value[(W + w.value.length) % w.value.length];
|
|
1014
|
+
ve !== void 0 && (ue(ve, !1), xe(() => document.getElementById(ie(ve))?.focus()));
|
|
986
1015
|
}
|
|
987
|
-
const
|
|
988
|
-
function
|
|
989
|
-
|
|
1016
|
+
const A = P(!1);
|
|
1017
|
+
function K(b) {
|
|
1018
|
+
$.value?.contains(b.relatedTarget) || (A.value = !0);
|
|
990
1019
|
}
|
|
991
|
-
const
|
|
992
|
-
function
|
|
993
|
-
const
|
|
994
|
-
t.value = { ...t.value, ...Object.fromEntries(
|
|
1020
|
+
const te = h(() => Ta(t.value, e.requiredLocales)), Y = h(() => A.value && te.value.length > 0 ? o("core.form.i18n.required", { languages: ee(te.value) }) : void 0), se = h(() => e.requiredLocales.length > 0 ? te.value.length === 0 : w.value.some(N)), he = h(() => w.value.filter((b) => !N(b) && !(Y.value && te.value.includes(b)))), we = h(() => N(T.value) && w.value.some((b) => b !== T.value && !N(b)));
|
|
1021
|
+
function ke() {
|
|
1022
|
+
const b = E(T.value);
|
|
1023
|
+
t.value = { ...t.value, ...Object.fromEntries(w.value.filter((D) => !N(D)).map((D) => [D, b])) };
|
|
995
1024
|
}
|
|
996
|
-
const
|
|
997
|
-
return a({ focus: () =>
|
|
998
|
-
value:
|
|
1025
|
+
const ae = h(() => [n.value, T.value, ...w.value].find((b) => w.value.includes(b) && N(b))), _ = h(() => w.value.filter((b) => b !== ae.value)), c = h(() => _.value.filter(N).length), B = P(!1), M = h(() => e.label && !i.value && ae.value ? `${e.label} · ${V(ae.value)}` : e.label);
|
|
1026
|
+
return a({ focus: () => x.value?.focus() }), (b, D) => (d(), R(ye, J({ ...s(fe)(e), label: M.value, error: e.error ?? Y.value, required: e.required || e.requiredLocales.length > 0 }, {
|
|
1027
|
+
value: s(i) ? se.value ? "written" : null : ae.value ? E(ae.value) : null,
|
|
999
1028
|
"row-layout": "stacked"
|
|
1000
|
-
}),
|
|
1001
|
-
default: f(({ id:
|
|
1002
|
-
|
|
1029
|
+
}), Z({
|
|
1030
|
+
default: f(({ id: L, describedby: W, invalid: ve }) => [
|
|
1031
|
+
p("div", {
|
|
1003
1032
|
ref_key: "root",
|
|
1004
|
-
ref:
|
|
1033
|
+
ref: $,
|
|
1005
1034
|
class: "w-full",
|
|
1006
|
-
onFocusout:
|
|
1035
|
+
onFocusout: K
|
|
1007
1036
|
}, [
|
|
1008
|
-
|
|
1009
|
-
id: `${
|
|
1037
|
+
p("div", {
|
|
1038
|
+
id: `${s(k)}-panel`,
|
|
1010
1039
|
role: "tabpanel",
|
|
1011
|
-
"aria-labelledby":
|
|
1040
|
+
"aria-labelledby": ie(O.value)
|
|
1012
1041
|
}, [
|
|
1013
|
-
|
|
1014
|
-
class:
|
|
1042
|
+
p("div", {
|
|
1043
|
+
class: j(["w-full", s(v)])
|
|
1015
1044
|
}, [
|
|
1016
|
-
e.multiline ? (
|
|
1045
|
+
e.multiline ? (d(), y("textarea", {
|
|
1017
1046
|
key: 0,
|
|
1018
|
-
id:
|
|
1047
|
+
id: L,
|
|
1019
1048
|
ref_key: "field",
|
|
1020
|
-
ref:
|
|
1021
|
-
value: O
|
|
1022
|
-
lang:
|
|
1049
|
+
ref: x,
|
|
1050
|
+
value: E(O.value),
|
|
1051
|
+
lang: O.value,
|
|
1023
1052
|
name: e.name,
|
|
1024
1053
|
rows: e.rows,
|
|
1025
1054
|
placeholder: e.placeholder,
|
|
1026
1055
|
maxlength: e.maxLength,
|
|
1027
1056
|
disabled: e.disabled,
|
|
1028
1057
|
"aria-required": e.required || void 0,
|
|
1029
|
-
"aria-invalid":
|
|
1030
|
-
"aria-describedby":
|
|
1058
|
+
"aria-invalid": ve || void 0,
|
|
1059
|
+
"aria-describedby": W,
|
|
1031
1060
|
"data-test": "i18n-input",
|
|
1032
1061
|
class: "block w-full resize-y border-0 bg-transparent px-0 py-1 text-body text-content-strong placeholder:text-content-disabled focus:outline-none focus:ring-0 disabled:cursor-not-allowed",
|
|
1033
|
-
onInput:
|
|
1034
|
-
}, null, 40, za)) : (
|
|
1062
|
+
onInput: D[0] || (D[0] = (Le) => ne(O.value, Le.target.value))
|
|
1063
|
+
}, null, 40, za)) : (d(), y("input", {
|
|
1035
1064
|
key: 1,
|
|
1036
|
-
id:
|
|
1065
|
+
id: L,
|
|
1037
1066
|
ref_key: "field",
|
|
1038
|
-
ref:
|
|
1039
|
-
value: O
|
|
1040
|
-
lang:
|
|
1067
|
+
ref: x,
|
|
1068
|
+
value: E(O.value),
|
|
1069
|
+
lang: O.value,
|
|
1041
1070
|
type: "text",
|
|
1042
1071
|
name: e.name,
|
|
1043
1072
|
placeholder: e.placeholder,
|
|
1044
1073
|
maxlength: e.maxLength,
|
|
1045
1074
|
disabled: e.disabled,
|
|
1046
1075
|
"aria-required": e.required || void 0,
|
|
1047
|
-
"aria-invalid":
|
|
1048
|
-
"aria-describedby":
|
|
1076
|
+
"aria-invalid": ve || void 0,
|
|
1077
|
+
"aria-describedby": W,
|
|
1049
1078
|
"data-test": "i18n-input",
|
|
1050
1079
|
class: "block w-full min-w-0 border-0 bg-transparent px-0 py-1 text-body text-content-strong placeholder:text-content-disabled focus:outline-none focus:ring-0 disabled:cursor-not-allowed",
|
|
1051
|
-
onInput:
|
|
1080
|
+
onInput: D[1] || (D[1] = (Le) => ne(O.value, Le.target.value))
|
|
1052
1081
|
}, null, 40, Va))
|
|
1053
1082
|
], 2)
|
|
1054
|
-
], 8,
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1083
|
+
], 8, qa),
|
|
1084
|
+
he.value.length > 0 || we.value ? (d(), y("div", Da, [
|
|
1085
|
+
he.value.length > 0 ? (d(), y("p", Ra, C(s(o)("core.form.i18n.missing", { languages: ee(he.value) })), 1)) : (d(), y("span", Ma)),
|
|
1086
|
+
we.value && !e.disabled ? (d(), y("button", {
|
|
1058
1087
|
key: 2,
|
|
1059
1088
|
type: "button",
|
|
1060
1089
|
"data-test": "i18n-copy",
|
|
1061
1090
|
class: "shrink-0 cursor-pointer rounded-control bg-tint-soft px-2.5 py-1.5 text-footnote font-medium text-content-link transition-colors duration-motion-fast hover:bg-fill focus-visible:outline-2 focus-visible:outline-offset-1 focus-visible:outline-border-focus",
|
|
1062
|
-
onClick:
|
|
1063
|
-
},
|
|
1064
|
-
])) :
|
|
1091
|
+
onClick: ke
|
|
1092
|
+
}, C(s(o)("core.form.i18n.copy", { language: V(T.value) })), 1)) : q("", !0)
|
|
1093
|
+
])) : q("", !0)
|
|
1065
1094
|
], 544)
|
|
1066
1095
|
]),
|
|
1067
1096
|
labelTrailing: f(() => [
|
|
1068
|
-
|
|
1097
|
+
p("div", {
|
|
1069
1098
|
role: "tablist",
|
|
1070
|
-
"aria-label":
|
|
1099
|
+
"aria-label": s(o)("core.form.i18n.languages"),
|
|
1071
1100
|
class: "flex shrink-0 gap-0.5 rounded-control bg-fill p-0.5",
|
|
1072
1101
|
"data-test": "i18n-tabs"
|
|
1073
1102
|
}, [
|
|
1074
|
-
(
|
|
1075
|
-
id:
|
|
1076
|
-
key:
|
|
1103
|
+
(d(!0), y(de, null, $e(w.value, (L, W) => (d(), y("button", {
|
|
1104
|
+
id: ie(L),
|
|
1105
|
+
key: L,
|
|
1077
1106
|
type: "button",
|
|
1078
1107
|
role: "tab",
|
|
1079
|
-
"aria-selected":
|
|
1080
|
-
tabindex:
|
|
1081
|
-
"aria-controls": `${
|
|
1082
|
-
"aria-label":
|
|
1083
|
-
title:
|
|
1084
|
-
class:
|
|
1085
|
-
onClick: (
|
|
1086
|
-
onKeydown: (
|
|
1108
|
+
"aria-selected": L === O.value,
|
|
1109
|
+
tabindex: L === O.value ? 0 : -1,
|
|
1110
|
+
"aria-controls": `${s(k)}-panel`,
|
|
1111
|
+
"aria-label": s(o)(N(L) ? "core.form.i18n.tab_written" : "core.form.i18n.tab_empty", { language: Q(L) }),
|
|
1112
|
+
title: Q(L),
|
|
1113
|
+
class: j(["flex min-h-7 cursor-pointer items-center gap-1.5 rounded-control px-2.5 py-1 text-footnote font-semibold transition-colors duration-motion-fast focus-visible:outline-2 focus-visible:outline-offset-1 focus-visible:outline-border-focus", L === O.value ? "bg-segment-selected text-content-strong shadow-sm" : "text-content-muted hover:text-content-strong"]),
|
|
1114
|
+
onClick: (ve) => ue(L, !0),
|
|
1115
|
+
onKeydown: (ve) => z(ve, W)
|
|
1087
1116
|
}, [
|
|
1088
|
-
H(
|
|
1089
|
-
|
|
1117
|
+
H(C(V(L)) + " ", 1),
|
|
1118
|
+
p("span", {
|
|
1090
1119
|
"aria-hidden": "true",
|
|
1091
|
-
class:
|
|
1120
|
+
class: j(["size-1.5 rounded-full", N(L) ? "bg-status-success-solid" : Y.value && te.value.includes(L) ? "bg-content-destructive" : "bg-content-disabled"]),
|
|
1092
1121
|
"data-test": "i18n-dot",
|
|
1093
|
-
"data-state":
|
|
1094
|
-
}, null, 10,
|
|
1122
|
+
"data-state": N(L) ? "written" : Y.value && te.value.includes(L) ? "required" : "empty"
|
|
1123
|
+
}, null, 10, Oa)
|
|
1095
1124
|
], 42, ja))), 128))
|
|
1096
|
-
], 8,
|
|
1125
|
+
], 8, Ia)
|
|
1097
1126
|
]),
|
|
1098
1127
|
_: 2
|
|
1099
1128
|
}, [
|
|
1100
|
-
|
|
1129
|
+
ae.value ? {
|
|
1101
1130
|
name: "readonly",
|
|
1102
1131
|
fn: f(() => [
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1132
|
+
p("div", Ea, [
|
|
1133
|
+
p("p", Na, C(E(ae.value)), 1),
|
|
1134
|
+
_.value.length > 0 ? (d(), y(de, { key: 0 }, [
|
|
1135
|
+
p("button", {
|
|
1107
1136
|
type: "button",
|
|
1108
|
-
"aria-expanded":
|
|
1137
|
+
"aria-expanded": B.value,
|
|
1109
1138
|
class: "mt-1.5 flex w-full cursor-pointer items-center gap-2 text-left text-footnote text-content-muted focus-visible:outline-2 focus-visible:outline-offset-1 focus-visible:outline-border-focus",
|
|
1110
|
-
onClick:
|
|
1139
|
+
onClick: D[2] || (D[2] = (L) => B.value = !B.value)
|
|
1111
1140
|
}, [
|
|
1112
|
-
|
|
1113
|
-
|
|
1141
|
+
p("span", Ga, C(s(o)("core.form.i18n.more", { count: _.value.length, filled: c.value })), 1),
|
|
1142
|
+
I(s(X), {
|
|
1114
1143
|
name: "arrowRightSLine",
|
|
1115
1144
|
size: 16,
|
|
1116
|
-
class:
|
|
1145
|
+
class: j(["shrink-0 transition-transform duration-motion-fast", B.value ? "rotate-90" : ""])
|
|
1117
1146
|
}, null, 8, ["class"])
|
|
1118
|
-
], 8,
|
|
1119
|
-
|
|
1120
|
-
(
|
|
1121
|
-
key:
|
|
1147
|
+
], 8, Aa),
|
|
1148
|
+
B.value ? (d(), y("dl", Ka, [
|
|
1149
|
+
(d(!0), y(de, null, $e(_.value, (L) => (d(), y("div", {
|
|
1150
|
+
key: L,
|
|
1122
1151
|
class: "flex gap-2 text-body"
|
|
1123
1152
|
}, [
|
|
1124
|
-
|
|
1153
|
+
p("dt", {
|
|
1125
1154
|
class: "w-8 shrink-0 text-footnote font-semibold leading-6 text-content-muted",
|
|
1126
|
-
title:
|
|
1127
|
-
},
|
|
1128
|
-
|
|
1129
|
-
class:
|
|
1130
|
-
},
|
|
1155
|
+
title: Q(L)
|
|
1156
|
+
}, C(V(L)), 9, Pa),
|
|
1157
|
+
p("dd", {
|
|
1158
|
+
class: j(["min-w-0 flex-1 whitespace-pre-line break-words", N(L) ? "text-content-strong" : "text-content-disabled"])
|
|
1159
|
+
}, C(N(L) ? E(L) : s(o)("core.state.no_value")), 3)
|
|
1131
1160
|
]))), 128))
|
|
1132
|
-
])) :
|
|
1133
|
-
], 64)) :
|
|
1161
|
+
])) : q("", !0)
|
|
1162
|
+
], 64)) : q("", !0)
|
|
1134
1163
|
])
|
|
1135
1164
|
]),
|
|
1136
1165
|
key: "0"
|
|
1137
1166
|
} : void 0,
|
|
1138
|
-
|
|
1167
|
+
b.$slots.trailing ? {
|
|
1139
1168
|
name: "trailing",
|
|
1140
1169
|
fn: f(() => [
|
|
1141
|
-
|
|
1170
|
+
S(b.$slots, "trailing")
|
|
1142
1171
|
]),
|
|
1143
1172
|
key: "1"
|
|
1144
1173
|
} : void 0
|
|
1145
1174
|
]), 1040, ["value"]));
|
|
1146
1175
|
}
|
|
1147
|
-
}),
|
|
1148
|
-
function
|
|
1149
|
-
return
|
|
1176
|
+
}), Ha = "unsupported_characters", Ua = /[\u{10000}-\u{10FFFF}]/u;
|
|
1177
|
+
function Ya(l) {
|
|
1178
|
+
return Ua.test(l);
|
|
1150
1179
|
}
|
|
1151
|
-
function
|
|
1152
|
-
if (typeof
|
|
1153
|
-
|
|
1154
|
-
else if (Array.isArray(
|
|
1155
|
-
|
|
1156
|
-
else if (
|
|
1157
|
-
for (const [t,
|
|
1180
|
+
function De(l, a, e) {
|
|
1181
|
+
if (typeof l == "string")
|
|
1182
|
+
Ya(l) && e.addIssue({ code: "custom", path: a, params: { code: Ha } });
|
|
1183
|
+
else if (Array.isArray(l))
|
|
1184
|
+
l.forEach((t, o) => De(t, [...a, o], e));
|
|
1185
|
+
else if (l && typeof l == "object")
|
|
1186
|
+
for (const [t, o] of Object.entries(l)) De(o, [...a, t], e);
|
|
1158
1187
|
}
|
|
1159
|
-
function
|
|
1160
|
-
|
|
1188
|
+
function go(l, a) {
|
|
1189
|
+
De(l, [], a);
|
|
1161
1190
|
}
|
|
1162
|
-
const yo = /* @__PURE__ */
|
|
1191
|
+
const yo = /* @__PURE__ */ G({
|
|
1163
1192
|
__name: "MoneyField",
|
|
1164
|
-
props: /* @__PURE__ */
|
|
1193
|
+
props: /* @__PURE__ */ ce({
|
|
1165
1194
|
label: {},
|
|
1166
1195
|
labelHidden: { type: Boolean },
|
|
1167
1196
|
hint: {},
|
|
@@ -1178,50 +1207,50 @@ const yo = /* @__PURE__ */ A({
|
|
|
1178
1207
|
blankZero: { type: Boolean },
|
|
1179
1208
|
negative: { type: Boolean },
|
|
1180
1209
|
width: {}
|
|
1181
|
-
}, { ...
|
|
1210
|
+
}, { ...me, modelValue: void 0, decimals: 2, blankZero: !1, negative: !1, width: "sm" }),
|
|
1182
1211
|
emits: ["update:modelValue", "focus", "blur"],
|
|
1183
|
-
setup(
|
|
1184
|
-
const t =
|
|
1185
|
-
return a({ focus: () => n.value?.focus() }), (
|
|
1212
|
+
setup(l, { expose: a, emit: e }) {
|
|
1213
|
+
const t = l, o = e, n = U("field");
|
|
1214
|
+
return a({ focus: () => n.value?.focus() }), (u, r) => (d(), R(Vt, J({
|
|
1186
1215
|
ref_key: "field",
|
|
1187
1216
|
ref: n,
|
|
1188
1217
|
"model-value": t.modelValue,
|
|
1189
|
-
"onUpdate:modelValue":
|
|
1190
|
-
},
|
|
1218
|
+
"onUpdate:modelValue": r[0] || (r[0] = (m) => o("update:modelValue", m))
|
|
1219
|
+
}, s(fe)(t), {
|
|
1191
1220
|
decimals: t.decimals,
|
|
1192
1221
|
negative: t.negative,
|
|
1193
1222
|
"blank-zero": t.blankZero,
|
|
1194
1223
|
suffix: t.currency,
|
|
1195
1224
|
width: t.width,
|
|
1196
|
-
onFocus:
|
|
1197
|
-
onBlur:
|
|
1198
|
-
}),
|
|
1199
|
-
|
|
1225
|
+
onFocus: r[1] || (r[1] = (m) => o("focus", m)),
|
|
1226
|
+
onBlur: r[2] || (r[2] = (m) => o("blur", m))
|
|
1227
|
+
}), Z({ _: 2 }, [
|
|
1228
|
+
u.$slots.trailing ? {
|
|
1200
1229
|
name: "trailing",
|
|
1201
1230
|
fn: f(() => [
|
|
1202
|
-
|
|
1231
|
+
S(u.$slots, "trailing")
|
|
1203
1232
|
]),
|
|
1204
1233
|
key: "0"
|
|
1205
1234
|
} : void 0,
|
|
1206
|
-
|
|
1235
|
+
u.$slots.labelTrailing ? {
|
|
1207
1236
|
name: "labelTrailing",
|
|
1208
1237
|
fn: f(() => [
|
|
1209
|
-
|
|
1238
|
+
S(u.$slots, "labelTrailing")
|
|
1210
1239
|
]),
|
|
1211
1240
|
key: "1"
|
|
1212
1241
|
} : void 0,
|
|
1213
|
-
|
|
1242
|
+
u.$slots.readonly ? {
|
|
1214
1243
|
name: "readonly",
|
|
1215
1244
|
fn: f(() => [
|
|
1216
|
-
|
|
1245
|
+
S(u.$slots, "readonly")
|
|
1217
1246
|
]),
|
|
1218
1247
|
key: "2"
|
|
1219
1248
|
} : void 0
|
|
1220
1249
|
]), 1040, ["model-value", "decimals", "negative", "blank-zero", "suffix", "width"]));
|
|
1221
1250
|
}
|
|
1222
|
-
}),
|
|
1251
|
+
}), Wa = { class: "flex flex-col gap-2" }, Ja = ["onClick"], ho = /* @__PURE__ */ G({
|
|
1223
1252
|
__name: "MonthYearField",
|
|
1224
|
-
props: /* @__PURE__ */ le(/* @__PURE__ */
|
|
1253
|
+
props: /* @__PURE__ */ le(/* @__PURE__ */ ce({
|
|
1225
1254
|
label: {},
|
|
1226
1255
|
labelHidden: { type: Boolean },
|
|
1227
1256
|
hint: {},
|
|
@@ -1235,67 +1264,67 @@ const yo = /* @__PURE__ */ A({
|
|
|
1235
1264
|
minYear: {},
|
|
1236
1265
|
maxYear: {},
|
|
1237
1266
|
placeholder: {}
|
|
1238
|
-
}, { ...
|
|
1267
|
+
}, { ...me, placeholder: void 0, minYear: 1970, maxYear: () => (/* @__PURE__ */ new Date()).getFullYear() + 1 }), {
|
|
1239
1268
|
month: { default: null },
|
|
1240
1269
|
monthModifiers: {},
|
|
1241
1270
|
year: { default: null },
|
|
1242
1271
|
yearModifiers: {}
|
|
1243
1272
|
}),
|
|
1244
1273
|
emits: ["update:month", "update:year"],
|
|
1245
|
-
setup(
|
|
1246
|
-
const a =
|
|
1247
|
-
function
|
|
1248
|
-
e.value =
|
|
1274
|
+
setup(l) {
|
|
1275
|
+
const a = l, e = re(l, "month"), t = re(l, "year"), { t: o } = oe(), n = h(() => e.value !== null && e.value >= 1 && e.value <= 12), u = (x, $) => o(`core.form.months.${$}.${x}`), r = h(() => n.value && t.value !== null ? o("core.form.months.with_year", { month: u(e.value, "long"), year: t.value }) : t.value !== null ? String(t.value) : n.value ? u(e.value, "long") : "");
|
|
1276
|
+
function m(x, $) {
|
|
1277
|
+
e.value = x.month, t.value = x.year, $();
|
|
1249
1278
|
}
|
|
1250
|
-
function k(
|
|
1251
|
-
e.value = null, t.value = null,
|
|
1279
|
+
function k(x) {
|
|
1280
|
+
e.value = null, t.value = null, x();
|
|
1252
1281
|
}
|
|
1253
|
-
return (
|
|
1254
|
-
value:
|
|
1255
|
-
}),
|
|
1256
|
-
default: f(({ id:
|
|
1257
|
-
|
|
1258
|
-
label: a.label ??
|
|
1282
|
+
return (x, $) => (d(), R(ye, J(s(fe)(a), {
|
|
1283
|
+
value: r.value || null
|
|
1284
|
+
}), Z({
|
|
1285
|
+
default: f(({ id: i, describedby: v, invalid: g }) => [
|
|
1286
|
+
I(je, {
|
|
1287
|
+
label: a.label ?? r.value,
|
|
1259
1288
|
width: "sm",
|
|
1260
1289
|
placement: "bottom-start",
|
|
1261
1290
|
arrow: !1
|
|
1262
1291
|
}, {
|
|
1263
|
-
trigger: f(({ toggle:
|
|
1264
|
-
|
|
1265
|
-
expanded:
|
|
1292
|
+
trigger: f(({ toggle: T, presented: w }) => [
|
|
1293
|
+
I(tt, J({ id: i, "aria-describedby": v }, {
|
|
1294
|
+
expanded: w,
|
|
1266
1295
|
disabled: a.disabled,
|
|
1267
|
-
invalid:
|
|
1268
|
-
placeholder: a.placeholder ??
|
|
1269
|
-
onClick:
|
|
1296
|
+
invalid: g,
|
|
1297
|
+
placeholder: a.placeholder ?? s(o)("core.form.select.choose"),
|
|
1298
|
+
onClick: T
|
|
1270
1299
|
}), {
|
|
1271
1300
|
default: f(() => [
|
|
1272
|
-
|
|
1273
|
-
H(
|
|
1274
|
-
|
|
1301
|
+
r.value ? (d(), y(de, { key: 0 }, [
|
|
1302
|
+
H(C(r.value), 1),
|
|
1303
|
+
I(s(X), {
|
|
1275
1304
|
name: "calendarLine",
|
|
1276
1305
|
size: 16,
|
|
1277
1306
|
class: "ml-2 shrink-0 text-content-muted"
|
|
1278
1307
|
})
|
|
1279
|
-
], 64)) :
|
|
1308
|
+
], 64)) : q("", !0)
|
|
1280
1309
|
]),
|
|
1281
1310
|
_: 1
|
|
1282
1311
|
}, 16, ["expanded", "disabled", "invalid", "placeholder", "onClick"])
|
|
1283
1312
|
]),
|
|
1284
|
-
default: f(({ dismiss:
|
|
1285
|
-
|
|
1286
|
-
|
|
1313
|
+
default: f(({ dismiss: T }) => [
|
|
1314
|
+
p("div", Wa, [
|
|
1315
|
+
I(Ft, {
|
|
1287
1316
|
month: e.value,
|
|
1288
1317
|
year: t.value,
|
|
1289
1318
|
"min-year": a.minYear,
|
|
1290
1319
|
"max-year": a.maxYear,
|
|
1291
|
-
onPick: (
|
|
1320
|
+
onPick: (w) => m(w, T)
|
|
1292
1321
|
}, null, 8, ["month", "year", "min-year", "max-year", "onPick"]),
|
|
1293
|
-
n.value || t.value !== null ? (
|
|
1322
|
+
n.value || t.value !== null ? (d(), y("button", {
|
|
1294
1323
|
key: 0,
|
|
1295
1324
|
type: "button",
|
|
1296
1325
|
class: "cursor-pointer self-start rounded-control px-1 text-footnote text-content-link",
|
|
1297
|
-
onClick: (
|
|
1298
|
-
},
|
|
1326
|
+
onClick: (w) => k(T)
|
|
1327
|
+
}, C(s(o)("core.form.select.clear")), 9, Ja)) : q("", !0)
|
|
1299
1328
|
])
|
|
1300
1329
|
]),
|
|
1301
1330
|
_: 2
|
|
@@ -1303,32 +1332,32 @@ const yo = /* @__PURE__ */ A({
|
|
|
1303
1332
|
]),
|
|
1304
1333
|
_: 2
|
|
1305
1334
|
}, [
|
|
1306
|
-
|
|
1335
|
+
x.$slots.trailing ? {
|
|
1307
1336
|
name: "trailing",
|
|
1308
1337
|
fn: f(() => [
|
|
1309
|
-
|
|
1338
|
+
S(x.$slots, "trailing")
|
|
1310
1339
|
]),
|
|
1311
1340
|
key: "0"
|
|
1312
1341
|
} : void 0,
|
|
1313
|
-
|
|
1342
|
+
x.$slots.labelTrailing ? {
|
|
1314
1343
|
name: "labelTrailing",
|
|
1315
1344
|
fn: f(() => [
|
|
1316
|
-
|
|
1345
|
+
S(x.$slots, "labelTrailing")
|
|
1317
1346
|
]),
|
|
1318
1347
|
key: "1"
|
|
1319
1348
|
} : void 0,
|
|
1320
|
-
|
|
1349
|
+
x.$slots.readonly ? {
|
|
1321
1350
|
name: "readonly",
|
|
1322
1351
|
fn: f(() => [
|
|
1323
|
-
|
|
1352
|
+
S(x.$slots, "readonly")
|
|
1324
1353
|
]),
|
|
1325
1354
|
key: "2"
|
|
1326
1355
|
} : void 0
|
|
1327
1356
|
]), 1040, ["value"]));
|
|
1328
1357
|
}
|
|
1329
|
-
}),
|
|
1358
|
+
}), Za = { class: "flex min-w-0 flex-wrap items-center gap-1.5 py-0.5" }, Xa = { class: "truncate" }, Qa = ["disabled", "aria-label", "onClick"], el = ["id", "disabled", "aria-expanded", "aria-invalid", "aria-describedby", "aria-busy"], tl = ["id", "disabled", "aria-invalid", "aria-describedby", "aria-busy", "onClick"], al = { class: "max-h-72 overflow-y-auto" }, ll = { class: "flex items-center justify-between gap-2" }, Ue = "inline-flex min-h-7 cursor-pointer items-center gap-1 rounded-control bg-fill px-2.5 py-1 text-body text-content-muted hover:bg-fill-strong focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-border-focus disabled:cursor-not-allowed disabled:opacity-45", ko = /* @__PURE__ */ G({
|
|
1330
1359
|
__name: "MultiSelectField",
|
|
1331
|
-
props: /* @__PURE__ */ le(/* @__PURE__ */
|
|
1360
|
+
props: /* @__PURE__ */ le(/* @__PURE__ */ ce({
|
|
1332
1361
|
label: {},
|
|
1333
1362
|
labelHidden: { type: Boolean },
|
|
1334
1363
|
hint: {},
|
|
@@ -1343,69 +1372,69 @@ const yo = /* @__PURE__ */ A({
|
|
|
1343
1372
|
selected: {},
|
|
1344
1373
|
placeholder: {},
|
|
1345
1374
|
searchFrom: {}
|
|
1346
|
-
}, { ...
|
|
1375
|
+
}, { ...me, selected: () => [], placeholder: void 0, searchFrom: 9 }), {
|
|
1347
1376
|
modelValue: { default: () => [] },
|
|
1348
1377
|
modelModifiers: {}
|
|
1349
1378
|
}),
|
|
1350
1379
|
emits: ["update:modelValue"],
|
|
1351
|
-
setup(
|
|
1352
|
-
const a =
|
|
1353
|
-
const
|
|
1354
|
-
|
|
1355
|
-
}),
|
|
1356
|
-
const
|
|
1357
|
-
return
|
|
1380
|
+
setup(l) {
|
|
1381
|
+
const a = l, e = re(l, "modelValue"), { t } = oe(), o = Ie(), n = U("sheet"), u = P(!1), r = Rt(() => a.options, (i) => {
|
|
1382
|
+
const v = e.value.filter((g) => i.some((T) => T.value === g));
|
|
1383
|
+
v.length !== e.value.length && (e.value = v);
|
|
1384
|
+
}), m = h(() => e.value.flatMap((i) => {
|
|
1385
|
+
const v = r.known.value.find((g) => g.value === i) ?? a.selected.find((g) => g.value === i);
|
|
1386
|
+
return v ? [v] : [];
|
|
1358
1387
|
})), k = h(() => a.placeholder ?? t("core.form.select.choose"));
|
|
1359
|
-
function
|
|
1360
|
-
|
|
1388
|
+
function x(i) {
|
|
1389
|
+
i !== null && (e.value = e.value.includes(i) ? e.value.filter((v) => v !== i) : [...e.value, i]);
|
|
1361
1390
|
}
|
|
1362
|
-
const $ = (
|
|
1363
|
-
return (
|
|
1364
|
-
value:
|
|
1391
|
+
const $ = (i) => e.value = e.value.filter((v) => v !== i);
|
|
1392
|
+
return (i, v) => (d(), R(ye, J(s(fe)(a), {
|
|
1393
|
+
value: m.value.length ? m.value.map((g) => g.label).join(", ") : null,
|
|
1365
1394
|
"row-layout": "stacked"
|
|
1366
|
-
}),
|
|
1367
|
-
default: f(({ id:
|
|
1368
|
-
|
|
1369
|
-
(
|
|
1370
|
-
key: String(
|
|
1395
|
+
}), Z({
|
|
1396
|
+
default: f(({ id: g, describedby: T, invalid: w }) => [
|
|
1397
|
+
p("div", Za, [
|
|
1398
|
+
(d(!0), y(de, null, $e(m.value, (F) => (d(), y("span", {
|
|
1399
|
+
key: String(F.value),
|
|
1371
1400
|
"data-test": "chip",
|
|
1372
1401
|
class: "inline-flex min-h-7 max-w-full items-center gap-1 rounded-full bg-tint-soft pl-3 pr-1 text-subheadline font-medium text-content-link"
|
|
1373
1402
|
}, [
|
|
1374
|
-
|
|
1375
|
-
|
|
1403
|
+
p("span", Xa, C(F.label), 1),
|
|
1404
|
+
p("button", {
|
|
1376
1405
|
type: "button",
|
|
1377
1406
|
disabled: a.disabled,
|
|
1378
|
-
"aria-label": `${
|
|
1407
|
+
"aria-label": `${s(t)("core.form.select.clear")}: ${F.label}`,
|
|
1379
1408
|
class: "flex size-5 shrink-0 cursor-pointer items-center justify-center rounded-full hover:bg-fill focus-visible:outline-2 focus-visible:outline-border-focus disabled:cursor-not-allowed",
|
|
1380
|
-
onClick: (O) => $(
|
|
1409
|
+
onClick: (O) => $(F.value)
|
|
1381
1410
|
}, [
|
|
1382
|
-
|
|
1411
|
+
I(s(X), {
|
|
1383
1412
|
name: "close",
|
|
1384
1413
|
size: 12
|
|
1385
1414
|
})
|
|
1386
|
-
], 8,
|
|
1415
|
+
], 8, Qa)
|
|
1387
1416
|
]))), 128)),
|
|
1388
|
-
|
|
1417
|
+
s(o) ? (d(), y("button", {
|
|
1389
1418
|
key: 0,
|
|
1390
|
-
id:
|
|
1419
|
+
id: g,
|
|
1391
1420
|
type: "button",
|
|
1392
1421
|
disabled: a.disabled,
|
|
1393
1422
|
"aria-haspopup": "dialog",
|
|
1394
|
-
"aria-expanded":
|
|
1395
|
-
"aria-invalid":
|
|
1396
|
-
"aria-describedby":
|
|
1397
|
-
"aria-busy":
|
|
1398
|
-
class:
|
|
1399
|
-
onClick:
|
|
1423
|
+
"aria-expanded": u.value,
|
|
1424
|
+
"aria-invalid": w || void 0,
|
|
1425
|
+
"aria-describedby": T,
|
|
1426
|
+
"aria-busy": s(r).loading.value || void 0,
|
|
1427
|
+
class: j(Ue),
|
|
1428
|
+
onClick: v[0] || (v[0] = (F) => n.value?.present())
|
|
1400
1429
|
}, [
|
|
1401
|
-
|
|
1430
|
+
s(r).loading.value ? (d(), R(s(X), {
|
|
1402
1431
|
key: 0,
|
|
1403
1432
|
name: "loader4Line",
|
|
1404
1433
|
size: 14,
|
|
1405
1434
|
class: "shrink-0 animate-spin"
|
|
1406
|
-
})) :
|
|
1407
|
-
H(" " +
|
|
1408
|
-
], 8,
|
|
1435
|
+
})) : q("", !0),
|
|
1436
|
+
H(" " + C(m.value.length ? s(t)("core.actions.edit") : k.value), 1)
|
|
1437
|
+
], 8, el)) : (d(), R(je, {
|
|
1409
1438
|
key: 1,
|
|
1410
1439
|
label: a.label ?? k.value,
|
|
1411
1440
|
width: "lg",
|
|
@@ -1413,44 +1442,44 @@ const yo = /* @__PURE__ */ A({
|
|
|
1413
1442
|
placement: "bottom-start",
|
|
1414
1443
|
arrow: !1
|
|
1415
1444
|
}, {
|
|
1416
|
-
trigger: f(({ toggle:
|
|
1417
|
-
|
|
1418
|
-
id:
|
|
1445
|
+
trigger: f(({ toggle: F, attrs: O }) => [
|
|
1446
|
+
p("button", J({
|
|
1447
|
+
id: g,
|
|
1419
1448
|
type: "button"
|
|
1420
1449
|
}, O, {
|
|
1421
1450
|
"aria-haspopup": "listbox",
|
|
1422
1451
|
disabled: a.disabled,
|
|
1423
|
-
"aria-invalid":
|
|
1424
|
-
"aria-describedby":
|
|
1425
|
-
"aria-busy":
|
|
1426
|
-
class:
|
|
1427
|
-
onClick:
|
|
1452
|
+
"aria-invalid": w || void 0,
|
|
1453
|
+
"aria-describedby": T,
|
|
1454
|
+
"aria-busy": s(r).loading.value || void 0,
|
|
1455
|
+
class: Ue,
|
|
1456
|
+
onClick: F
|
|
1428
1457
|
}), [
|
|
1429
|
-
|
|
1458
|
+
s(r).loading.value ? (d(), R(s(X), {
|
|
1430
1459
|
key: 0,
|
|
1431
1460
|
name: "loader4Line",
|
|
1432
1461
|
size: 14,
|
|
1433
1462
|
class: "shrink-0 animate-spin"
|
|
1434
|
-
})) :
|
|
1435
|
-
H(" " +
|
|
1436
|
-
], 16,
|
|
1463
|
+
})) : q("", !0),
|
|
1464
|
+
H(" " + C(m.value.length ? s(t)("core.actions.edit") : k.value), 1)
|
|
1465
|
+
], 16, tl)
|
|
1437
1466
|
]),
|
|
1438
1467
|
default: f(() => [
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
options:
|
|
1442
|
-
status:
|
|
1468
|
+
p("div", al, [
|
|
1469
|
+
I(Ke, {
|
|
1470
|
+
options: s(r).rows.value,
|
|
1471
|
+
status: s(r).status.value,
|
|
1443
1472
|
"model-value": e.value,
|
|
1444
1473
|
multiple: "",
|
|
1445
1474
|
"search-from": a.searchFrom,
|
|
1446
1475
|
presentation: "plain",
|
|
1447
|
-
onSelect:
|
|
1448
|
-
onRetry:
|
|
1449
|
-
},
|
|
1450
|
-
|
|
1476
|
+
onSelect: x,
|
|
1477
|
+
onRetry: v[1] || (v[1] = (F) => s(r).reload())
|
|
1478
|
+
}, Z({ _: 2 }, [
|
|
1479
|
+
i.$slots.option ? {
|
|
1451
1480
|
name: "option",
|
|
1452
|
-
fn: f((
|
|
1453
|
-
|
|
1481
|
+
fn: f((F) => [
|
|
1482
|
+
S(i.$slots, "option", ze(Ve(F)))
|
|
1454
1483
|
]),
|
|
1455
1484
|
key: "0"
|
|
1456
1485
|
} : void 0
|
|
@@ -1460,88 +1489,88 @@ const yo = /* @__PURE__ */ A({
|
|
|
1460
1489
|
_: 2
|
|
1461
1490
|
}, 1032, ["label"]))
|
|
1462
1491
|
]),
|
|
1463
|
-
|
|
1492
|
+
s(o) ? (d(), R(Dt, {
|
|
1464
1493
|
key: 0,
|
|
1465
1494
|
ref_key: "sheet",
|
|
1466
1495
|
ref: n,
|
|
1467
1496
|
title: a.label ?? k.value,
|
|
1468
1497
|
grouped: "",
|
|
1469
|
-
onPresented:
|
|
1470
|
-
onDismissed:
|
|
1498
|
+
onPresented: v[5] || (v[5] = (F) => u.value = !0),
|
|
1499
|
+
onDismissed: v[6] || (v[6] = (F) => u.value = !1)
|
|
1471
1500
|
}, {
|
|
1472
1501
|
footer: f(() => [
|
|
1473
|
-
|
|
1474
|
-
|
|
1502
|
+
p("div", ll, [
|
|
1503
|
+
I(be, {
|
|
1475
1504
|
prominence: "plain",
|
|
1476
1505
|
disabled: e.value.length === 0,
|
|
1477
|
-
onClick:
|
|
1506
|
+
onClick: v[3] || (v[3] = (F) => e.value = [])
|
|
1478
1507
|
}, {
|
|
1479
1508
|
default: f(() => [
|
|
1480
|
-
H(
|
|
1509
|
+
H(C(s(t)("core.form.select.clear")), 1)
|
|
1481
1510
|
]),
|
|
1482
1511
|
_: 1
|
|
1483
1512
|
}, 8, ["disabled"]),
|
|
1484
|
-
|
|
1513
|
+
I(be, {
|
|
1485
1514
|
prominence: "primary",
|
|
1486
|
-
onClick:
|
|
1515
|
+
onClick: v[4] || (v[4] = (F) => n.value?.dismiss())
|
|
1487
1516
|
}, {
|
|
1488
1517
|
default: f(() => [
|
|
1489
|
-
H(
|
|
1518
|
+
H(C(s(t)("core.form.select.done")), 1)
|
|
1490
1519
|
]),
|
|
1491
1520
|
_: 1
|
|
1492
1521
|
})
|
|
1493
1522
|
])
|
|
1494
1523
|
]),
|
|
1495
1524
|
default: f(() => [
|
|
1496
|
-
|
|
1497
|
-
options:
|
|
1498
|
-
status:
|
|
1525
|
+
I(Ke, {
|
|
1526
|
+
options: s(r).rows.value,
|
|
1527
|
+
status: s(r).status.value,
|
|
1499
1528
|
"model-value": e.value,
|
|
1500
1529
|
multiple: "",
|
|
1501
1530
|
"search-from": a.searchFrom,
|
|
1502
|
-
onSelect:
|
|
1503
|
-
onRetry:
|
|
1504
|
-
},
|
|
1505
|
-
|
|
1531
|
+
onSelect: x,
|
|
1532
|
+
onRetry: v[2] || (v[2] = (F) => s(r).reload())
|
|
1533
|
+
}, Z({ _: 2 }, [
|
|
1534
|
+
i.$slots.option ? {
|
|
1506
1535
|
name: "option",
|
|
1507
|
-
fn: f((
|
|
1508
|
-
|
|
1536
|
+
fn: f((F) => [
|
|
1537
|
+
S(i.$slots, "option", ze(Ve(F)))
|
|
1509
1538
|
]),
|
|
1510
1539
|
key: "0"
|
|
1511
1540
|
} : void 0
|
|
1512
1541
|
]), 1032, ["options", "status", "model-value", "search-from"])
|
|
1513
1542
|
]),
|
|
1514
1543
|
_: 3
|
|
1515
|
-
}, 8, ["title"])) :
|
|
1544
|
+
}, 8, ["title"])) : q("", !0)
|
|
1516
1545
|
]),
|
|
1517
1546
|
_: 2
|
|
1518
1547
|
}, [
|
|
1519
|
-
|
|
1548
|
+
i.$slots.trailing ? {
|
|
1520
1549
|
name: "trailing",
|
|
1521
1550
|
fn: f(() => [
|
|
1522
|
-
|
|
1551
|
+
S(i.$slots, "trailing")
|
|
1523
1552
|
]),
|
|
1524
1553
|
key: "0"
|
|
1525
1554
|
} : void 0,
|
|
1526
|
-
|
|
1555
|
+
i.$slots.labelTrailing ? {
|
|
1527
1556
|
name: "labelTrailing",
|
|
1528
1557
|
fn: f(() => [
|
|
1529
|
-
|
|
1558
|
+
S(i.$slots, "labelTrailing")
|
|
1530
1559
|
]),
|
|
1531
1560
|
key: "1"
|
|
1532
1561
|
} : void 0,
|
|
1533
|
-
|
|
1562
|
+
i.$slots.readonly ? {
|
|
1534
1563
|
name: "readonly",
|
|
1535
1564
|
fn: f(() => [
|
|
1536
|
-
|
|
1565
|
+
S(i.$slots, "readonly")
|
|
1537
1566
|
]),
|
|
1538
1567
|
key: "2"
|
|
1539
1568
|
} : void 0
|
|
1540
1569
|
]), 1040, ["value"]));
|
|
1541
1570
|
}
|
|
1542
|
-
}),
|
|
1571
|
+
}), ol = ["aria-label"], nl = ["src"], sl = { class: "flex flex-wrap items-center gap-3" }, rl = ["id", "accept", "disabled", "aria-describedby", "aria-invalid"], il = ["aria-label"], ul = ["src"], xo = /* @__PURE__ */ G({
|
|
1543
1572
|
__name: "PhotoField",
|
|
1544
|
-
props: /* @__PURE__ */ le(/* @__PURE__ */
|
|
1573
|
+
props: /* @__PURE__ */ le(/* @__PURE__ */ ce({
|
|
1545
1574
|
label: {},
|
|
1546
1575
|
labelHidden: { type: Boolean },
|
|
1547
1576
|
hint: {},
|
|
@@ -1554,181 +1583,181 @@ const yo = /* @__PURE__ */ A({
|
|
|
1554
1583
|
name: {},
|
|
1555
1584
|
accept: {},
|
|
1556
1585
|
maxSize: {}
|
|
1557
|
-
}, { ...
|
|
1586
|
+
}, { ...me, accept: () => ["image/jpeg", "image/png", "image/webp", "image/gif"], maxSize: 5 * 1024 * 1024 }), {
|
|
1558
1587
|
modelValue: { default: null },
|
|
1559
1588
|
modelModifiers: {}
|
|
1560
1589
|
}),
|
|
1561
1590
|
emits: ["update:modelValue"],
|
|
1562
|
-
setup(
|
|
1563
|
-
const a =
|
|
1564
|
-
function
|
|
1565
|
-
|
|
1591
|
+
setup(l) {
|
|
1592
|
+
const a = l, e = re(l, "modelValue"), { t } = oe(), o = U("chooser"), n = P(null), u = P(null);
|
|
1593
|
+
function r() {
|
|
1594
|
+
u.value && URL.revokeObjectURL(u.value), u.value = null;
|
|
1566
1595
|
}
|
|
1567
|
-
|
|
1596
|
+
ge(
|
|
1568
1597
|
e,
|
|
1569
|
-
(
|
|
1570
|
-
|
|
1598
|
+
(i) => {
|
|
1599
|
+
r(), i instanceof File && (u.value = URL.createObjectURL(i)), i === null && o.value && (o.value.value = "");
|
|
1571
1600
|
},
|
|
1572
1601
|
{ immediate: !0 }
|
|
1573
|
-
),
|
|
1574
|
-
const
|
|
1575
|
-
function $(
|
|
1576
|
-
if (!
|
|
1577
|
-
const
|
|
1578
|
-
|
|
1602
|
+
), Ze(r);
|
|
1603
|
+
const m = h(() => e.value instanceof File ? u.value : e.value), k = U("viewer"), x = h(() => m.value ? [{ src: m.value, alt: a.label ?? t("core.viewer.label"), downloadName: e.value instanceof File ? e.value.name : void 0 }] : []);
|
|
1604
|
+
function $(i) {
|
|
1605
|
+
if (!i) return;
|
|
1606
|
+
const v = lt(i, { accept: a.accept, maxSize: a.maxSize });
|
|
1607
|
+
v ? n.value = v === "invalid_type" ? t("core.form.file.invalid_type") : t("core.form.file.too_large", { size: Be(a.maxSize) }) : (n.value = null, e.value = i);
|
|
1579
1608
|
}
|
|
1580
|
-
return (
|
|
1581
|
-
value:
|
|
1609
|
+
return (i, v) => (d(), R(ye, J({ ...s(fe)(a), error: n.value ?? a.error }, {
|
|
1610
|
+
value: m.value ? s(t)("core.form.file.choose") : null,
|
|
1582
1611
|
"row-layout": "stacked"
|
|
1583
|
-
}),
|
|
1612
|
+
}), Z({
|
|
1584
1613
|
readonly: f(() => [
|
|
1585
|
-
|
|
1614
|
+
m.value ? (d(), y("button", {
|
|
1586
1615
|
key: 0,
|
|
1587
1616
|
type: "button",
|
|
1588
|
-
"aria-label":
|
|
1617
|
+
"aria-label": s(t)("core.viewer.open"),
|
|
1589
1618
|
"data-test": "photo-open",
|
|
1590
1619
|
class: "block cursor-zoom-in rounded-group focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-border-focus",
|
|
1591
|
-
onClick:
|
|
1620
|
+
onClick: v[0] || (v[0] = (g) => k.value?.present(0))
|
|
1592
1621
|
}, [
|
|
1593
|
-
|
|
1594
|
-
src:
|
|
1622
|
+
p("img", {
|
|
1623
|
+
src: m.value,
|
|
1595
1624
|
alt: "",
|
|
1596
1625
|
class: "size-40 rounded-group object-cover"
|
|
1597
|
-
}, null, 8,
|
|
1598
|
-
], 8,
|
|
1599
|
-
|
|
1626
|
+
}, null, 8, nl)
|
|
1627
|
+
], 8, ol)) : q("", !0),
|
|
1628
|
+
m.value ? (d(), R(Pe, {
|
|
1600
1629
|
key: 1,
|
|
1601
1630
|
ref_key: "viewer",
|
|
1602
1631
|
ref: k,
|
|
1603
|
-
items:
|
|
1604
|
-
}, null, 8, ["items"])) :
|
|
1632
|
+
items: x.value
|
|
1633
|
+
}, null, 8, ["items"])) : q("", !0)
|
|
1605
1634
|
]),
|
|
1606
|
-
default: f(({ id:
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
id:
|
|
1635
|
+
default: f(({ id: g, describedby: T, invalid: w }) => [
|
|
1636
|
+
p("div", sl, [
|
|
1637
|
+
p("input", {
|
|
1638
|
+
id: g,
|
|
1610
1639
|
ref_key: "chooser",
|
|
1611
|
-
ref:
|
|
1640
|
+
ref: o,
|
|
1612
1641
|
type: "file",
|
|
1613
1642
|
class: "sr-only",
|
|
1614
1643
|
tabindex: "-1",
|
|
1615
1644
|
accept: a.accept.join(","),
|
|
1616
1645
|
disabled: a.disabled,
|
|
1617
|
-
"aria-describedby":
|
|
1618
|
-
"aria-invalid":
|
|
1619
|
-
onChange:
|
|
1620
|
-
}, null, 40,
|
|
1621
|
-
|
|
1646
|
+
"aria-describedby": T,
|
|
1647
|
+
"aria-invalid": w || void 0,
|
|
1648
|
+
onChange: v[1] || (v[1] = (F) => $(F.target.files?.[0]))
|
|
1649
|
+
}, null, 40, rl),
|
|
1650
|
+
m.value ? (d(), y("button", {
|
|
1622
1651
|
key: 0,
|
|
1623
1652
|
type: "button",
|
|
1624
|
-
"aria-label":
|
|
1653
|
+
"aria-label": s(t)("core.viewer.open"),
|
|
1625
1654
|
"data-test": "photo-open",
|
|
1626
1655
|
class: "block cursor-zoom-in rounded-group focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-border-focus",
|
|
1627
|
-
onClick:
|
|
1656
|
+
onClick: v[2] || (v[2] = (F) => k.value?.present(0))
|
|
1628
1657
|
}, [
|
|
1629
|
-
|
|
1630
|
-
src:
|
|
1658
|
+
p("img", {
|
|
1659
|
+
src: m.value,
|
|
1631
1660
|
alt: "",
|
|
1632
1661
|
"data-test": "photo-preview",
|
|
1633
1662
|
class: "size-28 rounded-group object-cover"
|
|
1634
|
-
}, null, 8,
|
|
1635
|
-
], 8,
|
|
1636
|
-
|
|
1663
|
+
}, null, 8, ul)
|
|
1664
|
+
], 8, il)) : q("", !0),
|
|
1665
|
+
I(be, {
|
|
1637
1666
|
disabled: a.disabled,
|
|
1638
|
-
onClick:
|
|
1667
|
+
onClick: v[3] || (v[3] = (F) => o.value?.click())
|
|
1639
1668
|
}, {
|
|
1640
1669
|
default: f(() => [
|
|
1641
|
-
H(
|
|
1670
|
+
H(C(s(t)("core.form.file.choose")), 1)
|
|
1642
1671
|
]),
|
|
1643
1672
|
_: 1
|
|
1644
1673
|
}, 8, ["disabled"]),
|
|
1645
|
-
|
|
1674
|
+
m.value ? (d(), R(be, {
|
|
1646
1675
|
key: 1,
|
|
1647
1676
|
prominence: "plain",
|
|
1648
1677
|
tone: "critical",
|
|
1649
1678
|
disabled: a.disabled,
|
|
1650
|
-
onClick:
|
|
1679
|
+
onClick: v[4] || (v[4] = (F) => {
|
|
1651
1680
|
e.value = null, n.value = null;
|
|
1652
1681
|
})
|
|
1653
1682
|
}, {
|
|
1654
1683
|
default: f(() => [
|
|
1655
|
-
H(
|
|
1684
|
+
H(C(s(t)("core.form.file.remove")), 1)
|
|
1656
1685
|
]),
|
|
1657
1686
|
_: 1
|
|
1658
|
-
}, 8, ["disabled"])) :
|
|
1687
|
+
}, 8, ["disabled"])) : q("", !0)
|
|
1659
1688
|
]),
|
|
1660
|
-
|
|
1689
|
+
m.value ? (d(), R(Pe, {
|
|
1661
1690
|
key: 0,
|
|
1662
1691
|
ref_key: "viewer",
|
|
1663
1692
|
ref: k,
|
|
1664
|
-
items:
|
|
1665
|
-
}, null, 8, ["items"])) :
|
|
1693
|
+
items: x.value
|
|
1694
|
+
}, null, 8, ["items"])) : q("", !0)
|
|
1666
1695
|
]),
|
|
1667
1696
|
_: 2
|
|
1668
1697
|
}, [
|
|
1669
|
-
|
|
1698
|
+
i.$slots.trailing ? {
|
|
1670
1699
|
name: "trailing",
|
|
1671
1700
|
fn: f(() => [
|
|
1672
|
-
|
|
1701
|
+
S(i.$slots, "trailing")
|
|
1673
1702
|
]),
|
|
1674
1703
|
key: "0"
|
|
1675
1704
|
} : void 0,
|
|
1676
|
-
|
|
1705
|
+
i.$slots.labelTrailing ? {
|
|
1677
1706
|
name: "labelTrailing",
|
|
1678
1707
|
fn: f(() => [
|
|
1679
|
-
|
|
1708
|
+
S(i.$slots, "labelTrailing")
|
|
1680
1709
|
]),
|
|
1681
1710
|
key: "1"
|
|
1682
1711
|
} : void 0
|
|
1683
1712
|
]), 1040, ["value"]));
|
|
1684
1713
|
}
|
|
1685
|
-
}),
|
|
1714
|
+
}), dl = { hidden: "" }, cl = /* @__PURE__ */ G({
|
|
1686
1715
|
__name: "EditorChrome",
|
|
1687
1716
|
props: {
|
|
1688
1717
|
options: {}
|
|
1689
1718
|
},
|
|
1690
|
-
setup(
|
|
1691
|
-
return
|
|
1719
|
+
setup(l) {
|
|
1720
|
+
return Et(l.options), (e, t) => (d(), y("span", dl));
|
|
1692
1721
|
}
|
|
1693
1722
|
});
|
|
1694
|
-
function
|
|
1723
|
+
function fl(l) {
|
|
1695
1724
|
const a = P(0);
|
|
1696
1725
|
let e = 0;
|
|
1697
1726
|
const t = () => {
|
|
1698
1727
|
e || (e = requestAnimationFrame(() => {
|
|
1699
1728
|
e = 0, a.value++;
|
|
1700
1729
|
}));
|
|
1701
|
-
},
|
|
1702
|
-
|
|
1703
|
-
() =>
|
|
1704
|
-
(
|
|
1705
|
-
|
|
1706
|
-
for (const
|
|
1707
|
-
|
|
1730
|
+
}, o = typeof MutationObserver > "u" ? null : new MutationObserver(t);
|
|
1731
|
+
ge(
|
|
1732
|
+
() => l.sections.value,
|
|
1733
|
+
(r) => {
|
|
1734
|
+
o?.disconnect();
|
|
1735
|
+
for (const m of r)
|
|
1736
|
+
o?.observe(m.element, { subtree: !0, childList: !0, attributes: !0, attributeFilter: ["data-field-error", "data-field-required", "data-field-filled"] });
|
|
1708
1737
|
t();
|
|
1709
1738
|
},
|
|
1710
1739
|
{ immediate: !0 }
|
|
1711
|
-
),
|
|
1712
|
-
|
|
1740
|
+
), it() && ut(() => {
|
|
1741
|
+
o?.disconnect(), e && cancelAnimationFrame(e);
|
|
1713
1742
|
});
|
|
1714
1743
|
const n = h(() => (a.value, Object.fromEntries(
|
|
1715
|
-
|
|
1716
|
-
|
|
1744
|
+
l.sections.value.map((r) => [
|
|
1745
|
+
r.id,
|
|
1717
1746
|
{
|
|
1718
|
-
errors:
|
|
1719
|
-
required: { total:
|
|
1747
|
+
errors: r.element.querySelectorAll("[data-field-error]").length,
|
|
1748
|
+
required: { total: r.element.querySelectorAll("[data-field-required]").length, filled: r.element.querySelectorAll("[data-field-required][data-field-filled]").length }
|
|
1720
1749
|
}
|
|
1721
1750
|
])
|
|
1722
|
-
))),
|
|
1723
|
-
return { states: n, totals:
|
|
1751
|
+
))), u = h(() => Object.values(n.value).reduce((r, m) => ({ filled: r.filled + m.required.filled, total: r.total + m.required.total }), { filled: 0, total: 0 }));
|
|
1752
|
+
return { states: n, totals: u };
|
|
1724
1753
|
}
|
|
1725
|
-
const
|
|
1754
|
+
const ml = {
|
|
1726
1755
|
class: "grid min-w-0 grid-cols-1 items-start gap-8 lg:grid-cols-[12.5rem_minmax(0,1fr)]",
|
|
1727
1756
|
"data-test": "editor-page"
|
|
1728
|
-
},
|
|
1757
|
+
}, vl = {
|
|
1729
1758
|
key: 0,
|
|
1730
1759
|
class: "sticky top-[calc(var(--app-bar-height)+1.5rem+var(--shell-banner-h,0px))] hidden min-w-0 flex-col gap-4 self-start lg:flex"
|
|
1731
|
-
},
|
|
1760
|
+
}, wo = /* @__PURE__ */ G({
|
|
1732
1761
|
__name: "EditorPage",
|
|
1733
1762
|
props: {
|
|
1734
1763
|
title: {},
|
|
@@ -1740,11 +1769,11 @@ const fl = {
|
|
|
1740
1769
|
disabledWhileClean: { type: Boolean, default: !1 }
|
|
1741
1770
|
},
|
|
1742
1771
|
emits: ["save", "cancel"],
|
|
1743
|
-
setup(
|
|
1744
|
-
const e =
|
|
1772
|
+
setup(l, { emit: a }) {
|
|
1773
|
+
const e = l, t = a, { t: o } = oe(), n = Ie(), u = Ot(), { states: r, totals: m } = fl(u), k = U("content"), x = h(
|
|
1745
1774
|
() => e.form ? {
|
|
1746
1775
|
form: e.form,
|
|
1747
|
-
label: () => e.saveLabel ??
|
|
1776
|
+
label: () => e.saveLabel ?? o("core.actions.save"),
|
|
1748
1777
|
allowed: () => e.canSave,
|
|
1749
1778
|
disabledWhileClean: () => e.disabledWhileClean,
|
|
1750
1779
|
save: () => {
|
|
@@ -1755,88 +1784,88 @@ const fl = {
|
|
|
1755
1784
|
}
|
|
1756
1785
|
} : null
|
|
1757
1786
|
);
|
|
1758
|
-
|
|
1787
|
+
ge(
|
|
1759
1788
|
() => e.form?.failure.value,
|
|
1760
|
-
async (
|
|
1761
|
-
|
|
1789
|
+
async (i) => {
|
|
1790
|
+
i?.kind === "invalid" && (await xe(), await qe(k.value ?? document, u));
|
|
1762
1791
|
}
|
|
1763
1792
|
);
|
|
1764
|
-
function $(
|
|
1765
|
-
const
|
|
1766
|
-
|
|
1793
|
+
function $(i) {
|
|
1794
|
+
const v = u.sections.value.find((g) => g.id === i)?.element;
|
|
1795
|
+
v && xe(() => qe(v));
|
|
1767
1796
|
}
|
|
1768
|
-
return (
|
|
1797
|
+
return (i, v) => (d(), R(Mt, {
|
|
1769
1798
|
title: e.title,
|
|
1770
1799
|
back: e.back,
|
|
1771
1800
|
width: "content"
|
|
1772
|
-
},
|
|
1801
|
+
}, Z({
|
|
1773
1802
|
default: f(() => [
|
|
1774
|
-
|
|
1803
|
+
x.value ? (d(), R(cl, {
|
|
1775
1804
|
key: 0,
|
|
1776
|
-
options:
|
|
1777
|
-
}, null, 8, ["options"])) :
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1805
|
+
options: x.value
|
|
1806
|
+
}, null, 8, ["options"])) : q("", !0),
|
|
1807
|
+
p("div", ml, [
|
|
1808
|
+
s(n) ? q("", !0) : (d(), y("aside", vl, [
|
|
1809
|
+
I(It, {
|
|
1781
1810
|
standalone: "",
|
|
1782
|
-
states:
|
|
1783
|
-
progress:
|
|
1811
|
+
states: s(r),
|
|
1812
|
+
progress: s(m),
|
|
1784
1813
|
onSelect: $
|
|
1785
1814
|
}, null, 8, ["states", "progress"]),
|
|
1786
|
-
|
|
1815
|
+
S(i.$slots, "aside")
|
|
1787
1816
|
])),
|
|
1788
|
-
|
|
1817
|
+
p("div", {
|
|
1789
1818
|
ref_key: "content",
|
|
1790
1819
|
ref: k,
|
|
1791
1820
|
class: "flex min-w-0 flex-col gap-section-gap"
|
|
1792
1821
|
}, [
|
|
1793
|
-
e.form ? (
|
|
1822
|
+
e.form ? (d(), R(We, {
|
|
1794
1823
|
key: 0,
|
|
1795
1824
|
form: e.form,
|
|
1796
1825
|
label: e.fieldLabel,
|
|
1797
1826
|
scope: k.value
|
|
1798
|
-
}, null, 8, ["form", "label", "scope"])) :
|
|
1799
|
-
|
|
1827
|
+
}, null, 8, ["form", "label", "scope"])) : q("", !0),
|
|
1828
|
+
S(i.$slots, "default")
|
|
1800
1829
|
], 512)
|
|
1801
1830
|
]),
|
|
1802
|
-
|
|
1831
|
+
s(n) ? (d(), R(jt, {
|
|
1803
1832
|
key: 1,
|
|
1804
|
-
states:
|
|
1805
|
-
}, null, 8, ["states"])) :
|
|
1833
|
+
states: s(r)
|
|
1834
|
+
}, null, 8, ["states"])) : q("", !0)
|
|
1806
1835
|
]),
|
|
1807
1836
|
_: 2
|
|
1808
1837
|
}, [
|
|
1809
|
-
|
|
1838
|
+
i.$slots.header ? {
|
|
1810
1839
|
name: "header",
|
|
1811
1840
|
fn: f(() => [
|
|
1812
|
-
|
|
1841
|
+
S(i.$slots, "header")
|
|
1813
1842
|
]),
|
|
1814
1843
|
key: "0"
|
|
1815
1844
|
} : void 0,
|
|
1816
|
-
|
|
1845
|
+
i.$slots.pager ? {
|
|
1817
1846
|
name: "pager",
|
|
1818
1847
|
fn: f(() => [
|
|
1819
|
-
|
|
1848
|
+
S(i.$slots, "pager")
|
|
1820
1849
|
]),
|
|
1821
1850
|
key: "1"
|
|
1822
1851
|
} : void 0,
|
|
1823
|
-
|
|
1852
|
+
i.$slots.notices ? {
|
|
1824
1853
|
name: "notices",
|
|
1825
1854
|
fn: f(() => [
|
|
1826
|
-
|
|
1855
|
+
S(i.$slots, "notices")
|
|
1827
1856
|
]),
|
|
1828
1857
|
key: "2"
|
|
1829
1858
|
} : void 0,
|
|
1830
|
-
|
|
1859
|
+
i.$slots.bottom ? {
|
|
1831
1860
|
name: "bottom",
|
|
1832
1861
|
fn: f(() => [
|
|
1833
|
-
|
|
1862
|
+
S(i.$slots, "bottom")
|
|
1834
1863
|
]),
|
|
1835
1864
|
key: "3"
|
|
1836
1865
|
} : void 0
|
|
1837
1866
|
]), 1032, ["title", "back"]));
|
|
1838
1867
|
}
|
|
1839
|
-
}),
|
|
1868
|
+
}), pl = ["value", "aria-label", "disabled", "aria-invalid", "placeholder"], $o = /* @__PURE__ */ G({
|
|
1840
1869
|
__name: "NumberCell",
|
|
1841
1870
|
props: /* @__PURE__ */ le({
|
|
1842
1871
|
label: {},
|
|
@@ -1851,14 +1880,14 @@ const fl = {
|
|
|
1851
1880
|
modelModifiers: {}
|
|
1852
1881
|
}),
|
|
1853
1882
|
emits: ["update:modelValue"],
|
|
1854
|
-
setup(
|
|
1855
|
-
const a =
|
|
1883
|
+
setup(l) {
|
|
1884
|
+
const a = l, e = re(l, "modelValue");
|
|
1856
1885
|
function t(n) {
|
|
1857
|
-
const
|
|
1858
|
-
e.value =
|
|
1886
|
+
const u = n.target.value.replace(/\D/g, "");
|
|
1887
|
+
e.value = u === "" ? null : Math.min(a.max, Math.max(a.min, Number(u)));
|
|
1859
1888
|
}
|
|
1860
|
-
const
|
|
1861
|
-
return (n,
|
|
1889
|
+
const o = (n) => n.target.value = e.value === null ? "" : String(e.value);
|
|
1890
|
+
return (n, u) => (d(), y("input", {
|
|
1862
1891
|
value: e.value ?? "",
|
|
1863
1892
|
type: "text",
|
|
1864
1893
|
inputmode: "numeric",
|
|
@@ -1867,331 +1896,331 @@ const fl = {
|
|
|
1867
1896
|
disabled: a.disabled,
|
|
1868
1897
|
"aria-invalid": a.invalid || void 0,
|
|
1869
1898
|
placeholder: a.placeholder,
|
|
1870
|
-
class:
|
|
1899
|
+
class: j(["rounded-control bg-fill px-2 py-1 text-right text-body tabular-nums text-content-strong transition-[background-color,box-shadow] duration-motion-fast ease-motion-standard placeholder:text-content-disabled focus:bg-surface-cell focus:outline-none focus:ring-[1.5px] focus:ring-inset focus:ring-border-focus disabled:opacity-45", [a.wide ? "w-28" : "w-16", a.invalid ? "bg-status-danger-surface ring-[1.5px] ring-inset ring-border-destructive" : ""]]),
|
|
1871
1900
|
onInput: t,
|
|
1872
|
-
onBlur:
|
|
1873
|
-
}, null, 42,
|
|
1901
|
+
onBlur: o
|
|
1902
|
+
}, null, 42, pl));
|
|
1874
1903
|
}
|
|
1875
|
-
}),
|
|
1876
|
-
function
|
|
1904
|
+
}), Oe = "vue-core:step-draft:";
|
|
1905
|
+
function Ee(l) {
|
|
1877
1906
|
try {
|
|
1878
|
-
return (
|
|
1907
|
+
return (l.storage === "local" ? window.localStorage : window.sessionStorage) ?? null;
|
|
1879
1908
|
} catch {
|
|
1880
1909
|
return null;
|
|
1881
1910
|
}
|
|
1882
1911
|
}
|
|
1883
|
-
function
|
|
1912
|
+
function bl(l) {
|
|
1884
1913
|
try {
|
|
1885
|
-
const a =
|
|
1914
|
+
const a = Ee(l)?.getItem(Oe + l.key);
|
|
1886
1915
|
if (!a) return null;
|
|
1887
1916
|
const e = JSON.parse(a);
|
|
1888
|
-
return !e || e.version !== (
|
|
1917
|
+
return !e || e.version !== (l.version ?? 1) || typeof e.values != "object" || e.values === null || typeof e.step != "string" || !Array.isArray(e.passed) ? null : e;
|
|
1889
1918
|
} catch {
|
|
1890
1919
|
return null;
|
|
1891
1920
|
}
|
|
1892
1921
|
}
|
|
1893
|
-
function
|
|
1922
|
+
function gl(l, a) {
|
|
1894
1923
|
try {
|
|
1895
|
-
const e =
|
|
1924
|
+
const e = Ee(l);
|
|
1896
1925
|
if (!e) return !1;
|
|
1897
|
-
const t = (
|
|
1898
|
-
return e.setItem(
|
|
1926
|
+
const t = (o, n) => typeof Blob < "u" && n instanceof Blob ? null : n;
|
|
1927
|
+
return e.setItem(Oe + l.key, JSON.stringify({ version: l.version ?? 1, ...a }, t)), !0;
|
|
1899
1928
|
} catch {
|
|
1900
1929
|
return !1;
|
|
1901
1930
|
}
|
|
1902
1931
|
}
|
|
1903
|
-
function
|
|
1932
|
+
function Ye(l) {
|
|
1904
1933
|
try {
|
|
1905
|
-
|
|
1934
|
+
Ee(l)?.removeItem(Oe + l.key);
|
|
1906
1935
|
} catch {
|
|
1907
1936
|
}
|
|
1908
1937
|
}
|
|
1909
|
-
function yl(
|
|
1910
|
-
for (const [e, t] of Object.entries(
|
|
1938
|
+
function yl(l, a) {
|
|
1939
|
+
for (const [e, t] of Object.entries(l)) {
|
|
1911
1940
|
if (!(e in a)) continue;
|
|
1912
|
-
const
|
|
1913
|
-
(
|
|
1941
|
+
const o = a[e];
|
|
1942
|
+
(o === null || t === null || t === void 0 || typeof o == typeof t && Array.isArray(o) === Array.isArray(t)) && (l[e] = o);
|
|
1914
1943
|
}
|
|
1915
1944
|
}
|
|
1916
|
-
function
|
|
1917
|
-
const { t: e } = oe(), t = h(() =>
|
|
1945
|
+
function _o(l, a) {
|
|
1946
|
+
const { t: e } = oe(), t = h(() => dt(a.steps));
|
|
1918
1947
|
if (t.value.length === 0) throw new Error("useStepForm: a flow needs at least one step.");
|
|
1919
|
-
const
|
|
1920
|
-
let
|
|
1921
|
-
const
|
|
1922
|
-
() => t.value.map((
|
|
1923
|
-
const
|
|
1948
|
+
const o = P(t.value[0].name), n = Ae(/* @__PURE__ */ new Set()), u = Ae(/* @__PURE__ */ new Set([t.value[0].name])), r = P(null), m = P(!1), k = P(0), x = P(!1), $ = P(!1);
|
|
1949
|
+
let i = !1, v = 0;
|
|
1950
|
+
const g = h(() => Math.max(0, t.value.findIndex((c) => c.name === o.value))), T = (c) => c.fields?.filter((B) => l.errors.has(B)).length ?? 0, w = h(
|
|
1951
|
+
() => t.value.map((c, B) => {
|
|
1952
|
+
const M = T(c), b = B === g.value;
|
|
1924
1953
|
return {
|
|
1925
|
-
name:
|
|
1926
|
-
label:
|
|
1927
|
-
position:
|
|
1928
|
-
state:
|
|
1929
|
-
errors:
|
|
1930
|
-
reachable: !
|
|
1954
|
+
name: c.name,
|
|
1955
|
+
label: c.label,
|
|
1956
|
+
position: B + 1,
|
|
1957
|
+
state: b ? "current" : n.has(c.name) && M === 0 ? "done" : "todo",
|
|
1958
|
+
errors: M,
|
|
1959
|
+
reachable: !b && (u.has(c.name) || B < g.value)
|
|
1931
1960
|
};
|
|
1932
1961
|
})
|
|
1933
|
-
),
|
|
1934
|
-
function
|
|
1935
|
-
const
|
|
1936
|
-
|
|
1962
|
+
), F = h(() => w.value[g.value]), O = h(() => w.value.length), E = h(() => g.value === 0), N = h(() => g.value === O.value - 1), V = h(() => m.value || l.submitting.value);
|
|
1963
|
+
function Q(c) {
|
|
1964
|
+
const B = t.value[c];
|
|
1965
|
+
B && (r.value = c > g.value ? "forward" : "back", o.value = B.name, u.add(B.name), v = c, x.value = !1);
|
|
1937
1966
|
}
|
|
1938
|
-
|
|
1939
|
-
() => t.value.map((
|
|
1967
|
+
ge(
|
|
1968
|
+
() => t.value.map((c) => c.name).join("\0"),
|
|
1940
1969
|
() => {
|
|
1941
|
-
const
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
}),
|
|
1945
|
-
for (const
|
|
1970
|
+
const c = t.value, B = c.findIndex((b) => b.name === o.value), M = B === -1 ? Math.min(v, c.length - 1) : B;
|
|
1971
|
+
o.value = c[M].name, v = M, c.forEach((b, D) => {
|
|
1972
|
+
D > M && (n.delete(b.name), u.delete(b.name));
|
|
1973
|
+
}), u.add(o.value);
|
|
1974
|
+
for (const b of [n, u]) for (const D of [...b]) c.some((L) => L.name === D) || b.delete(D);
|
|
1946
1975
|
}
|
|
1947
1976
|
);
|
|
1948
|
-
function
|
|
1949
|
-
const
|
|
1950
|
-
if (!
|
|
1951
|
-
const
|
|
1952
|
-
return
|
|
1977
|
+
function ee(c) {
|
|
1978
|
+
const B = c.fields;
|
|
1979
|
+
if (!B?.length) return !0;
|
|
1980
|
+
const M = Object.entries(l.errors.all()).filter(([D]) => !B.includes(st(D))), b = l.check(c.fields);
|
|
1981
|
+
return M.length > 0 && l.errors.set({ ...Object.fromEntries(M), ...l.errors.all() }), b;
|
|
1953
1982
|
}
|
|
1954
|
-
async function
|
|
1955
|
-
if (!
|
|
1983
|
+
async function ne(c) {
|
|
1984
|
+
if (!ee(c))
|
|
1956
1985
|
return k.value++, !1;
|
|
1957
|
-
if (!
|
|
1958
|
-
|
|
1986
|
+
if (!c.beforeNext) return !0;
|
|
1987
|
+
m.value = !0;
|
|
1959
1988
|
try {
|
|
1960
|
-
if (await
|
|
1989
|
+
if (await c.beforeNext()) return !0;
|
|
1961
1990
|
} finally {
|
|
1962
|
-
|
|
1991
|
+
m.value = !1;
|
|
1963
1992
|
}
|
|
1964
1993
|
return k.value++, !1;
|
|
1965
1994
|
}
|
|
1966
|
-
async function
|
|
1967
|
-
const
|
|
1968
|
-
if (
|
|
1969
|
-
return
|
|
1970
|
-
if (
|
|
1971
|
-
const
|
|
1972
|
-
|
|
1995
|
+
async function ie() {
|
|
1996
|
+
const c = await l.submit(a.submit, a.submitOptions);
|
|
1997
|
+
if (c.status === "saved" || c.status === "saved-refresh-failed")
|
|
1998
|
+
return i = !0, Y(), a.onSaved?.(c.value), !0;
|
|
1999
|
+
if (c.status === "failed" && (k.value++, F.value.errors === 0)) {
|
|
2000
|
+
const B = w.value.findIndex((M) => M.errors > 0);
|
|
2001
|
+
B !== -1 && Q(B);
|
|
1973
2002
|
}
|
|
1974
2003
|
return !1;
|
|
1975
2004
|
}
|
|
1976
|
-
async function
|
|
1977
|
-
if (
|
|
1978
|
-
const
|
|
1979
|
-
return await
|
|
2005
|
+
async function ue() {
|
|
2006
|
+
if (V.value) return !1;
|
|
2007
|
+
const c = t.value[g.value];
|
|
2008
|
+
return await ne(c) ? (n.add(c.name), g.value < O.value - 1 ? (Q(g.value + 1), !0) : ie()) : !1;
|
|
1980
2009
|
}
|
|
1981
|
-
async function
|
|
1982
|
-
if (
|
|
1983
|
-
const
|
|
1984
|
-
if (
|
|
1985
|
-
if (
|
|
1986
|
-
return
|
|
1987
|
-
if (!
|
|
1988
|
-
for (;
|
|
1989
|
-
return
|
|
2010
|
+
async function z(c) {
|
|
2011
|
+
if (V.value) return !1;
|
|
2012
|
+
const B = t.value.findIndex((M) => M.name === c);
|
|
2013
|
+
if (B === -1) return !1;
|
|
2014
|
+
if (B <= g.value)
|
|
2015
|
+
return B < g.value && Q(B), !0;
|
|
2016
|
+
if (!u.has(c)) return !1;
|
|
2017
|
+
for (; g.value < B; ) if (!await ue()) return !1;
|
|
2018
|
+
return g.value === B;
|
|
1990
2019
|
}
|
|
1991
|
-
const
|
|
1992
|
-
let
|
|
1993
|
-
function
|
|
1994
|
-
if (
|
|
1995
|
-
if (!
|
|
1996
|
-
|
|
2020
|
+
const A = a.draft;
|
|
2021
|
+
let K;
|
|
2022
|
+
function te() {
|
|
2023
|
+
if (K = void 0, !(!A || i)) {
|
|
2024
|
+
if (!l.dirty.value) {
|
|
2025
|
+
Ye(A), $.value = !1;
|
|
1997
2026
|
return;
|
|
1998
2027
|
}
|
|
1999
|
-
$.value =
|
|
2028
|
+
$.value = gl(A, { values: nt(l.values), step: o.value, passed: [...n] });
|
|
2000
2029
|
}
|
|
2001
2030
|
}
|
|
2002
|
-
function
|
|
2003
|
-
|
|
2031
|
+
function Y() {
|
|
2032
|
+
i = !0, clearTimeout(K), K = void 0, $.value = !1, A && Ye(A);
|
|
2004
2033
|
}
|
|
2005
|
-
if (
|
|
2006
|
-
const
|
|
2007
|
-
if (
|
|
2008
|
-
yl(
|
|
2009
|
-
const
|
|
2010
|
-
|
|
2011
|
-
for (const
|
|
2012
|
-
for (const
|
|
2013
|
-
|
|
2034
|
+
if (A) {
|
|
2035
|
+
const c = bl(A);
|
|
2036
|
+
if (c) {
|
|
2037
|
+
yl(l.values, c.values);
|
|
2038
|
+
const B = t.value.map((M) => M.name);
|
|
2039
|
+
B.includes(c.step) && (o.value = c.step);
|
|
2040
|
+
for (const M of c.passed) B.includes(M) && n.add(M);
|
|
2041
|
+
for (const M of [...n, o.value]) u.add(M);
|
|
2042
|
+
v = g.value, x.value = l.dirty.value, $.value = x.value;
|
|
2014
2043
|
}
|
|
2015
|
-
|
|
2016
|
-
[() =>
|
|
2044
|
+
ge(
|
|
2045
|
+
[() => l.values, o, () => [...n].join("\0")],
|
|
2017
2046
|
() => {
|
|
2018
|
-
|
|
2047
|
+
i || (clearTimeout(K), K = setTimeout(te, 400));
|
|
2019
2048
|
},
|
|
2020
2049
|
{ deep: !0 }
|
|
2021
|
-
),
|
|
2022
|
-
|
|
2050
|
+
), Ze(() => {
|
|
2051
|
+
K !== void 0 && (clearTimeout(K), te());
|
|
2023
2052
|
});
|
|
2024
2053
|
}
|
|
2025
|
-
const { confirmDiscard:
|
|
2026
|
-
|
|
2027
|
-
async function
|
|
2028
|
-
const
|
|
2029
|
-
return
|
|
2054
|
+
const { confirmDiscard: se } = Xe(() => !i && l.dirty.value);
|
|
2055
|
+
Je(Nt, null) && At(() => (i || Y(), !0));
|
|
2056
|
+
async function he() {
|
|
2057
|
+
const c = await se();
|
|
2058
|
+
return c && Y(), c;
|
|
2030
2059
|
}
|
|
2031
2060
|
function we() {
|
|
2032
|
-
|
|
2061
|
+
l.reset(), n.clear(), u.clear(), r.value = null, o.value = t.value[0].name, u.add(o.value), v = 0, x.value = !1, Y(), i = !1;
|
|
2033
2062
|
}
|
|
2034
|
-
const
|
|
2035
|
-
const
|
|
2036
|
-
return $.value &&
|
|
2037
|
-
}),
|
|
2038
|
-
const
|
|
2039
|
-
return
|
|
2040
|
-
}),
|
|
2063
|
+
const ke = h(() => {
|
|
2064
|
+
const c = [e("core.steps.position", { current: g.value + 1, total: O.value }), F.value.label];
|
|
2065
|
+
return $.value && c.push(e("core.steps.draft_saved")), c.join(" · ");
|
|
2066
|
+
}), ae = h(() => {
|
|
2067
|
+
const c = t.value[g.value];
|
|
2068
|
+
return c.nextLabel ? c.nextLabel : N.value ? a.submitLabel ?? e("core.actions.save") : e("core.steps.next_named", { step: t.value[g.value + 1].label });
|
|
2069
|
+
}), _ = h(() => E.value ? null : t.value[g.value - 1].label);
|
|
2041
2070
|
return {
|
|
2042
|
-
steps:
|
|
2043
|
-
current:
|
|
2044
|
-
index:
|
|
2071
|
+
steps: w,
|
|
2072
|
+
current: F,
|
|
2073
|
+
index: g,
|
|
2045
2074
|
count: O,
|
|
2046
|
-
isFirst:
|
|
2047
|
-
isLast:
|
|
2048
|
-
busy:
|
|
2049
|
-
direction:
|
|
2050
|
-
subtitle:
|
|
2051
|
-
nextLabel:
|
|
2052
|
-
backLabel:
|
|
2053
|
-
restored:
|
|
2075
|
+
isFirst: E,
|
|
2076
|
+
isLast: N,
|
|
2077
|
+
busy: V,
|
|
2078
|
+
direction: r,
|
|
2079
|
+
subtitle: ke,
|
|
2080
|
+
nextLabel: ae,
|
|
2081
|
+
backLabel: _,
|
|
2082
|
+
restored: x,
|
|
2054
2083
|
refusals: k,
|
|
2055
|
-
errors:
|
|
2056
|
-
failure:
|
|
2057
|
-
next:
|
|
2058
|
-
back: () =>
|
|
2059
|
-
goTo:
|
|
2084
|
+
errors: l.errors,
|
|
2085
|
+
failure: l.failure,
|
|
2086
|
+
next: ue,
|
|
2087
|
+
back: () => Q(g.value - 1),
|
|
2088
|
+
goTo: z,
|
|
2060
2089
|
restart: we,
|
|
2061
|
-
confirmDiscard:
|
|
2062
|
-
bindDialog: () => ({ subtitle:
|
|
2090
|
+
confirmDiscard: he,
|
|
2091
|
+
bindDialog: () => ({ subtitle: ke.value, primaryLabel: ae.value, status: V.value ? "processing" : "idle", beforeDismiss: he })
|
|
2063
2092
|
};
|
|
2064
2093
|
}
|
|
2065
|
-
const
|
|
2094
|
+
const hl = {
|
|
2066
2095
|
class: "flex flex-wrap items-center gap-2.5 border-t border-border-separator pt-3.5",
|
|
2067
2096
|
"data-test": "step-navigation"
|
|
2068
|
-
},
|
|
2097
|
+
}, kl = /* @__PURE__ */ G({
|
|
2069
2098
|
__name: "StepNavigation",
|
|
2070
2099
|
props: {
|
|
2071
2100
|
flow: {}
|
|
2072
2101
|
},
|
|
2073
2102
|
emits: ["cancel"],
|
|
2074
|
-
setup(
|
|
2075
|
-
const a =
|
|
2076
|
-
return (t,
|
|
2077
|
-
a.flow.backLabel.value ? (
|
|
2103
|
+
setup(l) {
|
|
2104
|
+
const a = l, { t: e } = oe();
|
|
2105
|
+
return (t, o) => (d(), y("div", hl, [
|
|
2106
|
+
a.flow.backLabel.value ? (d(), R(be, {
|
|
2078
2107
|
key: 0,
|
|
2079
2108
|
prominence: "plain",
|
|
2080
2109
|
icon: "arrowLeftSLine",
|
|
2081
2110
|
disabled: a.flow.busy.value,
|
|
2082
2111
|
"data-test": "step-back",
|
|
2083
|
-
onClick:
|
|
2112
|
+
onClick: o[0] || (o[0] = (n) => a.flow.back())
|
|
2084
2113
|
}, {
|
|
2085
2114
|
default: f(() => [
|
|
2086
|
-
H(
|
|
2115
|
+
H(C(a.flow.backLabel.value), 1)
|
|
2087
2116
|
]),
|
|
2088
2117
|
_: 1
|
|
2089
|
-
}, 8, ["disabled"])) :
|
|
2090
|
-
|
|
2091
|
-
|
|
2118
|
+
}, 8, ["disabled"])) : q("", !0),
|
|
2119
|
+
o[3] || (o[3] = p("div", { class: "grow" }, null, -1)),
|
|
2120
|
+
I(be, {
|
|
2092
2121
|
prominence: "plain",
|
|
2093
2122
|
"data-test": "step-cancel",
|
|
2094
|
-
onClick:
|
|
2123
|
+
onClick: o[1] || (o[1] = (n) => t.$emit("cancel"))
|
|
2095
2124
|
}, {
|
|
2096
2125
|
default: f(() => [
|
|
2097
|
-
H(
|
|
2126
|
+
H(C(s(e)("core.actions.cancel")), 1)
|
|
2098
2127
|
]),
|
|
2099
2128
|
_: 1
|
|
2100
2129
|
}),
|
|
2101
|
-
|
|
2130
|
+
I(be, {
|
|
2102
2131
|
prominence: "primary",
|
|
2103
2132
|
processing: a.flow.busy.value,
|
|
2104
2133
|
"data-test": "step-next",
|
|
2105
|
-
onClick:
|
|
2134
|
+
onClick: o[2] || (o[2] = (n) => a.flow.next())
|
|
2106
2135
|
}, {
|
|
2107
2136
|
default: f(() => [
|
|
2108
|
-
H(
|
|
2137
|
+
H(C(a.flow.nextLabel.value), 1)
|
|
2109
2138
|
]),
|
|
2110
2139
|
_: 1
|
|
2111
2140
|
}, 8, ["processing"])
|
|
2112
2141
|
]));
|
|
2113
2142
|
}
|
|
2114
|
-
}),
|
|
2143
|
+
}), xl = ["aria-label"], wl = ["aria-current"], $l = ["aria-label"], _l = {
|
|
2115
2144
|
key: 2,
|
|
2116
2145
|
class: "sr-only"
|
|
2117
|
-
},
|
|
2146
|
+
}, Cl = {
|
|
2118
2147
|
key: 1,
|
|
2119
2148
|
"data-test": "step-dots",
|
|
2120
2149
|
class: "flex justify-center gap-1.5",
|
|
2121
2150
|
"aria-hidden": "true"
|
|
2122
|
-
},
|
|
2151
|
+
}, Sl = ["data-state"], Fl = /* @__PURE__ */ G({
|
|
2123
2152
|
__name: "StepProgress",
|
|
2124
2153
|
props: {
|
|
2125
2154
|
flow: {},
|
|
2126
2155
|
progress: { default: "bar" }
|
|
2127
2156
|
},
|
|
2128
|
-
setup(
|
|
2129
|
-
const a =
|
|
2130
|
-
return (t,
|
|
2157
|
+
setup(l) {
|
|
2158
|
+
const a = l, { t: e } = oe();
|
|
2159
|
+
return (t, o) => a.progress === "bar" ? (d(), y("ol", {
|
|
2131
2160
|
key: 0,
|
|
2132
|
-
"aria-label":
|
|
2161
|
+
"aria-label": s(e)("core.steps.label"),
|
|
2133
2162
|
"data-test": "step-bar",
|
|
2134
2163
|
class: "grid min-w-0 gap-2",
|
|
2135
|
-
style:
|
|
2164
|
+
style: ct({ gridTemplateColumns: `repeat(${a.flow.count.value}, minmax(0, 1fr))` })
|
|
2136
2165
|
}, [
|
|
2137
|
-
(
|
|
2166
|
+
(d(!0), y(de, null, $e(a.flow.steps.value, (n) => (d(), y("li", {
|
|
2138
2167
|
key: n.name,
|
|
2139
2168
|
class: "flex min-w-0",
|
|
2140
2169
|
"aria-current": n.state === "current" ? "step" : void 0
|
|
2141
2170
|
}, [
|
|
2142
|
-
(
|
|
2171
|
+
(d(), R(ft(n.reachable ? "button" : "div"), {
|
|
2143
2172
|
type: n.reachable ? "button" : void 0,
|
|
2144
2173
|
disabled: n.reachable ? a.flow.busy.value : void 0,
|
|
2145
2174
|
"data-test": `step-${n.name}`,
|
|
2146
2175
|
"data-state": n.errors > 0 ? "error" : n.state,
|
|
2147
|
-
class:
|
|
2148
|
-
onClick: (
|
|
2176
|
+
class: j(["group flex min-w-0 flex-1 flex-col gap-1.5 text-left", n.reachable ? "cursor-pointer rounded-control focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-border-focus disabled:cursor-default" : ""]),
|
|
2177
|
+
onClick: (u) => n.reachable ? a.flow.goTo(n.name) : void 0
|
|
2149
2178
|
}, {
|
|
2150
2179
|
default: f(() => [
|
|
2151
|
-
|
|
2152
|
-
class:
|
|
2180
|
+
p("span", {
|
|
2181
|
+
class: j(["h-1 rounded-full transition-colors duration-motion-normal", n.errors > 0 ? "bg-status-danger-solid" : n.state === "current" ? "bg-tint" : n.state === "done" ? "bg-control-on" : "bg-fill-strong"]),
|
|
2153
2182
|
"aria-hidden": "true"
|
|
2154
2183
|
}, null, 2),
|
|
2155
|
-
|
|
2156
|
-
class:
|
|
2184
|
+
p("span", {
|
|
2185
|
+
class: j(["flex min-w-0 items-center gap-1.5 text-footnote", n.state === "current" ? "font-bold text-content-strong" : n.state === "done" ? "font-medium text-content-link" : "font-medium text-content-muted"])
|
|
2157
2186
|
}, [
|
|
2158
|
-
n.state === "done" ? (
|
|
2187
|
+
n.state === "done" ? (d(), R(s(X), {
|
|
2159
2188
|
key: 0,
|
|
2160
2189
|
name: "checkCustom",
|
|
2161
2190
|
size: 12,
|
|
2162
2191
|
class: "shrink-0"
|
|
2163
|
-
})) :
|
|
2164
|
-
|
|
2165
|
-
class:
|
|
2166
|
-
},
|
|
2167
|
-
n.errors > 0 ? (
|
|
2192
|
+
})) : q("", !0),
|
|
2193
|
+
p("span", {
|
|
2194
|
+
class: j(["truncate", n.reachable ? "group-hover:text-content-link" : ""])
|
|
2195
|
+
}, C(n.position) + ". " + C(n.label), 3),
|
|
2196
|
+
n.errors > 0 ? (d(), y("span", {
|
|
2168
2197
|
key: 1,
|
|
2169
2198
|
"data-test": "step-errors",
|
|
2170
|
-
"aria-label":
|
|
2199
|
+
"aria-label": s(e)("core.form.sections.errors", { count: n.errors }),
|
|
2171
2200
|
class: "min-w-4.5 shrink-0 rounded-full bg-status-danger-solid px-1.5 text-center text-caption font-semibold text-white"
|
|
2172
|
-
},
|
|
2173
|
-
n.state === "done" ? (
|
|
2201
|
+
}, C(n.errors), 9, $l)) : q("", !0),
|
|
2202
|
+
n.state === "done" ? (d(), y("span", _l, C(s(e)("core.steps.done")), 1)) : q("", !0)
|
|
2174
2203
|
], 2)
|
|
2175
2204
|
]),
|
|
2176
2205
|
_: 2
|
|
2177
2206
|
}, 1032, ["type", "disabled", "data-test", "data-state", "class", "onClick"]))
|
|
2178
|
-
], 8,
|
|
2179
|
-
], 12,
|
|
2180
|
-
(
|
|
2207
|
+
], 8, wl))), 128))
|
|
2208
|
+
], 12, xl)) : (d(), y("div", Cl, [
|
|
2209
|
+
(d(!0), y(de, null, $e(a.flow.steps.value, (n) => (d(), y("span", {
|
|
2181
2210
|
key: n.name,
|
|
2182
|
-
class:
|
|
2211
|
+
class: j(["h-1.5 rounded-full transition-all duration-motion-fast", [n.state === "current" ? "w-4.5" : "w-1.5", n.errors > 0 ? "bg-status-danger-solid" : n.state === "todo" && n.position > a.flow.index.value ? "bg-fill-strong" : "bg-tint"]]),
|
|
2183
2212
|
"data-state": n.errors > 0 ? "error" : n.state
|
|
2184
|
-
}, null, 10,
|
|
2213
|
+
}, null, 10, Sl))), 128))
|
|
2185
2214
|
]));
|
|
2186
2215
|
}
|
|
2187
|
-
}),
|
|
2216
|
+
}), Bl = ["data-step"], Ll = {
|
|
2188
2217
|
class: "sr-only",
|
|
2189
2218
|
"aria-live": "polite"
|
|
2190
|
-
},
|
|
2219
|
+
}, Tl = {
|
|
2191
2220
|
key: 1,
|
|
2192
2221
|
"data-test": "step-restored",
|
|
2193
2222
|
class: "flex items-center gap-2 text-footnote text-content-muted"
|
|
2194
|
-
},
|
|
2223
|
+
}, Co = /* @__PURE__ */ G({
|
|
2195
2224
|
__name: "StepForm",
|
|
2196
2225
|
props: {
|
|
2197
2226
|
flow: {},
|
|
@@ -2199,151 +2228,152 @@ const gl = {
|
|
|
2199
2228
|
navigation: { default: "inline" }
|
|
2200
2229
|
},
|
|
2201
2230
|
emits: ["cancel"],
|
|
2202
|
-
setup(
|
|
2203
|
-
const a =
|
|
2204
|
-
function n(
|
|
2205
|
-
for (let
|
|
2206
|
-
const
|
|
2207
|
-
if ((
|
|
2231
|
+
setup(l) {
|
|
2232
|
+
const a = l, { t: e } = oe(), t = U("body"), o = U("root");
|
|
2233
|
+
function n(u) {
|
|
2234
|
+
for (let r = u.parentElement; r; r = r.parentElement) {
|
|
2235
|
+
const m = getComputedStyle(r).overflowY;
|
|
2236
|
+
if ((m === "auto" || m === "scroll") && r.scrollHeight > r.clientHeight) return u.getBoundingClientRect().top < r.getBoundingClientRect().top;
|
|
2208
2237
|
}
|
|
2209
|
-
return
|
|
2238
|
+
return u.getBoundingClientRect().top < 0;
|
|
2210
2239
|
}
|
|
2211
|
-
return
|
|
2212
|
-
await
|
|
2213
|
-
}),
|
|
2214
|
-
await
|
|
2215
|
-
}), (
|
|
2240
|
+
return ge(() => a.flow.current.value.name, async () => {
|
|
2241
|
+
await xe(), o.value && n(o.value) && o.value.scrollIntoView?.({ block: "start" }), t.value?.focus({ preventScroll: !0 });
|
|
2242
|
+
}), ge(() => a.flow.refusals.value, async () => {
|
|
2243
|
+
await xe(), t.value && await qe(t.value);
|
|
2244
|
+
}), (u, r) => (d(), y("div", {
|
|
2216
2245
|
ref_key: "root",
|
|
2217
|
-
ref:
|
|
2246
|
+
ref: o,
|
|
2218
2247
|
class: "flex min-w-0 flex-col gap-group-gap",
|
|
2219
2248
|
"data-test": "step-form",
|
|
2220
2249
|
"data-step": a.flow.current.value.name
|
|
2221
2250
|
}, [
|
|
2222
|
-
a.progress !== "none" ? (
|
|
2251
|
+
a.progress !== "none" ? (d(), R(Fl, {
|
|
2223
2252
|
key: 0,
|
|
2224
2253
|
flow: a.flow,
|
|
2225
2254
|
progress: a.progress
|
|
2226
|
-
}, null, 8, ["flow", "progress"])) :
|
|
2227
|
-
|
|
2228
|
-
a.flow.restored.value ? (
|
|
2229
|
-
|
|
2230
|
-
|
|
2255
|
+
}, null, 8, ["flow", "progress"])) : q("", !0),
|
|
2256
|
+
p("p", Ll, C(a.flow.subtitle.value), 1),
|
|
2257
|
+
a.flow.restored.value ? (d(), y("div", Tl, [
|
|
2258
|
+
p("span", null, C(s(e)("core.steps.restored")), 1),
|
|
2259
|
+
I(be, {
|
|
2231
2260
|
prominence: "link",
|
|
2232
2261
|
size: "sm",
|
|
2233
|
-
onClick:
|
|
2262
|
+
onClick: r[0] || (r[0] = (m) => a.flow.restart())
|
|
2234
2263
|
}, {
|
|
2235
2264
|
default: f(() => [
|
|
2236
|
-
H(
|
|
2265
|
+
H(C(s(e)("core.steps.start_over")), 1)
|
|
2237
2266
|
]),
|
|
2238
2267
|
_: 1
|
|
2239
2268
|
})
|
|
2240
|
-
])) :
|
|
2241
|
-
(
|
|
2269
|
+
])) : q("", !0),
|
|
2270
|
+
(d(), R(We, {
|
|
2242
2271
|
key: a.flow.current.value.name,
|
|
2243
2272
|
form: a.flow
|
|
2244
2273
|
}, null, 8, ["form"])),
|
|
2245
|
-
(
|
|
2274
|
+
(d(), y("form", {
|
|
2246
2275
|
key: a.flow.current.value.name,
|
|
2247
2276
|
ref_key: "body",
|
|
2248
2277
|
ref: t,
|
|
2249
2278
|
tabindex: "-1",
|
|
2250
2279
|
novalidate: "",
|
|
2251
2280
|
"data-test": "step-body",
|
|
2252
|
-
class:
|
|
2253
|
-
onSubmit:
|
|
2281
|
+
class: j(["flex min-w-0 flex-col gap-group-gap outline-none", a.flow.direction.value === "back" ? "animate-step-back" : a.flow.direction.value === "forward" ? "animate-step-in" : ""]),
|
|
2282
|
+
onSubmit: r[1] || (r[1] = pe((m) => a.flow.next(), ["prevent"]))
|
|
2254
2283
|
}, [
|
|
2255
|
-
|
|
2256
|
-
|
|
2284
|
+
S(u.$slots, a.flow.current.value.name),
|
|
2285
|
+
r[3] || (r[3] = p("button", {
|
|
2257
2286
|
type: "submit",
|
|
2258
2287
|
class: "sr-only",
|
|
2259
2288
|
tabindex: "-1",
|
|
2260
2289
|
"aria-hidden": "true"
|
|
2261
2290
|
}, null, -1))
|
|
2262
2291
|
], 34)),
|
|
2263
|
-
a.navigation === "inline" ? (
|
|
2292
|
+
a.navigation === "inline" ? (d(), R(kl, {
|
|
2264
2293
|
key: 2,
|
|
2265
2294
|
flow: a.flow,
|
|
2266
|
-
onCancel:
|
|
2267
|
-
}, null, 8, ["flow"])) :
|
|
2268
|
-
], 8,
|
|
2295
|
+
onCancel: r[2] || (r[2] = (m) => u.$emit("cancel"))
|
|
2296
|
+
}, null, 8, ["flow"])) : q("", !0)
|
|
2297
|
+
], 8, Bl));
|
|
2269
2298
|
}
|
|
2270
2299
|
});
|
|
2271
2300
|
export {
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
|
|
2279
|
-
|
|
2280
|
-
|
|
2281
|
-
|
|
2282
|
-
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2291
|
-
|
|
2292
|
-
|
|
2293
|
-
|
|
2294
|
-
|
|
2301
|
+
$t as Calendar,
|
|
2302
|
+
ro as CardSelectField,
|
|
2303
|
+
io as CheckboxField,
|
|
2304
|
+
uo as ChoiceChips,
|
|
2305
|
+
co as ComboField,
|
|
2306
|
+
Io as CommandDialog,
|
|
2307
|
+
nn as DateField,
|
|
2308
|
+
fo as DateTimeField,
|
|
2309
|
+
wo as EditorPage,
|
|
2310
|
+
Bo as ErrorBag,
|
|
2311
|
+
ye as Field,
|
|
2312
|
+
mo as FileField,
|
|
2313
|
+
We as FormErrors,
|
|
2314
|
+
ot as FormGroup,
|
|
2315
|
+
vo as FormGroupButton,
|
|
2316
|
+
po as FormIndent,
|
|
2317
|
+
mt as FormRow,
|
|
2318
|
+
dn as FormView,
|
|
2319
|
+
Lo as GroupEditAction,
|
|
2320
|
+
pn as GroupSheet,
|
|
2321
|
+
bo as I18nField,
|
|
2322
|
+
Uo as LeaveGuardRoot,
|
|
2323
|
+
No as MissingLeaveGuardRootError,
|
|
2295
2324
|
yo as MoneyField,
|
|
2296
|
-
|
|
2297
|
-
|
|
2298
|
-
|
|
2325
|
+
ho as MonthYearField,
|
|
2326
|
+
ko as MultiSelectField,
|
|
2327
|
+
$o as NumberCell,
|
|
2299
2328
|
Vt as NumberField,
|
|
2300
|
-
|
|
2301
|
-
|
|
2302
|
-
|
|
2303
|
-
|
|
2304
|
-
|
|
2305
|
-
|
|
2306
|
-
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2310
|
-
|
|
2311
|
-
|
|
2312
|
-
|
|
2313
|
-
|
|
2314
|
-
|
|
2315
|
-
|
|
2316
|
-
|
|
2329
|
+
Ke as OptionList,
|
|
2330
|
+
bn as OtpInput,
|
|
2331
|
+
xo as PhotoField,
|
|
2332
|
+
gn as RecordGroupScope,
|
|
2333
|
+
kn as SegmentedField,
|
|
2334
|
+
fn as SelectField,
|
|
2335
|
+
Co as StepForm,
|
|
2336
|
+
kl as StepNavigation,
|
|
2337
|
+
Fl as StepProgress,
|
|
2338
|
+
wn as SwitchField,
|
|
2339
|
+
tn as TextField,
|
|
2340
|
+
_n as TextareaField,
|
|
2341
|
+
rn as TimeField,
|
|
2342
|
+
lt as checkFile,
|
|
2343
|
+
To as createFieldGroups,
|
|
2344
|
+
Ao as createLeaveGuard,
|
|
2345
|
+
me as fieldDefaults,
|
|
2317
2346
|
jo as fieldKey,
|
|
2318
|
-
|
|
2319
|
-
|
|
2320
|
-
|
|
2321
|
-
|
|
2322
|
-
|
|
2323
|
-
|
|
2324
|
-
|
|
2325
|
-
|
|
2326
|
-
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
|
|
2347
|
+
fe as fieldProps,
|
|
2348
|
+
qe as focusFirstError,
|
|
2349
|
+
Zo as formEditableKey,
|
|
2350
|
+
Be as formatBytes,
|
|
2351
|
+
Xo as groupOptions,
|
|
2352
|
+
Ya as hasUnsupportedCharacters,
|
|
2353
|
+
Go as installLeaveGuard,
|
|
2354
|
+
Ko as leaveGuardKey,
|
|
2355
|
+
Qo as matchOptions,
|
|
2356
|
+
Ta as missingLocales,
|
|
2357
|
+
qo as provideRecordGroups,
|
|
2358
|
+
ln as recentChoicesKey,
|
|
2330
2359
|
zo as recordGroupsKey,
|
|
2331
|
-
|
|
2332
|
-
|
|
2333
|
-
|
|
2334
|
-
|
|
2335
|
-
|
|
2360
|
+
go as refineStorableText,
|
|
2361
|
+
Ha as unsupportedCharactersCode,
|
|
2362
|
+
Oo as useCommand,
|
|
2363
|
+
Gt as useDirtySnapshot,
|
|
2364
|
+
Qe as useFieldMode,
|
|
2336
2365
|
Vo as useForm,
|
|
2337
2366
|
yn as useGroupSheet,
|
|
2338
|
-
|
|
2339
|
-
|
|
2340
|
-
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
|
|
2344
|
-
|
|
2345
|
-
|
|
2346
|
-
|
|
2367
|
+
Do as useHiddenFieldErrors,
|
|
2368
|
+
Xe as useLeaveGuard,
|
|
2369
|
+
Po as useLeaveGuardContext,
|
|
2370
|
+
mn as useOptions,
|
|
2371
|
+
Sn as useRecordDialog,
|
|
2372
|
+
Ro as useRecordGroups,
|
|
2373
|
+
Wo as useResourceForm,
|
|
2374
|
+
Et as useSaveChrome,
|
|
2375
|
+
fl as useSectionStates,
|
|
2347
2376
|
no as useSheetDiscardGuard,
|
|
2348
|
-
|
|
2377
|
+
_o as useStepForm,
|
|
2378
|
+
so as zodErrorMap
|
|
2349
2379
|
};
|