@wssto2/vue-core 0.13.1 → 0.14.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 (63) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/dist/{Activity-ChfxdvXf.js → Activity-C0HUEDUz.js} +3 -3
  3. package/dist/{AdaptivePageShell.vue_vue_type_script_setup_true_lang-lPj9hPqV.js → AdaptivePageShell.vue_vue_type_script_setup_true_lang-Bsv5j5Z8.js} +1 -1
  4. package/dist/{Changes-BCa43_mO.js → Changes-CSaHgVuz.js} +1 -1
  5. package/dist/{CollectionPage.vue_vue_type_script_setup_true_lang-C1GCvyZx.js → CollectionPage.vue_vue_type_script_setup_true_lang-dIrdS_Gn.js} +4 -4
  6. package/dist/{DataTable.vue_vue_type_script_setup_true_lang-B9r9M5Gt.js → DataTable.vue_vue_type_script_setup_true_lang-J3PhyJAS.js} +1 -1
  7. package/dist/{DateField.vue_vue_type_script_setup_true_lang-B5UUY1OO.js → DateField.vue_vue_type_script_setup_true_lang-CKKG4JEg.js} +2 -2
  8. package/dist/{DeadLetters-wFTqhISU.js → DeadLetters-CHX4Ypgy.js} +3 -3
  9. package/dist/{General-jW7u4MjH.js → General-v_24-zZw.js} +3 -3
  10. package/dist/IncidentRecord-BwSBNE37.js +522 -0
  11. package/dist/{IncidentsList-yu0xSMrH.js → IncidentsList-BqzRU5cZ.js} +5 -5
  12. package/dist/{NewRolePage-CQ5UVaHs.js → NewRolePage-Dt0O0VSI.js} +1 -1
  13. package/dist/{NumberField.vue_vue_type_script_setup_true_lang-YVgf5CP6.js → NumberField.vue_vue_type_script_setup_true_lang-U-_kcnGr.js} +1 -1
  14. package/dist/{ProfilePage-Ca3x3UAH.js → ProfilePage-DApTxq8C.js} +4 -4
  15. package/dist/{RecordHeader.vue_vue_type_script_setup_true_lang-Do_ATJwT.js → RecordHeader.vue_vue_type_script_setup_true_lang-SDgLjwEI.js} +1 -1
  16. package/dist/{ResourcePage.vue_vue_type_script_setup_true_lang-Coz91xht.js → ResourcePage.vue_vue_type_script_setup_true_lang-DRC3h71-.js} +1 -1
  17. package/dist/{RolePage-BUj1w1m1.js → RolePage-noy-wmNc.js} +2 -2
  18. package/dist/{RolesPage-NKzBUsrM.js → RolesPage-NRRainCw.js} +1 -1
  19. package/dist/{SectionNavigator.vue_vue_type_script_setup_true_lang-DfKEhTFv.js → SectionNavigator.vue_vue_type_script_setup_true_lang-D_08MS1-.js} +1 -1
  20. package/dist/{ServiceAccountDialog.vue_vue_type_script_setup_true_lang-4nbhEpv_.js → ServiceAccountDialog.vue_vue_type_script_setup_true_lang-DDcaju7L.js} +2 -2
  21. package/dist/{ServiceAccountRecord-ClbyeLhL.js → ServiceAccountRecord-D_HduQoK.js} +6 -6
  22. package/dist/{ServiceAccountsList-B2VDnYxD.js → ServiceAccountsList-CdSsqTGt.js} +4 -4
  23. package/dist/{Sessions-BjkciyHH.js → Sessions-CTjzMfNg.js} +1 -1
  24. package/dist/{SettingsPage-Csb14qsx.js → SettingsPage-CpqASf_D.js} +6 -6
  25. package/dist/{SignIn-DPFMv4C7.js → SignIn-D6tWsKf0.js} +2 -2
  26. package/dist/{SignInPage-DukoFqkt.js → SignInPage-BCNGI871.js} +1 -1
  27. package/dist/{SignIns-DvdpNkiS.js → SignIns-BxGGA99u.js} +1 -1
  28. package/dist/{TimeField.vue_vue_type_script_setup_true_lang-DpDXHH7u.js → TimeField.vue_vue_type_script_setup_true_lang-BDlTAMsh.js} +2 -2
  29. package/dist/{Timestamp.vue_vue_type_script_setup_true_lang-DlEUKWra.js → Timestamp.vue_vue_type_script_setup_true_lang-jCXYFLtq.js} +1 -1
  30. package/dist/{UserRecord-B9SeSWQh.js → UserRecord-B0kG0-Tm.js} +4 -4
  31. package/dist/{UsersList-CREG8q3l.js → UsersList-KMgImERy.js} +3 -3
  32. package/dist/access/index.js +3 -3
  33. package/dist/app/index.js +1 -1
  34. package/dist/{application-DomS6sbx.js → application-CrXtiGdw.js} +1 -1
  35. package/dist/collection/index.js +3 -3
  36. package/dist/content/index.js +2 -2
  37. package/dist/form/index.js +8 -8
  38. package/dist/format/format.d.ts +5 -2
  39. package/dist/format/index.js +1 -1
  40. package/dist/format-Cp1h0vsC.js +125 -0
  41. package/dist/i18n/index.js +13 -13
  42. package/dist/identity/index.js +1 -1
  43. package/dist/incidents/Occurrences.vue.d.ts +9 -0
  44. package/dist/incidents/api.d.ts +11 -2
  45. package/dist/incidents/index.js +1 -1
  46. package/dist/{index-Be9Q1PB_.js → index-Crz-j_Hu.js} +112 -106
  47. package/dist/{index-DZikGJ8L.js → index-D-2NNye6.js} +15 -15
  48. package/dist/{index-D_yyd4C2.js → index-DNeIZpXo.js} +3 -3
  49. package/dist/index.d.ts +1 -1
  50. package/dist/index.js +1 -1
  51. package/dist/modules/incident/entities.d.ts +19 -0
  52. package/dist/modules/incident/routes.d.ts +4 -1
  53. package/dist/notifications/index.js +1 -1
  54. package/dist/page/index.js +3 -3
  55. package/dist/phone/index.js +1 -1
  56. package/dist/resource/index.js +1 -1
  57. package/dist/{rowLayout-y1IB_h2r.js → rowLayout-Ohh5ng1u.js} +2 -2
  58. package/dist/{serverMessages-Ddghrewh.js → serverMessages-DnTqVS3h.js} +1 -1
  59. package/dist/testing/index.js +2 -2
  60. package/dist/{useTypedEntry-DKs8I1yP.js → useTypedEntry-tttjrClq.js} +1 -1
  61. package/package.json +2 -2
  62. package/dist/IncidentRecord-zTemLz2R.js +0 -404
  63. package/dist/format-DoKs29bZ.js +0 -118
