@webx-ui/module-services 0.1.6 → 0.1.7

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/dist/index.js CHANGED
@@ -1,19 +1,19 @@
1
- import { reorderItems as Ne, useAdmin as ae, useDates as Be, useTranslate as le, useErrorText as me, provideRecordAddress as De, WxScreenHead as Oe, WxScreen as Pe, WxSaveState as Ae, WxDate as Me, useItemOrder as Le, WxListScreen as Re, WxRowMenu as Ue, categoryRoutes as He } from "@webx-ui/module-admin";
2
- import { provide as Fe, inject as Ke, defineComponent as ne, computed as f, ref as b, watch as se, onMounted as Te, onBeforeUnmount as Se, openBlock as d, createElementBlock as I, Fragment as Q, createVNode as p, unref as e, withCtx as o, createTextVNode as _, toDisplayString as w, createBlock as k, createCommentVNode as L, createElementVNode as q, renderList as $e, normalizeClass as ye, useTemplateRef as Ge, nextTick as Je, isRef as je, withKeys as Qe, resolveDynamicComponent as Xe, mergeProps as Ye } from "vue";
3
- import { useRoute as We, useRouter as Ce, onBeforeRouteLeave as Ze } from "vue-router";
4
- import { provideBlocksPreview as et } from "@webx-ui/module-blocks";
5
- import { useLocales as tt, localizedValue as st, confirm as Y, WxSkeleton as ie, WxCard as at, WxBadge as J, WxBreadcrumb as rt, WxBreadcrumbItem as _e, WxAlert as Ve, WxButton as j, WxActionBar as it, toast as S, WxEmpty as qe, WxText as lt, useModal as nt, WxDialog as ot, WxFormItem as ct, WxInput as Ie, WxSpace as ut, createModal as dt, WxIcon as xe, WxSelect as vt, WxSortableList as pt, WxTooltip as ht } from "@webx-ui/core";
1
+ import { reorderItems as De, useAdmin as ae, useDates as Oe, useTranslate as le, useErrorText as me, provideRecordAddress as Pe, WxScreenHead as Ae, WxScreen as Me, WxSaveState as Le, WxDate as Re, useItemOrder as Ue, WxListScreen as He, WxRowMenu as Fe, categoryRoutes as Ke } from "@webx-ui/module-admin";
2
+ import { provide as Ge, inject as Je, defineComponent as ne, computed as f, ref as b, watch as se, onMounted as Te, onBeforeUnmount as Se, openBlock as d, createElementBlock as N, Fragment as X, createVNode as p, unref as e, withCtx as o, createTextVNode as _, toDisplayString as w, createBlock as k, createCommentVNode as R, createElementVNode as E, renderList as $e, normalizeClass as ye, useTemplateRef as je, nextTick as Qe, isRef as Xe, withKeys as Ye, resolveDynamicComponent as Ze, mergeProps as et } from "vue";
3
+ import { useRoute as We, useRouter as Ce, onBeforeRouteLeave as tt } from "vue-router";
4
+ import { provideBlocksPreview as st } from "@webx-ui/module-blocks";
5
+ import { useLocales as at, localizedValue as rt, confirm as Z, WxSkeleton as ie, WxCard as it, WxBadge as j, WxBreadcrumb as lt, WxBreadcrumbItem as _e, WxAlert as Ve, WxButton as Q, WxActionBar as nt, toast as S, WxEmpty as qe, WxText as ot, useModal as ct, WxDialog as ut, WxFormItem as dt, WxInput as Ie, WxSpace as vt, createModal as pt, WxIcon as xe, WxSelect as ht, WxSortableList as ft, WxTooltip as yt } from "@webx-ui/core";
6
6
  const ge = "services";
7
7
  function oe(c) {
8
8
  const n = `${c.apiPath}/${ge}`, y = (r) => r.data;
9
9
  return {
10
10
  list: (r = {}) => {
11
- const i = new URLSearchParams();
12
- return r.q && i.set("q", r.q), r.category != null && i.set("category", String(r.category)), r.status && i.set("status", r.status), r.trashed && i.set("trashed", "1"), c.http.get(i.size > 0 ? `${n}?${i}` : n);
11
+ const l = new URLSearchParams();
12
+ return r.q && l.set("q", r.q), r.category != null && l.set("category", String(r.category)), r.status && l.set("status", r.status), r.trashed && l.set("trashed", "1"), c.http.get(l.size > 0 ? `${n}?${l}` : n);
13
13
  },
14
14
  get: (r) => c.http.get(`${n}/${r}`).then(y),
15
15
  create: (r) => c.http.post(n, r).then(y),
16
- save: (r, i) => c.http.put(`${n}/${r}`, i).then(y),
16
+ save: (r, l) => c.http.put(`${n}/${r}`, l).then(y),
17
17
  discard: (r) => c.http.post(`${n}/${r}/discard`, {}).then(y),
18
18
  publish: (r) => c.http.post(`${n}/${r}/publish`, {}).then(y),
19
19
  unpublish: (r) => c.http.post(`${n}/${r}/unpublish`, {}).then(y),
@@ -21,18 +21,18 @@ function oe(c) {
21
21
  }),
22
22
  restore: (r) => c.http.post(`${n}/${r}/restore`, {}).then(y),
23
23
  versions: (r) => c.http.get(`${n}/${r}/versions`).then(y),
24
- restoreVersion: (r, i) => c.http.post(`${n}/${r}/versions/${i}/restore`, {}).then(y),
25
- reorder: (r, i = null) => Ne(c, ge, r, i)
24
+ restoreVersion: (r, l) => c.http.post(`${n}/${r}/versions/${l}/restore`, {}).then(y),
25
+ reorder: (r, l = null) => De(c, ge, r, l)
26
26
  };
27
27
  }
28
28
  const ze = /* @__PURE__ */ Symbol("wx-service-editor");
