@webx-ui/module-blog 0.5.17 → 0.5.19

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,16 +1,16 @@
1
- import { useAdmin as ne, useTranslate as J, useDates as ut, useErrorText as be, WxScreenHead as ct, WxScreen as dt, WxSaveState as pt, WxDate as Ee, rowMenuWidth as Ye, WxListScreen as et, WxRowMenu as ze, WxFilterChips as vt, categoryRoutes as gt } from "@webx-ui/module-admin";
2
- import { provide as ft, inject as ht, defineComponent as Q, useModel as Le, computed as h, openBlock as _, createBlock as q, unref as e, mergeModels as Fe, ref as M, watch as ve, onMounted as Ne, onBeforeUnmount as Ke, createElementBlock as H, Fragment as ke, createVNode as r, withCtx as l, createTextVNode as C, toDisplayString as k, createCommentVNode as K, createElementVNode as F, renderList as qe, normalizeClass as tt, normalizeProps as mt, guardReactiveProps as bt, useTemplateRef as Ie, nextTick as He, isRef as Pe, withKeys as Me, useId as yt, withModifiers as Je } from "vue";
3
- import { WxSelect as _e, useLocales as at, localizedValue as wt, confirm as de, WxSkeleton as Oe, WxCard as xt, WxBadge as ie, WxBreadcrumb as _t, WxBreadcrumbItem as Ze, WxAlert as Ue, WxButton as G, WxActionBar as lt, toast as R, WxEmpty as kt, WxText as le, WxSortableList as $t, WxAction as Tt, WxInput as Ce, WxFormItem as pe, useModal as Re, WxDialog as De, WxSpace as Be, useElementWidth as At, createModal as Ve, WxTable as it, WxEntityCard as St, WxIcon as Te, WxTooltip as nt, WxCheckbox as Wt } from "@webx-ui/core";
4
- import { useRoute as Ge, useRouter as je, onBeforeRouteLeave as Ct } from "vue-router";
5
- import { provideBlocksPreview as Vt } from "@webx-ui/module-blocks";
6
- const st = /* @__PURE__ */ Symbol("wx-article-editor");
7
- function zt(g) {
8
- ft(st, g);
1
+ import { useAdmin as ne, useTranslate as Z, useDates as pt, useErrorText as he, WxScreenHead as vt, WxScreen as gt, WxSaveState as ft, WxDate as Ee, rowMenuWidth as et, WxListScreen as tt, WxRowMenu as ze, WxAddressNote as ht, WxFilterChips as mt, categoryRoutes as bt } from "@webx-ui/module-admin";
2
+ import { provide as yt, inject as wt, defineComponent as ee, useModel as Le, computed as b, openBlock as _, createBlock as q, unref as e, mergeModels as Fe, ref as M, watch as pe, onMounted as Ue, onBeforeUnmount as Ke, createElementBlock as j, Fragment as _e, createVNode as r, withCtx as l, createTextVNode as C, toDisplayString as $, createCommentVNode as L, createElementVNode as F, renderList as qe, normalizeClass as at, normalizeProps as xt, guardReactiveProps as _t, useTemplateRef as Ie, nextTick as He, isRef as Pe, withKeys as Me, useId as kt, withModifiers as Ze } from "vue";
3
+ import { WxSelect as xe, useLocales as lt, localizedValue as $t, confirm as oe, WxSkeleton as Oe, WxCard as Tt, WxBadge as ie, WxBreadcrumb as At, WxBreadcrumbItem as Qe, WxAlert as Ne, WxButton as J, WxActionBar as it, toast as P, WxEmpty as St, WxText as le, WxSortableList as Wt, WxAction as Ct, WxInput as Ce, WxFormItem as de, useModal as Re, WxDialog as De, WxSpace as Be, useElementWidth as Vt, createModal as Ve, WxTable as nt, WxEntityCard as zt, WxIcon as Te, WxTooltip as st, WxCheckbox as Mt } from "@webx-ui/core";
4
+ import { useRoute as Ge, useRouter as je, onBeforeRouteLeave as Nt } from "vue-router";
5
+ import { provideBlocksPreview as Ut } from "@webx-ui/module-blocks";
6
+ const rt = /* @__PURE__ */ Symbol("wx-article-editor");
7
+ function qt(h) {
8
+ yt(rt, h);
9
9
  }
10
10
  function Ae() {
11
- return ht(st, null);
11
+ return wt(rt, null);
12
12
  }
13
- const Mt = {
13
+ const It = {
14
14
  module: {
15
15
  group: "Blog",
16
16
  articles: "Articles",
@@ -88,8 +88,6 @@ const Mt = {
88
88
  preview: "Preview",
89
89
  more: "More",
90
90
  discard: "Discard changes",
91
- "discard-title": "Discard what is waiting?",
92
- "discard-text": "The article goes back to what the site is showing. What was written since is not listed anywhere.",
93
91
  discarded: "The article is back to what is published.",
94
92
  "conflict-title": "The article changed while you were editing",
95
93
  "conflict-mine": "Keep mine",
@@ -223,15 +221,15 @@ const Mt = {
223
221
  "merge-warning": ":count articles will carry “:tag” instead. :merged tags will be deleted, and there is no undoing it.",
224
222
  "merge-confirm": "Merge"
225
223
  }
226
- }, Qe = /* @__PURE__ */ new WeakSet();
227
- function X() {
224
+ }, Xe = /* @__PURE__ */ new WeakSet();
225
+ function te() {
228
226
  try {
229
- const { i18n: g } = ne();
230
- Qe.has(g) || (g.defaults("webx-blog", Mt), Qe.add(g));
227
+ const { i18n: h } = ne();
228
+ Xe.has(h) || (h.defaults("webx-blog", It), Xe.add(h));
231
229
  } catch {
232
230
  }
233
231
  }
234
- const Ut = /* @__PURE__ */ Q({
232
+ const Pt = /* @__PURE__ */ ee({
235
233
  name: "WxArticleAuthor",
236
234
  __name: "ArticleAuthor",
237
235
  props: /* @__PURE__ */ Fe({
@@ -241,23 +239,23 @@ const Ut = /* @__PURE__ */ Q({
241
239
  modelModifiers: {}
242
240
  }),
243
241
  emits: ["update:modelValue"],
244
- setup(g) {
245
- const c = g, v = Le(g, "modelValue"), f = Ae();
246
- X();
247
- const a = J("webx-blog"), s = h(() => c.disabled || f?.disabled.value === !0), t = h(
242
+ setup(h) {
243
+ const c = h, v = Le(h, "modelValue"), f = Ae();
244
+ te();
245
+ const a = Z("webx-blog"), s = b(() => c.disabled || f?.disabled.value === !0), t = b(
248
246
  () => (f?.options.value.authors ?? []).map((i) => ({
249
247
  label: i.title,
250
248
  value: i.id
251
249
  }))
252
- ), u = h({
250
+ ), o = b({
253
251
  get: () => v.value,
254
252
  set: (i) => {
255
253
  v.value = typeof i == "number" ? i : null;
256
254
  }
257
255
  });
258
- return (i, m) => (_(), q(e(_e), {
259
- modelValue: u.value,
260
- "onUpdate:modelValue": m[0] || (m[0] = (y) => u.value = y),
256
+ return (i, d) => (_(), q(e(xe), {
257
+ modelValue: o.value,
258
+ "onUpdate:modelValue": d[0] || (d[0] = (w) => o.value = w),
261
259
  options: t.value,
262
260
  placeholder: e(a)("article.no-author"),
263
261
  disabled: s.value,
@@ -268,267 +266,294 @@ const Ut = /* @__PURE__ */ Q({
268
266
  }, null, 8, ["modelValue", "options", "placeholder", "disabled", "aria-label"]));
269
267
  }
270
268
  });
271
- function ue(g) {
272
- const c = `${g.apiPath}/blog/articles`, v = `${g.apiPath}/blog/tags`, f = (a) => a.data;
269
+ function ue(h) {
270
+ const c = `${h.apiPath}/blog/articles`, v = `${h.apiPath}/blog/tags`, f = (a) => a.data;
273
271
  return {
274
272
  articles: (a = {}) => {
275
273
  const s = new URLSearchParams();
276
274
  a.q && s.set("q", a.q), a.rubric != null && s.set("rubric", String(a.rubric)), a.tag != null && s.set("tag", String(a.tag)), a.author != null && s.set("author", String(a.author)), a.status && s.set("status", a.status), a.sort && s.set("sort", a.sort), a.trashed && s.set("trashed", "1"), a.page && a.page > 1 && s.set("page", String(a.page)), a.per_page && s.set("per_page", String(a.per_page));
277
275
  const t = s.size > 0 ? `?${s}` : "";
278
- return g.http.get(`${c}${t}`).then((u) => ({ ...u.meta, data: u.data, filters: u.filters }));
276
+ return h.http.get(`${c}${t}`).then((o) => ({ ...o.meta, data: o.data, filters: o.filters }));
279
277
  },
280
- get: (a) => g.http.get(`${c}/${a}`).then(f),
281
- create: (a) => g.http.post(c, a).then(f),
282
- save: (a, s) => g.http.put(`${c}/${a}`, s).then(f),
283
- discard: (a) => g.http.post(`${c}/${a}/discard`, {}).then(f),
284
- versions: (a) => g.http.get(`${c}/${a}/versions`).then(f),
285
- restoreVersion: (a, s) => g.http.post(`${c}/${a}/versions/${s}/restore`, {}).then(f),
278
+ get: (a) => h.http.get(`${c}/${a}`).then(f),
279
+ create: (a) => h.http.post(c, a).then(f),
280
+ save: (a, s) => h.http.put(`${c}/${a}`, s).then(f),
281
+ discard: (a) => h.http.post(`${c}/${a}/discard`, {}).then(f),
282
+ versions: (a) => h.http.get(`${c}/${a}/versions`).then(f),
283
+ restoreVersion: (a, s) => h.http.post(`${c}/${a}/versions/${s}/restore`, {}).then(f),
286
284
  tags: (a = "") => {
287
285
  const s = a.trim() === "" ? "" : `?q=${encodeURIComponent(a.trim())}`;
288
- return g.http.get(`${v}${s}`).then(f);
286
+ return h.http.get(`${v}${s}`).then(f);
289
287
  },
290
- createTag: (a) => g.http.post(v, a).then(f),
291
- publish: (a, s) => g.http.post(`${c}/${a}/publish`, s == null ? {} : { at: s }).then(f),
292
- unpublish: (a) => g.http.post(`${c}/${a}/unpublish`, {}).then(f),
293
- remove: (a) => g.http.delete(`${c}/${a}`).then(() => {
288
+ createTag: (a) => h.http.post(v, a).then(f),
289
+ publish: (a, s) => h.http.post(`${c}/${a}/publish`, s == null ? {} : { at: s }).then(f),
290
+ unpublish: (a) => h.http.post(`${c}/${a}/unpublish`, {}).then(f),
291
+ remove: (a) => h.http.delete(`${c}/${a}`).then(() => {
294
292
  }),
295
- restore: (a) => g.http.post(`${c}/${a}/restore`, {}).then(f),
293
+ restore: (a) => h.http.post(`${c}/${a}/restore`, {}).then(f),
296
294
  tagsPage: (a = {}) => {
297
295
  const s = new URLSearchParams();
298
296
  a.q && s.set("q", a.q), a.empty && s.set("empty", "1"), a.noindex && s.set("noindex", "1"), a.sort && s.set("sort", a.sort), a.page && a.page > 1 && s.set("page", String(a.page)), a.per_page && s.set("per_page", String(a.per_page));
299
297
  const t = s.size > 0 ? `?${s}` : "";
300
- return g.http.get(`${v}${t}`).then((u) => ({ ...u.meta, data: u.data, filters: u.filters }));
298
+ return h.http.get(`${v}${t}`).then((o) => ({ ...o.meta, data: o.data, filters: o.filters }));
301
299
  },
302
- saveTag: (a, s) => g.http.put(`${v}/${a}`, s).then(f),
303
- removeTag: (a) => g.http.delete(`${v}/${a}`).then(() => {
300
+ saveTag: (a, s) => h.http.put(`${v}/${a}`, s).then(f),
301
+ removeTag: (a) => h.http.delete(`${v}/${a}`).then(() => {
304
302
  }),
305
- massTags: (a, s) => g.http.post(`${v}/mass`, { ids: a, action: s }).then((t) => t.data.affected),
306
- mergeTags: (a, s, t) => g.http.post(`${v}/merge`, { ids: a, keep: s, redirect: t }).then(f)
303
+ massTags: (a, s) => h.http.post(`${v}/mass`, { ids: a, action: s }).then((t) => t.data.affected),
304
+ mergeTags: (a, s, t) => h.http.post(`${v}/merge`, { ids: a, keep: s, redirect: t }).then(f)
307
305
  };
308
306
  }
309
- const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__ */ Q({
307
+ const Rt = { class: "wx-article-editor__screen" }, Dt = 1200, Bt = /* @__PURE__ */ ee({
310
308
  __name: "ArticleEditorPage",
311
309
  props: {
312
310
  base: { default: "/blog" }
313
311
  },
314
- setup(g) {
315
- const c = g, v = ne(), f = ue(v), a = Ge(), s = je(), t = at(), u = ut();
316
- X();
317
- const i = J("webx-blog"), m = be(), y = h(() => Number(a.params.id)), $ = h(() => `${c.base}/articles`), d = M(null), W = M({}), V = M(""), z = M(""), D = M(null), B = M({ rubrics: [], authors: [] }), w = M([]), T = M(!0), N = M(!1), I = M(!1), b = M({}), P = M(null), E = M(""), Z = M(0), Y = h(() => v.can("blog.articles.manage")), se = h(() => !Y.value || I.value), re = h(() => JSON.stringify(W.value)), O = h(() => E.value !== "" && re.value !== E.value), ye = h(() => N.value ? "saving" : O.value ? "unsaved" : "saved"), we = h(() => {
318
- const x = W.value.title;
319
- return wt(x, t.active.value, d.value?.title ?? "");
320
- }), te = h(() => {
321
- const x = W.value.published_at;
322
- return typeof x == "string" && x !== "" ? x : null;
323
- }), fe = h(() => {
324
- if (te.value === null) return !1;
325
- const x = new Date(te.value.replace(" ", "T"));
326
- return !Number.isNaN(x.valueOf()) && x.valueOf() > Date.now();
327
- }), Se = h(() => {
328
- const x = d.value;
329
- if (!x) return "";
330
- const L = u.short(x.published_at);
312
+ setup(h) {
313
+ const c = h, v = ne(), f = ue(v), a = Ge(), s = je(), t = lt(), o = pt();
314
+ te();
315
+ const i = Z("webx-blog"), d = Z("webx-admin"), w = he(), T = b(() => Number(a.params.id)), A = b(() => `${c.base}/articles`), y = M(null), S = M({}), z = M(""), E = M(""), R = M(null), x = M({ rubrics: [], authors: [] }), W = M([]), U = M(!0), I = M(!1), g = M(!1), B = M({}), D = M(null), H = M(""), me = M(0), Q = b(() => v.can("blog.articles.manage")), ke = b(() => !Q.value || g.value), X = b(() => JSON.stringify(S.value)), G = b(() => H.value !== "" && X.value !== H.value), $e = b(() => I.value ? "saving" : G.value ? "unsaved" : "saved"), ge = b(() => {
316
+ const m = S.value.title;
317
+ return $t(m, t.active.value, y.value?.title ?? "");
318
+ }), ce = b(() => {
319
+ const m = S.value.published_at;
320
+ return typeof m == "string" && m !== "" ? m : null;
321
+ }), fe = b(() => {
322
+ if (ce.value === null) return !1;
323
+ const m = new Date(ce.value.replace(" ", "T"));
324
+ return !Number.isNaN(m.valueOf()) && m.valueOf() > Date.now();
325
+ }), Se = b(() => {
326
+ const m = y.value;
327
+ if (!m) return "";
328
+ const O = o.short(m.published_at);
331
329
  return {
332
- scheduled: i("article.live-scheduled", { date: L }),
333
- published: i("article.live-since", { date: L }),
334
- modified: i("article.live-since", { date: L })
335
- }[x.status] ?? "";
330
+ scheduled: i("article.live-scheduled", { date: O }),
331
+ published: i("article.live-since", { date: O }),
332
+ modified: i("article.live-since", { date: O })
333
+ }[m.status] ?? "";
336
334
  });
337
- Vt({ url: h(() => D.value), reload: Z }), zt({
338
- article: d,
339
- values: W,
340
- options: B,
341
- related: w,
342
- prefix: z,
335
+ Ut({ url: b(() => R.value), reload: me }), qt({
336
+ article: y,
337
+ values: S,
338
+ options: x,
339
+ related: W,
340
+ prefix: E,
343
341
  base: c.base,
344
- canManage: Y.value,
345
- disabled: se,
346
- reload: () => oe(!0),
347
- save: () => A()
342
+ canManage: Q.value,
343
+ disabled: ke,
344
+ reload: () => se(!0),
345
+ save: () => k()
348
346
  });
349
- function $e(x) {
350
- d.value = x.article, W.value = x.values, V.value = x.revision, z.value = x.prefix, D.value = x.preview_url, B.value = x.options, w.value = x.related, E.value = JSON.stringify(x.values), P.value = null;
347
+ function be(m) {
348
+ y.value = m.article, S.value = m.values, z.value = m.revision, E.value = m.prefix, R.value = m.preview_url, x.value = m.options, W.value = m.related, H.value = JSON.stringify(m.values), D.value = null;
351
349
  }
352
- async function oe(x = !1) {
353
- x || (T.value = !0);
350
+ async function se(m = !1) {
351
+ m || (U.value = !0);
354
352
  try {
355
- $e(await f.get(y.value));
356
- } catch (L) {
357
- R.danger(m(L)), s.push($.value);
353
+ be(await f.get(T.value));
354
+ } catch (O) {
355
+ P.danger(w(O)), s.push(A.value);
358
356
  } finally {
359
- T.value = !1;
357
+ U.value = !1;
360
358
  }
361
359
  }
362
- let ce;
363
- function ae() {
364
- !Y.value || P.value || !O.value || (clearTimeout(ce), ce = setTimeout(() => {
365
- A();
366
- }, qt));
367
- }
360
+ let Y;
368
361
  function We() {
369
- !Y.value || P.value || !O.value || N.value || (clearTimeout(ce), A());
362
+ !Q.value || D.value || !G.value || (clearTimeout(Y), Y = setTimeout(() => {
363
+ k();
364
+ }, Dt));
370
365
  }
371
- let o;
372
- async function A() {
373
- for (; o; ) {
374
- const { carried: j, done: me } = o;
375
- if (await me, !O.value || P.value || re.value === j) return;
366
+ function u() {
367
+ !Q.value || D.value || !G.value || I.value || (clearTimeout(Y), k());
368
+ }
369
+ let V;
370
+ async function k() {
371
+ for (; V; ) {
372
+ const { carried: K, done: re } = V;
373
+ if (await re, !G.value || D.value || X.value === K) return;
376
374
  }
377
- const x = re.value, L = S();
378
- o = { carried: x, done: L };
375
+ const m = X.value, O = ae();
376
+ V = { carried: m, done: O };
379
377
  try {
380
- await L;
378
+ await O;
381
379
  } finally {
382
- o?.done === L && (o = void 0);
380
+ V?.done === O && (V = void 0);
383
381
  }
384
382
  }
385
- async function S() {
386
- if (!d.value || !Y.value) return;
387
- clearTimeout(ce);
388
- const x = re.value, L = W.value;
389
- N.value = !0, b.value = {};
383
+ async function ae() {
384
+ if (!y.value || !Q.value) return;
385
+ clearTimeout(Y);
386
+ const m = X.value, O = S.value;
387
+ I.value = !0, B.value = {};
390
388
  try {
391
- const j = await f.save(d.value.id, { values: L, revision: V.value });
392
- d.value = j.article, V.value = j.revision, z.value = j.prefix, D.value = j.preview_url, B.value = j.options, w.value = j.related, P.value = null, re.value === x && (E.value = x), Z.value += 1;
393
- } catch (j) {
394
- const me = j;
395
- me.status === 409 && me.body?.data ? P.value = me.body : me.body?.errors ? (b.value = me.body.errors, R.danger(i("article.save-failed"))) : R.danger(m(j));
389
+ const K = await f.save(y.value.id, { values: O, revision: z.value });
390
+ y.value = K.article, z.value = K.revision, E.value = K.prefix, R.value = K.preview_url, x.value = K.options, W.value = K.related, D.value = null, X.value === m && (H.value = m), me.value += 1;
391
+ } catch (K) {
392
+ const re = K;
393
+ re.status === 409 && re.body?.data ? D.value = re.body : re.body?.errors ? (B.value = re.body.errors, P.danger(i("article.save-failed"))) : P.danger(w(K));
396
394
  } finally {
397
- N.value = !1;
395
+ I.value = !1;
398
396
  }
399
397
  }
400
- async function ee() {
401
- await de({
398
+ async function n() {
399
+ await oe({
402
400
  title: i("article.conflict-theirs-title"),
403
401
  message: i("article.conflict-theirs-text"),
404
402
  confirmText: i("article.conflict-theirs"),
405
403
  cancelText: i("panel.cancel"),
406
404
  tone: "danger"
407
- }) && await oe(!0);
405
+ }) && await se(!0);
408
406
  }
409
- async function n() {
410
- const x = P.value;
411
- x && (V.value = x.data.revision, P.value = null, await A());
407
+ async function N() {
408
+ const m = D.value;
409
+ m && (z.value = m.data.revision, D.value = null, await k());
412
410
  }
413
- async function U() {
414
- if (!(!d.value || !await de({
415
- title: i("article.discard-title"),
416
- message: i("article.discard-text"),
411
+ async function p() {
412
+ if (!(!y.value || !await oe({
413
+ title: d("editor.discard-title"),
414
+ message: d("editor.discard-text"),
417
415
  confirmText: i("article.discard"),
418
- cancelText: i("panel.cancel"),
416
+ // Not «Cancel»: beside «Discard changes» the two read as the same word.
417
+ cancelText: d("editor.keep-changes"),
419
418
  tone: "danger"
420
419
  }))) {
421
- I.value = !0;
420
+ g.value = !0;
422
421
  try {
423
- $e(await f.discard(d.value.id)), R.success(i("article.discarded"));
424
- } catch (L) {
425
- R.danger(m(L));
422
+ be(await f.discard(y.value.id)), P.success(i("article.discarded"));
423
+ } catch (O) {
424
+ P.danger(w(O));
426
425
  } finally {
427
- I.value = !1;
426
+ g.value = !1;
428
427
  }
429
428
  }
430
429
  }
431
- async function p() {
432
- const x = d.value;
433
- if (!x) return;
434
- const L = x.path === null ? null : `/${x.path}`, j = te.value === null ? i("article.publish-now") : u.short(te.value);
435
- if (await de({
436
- title: i("article.publish-title", { title: x.title }),
437
- message: fe.value ? i("article.publish-later", { date: j }) : L === null ? i("article.publish-nowhere") : i("article.publish-text", { address: L }),
430
+ async function ye() {
431
+ if (G.value && await k(), D.value || G.value) return;
432
+ const m = y.value;
433
+ if (!m) return;
434
+ const O = m.next_path ?? m.path, K = m.next_path != null && m.path !== null ? ` ${d("editor.publish-moves", { old: `/${m.path}` })}` : "", re = O === null ? null : `/${O}`, ct = ce.value === null ? i("article.publish-now") : o.short(ce.value);
435
+ if (await oe({
436
+ title: i("article.publish-title", { title: m.title }),
437
+ message: fe.value ? i("article.publish-later", { date: ct }) : re === null ? i("article.publish-nowhere") : i("article.publish-text", { address: re }) + K,
438
438
  confirmText: fe.value ? i("article.schedule") : i("panel.publish"),
439
439
  cancelText: i("panel.cancel")
440
- }) && (O.value && await A(), !P.value)) {
441
- I.value = !0;
440
+ })) {
441
+ g.value = !0;
442
+ try {
443
+ await f.publish(m.id, ce.value), await se(!0), P.success(fe.value ? i("article.scheduled") : i("panel.published"));
444
+ } catch (dt) {
445
+ P.danger(w(dt));
446
+ } finally {
447
+ g.value = !1;
448
+ }
449
+ }
450
+ }
451
+ async function we() {
452
+ const m = y.value;
453
+ if (!(!m || !await oe({
454
+ title: d("editor.unpublish-title"),
455
+ message: d("editor.unpublish-text"),
456
+ confirmText: d("editor.unpublish"),
457
+ cancelText: d("editor.keep-published")
458
+ }))) {
459
+ g.value = !0;
442
460
  try {
443
- await f.publish(x.id, te.value), await oe(!0), R.success(fe.value ? i("article.scheduled") : i("panel.published"));
444
- } catch (ot) {
445
- R.danger(m(ot));
461
+ await f.unpublish(m.id), await se(!0), P.success(d("editor.unpublished"));
462
+ } catch (K) {
463
+ P.danger(w(K));
446
464
  } finally {
447
- I.value = !1;
465
+ g.value = !1;
448
466
  }
449
467
  }
450
468
  }
451
- function xe() {
452
- const x = d.value?.status;
453
- return x === "published" ? "success" : x === "modified" ? "warning" : x === "scheduled" ? "primary" : "default";
469
+ function ot() {
470
+ const m = y.value?.status;
471
+ return m === "published" ? "success" : m === "modified" ? "warning" : m === "scheduled" ? "primary" : "default";
454
472
  }
455
- function he(x) {
456
- O.value && x.preventDefault();
473
+ function Je(m) {
474
+ G.value && m.preventDefault();
457
475
  }
458
- ve(re, ae), ve(y, () => {
459
- oe();
460
- }), Ne(() => {
461
- oe(), window.addEventListener("beforeunload", he);
476
+ pe(X, We), pe(T, () => {
477
+ se();
478
+ }), Ue(() => {
479
+ se(), window.addEventListener("beforeunload", Je);
462
480
  }), Ke(() => {
463
- clearTimeout(ce), window.removeEventListener("beforeunload", he);
464
- }), Ct(async () => !O.value || !Y.value || (await A(), !O.value) ? !0 : await de({
481
+ clearTimeout(Y), window.removeEventListener("beforeunload", Je);
482
+ }), Nt(async () => !G.value || !Q.value || (await k(), !G.value) ? !0 : await oe({
465
483
  title: i("article.leave-title"),
466
484
  message: i("article.leave-text"),
467
485
  confirmText: i("article.leave"),
468
486
  cancelText: i("panel.cancel"),
469
487
  tone: "danger"
470
488
  }));
471
- const rt = h(() => {
472
- const x = [];
473
- return D.value && x.push({ key: "preview", label: i("article.preview"), icon: "eye", href: D.value }), d.value?.url && d.value.status !== "draft" && x.push({
489
+ const ut = b(() => {
490
+ const m = [];
491
+ return R.value && m.push({ key: "preview", label: i("article.preview"), icon: "eye", href: R.value }), y.value?.url && y.value.status !== "draft" && m.push({
474
492
  key: "site",
475
493
  label: i("panel.open-on-site"),
476
494
  icon: "link",
477
- href: d.value.url
478
- }), d.value?.status === "modified" && x.push({
495
+ href: y.value.url
496
+ }), Q.value && (y.value?.status === "published" || y.value?.status === "modified") && m.push({
497
+ key: "unpublish",
498
+ label: d("editor.unpublish"),
499
+ icon: "eye-off",
500
+ run: () => {
501
+ we();
502
+ }
503
+ }), y.value?.status === "modified" && m.push({
479
504
  key: "discard",
480
505
  label: i("article.discard"),
481
506
  icon: "refresh",
482
507
  danger: !0,
483
508
  menu: !0,
484
509
  run: () => {
485
- U();
510
+ p();
486
511
  }
487
- }), x;
512
+ }), m;
488
513
  });
489
- return (x, L) => (_(), H("div", {
514
+ return (m, O) => (_(), j("div", {
490
515
  class: "wx-article-editor",
491
- onFocusout: We
516
+ onFocusout: u
492
517
  }, [
493
- T.value || !d.value ? (_(), H(ke, { key: 0 }, [
518
+ U.value || !y.value ? (_(), j(_e, { key: 0 }, [
494
519
  r(e(Oe), {
495
520
  class: "wx-article-editor__ghost",
496
521
  title: "",
497
522
  rows: 1
498
523
  }),
499
- r(e(xt), null, {
524
+ r(e(Tt), null, {
500
525
  default: l(() => [
501
526
  r(e(Oe), { rows: 8 })
502
527
  ]),
503
528
  _: 1
504
529
  })
505
- ], 64)) : (_(), H(ke, { key: 1 }, [
506
- r(e(ct), {
530
+ ], 64)) : (_(), j(_e, { key: 1 }, [
531
+ r(e(vt), {
507
532
  divider: "",
508
- back: $.value,
533
+ back: A.value,
509
534
  "back-label": e(i)("module.articles"),
510
- title: we.value || e(i)("article.untitled"),
535
+ title: ge.value || e(i)("article.untitled"),
511
536
  subtitle: Se.value,
512
- actions: rt.value
537
+ actions: ut.value
513
538
  }, {
514
539
  trail: l(() => [
515
- r(e(_t), {
540
+ r(e(At), {
516
541
  size: "sm",
517
542
  label: e(i)("article.trail")
518
543
  }, {
519
544
  default: l(() => [
520
- r(e(Ze), {
545
+ r(e(Qe), {
521
546
  as: "router-link",
522
- to: $.value
547
+ to: A.value
523
548
  }, {
524
549
  default: l(() => [
525
- C(k(e(i)("module.articles")), 1)
550
+ C($(e(i)("module.articles")), 1)
526
551
  ]),
527
552
  _: 1
528
553
  }, 8, ["to"]),
529
- r(e(Ze), { current: "" }, {
554
+ r(e(Qe), { current: "" }, {
530
555
  default: l(() => [
531
- C(k(we.value || e(i)("article.untitled")), 1)
556
+ C($(ge.value || e(i)("article.untitled")), 1)
532
557
  ]),
533
558
  _: 1
534
559
  })
@@ -538,205 +563,205 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
538
563
  ]),
539
564
  "title-after": l(() => [
540
565
  r(e(ie), {
541
- type: xe(),
566
+ type: ot(),
542
567
  dot: ""
543
568
  }, {
544
569
  default: l(() => [
545
- C(k(e(i)(`panel.status-${d.value.status}`)), 1)
570
+ C($(e(i)(`panel.status-${y.value.status}`)), 1)
546
571
  ]),
547
572
  _: 1
548
573
  }, 8, ["type"]),
549
- d.value.status === "modified" ? (_(), q(e(ie), {
574
+ y.value.status === "modified" ? (_(), q(e(ie), {
550
575
  key: 0,
551
576
  type: "primary",
552
577
  round: ""
553
578
  }, {
554
579
  default: l(() => [
555
- C(k(e(i)("panel.edits")), 1)
580
+ C($(e(i)("panel.edits")), 1)
556
581
  ]),
557
582
  _: 1
558
- })) : K("", !0)
583
+ })) : L("", !0)
559
584
  ]),
560
585
  _: 1
561
586
  }, 8, ["back", "back-label", "title", "subtitle", "actions"]),
562
- P.value ? (_(), q(e(Ue), {
587
+ D.value ? (_(), q(e(Ne), {
563
588
  key: 0,
564
589
  type: "warning",
565
590
  title: e(i)("article.conflict-title"),
566
- description: P.value.message
591
+ description: D.value.message
567
592
  }, {
568
593
  actions: l(() => [
569
- r(e(G), {
594
+ r(e(J), {
570
595
  size: "sm",
571
596
  variant: "outline",
572
- onClick: ee
597
+ onClick: n
573
598
  }, {
574
599
  default: l(() => [
575
- C(k(e(i)("article.conflict-theirs")), 1)
600
+ C($(e(i)("article.conflict-theirs")), 1)
576
601
  ]),
577
602
  _: 1
578
603
  }),
579
- r(e(G), {
604
+ r(e(J), {
580
605
  size: "sm",
581
606
  type: "primary",
582
- onClick: n
607
+ onClick: N
583
608
  }, {
584
609
  default: l(() => [
585
- C(k(e(i)("article.conflict-mine")), 1)
610
+ C($(e(i)("article.conflict-mine")), 1)
586
611
  ]),
587
612
  _: 1
588
613
  })
589
614
  ]),
590
615
  _: 1
591
- }, 8, ["title", "description"])) : K("", !0),
592
- F("div", Nt, [
593
- r(e(dt), {
594
- modelValue: W.value,
595
- "onUpdate:modelValue": L[0] || (L[0] = (j) => W.value = j),
616
+ }, 8, ["title", "description"])) : L("", !0),
617
+ F("div", Rt, [
618
+ r(e(gt), {
619
+ modelValue: S.value,
620
+ "onUpdate:modelValue": O[0] || (O[0] = (K) => S.value = K),
596
621
  name: "blog.article-form",
597
- errors: b.value,
598
- disabled: se.value
622
+ errors: B.value,
623
+ disabled: ke.value
599
624
  }, null, 8, ["modelValue", "errors", "disabled"])
600
625
  ]),
601
- Y.value ? (_(), q(e(lt), { key: 1 }, {
626
+ Q.value ? (_(), q(e(it), { key: 1 }, {
602
627
  state: l(() => [
603
- r(e(pt), { state: ye.value }, null, 8, ["state"])
628
+ r(e(ft), { state: $e.value }, null, 8, ["state"])
604
629
  ]),
605
630
  default: l(() => [
606
- r(e(G), {
631
+ r(e(J), {
607
632
  variant: "outline",
608
- loading: N.value,
609
- disabled: !O.value,
610
- onClick: A
633
+ loading: I.value,
634
+ disabled: !G.value,
635
+ onClick: k
611
636
  }, {
612
637
  default: l(() => [
613
- C(k(e(i)("article.save")), 1)
638
+ C($(e(i)("article.save")), 1)
614
639
  ]),
615
640
  _: 1
616
641
  }, 8, ["loading", "disabled"]),
617
- r(e(G), {
642
+ r(e(J), {
618
643
  type: "primary",
619
- loading: I.value,
620
- disabled: d.value.status === "published" && !O.value,
621
- onClick: p
644
+ loading: g.value,
645
+ disabled: y.value.status === "published" && !G.value,
646
+ onClick: ye
622
647
  }, {
623
648
  default: l(() => [
624
- C(k(fe.value ? e(i)("article.schedule") : e(i)("panel.publish")), 1)
649
+ C($(fe.value ? e(i)("article.schedule") : e(i)("panel.publish")), 1)
625
650
  ]),
626
651
  _: 1
627
652
  }, 8, ["loading", "disabled"])
628
653
  ]),
629
654
  _: 1
630
- })) : K("", !0)
655
+ })) : L("", !0)
631
656
  ], 64))
632
657
  ], 32));
633
658
  }
634
- }), ge = (g, c) => {
635
- const v = g.__vccOpts || g;
659
+ }), ve = (h, c) => {
660
+ const v = h.__vccOpts || h;
636
661
  for (const [f, a] of c)
637
662
  v[f] = a;
638
663
  return v;
639
- }, Pt = /* @__PURE__ */ ge(It, [["__scopeId", "data-v-c8b3304e"]]), Rt = { class: "wx-article-history" }, Dt = { class: "wx-article-history__number" }, Bt = { class: "wx-article-history__who" }, Et = /* @__PURE__ */ Q({
664
+ }, Et = /* @__PURE__ */ ve(Bt, [["__scopeId", "data-v-98dc2b0f"]]), Ot = { class: "wx-article-history" }, Lt = { class: "wx-article-history__number" }, Ft = { class: "wx-article-history__who" }, Kt = /* @__PURE__ */ ee({
640
665
  name: "WxArticleHistory",
641
666
  __name: "ArticleHistory",
642
- setup(g) {
667
+ setup(h) {
643
668
  const c = ne(), v = ue(c), f = Ae();
644
- X();
645
- const a = J("webx-blog"), s = be(), t = M(null), u = M(!1), i = h(() => f?.article.value ?? null), m = h(() => c.can("blog.articles.manage")), y = h(
669
+ te();
670
+ const a = Z("webx-blog"), s = he(), t = M(null), o = M(!1), i = b(() => f?.article.value ?? null), d = b(() => c.can("blog.articles.manage")), w = b(
646
671
  () => i.value?.status === "published" || i.value?.status === "modified" ? t.value?.[0]?.number ?? null : null
647
672
  );
648
- async function $() {
649
- const W = i.value;
650
- if (W)
673
+ async function T() {
674
+ const y = i.value;
675
+ if (y)
651
676
  try {
652
- t.value = await v.versions(W.id);
653
- } catch (V) {
654
- t.value = [], R.danger(s(V));
677
+ t.value = await v.versions(y.id);
678
+ } catch (S) {
679
+ t.value = [], P.danger(s(S));
655
680
  }
656
681
  }
657
- async function d(W) {
658
- const V = i.value;
659
- if (!(!V || !await de({
660
- title: a("article.restore-title", { number: W.number }),
682
+ async function A(y) {
683
+ const S = i.value;
684
+ if (!(!S || !await oe({
685
+ title: a("article.restore-title", { number: y.number }),
661
686
  message: a("article.restore-text"),
662
687
  confirmText: a("article.restore-version"),
663
688
  cancelText: a("panel.cancel")
664
689
  }))) {
665
- u.value = !0;
690
+ o.value = !0;
666
691
  try {
667
- await v.restoreVersion(V.id, W.number), await f?.reload(), R.success(a("article.restored-version", { number: W.number }));
668
- } catch (D) {
669
- R.danger(s(D));
692
+ await v.restoreVersion(S.id, y.number), await f?.reload(), P.success(a("article.restored-version", { number: y.number }));
693
+ } catch (E) {
694
+ P.danger(s(E));
670
695
  } finally {
671
- u.value = !1;
696
+ o.value = !1;
672
697
  }
673
698
  }
674
699
  }
675
- return ve(
700
+ return pe(
676
701
  () => [i.value?.id, i.value?.published_at, i.value?.updated_at],
677
702
  () => {
678
- $();
703
+ T();
679
704
  },
680
705
  { immediate: !0 }
681
- ), (W, V) => (_(), H("div", Rt, [
706
+ ), (y, S) => (_(), j("div", Ot, [
682
707
  t.value === null ? (_(), q(e(Oe), {
683
708
  key: 0,
684
709
  class: "wx-article-history__ghost",
685
710
  rows: 3
686
- })) : t.value.length === 0 ? (_(), q(e(kt), {
711
+ })) : t.value.length === 0 ? (_(), q(e(St), {
687
712
  key: 1,
688
713
  description: e(a)("article.history-empty")
689
- }, null, 8, ["description"])) : (_(!0), H(ke, { key: 2 }, qe(t.value, (z) => (_(), H("div", {
714
+ }, null, 8, ["description"])) : (_(!0), j(_e, { key: 2 }, qe(t.value, (z) => (_(), j("div", {
690
715
  key: z.number,
691
- class: tt(["wx-article-history__row", { "is-live": z.number === y.value }])
716
+ class: at(["wx-article-history__row", { "is-live": z.number === w.value }])
692
717
  }, [
693
- F("code", Dt, k(e(a)("article.version", { number: z.number })), 1),
694
- F("div", Bt, [
718
+ F("code", Lt, $(e(a)("article.version", { number: z.number })), 1),
719
+ F("div", Ft, [
695
720
  z.created_at ? (_(), q(e(Ee), {
696
721
  key: 0,
697
722
  value: z.created_at,
698
723
  size: "md",
699
724
  tone: "default"
700
- }, null, 8, ["value"])) : K("", !0),
725
+ }, null, 8, ["value"])) : L("", !0),
701
726
  r(e(le), {
702
727
  size: "sm",
703
728
  tone: "muted"
704
729
  }, {
705
730
  default: l(() => [
706
- C(k(z.author ?? e(a)(`article.source-${z.source}`)) + " ", 1),
707
- z.comment ? (_(), H(ke, { key: 0 }, [
708
- C(" · " + k(z.comment), 1)
709
- ], 64)) : K("", !0)
731
+ C($(z.author ?? e(a)(`article.source-${z.source}`)) + " ", 1),
732
+ z.comment ? (_(), j(_e, { key: 0 }, [
733
+ C(" · " + $(z.comment), 1)
734
+ ], 64)) : L("", !0)
710
735
  ]),
711
736
  _: 2
712
737
  }, 1024)
713
738
  ]),
714
- z.number === y.value ? (_(), q(e(ie), {
739
+ z.number === w.value ? (_(), q(e(ie), {
715
740
  key: 0,
716
741
  type: "success",
717
742
  dot: ""
718
743
  }, {
719
744
  default: l(() => [
720
- C(k(e(a)("article.version-live")), 1)
745
+ C($(e(a)("article.version-live")), 1)
721
746
  ]),
722
747
  _: 1
723
- })) : K("", !0),
724
- m.value && z.number !== y.value ? (_(), q(e(G), {
748
+ })) : L("", !0),
749
+ d.value && z.number !== w.value ? (_(), q(e(J), {
725
750
  key: 1,
726
751
  size: "sm",
727
752
  variant: "outline",
728
- loading: u.value,
729
- onClick: (D) => d(z)
753
+ loading: o.value,
754
+ onClick: (E) => A(z)
730
755
  }, {
731
756
  default: l(() => [
732
- C(k(e(a)("article.restore-version")), 1)
757
+ C($(e(a)("article.restore-version")), 1)
733
758
  ]),
734
759
  _: 1
735
- }, 8, ["loading", "onClick"])) : K("", !0)
760
+ }, 8, ["loading", "onClick"])) : L("", !0)
736
761
  ], 2))), 128))
737
762
  ]));
738
763
  }
739
- }), Ot = /* @__PURE__ */ ge(Et, [["__scopeId", "data-v-0a997938"]]), Lt = { class: "wx-article-related" }, Ft = { class: "wx-article-related__name" }, Kt = 250, Ht = 10, Gt = /* @__PURE__ */ Q({
764
+ }), Ht = /* @__PURE__ */ ve(Kt, [["__scopeId", "data-v-0a997938"]]), Gt = { class: "wx-article-related" }, jt = { class: "wx-article-related__name" }, Jt = 250, Zt = 10, Qt = /* @__PURE__ */ ee({
740
765
  name: "WxArticleRelated",
741
766
  __name: "ArticleRelated",
742
767
  props: /* @__PURE__ */ Fe({
@@ -746,61 +771,61 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
746
771
  modelModifiers: {}
747
772
  }),
748
773
  emits: ["update:modelValue"],
749
- setup(g) {
750
- const c = g, v = Le(g, "modelValue"), f = ne(), a = ue(f), s = Ae();
751
- X();
752
- const t = J("webx-blog"), u = be(), i = h(() => c.disabled || s?.disabled.value === !0), m = M(/* @__PURE__ */ new Map()), y = M([]);
753
- let $;
754
- ve(
774
+ setup(h) {
775
+ const c = h, v = Le(h, "modelValue"), f = ne(), a = ue(f), s = Ae();
776
+ te();
777
+ const t = Z("webx-blog"), o = he(), i = b(() => c.disabled || s?.disabled.value === !0), d = M(/* @__PURE__ */ new Map()), w = M([]);
778
+ let T;
779
+ pe(
755
780
  () => s?.related.value,
756
- (w) => {
757
- const T = new Map(m.value);
758
- for (const N of w ?? []) T.set(N.id, N.title);
759
- m.value = T;
781
+ (x) => {
782
+ const W = new Map(d.value);
783
+ for (const U of x ?? []) W.set(U.id, U.title);
784
+ d.value = W;
760
785
  },
761
786
  { immediate: !0, deep: !0 }
762
787
  );
763
- const d = h({
764
- get: () => v.value.map((w) => ({ id: w, title: m.value.get(w) ?? `#${w}` })),
765
- set: (w) => {
766
- v.value = w.map((T) => T.id);
788
+ const A = b({
789
+ get: () => v.value.map((x) => ({ id: x, title: d.value.get(x) ?? `#${x}` })),
790
+ set: (x) => {
791
+ v.value = x.map((W) => W.id);
767
792
  }
768
- }), W = h(
769
- () => y.value.filter((w) => !v.value.includes(w.id)).map((w) => ({ label: w.title, value: w.id }))
793
+ }), y = b(
794
+ () => w.value.filter((x) => !v.value.includes(x.id)).map((x) => ({ label: x.title, value: x.id }))
770
795
  );
771
- async function V(w) {
772
- const T = s?.article.value?.id;
796
+ async function S(x) {
797
+ const W = s?.article.value?.id;
773
798
  try {
774
- const N = await a.articles({ q: w, per_page: Ht });
775
- y.value = N.data.filter((b) => b.id !== T).map((b) => ({ id: b.id, title: b.title }));
776
- const I = new Map(m.value);
777
- for (const b of y.value) I.set(b.id, b.title);
778
- m.value = I;
779
- } catch (N) {
780
- R.danger(u(N));
799
+ const U = await a.articles({ q: x, per_page: Zt });
800
+ w.value = U.data.filter((g) => g.id !== W).map((g) => ({ id: g.id, title: g.title }));
801
+ const I = new Map(d.value);
802
+ for (const g of w.value) I.set(g.id, g.title);
803
+ d.value = I;
804
+ } catch (U) {
805
+ P.danger(o(U));
781
806
  }
782
807
  }
783
- function z(w) {
784
- clearTimeout($), $ = setTimeout(() => {
785
- V(w);
786
- }, Kt);
808
+ function z(x) {
809
+ clearTimeout(T), T = setTimeout(() => {
810
+ S(x);
811
+ }, Jt);
787
812
  }
788
- function D(w) {
789
- typeof w != "number" || v.value.includes(w) || (v.value = [...v.value, w]);
813
+ function E(x) {
814
+ typeof x != "number" || v.value.includes(x) || (v.value = [...v.value, x]);
790
815
  }
791
- function B(w) {
792
- v.value = v.value.filter((T) => T !== w);
816
+ function R(x) {
817
+ v.value = v.value.filter((W) => W !== x);
793
818
  }
794
- return ve(
819
+ return pe(
795
820
  () => s?.article.value?.id,
796
821
  () => {
797
- V("");
822
+ S("");
798
823
  },
799
824
  { immediate: !0 }
800
- ), Ke(() => clearTimeout($)), (w, T) => (_(), H("div", Lt, [
801
- r(e($t), {
802
- modelValue: d.value,
803
- "onUpdate:modelValue": T[0] || (T[0] = (N) => d.value = N),
825
+ ), Ke(() => clearTimeout(T)), (x, W) => (_(), j("div", Gt, [
826
+ r(e(Wt), {
827
+ modelValue: A.value,
828
+ "onUpdate:modelValue": W[0] || (W[0] = (U) => A.value = U),
804
829
  plain: "",
805
830
  size: "sm",
806
831
  "item-key": "id",
@@ -809,23 +834,23 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
809
834
  "empty-text": e(t)("article.related-empty"),
810
835
  "aria-label": e(t)("article.related")
811
836
  }, {
812
- default: l(({ item: N }) => [
813
- F("span", Ft, k(N.title), 1)
837
+ default: l(({ item: U }) => [
838
+ F("span", jt, $(U.title), 1)
814
839
  ]),
815
- actions: l(({ item: N }) => [
816
- r(e(Tt), {
840
+ actions: l(({ item: U }) => [
841
+ r(e(Ct), {
817
842
  type: "remove",
818
843
  size: "sm",
819
844
  disabled: i.value,
820
845
  title: e(t)("article.related-remove"),
821
- onClick: (I) => B(N.id)
846
+ onClick: (I) => R(U.id)
822
847
  }, null, 8, ["disabled", "title", "onClick"])
823
848
  ]),
824
849
  _: 1
825
850
  }, 8, ["modelValue", "disabled", "empty-text", "aria-label"]),
826
- r(e(_e), {
851
+ r(e(xe), {
827
852
  "model-value": null,
828
- options: W.value,
853
+ options: y.value,
829
854
  placeholder: e(t)("article.related-add"),
830
855
  "empty-text": e(t)("article.related-nothing"),
831
856
  disabled: i.value,
@@ -833,46 +858,46 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
833
858
  teleport: "",
834
859
  "aria-label": e(t)("article.related-add"),
835
860
  onSearch: z,
836
- "onUpdate:modelValue": D
861
+ "onUpdate:modelValue": E
837
862
  }, null, 8, ["options", "placeholder", "empty-text", "disabled", "aria-label"])
838
863
  ]));
839
864
  }
840
- }), jt = /* @__PURE__ */ ge(Gt, [["__scopeId", "data-v-164e86fe"]]), Jt = { class: "wx-article-slug" }, Zt = { class: "wx-article-slug__prefix" }, Qt = /* @__PURE__ */ Q({
865
+ }), Xt = /* @__PURE__ */ ve(Qt, [["__scopeId", "data-v-164e86fe"]]), Yt = { class: "wx-article-slug" }, ea = { class: "wx-article-slug__prefix" }, ta = /* @__PURE__ */ ee({
841
866
  name: "WxArticleSlug",
842
867
  inheritAttrs: !1,
843
868
  __name: "ArticleSlug",
844
- setup(g) {
845
- const c = Ae(), v = at();
846
- X();
847
- const f = J("webx-blog"), a = h(() => {
848
- const u = c?.prefix.value ?? "";
849
- return u === "" ? "/" : `/${u}/`;
850
- }), s = h(() => {
851
- const u = c?.values.value.slug;
852
- return typeof u == "string" ? u : u?.[v.active.value] ?? "";
853
- }), t = h(() => {
854
- const u = c?.article.value?.path;
855
- return typeof u == "string" && s.value !== "" && `${a.value}${s.value}` != `/${u}`;
869
+ setup(h) {
870
+ const c = Ae(), v = lt();
871
+ te();
872
+ const f = Z("webx-blog"), a = b(() => {
873
+ const o = c?.prefix.value ?? "";
874
+ return o === "" ? "/" : `/${o}/`;
875
+ }), s = b(() => {
876
+ const o = c?.values.value.slug;
877
+ return typeof o == "string" ? o : o?.[v.active.value] ?? "";
878
+ }), t = b(() => {
879
+ const o = c?.article.value?.path;
880
+ return typeof o == "string" && s.value !== "" && `${a.value}${s.value}` != `/${o}`;
856
881
  });
857
- return (u, i) => (_(), H("div", Jt, [
858
- r(e(Ce), mt(bt(u.$attrs)), {
882
+ return (o, i) => (_(), j("div", Yt, [
883
+ r(e(Ce), xt(_t(o.$attrs)), {
859
884
  prefix: l(() => [
860
- F("span", Zt, k(a.value), 1)
885
+ F("span", ea, $(a.value), 1)
861
886
  ]),
862
887
  _: 1
863
888
  }, 16),
864
- t.value ? (_(), q(e(Ue), {
889
+ t.value ? (_(), q(e(Ne), {
865
890
  key: 0,
866
891
  type: "info",
867
892
  variant: "soft",
868
893
  description: e(f)("article.address-moving")
869
- }, null, 8, ["description"])) : K("", !0)
894
+ }, null, 8, ["description"])) : L("", !0)
870
895
  ]));
871
896
  }
872
- }), Xt = /* @__PURE__ */ ge(Qt, [["__scopeId", "data-v-5da20e5e"]]), Yt = { class: "wx-article-tags" }, ea = {
897
+ }), aa = /* @__PURE__ */ ve(ta, [["__scopeId", "data-v-5da20e5e"]]), la = { class: "wx-article-tags" }, ia = {
873
898
  key: 0,
874
899
  class: "wx-article-tags__chips"
875
- }, ta = { class: "wx-article-tags__pick" }, aa = 250, la = /* @__PURE__ */ Q({
900
+ }, na = { class: "wx-article-tags__pick" }, sa = 250, ra = /* @__PURE__ */ ee({
876
901
  name: "WxArticleTags",
877
902
  __name: "ArticleTags",
878
903
  props: /* @__PURE__ */ Fe({
@@ -882,87 +907,87 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
882
907
  modelModifiers: {}
883
908
  }),
884
909
  emits: ["update:modelValue"],
885
- setup(g) {
886
- const c = g, v = Le(g, "modelValue"), f = ne(), a = ue(f), s = Ae();
887
- X();
888
- const t = J("webx-blog"), u = be(), i = h(() => c.disabled || s?.disabled.value === !0), m = M(/* @__PURE__ */ new Map()), y = M([]), $ = M(""), d = M(!1);
889
- let W;
890
- ve(
910
+ setup(h) {
911
+ const c = h, v = Le(h, "modelValue"), f = ne(), a = ue(f), s = Ae();
912
+ te();
913
+ const t = Z("webx-blog"), o = he(), i = b(() => c.disabled || s?.disabled.value === !0), d = M(/* @__PURE__ */ new Map()), w = M([]), T = M(""), A = M(!1);
914
+ let y;
915
+ pe(
891
916
  () => s?.article.value?.tags,
892
- (b) => {
893
- const P = new Map(m.value);
894
- for (const E of b ?? []) P.set(E.id, E.title);
895
- m.value = P;
917
+ (g) => {
918
+ const B = new Map(d.value);
919
+ for (const D of g ?? []) B.set(D.id, D.title);
920
+ d.value = B;
896
921
  },
897
922
  { immediate: !0, deep: !0 }
898
923
  );
899
- const V = h(
900
- () => v.value.map((b) => ({ id: b, title: m.value.get(b) ?? `#${b}` }))
901
- ), z = h(
902
- () => y.value.filter((b) => !v.value.includes(b.id)).map((b) => ({
924
+ const S = b(
925
+ () => v.value.map((g) => ({ id: g, title: d.value.get(g) ?? `#${g}` }))
926
+ ), z = b(
927
+ () => w.value.filter((g) => !v.value.includes(g.id)).map((g) => ({
903
928
  // The count is part of the label rather than a column: a select draws a line of text, and
904
929
  // the number is what the reader is choosing between two near-identical words on.
905
- label: t("article.tag-option", { title: b.title, count: b.articles_count }),
906
- value: b.id
930
+ label: t("article.tag-option", { title: g.title, count: g.articles_count }),
931
+ value: g.id
907
932
  }))
908
- ), D = h(() => {
909
- const b = $.value.trim();
910
- if (b === "") return null;
911
- const P = (E) => E.toLowerCase() === b.toLowerCase();
912
- return y.value.some((E) => P(E.title)) ? null : b;
933
+ ), E = b(() => {
934
+ const g = T.value.trim();
935
+ if (g === "") return null;
936
+ const B = (D) => D.toLowerCase() === g.toLowerCase();
937
+ return w.value.some((D) => B(D.title)) ? null : g;
913
938
  });
914
- async function B() {
939
+ async function R() {
915
940
  try {
916
- y.value = await a.tags($.value);
917
- const b = new Map(m.value);
918
- for (const P of y.value) b.set(P.id, P.title);
919
- m.value = b;
920
- } catch (b) {
921
- R.danger(u(b));
941
+ w.value = await a.tags(T.value);
942
+ const g = new Map(d.value);
943
+ for (const B of w.value) g.set(B.id, B.title);
944
+ d.value = g;
945
+ } catch (g) {
946
+ P.danger(o(g));
922
947
  }
923
948
  }
924
- function w(b) {
925
- $.value = b, clearTimeout(W), W = setTimeout(() => {
926
- B();
927
- }, aa);
949
+ function x(g) {
950
+ T.value = g, clearTimeout(y), y = setTimeout(() => {
951
+ R();
952
+ }, sa);
928
953
  }
929
- function T(b) {
930
- typeof b != "number" || v.value.includes(b) || (v.value = [...v.value, b], $.value = "");
954
+ function W(g) {
955
+ typeof g != "number" || v.value.includes(g) || (v.value = [...v.value, g], T.value = "");
931
956
  }
932
- function N(b) {
933
- v.value = v.value.filter((P) => P !== b);
957
+ function U(g) {
958
+ v.value = v.value.filter((B) => B !== g);
934
959
  }
935
960
  async function I() {
936
- const b = D.value;
937
- if (!(b === null || d.value)) {
938
- d.value = !0;
961
+ const g = E.value;
962
+ if (!(g === null || A.value)) {
963
+ A.value = !0;
939
964
  try {
940
- const P = await a.createTag({ title: b });
941
- m.value = new Map(m.value).set(P.id, P.title), y.value = [P, ...y.value], T(P.id);
942
- } catch (P) {
943
- R.danger(u(P));
965
+ const B = await a.createTag({ title: g });
966
+ d.value = new Map(d.value).set(B.id, B.title), w.value = [B, ...w.value], W(B.id);
967
+ } catch (B) {
968
+ P.danger(o(B));
944
969
  } finally {
945
- d.value = !1;
970
+ A.value = !1;
946
971
  }
947
972
  }
948
973
  }
949
- return ve(
974
+ return pe(
950
975
  () => s?.article.value?.id,
951
976
  () => {
952
- B();
977
+ R();
953
978
  },
954
979
  { immediate: !0 }
955
- ), Ke(() => clearTimeout(W)), (b, P) => (_(), H("div", Yt, [
956
- V.value.length > 0 ? (_(), H("div", ea, [
957
- (_(!0), H(ke, null, qe(V.value, (E) => (_(), q(e(ie), {
958
- key: E.id,
980
+ ), Ke(() => clearTimeout(y)), (g, B) => (_(), j("div", la, [
981
+ S.value.length > 0 ? (_(), j("div", ia, [
982
+ (_(!0), j(_e, null, qe(S.value, (D) => (_(), q(e(ie), {
983
+ key: D.id,
959
984
  type: "default",
960
985
  closable: !i.value,
961
986
  "close-label": e(t)("article.tag-remove"),
962
- onClose: (Z) => N(E.id)
987
+ onClose: (H) => U(D.id)
963
988
  }, {
964
989
  default: l(() => [
965
- C(k(E.title), 1)
990
+ C($(D.title), 1)
966
991
  ]),
967
992
  _: 2
968
993
  }, 1032, ["closable", "close-label", "onClose"]))), 128))
@@ -972,12 +997,12 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
972
997
  tone: "muted"
973
998
  }, {
974
999
  default: l(() => [
975
- C(k(e(t)("article.tags-empty")), 1)
1000
+ C($(e(t)("article.tags-empty")), 1)
976
1001
  ]),
977
1002
  _: 1
978
1003
  })),
979
- F("div", ta, [
980
- r(e(_e), {
1004
+ F("div", na, [
1005
+ r(e(xe), {
981
1006
  "model-value": null,
982
1007
  options: z.value,
983
1008
  placeholder: e(t)("article.tag-add"),
@@ -986,124 +1011,124 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
986
1011
  filterable: "",
987
1012
  teleport: "",
988
1013
  "aria-label": e(t)("article.tag-add"),
989
- onSearch: w,
990
- "onUpdate:modelValue": T
1014
+ onSearch: x,
1015
+ "onUpdate:modelValue": W
991
1016
  }, null, 8, ["options", "placeholder", "empty-text", "disabled", "aria-label"]),
992
- D.value ? (_(), q(e(G), {
1017
+ E.value ? (_(), q(e(J), {
993
1018
  key: 0,
994
1019
  variant: "outline",
995
1020
  icon: "plus",
996
- loading: d.value,
1021
+ loading: A.value,
997
1022
  disabled: i.value,
998
1023
  onClick: I
999
1024
  }, {
1000
1025
  default: l(() => [
1001
- C(k(e(t)("article.tag-create", { title: D.value })), 1)
1026
+ C($(e(t)("article.tag-create", { title: E.value })), 1)
1002
1027
  ]),
1003
1028
  _: 1
1004
- }, 8, ["loading", "disabled"])) : K("", !0)
1029
+ }, 8, ["loading", "disabled"])) : L("", !0)
1005
1030
  ])
1006
1031
  ]));
1007
1032
  }
1008
- }), ia = /* @__PURE__ */ ge(la, [["__scopeId", "data-v-faf5adec"]]), na = /* @__PURE__ */ Q({
1033
+ }), oa = /* @__PURE__ */ ve(ra, [["__scopeId", "data-v-faf5adec"]]), ua = /* @__PURE__ */ ee({
1009
1034
  name: "WxArticleUnpublish",
1010
1035
  __name: "ArticleUnpublish",
1011
- setup(g) {
1036
+ setup(h) {
1012
1037
  const c = ne(), v = ue(c), f = Ae();
1013
- X();
1014
- const a = J("webx-blog"), s = be(), t = M(!1), u = h(() => {
1015
- const y = f?.article.value?.status;
1016
- return y === "published" || y === "modified" || y === "scheduled";
1017
- }), i = h(() => f?.disabled.value === !0 || t.value);
1018
- async function m() {
1019
- const y = f?.article.value;
1020
- if (!(!y || !await de({
1021
- title: a("article.unpublish-title", { title: y.title }),
1022
- message: y.status === "scheduled" ? a("article.unpublish-waiting") : a("article.unpublish-text"),
1038
+ te();
1039
+ const a = Z("webx-blog"), s = he(), t = M(!1), o = b(() => {
1040
+ const w = f?.article.value?.status;
1041
+ return w === "published" || w === "modified" || w === "scheduled";
1042
+ }), i = b(() => f?.disabled.value === !0 || t.value);
1043
+ async function d() {
1044
+ const w = f?.article.value;
1045
+ if (!(!w || !await oe({
1046
+ title: a("article.unpublish-title", { title: w.title }),
1047
+ message: w.status === "scheduled" ? a("article.unpublish-waiting") : a("article.unpublish-text"),
1023
1048
  confirmText: a("panel.unpublish"),
1024
1049
  cancelText: a("panel.cancel"),
1025
1050
  tone: "danger"
1026
1051
  }))) {
1027
1052
  t.value = !0;
1028
1053
  try {
1029
- await v.unpublish(y.id), await f?.reload(), R.success(a("panel.unpublished-done"));
1030
- } catch (d) {
1031
- R.danger(s(d));
1054
+ await v.unpublish(w.id), await f?.reload(), P.success(a("panel.unpublished-done"));
1055
+ } catch (A) {
1056
+ P.danger(s(A));
1032
1057
  } finally {
1033
1058
  t.value = !1;
1034
1059
  }
1035
1060
  }
1036
1061
  }
1037
- return (y, $) => u.value && e(f)?.canManage ? (_(), q(e(pe), {
1062
+ return (w, T) => o.value && e(f)?.canManage ? (_(), q(e(de), {
1038
1063
  key: 0,
1039
1064
  class: "wx-article-unpublish",
1040
1065
  help: e(a)("article.unpublish-help")
1041
1066
  }, {
1042
1067
  default: l(() => [
1043
- r(e(G), {
1068
+ r(e(J), {
1044
1069
  variant: "outline",
1045
1070
  type: "danger",
1046
1071
  icon: "eye-off",
1047
1072
  loading: t.value,
1048
1073
  disabled: i.value,
1049
- onClick: m
1074
+ onClick: d
1050
1075
  }, {
1051
1076
  default: l(() => [
1052
- C(k(e(a)("panel.unpublish")), 1)
1077
+ C($(e(a)("panel.unpublish")), 1)
1053
1078
  ]),
1054
1079
  _: 1
1055
1080
  }, 8, ["loading", "disabled"])
1056
1081
  ]),
1057
1082
  _: 1
1058
- }, 8, ["help"])) : K("", !0);
1083
+ }, 8, ["help"])) : L("", !0);
1059
1084
  }
1060
- }), sa = /* @__PURE__ */ ge(na, [["__scopeId", "data-v-c311cff2"]]), ra = /* @__PURE__ */ Q({
1085
+ }), ca = /* @__PURE__ */ ve(ua, [["__scopeId", "data-v-c311cff2"]]), da = /* @__PURE__ */ ee({
1061
1086
  __name: "ArticleCreateDialog",
1062
- setup(g) {
1087
+ setup(h) {
1063
1088
  const { open: c, resolve: v, dismiss: f } = Re(), a = ne(), s = ue(a);
1064
- X();
1065
- const t = J("webx-blog"), u = M(""), i = M(!1), m = M({}), y = Ie("field");
1066
- Ne(async () => {
1067
- await He(), y.value?.querySelector("input")?.focus();
1089
+ te();
1090
+ const t = Z("webx-blog"), o = M(""), i = M(!1), d = M({}), w = Ie("field");
1091
+ Ue(async () => {
1092
+ await He(), w.value?.querySelector("input")?.focus();
1068
1093
  });
1069
- async function $() {
1070
- if (!(u.value.trim() === "" || i.value)) {
1071
- i.value = !0, m.value = {};
1094
+ async function T() {
1095
+ if (!(o.value.trim() === "" || i.value)) {
1096
+ i.value = !0, d.value = {};
1072
1097
  try {
1073
- v(await s.create({ title: u.value.trim() }));
1074
- } catch (d) {
1075
- m.value = d.body?.errors ?? {};
1098
+ v(await s.create({ title: o.value.trim() }));
1099
+ } catch (A) {
1100
+ d.value = A.body?.errors ?? {};
1076
1101
  } finally {
1077
1102
  i.value = !1;
1078
1103
  }
1079
1104
  }
1080
1105
  }
1081
- return (d, W) => (_(), q(e(De), {
1106
+ return (A, y) => (_(), q(e(De), {
1082
1107
  open: e(c),
1083
- "onUpdate:open": W[2] || (W[2] = (V) => Pe(c) ? c.value = V : null),
1108
+ "onUpdate:open": y[2] || (y[2] = (S) => Pe(c) ? c.value = S : null),
1084
1109
  title: e(t)("panel.new-title"),
1085
1110
  width: 440
1086
1111
  }, {
1087
1112
  footer: l(() => [
1088
1113
  r(e(Be), { size: "sm" }, {
1089
1114
  default: l(() => [
1090
- r(e(G), {
1115
+ r(e(J), {
1091
1116
  variant: "outline",
1092
- onClick: W[1] || (W[1] = (V) => e(f)())
1117
+ onClick: y[1] || (y[1] = (S) => e(f)())
1093
1118
  }, {
1094
1119
  default: l(() => [
1095
- C(k(e(t)("panel.cancel")), 1)
1120
+ C($(e(t)("panel.cancel")), 1)
1096
1121
  ]),
1097
1122
  _: 1
1098
1123
  }),
1099
- r(e(G), {
1124
+ r(e(J), {
1100
1125
  type: "primary",
1101
1126
  loading: i.value,
1102
- disabled: u.value.trim() === "",
1103
- onClick: $
1127
+ disabled: o.value.trim() === "",
1128
+ onClick: T
1104
1129
  }, {
1105
1130
  default: l(() => [
1106
- C(k(e(t)("panel.create")), 1)
1131
+ C($(e(t)("panel.create")), 1)
1107
1132
  ]),
1108
1133
  _: 1
1109
1134
  }, 8, ["loading", "disabled"])
@@ -1112,21 +1137,21 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1112
1137
  })
1113
1138
  ]),
1114
1139
  default: l(() => [
1115
- r(e(pe), {
1140
+ r(e(de), {
1116
1141
  label: e(t)("panel.field-title"),
1117
- error: m.value.title?.[0] ?? m.value.slug?.[0],
1142
+ error: d.value.title?.[0] ?? d.value.slug?.[0],
1118
1143
  required: ""
1119
1144
  }, {
1120
1145
  default: l(() => [
1121
1146
  F("div", {
1122
1147
  ref_key: "field",
1123
- ref: y
1148
+ ref: w
1124
1149
  }, [
1125
1150
  r(e(Ce), {
1126
- modelValue: u.value,
1127
- "onUpdate:modelValue": W[0] || (W[0] = (V) => u.value = V),
1151
+ modelValue: o.value,
1152
+ "onUpdate:modelValue": y[0] || (y[0] = (S) => o.value = S),
1128
1153
  "aria-label": e(t)("panel.field-title"),
1129
- onKeyup: Me($, ["enter"])
1154
+ onKeyup: Me(T, ["enter"])
1130
1155
  }, null, 8, ["modelValue", "aria-label"])
1131
1156
  ], 512)
1132
1157
  ]),
@@ -1136,42 +1161,42 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1136
1161
  _: 1
1137
1162
  }, 8, ["open", "title"]));
1138
1163
  }
1139
- }), oa = ["src"], ua = { class: "wx-articles__name" }, ca = { class: "wx-articles__name-text" }, da = { class: "wx-articles__title" }, pa = { class: "wx-articles__address" }, va = { class: "wx-articles__chips" }, ga = { class: "wx-articles__state" }, Xe = 640, fa = /* @__PURE__ */ Q({
1164
+ }), pa = ["src"], va = { class: "wx-articles__name" }, ga = { class: "wx-articles__name-text" }, fa = { class: "wx-articles__title" }, ha = { class: "wx-articles__address" }, ma = { class: "wx-articles__chips" }, ba = { class: "wx-articles__state" }, Ye = 640, ya = /* @__PURE__ */ ee({
1140
1165
  __name: "ArticlesPage",
1141
1166
  props: {
1142
1167
  base: { default: "/blog" }
1143
1168
  },
1144
- setup(g) {
1145
- const c = g, v = ne(), f = ue(v), a = Ge(), s = je();
1146
- X();
1147
- const t = J("webx-blog"), u = J("webx-admin"), i = be(), m = Ie("root"), y = At(m), $ = M(null), d = M(!0), W = Ve(ra), V = h(() => v.can("blog.articles.manage")), z = h(
1169
+ setup(h) {
1170
+ const c = h, v = ne(), f = ue(v), a = Ge(), s = je();
1171
+ te();
1172
+ const t = Z("webx-blog"), o = Z("webx-admin"), i = he(), d = Ie("root"), w = Vt(d), T = M(null), A = M(!0), y = Ve(da), S = b(() => v.can("blog.articles.manage")), z = b(
1148
1173
  () => v.state.manifest?.modules.find((n) => n.id === "articles")?.title ?? t("module.articles")
1149
- ), D = h({
1174
+ ), E = b({
1150
1175
  get: () => typeof a.query.view == "string" ? a.query.view : "",
1151
1176
  set: (n) => {
1152
1177
  s.replace({
1153
1178
  query: { ...a.query, view: n === "" ? void 0 : String(n), page: void 0 }
1154
1179
  });
1155
1180
  }
1156
- }), B = h(() => D.value === "trashed"), w = h(() => ({
1181
+ }), R = b(() => E.value === "trashed"), x = b(() => ({
1157
1182
  q: typeof a.query.q == "string" ? a.query.q : "",
1158
- rubric: T(a.query.rubric),
1159
- tag: T(a.query.tag),
1160
- author: T(a.query.author),
1183
+ rubric: W(a.query.rubric),
1184
+ tag: W(a.query.tag),
1185
+ author: W(a.query.author),
1161
1186
  sort: typeof a.query.sort == "string" ? a.query.sort : null,
1162
1187
  page: Number(a.query.page ?? 1) || 1
1163
1188
  }));
1164
- function T(n) {
1189
+ function W(n) {
1165
1190
  return typeof n == "string" && n !== "" && Number(n) || null;
1166
1191
  }
1167
- const N = h(() => [
1192
+ const U = b(() => [
1168
1193
  { value: "", label: t("panel.view-all") },
1169
1194
  { value: "published", label: t("panel.view-published") },
1170
1195
  { value: "scheduled", label: t("panel.view-scheduled") },
1171
1196
  { value: "draft", label: t("panel.view-draft") },
1172
1197
  { value: "unpublished", label: t("panel.view-unpublished") },
1173
1198
  { value: "trashed", label: t("panel.bin"), icon: "trash" }
1174
- ]), I = h(() => $.value?.filters ?? { rubrics: [], tags: [], authors: [] }), b = h(() => y.value > 0 && y.value < Xe), P = h(() => b.value ? [{ key: "card", label: "" }] : [
1199
+ ]), I = b(() => T.value?.filters ?? { rubrics: [], tags: [], authors: [] }), g = b(() => w.value > 0 && w.value < Ye), B = b(() => g.value ? [{ key: "card", label: "" }] : [
1175
1200
  { key: "cover", label: "", width: 68 },
1176
1201
  /* The one that takes what the others leave, and the only one without a number. */
1177
1202
  { key: "title", label: t("panel.column-title"), minWidth: 220 },
@@ -1179,7 +1204,7 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1179
1204
  { key: "author", label: t("panel.column-author"), width: 160, hideBelow: 1200 },
1180
1205
  {
1181
1206
  key: "date",
1182
- label: B.value ? t("panel.column-deleted") : t("panel.column-date"),
1207
+ label: R.value ? t("panel.column-deleted") : t("panel.column-date"),
1183
1208
  width: 120,
1184
1209
  hideBelow: 700,
1185
1210
  // "today at 16:22" is three words the table will break over two lines given half a
@@ -1187,28 +1212,28 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1187
1212
  cellClass: "wx-articles__when"
1188
1213
  },
1189
1214
  { key: "status", label: t("panel.column-status"), width: 170 },
1190
- { key: "actions", label: "", width: Ye, align: "right" }
1191
- ]), E = h(() => w.value.q !== "" ? t("panel.empty-search") : B.value ? t("panel.empty-bin") : t("panel.empty")), Z = h(() => {
1192
- const n = [], U = I.value.rubrics.find((he) => he.id === w.value.rubric);
1193
- U && n.push({
1215
+ { key: "actions", label: "", width: et, align: "right" }
1216
+ ]), D = b(() => x.value.q !== "" ? t("panel.empty-search") : R.value ? t("panel.empty-bin") : t("panel.empty")), H = b(() => {
1217
+ const n = [], N = I.value.rubrics.find((we) => we.id === x.value.rubric);
1218
+ N && n.push({
1194
1219
  key: "rubric",
1195
- label: `${t("panel.filter-rubric")}: ${U.title}`,
1196
- clear: () => O("rubric", void 0)
1220
+ label: `${t("panel.filter-rubric")}: ${N.title}`,
1221
+ clear: () => X("rubric", void 0)
1197
1222
  });
1198
- const p = I.value.tags.find((he) => he.id === w.value.tag);
1223
+ const p = I.value.tags.find((we) => we.id === x.value.tag);
1199
1224
  p && n.push({
1200
1225
  key: "tag",
1201
1226
  label: `${t("panel.filter-tag")}: ${p.title}`,
1202
- clear: () => O("tag", void 0)
1227
+ clear: () => X("tag", void 0)
1203
1228
  });
1204
- const xe = I.value.authors.find((he) => he.id === w.value.author);
1205
- return xe && n.push({
1229
+ const ye = I.value.authors.find((we) => we.id === x.value.author);
1230
+ return ye && n.push({
1206
1231
  key: "author",
1207
- label: `${t("panel.filter-author")}: ${xe.title}`,
1208
- clear: () => O("author", void 0)
1232
+ label: `${t("panel.filter-author")}: ${ye.title}`,
1233
+ clear: () => X("author", void 0)
1209
1234
  }), n;
1210
1235
  });
1211
- function Y() {
1236
+ function me() {
1212
1237
  s.replace({
1213
1238
  query: {
1214
1239
  ...a.query,
@@ -1219,281 +1244,281 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1219
1244
  }
1220
1245
  });
1221
1246
  }
1222
- async function se(n) {
1223
- d.value = !0;
1247
+ async function Q(n) {
1248
+ A.value = !0;
1224
1249
  try {
1225
- $.value = await f.articles({
1226
- q: n?.search ?? w.value.q,
1227
- status: B.value ? "" : D.value,
1228
- trashed: B.value,
1229
- rubric: w.value.rubric,
1230
- tag: w.value.tag,
1231
- author: w.value.author,
1250
+ T.value = await f.articles({
1251
+ q: n?.search ?? x.value.q,
1252
+ status: R.value ? "" : E.value,
1253
+ trashed: R.value,
1254
+ rubric: x.value.rubric,
1255
+ tag: x.value.tag,
1256
+ author: x.value.author,
1232
1257
  sort: n?.sort ? `${n.sort.order === "desc" ? "-" : ""}${n.sort.key}` : null,
1233
- page: n?.page ?? w.value.page,
1258
+ page: n?.page ?? x.value.page,
1234
1259
  per_page: n?.perPage
1235
1260
  });
1236
- } catch (U) {
1237
- R.danger(i(U));
1261
+ } catch (N) {
1262
+ P.danger(i(N));
1238
1263
  } finally {
1239
- d.value = !1;
1264
+ A.value = !1;
1240
1265
  }
1241
1266
  }
1242
- function re(n) {
1243
- const U = {
1267
+ function ke(n) {
1268
+ const N = {
1244
1269
  ...a.query,
1245
1270
  q: n.search === "" ? void 0 : n.search,
1246
1271
  sort: n.sort === null ? void 0 : `${n.sort.order === "desc" ? "-" : ""}${n.sort.key}`,
1247
1272
  page: n.page === 1 ? void 0 : String(n.page)
1248
1273
  };
1249
- s.replace({ query: U }), se(n);
1274
+ s.replace({ query: N }), Q(n);
1250
1275
  }
1251
- function O(n, U) {
1276
+ function X(n, N) {
1252
1277
  s.replace({
1253
1278
  query: {
1254
1279
  ...a.query,
1255
- [n]: typeof U == "number" ? String(U) : void 0,
1280
+ [n]: typeof N == "number" ? String(N) : void 0,
1256
1281
  page: void 0
1257
1282
  }
1258
1283
  });
1259
1284
  }
1260
- ve(
1261
- [D, () => w.value.rubric, () => w.value.tag, () => w.value.author],
1285
+ pe(
1286
+ [E, () => x.value.rubric, () => x.value.tag, () => x.value.author],
1262
1287
  () => {
1263
- se();
1288
+ Q();
1264
1289
  }
1265
- ), se();
1266
- function ye(n) {
1267
- const U = `${c.base}/articles/${n.id}`;
1268
- s.resolve(U).matched.length > 0 && s.push({ path: U, query: { ...a.query } });
1290
+ ), Q();
1291
+ function G(n) {
1292
+ const N = `${c.base}/articles/${n.id}`;
1293
+ s.resolve(N).matched.length > 0 && s.push({ path: N, query: { ...a.query } });
1269
1294
  }
1270
- async function we() {
1271
- const n = await W({});
1272
- n && (await se(), ye(n));
1295
+ async function $e() {
1296
+ const n = await y({});
1297
+ n && (await Q(), G(n));
1273
1298
  }
1274
- function te(n) {
1275
- if (!V.value) return [];
1276
- if (B.value)
1299
+ function ge(n) {
1300
+ if (!S.value) return [];
1301
+ if (R.value)
1277
1302
  return [
1278
1303
  {
1279
1304
  key: "restore",
1280
1305
  icon: "refresh",
1281
1306
  label: t("panel.restore"),
1282
1307
  run: () => {
1283
- ce(n);
1308
+ se(n);
1284
1309
  }
1285
1310
  }
1286
1311
  ];
1287
- const U = [
1288
- { key: "open", icon: "edit", label: t("panel.open"), run: () => ye(n) }
1312
+ const N = [
1313
+ { key: "open", icon: "edit", label: t("panel.open"), run: () => G(n) }
1289
1314
  ];
1290
- return n.url && n.status !== "draft" && U.push({
1315
+ return n.url && n.status !== "draft" && N.push({
1291
1316
  key: "site",
1292
1317
  icon: "external-link",
1293
1318
  label: t("panel.open-on-site"),
1294
1319
  href: n.url
1295
- }), n.path !== null && U.push({
1320
+ }), n.path !== null && N.push({
1296
1321
  key: "copy",
1297
1322
  icon: "copy",
1298
1323
  label: t("panel.copy-address"),
1299
1324
  run: () => {
1300
1325
  We(n);
1301
1326
  }
1302
- }), U.push({
1327
+ }), N.push({
1303
1328
  key: "pin",
1304
1329
  icon: "star",
1305
1330
  label: n.pinned ? t("panel.unpin") : t("panel.pin"),
1306
1331
  run: () => {
1307
- $e(n, !n.pinned);
1332
+ Se(n, !n.pinned);
1308
1333
  }
1309
- }), U.push(
1334
+ }), N.push(
1310
1335
  n.status === "published" || n.status === "modified" || n.status === "scheduled" ? {
1311
1336
  key: "unpublish",
1312
1337
  icon: "eye-off",
1313
1338
  label: t("panel.unpublish"),
1314
1339
  run: () => {
1315
- Se(n);
1340
+ fe(n);
1316
1341
  }
1317
1342
  } : {
1318
1343
  key: "publish",
1319
1344
  icon: "upload",
1320
1345
  label: t("panel.publish"),
1321
1346
  run: () => {
1322
- fe(n);
1347
+ ce(n);
1323
1348
  }
1324
1349
  }
1325
- ), U.push({
1350
+ ), N.push({
1326
1351
  key: "delete",
1327
1352
  icon: "trash",
1328
1353
  label: t("panel.delete"),
1329
1354
  danger: !0,
1330
1355
  run: () => {
1331
- oe(n);
1356
+ be(n);
1332
1357
  }
1333
- }), U;
1358
+ }), N;
1334
1359
  }
1335
- async function fe(n) {
1336
- await ae(() => f.publish(n.id), t("panel.published"));
1360
+ async function ce(n) {
1361
+ await Y(() => f.publish(n.id), t("panel.published"));
1337
1362
  }
1338
- async function Se(n) {
1339
- await ae(() => f.unpublish(n.id), t("panel.unpublished-done"));
1363
+ async function fe(n) {
1364
+ await Y(() => f.unpublish(n.id), t("panel.unpublished-done"));
1340
1365
  }
1341
- async function $e(n, U) {
1342
- await ae(
1343
- () => f.save(n.id, { values: { pinned: U }, revision: n.revision }),
1344
- t(U ? "panel.pinned-done" : "panel.unpinned")
1366
+ async function Se(n, N) {
1367
+ await Y(
1368
+ () => f.save(n.id, { values: { pinned: N }, revision: n.revision }),
1369
+ t(N ? "panel.pinned-done" : "panel.unpinned")
1345
1370
  );
1346
1371
  }
1347
- async function oe(n) {
1348
- await de({
1372
+ async function be(n) {
1373
+ await oe({
1349
1374
  title: t("panel.delete-title", { title: n.title }),
1350
1375
  message: t("panel.delete-text"),
1351
1376
  confirmText: t("panel.delete"),
1352
1377
  cancelText: t("panel.cancel"),
1353
1378
  tone: "danger"
1354
- }) && await ae(() => f.remove(n.id), t("panel.deleted"));
1379
+ }) && await Y(() => f.remove(n.id), t("panel.deleted"));
1355
1380
  }
1356
- async function ce(n) {
1357
- await ae(() => f.restore(n.id), t("panel.restored"));
1381
+ async function se(n) {
1382
+ await Y(() => f.restore(n.id), t("panel.restored"));
1358
1383
  }
1359
- async function ae(n, U) {
1384
+ async function Y(n, N) {
1360
1385
  try {
1361
- await n(), R.success(U);
1386
+ await n(), P.success(N);
1362
1387
  } catch (p) {
1363
- R.danger(i(p));
1388
+ P.danger(i(p));
1364
1389
  } finally {
1365
- await se();
1390
+ await Q();
1366
1391
  }
1367
1392
  }
1368
1393
  async function We(n) {
1369
1394
  if (n.url)
1370
1395
  try {
1371
- await navigator.clipboard.writeText(n.url), R.success(t("panel.address-copied"));
1396
+ await navigator.clipboard.writeText(n.url), P.success(t("panel.address-copied"));
1372
1397
  } catch {
1373
1398
  }
1374
1399
  }
1375
- function o(n) {
1400
+ function u(n) {
1376
1401
  return n === "published" || n === "modified" ? "success" : n === "scheduled" ? "warning" : "default";
1377
1402
  }
1378
- function A(n) {
1379
- return B.value ? "—" : n.path === null ? t("panel.no-address") : `/${n.path}`;
1403
+ function V(n) {
1404
+ return R.value ? "—" : n.path === null ? t("panel.no-address") : `/${n.path}`;
1380
1405
  }
1381
- function S(n) {
1382
- return B.value ? n.deleted_at : n.published_at;
1406
+ function k(n) {
1407
+ return R.value ? n.deleted_at : n.published_at;
1383
1408
  }
1384
- const ee = h(
1385
- () => V.value ? [{ key: "new", label: t("panel.new"), icon: "plus", primary: !0, run: () => {
1386
- we();
1409
+ const ae = b(
1410
+ () => S.value ? [{ key: "new", label: t("panel.new"), icon: "plus", primary: !0, run: () => {
1411
+ $e();
1387
1412
  } }] : []
1388
1413
  );
1389
- return (n, U) => (_(), H("div", {
1414
+ return (n, N) => (_(), j("div", {
1390
1415
  ref_key: "root",
1391
- ref: m,
1416
+ ref: d,
1392
1417
  class: "wx-articles"
1393
1418
  }, [
1394
- r(e(et), {
1395
- view: D.value,
1396
- "onUpdate:view": U[3] || (U[3] = (p) => D.value = p),
1419
+ r(e(tt), {
1420
+ view: E.value,
1421
+ "onUpdate:view": N[3] || (N[3] = (p) => E.value = p),
1397
1422
  title: z.value,
1398
- views: N.value,
1399
- actions: ee.value
1423
+ views: U.value,
1424
+ actions: ae.value
1400
1425
  }, {
1401
1426
  default: l(() => [
1402
- r(e(it), {
1403
- data: $.value,
1404
- columns: P.value,
1427
+ r(e(nt), {
1428
+ data: T.value,
1429
+ columns: B.value,
1405
1430
  "row-key": "id",
1406
1431
  searchable: "",
1407
- clickable: !B.value,
1408
- hover: !B.value,
1432
+ clickable: !R.value,
1433
+ hover: !R.value,
1409
1434
  flush: "",
1410
- loading: d.value,
1435
+ loading: A.value,
1411
1436
  layout: "fixed",
1412
- "cards-below": Xe,
1413
- "filters-count": Z.value.length,
1414
- "filters-label": e(u)("filters.title"),
1437
+ "cards-below": Ye,
1438
+ "filters-count": H.value.length,
1439
+ "filters-label": e(o)("filters.title"),
1415
1440
  "search-placeholder": e(t)("panel.search"),
1416
- "empty-text": E.value,
1441
+ "empty-text": D.value,
1417
1442
  "aria-label": z.value,
1418
- onRowClick: ye,
1419
- onStateChange: re
1443
+ onRowClick: G,
1444
+ onStateChange: ke
1420
1445
  }, {
1421
1446
  filters: l(() => [
1422
- r(e(pe), {
1447
+ r(e(de), {
1423
1448
  label: e(t)("panel.filter-rubric")
1424
1449
  }, {
1425
1450
  default: l(() => [
1426
- r(e(_e), {
1427
- "model-value": w.value.rubric,
1451
+ r(e(xe), {
1452
+ "model-value": x.value.rubric,
1428
1453
  options: I.value.rubrics.map((p) => ({ value: p.id, label: p.title })),
1429
1454
  placeholder: e(t)("panel.any-rubric"),
1430
1455
  clearable: "",
1431
1456
  size: "sm",
1432
- "onUpdate:modelValue": U[0] || (U[0] = (p) => O("rubric", p))
1457
+ "onUpdate:modelValue": N[0] || (N[0] = (p) => X("rubric", p))
1433
1458
  }, null, 8, ["model-value", "options", "placeholder"])
1434
1459
  ]),
1435
1460
  _: 1
1436
1461
  }, 8, ["label"]),
1437
- r(e(pe), {
1462
+ r(e(de), {
1438
1463
  label: e(t)("panel.filter-tag")
1439
1464
  }, {
1440
1465
  default: l(() => [
1441
- r(e(_e), {
1442
- "model-value": w.value.tag,
1466
+ r(e(xe), {
1467
+ "model-value": x.value.tag,
1443
1468
  options: I.value.tags.map((p) => ({ value: p.id, label: p.title })),
1444
1469
  placeholder: e(t)("panel.any-tag"),
1445
1470
  clearable: "",
1446
1471
  filterable: "",
1447
1472
  size: "sm",
1448
- "onUpdate:modelValue": U[1] || (U[1] = (p) => O("tag", p))
1473
+ "onUpdate:modelValue": N[1] || (N[1] = (p) => X("tag", p))
1449
1474
  }, null, 8, ["model-value", "options", "placeholder"])
1450
1475
  ]),
1451
1476
  _: 1
1452
1477
  }, 8, ["label"]),
1453
- r(e(pe), {
1478
+ r(e(de), {
1454
1479
  label: e(t)("panel.filter-author")
1455
1480
  }, {
1456
1481
  default: l(() => [
1457
- r(e(_e), {
1458
- "model-value": w.value.author,
1482
+ r(e(xe), {
1483
+ "model-value": x.value.author,
1459
1484
  options: I.value.authors.map((p) => ({ value: p.id, label: p.title })),
1460
1485
  placeholder: e(t)("panel.any-author"),
1461
1486
  clearable: "",
1462
1487
  size: "sm",
1463
- "onUpdate:modelValue": U[2] || (U[2] = (p) => O("author", p))
1488
+ "onUpdate:modelValue": N[2] || (N[2] = (p) => X("author", p))
1464
1489
  }, null, 8, ["model-value", "options", "placeholder"])
1465
1490
  ]),
1466
1491
  _: 1
1467
1492
  }, 8, ["label"]),
1468
- Z.value.length > 0 ? (_(), q(e(G), {
1493
+ H.value.length > 0 ? (_(), q(e(J), {
1469
1494
  key: 0,
1470
1495
  variant: "text",
1471
1496
  size: "sm",
1472
1497
  block: "",
1473
- onClick: Y
1498
+ onClick: me
1474
1499
  }, {
1475
1500
  icon: l(() => [
1476
1501
  r(e(Te), { name: "close" })
1477
1502
  ]),
1478
1503
  default: l(() => [
1479
- C(" " + k(e(u)("filters.reset")), 1)
1504
+ C(" " + $(e(o)("filters.reset")), 1)
1480
1505
  ]),
1481
1506
  _: 1
1482
- })) : K("", !0)
1507
+ })) : L("", !0)
1483
1508
  ]),
1484
1509
  applied: l(() => [
1485
- r(e(vt), { filters: Z.value }, null, 8, ["filters"])
1510
+ r(e(mt), { filters: H.value }, null, 8, ["filters"])
1486
1511
  ]),
1487
1512
  "cell-cover": l(({ row: p }) => [
1488
1513
  F("span", {
1489
- class: tt(["wx-articles__cover", { "is-empty": !p.cover }])
1514
+ class: at(["wx-articles__cover", { "is-empty": !p.cover }])
1490
1515
  }, [
1491
- p.cover?.thumb ? (_(), H("img", {
1516
+ p.cover?.thumb ? (_(), j("img", {
1492
1517
  key: 0,
1493
1518
  src: p.cover.thumb,
1494
1519
  alt: "",
1495
1520
  loading: "lazy"
1496
- }, null, 8, oa)) : (_(), q(e(Te), {
1521
+ }, null, 8, pa)) : (_(), q(e(Te), {
1497
1522
  key: 1,
1498
1523
  name: "image",
1499
1524
  size: "sm"
@@ -1501,8 +1526,8 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1501
1526
  ], 2)
1502
1527
  ]),
1503
1528
  "cell-title": l(({ row: p }) => [
1504
- F("div", ua, [
1505
- p.pinned ? (_(), q(e(nt), {
1529
+ F("div", va, [
1530
+ p.pinned ? (_(), q(e(st), {
1506
1531
  key: 0,
1507
1532
  content: e(t)("panel.pinned")
1508
1533
  }, {
@@ -1514,22 +1539,28 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1514
1539
  })
1515
1540
  ]),
1516
1541
  _: 1
1517
- }, 8, ["content"])) : K("", !0),
1518
- F("div", ca, [
1519
- F("span", da, k(p.title), 1),
1520
- F("span", pa, k(A(p)), 1)
1542
+ }, 8, ["content"])) : L("", !0),
1543
+ F("div", ga, [
1544
+ F("span", fa, $(p.title), 1),
1545
+ F("span", ha, [
1546
+ C($(V(p)) + " ", 1),
1547
+ R.value ? L("", !0) : (_(), q(e(ht), {
1548
+ key: 0,
1549
+ locale: p.address_locale
1550
+ }, null, 8, ["locale"]))
1551
+ ])
1521
1552
  ])
1522
1553
  ])
1523
1554
  ]),
1524
1555
  "cell-rubrics": l(({ row: p }) => [
1525
- F("span", va, [
1526
- (_(!0), H(ke, null, qe(p.rubrics, (xe) => (_(), q(e(ie), {
1527
- key: xe.id,
1556
+ F("span", ma, [
1557
+ (_(!0), j(_e, null, qe(p.rubrics, (ye) => (_(), q(e(ie), {
1558
+ key: ye.id,
1528
1559
  size: "sm",
1529
1560
  round: ""
1530
1561
  }, {
1531
1562
  default: l(() => [
1532
- C(k(xe.title), 1)
1563
+ C($(ye.title), 1)
1533
1564
  ]),
1534
1565
  _: 2
1535
1566
  }, 1024))), 128))
@@ -1542,36 +1573,36 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1542
1573
  truncate: ""
1543
1574
  }, {
1544
1575
  default: l(() => [
1545
- C(k(p.author ? p.author.name : "—"), 1)
1576
+ C($(p.author ? p.author.name : "—"), 1)
1546
1577
  ]),
1547
1578
  _: 2
1548
1579
  }, 1024)
1549
1580
  ]),
1550
1581
  "cell-date": l(({ row: p }) => [
1551
- S(p) ? (_(), q(e(Ee), {
1582
+ k(p) ? (_(), q(e(Ee), {
1552
1583
  key: 0,
1553
- value: S(p),
1584
+ value: k(p),
1554
1585
  compact: ""
1555
1586
  }, null, 8, ["value"])) : (_(), q(e(le), {
1556
1587
  key: 1,
1557
1588
  size: "sm",
1558
1589
  tone: "muted"
1559
1590
  }, {
1560
- default: l(() => [...U[4] || (U[4] = [
1591
+ default: l(() => [...N[4] || (N[4] = [
1561
1592
  C("—", -1)
1562
1593
  ])]),
1563
1594
  _: 1
1564
1595
  }))
1565
1596
  ]),
1566
1597
  "cell-status": l(({ row: p }) => [
1567
- F("span", ga, [
1598
+ F("span", ba, [
1568
1599
  r(e(ie), {
1569
- type: o(p.status),
1600
+ type: u(p.status),
1570
1601
  dot: "",
1571
1602
  size: "sm"
1572
1603
  }, {
1573
1604
  default: l(() => [
1574
- C(k(e(t)(`panel.status-${p.status}`)), 1)
1605
+ C($(e(t)(`panel.status-${p.status}`)), 1)
1575
1606
  ]),
1576
1607
  _: 2
1577
1608
  }, 1032, ["type"]),
@@ -1582,21 +1613,21 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1582
1613
  round: ""
1583
1614
  }, {
1584
1615
  default: l(() => [
1585
- C(k(e(t)("panel.edits")), 1)
1616
+ C($(e(t)("panel.edits")), 1)
1586
1617
  ]),
1587
1618
  _: 1
1588
- })) : K("", !0)
1619
+ })) : L("", !0)
1589
1620
  ])
1590
1621
  ]),
1591
1622
  "cell-card": l(({ row: p }) => [
1592
- r(e(St), {
1623
+ r(e(zt), {
1593
1624
  class: "wx-articles__entity",
1594
1625
  variant: "plain",
1595
1626
  title: p.title,
1596
1627
  image: p.cover?.thumb ?? void 0,
1597
1628
  "image-size": "56px",
1598
1629
  "title-lines": 2,
1599
- subtitle: A(p)
1630
+ subtitle: V(p)
1600
1631
  }, {
1601
1632
  title: l(() => [
1602
1633
  p.pinned ? (_(), q(e(Te), {
@@ -1604,8 +1635,8 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1604
1635
  class: "wx-articles__pin",
1605
1636
  name: "star",
1606
1637
  size: "sm"
1607
- })) : K("", !0),
1608
- C(" " + k(p.title), 1)
1638
+ })) : L("", !0),
1639
+ C(" " + $(p.title), 1)
1609
1640
  ]),
1610
1641
  meta: l(() => [
1611
1642
  p.rubrics[0] ? (_(), q(e(ie), {
@@ -1614,37 +1645,37 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1614
1645
  round: ""
1615
1646
  }, {
1616
1647
  default: l(() => [
1617
- C(k(p.rubrics[0].title), 1)
1648
+ C($(p.rubrics[0].title), 1)
1618
1649
  ]),
1619
1650
  _: 2
1620
- }, 1024)) : K("", !0),
1651
+ }, 1024)) : L("", !0),
1621
1652
  r(e(ie), {
1622
- type: o(p.status),
1653
+ type: u(p.status),
1623
1654
  dot: "",
1624
1655
  size: "sm"
1625
1656
  }, {
1626
1657
  default: l(() => [
1627
- C(k(e(t)(`panel.status-${p.status}`)), 1)
1658
+ C($(e(t)(`panel.status-${p.status}`)), 1)
1628
1659
  ]),
1629
1660
  _: 2
1630
1661
  }, 1032, ["type"]),
1631
- S(p) ? (_(), q(e(Ee), {
1662
+ k(p) ? (_(), q(e(Ee), {
1632
1663
  key: 1,
1633
- value: S(p)
1634
- }, null, 8, ["value"])) : K("", !0)
1664
+ value: k(p)
1665
+ }, null, 8, ["value"])) : L("", !0)
1635
1666
  ]),
1636
1667
  _: 2
1637
1668
  }, 1032, ["title", "image", "subtitle"])
1638
1669
  ]),
1639
1670
  "card-actions": l(({ row: p }) => [
1640
1671
  r(e(ze), {
1641
- actions: te(p),
1672
+ actions: ge(p),
1642
1673
  label: p.title
1643
1674
  }, null, 8, ["actions", "label"])
1644
1675
  ]),
1645
1676
  "cell-actions": l(({ row: p }) => [
1646
1677
  r(e(ze), {
1647
- actions: te(p),
1678
+ actions: ge(p),
1648
1679
  label: p.title
1649
1680
  }, null, 8, ["actions", "label"])
1650
1681
  ]),
@@ -1655,58 +1686,58 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1655
1686
  }, 8, ["view", "title", "views", "actions"])
1656
1687
  ], 512));
1657
1688
  }
1658
- }), ha = /* @__PURE__ */ ge(fa, [["__scopeId", "data-v-d6800820"]]), ma = /* @__PURE__ */ Q({
1689
+ }), wa = /* @__PURE__ */ ve(ya, [["__scopeId", "data-v-5dfe798a"]]), xa = /* @__PURE__ */ ee({
1659
1690
  __name: "TagCreateDialog",
1660
- setup(g) {
1691
+ setup(h) {
1661
1692
  const { open: c, resolve: v, dismiss: f } = Re(), a = ne(), s = ue(a);
1662
- X();
1663
- const t = J("webx-blog"), u = M(""), i = M(""), m = M(!1), y = M({}), $ = Ie("field");
1664
- Ne(async () => {
1665
- await He(), $.value?.querySelector("input")?.focus();
1693
+ te();
1694
+ const t = Z("webx-blog"), o = M(""), i = M(""), d = M(!1), w = M({}), T = Ie("field");
1695
+ Ue(async () => {
1696
+ await He(), T.value?.querySelector("input")?.focus();
1666
1697
  });
1667
- async function d() {
1668
- if (!(u.value.trim() === "" || m.value)) {
1669
- m.value = !0, y.value = {};
1698
+ async function A() {
1699
+ if (!(o.value.trim() === "" || d.value)) {
1700
+ d.value = !0, w.value = {};
1670
1701
  try {
1671
1702
  v(
1672
1703
  await s.createTag({
1673
- title: u.value.trim(),
1704
+ title: o.value.trim(),
1674
1705
  ...i.value.trim() === "" ? {} : { slug: i.value.trim() }
1675
1706
  })
1676
1707
  );
1677
- } catch (W) {
1678
- y.value = W.body?.errors ?? {};
1708
+ } catch (y) {
1709
+ w.value = y.body?.errors ?? {};
1679
1710
  } finally {
1680
- m.value = !1;
1711
+ d.value = !1;
1681
1712
  }
1682
1713
  }
1683
1714
  }
1684
- return (W, V) => (_(), q(e(De), {
1715
+ return (y, S) => (_(), q(e(De), {
1685
1716
  open: e(c),
1686
- "onUpdate:open": V[3] || (V[3] = (z) => Pe(c) ? c.value = z : null),
1717
+ "onUpdate:open": S[3] || (S[3] = (z) => Pe(c) ? c.value = z : null),
1687
1718
  title: e(t)("tag.new-title"),
1688
1719
  width: 440
1689
1720
  }, {
1690
1721
  footer: l(() => [
1691
1722
  r(e(Be), { size: "sm" }, {
1692
1723
  default: l(() => [
1693
- r(e(G), {
1724
+ r(e(J), {
1694
1725
  variant: "outline",
1695
- onClick: V[2] || (V[2] = (z) => e(f)())
1726
+ onClick: S[2] || (S[2] = (z) => e(f)())
1696
1727
  }, {
1697
1728
  default: l(() => [
1698
- C(k(e(t)("tag.cancel")), 1)
1729
+ C($(e(t)("tag.cancel")), 1)
1699
1730
  ]),
1700
1731
  _: 1
1701
1732
  }),
1702
- r(e(G), {
1733
+ r(e(J), {
1703
1734
  type: "primary",
1704
- loading: m.value,
1705
- disabled: u.value.trim() === "",
1706
- onClick: d
1735
+ loading: d.value,
1736
+ disabled: o.value.trim() === "",
1737
+ onClick: A
1707
1738
  }, {
1708
1739
  default: l(() => [
1709
- C(k(e(t)("tag.create")), 1)
1740
+ C($(e(t)("tag.create")), 1)
1710
1741
  ]),
1711
1742
  _: 1
1712
1743
  }, 8, ["loading", "disabled"])
@@ -1715,37 +1746,37 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1715
1746
  })
1716
1747
  ]),
1717
1748
  default: l(() => [
1718
- r(e(pe), {
1749
+ r(e(de), {
1719
1750
  label: e(t)("tag.field-title"),
1720
- error: y.value.title?.[0],
1751
+ error: w.value.title?.[0],
1721
1752
  required: ""
1722
1753
  }, {
1723
1754
  default: l(() => [
1724
1755
  F("div", {
1725
1756
  ref_key: "field",
1726
- ref: $
1757
+ ref: T
1727
1758
  }, [
1728
1759
  r(e(Ce), {
1729
- modelValue: u.value,
1730
- "onUpdate:modelValue": V[0] || (V[0] = (z) => u.value = z),
1760
+ modelValue: o.value,
1761
+ "onUpdate:modelValue": S[0] || (S[0] = (z) => o.value = z),
1731
1762
  "aria-label": e(t)("tag.field-title"),
1732
- onKeyup: Me(d, ["enter"])
1763
+ onKeyup: Me(A, ["enter"])
1733
1764
  }, null, 8, ["modelValue", "aria-label"])
1734
1765
  ], 512)
1735
1766
  ]),
1736
1767
  _: 1
1737
1768
  }, 8, ["label", "error"]),
1738
- r(e(pe), {
1769
+ r(e(de), {
1739
1770
  label: e(t)("tag.field-slug"),
1740
- error: y.value.slug?.[0],
1771
+ error: w.value.slug?.[0],
1741
1772
  help: e(t)("tag.field-slug-help")
1742
1773
  }, {
1743
1774
  default: l(() => [
1744
1775
  r(e(Ce), {
1745
1776
  modelValue: i.value,
1746
- "onUpdate:modelValue": V[1] || (V[1] = (z) => i.value = z),
1777
+ "onUpdate:modelValue": S[1] || (S[1] = (z) => i.value = z),
1747
1778
  "aria-label": e(t)("tag.field-slug"),
1748
- onKeyup: Me(d, ["enter"])
1779
+ onKeyup: Me(A, ["enter"])
1749
1780
  }, null, 8, ["modelValue", "aria-label"])
1750
1781
  ]),
1751
1782
  _: 1
@@ -1754,54 +1785,54 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1754
1785
  _: 1
1755
1786
  }, 8, ["open", "title"]));
1756
1787
  }
1757
- }), ba = ["id"], ya = /* @__PURE__ */ Q({
1788
+ }), _a = ["id"], ka = /* @__PURE__ */ ee({
1758
1789
  __name: "TagRenameDialog",
1759
1790
  props: {
1760
1791
  name: {}
1761
1792
  },
1762
- setup(g) {
1763
- const c = g, { open: v, resolve: f, dismiss: a } = Re();
1764
- X();
1765
- const s = J("webx-blog"), t = J("webx-admin"), u = yt(), i = M(c.name), m = Ie("field");
1766
- Ne(async () => {
1793
+ setup(h) {
1794
+ const c = h, { open: v, resolve: f, dismiss: a } = Re();
1795
+ te();
1796
+ const s = Z("webx-blog"), t = Z("webx-admin"), o = kt(), i = M(c.name), d = Ie("field");
1797
+ Ue(async () => {
1767
1798
  await He();
1768
- const $ = m.value?.querySelector("input");
1769
- $?.focus(), $?.select();
1799
+ const T = d.value?.querySelector("input");
1800
+ T?.focus(), T?.select();
1770
1801
  });
1771
- function y() {
1772
- const $ = i.value.trim();
1773
- if ($ === "" || $ === c.name) {
1802
+ function w() {
1803
+ const T = i.value.trim();
1804
+ if (T === "" || T === c.name) {
1774
1805
  a();
1775
1806
  return;
1776
1807
  }
1777
- f($);
1808
+ f(T);
1778
1809
  }
1779
- return ($, d) => (_(), q(e(De), {
1810
+ return (T, A) => (_(), q(e(De), {
1780
1811
  open: e(v),
1781
- "onUpdate:open": d[2] || (d[2] = (W) => Pe(v) ? v.value = W : null),
1812
+ "onUpdate:open": A[2] || (A[2] = (y) => Pe(v) ? v.value = y : null),
1782
1813
  title: e(s)("tag.rename"),
1783
1814
  width: 420
1784
1815
  }, {
1785
1816
  footer: l(() => [
1786
1817
  r(e(Be), { size: "sm" }, {
1787
1818
  default: l(() => [
1788
- r(e(G), {
1819
+ r(e(J), {
1789
1820
  variant: "outline",
1790
- onClick: d[1] || (d[1] = (W) => e(a)())
1821
+ onClick: A[1] || (A[1] = (y) => e(a)())
1791
1822
  }, {
1792
1823
  default: l(() => [
1793
- C(k(e(s)("tag.cancel")), 1)
1824
+ C($(e(s)("tag.cancel")), 1)
1794
1825
  ]),
1795
1826
  _: 1
1796
1827
  }),
1797
- r(e(G), {
1828
+ r(e(J), {
1798
1829
  type: "primary",
1799
1830
  "native-type": "submit",
1800
- form: e(u),
1831
+ form: e(o),
1801
1832
  disabled: i.value.trim() === ""
1802
1833
  }, {
1803
1834
  default: l(() => [
1804
- C(k(e(t)("editor.save")), 1)
1835
+ C($(e(t)("editor.save")), 1)
1805
1836
  ]),
1806
1837
  _: 1
1807
1838
  }, 8, ["form", "disabled"])
@@ -1811,87 +1842,87 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1811
1842
  ]),
1812
1843
  default: l(() => [
1813
1844
  F("form", {
1814
- id: e(u),
1845
+ id: e(o),
1815
1846
  ref_key: "field",
1816
- ref: m,
1817
- onSubmit: Je(y, ["prevent"])
1847
+ ref: d,
1848
+ onSubmit: Ze(w, ["prevent"])
1818
1849
  }, [
1819
- r(e(pe), {
1850
+ r(e(de), {
1820
1851
  label: e(s)("tag.field-title"),
1821
1852
  required: ""
1822
1853
  }, {
1823
1854
  default: l(() => [
1824
1855
  r(e(Ce), {
1825
1856
  modelValue: i.value,
1826
- "onUpdate:modelValue": d[0] || (d[0] = (W) => i.value = W),
1857
+ "onUpdate:modelValue": A[0] || (A[0] = (y) => i.value = y),
1827
1858
  "aria-label": e(s)("tag.field-title"),
1828
- onKeydown: Me(Je(y, ["prevent"]), ["enter"])
1859
+ onKeydown: Me(Ze(w, ["prevent"]), ["enter"])
1829
1860
  }, null, 8, ["modelValue", "aria-label", "onKeydown"])
1830
1861
  ]),
1831
1862
  _: 1
1832
1863
  }, 8, ["label"])
1833
- ], 40, ba)
1864
+ ], 40, _a)
1834
1865
  ]),
1835
1866
  _: 1
1836
1867
  }, 8, ["open", "title"]));
1837
1868
  }
1838
- }), wa = { class: "wx-tag-merge" }, xa = { class: "wx-tag-merge__chips" }, _a = { class: "wx-tag-merge__redirect" }, ka = /* @__PURE__ */ Q({
1869
+ }), $a = { class: "wx-tag-merge" }, Ta = { class: "wx-tag-merge__chips" }, Aa = { class: "wx-tag-merge__redirect" }, Sa = /* @__PURE__ */ ee({
1839
1870
  __name: "TagMergeDialog",
1840
1871
  props: {
1841
1872
  tags: {}
1842
1873
  },
1843
- setup(g) {
1844
- const c = g, { open: v, resolve: f, dismiss: a } = Re(), s = ne(), t = ue(s);
1845
- X();
1846
- const u = J("webx-blog"), i = be(), m = M(
1847
- [...c.tags].sort((T, N) => N.articles_count - T.articles_count)[0]?.id ?? 0
1848
- ), y = M(!1), $ = M(!0), d = M(null), W = h(
1849
- () => c.tags.map((T) => ({ value: T.id, label: `${T.title} · ${T.articles_count}` }))
1850
- ), V = h(() => c.tags.find((T) => T.id === m.value) ?? null), z = h(() => c.tags.filter((T) => T.id !== m.value)), D = h(() => z.value.reduce((T, N) => T + N.articles_count, 0)), B = h(() => z.value.map((T) => T.path).filter(Boolean));
1851
- async function w() {
1852
- if (!(V.value === null || z.value.length === 0 || y.value)) {
1853
- y.value = !0, d.value = null;
1874
+ setup(h) {
1875
+ const c = h, { open: v, resolve: f, dismiss: a } = Re(), s = ne(), t = ue(s);
1876
+ te();
1877
+ const o = Z("webx-blog"), i = he(), d = M(
1878
+ [...c.tags].sort((W, U) => U.articles_count - W.articles_count)[0]?.id ?? 0
1879
+ ), w = M(!1), T = M(!0), A = M(null), y = b(
1880
+ () => c.tags.map((W) => ({ value: W.id, label: `${W.title} · ${W.articles_count}` }))
1881
+ ), S = b(() => c.tags.find((W) => W.id === d.value) ?? null), z = b(() => c.tags.filter((W) => W.id !== d.value)), E = b(() => z.value.reduce((W, U) => W + U.articles_count, 0)), R = b(() => z.value.map((W) => W.path).filter(Boolean));
1882
+ async function x() {
1883
+ if (!(S.value === null || z.value.length === 0 || w.value)) {
1884
+ w.value = !0, A.value = null;
1854
1885
  try {
1855
1886
  f(
1856
1887
  await t.mergeTags(
1857
- z.value.map((T) => T.id),
1858
- m.value,
1859
- $.value
1888
+ z.value.map((W) => W.id),
1889
+ d.value,
1890
+ T.value
1860
1891
  )
1861
1892
  );
1862
- } catch (T) {
1863
- d.value = i(T);
1893
+ } catch (W) {
1894
+ A.value = i(W);
1864
1895
  } finally {
1865
- y.value = !1;
1896
+ w.value = !1;
1866
1897
  }
1867
1898
  }
1868
1899
  }
1869
- return (T, N) => (_(), q(e(De), {
1900
+ return (W, U) => (_(), q(e(De), {
1870
1901
  open: e(v),
1871
- "onUpdate:open": N[3] || (N[3] = (I) => Pe(v) ? v.value = I : null),
1872
- title: e(u)("tag.merge-title"),
1902
+ "onUpdate:open": U[3] || (U[3] = (I) => Pe(v) ? v.value = I : null),
1903
+ title: e(o)("tag.merge-title"),
1873
1904
  width: 520
1874
1905
  }, {
1875
1906
  footer: l(() => [
1876
1907
  r(e(Be), { size: "sm" }, {
1877
1908
  default: l(() => [
1878
- r(e(G), {
1909
+ r(e(J), {
1879
1910
  variant: "outline",
1880
- onClick: N[2] || (N[2] = (I) => e(a)())
1911
+ onClick: U[2] || (U[2] = (I) => e(a)())
1881
1912
  }, {
1882
1913
  default: l(() => [
1883
- C(k(e(u)("tag.cancel")), 1)
1914
+ C($(e(o)("tag.cancel")), 1)
1884
1915
  ]),
1885
1916
  _: 1
1886
1917
  }),
1887
- r(e(G), {
1918
+ r(e(J), {
1888
1919
  type: "primary",
1889
- loading: y.value,
1920
+ loading: w.value,
1890
1921
  disabled: z.value.length === 0,
1891
- onClick: w
1922
+ onClick: x
1892
1923
  }, {
1893
1924
  default: l(() => [
1894
- C(k(e(u)("tag.merge-confirm")), 1)
1925
+ C($(e(o)("tag.merge-confirm")), 1)
1895
1926
  ]),
1896
1927
  _: 1
1897
1928
  }, 8, ["loading", "disabled"])
@@ -1900,15 +1931,15 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1900
1931
  })
1901
1932
  ]),
1902
1933
  default: l(() => [
1903
- F("div", wa, [
1904
- F("div", xa, [
1905
- (_(!0), H(ke, null, qe(z.value, (I) => (_(), q(e(ie), {
1934
+ F("div", $a, [
1935
+ F("div", Ta, [
1936
+ (_(!0), j(_e, null, qe(z.value, (I) => (_(), q(e(ie), {
1906
1937
  key: I.id,
1907
1938
  size: "sm",
1908
1939
  round: ""
1909
1940
  }, {
1910
1941
  default: l(() => [
1911
- C(k(I.title) + " · " + k(I.articles_count), 1)
1942
+ C($(I.title) + " · " + $(I.articles_count), 1)
1912
1943
  ]),
1913
1944
  _: 2
1914
1945
  }, 1024))), 128)),
@@ -1916,89 +1947,89 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
1916
1947
  name: "arrow-right",
1917
1948
  size: "sm"
1918
1949
  }),
1919
- V.value ? (_(), q(e(ie), {
1950
+ S.value ? (_(), q(e(ie), {
1920
1951
  key: 0,
1921
1952
  type: "primary",
1922
1953
  size: "sm",
1923
1954
  round: ""
1924
1955
  }, {
1925
1956
  default: l(() => [
1926
- C(k(V.value.title) + " · " + k(V.value.articles_count), 1)
1957
+ C($(S.value.title) + " · " + $(S.value.articles_count), 1)
1927
1958
  ]),
1928
1959
  _: 1
1929
- })) : K("", !0)
1960
+ })) : L("", !0)
1930
1961
  ]),
1931
- r(e(pe), {
1932
- label: e(u)("tag.merge-keep")
1962
+ r(e(de), {
1963
+ label: e(o)("tag.merge-keep")
1933
1964
  }, {
1934
1965
  default: l(() => [
1935
- r(e(_e), {
1936
- modelValue: m.value,
1937
- "onUpdate:modelValue": N[0] || (N[0] = (I) => m.value = I),
1938
- options: W.value,
1939
- "aria-label": e(u)("tag.merge-keep")
1966
+ r(e(xe), {
1967
+ modelValue: d.value,
1968
+ "onUpdate:modelValue": U[0] || (U[0] = (I) => d.value = I),
1969
+ options: y.value,
1970
+ "aria-label": e(o)("tag.merge-keep")
1940
1971
  }, null, 8, ["modelValue", "options", "aria-label"])
1941
1972
  ]),
1942
1973
  _: 1
1943
1974
  }, 8, ["label"]),
1944
- F("div", _a, [
1945
- r(e(Wt), {
1946
- modelValue: $.value,
1947
- "onUpdate:modelValue": N[1] || (N[1] = (I) => $.value = I),
1948
- label: e(u)("tag.merge-redirect")
1975
+ F("div", Aa, [
1976
+ r(e(Mt), {
1977
+ modelValue: T.value,
1978
+ "onUpdate:modelValue": U[1] || (U[1] = (I) => T.value = I),
1979
+ label: e(o)("tag.merge-redirect")
1949
1980
  }, null, 8, ["modelValue", "label"]),
1950
1981
  r(e(le), {
1951
1982
  size: "sm",
1952
1983
  tone: "muted"
1953
1984
  }, {
1954
1985
  default: l(() => [
1955
- C(k(B.value.length === 0 ? e(u)("tag.merge-redirect-none") : e(u)("tag.merge-redirect-help", { addresses: B.value.join(", ") })), 1)
1986
+ C($(R.value.length === 0 ? e(o)("tag.merge-redirect-none") : e(o)("tag.merge-redirect-help", { addresses: R.value.join(", ") })), 1)
1956
1987
  ]),
1957
1988
  _: 1
1958
1989
  })
1959
1990
  ]),
1960
- r(e(Ue), {
1991
+ r(e(Ne), {
1961
1992
  type: "warning",
1962
1993
  variant: "soft",
1963
- description: e(u)("tag.merge-warning", {
1964
- count: D.value,
1965
- tag: V.value?.title ?? "",
1994
+ description: e(o)("tag.merge-warning", {
1995
+ count: E.value,
1996
+ tag: S.value?.title ?? "",
1966
1997
  merged: z.value.length
1967
1998
  })
1968
1999
  }, null, 8, ["description"]),
1969
- d.value ? (_(), q(e(Ue), {
2000
+ A.value ? (_(), q(e(Ne), {
1970
2001
  key: 0,
1971
2002
  type: "danger",
1972
2003
  variant: "soft",
1973
- description: d.value
1974
- }, null, 8, ["description"])) : K("", !0)
2004
+ description: A.value
2005
+ }, null, 8, ["description"])) : L("", !0)
1975
2006
  ])
1976
2007
  ]),
1977
2008
  _: 1
1978
2009
  }, 8, ["open", "title"]));
1979
2010
  }
1980
- }), $a = /* @__PURE__ */ ge(ka, [["__scopeId", "data-v-aa68b3a8"]]), Ta = { class: "wx-tags" }, Aa = /* @__PURE__ */ Q({
2011
+ }), Wa = /* @__PURE__ */ ve(Sa, [["__scopeId", "data-v-aa68b3a8"]]), Ca = { class: "wx-tags" }, Va = /* @__PURE__ */ ee({
1981
2012
  __name: "TagsPage",
1982
2013
  props: {
1983
2014
  base: { default: "/blog" }
1984
2015
  },
1985
- setup(g) {
1986
- const c = g, v = ne(), f = ue(v), a = Ge(), s = je();
1987
- X();
1988
- const t = J("webx-blog"), u = J("webx-admin"), i = be(), m = M(null), y = M(!0), $ = M([]), d = M(!1), W = Ve(ya), V = Ve(ma), z = Ve($a), D = h(() => v.can("blog.taxonomy.manage")), B = h(
1989
- () => v.state.manifest?.modules.find((o) => o.id === "tags")?.title ?? t("module.tags")
1990
- ), w = h({
2016
+ setup(h) {
2017
+ const c = h, v = ne(), f = ue(v), a = Ge(), s = je();
2018
+ te();
2019
+ const t = Z("webx-blog"), o = Z("webx-admin"), i = he(), d = M(null), w = M(!0), T = M([]), A = M(!1), y = Ve(ka), S = Ve(xa), z = Ve(Wa), E = b(() => v.can("blog.taxonomy.manage")), R = b(
2020
+ () => v.state.manifest?.modules.find((u) => u.id === "tags")?.title ?? t("module.tags")
2021
+ ), x = b({
1991
2022
  get: () => typeof a.query.view == "string" ? a.query.view : "",
1992
- set: (o) => {
2023
+ set: (u) => {
1993
2024
  s.replace({
1994
- query: { ...a.query, view: o === "" ? void 0 : String(o), page: void 0 }
2025
+ query: { ...a.query, view: u === "" ? void 0 : String(u), page: void 0 }
1995
2026
  });
1996
2027
  }
1997
- }), T = h(() => m.value?.filters ?? { total: 0, empty: 0, noindex: 0 }), N = h(() => [
1998
- { value: "", label: t("tag.view-all"), badge: T.value.total },
1999
- { value: "empty", label: t("tag.view-empty"), badge: T.value.empty },
2000
- { value: "noindex", label: t("tag.view-noindex"), badge: T.value.noindex }
2001
- ]), I = h(() => m.value?.data ?? []), b = h(() => I.value.filter((o) => $.value.includes(o.id))), P = h(() => [
2028
+ }), W = b(() => d.value?.filters ?? { total: 0, empty: 0, noindex: 0 }), U = b(() => [
2029
+ { value: "", label: t("tag.view-all"), badge: W.value.total },
2030
+ { value: "empty", label: t("tag.view-empty"), badge: W.value.empty },
2031
+ { value: "noindex", label: t("tag.view-noindex"), badge: W.value.noindex }
2032
+ ]), I = b(() => d.value?.data ?? []), g = b(() => I.value.filter((u) => T.value.includes(u.id))), B = b(() => [
2002
2033
  { key: "title", label: t("tag.column-title"), minWidth: 150, sortable: !0 },
2003
2034
  // The number is what the other columns and the narrowest the title may be add up to without
2004
2035
  // this one: below it the address is what does not fit, and a fixed table does not shrink —
@@ -2016,106 +2047,106 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
2016
2047
  // at 180px of text, and a cell keeps 32 of its own. Narrower, the ruled row wrapped and
2017
2048
  // stood eighteen pixels taller than the ones around it.
2018
2049
  { key: "indexing", label: t("tag.column-indexing"), width: 230, hideBelow: 560 },
2019
- { key: "actions", label: "", width: Ye, align: "right" }
2050
+ { key: "actions", label: "", width: et, align: "right" }
2020
2051
  ]);
2021
- function E(o) {
2052
+ function D(u) {
2022
2053
  return {
2023
- q: o?.search ?? (typeof a.query.q == "string" ? a.query.q : ""),
2024
- empty: w.value === "empty",
2025
- noindex: w.value === "noindex",
2054
+ q: u?.search ?? (typeof a.query.q == "string" ? a.query.q : ""),
2055
+ empty: x.value === "empty",
2056
+ noindex: x.value === "noindex",
2026
2057
  // Only when it is not the default: most used first is what the list is, and a query
2027
2058
  // string that repeats the default is a link that outlives a change of mind about it.
2028
- sort: Y(o),
2029
- page: o?.page ?? (Number(a.query.page ?? 1) || 1),
2030
- per_page: o?.perPage
2059
+ sort: me(u),
2060
+ page: u?.page ?? (Number(a.query.page ?? 1) || 1),
2061
+ per_page: u?.perPage
2031
2062
  };
2032
2063
  }
2033
- async function Z(o) {
2034
- y.value = !0;
2064
+ async function H(u) {
2065
+ w.value = !0;
2035
2066
  try {
2036
- m.value = await f.tagsPage(E(o));
2037
- } catch (A) {
2038
- R.danger(i(A));
2067
+ d.value = await f.tagsPage(D(u));
2068
+ } catch (V) {
2069
+ P.danger(i(V));
2039
2070
  } finally {
2040
- y.value = !1;
2071
+ w.value = !1;
2041
2072
  }
2042
2073
  }
2043
- function Y(o) {
2044
- const A = o?.sort ?? se();
2045
- if (!A) return;
2046
- const S = A.key === "title" ? "name" : "articles", ee = `${A.order === "desc" ? "-" : ""}${S}`;
2047
- return ee === "articles" ? void 0 : ee;
2074
+ function me(u) {
2075
+ const V = u?.sort ?? Q();
2076
+ if (!V) return;
2077
+ const k = V.key === "title" ? "name" : "articles", ae = `${V.order === "desc" ? "-" : ""}${k}`;
2078
+ return ae === "articles" ? void 0 : ae;
2048
2079
  }
2049
- function se() {
2050
- const o = typeof a.query.sort == "string" ? a.query.sort : "";
2051
- if (o === "") return null;
2052
- const A = o.startsWith("-");
2053
- return { key: (A ? o.slice(1) : o) === "name" ? "title" : "articles_count", order: A ? "desc" : "asc" };
2080
+ function Q() {
2081
+ const u = typeof a.query.sort == "string" ? a.query.sort : "";
2082
+ if (u === "") return null;
2083
+ const V = u.startsWith("-");
2084
+ return { key: (V ? u.slice(1) : u) === "name" ? "title" : "articles_count", order: V ? "desc" : "asc" };
2054
2085
  }
2055
- function re(o) {
2056
- const A = {
2086
+ function ke(u) {
2087
+ const V = {
2057
2088
  ...a.query,
2058
- q: o.search === "" ? void 0 : o.search,
2059
- sort: Y(o),
2060
- page: o.page === 1 ? void 0 : String(o.page)
2089
+ q: u.search === "" ? void 0 : u.search,
2090
+ sort: me(u),
2091
+ page: u.page === 1 ? void 0 : String(u.page)
2061
2092
  };
2062
- s.replace({ query: A }), Z(o);
2093
+ s.replace({ query: V }), H(u);
2063
2094
  }
2064
- ve(w, () => {
2065
- $.value = [], Z();
2066
- }), Z();
2067
- async function O() {
2068
- await V({}) && await Z();
2095
+ pe(x, () => {
2096
+ T.value = [], H();
2097
+ }), H();
2098
+ async function X() {
2099
+ await S({}) && await H();
2069
2100
  }
2070
- async function ye(o) {
2071
- const A = await W({ name: o.title });
2072
- A && await te(o, { title: A }, t("tag.renamed"));
2101
+ async function G(u) {
2102
+ const V = await y({ name: u.title });
2103
+ V && await ge(u, { title: V }, t("tag.renamed"));
2073
2104
  }
2074
- async function we(o, A) {
2075
- await te(o, { noindex: A }, t(A ? "tag.kept-out" : "tag.indexed"));
2105
+ async function $e(u, V) {
2106
+ await ge(u, { noindex: V }, t(V ? "tag.kept-out" : "tag.indexed"));
2076
2107
  }
2077
- async function te(o, A, S) {
2108
+ async function ge(u, V, k) {
2078
2109
  try {
2079
- const ee = await f.saveTag(o.id, A);
2080
- m.value && (m.value = {
2081
- ...m.value,
2082
- data: m.value.data.map((n) => n.id === ee.id ? ee : n)
2083
- }), R.success(S);
2084
- } catch (ee) {
2085
- R.danger(i(ee));
2110
+ const ae = await f.saveTag(u.id, V);
2111
+ d.value && (d.value = {
2112
+ ...d.value,
2113
+ data: d.value.data.map((n) => n.id === ae.id ? ae : n)
2114
+ }), P.success(k);
2115
+ } catch (ae) {
2116
+ P.danger(i(ae));
2086
2117
  }
2087
2118
  }
2088
- async function fe(o) {
2089
- if (await de({
2090
- title: t("tag.delete-title", { title: o.title }),
2091
- message: o.articles_count > 0 ? t("tag.delete-text-used", { count: o.articles_count }) : t("tag.delete-text"),
2119
+ async function ce(u) {
2120
+ if (await oe({
2121
+ title: t("tag.delete-title", { title: u.title }),
2122
+ message: u.articles_count > 0 ? t("tag.delete-text-used", { count: u.articles_count }) : t("tag.delete-text"),
2092
2123
  confirmText: t("tag.delete"),
2093
2124
  cancelText: t("tag.cancel"),
2094
2125
  tone: "danger"
2095
2126
  }))
2096
2127
  try {
2097
- await f.removeTag(o.id), R.success(t("tag.deleted")), $.value = $.value.filter((S) => S !== o.id), await Z();
2098
- } catch (S) {
2099
- R.danger(i(S));
2128
+ await f.removeTag(u.id), P.success(t("tag.deleted")), T.value = T.value.filter((k) => k !== u.id), await H();
2129
+ } catch (k) {
2130
+ P.danger(i(k));
2100
2131
  }
2101
2132
  }
2102
- const Se = h(() => [
2133
+ const fe = b(() => [
2103
2134
  {
2104
2135
  key: "index",
2105
2136
  icon: "eye",
2106
2137
  label: t("tag.index"),
2107
- disabled: d.value,
2138
+ disabled: A.value,
2108
2139
  run: () => {
2109
- ae("index");
2140
+ Y("index");
2110
2141
  }
2111
2142
  },
2112
2143
  {
2113
2144
  key: "noindex",
2114
2145
  icon: "eye-off",
2115
2146
  label: t("tag.noindex"),
2116
- disabled: d.value,
2147
+ disabled: A.value,
2117
2148
  run: () => {
2118
- ae("noindex");
2149
+ Y("noindex");
2119
2150
  }
2120
2151
  },
2121
2152
  {
@@ -2123,134 +2154,134 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
2123
2154
  icon: "trash",
2124
2155
  label: t("tag.delete"),
2125
2156
  danger: !0,
2126
- disabled: d.value,
2157
+ disabled: A.value,
2127
2158
  run: () => {
2128
- ae("delete");
2159
+ Y("delete");
2129
2160
  }
2130
2161
  }
2131
2162
  ]);
2132
- function $e(o) {
2133
- if (!D.value) return [];
2134
- const A = [
2163
+ function Se(u) {
2164
+ if (!E.value) return [];
2165
+ const V = [
2135
2166
  { key: "rename", icon: "edit", label: t("tag.rename"), run: () => {
2136
- ye(o);
2167
+ G(u);
2137
2168
  } }
2138
2169
  ];
2139
- return o.url && A.push({
2170
+ return u.url && V.push({
2140
2171
  key: "site",
2141
2172
  icon: "external-link",
2142
2173
  label: t("tag.open-on-site"),
2143
- href: o.url
2144
- }), A.push({
2174
+ href: u.url
2175
+ }), V.push({
2145
2176
  key: "articles",
2146
2177
  icon: "list",
2147
2178
  label: t("tag.show-articles"),
2148
2179
  run: () => {
2149
- s.push({ path: `${c.base}/articles`, query: { tag: String(o.id) } });
2180
+ s.push({ path: `${c.base}/articles`, query: { tag: String(u.id) } });
2150
2181
  }
2151
- }), A.push(
2152
- o.noindex ? {
2182
+ }), V.push(
2183
+ u.noindex ? {
2153
2184
  key: "index",
2154
2185
  icon: "eye",
2155
2186
  label: t("tag.index"),
2156
2187
  run: () => {
2157
- we(o, !1);
2188
+ $e(u, !1);
2158
2189
  }
2159
2190
  } : {
2160
2191
  key: "noindex",
2161
2192
  icon: "eye-off",
2162
2193
  label: t("tag.noindex"),
2163
2194
  run: () => {
2164
- we(o, !0);
2195
+ $e(u, !0);
2165
2196
  }
2166
2197
  }
2167
- ), A.push({
2198
+ ), V.push({
2168
2199
  key: "delete",
2169
2200
  icon: "trash",
2170
2201
  label: t("tag.delete"),
2171
2202
  danger: !0,
2172
2203
  run: () => {
2173
- fe(o);
2204
+ ce(u);
2174
2205
  }
2175
- }), A;
2206
+ }), V;
2176
2207
  }
2177
- function oe(o) {
2178
- return o === "noindex" ? "muted" : "success";
2208
+ function be(u) {
2209
+ return u === "noindex" ? "muted" : "success";
2179
2210
  }
2180
- async function ce() {
2181
- if (b.value.length < 2) return;
2182
- const o = await z({ tags: b.value });
2183
- o && (R.success(t("tag.merged", { tag: o.tag.title, count: o.articles_count })), $.value = [], await Z());
2211
+ async function se() {
2212
+ if (g.value.length < 2) return;
2213
+ const u = await z({ tags: g.value });
2214
+ u && (P.success(t("tag.merged", { tag: u.tag.title, count: u.articles_count })), T.value = [], await H());
2184
2215
  }
2185
- async function ae(o) {
2186
- const A = b.value.map((S) => S.id);
2187
- if (!(A.length === 0 || d.value)) {
2188
- if (o === "delete") {
2189
- const S = b.value.reduce((n, U) => n + U.articles_count, 0);
2190
- if (!await de({
2191
- title: t("tag.delete-many-title", { count: A.length }),
2192
- message: S > 0 ? t("tag.delete-many-text-used", { count: S }) : t("tag.delete-many-text"),
2216
+ async function Y(u) {
2217
+ const V = g.value.map((k) => k.id);
2218
+ if (!(V.length === 0 || A.value)) {
2219
+ if (u === "delete") {
2220
+ const k = g.value.reduce((n, N) => n + N.articles_count, 0);
2221
+ if (!await oe({
2222
+ title: t("tag.delete-many-title", { count: V.length }),
2223
+ message: k > 0 ? t("tag.delete-many-text-used", { count: k }) : t("tag.delete-many-text"),
2193
2224
  confirmText: t("tag.delete"),
2194
2225
  cancelText: t("tag.cancel"),
2195
2226
  tone: "danger"
2196
2227
  })) return;
2197
2228
  }
2198
- d.value = !0;
2229
+ A.value = !0;
2199
2230
  try {
2200
- const S = await f.massTags(A, o);
2201
- R.success(
2202
- o === "delete" ? t("tag.deleted-many", { count: S }) : o === "index" ? t("tag.indexed-many", { count: S }) : t("tag.kept-out-many", { count: S })
2203
- ), $.value = [], await Z();
2204
- } catch (S) {
2205
- R.danger(i(S));
2231
+ const k = await f.massTags(V, u);
2232
+ P.success(
2233
+ u === "delete" ? t("tag.deleted-many", { count: k }) : u === "index" ? t("tag.indexed-many", { count: k }) : t("tag.kept-out-many", { count: k })
2234
+ ), T.value = [], await H();
2235
+ } catch (k) {
2236
+ P.danger(i(k));
2206
2237
  } finally {
2207
- d.value = !1;
2238
+ A.value = !1;
2208
2239
  }
2209
2240
  }
2210
2241
  }
2211
- const We = h(
2212
- () => D.value ? [{ key: "new", label: t("tag.new"), icon: "plus", primary: !0, run: () => {
2213
- O();
2242
+ const We = b(
2243
+ () => E.value ? [{ key: "new", label: t("tag.new"), icon: "plus", primary: !0, run: () => {
2244
+ X();
2214
2245
  } }] : []
2215
2246
  );
2216
- return (o, A) => (_(), H("div", Ta, [
2217
- r(e(et), {
2218
- view: w.value,
2219
- "onUpdate:view": A[1] || (A[1] = (S) => w.value = S),
2220
- title: B.value,
2221
- views: N.value,
2247
+ return (u, V) => (_(), j("div", Ca, [
2248
+ r(e(tt), {
2249
+ view: x.value,
2250
+ "onUpdate:view": V[1] || (V[1] = (k) => x.value = k),
2251
+ title: R.value,
2252
+ views: U.value,
2222
2253
  actions: We.value
2223
2254
  }, {
2224
2255
  default: l(() => [
2225
- r(e(it), {
2226
- selected: $.value,
2227
- "onUpdate:selected": A[0] || (A[0] = (S) => $.value = S),
2228
- data: m.value,
2229
- columns: P.value,
2256
+ r(e(nt), {
2257
+ selected: T.value,
2258
+ "onUpdate:selected": V[0] || (V[0] = (k) => T.value = k),
2259
+ data: d.value,
2260
+ columns: B.value,
2230
2261
  "row-key": "id",
2231
2262
  searchable: "",
2232
2263
  hover: "",
2233
2264
  flush: "",
2234
2265
  layout: "fixed",
2235
- loading: y.value,
2236
- selectable: D.value,
2237
- "select-row-label": e(u)("filters.select-row"),
2238
- "select-all-label": e(u)("filters.select-all"),
2266
+ loading: w.value,
2267
+ selectable: E.value,
2268
+ "select-row-label": e(o)("filters.select-row"),
2269
+ "select-all-label": e(o)("filters.select-all"),
2239
2270
  "cards-below": 0,
2240
2271
  "search-placeholder": e(t)("tag.search"),
2241
- "empty-text": I.value.length === 0 && !y.value ? e(t)("tag.empty") : void 0,
2242
- "aria-label": B.value,
2243
- onStateChange: re
2272
+ "empty-text": I.value.length === 0 && !w.value ? e(t)("tag.empty") : void 0,
2273
+ "aria-label": R.value,
2274
+ onStateChange: ke
2244
2275
  }, {
2245
- "cell-title": l(({ row: S }) => [
2276
+ "cell-title": l(({ row: k }) => [
2246
2277
  r(e(le), { truncate: "" }, {
2247
2278
  default: l(() => [
2248
- C(k(S.title), 1)
2279
+ C($(k.title), 1)
2249
2280
  ]),
2250
2281
  _: 2
2251
2282
  }, 1024)
2252
2283
  ]),
2253
- "cell-path": l(({ row: S }) => [
2284
+ "cell-path": l(({ row: k }) => [
2254
2285
  r(e(le), {
2255
2286
  size: "sm",
2256
2287
  tone: "muted",
@@ -2258,33 +2289,33 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
2258
2289
  truncate: ""
2259
2290
  }, {
2260
2291
  default: l(() => [
2261
- C(k(S.path ?? e(t)("tag.no-address")), 1)
2292
+ C($(k.path ?? e(t)("tag.no-address")), 1)
2262
2293
  ]),
2263
2294
  _: 2
2264
2295
  }, 1024)
2265
2296
  ]),
2266
- "cell-articles_count": l(({ row: S }) => [
2297
+ "cell-articles_count": l(({ row: k }) => [
2267
2298
  r(e(le), {
2268
- tone: S.articles_count === 0 ? "muted" : "default"
2299
+ tone: k.articles_count === 0 ? "muted" : "default"
2269
2300
  }, {
2270
2301
  default: l(() => [
2271
- C(k(S.articles_count), 1)
2302
+ C($(k.articles_count), 1)
2272
2303
  ]),
2273
2304
  _: 2
2274
2305
  }, 1032, ["tone"])
2275
2306
  ]),
2276
- "cell-indexing": l(({ row: S }) => [
2277
- S.indexing === "rule" ? (_(), q(e(nt), {
2307
+ "cell-indexing": l(({ row: k }) => [
2308
+ k.indexing === "rule" ? (_(), q(e(st), {
2278
2309
  key: 0,
2279
2310
  content: e(t)("tag.indexing-rule-help")
2280
2311
  }, {
2281
2312
  default: l(() => [
2282
2313
  r(e(le), {
2283
2314
  size: "sm",
2284
- tone: oe(S.indexing)
2315
+ tone: be(k.indexing)
2285
2316
  }, {
2286
2317
  default: l(() => [
2287
- C(k(e(t)("tag.indexing-rule")), 1)
2318
+ C($(e(t)("tag.indexing-rule")), 1)
2288
2319
  ]),
2289
2320
  _: 1
2290
2321
  }, 8, ["tone"])
@@ -2293,18 +2324,18 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
2293
2324
  }, 1032, ["content"])) : (_(), q(e(le), {
2294
2325
  key: 1,
2295
2326
  size: "sm",
2296
- tone: oe(S.indexing)
2327
+ tone: be(k.indexing)
2297
2328
  }, {
2298
2329
  default: l(() => [
2299
- C(k(e(t)(`tag.indexing-${S.indexing}`)), 1)
2330
+ C($(e(t)(`tag.indexing-${k.indexing}`)), 1)
2300
2331
  ]),
2301
2332
  _: 2
2302
2333
  }, 1032, ["tone"]))
2303
2334
  ]),
2304
- "cell-actions": l(({ row: S }) => [
2335
+ "cell-actions": l(({ row: k }) => [
2305
2336
  r(e(ze), {
2306
- actions: $e(S),
2307
- label: S.title
2337
+ actions: Se(k),
2338
+ label: k.title
2308
2339
  }, null, 8, ["actions", "label"])
2309
2340
  ]),
2310
2341
  _: 1
@@ -2312,7 +2343,7 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
2312
2343
  ]),
2313
2344
  _: 1
2314
2345
  }, 8, ["view", "title", "views", "actions"]),
2315
- b.value.length > 0 ? (_(), q(e(lt), {
2346
+ g.value.length > 0 ? (_(), q(e(it), {
2316
2347
  key: 0,
2317
2348
  class: "wx-tags__bar",
2318
2349
  sticky: ""
@@ -2320,46 +2351,46 @@ const Nt = { class: "wx-article-editor__screen" }, qt = 1200, It = /* @__PURE__
2320
2351
  state: l(() => [
2321
2352
  r(e(le), { weight: "medium" }, {
2322
2353
  default: l(() => [
2323
- C(k(e(t)("tag.selected", { count: b.value.length })), 1)
2354
+ C($(e(t)("tag.selected", { count: g.value.length })), 1)
2324
2355
  ]),
2325
2356
  _: 1
2326
2357
  })
2327
2358
  ]),
2328
2359
  default: l(() => [
2329
- r(e(G), {
2360
+ r(e(J), {
2330
2361
  type: "primary",
2331
- disabled: b.value.length < 2 || d.value,
2332
- onClick: ce
2362
+ disabled: g.value.length < 2 || A.value,
2363
+ onClick: se
2333
2364
  }, {
2334
2365
  icon: l(() => [
2335
2366
  r(e(Te), { name: "link" })
2336
2367
  ]),
2337
2368
  default: l(() => [
2338
- C(" " + k(e(t)("tag.merge")), 1)
2369
+ C(" " + $(e(t)("tag.merge")), 1)
2339
2370
  ]),
2340
2371
  _: 1
2341
2372
  }, 8, ["disabled"]),
2342
2373
  r(e(ze), {
2343
2374
  size: "lg",
2344
- actions: Se.value,
2345
- label: e(t)("tag.selected", { count: b.value.length })
2375
+ actions: fe.value,
2376
+ label: e(t)("tag.selected", { count: g.value.length })
2346
2377
  }, null, 8, ["actions", "label"])
2347
2378
  ]),
2348
2379
  _: 1
2349
- })) : K("", !0)
2380
+ })) : L("", !0)
2350
2381
  ]));
2351
2382
  }
2352
- }), Sa = /* @__PURE__ */ ge(Aa, [["__scopeId", "data-v-d9b8d73d"]]);
2353
- function Wa(g = "/blog") {
2383
+ }), za = /* @__PURE__ */ ve(Va, [["__scopeId", "data-v-d9b8d73d"]]);
2384
+ function Ma(h = "/blog") {
2354
2385
  return {
2355
2386
  api: "blog/rubrics",
2356
- path: `${g}/rubrics`,
2387
+ path: `${h}/rubrics`,
2357
2388
  name: "webx.blog.rubrics",
2358
2389
  module: "rubrics",
2359
2390
  screen: "blog.category-form",
2360
2391
  manage: "blog.taxonomy.manage",
2361
2392
  count: "articles_count",
2362
- items: (c) => ({ path: `${g}/articles`, query: { rubric: String(c) } }),
2393
+ items: (c) => ({ path: `${h}/articles`, query: { rubric: String(c) } }),
2363
2394
  words: {
2364
2395
  new: "webx-blog::rubric.new",
2365
2396
  empty: "webx-blog::rubric.empty",
@@ -2379,8 +2410,8 @@ function Wa(g = "/blog") {
2379
2410
  }
2380
2411
  };
2381
2412
  }
2382
- function Na(g = {}) {
2383
- const c = g.path ?? "/blog";
2413
+ function Da(h = {}) {
2414
+ const c = h.path ?? "/blog";
2384
2415
  return [
2385
2416
  {
2386
2417
  id: "articles",
@@ -2391,13 +2422,13 @@ function Na(g = {}) {
2391
2422
  {
2392
2423
  path: `${c}/articles`,
2393
2424
  name: "webx.blog.articles",
2394
- component: ha,
2425
+ component: wa,
2395
2426
  props: { base: c }
2396
2427
  },
2397
2428
  {
2398
2429
  path: `${c}/articles/:id(\\d+)`,
2399
2430
  name: "webx.blog.articles.edit",
2400
- component: Pt,
2431
+ component: Et,
2401
2432
  props: { base: c }
2402
2433
  }
2403
2434
  ],
@@ -2416,12 +2447,12 @@ function Na(g = {}) {
2416
2447
  * description — it is configuration the editor was handed with the record.
2417
2448
  */
2418
2449
  types: {
2419
- "wx-article-slug": { component: Xt, kind: "field" },
2420
- "wx-article-author": { component: Ut, kind: "field" },
2421
- "wx-article-tags": { component: ia, kind: "field" },
2422
- "wx-article-related": { component: jt, kind: "field" },
2423
- "wx-article-unpublish": { component: sa, kind: "display" },
2424
- "wx-article-history": { component: Ot, kind: "display" }
2450
+ "wx-article-slug": { component: aa, kind: "field" },
2451
+ "wx-article-author": { component: Pt, kind: "field" },
2452
+ "wx-article-tags": { component: oa, kind: "field" },
2453
+ "wx-article-related": { component: Xt, kind: "field" },
2454
+ "wx-article-unpublish": { component: ca, kind: "display" },
2455
+ "wx-article-history": { component: Ht, kind: "display" }
2425
2456
  }
2426
2457
  },
2427
2458
  {
@@ -2429,7 +2460,7 @@ function Na(g = {}) {
2429
2460
  path: `${c}/rubrics`,
2430
2461
  // The list and the page of one rubric are the panel's shared category screens (§3.6 of
2431
2462
  // the services spec); what is the blog's is the description they are handed.
2432
- routes: gt(Wa(c))
2463
+ routes: bt(Ma(c))
2433
2464
  },
2434
2465
  {
2435
2466
  id: "tags",
@@ -2438,7 +2469,7 @@ function Na(g = {}) {
2438
2469
  {
2439
2470
  path: `${c}/tags`,
2440
2471
  name: "webx.blog.tags",
2441
- component: Sa,
2472
+ component: za,
2442
2473
  props: { base: c }
2443
2474
  }
2444
2475
  ]
@@ -2446,24 +2477,24 @@ function Na(g = {}) {
2446
2477
  ];
2447
2478
  }
2448
2479
  export {
2449
- Ut as WxArticleAuthorField,
2450
- ra as WxArticleCreateDialog,
2451
- Pt as WxArticleEditorPage,
2452
- Ot as WxArticleHistory,
2453
- jt as WxArticleRelated,
2454
- Xt as WxArticleSlug,
2455
- ia as WxArticleTags,
2456
- sa as WxArticleUnpublish,
2457
- ha as WxArticlesPage,
2458
- ma as WxTagCreateDialog,
2459
- $a as WxTagMergeDialog,
2460
- Sa as WxTagsPage,
2461
- st as articleEditorKey,
2462
- Na as blog,
2463
- Mt as blogMessages,
2480
+ Pt as WxArticleAuthorField,
2481
+ da as WxArticleCreateDialog,
2482
+ Et as WxArticleEditorPage,
2483
+ Ht as WxArticleHistory,
2484
+ Xt as WxArticleRelated,
2485
+ aa as WxArticleSlug,
2486
+ oa as WxArticleTags,
2487
+ ca as WxArticleUnpublish,
2488
+ wa as WxArticlesPage,
2489
+ xa as WxTagCreateDialog,
2490
+ Wa as WxTagMergeDialog,
2491
+ za as WxTagsPage,
2492
+ rt as articleEditorKey,
2493
+ Da as blog,
2494
+ It as blogMessages,
2464
2495
  ue as createBlogApi,
2465
- zt as provideArticleEditor,
2466
- Wa as rubricsOptions,
2496
+ qt as provideArticleEditor,
2497
+ Ma as rubricsOptions,
2467
2498
  Ae as useArticleEditor
2468
2499
  };
2469
2500
  //# sourceMappingURL=index.js.map