@@ -1,5 +1,5 @@
1
1
  import { i as a } from "../preferences-hYhrw8Uy.js";
2
- import { k as o, r as n, t as i, P as r, j as u, h as c, _ as d, q as S, i as g, U as A, v as f, w as l, x as p, y as m, z as I, A as R, o as x, B as y, C as P, n as U, s as v, e as D, g as E, b, f as w, D as F, E as B, c as C } from "../index-DZikGJ8L.js";
2
+ import { k as o, r as n, t as i, P as r, j as u, h as c, _ as d, q as S, i as g, U as A, v as f, w as l, x as p, y as m, z as I, A as R, o as x, B as y, C as P, n as U, s as v, e as D, g as E, b, f as w, D as F, E as B, c as C } from "../index-D-2NNye6.js";
3
3
  import { a as T, _ } from "../ActionRow.vue_vue_type_script_setup_true_lang-DybAIOHS.js";
4
4
  import { i as k, l as N, r as O, s as j, a as q, u as z } from "../usePreferences-B8LIZp_f.js";
5
5
  import { s as K } from "../routes-Beyr5NQo.js";
@@ -0,0 +1,9 @@
1
+ /**
2
+ * An incident's occurrences (staff only: the caller shows it for `incident:manage`), newest first, a page at a time. Each opens to its stack
3
+ * and the context and request the server kept (read-only JSON).
4
+ */
5
+ type __VLS_Props = {
6
+ incidentId: number;
7
+ };
8
+ declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
9
+ export default _default;
@@ -1,5 +1,5 @@
1
- import type { HttpClient } from "../client";
2
- import type { CommentResponse, Incident, ReportResponse } from "../modules/incident/entities";
1
+ import type { HttpClient, PageMeta } from "../client";
2
+ import type { CommentResponse, Incident, OccurrenceResponse, ReportResponse } from "../modules/incident/entities";
3
3
  import type { CommentRequest, ReportInput, UpdateRequest } from "../modules/incident/schemas";
4
4
  export type IncidentSort = "title" | "last_seen_at";
5
5
  export type IncidentFilter = "created_at" | "status" | "severity" | "source";
@@ -11,11 +11,20 @@ export interface IncidentDetail {
11
11
  readonly reports: readonly ReportResponse[];
12
12
  readonly comments: readonly CommentResponse[];
13
13
  }
14
+ /** The occurrences a page of the incident page shows. */
15
+ export declare const OCCURRENCES_PER_PAGE = 10;
14
16
  /** go-core's incident routes as calls; `data` of each answer already read. A change takes the `Idempotency-Key` of its attempt. */