29
- function ft(c) {
30
- Fe(ze, c);
29
+ function gt(c) {
30
+ Ge(ze, c);
31
31
  }
32
- function yt() {
33
- return Ke(ze, null);
32
+ function mt() {
33
+ return Je(ze, null);
34
34
  }
35
- const gt = {
35
+ const bt = {
36
36
  module: {
37
37
  group: "Services",
38
38
  services: "Services",
@@ -143,70 +143,84 @@ const gt = {
143
143
  function ce() {
144
144
  try {
145
145
  const { i18n: c } = ae();
146
- ke.has(c) || (c.defaults("webx-services", gt), ke.add(c));
146
+ ke.has(c) || (c.defaults("webx-services", bt), ke.add(c));
147
147
  } catch {
148
148
  }
149
149
  }
150
- const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__ */ ne({
150
+ const wt = { class: "wx-service-editor__screen" }, _t = 1200, xt = /* @__PURE__ */ ne({
151
151
  __name: "ServiceEditorPage",
152
152
  props: {
153
153
  base: { default: "/services" }
154
154
  },
155
155
  setup(c) {
156
- const n = c, y = ae(), r = oe(y), i = We(), z = Ce(), a = tt(), T = Be();
156
+ const n = c, y = ae(), r = oe(y), l = We(), B = Ce(), a = at(), T = Oe();
157
157
  ce();
158
- const s = le("webx-services"), $ = me(), W = f(() => Number(i.params.id)), D = f(() => n.base), u = b(null), g = b({}), m = b(""), h = b(null), C = b(null), O = b(!0), P = b(!1), R = b(!1), H = b({}), V = b(null), X = b(""), F = b(0), E = f(() => y.can("services.manage")), ue = f(() => !E.value || R.value), K = f(() => JSON.stringify(g.value)), N = f(() => X.value !== "" && K.value !== X.value), de = f(() => P.value ? "saving" : N.value ? "unsaved" : "saved"), Z = f(() => {
159
- const l = g.value.title;
160
- return st(l, a.active.value, u.value?.title ?? "");
158
+ const s = le("webx-services"), $ = me(), W = f(() => Number(l.params.id)), O = f(() => n.base), u = b(null), g = b({}), m = b(""), h = b(null), C = b(null), P = b(!0), M = b(!1), U = b(!1), H = b({}), V = b(null), Y = b(""), F = b(0), D = f(() => y.can("services.manage")), ue = f(() => !D.value || U.value), L = f(() => JSON.stringify(g.value)), z = f(() => Y.value !== "" && L.value !== Y.value), de = f(() => M.value ? "saving" : z.value ? "unsaved" : "saved"), ee = f(() => {
159
+ const i = g.value.title;
160
+ return rt(i, a.active.value, u.value?.title ?? "");
161
161
  }), ve = f(() => {
162
- const l = u.value;
163
- return !l || l.status !== "published" && l.status !== "modified" ? "" : s("service.live-since", { date: T.short(l.published_at) });
162
+ const i = u.value;
163
+ return !i || i.status !== "published" && i.status !== "modified" ? "" : s("service.live-since", { date: T.short(i.published_at) });
164
164
  });
165
- et({ url: f(() => C.value), reload: F }), De({
165
+ st({ url: f(() => C.value), reload: F }), Pe({
166
166
  values: g,
167
167
  prefix: h,
168
168
  path: f(() => u.value?.path),
169
169
  moving: () => s("service.address-moving")
170
- }), ft({ service: u, canManage: E.value, reload: () => A(!0) });
171
- function re(l) {
172
- u.value = l.service, g.value = l.values, m.value = l.revision, h.value = l.prefix, C.value = l.preview_url, X.value = JSON.stringify(l.values), V.value = null;
170
+ }), gt({ service: u, canManage: D.value, reload: () => A(!0) });
171
+ function re(i) {
172
+ u.value = i.service, g.value = i.values, m.value = i.revision, h.value = i.prefix, C.value = i.preview_url, Y.value = JSON.stringify(i.values), V.value = null;
173
173
  }
174
- async function A(l = !1) {
175
- l || (O.value = !0);
174
+ async function A(i = !1) {
175
+ i || (P.value = !0);
176
176
  try {
177
177
  re(await r.get(W.value));
178
- } catch (M) {
179
- S.danger($(M)), z.push(D.value);
178
+ } catch (q) {
179
+ S.danger($(q)), B.push(O.value);
180
180
  } finally {
181
- O.value = !1;
181
+ P.value = !1;
182
182
  }
183
183
  }
184
- let G;
184
+ let K;
185
185
  function pe() {
186
- !E.value || V.value || !N.value || (clearTimeout(G), G = setTimeout(() => {
187
- U();
188
- }, bt));
186
+ !D.value || V.value || !z.value || (clearTimeout(K), K = setTimeout(() => {
187
+ t();
188
+ }, _t));
189
189
  }
190
190
  function he() {
191
- !E.value || V.value || !N.value || P.value || (clearTimeout(G), U());
191
+ !D.value || V.value || !z.value || M.value || (clearTimeout(K), t());
192
192
  }
193
- async function U() {
194
- if (!u.value || P.value || !E.value) return;
195
- clearTimeout(G);
196
- const l = K.value, M = g.value;
197
- P.value = !0, H.value = {};
193
+ let G;
194
+ async function t() {
195
+ for (; G; ) {
196
+ const { carried: I, done: J } = G;
197
+ if (await J, !z.value || V.value || L.value === I) return;
198
+ }
199
+ const i = L.value, q = x();
200
+ G = { carried: i, done: q };
198
201
  try {
199
- const B = await r.save(u.value.id, { values: M, revision: m.value });
200
- u.value = B.service, m.value = B.revision, h.value = B.prefix, C.value = B.preview_url, V.value = null, K.value === l && (X.value = l), F.value += 1;
201
- } catch (B) {
202
- const te = B;
203
- te.status === 409 && te.body?.data ? V.value = te.body : te.body?.errors ? (H.value = te.body.errors, S.danger(s("service.save-failed"))) : S.danger($(B));
202
+ await q;
204
203
  } finally {
205
- P.value = !1;
204
+ G?.done === q && (G = void 0);
206
205
  }
207
206
  }
208
- async function t() {
209
- await Y({
207
+ async function x() {
208
+ if (!u.value || !D.value) return;
209
+ clearTimeout(K);
210
+ const i = L.value, q = g.value;
211
+ M.value = !0, H.value = {};
212
+ try {
213
+ const I = await r.save(u.value.id, { values: q, revision: m.value });
214
+ u.value = I.service, m.value = I.revision, h.value = I.prefix, C.value = I.preview_url, V.value = null, L.value === i && (Y.value = i), F.value += 1;
215
+ } catch (I) {
216
+ const J = I;
217
+ J.status === 409 && J.body?.data ? V.value = J.body : J.body?.errors ? (H.value = J.body.errors, S.danger(s("service.save-failed"))) : S.danger($(I));
218
+ } finally {
219
+ M.value = !1;
220
+ }
221
+ }
222
+ async function v() {
223
+ await Z({
210
224
  title: s("service.conflict-theirs-title"),
211
225
  message: s("service.conflict-theirs-text"),
212
226
  confirmText: s("service.conflict-theirs"),
@@ -214,118 +228,118 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
214
228
  tone: "danger"
215
229
  }) && await A(!0);
216
230
  }
217
- async function x() {
218
- const l = V.value;
219
- l && (m.value = l.data.revision, V.value = null, await U());
231
+ async function te() {
232
+ const i = V.value;
233
+ i && (m.value = i.data.revision, V.value = null, await t());
220
234
  }
221
- async function v() {
222
- if (!(!u.value || !await Y({
235
+ async function fe() {
236
+ if (!(!u.value || !await Z({
223
237
  title: s("service.discard-title"),
224
238
  message: s("service.discard-text"),
225
239
  confirmText: s("service.discard"),
226
240
  cancelText: s("panel.cancel"),
227
241
  tone: "danger"
228
242
  }))) {
229
- R.value = !0;
243
+ U.value = !0;
230
244
  try {
231
245
  re(await r.discard(u.value.id)), S.success(s("service.discarded"));
232
- } catch (M) {
233
- S.danger($(M));
246
+ } catch (q) {
247
+ S.danger($(q));
234
248
  } finally {
235
- R.value = !1;
249
+ U.value = !1;
236
250
  }
237
251
  }
238
252
  }
239
- async function ee() {
240
- const l = u.value;
241
- if (!(!l || !await Y({
242
- title: s("service.publish-title", { title: Z.value || l.title }),
243
- message: l.path === null ? s("service.publish-nowhere") : s("service.publish-text", { address: `/${l.path}` }),
253
+ async function Ee() {
254
+ const i = u.value;
255
+ if (!(!i || !await Z({
256
+ title: s("service.publish-title", { title: ee.value || i.title }),
257
+ message: i.path === null ? s("service.publish-nowhere") : s("service.publish-text", { address: `/${i.path}` }),
244
258
  confirmText: s("panel.publish"),
245
259
  cancelText: s("panel.cancel")
246
- })) && (N.value && await U(), !V.value)) {
247
- R.value = !0;
260
+ })) && (z.value && await t(), !V.value)) {
261
+ U.value = !0;
248
262
  try {
249
- await r.publish(l.id), await A(!0), S.success(s("panel.published"));
250
- } catch (B) {
251
- S.danger($(B));
263
+ await r.publish(i.id), await A(!0), S.success(s("panel.published"));
264
+ } catch (I) {
265
+ S.danger($(I));
252
266
  } finally {
253
- R.value = !1;
267
+ U.value = !1;
254
268
  }
255
269
  }
256
270
  }
257
- function fe() {
258
- const l = u.value?.status;
259
- return l === "published" || l === "modified" ? "success" : "default";
271
+ function Ne() {
272
+ const i = u.value?.status;
273
+ return i === "published" || i === "modified" ? "success" : "default";
260
274
  }
261
- function we(l) {
262
- N.value && l.preventDefault();
275
+ function we(i) {
276
+ z.value && i.preventDefault();
263
277
  }
264
- se(K, pe), se(W, () => {
278
+ se(L, pe), se(W, () => {
265
279
  A();
266
280
  }), Te(() => {
267
281
  A(), window.addEventListener("beforeunload", we);
268
282
  }), Se(() => {
269
- clearTimeout(G), window.removeEventListener("beforeunload", we);
270
- }), Ze(async () => !N.value || !E.value || (await U(), !N.value) ? !0 : await Y({
283
+ clearTimeout(K), window.removeEventListener("beforeunload", we);
284
+ }), tt(async () => !z.value || !D.value || (await t(), !z.value) ? !0 : await Z({
271
285
  title: s("service.leave-title"),
272
286
  message: s("service.leave-text"),
273
287
  confirmText: s("service.leave"),
274
288
  cancelText: s("panel.cancel"),
275
289
  tone: "danger"
276
290
  }));
277
- const Ee = f(() => {
278
- const l = [];
279
- return C.value && l.push({ key: "preview", label: s("service.preview"), icon: "eye", href: C.value }), u.value?.url && u.value.status !== "draft" && l.push({
291
+ const Be = f(() => {
292
+ const i = [];
293
+ return C.value && i.push({ key: "preview", label: s("service.preview"), icon: "eye", href: C.value }), u.value?.url && u.value.status !== "draft" && i.push({
280
294
  key: "site",
281
295
  label: s("panel.open-on-site"),
282
296
  icon: "link",
283
297
  href: u.value.url
284
- }), u.value?.status === "modified" && l.push({
298
+ }), u.value?.status === "modified" && i.push({
285
299
  key: "discard",
286
300
  label: s("service.discard"),
287
301
  icon: "refresh",
288
302
  danger: !0,
289
303
  menu: !0,
290
304
  run: () => {
291
- v();
305
+ fe();
292
306
  }
293
- }), l;
307
+ }), i;
294
308
  });
295
- return (l, M) => (d(), I("div", {
309
+ return (i, q) => (d(), N("div", {
296
310
  class: "wx-service-editor",
297
311
  onFocusout: he
298
312
  }, [
299
- O.value || !u.value ? (d(), I(Q, { key: 0 }, [
313
+ P.value || !u.value ? (d(), N(X, { key: 0 }, [
300
314
  p(e(ie), {
301
315
  class: "wx-service-editor__ghost",
302
316
  title: "",
303
317
  rows: 1
304
318
  }),
305
- p(e(at), null, {
319
+ p(e(it), null, {
306
320
  default: o(() => [
307
321
  p(e(ie), { rows: 8 })
308
322
  ]),
309
323
  _: 1
310
324
  })
311
- ], 64)) : (d(), I(Q, { key: 1 }, [
312
- p(e(Oe), {
325
+ ], 64)) : (d(), N(X, { key: 1 }, [
326
+ p(e(Ae), {
313
327
  divider: "",
314
- back: D.value,
328
+ back: O.value,
315
329
  "back-label": e(s)("module.services"),
316
- title: Z.value || e(s)("service.untitled"),
330
+ title: ee.value || e(s)("service.untitled"),
317
331
  subtitle: ve.value,
318
- actions: Ee.value
332
+ actions: Be.value
319
333
  }, {
320
334
  trail: o(() => [
321
- p(e(rt), {
335
+ p(e(lt), {
322
336
  size: "sm",
323
337
  label: e(s)("service.trail")
324
338
  }, {
325
339
  default: o(() => [
326
340
  p(e(_e), {
327
341
  as: "router-link",
328
- to: D.value
342
+ to: O.value
329
343
  }, {
330
344
  default: o(() => [
331
345
  _(w(e(s)("module.services")), 1)
@@ -334,7 +348,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
334
348
  }, 8, ["to"]),
335
349
  p(e(_e), { current: "" }, {
336
350
  default: o(() => [
337
- _(w(Z.value || e(s)("service.untitled")), 1)
351
+ _(w(ee.value || e(s)("service.untitled")), 1)
338
352
  ]),
339
353
  _: 1
340
354
  })
@@ -343,8 +357,8 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
343
357
  }, 8, ["label"])
344
358
  ]),
345
359
  "title-after": o(() => [
346
- p(e(J), {
347
- type: fe(),
360
+ p(e(j), {
361
+ type: Ne(),
348
362
  dot: ""
349
363
  }, {
350
364
  default: o(() => [
@@ -352,7 +366,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
352
366
  ]),
353
367
  _: 1
354
368
  }, 8, ["type"]),
355
- u.value.status === "modified" ? (d(), k(e(J), {
369
+ u.value.status === "modified" ? (d(), k(e(j), {
356
370
  key: 0,
357
371
  type: "primary",
358
372
  round: ""
@@ -361,7 +375,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
361
375
  _(w(e(s)("panel.edits")), 1)
362
376
  ]),
363
377
  _: 1
364
- })) : L("", !0)
378
+ })) : R("", !0)
365
379
  ]),
366
380
  _: 1
367
381
  }, 8, ["back", "back-label", "title", "subtitle", "actions"]),
@@ -372,20 +386,20 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
372
386
  description: V.value.message
373
387
  }, {
374
388
  actions: o(() => [
375
- p(e(j), {
389
+ p(e(Q), {
376
390
  size: "sm",
377
391
  variant: "outline",
378
- onClick: t
392
+ onClick: v
379
393
  }, {
380
394
  default: o(() => [
381
395
  _(w(e(s)("service.conflict-theirs")), 1)
382
396
  ]),
383
397
  _: 1
384
398
  }),
385
- p(e(j), {
399
+ p(e(Q), {
386
400
  size: "sm",
387
401
  type: "primary",
388
- onClick: x
402
+ onClick: te
389
403
  }, {
390
404
  default: o(() => [
391
405
  _(w(e(s)("service.conflict-mine")), 1)
@@ -394,37 +408,37 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
394
408
  })
395
409
  ]),
396
410
  _: 1
397
- }, 8, ["title", "description"])) : L("", !0),
398
- q("div", mt, [
399
- p(e(Pe), {
411
+ }, 8, ["title", "description"])) : R("", !0),
412
+ E("div", wt, [
413
+ p(e(Me), {
400
414
  modelValue: g.value,
401
- "onUpdate:modelValue": M[0] || (M[0] = (B) => g.value = B),
415
+ "onUpdate:modelValue": q[0] || (q[0] = (I) => g.value = I),
402
416
  name: "services.form",
403
417
  errors: H.value,
404
418
  disabled: ue.value
405
419
  }, null, 8, ["modelValue", "errors", "disabled"])
406
420
  ]),
407
- E.value ? (d(), k(e(it), { key: 1 }, {
421
+ D.value ? (d(), k(e(nt), { key: 1 }, {
408
422
  state: o(() => [
409
- p(e(Ae), { state: de.value }, null, 8, ["state"])
423
+ p(e(Le), { state: de.value }, null, 8, ["state"])
410
424
  ]),
411
425
  default: o(() => [
412
- p(e(j), {
426
+ p(e(Q), {
413
427
  variant: "outline",
414
- loading: P.value,
415
- disabled: !N.value,
416
- onClick: U
428
+ loading: M.value,
429
+ disabled: !z.value,
430
+ onClick: t
417
431
  }, {
418
432
  default: o(() => [
419
433
  _(w(e(s)("service.save")), 1)
420
434
  ]),
421
435
  _: 1
422
436
  }, 8, ["loading", "disabled"]),
423
- p(e(j), {
437
+ p(e(Q), {
424
438
  type: "primary",
425
- loading: R.value,
426
- disabled: u.value.status === "published" && !N.value,
427
- onClick: ee
439
+ loading: U.value,
440
+ disabled: u.value.status === "published" && !z.value,
441
+ onClick: Ee
428
442
  }, {
429
443
  default: o(() => [
430
444
  _(w(e(s)("panel.publish")), 1)
@@ -433,46 +447,46 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
433
447
  }, 8, ["loading", "disabled"])
434
448
  ]),
435
449
  _: 1
436
- })) : L("", !0)
450
+ })) : R("", !0)
437
451
  ], 64))
438
452
  ], 32));
439
453
  }
440
454
  }), be = (c, n) => {
441
455
  const y = c.__vccOpts || c;
442
- for (const [r, i] of n)
443
- y[r] = i;
456
+ for (const [r, l] of n)
457
+ y[r] = l;
444
458
  return y;
445
- }, _t = /* @__PURE__ */ be(wt, [["__scopeId", "data-v-c1092685"]]), xt = { class: "wx-service-history" }, kt = { class: "wx-service-history__number" }, Tt = { class: "wx-service-history__who" }, St = /* @__PURE__ */ ne({
459
+ }, kt = /* @__PURE__ */ be(xt, [["__scopeId", "data-v-15dec02d"]]), Tt = { class: "wx-service-history" }, St = { class: "wx-service-history__number" }, $t = { class: "wx-service-history__who" }, Wt = /* @__PURE__ */ ne({
446
460
  name: "WxServiceHistory",
447
461
  __name: "ServiceHistory",
448
462
  setup(c) {
449
- const n = ae(), y = oe(n), r = yt();
463
+ const n = ae(), y = oe(n), r = mt();
450
464
  ce();
451
- const i = le("webx-services"), z = me(), a = b(null), T = b(!1), s = f(() => r?.service.value ?? null), $ = f(() => r?.canManage ?? !1), W = f(
465
+ const l = le("webx-services"), B = me(), a = b(null), T = b(!1), s = f(() => r?.service.value ?? null), $ = f(() => r?.canManage ?? !1), W = f(
452
466
  () => s.value?.status === "published" || s.value?.status === "modified" ? a.value?.[0]?.number ?? null : null
453
467
  );
454
- async function D() {
468
+ async function O() {
455
469
  const g = s.value;
456
470
  if (g)
457
471
  try {
458
472
  a.value = await y.versions(g.id);
459
473
  } catch (m) {
460
- a.value = [], S.danger(z(m));
474
+ a.value = [], S.danger(B(m));
461
475
  }
462
476
  }
463
477
  async function u(g) {
464
478
  const m = s.value;
465
- if (!(!m || !await Y({
466
- title: i("service.restore-title", { number: g.number }),
467
- message: i("service.restore-text"),
468
- confirmText: i("service.restore-version"),
469
- cancelText: i("panel.cancel")
479
+ if (!(!m || !await Z({
480
+ title: l("service.restore-title", { number: g.number }),
481
+ message: l("service.restore-text"),
482
+ confirmText: l("service.restore-version"),
483
+ cancelText: l("panel.cancel")
470
484
  }))) {
471
485
  T.value = !0;
472
486
  try {
473
- await y.restoreVersion(m.id, g.number), await r?.reload(), S.success(i("service.restored-version", { number: g.number }));
487
+ await y.restoreVersion(m.id, g.number), await r?.reload(), S.success(l("service.restored-version", { number: g.number }));
474
488
  } catch (C) {
475
- S.danger(z(C));
489
+ S.danger(B(C));
476
490
  } finally {
477
491
  T.value = !1;
478
492
  }
@@ -481,53 +495,53 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
481
495
  return se(
482
496
  () => [s.value?.id, s.value?.published_at, s.value?.updated_at],
483
497
  () => {
484
- D();
498
+ O();
485
499
  },
486
500
  { immediate: !0 }
487
- ), (g, m) => (d(), I("div", xt, [
501
+ ), (g, m) => (d(), N("div", Tt, [
488
502
  a.value === null ? (d(), k(e(ie), {
489
503
  key: 0,
490
504
  class: "wx-service-history__ghost",
491
505
  rows: 3
492
506
  })) : a.value.length === 0 ? (d(), k(e(qe), {
493
507
  key: 1,
494
- description: e(i)("service.history-empty")
495
- }, null, 8, ["description"])) : (d(!0), I(Q, { key: 2 }, $e(a.value, (h) => (d(), I("div", {
508
+ description: e(l)("service.history-empty")
509
+ }, null, 8, ["description"])) : (d(!0), N(X, { key: 2 }, $e(a.value, (h) => (d(), N("div", {
496
510
  key: h.number,
497
511
  class: ye(["wx-service-history__row", { "is-live": h.number === W.value }])
498
512
  }, [
499
- q("code", kt, w(e(i)("service.version", { number: h.number })), 1),
500
- q("div", Tt, [
501
- h.created_at ? (d(), k(e(Me), {
513
+ E("code", St, w(e(l)("service.version", { number: h.number })), 1),
514
+ E("div", $t, [
515
+ h.created_at ? (d(), k(e(Re), {
502
516
  key: 0,
503
517
  value: h.created_at,
504
518
  size: "md",
505
519
  tone: "default"
506
- }, null, 8, ["value"])) : L("", !0),
507
- p(e(lt), {
520
+ }, null, 8, ["value"])) : R("", !0),
521
+ p(e(ot), {
508
522
  size: "sm",
509
523
  tone: "muted"
510
524
  }, {
511
525
  default: o(() => [
512
- _(w(h.author ?? e(i)(`service.source-${h.source}`)) + " ", 1),
513
- h.comment ? (d(), I(Q, { key: 0 }, [
526
+ _(w(h.author ?? e(l)(`service.source-${h.source}`)) + " ", 1),
527
+ h.comment ? (d(), N(X, { key: 0 }, [
514
528
  _(" · " + w(h.comment), 1)
515
- ], 64)) : L("", !0)
529
+ ], 64)) : R("", !0)
516
530
  ]),
517
531
  _: 2
518
532
  }, 1024)
519
533
  ]),
520
- h.number === W.value ? (d(), k(e(J), {
534
+ h.number === W.value ? (d(), k(e(j), {
521
535
  key: 0,
522
536
  type: "success",
523
537
  dot: ""
524
538
  }, {
525
539
  default: o(() => [
526
- _(w(e(i)("service.version-live")), 1)
540
+ _(w(e(l)("service.version-live")), 1)
527
541
  ]),
528
542
  _: 1
529
- })) : L("", !0),
530
- $.value && h.number !== W.value ? (d(), k(e(j), {
543
+ })) : R("", !0),
544
+ $.value && h.number !== W.value ? (d(), k(e(Q), {
531
545
  key: 1,
532
546
  size: "sm",
533
547
  variant: "outline",
@@ -535,27 +549,27 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
535
549
  onClick: (C) => u(h)
536
550
  }, {
537
551
  default: o(() => [
538
- _(w(e(i)("service.restore-version")), 1)
552
+ _(w(e(l)("service.restore-version")), 1)
539
553
  ]),
540
554
  _: 1
541
- }, 8, ["loading", "onClick"])) : L("", !0)
555
+ }, 8, ["loading", "onClick"])) : R("", !0)
542
556
  ], 2))), 128))
543
557
  ]));
544
558
  }
545
- }), $t = /* @__PURE__ */ be(St, [["__scopeId", "data-v-72dccbb1"]]), Wt = /* @__PURE__ */ ne({
559
+ }), Ct = /* @__PURE__ */ be(Wt, [["__scopeId", "data-v-72dccbb1"]]), Vt = /* @__PURE__ */ ne({
546
560
  __name: "ServiceCreateDialog",
547
561
  setup(c) {
548
- const { open: n, resolve: y, dismiss: r } = nt(), i = ae(), z = oe(i);
562
+ const { open: n, resolve: y, dismiss: r } = ct(), l = ae(), B = oe(l);
549
563
  ce();
550
- const a = le("webx-services"), T = b(""), s = b(!1), $ = b({}), W = Ge("field");
564
+ const a = le("webx-services"), T = b(""), s = b(!1), $ = b({}), W = je("field");
551
565
  Te(async () => {
552
- await Je(), W.value?.querySelector("input")?.focus();
566
+ await Qe(), W.value?.querySelector("input")?.focus();
553
567
  });
554
- async function D() {
568
+ async function O() {
555
569
  if (!(T.value.trim() === "" || s.value)) {
556
570
  s.value = !0, $.value = {};
557
571
  try {
558
- y(await z.create({ title: T.value.trim() }));
572
+ y(await B.create({ title: T.value.trim() }));
559
573
  } catch (u) {
560
574
  $.value = u.body?.errors ?? {};
561
575
  } finally {
@@ -563,16 +577,16 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
563
577
  }
564
578
  }
565
579
  }
566
- return (u, g) => (d(), k(e(ot), {
580
+ return (u, g) => (d(), k(e(ut), {
567
581
  open: e(n),
568
- "onUpdate:open": g[2] || (g[2] = (m) => je(n) ? n.value = m : null),
582
+ "onUpdate:open": g[2] || (g[2] = (m) => Xe(n) ? n.value = m : null),
569
583
  title: e(a)("panel.new-title"),
570
584
  width: 440
571
585
  }, {
572
586
  footer: o(() => [
573
- p(e(ut), { size: "sm" }, {
587
+ p(e(vt), { size: "sm" }, {
574
588
  default: o(() => [
575
- p(e(j), {
589
+ p(e(Q), {
576
590
  variant: "outline",
577
591
  onClick: g[1] || (g[1] = (m) => e(r)())
578
592
  }, {
@@ -581,11 +595,11 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
581
595
  ]),
582
596
  _: 1
583
597
  }),
584
- p(e(j), {
598
+ p(e(Q), {
585
599
  type: "primary",
586
600
  loading: s.value,
587
601
  disabled: T.value.trim() === "",
588
- onClick: D
602
+ onClick: O
589
603
  }, {
590
604
  default: o(() => [
591
605
  _(w(e(a)("panel.create")), 1)
@@ -597,13 +611,13 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
597
611
  })
598
612
  ]),
599
613
  default: o(() => [
600
- p(e(ct), {
614
+ p(e(dt), {
601
615
  label: e(a)("panel.field-title"),
602
616
  error: $.value.title?.[0] ?? $.value.slug?.[0],
603
617
  required: ""
604
618
  }, {
605
619
  default: o(() => [
606
- q("div", {
620
+ E("div", {
607
621
  ref_key: "field",
608
622
  ref: W
609
623
  }, [
@@ -611,7 +625,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
611
625
  modelValue: T.value,
612
626
  "onUpdate:modelValue": g[0] || (g[0] = (m) => T.value = m),
613
627
  "aria-label": e(a)("panel.field-title"),
614
- onKeyup: Qe(D, ["enter"])
628
+ onKeyup: Ye(O, ["enter"])
615
629
  }, null, 8, ["modelValue", "aria-label"])
616
630
  ], 512)
617
631
  ]),
@@ -621,42 +635,42 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
621
635
  _: 1
622
636
  }, 8, ["open", "title"]));
623
637
  }
624
- }), Ct = { class: "wx-services" }, Vt = { class: "wx-services__bar" }, qt = ["src"], It = { class: "wx-service-row__name" }, zt = { class: "wx-service-row__title" }, Et = { class: "wx-service-row__address" }, Nt = { class: "wx-service-row__facts" }, Bt = { class: "wx-service-row__chips" }, Dt = { class: "wx-service-row__state" }, Ot = /* @__PURE__ */ ne({
638
+ }), qt = { class: "wx-services" }, It = { class: "wx-services__bar" }, zt = ["src"], Et = { class: "wx-service-row__name" }, Nt = { class: "wx-service-row__title" }, Bt = { class: "wx-service-row__address" }, Dt = { class: "wx-service-row__facts" }, Ot = { class: "wx-service-row__chips" }, Pt = { class: "wx-service-row__state" }, At = /* @__PURE__ */ ne({
625
639
  __name: "ServicesPage",
626
640
  props: {
627
641
  base: { default: "/services" }
628
642
  },
629
643
  setup(c) {
630
- const n = c, y = ae(), r = oe(y), i = We(), z = Ce();
644
+ const n = c, y = ae(), r = oe(y), l = We(), B = Ce();
631
645
  ce();
632
- const a = le("webx-services"), T = me(), s = b([]), $ = b([]), W = b(!0), D = dt(Wt), u = f(() => y.can("services.manage")), g = f(
646
+ const a = le("webx-services"), T = me(), s = b([]), $ = b([]), W = b(!0), O = pt(Vt), u = f(() => y.can("services.manage")), g = f(
633
647
  () => y.state.manifest?.modules.find((t) => t.id === "services")?.title ?? a("module.services")
634
648
  ), m = f({
635
- get: () => typeof i.query.view == "string" ? i.query.view : "",
649
+ get: () => typeof l.query.view == "string" ? l.query.view : "",
636
650
  set: (t) => {
637
- z.replace({
638
- query: { ...i.query, view: t === "" ? void 0 : String(t) }
651
+ B.replace({
652
+ query: { ...l.query, view: t === "" ? void 0 : String(t) }
639
653
  });
640
654
  }
641
655
  }), h = f(() => m.value === "trashed"), C = f(() => {
642
- const t = i.query.category;
656
+ const t = l.query.category;
643
657
  return typeof t == "string" && t !== "" && Number(t) || null;
644
- }), O = f(() => typeof i.query.q == "string" ? i.query.q : ""), P = b(O.value), R = f(() => [
658
+ }), P = f(() => typeof l.query.q == "string" ? l.query.q : ""), M = b(P.value), U = f(() => [
645
659
  { value: "", label: a("panel.view-all") },
646
660
  { value: "published", label: a("panel.view-published") },
647
661
  { value: "draft", label: a("panel.view-draft") },
648
662
  { value: "unpublished", label: a("panel.view-unpublished") },
649
663
  { value: "trashed", label: a("panel.bin"), icon: "trash" }
650
- ]), H = Le(ge, () => ({
651
- q: O.value,
664
+ ]), H = Ue(ge, () => ({
665
+ q: P.value,
652
666
  category: C.value,
653
667
  filtered: m.value !== ""
654
- })), V = f(() => u.value && H.sortable.value), X = f(() => O.value !== "" ? a("panel.empty-search") : h.value ? a("panel.empty-bin") : a("panel.empty"));
668
+ })), V = f(() => u.value && H.sortable.value), Y = f(() => P.value !== "" ? a("panel.empty-search") : h.value ? a("panel.empty-bin") : a("panel.empty"));
655
669
  async function F() {
656
670
  W.value = !0;
657
671
  try {
658
672
  const t = await r.list({
659
- q: O.value,
673
+ q: P.value,
660
674
  category: C.value,
661
675
  status: h.value ? "" : m.value,
662
676
  trashed: h.value
@@ -669,28 +683,28 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
669
683
  }
670
684
  }
671
685
  se(
672
- () => [m.value, C.value, O.value],
686
+ () => [m.value, C.value, P.value],
673
687
  () => {
674
688
  F();
675
689
  }
676
690
  ), F();
677
- let E;
678
- se(P, (t) => {
679
- clearTimeout(E), E = setTimeout(() => {
680
- z.replace({ query: { ...i.query, q: t.trim() === "" ? void 0 : t } });
691
+ let D;
692
+ se(M, (t) => {
693
+ clearTimeout(D), D = setTimeout(() => {
694
+ B.replace({ query: { ...l.query, q: t.trim() === "" ? void 0 : t } });
681
695
  }, 300);
682
- }), Se(() => clearTimeout(E));
696
+ }), Se(() => clearTimeout(D));
683
697
  function ue(t) {
684
- z.replace({
685
- query: { ...i.query, category: typeof t == "number" ? String(t) : void 0 }
698
+ B.replace({
699
+ query: { ...l.query, category: typeof t == "number" ? String(t) : void 0 }
686
700
  });
687
701
  }
688
- function K(t) {
689
- z.push({ path: `${n.base}/${t.id}`, query: { ...i.query } });
702
+ function L(t) {
703
+ B.push({ path: `${n.base}/${t.id}`, query: { ...l.query } });
690
704
  }
691
- async function N() {
692
- const t = await D({});
693
- t && K(t);
705
+ async function z() {
706
+ const t = await O({});
707
+ t && L(t);
694
708
  }
695
709
  async function de() {
696
710
  try {
@@ -699,7 +713,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
699
713
  S.danger(T(t, a("panel.reorder-failed"))), await F();
700
714
  }
701
715
  }
702
- function Z(t) {
716
+ function ee(t) {
703
717
  if (!u.value) return [];
704
718
  if (h.value)
705
719
  return [
@@ -713,7 +727,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
713
727
  }
714
728
  ];
715
729
  const x = [
716
- { key: "open", icon: "edit", label: a("panel.open"), run: () => K(t) }
730
+ { key: "open", icon: "edit", label: a("panel.open"), run: () => L(t) }
717
731
  ];
718
732
  return t.url && t.status !== "draft" && x.push({
719
733
  key: "site",
@@ -725,7 +739,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
725
739
  icon: "copy",
726
740
  label: a("panel.copy-address"),
727
741
  run: () => {
728
- G(t);
742
+ K(t);
729
743
  }
730
744
  }), x.push(
731
745
  t.status === "published" || t.status === "modified" ? {
@@ -754,7 +768,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
754
768
  }), x;
755
769
  }
756
770
  async function ve(t) {
757
- await Y({
771
+ await Z({
758
772
  title: a("panel.delete-title", { title: t.title }),
759
773
  message: a("panel.delete-text"),
760
774
  confirmText: a("panel.delete"),
@@ -774,7 +788,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
774
788
  await F();
775
789
  }
776
790
  }
777
- async function G(t) {
791
+ async function K(t) {
778
792
  if (t.url)
779
793
  try {
780
794
  await navigator.clipboard.writeText(t.url), S.success(a("panel.address-copied"));
@@ -787,25 +801,25 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
787
801
  function he(t) {
788
802
  return h.value ? "—" : t.path === null ? a("panel.no-address") : `/${t.path}`;
789
803
  }
790
- const U = f(
804
+ const G = f(
791
805
  () => u.value ? [{ key: "new", label: a("panel.new"), icon: "plus", primary: !0, run: () => {
792
- N();
806
+ z();
793
807
  } }] : []
794
808
  );
795
- return (t, x) => (d(), I("div", Ct, [
796
- p(e(Re), {
809
+ return (t, x) => (d(), N("div", qt, [
810
+ p(e(He), {
797
811
  view: m.value,
798
812
  "onUpdate:view": x[2] || (x[2] = (v) => m.value = v),
799
813
  title: g.value,
800
- views: R.value,
801
- actions: U.value,
814
+ views: U.value,
815
+ actions: G.value,
802
816
  padding: "sm"
803
817
  }, {
804
818
  default: o(() => [
805
- q("div", Vt, [
819
+ E("div", It, [
806
820
  p(e(Ie), {
807
- modelValue: P.value,
808
- "onUpdate:modelValue": x[0] || (x[0] = (v) => P.value = v),
821
+ modelValue: M.value,
822
+ "onUpdate:modelValue": x[0] || (x[0] = (v) => M.value = v),
809
823
  class: "wx-services__search",
810
824
  size: "sm",
811
825
  clearable: "",
@@ -820,7 +834,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
820
834
  ]),
821
835
  _: 1
822
836
  }, 8, ["modelValue", "placeholder", "aria-label"]),
823
- p(e(vt), {
837
+ p(e(ht), {
824
838
  class: "wx-services__category",
825
839
  "model-value": C.value,
826
840
  options: $.value.map((v) => ({ value: v.id, label: v.title })),
@@ -837,10 +851,10 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
837
851
  rows: 5
838
852
  })) : s.value.length === 0 ? (d(), k(e(qe), {
839
853
  key: 1,
840
- title: X.value,
841
- description: m.value === "" && O.value === "" && C.value === null ? e(a)("panel.empty-help") : void 0
842
- }, null, 8, ["title", "description"])) : (d(), I(Q, { key: 2 }, [
843
- p(e(pt), {
854
+ title: Y.value,
855
+ description: m.value === "" && P.value === "" && C.value === null ? e(a)("panel.empty-help") : void 0
856
+ }, null, 8, ["title", "description"])) : (d(), N(X, { key: 2 }, [
857
+ p(e(ft), {
844
858
  modelValue: s.value,
845
859
  "onUpdate:modelValue": x[1] || (x[1] = (v) => s.value = v),
846
860
  class: ye(["wx-services__list", { "is-loading": W.value }]),
@@ -852,62 +866,62 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
852
866
  onMove: de
853
867
  }, {
854
868
  default: o(({ item: v }) => [
855
- (d(), k(Xe(h.value ? "div" : "router-link"), Ye({ class: "wx-service-row" }, h.value ? {} : { to: { path: `${n.base}/${v.id}`, query: e(i).query } }), {
869
+ (d(), k(Ze(h.value ? "div" : "router-link"), et({ class: "wx-service-row" }, h.value ? {} : { to: { path: `${n.base}/${v.id}`, query: e(l).query } }), {
856
870
  default: o(() => [
857
- q("span", {
871
+ E("span", {
858
872
  class: ye(["wx-service-row__cover", { "is-empty": !v.cover }])
859
873
  }, [
860
- v.cover?.thumb ? (d(), I("img", {
874
+ v.cover?.thumb ? (d(), N("img", {
861
875
  key: 0,
862
876
  src: v.cover.thumb,
863
877
  alt: "",
864
878
  loading: "lazy"
865
- }, null, 8, qt)) : (d(), k(e(xe), {
879
+ }, null, 8, zt)) : (d(), k(e(xe), {
866
880
  key: 1,
867
881
  name: "image",
868
882
  size: "sm"
869
883
  }))
870
884
  ], 2),
871
- q("span", It, [
872
- q("span", zt, w(v.title), 1),
873
- q("span", Et, w(he(v)), 1)
885
+ E("span", Et, [
886
+ E("span", Nt, w(v.title), 1),
887
+ E("span", Bt, w(he(v)), 1)
874
888
  ]),
875
- q("span", Nt, [
876
- q("span", Bt, [
877
- (d(!0), I(Q, null, $e(v.categories, (ee, fe) => (d(), I(Q, {
878
- key: ee.id
889
+ E("span", Dt, [
890
+ E("span", Ot, [
891
+ (d(!0), N(X, null, $e(v.categories, (te, fe) => (d(), N(X, {
892
+ key: te.id
879
893
  }, [
880
- fe === 0 ? (d(), k(e(ht), {
894
+ fe === 0 ? (d(), k(e(yt), {
881
895
  key: 0,
882
896
  content: e(a)("panel.main-category")
883
897
  }, {
884
898
  default: o(() => [
885
- p(e(J), {
899
+ p(e(j), {
886
900
  size: "sm",
887
901
  round: "",
888
902
  type: "primary"
889
903
  }, {
890
904
  default: o(() => [
891
- _(w(ee.title), 1)
905
+ _(w(te.title), 1)
892
906
  ]),
893
907
  _: 2
894
908
  }, 1024)
895
909
  ]),
896
910
  _: 2
897
- }, 1032, ["content"])) : (d(), k(e(J), {
911
+ }, 1032, ["content"])) : (d(), k(e(j), {
898
912
  key: 1,
899
913
  size: "sm",
900
914
  round: ""
901
915
  }, {
902
916
  default: o(() => [
903
- _(w(ee.title), 1)
917
+ _(w(te.title), 1)
904
918
  ]),
905
919
  _: 2
906
920
  }, 1024))
907
921
  ], 64))), 128))
908
922
  ]),
909
- q("span", Dt, [
910
- p(e(J), {
923
+ E("span", Pt, [
924
+ p(e(j), {
911
925
  type: pe(v.status),
912
926
  dot: "",
913
927
  size: "sm"
@@ -917,7 +931,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
917
931
  ]),
918
932
  _: 2
919
933
  }, 1032, ["type"]),
920
- v.status === "modified" ? (d(), k(e(J), {
934
+ v.status === "modified" ? (d(), k(e(j), {
921
935
  key: 0,
922
936
  type: "primary",
923
937
  size: "sm",
@@ -927,7 +941,7 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
927
941
  _(w(e(a)("panel.edits")), 1)
928
942
  ]),
929
943
  _: 1
930
- })) : L("", !0)
944
+ })) : R("", !0)
931
945
  ])
932
946
  ])
933
947
  ]),
@@ -935,8 +949,8 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
935
949
  }, 1040))
936
950
  ]),
937
951
  actions: o(({ item: v }) => [
938
- p(e(Ue), {
939
- actions: Z(v),
952
+ p(e(Fe), {
953
+ actions: ee(v),
940
954
  label: v.title
941
955
  }, null, 8, ["actions", "label"])
942
956
  ]),
@@ -947,15 +961,15 @@ const mt = { class: "wx-service-editor__screen" }, bt = 1200, wt = /* @__PURE__
947
961
  class: "wx-services__note",
948
962
  type: "info",
949
963
  description: e(H).hint.value
950
- }, null, 8, ["description"])) : L("", !0)
964
+ }, null, 8, ["description"])) : R("", !0)
951
965
  ], 64))
952
966
  ]),
953
967
  _: 1
954
968
  }, 8, ["view", "title", "views", "actions"])
955
969
  ]));
956
970
  }
957
- }), Pt = /* @__PURE__ */ be(Ot, [["__scopeId", "data-v-f99d37d6"]]);
958
- function At(c = "/services") {
971
+ }), Mt = /* @__PURE__ */ be(At, [["__scopeId", "data-v-f99d37d6"]]);
972
+ function Lt(c = "/services") {
959
973
  return {
960
974
  api: "services/categories",
961
975
  path: `${c}/categories`,
@@ -985,18 +999,18 @@ function At(c = "/services") {
985
999
  }
986
1000
  };
987
1001
  }
988
- function Ft(c = {}) {
1002
+ function Gt(c = {}) {
989
1003
  const n = c.path ?? "/services";
990
1004
  return [
991
1005
  {
992
1006
  id: "services",
993
1007
  path: n,
994
1008
  routes: [
995
- { path: n, name: "webx.services", component: Pt, props: { base: n } },
1009
+ { path: n, name: "webx.services", component: Mt, props: { base: n } },
996
1010
  {
997
1011
  path: `${n}/:id(\\d+)`,
998
1012
  name: "webx.services.edit",
999
- component: _t,
1013
+ component: kt,
1000
1014
  props: { base: n }
1001
1015
  }
1002
1016
  ],
@@ -1006,28 +1020,28 @@ function Ft(c = {}) {
1006
1020
  * particular is shared, and reads the prefix from the editor hosting the screen.
1007
1021
  */
1008
1022
  types: {
1009
- "wx-service-history": { component: $t, kind: "display" }
1023
+ "wx-service-history": { component: Ct, kind: "display" }
1010
1024
  }
1011
1025
  },
1012
1026
  {
1013
1027
  id: "service-categories",
1014
1028
  path: `${n}/categories`,
1015
- routes: He(At(n))
1029
+ routes: Ke(Lt(n))
1016
1030
  }
1017
1031
  ];
1018
1032
  }
1019
1033
  export {
1020
1034
  ge as SERVICES_API,
1021
- Wt as WxServiceCreateDialog,
1022
- _t as WxServiceEditorPage,
1023
- $t as WxServiceHistory,
1024
- Pt as WxServicesPage,
1035
+ Vt as WxServiceCreateDialog,
1036
+ kt as WxServiceEditorPage,
1037
+ Ct as WxServiceHistory,
1038
+ Mt as WxServicesPage,
1025
1039
  oe as createServicesApi,
1026
- ft as provideServiceEditor,
1027
- At as serviceCategoriesOptions,
1040
+ gt as provideServiceEditor,
1041
+ Lt as serviceCategoriesOptions,
1028
1042
  ze as serviceEditorKey,
1029
- Ft as services,
1030
- gt as servicesMessages,
1031
- yt as useServiceEditor
1043
+ Gt as services,
1044
+ bt as servicesMessages,
1045
+ mt as useServiceEditor
1032
1046
  };
1033
1047
  //# sourceMappingURL=index.js.map