@webx-ui/module-blocks 0.8.7 → 0.8.8

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,7 +1,7 @@
1
- import { defineComponent as ae, computed as L, openBlock as c, createElementBlock as C, createVNode as m, unref as n, createElementVNode as A, createTextVNode as M, toDisplayString as S, Fragment as F, createCommentVNode as D, renderList as le, ref as I, onMounted as Re, watch as te, createBlock as z, withCtx as b, onBeforeUnmount as Xe, normalizeStyle as xe, reactive as st, normalizeClass as $e, withDirectives as al, vShow as il, inject as De, watchEffect as rl, resolveComponent as At, isRef as Vt, nextTick as ul, withKeys as ht, withModifiers as bt, provide as Bt, useModel as cl, getCurrentInstance as dl, resolveDynamicComponent as pl, mergeProps as fl, mergeModels as ml } from "vue";
1
+ import { defineComponent as ae, computed as L, openBlock as d, createElementBlock as C, createVNode as m, unref as n, createElementVNode as A, createTextVNode as M, toDisplayString as S, Fragment as F, createCommentVNode as D, renderList as le, ref as I, onMounted as Re, watch as te, createBlock as z, withCtx as b, onBeforeUnmount as Xe, normalizeStyle as xe, reactive as st, normalizeClass as $e, withDirectives as al, vShow as il, inject as De, watchEffect as rl, resolveComponent as At, isRef as Vt, nextTick as ul, withKeys as ht, withModifiers as bt, provide as Bt, useModel as cl, getCurrentInstance as dl, resolveDynamicComponent as pl, mergeProps as fl, mergeModels as ml } from "vue";
2
2
  import { useRoute as vl, useRouter as Wt } from "vue-router";
3
3
  import { useTranslate as de, useAdmin as je, useErrorText as Fe, WxDate as hl, WxScreenHead as bl, WxRenameButton as gl, WxHelpButton as yl, adminKey as Mt, WxRowMenu as kl, WxListScreen as wl } from "@webx-ui/module-admin";
4
- import { WxIcon as he, WxSkeleton as Be, WxText as K, WxBadge as ue, WxButton as ce, confirm as Qe, toast as Z, useElementWidth as et, WxSegmented as Nt, WxCard as Ae, WxPopover as _l, WxAlert as zt, WxTabs as xl, WxTab as Ve, WxCodeEditor as Ye, WxFormItem as oe, WxInput as Ue, WxSelect as Dt, WxTextarea as $l, WxIconPicker as Sl, WxInputNumber as gt, WxTagsInput as yt, WxSwitch as El, WxActionBar as Tl, useModal as It, WxDialog as Ot, WxEmpty as Pt, WxAction as Ie, WxSortableList as Cl, createModal as Ut, WxDrawer as Ll, WxSpace as Al, WxSkeletonItem as qe } from "@webx-ui/core";
4
+ import { WxIcon as he, WxSkeleton as Be, WxText as q, WxBadge as ue, WxButton as ce, confirm as Qe, toast as Z, useElementWidth as et, WxSegmented as Nt, WxCard as Ae, WxPopover as _l, WxAlert as zt, WxTabs as xl, WxTab as Ve, WxCodeEditor as Ke, WxFormItem as oe, WxInput as Ue, WxSelect as Dt, WxTextarea as $l, WxIconPicker as Sl, WxInputNumber as gt, WxTagsInput as yt, WxSwitch as El, WxActionBar as Tl, useModal as It, WxDialog as Ot, WxEmpty as Pt, WxAction as Ie, WxSortableList as Cl, createModal as Ut, WxDrawer as Ll, WxSpace as Al, WxSkeletonItem as Ye } from "@webx-ui/core";
5
5
  import { WxScreenRenderer as Rt, coreTypes as Je } from "@webx-ui/schema";
6
6
  import { autocompletion as Vl, snippetCompletion as ve, pickedCompletion as dt, startCompletion as Bl } from "@codemirror/autocomplete";
7
7
  import { EditorState as Wl } from "@codemirror/state";
@@ -38,32 +38,32 @@ const Ml = { class: "wx-block-checks" }, Nl = {
38
38
  const i = new Set(s.value.map((r) => r.code)), o = [];
39
39
  return l.file === "template" && (i.has("no-marker") || o.push(t("checks.ok-marker")), i.has("variables-missing") || o.push(t("checks.ok-variables"))), l.file === "styles" && (i.has("stray-selectors") || o.push(t("checks.ok-prefix", { slug: l.slug })), i.has("bare-selectors") || o.push(t("checks.ok-bare")), i.has("media-query") || o.push(t("checks.ok-container"))), o;
40
40
  });
