@wssto2/vue-core 0.6.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (143) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/README.md +3 -0
  3. package/dist/{AccessGate.vue_vue_type_script_setup_true_lang-DZ9GcLC1.js → AccessGate.vue_vue_type_script_setup_true_lang-CkomzGrt.js} +1 -1
  4. package/dist/{AccountMenuItem.vue_vue_type_script_setup_true_lang-CPeNxh5K.js → AccountMenuItem.vue_vue_type_script_setup_true_lang-BIYgaihv.js} +1 -1
  5. package/dist/{ActionRow.vue_vue_type_script_setup_true_lang-D8NCXX4p.js → ActionRow.vue_vue_type_script_setup_true_lang-Cg1lhpcA.js} +2 -2
  6. package/dist/{Activity-DGodh6BU.js → Activity-CW2TOQAY.js} +9 -9
  7. package/dist/{AdaptivePageShell.vue_vue_type_script_setup_true_lang-GUTIXuNd.js → AdaptivePageShell.vue_vue_type_script_setup_true_lang-9Lt1XggN.js} +3 -3
  8. package/dist/{AlertDialog.vue_vue_type_script_setup_true_lang-whA4WLdl.js → AlertDialog.vue_vue_type_script_setup_true_lang-BvGc1Rfl.js} +1 -1
  9. package/dist/{AsyncSection.vue_vue_type_script_setup_true_lang-B0NfvG3B.js → AsyncSection.vue_vue_type_script_setup_true_lang-GxAsImnO.js} +4 -4
  10. package/dist/{Banner.vue_vue_type_script_setup_true_lang-DSStj_5z.js → Banner.vue_vue_type_script_setup_true_lang-sv0phngk.js} +1 -1
  11. package/dist/{Button.vue_vue_type_script_setup_true_lang-CL9Qh5yq.js → Button.vue_vue_type_script_setup_true_lang-DQq_0P0p.js} +1 -1
  12. package/dist/{Changes-38u4xY6e.js → Changes-BCaVkeZg.js} +8 -8
  13. package/dist/{CollectionPage.vue_vue_type_script_setup_true_lang-DPcCnrjr.js → CollectionPage.vue_vue_type_script_setup_true_lang-BmXnfM5f.js} +17 -16
  14. package/dist/{DataTable.vue_vue_type_script_setup_true_lang-BEvz5zqo.js → DataTable.vue_vue_type_script_setup_true_lang-DRWrCRLr.js} +1 -1
  15. package/dist/{DateField.vue_vue_type_script_setup_true_lang-BxUuUypB.js → DateField.vue_vue_type_script_setup_true_lang-DmYp54mq.js} +3 -3
  16. package/dist/{DeadLetters-CeHfhFHP.js → DeadLetters-DUM_bsL-.js} +5 -5
  17. package/dist/{DiscardChangesModal.vue_vue_type_script_setup_true_lang-D1arePCZ.js → DiscardChangesModal.vue_vue_type_script_setup_true_lang-DcihJfpk.js} +1 -1
  18. package/dist/{EmptyState.vue_vue_type_script_setup_true_lang-50p-Mp8I.js → EmptyState.vue_vue_type_script_setup_true_lang-DbZiO2RF.js} +1 -1
  19. package/dist/{FormErrors.vue_vue_type_script_setup_true_lang-D7edzNTL.js → FormErrors.vue_vue_type_script_setup_true_lang-DJiK8iqo.js} +1 -1
  20. package/dist/{FormGroup.vue_vue_type_script_setup_true_lang-CNb2CK01.js → FormGroup.vue_vue_type_script_setup_true_lang-BTADNpwB.js} +2 -2
  21. package/dist/{FormView.vue_vue_type_script_setup_true_lang-nyz8EkzM.js → FormView.vue_vue_type_script_setup_true_lang-Ncl9DmFB.js} +2 -2
  22. package/dist/{General-BNTjPvat.js → General-Dsh0TJ5w.js} +8 -8
  23. package/dist/{HeaderAction.vue_vue_type_script_setup_true_lang-Cgji-Jrr.js → HeaderAction.vue_vue_type_script_setup_true_lang-Da59TLBh.js} +2 -2
  24. package/dist/{Icon.vue_vue_type_script_lang-D7oC-d-S.js → Icon.vue_vue_type_script_lang-BhhsFYwp.js} +45 -42
  25. package/dist/{IconTile.vue_vue_type_script_setup_true_lang-_FXvaj93.js → IconTile.vue_vue_type_script_setup_true_lang-BmxCuUZ9.js} +1 -1
  26. package/dist/IncidentRecord-C9zrjNrp.js +405 -0
  27. package/dist/IncidentsList-ClQOjd5c.js +140 -0
  28. package/dist/KeyValue.vue_vue_type_script_setup_true_lang-wcZcvnow.js +35 -0
  29. package/dist/{LeaveGuardRoot.vue_vue_type_script_setup_true_lang-Cv7KlA5y.js → LeaveGuardRoot.vue_vue_type_script_setup_true_lang-ChIsmnts.js} +1 -1
  30. package/dist/{Menu.vue_vue_type_script_setup_true_lang-DsFOeCVe.js → Menu.vue_vue_type_script_setup_true_lang-ldLdJ5Q-.js} +1 -1
  31. package/dist/{MenuButton.vue_vue_type_script_setup_true_lang-AGbN9r5q.js → MenuButton.vue_vue_type_script_setup_true_lang-C-XRr5f2.js} +1 -1
  32. package/dist/{Modal.vue_vue_type_script_setup_true_lang-DpBb8ans.js → Modal.vue_vue_type_script_setup_true_lang-4MsnTWyx.js} +2 -2
  33. package/dist/{NewRolePage-Btg7gzzH.js → NewRolePage-Bw2_jXcQ.js} +4 -4
  34. package/dist/{NoAccess.vue_vue_type_script_setup_true_lang-DWxq-MTM.js → NoAccess.vue_vue_type_script_setup_true_lang-BHzZtZ50.js} +1 -1
  35. package/dist/{NumberField.vue_vue_type_script_setup_true_lang-C8um4ARi.js → NumberField.vue_vue_type_script_setup_true_lang-C3nw944P.js} +1 -1
  36. package/dist/{PageBar.vue_vue_type_script_setup_true_lang-B7qdEeej.js → PageBar.vue_vue_type_script_setup_true_lang-DPpcZxuT.js} +1 -1
  37. package/dist/{Panel.vue_vue_type_script_setup_true_lang-BA0u_DtS.js → Panel.vue_vue_type_script_setup_true_lang-D_Wg42hu.js} +1 -1
  38. package/dist/{PersonAccess.vue_vue_type_script_setup_true_lang-ClmawvYm.js → PersonAccess.vue_vue_type_script_setup_true_lang-07pq4SrY.js} +12 -12
  39. package/dist/{PhotoViewer.vue_vue_type_script_setup_true_lang-CY5EZiyK.js → PhotoViewer.vue_vue_type_script_setup_true_lang-Cj0hSMk9.js} +1 -1
  40. package/dist/{ProfilePage-CoZyG11N.js → ProfilePage-CJIztbx3.js} +19 -19
  41. package/dist/{RecordHeader.vue_vue_type_script_setup_true_lang-fmx0f8xi.js → RecordHeader.vue_vue_type_script_setup_true_lang-DPm9q1P_.js} +2 -2
  42. package/dist/{ResourcePage.vue_vue_type_script_setup_true_lang-BFBGvevP.js → ResourcePage.vue_vue_type_script_setup_true_lang-Cm3tx76N.js} +5 -5
  43. package/dist/{RoleEditor.vue_vue_type_script_setup_true_lang-Bs9bo0Zb.js → RoleEditor.vue_vue_type_script_setup_true_lang-DuQR8hFf.js} +13 -13
  44. package/dist/{RolePage-CPlwZA6X.js → RolePage-Yv6m6u7o.js} +13 -13
  45. package/dist/{RolesPage-CdYdIHR4.js → RolesPage-TibtzxzQ.js} +9 -9
  46. package/dist/{SectionList.vue_vue_type_script_setup_true_lang-wyW7n3Uq.js → SectionList.vue_vue_type_script_setup_true_lang-DAnZbfWA.js} +3 -3
  47. package/dist/{SectionNavigator.vue_vue_type_script_setup_true_lang-Ci04hApd.js → SectionNavigator.vue_vue_type_script_setup_true_lang-ivdGWUeF.js} +5 -5
  48. package/dist/{SegmentedField.vue_vue_type_script_setup_true_lang-B_hBL5f4.js → SegmentedField.vue_vue_type_script_setup_true_lang-ChfDFAA2.js} +1 -1
  49. package/dist/{SelectField.vue_vue_type_script_setup_true_lang-CBZhGNpm.js → SelectField.vue_vue_type_script_setup_true_lang-iJm8qmjT.js} +5 -5
  50. package/dist/{ServiceAccountDialog.vue_vue_type_script_setup_true_lang-DuvSSBbX.js → ServiceAccountDialog.vue_vue_type_script_setup_true_lang-D2Xj5mr7.js} +8 -8
  51. package/dist/{ServiceAccountRecord-BtaUZuWU.js → ServiceAccountRecord-Ct3TrSqZ.js} +18 -18
  52. package/dist/{ServiceAccountsList-CcRJvNaf.js → ServiceAccountsList-CaXEp73j.js} +10 -10
  53. package/dist/{SessionList.vue_vue_type_script_setup_true_lang-VvBB2EZz.js → SessionList.vue_vue_type_script_setup_true_lang-BEKTaL0g.js} +4 -4
  54. package/dist/{Sessions-DkGNO1FO.js → Sessions-Bg4Zk9Gf.js} +6 -6
  55. package/dist/{SettingsPage-D4G1HGbG.js → SettingsPage-Brq9U4tJ.js} +19 -19
  56. package/dist/{Sheet.vue_vue_type_script_setup_true_lang-DgOFV4fa.js → Sheet.vue_vue_type_script_setup_true_lang-sh9YD0Pm.js} +1 -1
  57. package/dist/{SignIn-DS1YymqD.js → SignIn-DB5LRNlB.js} +7 -7
  58. package/dist/{SignInPage-BrmL0PUw.js → SignInPage-Ts-iTaC1.js} +6 -6
  59. package/dist/{SignIns-C7l7IPHQ.js → SignIns-bCvvmCHF.js} +6 -6
  60. package/dist/{SwipeActions.vue_vue_type_script_setup_true_lang-BJIA2JfI.js → SwipeActions.vue_vue_type_script_setup_true_lang-D8SiC0G7.js} +1 -1
  61. package/dist/{SwitchField.vue_vue_type_script_setup_true_lang-DXZK89A3.js → SwitchField.vue_vue_type_script_setup_true_lang-BMA2YXTZ.js} +1 -1
  62. package/dist/{Tabs.vue_vue_type_script_setup_true_lang-CcMcE38r.js → Tabs.vue_vue_type_script_setup_true_lang-tpkGp98F.js} +1 -1
  63. package/dist/{TextField.vue_vue_type_script_setup_true_lang-CX3LdZLK.js → TextField.vue_vue_type_script_setup_true_lang-7IAl4eAE.js} +3 -3
  64. package/dist/{TextareaField.vue_vue_type_script_setup_true_lang-BOtn_1GT.js → TextareaField.vue_vue_type_script_setup_true_lang-Dyh4Hhyl.js} +1 -1
  65. package/dist/{TimeField.vue_vue_type_script_setup_true_lang-CbflIrq6.js → TimeField.vue_vue_type_script_setup_true_lang-BwoE08jT.js} +3 -3
  66. package/dist/{Timestamp.vue_vue_type_script_setup_true_lang-CutyQkJb.js → Timestamp.vue_vue_type_script_setup_true_lang-u53rHMFG.js} +1 -1
  67. package/dist/{UserRecord-Du8M_kuk.js → UserRecord-DgK9FsvV.js} +12 -12
  68. package/dist/{UsersList-D3ydQice.js → UsersList-Due2ZkbO.js} +8 -8
  69. package/dist/{ViewTabs.vue_vue_type_script_setup_true_lang-BJIoZAlH.js → ViewTabs.vue_vue_type_script_setup_true_lang-BjdDXE3T.js} +1 -1
  70. package/dist/access/index.js +4 -4
  71. package/dist/app/application.d.ts +2 -0
  72. package/dist/app/index.js +13 -427
  73. package/dist/application-D8Nm17zA.js +420 -0
  74. package/dist/button/index.js +1 -1
  75. package/dist/client/client.d.ts +7 -0
  76. package/dist/client/index.d.ts +1 -1
  77. package/dist/client/index.js +5 -4
  78. package/dist/client-CZgikXPG.js +151 -0
  79. package/dist/collection/index.js +55 -64
  80. package/dist/content/index.js +37 -66
  81. package/dist/{contributions-fx5q5n1u.js → contributions-BQ9dZoRw.js} +1 -1
  82. package/dist/controls/index.js +4 -4
  83. package/dist/datePresets-DB13HHHd.js +17 -0
  84. package/dist/definition-C7QuyV3i.js +54 -0
  85. package/dist/form/index.js +34 -34
  86. package/dist/{guards-D4mXf_2X.js → guards-BFCulig0.js} +1 -1
  87. package/dist/i18n/index.js +18 -18
  88. package/dist/icon/core.d.ts +3 -0
  89. package/dist/icon/index.js +1 -1
  90. package/dist/identity/index.js +2 -2
  91. package/dist/incidents/IncidentRecord.vue.d.ts +2 -0
  92. package/dist/incidents/IncidentsList.vue.d.ts +2 -0
  93. package/dist/incidents/Person.vue.d.ts +7 -0
  94. package/dist/incidents/ReportDialog.vue.d.ts +21 -0
  95. package/dist/incidents/ReportHost.vue.d.ts +2 -0
  96. package/dist/incidents/ReportMenuItem.vue.d.ts +2 -0
  97. package/dist/incidents/access.d.ts +6 -0
  98. package/dist/incidents/api.d.ts +27 -0
  99. package/dist/incidents/clientErrorReporter.d.ts +38 -0
  100. package/dist/incidents/context.d.ts +7 -0
  101. package/dist/incidents/feature.d.ts +20 -0
  102. package/dist/incidents/form.d.ts +16 -0
  103. package/dist/incidents/index.d.ts +9 -0
  104. package/dist/incidents/index.js +8 -0
  105. package/dist/incidents/look.d.ts +6 -0
  106. package/dist/incidents/routes.d.ts +21 -0
  107. package/dist/{index-Cmj9iZmT.js → index-CXTJ_1NV.js} +21 -21
  108. package/dist/index-D5_GAqjA.js +340 -0
  109. package/dist/{index-DH0MoFqg.js → index-i-cTTVxo.js} +10 -10
  110. package/dist/index.d.ts +1 -1
  111. package/dist/index.js +1 -1
  112. package/dist/modal/index.js +5 -5
  113. package/dist/modules/incident/entities.d.ts +84 -0
  114. package/dist/modules/incident/routes.d.ts +54 -0
  115. package/dist/modules/incident/schemas.d.ts +48 -0
  116. package/dist/{navigation-Bc5EQ_Si.js → navigation-BSC9X7FM.js} +1 -1
  117. package/dist/{neighbors-DNZuGlQH.js → neighbors-BKzihEGQ.js} +1 -1
  118. package/dist/notifications/index.js +1 -1
  119. package/dist/{options-e_CAfvDQ.js → options-QuOkMKVZ.js} +1 -1
  120. package/dist/overlay/index.js +4 -4
  121. package/dist/page/index.js +7 -7
  122. package/dist/phone/index.js +2 -2
  123. package/dist/platform/index.js +3 -3
  124. package/dist/{platform-Dx6STiwY.js → platform-Dr4iY3b8.js} +1 -1
  125. package/dist/resource/index.js +1 -1
  126. package/dist/router/index.js +4 -4
  127. package/dist/{rowLayout-BBFyLbOl.js → rowLayout-Cz-K7jeo.js} +5 -5
  128. package/dist/{sections-B0HxIOC2.js → sections-BXg4_ZhO.js} +1 -1
  129. package/dist/shell/index.js +9 -9
  130. package/dist/state/index.js +4 -4
  131. package/dist/state-ChVIjayU.js +102 -0
  132. package/dist/{status-C8XtnK6m.js → status-DZ4eSnAS.js} +5 -5
  133. package/dist/styles.css +1 -1
  134. package/dist/{suggestions-cPjs5gQz.js → suggestions-niXd1oOl.js} +1 -1
  135. package/dist/testing/index.js +1 -1
  136. package/dist/{useCommand-CfG727e8.js → useCommand-BIZX1ReM.js} +4 -4
  137. package/dist/{useGroupSheet-BVcNDWbP.js → useGroupSheet-DxXzdKo3.js} +5 -5
  138. package/dist/{useRecordDialog-D65FF85F.js → useRecordDialog-BLVSz7g3.js} +1 -1
  139. package/dist/{useResourceForm-CJfl8rj_.js → useResourceForm-DYuYT_on.js} +1 -1
  140. package/dist/{useTypedEntry-C7k7Dyl-.js → useTypedEntry-CKuGqWT8.js} +2 -2
  141. package/package.json +6 -2
  142. package/dist/client-BHPFfBj3.js +0 -147
  143. package/dist/state-BC1Fc6U2.js +0 -154