15
17
  export declare function createIncidentsApi(http: HttpClient): {
16
18
  show: (id: number, options?: {
17
19
  readonly signal?: AbortSignal;
18
20
  }) => Promise<IncidentDetail>;
21
+ /** One page of an incident's occurrences, newest first (`incident:manage`). */
22
+ occurrences: (id: number, page: number, options?: {
23
+ readonly signal?: AbortSignal;
24
+ }) => Promise<{
25
+ readonly rows: readonly OccurrenceResponse[];
26
+ readonly meta: PageMeta | null;
27
+ }>;
19
28
  /** The whole management form; the answer is the stored incident (without its people: the page reads again for them). */
20
29
  update: (id: number, input: UpdateRequest, idempotencyKey: string) => Promise<Incident>;
21
30
  /** A report: the incident it opened or joined. */
@@ -1,4 +1,4 @@
1
- import { h as t, j as i, k as r, l as n, i as a } from "../index-Be9Q1PB_.js";
1
+ import { h as t, j as i, k as r, l as n, i as a } from "../index-Crz-j_Hu.js";
2
2
  export {
3
3
  t as MAX_REPORTS_PER_SESSION,
4
4
  i as clientErrorReporter,
@@ -1,56 +1,62 @@
1
- import { r as p } from "./route-goWMxDUN.js";
2
- import { d as V, p as L } from "./feature-DdUAfyi4.js";
3
- import { defineComponent as A, computed as O, onMounted as U, watch as X, openBlock as S, createBlock as y, unref as e, withCtx as I, createElementVNode as B, createVNode as c, mergeProps as l, createCommentVNode as R, ref as F } from "vue";
4
- import { d as j } from "./context-Ch1r4fdN.js";
5
- import { useI18n as P } from "vue-i18n";
1
+ import { r as _ } from "./route-goWMxDUN.js";
2
+ import { d as V, p as U } from "./feature-DdUAfyi4.js";
3
+ import { defineComponent as A, computed as O, onMounted as L, watch as X, openBlock as S, createBlock as I, unref as e, withCtx as y, createElementVNode as B, createVNode as c, mergeProps as l, createCommentVNode as R, ref as G } from "vue";
4
+ import { d as F } from "./context-Ch1r4fdN.js";
5
+ import { useI18n as M } from "vue-i18n";
6
6
  import { a as N } from "./FormGroup.vue_vue_type_script_setup_true_lang-D6jYfNjW.js";
7
- import { _ as G } from "./SelectField.vue_vue_type_script_setup_true_lang-BZwdANL3.js";
7
+ import { _ as j } from "./SelectField.vue_vue_type_script_setup_true_lang-BZwdANL3.js";
8
8
  import { _ as b } from "./TextareaField.vue_vue_type_script_setup_true_lang-D2j4s96s.js";
9
- import { _ as x } from "./TextField.vue_vue_type_script_setup_true_lang-CWIeeZRE.js";
9
+ import { _ as w } from "./TextField.vue_vue_type_script_setup_true_lang-CWIeeZRE.js";
10
10
  import { u as K, _ as z } from "./useCommand-Ch_nx1AQ.js";
11
11
  import { t as H } from "./toast-CqSDTWRX.js";
12
- import { u as k } from "./platform-DtISOEt7.js";
12
+ import { u as C } from "./platform-DtISOEt7.js";
13
13
  import { d as Q, r as W, a as Y } from "./http-DOEfFCDA.js";
14
14
  import { _ as J } from "./AccountMenuItem.vue_vue_type_script_setup_true_lang-BIYgaihv.js";
15
15
  import { d as Z } from "./defineRoutes-BGAdiIrt.js";
16
- import { d as ee } from "./application-DomS6sbx.js";
16
+ import { d as ee } from "./application-CrXtiGdw.js";
17
17
  import { R as te } from "./client-Dg303Pmc.js";
18
18
  import { a as ne } from "./error-CD7x0Jrz.js";
19
- const v = {
20
- index: p("GET", "/v1/incidents", { permission: "incident:view" }),
21
- show: p("GET", "/v1/incidents/:incidentID", { permission: "incident:view" }),
22
- comments: p("GET", "/v1/incidents/:incidentID/comments", { permission: "incident:view" }),
23
- report: p("POST", "/v1/incidents/reports", { permission: "incident:create" }),
24
- comment: p("POST", "/v1/incidents/:incidentID/comments", { permission: "incident:create" }),
25
- update: p("PATCH", "/v1/incidents/:incidentID", { permission: "incident:update" }),
26
- clientError: p("POST", "/v1/incidents/client-errors")
27
- }, [ie, C] = j("vue-core.incidents"), M = "incident:view", se = "incident:create", je = "incident:update", re = "incident:manage";
28
- function Ge(t) {
19
+ const g = {
20
+ index: _("GET", "/v1/incidents", { permission: "incident:view" }),
21
+ show: _("GET", "/v1/incidents/:incidentID", { permission: "incident:view" }),
22
+ comments: _("GET", "/v1/incidents/:incidentID/comments", { permission: "incident:view" }),
23
+ occurrences: _("GET", "/v1/incidents/:incidentID/occurrences", { permission: "incident:manage" }),
24
+ report: _("POST", "/v1/incidents/reports", { permission: "incident:create" }),
25
+ comment: _("POST", "/v1/incidents/:incidentID/comments", { permission: "incident:create" }),
26
+ update: _("PATCH", "/v1/incidents/:incidentID", { permission: "incident:update" }),
27
+ clientError: _("POST", "/v1/incidents/client-errors")
28
+ }, [ie, D] = F("vue-core.incidents"), P = "incident:view", se = "incident:create", je = "incident:update", re = "incident:manage";
29
+ function Ke(t) {
29
30
  return Q({
30
31
  id: "incidents",
31
32
  stateVersion: 1,
32
- load: async (n, { signal: s }) => W(await t.request(v.index, Y(n), { signal: s }), n),
33
+ load: async (n, { signal: s }) => W(await t.request(g.index, Y(n), { signal: s }), n),
33
34
  key: (n) => n.id,
34
35
  query: { sorts: ["title", "last_seen_at"], filters: ["created_at", "status", "severity", "source"] },
35
36
  defaults: { sort: "last_seen_at", direction: "desc" }
36
37
  });
37
38
  }
38
- const T = (t) => ({ headers: { "Idempotency-Key": t } });
39
- function oe(t) {
39
+ const oe = 10, T = (t) => ({ headers: { "Idempotency-Key": t } });
40
+ function ae(t) {
40
41
  return {
41
42
  show: async (n, s) => {
42
- const { data: r, meta: o } = await t.request(v.show, { incidentID: n }, s);
43
+ const { data: r, meta: o } = await t.request(g.show, { incidentID: n }, s);
43
44
  return { incident: r, reports: o?.reports ?? [], comments: o?.comments ?? [] };
44
45
  },
46
+ /** One page of an incident's occurrences, newest first (`incident:manage`). */
47
+ occurrences: async (n, s, r) => {
48
+ const { data: o, meta: i } = await t.request(g.occurrences, { incidentID: n, page: s, per_page: oe }, r);
49
+ return { rows: o, meta: i };
50
+ },
45
51
  /** The whole management form; the answer is the stored incident (without its people: the page reads again for them). */
46
- update: async (n, s, r) => (await t.request(v.update, { ...s, incidentID: n }, T(r))).data,
52
+ update: async (n, s, r) => (await t.request(g.update, { ...s, incidentID: n }, T(r))).data,
47
53
  /** A report: the incident it opened or joined. */
48
- report: async (n, s) => (await t.request(v.report, n, T(s))).data.data,
49
- comment: async (n, s, r) => (await t.request(v.comment, { ...s, incidentID: n }, T(r))).data
54
+ report: async (n, s) => (await t.request(g.report, n, T(s))).data.data,
55
+ comment: async (n, s, r) => (await t.request(g.comment, { ...s, incidentID: n }, T(r))).data
50
56
  };
51
57
  }
52
- const ae = () => oe(k().http);
53
- function ce(t, n) {
58
+ const ce = () => ae(C().http);
59
+ function de(t, n) {
54
60
  return {
55
61
  safeParse(s) {
56
62
  const r = s, o = t.filter((i) => String(r[i] ?? "").trim() === "").map((i) => ({ path: [i], message: n }));
@@ -58,7 +64,7 @@ function ce(t, n) {
58
64
  }
59
65
  };
60
66
  }
61
- function de(t) {
67
+ function le(t) {
62
68
  return {
63
69
  title: "",
64
70
  description: "",
@@ -76,8 +82,8 @@ function de(t) {
76
82
  extra_json: ""
77
83
  };
78
84
  }
79
- const Ke = () => ({ body: "", visibility: "public" });
80
- function ze() {
85
+ const ze = () => ({ body: "", visibility: "public" });
86
+ function He() {
81
87
  return {
82
88
  status: "",
83
89
  severity: "",
@@ -90,7 +96,7 @@ function ze() {
90
96
  external_ticket_url: ""
91
97
  };
92
98
  }
93
- function He({ incident: t }) {
99
+ function Qe({ incident: t }) {
94
100
  return {
95
101
  status: t.status,
96
102
  severity: t.severity,
@@ -103,69 +109,69 @@ function He({ incident: t }) {
103
109
  external_ticket_url: t.external_ticket_url ?? ""
104
110
  };
105
111
  }
106
- const Qe = {
112
+ const We = {
107
113
  new: "core.incidents.statuses.new",
108
114
  triaged: "core.incidents.statuses.triaged",
109
115
  in_progress: "core.incidents.statuses.in_progress",
110
116
  resolved: "core.incidents.statuses.resolved",
111
117
  ignored: "core.incidents.statuses.ignored",
112
118
  duplicate: "core.incidents.statuses.duplicate"
113
- }, le = {
119
+ }, ue = {
114
120
  low: "core.incidents.severities.low",
115
121
  medium: "core.incidents.severities.medium",
116
122
  high: "core.incidents.severities.high",
117
123
  critical: "core.incidents.severities.critical"
118
- }, We = {
124
+ }, Ye = {
119
125
  user_report: "core.incidents.sources.user_report",
120
126
  runtime_error: "core.incidents.sources.runtime_error",
121
127
  client_error: "core.incidents.sources.client_error",
122
128
  mixed: "core.incidents.sources.mixed"
123
- }, Ye = {
129
+ }, Je = {
124
130
  new: "info",
125
131
  triaged: "warning",
126
132
  in_progress: "warning",
127
133
  resolved: "positive",
128
134
  ignored: "neutral",
129
135
  duplicate: "neutral"
130
- }, Je = {
136
+ }, Ze = {
131
137
  low: "neutral",
132
138
  medium: "info",
133
139
  high: "warning",
134
140
  critical: "critical"
135
- }, ue = {
141
+ }, me = {
136
142
  class: "flex flex-col gap-group-gap",
137
143
  "data-test": "incident-report"
138
- }, me = /* @__PURE__ */ A({
144
+ }, _e = /* @__PURE__ */ A({
139
145
  __name: "ReportDialog",
140
146
  props: {
141
147
  autoOpen: { type: Boolean }
142
148
  },
143
149
  emits: ["created", "close"],
144
150
  setup(t, { expose: n, emit: s }) {
145
- const r = t, o = s, { t: i } = P(), { access: d } = k(), u = ae(), { appVersion: h } = C(), E = O(() => d.can(re)), w = O(() => Object.entries(le).map(([m, g]) => ({ value: m, label: i(g) }))), _ = K({
146
- defaults: () => de(h),
147
- validator: ce(["title", "description"], i("core.account.validation.required")),
148
- run: (m, { idempotencyKey: g }) => u.report(m, g),
151
+ const r = t, o = s, { t: i } = M(), { access: d } = C(), u = ce(), { appVersion: E } = D(), h = O(() => d.can(re)), x = O(() => Object.entries(ue).map(([m, v]) => ({ value: m, label: i(v) }))), p = K({
152
+ defaults: () => le(E),
153
+ validator: de(["title", "description"], i("core.account.validation.required")),
154
+ run: (m, { idempotencyKey: v }) => u.report(m, v),
149
155
  done: (m) => {
150
156
  H.success(i("core.incidents.toasts.report_success")), o("created", m);
151
157
  }
152
- }), a = _.form, D = () => _.present(), $ = () => _.dismiss();
153
- return U(() => {
154
- r.autoOpen && D();
155
- }), X(() => _.open.value, (m, g) => {
156
- g && !m && o("close");
157
- }), n({ show: D, hide: $ }), (m, g) => (S(), y(e(z), {
158
- command: e(_),
158
+ }), a = p.form, k = () => p.present(), $ = () => p.dismiss();
159
+ return L(() => {
160
+ r.autoOpen && k();
161
+ }), X(() => p.open.value, (m, v) => {
162
+ v && !m && o("close");
163
+ }), n({ show: k, hide: $ }), (m, v) => (S(), I(e(z), {
164
+ command: e(p),
159
165
  size: "md",
160
166
  title: e(i)("core.incidents.report_modal.title"),
161
167
  subtitle: e(i)("core.incidents.report_modal.description"),
162
168
  "confirm-label": e(i)("core.incidents.report_modal.submit")
163
169
  }, {
164
- default: I(() => [
165
- B("div", ue, [
170
+ default: y(() => [
171
+ B("div", me, [
166
172
  c(e(N), null, {
167
- default: I(() => [
168
- c(e(x), l(e(a).bind("title"), {
173
+ default: y(() => [
174
+ c(e(w), l(e(a).bind("title"), {
169
175
  label: e(i)("core.incidents.fields.title"),
170
176
  required: "",
171
177
  "max-length": 255
@@ -176,23 +182,23 @@ const Qe = {
176
182
  rows: 4,
177
183
  "max-length": 2e4
178
184
  }), null, 16, ["label"]),
179
- c(e(G), l(e(a).bind("severity"), {
185
+ c(e(j), l(e(a).bind("severity"), {
180
186
  label: e(i)("core.incidents.fields.severity"),
181
- options: w.value
187
+ options: x.value
182
188
  }), null, 16, ["label", "options"])
183
189
  ]),
184
190
  _: 1
185
191
  }),
186
- E.value ? (S(), y(e(N), {
192
+ h.value ? (S(), I(e(N), {
187
193
  key: 0,
188
194
  header: e(i)("core.incidents.report_modal.advanced_fields")
189
195
  }, {
190
- default: I(() => [
191
- c(e(x), l(e(a).bind("affected_module"), {
196
+ default: y(() => [
197
+ c(e(w), l(e(a).bind("affected_module"), {
192
198
  label: e(i)("core.incidents.fields.affected_module"),
193
199
  "max-length": 100
194
200
  }), null, 16, ["label"]),
195
- c(e(x), l(e(a).bind("page_url"), {
201
+ c(e(w), l(e(a).bind("page_url"), {
196
202
  label: e(i)("core.incidents.fields.page_url"),
197
203
  "max-length": 1e3
198
204
  }), null, 16, ["label"]),
@@ -211,11 +217,11 @@ const Qe = {
211
217
  rows: 2,
212
218
  "max-length": 2e4
213
219
  }), null, 16, ["label"]),
214
- c(e(x), l(e(a).bind("browser_info"), {
220
+ c(e(w), l(e(a).bind("browser_info"), {
215
221
  label: e(i)("core.incidents.fields.browser_info"),
216
222
  "max-length": 500
217
223
  }), null, 16, ["label"]),
218
- c(e(x), l(e(a).bind("app_version"), {
224
+ c(e(w), l(e(a).bind("app_version"), {
219
225
  label: e(i)("core.incidents.fields.app_version"),
220
226
  "max-length": 100
221
227
  }), null, 16, ["label"]),
@@ -237,23 +243,23 @@ const Qe = {
237
243
  _: 1
238
244
  }, 8, ["command", "title", "subtitle", "confirm-label"]));
239
245
  }
240
- }), _e = /* @__PURE__ */ A({
246
+ }), pe = /* @__PURE__ */ A({
241
247
  __name: "ReportHost",
242
248
  setup(t) {
243
- const { reporting: n } = C(), s = () => {
249
+ const { reporting: n } = D(), s = () => {
244
250
  n.value = !1;
245
251
  };
246
- return (r, o) => e(n) ? (S(), y(me, {
252
+ return (r, o) => e(n) ? (S(), I(_e, {
247
253
  key: 0,
248
254
  "auto-open": "",
249
255
  onClose: s
250
256
  })) : R("", !0);
251
257
  }
252
- }), pe = /* @__PURE__ */ A({
258
+ }), fe = /* @__PURE__ */ A({
253
259
  __name: "ReportMenuItem",
254
260
  setup(t) {
255
- const { t: n } = P(), { access: s } = k(), r = C();
256
- return (o, i) => e(s).can(e(se)) ? (S(), y(J, {
261
+ const { t: n } = M(), { access: s } = C(), r = D();
262
+ return (o, i) => e(s).can(e(se)) ? (S(), I(J, {
257
263
  key: 0,
258
264
  label: e(n)("core.incidents.report_modal.menu"),
259
265
  icon: "alertTriangle",
@@ -262,51 +268,51 @@ const Qe = {
262
268
  }, null, 8, ["label"])) : R("", !0);
263
269
  }
264
270
  }), q = Z({
265
- index: { name: "incidents.index", path: "/incidents", component: () => import("./IncidentsList-yu0xSMrH.js"), meta: { access: M, titleKey: "core.incidents.title" } },
271
+ index: { name: "incidents.index", path: "/incidents", component: () => import("./IncidentsList-BqzRU5cZ.js"), meta: { access: P, titleKey: "core.incidents.title" } },
266
272
  details: {
267
273
  name: "incidents.details",
268
274
  path: "/incidents/:incidentID",
269
- component: () => import("./IncidentRecord-zTemLz2R.js"),
275
+ component: () => import("./IncidentRecord-BwSBNE37.js"),
270
276
  // Previous / next record swaps the id in place.
271
- meta: { access: M, titleKey: "core.incidents.title", remountOnParam: "incidentID" }
277
+ meta: { access: P, titleKey: "core.incidents.title", remountOnParam: "incidentID" }
272
278
  }
273
279
  });
274
- function Ze(t = {}) {
280
+ function et(t = {}) {
275
281
  return V({
276
282
  id: "incidents",
277
283
  routes: q.records,
278
- context: L(ie, { reporting: F(!1), appVersion: t.appVersion ?? "" }),
284
+ context: U(ie, { reporting: G(!1), appVersion: t.appVersion ?? "" }),
279
285
  navigation: t.destination ? [{ destination: t.destination, to: q.index, within: ["incidents.details"] }] : [],
280
286
  contributions: [
281
- { id: "incidents.report-menu", slot: "accountMenu", component: pe, scope: "authenticated", order: 40, optional: !0 },
282
- { id: "incidents.report-host", slot: "host", component: _e, scope: "authenticated", optional: !0 }
287
+ { id: "incidents.report-menu", slot: "accountMenu", component: fe, scope: "authenticated", order: 40, optional: !0 },
288
+ { id: "incidents.report-host", slot: "host", component: pe, scope: "authenticated", optional: !0 }
283
289
  ]
284
290
  });
285
291
  }
286
- const fe = 2e3, ge = 2e4, be = 255, ve = 500, he = 100, Ee = 100, xe = 255, we = 20, Se = /* @__PURE__ */ new Set(["vue", "unhandledrejection", "window", "handled"]), f = (t, n) => t.slice(0, n), ye = (t) => /^script error\.?$/i.test(t.trim()), Ie = (t) => t.split(`
292
+ const ge = 2e3, ve = 2e4, be = 255, Ee = 500, he = 100, we = 100, xe = 255, Se = 20, Ie = /* @__PURE__ */ new Set(["vue", "unhandledrejection", "window", "handled"]), f = (t, n) => t.slice(0, n), ye = (t) => /^script error\.?$/i.test(t.trim()), Te = (t) => t.split(`
287
293
  `).find((n) => /^\s*at\s|@\S/.test(n))?.trim() ?? "";
288
- function et(t) {
294
+ function tt(t) {
289
295
  const { platform: n, appVersion: s = "", onError: r = ee } = t, o = /* @__PURE__ */ new Set();
290
296
  function i(d) {
291
297
  const { error: u } = d;
292
- if (!Se.has(d.source) || !(u instanceof Error) || ne(u) || u.message.trim() === "" || ye(u.message)) return;
293
- const h = t.origin ?? globalThis.location?.origin, E = u.stack ?? "";
294
- if (!h || h === "null" || !E.includes(`${h}/`) || n.session.state.value.status !== "authenticated") return;
295
- const w = `${u.message}
296
- ${Ie(E)}`;
297
- if (o.has(w) || o.size >= we) return;
298
- o.add(w);
299
- const _ = {
300
- message: f(u.message, fe),
298
+ if (!Ie.has(d.source) || !(u instanceof Error) || ne(u) || u.message.trim() === "" || ye(u.message)) return;
299
+ const E = t.origin ?? globalThis.location?.origin, h = u.stack ?? "";
300
+ if (!E || E === "null" || !h.includes(`${E}/`) || n.session.state.value.status !== "authenticated") return;
301
+ const x = `${u.message}
302
+ ${Te(h)}`;
303
+ if (o.has(x) || o.size >= Se) return;
304
+ o.add(x);
305
+ const p = {
306
+ message: f(u.message, ge),
301
307
  source: d.source,
302
308
  ...d.detail && { detail: f(d.detail, xe) },
303
- stack: f(E, ge),
309
+ stack: f(h, ve),
304
310
  route: f((d.route ?? "").split(/[?#]/)[0] ?? "", be),
305
- browser: f(globalThis.navigator?.userAgent ?? "", ve),
311
+ browser: f(globalThis.navigator?.userAgent ?? "", Ee),
306
312
  app_version: f(s, he),
307
- request_ids: n.http.recentRequestIds().slice(-te).map((a) => f(a, Ee))
313
+ request_ids: n.http.recentRequestIds().slice(-te).map((a) => f(a, we))
308
314
  };
309
- n.http.request(v.clientError, _).catch(() => {
315
+ n.http.request(g.clientError, p).catch(() => {
310
316
  });
311
317
  }
312
318
  return (d) => {
@@ -320,22 +326,22 @@ ${Ie(E)}`;
320
326
  export {
321
327
  se as C,
322
328
  re as M,
323
- We as S,
329
+ Ye as S,
324
330
  je as U,
325
- me as _,
326
- Ge as a,
327
- Ye as b,
328
- Qe as c,
329
- Je as d,
330
- le as e,
331
- ze as f,
332
- Ke as g,
333
- we as h,
331
+ _e as _,
332
+ Ke as a,
333
+ Je as b,
334
+ We as c,
335
+ Ze as d,
336
+ ue as e,
337
+ He as f,
338
+ ze as g,
339
+ Se as h,
334
340
  q as i,
335
- et as j,
336
- v as k,
337
- Ze as l,
338
- He as m,
339
- ce as r,
340
- ae as u
341
+ tt as j,
342
+ g as k,
343
+ et as l,
344
+ Qe as m,
345
+ de as r,
346
+ ce as u
341
347
  };
@@ -22,18 +22,18 @@ import { u as Ge } from "./mediaQuery-CygcXmFW.js";
22
22
  import { u as Xe } from "./useDialog-DfNmqM-0.js";
23
23
  import { c as Ye } from "./closeOverlays-CjVsIrpL.js";
24
24
  import { u as He, a as V } from "./FormGroup.vue_vue_type_script_setup_true_lang-D6jYfNjW.js";
25
- import { u as J } from "./format-DoKs29bZ.js";
25
+ import { u as J } from "./format-Cp1h0vsC.js";
26
26
  import { b as Je } from "./routeResource-DlTsGTg_.js";
27
27
  import { _ as F } from "./IconTile.vue_vue_type_script_setup_true_lang-BmxCuUZ9.js";
28
28
  import { g as U } from "./options-B48UiYsG.js";
29
29
  import { u as he, _ as be } from "./useCommand-Ch_nx1AQ.js";
30
- import { u as ye } from "./serverMessages-Ddghrewh.js";
30
+ import { u as ye } from "./serverMessages-DnTqVS3h.js";
31
31
  import { _ as Qe } from "./SelectField.vue_vue_type_script_setup_true_lang-BZwdANL3.js";
32
32
  import { d as Ze, r as et } from "./http-DOEfFCDA.js";
33
33
  import { z as r } from "zod";
34
34
  import "./ActionRow.vue_vue_type_script_setup_true_lang-DybAIOHS.js";
35
35
  import { _ as G } from "./Badge.vue_vue_type_script_setup_true_lang-DJyZc0C7.js";
36
- import { _ as tt } from "./DataTable.vue_vue_type_script_setup_true_lang-B9r9M5Gt.js";
36
+ import { _ as tt } from "./DataTable.vue_vue_type_script_setup_true_lang-J3PhyJAS.js";
37
37
  import { _ as nt } from "./Avatar.vue_vue_type_script_setup_true_lang-BPj_fkJR.js";
38
38
  import { _ as st } from "./AccessGate.vue_vue_type_script_setup_true_lang-DEzXovsY.js";
39
39
  import "./routes-Beyr5NQo.js";
@@ -246,7 +246,7 @@ const ft = ["aria-labelledby"], gt = ["id"], _t = { class: "mt-1 text-subheadlin
246
246
  ]));
247
247
  }
248
248
  }), wt = X({
249
- login: { name: "login", path: "/login", component: () => import("./SignInPage-DukoFqkt.js"), meta: { public: !0, titleKey: "core.identity.signin.title" } }
249
+ login: { name: "login", path: "/login", component: () => import("./SignInPage-BCNGI871.js"), meta: { public: !0, titleKey: "core.identity.signin.title" } }
250
250
  });
251
251
  function Xn(e = {}) {
252
252
  return ne({
@@ -381,7 +381,7 @@ function Hn(e) {
381
381
  };
382
382
  }
383
383
  const ke = X({
384
- index: { name: "profile", path: "/profile", component: () => import("./ProfilePage-Ca3x3UAH.js"), meta: { titleKey: "core.profile.title" } }
384
+ index: { name: "profile", path: "/profile", component: () => import("./ProfilePage-DApTxq8C.js"), meta: { titleKey: "core.profile.title" } }
385
385
  }), At = /* @__PURE__ */ $({
386
386
  __name: "ProfileMenuItem",
387
387
  setup(e) {
@@ -412,19 +412,19 @@ function jt(e, n) {
412
412
  return [...e.flatMap((s) => [s, ...o(s)]), ...n.filter((s) => s.after === void 0).map((s) => ce(s))];
413
413
  }
414
414
  const le = "iam.user:view", ts = "iam.user:manage", Kt = "iam.user.activity:view", Se = X({
415
- index: { name: "users.index", path: "/users", component: () => import("./UsersList-CREG8q3l.js"), meta: { access: le, titleKey: "core.users.title" } },
415
+ index: { name: "users.index", path: "/users", component: () => import("./UsersList-KMgImERy.js"), meta: { access: le, titleKey: "core.users.title" } },
416
416
  record: {
417
417
  name: "users.record",
418
418
  path: "/users/:id",
419
- component: () => import("./UserRecord-B9SeSWQh.js"),
419
+ component: () => import("./UserRecord-B0kG0-Tm.js"),
420
420
  meta: { access: le, titleKey: "core.users.title", remountOnParam: "id" },
421
421
  children: [
422
- { name: "users.record.general", path: "general", component: () => import("./General-jW7u4MjH.js"), meta: { section: { labelKey: "core.users.sections.general", icon: "user3Line", groupKey: "core.users.section_groups.person" } } },
423
- { name: "users.record.signin", path: "signin", component: () => import("./SignIn-DPFMv4C7.js"), meta: { section: { labelKey: "core.users.sections.signin", icon: "key2Line", groupKey: "core.users.section_groups.access" } } },
424
- { name: "users.record.sessions", path: "sessions", component: () => import("./Sessions-BjkciyHH.js"), meta: { section: { labelKey: "core.users.sections.sessions", icon: "deviceLine", groupKey: "core.users.section_groups.access" } } },
425
- { name: "users.record.signins", path: "signins", component: () => import("./SignIns-DvdpNkiS.js"), meta: { section: { labelKey: "core.users.sections.signins", icon: "timeFill", groupKey: "core.users.section_groups.activity" } } },
426
- { name: "users.record.changes", path: "changes", component: () => import("./Changes-BCa43_mO.js"), meta: { section: { labelKey: "core.users.sections.changes", icon: "edit", groupKey: "core.users.section_groups.activity" } } },
427
- { name: "users.record.activity", path: "activity", component: () => import("./Activity-ChfxdvXf.js"), meta: { access: Kt, section: { labelKey: "core.users.sections.activity", icon: "listCheck", groupKey: "core.users.section_groups.activity" } } }
422
+ { name: "users.record.general", path: "general", component: () => import("./General-v_24-zZw.js"), meta: { section: { labelKey: "core.users.sections.general", icon: "user3Line", groupKey: "core.users.section_groups.person" } } },
423
+ { name: "users.record.signin", path: "signin", component: () => import("./SignIn-D6tWsKf0.js"), meta: { section: { labelKey: "core.users.sections.signin", icon: "key2Line", groupKey: "core.users.section_groups.access" } } },
424
+ { name: "users.record.sessions", path: "sessions", component: () => import("./Sessions-CTjzMfNg.js"), meta: { section: { labelKey: "core.users.sections.sessions", icon: "deviceLine", groupKey: "core.users.section_groups.access" } } },
425
+ { name: "users.record.signins", path: "signins", component: () => import("./SignIns-BxGGA99u.js"), meta: { section: { labelKey: "core.users.sections.signins", icon: "timeFill", groupKey: "core.users.section_groups.activity" } } },
426
+ { name: "users.record.changes", path: "changes", component: () => import("./Changes-CSaHgVuz.js"), meta: { section: { labelKey: "core.users.sections.changes", icon: "edit", groupKey: "core.users.section_groups.activity" } } },
427
+ { name: "users.record.activity", path: "activity", component: () => import("./Activity-C0HUEDUz.js"), meta: { access: Kt, section: { labelKey: "core.users.sections.activity", icon: "listCheck", groupKey: "core.users.section_groups.activity" } } }
428
428
  ]
429
429
  }
430
430
  });
@@ -1153,11 +1153,11 @@ const Jt = ["title"], Qt = { class: "font-mono" }, cs = /* @__PURE__ */ $({
1153
1153
  }, 8, ["permission"])) : k("", !0);
1154
1154
  }
1155
1155
  }), [cn, ms] = N("vue-core.serviceaccounts"), ue = "iam.serviceaccount:view", ps = "iam.serviceaccount:manage", fs = "iam.serviceaccount:revoke", de = X({
1156
- index: { name: "serviceaccounts.index", path: "/iam/service-accounts", component: () => import("./ServiceAccountsList-B2VDnYxD.js"), meta: { access: ue, titleKey: "core.serviceaccounts.title_plural" } },
1156
+ index: { name: "serviceaccounts.index", path: "/iam/service-accounts", component: () => import("./ServiceAccountsList-CdSsqTGt.js"), meta: { access: ue, titleKey: "core.serviceaccounts.title_plural" } },
1157
1157
  record: {
1158
1158
  name: "serviceaccounts.record",
1159
1159
  path: "/iam/service-accounts/:id",
1160
- component: () => import("./ServiceAccountRecord-ClbyeLhL.js"),
1160
+ component: () => import("./ServiceAccountRecord-D_HduQoK.js"),
1161
1161
  meta: { access: ue, titleKey: "core.serviceaccounts.title_plural", remountOnParam: "id" }
1162
1162
  }
1163
1163
  });
@@ -13,7 +13,7 @@ import { _ as Se } from "./Popover.vue_vue_type_script_setup_true_lang-C20Hf3Hl.
13
13
  import { _ as J } from "./HeaderAction.vue_vue_type_script_setup_true_lang-Da59TLBh.js";
14
14
  import { useRouter as Te } from "vue-router";
15
15
  import { _ as K } from "./Button.vue_vue_type_script_setup_true_lang-C74hcb0N.js";
16
- import { u as Ee } from "./format-DoKs29bZ.js";
16
+ import { u as Ee } from "./format-Cp1h0vsC.js";
17
17
  import { _ as Pe } from "./Icon.vue_vue_type_script_lang-BhhsFYwp.js";
18
18
  import { _ as Ce } from "./AsyncSection.vue_vue_type_script_setup_true_lang-DGzQ-Snp.js";
19
19
  const E = {
@@ -135,9 +135,9 @@ function Me(n = ee().http, t = W()) {
135
135
  return { state: $(e), hash: $(i), busy: $(a), inspect: c, enable: u, disable: g };
136
136
  }
137
137
  const Ne = "events.deadletter:view", $t = "events.deadletter:retry", Y = te({
138
- index: { name: "events.deadletters", path: "/events/dead-letters", component: () => import("./DeadLetters-wFTqhISU.js"), meta: { access: Ne, titleKey: "core.notifications.dead_letters.title" } }
138
+ index: { name: "events.deadletters", path: "/events/dead-letters", component: () => import("./DeadLetters-CHX4Ypgy.js"), meta: { access: Ne, titleKey: "core.notifications.dead_letters.title" } }
139
139
  }), j = te({
140
- index: { name: "notifications.settings", path: "/profile/notifications", component: () => import("./SettingsPage-Csb14qsx.js"), meta: { titleKey: "core.notifications.settings.title" } }
140
+ index: { name: "notifications.settings", path: "/profile/notifications", component: () => import("./SettingsPage-CpqASf_D.js"), meta: { titleKey: "core.notifications.settings.title" } }
141
141
  }), Oe = /* @__PURE__ */ q({
142
142
  __name: "SettingsMenuItem",
143
143
  setup(n) {
package/dist/index.d.ts CHANGED
@@ -1,2 +1,2 @@
1
1
  /** The version of @wssto2/vue-core (kept equal to package.json by index.test.ts). */
2
- export declare const version = "0.13.1";
2
+ export declare const version = "0.14.0";
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- const o = "0.13.1";
1
+ const o = "0.14.0";
2
2
  export {
3
3
  o as version
4
4
  };
@@ -53,6 +53,25 @@ export type Meta = {
53
53
  reports: ReportResponse[];
54
54
  watching: boolean;
55
55
  };
56
+ export type OccurrenceResponse = {
57
+ id: number;
58
+ incident_id: number;
59
+ occurred_at: string;
60
+ environment?: string;
61
+ module?: string;
62
+ route?: string;
63
+ method?: string;
64
+ user_id?: number | null;
65
+ user?: PersonResponse | null;
66
+ ip_address?: string;
67
+ request_id?: string;
68
+ error_class?: string;
69
+ error_code?: string;
70
+ message: string;
71
+ stacktrace?: string;
72
+ context?: unknown;
73
+ request?: unknown;
74
+ };
56
75
  export type PersonResponse = {
57
76
  id: number;
58
77
  name: string;
@@ -1,5 +1,5 @@
1
1
  import { type PageMeta, type QueryValue } from "../../client";
2
- import type { CommentResponse, Created, Incident, Meta } from "./entities";
2
+ import type { CommentResponse, Created, Incident, Meta, OccurrenceResponse } from "./entities";
3
3
  export declare const incidentRoutes: {
4
4
  readonly index: import("../../client").ApiRoute<Record<string, QueryValue>, Incident[], PageMeta>;
5
5
  readonly show: import("../../client").ApiRoute<{
@@ -8,6 +8,9 @@ export declare const incidentRoutes: {
8
8
  readonly comments: import("../../client").ApiRoute<{
9
9
  incidentID: number;
10
10
  }, CommentResponse[], unknown>;
11
+ readonly occurrences: import("../../client").ApiRoute<{
12
+ incidentID: number;
13
+ } & Record<string, QueryValue>, OccurrenceResponse[], PageMeta>;
11
14
  readonly report: import("../../client").ApiRoute<{
12
15
  title: string;
13
16
  description: string;
@@ -1,4 +1,4 @@
1
- import { d as s, e as a, n as o, b as i, c as n, f as u } from "../index-D_yyd4C2.js";
1
+ import { d as s, e as a, n as o, b as i, c as n, f as u } from "../index-DNeIZpXo.js";
2
2
  export {
3
3
  s as deadLettersRoutes,
4
4
  a as eventsRoutes,