@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
|
@@ -1,22 +1,24 @@
|
|
|
1
|
-
import { defineComponent as E, openBlock as N, createBlock as L, unref as e, withCtx as p, createVNode as n, mergeProps as
|
|
1
|
+
import { defineComponent as E, openBlock as N, createBlock as L, unref as e, withCtx as p, createVNode as n, mergeProps as q, provide as C, computed as _, useTemplateRef as D, createElementVNode as h, toDisplayString as S, createTextVNode as K } from "vue";
|
|
2
2
|
import { useI18n as U } from "vue-i18n";
|
|
3
|
-
import { u as z } from "./neighbors-
|
|
3
|
+
import { u as z } from "./neighbors-Csfan8Ho.js";
|
|
4
4
|
import { _ as G } from "./Avatar.vue_vue_type_script_setup_true_lang-BPj_fkJR.js";
|
|
5
5
|
import { u as I } from "./describeError-B-NMa--w.js";
|
|
6
|
-
import { i as k
|
|
7
|
-
import { _ as
|
|
6
|
+
import { i as k } from "./preferences-hYhrw8Uy.js";
|
|
7
|
+
import { _ as O } from "./AlertDialog.vue_vue_type_script_setup_true_lang-CrFhR9rJ.js";
|
|
8
8
|
import { t as $ } from "./toast-CqSDTWRX.js";
|
|
9
|
-
import { _ as
|
|
10
|
-
import { u as V } from "./platform-
|
|
11
|
-
import { a as
|
|
12
|
-
import { a as
|
|
13
|
-
import { A as
|
|
14
|
-
import { _ as
|
|
15
|
-
import { u as
|
|
9
|
+
import { _ as j } from "./SectionNavigator.vue_vue_type_script_setup_true_lang-DfKEhTFv.js";
|
|
10
|
+
import { u as V } from "./platform-DtISOEt7.js";
|
|
11
|
+
import { a as F } from "./routeResource-DlTsGTg_.js";
|
|
12
|
+
import { a as H } from "./ResourcePage.vue_vue_type_script_setup_true_lang-Coz91xht.js";
|
|
13
|
+
import { A as J } from "./access-DmAceEo5.js";
|
|
14
|
+
import { _ as Q } from "./Badge.vue_vue_type_script_setup_true_lang-DJyZc0C7.js";
|
|
15
|
+
import { u as W } from "./useLoad-M7V-AVwR.js";
|
|
16
|
+
import { i as X } from "./usePreferences-B8LIZp_f.js";
|
|
17
|
+
import { P as Y, p as Z, c as ee, d as se, b as ae, M as te, o as oe, s as re } from "./index-DZikGJ8L.js";
|
|
16
18
|
import { a as ne } from "./FormGroup.vue_vue_type_script_setup_true_lang-D6jYfNjW.js";
|
|
17
19
|
import { _ as A } from "./TextField.vue_vue_type_script_setup_true_lang-CWIeeZRE.js";
|
|
18
|
-
import { u as
|
|
19
|
-
import { u as le } from "./serverMessages-
|
|
20
|
+
import { u as ie, _ as ce } from "./useCommand-Ch_nx1AQ.js";
|
|
21
|
+
import { u as le } from "./serverMessages-Ddghrewh.js";
|
|
20
22
|
const ue = /* @__PURE__ */ E({
|
|
21
23
|
__name: "SetPasswordDialog",
|
|
22
24
|
props: {
|
|
@@ -24,25 +26,25 @@ const ue = /* @__PURE__ */ E({
|
|
|
24
26
|
name: {}
|
|
25
27
|
},
|
|
26
28
|
emits: ["saved"],
|
|
27
|
-
setup(
|
|
28
|
-
const v =
|
|
29
|
+
setup(P, { expose: s, emit: f }) {
|
|
30
|
+
const v = P, w = f, { t: o } = U(), { http: i } = V(), u = {
|
|
29
31
|
safeParse(a) {
|
|
30
|
-
const { password:
|
|
31
|
-
...
|
|
32
|
-
...
|
|
32
|
+
const { password: c, repeat: d } = a, b = [
|
|
33
|
+
...c === "" ? [{ path: ["password"], message: o("core.account.validation.required") }] : [],
|
|
34
|
+
...c !== "" && d !== c ? [{ path: ["repeat"], message: o(d === "" ? "core.account.validation.required" : "core.account.validation.mismatch") }] : []
|
|
33
35
|
];
|
|
34
|
-
return
|
|
36
|
+
return b.length > 0 ? { success: !1, error: { issues: b } } : { success: !0, data: { password: c } };
|
|
35
37
|
}
|
|
36
|
-
}, m =
|
|
38
|
+
}, m = ie({
|
|
37
39
|
...le(),
|
|
38
40
|
defaults: () => ({ password: "", repeat: "" }),
|
|
39
41
|
validator: u,
|
|
40
|
-
run: (a) =>
|
|
42
|
+
run: (a) => i.request(k.usersSetPassword, { id: v.id, password: a.password }),
|
|
41
43
|
done: () => {
|
|
42
44
|
$.success(o("core.users.password.done", { name: v.name })), w("saved");
|
|
43
45
|
}
|
|
44
46
|
});
|
|
45
|
-
return s({ open: () => m.present() }), (a,
|
|
47
|
+
return s({ open: () => m.present() }), (a, c) => (N(), L(e(ce), {
|
|
46
48
|
command: e(m),
|
|
47
49
|
title: e(o)("core.users.password.title"),
|
|
48
50
|
subtitle: v.name,
|
|
@@ -54,13 +56,13 @@ const ue = /* @__PURE__ */ E({
|
|
|
54
56
|
"data-set-password-dialog": ""
|
|
55
57
|
}, {
|
|
56
58
|
default: p(() => [
|
|
57
|
-
n(e(A),
|
|
59
|
+
n(e(A), q(e(m).form.bind("password"), {
|
|
58
60
|
label: e(o)("core.users.fields.password"),
|
|
59
61
|
type: "password",
|
|
60
62
|
required: "",
|
|
61
63
|
autocomplete: "new-password"
|
|
62
64
|
}), null, 16, ["label"]),
|
|
63
|
-
n(e(A),
|
|
65
|
+
n(e(A), q(e(m).form.bind("repeat"), {
|
|
64
66
|
label: e(o)("core.users.fields.password_repeat"),
|
|
65
67
|
type: "password",
|
|
66
68
|
required: "",
|
|
@@ -76,48 +78,48 @@ const ue = /* @__PURE__ */ E({
|
|
|
76
78
|
}), me = {
|
|
77
79
|
class: "flex items-center gap-3 px-1.5",
|
|
78
80
|
"data-person-identity": ""
|
|
79
|
-
}, de = { class: "flex min-w-0 flex-col items-start gap-0.5" }, pe = { class: "max-w-full truncate text-headline font-semibold text-content-strong" }, fe = { class: "max-w-full truncate text-footnote text-content-muted" },
|
|
81
|
+
}, de = { class: "flex min-w-0 flex-col items-start gap-0.5" }, pe = { class: "max-w-full truncate text-headline font-semibold text-content-strong" }, fe = { class: "max-w-full truncate text-footnote text-content-muted" }, Ve = /* @__PURE__ */ E({
|
|
80
82
|
__name: "UserRecord",
|
|
81
|
-
setup(
|
|
82
|
-
const { t: s } = U(), { http: f, access: v, session: w } = V(), o = I(),
|
|
83
|
-
key:
|
|
83
|
+
setup(P) {
|
|
84
|
+
const { t: s } = U(), { http: f, access: v, session: w } = V(), o = I(), i = F({
|
|
85
|
+
key: Y,
|
|
84
86
|
param: "id",
|
|
85
87
|
load: async (t, { signal: l }) => (await f.request(k.usersShow, { id: t }, { signal: l })).data
|
|
86
|
-
}), u =
|
|
88
|
+
}), u = W(
|
|
87
89
|
async ({ signal: t }) => {
|
|
88
|
-
const l =
|
|
90
|
+
const l = i.data.value?.id;
|
|
89
91
|
return l === void 0 ? { sessions: [] } : (await f.request(k.usersSessions, { id: l }, { signal: t })).data;
|
|
90
92
|
},
|
|
91
|
-
{ watch: () =>
|
|
93
|
+
{ watch: () => i.data.value?.id }
|
|
92
94
|
);
|
|
93
|
-
C(
|
|
94
|
-
const m = z(
|
|
95
|
-
async function
|
|
96
|
-
await Promise.all([
|
|
95
|
+
C(Z, u);
|
|
96
|
+
const m = z(se(), { current: () => i.id.value, list: ee.index, param: "id", backLabel: () => s("core.users.title") }), a = _(() => i.data.value), c = _(() => a.value !== null && w.state.value.status === "authenticated" && w.state.value.user.id === a.value.id), d = D("deactivateDialog"), { deactivate: b } = ae(), R = D("passwordDialog"), x = D("activateDialog");
|
|
97
|
+
async function g() {
|
|
98
|
+
await Promise.all([i.reload(), u.reload()]);
|
|
97
99
|
}
|
|
98
100
|
async function M() {
|
|
99
|
-
const t =
|
|
101
|
+
const t = i.id.value;
|
|
100
102
|
if (t !== null) {
|
|
101
103
|
try {
|
|
102
104
|
await f.request(k.usersActivate, { id: t }), $.success(s("core.users.activate.done", { name: a.value?.name ?? "" }));
|
|
103
105
|
} catch (l) {
|
|
104
|
-
|
|
106
|
+
X(l) || $.error(o(l, { fallback: s("core.users.activate.failed") }));
|
|
105
107
|
}
|
|
106
|
-
await
|
|
108
|
+
await g();
|
|
107
109
|
}
|
|
108
110
|
}
|
|
109
111
|
const y = _(() => {
|
|
110
|
-
const t = v.can(
|
|
111
|
-
return { manage: t, deactivate: t && !!a.value?.active && !
|
|
112
|
+
const t = v.can(te);
|
|
113
|
+
return { manage: t, deactivate: t && !!a.value?.active && !c.value, activate: t && a.value !== null && !a.value.active, endSessions: t && !c.value };
|
|
112
114
|
});
|
|
113
|
-
C(
|
|
115
|
+
C(oe, {
|
|
114
116
|
get can() {
|
|
115
117
|
return y.value;
|
|
116
118
|
},
|
|
117
119
|
deactivate: () => d.value?.open(),
|
|
118
120
|
activate: () => x.value?.present(),
|
|
119
|
-
setPassword: () =>
|
|
120
|
-
refresh:
|
|
121
|
+
setPassword: () => R.value?.open(),
|
|
122
|
+
refresh: g
|
|
121
123
|
});
|
|
122
124
|
const T = _(() => [
|
|
123
125
|
...y.value.deactivate ? [{ id: "deactivate", label: s("core.users.actions.deactivate"), icon: "lockLine", placement: "overflow", tone: "critical", onClick: () => d.value?.open() }] : [],
|
|
@@ -126,14 +128,14 @@ const ue = /* @__PURE__ */ E({
|
|
|
126
128
|
...u.data.value ? { "users.record.sessions": u.data.value.sessions.length } : {},
|
|
127
129
|
...a.value?.status === "locked" ? { "users.record.signin": s("core.users.status.locked") } : {}
|
|
128
130
|
}));
|
|
129
|
-
return (t, l) => (N(), L(e(
|
|
130
|
-
resource: e(
|
|
131
|
+
return (t, l) => (N(), L(e(H), {
|
|
132
|
+
resource: e(i),
|
|
131
133
|
title: a.value?.name ?? e(s)("core.users.record"),
|
|
132
134
|
list: e(m).context,
|
|
133
135
|
actions: T.value
|
|
134
136
|
}, {
|
|
135
137
|
default: p(({ record: r }) => [
|
|
136
|
-
n(e(
|
|
138
|
+
n(e(j), {
|
|
137
139
|
label: e(s)("core.users.sections_label"),
|
|
138
140
|
desktop: "sidebar",
|
|
139
141
|
compact: "rows",
|
|
@@ -150,8 +152,8 @@ const ue = /* @__PURE__ */ E({
|
|
|
150
152
|
h("div", de, [
|
|
151
153
|
h("span", pe, S(r.name), 1),
|
|
152
154
|
h("span", fe, S(r.email), 1),
|
|
153
|
-
n(e(
|
|
154
|
-
tone: e(
|
|
155
|
+
n(e(Q), {
|
|
156
|
+
tone: e(re)(r.status),
|
|
155
157
|
dot: "",
|
|
156
158
|
"data-person-status": ""
|
|
157
159
|
}, {
|
|
@@ -164,26 +166,26 @@ const ue = /* @__PURE__ */ E({
|
|
|
164
166
|
])
|
|
165
167
|
]),
|
|
166
168
|
default: p(() => [
|
|
167
|
-
n(e(
|
|
169
|
+
n(e(J))
|
|
168
170
|
]),
|
|
169
171
|
_: 2
|
|
170
172
|
}, 1032, ["label", "back-label", "counts"]),
|
|
171
|
-
n(e(
|
|
173
|
+
n(e(b), {
|
|
172
174
|
ref_key: "deactivateDialog",
|
|
173
175
|
ref: d,
|
|
174
176
|
id: r.id,
|
|
175
177
|
name: r.name,
|
|
176
178
|
"session-count": e(u).data.value?.sessions.length ?? null,
|
|
177
|
-
onDone:
|
|
179
|
+
onDone: g
|
|
178
180
|
}, null, 8, ["id", "name", "session-count"]),
|
|
179
181
|
n(ue, {
|
|
180
182
|
ref_key: "passwordDialog",
|
|
181
|
-
ref:
|
|
183
|
+
ref: R,
|
|
182
184
|
id: r.id,
|
|
183
185
|
name: r.name,
|
|
184
|
-
onSaved:
|
|
186
|
+
onSaved: g
|
|
185
187
|
}, null, 8, ["id", "name"]),
|
|
186
|
-
n(e(
|
|
188
|
+
n(e(O), {
|
|
187
189
|
ref_key: "activateDialog",
|
|
188
190
|
ref: x,
|
|
189
191
|
icon: "checkCircle",
|
|
@@ -198,5 +200,5 @@ const ue = /* @__PURE__ */ E({
|
|
|
198
200
|
}
|
|
199
201
|
});
|
|
200
202
|
export {
|
|
201
|
-
|
|
203
|
+
Ve as default
|
|
202
204
|
};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { defineComponent as C, useTemplateRef as N, computed as a, openBlock as i, createBlock as m, unref as s, withCtx as r, createVNode as d, createTextVNode as R, toDisplayString as l, createCommentVNode as S, createElementBlock as _, normalizeClass as p } from "vue";
|
|
2
2
|
import { useI18n as E } from "vue-i18n";
|
|
3
3
|
import { useRouter as $ } from "vue-router";
|
|
4
|
-
import { u as B, _ as T } from "./CollectionPage.vue_vue_type_script_setup_true_lang-
|
|
4
|
+
import { u as B, _ as T } from "./CollectionPage.vue_vue_type_script_setup_true_lang-C1GCvyZx.js";
|
|
5
5
|
import { _ as V } from "./Avatar.vue_vue_type_script_setup_true_lang-BPj_fkJR.js";
|
|
6
|
-
import { u as L } from "./format-
|
|
7
|
-
import { u as z } from "./platform-
|
|
6
|
+
import { u as L } from "./format-DoKs29bZ.js";
|
|
7
|
+
import { u as z } from "./platform-DtISOEt7.js";
|
|
8
8
|
import { _ as A } from "./Badge.vue_vue_type_script_setup_true_lang-DJyZc0C7.js";
|
|
9
|
-
import { b as D, U as I, c as f, d as M, M as q, s as F } from "./index-
|
|
9
|
+
import { b as D, U as I, c as f, d as M, M as q, s as F } from "./index-DZikGJ8L.js";
|
|
10
10
|
const G = ["datetime"], Z = /* @__PURE__ */ C({
|
|
11
11
|
__name: "UsersList",
|
|
12
12
|
setup(K) {
|
package/dist/access/index.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { _ as f, a as R, b } from "../PersonAccess.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
import { _ as f, a as R, b } from "../PersonAccess.vue_vue_type_script_setup_true_lang-CWCt9_dM.js";
|
|
2
2
|
import { d as o, p as c } from "../feature-DdUAfyi4.js";
|
|
3
3
|
import { a as s, b as t } from "../refusals-DfPzVNNY.js";
|
|
4
4
|
import { d as g, p as x, r as h, c as v, u as y, e as C, f as K } from "../refusals-DfPzVNNY.js";
|
|
5
5
|
import { d as r } from "../defineRoutes-BGAdiIrt.js";
|
|
6
6
|
const a = r({
|
|
7
|
-
roles: { name: "access.roles", path: "/iam/roles", component: () => import("../RolesPage-
|
|
8
|
-
newRole: { name: "access.roles.new", path: "/iam/roles/new", component: () => import("../NewRolePage-
|
|
7
|
+
roles: { name: "access.roles", path: "/iam/roles", component: () => import("../RolesPage-NKzBUsrM.js"), meta: { access: s.viewRoles, titleKey: "core.access.title" } },
|
|
8
|
+
newRole: { name: "access.roles.new", path: "/iam/roles/new", component: () => import("../NewRolePage-CQ5UVaHs.js"), meta: { access: s.manageRoles, titleKey: "core.access.new_title" } },
|
|
9
9
|
role: {
|
|
10
10
|
name: "access.role",
|
|
11
11
|
path: "/iam/roles/:ref",
|
|
12
|
-
component: () => import("../RolePage-
|
|
12
|
+
component: () => import("../RolePage-BUj1w1m1.js"),
|
|
13
13
|
// A role's ref (its key, or the id of a custom one) swaps in place when a link leads to another role.
|
|
14
14
|
meta: { access: s.viewRoles, titleKey: "core.access.title", remountOnParam: "ref" }
|
|
15
15
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type App, type Component } from "vue";
|
|
2
2
|
import { type PluralizationRule } from "vue-i18n";
|
|
3
3
|
import { type RouteLocationRaw, type Router, type RouterHistory, type RouterScrollBehavior } from "vue-router";
|
|
4
|
-
import { type Formatters } from "../format";
|
|
4
|
+
import { type Formatters, type Formatting, type FormattingSettings } from "../format";
|
|
5
5
|
import { type MessageNamespace } from "../i18n";
|
|
6
6
|
import { type IconSet } from "../icon";
|
|
7
7
|
import { type Platform, type SessionSnapshot } from "../platform";
|
|
@@ -21,7 +21,8 @@ export interface ShellDefinition {
|
|
|
21
21
|
}
|
|
22
22
|
/** Where an error the application caught came from. */
|
|
23
23
|
export interface ApplicationErrorReport {
|
|
24
|
-
|
|
24
|
+
/** `handled`: an error the application's own code caught and showed the user (`report`), not one that escaped. */
|
|
25
|
+
readonly source: "vue" | "unhandledrejection" | "window" | "effect" | "messages" | "session" | "router" | "locale" | "handled";
|
|
25
26
|
readonly error: unknown;
|
|
26
27
|
/** The route the user was on, when there was one. */
|
|
27
28
|
readonly route: string | null;
|
|
@@ -82,10 +83,11 @@ export interface ApplicationOptions {
|
|
|
82
83
|
router?: ApplicationRouterOptions;
|
|
83
84
|
i18n?: ApplicationI18nOptions;
|
|
84
85
|
locale?: ApplicationLocaleOptions;
|
|
85
|
-
/**
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
86
|
+
/**
|
|
87
|
+
* How dates and numbers are written: the `Intl` formatters, any of them replaced, and the `FormattingSettings` (the `intlLocale` map, a numeric
|
|
88
|
+
* `datePattern` per language, `numberSymbols`, `emptyNumber`, the `currencySymbol` shown after an amount without an ISO currency).
|
|
89
|
+
*/
|
|
90
|
+
formatting?: Partial<Formatters> & FormattingSettings;
|
|
89
91
|
/** Message namespaces the application or its shell owns itself, outside any feature. */
|
|
90
92
|
messages?: readonly MessageNamespace[];
|
|
91
93
|
/** The application's icons (`installIcons`): one set, or several partial ones (a feature's own) that are merged. */
|
|
@@ -114,12 +116,18 @@ export interface ApplicationOptions {
|
|
|
114
116
|
export interface Application {
|
|
115
117
|
/** The Vue app, for the few things that need it (a plugin, a test). */
|
|
116
118
|
readonly app: App;
|
|
119
|
+
/** The app-scoped services, as `createApplication` was given them: `currentApplication().platform.http` outside setup. */
|
|
120
|
+
readonly platform: Platform;
|
|
121
|
+
/** The application's formatting (`useFormat()` in setup): dates, numbers and money in the active locale. */
|
|
122
|
+
readonly format: Formatting;
|
|
117
123
|
readonly router: Router;
|
|
118
124
|
/** The vue-i18n instance of this application. */
|
|
119
125
|
readonly i18n: ApplicationI18n;
|
|
120
126
|
readonly state: ApplicationEnvironment["state"];
|
|
121
127
|
readonly locale: ApplicationEnvironment["locale"];
|
|
122
128
|
setLocale: ApplicationEnvironment["setLocale"];
|
|
129
|
+
/** Reports an error the code caught and the user saw fail (`ApplicationEnvironment.report`), through `onError`. */
|
|
130
|
+
report: ApplicationEnvironment["report"];
|
|
123
131
|
/**
|
|
124
132
|
* Starts the application and mounts it: restores the session, loads the essential texts, runs the
|
|
125
133
|
* first navigation, then renders. A failure of the session or the texts mounts the failure view
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Application } from "./application";
|
|
2
|
+
/** Called by `createApplication`; the returned function unbinds, and only if this application is still the current one. */
|
|
3
|
+
export declare function bindApplication(application: Application): () => void;
|
|
4
|
+
/**
|
|
5
|
+
* The application `createApplication` made, for code that runs outside setup: an `api.ts` reading `currentApplication().platform.http`, a router
|
|
6
|
+
* guard, a store. Inside a component use `useApplication()` and the injected services; read it when the code runs, not at module load
|
|
7
|
+
* (a module is evaluated before `main.ts` creates the application).
|
|
8
|
+
*
|
|
9
|
+
* Throws before one exists. In a unit test make one first: `createTestApplication()` from `@wssto2/vue-core/testing`, and `dispose()` it after.
|
|
10
|
+
*/
|
|
11
|
+
export declare function currentApplication(): Application;
|
|
@@ -28,5 +28,13 @@ export interface ApplicationEnvironment {
|
|
|
28
28
|
setLocale(locale: string): Promise<boolean>;
|
|
29
29
|
/** Tries the start again after a failed one. */
|
|
30
30
|
retry(): Promise<void>;
|
|
31
|
+
/**
|
|
32
|
+
* Reports an error the code caught and the user saw fail (a save that did not go through, a panel that could not load): it goes
|
|
33
|
+
* through the application's `onError` as `source: "handled"` with the page the user was on, and `clientErrorReporter` sends it to the
|
|
34
|
+
* incidents. `detail` says where ("vehicle-location-edit"). Not for an error the user is expected to fix (a validation message).
|
|
35
|
+
*/
|
|
36
|
+
report(error: unknown, options?: {
|
|
37
|
+
readonly detail?: string;
|
|
38
|
+
}): void;
|
|
31
39
|
}
|
|
32
40
|
export declare const applicationKey: import("vue").InjectionKey<ApplicationEnvironment>, useApplication: () => ApplicationEnvironment;
|
package/dist/app/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { createApplication } from "./application";
|
|
2
2
|
export type { Application, ApplicationI18n, ApplicationErrorReport, ApplicationI18nOptions, ApplicationLocaleOptions, ApplicationOptions, ApplicationRouterOptions, ShellDefinition, } from "./application";
|
|
3
|
+
export { currentApplication } from "./current";
|
|
3
4
|
export { ShellOutlet } from "./contributions";
|
|
4
5
|
export { applicationKey, useApplication } from "./environment";
|
|
5
6
|
export type { ApplicationEnvironment, ApplicationState } from "./environment";
|
package/dist/app/index.js
CHANGED
|
@@ -1,16 +1,18 @@
|
|
|
1
|
-
import { A as o, c as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
1
|
+
import { A as o, c as r } from "../application-DomS6sbx.js";
|
|
2
|
+
import { c as t } from "../current-B0lHKTWr.js";
|
|
3
|
+
import { S as i } from "../contributions-obnyn03x.js";
|
|
4
|
+
import { a as c, u as l } from "../environment-Dva-SG8D.js";
|
|
5
|
+
import { d as f, p as x } from "../feature-DdUAfyi4.js";
|
|
6
|
+
import { k as A, u as d } from "../keepAlive-ClGnsIzT.js";
|
|
6
7
|
export {
|
|
7
8
|
o as ApplicationError,
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
9
|
+
i as ShellOutlet,
|
|
10
|
+
c as applicationKey,
|
|
11
|
+
r as createApplication,
|
|
12
|
+
t as currentApplication,
|
|
13
|
+
f as defineFeature,
|
|
14
|
+
A as keepSessionAlive,
|
|
15
|
+
x as provideContext,
|
|
14
16
|
l as useApplication,
|
|
15
|
-
|
|
17
|
+
d as useLanguages
|
|
16
18
|
};
|