41
- return (i, o) => (c(), C("div", Ml, [
42
- e.error ? (c(), C("div", Nl, [
41
+ return (i, o) => (d(), C("div", Ml, [
42
+ e.error ? (d(), C("div", Nl, [
43
43
  m(n(he), { name: "close-circle" }),
44
44
  A("span", null, [
45
45
  M(S(e.error.message) + " ", 1),
46
- e.error.line !== null ? (c(), C(F, { key: 0 }, [
46
+ e.error.line !== null ? (d(), C(F, { key: 0 }, [
47
47
  M(" · " + S(n(t)("page.line", { line: e.error.line })), 1)
48
48
  ], 64)) : D("", !0),
49
- e.error.where ? (c(), C(F, { key: 1 }, [
49
+ e.error.where ? (d(), C(F, { key: 1 }, [
50
50
  M(" · " + S(e.error.where), 1)
51
51
  ], 64)) : D("", !0)
52
52
  ])
53
53
  ])) : D("", !0),
54
- (c(!0), C(F, null, le(s.value, (r) => (c(), C("div", {
54
+ (d(!0), C(F, null, le(s.value, (r) => (d(), C("div", {
55
55
  key: r.code,
56
56
  class: "wx-block-checks__line is-warning"
57
57
  }, [
58
58
  m(n(he), { name: "warning" }),
59
59
  A("span", null, [
60
60
  M(S(r.message) + " ", 1),
61
- r.line !== null ? (c(), C(F, { key: 0 }, [
61
+ r.line !== null ? (d(), C(F, { key: 0 }, [
62
62
  M(" · " + S(n(t)("page.line", { line: r.line })), 1)
63
63
  ], 64)) : D("", !0)
64
64
  ])
65
65
  ]))), 128)),
66
- (c(!0), C(F, null, le(a.value, (r) => (c(), C("div", {
66
+ (d(!0), C(F, null, le(a.value, (r) => (d(), C("div", {
67
67
  key: r,
68
68
  class: "wx-block-checks__line is-ok"
69
69
  }, [
@@ -85,9 +85,9 @@ const Ml = { class: "wx-block-checks" }, Nl = {
85
85
  },
86
86
  emits: ["restored"],
87
87
  setup(e, { emit: l }) {
88
- const t = e, s = l, a = je(), i = Me(a), o = de("webx-blocks"), r = Fe(), d = I(null);
88
+ const t = e, s = l, a = je(), i = Me(a), o = de("webx-blocks"), r = Fe(), c = I(null);
89
89
  async function u() {
90
- d.value = await i.versions(t.block.id);
90
+ c.value = await i.versions(t.block.id);
91
91
  }
92
92
  function p(v) {
93
93
  return t.block.draft?.number === v.number ? "draft" : t.block.published?.number === v.number ? "live" : "replaced";
@@ -111,41 +111,41 @@ const Ml = { class: "wx-block-checks" }, Nl = {
111
111
  () => {
112
112
  u();
113
113
  }
114
- ), (v, g) => (c(), C("div", Dl, [
115
- d.value === null ? (c(), z(n(Be), {
114
+ ), (v, g) => (d(), C("div", Dl, [
115
+ c.value === null ? (d(), z(n(Be), {
116
116
  key: 0,
117
117
  class: "wx-block-history__ghost",
118
118
  rows: 3
119
- })) : (c(!0), C(F, { key: 1 }, le(d.value, (x) => (c(), C("div", {
119
+ })) : (d(!0), C(F, { key: 1 }, le(c.value, (x) => (d(), C("div", {
120
120
  key: x.number,
121
121
  class: "wx-block-history__row"
122
122
  }, [
123
123
  A("code", Il, S(n(o)("page.version", { number: x.number })), 1),
124
124
  A("div", Ol, [
125
- m(n(K), null, {
125
+ m(n(q), null, {
126
126
  default: b(() => [
127
127
  M(S(n(o)(`page.version-${p(x)}`)), 1)
128
128
  ]),
129
129
  _: 2
130
130
  }, 1024),
131
- m(n(K), {
131
+ m(n(q), {
132
132
  size: "sm",
133
133
  tone: "muted"
134
134
  }, {
135
135
  default: b(() => [
136
- x.created_at ? (c(), z(n(hl), {
136
+ x.created_at ? (d(), z(n(hl), {
137
137
  key: 0,
138
138
  value: x.created_at
139
139
  }, null, 8, ["value"])) : D("", !0),
140
140
  M(" · " + S(x.author ?? n(o)(`page.source-${x.source}`)) + " ", 1),
141
- x.comment ? (c(), C(F, { key: 1 }, [
141
+ x.comment ? (d(), C(F, { key: 1 }, [
142
142
  M(" · " + S(x.comment), 1)
143
143
  ], 64)) : D("", !0)
144
144
  ]),
145
145
  _: 2
146
146
  }, 1024)
147
147
  ]),
148
- p(x) === "draft" ? (c(), z(n(ue), {
148
+ p(x) === "draft" ? (d(), z(n(ue), {
149
149
  key: 0,
150
150
  type: "warning",
151
151
  dot: ""
@@ -154,7 +154,7 @@ const Ml = { class: "wx-block-checks" }, Nl = {
154
154
  M(S(n(o)("page.version-draft")), 1)
155
155
  ]),
156
156
  _: 1
157
- })) : p(x) === "live" ? (c(), z(n(ue), {
157
+ })) : p(x) === "live" ? (d(), z(n(ue), {
158
158
  key: 1,
159
159
  type: "success",
160
160
  dot: ""
@@ -164,7 +164,7 @@ const Ml = { class: "wx-block-checks" }, Nl = {
164
164
  ]),
165
165
  _: 1
166
166
  })) : D("", !0),
167
- e.canManage && p(x) === "replaced" ? (c(), z(n(ce), {
167
+ e.canManage && p(x) === "replaced" ? (d(), z(n(ce), {
168
168
  key: 2,
169
169
  size: "sm",
170
170
  variant: "outline",
@@ -209,8 +209,8 @@ function Ft(e, l, t) {
209
209
  if (a.removeChild(r), v) break;
210
210
  r = f;
211
211
  }
212
- const d = i.content, u = Array.from(d.childNodes);
213
- a.insertBefore(d, o);
212
+ const c = i.content, u = Array.from(c.childNodes);
213
+ a.insertBefore(c, o);
214
214
  const p = e.defaultView?.webx;
215
215
  if (p?.mount)
216
216
  for (const f of u)
@@ -317,9 +317,9 @@ function Ht(e) {
317
317
  const l = e.base ? `<base href="${rt(e.base)}">` : "", t = e.frame ? `<style>${e.frame}</style>` : "", s = e.script && e.runtime ? `<script src="${rt(e.runtime)}"><\/script><script>${e.script}<\/script>` : "";
318
318
  return `<!doctype html><html><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1">${l}<style>html,body{margin:0}body{container-type:inline-size}</style>${t}<style>${e.styles}</style></head><body>${e.html}${s}</body></html>`;
319
319
  }
320
- const Kt = "<!--wx-thumb-->";
321
- function Kl(e, l) {
322
- const t = new DOMParser().parseFromString(e, "text/html"), s = ql(t, `wx:${Ze}`);
320
+ const qt = "<!--wx-thumb-->";
321
+ function ql(e, l) {
322
+ const t = new DOMParser().parseFromString(e, "text/html"), s = Yl(t, `wx:${Ze}`);
323
323
  if (s === null) return null;
324
324
  const a = (u) => u === null ? null : new URL(u, new URL(l, location.href)).href, i = [];
325
325
  for (const u of Array.from(t.head.children)) {
@@ -331,18 +331,18 @@ function Kl(e, l) {
331
331
  v.setAttribute("href", a(u.getAttribute("href")) ?? ""), i.push(v.outerHTML);
332
332
  }
333
333
  }
334
- let o = Kt, r = s.parentElement;
334
+ let o = qt, r = s.parentElement;
335
335
  for (; r !== null && r !== t.body && r !== t.documentElement; ) {
336
336
  const u = r.cloneNode(!1);
337
337
  u.innerHTML = o, o = u.outerHTML, r = r.parentElement;
338
338
  }
339
- const d = (u) => Array.from(u.attributes).map((p) => ` ${p.name}="${rt(p.value)}"`).join("");
340
- return `<!doctype html><html${d(t.documentElement)}><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1">${i.join("")}</head><body${d(t.body)}>${o}</body></html>`;
339
+ const c = (u) => Array.from(u.attributes).map((p) => ` ${p.name}="${rt(p.value)}"`).join("");
340
+ return `<!doctype html><html${c(t.documentElement)}><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1">${i.join("")}</head><body${c(t.body)}>${o}</body></html>`;
341
341
  }
342
- function Yl(e, l) {
343
- return e.replace("</head>", () => `<style>${l.styles}</style></head>`).replace(Kt, () => l.html);
342
+ function Kl(e, l) {
343
+ return e.replace("</head>", () => `<style>${l.styles}</style></head>`).replace(qt, () => l.html);
344
344
  }
345
- function ql(e, l) {
345
+ function Yl(e, l) {
346
346
  const t = e.createTreeWalker(e.body ?? e.documentElement, NodeFilter.SHOW_COMMENT);
347
347
  for (let s = t.nextNode(); s !== null; s = t.nextNode())
348
348
  if (s.data.trim() === l) return s;
@@ -366,7 +366,7 @@ const Jl = { class: "wx-block-stage" }, Gl = { class: "wx-block-stage__bar" }, Z
366
366
  { value: 1280, icon: "monitor", ariaLabel: t("page.width-desktop") },
367
367
  { value: 834, icon: "tablet", ariaLabel: t("page.width-tablet") },
368
368
  { value: 390, icon: "smartphone", ariaLabel: t("page.width-phone") }
369
- ]), a = I(1280), i = I(null), o = I(null), r = et(i), d = I(360), u = I(!1);
369
+ ]), a = I(1280), i = I(null), o = I(null), r = et(i), c = I(360), u = I(!1);
370
370
  te([r, s], () => {
371
371
  if (u.value || r.value === 0) return;
372
372
  const h = s.value.find((V) => r.value / V.value >= 0.45);
@@ -395,7 +395,7 @@ const Jl = { class: "wx-block-stage" }, Gl = { class: "wx-block-stage__bar" }, Z
395
395
  const h = o.value?.contentDocument?.body;
396
396
  if (!h) return;
397
397
  const V = h.ownerDocument.defaultView, O = V && parseFloat(V.getComputedStyle(h).marginBottom) || 0, J = h.getBoundingClientRect().bottom + O + (V?.scrollY ?? 0);
398
- d.value = Math.max(120, Math.ceil(Math.max(h.scrollHeight, J)));
398
+ c.value = Math.max(120, Math.ceil(Math.max(h.scrollHeight, J)));
399
399
  }
400
400
  let w = null, y = null;
401
401
  function _() {
@@ -404,7 +404,7 @@ const Jl = { class: "wx-block-stage" }, Gl = { class: "wx-block-stage__bar" }, Z
404
404
  function R(h) {
405
405
  l.stage && (l.script && x !== l.script && (x = l.script, Hl(h, l.script)), Fl(h, { html: l.html, styles: l.styles }));
406
406
  }
407
- function Y() {
407
+ function K() {
408
408
  _();
409
409
  const h = o.value?.contentDocument;
410
410
  if (!h?.body) return;
@@ -421,15 +421,15 @@ const Jl = { class: "wx-block-stage" }, Gl = { class: "wx-block-stage__bar" }, Z
421
421
  ), te(r, (h, V) => {
422
422
  h > 0 && V === 0 && setTimeout(T, 50);
423
423
  }), te(a, () => setTimeout(T, 50)), Xe(_);
424
- const q = L(() => ({
424
+ const Y = L(() => ({
425
425
  width: `${a.value}px`,
426
- height: `${d.value}px`,
426
+ height: `${c.value}px`,
427
427
  transform: `scale(${f.value})`
428
428
  })), X = L(() => ({
429
429
  width: `${Math.round(a.value * f.value)}px`,
430
- height: `${Math.round(d.value * f.value)}px`
430
+ height: `${Math.round(c.value * f.value)}px`
431
431
  }));
432
- return (h, V) => (c(), C("div", Jl, [
432
+ return (h, V) => (d(), C("div", Jl, [
433
433
  A("div", Gl, [
434
434
  m(n(Nt), {
435
435
  "model-value": a.value,
@@ -444,36 +444,36 @@ const Jl = { class: "wx-block-stage" }, Gl = { class: "wx-block-stage__bar" }, Z
444
444
  ref: i,
445
445
  class: "wx-block-stage__ground"
446
446
  }, [
447
- e.loading && !e.html ? (c(), z(n(Be), {
447
+ e.loading && !e.html ? (d(), z(n(Be), {
448
448
  key: 0,
449
449
  rows: 3
450
- })) : (c(), C("div", {
450
+ })) : (d(), C("div", {
451
451
  key: 1,
452
452
  class: "wx-block-stage__clip",
453
453
  style: xe(X.value)
454
454
  }, [
455
- (c(), C("iframe", {
455
+ (d(), C("iframe", {
456
456
  ref_key: "frame",
457
457
  ref: o,
458
458
  key: g.value,
459
459
  class: "wx-block-stage__frame",
460
460
  src: e.stage ?? void 0,
461
461
  srcdoc: v.value,
462
- style: xe(q.value),
462
+ style: xe(Y.value),
463
463
  sandbox: "allow-same-origin allow-scripts",
464
464
  title: n(t)("page.preview"),
465
- onLoad: Y
465
+ onLoad: K
466
466
  }, null, 44, Zl))
467
467
  ], 4))
468
468
  ], 512)
469
469
  ]));
470
470
  }
471
471
  }), Xl = /* @__PURE__ */ ie(Ql, [["__scopeId", "data-v-3185ee45"]]);
472
- function Yt(e) {
472
+ function Kt(e) {
473
473
  return typeof e == "object" && e !== null && typeof e.type == "string" && e.type !== "";
474
474
  }
475
475
  function tt(e) {
476
- return Array.isArray(e) && e.length > 0 && e.every(Yt);
476
+ return Array.isArray(e) && e.length > 0 && e.every(Kt);
477
477
  }
478
478
  function ut() {
479
479
  return (typeof crypto < "u" && "randomUUID" in crypto ? crypto.randomUUID().replace(/-/g, "") : Math.random().toString(36).slice(2) + Math.random().toString(36).slice(2)).slice(0, 12);
@@ -482,23 +482,23 @@ function en(e, l = {}) {
482
482
  return { key: ut(), type: e, values: l };
483
483
  }
484
484
  function re(e, l) {
485
- return qt(e, l, null, null);
485
+ return Yt(e, l, null, null);
486
486
  }
487
- function qt(e, l, t, s) {
487
+ function Yt(e, l, t, s) {
488
488
  for (let a = 0; a < e.length; a++) {
489
489
  const i = e[a];
490
490
  if (i.key === l) return { node: i, parent: t, field: s, list: e, index: a };
491
491
  for (const [o, r] of Object.entries(i.values ?? {}))
492
492
  if (tt(r)) {
493
- const d = qt(r, l, i, o);
494
- if (d) return d;
493
+ const c = Yt(r, l, i, o);
494
+ if (c) return c;
495
495
  }
496
496
  }
497
497
  return null;
498
498
  }
499
499
  function He(e, l, t = 0, s = null) {
500
500
  for (const a of e)
501
- if (Yt(a)) {
501
+ if (Kt(a)) {
502
502
  l(a, t, s);
503
503
  for (const i of Object.values(a.values ?? {}))
504
504
  tt(i) && He(i, l, t + 1, a);
@@ -516,7 +516,7 @@ function ln(e) {
516
516
  tt(t) && He(t, () => l++);
517
517
  return l;
518
518
  }
519
- function mo(e) {
519
+ function vo(e) {
520
520
  const l = [];
521
521
  return He(e, (t) => {
522
522
  l.includes(t.type) || l.push(t.type);
@@ -722,7 +722,7 @@ const un = {
722
722
  "ok-variables": "Every variable of the template is a field of the schema."
723
723
  }
724
724
  }, St = /* @__PURE__ */ new WeakSet();
725
- function Ke() {
725
+ function qe() {
726
726
  try {
727
727
  const { i18n: e } = je();
728
728
  St.has(e) || (e.defaults("webx-blocks", un), St.add(e));
@@ -741,33 +741,47 @@ const cn = [
741
741
  ], dn = ["key", "type", "version", "depth"], Zt = ["url", "alt", "title", "path"], pn = [...Zt, "thumb", "name", "extension", "mime", "size", "width", "height"], fn = ["wx-media"], mn = ["wx-gallery", "wx-files"], vn = ["items", "groups", "filter"], hn = {
742
742
  items: ["id", "anchor", "categories"],
743
743
  groups: ["id", "title", "items"]
744
+ }, bn = {
745
+ faq: ["question", "answer"],
746
+ services: ["title", "url", "lead", "cover", "fields"],
747
+ reviews: [
748
+ "name",
749
+ "initials",
750
+ "job_title",
751
+ "text",
752
+ "rating",
753
+ "date",
754
+ "profile",
755
+ "photo",
756
+ "fields"
757
+ ]
744
758
  };
745
- function bn({ schema: e, styles: l }) {
759
+ function gn({ schema: e, styles: l }) {
746
760
  return (t) => {
747
761
  const s = t.state.sliceDoc(Math.max(0, t.pos - 200), t.pos), a = /\$block->(\w*)$/.exec(s);
748
- if (a) return kn(t, a[1]);
762
+ if (a) return wn(t, a[1]);
749
763
  const i = /\$(\w+)\[\s*(['"]?)(\w*)$/.exec(s);
750
- if (i) return wn(t, i[1], i[2], i[3], e());
764
+ if (i) return _n(t, i[1], i[2], i[3], e());
751
765
  const o = /\$(\w*)$/.exec(s);
752
766
  if (o)
753
767
  return {
754
768
  from: t.pos - o[0].length,
755
- options: gn(e(), t.state.doc.toString()),
769
+ options: yn(e(), t.state.doc.toString()),
756
770
  validFor: /^\$\w*$/
757
771
  };
758
772
  const r = /(\{\{|\{!!)(\s*)(\w*)$/.exec(s);
759
- if (r) return yn(t, r[1], r[2], r[3], e());
760
- const d = /\bclass\s*=\s*"([^"]*)$/.exec(s);
761
- if (d) return xn(t, d[1], l());
773
+ if (r) return kn(t, r[1], r[2], r[3], e());
774
+ const c = /\bclass\s*=\s*"([^"]*)$/.exec(s);
775
+ if (c) return $n(t, c[1], l());
762
776
  const u = /(?:^|[\s>(])@(\w*)$/.exec(s);
763
777
  return u ? {
764
778
  from: t.pos - u[1].length - 1,
765
- options: $n(e()),
779
+ options: Sn(e()),
766
780
  validFor: /^@\w*$/
767
781
  } : null;
768
782
  };
769
783
  }
770
- function gn(e, l) {
784
+ function yn(e, l) {
771
785
  const t = el(e).map((s, a) => ({
772
786
  label: `$${s.id}`,
773
787
  detail: s.type,
@@ -781,21 +795,21 @@ function gn(e, l) {
781
795
  t.push({ label: `$${s}`, detail: "given", info: a, type: "variable", boost: -10 });
782
796
  return t.push({ label: "$loop", detail: "given", info: "inside @foreach", boost: -20 }), t;
783
797
  }
784
- function yn(e, l, t, s, a) {
798
+ function kn(e, l, t, s, a) {
785
799
  const i = el(a);
786
800
  if (i.length === 0) return null;
787
801
  const o = l === "{{" ? "}}" : "!!}";
788
802
  return {
789
803
  from: e.pos - s.length,
790
- options: i.map((r, d) => ({
804
+ options: i.map((r, c) => ({
791
805
  label: r.id,
792
806
  displayLabel: `$${r.id}`,
793
807
  detail: r.type,
794
808
  info: r.label,
795
809
  type: "variable",
796
- boost: 50 - d,
810
+ boost: 50 - c,
797
811
  apply: (u, p, f, v) => {
798
- const g = u.state.sliceDoc(v, v + 8), x = new RegExp(`^\\s*${Vn(o)}`).exec(g), T = x ? /^\s/.test(g) ? "" : " " : ` ${o}`, w = `${t === "" ? " " : ""}$${r.id}${T}`;
812
+ const g = u.state.sliceDoc(v, v + 8), x = new RegExp(`^\\s*${Bn(o)}`).exec(g), T = x ? /^\s/.test(g) ? "" : " " : ` ${o}`, w = `${t === "" ? " " : ""}$${r.id}${T}`;
799
813
  u.dispatch({
800
814
  changes: { from: f, to: v, insert: w },
801
815
  // Past the closing braces: the echo is finished, the next thing is the markup.
@@ -808,7 +822,7 @@ function yn(e, l, t, s, a) {
808
822
  validFor: /^\w*$/
809
823
  };
810
824
  }
811
- function kn(e, l) {
825
+ function wn(e, l) {
812
826
  return {
813
827
  from: e.pos - l.length,
814
828
  options: [
@@ -822,17 +836,17 @@ function kn(e, l) {
822
836
  validFor: /^\w*$/
823
837
  };
824
838
  }
825
- function wn(e, l, t, s, a) {
826
- const i = _n(l, a, e.state.doc.toString());
839
+ function _n(e, l, t, s, a) {
840
+ const i = xn(l, a, e.state.doc.toString());
827
841
  return i.length === 0 ? null : {
828
842
  from: e.pos - s.length,
829
843
  options: i.map(([o, r]) => ({
830
844
  label: o,
831
845
  detail: r,
832
846
  type: "property",
833
- apply: (d, u, p, f) => {
834
- const v = t ? p - 1 : p, g = d.state.sliceDoc(f, f + 2), x = t || "'", T = f + (g.startsWith(x) ? 1 : 0), w = d.state.sliceDoc(T, T + 1) === "]", y = `${x}${o}${x}${w ? "" : "]"}`;
835
- d.dispatch({
847
+ apply: (c, u, p, f) => {
848
+ const v = t ? p - 1 : p, g = c.state.sliceDoc(f, f + 2), x = t || "'", T = f + (g.startsWith(x) ? 1 : 0), w = c.state.sliceDoc(T, T + 1) === "]", y = `${x}${o}${x}${w ? "" : "]"}`;
849
+ c.dispatch({
836
850
  changes: { from: v, to: T, insert: y },
837
851
  selection: { anchor: v + y.length + (w ? 1 : 0) },
838
852
  annotations: dt.of(u),
@@ -843,17 +857,17 @@ function wn(e, l, t, s, a) {
843
857
  validFor: /^\w*$/
844
858
  };
845
859
  }
846
- function _n(e, l, t) {
847
- const s = We(l).find((d) => d.id === e);
848
- if (s && fn.includes(s.type)) return Zt.map((d) => [d, s.type]);
849
- if (s?.type === "wx-collection") return vn.map((d) => [d, s.type]);
850
- const a = Qt(t).get(e), [i, o] = a?.split(".") ?? [], r = i ? We(l).find((d) => d.id === i) : void 0;
860
+ function xn(e, l, t) {
861
+ const s = We(l).find((c) => c.id === e);
862
+ if (s && fn.includes(s.type)) return Zt.map((c) => [c, s.type]);
863
+ if (s?.type === "wx-collection") return vn.map((c) => [c, s.type]);
864
+ const a = Qt(t).get(e), [i, o] = a?.split(".") ?? [], r = i ? We(l).find((c) => c.id === i) : void 0;
851
865
  if (!r) return [];
852
866
  if (r.type === "wx-collection") {
853
- const d = typeof r.props?.source == "string" ? r.props.source : r.type;
854
- return (hn[o ?? ""] ?? []).map((u) => [u, d]);
867
+ const c = typeof r.props?.source == "string" ? r.props.source : r.type, u = o === "items" ? bn[c] ?? [] : [];
868
+ return [...hn[o ?? ""] ?? [], ...u].map((p) => [p, c]);
855
869
  }
856
- return mn.includes(r.type) ? pn.map((d) => [d, r.type]) : r.type === "wx-repeater" ? We(r.children ?? []).map((d) => [d.id, d.type]) : [];
870
+ return mn.includes(r.type) ? pn.map((c) => [c, r.type]) : r.type === "wx-repeater" ? We(r.children ?? []).map((c) => [c.id, c.type]) : [];
857
871
  }
858
872
  function Qt(e) {
859
873
  const l = /* @__PURE__ */ new Map();
@@ -863,7 +877,7 @@ function Qt(e) {
863
877
  l.set(t[4] ?? t[3], t[2] ? `${t[1]}.${t[2]}` : t[1]);
864
878
  return l;
865
879
  }
866
- function xn(e, l, t) {
880
+ function $n(e, l, t) {
867
881
  const s = /[\w-]*$/.exec(l)[0], a = new Set(l.split(/\s+/));
868
882
  return {
869
883
  from: e.pos - s.length,
@@ -871,7 +885,7 @@ function xn(e, l, t) {
871
885
  validFor: /^[\w-]*$/
872
886
  };
873
887
  }
874
- function $n(e) {
888
+ function Sn(e) {
875
889
  const l = We(e).filter((t) => t.type === "wx-blocks");
876
890
  return [
877
891
  ve("@if (${condition})\n ${}\n@endif", { label: "@if", type: "keyword" }),
@@ -903,13 +917,13 @@ function $n(e) {
903
917
  )
904
918
  ];
905
919
  }
906
- function Sn({ slug: e, template: l }) {
920
+ function En({ slug: e, template: l }) {
907
921
  return (t) => {
908
922
  const s = t.state.sliceDoc(Math.max(0, t.pos - 200), t.pos), a = /(?:^|[\s,>+~(}{])\.([\w-]*)$/.exec(s);
909
923
  if (!a) return null;
910
924
  const i = /[^{};]*$/.exec(s)[0];
911
925
  if (/^\s*[\w-]+\s*:\s/.test(i)) return null;
912
- const o = `b-${e()}`, r = new Set(Xt(t.state.doc.toString())), d = En(l()), u = [o, ...d.filter((f) => f !== o)], p = u.map((f, v) => ({
926
+ const o = `b-${e()}`, r = new Set(Xt(t.state.doc.toString())), c = Tn(l()), u = [o, ...c.filter((f) => f !== o)], p = u.map((f, v) => ({
913
927
  label: `.${f}`,
914
928
  // A class the template uses and nothing styles yet is the likeliest thing to write.
915
929
  detail: r.has(f) ? "template" : "template · no rule yet",
@@ -926,16 +940,16 @@ function Xt(e) {
926
940
  let a = "";
927
941
  for (const i of l)
928
942
  if (i === "{") {
929
- const o = s.at(-1) ?? [""], r = a.split(",").map((d) => d.trim()).filter((d) => d !== "" && !d.startsWith("@")).flatMap(
930
- (d) => d.includes("&") ? o.map((u) => d.replaceAll("&", u)) : o.map((u) => u ? `${u} ${d}` : d)
943
+ const o = s.at(-1) ?? [""], r = a.split(",").map((c) => c.trim()).filter((c) => c !== "" && !c.startsWith("@")).flatMap(
944
+ (c) => c.includes("&") ? o.map((u) => c.replaceAll("&", u)) : o.map((u) => u ? `${u} ${c}` : c)
931
945
  );
932
- for (const d of r)
933
- for (const u of d.matchAll(/\.(-?[a-zA-Z_][\w-]*)/g)) t.add(u[1]);
946
+ for (const c of r)
947
+ for (const u of c.matchAll(/\.(-?[a-zA-Z_][\w-]*)/g)) t.add(u[1]);
934
948
  s.push(a.trim().startsWith("@") ? o : r.length ? r : o), a = "";
935
949
  } else i === "}" ? (s.pop(), a = "") : i === ";" ? a = "" : a += i;
936
950
  return [...t];
937
951
  }
938
- function En(e) {
952
+ function Tn(e) {
939
953
  const l = /* @__PURE__ */ new Set();
940
954
  for (const t of e.matchAll(/\bclass\s*=\s*"([^"]*)"/g)) {
941
955
  const s = t[1].replace(/\{\{[\s\S]*?\}\}|\{!![\s\S]*?!!\}|@\w+(\([^)]*\))?/g, " ");
@@ -944,7 +958,7 @@ function En(e) {
944
958
  }
945
959
  return [...l];
946
960
  }
947
- const Tn = [
961
+ const Cn = [
948
962
  { key: "id", value: '""', info: "The variable the template gets, in snake_case." },
949
963
  { key: "type", value: '""', info: "A type from the registry." },
950
964
  { key: "label", value: '""', info: "What the editor sees above the field." },
@@ -956,32 +970,32 @@ const Tn = [
956
970
  { key: "slot", value: '""', info: "The parent's named slot to land in." },
957
971
  { key: "can", value: '""', info: "The permission the node needs." }
958
972
  ];
959
- function Cn({ types: e }) {
973
+ function Ln({ types: e }) {
960
974
  return (l) => {
961
- const t = Ln(l.state.doc.toString(), l.pos);
975
+ const t = An(l.state.doc.toString(), l.pos);
962
976
  if (!t || !t.node) return null;
963
977
  const s = t.string ? l.state.sliceDoc(t.string, l.pos) : /[\w-]*$/.exec(l.state.sliceDoc(Math.max(0, l.pos - 60), l.pos))[0];
964
978
  if (!t.string && s === "" && !l.explicit) return null;
965
979
  const a = l.pos - s.length, i = t.string !== null;
966
980
  if (t.phase === "key") {
967
- const o = Tn.filter(({ key: r }) => !t.keys.has(r) || r === s).map(
968
- ({ key: r, value: d, info: u }, p) => ({
981
+ const o = Cn.filter(({ key: r }) => !t.keys.has(r) || r === s).map(
982
+ ({ key: r, value: c, info: u }, p) => ({
969
983
  label: r,
970
984
  info: u,
971
985
  type: "property",
972
986
  boost: -p,
973
- apply: (f, v, g, x) => Et(f, v, g, x, i, `"${r}": ${d}`, d)
987
+ apply: (f, v, g, x) => Et(f, v, g, x, i, `"${r}": ${c}`, c)
974
988
  })
975
989
  );
976
990
  return { from: a, options: o, validFor: /^[\w-]*$/ };
977
991
  }
978
992
  if (t.phase === "value" && t.key === "type") {
979
- const o = Object.entries(e()).map(([r, d]) => ({
993
+ const o = Object.entries(e()).map(([r, c]) => ({
980
994
  label: r,
981
- detail: d.kind,
995
+ detail: c.kind,
982
996
  type: "type",
983
997
  // Fields first: a block's schema is mostly fields, the layout only groups them.
984
- boost: d.kind === "field" ? 1 : 0,
998
+ boost: c.kind === "field" ? 1 : 0,
985
999
  apply: (u, p, f, v) => Et(u, p, f, v, i, `"${r}"`, "")
986
1000
  }));
987
1001
  return { from: a, options: o, validFor: /^[\w-]*$/ };
@@ -990,7 +1004,7 @@ function Cn({ types: e }) {
990
1004
  };
991
1005
  }
992
1006
  function Et(e, l, t, s, a, i, o) {
993
- const r = a ? t - 1 : t, d = /^[\w-]*"?/.exec(e.state.sliceDoc(s, s + 60))[0], u = s + (a ? d.length : /^[\w-]*/.exec(d)[0].length), p = o === '""' || o === "{}" || o === "[]" ? 1 : 0;
1007
+ const r = a ? t - 1 : t, c = /^[\w-]*"?/.exec(e.state.sliceDoc(s, s + 60))[0], u = s + (a ? c.length : /^[\w-]*/.exec(c)[0].length), p = o === '""' || o === "{}" || o === "[]" ? 1 : 0;
994
1008
  e.dispatch({
995
1009
  changes: { from: r, to: u, insert: i },
996
1010
  selection: { anchor: r + i.length - p },
@@ -998,7 +1012,7 @@ function Et(e, l, t, s, a, i, o) {
998
1012
  userEvent: "input.complete"
999
1013
  }), i.startsWith('"type"') && Bl(e);
1000
1014
  }
1001
- function Ln(e, l) {
1015
+ function An(e, l) {
1002
1016
  let t = null, s = null, a = null, i = !1;
1003
1017
  const o = (r) => r?.kind === "object" && r.parent?.kind === "array" && (r.parent.parent === null || r.parent.under === "children");
1004
1018
  for (let r = 0; r <= e.length && (r === l && (s = t?.kind === "object" ? {
@@ -1008,23 +1022,23 @@ function Ln(e, l) {
1008
1022
  keys: t.keys,
1009
1023
  string: a ? a.start + 1 : null
1010
1024
  } : null), r !== e.length); r++) {
1011
- const d = e[r];
1025
+ const c = e[r];
1012
1026
  if (a) {
1013
1027
  if (i) i = !1;
1014
- else if (d === "\\") i = !0;
1015
- else if (d === '"' || d === `
1028
+ else if (c === "\\") i = !0;
1029
+ else if (c === '"' || c === `
1016
1030
  `) {
1017
1031
  const u = e.slice(a.start + 1, r);
1018
1032
  t?.kind === "object" && (a.key ? (t.keys.add(u), t.key = u, t.phase = "colon") : t.phase === "value" && (t.phase = "after")), a = null;
1019
1033
  }
1020
1034
  continue;
1021
1035
  }
1022
- if (!/\s/.test(d))
1023
- if (d === '"')
1036
+ if (!/\s/.test(c))
1037
+ if (c === '"')
1024
1038
  a = { start: r, key: t?.kind === "object" && t.phase === "key" };
1025
- else if (d === "{" || d === "[") {
1039
+ else if (c === "{" || c === "[") {
1026
1040
  const u = {
1027
- kind: d === "{" ? "object" : "array",
1041
+ kind: c === "{" ? "object" : "array",
1028
1042
  parent: t,
1029
1043
  under: t?.kind === "object" ? t.key : null,
1030
1044
  keys: /* @__PURE__ */ new Set(),
@@ -1032,28 +1046,28 @@ function Ln(e, l) {
1032
1046
  key: null
1033
1047
  };
1034
1048
  t?.kind === "object" && (t.phase = "after"), t = u;
1035
- } else d === "}" || d === "]" ? t = t?.parent ?? null : d === ":" ? t?.kind === "object" && (t.phase = "value") : d === "," && t?.kind === "object" && (t.phase = "key", t.key = null);
1049
+ } else c === "}" || c === "]" ? t = t?.parent ?? null : c === ":" ? t?.kind === "object" && (t.phase = "value") : c === "," && t?.kind === "object" && (t.phase = "key", t.key = null);
1036
1050
  }
1037
1051
  return s;
1038
1052
  }
1039
1053
  function We(e) {
1040
1054
  const l = [];
1041
1055
  for (const t of e)
1042
- !t || typeof t != "object" || (An.has(t.type) ? l.push(...We(t.children ?? [])) : typeof t.id == "string" && t.id !== "" && l.push(t));
1056
+ !t || typeof t != "object" || (Vn.has(t.type) ? l.push(...We(t.children ?? [])) : typeof t.id == "string" && t.id !== "" && l.push(t));
1043
1057
  return l;
1044
1058
  }
1045
1059
  function el(e) {
1046
1060
  return We(e).filter((l) => l.type !== "wx-blocks");
1047
1061
  }
1048
- const An = /* @__PURE__ */ new Set(["wx-card", "wx-tabs", "wx-tab", "wx-row", "wx-col", "wx-divider"]);
1049
- function Vn(e) {
1062
+ const Vn = /* @__PURE__ */ new Set(["wx-card", "wx-tabs", "wx-tab", "wx-row", "wx-col", "wx-divider"]);
1063
+ function Bn(e) {
1050
1064
  return e.replace(/[.*+?^${}()|[\]\\!]/g, "\\$&");
1051
1065
  }
1052
- const Bn = ["block", "entity", "loop", "__env", "errors", "app"];
1053
- function Wn(e, l, t) {
1066
+ const Wn = ["block", "entity", "loop", "__env", "errors", "app"];
1067
+ function Mn(e, l, t) {
1054
1068
  const s = [];
1055
1069
  /data-wx-block\s*=/.test(l.template) || s.push({ file: "template", code: "no-marker", line: null, message: t("checks.no-marker") });
1056
- const a = Mn(l.template, l.schema);
1070
+ const a = Nn(l.template, l.schema);
1057
1071
  a.length > 0 && s.push({
1058
1072
  file: "template",
1059
1073
  code: "variables-missing",
@@ -1063,7 +1077,7 @@ function Wn(e, l, t) {
1063
1077
  })
1064
1078
  });
1065
1079
  const i = [], o = [], r = `.b-${e}`;
1066
- for (const [p, f] of Nn(l.styles))
1080
+ for (const [p, f] of zn(l.styles))
1067
1081
  p.startsWith(r) || p.startsWith("&") || (/^[a-z][a-z0-9-]*/i.test(p) ? o.push([p, f]) : i.push([p, f]));
1068
1082
  i.length > 0 && s.push({
1069
1083
  file: "styles",
@@ -1076,11 +1090,11 @@ function Wn(e, l, t) {
1076
1090
  line: o[0][1],
1077
1091
  message: t("checks.bare-selectors", { selectors: Tt(o) })
1078
1092
  });
1079
- const d = ll(l.styles), u = /@media\b/.exec(d);
1093
+ const c = ll(l.styles), u = /@media\b/.exec(c);
1080
1094
  return u && s.push({
1081
1095
  file: "styles",
1082
1096
  code: "media-query",
1083
- line: nl(d, u.index),
1097
+ line: nl(c, u.index),
1084
1098
  message: t("checks.media-query")
1085
1099
  }), s;
1086
1100
  }
@@ -1090,8 +1104,8 @@ function tl(e) {
1090
1104
  t.id && l.push(t.id), t.children && l.push(...tl(t.children));
1091
1105
  return l;
1092
1106
  }
1093
- function Mn(e, l) {
1094
- const t = /* @__PURE__ */ new Set([...tl(l), ...Bn]);
1107
+ function Nn(e, l) {
1108
+ const t = /* @__PURE__ */ new Set([...tl(l), ...Wn]);
1095
1109
  for (const a of e.matchAll(/\bas\s+\$([a-zA-Z_]\w*)(?:\s*=>\s*\$([a-zA-Z_]\w*))?/g))
1096
1110
  t.add(a[1]), a[2] && t.add(a[2]);
1097
1111
  for (const a of e.matchAll(/\$([a-zA-Z_]\w*)\s*(?:=[^=]|\+\+|--|\.=|\+=|-=)/g))
@@ -1103,7 +1117,7 @@ function Mn(e, l) {
1103
1117
  }
1104
1118
  return s;
1105
1119
  }
1106
- function Nn(e) {
1120
+ function zn(e) {
1107
1121
  const l = ll(e), t = [];
1108
1122
  for (const s of l.matchAll(/([^{};]+)\{/g)) {
1109
1123
  const a = s[1], i = a.trim();
@@ -1140,24 +1154,24 @@ function Ne(e, l) {
1140
1154
  const t = `groups.${e}`, s = l(t);
1141
1155
  return s === t || s === `webx-blocks::${t}` ? e.charAt(0).toUpperCase() + e.slice(1) : s;
1142
1156
  }
1143
- const zn = { class: "wx-block-editor" }, Dn = { class: "wx-block-editor__split" }, In = {
1157
+ const Dn = { class: "wx-block-editor" }, In = { class: "wx-block-editor__split" }, On = {
1144
1158
  type: "button",
1145
1159
  class: "wx-block-editor__uses"
1146
- }, On = { class: "wx-block-editor__usage" }, Pn = { class: "wx-block-editor__pane" }, Un = {
1160
+ }, Pn = { class: "wx-block-editor__usage" }, Un = { class: "wx-block-editor__pane" }, Rn = {
1147
1161
  key: 0,
1148
1162
  class: "wx-block-editor__pills"
1149
- }, Rn = ["disabled", "onClick", "textContent"], jn = { class: "wx-block-editor__pane" }, Fn = { class: "wx-block-editor__pane" }, Hn = { class: "wx-block-editor__note" }, Kn = { class: "wx-block-editor__split" }, Yn = { class: "wx-block-editor__pane" }, qn = { class: "wx-block-editor__note" }, Jn = { class: "wx-block-editor__settings" }, Gn = {
1163
+ }, jn = ["disabled", "onClick", "textContent"], Fn = { class: "wx-block-editor__pane" }, Hn = { class: "wx-block-editor__pane" }, qn = { class: "wx-block-editor__note" }, Kn = { class: "wx-block-editor__split" }, Yn = { class: "wx-block-editor__pane" }, Jn = { class: "wx-block-editor__note" }, Gn = { class: "wx-block-editor__settings" }, Zn = {
1150
1164
  key: 0,
1151
1165
  class: "is-wide wx-block-editor__danger"
1152
- }, Zn = /* @__PURE__ */ ae({
1166
+ }, Qn = /* @__PURE__ */ ae({
1153
1167
  __name: "BlockEditorPage",
1154
1168
  props: {
1155
1169
  base: { default: "/blocks" }
1156
1170
  },
1157
1171
  setup(e) {
1158
1172
  const l = e, t = je(), s = Me(t), a = vl(), i = Wt();
1159
- Ke();
1160
- const o = de("webx-blocks"), r = Fe(), d = L(() => Number(a.params.id)), u = I(null), p = I([]), f = I(!0), v = I(!1), g = I(!1), x = I("template"), T = L(() => {
1173
+ qe();
1174
+ const o = de("webx-blocks"), r = Fe(), c = L(() => Number(a.params.id)), u = I(null), p = I([]), f = I(!0), v = I(!1), g = I(!1), x = I("template"), T = L(() => {
1161
1175
  const B = t.state.manifest?.modules.find((k) => k.id === "blocks")?.meta;
1162
1176
  return {
1163
1177
  groups: B?.groups ?? [],
@@ -1181,24 +1195,24 @@ const zn = { class: "wx-block-editor" }, Dn = { class: "wx-block-editor__split"
1181
1195
  styles: "",
1182
1196
  script: null,
1183
1197
  sample: {}
1184
- }), R = I("[]"), Y = I(null), q = I(""), X = I({}), h = I(null), V = st({
1198
+ }), R = I("[]"), K = I(null), Y = I(""), X = I({}), h = I(null), V = st({
1185
1199
  html: "",
1186
1200
  styles: "",
1187
1201
  script: null,
1188
1202
  runtime: null,
1189
1203
  stage: null,
1190
1204
  loading: !1
1191
- }), O = L(() => JSON.stringify({ settings: y, content: _ })), J = L(() => q.value !== "" && O.value !== q.value), Se = L(() => Wn(y.slug, _, o)), ne = {
1205
+ }), O = L(() => JSON.stringify({ settings: y, content: _ })), J = L(() => Y.value !== "" && O.value !== Y.value), Se = L(() => Mn(y.slug, _, o)), ne = {
1192
1206
  template: [
1193
1207
  at(
1194
- bn({ schema: () => _.schema, styles: () => _.styles })
1208
+ gn({ schema: () => _.schema, styles: () => _.styles })
1195
1209
  )
1196
1210
  ],
1197
1211
  styles: [
1198
- at(Sn({ slug: () => y.slug, template: () => _.template }))
1212
+ at(En({ slug: () => y.slug, template: () => _.template }))
1199
1213
  ],
1200
1214
  // The renderer's own types under the panel's, the same merge the sample form is drawn with.
1201
- schema: [at(Cn({ types: () => ({ ...Je, ...t.types }) }))]
1215
+ schema: [at(Ln({ types: () => ({ ...Je, ...t.types }) }))]
1202
1216
  }, pe = L(() => {
1203
1217
  const B = [...T.value.groups];
1204
1218
  return B.includes(y.group) || B.push(y.group), B.map((k) => ({ value: k, label: Ne(k, o) }));
@@ -1234,12 +1248,12 @@ const zn = { class: "wx-block-editor" }, Dn = { class: "wx-block-editor__split"
1234
1248
  script: null,
1235
1249
  sample: {}
1236
1250
  };
1237
- Object.assign(_, be(k)), R.value = JSON.stringify(k.schema, null, 2), Y.value = null, q.value = O.value;
1251
+ Object.assign(_, be(k)), R.value = JSON.stringify(k.schema, null, 2), K.value = null, Y.value = O.value;
1238
1252
  }
1239
1253
  async function ke() {
1240
1254
  f.value = !0;
1241
1255
  try {
1242
- Q(await s.get(d.value)), p.value = await s.usage(d.value);
1256
+ Q(await s.get(c.value)), p.value = await s.usage(c.value);
1243
1257
  } catch (B) {
1244
1258
  Z.danger(r(B));
1245
1259
  } finally {
@@ -1251,9 +1265,9 @@ const zn = { class: "wx-block-editor" }, Dn = { class: "wx-block-editor__split"
1251
1265
  try {
1252
1266
  const k = JSON.parse(B);
1253
1267
  if (!Array.isArray(k)) throw new Error("not a list");
1254
- _.schema = k, Y.value = null;
1268
+ _.schema = k, K.value = null;
1255
1269
  } catch (k) {
1256
- Y.value = o("page.schema-invalid", { error: k.message });
1270
+ K.value = o("page.schema-invalid", { error: k.message });
1257
1271
  }
1258
1272
  }
1259
1273
  let ge, W = 0;
@@ -1312,7 +1326,7 @@ const zn = { class: "wx-block-editor" }, Dn = { class: "wx-block-editor__split"
1312
1326
  allowed_in: y.allowed_in.length ? y.allowed_in : null,
1313
1327
  description: y.description || null,
1314
1328
  icon: y.icon || null,
1315
- content: Y.value ? { ..._, schema: void 0 } : _
1329
+ content: K.value ? { ..._, schema: void 0 } : _
1316
1330
  });
1317
1331
  Q(k), Z.success(
1318
1332
  k.draft && k.draft.number !== B ? o("page.saved", { number: k.draft.number }) : o("page.unchanged")
@@ -1398,7 +1412,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1398
1412
  ke(), window.addEventListener("beforeunload", ee);
1399
1413
  }), Xe(() => {
1400
1414
  clearTimeout(ge), window.removeEventListener("beforeunload", ee);
1401
- }), te(d, () => {
1415
+ }), te(c, () => {
1402
1416
  ke();
1403
1417
  });
1404
1418
  const lt = L(
@@ -1418,14 +1432,14 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1418
1432
  }
1419
1433
  ] : []
1420
1434
  );
1421
- return (B, k) => (c(), C("div", zn, [
1422
- f.value || !u.value ? (c(), C(F, { key: 0 }, [
1435
+ return (B, k) => (d(), C("div", Dn, [
1436
+ f.value || !u.value ? (d(), C(F, { key: 0 }, [
1423
1437
  m(n(Be), {
1424
1438
  class: "wx-block-editor__ghost-head",
1425
1439
  title: "",
1426
1440
  rows: 1
1427
1441
  }),
1428
- A("div", Dn, [
1442
+ A("div", In, [
1429
1443
  m(n(Ae), null, {
1430
1444
  default: b(() => [
1431
1445
  m(n(Be), { rows: 8 })
@@ -1439,7 +1453,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1439
1453
  _: 1
1440
1454
  })
1441
1455
  ])
1442
- ], 64)) : (c(), C(F, { key: 1 }, [
1456
+ ], 64)) : (d(), C(F, { key: 1 }, [
1443
1457
  m(n(bl), {
1444
1458
  title: y.title,
1445
1459
  back: e.base,
@@ -1447,13 +1461,13 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1447
1461
  actions: lt.value
1448
1462
  }, {
1449
1463
  "title-after": b(() => [
1450
- w.value ? (c(), z(n(gl), {
1464
+ w.value ? (d(), z(n(gl), {
1451
1465
  key: 0,
1452
1466
  name: y.title,
1453
1467
  placeholder: n(o)("page.title"),
1454
1468
  onRename: k[0] || (k[0] = (E) => y.title = E)
1455
1469
  }, null, 8, ["name", "placeholder"])) : D("", !0),
1456
- J.value ? (c(), z(n(ue), {
1470
+ J.value ? (d(), z(n(ue), {
1457
1471
  key: 1,
1458
1472
  type: "primary",
1459
1473
  dot: ""
@@ -1463,7 +1477,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1463
1477
  ]),
1464
1478
  _: 1
1465
1479
  })) : D("", !0),
1466
- u.value.draft ? (c(), z(n(ue), {
1480
+ u.value.draft ? (d(), z(n(ue), {
1467
1481
  key: 2,
1468
1482
  type: "warning",
1469
1483
  dot: ""
@@ -1473,7 +1487,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1473
1487
  ]),
1474
1488
  _: 1
1475
1489
  })) : D("", !0),
1476
- u.value.published ? (c(), z(n(ue), {
1490
+ u.value.published ? (d(), z(n(ue), {
1477
1491
  key: 3,
1478
1492
  type: "success",
1479
1493
  dot: ""
@@ -1482,7 +1496,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1482
1496
  M(S(n(o)("page.live", { number: u.value.published.number })), 1)
1483
1497
  ]),
1484
1498
  _: 1
1485
- })) : (c(), z(n(ue), {
1499
+ })) : (d(), z(n(ue), {
1486
1500
  key: 4,
1487
1501
  type: "default"
1488
1502
  }, {
@@ -1495,23 +1509,23 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1495
1509
  subtitle: b(() => [
1496
1510
  A("code", null, S(y.slug), 1),
1497
1511
  M(" · " + S(n(Ne)(y.group, n(o))) + " · ", 1),
1498
- u.value.usage_count > 0 ? (c(), z(n(_l), {
1512
+ u.value.usage_count > 0 ? (d(), z(n(_l), {
1499
1513
  key: 0,
1500
1514
  title: n(o)("page.usage"),
1501
1515
  width: 260,
1502
1516
  align: "start"
1503
1517
  }, {
1504
1518
  trigger: b(() => [
1505
- A("button", In, S(n(ct)(u.value.usage_count, n(o))), 1)
1519
+ A("button", On, S(n(ct)(u.value.usage_count, n(o))), 1)
1506
1520
  ]),
1507
1521
  default: b(() => [
1508
- A("div", On, [
1509
- (c(!0), C(F, null, le(U.value, (E) => (c(), C("div", {
1522
+ A("div", Pn, [
1523
+ (d(!0), C(F, null, le(U.value, (E) => (d(), C("div", {
1510
1524
  key: `${E.model}:${E.id}`,
1511
1525
  class: "wx-block-editor__use"
1512
1526
  }, [
1513
1527
  A("span", null, S(E.title ?? `#${E.id}`), 1),
1514
- E.published ? D("", !0) : (c(), z(n(ue), {
1528
+ E.published ? D("", !0) : (d(), z(n(ue), {
1515
1529
  key: 0,
1516
1530
  type: "warning",
1517
1531
  size: "sm"
@@ -1522,7 +1536,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1522
1536
  _: 1
1523
1537
  }))
1524
1538
  ]))), 128)),
1525
- p.value.length > U.value.length ? (c(), z(n(K), {
1539
+ p.value.length > U.value.length ? (d(), z(n(q), {
1526
1540
  key: 0,
1527
1541
  size: "sm",
1528
1542
  tone: "muted"
@@ -1535,13 +1549,13 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1535
1549
  ])
1536
1550
  ]),
1537
1551
  _: 1
1538
- }, 8, ["title"])) : (c(), C(F, { key: 1 }, [
1552
+ }, 8, ["title"])) : (d(), C(F, { key: 1 }, [
1539
1553
  M(S(n(ct)(u.value.usage_count, n(o))), 1)
1540
1554
  ], 64))
1541
1555
  ]),
1542
1556
  _: 1
1543
1557
  }, 8, ["title", "back", "back-label", "actions"]),
1544
- T.value.editing ? D("", !0) : (c(), z(n(zt), {
1558
+ T.value.editing ? D("", !0) : (d(), z(n(zt), {
1545
1559
  key: 0,
1546
1560
  type: "info",
1547
1561
  variant: "soft",
@@ -1561,8 +1575,8 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1561
1575
  label: n(o)("page.tab-template")
1562
1576
  }, {
1563
1577
  default: b(() => [
1564
- A("div", Pn, [
1565
- m(n(Ye), {
1578
+ A("div", Un, [
1579
+ m(n(Ke), {
1566
1580
  ref_key: "templateEditor",
1567
1581
  ref: G,
1568
1582
  modelValue: _.template,
@@ -1574,8 +1588,8 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1574
1588
  "max-height": "70vh",
1575
1589
  "line-wrapping": ""
1576
1590
  }, null, 8, ["modelValue", "extensions", "readonly"]),
1577
- Ee.value.length ? (c(), C("div", Un, [
1578
- m(n(K), {
1591
+ Ee.value.length ? (d(), C("div", Rn, [
1592
+ m(n(q), {
1579
1593
  size: "sm",
1580
1594
  tone: "muted"
1581
1595
  }, {
@@ -1584,14 +1598,14 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1584
1598
  ]),
1585
1599
  _: 1
1586
1600
  }),
1587
- (c(!0), C(F, null, le(Ee.value, (E) => (c(), C("button", {
1601
+ (d(!0), C(F, null, le(Ee.value, (E) => (d(), C("button", {
1588
1602
  key: E,
1589
1603
  type: "button",
1590
1604
  class: "wx-block-editor__pill",
1591
1605
  disabled: !w.value,
1592
1606
  onClick: (nt) => we(E),
1593
1607
  textContent: S(fe(E))
1594
- }, null, 8, Rn))), 128))
1608
+ }, null, 8, jn))), 128))
1595
1609
  ])) : D("", !0),
1596
1610
  m(kt, {
1597
1611
  file: "template",
@@ -1608,8 +1622,8 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1608
1622
  label: n(o)("page.tab-styles")
1609
1623
  }, {
1610
1624
  default: b(() => [
1611
- A("div", jn, [
1612
- m(n(Ye), {
1625
+ A("div", Fn, [
1626
+ m(n(Ke), {
1613
1627
  modelValue: _.styles,
1614
1628
  "onUpdate:modelValue": k[2] || (k[2] = (E) => _.styles = E),
1615
1629
  language: "css",
@@ -1632,8 +1646,8 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1632
1646
  label: n(o)("page.tab-script")
1633
1647
  }, {
1634
1648
  default: b(() => [
1635
- A("div", Fn, [
1636
- m(n(Ye), {
1649
+ A("div", Hn, [
1650
+ m(n(Ke), {
1637
1651
  "model-value": _.script ?? "",
1638
1652
  language: "javascript",
1639
1653
  readonly: !w.value,
@@ -1641,8 +1655,8 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1641
1655
  "max-height": "70vh",
1642
1656
  "onUpdate:modelValue": k[3] || (k[3] = (E) => _.script = E || null)
1643
1657
  }, null, 8, ["model-value", "readonly"]),
1644
- A("div", Hn, [
1645
- m(n(K), {
1658
+ A("div", qn, [
1659
+ m(n(q), {
1646
1660
  size: "sm",
1647
1661
  tone: "muted"
1648
1662
  }, {
@@ -1651,7 +1665,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1651
1665
  ]),
1652
1666
  _: 1
1653
1667
  }),
1654
- m(n(K), {
1668
+ m(n(q), {
1655
1669
  size: "sm",
1656
1670
  tone: "muted"
1657
1671
  }, {
@@ -1667,11 +1681,11 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1667
1681
  title: n(o)("page.examples")
1668
1682
  }, {
1669
1683
  default: b(() => [
1670
- (c(!0), C(F, null, le(N.value, (E) => (c(), C("div", {
1684
+ (d(!0), C(F, null, le(N.value, (E) => (d(), C("div", {
1671
1685
  key: E.title,
1672
1686
  class: "wx-block-editor__example"
1673
1687
  }, [
1674
- m(n(K), {
1688
+ m(n(q), {
1675
1689
  size: "sm",
1676
1690
  tone: "muted"
1677
1691
  }, {
@@ -1697,7 +1711,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1697
1711
  default: b(() => [
1698
1712
  A("div", Kn, [
1699
1713
  A("div", Yn, [
1700
- m(n(Ye), {
1714
+ m(n(Ke), {
1701
1715
  "model-value": R.value,
1702
1716
  language: "json",
1703
1717
  extensions: ne.schema,
@@ -1707,17 +1721,17 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1707
1721
  "max-height": "70vh",
1708
1722
  "onUpdate:modelValue": Ce
1709
1723
  }, null, 8, ["model-value", "extensions", "readonly"]),
1710
- A("div", qn, [
1711
- Y.value ? (c(), z(n(K), {
1724
+ A("div", Jn, [
1725
+ K.value ? (d(), z(n(q), {
1712
1726
  key: 0,
1713
1727
  size: "sm",
1714
1728
  tone: "danger"
1715
1729
  }, {
1716
1730
  default: b(() => [
1717
- M(S(Y.value), 1)
1731
+ M(S(K.value), 1)
1718
1732
  ]),
1719
1733
  _: 1
1720
- })) : H("content.schema") ? (c(), z(n(K), {
1734
+ })) : H("content.schema") ? (d(), z(n(q), {
1721
1735
  key: 1,
1722
1736
  size: "sm",
1723
1737
  tone: "danger"
@@ -1726,7 +1740,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1726
1740
  M(S(H("content.schema")), 1)
1727
1741
  ]),
1728
1742
  _: 1
1729
- })) : (c(), z(n(K), {
1743
+ })) : (d(), z(n(q), {
1730
1744
  key: 2,
1731
1745
  size: "sm",
1732
1746
  tone: "muted"
@@ -1747,7 +1761,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1747
1761
  title: n(o)("page.sample")
1748
1762
  }, {
1749
1763
  default: b(() => [
1750
- _.schema.length ? (c(), z(n(Rt), {
1764
+ _.schema.length ? (d(), z(n(Rt), {
1751
1765
  key: 0,
1752
1766
  modelValue: ye.value,
1753
1767
  "onUpdate:modelValue": k[4] || (k[4] = (E) => ye.value = E),
@@ -1772,7 +1786,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1772
1786
  default: b(() => [
1773
1787
  m(n(Ae), { class: "wx-block-editor__sheet" }, {
1774
1788
  default: b(() => [
1775
- A("div", Jn, [
1789
+ A("div", Gn, [
1776
1790
  m(n(oe), {
1777
1791
  label: n(o)("page.identifier"),
1778
1792
  help: n(o)("page.identifier-help"),
@@ -1909,7 +1923,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1909
1923
  ]),
1910
1924
  _: 1
1911
1925
  }, 8, ["label", "help", "disabled"]),
1912
- w.value ? (c(), C("div", Gn, [
1926
+ w.value ? (d(), C("div", Zn, [
1913
1927
  m(n(ce), {
1914
1928
  type: "danger",
1915
1929
  variant: "outline",
@@ -1921,7 +1935,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1921
1935
  ]),
1922
1936
  _: 1
1923
1937
  }, 8, ["disabled"]),
1924
- u.value.usage_count > 0 ? (c(), z(n(K), {
1938
+ u.value.usage_count > 0 ? (d(), z(n(q), {
1925
1939
  key: 0,
1926
1940
  size: "sm",
1927
1941
  tone: "muted"
@@ -1975,7 +1989,7 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
1975
1989
  [il, $.value]
1976
1990
  ])
1977
1991
  ], 2),
1978
- w.value ? (c(), z(n(Tl), { key: 1 }, {
1992
+ w.value ? (d(), z(n(Tl), { key: 1 }, {
1979
1993
  default: b(() => [
1980
1994
  m(n(ce), {
1981
1995
  variant: "outline",
@@ -2004,27 +2018,27 @@ new Swiper(el.querySelector('.b-slider__viewport'), { loop: true })`
2004
2018
  ], 64))
2005
2019
  ]));
2006
2020
  }
2007
- }), Qn = /* @__PURE__ */ ie(Zn, [["__scopeId", "data-v-22e5f784"]]), Ct = /* @__PURE__ */ new Map();
2008
- function Xn(e) {
2021
+ }), Xn = /* @__PURE__ */ ie(Qn, [["__scopeId", "data-v-22e5f784"]]), Ct = /* @__PURE__ */ new Map();
2022
+ function es(e) {
2009
2023
  let l = Ct.get(e);
2010
- return l === void 0 && (l = fetch(e, { credentials: "same-origin", headers: { Accept: "text/html" } }).then((t) => t.ok ? t.text() : null).then((t) => t === null ? null : Kl(t, e)).catch(() => null), Ct.set(e, l)), l;
2024
+ return l === void 0 && (l = fetch(e, { credentials: "same-origin", headers: { Accept: "text/html" } }).then((t) => t.ok ? t.text() : null).then((t) => t === null ? null : ql(t, e)).catch(() => null), Ct.set(e, l)), l;
2011
2025
  }
2012
- function es() {
2026
+ function ts() {
2013
2027
  const e = De(Mt, null), l = I(null), t = L(() => {
2014
2028
  const a = e?.state.manifest?.modules.find((i) => i.id === "blocks")?.meta?.stage;
2015
2029
  return typeof a == "string" && a !== "" ? a : null;
2016
2030
  });
2017
2031
  return rl(() => {
2018
2032
  const s = t.value;
2019
- s !== null && Xn(s).then((a) => {
2033
+ s !== null && es(s).then((a) => {
2020
2034
  t.value === s && (l.value = a);
2021
2035
  });
2022
2036
  }), l;
2023
2037
  }
2024
- const ts = ["srcdoc"], ls = {
2038
+ const ls = ["srcdoc"], ns = {
2025
2039
  key: 1,
2026
2040
  class: "wx-block-thumb__empty"
2027
- }, ns = /* @__PURE__ */ ae({
2041
+ }, ss = /* @__PURE__ */ ae({
2028
2042
  __name: "BlockThumb",
2029
2043
  props: {
2030
2044
  thumbnail: {},
@@ -2032,22 +2046,22 @@ const ts = ["srcdoc"], ls = {
2032
2046
  height: { default: 120 }
2033
2047
  },
2034
2048
  setup(e) {
2035
- const l = e, t = I(null), s = et(t), a = L(() => s.value > 0 ? s.value / l.width : 0.2), i = es(), o = L(() => {
2049
+ const l = e, t = I(null), s = et(t), a = L(() => s.value > 0 ? s.value / l.width : 0.2), i = ts(), o = L(() => {
2036
2050
  if (!l.thumbnail) return "";
2037
- const d = { html: l.thumbnail.html, styles: l.thumbnail.styles };
2038
- return i.value ? Yl(i.value, d) : Ht(d);
2051
+ const c = { html: l.thumbnail.html, styles: l.thumbnail.styles };
2052
+ return i.value ? Kl(i.value, c) : Ht(c);
2039
2053
  }), r = L(() => ({
2040
2054
  width: `${l.width}px`,
2041
2055
  height: `${Math.round(l.height / a.value)}px`,
2042
2056
  transform: `scale(${a.value})`
2043
2057
  }));
2044
- return (d, u) => (c(), C("div", {
2058
+ return (c, u) => (d(), C("div", {
2045
2059
  ref_key: "box",
2046
2060
  ref: t,
2047
2061
  class: "wx-block-thumb",
2048
2062
  style: xe({ height: `${e.height}px` })
2049
2063
  }, [
2050
- e.thumbnail ? (c(), C("iframe", {
2064
+ e.thumbnail ? (d(), C("iframe", {
2051
2065
  key: 0,
2052
2066
  class: "wx-block-thumb__frame",
2053
2067
  srcdoc: o.value,
@@ -2055,15 +2069,15 @@ const ts = ["srcdoc"], ls = {
2055
2069
  sandbox: "allow-same-origin",
2056
2070
  tabindex: "-1",
2057
2071
  "aria-hidden": "true"
2058
- }, null, 12, ts)) : (c(), C("div", ls, [
2072
+ }, null, 12, ls)) : (d(), C("div", ns, [
2059
2073
  m(n(he), { name: "grid" })
2060
2074
  ]))
2061
2075
  ], 4));
2062
2076
  }
2063
- }), sl = /* @__PURE__ */ ie(ns, [["__scopeId", "data-v-5ca74656"]]), ss = { class: "wx-block-picker" }, os = {
2077
+ }), sl = /* @__PURE__ */ ie(ss, [["__scopeId", "data-v-5ca74656"]]), os = { class: "wx-block-picker" }, as = {
2064
2078
  key: 0,
2065
2079
  class: "wx-block-picker__group-title"
2066
- }, as = { class: "wx-block-picker__cards" }, is = ["disabled", "title", "onClick"], rs = { class: "wx-block-picker__body" }, us = { class: "wx-block-picker__title" }, cs = /* @__PURE__ */ ae({
2080
+ }, is = { class: "wx-block-picker__cards" }, rs = ["disabled", "title", "onClick"], us = { class: "wx-block-picker__body" }, cs = { class: "wx-block-picker__title" }, ds = /* @__PURE__ */ ae({
2067
2081
  __name: "BlockPicker",
2068
2082
  props: {
2069
2083
  catalog: {},
@@ -2075,7 +2089,7 @@ const ts = ["srcdoc"], ls = {
2075
2089
  },
2076
2090
  setup(e) {
2077
2091
  const l = e, { resolve: t, dismiss: s, open: a } = It();
2078
- Ke();
2092
+ qe();
2079
2093
  const i = de("webx-blocks"), o = I("");
2080
2094
  function r(v) {
2081
2095
  if (l.parent === null)
@@ -2083,14 +2097,14 @@ const ts = ["srcdoc"], ls = {
2083
2097
  const g = l.allow ? l.allow.includes(v.slug) : l.parent.allow?.includes(v.slug) === !0, x = v.allowed_in === null || v.allowed_in.includes(l.parent.slug);
2084
2098
  return g && x;
2085
2099
  }
2086
- const d = L(
2100
+ const c = L(
2087
2101
  () => l.catalog.filter((v) => v.is_enabled && v.published !== null && r(v)).map((v) => {
2088
2102
  const g = tn(l.tree, v.slug), x = v.max_per_entity !== null && g >= v.max_per_entity;
2089
2103
  return { type: v, reason: x ? i("field.limit-reached", { count: g }) : null };
2090
2104
  })
2091
2105
  ), u = L(() => {
2092
2106
  const v = o.value.trim().toLowerCase();
2093
- return v === "" ? d.value : d.value.filter(
2107
+ return v === "" ? c.value : c.value.filter(
2094
2108
  ({ type: g }) => g.title.toLowerCase().includes(v) || g.slug.includes(v) || (g.description ?? "").toLowerCase().includes(v)
2095
2109
  );
2096
2110
  }), p = L(() => {
@@ -2105,7 +2119,7 @@ const ts = ["srcdoc"], ls = {
2105
2119
  return u.value.length <= 5 || o.value.trim() !== "" || g.length < 2 ? [{ id: "", label: "", options: u.value }] : g;
2106
2120
  }), f = L(() => {
2107
2121
  if (l.catalog.length === 0) return i("field.pick-none");
2108
- if (d.value.length === 0 && l.parent) {
2122
+ if (c.value.length === 0 && l.parent) {
2109
2123
  const v = (l.allow ?? l.parent.allow ?? []).filter(
2110
2124
  (g) => l.catalog.some((x) => x.slug === g)
2111
2125
  );
@@ -2115,7 +2129,7 @@ const ts = ["srcdoc"], ls = {
2115
2129
  });
2116
2130
  return (v, g) => {
2117
2131
  const x = At("router-link");
2118
- return c(), z(n(Ot), {
2132
+ return d(), z(n(Ot), {
2119
2133
  open: n(a),
2120
2134
  "onUpdate:open": g[2] || (g[2] = (T) => Vt(a) ? a.value = T : null),
2121
2135
  title: n(i)("field.pick"),
@@ -2133,8 +2147,8 @@ const ts = ["srcdoc"], ls = {
2133
2147
  })
2134
2148
  ]),
2135
2149
  default: b(() => [
2136
- A("div", ss, [
2137
- d.value.length > 0 ? (c(), z(n(Ue), {
2150
+ A("div", os, [
2151
+ c.value.length > 0 ? (d(), z(n(Ue), {
2138
2152
  key: 0,
2139
2153
  modelValue: o.value,
2140
2154
  "onUpdate:modelValue": g[0] || (g[0] = (T) => o.value = T),
@@ -2142,14 +2156,14 @@ const ts = ["srcdoc"], ls = {
2142
2156
  clearable: "",
2143
2157
  autofocus: ""
2144
2158
  }, null, 8, ["modelValue", "placeholder"])) : D("", !0),
2145
- u.value.length === 0 ? (c(), z(n(Pt), {
2159
+ u.value.length === 0 ? (d(), z(n(Pt), {
2146
2160
  key: 1,
2147
2161
  icon: "grid",
2148
2162
  title: f.value,
2149
2163
  size: "sm"
2150
2164
  }, {
2151
2165
  default: b(() => [
2152
- e.catalog.length === 0 && e.blocksPath ? (c(), z(x, {
2166
+ e.catalog.length === 0 && e.blocksPath ? (d(), z(x, {
2153
2167
  key: 0,
2154
2168
  to: e.blocksPath
2155
2169
  }, {
@@ -2161,13 +2175,13 @@ const ts = ["srcdoc"], ls = {
2161
2175
  ]),
2162
2176
  _: 1
2163
2177
  }, 8, ["title"])) : D("", !0),
2164
- (c(!0), C(F, null, le(p.value, (T) => (c(), C("section", {
2178
+ (d(!0), C(F, null, le(p.value, (T) => (d(), C("section", {
2165
2179
  key: T.id,
2166
2180
  class: "wx-block-picker__group"
2167
2181
  }, [
2168
- T.label ? (c(), C("div", os, S(T.label), 1)) : D("", !0),
2169
- A("div", as, [
2170
- (c(!0), C(F, null, le(T.options, (w) => (c(), C("button", {
2182
+ T.label ? (d(), C("div", as, S(T.label), 1)) : D("", !0),
2183
+ A("div", is, [
2184
+ (d(!0), C(F, null, le(T.options, (w) => (d(), C("button", {
2171
2185
  key: w.type.id,
2172
2186
  type: "button",
2173
2187
  class: $e(["wx-block-picker__card", { "is-disabled": w.reason !== null }]),
@@ -2179,9 +2193,9 @@ const ts = ["srcdoc"], ls = {
2179
2193
  thumbnail: w.type.thumbnail,
2180
2194
  height: 96
2181
2195
  }, null, 8, ["thumbnail"]),
2182
- A("div", rs, [
2183
- A("div", us, S(w.type.title), 1),
2184
- w.reason ? (c(), z(n(K), {
2196
+ A("div", us, [
2197
+ A("div", cs, S(w.type.title), 1),
2198
+ w.reason ? (d(), z(n(q), {
2185
2199
  key: 0,
2186
2200
  size: "sm",
2187
2201
  tone: "warning"
@@ -2190,7 +2204,7 @@ const ts = ["srcdoc"], ls = {
2190
2204
  M(S(w.reason), 1)
2191
2205
  ]),
2192
2206
  _: 2
2193
- }, 1024)) : w.type.description ? (c(), z(n(K), {
2207
+ }, 1024)) : w.type.description ? (d(), z(n(q), {
2194
2208
  key: 1,
2195
2209
  size: "sm",
2196
2210
  tone: "muted"
@@ -2201,7 +2215,7 @@ const ts = ["srcdoc"], ls = {
2201
2215
  _: 2
2202
2216
  }, 1024)) : D("", !0)
2203
2217
  ])
2204
- ], 10, is))), 128))
2218
+ ], 10, rs))), 128))
2205
2219
  ])
2206
2220
  ]))), 128))
2207
2221
  ])
@@ -2210,7 +2224,7 @@ const ts = ["srcdoc"], ls = {
2210
2224
  }, 8, ["open", "title"]);
2211
2225
  };
2212
2226
  }
2213
- }), ds = /* @__PURE__ */ ie(cs, [["__scopeId", "data-v-99f4090e"]]), ps = { class: "wx-blocks-preview__tools" }, fs = ["src", "title"], ms = /* @__PURE__ */ ae({
2227
+ }), ps = /* @__PURE__ */ ie(ds, [["__scopeId", "data-v-99f4090e"]]), fs = { class: "wx-blocks-preview__tools" }, ms = ["src", "title"], vs = /* @__PURE__ */ ae({
2214
2228
  __name: "BlocksPreview",
2215
2229
  props: {
2216
2230
  url: {},
@@ -2220,7 +2234,7 @@ const ts = ["srcdoc"], ls = {
2220
2234
  },
2221
2235
  emits: ["select", "edit"],
2222
2236
  setup(e, { expose: l, emit: t }) {
2223
- const s = e, a = t, i = de("webx-blocks"), o = I(null), r = I(null), d = I(null), u = et(d), p = I(!1), f = I(!1), v = I(null), g = I(0), x = L(() => g.value > 0), T = L(() => [
2237
+ const s = e, a = t, i = de("webx-blocks"), o = I(null), r = I(null), c = I(null), u = et(c), p = I(!1), f = I(!1), v = I(null), g = I(0), x = L(() => g.value > 0), T = L(() => [
2224
2238
  { value: 1280, icon: "monitor", ariaLabel: i("field.width-desktop") },
2225
2239
  { value: 834, icon: "tablet", ariaLabel: i("field.width-tablet") },
2226
2240
  { value: 390, icon: "smartphone", ariaLabel: i("field.width-phone") }
@@ -2231,7 +2245,7 @@ const ts = ["srcdoc"], ls = {
2231
2245
  })), R = L(() => ({
2232
2246
  width: `${Math.round(w.value * y.value)}px`,
2233
2247
  ...x.value ? { height: `${Math.round(g.value * y.value)}px` } : {}
2234
- })), Y = L(() => {
2248
+ })), K = L(() => {
2235
2249
  if (!s.url) return "";
2236
2250
  try {
2237
2251
  return `${new URL(s.url, location.origin).pathname} · ${w.value} px`;
@@ -2239,7 +2253,7 @@ const ts = ["srcdoc"], ls = {
2239
2253
  return s.url;
2240
2254
  }
2241
2255
  });
2242
- function q() {
2256
+ function Y() {
2243
2257
  try {
2244
2258
  return o.value?.contentDocument ?? null;
2245
2259
  } catch {
@@ -2251,7 +2265,7 @@ const ts = ["srcdoc"], ls = {
2251
2265
  W.documentElement.scrollTop !== 0 && (W.documentElement.scrollTop = 0);
2252
2266
  }
2253
2267
  function O() {
2254
- const W = q(), P = W?.body;
2268
+ const W = Y(), P = W?.body;
2255
2269
  if (!P || !W?.defaultView) return;
2256
2270
  V(W);
2257
2271
  const j = W.defaultView.getComputedStyle(P), G = (parseFloat(j.marginTop) || 0) + (parseFloat(j.marginBottom) || 0), fe = Math.ceil(P.scrollHeight + G);
@@ -2264,7 +2278,7 @@ const ts = ["srcdoc"], ls = {
2264
2278
  }
2265
2279
  function Se() {
2266
2280
  f.value = !0;
2267
- const W = q();
2281
+ const W = Y();
2268
2282
  W && (J(W), X?.release(), X = Rl(W, {
2269
2283
  /* No guard against answering a click with a scroll: `bring` moves nothing that is already
2270
2284
  readable, and a block clicked at the very bottom of the window, half under the action
@@ -2295,7 +2309,7 @@ const ts = ["srcdoc"], ls = {
2295
2309
  return null;
2296
2310
  }
2297
2311
  function Q() {
2298
- const W = q();
2312
+ const W = Y();
2299
2313
  if (ne === null || !W) return;
2300
2314
  V(W);
2301
2315
  const P = pt(W, ne), j = P ? Ee(P) : null;
@@ -2307,7 +2321,7 @@ const ts = ["srcdoc"], ls = {
2307
2321
  $ !== 0 && (G ?? window).scrollBy({ top: $, behavior: "smooth" });
2308
2322
  }
2309
2323
  function ke(W, P) {
2310
- const j = q();
2324
+ const j = Y();
2311
2325
  if (!j || !f.value) return !1;
2312
2326
  const G = Ft(j, W, P);
2313
2327
  return G && ot(j, s.selected ?? null), G;
@@ -2321,7 +2335,7 @@ const ts = ["srcdoc"], ls = {
2321
2335
  return te(
2322
2336
  () => s.selected,
2323
2337
  (W) => {
2324
- const P = q();
2338
+ const P = Y();
2325
2339
  !P || !f.value || (ot(P, W ?? null), ye(W ?? null));
2326
2340
  }
2327
2341
  ), te(() => s.reload, Ce), te(
@@ -2329,7 +2343,7 @@ const ts = ["srcdoc"], ls = {
2329
2343
  () => f.value = !1
2330
2344
  ), Re(() => window.addEventListener("keydown", ge)), Xe(() => {
2331
2345
  window.removeEventListener("keydown", ge), pe !== null && clearTimeout(pe), h?.disconnect(), X?.release();
2332
- }), l({ replace: ke, refresh: Ce, open: () => p.value = !0 }), (W, P) => (c(), C("div", {
2346
+ }), l({ replace: ke, refresh: Ce, open: () => p.value = !0 }), (W, P) => (d(), C("div", {
2333
2347
  class: $e(["wx-blocks-preview", { "is-fullscreen": p.value, "is-grown": x.value, "is-compact": e.compact }]),
2334
2348
  style: xe({ "--wx-preview-scale": y.value })
2335
2349
  }, [
@@ -2338,14 +2352,14 @@ const ts = ["srcdoc"], ls = {
2338
2352
  ref: r,
2339
2353
  class: "wx-blocks-preview__bar"
2340
2354
  }, [
2341
- m(n(K), {
2355
+ m(n(q), {
2342
2356
  size: "xs",
2343
2357
  tone: "muted",
2344
2358
  class: "wx-blocks-preview__label",
2345
2359
  truncate: ""
2346
2360
  }, {
2347
2361
  default: b(() => [
2348
- M(S(Y.value), 1)
2362
+ M(S(K.value), 1)
2349
2363
  ]),
2350
2364
  _: 1
2351
2365
  }),
@@ -2357,8 +2371,8 @@ const ts = ["srcdoc"], ls = {
2357
2371
  "aria-label": n(i)("field.width"),
2358
2372
  "onUpdate:modelValue": P[0] || (P[0] = (j) => v.value = Number(j))
2359
2373
  }, null, 8, ["model-value", "options", "aria-label"]),
2360
- A("div", ps, [
2361
- e.compact ? (c(), z(n(Ie), {
2374
+ A("div", fs, [
2375
+ e.compact ? (d(), z(n(Ie), {
2362
2376
  key: 0,
2363
2377
  size: "sm",
2364
2378
  tone: "primary",
@@ -2366,7 +2380,7 @@ const ts = ["srcdoc"], ls = {
2366
2380
  title: n(i)("field.blocks"),
2367
2381
  onClick: P[1] || (P[1] = (j) => a("edit"))
2368
2382
  }, null, 8, ["title"])) : D("", !0),
2369
- e.url ? (c(), z(n(Ie), {
2383
+ e.url ? (d(), z(n(Ie), {
2370
2384
  key: 1,
2371
2385
  size: "sm",
2372
2386
  icon: "external-link",
@@ -2387,14 +2401,14 @@ const ts = ["srcdoc"], ls = {
2387
2401
  ], 512),
2388
2402
  A("div", {
2389
2403
  ref_key: "box",
2390
- ref: d,
2404
+ ref: c,
2391
2405
  class: "wx-blocks-preview__ground"
2392
2406
  }, [
2393
2407
  A("div", {
2394
2408
  class: "wx-blocks-preview__clip",
2395
2409
  style: xe(R.value)
2396
2410
  }, [
2397
- e.url ? (c(), C("iframe", {
2411
+ e.url ? (d(), C("iframe", {
2398
2412
  key: 0,
2399
2413
  ref_key: "frame",
2400
2414
  ref: o,
@@ -2403,15 +2417,15 @@ const ts = ["srcdoc"], ls = {
2403
2417
  style: xe(_.value),
2404
2418
  title: n(i)("field.preview"),
2405
2419
  onLoad: Se
2406
- }, null, 44, fs)) : D("", !0)
2420
+ }, null, 44, ms)) : D("", !0)
2407
2421
  ], 4)
2408
2422
  ], 512)
2409
2423
  ], 6));
2410
2424
  }
2411
- }), vs = /* @__PURE__ */ ie(ms, [["__scopeId", "data-v-398e4cef"]]), hs = { class: "wx-blocks-tree__node" }, bs = ["onClick", "onKeydown"], gs = { class: "wx-blocks-tree__name" }, ys = ["title"], ks = ["title"], ws = ["title"], _s = ["title"], xs = {
2425
+ }), hs = /* @__PURE__ */ ie(vs, [["__scopeId", "data-v-398e4cef"]]), bs = { class: "wx-blocks-tree__node" }, gs = ["onClick", "onKeydown"], ys = { class: "wx-blocks-tree__name" }, ks = ["title"], ws = ["title"], _s = ["title"], xs = ["title"], $s = {
2412
2426
  key: 4,
2413
2427
  class: "wx-blocks-tree__actions"
2414
- }, $s = ["onClick"], Ss = /* @__PURE__ */ ae({
2428
+ }, Ss = ["onClick"], Es = /* @__PURE__ */ ae({
2415
2429
  __name: "BlocksTree",
2416
2430
  props: {
2417
2431
  nodes: {},
@@ -2435,7 +2449,7 @@ const ts = ["srcdoc"], ls = {
2435
2449
  const f = i(p);
2436
2450
  return f?.content ? Jt(f.content.schema) : [];
2437
2451
  }
2438
- function d(p, f) {
2452
+ function c(p, f) {
2439
2453
  const v = p.values[f.id];
2440
2454
  return Array.isArray(v) ? v : [];
2441
2455
  }
@@ -2464,7 +2478,7 @@ const ts = ["srcdoc"], ls = {
2464
2478
  }
2465
2479
  return (p, f) => {
2466
2480
  const v = At("blocks-tree", !0);
2467
- return c(), z(n(Cl), {
2481
+ return d(), z(n(Cl), {
2468
2482
  "model-value": e.nodes,
2469
2483
  "item-key": "key",
2470
2484
  "item-label": (g) => o(g),
@@ -2476,7 +2490,7 @@ const ts = ["srcdoc"], ls = {
2476
2490
  "onUpdate:modelValue": f[6] || (f[6] = (g) => s("reorder", e.parentKey, e.field, g))
2477
2491
  }, {
2478
2492
  default: b(({ item: g }) => [
2479
- A("div", hs, [
2493
+ A("div", bs, [
2480
2494
  A("div", {
2481
2495
  class: $e(["wx-blocks-tree__row", { "is-selected": e.selected === g.key, "is-hidden": g.hidden === !0 }]),
2482
2496
  role: "button",
@@ -2487,46 +2501,46 @@ const ts = ["srcdoc"], ls = {
2487
2501
  ht(bt((x) => s("select", g.key), ["prevent"]), ["space"])
2488
2502
  ]
2489
2503
  }, [
2490
- A("span", gs, S(o(g)), 1),
2491
- i(g) ? i(g)?.draft ? (c(), C("span", {
2504
+ A("span", ys, S(o(g)), 1),
2505
+ i(g) ? i(g)?.draft ? (d(), C("span", {
2492
2506
  key: 1,
2493
2507
  class: "wx-blocks-tree__flag is-warning",
2494
2508
  title: n(a)("field.draft-type")
2495
2509
  }, [
2496
2510
  m(n(he), { name: "warning" })
2497
- ], 8, ks)) : i(g)?.is_enabled === !1 ? (c(), C("span", {
2511
+ ], 8, ws)) : i(g)?.is_enabled === !1 ? (d(), C("span", {
2498
2512
  key: 2,
2499
2513
  class: "wx-blocks-tree__flag",
2500
2514
  title: n(a)("field.disabled-type")
2501
2515
  }, [
2502
2516
  m(n(he), { name: "lock" })
2503
- ], 8, ws)) : D("", !0) : (c(), C("span", {
2517
+ ], 8, _s)) : D("", !0) : (d(), C("span", {
2504
2518
  key: 0,
2505
2519
  class: "wx-blocks-tree__flag is-danger",
2506
2520
  title: n(a)("field.unknown-type", { type: g.type })
2507
2521
  }, [
2508
2522
  m(n(he), { name: "close-circle" })
2509
- ], 8, ys)),
2510
- g.hidden === !0 ? (c(), C("span", {
2523
+ ], 8, ks)),
2524
+ g.hidden === !0 ? (d(), C("span", {
2511
2525
  key: 3,
2512
2526
  class: "wx-blocks-tree__flag",
2513
2527
  title: n(a)("field.hidden-note")
2514
2528
  }, [
2515
2529
  m(n(he), { name: "eye-off" })
2516
- ], 8, _s)) : D("", !0),
2517
- e.disabled ? D("", !0) : (c(), C("span", xs, [
2530
+ ], 8, xs)) : D("", !0),
2531
+ e.disabled ? D("", !0) : (d(), C("span", $s, [
2518
2532
  m(n(kl), {
2519
2533
  actions: u(g),
2520
2534
  label: o(g)
2521
2535
  }, null, 8, ["actions", "label"])
2522
2536
  ]))
2523
- ], 42, bs),
2524
- (c(!0), C(F, null, le(r(g), (x) => (c(), C("div", {
2537
+ ], 42, gs),
2538
+ (d(!0), C(F, null, le(r(g), (x) => (d(), C("div", {
2525
2539
  key: x.id,
2526
2540
  class: "wx-blocks-tree__kids"
2527
2541
  }, [
2528
2542
  m(v, {
2529
- nodes: d(g, x),
2543
+ nodes: c(g, x),
2530
2544
  catalog: e.catalog,
2531
2545
  "parent-key": g.key,
2532
2546
  field: x.id,
@@ -2540,17 +2554,17 @@ const ts = ["srcdoc"], ls = {
2540
2554
  onVisibility: f[4] || (f[4] = (T, w) => s("visibility", T, w)),
2541
2555
  onReorder: f[5] || (f[5] = (T, w, y) => s("reorder", T, w, y))
2542
2556
  }, null, 8, ["nodes", "catalog", "parent-key", "field", "selected", "disabled", "depth"]),
2543
- e.disabled ? D("", !0) : (c(), C("button", {
2557
+ e.disabled ? D("", !0) : (d(), C("button", {
2544
2558
  key: 0,
2545
2559
  type: "button",
2546
2560
  class: "wx-blocks-tree__add is-inner",
2547
2561
  onClick: (T) => s("add", g.key, x.id, x)
2548
2562
  }, [
2549
2563
  M(" + " + S(n(a)("field.add-inside")), 1),
2550
- r(g).length > 1 ? (c(), C(F, { key: 0 }, [
2564
+ r(g).length > 1 ? (d(), C(F, { key: 0 }, [
2551
2565
  M(" · " + S(x.label ?? x.id), 1)
2552
2566
  ], 64)) : D("", !0)
2553
- ], 8, $s))
2567
+ ], 8, Ss))
2554
2568
  ]))), 128))
2555
2569
  ])
2556
2570
  ]),
@@ -2558,29 +2572,29 @@ const ts = ["srcdoc"], ls = {
2558
2572
  }, 8, ["model-value", "item-label", "disabled", "empty-text", "class"]);
2559
2573
  };
2560
2574
  }
2561
- }), Es = /* @__PURE__ */ ie(Ss, [["__scopeId", "data-v-590fa1d6"]]), vt = /* @__PURE__ */ Symbol("wx-blocks-preview");
2562
- function vo(e) {
2575
+ }), Ts = /* @__PURE__ */ ie(Es, [["__scopeId", "data-v-590fa1d6"]]), vt = /* @__PURE__ */ Symbol("wx-blocks-preview");
2576
+ function ho(e) {
2563
2577
  Bt(vt, e);
2564
2578
  }
2565
- function ho() {
2579
+ function bo() {
2566
2580
  return De(vt, null);
2567
2581
  }
2568
- const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2582
+ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Cs = {
2569
2583
  key: 0,
2570
2584
  class: "wx-blocks-nested"
2571
- }, Cs = {
2585
+ }, Ls = {
2572
2586
  key: 0,
2573
2587
  class: "wx-blocks__tree"
2574
- }, Ls = { class: "wx-blocks__panel-head" }, As = { class: "wx-blocks__panel-title" }, Vs = { class: "wx-blocks__list" }, Bs = { class: "wx-blocks__tools" }, Ws = {
2588
+ }, As = { class: "wx-blocks__panel-head" }, Vs = { class: "wx-blocks__panel-title" }, Bs = { class: "wx-blocks__list" }, Ws = { class: "wx-blocks__tools" }, Ms = {
2575
2589
  key: 1,
2576
2590
  class: "wx-blocks__fields"
2577
- }, Ms = { class: "wx-blocks__panel-head" }, Ns = { class: "wx-blocks__panel-title" }, zs = {
2591
+ }, Ns = { class: "wx-blocks__panel-head" }, zs = { class: "wx-blocks__panel-title" }, Ds = {
2578
2592
  key: 0,
2579
2593
  class: "wx-blocks__trail"
2580
- }, Ds = ["onClick"], Is = { class: "wx-blocks__panel-name" }, Os = { class: "wx-blocks__panel-extra" }, Ps = { key: 0 }, Us = { class: "wx-blocks__form" }, Rs = {
2594
+ }, Is = ["onClick"], Os = { class: "wx-blocks__panel-name" }, Ps = { class: "wx-blocks__panel-extra" }, Us = { key: 0 }, Rs = { class: "wx-blocks__form" }, js = {
2581
2595
  key: 0,
2582
2596
  class: "wx-blocks__preview"
2583
- }, js = /* @__PURE__ */ ae({
2597
+ }, Fs = /* @__PURE__ */ ae({
2584
2598
  name: "WxBlocks",
2585
2599
  inheritAttrs: !1,
2586
2600
  __name: "BlocksField",
@@ -2601,10 +2615,10 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2601
2615
  emits: ["update:modelValue"],
2602
2616
  setup(e) {
2603
2617
  const l = e, t = cl(e, "modelValue"), s = De(Lt, !1);
2604
- Bt(Lt, !0), Ke();
2618
+ Bt(Lt, !0), qe();
2605
2619
  const a = de("webx-blocks"), i = Fe(), o = De(Mt, null);
2606
2620
  let r = null;
2607
- const d = I([]), u = L(() => l.catalog ?? d.value), p = L(() => Array.isArray(t.value) ? t.value : []), f = I(null), v = L(() => f.value ? re(p.value, f.value) : null), g = L(
2621
+ const c = I([]), u = L(() => l.catalog ?? c.value), p = L(() => Array.isArray(t.value) ? t.value : []), f = I(null), v = L(() => f.value ? re(p.value, f.value) : null), g = L(
2608
2622
  () => v.value ? u.value.find(($) => $.slug === v.value?.node.type) ?? null : null
2609
2623
  );
2610
2624
  function x($) {
@@ -2625,7 +2639,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2625
2639
  for (; N; )
2626
2640
  $.unshift({ key: N.key, title: x(N) }), N = re(p.value, N.key)?.parent ?? null;
2627
2641
  return $;
2628
- }), _ = De(vt, null), R = I(null), Y = I(null), q = et(Y), X = L(() => _ !== null && _.url.value !== null), h = L(() => X.value && q.value > 0 && q.value <= 900), V = I(!1), O = L(() => {
2642
+ }), _ = De(vt, null), R = I(null), K = I(null), Y = et(K), X = L(() => _ !== null && _.url.value !== null), h = L(() => X.value && Y.value > 0 && Y.value <= 900), V = I(!1), O = L(() => {
2629
2643
  if (!v.value) return;
2630
2644
  const $ = g.value?.title ?? v.value.node.type;
2631
2645
  return [...y.value.map((N) => N.title), $].join(" / ");
@@ -2655,7 +2669,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2655
2669
  () => o?.state.manifest?.modules.find(($) => $.id === "blocks")?.meta?.groups ?? []
2656
2670
  ), ne = dl()?.type, pe = L(() => l.context?.types ? l.context.types : o?.types ? { ...Je, ...o.types } : ne ? { ...Je, "wx-blocks": { component: ne, kind: "field", nested: !0 } } : Je), ye = L(
2657
2671
  () => l.context?.translate ?? o?.i18n.t ?? (($) => $)
2658
- ), Ee = L(() => l.context?.can ?? o?.can ?? (() => !0)), Te = Ut(ds);
2672
+ ), Ee = L(() => l.context?.can ?? o?.can ?? (() => !0)), Te = Ut(ps);
2659
2673
  function Q($) {
2660
2674
  t.value = $;
2661
2675
  }
@@ -2740,7 +2754,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2740
2754
  if (window.addEventListener("keydown", Le), l.catalog === null && o) {
2741
2755
  r = Me(o);
2742
2756
  try {
2743
- d.value = await r.catalog();
2757
+ c.value = await r.catalog();
2744
2758
  } catch ($) {
2745
2759
  Z.danger(i($));
2746
2760
  }
@@ -2751,8 +2765,8 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2751
2765
  const ze = L(
2752
2766
  () => g.value?.content ? mt(g.value.content.schema) : []
2753
2767
  );
2754
- return ($, N) => n(s) ? (c(), C("div", Ts, [
2755
- m(n(K), {
2768
+ return ($, N) => n(s) ? (d(), C("div", Cs, [
2769
+ m(n(q), {
2756
2770
  size: "sm",
2757
2771
  tone: "muted"
2758
2772
  }, {
@@ -2761,10 +2775,10 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2761
2775
  ]),
2762
2776
  _: 1
2763
2777
  })
2764
- ])) : (c(), C("div", {
2778
+ ])) : (d(), C("div", {
2765
2779
  key: 1,
2766
2780
  ref_key: "host",
2767
- ref: Y,
2781
+ ref: K,
2768
2782
  class: $e(["wx-blocks-host", { "is-compact": h.value }])
2769
2783
  }, [
2770
2784
  A("div", {
@@ -2773,12 +2787,12 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2773
2787
  "has-preview": n(_) !== null && n(_).url.value !== null
2774
2788
  }])
2775
2789
  }, [
2776
- (c(), z(pl(h.value ? n(Ll) : "div"), fl(J.value, { class: "wx-blocks__side" }), {
2790
+ (d(), z(pl(h.value ? n(Ll) : "div"), fl(J.value, { class: "wx-blocks__side" }), {
2777
2791
  default: b(() => [
2778
- v.value ? D("", !0) : (c(), C("div", Cs, [
2779
- A("div", Ls, [
2780
- A("span", As, S(n(a)("field.blocks")), 1),
2781
- m(n(K), {
2792
+ v.value ? D("", !0) : (d(), C("div", Ls, [
2793
+ A("div", As, [
2794
+ A("span", Vs, S(n(a)("field.blocks")), 1),
2795
+ m(n(q), {
2782
2796
  size: "sm",
2783
2797
  tone: "muted"
2784
2798
  }, {
@@ -2788,8 +2802,8 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2788
2802
  _: 1
2789
2803
  })
2790
2804
  ]),
2791
- A("div", Vs, [
2792
- m(Es, {
2805
+ A("div", Bs, [
2806
+ m(Ts, {
2793
2807
  nodes: p.value,
2794
2808
  catalog: u.value,
2795
2809
  selected: f.value,
@@ -2802,8 +2816,8 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2802
2816
  onReorder: j
2803
2817
  }, null, 8, ["nodes", "catalog", "selected", "disabled"])
2804
2818
  ]),
2805
- A("div", Bs, [
2806
- !e.disabled && (e.max === null || p.value.length < e.max) ? (c(), z(n(ce), {
2819
+ A("div", Ws, [
2820
+ !e.disabled && (e.max === null || p.value.length < e.max) ? (d(), z(n(ce), {
2807
2821
  key: 0,
2808
2822
  variant: "outline",
2809
2823
  icon: "plus",
@@ -2815,7 +2829,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2815
2829
  ]),
2816
2830
  _: 1
2817
2831
  })) : D("", !0),
2818
- !h.value && n(_) && n(_).url.value ? (c(), z(n(ce), {
2832
+ !h.value && n(_) && n(_).url.value ? (d(), z(n(ce), {
2819
2833
  key: 1,
2820
2834
  variant: "outline",
2821
2835
  icon: "eye",
@@ -2829,25 +2843,25 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2829
2843
  })) : D("", !0)
2830
2844
  ])
2831
2845
  ])),
2832
- v.value ? (c(), C("div", Ws, [
2833
- A("div", Ms, [
2834
- A("span", Ns, [
2835
- y.value.length ? (c(), C("span", zs, [
2836
- (c(!0), C(F, null, le(y.value, (U) => (c(), C(F, {
2846
+ v.value ? (d(), C("div", Ms, [
2847
+ A("div", Ns, [
2848
+ A("span", zs, [
2849
+ y.value.length ? (d(), C("span", Ds, [
2850
+ (d(!0), C(F, null, le(y.value, (U) => (d(), C(F, {
2837
2851
  key: U.key
2838
2852
  }, [
2839
2853
  A("button", {
2840
2854
  type: "button",
2841
2855
  class: "wx-blocks__trail-step",
2842
2856
  onClick: (H) => G(U.key)
2843
- }, S(U.title), 9, Ds),
2857
+ }, S(U.title), 9, Is),
2844
2858
  m(n(he), { name: "chevron-right" })
2845
2859
  ], 64))), 128))
2846
2860
  ])) : D("", !0),
2847
- A("span", Is, S(g.value?.title ?? v.value.node.type), 1)
2861
+ A("span", Os, S(g.value?.title ?? v.value.node.type), 1)
2848
2862
  ]),
2849
- A("span", Os, [
2850
- h.value ? D("", !0) : (c(), C("code", Ps, S(v.value.node.type), 1)),
2863
+ A("span", Ps, [
2864
+ h.value ? D("", !0) : (d(), C("code", Us, S(v.value.node.type), 1)),
2851
2865
  m(n(Ie), {
2852
2866
  size: "sm",
2853
2867
  tone: "neutral",
@@ -2864,7 +2878,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2864
2878
  disabled: w.value.next === null,
2865
2879
  onClick: N[3] || (N[3] = (U) => w.value.next && G(w.value.next))
2866
2880
  }, null, 8, ["title", "disabled"]),
2867
- !h.value && n(_) && n(_).url.value ? (c(), z(n(ce), {
2881
+ !h.value && n(_) && n(_).url.value ? (d(), z(n(ce), {
2868
2882
  key: 1,
2869
2883
  size: "sm",
2870
2884
  variant: "outline",
@@ -2885,8 +2899,8 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2885
2899
  })
2886
2900
  ])
2887
2901
  ]),
2888
- A("div", Us, [
2889
- g.value?.content ? (c(), z(n(Rt), {
2902
+ A("div", Rs, [
2903
+ g.value?.content ? (d(), z(n(Rt), {
2890
2904
  key: v.value.node.key,
2891
2905
  "model-value": v.value.node.values,
2892
2906
  root: ze.value,
@@ -2895,7 +2909,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2895
2909
  can: Ee.value,
2896
2910
  disabled: e.disabled,
2897
2911
  "onUpdate:modelValue": se
2898
- }, null, 8, ["model-value", "root", "types", "translate", "can", "disabled"])) : (c(), z(n(K), {
2912
+ }, null, 8, ["model-value", "root", "types", "translate", "can", "disabled"])) : (d(), z(n(q), {
2899
2913
  key: 1,
2900
2914
  size: "sm",
2901
2915
  tone: "danger"
@@ -2910,8 +2924,8 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2910
2924
  ]),
2911
2925
  _: 1
2912
2926
  }, 16)),
2913
- n(_) && n(_).url.value ? (c(), C("div", Rs, [
2914
- m(vs, {
2927
+ n(_) && n(_).url.value ? (d(), C("div", js, [
2928
+ m(hs, {
2915
2929
  ref_key: "previewEl",
2916
2930
  ref: R,
2917
2931
  url: n(_).url.value,
@@ -2925,7 +2939,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2925
2939
  ], 2)
2926
2940
  ], 2));
2927
2941
  }
2928
- }), Fs = /* @__PURE__ */ ie(js, [["__scopeId", "data-v-3952ee19"]]), Hs = { class: "wx-block-card__body" }, Ks = { class: "wx-block-card__title" }, Ys = { class: "wx-block-card__chips" }, qs = /* @__PURE__ */ ae({
2942
+ }), Hs = /* @__PURE__ */ ie(Fs, [["__scopeId", "data-v-3952ee19"]]), qs = { class: "wx-block-card__body" }, Ks = { class: "wx-block-card__title" }, Ys = { class: "wx-block-card__chips" }, Js = /* @__PURE__ */ ae({
2929
2943
  __name: "BlockCard",
2930
2944
  props: {
2931
2945
  block: {}
@@ -2933,7 +2947,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2933
2947
  emits: ["open"],
2934
2948
  setup(e, { emit: l }) {
2935
2949
  const t = l, s = de("webx-blocks");
2936
- return (a, i) => (c(), C("button", {
2950
+ return (a, i) => (d(), C("button", {
2937
2951
  type: "button",
2938
2952
  class: "wx-block-card",
2939
2953
  onClick: i[0] || (i[0] = (o) => t("open", e.block))
@@ -2942,9 +2956,9 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2942
2956
  thumbnail: e.block.thumbnail,
2943
2957
  height: 120
2944
2958
  }, null, 8, ["thumbnail"]),
2945
- A("div", Hs, [
2959
+ A("div", qs, [
2946
2960
  A("div", Ks, S(e.block.title), 1),
2947
- m(n(K), {
2961
+ m(n(q), {
2948
2962
  size: "sm",
2949
2963
  tone: "muted"
2950
2964
  }, {
@@ -2955,7 +2969,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2955
2969
  _: 1
2956
2970
  }),
2957
2971
  A("div", Ys, [
2958
- e.block.draft ? (c(), z(n(ue), {
2972
+ e.block.draft ? (d(), z(n(ue), {
2959
2973
  key: 0,
2960
2974
  type: "warning",
2961
2975
  dot: ""
@@ -2965,7 +2979,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2965
2979
  ]),
2966
2980
  _: 1
2967
2981
  })) : D("", !0),
2968
- e.block.published ? (c(), z(n(ue), {
2982
+ e.block.published ? (d(), z(n(ue), {
2969
2983
  key: 1,
2970
2984
  type: "success",
2971
2985
  dot: ""
@@ -2974,7 +2988,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2974
2988
  M(S(n(s)("page.live", { number: e.block.published.number })), 1)
2975
2989
  ]),
2976
2990
  _: 1
2977
- })) : (c(), z(n(ue), {
2991
+ })) : (d(), z(n(ue), {
2978
2992
  key: 2,
2979
2993
  type: "default"
2980
2994
  }, {
@@ -2983,7 +2997,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2983
2997
  ]),
2984
2998
  _: 1
2985
2999
  })),
2986
- e.block.is_enabled ? D("", !0) : (c(), z(n(ue), {
3000
+ e.block.is_enabled ? D("", !0) : (d(), z(n(ue), {
2987
3001
  key: 3,
2988
3002
  type: "default",
2989
3003
  variant: "outline"
@@ -2997,13 +3011,13 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
2997
3011
  ])
2998
3012
  ]));
2999
3013
  }
3000
- }), Js = /* @__PURE__ */ ie(qs, [["__scopeId", "data-v-3d94f339"]]), Gs = { class: "wx-block-create" }, Zs = /* @__PURE__ */ ae({
3014
+ }), Gs = /* @__PURE__ */ ie(Js, [["__scopeId", "data-v-3d94f339"]]), Zs = { class: "wx-block-create" }, Qs = /* @__PURE__ */ ae({
3001
3015
  __name: "BlockCreateDialog",
3002
3016
  setup(e) {
3003
3017
  const { resolve: l, dismiss: t, open: s } = It(), a = je(), i = Me(a);
3004
- Ke();
3005
- const o = de("webx-blocks"), r = Fe(), d = L(() => a.state.manifest?.modules.find((_) => _.id === "blocks")?.meta?.groups ?? ["content"]), u = I({ title: "", slug: "", group: d.value[0] ?? "content" }), p = I({}), f = I(!1), v = I(!1), g = L(
3006
- () => d.value.map((y) => ({ value: y, label: Ne(y, o) }))
3018
+ qe();
3019
+ const o = de("webx-blocks"), r = Fe(), c = L(() => a.state.manifest?.modules.find((_) => _.id === "blocks")?.meta?.groups ?? ["content"]), u = I({ title: "", slug: "", group: c.value[0] ?? "content" }), p = I({}), f = I(!1), v = I(!1), g = L(
3020
+ () => c.value.map((y) => ({ value: y, label: Ne(y, o) }))
3007
3021
  );
3008
3022
  function x(y) {
3009
3023
  return y.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-+|-+$/g, "").replace(/^[^a-z]+/, "").slice(0, 64);
@@ -3028,7 +3042,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
3028
3042
  f.value = !1;
3029
3043
  }
3030
3044
  }
3031
- return (y, _) => (c(), z(n(Ot), {
3045
+ return (y, _) => (d(), z(n(Ot), {
3032
3046
  open: n(s),
3033
3047
  "onUpdate:open": _[5] || (_[5] = (R) => Vt(s) ? s.value = R : null),
3034
3048
  title: n(o)("page.new"),
@@ -3061,7 +3075,7 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
3061
3075
  })
3062
3076
  ]),
3063
3077
  default: b(() => [
3064
- A("div", Gs, [
3078
+ A("div", Zs, [
3065
3079
  m(n(oe), {
3066
3080
  label: n(o)("page.title"),
3067
3081
  error: T("title")
@@ -3109,21 +3123,21 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
3109
3123
  _: 1
3110
3124
  }, 8, ["open", "title"]));
3111
3125
  }
3112
- }), Qs = /* @__PURE__ */ ie(Zs, [["__scopeId", "data-v-a4c0d44c"]]), Xs = {
3126
+ }), Xs = /* @__PURE__ */ ie(Qs, [["__scopeId", "data-v-a4c0d44c"]]), eo = {
3113
3127
  key: 1,
3114
3128
  class: "wx-blocks-page__toolbar"
3115
- }, eo = { class: "wx-blocks-page__cards" }, to = { class: "wx-blocks-page__ghost-body" }, lo = {
3129
+ }, to = { class: "wx-blocks-page__cards" }, lo = { class: "wx-blocks-page__ghost-body" }, no = {
3116
3130
  key: 0,
3117
3131
  class: "wx-blocks-page__group-title"
3118
- }, no = { class: "wx-blocks-page__cards" }, so = /* @__PURE__ */ ae({
3132
+ }, so = { class: "wx-blocks-page__cards" }, oo = /* @__PURE__ */ ae({
3119
3133
  __name: "BlocksPage",
3120
3134
  props: {
3121
3135
  base: { default: "/blocks" }
3122
3136
  },
3123
3137
  setup(e) {
3124
3138
  const l = e, t = je(), s = Me(t), a = Wt();
3125
- Ke();
3126
- const i = de("webx-blocks"), o = Fe(), r = I([]), d = I(!0), u = I(""), p = I(""), f = Ut(Qs), v = L(() => {
3139
+ qe();
3140
+ const i = de("webx-blocks"), o = Fe(), r = I([]), c = I(!0), u = I(""), p = I(""), f = Ut(Xs), v = L(() => {
3127
3141
  const h = t.state.manifest?.modules.find((V) => V.id === "blocks")?.meta;
3128
3142
  return {
3129
3143
  groups: h?.groups ?? [],
@@ -3156,29 +3170,29 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
3156
3170
  return p.value !== "" || T.value.length <= 5 || u.value.trim() !== "" || h.length < 2 ? [{ id: "", label: "", blocks: T.value }] : h;
3157
3171
  });
3158
3172
  async function R() {
3159
- d.value = !0;
3173
+ c.value = !0;
3160
3174
  try {
3161
3175
  r.value = await s.list();
3162
3176
  } catch (h) {
3163
3177
  Z.danger(o(h));
3164
3178
  } finally {
3165
- d.value = !1;
3179
+ c.value = !1;
3166
3180
  }
3167
3181
  }
3168
- function Y(h) {
3182
+ function K(h) {
3169
3183
  a.push(`${l.base}/${h.id}`);
3170
3184
  }
3171
- async function q() {
3185
+ async function Y() {
3172
3186
  const h = await f({});
3173
- h && Y(h);
3187
+ h && K(h);
3174
3188
  }
3175
3189
  Re(R);
3176
3190
  const X = L(
3177
3191
  () => g.value ? [{ key: "new", label: i("page.new"), icon: "plus", primary: !0, run: () => {
3178
- q();
3192
+ Y();
3179
3193
  } }] : []
3180
3194
  );
3181
- return (h, V) => (c(), z(n(wl), {
3195
+ return (h, V) => (d(), z(n(wl), {
3182
3196
  view: p.value,
3183
3197
  "onUpdate:view": V[1] || (V[1] = (O) => p.value = O),
3184
3198
  class: "wx-blocks-page",
@@ -3187,13 +3201,13 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
3187
3201
  actions: X.value
3188
3202
  }, {
3189
3203
  default: b(() => [
3190
- v.value.editing ? D("", !0) : (c(), z(n(zt), {
3204
+ v.value.editing ? D("", !0) : (d(), z(n(zt), {
3191
3205
  key: 0,
3192
3206
  type: "info",
3193
3207
  variant: "soft",
3194
3208
  description: n(i)("page.editing-off")
3195
3209
  }, null, 8, ["description"])),
3196
- d.value || r.value.length > 0 ? (c(), C("div", Xs, [
3210
+ c.value || r.value.length > 0 ? (d(), C("div", eo, [
3197
3211
  m(n(Ue), {
3198
3212
  modelValue: u.value,
3199
3213
  "onUpdate:modelValue": V[0] || (V[0] = (O) => u.value = O),
@@ -3202,28 +3216,28 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
3202
3216
  clearable: ""
3203
3217
  }, null, 8, ["modelValue", "placeholder"])
3204
3218
  ])) : D("", !0),
3205
- d.value ? (c(), z(n(Be), { key: 2 }, {
3219
+ c.value ? (d(), z(n(Be), { key: 2 }, {
3206
3220
  template: b(() => [
3207
- A("div", eo, [
3208
- (c(), C(F, null, le(4, (O) => A("div", {
3221
+ A("div", to, [
3222
+ (d(), C(F, null, le(4, (O) => A("div", {
3209
3223
  key: O,
3210
3224
  class: "wx-blocks-page__ghost"
3211
3225
  }, [
3212
- m(n(qe), {
3226
+ m(n(Ye), {
3213
3227
  variant: "image",
3214
3228
  height: 120,
3215
3229
  class: "wx-blocks-page__ghost-thumb"
3216
3230
  }),
3217
- A("div", to, [
3218
- m(n(qe), {
3231
+ A("div", lo, [
3232
+ m(n(Ye), {
3219
3233
  variant: "title",
3220
3234
  width: "45%"
3221
3235
  }),
3222
- m(n(qe), {
3236
+ m(n(Ye), {
3223
3237
  variant: "text",
3224
3238
  width: "70%"
3225
3239
  }),
3226
- m(n(qe), {
3240
+ m(n(Ye), {
3227
3241
  variant: "button",
3228
3242
  width: "64px",
3229
3243
  height: "22px"
@@ -3233,21 +3247,21 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
3233
3247
  ])
3234
3248
  ]),
3235
3249
  _: 1
3236
- })) : r.value.length === 0 ? (c(), z(n(Pt), {
3250
+ })) : r.value.length === 0 ? (d(), z(n(Pt), {
3237
3251
  key: 3,
3238
3252
  icon: "grid",
3239
3253
  title: n(i)("page.empty"),
3240
3254
  description: n(i)("page.empty-help")
3241
- }, null, 8, ["title", "description"])) : (c(!0), C(F, { key: 4 }, le(_.value, (O) => (c(), C("section", {
3255
+ }, null, 8, ["title", "description"])) : (d(!0), C(F, { key: 4 }, le(_.value, (O) => (d(), C("section", {
3242
3256
  key: O.id,
3243
3257
  class: "wx-blocks-page__group"
3244
3258
  }, [
3245
- O.label ? (c(), C("div", lo, S(O.label), 1)) : D("", !0),
3246
- A("div", no, [
3247
- (c(!0), C(F, null, le(O.blocks, (J) => (c(), z(Js, {
3259
+ O.label ? (d(), C("div", no, S(O.label), 1)) : D("", !0),
3260
+ A("div", so, [
3261
+ (d(!0), C(F, null, le(O.blocks, (J) => (d(), z(Gs, {
3248
3262
  key: J.id,
3249
3263
  block: J,
3250
- onOpen: Y
3264
+ onOpen: K
3251
3265
  }, null, 8, ["block"]))), 128))
3252
3266
  ])
3253
3267
  ]))), 128))
@@ -3255,18 +3269,18 @@ const Lt = /* @__PURE__ */ Symbol("wx-blocks-root"), Ts = {
3255
3269
  _: 1
3256
3270
  }, 8, ["view", "title", "views", "actions"]));
3257
3271
  }
3258
- }), oo = /* @__PURE__ */ ie(so, [["__scopeId", "data-v-553b680f"]]);
3259
- function bo(e = {}) {
3272
+ }), ao = /* @__PURE__ */ ie(oo, [["__scopeId", "data-v-553b680f"]]);
3273
+ function go(e = {}) {
3260
3274
  const l = e.path ?? "/blocks";
3261
3275
  return {
3262
3276
  id: "blocks",
3263
3277
  path: l,
3264
3278
  routes: [
3265
- { path: l, name: "webx.blocks", component: oo, props: { base: l } },
3279
+ { path: l, name: "webx.blocks", component: ao, props: { base: l } },
3266
3280
  {
3267
3281
  path: `${l}/:id(\\d+)`,
3268
3282
  name: "webx.blocks.edit",
3269
- component: Qn,
3283
+ component: Xn,
3270
3284
  props: { base: l }
3271
3285
  }
3272
3286
  ],
@@ -3275,7 +3289,7 @@ function bo(e = {}) {
3275
3289
  // draws its children through the renderer; it needs the node for `props.allow` alone.
3276
3290
  types: {
3277
3291
  "wx-blocks": {
3278
- component: Fs,
3292
+ component: Hs,
3279
3293
  kind: "field",
3280
3294
  nested: !0,
3281
3295
  wide: !0,
@@ -3285,13 +3299,13 @@ function bo(e = {}) {
3285
3299
  };
3286
3300
  }
3287
3301
  export {
3288
- Qn as WxBlockEditorPage,
3289
- ds as WxBlockPicker,
3302
+ Xn as WxBlockEditorPage,
3303
+ ps as WxBlockPicker,
3290
3304
  Xl as WxBlockStage,
3291
3305
  sl as WxBlockThumb,
3292
- Fs as WxBlocks,
3293
- oo as WxBlocksPage,
3294
- bo as blocks,
3306
+ Hs as WxBlocks,
3307
+ ao as WxBlocksPage,
3308
+ go as blocks,
3295
3309
  un as blocksMessages,
3296
3310
  vt as blocksPreviewKey,
3297
3311
  Gt as cloneNode,
@@ -3301,21 +3315,21 @@ export {
3301
3315
  mt as formSchema,
3302
3316
  ot as highlightBlock,
3303
3317
  $t as insertNode,
3304
- Yt as isNode,
3318
+ Kt as isNode,
3305
3319
  tt as isNodeList,
3306
- Wn as lintBlock,
3320
+ Mn as lintBlock,
3307
3321
  re as locate,
3308
3322
  en as makeNode,
3309
3323
  ut as newKey,
3310
- vo as provideBlocksPreview,
3324
+ ho as provideBlocksPreview,
3311
3325
  on as removeNode,
3312
3326
  Ft as replaceBlock,
3313
3327
  rn as replaceList,
3314
3328
  Ht as stageDocument,
3315
- mo as typesIn,
3316
- Mn as undeclared,
3329
+ vo as typesIn,
3330
+ Nn as undeclared,
3317
3331
  an as updateValues,
3318
- ho as useBlocksPreview,
3332
+ bo as useBlocksPreview,
3319
3333
  He as walk
3320
3334
  };
3321
3335
  //# sourceMappingURL=index.js.map