@@ -0,0 +1,420 @@
1
+ var Se = Object.defineProperty;
2
+ var xe = (e, n, r) => n in e ? Se(e, n, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[n] = r;
3
+ var Z = (e, n, r) => xe(e, typeof n != "symbol" ? n + "" : n, r);
4
+ import { effectScope as P, watch as W, defineComponent as pe, openBlock as Me, createElementBlock as Le, createVNode as ee, unref as _, withCtx as te, createTextVNode as je, toDisplayString as Ae, shallowRef as Ne, computed as Ke, h as se, createApp as Oe } from "vue";
5
+ import { useI18n as _e, createI18n as Ce } from "vue-i18n";
6
+ import { createRouter as Fe, isNavigationFailure as Ie } from "vue-router";
7
+ import { i as Te } from "./leaveGuard-Cc8yeLxM.js";
8
+ import { c as qe, i as De, f as Pe } from "./format-D8X4zsx6.js";
9
+ import { coreMessages as oe, createMessageRuntime as We } from "./i18n/index.js";
10
+ import { i as Be, a as He } from "./Icon.vue_vue_type_script_lang-BhhsFYwp.js";
11
+ import { i as Ve, b as Ge } from "./bottomDock-BZEiOPYZ.js";
12
+ import { i as Je, p as ze } from "./chrome-nUcmVu8G.js";
13
+ import { i as Qe, g as Ue } from "./platform-Dr4iY3b8.js";
14
+ import { c as Xe, A as Ye, r as re } from "./access-DmAceEo5.js";
15
+ import { c as Ze, _ as et } from "./NoAccess.vue_vue_type_script_setup_true_lang-BHzZtZ50.js";
16
+ import { i as tt } from "./guards-BFCulig0.js";
17
+ import { b as st, c as ot, n as ae } from "./navigation-BSC9X7FM.js";
18
+ import { c as rt, s as ne } from "./contributions-BQ9dZoRw.js";
19
+ import { a as ie } from "./environment-Dva-SG8D.js";
20
+ import { b as ce, c as le } from "./describeError-BqGAUZgX.js";
21
+ import { _ as at } from "./Button.vue_vue_type_script_setup_true_lang-DQq_0P0p.js";
22
+ import { _ as nt } from "./EmptyState.vue_vue_type_script_setup_true_lang-DbZiO2RF.js";
23
+ import { i as it } from "./feature-DdUAfyi4.js";
24
+ function ct(e) {
25
+ const { platform: n } = e, r = P();
26
+ let i = null, v = null, y = !1;
27
+ function E(l, m) {
28
+ const h = new AbortController(), u = { controller: h, stops: [] };
29
+ for (const k of l)
30
+ try {
31
+ const b = m(k, h.signal);
32
+ typeof b == "function" && u.stops.push({ owned: k, stop: b });
33
+ } catch (b) {
34
+ e.onError(b, k);
35
+ }
36
+ return u;
37
+ }
38
+ function x(l) {
39
+ if (l) {
40
+ l.controller.abort();
41
+ for (const { owned: m, stop: h } of l.stops.reverse())
42
+ try {
43
+ h();
44
+ } catch (u) {
45
+ e.onError(u, m);
46
+ }
47
+ }
48
+ }
49
+ const j = (l) => e.effects.filter((m) => m.effect.scope === l), M = (l) => l.status !== "authenticated" ? null : e.sessionKey ? e.sessionKey(l) : String(l.user.id);
50
+ return {
51
+ start() {
52
+ if (y || i) return;
53
+ i = E(
54
+ j("app"),
55
+ (m, h) => m.effect.start({ signal: h, platform: n, report: (u) => e.onError(u, m) })
56
+ );
57
+ const l = j("session");
58
+ r.run(
59
+ () => W(
60
+ () => M(n.session.state.value),
61
+ (m) => {
62
+ x(v), v = null;
63
+ const h = n.session.state.value;
64
+ m === null || h.status !== "authenticated" || (v = E(
65
+ l,
66
+ (u, k) => u.effect.start({ signal: k, platform: n, user: h.user, report: (b) => e.onError(b, u) })
67
+ ));
68
+ },
69
+ { immediate: !0, flush: "sync" }
70
+ )
71
+ );
72
+ },
73
+ dispose() {
74
+ y || (y = !0, r.stop(), x(v), x(i), v = i = null);
75
+ }
76
+ };
77
+ }
78
+ const lt = { class: "mx-auto flex min-h-screen max-w-content items-center justify-center p-screen-padding" }, ut = /* @__PURE__ */ pe({
79
+ __name: "StartupFailure",
80
+ props: {
81
+ kind: {}
82
+ },
83
+ emits: ["retry"],
84
+ setup(e) {
85
+ const { t: n } = _e();
86
+ return (r, i) => (Me(), Le("div", lt, [
87
+ ee(_(nt), {
88
+ title: _(n)("core.startup.title"),
89
+ description: _(n)(e.kind === "startup" ? "core.startup.other" : `core.startup.${e.kind}`),
90
+ icon: "errorWarningLine"
91
+ }, {
92
+ actions: te(() => [
93
+ ee(_(at), {
94
+ prominence: "primary",
95
+ icon: "refreshLine",
96
+ onClick: i[0] || (i[0] = (v) => r.$emit("retry"))
97
+ }, {
98
+ default: te(() => [
99
+ je(Ae(_(n)("core.actions.retry")), 1)
100
+ ]),
101
+ _: 1
102
+ })
103
+ ]),
104
+ _: 1
105
+ }, 8, ["title", "description"])
106
+ ]));
107
+ }
108
+ });
109
+ class ue extends Error {
110
+ constructor(r) {
111
+ super(`The application composition is invalid:
112
+ ${r.map((i) => ` - [${i.owner}] ${i.message}`).join(`
113
+ `)}`);
114
+ Z(this, "issues");
115
+ this.name = "ApplicationError", this.issues = r;
116
+ }
117
+ }
118
+ const fe = "application", w = (e) => `feature "${e.id}"`;
119
+ function* B(e, n = "") {
120
+ for (const r of e) {
121
+ const i = r.path.startsWith("/") ? r.path : `${n.replace(/\/$/, "")}/${r.path}`;
122
+ yield { record: r, path: i }, r.children && (yield* B(r.children, i));
123
+ }
124
+ }
125
+ function ft(e) {
126
+ const n = [], r = (o, s) => n.push({ owner: o, message: s }), i = [];
127
+ e.features.forEach((o, s) => {
128
+ it(o) ? i.push(o) : r(fe, `features[${s}] was not created with defineFeature().`);
129
+ });
130
+ const v = /* @__PURE__ */ new Map();
131
+ for (const o of i)
132
+ v.has(o.id) ? r(w(o), `the feature id "${o.id}" is used twice in the features list.`) : v.set(o.id, o);
133
+ for (const o of i)
134
+ for (const s of o.requires)
135
+ v.has(s) || r(w(o), `requires the feature "${s}", which is not in the features list.`);
136
+ const y = [], E = /* @__PURE__ */ new Set(), x = (o) => {
137
+ if (E.has(o.id)) return;
138
+ const s = y.indexOf(o.id);
139
+ if (s !== -1) {
140
+ r(w(o), `requirements form a cycle: ${[...y.slice(s), o.id].join(" -> ")}.`), E.add(o.id);
141
+ return;
142
+ }
143
+ y.push(o.id);
144
+ for (const c of o.requires) {
145
+ const f = v.get(c);
146
+ f && x(f);
147
+ }
148
+ y.pop(), E.add(o.id);
149
+ };
150
+ i.forEach(x);
151
+ const j = new Set(e.platform.config.capabilities);
152
+ for (const o of i)
153
+ for (const s of o.backend)
154
+ j.has(s) || r(w(o), `needs the backend capability "${s}", which the server does not report.`);
155
+ const M = /* @__PURE__ */ new Map(), l = /* @__PURE__ */ new Map();
156
+ for (const o of i) {
157
+ for (const s of o.routes) {
158
+ const c = s.path.length > 1 ? s.path.replace(/\/$/, "") : s.path, f = l.get(c);
159
+ f ? r(w(o), `declares the path "${s.path}", which feature "${f.id}" declares too.`) : l.set(c, o);
160
+ }
161
+ for (const { record: s } of B(o.routes)) {
162
+ if (s.meta && "feature" in s.meta && r(w(o), `the route "${String(s.name ?? s.path)}" sets meta.feature, which the runtime owns.`), typeof s.name != "string") continue;
163
+ const c = M.get(s.name);
164
+ c ? r(w(o), `declares the route name "${s.name}", which feature "${c.id}" declares too.`) : M.set(s.name, o);
165
+ }
166
+ }
167
+ const m = new Set(e.reservedContexts), h = /* @__PURE__ */ new Map();
168
+ for (const o of i)
169
+ for (const { key: s } of o.contexts) {
170
+ const c = s.description ?? "a context";
171
+ m.has(s) && r(w(o), `provides the context "${c}", which the runtime provides itself.`);
172
+ const f = h.get(s);
173
+ f ? r(w(o), `provides the context "${c}", which feature "${f.id}" provides too.`) : h.set(s, o);
174
+ }
175
+ const u = /* @__PURE__ */ new Map(), k = (o, s) => {
176
+ for (const c of s) {
177
+ const f = u.get(c.namespace);
178
+ f ? r(o, `declares the message namespace "${c.namespace}", which ${f} declares too.`) : u.set(c.namespace, o);
179
+ for (const A of Object.keys(c.loaders))
180
+ e.supportedLocales.includes(A) || r(o, `the namespace "${c.namespace}" has a loader for "${A}", which is not a supported locale (${e.supportedLocales.join(", ")}).`);
181
+ }
182
+ };
183
+ for (const o of i) k(w(o), o.messages);
184
+ k(fe, e.messages);
185
+ const b = (o) => u.has(o);
186
+ for (const o of i)
187
+ for (const { record: s } of B(o.routes))
188
+ for (const c of s.meta?.messages ?? [])
189
+ b(c) || r(w(o), `the route "${String(s.name ?? s.path)}" needs the message namespace "${c}", which nobody declares.`);
190
+ const R = /* @__PURE__ */ new Map();
191
+ for (const o of i)
192
+ for (const s of o.contributions) {
193
+ const c = R.get(s.id);
194
+ c ? r(w(o), `declares the shell contribution "${s.id}", which feature "${c.id}" declares too.`) : R.set(s.id, o), e.shellSlots && !s.optional && !e.shellSlots.includes(s.slot) && r(w(o), `contributes "${s.id}" to the slot "${s.slot}", which the shell does not render (it renders ${e.shellSlots.join(", ") || "none"}). Mark it optional to leave it out instead.`);
195
+ for (const f of s.messages ?? [])
196
+ b(f) || r(w(o), `the contribution "${s.id}" needs the message namespace "${f}", which nobody declares.`);
197
+ }
198
+ const L = /* @__PURE__ */ new Map();
199
+ for (const o of i)
200
+ for (const s of o.effects) {
201
+ const c = L.get(s.id);
202
+ c ? r(w(o), `declares the effect "${s.id}", which feature "${c.id}" declares too.`) : L.set(s.id, o);
203
+ const f = s.scope;
204
+ f !== "app" && f !== "session" && r(w(o), `the effect "${s.id}" has the scope "${f}"; use "app" or "session".`);
205
+ }
206
+ return { features: i, issues: n };
207
+ }
208
+ const dt = (e, n, r) => Ce({
209
+ legacy: !1,
210
+ locale: e,
211
+ fallbackLocale: n,
212
+ pluralRules: r?.pluralRules && { ...r.pluralRules },
213
+ ...r?.missingWarn === !1 && { missingWarn: !1, fallbackWarn: !1 },
214
+ messages: {}
215
+ }), pt = (e) => typeof e == "object" && e !== null && "component" in e && "slots" in e;
216
+ function me(e, n) {
217
+ return e.map((r) => ({
218
+ ...r,
219
+ meta: { ...r.meta, feature: n },
220
+ ...r.children && { children: me(r.children, n) }
221
+ }));
222
+ }
223
+ const de = (e) => [...new Set(e)];
224
+ function Tt(e) {
225
+ const { platform: n } = e, r = e.locale?.supported ?? Object.keys(oe), i = e.locale?.fallback ?? "en", v = e.shell === void 0 ? void 0 : pt(e.shell) ? e.shell : { component: e.shell, slots: void 0, progress: void 0 }, y = [];
226
+ r.includes(i) || y.push({ owner: "application", message: `the fallback locale "${i}" is not among the supported locales (${r.join(", ")}).` });
227
+ for (const t of Object.keys(e.locale?.flags ?? {}))
228
+ r.includes(t) || y.push({ owner: "application", message: `locale.flags names the locale "${t}", which is not among the supported locales (${r.join(", ")}).` });
229
+ const E = e.locale?.initial ?? (r.includes(n.config.locale) ? n.config.locale : i);
230
+ r.includes(E) || y.push({ owner: "application", message: `the initial locale "${E}" is not among the supported locales (${r.join(", ")}).` });
231
+ const x = [Ue, Pe, ze, Ge, He, ae, ne, re, ie, ce, le], j = ft({
232
+ features: e.features,
233
+ platform: n,
234
+ messages: e.messages ?? [],
235
+ reservedContexts: x,
236
+ supportedLocales: r,
237
+ shellSlots: v?.slots
238
+ }), M = [...y, ...j.issues], l = j.features, m = st(
239
+ l.flatMap((t) => t.navigation.map((a) => ({ feature: t.id, binding: a }))),
240
+ e.navigation
241
+ );
242
+ for (const t of m.issues) M.push({ owner: "navigation", message: t });
243
+ if (M.length > 0) throw new ue(M);
244
+ const h = dt(E, i, e.i18n), u = h.global;
245
+ for (const [t, a] of Object.entries(oe)) u.mergeLocaleMessage(t, a);
246
+ for (const [t, a] of Object.entries(e.i18n?.messages ?? {})) u.mergeLocaleMessage(t, a);
247
+ const k = qe({ locale: () => u.locale.value, formatters: e.formatting }), b = [...l.flatMap((t) => t.messages), ...e.messages ?? []], R = (t) => (e.onError ?? mt)({ ...t, route: s.currentRoute.value.matched.length > 0 ? s.currentRoute.value.fullPath : null }), L = We({
248
+ target: u,
249
+ namespaces: b,
250
+ fallback: i,
251
+ supported: r,
252
+ onFailure: (t) => R({ source: "messages", error: t.error, detail: `${t.namespace} (${t.locale})`, feature: o.get(t.namespace) })
253
+ }), o = new Map(l.flatMap((t) => t.messages.map((a) => [a.namespace, t.id]))), s = Fe({
254
+ history: e.router?.history ?? Ze(),
255
+ routes: l.flatMap((t) => me(t.routes, t.id)),
256
+ scrollBehavior: e.router?.scrollBehavior ?? ((t, a) => t.name === a.name ? !1 : { top: 0 })
257
+ }), c = e.router?.login ?? { name: "login" }, f = e.router?.home ?? { path: "/" }, A = [], H = (t) => {
258
+ try {
259
+ return s.resolve(t).matched.length > 0 ? null : "matches no route";
260
+ } catch (a) {
261
+ const p = a instanceof Error ? a.message : String(a);
262
+ return p.startsWith("No match for") ? "matches no route" : `cannot be resolved (${p})`;
263
+ }
264
+ };
265
+ if (l.some((t) => t.routes.some((a) => a.meta?.public !== !0))) {
266
+ const t = H(c) ?? (s.resolve(c).meta.public === !0 ? null : "is not public (meta.public: true)");
267
+ t && A.push({ owner: "application", message: `the login route ${JSON.stringify(c)} ${t.replace("matches no route", "does not exist")}, but protected routes are installed: an anonymous visitor would have nowhere to go. Install a feature with the login route or set router.login.` });
268
+ }
269
+ for (const { feature: t, binding: a } of m.destinations.values()) {
270
+ const p = H(a.to);
271
+ p && A.push({ owner: `feature "${t}"`, message: `the destination "${a.destination}" is bound to ${JSON.stringify(a.to)}, which ${p}.` });
272
+ }
273
+ if (A.length > 0) throw new ue(A);
274
+ const N = Ne({ status: "idle" }), C = {
275
+ state: N,
276
+ locale: Ke(() => u.locale.value),
277
+ locales: r,
278
+ localeFlags: e.locale?.flags ?? {},
279
+ setLocale: async (t) => {
280
+ const a = u.locale.value, p = await L.setLocale(t);
281
+ if (p && u.locale.value !== a) {
282
+ const g = (O) => R({ source: "locale", error: O, detail: t });
283
+ try {
284
+ Promise.resolve(e.locale?.onChange?.(t)).catch(g);
285
+ } catch (O) {
286
+ g(O);
287
+ }
288
+ }
289
+ return p;
290
+ },
291
+ retry: () => D()
292
+ }, I = {
293
+ contributions: l.flatMap((t) => t.contributions.map((a) => ({ feature: t.id, contribution: a }))),
294
+ effects: l.flatMap((t) => t.effects.map((a) => ({ feature: t.id, effect: a })))
295
+ }, V = ct({
296
+ effects: I.effects,
297
+ platform: n,
298
+ sessionKey: e.sessionKey,
299
+ onError: (t, a) => R({ source: "effect", error: t, feature: a.feature, detail: a.effect.id })
300
+ }), he = new Map(l.map((t) => [t.id, t.messages.map((a) => a.namespace)])), G = (t) => de(I.contributions.filter(({ contribution: a }) => a.scope === t).flatMap(({ contribution: a }) => a.messages ?? [])), ge = G("always"), we = G("authenticated");
301
+ async function ve(t) {
302
+ const a = t.matched.flatMap((g) => [...he.get(g.meta.feature ?? "") ?? [], ...g.meta.messages ?? []]), p = n.session.state.value.status === "authenticated";
303
+ await L.load(de([...a, ...ge, ...p ? we : []]));
304
+ }
305
+ let T = null;
306
+ function q(t) {
307
+ const a = t.meta.titleKey, p = T?.documentTitle.value ?? (a && u.te(a) ? u.t(a) : null), g = (e.router?.documentTitle ?? ht)(p, n.config.appName);
308
+ g !== "" && (document.title = g);
309
+ }
310
+ const ye = ot({ session: n.session, router: s, i18n: u, destinations: m.destinations }), $e = rt(I.contributions, n.session), be = Xe({ router: s, access: n.access, noAccess: e.noAccess ?? et }), Ee = pe({
311
+ name: "ApplicationRoot",
312
+ setup() {
313
+ return () => {
314
+ const t = N.value;
315
+ return t.status === "failed" ? se(ut, { kind: t.kind, onRetry: () => void D() }) : t.status !== "ready" ? null : se(v?.component ?? Ye);
316
+ };
317
+ }
318
+ }), d = Oe(Ee);
319
+ Qe(d, n), d.use(h), De(d, k), T = Je(d), Ve(d), Te(d), e.icons && Be(d, ...Array.isArray(e.icons) ? e.icons : [e.icons]), d.provide(ie, C), e.describeError && d.provide(ce, e.describeError), e.describeFieldError && d.provide(le, e.describeFieldError), d.provide(ae, ye), d.provide(ne, $e), d.provide(re, be);
320
+ for (const t of l) for (const { key: a, value: p } of t.contexts) d.provide(a, p);
321
+ let S = !1, J = !1, z = !1, Q = !1;
322
+ const K = [];
323
+ function ke() {
324
+ const t = d.config.errorHandler;
325
+ d.config.errorHandler = ($, Re, Y) => {
326
+ R({ source: "vue", error: $, detail: Y }), t?.($, Re, Y);
327
+ };
328
+ const a = ($) => R({ source: "unhandledrejection", error: $.reason }), p = ($) => {
329
+ $.error && R({ source: "window", error: $.error });
330
+ };
331
+ window.addEventListener("unhandledrejection", a), window.addEventListener("error", p), K.push(() => {
332
+ window.removeEventListener("unhandledrejection", a), window.removeEventListener("error", p);
333
+ });
334
+ const g = l.some(($) => $.holdsExpiredSession);
335
+ n.session.holdExpired(g), K.push(() => n.session.holdExpired(!1)), K.push(
336
+ tt({
337
+ router: s,
338
+ session: n.session,
339
+ login: c,
340
+ home: f,
341
+ holdExpired: g,
342
+ prepare: ve,
343
+ afterNavigation: q,
344
+ progress: e.router?.progress ?? v?.progress,
345
+ onError: ($) => R({ source: "router", error: $ })
346
+ })
347
+ );
348
+ const O = P();
349
+ O.run(() => W(() => T?.documentTitle.value, () => q(s.currentRoute.value))), K.push(() => O.stop());
350
+ const X = P();
351
+ X.run(
352
+ () => W(
353
+ () => u.locale.value,
354
+ ($) => {
355
+ document.documentElement.lang = $, q(s.currentRoute.value);
356
+ },
357
+ { immediate: !0 }
358
+ )
359
+ ), K.push(() => X.stop());
360
+ }
361
+ const F = (t, a) => {
362
+ N.value = { status: "failed", kind: t, error: a };
363
+ };
364
+ async function U() {
365
+ N.value = { status: "starting" };
366
+ const t = await n.session.restore();
367
+ if (S) return;
368
+ if (t.status === "failed") return F("session", t.error);
369
+ const a = t.status === "authenticated" ? t.user.locale : void 0;
370
+ if (typeof a == "string" && a !== u.locale.value && r.includes(a) && await C.setLocale(a), S) return;
371
+ const p = await L.loadEssential();
372
+ if (!S) {
373
+ if (p.length > 0) return F("messages", p[0].error);
374
+ try {
375
+ const g = await s.replace(s.options.history.location);
376
+ if (S) return;
377
+ if (Ie(g)) return F("startup", g);
378
+ } catch (g) {
379
+ S || F("startup", g);
380
+ return;
381
+ }
382
+ Q || (d.use(s), Q = !0), N.value = { status: "ready" }, V.start();
383
+ }
384
+ }
385
+ async function D() {
386
+ S || N.value.status !== "failed" || (await L.retry(), await U());
387
+ }
388
+ return {
389
+ app: d,
390
+ router: s,
391
+ i18n: h,
392
+ state: N,
393
+ locale: C.locale,
394
+ setLocale: C.setLocale,
395
+ async mount(t) {
396
+ if (S) throw new Error("This application was disposed; create a new one with createApplication().");
397
+ if (J) throw new Error("This application is already mounted.");
398
+ J = !0, ke(), await U(), !S && (d.mount(t), z = !0);
399
+ },
400
+ retry: D,
401
+ dispose() {
402
+ if (!S) {
403
+ S = !0, V.dispose(), L.dispose(), z && d.unmount();
404
+ for (const t of K.reverse()) t();
405
+ s.options.history.destroy();
406
+ }
407
+ }
408
+ };
409
+ }
410
+ function mt(e) {
411
+ console.error(`[vue-core] ${e.source}${e.feature ? ` (${e.feature})` : ""}${e.detail ? `: ${e.detail}` : ""}`, e.error);
412
+ }
413
+ function ht(e, n) {
414
+ return [e, n].filter((r) => !!r).join(" · ");
415
+ }
416
+ export {
417
+ ue as A,
418
+ Tt as c,
419
+ mt as d
420
+ };
@@ -1,4 +1,4 @@
1
- import { _ as a, m as o, s as r, u, a as e } from "../Button.vue_vue_type_script_setup_true_lang-CL9Qh5yq.js";
1
+ import { _ as a, m as o, s as r, u, a as e } from "../Button.vue_vue_type_script_setup_true_lang-DQq_0P0p.js";
2
2
  export {
3
3
  a as Button,
4
4
  o as matchesShortcut,
@@ -52,7 +52,14 @@ export interface HttpClient {
52
52
  put<TData = unknown, TMeta = unknown>(path: string, body?: unknown, options?: RequestOptions): Promise<ApiResult<TData, TMeta>>;
53
53
  patch<TData = unknown, TMeta = unknown>(path: string, body?: unknown, options?: RequestOptions): Promise<ApiResult<TData, TMeta>>;
54
54
  delete<TData = unknown, TMeta = unknown>(path: string, options?: RequestOptions): Promise<ApiResult<TData, TMeta>>;
55
+ /**
56
+ * The `X-Request-ID`s of the last requests this client got an answer to or failed to reach (the server's id, else the one sent),
57
+ * oldest first, at most `RECENT_REQUEST_IDS`: what a bug report quotes so the server's log can be found. A cancelled request leaves none.
58
+ */
59
+ recentRequestIds(): readonly string[];
55
60
  }
61
+ /** How many request ids `recentRequestIds` keeps. */
62
+ export declare const RECENT_REQUEST_IDS = 20;
56
63
  /** A client over a transport. Nothing is global: every call of this factory is independent. */
57
64
  export declare function createHttpClient(options?: HttpClientOptions): HttpClient;
58
65
  export {};
@@ -1,4 +1,4 @@
1
- export { createHttpClient } from "./client";
1
+ export { createHttpClient, RECENT_REQUEST_IDS } from "./client";
2
2
  export type { HttpClient, RouteResult, HttpClientOptions, RequestOptions, UnauthorizedContext, UnauthorizedDecision } from "./client";
3
3
  export type { QueryValue } from "./encode";
4
4
  export { REQUEST_ID_HEADER } from "./envelope";
@@ -1,4 +1,4 @@
1
- import { R as p, c as o, f as u } from "../client-BHPFfBj3.js";
1
+ import { R as p, a as o, c as u, f as E } from "../client-CZgikXPG.js";
2
2
  import { A as n, a as f, i as l } from "../error-Bb_dr_Ay.js";
3
3
  function s(e, i, r = {}) {
4
4
  return { method: e, path: i, permission: r.permission, public: r.public === !0, raw: !1 };
@@ -12,9 +12,10 @@ s.raw = (e, i, r = {}) => ({
12
12
  });
13
13
  export {
14
14
  n as ApiError,
15
- p as REQUEST_ID_HEADER,
16
- o as createHttpClient,
17
- u as fetchTransport,
15
+ p as RECENT_REQUEST_IDS,
16
+ o as REQUEST_ID_HEADER,
17
+ u as createHttpClient,
18
+ E as fetchTransport,
18
19
  f as isAborted,
19
20
  l as isApiError,
20
21
  s as route
@@ -0,0 +1,151 @@
1
+ import { A as T, k as D, i as j } from "./error-Bb_dr_Ay.js";
2
+ function z(t) {
3
+ if (!t) return "";
4
+ const e = new URLSearchParams();
5
+ for (const [s, r] of Object.entries(t))
6
+ if (!(r == null || r === ""))
7
+ if (Array.isArray(r)) for (const o of r) e.append(s, String(o));
8
+ else e.append(s, String(r));
9
+ return e.toString();
10
+ }
11
+ const b = (t) => typeof Blob < "u" && t instanceof Blob;
12
+ function v(t) {
13
+ const e = new FormData();
14
+ for (const [s, r] of Object.entries(t))
15
+ if (r != null)
16
+ if (Array.isArray(r))
17
+ for (const o of r) e.append(`${s}[]`, R(o));
18
+ else
19
+ e.append(s, R(r));
20
+ return e;
21
+ }
22
+ function R(t) {
23
+ return b(t) ? t : t instanceof Date ? t.toISOString() : typeof t == "object" && t !== null ? JSON.stringify(t) : String(t);
24
+ }
25
+ function B(t) {
26
+ if (t === void 0) return { body: void 0, contentType: null };
27
+ if (typeof t == "string" || t instanceof FormData || t instanceof URLSearchParams || t instanceof ArrayBuffer || ArrayBuffer.isView(t) || b(t))
28
+ return { body: t, contentType: null };
29
+ if (typeof t == "object" && t !== null && !Array.isArray(t)) {
30
+ const e = t;
31
+ if (Object.values(e).some((s) => b(s) || Array.isArray(s) && s.some(b)))
32
+ return { body: v(e), contentType: null };
33
+ }
34
+ return { body: JSON.stringify(t), contentType: "application/json" };
35
+ }
36
+ function O() {
37
+ const t = new Uint8Array(16);
38
+ return globalThis.crypto.getRandomValues(t), Array.from(t, (e) => e.toString(16).padStart(2, "0")).join("");
39
+ }
40
+ const E = "X-Request-ID", S = (t) => typeof t == "object" && t !== null && !Array.isArray(t), A = (t) => typeof t == "string" && t !== "" ? t : null;
41
+ function _(t) {
42
+ const e = t?.errors ?? t?.fields;
43
+ if (!S(e)) return {};
44
+ const s = {};
45
+ for (const [r, o] of Object.entries(e))
46
+ Array.isArray(o) ? s[r] = o.map(String) : o != null && (s[r] = [String(o)]);
47
+ return s;
48
+ }
49
+ async function C(t) {
50
+ const e = await t.text();
51
+ if (e.trim() === "") return { payload: null, readable: !0 };
52
+ try {
53
+ return { payload: JSON.parse(e), readable: !0 };
54
+ } catch {
55
+ return { payload: null, readable: !1 };
56
+ }
57
+ }
58
+ async function F(t, e) {
59
+ const s = t.headers.get(E) ?? e, { payload: r, readable: o } = await C(t), i = S(r) ? r : null;
60
+ if (!t.ok) {
61
+ const p = _(i), l = i?.params;
62
+ throw new T({
63
+ kind: D(t.status, Object.keys(p).length > 0),
64
+ message: A(i?.error) ?? A(i?.message) ?? `Request failed with status ${t.status}`,
65
+ status: t.status,
66
+ fields: p,
67
+ code: A(i?.code),
68
+ params: S(l) ? l : null,
69
+ requestId: s,
70
+ payload: r
71
+ });
72
+ }
73
+ if (!o)
74
+ throw new T({
75
+ kind: "malformed",
76
+ message: `The server answered ${t.status} with a body that is not JSON`,
77
+ status: t.status,
78
+ requestId: s
79
+ });
80
+ return i !== null && typeof i.success == "boolean" ? {
81
+ data: i.data ?? null,
82
+ meta: i.meta ?? null,
83
+ message: A(i.message),
84
+ status: t.status,
85
+ requestId: s
86
+ } : { data: r, meta: null, message: null, status: t.status, requestId: s };
87
+ }
88
+ const H = (t, e) => globalThis.fetch(t, e), N = 20, P = (t) => /^[a-z][a-z0-9+.-]*:\/\//i.test(t);
89
+ function x(t, e, s) {
90
+ const r = P(e) || t === "" ? e : `${t.replace(/\/+$/, "")}/${e.replace(/^\/+/, "")}`;
91
+ return s === "" ? r : `${r}${r.includes("?") ? "&" : "?"}${s}`;
92
+ }
93
+ const I = (t, e) => new T({ kind: "aborted", message: "The request was cancelled", requestId: t, cause: e });
94
+ function L(t = {}) {
95
+ const { baseUrl: e = "", transport: s = H, credentials: r = "include" } = t, o = [], i = (n) => {
96
+ n !== null && (o.push(n), o.length > N && o.shift());
97
+ };
98
+ async function p(n, a, c, f) {
99
+ const { signal: d } = f, y = t.requestId === !1 ? null : (t.requestId ?? O)();
100
+ if (d?.aborted) throw I(y, d.reason);
101
+ const g = B(c), h = new Headers({ Accept: "application/json" }), m = t.headers ? await t.headers() : void 0;
102
+ for (const u of [m, f.headers])
103
+ u && new Headers(u).forEach((w, U) => h.set(U, w));
104
+ y !== null && !h.has(E) && h.set(E, y), g.contentType !== null && !h.has("Content-Type") && h.set("Content-Type", g.contentType);
105
+ const q = { method: n, headers: h, credentials: r, body: g.body, signal: d }, $ = x(e, a, z(f.query));
106
+ try {
107
+ const u = await s($, q), w = await F(u, y);
108
+ return i(w.requestId), w;
109
+ } catch (u) {
110
+ throw j(u) ? (i(u.requestId), u) : d?.aborted || u instanceof Error && u.name === "AbortError" ? I(y, u) : (i(y), new T({
111
+ kind: "network",
112
+ message: u instanceof Error ? u.message : "The server could not be reached",
113
+ requestId: y,
114
+ cause: u
115
+ }));
116
+ }
117
+ }
118
+ async function l(n, a, c, f = {}) {
119
+ try {
120
+ return await p(n, a, c, f);
121
+ } catch (d) {
122
+ if (!j(d) || d.kind !== "unauthorized" || f.handleUnauthorized === !1 || !t.onUnauthorized || await t.onUnauthorized({ error: d, method: n, path: a }) !== "retry") throw d;
123
+ return p(n, a, c, f);
124
+ }
125
+ }
126
+ async function k(n, a, c = {}) {
127
+ const f = typeof a == "object" && a !== null && !Array.isArray(a) ? { ...a } : {}, d = n.path.replace(/:([A-Za-z_][A-Za-z0-9_]*)/g, (g, h) => {
128
+ const m = f[h];
129
+ if (m == null || m === "")
130
+ throw new Error(`${n.method} ${n.path}: the input has no value for the path parameter "${h}"`);
131
+ return delete f[h], encodeURIComponent(String(m));
132
+ }), y = Object.keys(f).length > 0;
133
+ return n.method === "GET" || n.method === "DELETE" ? l(n.method, d, void 0, { ...c, query: { ...f, ...c.query } }) : l(n.method, d, y ? f : void 0, c);
134
+ }
135
+ return {
136
+ // the rest-tuple overload is the public contract; the implementation takes its arguments positionally
137
+ request: k,
138
+ get: (n, a) => l("GET", n, void 0, a),
139
+ post: (n, a, c) => l("POST", n, a, c),
140
+ put: (n, a, c) => l("PUT", n, a, c),
141
+ patch: (n, a, c) => l("PATCH", n, a, c),
142
+ delete: (n, a) => l("DELETE", n, void 0, a),
143
+ recentRequestIds: () => [...o]
144
+ };
145
+ }
146
+ export {
147
+ N as R,
148
+ E as a,
149
+ L as c,
150
+ H as f
151
+ };