labull-framework 1.0.2 → 1.0.3
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/magic-block.js +203 -200
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/magic-block.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { shallowRef as ro, ref as B, computed as I, defineComponent as he, watch as Bt, nextTick as Je, onMounted as an, onBeforeUnmount as rn, openBlock as u, createElementBlock as c, normalizeStyle as un, normalizeClass as W, unref as K, createElementVNode as l, toDisplayString as f, createCommentVNode as w, Fragment as C, renderList as N, withModifiers as Ye, getCurrentInstance as uo, createBlock as co, createTextVNode as k, withDirectives as rt, vModelCheckbox as ts, vModelText as
|
|
1
|
+
import { shallowRef as ro, ref as B, computed as I, defineComponent as he, watch as Bt, nextTick as Je, onMounted as an, onBeforeUnmount as rn, openBlock as u, createElementBlock as c, normalizeStyle as un, normalizeClass as W, unref as K, createElementVNode as l, toDisplayString as f, createCommentVNode as w, Fragment as C, renderList as N, withModifiers as Ye, getCurrentInstance as uo, createBlock as co, createTextVNode as k, withDirectives as rt, vModelCheckbox as ts, vModelText as Zt, withKeys as po, vShow as pe, createStaticVNode as fo, vModelSelect as mo, vModelDynamic as bo } from "vue";
|
|
2
2
|
import { useRouter as es, useRoute as vo } from "vue-router";
|
|
3
3
|
import { b as mt, c as be, A as Qe, u as ns } from "./chunk-index-BVIJeFeJ.js";
|
|
4
4
|
import { s as Gc } from "./chunk-index-BVIJeFeJ.js";
|
|
@@ -365,7 +365,7 @@ function No(n, e) {
|
|
|
365
365
|
a.resolve = r, xt.value = [...xt.value, a];
|
|
366
366
|
});
|
|
367
367
|
}
|
|
368
|
-
const
|
|
368
|
+
const Ft = "index.open.html", He = "magic-block.open.yaml", Fn = "README.open.md", Un = "requires.open.yaml", Ke = ["id", "module", "name", "brief", "requires"], zn = ["id", "module", "name", "brief"], qo = ["detail"], te = ["models", "surface", "packages", "settings", "config", "routes", "opaque"], Fo = "surface", pn = 40, Uo = /^(?![A-Za-z]:)(?!\/)[^\\:*?"<>|\u0000-\u001f\u007f]+$/, zo = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i, Ho = /^[a-z][a-z0-9]*$/, Ko = /^[A-Za-z_][A-Za-z0-9_]*$/, Vo = /^([|>])([-+]?)$/, Wo = "_";
|
|
369
369
|
function Hn(n) {
|
|
370
370
|
return String(n ?? "").split("/").some((e) => e.startsWith(Wo));
|
|
371
371
|
}
|
|
@@ -508,17 +508,17 @@ function Qo(n, e, o, a) {
|
|
|
508
508
|
const v = e + 1, h = ge(m).trim();
|
|
509
509
|
if (e += 1, !h) continue;
|
|
510
510
|
if (h.startsWith("-")) {
|
|
511
|
-
a.push(`第 ${v} 行:requires 下面第一层只许写七个键里的一个(${
|
|
511
|
+
a.push(`第 ${v} 行:requires 下面第一层只许写七个键里的一个(${te.join(" / ")}),不是列表项(读到 ${h})`);
|
|
512
512
|
continue;
|
|
513
513
|
}
|
|
514
514
|
const y = fn(h);
|
|
515
515
|
if (y < 0) {
|
|
516
|
-
a.push(`第 ${v} 行不是「键: 值」(${h}):requires 下面要写 ${
|
|
516
|
+
a.push(`第 ${v} 行不是「键: 值」(${h}):requires 下面要写 ${te.join(" / ")} 里的一个,值缩进在它下面`);
|
|
517
517
|
continue;
|
|
518
518
|
}
|
|
519
519
|
const _ = h.slice(0, y).trim(), g = h.slice(y + 1).trim();
|
|
520
|
-
if (!
|
|
521
|
-
a.push(`第 ${v} 行的键不认识(${_}):requires 只有 ${
|
|
520
|
+
if (!te.includes(_)) {
|
|
521
|
+
a.push(`第 ${v} 行的键不认识(${_}):requires 只有 ${te.join(" / ")} 这几个键`);
|
|
522
522
|
continue;
|
|
523
523
|
}
|
|
524
524
|
if (p[_]) {
|
|
@@ -580,7 +580,7 @@ function Zo(n, e = !0) {
|
|
|
580
580
|
const R = y.slice(_ + 1).trim();
|
|
581
581
|
if (g === "requires") {
|
|
582
582
|
if (R) {
|
|
583
|
-
o.push(`第 ${v} 行:requires 要写成下面缩进的那一块(不支持一行写完),例如 requires: 换行后缩进两格再写 ${
|
|
583
|
+
o.push(`第 ${v} 行:requires 要写成下面缩进的那一块(不支持一行写完),例如 requires: 换行后缩进两格再写 ${te.join(" / ")} 里的一个`);
|
|
584
584
|
continue;
|
|
585
585
|
}
|
|
586
586
|
const [L, P] = Qo(p, m, h, o);
|
|
@@ -619,8 +619,8 @@ function tl(n) {
|
|
|
619
619
|
return Uo.test(n) && !n.split("/").includes("..");
|
|
620
620
|
}
|
|
621
621
|
function el(n) {
|
|
622
|
-
const e = [], o = n[
|
|
623
|
-
o === void 0 ? e.push(`包里缺入口:必须有 ${
|
|
622
|
+
const e = [], o = n[Ft];
|
|
623
|
+
o === void 0 ? e.push(`包里缺入口:必须有 ${Ft}(${Kn(n)})`) : o.trim() || e.push(`${Ft} 不能是空文件`);
|
|
624
624
|
const a = n[He];
|
|
625
625
|
let r = {};
|
|
626
626
|
if (a === void 0)
|
|
@@ -645,7 +645,7 @@ function nl(n) {
|
|
|
645
645
|
}
|
|
646
646
|
return { selected: n.length, issues: e };
|
|
647
647
|
}
|
|
648
|
-
const At = "labull.css",
|
|
648
|
+
const At = "labull.css", ee = "CONTROLS.lock.html";
|
|
649
649
|
function sl(n, e) {
|
|
650
650
|
const o = String(e || "");
|
|
651
651
|
if (/@font-face|@keyframes/i.test(o)) return !0;
|
|
@@ -732,7 +732,7 @@ function bs() {
|
|
|
732
732
|
" *",
|
|
733
733
|
" * 怎么用(块里):**什么都不用加** —— 宿主会把这一份注入每个块的 iframe(`MagicBlockHost` 的 `theme` prop),",
|
|
734
734
|
' * 所以直接写类名就行:`<button class="p-button">` / `<input class="p-inputtext">` / `<span class="p-tag">`。',
|
|
735
|
-
" * 这一份放在开发包里是给你**查 / 对照 / 抄**用的(`" +
|
|
735
|
+
" * 这一份放在开发包里是给你**查 / 对照 / 抄**用的(`" + ee + "` 里的每一块 markup 都能直接用)。",
|
|
736
736
|
" * ⚠️ 别把它当块包文件塞进块里:它 500 KB 上下,而且宿主已经注入了一份(重复只会更慢)。",
|
|
737
737
|
" * ⚠️ 块里**只有 CSS,没有 JS 组件**:下拉 / 日期 / 弹窗那些要装了 PrimeVue 才有行为,",
|
|
738
738
|
" * 这里能用的是类名(按钮、输入框、标签、面板、表格、图标)。",
|
|
@@ -889,7 +889,7 @@ ${e}
|
|
|
889
889
|
`) : n;
|
|
890
890
|
}
|
|
891
891
|
function gs(n, e = {}) {
|
|
892
|
-
const o = e.bootstrap ?? "", a = e.css ?? "", r = e.themeCss ?? "", p = n[
|
|
892
|
+
const o = e.bootstrap ?? "", a = e.css ?? "", r = e.themeCss ?? "", p = n[Ft];
|
|
893
893
|
if (p === void 0) return "";
|
|
894
894
|
const { html: m, slots: d } = bl(p, n), v = vl(Wn(Wn(m, r), a), o), h = v.split(vs);
|
|
895
895
|
if (h.length === 1) return v;
|
|
@@ -900,16 +900,16 @@ function gs(n, e = {}) {
|
|
|
900
900
|
}
|
|
901
901
|
return y;
|
|
902
902
|
}
|
|
903
|
-
const hl = "html, body { margin: 0; }";
|
|
903
|
+
const hl = "html, body { margin: 0; overflow: auto !important; }";
|
|
904
904
|
function _l(n, e, o = {}) {
|
|
905
|
-
const a = al(rl(e), il(n[
|
|
905
|
+
const a = al(rl(e), il(n[Ft] ?? ""));
|
|
906
906
|
return gs(
|
|
907
|
-
{ ...n, [
|
|
907
|
+
{ ...n, [Ft]: a },
|
|
908
908
|
{ bootstrap: o.bootstrap ?? "", css: hl, themeCss: o.themeCss ?? "" }
|
|
909
909
|
);
|
|
910
910
|
}
|
|
911
|
-
const
|
|
912
|
-
let
|
|
911
|
+
const ne = /* @__PURE__ */ new Map();
|
|
912
|
+
let Gt = null;
|
|
913
913
|
const nn = /* @__PURE__ */ new Set();
|
|
914
914
|
function gl(n) {
|
|
915
915
|
return nn.add(n), () => {
|
|
@@ -917,26 +917,26 @@ function gl(n) {
|
|
|
917
917
|
};
|
|
918
918
|
}
|
|
919
919
|
function yl() {
|
|
920
|
-
|
|
920
|
+
ne.clear(), Gt = null;
|
|
921
921
|
for (const n of nn) n();
|
|
922
922
|
}
|
|
923
923
|
async function kl(n) {
|
|
924
924
|
const e = [...new Set(n)].filter(Boolean);
|
|
925
|
-
if (e.some((o) => !
|
|
926
|
-
|
|
925
|
+
if (e.some((o) => !ne.has(o))) {
|
|
926
|
+
Gt && await Gt.catch(() => {
|
|
927
927
|
});
|
|
928
|
-
const o = e.filter((a) => !
|
|
929
|
-
o.length > 0 && (
|
|
930
|
-
for (const r of a) r?.id &&
|
|
928
|
+
const o = e.filter((a) => !ne.has(a));
|
|
929
|
+
o.length > 0 && (Gt = mt(`/magic-blocks/render?ids=${o.map(encodeURIComponent).join(",")}`).then((a) => {
|
|
930
|
+
for (const r of a) r?.id && ne.set(r.id, r);
|
|
931
931
|
return a;
|
|
932
932
|
}).catch(() => []).finally(() => {
|
|
933
|
-
|
|
934
|
-
}), await
|
|
933
|
+
Gt = null;
|
|
934
|
+
}), await Gt.catch(() => {
|
|
935
935
|
}));
|
|
936
936
|
}
|
|
937
|
-
return e.map((o) =>
|
|
937
|
+
return e.map((o) => ne.get(o)).filter((o) => !!o);
|
|
938
938
|
}
|
|
939
|
-
const
|
|
939
|
+
const qt = /* @__PURE__ */ new Map(), sn = /* @__PURE__ */ new Set(), $l = 4e3;
|
|
940
940
|
let on = "", fe = null;
|
|
941
941
|
function Gn() {
|
|
942
942
|
for (const n of sn) n();
|
|
@@ -953,14 +953,14 @@ function xl(n, e) {
|
|
|
953
953
|
const o = String(n || "").trim(), a = String(e || "").trim();
|
|
954
954
|
if (!o || !a) return () => {
|
|
955
955
|
};
|
|
956
|
-
let r =
|
|
957
|
-
return r || (r = /* @__PURE__ */ new Set(),
|
|
958
|
-
const p =
|
|
959
|
-
p && (p.delete(a), p.size === 0 &&
|
|
956
|
+
let r = qt.get(o);
|
|
957
|
+
return r || (r = /* @__PURE__ */ new Set(), qt.set(o, r)), r.add(a), () => {
|
|
958
|
+
const p = qt.get(o);
|
|
959
|
+
p && (p.delete(a), p.size === 0 && qt.delete(o));
|
|
960
960
|
};
|
|
961
961
|
}
|
|
962
962
|
function ln(n, e, o) {
|
|
963
|
-
const a =
|
|
963
|
+
const a = qt.get(String(n || ""));
|
|
964
964
|
if (!a) return null;
|
|
965
965
|
for (const r of a)
|
|
966
966
|
if (r !== e && !(o && !o(r)))
|
|
@@ -968,10 +968,10 @@ function ln(n, e, o) {
|
|
|
968
968
|
return null;
|
|
969
969
|
}
|
|
970
970
|
function El(n) {
|
|
971
|
-
return [...
|
|
971
|
+
return [...qt.get(String(n || "")) ?? []];
|
|
972
972
|
}
|
|
973
973
|
function Cl(n, e, o) {
|
|
974
|
-
const a =
|
|
974
|
+
const a = qt.get(String(n || ""));
|
|
975
975
|
return !a || a.size === 0 || a.has(e) ? null : ln(n, e, o);
|
|
976
976
|
}
|
|
977
977
|
function ys(n, e = $l) {
|
|
@@ -1004,7 +1004,7 @@ const Sl = ["data-magic-block", "data-magic-module"], Bl = ["srcdoc", "title"],
|
|
|
1004
1004
|
const S = {};
|
|
1005
1005
|
for (const [O, z] of Object.entries(d.value?.files ?? {})) O !== cl && (S[O] = z);
|
|
1006
1006
|
return S;
|
|
1007
|
-
}), $t = I(() => U.value === "ok" && typeof ut.value[
|
|
1007
|
+
}), $t = I(() => U.value === "ok" && typeof ut.value[Ft] == "string");
|
|
1008
1008
|
let E = null;
|
|
1009
1009
|
function T() {
|
|
1010
1010
|
if (!e.theme) return "";
|
|
@@ -1042,13 +1042,13 @@ const Sl = ["data-magic-block", "data-magic-module"], Bl = ["srcdoc", "title"],
|
|
|
1042
1042
|
},
|
|
1043
1043
|
onNavigateTab: ct,
|
|
1044
1044
|
context: A,
|
|
1045
|
-
onDialog:
|
|
1045
|
+
onDialog: zt,
|
|
1046
1046
|
/* 🔴 块给**自己所属那条标签**起名:整页就是一个块时(`MagicBlockPage`),标签栏上那条
|
|
1047
1047
|
* 默认只有路由的 `meta.title`("订单详情"),而"订单 SO-42"只有块自己知道。 */
|
|
1048
1048
|
onTabTitle: (O, z) => o.setTitle(O, z)
|
|
1049
1049
|
}));
|
|
1050
1050
|
}
|
|
1051
|
-
function
|
|
1051
|
+
function zt(S) {
|
|
1052
1052
|
return No(S, {
|
|
1053
1053
|
uuid: e.uuid,
|
|
1054
1054
|
buildDoc: (O) => _l(d.value?.files ?? {}, O, { bootstrap: ko, themeCss: T() }),
|
|
@@ -1056,22 +1056,22 @@ const Sl = ["data-magic-block", "data-magic-module"], Bl = ["srcdoc", "title"],
|
|
|
1056
1056
|
uuid: e.uuid,
|
|
1057
1057
|
onDone: z.onDone,
|
|
1058
1058
|
onHeight: z.onHeight,
|
|
1059
|
-
onDialog:
|
|
1059
|
+
onDialog: zt,
|
|
1060
1060
|
// 弹窗里还能再弹一个(排成一摞,只有最上面那个能点)
|
|
1061
1061
|
onNavigateTab: ct,
|
|
1062
1062
|
context: A,
|
|
1063
|
-
onTabTitle: (tt,
|
|
1063
|
+
onTabTitle: (tt, Ht) => o.setTitle(tt, Ht)
|
|
1064
1064
|
})
|
|
1065
1065
|
});
|
|
1066
1066
|
}
|
|
1067
|
-
async function
|
|
1067
|
+
async function Jt() {
|
|
1068
1068
|
const S = e.uuid, O = await kl([S]);
|
|
1069
1069
|
S === e.uuid && (d.value = O.find((z) => z.id === S) ?? null);
|
|
1070
1070
|
}
|
|
1071
|
-
function
|
|
1071
|
+
function se() {
|
|
1072
1072
|
window.dispatchEvent(new CustomEvent("magic-block:open-console", { detail: { uuid: e.uuid } }));
|
|
1073
1073
|
}
|
|
1074
|
-
function
|
|
1074
|
+
function oe(S = !1) {
|
|
1075
1075
|
S && j?.(), j = xl(e.uuid, o.key);
|
|
1076
1076
|
}
|
|
1077
1077
|
const dt = (S) => !ss(S, a), Z = I(() => {
|
|
@@ -1095,7 +1095,7 @@ const Sl = ["data-magic-block", "data-magic-module"], Bl = ["srcdoc", "title"],
|
|
|
1095
1095
|
function ot() {
|
|
1096
1096
|
const S = p.value;
|
|
1097
1097
|
if (!S) return 0;
|
|
1098
|
-
const O = ht(S), z = getComputedStyle(O), tt = parseFloat(z.paddingTop) || 0,
|
|
1098
|
+
const O = ht(S), z = getComputedStyle(O), tt = parseFloat(z.paddingTop) || 0, Ht = parseFloat(z.paddingBottom) || 0, le = parseFloat(z.borderTopWidth) || 0, G = O === document.documentElement, we = G ? Math.max(0, window.innerHeight - tt - Ht) : Math.max(0, O.clientHeight - tt - Ht), xe = G ? tt : O.getBoundingClientRect().top + le + tt, Ee = G ? window.scrollY || 0 : O.scrollTop, Ce = S.getBoundingClientRect().top - xe + Ee;
|
|
1099
1099
|
return Math.max(0, Math.floor(we - Ce));
|
|
1100
1100
|
}
|
|
1101
1101
|
function lt() {
|
|
@@ -1119,11 +1119,11 @@ const Sl = ["data-magic-block", "data-magic-module"], Bl = ["srcdoc", "title"],
|
|
|
1119
1119
|
!O || !O.isConnected || O.offsetParent === null || v.value && O.scrollIntoView({ behavior: "smooth", block: "center" });
|
|
1120
1120
|
});
|
|
1121
1121
|
}), Bt(() => e.uuid, (S, O) => {
|
|
1122
|
-
O && O !== S && qn(O), h.value = 0, d.value = null,
|
|
1122
|
+
O && O !== S && qn(O), h.value = 0, d.value = null, oe(!0), v.value = Ve() === e.uuid, Jt();
|
|
1123
1123
|
}), an(() => {
|
|
1124
|
-
R = gl(() => void
|
|
1124
|
+
R = gl(() => void Jt()), L = wl(() => {
|
|
1125
1125
|
v.value = Ve() === e.uuid;
|
|
1126
|
-
}), v.value = Ve() === e.uuid,
|
|
1126
|
+
}), v.value = Ve() === e.uuid, oe(), Y(), Jt();
|
|
1127
1127
|
}), rn(() => {
|
|
1128
1128
|
qn(e.uuid), g?.disconnect(), g = null, R?.(), R = null, L?.(), L = null, j?.(), j = null, x?.(), x = null;
|
|
1129
1129
|
}), (S, O) => (u(), c("div", {
|
|
@@ -1160,7 +1160,7 @@ const Sl = ["data-magic-block", "data-magic-module"], Bl = ["srcdoc", "title"],
|
|
|
1160
1160
|
l("button", {
|
|
1161
1161
|
class: "mb__go",
|
|
1162
1162
|
type: "button",
|
|
1163
|
-
onClick: Ye(
|
|
1163
|
+
onClick: Ye(se, ["stop"])
|
|
1164
1164
|
}, "去管理台")
|
|
1165
1165
|
], 2)),
|
|
1166
1166
|
K(r) ? (u(), c("span", Ol)) : w("", !0),
|
|
@@ -1324,7 +1324,7 @@ function St(n) {
|
|
|
1324
1324
|
function Wl(n) {
|
|
1325
1325
|
return /^(https?:\/\/|mailto:|\/(?!\/))/i.test(String(n ?? "").trim());
|
|
1326
1326
|
}
|
|
1327
|
-
function
|
|
1327
|
+
function Xt(n) {
|
|
1328
1328
|
const e = String(n ?? "");
|
|
1329
1329
|
let o = "", a = 0;
|
|
1330
1330
|
for (; a < e.length; ) {
|
|
@@ -1340,7 +1340,7 @@ function Gt(n) {
|
|
|
1340
1340
|
}
|
|
1341
1341
|
const d = /^\[([^\]]*)\]\(([^)\s]*)\)/.exec(r);
|
|
1342
1342
|
if (d && Wl(d[2])) {
|
|
1343
|
-
o += `<a href="${St(d[2])}" target="_blank" rel="noopener noreferrer">${
|
|
1343
|
+
o += `<a href="${St(d[2])}" target="_blank" rel="noopener noreferrer">${Xt(d[1])}</a>`, a += d[0].length;
|
|
1344
1344
|
continue;
|
|
1345
1345
|
}
|
|
1346
1346
|
const v = /^\*\*([^*]+)\*\*/.exec(r);
|
|
@@ -1363,9 +1363,9 @@ function Gl(n) {
|
|
|
1363
1363
|
`), o = [];
|
|
1364
1364
|
let a = "", r = [], p = [], m = !1, d = [];
|
|
1365
1365
|
const v = () => {
|
|
1366
|
-
r.length > 0 && (o.push(`<p>${r.map((x) =>
|
|
1366
|
+
r.length > 0 && (o.push(`<p>${r.map((x) => Xt(x)).join("<br>")}</p>`), r = []);
|
|
1367
1367
|
}, h = () => {
|
|
1368
|
-
p.length > 0 && (o.push(`<blockquote>${p.map((x) =>
|
|
1368
|
+
p.length > 0 && (o.push(`<blockquote>${p.map((x) => Xt(x)).join("<br>")}</blockquote>`), p = []);
|
|
1369
1369
|
}, y = () => {
|
|
1370
1370
|
a && (o.push(`</${a}>`), a = "");
|
|
1371
1371
|
}, _ = () => {
|
|
@@ -1392,7 +1392,7 @@ function Gl(n) {
|
|
|
1392
1392
|
if (j) {
|
|
1393
1393
|
_();
|
|
1394
1394
|
const nt = j[1].length;
|
|
1395
|
-
o.push(`<h${nt}>${
|
|
1395
|
+
o.push(`<h${nt}>${Xt(j[2])}</h${nt}>`);
|
|
1396
1396
|
continue;
|
|
1397
1397
|
}
|
|
1398
1398
|
if (/^\s*(-{3,}|\*{3,}|_{3,})\s*$/.test(R)) {
|
|
@@ -1401,12 +1401,12 @@ function Gl(n) {
|
|
|
1401
1401
|
}
|
|
1402
1402
|
const L = /^\s*[-*+]\s+(.*)$/.exec(R);
|
|
1403
1403
|
if (L) {
|
|
1404
|
-
v(), h(), g("ul"), o.push(`<li>${
|
|
1404
|
+
v(), h(), g("ul"), o.push(`<li>${Xt(L[1])}</li>`);
|
|
1405
1405
|
continue;
|
|
1406
1406
|
}
|
|
1407
1407
|
const P = /^\s*\d+[.)]\s+(.*)$/.exec(R);
|
|
1408
1408
|
if (P) {
|
|
1409
|
-
v(), h(), g("ol"), o.push(`<li>${
|
|
1409
|
+
v(), h(), g("ol"), o.push(`<li>${Xt(P[1])}</li>`);
|
|
1410
1410
|
continue;
|
|
1411
1411
|
}
|
|
1412
1412
|
const U = /^\s*>\s?(.*)$/.exec(R);
|
|
@@ -1466,6 +1466,8 @@ function Yl(n) {
|
|
|
1466
1466
|
" * 用户的选择 `{ button, values, closed }`;要自己写整篇就传 `{ html }`(宿主给一个**按内容自适应**的面板 +",
|
|
1467
1467
|
" * 另一格沙箱 iframe 装它,里面用 `magicBlock.done({ button, values })` 把选择交回来)。",
|
|
1468
1468
|
" * ⚠️ 那一篇里**照样能用你自己那几段 `<style>` 与主题类名**:你入口 `<head>` 里的样式会被一起带过去。",
|
|
1469
|
+
" * ⚠️ 那一篇比面板高时**整篇一起滚**(宿主给的兜底压过你写的 `html, body { overflow: hidden }`)——",
|
|
1470
|
+
' * 不必自己套一层滚动容器;要"头部固定、中间自己滚"才给它 `size.height` 再自己套 `overflow: auto`。',
|
|
1469
1471
|
" *",
|
|
1470
1472
|
' * 🔴 **别在块里自己画浮层**:块可以是好几屏高,块里 `position: fixed` / `100vh` 的基准是"整块高度"、',
|
|
1471
1473
|
' * 不是用户那一屏 ⇒ 浮层会被摆到看不见的地方("弹窗没反应"多半是这个)。交给 `magicBlock.dialog()`。',
|
|
@@ -1644,7 +1646,7 @@ async function si(n, e, o, a = {}) {
|
|
|
1644
1646
|
async function Ge(n, e) {
|
|
1645
1647
|
const o = { items: [], topCount: 0, files: 0, dirs: 0 }, a = async (m, d) => {
|
|
1646
1648
|
const v = [];
|
|
1647
|
-
for (const h of await
|
|
1649
|
+
for (const h of await Ut(m)) {
|
|
1648
1650
|
if (h.kind === "file") {
|
|
1649
1651
|
o.files += 1;
|
|
1650
1652
|
continue;
|
|
@@ -1652,7 +1654,7 @@ async function Ge(n, e) {
|
|
|
1652
1654
|
o.dirs += 1, !(d >= e.maxDepth) && (e.skipDirs.includes(h.name) || v.push(h));
|
|
1653
1655
|
}
|
|
1654
1656
|
await Et(v, (h) => a(h, d + 1));
|
|
1655
|
-
}, r = await
|
|
1657
|
+
}, r = await Ut(n.handle), p = [];
|
|
1656
1658
|
for (const m of r)
|
|
1657
1659
|
if (o.items.push({ name: m.name, dir: m.kind === "directory" }), m.kind === "file") o.files += 1;
|
|
1658
1660
|
else {
|
|
@@ -1663,7 +1665,7 @@ async function Ge(n, e) {
|
|
|
1663
1665
|
}
|
|
1664
1666
|
async function oi(n) {
|
|
1665
1667
|
const e = [];
|
|
1666
|
-
for (const a of await
|
|
1668
|
+
for (const a of await Ut(n.handle)) e.push(a.name);
|
|
1667
1669
|
let o = 0;
|
|
1668
1670
|
return await Et(e, async (a) => {
|
|
1669
1671
|
await n.handle.removeEntry(a, { recursive: !0 }), o += 1;
|
|
@@ -1674,7 +1676,7 @@ async function li(n, e, o = []) {
|
|
|
1674
1676
|
let d = 0;
|
|
1675
1677
|
const v = async (h, y) => {
|
|
1676
1678
|
const _ = [], g = [];
|
|
1677
|
-
for (const x of await
|
|
1679
|
+
for (const x of await Ut(h)) {
|
|
1678
1680
|
const R = y ? `${y}/${x.name}` : x.name;
|
|
1679
1681
|
if (!(!y && p.has(R))) {
|
|
1680
1682
|
if (x.kind === "file") {
|
|
@@ -1702,7 +1704,7 @@ function Es(n) {
|
|
|
1702
1704
|
async function ii(n, e) {
|
|
1703
1705
|
const { wantedFiles: o, wantedDirs: a } = Es(e), r = /* @__PURE__ */ new Set(), p = async (m, d) => {
|
|
1704
1706
|
const v = [];
|
|
1705
|
-
for (const h of await
|
|
1707
|
+
for (const h of await Ut(m)) {
|
|
1706
1708
|
const y = d ? `${d}/${h.name}` : h.name;
|
|
1707
1709
|
if (h.kind === "file") {
|
|
1708
1710
|
o.has(y) && r.add(y);
|
|
@@ -1727,7 +1729,7 @@ function ri(n, e) {
|
|
|
1727
1729
|
`这一趟要铺的是"只导框架文件",但回话里带着块代码(${a}):后端还没支持这一档 —— 把后端升上去再试(照这份报文铺下去会把 ${e.blocksDir}/ 里的块代码整库覆盖)。`
|
|
1728
1730
|
);
|
|
1729
1731
|
}
|
|
1730
|
-
async function
|
|
1732
|
+
async function Ut(n) {
|
|
1731
1733
|
const e = [];
|
|
1732
1734
|
for await (const o of n.values()) e.push(o);
|
|
1733
1735
|
return e.sort((o, a) => o.name < a.name ? -1 : o.name > a.name ? 1 : 0), e;
|
|
@@ -1741,7 +1743,7 @@ function ci(n) {
|
|
|
1741
1743
|
}
|
|
1742
1744
|
const di = { folders: [], failures: [], truncated: !1 };
|
|
1743
1745
|
async function Cs(n, e, o) {
|
|
1744
|
-
const a = await
|
|
1746
|
+
const a = await Ut(n), r = new Array(a.length);
|
|
1745
1747
|
await Et(a, async (d, v) => {
|
|
1746
1748
|
const h = e ? `${e}/${d.name}` : d.name, y = { files: {}, failures: [] };
|
|
1747
1749
|
if (r[v] = y, d.kind === "directory") {
|
|
@@ -1783,7 +1785,7 @@ async function Cs(n, e, o) {
|
|
|
1783
1785
|
return { files: p, failures: m };
|
|
1784
1786
|
}
|
|
1785
1787
|
async function Ss(n, e, o, a) {
|
|
1786
|
-
const r = await
|
|
1788
|
+
const r = await Ut(n), p = r.filter((_) => _.kind === "directory"), m = r.filter((_) => _.kind === "file"), d = e.join("/"), v = { folders: [], failures: [], truncated: !1 };
|
|
1787
1789
|
if (p.length === 0 || m.some((_) => _.name === a.entry)) {
|
|
1788
1790
|
const _ = await Cs(n, d, a);
|
|
1789
1791
|
return v.folders.push({ where: d, files: _.files }), v.failures.push(..._.failures), v;
|
|
@@ -1928,28 +1930,28 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
1928
1930
|
}, Ir = {
|
|
1929
1931
|
key: 1,
|
|
1930
1932
|
class: "mbc__hint"
|
|
1931
|
-
}, Nr = {
|
|
1933
|
+
}, Nr = { class: "mbc__field mbc__field--end" }, qr = ["disabled", "title"], Fr = {
|
|
1932
1934
|
key: 0,
|
|
1933
1935
|
class: "mbc__hint"
|
|
1934
|
-
},
|
|
1936
|
+
}, Ur = { class: "mbc__ok-text" }, zr = ["disabled"], Hr = ["disabled"], Kr = {
|
|
1935
1937
|
key: 1,
|
|
1936
1938
|
class: "mbc__scan"
|
|
1937
|
-
},
|
|
1939
|
+
}, Vr = { class: "mbc__pick" }, Wr = ["disabled", "checked", "onChange"], Gr = { class: "mbc__name" }, Xr = { class: "mbc__module" }, Jr = { class: "mbc__hint" }, Yr = { class: "mbc__mono" }, Qr = {
|
|
1938
1940
|
key: 0,
|
|
1939
1941
|
class: "mbc__problem"
|
|
1940
|
-
},
|
|
1942
|
+
}, Zr = {
|
|
1941
1943
|
key: 1,
|
|
1942
1944
|
class: "mbc__failures"
|
|
1943
|
-
},
|
|
1945
|
+
}, tu = { class: "mbc__hint mbc__mono" }, eu = {
|
|
1944
1946
|
key: 2,
|
|
1945
1947
|
class: "mbc__hint"
|
|
1946
|
-
},
|
|
1948
|
+
}, nu = { class: "mbc__field" }, su = ["title"], ou = {
|
|
1947
1949
|
key: 1,
|
|
1948
1950
|
class: "mbc__chip is-ok"
|
|
1949
|
-
},
|
|
1951
|
+
}, lu = ["title"], iu = {
|
|
1950
1952
|
key: 3,
|
|
1951
1953
|
class: "mbc__hint"
|
|
1952
|
-
},
|
|
1954
|
+
}, au = { class: "mbc__panel mbc__panel--declared" }, ru = { class: "mbc__title" }, uu = { class: "p-tag p-tag-info" }, cu = { class: "mbc__count" }, du = {
|
|
1953
1955
|
key: 0,
|
|
1954
1956
|
class: "mbc__hint"
|
|
1955
1957
|
}, pu = { class: "mbc__hint" }, fu = { class: "mbc__scan" }, mu = { class: "mbc__pick" }, bu = { class: "mbc__name" }, vu = { class: "p-tag p-tag-info" }, hu = { class: "mbc__module" }, _u = { class: "mbc__hint" }, gu = { class: "mbc__mono" }, yu = { class: "mbc__hint mbc__mono" }, ku = {
|
|
@@ -2011,15 +2013,15 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
2011
2013
|
两种情形共用它(前端声明了、手里却还没有那个文件夹 / 手里那个文件夹的清单 id 库里没有)
|
|
2012
2014
|
—— 对用户是同一件事:这个块不在库里。 */
|
|
2013
2015
|
"not-in-db": "不在数据库"
|
|
2014
|
-
}, o = e["not-in-db"], { isStaff: a } = ns(), r = es(), { active: p } = _o(), m = (i) => !ss(i, r), d = B(!1), v = B(""), h = B([]), y = B(""), _ = B(""), g = B(""), x = B([]), R = B(!1), j = B(!1), L = B("blocks"), P = B(""), U = B([]), nt = B(""), st = B(""), vt = B(""), kt = B(""), D = B(!1), Mt = B(!1), ut = B(!1), $t = B(!1), E = B(!1), T = B(null), $ = B(null), A = B("one"), ct = B(
|
|
2015
|
-
function
|
|
2016
|
+
}, o = e["not-in-db"], { isStaff: a } = ns(), r = es(), { active: p } = _o(), m = (i) => !ss(i, r), d = B(!1), v = B(""), h = B([]), y = B(""), _ = B(""), g = B(""), x = B([]), R = B(!1), j = B(!1), L = B("blocks"), P = B(""), U = B([]), nt = B(""), st = B(""), vt = B(""), kt = B(""), D = B(!1), Mt = B(!1), ut = B(!1), $t = B(!1), E = B(!1), T = B(null), $ = B(null), A = B("one"), ct = B(oe()), Q = I(() => h.value.find((i) => i.id === ct.value) ?? null), zt = () => A.value === "framework" ? { framework: !0 } : A.value === "all" ? {} : { blocks: [ct.value] }, Jt = I(() => A.value === "framework" ? "只铺框架文件(顶层那几份生成物 + example/):workspace/ 里的块代码一个字节都不写、也不删" : A.value === "one" && !Q.value ? "先在左边挑一个块(或者把范围改成「全部块」/「只铺框架文件」)" : "把库里的块铺到你选的文件夹");
|
|
2017
|
+
function se(i) {
|
|
2016
2018
|
ct.value = i;
|
|
2017
2019
|
try {
|
|
2018
2020
|
window.localStorage.setItem("mb:export-block", i);
|
|
2019
2021
|
} catch {
|
|
2020
2022
|
}
|
|
2021
2023
|
}
|
|
2022
|
-
function
|
|
2024
|
+
function oe() {
|
|
2023
2025
|
try {
|
|
2024
2026
|
return window.localStorage.getItem("mb:export-block") ?? "";
|
|
2025
2027
|
} catch {
|
|
@@ -2027,7 +2029,7 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
2027
2029
|
}
|
|
2028
2030
|
}
|
|
2029
2031
|
Bt(h, (i) => {
|
|
2030
|
-
i.length !== 0 && (i.some((t) => t.id === ct.value) ||
|
|
2032
|
+
i.length !== 0 && (i.some((t) => t.id === ct.value) || se(i[0].id));
|
|
2031
2033
|
});
|
|
2032
2034
|
const dt = B(null), Z = B(""), F = B(null), ht = B({}), ot = B([]), lt = B([]), Y = B(null), S = B({}), O = B(""), z = B(null);
|
|
2033
2035
|
async function tt(i) {
|
|
@@ -2036,16 +2038,16 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
2036
2038
|
const t = await mt(`/magic-blocks/${encodeURIComponent(i)}/versions`);
|
|
2037
2039
|
S.value = { ...S.value, [i]: t.versions ?? [] };
|
|
2038
2040
|
} catch (t) {
|
|
2039
|
-
|
|
2041
|
+
Qt(t, "读版本列表");
|
|
2040
2042
|
} finally {
|
|
2041
2043
|
O.value = "";
|
|
2042
2044
|
}
|
|
2043
2045
|
}
|
|
2044
|
-
function
|
|
2046
|
+
function Ht(i) {
|
|
2045
2047
|
const t = [i.current ? "当前" : "", i.empty ? "空包(代码被删过)" : ""].filter(Boolean).join("、");
|
|
2046
2048
|
return `v${i.number}${t ? ` · ${t}` : ""}`;
|
|
2047
2049
|
}
|
|
2048
|
-
function
|
|
2050
|
+
function le(i) {
|
|
2049
2051
|
return i < 1024 ? `${i} B` : i < 1024 * 1024 ? `${Math.round(i / 1024)} KB` : `${(i / 1024 / 1024).toFixed(1)} MB`;
|
|
2050
2052
|
}
|
|
2051
2053
|
const G = B(null);
|
|
@@ -2073,7 +2075,7 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
2073
2075
|
const b = await Ce(i.target, i.folder), M = await oi(b);
|
|
2074
2076
|
s = `清掉了本机「${i.target.name}/${i.folder}」里的 ${M} 项`;
|
|
2075
2077
|
} catch (b) {
|
|
2076
|
-
s = `本机那份没清成(${
|
|
2078
|
+
s = `本机那份没清成(${Kt(b)})`;
|
|
2077
2079
|
}
|
|
2078
2080
|
else
|
|
2079
2081
|
s = "没选开发目录 ⇒ 本机那份没动";
|
|
@@ -2081,9 +2083,9 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
2081
2083
|
try {
|
|
2082
2084
|
await mt(`/magic-blocks/${i.row.id}`, { method: "DELETE" });
|
|
2083
2085
|
} catch (b) {
|
|
2084
|
-
throw Dt(!1, "本机清了,但库里那份代码没清成"), new Error(`${s};但**库里那份代码没清成**(${
|
|
2086
|
+
throw Dt(!1, "本机清了,但库里那份代码没清成"), new Error(`${s};但**库里那份代码没清成**(${Kt(b)})—— 再点一次「删除代码文件」`);
|
|
2085
2087
|
}
|
|
2086
|
-
await
|
|
2088
|
+
await Pt(), Z.value = `${t}的代码文件已删除:${s};库里那一份也清空了 ——**块还在**(页面上会显示成占位框)。想找回来:上面「块」那一屏点开这一块 → 版本史 → 对上一版点「切回」`, g.value = `删掉了${t}的代码文件(块本身还在)`, Dt(!0, "完成");
|
|
2087
2089
|
}, D);
|
|
2088
2090
|
async function Ce(i, t) {
|
|
2089
2091
|
let s = i.handle;
|
|
@@ -2091,7 +2093,7 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
2091
2093
|
s = await s.getDirectoryHandle(b, { create: !0 });
|
|
2092
2094
|
return { handle: s, name: `${i.name}/${t}` };
|
|
2093
2095
|
}
|
|
2094
|
-
const V = B(null),
|
|
2096
|
+
const V = B(null), ie = B(!1), X = B({ active: !1, percent: 0, stage: "", failed: !1 }), Bs = I(() => ({
|
|
2095
2097
|
width: `${Math.max(0, Math.min(100, X.value.percent))}%`,
|
|
2096
2098
|
background: X.value.failed ? "var(--sp-color-danger)" : "var(--sp-color-primary, var(--primary-color))"
|
|
2097
2099
|
}));
|
|
@@ -2114,12 +2116,12 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
2114
2116
|
function bn() {
|
|
2115
2117
|
Se = [], Be(!0);
|
|
2116
2118
|
}
|
|
2117
|
-
const vn = (i) => (i.disabledReason ?? "").trim(), Te = (i) => (i.issues ?? []).map((t) => String(t?.message ?? "")).filter(Boolean),
|
|
2119
|
+
const vn = (i) => (i.disabledReason ?? "").trim(), Te = (i) => (i.issues ?? []).map((t) => String(t?.message ?? "")).filter(Boolean), ae = (i) => El(i.id);
|
|
2118
2120
|
function Ts(i) {
|
|
2119
2121
|
y.value = y.value === i.id ? "" : i.id, y.value === i.id && tt(i.id);
|
|
2120
2122
|
const t = p.value;
|
|
2121
2123
|
ys(i.id);
|
|
2122
|
-
const s = i.name || i.id, b =
|
|
2124
|
+
const s = i.name || i.id, b = ae(i);
|
|
2123
2125
|
if (b.length === 0) {
|
|
2124
2126
|
g.value = `「${s}」这次会话里还没在哪条标签上露过面:先打开挂着它的那一页,再点一次`;
|
|
2125
2127
|
return;
|
|
@@ -2143,7 +2145,7 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
2143
2145
|
}, D), Ms = (i, t) => et(async () => {
|
|
2144
2146
|
window.confirm(`把「${i.name || i.id}」切回 v${t}?
|
|
2145
2147
|
|
|
2146
|
-
这会把那一版的代码变成**当前版**,并且记成一个**新版本**(号继续 +1):历史只追加,旧版本一个都不会没。`) && (await
|
|
2148
|
+
这会把那一版的代码变成**当前版**,并且记成一个**新版本**(号继续 +1):历史只追加,旧版本一个都不会没。`) && (await Lt(`/magic-blocks/${encodeURIComponent(i.id)}/versions/${t}`, { updatedBy: "" }), g.value = `「${i.name || i.id}」已切回 v${t}(并记成了一个新版本)`, await Pt(), await tt(i.id));
|
|
2147
2149
|
}, D), Ds = (i, t) => et(async () => {
|
|
2148
2150
|
window.confirm(`删掉「${i.name || i.id}」的 v${t}?
|
|
2149
2151
|
|
|
@@ -2167,11 +2169,11 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
2167
2169
|
nt.value = i.id, st.value = (i.tags ?? []).join(", ");
|
|
2168
2170
|
}
|
|
2169
2171
|
const hn = (i) => et(async () => {
|
|
2170
|
-
const t = st.value.split(/[,,\s]+/).map((b) => b.trim()).filter(Boolean), s = await
|
|
2171
|
-
nt.value = "", g.value = `「${i.name || i.id}」的标签已存:${(s.tags ?? []).join(" / ") || "(一个都不剩)"}`, await
|
|
2172
|
+
const t = st.value.split(/[,,\s]+/).map((b) => b.trim()).filter(Boolean), s = await Lt(`/magic-blocks/${encodeURIComponent(i.id)}/tags`, { tags: t });
|
|
2173
|
+
nt.value = "", g.value = `「${i.name || i.id}」的标签已存:${(s.tags ?? []).join(" / ") || "(一个都不剩)"}`, await Pt();
|
|
2172
2174
|
}, D, "存标签"), js = (i) => et(async () => {
|
|
2173
|
-
const t = await
|
|
2174
|
-
vt.value = "", g.value = `「${i.name || i.id}」的详情已存${(t.detail ?? "").trim() ? "" : "(清掉了)"};块包里那份 ${Fn} 跟着一起写了`, await
|
|
2175
|
+
const t = await Lt(`/magic-blocks/${encodeURIComponent(i.id)}/detail`, { detail: kt.value });
|
|
2176
|
+
vt.value = "", g.value = `「${i.name || i.id}」的详情已存${(t.detail ?? "").trim() ? "" : "(清掉了)"};块包里那份 ${Fn} 跟着一起写了`, await Pt();
|
|
2175
2177
|
}, D, "存详情");
|
|
2176
2178
|
function Ls(i) {
|
|
2177
2179
|
vt.value = i.id, kt.value = (i.detail ?? "").trim();
|
|
@@ -2187,20 +2189,20 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
2187
2189
|
const t = P.value.trim().toLowerCase();
|
|
2188
2190
|
return t ? (i.tags ?? []).some((s) => s.toLowerCase().includes(t)) : !0;
|
|
2189
2191
|
}
|
|
2190
|
-
function
|
|
2192
|
+
function re(i) {
|
|
2191
2193
|
const t = i.code;
|
|
2192
2194
|
return t && typeof t.total == "number" ? t : null;
|
|
2193
2195
|
}
|
|
2194
2196
|
function _n(i) {
|
|
2195
|
-
const t =
|
|
2197
|
+
const t = re(i);
|
|
2196
2198
|
return t ? `${t.total} 行` : "";
|
|
2197
2199
|
}
|
|
2198
2200
|
function gn(i) {
|
|
2199
|
-
const t =
|
|
2201
|
+
const t = re(i);
|
|
2200
2202
|
return t && t.nonEffective > 0 ? `另有 ${t.nonEffective} 行不生效` : "";
|
|
2201
2203
|
}
|
|
2202
2204
|
function yn(i) {
|
|
2203
|
-
const t =
|
|
2205
|
+
const t = re(i);
|
|
2204
2206
|
if (!t) return "";
|
|
2205
2207
|
const s = [
|
|
2206
2208
|
`生效代码 ${t.total} 行 · ${t.files} 个文件(含注释与空行)`,
|
|
@@ -2215,14 +2217,14 @@ const fi = { class: "mbc__head" }, mi = ["title"], bi = ["title"], vi = {
|
|
|
2215
2217
|
`);
|
|
2216
2218
|
}
|
|
2217
2219
|
function qs(i) {
|
|
2218
|
-
const t =
|
|
2220
|
+
const t = ae(i), s = t.length === 0 ? "点一下:这次会话里它还没在哪条标签上露过面" : `点一下:把「${i.name || i.id}」标红,并在需要时切到挂着它的标签(${t.join(" / ")})`, b = vn(i);
|
|
2219
2221
|
return b ? `${b}
|
|
2220
2222
|
${s}` : s;
|
|
2221
2223
|
}
|
|
2222
2224
|
const kn = I(() => {
|
|
2223
2225
|
const i = v.value.trim().toLowerCase();
|
|
2224
2226
|
return h.value.filter((t) => Ns(t) ? i ? `${t.module} ${t.name} ${t.brief} ${t.detail ?? ""} ${t.id} v${t.version ?? ""} ${(t.tags ?? []).join(" ")}`.toLowerCase().includes(i) : !0 : !1);
|
|
2225
|
-
}),
|
|
2227
|
+
}), ue = I(() => (F.value?.blocks ?? []).filter((i) => i.canApply)), Ot = I(() => ue.value.filter((i) => ht.value[i.id] === !0)), Rt = B(!1), _t = I(() => ot.value.length + (F.value?.failures ?? []).length + lt.value.filter((i) => !i.ok).length), Yt = I(() => lt.value.filter((i) => !i.ok)), Ae = I(() => lt.value.filter((i) => i.ok).length), Me = I(() => h.value.filter((i) => i.enabled === !1).length), jt = I(() => (Y.value?.results ?? []).filter((i) => (i.verifyNotes ?? []).length > 0)), Ct = I(() => jt.value.reduce((i, t) => i + (t.verifyNotes ?? []).length, 0)), it = I(() => (Y.value?.results ?? []).filter((i) => i.probeRan !== !0).map((i) => i.name || i.id));
|
|
2226
2228
|
function Fs() {
|
|
2227
2229
|
const i = /* @__PURE__ */ new Set(), t = [];
|
|
2228
2230
|
for (const s of De()) {
|
|
@@ -2257,8 +2259,8 @@ ${s}` : s;
|
|
|
2257
2259
|
for (const [b, M] of Object.entries(Us)) {
|
|
2258
2260
|
const q = t[b], H = [];
|
|
2259
2261
|
if (b === "surface" && q && typeof q == "object")
|
|
2260
|
-
for (const [J,
|
|
2261
|
-
for (const pt of Array.isArray(
|
|
2262
|
+
for (const [J, Nt] of Object.entries(q))
|
|
2263
|
+
for (const pt of Array.isArray(Nt) ? Nt : []) H.push(`${J}.${String(pt)}`);
|
|
2262
2264
|
else if (Array.isArray(q))
|
|
2263
2265
|
for (const J of q) H.push(String(J));
|
|
2264
2266
|
H.length > 0 && s.push({ key: b, title: M, values: H });
|
|
@@ -2268,19 +2270,19 @@ ${s}` : s;
|
|
|
2268
2270
|
function zs(i) {
|
|
2269
2271
|
return Vl(i.requires?.routes, De());
|
|
2270
2272
|
}
|
|
2271
|
-
function
|
|
2273
|
+
function Kt(i) {
|
|
2272
2274
|
return (i instanceof Error ? i.message.trim() : String(i)) || "请求没有到达后端(网络或登录态的问题),请重试";
|
|
2273
2275
|
}
|
|
2274
2276
|
function Hs(i) {
|
|
2275
2277
|
const t = i?.issues;
|
|
2276
2278
|
return Array.isArray(t) ? t.map((s) => typeof s == "string" ? s : String(s?.message ?? "")).filter(Boolean) : [];
|
|
2277
2279
|
}
|
|
2278
|
-
async function
|
|
2280
|
+
async function Lt(i, t) {
|
|
2279
2281
|
const s = JSON.stringify(t);
|
|
2280
2282
|
try {
|
|
2281
2283
|
return await mt(i, { method: "POST", body: s });
|
|
2282
2284
|
} catch (b) {
|
|
2283
|
-
const M =
|
|
2285
|
+
const M = Kt(b), q = await fetch(`${Qe}${i}`, {
|
|
2284
2286
|
method: "POST",
|
|
2285
2287
|
credentials: "include",
|
|
2286
2288
|
headers: { "Content-Type": "application/json", ...be("POST", !0) },
|
|
@@ -2299,7 +2301,7 @@ ${t.text}`).join(`
|
|
|
2299
2301
|
try {
|
|
2300
2302
|
await navigator.clipboard.writeText(i), g.value = `已复制 ${x.value.length} 条报错`;
|
|
2301
2303
|
} catch (t) {
|
|
2302
|
-
|
|
2304
|
+
Qt(t, "复制报错");
|
|
2303
2305
|
}
|
|
2304
2306
|
}
|
|
2305
2307
|
function Vs() {
|
|
@@ -2307,7 +2309,7 @@ ${t.text}`).join(`
|
|
|
2307
2309
|
ot.value.length > 0 && i.push("【前端校验拦下的】", ...ot.value.map((t) => `- ${t}`), "");
|
|
2308
2310
|
for (const t of F.value?.failures ?? [])
|
|
2309
2311
|
i.push(`【读回:${t.kind || "问题"}】${t.where || ""}`, `- ${t.message || ""}`, "");
|
|
2310
|
-
for (const t of
|
|
2312
|
+
for (const t of Yt.value)
|
|
2311
2313
|
i.push(
|
|
2312
2314
|
`【没存成】${t.name || t.id}`,
|
|
2313
2315
|
`- ${t.error || ""}`,
|
|
@@ -2318,7 +2320,7 @@ ${t.text}`).join(`
|
|
|
2318
2320
|
`【体检:这一趟没验运行期(不是错)】只做了静态判据(引用 / 字段 / 枚举在不在),运行期错误一个都没验 —— 那 ${it.value.length} 个块的"通过"是静态通过,不等于"跑得起来":${it.value.join(" / ")}`,
|
|
2319
2321
|
""
|
|
2320
2322
|
);
|
|
2321
|
-
for (const t of
|
|
2323
|
+
for (const t of jt.value)
|
|
2322
2324
|
i.push(
|
|
2323
2325
|
`【体检说明:提示 / 没验到(不是错)】${t.name || t.id}`,
|
|
2324
2326
|
...(t.verifyNotes ?? []).map((s) => `- ${s}`),
|
|
@@ -2331,22 +2333,22 @@ ${t.text}`).join(`
|
|
|
2331
2333
|
try {
|
|
2332
2334
|
await navigator.clipboard.writeText(Vs()), g.value = `已复制这一趟的 ${_t.value} 条问题`;
|
|
2333
2335
|
} catch (i) {
|
|
2334
|
-
|
|
2336
|
+
Qt(i, "复制问题");
|
|
2335
2337
|
}
|
|
2336
2338
|
}
|
|
2337
|
-
function
|
|
2338
|
-
const s =
|
|
2339
|
+
function Qt(i, t) {
|
|
2340
|
+
const s = Kt(i);
|
|
2339
2341
|
_.value = s, x.value = [...x.value, { at: (/* @__PURE__ */ new Date()).toLocaleTimeString(), where: t, text: s }];
|
|
2340
2342
|
}
|
|
2341
2343
|
function Re() {
|
|
2342
2344
|
_.value = "", x.value = [];
|
|
2343
2345
|
}
|
|
2344
|
-
async function
|
|
2346
|
+
async function Pt() {
|
|
2345
2347
|
try {
|
|
2346
2348
|
const i = await mt("/magic-blocks/index");
|
|
2347
2349
|
h.value = i.blocks ?? [], U.value = i.tags ?? [];
|
|
2348
2350
|
} catch (i) {
|
|
2349
|
-
|
|
2351
|
+
Qt(i, "读块清单");
|
|
2350
2352
|
}
|
|
2351
2353
|
}
|
|
2352
2354
|
async function et(i, t, s = "") {
|
|
@@ -2354,7 +2356,7 @@ ${t.text}`).join(`
|
|
|
2354
2356
|
try {
|
|
2355
2357
|
await i(), yl();
|
|
2356
2358
|
} catch (b) {
|
|
2357
|
-
|
|
2359
|
+
Qt(b, s || "这个动作");
|
|
2358
2360
|
} finally {
|
|
2359
2361
|
t.value = !1;
|
|
2360
2362
|
}
|
|
@@ -2365,7 +2367,7 @@ ${t.text}`).join(`
|
|
|
2365
2367
|
const i = await mt("/magic-blocks/check", { method: "POST", body: JSON.stringify({}) });
|
|
2366
2368
|
Y.value = i;
|
|
2367
2369
|
const t = Ct.value;
|
|
2368
|
-
g.value = `全部魔法块重新校验完了:查了 ${i.checked} 个块,通过 ${i.passed}、停用 ${i.disabled};${it.value.length > 0 ? `⚠️ 这一趟**没验运行期**(${it.value.length} 个块)` : "运行期也真跑了一遍"}` + (t > 0 ? `;另有 ${t} 条"没验到 / 只提示"的说明,见下面那一段` : ""), await
|
|
2370
|
+
g.value = `全部魔法块重新校验完了:查了 ${i.checked} 个块,通过 ${i.passed}、停用 ${i.disabled};${it.value.length > 0 ? `⚠️ 这一趟**没验运行期**(${it.value.length} 个块)` : "运行期也真跑了一遍"}` + (t > 0 ? `;另有 ${t} 条"没验到 / 只提示"的说明,见下面那一段` : ""), await Pt();
|
|
2369
2371
|
} finally {
|
|
2370
2372
|
Mt.value = !1;
|
|
2371
2373
|
}
|
|
@@ -2383,15 +2385,15 @@ ${t.text}`).join(`
|
|
|
2383
2385
|
const i = A.value === "framework";
|
|
2384
2386
|
if (A.value === "one" && !Q.value)
|
|
2385
2387
|
throw new Error("还没挑块:上面选「仅这一个块」时要先在下拉里挑一个块(或者把范围改成「全部块」/「只铺框架文件」)");
|
|
2386
|
-
ut.value = !0, g.value = "", Z.value = "", Re(), bn(), Le.length = 0, ce = performance.now(),
|
|
2388
|
+
ut.value = !0, g.value = "", Z.value = "", Re(), bn(), Le.length = 0, ce = performance.now(), Vt = null, Wt = null, X.value = { active: !0, percent: 0, stage: "准备…", failed: !1 };
|
|
2387
2389
|
try {
|
|
2388
2390
|
const t = T.value ?? await We();
|
|
2389
2391
|
T.value = t, $.value || ($.value = t);
|
|
2390
|
-
const s =
|
|
2392
|
+
const s = Lt("/magic-blocks/export", zt()), b = Ie(), M = dt.value ? Ge(t, dt.value) : null, q = await It("取包", s);
|
|
2391
2393
|
dt.value = q.rules, ai(t, q.rules);
|
|
2392
|
-
const H = M ? await
|
|
2394
|
+
const H = M ? await It("数目录", M) : await It("数目录", Ge(t, q.rules));
|
|
2393
2395
|
if (H.topCount > 0) {
|
|
2394
|
-
wt(5, "等你确认要不要先清空"),
|
|
2396
|
+
wt(5, "等你确认要不要先清空"), Vt = q, Wt = b, V.value = { target: t, inventory: H, framework: i, exampleDir: q.exampleDir ?? "" };
|
|
2395
2397
|
return;
|
|
2396
2398
|
}
|
|
2397
2399
|
await Ne(t, q, { clean: !1, verify: !1, front: b, framework: i });
|
|
@@ -2401,11 +2403,11 @@ ${t.text}`).join(`
|
|
|
2401
2403
|
ut.value = !1;
|
|
2402
2404
|
}
|
|
2403
2405
|
}, D), xn = /* @__PURE__ */ new WeakMap(), Le = [];
|
|
2404
|
-
let ce = 0,
|
|
2406
|
+
let ce = 0, Vt = null, Wt = null;
|
|
2405
2407
|
function Pe(i, t) {
|
|
2406
2408
|
Le.push([i, Math.round(performance.now() - t)]);
|
|
2407
2409
|
}
|
|
2408
|
-
async function
|
|
2410
|
+
async function It(i, t) {
|
|
2409
2411
|
const s = performance.now();
|
|
2410
2412
|
try {
|
|
2411
2413
|
return await t;
|
|
@@ -2428,7 +2430,7 @@ ${t.text}`).join(`
|
|
|
2428
2430
|
note: s.skipped.length > 0 ? `;⚠️ 有 ${s.skipped.length} 张样式表读不到规则(跨源):${s.skipped.join(" / ")}` : ""
|
|
2429
2431
|
};
|
|
2430
2432
|
} catch (s) {
|
|
2431
|
-
t = { css: "", controls: "", note: `;主题 CSS 没收成(${
|
|
2433
|
+
t = { css: "", controls: "", note: `;主题 CSS 没收成(${Kt(s)}):${At} 没写,其余照旧` };
|
|
2432
2434
|
}
|
|
2433
2435
|
return Pe("收主题", i), t;
|
|
2434
2436
|
}
|
|
@@ -2437,8 +2439,8 @@ ${t.text}`).join(`
|
|
|
2437
2439
|
H && ri(t.files, t.rules);
|
|
2438
2440
|
try {
|
|
2439
2441
|
wt(20, "准备写盘…");
|
|
2440
|
-
const
|
|
2441
|
-
pt[me] =
|
|
2442
|
+
const Nt = Yl(Fs()), pt = { ...t.files };
|
|
2443
|
+
pt[me] = Nt, J.css && (pt[At] = J.css), J.controls && (pt[ee] = J.controls), t.exampleDir && (pt[`${t.exampleDir}/${me}`] = Nt, J.css && (pt[`${t.exampleDir}/${At}`] = J.css), J.controls && (pt[`${t.exampleDir}/${ee}`] = J.controls));
|
|
2442
2444
|
const no = J.note;
|
|
2443
2445
|
await new Promise((ft) => {
|
|
2444
2446
|
setTimeout(ft, 0);
|
|
@@ -2446,10 +2448,10 @@ ${t.text}`).join(`
|
|
|
2446
2448
|
let Tn = "", qe;
|
|
2447
2449
|
if (b) {
|
|
2448
2450
|
wt(35, "清掉这一包不要的东西…");
|
|
2449
|
-
const ft = await
|
|
2451
|
+
const ft = await It("清多余", li(i, pt, H ? [t.rules.blocksDir] : []));
|
|
2450
2452
|
qe = ft.existing, Tn = ft.removed > 0 ? `,先清掉了 ${ft.removed} 项` : ",没有多余的东西要清";
|
|
2451
2453
|
} else
|
|
2452
|
-
wt(35, "看一眼目录里有什么…"), qe = await
|
|
2454
|
+
wt(35, "看一眼目录里有什么…"), qe = await It("看目录", ii(i, pt));
|
|
2453
2455
|
const so = xn.get(i.handle), oo = Object.keys(pt).length, Fe = b ? 45 : 30;
|
|
2454
2456
|
wt(Fe, `写文件 0/${oo}…`);
|
|
2455
2457
|
let An = 0;
|
|
@@ -2465,10 +2467,10 @@ ${t.text}`).join(`
|
|
|
2465
2467
|
Pe("写盘", lo), xn.set(i.handle, at.fingerprints), wt(98, "收尾…");
|
|
2466
2468
|
const io = at.failed.length > 0 ? `;⚠️ ${at.failed.length} 个文件没写成:${at.failed.slice(0, 3).map((ft) => `${ft.path}(${ft.message})`).join("、")}` + (at.failed.length > 3 ? ` 等 ${at.failed.length} 条` : "") : "", de = [];
|
|
2467
2469
|
at.skipped > 0 && de.push(`${at.skipped} 个与库里一字不差(逐字节比过)`), at.trusted > 0 && de.push(`${at.trusted} 个按上一趟的账本跳过(没再碰磁盘)`);
|
|
2468
|
-
const Mn = de.length > 0 ? `,跳过 ${de.join(" / ")}` : "", ao = `${me} / ${At} / ${
|
|
2469
|
-
Z.value = (H ? `只铺「${i.name}」里的**框架文件**:写了 ${at.written} 个文件${Mn}(${ao};${t.rules.blocksDir}/ 里的块代码一个字节都没动)` : `铺到「${i.name}」:${t.blocks} 个块、写了 ${at.written} 个文件${Mn}(含 ${me} / ${At} / ${
|
|
2470
|
-
} catch (
|
|
2471
|
-
throw Dt(!1, "导出中途失败(已经铺进去的文件不会自己删掉)"),
|
|
2470
|
+
const Mn = de.length > 0 ? `,跳过 ${de.join(" / ")}` : "", ao = `${me} / ${At} / ${ee}` + (t.exampleDir ? ` / ${t.exampleDir}/` : "") + " 与顶层另外那几份生成物";
|
|
2471
|
+
Z.value = (H ? `只铺「${i.name}」里的**框架文件**:写了 ${at.written} 个文件${Mn}(${ao};${t.rules.blocksDir}/ 里的块代码一个字节都没动)` : `铺到「${i.name}」:${t.blocks} 个块、写了 ${at.written} 个文件${Mn}(含 ${me} / ${At} / ${ee})`) + `${Tn}${io}${no}${Js()}`, g.value = at.failed.length > 0 ? "导出完了,但有文件没写成(见下面那句)" : "导出完了:用你自己的编辑器改,改完回这里「读回改动」", Dt(!0, "完成"), Vt = null, Wt = null;
|
|
2472
|
+
} catch (Nt) {
|
|
2473
|
+
throw Dt(!1, "导出中途失败(已经铺进去的文件不会自己删掉)"), Nt;
|
|
2472
2474
|
}
|
|
2473
2475
|
}
|
|
2474
2476
|
const Ys = () => et(async () => {
|
|
@@ -2476,11 +2478,11 @@ ${t.text}`).join(`
|
|
|
2476
2478
|
if (V.value = null, !!i) {
|
|
2477
2479
|
ut.value = !0;
|
|
2478
2480
|
try {
|
|
2479
|
-
const t =
|
|
2481
|
+
const t = Vt ?? await It("取包", Lt("/magic-blocks/export", zt())), s = Wt ?? Ie();
|
|
2480
2482
|
dt.value = t.rules, await Ne(i.target, t, {
|
|
2481
2483
|
clean: !0,
|
|
2482
2484
|
verify: !0,
|
|
2483
|
-
thorough:
|
|
2485
|
+
thorough: ie.value,
|
|
2484
2486
|
framework: i.framework,
|
|
2485
2487
|
front: s
|
|
2486
2488
|
});
|
|
@@ -2495,11 +2497,11 @@ ${t.text}`).join(`
|
|
|
2495
2497
|
if (V.value = null, !!i) {
|
|
2496
2498
|
ut.value = !0;
|
|
2497
2499
|
try {
|
|
2498
|
-
const t =
|
|
2500
|
+
const t = Vt ?? await It("取包", Lt("/magic-blocks/export", zt())), s = Wt ?? Ie();
|
|
2499
2501
|
dt.value = t.rules, await Ne(i.target, t, {
|
|
2500
2502
|
clean: !1,
|
|
2501
2503
|
verify: !0,
|
|
2502
|
-
thorough:
|
|
2504
|
+
thorough: ie.value,
|
|
2503
2505
|
framework: i.framework,
|
|
2504
2506
|
front: s
|
|
2505
2507
|
});
|
|
@@ -2511,14 +2513,14 @@ ${t.text}`).join(`
|
|
|
2511
2513
|
}
|
|
2512
2514
|
}, D);
|
|
2513
2515
|
function Zs() {
|
|
2514
|
-
V.value = null,
|
|
2516
|
+
V.value = null, Vt = null, Wt = null, ce = 0, X.value = { active: !1, percent: 0, stage: "", failed: !1 }, g.value = "这次没有导出(目录里的东西一个字节都没动)", Z.value = "";
|
|
2515
2517
|
}
|
|
2516
2518
|
const En = () => et(async () => {
|
|
2517
2519
|
const i = $.value ?? await We();
|
|
2518
2520
|
$.value = i, T.value || (T.value = i), $t.value = !0, g.value = "", ot.value = [], lt.value = [];
|
|
2519
2521
|
try {
|
|
2520
2522
|
const t = await je().catch((H) => {
|
|
2521
|
-
throw new Error(`取不到扫描规则(GET /magic-blocks/rules):${
|
|
2523
|
+
throw new Error(`取不到扫描规则(GET /magic-blocks/rules):${Kt(H)}`);
|
|
2522
2524
|
}), s = await pi(i, t), b = await mt("/magic-blocks/read", {
|
|
2523
2525
|
method: "POST",
|
|
2524
2526
|
body: JSON.stringify({ ...s, includeMissing: !1 })
|
|
@@ -2533,15 +2535,15 @@ ${t.text}`).join(`
|
|
|
2533
2535
|
$t.value = !1;
|
|
2534
2536
|
}
|
|
2535
2537
|
}, D), to = () => et(async () => {
|
|
2536
|
-
const i =
|
|
2538
|
+
const i = Ot.value, t = nl(i);
|
|
2537
2539
|
if (ot.value = t.issues, lt.value = [], t.issues.length > 0)
|
|
2538
2540
|
throw g.value = "", new Error(`前端校验没过(${t.issues.length} 条),没有发请求:
|
|
2539
2541
|
- ${t.issues.join(`
|
|
2540
2542
|
- `)}`);
|
|
2541
2543
|
E.value = !0, g.value = "";
|
|
2542
2544
|
try {
|
|
2543
|
-
const s = await
|
|
2544
|
-
lt.value = s.results ?? [], g.value = `保存:成功 ${s.saved} 个、失败 ${s.failed} 个`, await
|
|
2545
|
+
const s = await Lt("/magic-blocks/import", { updatedBy: "", blocks: i });
|
|
2546
|
+
lt.value = s.results ?? [], g.value = `保存:成功 ${s.saved} 个、失败 ${s.failed} 个`, await Pt();
|
|
2545
2547
|
const b = g.value;
|
|
2546
2548
|
await En(), g.value = `${b};已重新读回该目录`;
|
|
2547
2549
|
} finally {
|
|
@@ -2554,7 +2556,7 @@ ${t.text}`).join(`
|
|
|
2554
2556
|
}
|
|
2555
2557
|
function Cn(i) {
|
|
2556
2558
|
const t = { ...ht.value };
|
|
2557
|
-
for (const s of
|
|
2559
|
+
for (const s of ue.value) t[s.id] = i;
|
|
2558
2560
|
ht.value = t;
|
|
2559
2561
|
}
|
|
2560
2562
|
function Sn(i) {
|
|
@@ -2565,7 +2567,7 @@ ${t.text}`).join(`
|
|
|
2565
2567
|
i.key === "Escape" && d.value && (d.value = !1);
|
|
2566
2568
|
}
|
|
2567
2569
|
return an(() => {
|
|
2568
|
-
window.addEventListener("magic-block:open-console", Sn), window.addEventListener("keydown", Bn),
|
|
2570
|
+
window.addEventListener("magic-block:open-console", Sn), window.addEventListener("keydown", Bn), Pt(), je().catch(() => {
|
|
2569
2571
|
});
|
|
2570
2572
|
}), rn(() => {
|
|
2571
2573
|
window.removeEventListener("magic-block:open-console", Sn), window.removeEventListener("keydown", Bn);
|
|
@@ -2683,10 +2685,10 @@ ${t.text}`).join(`
|
|
|
2683
2685
|
])),
|
|
2684
2686
|
l("label", Oi, [
|
|
2685
2687
|
rt(l("input", {
|
|
2686
|
-
"onUpdate:modelValue": t[5] || (t[5] = (s) =>
|
|
2688
|
+
"onUpdate:modelValue": t[5] || (t[5] = (s) => ie.value = s),
|
|
2687
2689
|
type: "checkbox"
|
|
2688
2690
|
}, null, 512), [
|
|
2689
|
-
[ts,
|
|
2691
|
+
[ts, ie.value]
|
|
2690
2692
|
]),
|
|
2691
2693
|
l("span", null, [
|
|
2692
2694
|
t[72] || (t[72] = k("逐个核对磁盘(慢):把上一趟铺过的也重新读一遍比对,", -1)),
|
|
@@ -2771,7 +2773,7 @@ ${t.text}`).join(`
|
|
|
2771
2773
|
type: "search",
|
|
2772
2774
|
placeholder: "筛选 module / 名字 / 备注 / 详情 / id / 版本号 / 标签"
|
|
2773
2775
|
}, null, 512), [
|
|
2774
|
-
[
|
|
2776
|
+
[Zt, v.value]
|
|
2775
2777
|
]),
|
|
2776
2778
|
U.value.length > 0 ? (u(), c("div", Xi, [
|
|
2777
2779
|
t[89] || (t[89] = l("span", { class: "mbc__label" }, "标签", -1)),
|
|
@@ -2781,7 +2783,7 @@ ${t.text}`).join(`
|
|
|
2781
2783
|
type: "search",
|
|
2782
2784
|
placeholder: "只看贴了…的块"
|
|
2783
2785
|
}, null, 512), [
|
|
2784
|
-
[
|
|
2786
|
+
[Zt, P.value]
|
|
2785
2787
|
]),
|
|
2786
2788
|
(u(!0), c(C, null, N(U.value.slice(0, 24), (s) => (u(), c("button", {
|
|
2787
2789
|
key: s.tag,
|
|
@@ -2832,7 +2834,7 @@ ${t.text}`).join(`
|
|
|
2832
2834
|
class: "mbc__loc mbc__loc--inert",
|
|
2833
2835
|
title: yn(s)
|
|
2834
2836
|
}, f(gn(s)), 9, sa)) : w("", !0),
|
|
2835
|
-
|
|
2837
|
+
ae(s).length > 0 ? (u(), c("span", oa, f(ae(s).join(" / ")), 1)) : w("", !0),
|
|
2836
2838
|
l("em", {
|
|
2837
2839
|
class: W({ "is-off": s.enabled === !1 })
|
|
2838
2840
|
}, f(s.enabled === !1 ? vn(s) || "校验失败已停用" : "可用"), 3),
|
|
@@ -2881,7 +2883,7 @@ ${t.text}`).join(`
|
|
|
2881
2883
|
- 怎么用:搜手机号 → 打开档案
|
|
2882
2884
|
(**别写**路由名 / 字段名 / 实现方式)`
|
|
2883
2885
|
}, null, 512), [
|
|
2884
|
-
[
|
|
2886
|
+
[Zt, kt.value]
|
|
2885
2887
|
]),
|
|
2886
2888
|
l("button", {
|
|
2887
2889
|
class: "p-button p-button-sm",
|
|
@@ -2899,7 +2901,7 @@ ${t.text}`).join(`
|
|
|
2899
2901
|
]),
|
|
2900
2902
|
t[103] || (t[103] = l("dt", null, "文件", -1)),
|
|
2901
2903
|
l("dd", null, f((s.fileNames || []).join(" / ") || "(没有文件)"), 1),
|
|
2902
|
-
|
|
2904
|
+
re(s) ? (u(), c(C, { key: 0 }, [
|
|
2903
2905
|
t[95] || (t[95] = l("dt", null, "代码", -1)),
|
|
2904
2906
|
l("dd", null, [
|
|
2905
2907
|
l("b", null, f(s.code?.total ?? 0), 1),
|
|
@@ -2988,7 +2990,7 @@ ${t.text}`).join(`
|
|
|
2988
2990
|
placeholder: "逗号分隔,例如:订单, 报表",
|
|
2989
2991
|
onKeyup: po((b) => hn(s), ["enter"])
|
|
2990
2992
|
}, null, 40, Ma), [
|
|
2991
|
-
[
|
|
2993
|
+
[Zt, st.value]
|
|
2992
2994
|
]),
|
|
2993
2995
|
l("button", {
|
|
2994
2996
|
class: "p-button p-button-sm",
|
|
@@ -3053,9 +3055,9 @@ ${t.text}`).join(`
|
|
|
3053
3055
|
key: b.number,
|
|
3054
3056
|
class: W({ "is-current": b.current })
|
|
3055
3057
|
}, [
|
|
3056
|
-
l("span", Va, f(
|
|
3058
|
+
l("span", Va, f(Ht(b)), 1),
|
|
3057
3059
|
l("span", Wa, [
|
|
3058
|
-
k(f(b.fileCount) + " 个文件 · " + f(
|
|
3060
|
+
k(f(b.fileCount) + " 个文件 · " + f(le(b.sizeBytes)), 1),
|
|
3059
3061
|
b.createdBy ? (u(), c(C, { key: 0 }, [
|
|
3060
3062
|
k(" · " + f(b.createdBy), 1)
|
|
3061
3063
|
], 64)) : w("", !0),
|
|
@@ -3106,7 +3108,7 @@ ${t.text}`).join(`
|
|
|
3106
3108
|
key: M,
|
|
3107
3109
|
class: "mbc__viewer-file"
|
|
3108
3110
|
}, [
|
|
3109
|
-
l("summary", nr, f(M) + "(" + f(
|
|
3111
|
+
l("summary", nr, f(M) + "(" + f(le(b.length)) + ")", 1),
|
|
3110
3112
|
l("pre", sr, f(b), 1)
|
|
3111
3113
|
]))), 128))
|
|
3112
3114
|
])) : w("", !0)
|
|
@@ -3144,7 +3146,7 @@ ${t.text}`).join(`
|
|
|
3144
3146
|
key: 0,
|
|
3145
3147
|
class: "p-button p-button-sm p-button-text",
|
|
3146
3148
|
type: "button",
|
|
3147
|
-
onClick: t[20] || (t[20] = (s) =>
|
|
3149
|
+
onClick: t[20] || (t[20] = (s) => Rt.value = !0)
|
|
3148
3150
|
}, "查看体检说明(" + f(Ct.value) + ")", 1)) : w("", !0)
|
|
3149
3151
|
])) : w("", !0),
|
|
3150
3152
|
Y.value ? (u(), c("div", cr, [
|
|
@@ -3156,8 +3158,8 @@ ${t.text}`).join(`
|
|
|
3156
3158
|
t[117] || (t[117] = l("b", null, '别把"通过"读成"跑得起来"', -1)),
|
|
3157
3159
|
t[118] || (t[118] = k(":探针没跑,所以运行期错误**一个都没验** —— handler 里会在运行时炸的那些(字段用错、查询写错)这一次看不出来。 探针不跑的原因逐块写在下面那些说明里(非 SQLite 的库 / 深检被关掉 / 环境起不来)。 ", -1))
|
|
3158
3160
|
])) : (u(), c("p", fr, "运行期也**真跑**了一遍(探针跑了:每个 handler 都用它自己的内存库试跑过)。")),
|
|
3159
|
-
|
|
3160
|
-
(u(!0), c(C, null, N(
|
|
3161
|
+
jt.value.length > 0 ? (u(), c(C, { key: 2 }, [
|
|
3162
|
+
(u(!0), c(C, null, N(jt.value, (s) => (u(), c("p", {
|
|
3161
3163
|
key: s.id,
|
|
3162
3164
|
class: "mbc__hint"
|
|
3163
3165
|
}, [
|
|
@@ -3208,7 +3210,7 @@ ${t.text}`).join(`
|
|
|
3208
3210
|
class: "p-inputtext p-component mbc__grow",
|
|
3209
3211
|
value: ct.value,
|
|
3210
3212
|
disabled: D.value || h.value.length === 0,
|
|
3211
|
-
onChange: t[24] || (t[24] = (s) =>
|
|
3213
|
+
onChange: t[24] || (t[24] = (s) => se(s.target.value))
|
|
3212
3214
|
}, [
|
|
3213
3215
|
h.value.length === 0 ? (u(), c("option", wr, "(库里还没有块)")) : w("", !0),
|
|
3214
3216
|
(u(!0), c(C, null, N(h.value, (s) => (u(), c("option", {
|
|
@@ -3236,12 +3238,12 @@ ${t.text}`).join(`
|
|
|
3236
3238
|
class: "p-button p-button-sm mbc__act-export",
|
|
3237
3239
|
type: "button",
|
|
3238
3240
|
disabled: D.value || A.value === "one" && !Q.value,
|
|
3239
|
-
title:
|
|
3241
|
+
title: Jt.value,
|
|
3240
3242
|
onClick: t[26] || (t[26] = (s) => Xs())
|
|
3241
3243
|
}, f(ut.value ? "导出中…" : "导出"), 9, Br)
|
|
3242
3244
|
]),
|
|
3243
3245
|
A.value === "framework" ? (u(), c("p", Tr, [...t[124] || (t[124] = [
|
|
3244
|
-
fo(' 这一趟只铺<b data-v-
|
|
3246
|
+
fo(' 这一趟只铺<b data-v-e324211d>框架文件</b>:顶层那几份生成物(<span class="mbc__mono" data-v-e324211d>AGENTS.lock.md</span> / <span class="mbc__mono" data-v-e324211d>backend.lock.pyi</span> / <span class="mbc__mono" data-v-e324211d>requirements.lock.txt</span> / <span class="mbc__mono" data-v-e324211d>smoke.lock.mjs</span> / <span class="mbc__mono" data-v-e324211d>pages.lock.ts</span> / <span class="mbc__mono" data-v-e324211d>labull.css</span> / <span class="mbc__mono" data-v-e324211d>CONTROLS.lock.html</span>) 与 <span class="mbc__mono" data-v-e324211d>example/</span> 那一层。 🔴 <span class="mbc__mono" data-v-e324211d>workspace/</span> 里的块代码<b data-v-e324211d>一个字节都不写、也不删</b> (连「清空并导出」都不进那一层)—— 平台升级之后刷新框架就用这一档。 ', 23)
|
|
3245
3247
|
])])) : (u(), c("p", Ar, [
|
|
3246
3248
|
k(f(A.value === "all" ? `这一趟铺全部 ${h.value.length} 个块` : Q.value ? `这一趟只铺「${Q.value.module} / ${Q.value.name || Q.value.id}」` : "先挑一个块") + " ⇒ ", 1),
|
|
3247
3249
|
t[125] || (t[125] = l("span", { class: "mbc__mono" }, "workspace/<可读名>-<块 uuid>/", -1)),
|
|
@@ -3278,34 +3280,43 @@ ${t.text}`).join(`
|
|
|
3278
3280
|
}, f($t.value ? "读回中…" : "读回改动"), 9, Lr)
|
|
3279
3281
|
]),
|
|
3280
3282
|
$.value && T.value && $.value.name !== T.value.name ? (u(), c("p", Pr, " 读回的是「" + f($.value.name) + "」(与导出目录「" + f(T.value.name) + "」不是同一个 —— 想同步就再选一次)。 ", 1)) : (u(), c("p", Ir, "读回目录默认跟着导出目录;要读别的文件夹就点「选择文件夹」单独选一个。")),
|
|
3283
|
+
l("div", Nr, [
|
|
3284
|
+
l("button", {
|
|
3285
|
+
class: "p-button p-button-sm mbc__act-import",
|
|
3286
|
+
type: "button",
|
|
3287
|
+
disabled: D.value || Ot.value.length === 0,
|
|
3288
|
+
title: Ot.value.length === 0 ? "先「读回改动」,再在清单里勾上要存的块(勾不上的是目录里缺的那一块)" : `存这 ${Ot.value.length} 个块:校验 + 体检 + 记一版`,
|
|
3289
|
+
onClick: t[29] || (t[29] = (s) => to())
|
|
3290
|
+
}, f(E.value ? "保存中…" : `保存选中的块(${Ot.value.length})`), 9, qr)
|
|
3291
|
+
]),
|
|
3281
3292
|
F.value ? (u(), c(C, { key: 2 }, [
|
|
3282
|
-
|
|
3293
|
+
ue.value.length > 0 ? (u(), c("p", Fr, [
|
|
3283
3294
|
t[132] || (t[132] = k(" 扫到 ", -1)),
|
|
3284
3295
|
l("b", null, f(F.value.blocks.length), 1),
|
|
3285
3296
|
t[133] || (t[133] = k(" 个块,其中 ", -1)),
|
|
3286
|
-
l("b",
|
|
3297
|
+
l("b", Ur, f(ue.value.length), 1),
|
|
3287
3298
|
t[134] || (t[134] = k(" 个可以存;已经勾了 ", -1)),
|
|
3288
|
-
l("b", null, f(
|
|
3299
|
+
l("b", null, f(Ot.value.length), 1),
|
|
3289
3300
|
t[135] || (t[135] = k(" 个。 ", -1)),
|
|
3290
3301
|
l("button", {
|
|
3291
3302
|
class: "p-button p-button-sm p-button-text",
|
|
3292
3303
|
type: "button",
|
|
3293
3304
|
disabled: D.value,
|
|
3294
|
-
onClick: t[
|
|
3295
|
-
}, "全选可存的", 8,
|
|
3305
|
+
onClick: t[30] || (t[30] = (s) => Cn(!0))
|
|
3306
|
+
}, "全选可存的", 8, zr),
|
|
3296
3307
|
l("button", {
|
|
3297
3308
|
class: "p-button p-button-sm p-button-text",
|
|
3298
3309
|
type: "button",
|
|
3299
|
-
disabled: D.value ||
|
|
3300
|
-
onClick: t[
|
|
3301
|
-
}, "全不选", 8,
|
|
3310
|
+
disabled: D.value || Ot.value.length === 0,
|
|
3311
|
+
onClick: t[31] || (t[31] = (s) => Cn(!1))
|
|
3312
|
+
}, "全不选", 8, Hr)
|
|
3302
3313
|
])) : w("", !0),
|
|
3303
|
-
F.value.blocks.length > 0 ? (u(), c("ul",
|
|
3314
|
+
F.value.blocks.length > 0 ? (u(), c("ul", Kr, [
|
|
3304
3315
|
(u(!0), c(C, null, N(F.value.blocks, (s) => (u(), c("li", {
|
|
3305
3316
|
key: s.id,
|
|
3306
3317
|
class: W(["mbc__block", { "is-picked": ht.value[s.id] === !0, "is-blocked": !s.canApply }])
|
|
3307
3318
|
}, [
|
|
3308
|
-
l("label",
|
|
3319
|
+
l("label", Vr, [
|
|
3309
3320
|
l("span", {
|
|
3310
3321
|
class: W(["p-checkbox p-component", { "p-disabled": !s.canApply }])
|
|
3311
3322
|
}, [
|
|
@@ -3315,64 +3326,56 @@ ${t.text}`).join(`
|
|
|
3315
3326
|
disabled: !s.canApply,
|
|
3316
3327
|
checked: ht.value[s.id] === !0,
|
|
3317
3328
|
onChange: (b) => eo(s.id, b)
|
|
3318
|
-
}, null, 40,
|
|
3329
|
+
}, null, 40, Wr),
|
|
3319
3330
|
t[136] || (t[136] = l("span", { class: "p-checkbox-box" }, null, -1))
|
|
3320
3331
|
], 2),
|
|
3321
|
-
l("span",
|
|
3332
|
+
l("span", Gr, f(s.name || s.id), 1),
|
|
3322
3333
|
l("span", {
|
|
3323
3334
|
class: W(["p-tag", s.status === "modified" ? "p-tag-success" : s.status === "missing" ? "p-tag-warning" : s.status === "not-in-db" ? "p-tag-info" : ""])
|
|
3324
3335
|
}, f(e[s.status]), 3),
|
|
3325
|
-
l("span",
|
|
3336
|
+
l("span", Xr, f(s.module || "—"), 1)
|
|
3326
3337
|
]),
|
|
3327
|
-
l("p",
|
|
3338
|
+
l("p", Jr, [
|
|
3328
3339
|
s.status === "missing" ? (u(), c(C, { key: 0 }, [
|
|
3329
3340
|
k("目录里没有这一块,勾不上")
|
|
3330
3341
|
], 64)) : s.status === "not-in-db" ? (u(), c(C, { key: 1 }, [
|
|
3331
3342
|
k("库里还没有这一块 —— 勾上它保存,就是按这一包新建")
|
|
3332
3343
|
], 64)) : s.changedFiles.length > 0 ? (u(), c(C, { key: 2 }, [
|
|
3333
3344
|
t[137] || (t[137] = k("改了:", -1)),
|
|
3334
|
-
l("span",
|
|
3345
|
+
l("span", Yr, f(s.changedFiles.join(" / ")), 1)
|
|
3335
3346
|
], 64)) : (u(), c(C, { key: 3 }, [
|
|
3336
3347
|
k("内容与库里一致")
|
|
3337
3348
|
], 64))
|
|
3338
3349
|
]),
|
|
3339
|
-
s.blockedWhy ? (u(), c("p",
|
|
3340
|
-
(s.verifyNotes ?? []).length > 0 ? (u(), c("ul",
|
|
3350
|
+
s.blockedWhy ? (u(), c("p", Qr, "不能存:" + f(s.blockedWhy), 1)) : w("", !0),
|
|
3351
|
+
(s.verifyNotes ?? []).length > 0 ? (u(), c("ul", Zr, [
|
|
3341
3352
|
(u(!0), c(C, null, N(s.verifyNotes ?? [], (b, M) => (u(), c("li", {
|
|
3342
3353
|
key: M,
|
|
3343
3354
|
class: "mbc__note"
|
|
3344
3355
|
}, f(b), 1))), 128))
|
|
3345
3356
|
])) : w("", !0),
|
|
3346
|
-
l("p",
|
|
3357
|
+
l("p", tu, f(s.folder || s.where), 1)
|
|
3347
3358
|
], 2))), 128))
|
|
3348
|
-
])) : (u(), c("p",
|
|
3349
|
-
l("div",
|
|
3359
|
+
])) : (u(), c("p", eu, "这个目录里没有认出任何块(点上面那个按钮再扫一次,或者确认文件夹名里有那个块的 uuid)。")),
|
|
3360
|
+
l("div", nu, [
|
|
3350
3361
|
_t.value > 0 ? (u(), c("button", {
|
|
3351
3362
|
key: 0,
|
|
3352
3363
|
class: "p-button p-button-sm mbc__report-btn",
|
|
3353
3364
|
type: "button",
|
|
3354
3365
|
title: "点开看这一趟的全部问题(" + _t.value + " 条)",
|
|
3355
|
-
onClick: t[
|
|
3356
|
-
}, "查看问题(" + f(_t.value) + ")⚠", 9,
|
|
3366
|
+
onClick: t[32] || (t[32] = (s) => Rt.value = !0)
|
|
3367
|
+
}, "查看问题(" + f(_t.value) + ")⚠", 9, su)) : (u(), c("span", ou, "这一趟没有问题")),
|
|
3357
3368
|
F.value.unmatched.length > 0 ? (u(), c("span", {
|
|
3358
3369
|
key: 2,
|
|
3359
3370
|
class: "mbc__chip is-bad",
|
|
3360
3371
|
title: F.value.unmatched.join(" / ")
|
|
3361
|
-
}, "认不出归属的文件夹 " + f(F.value.unmatched.length), 9,
|
|
3372
|
+
}, "认不出归属的文件夹 " + f(F.value.unmatched.length), 9, lu)) : w("", !0)
|
|
3362
3373
|
]),
|
|
3363
|
-
(F.value.skipped ?? []).length > 0 ? (u(), c("p",
|
|
3374
|
+
(F.value.skipped ?? []).length > 0 ? (u(), c("p", iu, [
|
|
3364
3375
|
k(" 忽略了 " + f((F.value.skipped ?? []).length) + " 个文件夹(名字里没有 uuid,当测试文件处理 —— 与忽略 ", 1),
|
|
3365
3376
|
t[138] || (t[138] = l("span", { class: "mbc__mono" }, "example/", -1)),
|
|
3366
3377
|
k(" 同一个规矩):" + f((F.value.skipped ?? []).join(" / ")), 1)
|
|
3367
|
-
])) : w("", !0)
|
|
3368
|
-
l("div", lu, [
|
|
3369
|
-
l("button", {
|
|
3370
|
-
class: "p-button p-button-sm mbc__act-import",
|
|
3371
|
-
type: "button",
|
|
3372
|
-
disabled: D.value,
|
|
3373
|
-
onClick: t[32] || (t[32] = (s) => to())
|
|
3374
|
-
}, f(E.value ? "保存中…" : `保存选中的块(${ue.value.length})`), 9, iu)
|
|
3375
|
-
])
|
|
3378
|
+
])) : w("", !0)
|
|
3376
3379
|
], 64)) : w("", !0)
|
|
3377
3380
|
], 512), [
|
|
3378
3381
|
[pe, L.value === "workspace"]
|
|
@@ -3427,15 +3430,15 @@ ${t.text}`).join(`
|
|
|
3427
3430
|
t[150] || (t[150] = l("h3", { class: "mbc__title" }, "保存结果", -1)),
|
|
3428
3431
|
l("p", $u, [
|
|
3429
3432
|
l("span", wu, "存成 " + f(Ae.value), 1),
|
|
3430
|
-
|
|
3433
|
+
Yt.value.length > 0 ? (u(), c("span", xu, "没存成 " + f(Yt.value.length), 1)) : w("", !0),
|
|
3431
3434
|
ot.value.length > 0 ? (u(), c("span", Eu, "前端拦下 " + f(ot.value.length), 1)) : w("", !0),
|
|
3432
|
-
|
|
3435
|
+
Yt.value.length === 0 && ot.value.length === 0 ? (u(), c("span", Cu, "明细在下面那个「查看问题」里(没问题时是空的)。")) : w("", !0)
|
|
3433
3436
|
]),
|
|
3434
3437
|
l("div", Su, [
|
|
3435
3438
|
l("button", {
|
|
3436
3439
|
class: "p-button p-button-sm mbc__report-btn",
|
|
3437
3440
|
type: "button",
|
|
3438
|
-
onClick: t[33] || (t[33] = (s) =>
|
|
3441
|
+
onClick: t[33] || (t[33] = (s) => Rt.value = !0)
|
|
3439
3442
|
}, " 查看问题(" + f(_t.value) + f(Ct.value > 0 ? ` + 提示 ${Ct.value}` : "") + ")⚠ ", 1)
|
|
3440
3443
|
])
|
|
3441
3444
|
])) : w("", !0),
|
|
@@ -3455,12 +3458,12 @@ ${t.text}`).join(`
|
|
|
3455
3458
|
_.value ? (u(), c("p", Au, f(_.value), 1)) : g.value ? (u(), c("p", Mu, f(g.value), 1)) : (u(), c("p", Du, "—"))
|
|
3456
3459
|
])
|
|
3457
3460
|
], 2)) : w("", !0),
|
|
3458
|
-
d.value &&
|
|
3461
|
+
d.value && Rt.value ? (u(), c("div", {
|
|
3459
3462
|
key: 1,
|
|
3460
3463
|
class: "mbc__modal",
|
|
3461
3464
|
role: "dialog",
|
|
3462
3465
|
"aria-modal": "true",
|
|
3463
|
-
onClick: t[38] || (t[38] = Ye((s) =>
|
|
3466
|
+
onClick: t[38] || (t[38] = Ye((s) => Rt.value = !1, ["self"]))
|
|
3464
3467
|
}, [
|
|
3465
3468
|
l("div", Ou, [
|
|
3466
3469
|
l("header", Ru, [
|
|
@@ -3468,7 +3471,7 @@ ${t.text}`).join(`
|
|
|
3468
3471
|
l("button", {
|
|
3469
3472
|
class: "p-button p-button-sm p-button-text",
|
|
3470
3473
|
type: "button",
|
|
3471
|
-
onClick: t[35] || (t[35] = (s) =>
|
|
3474
|
+
onClick: t[35] || (t[35] = (s) => Rt.value = !1)
|
|
3472
3475
|
}, "收起")
|
|
3473
3476
|
]),
|
|
3474
3477
|
l("div", ju, [
|
|
@@ -3497,7 +3500,7 @@ ${t.text}`).join(`
|
|
|
3497
3500
|
])
|
|
3498
3501
|
])) : w("", !0),
|
|
3499
3502
|
lt.value.length > 0 ? (u(), c("section", Gu, [
|
|
3500
|
-
l("h4", Xu, "保存结果(" + f(lt.value.length) + ":存成 " + f(Ae.value) + ",没存成 " + f(
|
|
3503
|
+
l("h4", Xu, "保存结果(" + f(lt.value.length) + ":存成 " + f(Ae.value) + ",没存成 " + f(Yt.value.length) + ")", 1),
|
|
3501
3504
|
l("ul", Ju, [
|
|
3502
3505
|
(u(!0), c(C, null, N(lt.value, (s) => (u(), c("li", {
|
|
3503
3506
|
key: s.id,
|
|
@@ -3511,7 +3514,7 @@ ${t.text}`).join(`
|
|
|
3511
3514
|
], 2))), 128))
|
|
3512
3515
|
])
|
|
3513
3516
|
])) : w("", !0),
|
|
3514
|
-
Y.value && (it.value.length > 0 ||
|
|
3517
|
+
Y.value && (it.value.length > 0 || jt.value.length > 0) ? (u(), c("section", Zu, [
|
|
3515
3518
|
l("h4", tc, "体检:提示 / 没验到(**不是错**," + f(Ct.value + (it.value.length > 0 ? 1 : 0)) + " 条)", 1),
|
|
3516
3519
|
l("ul", ec, [
|
|
3517
3520
|
it.value.length > 0 ? (u(), c("li", nc, [
|
|
@@ -3519,7 +3522,7 @@ ${t.text}`).join(`
|
|
|
3519
3522
|
k(" 只做了静态判据(引用 / 字段 / 枚举在不在),运行期错误**一个都没验** —— 那 " + f(it.value.length) + ' 个块的"通过"是**静态通过**,不等于"跑得起来"。 没验的是:', 1),
|
|
3520
3523
|
l("span", sc, f(it.value.join(" / ")), 1)
|
|
3521
3524
|
])) : w("", !0),
|
|
3522
|
-
(u(!0), c(C, null, N(
|
|
3525
|
+
(u(!0), c(C, null, N(jt.value, (s) => (u(), c("li", {
|
|
3523
3526
|
key: s.id,
|
|
3524
3527
|
class: "mbc__note"
|
|
3525
3528
|
}, [
|
|
@@ -3531,7 +3534,7 @@ ${t.text}`).join(`
|
|
|
3531
3534
|
]),
|
|
3532
3535
|
t[153] || (t[153] = l("p", { class: "mbc__hint" }, ' 这一栏与"问题"分开:上面的都得改,这一栏**不拦保存、也不让块停用** (依赖声明那几条判据结论只在 `LABULL_REQUIRES` **显式写成 `warn`** 时才走这里; **默认档是 `error`**,那一档下它们进的是上面那个「问题」)。 ', -1))
|
|
3533
3536
|
])) : w("", !0),
|
|
3534
|
-
_t.value === 0 && !(Y.value && (it.value.length > 0 ||
|
|
3537
|
+
_t.value === 0 && !(Y.value && (it.value.length > 0 || jt.value.length > 0)) ? (u(), c("p", lc, "这一趟没有问题。")) : w("", !0)
|
|
3535
3538
|
]),
|
|
3536
3539
|
l("footer", ic, [
|
|
3537
3540
|
l("button", {
|
|
@@ -3542,7 +3545,7 @@ ${t.text}`).join(`
|
|
|
3542
3545
|
l("button", {
|
|
3543
3546
|
class: "p-button p-button-sm",
|
|
3544
3547
|
type: "button",
|
|
3545
|
-
onClick: t[37] || (t[37] = (s) =>
|
|
3548
|
+
onClick: t[37] || (t[37] = (s) => Rt.value = !1)
|
|
3546
3549
|
}, "知道了")
|
|
3547
3550
|
])
|
|
3548
3551
|
])
|
|
@@ -3603,7 +3606,7 @@ ${t.text}`).join(`
|
|
|
3603
3606
|
}, "×")) : w("", !0)
|
|
3604
3607
|
], 2)) : w("", !0);
|
|
3605
3608
|
}
|
|
3606
|
-
}), Hc = /* @__PURE__ */ cn(_c, [["__scopeId", "data-v-
|
|
3609
|
+
}), Hc = /* @__PURE__ */ cn(_c, [["__scopeId", "data-v-e324211d"]]), gc = ["aria-label"], yc = ["srcdoc"], kc = { class: "mbd__head" }, $c = { class: "mbd__title" }, wc = {
|
|
3607
3610
|
key: 0,
|
|
3608
3611
|
class: "mbd__body"
|
|
3609
3612
|
}, xc = {
|
|
@@ -3770,7 +3773,7 @@ ${t.text}`).join(`
|
|
|
3770
3773
|
rows: "3",
|
|
3771
3774
|
placeholder: $.placeholder
|
|
3772
3775
|
}, null, 8, Bc)), [
|
|
3773
|
-
[
|
|
3776
|
+
[Zt, p.value[$.name]]
|
|
3774
3777
|
]) : $.type === "select" ? rt((u(), c("select", {
|
|
3775
3778
|
key: 1,
|
|
3776
3779
|
"onUpdate:modelValue": (A) => p.value[$.name] = A,
|
|
@@ -3821,7 +3824,7 @@ Object.assign(ws, { [$s]: !0 });
|
|
|
3821
3824
|
export {
|
|
3822
3825
|
Qe as API_BASE,
|
|
3823
3826
|
cl as BLOCK_BACKEND_FILE,
|
|
3824
|
-
|
|
3827
|
+
Ft as BLOCK_ENTRY,
|
|
3825
3828
|
He as BLOCK_MANIFEST,
|
|
3826
3829
|
$s as BLOCK_PAGE_MARK,
|
|
3827
3830
|
as as CLIENT_SOURCE,
|
|
@@ -3835,7 +3838,7 @@ export {
|
|
|
3835
3838
|
ws as MagicBlockPage,
|
|
3836
3839
|
pn as NAME_MAX,
|
|
3837
3840
|
Fn as README_OPEN,
|
|
3838
|
-
|
|
3841
|
+
te as REQUIRES_KEYS,
|
|
3839
3842
|
Un as REQUIRES_OPEN,
|
|
3840
3843
|
Hl as blockPlacementProblems,
|
|
3841
3844
|
_l as buildDialogPreview,
|