template-designer 0.2.2 → 0.2.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/style.css +1 -1
- package/dist/template-designer.es.js +571 -547
- package/dist/template-designer.umd.js +10 -10
- package/package.json +1 -1
|
@@ -38,45 +38,45 @@ const td = {
|
|
|
38
38
|
overflow: "hidden",
|
|
39
39
|
boxSizing: "border-box"
|
|
40
40
|
})), i = k(/* @__PURE__ */ new Map()), l = (d) => {
|
|
41
|
-
var f, B,
|
|
41
|
+
var f, B, g, h, p, Q;
|
|
42
42
|
if (i.value.has(d))
|
|
43
43
|
return i.value.get(d);
|
|
44
|
-
const
|
|
45
|
-
return i.value.set(d,
|
|
44
|
+
const U = ((Q = (p = (h = (g = (B = (f = A.propsConfig) == null ? void 0 : f.text) == null ? void 0 : B.propertyPanel) == null ? void 0 : g.find((F) => F.prop == "FontName")) == null ? void 0 : h.options) == null ? void 0 : p.find((F) => F.value == d)) == null ? void 0 : Q.cssValue) || d;
|
|
45
|
+
return i.value.set(d, U), U;
|
|
46
46
|
}, s = {
|
|
47
47
|
1: "left",
|
|
48
48
|
2: "center",
|
|
49
49
|
3: "right"
|
|
50
50
|
}, c = H(() => {
|
|
51
|
-
const d = A.modelValue.TextWrap ?? r.value.TextWrap ?? 1,
|
|
52
|
-
fontSize:
|
|
51
|
+
const d = A.modelValue.TextWrap ?? r.value.TextWrap ?? 1, U = A.modelValue.FontSize ?? r.value.FontSize, f = A.modelValue.FontName || r.value.FontName, B = A.modelValue.Bold || r.value.Bold, g = A.modelValue.Italic || r.value.Italic, h = A.modelValue.FontColor || r.value.FontColor, p = A.modelValue.Alignment || r.value.Alignment || 2, Q = {
|
|
52
|
+
fontSize: U + "px",
|
|
53
53
|
fontFamily: l(f),
|
|
54
54
|
fontWeight: B ? "bold" : "normal",
|
|
55
|
-
fontStyle:
|
|
56
|
-
color:
|
|
55
|
+
fontStyle: g ? "italic" : "normal",
|
|
56
|
+
color: h,
|
|
57
57
|
width: "100%",
|
|
58
58
|
minWidth: 0,
|
|
59
59
|
boxSizing: "border-box",
|
|
60
|
-
textAlign: s[
|
|
60
|
+
textAlign: s[p]
|
|
61
61
|
};
|
|
62
62
|
switch (d) {
|
|
63
63
|
case 1:
|
|
64
|
-
|
|
64
|
+
Q.whiteSpace = "pre-wrap", Q.overflow = "visible", Q.textOverflow = "unset";
|
|
65
65
|
break;
|
|
66
66
|
case 2:
|
|
67
|
-
|
|
67
|
+
Q.whiteSpace = "nowrap", Q.overflow = "hidden", Q.textOverflow = "ellipsis";
|
|
68
68
|
break;
|
|
69
69
|
case 3:
|
|
70
|
-
|
|
70
|
+
Q.whiteSpace = "nowrap", Q.overflow = "hidden", Q.textOverflow = "clip";
|
|
71
71
|
break;
|
|
72
72
|
}
|
|
73
|
-
return
|
|
73
|
+
return Q;
|
|
74
74
|
}), u = () => {
|
|
75
|
-
var
|
|
76
|
-
const d = at((f = (
|
|
75
|
+
var U, f;
|
|
76
|
+
const d = at((f = (U = A.propsConfig) == null ? void 0 : U.text) == null ? void 0 : f.propertyPanel) || {};
|
|
77
77
|
r.value = d, i.value.clear();
|
|
78
78
|
};
|
|
79
|
-
return CA(() => A.propsConfig, () => u(), { deep: !0, immediate: !0 }), (d,
|
|
79
|
+
return CA(() => A.propsConfig, () => u(), { deep: !0, immediate: !0 }), (d, U) => (V(), N("div", {
|
|
80
80
|
class: "td-text-component",
|
|
81
81
|
style: $(o.value)
|
|
82
82
|
}, [
|
|
@@ -104,26 +104,26 @@ const td = {
|
|
|
104
104
|
b: (B = "") => Ke(t.value, e, B, "", ""),
|
|
105
105
|
e: (B) => B ? Ke(t.value, e, "", B, "") : "",
|
|
106
106
|
m: (B) => B ? Ke(t.value, e, "", "", B) : "",
|
|
107
|
-
be: (B,
|
|
108
|
-
em: (B,
|
|
109
|
-
bm: (B,
|
|
110
|
-
bem: (B,
|
|
111
|
-
is: (B, ...
|
|
112
|
-
const
|
|
113
|
-
return B &&
|
|
107
|
+
be: (B, g) => B && g ? Ke(t.value, e, B, g, "") : "",
|
|
108
|
+
em: (B, g) => B && g ? Ke(t.value, e, "", B, g) : "",
|
|
109
|
+
bm: (B, g) => B && g ? Ke(t.value, e, B, "", g) : "",
|
|
110
|
+
bem: (B, g, h) => B && g && h ? Ke(t.value, e, B, g, h) : "",
|
|
111
|
+
is: (B, ...g) => {
|
|
112
|
+
const h = g.length >= 1 ? g[0] : !0;
|
|
113
|
+
return B && h ? `${rd}${B}` : "";
|
|
114
114
|
},
|
|
115
115
|
cssVar: (B) => {
|
|
116
|
-
const
|
|
117
|
-
for (const
|
|
118
|
-
B[
|
|
119
|
-
return
|
|
116
|
+
const g = {};
|
|
117
|
+
for (const h in B)
|
|
118
|
+
B[h] && (g[`--${t.value}-${h}`] = B[h]);
|
|
119
|
+
return g;
|
|
120
120
|
},
|
|
121
121
|
cssVarName: (B) => `--${t.value}-${B}`,
|
|
122
122
|
cssVarBlock: (B) => {
|
|
123
|
-
const
|
|
124
|
-
for (const
|
|
125
|
-
B[
|
|
126
|
-
return
|
|
123
|
+
const g = {};
|
|
124
|
+
for (const h in B)
|
|
125
|
+
B[h] && (g[`--${t.value}-${e}-${h}`] = B[h]);
|
|
126
|
+
return g;
|
|
127
127
|
},
|
|
128
128
|
cssVarBlockName: (B) => `--${t.value}-${e}-${B}`
|
|
129
129
|
};
|
|
@@ -479,8 +479,8 @@ function JB(...e) {
|
|
|
479
479
|
Array.isArray(t) || (t = [t]), Array.isArray(r) || (r = [r]);
|
|
480
480
|
const a = [], o = () => {
|
|
481
481
|
a.forEach((c) => c()), a.length = 0;
|
|
482
|
-
}, i = (c, u, d,
|
|
483
|
-
o(), c && a.push(...t.flatMap((d) => r.map((
|
|
482
|
+
}, i = (c, u, d, U) => (c.addEventListener(u, d, U), () => c.removeEventListener(u, d, U)), l = CA(() => [Rs(A), To(n)], ([c, u]) => {
|
|
483
|
+
o(), c && a.push(...t.flatMap((d) => r.map((U) => i(c, d, U, u))));
|
|
484
484
|
}, { immediate: !0, flush: "post" }), s = () => {
|
|
485
485
|
l(), o();
|
|
486
486
|
};
|
|
@@ -771,7 +771,7 @@ const e0 = (e) => (A, t) => t0(A, t, I(e)), t0 = (e, A, t) => SB(t, e, e).replac
|
|
|
771
771
|
validator: t || o ? (s) => {
|
|
772
772
|
let c = !1, u = [];
|
|
773
773
|
if (t && (u = Array.from(t), Ti(e, "default") && u.push(n), c || (c = u.includes(s))), o && (c || (c = o(s))), !c && u.length > 0) {
|
|
774
|
-
const d = [...new Set(u)].map((
|
|
774
|
+
const d = [...new Set(u)].map((U) => JSON.stringify(U)).join(", ");
|
|
775
775
|
Gu(`Invalid prop: validation failed${A ? ` for prop "${A}"` : ""}. Expected one of [${d}], got value ${JSON.stringify(s)}.`);
|
|
776
776
|
}
|
|
777
777
|
return c;
|
|
@@ -1241,21 +1241,21 @@ const Ws = [
|
|
|
1241
1241
|
emits: x0,
|
|
1242
1242
|
setup(e, { expose: A, emit: t }) {
|
|
1243
1243
|
const r = e, { Close: n } = v0, a = k(!1), { ns: o, zIndex: i } = u0("message"), { currentZIndex: l, nextZIndex: s } = i, c = k(), u = k(!1), d = k(0);
|
|
1244
|
-
let
|
|
1244
|
+
let U;
|
|
1245
1245
|
const f = H(() => r.type ? r.type === "error" ? "danger" : r.type : "info"), B = H(() => {
|
|
1246
1246
|
const y = r.type;
|
|
1247
1247
|
return { [o.bm("icon", y)]: y && Yi[y] };
|
|
1248
|
-
}),
|
|
1249
|
-
top: `${
|
|
1248
|
+
}), g = H(() => r.icon || Yi[r.type] || ""), h = H(() => k0(r.id)), p = H(() => O0(r.id, r.offset) + h.value), Q = H(() => d.value + p.value), F = H(() => ({
|
|
1249
|
+
top: `${p.value}px`,
|
|
1250
1250
|
zIndex: l.value
|
|
1251
1251
|
}));
|
|
1252
1252
|
function v() {
|
|
1253
|
-
r.duration !== 0 && ({ stop:
|
|
1253
|
+
r.duration !== 0 && ({ stop: U } = DB(() => {
|
|
1254
1254
|
T();
|
|
1255
1255
|
}, r.duration));
|
|
1256
1256
|
}
|
|
1257
1257
|
function C() {
|
|
1258
|
-
|
|
1258
|
+
U == null || U();
|
|
1259
1259
|
}
|
|
1260
1260
|
function T() {
|
|
1261
1261
|
u.value = !1, ue(() => {
|
|
@@ -1274,7 +1274,7 @@ const Ws = [
|
|
|
1274
1274
|
d.value = c.value.getBoundingClientRect().height;
|
|
1275
1275
|
}), A({
|
|
1276
1276
|
visible: u,
|
|
1277
|
-
bottom:
|
|
1277
|
+
bottom: Q,
|
|
1278
1278
|
close: T
|
|
1279
1279
|
}), (y, S) => (V(), yA(gs, {
|
|
1280
1280
|
name: I(o).b("fade"),
|
|
@@ -1306,12 +1306,12 @@ const Ws = [
|
|
|
1306
1306
|
type: I(f),
|
|
1307
1307
|
class: _A(I(o).e("badge"))
|
|
1308
1308
|
}, null, 8, ["value", "type", "class"])) : tA("v-if", !0),
|
|
1309
|
-
I(
|
|
1309
|
+
I(g) ? (V(), yA(I(Gi), {
|
|
1310
1310
|
key: 1,
|
|
1311
1311
|
class: _A([I(o).e("icon"), I(B)])
|
|
1312
1312
|
}, {
|
|
1313
1313
|
default: j(() => [
|
|
1314
|
-
(V(), yA(cr(I(
|
|
1314
|
+
(V(), yA(cr(I(g))))
|
|
1315
1315
|
]),
|
|
1316
1316
|
_: 1
|
|
1317
1317
|
}, 8, ["class"])) : tA("v-if", !0),
|
|
@@ -1467,31 +1467,31 @@ const RA = (e, A) => {
|
|
|
1467
1467
|
}), u = () => {
|
|
1468
1468
|
n.value && !a.value && n.value.click();
|
|
1469
1469
|
}, d = (B) => {
|
|
1470
|
-
const
|
|
1471
|
-
|
|
1472
|
-
},
|
|
1473
|
-
var
|
|
1474
|
-
const
|
|
1475
|
-
if (!
|
|
1470
|
+
const g = B.target.value.trim();
|
|
1471
|
+
g ? g.startsWith("http://") || g.startsWith("https://") || g.startsWith("data:") ? s.value = g : g.startsWith("data:") || (s.value = g) : s.value = "";
|
|
1472
|
+
}, U = async (B) => {
|
|
1473
|
+
var Q;
|
|
1474
|
+
const g = B.target.files[0];
|
|
1475
|
+
if (!g)
|
|
1476
1476
|
return;
|
|
1477
|
-
if (t.accept && !
|
|
1477
|
+
if (t.accept && !g.type.match(t.accept.replace("*", ".*"))) {
|
|
1478
1478
|
alert("请选择正确的文件类型");
|
|
1479
1479
|
return;
|
|
1480
1480
|
}
|
|
1481
|
-
const
|
|
1482
|
-
if (!
|
|
1483
|
-
f(
|
|
1481
|
+
const h = (Q = l == null ? void 0 : l.image) == null ? void 0 : Q.request;
|
|
1482
|
+
if (!h || typeof h != "function") {
|
|
1483
|
+
f(g);
|
|
1484
1484
|
return;
|
|
1485
1485
|
}
|
|
1486
|
-
i.value =
|
|
1487
|
-
let
|
|
1486
|
+
i.value = g;
|
|
1487
|
+
let p = null;
|
|
1488
1488
|
try {
|
|
1489
|
-
a.value = !0,
|
|
1490
|
-
const F = await
|
|
1491
|
-
if (o.value ===
|
|
1489
|
+
a.value = !0, p = h(g), o.value = p;
|
|
1490
|
+
const F = await p;
|
|
1491
|
+
if (o.value === p && i.value === g)
|
|
1492
1492
|
if (F && F.success !== !1) {
|
|
1493
1493
|
const v = F.url || F.data || F, C = {
|
|
1494
|
-
fileName:
|
|
1494
|
+
fileName: g.name,
|
|
1495
1495
|
fileSrc: v,
|
|
1496
1496
|
uploadResult: F
|
|
1497
1497
|
};
|
|
@@ -1501,54 +1501,54 @@ const RA = (e, A) => {
|
|
|
1501
1501
|
else
|
|
1502
1502
|
console.log("组件已切换或文件已改变,忽略上传结果");
|
|
1503
1503
|
} catch (F) {
|
|
1504
|
-
o.value ===
|
|
1504
|
+
o.value === p && i.value === g && (n.value && (n.value.value = ""), dr.error(F.message || "上传失败,请重试"));
|
|
1505
1505
|
} finally {
|
|
1506
|
-
o.value ===
|
|
1506
|
+
o.value === p && (a.value = !1, o.value = null, i.value = null);
|
|
1507
1507
|
}
|
|
1508
1508
|
}, f = (B) => {
|
|
1509
|
-
const
|
|
1510
|
-
|
|
1511
|
-
const
|
|
1509
|
+
const g = new FileReader();
|
|
1510
|
+
g.onload = (h) => {
|
|
1511
|
+
const p = {
|
|
1512
1512
|
fileName: B.name,
|
|
1513
|
-
fileSrc:
|
|
1513
|
+
fileSrc: h.target.result
|
|
1514
1514
|
};
|
|
1515
|
-
s.value =
|
|
1516
|
-
},
|
|
1515
|
+
s.value = p, r("change", { target: { files: [B] } });
|
|
1516
|
+
}, g.onerror = () => {
|
|
1517
1517
|
alert("文件读取失败,请重试");
|
|
1518
|
-
},
|
|
1518
|
+
}, g.readAsDataURL(B);
|
|
1519
1519
|
};
|
|
1520
1520
|
return ju(() => {
|
|
1521
1521
|
o.value = null, i.value = null;
|
|
1522
|
-
}), (B,
|
|
1523
|
-
const
|
|
1522
|
+
}), (B, g) => {
|
|
1523
|
+
const h = wA("el-icon-loading"), p = wA("el-icon");
|
|
1524
1524
|
return V(), N("div", z0, [
|
|
1525
1525
|
e.label ? (V(), N("label", j0, Be(e.label), 1)) : tA("", !0),
|
|
1526
1526
|
e.type === "select" ? YA((V(), N("select", {
|
|
1527
1527
|
key: 1,
|
|
1528
|
-
"onUpdate:modelValue":
|
|
1528
|
+
"onUpdate:modelValue": g[0] || (g[0] = (Q) => s.value = Q)
|
|
1529
1529
|
}, [
|
|
1530
|
-
(V(!0), N(TA, null, Se(e.options, (
|
|
1531
|
-
key:
|
|
1532
|
-
value:
|
|
1533
|
-
}, Be(
|
|
1530
|
+
(V(!0), N(TA, null, Se(e.options, (Q) => (V(), N("option", {
|
|
1531
|
+
key: Q.value,
|
|
1532
|
+
value: Q.value
|
|
1533
|
+
}, Be(Q.label), 9, X0))), 128))
|
|
1534
1534
|
], 512)), [
|
|
1535
1535
|
[Xu, s.value]
|
|
1536
1536
|
]) : e.type === "color" ? YA((V(), N("input", {
|
|
1537
1537
|
key: 2,
|
|
1538
|
-
"onUpdate:modelValue":
|
|
1538
|
+
"onUpdate:modelValue": g[1] || (g[1] = (Q) => s.value = Q),
|
|
1539
1539
|
type: "color"
|
|
1540
1540
|
}, null, 512)), [
|
|
1541
1541
|
[Ge, s.value]
|
|
1542
1542
|
]) : e.type === "checkbox" ? YA((V(), N("input", {
|
|
1543
1543
|
key: 3,
|
|
1544
|
-
"onUpdate:modelValue":
|
|
1544
|
+
"onUpdate:modelValue": g[2] || (g[2] = (Q) => s.value = Q),
|
|
1545
1545
|
type: "checkbox"
|
|
1546
1546
|
}, null, 512)), [
|
|
1547
1547
|
[Pu, s.value]
|
|
1548
1548
|
]) : e.type === "file" ? (V(), N("div", P0, [
|
|
1549
1549
|
YA(m("input", {
|
|
1550
1550
|
type: "text",
|
|
1551
|
-
"onUpdate:modelValue":
|
|
1551
|
+
"onUpdate:modelValue": g[3] || (g[3] = (Q) => c.value = Q),
|
|
1552
1552
|
placeholder: "请选择图片",
|
|
1553
1553
|
class: "file-url-input",
|
|
1554
1554
|
onInput: d,
|
|
@@ -1562,12 +1562,12 @@ const RA = (e, A) => {
|
|
|
1562
1562
|
class: "file-select-btn",
|
|
1563
1563
|
disabled: a.value
|
|
1564
1564
|
}, [
|
|
1565
|
-
a.value ? (V(), yA(
|
|
1565
|
+
a.value ? (V(), yA(p, {
|
|
1566
1566
|
key: 0,
|
|
1567
1567
|
class: "is-loading"
|
|
1568
1568
|
}, {
|
|
1569
1569
|
default: j(() => [
|
|
1570
|
-
W(
|
|
1570
|
+
W(h)
|
|
1571
1571
|
]),
|
|
1572
1572
|
_: 1
|
|
1573
1573
|
})) : (V(), N("span", q0, Be(a.value ? "上传中..." : "选择"), 1))
|
|
@@ -1575,14 +1575,14 @@ const RA = (e, A) => {
|
|
|
1575
1575
|
m("input", {
|
|
1576
1576
|
type: "file",
|
|
1577
1577
|
accept: e.accept,
|
|
1578
|
-
onChange:
|
|
1578
|
+
onChange: U,
|
|
1579
1579
|
ref_key: "fileInput",
|
|
1580
1580
|
ref: n,
|
|
1581
1581
|
class: "file-input"
|
|
1582
1582
|
}, null, 40, $0)
|
|
1583
1583
|
])) : YA((V(), N("input", {
|
|
1584
1584
|
key: 5,
|
|
1585
|
-
"onUpdate:modelValue":
|
|
1585
|
+
"onUpdate:modelValue": g[4] || (g[4] = (Q) => s.value = Q),
|
|
1586
1586
|
type: e.type,
|
|
1587
1587
|
min: e.min,
|
|
1588
1588
|
max: e.max,
|
|
@@ -1628,10 +1628,10 @@ const tf = { class: "property-layout-container" }, rf = {
|
|
|
1628
1628
|
setup(e, { emit: A }) {
|
|
1629
1629
|
const t = e, r = A, { propsConfig: n, panelType: a } = qu(t), o = H(() => `${a.value}-property-panel`), i = H(() => {
|
|
1630
1630
|
const d = n.value.propertyPanel;
|
|
1631
|
-
return d && typeof d == "object" && !Array.isArray(d) ? Object.keys(d).map((
|
|
1632
|
-
prop:
|
|
1633
|
-
...d[
|
|
1634
|
-
})).filter((
|
|
1631
|
+
return d && typeof d == "object" && !Array.isArray(d) ? Object.keys(d).map((U) => ({
|
|
1632
|
+
prop: U,
|
|
1633
|
+
...d[U]
|
|
1634
|
+
})).filter((U) => !U.hide) : Array.isArray(d) ? d.filter((U) => !U.hide) || [] : [];
|
|
1635
1635
|
}), l = H({
|
|
1636
1636
|
get: () => t.modelValue,
|
|
1637
1637
|
set: (d) => r("update:modelValue", d)
|
|
@@ -1641,10 +1641,10 @@ const tf = { class: "property-layout-container" }, rf = {
|
|
|
1641
1641
|
var f;
|
|
1642
1642
|
if (d.options)
|
|
1643
1643
|
return d.options || [];
|
|
1644
|
-
const
|
|
1645
|
-
return
|
|
1644
|
+
const U = JSON.parse(JSON.stringify(((f = t.options) == null ? void 0 : f[d == null ? void 0 : d.optionsKey]) || [])) || [];
|
|
1645
|
+
return U.unshift({ label: "无", value: "" }), U;
|
|
1646
1646
|
}, u = (d) => d.layout ? d.layout : ["text", "file", "textarea"].includes(d.type) ? "full" : "half";
|
|
1647
|
-
return hs("config", t.propsConfig), (d,
|
|
1647
|
+
return hs("config", t.propsConfig), (d, U) => (V(), N("div", {
|
|
1648
1648
|
class: _A(o.value)
|
|
1649
1649
|
}, [
|
|
1650
1650
|
m("div", tf, [
|
|
@@ -4414,10 +4414,10 @@ const fQ = {
|
|
|
4414
4414
|
lineColor: "",
|
|
4415
4415
|
codeType: ""
|
|
4416
4416
|
}), l = () => {
|
|
4417
|
-
var
|
|
4417
|
+
var h, p, Q, F, v, C, T, M, y, S;
|
|
4418
4418
|
if (!t.value)
|
|
4419
4419
|
return;
|
|
4420
|
-
const c = at((
|
|
4420
|
+
const c = at((p = (h = A.propsConfig) == null ? void 0 : h.barcode) == null ? void 0 : p.propertyPanel) || {}, u = ((Q = A.modelValue) == null ? void 0 : Q.BarcodeValue) || c.BarcodeValue || "", d = ((F = A.modelValue) == null ? void 0 : F.CodeType) || c.CodeType || "", U = A.modelValue.LineColor || c.LineColor, f = ((S = (y = (M = (T = (C = (v = A.propsConfig) == null ? void 0 : v.barcode) == null ? void 0 : C.propertyPanel) == null ? void 0 : T.find((D) => D.prop === "CodeType")) == null ? void 0 : M.options) == null ? void 0 : y.find((D) => D.value === d)) == null ? void 0 : S.compValue) || "", B = { value: u, type: d, lineColor: U, codeType: f };
|
|
4421
4421
|
if (JSON.stringify(B) !== JSON.stringify(i.value)) {
|
|
4422
4422
|
i.value = B;
|
|
4423
4423
|
try {
|
|
@@ -4431,7 +4431,7 @@ const fQ = {
|
|
|
4431
4431
|
// 条形码的边距
|
|
4432
4432
|
margin: 0,
|
|
4433
4433
|
// 条形码的颜色
|
|
4434
|
-
lineColor:
|
|
4434
|
+
lineColor: U,
|
|
4435
4435
|
// 条形码的高度
|
|
4436
4436
|
height: 50,
|
|
4437
4437
|
// 确保条形码能够正确渲染
|
|
@@ -4726,8 +4726,8 @@ var pc = {};
|
|
|
4726
4726
|
for (let u = 0; u < a; u++) {
|
|
4727
4727
|
i = l = 0, s = c = null;
|
|
4728
4728
|
for (let d = 0; d < a; d++) {
|
|
4729
|
-
let
|
|
4730
|
-
|
|
4729
|
+
let U = n.get(u, d);
|
|
4730
|
+
U === s ? i++ : (i >= 5 && (o += A.N1 + (i - 5)), s = U, i = 1), U = n.get(d, u), U === c ? l++ : (l >= 5 && (o += A.N1 + (l - 5)), c = U, l = 1);
|
|
4731
4731
|
}
|
|
4732
4732
|
i >= 5 && (o += A.N1 + (i - 5)), l >= 5 && (o += A.N1 + (l - 5));
|
|
4733
4733
|
}
|
|
@@ -5303,66 +5303,66 @@ fe.testAlphanumeric = function(A) {
|
|
|
5303
5303
|
})(Oe);
|
|
5304
5304
|
(function(e) {
|
|
5305
5305
|
const A = jA, t = Yn, r = Gn, n = Oe, a = di, o = 7973, i = A.getBCHDigit(o);
|
|
5306
|
-
function l(d,
|
|
5306
|
+
function l(d, U, f) {
|
|
5307
5307
|
for (let B = 1; B <= 40; B++)
|
|
5308
|
-
if (
|
|
5308
|
+
if (U <= e.getCapacity(B, f, d))
|
|
5309
5309
|
return B;
|
|
5310
5310
|
}
|
|
5311
|
-
function s(d,
|
|
5312
|
-
return n.getCharCountIndicator(d,
|
|
5311
|
+
function s(d, U) {
|
|
5312
|
+
return n.getCharCountIndicator(d, U) + 4;
|
|
5313
5313
|
}
|
|
5314
|
-
function c(d,
|
|
5314
|
+
function c(d, U) {
|
|
5315
5315
|
let f = 0;
|
|
5316
5316
|
return d.forEach(function(B) {
|
|
5317
|
-
const
|
|
5318
|
-
f +=
|
|
5317
|
+
const g = s(B.mode, U);
|
|
5318
|
+
f += g + B.getBitsLength();
|
|
5319
5319
|
}), f;
|
|
5320
5320
|
}
|
|
5321
|
-
function u(d,
|
|
5321
|
+
function u(d, U) {
|
|
5322
5322
|
for (let f = 1; f <= 40; f++)
|
|
5323
|
-
if (c(d, f) <= e.getCapacity(f,
|
|
5323
|
+
if (c(d, f) <= e.getCapacity(f, U, n.MIXED))
|
|
5324
5324
|
return f;
|
|
5325
5325
|
}
|
|
5326
|
-
e.from = function(
|
|
5327
|
-
return a.isValid(
|
|
5328
|
-
}, e.getCapacity = function(
|
|
5329
|
-
if (!a.isValid(
|
|
5326
|
+
e.from = function(U, f) {
|
|
5327
|
+
return a.isValid(U) ? parseInt(U, 10) : f;
|
|
5328
|
+
}, e.getCapacity = function(U, f, B) {
|
|
5329
|
+
if (!a.isValid(U))
|
|
5330
5330
|
throw new Error("Invalid QR Code version");
|
|
5331
5331
|
typeof B > "u" && (B = n.BYTE);
|
|
5332
|
-
const
|
|
5332
|
+
const g = A.getSymbolTotalCodewords(U), h = t.getTotalCodewordsCount(U, f), p = (g - h) * 8;
|
|
5333
5333
|
if (B === n.MIXED)
|
|
5334
|
-
return
|
|
5335
|
-
const
|
|
5334
|
+
return p;
|
|
5335
|
+
const Q = p - s(B, U);
|
|
5336
5336
|
switch (B) {
|
|
5337
5337
|
case n.NUMERIC:
|
|
5338
|
-
return Math.floor(
|
|
5338
|
+
return Math.floor(Q / 10 * 3);
|
|
5339
5339
|
case n.ALPHANUMERIC:
|
|
5340
|
-
return Math.floor(
|
|
5340
|
+
return Math.floor(Q / 11 * 2);
|
|
5341
5341
|
case n.KANJI:
|
|
5342
|
-
return Math.floor(
|
|
5342
|
+
return Math.floor(Q / 13);
|
|
5343
5343
|
case n.BYTE:
|
|
5344
5344
|
default:
|
|
5345
|
-
return Math.floor(
|
|
5345
|
+
return Math.floor(Q / 8);
|
|
5346
5346
|
}
|
|
5347
|
-
}, e.getBestVersionForData = function(
|
|
5347
|
+
}, e.getBestVersionForData = function(U, f) {
|
|
5348
5348
|
let B;
|
|
5349
|
-
const
|
|
5350
|
-
if (Array.isArray(
|
|
5351
|
-
if (
|
|
5352
|
-
return u(
|
|
5353
|
-
if (
|
|
5349
|
+
const g = r.from(f, r.M);
|
|
5350
|
+
if (Array.isArray(U)) {
|
|
5351
|
+
if (U.length > 1)
|
|
5352
|
+
return u(U, g);
|
|
5353
|
+
if (U.length === 0)
|
|
5354
5354
|
return 1;
|
|
5355
|
-
B =
|
|
5355
|
+
B = U[0];
|
|
5356
5356
|
} else
|
|
5357
|
-
B =
|
|
5358
|
-
return l(B.mode, B.getLength(),
|
|
5359
|
-
}, e.getEncodedBits = function(
|
|
5360
|
-
if (!a.isValid(
|
|
5357
|
+
B = U;
|
|
5358
|
+
return l(B.mode, B.getLength(), g);
|
|
5359
|
+
}, e.getEncodedBits = function(U) {
|
|
5360
|
+
if (!a.isValid(U) || U < 7)
|
|
5361
5361
|
throw new Error("Invalid QR Code version");
|
|
5362
|
-
let f =
|
|
5362
|
+
let f = U << 12;
|
|
5363
5363
|
for (; A.getBCHDigit(f) - i >= 0; )
|
|
5364
5364
|
f ^= o << A.getBCHDigit(f) - i;
|
|
5365
|
-
return
|
|
5365
|
+
return U << 12 | f;
|
|
5366
5366
|
};
|
|
5367
5367
|
})(Fc);
|
|
5368
5368
|
var Ec = {};
|
|
@@ -5519,14 +5519,14 @@ var WQ = It, yc = { exports: {} };
|
|
|
5519
5519
|
o[r] = 0;
|
|
5520
5520
|
var i = A.PriorityQueue.make();
|
|
5521
5521
|
i.push(r, 0);
|
|
5522
|
-
for (var l, s, c, u, d,
|
|
5522
|
+
for (var l, s, c, u, d, U, f, B, g; !i.empty(); ) {
|
|
5523
5523
|
l = i.pop(), s = l.value, u = l.cost, d = t[s] || {};
|
|
5524
5524
|
for (c in d)
|
|
5525
|
-
d.hasOwnProperty(c) && (
|
|
5525
|
+
d.hasOwnProperty(c) && (U = d[c], f = u + U, B = o[c], g = typeof o[c] > "u", (g || B > f) && (o[c] = f, i.push(c, f), a[c] = s));
|
|
5526
5526
|
}
|
|
5527
5527
|
if (typeof n < "u" && typeof o[n] > "u") {
|
|
5528
|
-
var
|
|
5529
|
-
throw new Error(
|
|
5528
|
+
var h = ["Could not find a path from ", r, " to ", n, "."].join("");
|
|
5529
|
+
throw new Error(h);
|
|
5530
5530
|
}
|
|
5531
5531
|
return a;
|
|
5532
5532
|
},
|
|
@@ -5580,25 +5580,25 @@ var WQ = It, yc = { exports: {} };
|
|
|
5580
5580
|
var DQ = yc.exports;
|
|
5581
5581
|
(function(e) {
|
|
5582
5582
|
const A = Oe, t = MQ, r = HQ, n = ZQ, a = WQ, o = fe, i = jA, l = DQ;
|
|
5583
|
-
function s(
|
|
5584
|
-
return unescape(encodeURIComponent(
|
|
5583
|
+
function s(h) {
|
|
5584
|
+
return unescape(encodeURIComponent(h)).length;
|
|
5585
5585
|
}
|
|
5586
|
-
function c(
|
|
5586
|
+
function c(h, p, Q) {
|
|
5587
5587
|
const F = [];
|
|
5588
5588
|
let v;
|
|
5589
|
-
for (; (v =
|
|
5589
|
+
for (; (v = h.exec(Q)) !== null; )
|
|
5590
5590
|
F.push({
|
|
5591
5591
|
data: v[0],
|
|
5592
5592
|
index: v.index,
|
|
5593
|
-
mode:
|
|
5593
|
+
mode: p,
|
|
5594
5594
|
length: v[0].length
|
|
5595
5595
|
});
|
|
5596
5596
|
return F;
|
|
5597
5597
|
}
|
|
5598
|
-
function u(
|
|
5599
|
-
const
|
|
5598
|
+
function u(h) {
|
|
5599
|
+
const p = c(o.NUMERIC, A.NUMERIC, h), Q = c(o.ALPHANUMERIC, A.ALPHANUMERIC, h);
|
|
5600
5600
|
let F, v;
|
|
5601
|
-
return i.isKanjiModeEnabled() ? (F = c(o.BYTE, A.BYTE,
|
|
5601
|
+
return i.isKanjiModeEnabled() ? (F = c(o.BYTE, A.BYTE, h), v = c(o.KANJI, A.KANJI, h)) : (F = c(o.BYTE_KANJI, A.BYTE, h), v = []), p.concat(Q, F, v).sort(function(T, M) {
|
|
5602
5602
|
return T.index - M.index;
|
|
5603
5603
|
}).map(function(T) {
|
|
5604
5604
|
return {
|
|
@@ -5608,104 +5608,104 @@ var DQ = yc.exports;
|
|
|
5608
5608
|
};
|
|
5609
5609
|
});
|
|
5610
5610
|
}
|
|
5611
|
-
function d(
|
|
5612
|
-
switch (
|
|
5611
|
+
function d(h, p) {
|
|
5612
|
+
switch (p) {
|
|
5613
5613
|
case A.NUMERIC:
|
|
5614
|
-
return t.getBitsLength(
|
|
5614
|
+
return t.getBitsLength(h);
|
|
5615
5615
|
case A.ALPHANUMERIC:
|
|
5616
|
-
return r.getBitsLength(
|
|
5616
|
+
return r.getBitsLength(h);
|
|
5617
5617
|
case A.KANJI:
|
|
5618
|
-
return a.getBitsLength(
|
|
5618
|
+
return a.getBitsLength(h);
|
|
5619
5619
|
case A.BYTE:
|
|
5620
|
-
return n.getBitsLength(
|
|
5620
|
+
return n.getBitsLength(h);
|
|
5621
5621
|
}
|
|
5622
5622
|
}
|
|
5623
|
-
function h
|
|
5624
|
-
return
|
|
5625
|
-
const F =
|
|
5626
|
-
return F && F.mode ===
|
|
5623
|
+
function U(h) {
|
|
5624
|
+
return h.reduce(function(p, Q) {
|
|
5625
|
+
const F = p.length - 1 >= 0 ? p[p.length - 1] : null;
|
|
5626
|
+
return F && F.mode === Q.mode ? (p[p.length - 1].data += Q.data, p) : (p.push(Q), p);
|
|
5627
5627
|
}, []);
|
|
5628
5628
|
}
|
|
5629
|
-
function f(
|
|
5630
|
-
const
|
|
5631
|
-
for (let
|
|
5632
|
-
const F =
|
|
5629
|
+
function f(h) {
|
|
5630
|
+
const p = [];
|
|
5631
|
+
for (let Q = 0; Q < h.length; Q++) {
|
|
5632
|
+
const F = h[Q];
|
|
5633
5633
|
switch (F.mode) {
|
|
5634
5634
|
case A.NUMERIC:
|
|
5635
|
-
|
|
5635
|
+
p.push([
|
|
5636
5636
|
F,
|
|
5637
5637
|
{ data: F.data, mode: A.ALPHANUMERIC, length: F.length },
|
|
5638
5638
|
{ data: F.data, mode: A.BYTE, length: F.length }
|
|
5639
5639
|
]);
|
|
5640
5640
|
break;
|
|
5641
5641
|
case A.ALPHANUMERIC:
|
|
5642
|
-
|
|
5642
|
+
p.push([
|
|
5643
5643
|
F,
|
|
5644
5644
|
{ data: F.data, mode: A.BYTE, length: F.length }
|
|
5645
5645
|
]);
|
|
5646
5646
|
break;
|
|
5647
5647
|
case A.KANJI:
|
|
5648
|
-
|
|
5648
|
+
p.push([
|
|
5649
5649
|
F,
|
|
5650
5650
|
{ data: F.data, mode: A.BYTE, length: s(F.data) }
|
|
5651
5651
|
]);
|
|
5652
5652
|
break;
|
|
5653
5653
|
case A.BYTE:
|
|
5654
|
-
|
|
5654
|
+
p.push([
|
|
5655
5655
|
{ data: F.data, mode: A.BYTE, length: s(F.data) }
|
|
5656
5656
|
]);
|
|
5657
5657
|
}
|
|
5658
5658
|
}
|
|
5659
|
-
return
|
|
5659
|
+
return p;
|
|
5660
5660
|
}
|
|
5661
|
-
function B(
|
|
5662
|
-
const
|
|
5661
|
+
function B(h, p) {
|
|
5662
|
+
const Q = {}, F = { start: {} };
|
|
5663
5663
|
let v = ["start"];
|
|
5664
|
-
for (let C = 0; C <
|
|
5665
|
-
const T =
|
|
5664
|
+
for (let C = 0; C < h.length; C++) {
|
|
5665
|
+
const T = h[C], M = [];
|
|
5666
5666
|
for (let y = 0; y < T.length; y++) {
|
|
5667
5667
|
const S = T[y], D = "" + C + y;
|
|
5668
|
-
M.push(D),
|
|
5668
|
+
M.push(D), Q[D] = { node: S, lastCount: 0 }, F[D] = {};
|
|
5669
5669
|
for (let L = 0; L < v.length; L++) {
|
|
5670
5670
|
const b = v[L];
|
|
5671
|
-
|
|
5671
|
+
Q[b] && Q[b].node.mode === S.mode ? (F[b][D] = d(Q[b].lastCount + S.length, S.mode) - d(Q[b].lastCount, S.mode), Q[b].lastCount += S.length) : (Q[b] && (Q[b].lastCount = S.length), F[b][D] = d(S.length, S.mode) + 4 + A.getCharCountIndicator(S.mode, p));
|
|
5672
5672
|
}
|
|
5673
5673
|
}
|
|
5674
5674
|
v = M;
|
|
5675
5675
|
}
|
|
5676
5676
|
for (let C = 0; C < v.length; C++)
|
|
5677
5677
|
F[v[C]].end = 0;
|
|
5678
|
-
return { map: F, table:
|
|
5678
|
+
return { map: F, table: Q };
|
|
5679
5679
|
}
|
|
5680
|
-
function
|
|
5681
|
-
let
|
|
5682
|
-
const F = A.getBestModeForData(
|
|
5683
|
-
if (
|
|
5684
|
-
throw new Error('"' +
|
|
5680
|
+
function g(h, p) {
|
|
5681
|
+
let Q;
|
|
5682
|
+
const F = A.getBestModeForData(h);
|
|
5683
|
+
if (Q = A.from(p, F), Q !== A.BYTE && Q.bit < F.bit)
|
|
5684
|
+
throw new Error('"' + h + '" cannot be encoded with mode ' + A.toString(Q) + `.
|
|
5685
5685
|
Suggested mode is: ` + A.toString(F));
|
|
5686
|
-
switch (
|
|
5686
|
+
switch (Q === A.KANJI && !i.isKanjiModeEnabled() && (Q = A.BYTE), Q) {
|
|
5687
5687
|
case A.NUMERIC:
|
|
5688
|
-
return new t(
|
|
5688
|
+
return new t(h);
|
|
5689
5689
|
case A.ALPHANUMERIC:
|
|
5690
|
-
return new r(
|
|
5690
|
+
return new r(h);
|
|
5691
5691
|
case A.KANJI:
|
|
5692
|
-
return new a(
|
|
5692
|
+
return new a(h);
|
|
5693
5693
|
case A.BYTE:
|
|
5694
|
-
return new n(
|
|
5694
|
+
return new n(h);
|
|
5695
5695
|
}
|
|
5696
5696
|
}
|
|
5697
|
-
e.fromArray = function(
|
|
5698
|
-
return
|
|
5699
|
-
return typeof F == "string" ?
|
|
5697
|
+
e.fromArray = function(p) {
|
|
5698
|
+
return p.reduce(function(Q, F) {
|
|
5699
|
+
return typeof F == "string" ? Q.push(g(F, null)) : F.data && Q.push(g(F.data, F.mode)), Q;
|
|
5700
5700
|
}, []);
|
|
5701
|
-
}, e.fromString = function(
|
|
5702
|
-
const F = u(
|
|
5701
|
+
}, e.fromString = function(p, Q) {
|
|
5702
|
+
const F = u(p, i.isKanjiModeEnabled()), v = f(F), C = B(v, Q), T = l.find_path(C.map, "start", "end"), M = [];
|
|
5703
5703
|
for (let y = 1; y < T.length - 1; y++)
|
|
5704
5704
|
M.push(C.table[T[y]].node);
|
|
5705
|
-
return e.fromArray(
|
|
5706
|
-
}, e.rawSplit = function(
|
|
5705
|
+
return e.fromArray(U(M));
|
|
5706
|
+
}, e.rawSplit = function(p) {
|
|
5707
5707
|
return e.fromArray(
|
|
5708
|
-
u(
|
|
5708
|
+
u(p, i.isKanjiModeEnabled())
|
|
5709
5709
|
);
|
|
5710
5710
|
};
|
|
5711
5711
|
})(vc);
|
|
@@ -5779,24 +5779,24 @@ function Aw(e, A, t) {
|
|
|
5779
5779
|
return ew(r, e, A);
|
|
5780
5780
|
}
|
|
5781
5781
|
function ew(e, A, t) {
|
|
5782
|
-
const r = jn.getSymbolTotalCodewords(A), n = qa.getTotalCodewordsCount(A, t), a = r - n, o = qa.getBlocksCount(A, t), i = r % o, l = o - i, s = Math.floor(r / o), c = Math.floor(a / o), u = c + 1, d = s - c,
|
|
5782
|
+
const r = jn.getSymbolTotalCodewords(A), n = qa.getTotalCodewordsCount(A, t), a = r - n, o = qa.getBlocksCount(A, t), i = r % o, l = o - i, s = Math.floor(r / o), c = Math.floor(a / o), u = c + 1, d = s - c, U = new YQ(d);
|
|
5783
5783
|
let f = 0;
|
|
5784
|
-
const B = new Array(o),
|
|
5785
|
-
let
|
|
5786
|
-
const
|
|
5784
|
+
const B = new Array(o), g = new Array(o);
|
|
5785
|
+
let h = 0;
|
|
5786
|
+
const p = new Uint8Array(e.buffer);
|
|
5787
5787
|
for (let T = 0; T < o; T++) {
|
|
5788
5788
|
const M = T < l ? c : u;
|
|
5789
|
-
B[T] =
|
|
5789
|
+
B[T] = p.slice(f, f + M), g[T] = U.encode(B[T]), f += M, h = Math.max(h, M);
|
|
5790
5790
|
}
|
|
5791
|
-
const
|
|
5791
|
+
const Q = new Uint8Array(r);
|
|
5792
5792
|
let F = 0, v, C;
|
|
5793
|
-
for (v = 0; v <
|
|
5793
|
+
for (v = 0; v < h; v++)
|
|
5794
5794
|
for (C = 0; C < o; C++)
|
|
5795
|
-
v < B[C].length && (
|
|
5795
|
+
v < B[C].length && (Q[F++] = B[C][v]);
|
|
5796
5796
|
for (v = 0; v < d; v++)
|
|
5797
5797
|
for (C = 0; C < o; C++)
|
|
5798
|
-
|
|
5799
|
-
return
|
|
5798
|
+
Q[F++] = g[C][v];
|
|
5799
|
+
return Q;
|
|
5800
5800
|
}
|
|
5801
5801
|
function tw(e, A, t, r) {
|
|
5802
5802
|
let n;
|
|
@@ -5883,11 +5883,11 @@ var Rc = {}, Bi = {};
|
|
|
5883
5883
|
}, e.qrToImageData = function(r, n, a) {
|
|
5884
5884
|
const o = n.modules.size, i = n.modules.data, l = e.getScale(o, a), s = Math.floor((o + a.margin * 2) * l), c = a.margin * l, u = [a.color.light, a.color.dark];
|
|
5885
5885
|
for (let d = 0; d < s; d++)
|
|
5886
|
-
for (let
|
|
5887
|
-
let f = (d * s +
|
|
5888
|
-
if (d >= c &&
|
|
5889
|
-
const
|
|
5890
|
-
B = u[i[
|
|
5886
|
+
for (let U = 0; U < s; U++) {
|
|
5887
|
+
let f = (d * s + U) * 4, B = a.color.light;
|
|
5888
|
+
if (d >= c && U >= c && d < s - c && U < s - c) {
|
|
5889
|
+
const g = Math.floor((d - c) / l), h = Math.floor((U - c) / l);
|
|
5890
|
+
B = u[i[g * o + h] ? 1 : 0];
|
|
5891
5891
|
}
|
|
5892
5892
|
r[f++] = B.r, r[f++] = B.g, r[f++] = B.b, r[f] = B.a;
|
|
5893
5893
|
}
|
|
@@ -5992,15 +5992,15 @@ const iw = { class: "qrcode-canvas-fixed" }, lw = ["src", "alt"], sw = 200, cw =
|
|
|
5992
5992
|
boxSizing: "border-box",
|
|
5993
5993
|
zIndex: 1e3
|
|
5994
5994
|
})), o = k(null), i = () => {
|
|
5995
|
-
var B,
|
|
5996
|
-
return o.value || (o.value = at((
|
|
5997
|
-
}, l = (B,
|
|
5998
|
-
var B,
|
|
5995
|
+
var B, g;
|
|
5996
|
+
return o.value || (o.value = at((g = (B = A.propsConfig) == null ? void 0 : B.qrcode) == null ? void 0 : g.propertyPanel) || {}), o.value;
|
|
5997
|
+
}, l = (B, g) => g ? B.QRCodeValue !== g.QRCodeValue || B.QRCodeForeground !== g.QRCodeForeground || B.QRCodeBackground !== g.QRCodeBackground || B.QRCodeErrorLevel !== g.QRCodeErrorLevel : !0, s = async () => {
|
|
5998
|
+
var B, g, h, p;
|
|
5999
5999
|
try {
|
|
6000
|
-
const
|
|
6001
|
-
let v = ((
|
|
6000
|
+
const Q = i(), F = ((B = A.modelValue) == null ? void 0 : B.QRCodeValue) || Q.QRCodeValue || "测试二维码";
|
|
6001
|
+
let v = ((g = A.modelValue) == null ? void 0 : g.QRCodeForeground) || Q.QRCodeForeground || "#000000", C = ((h = A.modelValue) == null ? void 0 : h.QRCodeBackground) || Q.QRCodeBackground || "#ffffff";
|
|
6002
6002
|
(v === "transparent" || !v) && (v = "#000000"), (C === "transparent" || !C) && (C = "#ffffff");
|
|
6003
|
-
const M = { L: "low", M: "medium", Q: "quartile", H: "high" }[((
|
|
6003
|
+
const M = { L: "low", M: "medium", Q: "quartile", H: "high" }[((p = A.modelValue) == null ? void 0 : p.QRCodeErrorLevel) || Q.QRCodeErrorLevel || "M"] || "medium";
|
|
6004
6004
|
F && F.trim() ? t.value = await mr.toDataURL(F, {
|
|
6005
6005
|
width: sw,
|
|
6006
6006
|
margin: 0,
|
|
@@ -6011,15 +6011,15 @@ const iw = { class: "qrcode-canvas-fixed" }, lw = ["src", "alt"], sw = 200, cw =
|
|
|
6011
6011
|
},
|
|
6012
6012
|
errorCorrectionLevel: M
|
|
6013
6013
|
}) : t.value = "";
|
|
6014
|
-
} catch (
|
|
6015
|
-
console.error("生成二维码失败:",
|
|
6014
|
+
} catch (Q) {
|
|
6015
|
+
console.error("生成二维码失败:", Q), t.value = "";
|
|
6016
6016
|
}
|
|
6017
6017
|
}, c = H(() => {
|
|
6018
|
-
var
|
|
6019
|
-
const B = i(),
|
|
6018
|
+
var p, Q;
|
|
6019
|
+
const B = i(), g = ((p = A.modelValue) == null ? void 0 : p.width) ?? B.width, h = ((Q = A.modelValue) == null ? void 0 : Q.height) ?? B.height;
|
|
6020
6020
|
return {
|
|
6021
|
-
width: Qn(
|
|
6022
|
-
height: Qn(
|
|
6021
|
+
width: Qn(g) + "px",
|
|
6022
|
+
height: Qn(h) + "px",
|
|
6023
6023
|
display: "flex",
|
|
6024
6024
|
alignItems: "center",
|
|
6025
6025
|
justifyContent: "center",
|
|
@@ -6028,13 +6028,13 @@ const iw = { class: "qrcode-canvas-fixed" }, lw = ["src", "alt"], sw = 200, cw =
|
|
|
6028
6028
|
}), u = () => {
|
|
6029
6029
|
}, d = () => {
|
|
6030
6030
|
console.warn("QR Code image failed to load"), s();
|
|
6031
|
-
},
|
|
6032
|
-
const B = A.modelValue,
|
|
6033
|
-
l(B,
|
|
6031
|
+
}, U = () => {
|
|
6032
|
+
const B = A.modelValue, g = r.value;
|
|
6033
|
+
l(B, g) && s();
|
|
6034
6034
|
}, f = (() => {
|
|
6035
6035
|
let B;
|
|
6036
6036
|
return () => {
|
|
6037
|
-
clearTimeout(B), B = setTimeout(
|
|
6037
|
+
clearTimeout(B), B = setTimeout(U, 50);
|
|
6038
6038
|
};
|
|
6039
6039
|
})();
|
|
6040
6040
|
return Ze(() => {
|
|
@@ -6052,18 +6052,18 @@ const iw = { class: "qrcode-canvas-fixed" }, lw = ["src", "alt"], sw = 200, cw =
|
|
|
6052
6052
|
o.value = null, s();
|
|
6053
6053
|
}, { deep: !0 }), Ur(() => {
|
|
6054
6054
|
r.value = null, o.value = null, t.value = "";
|
|
6055
|
-
}), (B,
|
|
6056
|
-
var
|
|
6055
|
+
}), (B, g) => {
|
|
6056
|
+
var h;
|
|
6057
6057
|
return V(), N("div", {
|
|
6058
6058
|
class: "qrcode-component",
|
|
6059
|
-
onDragstart:
|
|
6059
|
+
onDragstart: g[0] || (g[0] = ZA(() => {
|
|
6060
6060
|
}, ["prevent"])),
|
|
6061
6061
|
style: $(c.value)
|
|
6062
6062
|
}, [
|
|
6063
6063
|
m("div", iw, [
|
|
6064
6064
|
m("img", {
|
|
6065
6065
|
src: t.value,
|
|
6066
|
-
alt: "QR Code: " + (((
|
|
6066
|
+
alt: "QR Code: " + (((h = A.modelValue) == null ? void 0 : h.QRCodeValue) || ""),
|
|
6067
6067
|
class: "qrcode-image",
|
|
6068
6068
|
onLoad: u,
|
|
6069
6069
|
onError: d
|
|
@@ -6157,8 +6157,8 @@ const pw = {
|
|
|
6157
6157
|
boxSizing: "border-box",
|
|
6158
6158
|
zIndex: 1e3
|
|
6159
6159
|
})), c = k(null), u = () => {
|
|
6160
|
-
var
|
|
6161
|
-
return c.value || (c.value = at((
|
|
6160
|
+
var p, Q;
|
|
6161
|
+
return c.value || (c.value = at((Q = (p = t.propsConfig) == null ? void 0 : p.image) == null ? void 0 : Q.propertyPanel) || {}), c.value;
|
|
6162
6162
|
}, d = H(() => ({
|
|
6163
6163
|
width: "100%",
|
|
6164
6164
|
height: "100%",
|
|
@@ -6167,16 +6167,16 @@ const pw = {
|
|
|
6167
6167
|
justifyContent: "center",
|
|
6168
6168
|
overflow: "hidden",
|
|
6169
6169
|
position: "relative"
|
|
6170
|
-
})),
|
|
6170
|
+
})), U = H(() => {
|
|
6171
6171
|
var v;
|
|
6172
6172
|
if (!n.value)
|
|
6173
6173
|
return {};
|
|
6174
|
-
const
|
|
6174
|
+
const p = u(), Q = ((v = t.modelValue) == null ? void 0 : v.ScaleMode) ?? p.ScaleMode ?? 1, F = {
|
|
6175
6175
|
maxWidth: "100%",
|
|
6176
6176
|
maxHeight: "100%",
|
|
6177
6177
|
display: "block"
|
|
6178
6178
|
};
|
|
6179
|
-
switch (
|
|
6179
|
+
switch (Q) {
|
|
6180
6180
|
case 1:
|
|
6181
6181
|
return {
|
|
6182
6182
|
...F,
|
|
@@ -6209,30 +6209,30 @@ const pw = {
|
|
|
6209
6209
|
}, B = () => {
|
|
6210
6210
|
a.value = !1, o.value = !0, n.value = "";
|
|
6211
6211
|
try {
|
|
6212
|
-
const
|
|
6213
|
-
|
|
6212
|
+
const p = { ...t.modelValue || {} };
|
|
6213
|
+
p.ImageSrc = "", r("update:modelValue", p);
|
|
6214
6214
|
} catch {
|
|
6215
6215
|
}
|
|
6216
6216
|
dr && dr.error("图片加载失败,请重新上传");
|
|
6217
|
-
},
|
|
6217
|
+
}, g = () => {
|
|
6218
6218
|
var v;
|
|
6219
|
-
const
|
|
6219
|
+
const p = u(), Q = ((v = t.modelValue) == null ? void 0 : v.ImageSrc) || p.ImageSrc || "";
|
|
6220
6220
|
let F = "";
|
|
6221
|
-
typeof
|
|
6222
|
-
},
|
|
6223
|
-
var
|
|
6224
|
-
const
|
|
6225
|
-
return typeof
|
|
6221
|
+
typeof Q == "object" && Q.fileSrc ? F = Q.fileSrc : typeof Q == "string" && (F = Q), F !== n.value && (n.value = F, a.value = !1, o.value = !1);
|
|
6222
|
+
}, h = () => {
|
|
6223
|
+
var Q;
|
|
6224
|
+
const p = (Q = t.modelValue) == null ? void 0 : Q.ImageSrc;
|
|
6225
|
+
return typeof p == "object" && p.fileName ? p.fileName : "未命名图片";
|
|
6226
6226
|
};
|
|
6227
6227
|
return CA(() => t.modelValue, () => {
|
|
6228
|
-
|
|
6228
|
+
g();
|
|
6229
6229
|
}, { deep: !0 }), CA(() => t.propsConfig, () => {
|
|
6230
|
-
c.value = null,
|
|
6230
|
+
c.value = null, g();
|
|
6231
6231
|
}, { deep: !0 }), Ze(() => {
|
|
6232
6232
|
ue(() => {
|
|
6233
|
-
|
|
6233
|
+
g();
|
|
6234
6234
|
});
|
|
6235
|
-
}), (
|
|
6235
|
+
}), (p, Q) => {
|
|
6236
6236
|
const F = wA("el-icon-picture-filled"), v = wA("el-icon"), C = wA("el-icon-loading");
|
|
6237
6237
|
return V(), N("div", {
|
|
6238
6238
|
class: "image-component",
|
|
@@ -6241,12 +6241,12 @@ const pw = {
|
|
|
6241
6241
|
n.value ? (V(), N("img", {
|
|
6242
6242
|
key: 1,
|
|
6243
6243
|
src: n.value,
|
|
6244
|
-
alt: "Image: " +
|
|
6244
|
+
alt: "Image: " + h(),
|
|
6245
6245
|
class: "image-content",
|
|
6246
|
-
style: $(
|
|
6246
|
+
style: $(U.value),
|
|
6247
6247
|
onLoad: f,
|
|
6248
6248
|
onError: B,
|
|
6249
|
-
onDragstart:
|
|
6249
|
+
onDragstart: Q[0] || (Q[0] = ZA(() => {
|
|
6250
6250
|
}, ["prevent"]))
|
|
6251
6251
|
}, null, 44, Qw)) : (V(), N("div", pw, [
|
|
6252
6252
|
W(v, {
|
|
@@ -6462,15 +6462,15 @@ const Mw = {
|
|
|
6462
6462
|
emits: ["update:modelValue"],
|
|
6463
6463
|
setup(e, { emit: A }) {
|
|
6464
6464
|
const t = e, { defaultProps: r, isSelected: n } = Ic(t, "rectangle"), a = H(() => Tw()), o = H(() => Iw()), i = H(() => {
|
|
6465
|
-
var
|
|
6466
|
-
return hi(((
|
|
6465
|
+
var g, h;
|
|
6466
|
+
return hi(((g = t.modelValue) == null ? void 0 : g.LineWidth) ?? ((h = r.value) == null ? void 0 : h.LineWidth));
|
|
6467
6467
|
}), l = H(() => {
|
|
6468
|
-
var
|
|
6469
|
-
return Mc(((
|
|
6468
|
+
var g, h;
|
|
6469
|
+
return Mc(((g = t.modelValue) == null ? void 0 : g.LineStyle) ?? ((h = r.value) == null ? void 0 : h.LineStyle));
|
|
6470
6470
|
}), s = H(() => l.value === "solid" && i.value < 1), c = H(() => {
|
|
6471
6471
|
if (s.value) {
|
|
6472
|
-
const
|
|
6473
|
-
return
|
|
6472
|
+
const g = Bl(t.modelValue, r.value);
|
|
6473
|
+
return g.border = "none", g.boxShadow = "none", g;
|
|
6474
6474
|
}
|
|
6475
6475
|
return Bl(t.modelValue, r.value);
|
|
6476
6476
|
}), u = Ft.BORDER_COLOR, d = H(() => ({
|
|
@@ -6481,7 +6481,7 @@ const Mw = {
|
|
|
6481
6481
|
background: u,
|
|
6482
6482
|
transform: `scaleY(${i.value})`,
|
|
6483
6483
|
transformOrigin: "top left"
|
|
6484
|
-
})),
|
|
6484
|
+
})), U = H(() => ({
|
|
6485
6485
|
left: 0,
|
|
6486
6486
|
bottom: 0,
|
|
6487
6487
|
width: "100%",
|
|
@@ -6507,16 +6507,16 @@ const Mw = {
|
|
|
6507
6507
|
transformOrigin: "top right"
|
|
6508
6508
|
}));
|
|
6509
6509
|
return CA(() => t.propsConfig, () => {
|
|
6510
|
-
var
|
|
6511
|
-
const
|
|
6510
|
+
var h, p;
|
|
6511
|
+
const g = at((p = (h = t.propsConfig) == null ? void 0 : h.rectangle) == null ? void 0 : p.propertyPanel) || {};
|
|
6512
6512
|
r.value = {
|
|
6513
|
-
LineWidth:
|
|
6514
|
-
LineStyle:
|
|
6515
|
-
BorderRadius:
|
|
6513
|
+
LineWidth: g.LineWidth ?? "0.75pt",
|
|
6514
|
+
LineStyle: g.LineStyle ?? "实线",
|
|
6515
|
+
BorderRadius: g.BorderRadius ?? 0
|
|
6516
6516
|
};
|
|
6517
6517
|
}, { deep: !0, immediate: !0 }), Ur(() => {
|
|
6518
6518
|
r.value = {};
|
|
6519
|
-
}), (
|
|
6519
|
+
}), (g, h) => (V(), N("div", {
|
|
6520
6520
|
class: "rectangle-component",
|
|
6521
6521
|
style: $(o.value)
|
|
6522
6522
|
}, [
|
|
@@ -6535,7 +6535,7 @@ const Mw = {
|
|
|
6535
6535
|
}, null, 4),
|
|
6536
6536
|
m("div", {
|
|
6537
6537
|
class: "hairline-edge bottom",
|
|
6538
|
-
style: $(
|
|
6538
|
+
style: $(U.value)
|
|
6539
6539
|
}, null, 4),
|
|
6540
6540
|
m("div", {
|
|
6541
6541
|
class: "hairline-edge left",
|
|
@@ -6620,17 +6620,17 @@ const Ww = ["width", "height"], Dw = ["y1", "x2", "y2", "stroke-width", "stroke-
|
|
|
6620
6620
|
return `${f},${B}`;
|
|
6621
6621
|
}
|
|
6622
6622
|
return null;
|
|
6623
|
-
}), d = H(() => Sw(o.value, s.value)),
|
|
6623
|
+
}), d = H(() => Sw(o.value, s.value)), U = H(() => Nw(t.modelValue, n.value));
|
|
6624
6624
|
return CA(() => t.modelValue, (f) => {
|
|
6625
6625
|
if (f) {
|
|
6626
6626
|
n.value = {
|
|
6627
6627
|
LineWidth: f.LineWidth || "0.75pt",
|
|
6628
6628
|
LineStyle: f.LineStyle || "实线"
|
|
6629
6629
|
};
|
|
6630
|
-
const
|
|
6631
|
-
Math.abs(f.height -
|
|
6630
|
+
const g = parseFloat(f.LineWidth || "0.75pt") * 0.3528;
|
|
6631
|
+
Math.abs(f.height - g) > 1e-3 && r("update:modelValue", {
|
|
6632
6632
|
...f,
|
|
6633
|
-
height: Number(
|
|
6633
|
+
height: Number(g.toFixed(3))
|
|
6634
6634
|
});
|
|
6635
6635
|
}
|
|
6636
6636
|
}, { immediate: !0, deep: !0 }), CA(() => {
|
|
@@ -6638,15 +6638,15 @@ const Ww = ["width", "height"], Dw = ["y1", "x2", "y2", "stroke-width", "stroke-
|
|
|
6638
6638
|
return (f = t.modelValue) == null ? void 0 : f.LineWidth;
|
|
6639
6639
|
}, (f) => {
|
|
6640
6640
|
if (f && t.modelValue) {
|
|
6641
|
-
const
|
|
6642
|
-
Math.abs(t.modelValue.height -
|
|
6641
|
+
const g = parseFloat(f) * 0.3528;
|
|
6642
|
+
Math.abs(t.modelValue.height - g) > 1e-3 && r("update:modelValue", {
|
|
6643
6643
|
...t.modelValue,
|
|
6644
|
-
height: Number(
|
|
6644
|
+
height: Number(g.toFixed(3))
|
|
6645
6645
|
});
|
|
6646
6646
|
}
|
|
6647
6647
|
}, { immediate: !0 }), (f, B) => (V(), N("div", {
|
|
6648
6648
|
class: "horline-component",
|
|
6649
|
-
style: $(
|
|
6649
|
+
style: $(U.value)
|
|
6650
6650
|
}, [
|
|
6651
6651
|
(V(), N("svg", {
|
|
6652
6652
|
width: o.value,
|
|
@@ -6872,8 +6872,8 @@ const qw = { class: "component-list" }, $w = { class: "group-title" }, AF = { cl
|
|
|
6872
6872
|
return (s, c) => {
|
|
6873
6873
|
const u = wA("el-icon");
|
|
6874
6874
|
return V(), N("div", qw, [
|
|
6875
|
-
(V(!0), N(TA, null, Se(t.value, (d,
|
|
6876
|
-
key:
|
|
6875
|
+
(V(!0), N(TA, null, Se(t.value, (d, U) => (V(), N("div", {
|
|
6876
|
+
key: U,
|
|
6877
6877
|
class: "component-group"
|
|
6878
6878
|
}, [
|
|
6879
6879
|
m("div", $w, Be(d.groupName), 1),
|
|
@@ -6882,7 +6882,7 @@ const qw = { class: "component-list" }, $w = { class: "group-title" }, AF = { cl
|
|
|
6882
6882
|
key: B,
|
|
6883
6883
|
class: "component-item",
|
|
6884
6884
|
draggable: "true",
|
|
6885
|
-
onDragstart: (
|
|
6885
|
+
onDragstart: (g) => s.$emit("dragStart", { e: g, comp: f, previewDiv: l(f) })
|
|
6886
6886
|
}, [
|
|
6887
6887
|
W(u, {
|
|
6888
6888
|
size: 30,
|
|
@@ -7002,7 +7002,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7002
7002
|
a.data.punchingList.splice(c, 1);
|
|
7003
7003
|
};
|
|
7004
7004
|
return (c, u) => {
|
|
7005
|
-
const d = wA("el-button"),
|
|
7005
|
+
const d = wA("el-button"), U = wA("el-input-number"), f = wA("el-table-column"), B = wA("el-col"), g = wA("el-row"), h = wA("el-table"), p = wA("el-form-item"), Q = wA("el-form"), F = wA("el-main"), v = wA("el-dialog");
|
|
7006
7006
|
return V(), N(TA, null, [
|
|
7007
7007
|
W(d, {
|
|
7008
7008
|
type: "primary",
|
|
@@ -7062,7 +7062,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7062
7062
|
default: j(() => [
|
|
7063
7063
|
W(F, { style: { "max-height": "60vh", padding: "0" } }, {
|
|
7064
7064
|
default: j(() => [
|
|
7065
|
-
W(
|
|
7065
|
+
W(Q, {
|
|
7066
7066
|
ref: "formRef",
|
|
7067
7067
|
model: a.data,
|
|
7068
7068
|
"label-width": "90px",
|
|
@@ -7070,7 +7070,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7070
7070
|
"label-suffix": ":"
|
|
7071
7071
|
}, {
|
|
7072
7072
|
default: j(() => [
|
|
7073
|
-
W(
|
|
7073
|
+
W(p, null, {
|
|
7074
7074
|
label: j(() => [
|
|
7075
7075
|
m("div", null, [
|
|
7076
7076
|
u[9] || (u[9] = m("p", null, "打印区域:", -1)),
|
|
@@ -7091,7 +7091,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7091
7091
|
var C, T, M;
|
|
7092
7092
|
return [
|
|
7093
7093
|
m("div", UF, [
|
|
7094
|
-
((T = (C = a.data) == null ? void 0 : C.printList) == null ? void 0 : T.length) > 0 ? (V(), yA(
|
|
7094
|
+
((T = (C = a.data) == null ? void 0 : C.printList) == null ? void 0 : T.length) > 0 ? (V(), yA(h, {
|
|
7095
7095
|
key: 0,
|
|
7096
7096
|
data: (M = a.data) == null ? void 0 : M.printList,
|
|
7097
7097
|
class: "graph-table"
|
|
@@ -7103,7 +7103,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7103
7103
|
width: "100"
|
|
7104
7104
|
}, {
|
|
7105
7105
|
default: j((y) => [
|
|
7106
|
-
W(
|
|
7106
|
+
W(U, {
|
|
7107
7107
|
modelValue: y.row.x,
|
|
7108
7108
|
"onUpdate:modelValue": (S) => y.row.x = S,
|
|
7109
7109
|
controls: !1,
|
|
@@ -7118,7 +7118,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7118
7118
|
width: "100"
|
|
7119
7119
|
}, {
|
|
7120
7120
|
default: j((y) => [
|
|
7121
|
-
W(
|
|
7121
|
+
W(U, {
|
|
7122
7122
|
modelValue: y.row.y,
|
|
7123
7123
|
"onUpdate:modelValue": (S) => y.row.y = S,
|
|
7124
7124
|
controls: !1,
|
|
@@ -7133,7 +7133,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7133
7133
|
width: "100"
|
|
7134
7134
|
}, {
|
|
7135
7135
|
default: j((y) => [
|
|
7136
|
-
W(
|
|
7136
|
+
W(U, {
|
|
7137
7137
|
modelValue: y.row.width,
|
|
7138
7138
|
"onUpdate:modelValue": (S) => y.row.width = S,
|
|
7139
7139
|
controls: !1,
|
|
@@ -7148,7 +7148,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7148
7148
|
width: "100"
|
|
7149
7149
|
}, {
|
|
7150
7150
|
default: j((y) => [
|
|
7151
|
-
W(
|
|
7151
|
+
W(U, {
|
|
7152
7152
|
modelValue: y.row.height,
|
|
7153
7153
|
"onUpdate:modelValue": (S) => y.row.height = S,
|
|
7154
7154
|
controls: !1,
|
|
@@ -7162,11 +7162,11 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7162
7162
|
align: "center"
|
|
7163
7163
|
}, {
|
|
7164
7164
|
default: j((y) => [
|
|
7165
|
-
W(
|
|
7165
|
+
W(g, { gutter: 10 }, {
|
|
7166
7166
|
default: j(() => [
|
|
7167
7167
|
W(B, { span: 6 }, {
|
|
7168
7168
|
default: j(() => [
|
|
7169
|
-
W(
|
|
7169
|
+
W(U, {
|
|
7170
7170
|
modelValue: y.row.topLeftRadius,
|
|
7171
7171
|
"onUpdate:modelValue": (S) => y.row.topLeftRadius = S,
|
|
7172
7172
|
controls: !1,
|
|
@@ -7177,7 +7177,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7177
7177
|
}, 1024),
|
|
7178
7178
|
W(B, { span: 6 }, {
|
|
7179
7179
|
default: j(() => [
|
|
7180
|
-
W(
|
|
7180
|
+
W(U, {
|
|
7181
7181
|
modelValue: y.row.bottomLeftRadius,
|
|
7182
7182
|
"onUpdate:modelValue": (S) => y.row.bottomLeftRadius = S,
|
|
7183
7183
|
controls: !1,
|
|
@@ -7188,7 +7188,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7188
7188
|
}, 1024),
|
|
7189
7189
|
W(B, { span: 6 }, {
|
|
7190
7190
|
default: j(() => [
|
|
7191
|
-
W(
|
|
7191
|
+
W(U, {
|
|
7192
7192
|
modelValue: y.row.topRightRadius,
|
|
7193
7193
|
"onUpdate:modelValue": (S) => y.row.topRightRadius = S,
|
|
7194
7194
|
controls: !1,
|
|
@@ -7199,7 +7199,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7199
7199
|
}, 1024),
|
|
7200
7200
|
W(B, { span: 6 }, {
|
|
7201
7201
|
default: j(() => [
|
|
7202
|
-
W(
|
|
7202
|
+
W(U, {
|
|
7203
7203
|
modelValue: y.row.bottomRightRadius,
|
|
7204
7204
|
"onUpdate:modelValue": (S) => y.row.bottomRightRadius = S,
|
|
7205
7205
|
controls: !1,
|
|
@@ -7242,7 +7242,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7242
7242
|
}),
|
|
7243
7243
|
_: 1
|
|
7244
7244
|
}),
|
|
7245
|
-
W(
|
|
7245
|
+
W(p, { label: "打孔区域" }, {
|
|
7246
7246
|
label: j(() => [
|
|
7247
7247
|
m("div", null, [
|
|
7248
7248
|
u[12] || (u[12] = m("p", null, "打孔区域:", -1)),
|
|
@@ -7261,7 +7261,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7261
7261
|
]),
|
|
7262
7262
|
default: j(() => [
|
|
7263
7263
|
m("div", QF, [
|
|
7264
|
-
a.data.punchingList.length > 0 ? (V(), yA(
|
|
7264
|
+
a.data.punchingList.length > 0 ? (V(), yA(h, {
|
|
7265
7265
|
key: 0,
|
|
7266
7266
|
data: a.data.punchingList,
|
|
7267
7267
|
class: "graph-table"
|
|
@@ -7273,7 +7273,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7273
7273
|
width: "100"
|
|
7274
7274
|
}, {
|
|
7275
7275
|
default: j((C) => [
|
|
7276
|
-
W(
|
|
7276
|
+
W(U, {
|
|
7277
7277
|
modelValue: C.row.x,
|
|
7278
7278
|
"onUpdate:modelValue": (T) => C.row.x = T,
|
|
7279
7279
|
controls: !1,
|
|
@@ -7288,7 +7288,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7288
7288
|
width: "100"
|
|
7289
7289
|
}, {
|
|
7290
7290
|
default: j((C) => [
|
|
7291
|
-
W(
|
|
7291
|
+
W(U, {
|
|
7292
7292
|
modelValue: C.row.y,
|
|
7293
7293
|
"onUpdate:modelValue": (T) => C.row.y = T,
|
|
7294
7294
|
controls: !1,
|
|
@@ -7303,7 +7303,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7303
7303
|
width: "100"
|
|
7304
7304
|
}, {
|
|
7305
7305
|
default: j((C) => [
|
|
7306
|
-
W(
|
|
7306
|
+
W(U, {
|
|
7307
7307
|
modelValue: C.row.width,
|
|
7308
7308
|
"onUpdate:modelValue": (T) => C.row.width = T,
|
|
7309
7309
|
controls: !1,
|
|
@@ -7319,7 +7319,7 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7319
7319
|
width: "100"
|
|
7320
7320
|
}, {
|
|
7321
7321
|
default: j((C) => [
|
|
7322
|
-
W(
|
|
7322
|
+
W(U, {
|
|
7323
7323
|
modelValue: C.row.height,
|
|
7324
7324
|
"onUpdate:modelValue": (T) => C.row.height = T,
|
|
7325
7325
|
controls: !1,
|
|
@@ -7458,14 +7458,14 @@ const gF = { class: "tg-title" }, UF = { class: "table-container" }, pF = {
|
|
|
7458
7458
|
}
|
|
7459
7459
|
}, CF = /* @__PURE__ */ RA(FF, [["__scopeId", "data-v-7f9ab3cb"]]);
|
|
7460
7460
|
function EF(e = {}) {
|
|
7461
|
-
const { scale: A, canvasWidth: t, canvasHeight: r, selectItem: n, onStopDrag: a, onStartDrag: o, onDragUpdate: i } = e, l = k(!1), s = k(!1), c = k(null), u = k({ x: 0, y: 0 }), d = k({ x: 0, y: 0 }),
|
|
7462
|
-
function f(
|
|
7463
|
-
l.value = !0, s.value = !0, typeof o == "function" && o(), c.value =
|
|
7464
|
-
}
|
|
7465
|
-
function B(
|
|
7466
|
-
const T = `${
|
|
7467
|
-
if (
|
|
7468
|
-
return
|
|
7461
|
+
const { scale: A, canvasWidth: t, canvasHeight: r, selectItem: n, onStopDrag: a, onStartDrag: o, onDragUpdate: i } = e, l = k(!1), s = k(!1), c = k(null), u = k({ x: 0, y: 0 }), d = k({ x: 0, y: 0 }), U = /* @__PURE__ */ new Map();
|
|
7462
|
+
function f(p, Q, F) {
|
|
7463
|
+
l.value = !0, s.value = !0, typeof o == "function" && o(), c.value = Q, u.value = { x: p.clientX, y: p.clientY }, d.value = { x: Q.props.x, y: Q.props.y }, typeof n == "function" && n(Q, F || p), document.addEventListener("mousemove", g), document.addEventListener("mouseup", h);
|
|
7464
|
+
}
|
|
7465
|
+
function B(p, Q, F, v, C) {
|
|
7466
|
+
const T = `${p}_${Q}_${F}_${v}_${C}`;
|
|
7467
|
+
if (U.has(T))
|
|
7468
|
+
return U.get(T);
|
|
7469
7469
|
const M = C * Math.PI / 180, y = F / 2, S = v / 2, L = [
|
|
7470
7470
|
{ x: 0, y: 0 },
|
|
7471
7471
|
{ x: F, y: 0 },
|
|
@@ -7474,8 +7474,8 @@ function EF(e = {}) {
|
|
|
7474
7474
|
].map((G) => {
|
|
7475
7475
|
const _ = G.x - y, rA = G.y - S, fA = _ * Math.cos(M) - rA * Math.sin(M), uA = _ * Math.sin(M) + rA * Math.cos(M);
|
|
7476
7476
|
return {
|
|
7477
|
-
x: Number((fA + y +
|
|
7478
|
-
y: Number((uA + S +
|
|
7477
|
+
x: Number((fA + y + p).toFixed(2)),
|
|
7478
|
+
y: Number((uA + S + Q).toFixed(2))
|
|
7479
7479
|
};
|
|
7480
7480
|
}), b = L.map((G) => G.x), P = L.map((G) => G.y), iA = {
|
|
7481
7481
|
minX: Math.min(...b),
|
|
@@ -7483,13 +7483,13 @@ function EF(e = {}) {
|
|
|
7483
7483
|
minY: Math.min(...P),
|
|
7484
7484
|
maxY: Math.max(...P)
|
|
7485
7485
|
};
|
|
7486
|
-
return
|
|
7486
|
+
return U.set(T, iA), iA;
|
|
7487
7487
|
}
|
|
7488
|
-
function
|
|
7488
|
+
function g(p) {
|
|
7489
7489
|
if (!l.value || !c.value)
|
|
7490
7490
|
return;
|
|
7491
|
-
const
|
|
7492
|
-
let T = d.value.x +
|
|
7491
|
+
const Q = p.clientX - u.value.x, F = p.clientY - u.value.y, v = (A == null ? void 0 : A.value) || 1, C = 1 / 3.7795275591;
|
|
7492
|
+
let T = d.value.x + Q * C / v, M = d.value.y + F * C / v;
|
|
7493
7493
|
if (t != null && t.value && (r != null && r.value)) {
|
|
7494
7494
|
const y = c.value.props.width || 0, S = c.value.props.height || 0, D = c.value.props.rotation || 0;
|
|
7495
7495
|
let L = !1;
|
|
@@ -7501,14 +7501,14 @@ function EF(e = {}) {
|
|
|
7501
7501
|
}
|
|
7502
7502
|
c.value.props.x = Number(T.toFixed(2)), c.value.props.y = Number(M.toFixed(2)), typeof i == "function" && i();
|
|
7503
7503
|
}
|
|
7504
|
-
function
|
|
7504
|
+
function h() {
|
|
7505
7505
|
l.value = !1, setTimeout(() => {
|
|
7506
7506
|
s.value = !1;
|
|
7507
|
-
}, 50), c.value && typeof n == "function" && n(c.value), c.value = null, typeof a == "function" && a(), typeof i == "function" && i(),
|
|
7508
|
-
const
|
|
7509
|
-
|
|
7507
|
+
}, 50), c.value && typeof n == "function" && n(c.value), c.value = null, typeof a == "function" && a(), typeof i == "function" && i(), U.clear();
|
|
7508
|
+
const p = function(Q) {
|
|
7509
|
+
Q && (typeof Q.stopImmediatePropagation == "function" && Q.stopImmediatePropagation(), typeof Q.stopPropagation == "function" && Q.stopPropagation(), typeof Q.preventDefault == "function" && Q.preventDefault()), window.removeEventListener("click", p, !0);
|
|
7510
7510
|
};
|
|
7511
|
-
window.addEventListener("click",
|
|
7511
|
+
window.addEventListener("click", p, !0), document.removeEventListener("mousemove", g), document.removeEventListener("mouseup", h);
|
|
7512
7512
|
}
|
|
7513
7513
|
return {
|
|
7514
7514
|
dragging: l,
|
|
@@ -7519,19 +7519,19 @@ function EF(e = {}) {
|
|
|
7519
7519
|
// 当前拖拽元素
|
|
7520
7520
|
startDrag: f,
|
|
7521
7521
|
// 开始拖拽方法
|
|
7522
|
-
stopDrag:
|
|
7522
|
+
stopDrag: h
|
|
7523
7523
|
// 停止拖拽方法
|
|
7524
7524
|
};
|
|
7525
7525
|
}
|
|
7526
7526
|
function mF(e, A, t, r) {
|
|
7527
|
-
const n = k(!1), a = k(null), o = k({ x: 0, y: 0 }), i = k({ width: 0, height: 0, x: 0, y: 0, rotation: 0 }), l = k(""), s = k(""), c = k({ x: 0, y: 0 }), u = k([]), d = k(null),
|
|
7528
|
-
function
|
|
7527
|
+
const n = k(!1), a = k(null), o = k({ x: 0, y: 0 }), i = k({ width: 0, height: 0, x: 0, y: 0, rotation: 0 }), l = k(""), s = k(""), c = k({ x: 0, y: 0 }), u = k([]), d = k(null), U = k(0), f = dl.UPDATE_THRESHOLD, B = k({ x: 0, y: 0, width: 0, height: 0 }), g = k(/* @__PURE__ */ new Map()), h = k(/* @__PURE__ */ new Map()), p = k(null);
|
|
7528
|
+
function Q(S) {
|
|
7529
7529
|
return S * Math.PI / 180;
|
|
7530
7530
|
}
|
|
7531
7531
|
function F(S, D, L, b, P, iA, G) {
|
|
7532
7532
|
const _ = `${S.toFixed(1)}_${D.toFixed(1)}_${L.toFixed(1)}_${b.toFixed(1)}_${P.toFixed(1)}`;
|
|
7533
|
-
if (
|
|
7534
|
-
return
|
|
7533
|
+
if (g.value.has(_))
|
|
7534
|
+
return g.value.get(_);
|
|
7535
7535
|
const rA = v(S, D, L, b, P), fA = rA.map((SA) => SA.x), uA = rA.map((SA) => SA.y), aA = Math.min(...fA), X = Math.max(...fA), z = Math.min(...uA), NA = Math.max(...uA), QA = 0.5, hA = aA < -QA || X > iA + QA || z < -QA || NA > G + QA, gA = {
|
|
7536
7536
|
minX: aA,
|
|
7537
7537
|
maxX: X,
|
|
@@ -7540,17 +7540,17 @@ function mF(e, A, t, r) {
|
|
|
7540
7540
|
isOutOfBounds: hA,
|
|
7541
7541
|
corners: rA
|
|
7542
7542
|
};
|
|
7543
|
-
if (
|
|
7544
|
-
const SA =
|
|
7545
|
-
|
|
7543
|
+
if (g.value.set(_, gA), g.value.size > dl.MAX_SIZE) {
|
|
7544
|
+
const SA = g.value.keys().next().value;
|
|
7545
|
+
g.value.delete(SA);
|
|
7546
7546
|
}
|
|
7547
7547
|
return gA;
|
|
7548
7548
|
}
|
|
7549
7549
|
function v(S, D, L, b, P) {
|
|
7550
7550
|
const iA = `${S.toFixed(1)}_${D.toFixed(1)}_${L.toFixed(1)}_${b.toFixed(1)}_${P.toFixed(1)}`;
|
|
7551
|
-
if (
|
|
7552
|
-
return
|
|
7553
|
-
const G =
|
|
7551
|
+
if (h.value.has(iA))
|
|
7552
|
+
return h.value.get(iA);
|
|
7553
|
+
const G = Q(P), _ = Math.cos(G), rA = Math.sin(G), fA = S + L / 2, uA = D + b / 2, X = [
|
|
7554
7554
|
{ x: -L / 2, y: -b / 2 },
|
|
7555
7555
|
{ x: L / 2, y: -b / 2 },
|
|
7556
7556
|
{ x: L / 2, y: b / 2 },
|
|
@@ -7559,9 +7559,9 @@ function mF(e, A, t, r) {
|
|
|
7559
7559
|
x: Number((fA + z.x * _ - z.y * rA).toFixed(2)),
|
|
7560
7560
|
y: Number((uA + z.x * rA + z.y * _).toFixed(2))
|
|
7561
7561
|
}));
|
|
7562
|
-
if (
|
|
7563
|
-
const z =
|
|
7564
|
-
|
|
7562
|
+
if (h.value.set(iA, X), h.value.size > 100) {
|
|
7563
|
+
const z = h.value.keys().next().value;
|
|
7564
|
+
h.value.delete(z);
|
|
7565
7565
|
}
|
|
7566
7566
|
return X;
|
|
7567
7567
|
}
|
|
@@ -7608,7 +7608,7 @@ function mF(e, A, t, r) {
|
|
|
7608
7608
|
x: D.props.x,
|
|
7609
7609
|
y: D.props.y,
|
|
7610
7610
|
rotation: D.props.rotation || 0
|
|
7611
|
-
}, s.value = "", c.value = { x: 0, y: 0 },
|
|
7611
|
+
}, s.value = "", c.value = { x: 0, y: 0 }, p.value = null, d.value = C(
|
|
7612
7612
|
L,
|
|
7613
7613
|
i.value.x,
|
|
7614
7614
|
i.value.y,
|
|
@@ -7620,24 +7620,24 @@ function mF(e, A, t, r) {
|
|
|
7620
7620
|
y: i.value.y,
|
|
7621
7621
|
width: i.value.width,
|
|
7622
7622
|
height: i.value.height
|
|
7623
|
-
}, u.value = [...r.value],
|
|
7623
|
+
}, u.value = [...r.value], g.value.clear(), h.value.clear(), document.addEventListener("mousemove", M), document.addEventListener("mouseup", y));
|
|
7624
7624
|
}
|
|
7625
7625
|
function M(S) {
|
|
7626
7626
|
if (!n.value || !a.value || !d.value)
|
|
7627
7627
|
return;
|
|
7628
7628
|
const D = Date.now();
|
|
7629
|
-
if (D -
|
|
7629
|
+
if (D - U.value < f)
|
|
7630
7630
|
return;
|
|
7631
|
-
|
|
7632
|
-
const L = (t == null ? void 0 : t.value) || 1, b = i.value.rotation || 0, P =
|
|
7631
|
+
U.value = D;
|
|
7632
|
+
const L = (t == null ? void 0 : t.value) || 1, b = i.value.rotation || 0, P = Q(b), iA = Math.cos(P), G = Math.sin(P), _ = i.value.width, rA = i.value.height, fA = i.value.x, uA = i.value.y, aA = 1;
|
|
7633
7633
|
let X = _, z = rA;
|
|
7634
7634
|
const NA = (S.clientX - o.value.x) / 3.7795275591 / L, QA = (S.clientY - o.value.y) / 3.7795275591 / L;
|
|
7635
7635
|
let hA, gA;
|
|
7636
7636
|
b === 0 ? (hA = NA, gA = QA) : (hA = NA * iA + QA * G, gA = -NA * G + QA * iA);
|
|
7637
7637
|
const SA = !!a.value.props.lockAspectRatio, XA = _ / rA, se = Math.abs(S.clientX - o.value.x), We = Math.abs(S.clientY - o.value.y);
|
|
7638
|
-
if (SA && !
|
|
7639
|
-
if (SA &&
|
|
7640
|
-
|
|
7638
|
+
if (SA && !p.value && (p.value = se > We ? "x" : "y"), l.value.includes("-")) {
|
|
7639
|
+
if (SA && p.value)
|
|
7640
|
+
p.value === "x" ? (["top-left", "bottom-left"].includes(l.value) ? X = Math.max(aA, _ - hA) : X = Math.max(aA, _ + hA), z = X / XA) : (["top-left", "top-right"].includes(l.value) ? z = Math.max(aA, rA - gA) : z = Math.max(aA, rA + gA), X = z * XA);
|
|
7641
7641
|
else if (l.value === "top-left" ? (X = Math.max(aA, _ - hA), z = Math.max(aA, rA - gA)) : l.value === "top-right" ? (X = Math.max(aA, _ + hA), z = Math.max(aA, rA - gA)) : l.value === "bottom-right" ? (X = Math.max(aA, _ + hA), z = Math.max(aA, rA + gA)) : l.value === "bottom-left" && (X = Math.max(aA, _ - hA), z = Math.max(aA, rA + gA)), SA) {
|
|
7642
7642
|
const HA = X / z;
|
|
7643
7643
|
if (Math.abs(HA - XA) > 0.01) {
|
|
@@ -7673,7 +7673,7 @@ function mF(e, A, t, r) {
|
|
|
7673
7673
|
(Math.abs(X - a.value.props.width) > 1e-3 || Math.abs(z - a.value.props.height) > 1e-3 || Math.abs(ne - a.value.props.x) > 1e-3 || Math.abs(EA - a.value.props.y) > 1e-3) && (a.value.props.x = Number(ne.toFixed(2)), a.value.props.y = Number(EA.toFixed(2)), a.value.props.width = Number(X.toFixed(2)), a.value.props.height = Number(z.toFixed(2)), B.value = { x: ne, y: EA, width: X, height: z });
|
|
7674
7674
|
}
|
|
7675
7675
|
function y() {
|
|
7676
|
-
n.value = !1, a.value = null, s.value = "", c.value = { x: 0, y: 0 }, d.value = null, B.value = { x: 0, y: 0, width: 0, height: 0 },
|
|
7676
|
+
n.value = !1, a.value = null, s.value = "", c.value = { x: 0, y: 0 }, d.value = null, B.value = { x: 0, y: 0, width: 0, height: 0 }, g.value.clear(), h.value.clear(), u.value.length > 0 && (r.value = [...u.value]), u.value = [], document.removeEventListener("mousemove", M), document.removeEventListener("mouseup", y), p.value = null;
|
|
7677
7677
|
}
|
|
7678
7678
|
return {
|
|
7679
7679
|
resizing: n,
|
|
@@ -7724,38 +7724,38 @@ function yF() {
|
|
|
7724
7724
|
return;
|
|
7725
7725
|
a.preventDefault(), a.stopPropagation();
|
|
7726
7726
|
const i = a.target.parentElement.getBoundingClientRect(), l = i.left + i.width / 2, s = i.top + i.height / 2;
|
|
7727
|
-
let c = null, u = !1, d = B(a.clientX, a.clientY),
|
|
7728
|
-
function B(
|
|
7729
|
-
const v =
|
|
7727
|
+
let c = null, u = !1, d = B(a.clientX, a.clientY), U = o.props.rotation || 0, f = U;
|
|
7728
|
+
function B(Q, F) {
|
|
7729
|
+
const v = Q - l, C = F - s;
|
|
7730
7730
|
let T = Math.atan2(C, v) * 180 / Math.PI + 90;
|
|
7731
7731
|
return T > 180 && (T -= 360), T < -180 && (T += 360), T;
|
|
7732
7732
|
}
|
|
7733
|
-
function
|
|
7734
|
-
const F =
|
|
7733
|
+
function g(Q) {
|
|
7734
|
+
const F = Q.clientX - l, v = Q.clientY - s;
|
|
7735
7735
|
if (Math.sqrt(F * F + v * v) < 20) {
|
|
7736
7736
|
u = !0, c = null;
|
|
7737
7737
|
return;
|
|
7738
7738
|
}
|
|
7739
7739
|
if (u) {
|
|
7740
|
-
d = B(
|
|
7740
|
+
d = B(Q.clientX, Q.clientY), u = !1, c = null;
|
|
7741
7741
|
return;
|
|
7742
7742
|
}
|
|
7743
|
-
const T = B(
|
|
7743
|
+
const T = B(Q.clientX, Q.clientY);
|
|
7744
7744
|
let M = T - d;
|
|
7745
|
-
M > 180 && (M -= 360), M < -180 && (M += 360),
|
|
7745
|
+
M > 180 && (M -= 360), M < -180 && (M += 360), U += M, d = T, f = r(f, U, 0.25);
|
|
7746
7746
|
const y = (f % 360 + 360) % 360;
|
|
7747
7747
|
Math.abs(o.props.rotation - y) >= 0.2 && (o.props.rotation = Number(y.toFixed(2))), c = null;
|
|
7748
7748
|
}
|
|
7749
|
-
const
|
|
7750
|
-
c || (c = requestAnimationFrame(() =>
|
|
7751
|
-
},
|
|
7752
|
-
|
|
7749
|
+
const h = (Q) => {
|
|
7750
|
+
c || (c = requestAnimationFrame(() => g(Q)));
|
|
7751
|
+
}, p = (Q) => {
|
|
7752
|
+
Q && Q.stopPropagation(), document.removeEventListener("mousemove", h), document.removeEventListener("mouseup", p), c && (cancelAnimationFrame(c), c = null), u = !1;
|
|
7753
7753
|
const F = (v) => {
|
|
7754
7754
|
v.stopImmediatePropagation(), document.removeEventListener("click", F, !0);
|
|
7755
7755
|
};
|
|
7756
7756
|
document.addEventListener("click", F, !0);
|
|
7757
7757
|
};
|
|
7758
|
-
document.addEventListener("mousemove",
|
|
7758
|
+
document.addEventListener("mousemove", h), document.addEventListener("mouseup", p);
|
|
7759
7759
|
}
|
|
7760
7760
|
return {
|
|
7761
7761
|
startRotate: n
|
|
@@ -7785,15 +7785,15 @@ function VF(e, A, t) {
|
|
|
7785
7785
|
const c = e.value[e.value.length - 1];
|
|
7786
7786
|
let u = Number(c.props[i]) + Number(l);
|
|
7787
7787
|
if (i === "x" || i === "y") {
|
|
7788
|
-
const d = A != null && A.value ? A.value - c.props.width : 1 / 0,
|
|
7789
|
-
i === "x" ? u = Math.max(0, Math.min(u, d)) : i === "y" && (u = Math.max(0, Math.min(u,
|
|
7788
|
+
const d = A != null && A.value ? A.value - c.props.width : 1 / 0, U = t != null && t.value ? t.value - c.props.height : 1 / 0;
|
|
7789
|
+
i === "x" ? u = Math.max(0, Math.min(u, d)) : i === "y" && (u = Math.max(0, Math.min(u, U)));
|
|
7790
7790
|
} else if (i === "width" || i === "height") {
|
|
7791
7791
|
if (i === "width") {
|
|
7792
|
-
const
|
|
7793
|
-
u = Math.max(1, Math.min(u,
|
|
7792
|
+
const U = A != null && A.value ? A.value - c.props.x : 1 / 0;
|
|
7793
|
+
u = Math.max(1, Math.min(u, U));
|
|
7794
7794
|
} else if (i === "height") {
|
|
7795
|
-
const
|
|
7796
|
-
u = Math.max(1, Math.min(u,
|
|
7795
|
+
const U = t != null && t.value ? t.value - c.props.y : 1 / 0;
|
|
7796
|
+
u = Math.max(1, Math.min(u, U));
|
|
7797
7797
|
}
|
|
7798
7798
|
}
|
|
7799
7799
|
if (!(u < s)) {
|
|
@@ -7807,8 +7807,8 @@ function VF(e, A, t) {
|
|
|
7807
7807
|
}
|
|
7808
7808
|
}
|
|
7809
7809
|
if (c.type === "horline" && i === "height") {
|
|
7810
|
-
const
|
|
7811
|
-
c.props.height = Number(u.toFixed(2)), c.props.LineWidth = Number(
|
|
7810
|
+
const U = u / 0.3528;
|
|
7811
|
+
c.props.height = Number(u.toFixed(2)), c.props.LineWidth = Number(U.toFixed(2)) + "pt";
|
|
7812
7812
|
return;
|
|
7813
7813
|
}
|
|
7814
7814
|
c.props[i] = Number(u.toFixed(2));
|
|
@@ -7869,8 +7869,8 @@ function TF(e, A, t, r) {
|
|
|
7869
7869
|
const s = JSON.parse(JSON.stringify(n.value));
|
|
7870
7870
|
if (s.id = Date.now(), s.props) {
|
|
7871
7871
|
let c = Number(s.props.x) + 5, u = Number(s.props.y) + 5;
|
|
7872
|
-
const d = t.value - Number(s.props.width),
|
|
7873
|
-
s.props.x = Math.max(0, Math.min(c, d)), s.props.y = Math.max(0, Math.min(u,
|
|
7872
|
+
const d = t.value - Number(s.props.width), U = r.value - Number(s.props.height);
|
|
7873
|
+
s.props.x = Math.max(0, Math.min(c, d)), s.props.y = Math.max(0, Math.min(u, U)), s.props.x != c && (s.props.x = c - 5 * 2), s.props.y != u && (s.props.y = u - 5 * 2);
|
|
7874
7874
|
}
|
|
7875
7875
|
e.value.push(s), A.value = [s], i.preventDefault();
|
|
7876
7876
|
}
|
|
@@ -7885,34 +7885,34 @@ function IF(e = {}) {
|
|
|
7885
7885
|
// 垂直对齐线 [{ x: number, visible: boolean }]
|
|
7886
7886
|
}), a = 0.1;
|
|
7887
7887
|
function o(d) {
|
|
7888
|
-
const
|
|
7888
|
+
const U = Number(d.props.x) || 0, f = Number(d.props.y) || 0, B = Number(d.props.width) || 0, g = Number(d.props.height) || 0;
|
|
7889
7889
|
return {
|
|
7890
|
-
centerX:
|
|
7891
|
-
centerY: f +
|
|
7890
|
+
centerX: U + B / 2,
|
|
7891
|
+
centerY: f + g / 2
|
|
7892
7892
|
};
|
|
7893
7893
|
}
|
|
7894
|
-
function i(d,
|
|
7894
|
+
function i(d, U) {
|
|
7895
7895
|
const f = [], B = /* @__PURE__ */ new Set();
|
|
7896
|
-
return
|
|
7897
|
-
const
|
|
7896
|
+
return U.forEach((g) => {
|
|
7897
|
+
const h = o(g), p = Math.abs(d.centerY - h.centerY);
|
|
7898
7898
|
Math.round(d.centerY * 100) / 100;
|
|
7899
|
-
const
|
|
7900
|
-
|
|
7901
|
-
y:
|
|
7899
|
+
const Q = Math.round(h.centerY * 100) / 100;
|
|
7900
|
+
p <= a && !B.has(Q) && (f.push({
|
|
7901
|
+
y: Q,
|
|
7902
7902
|
visible: !0
|
|
7903
|
-
}), B.add(
|
|
7903
|
+
}), B.add(Q));
|
|
7904
7904
|
}), f;
|
|
7905
7905
|
}
|
|
7906
|
-
function l(d,
|
|
7906
|
+
function l(d, U) {
|
|
7907
7907
|
const f = [], B = /* @__PURE__ */ new Set();
|
|
7908
|
-
return
|
|
7909
|
-
const
|
|
7908
|
+
return U.forEach((g) => {
|
|
7909
|
+
const h = o(g), p = Math.abs(d.centerX - h.centerX);
|
|
7910
7910
|
Math.round(d.centerX * 100) / 100;
|
|
7911
|
-
const
|
|
7912
|
-
|
|
7913
|
-
x:
|
|
7911
|
+
const Q = Math.round(h.centerX * 100) / 100;
|
|
7912
|
+
p <= a && !B.has(Q) && (f.push({
|
|
7913
|
+
x: Q,
|
|
7914
7914
|
visible: !0
|
|
7915
|
-
}), B.add(
|
|
7915
|
+
}), B.add(Q));
|
|
7916
7916
|
}), f;
|
|
7917
7917
|
}
|
|
7918
7918
|
function s() {
|
|
@@ -7920,7 +7920,7 @@ function IF(e = {}) {
|
|
|
7920
7920
|
n.value.horizontal = [], n.value.vertical = [];
|
|
7921
7921
|
return;
|
|
7922
7922
|
}
|
|
7923
|
-
const d = o(t.value),
|
|
7923
|
+
const d = o(t.value), U = A.value.filter((g) => g !== t.value), f = i(d, U), B = l(d, U);
|
|
7924
7924
|
n.value.horizontal = f, n.value.vertical = B;
|
|
7925
7925
|
}
|
|
7926
7926
|
function c() {
|
|
@@ -8315,7 +8315,7 @@ var qF = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
|
|
|
8315
8315
|
if (so === l && [so, dn, oo, io].indexOf(c) !== -1 || [dn, oo].indexOf(l) !== -1 && [dn, Bn].indexOf(c) !== -1 || [Bn, io].indexOf(l) !== -1 && c === Bn || yl.indexOf(l) !== -1 && [ml, qt].indexOf(c) !== -1 || yl.indexOf(c) !== -1 && l === $t || pe.indexOf(l) !== -1 && pe.indexOf(c) !== -1 || l === ut && pe.indexOf(c) !== -1 || pe.concat(KA).indexOf(l) !== -1 && c === Yt && iC.indexOf(e[i]) === -1 || pe.concat(KA).indexOf(c) !== -1 && l === Gt)
|
|
8316
8316
|
return AA;
|
|
8317
8317
|
if (l === ya && c === ya) {
|
|
8318
|
-
for (var
|
|
8318
|
+
for (var U = t[a], f = 1; U > 0 && (U--, A[U] === ya); )
|
|
8319
8319
|
f++;
|
|
8320
8320
|
if (f % 2 !== 0)
|
|
8321
8321
|
return AA;
|
|
@@ -8540,8 +8540,8 @@ var qF = "KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF
|
|
|
8540
8540
|
return this.consumeCodePoint(), this.consumeCodePoint(), BE;
|
|
8541
8541
|
break;
|
|
8542
8542
|
case yC:
|
|
8543
|
-
var u = this.peekCodePoint(0), d = this.peekCodePoint(1),
|
|
8544
|
-
if ($r(u, d,
|
|
8543
|
+
var u = this.peekCodePoint(0), d = this.peekCodePoint(1), U = this.peekCodePoint(2);
|
|
8544
|
+
if ($r(u, d, U)) {
|
|
8545
8545
|
var o = this.consumeName();
|
|
8546
8546
|
return { type: 7, value: o };
|
|
8547
8547
|
}
|
|
@@ -8968,8 +8968,8 @@ var Hl = function(e, A) {
|
|
|
8968
8968
|
var t = A.filter(Nt), r = t[0], n = t[1], a = t[2], o = t[3], i = (r.type === 17 ? Ae(r.number) : _n.parse(e, r)) / (Math.PI * 2), l = FA(n) ? n.number / 100 : 0, s = FA(a) ? a.number / 100 : 0, c = typeof o < "u" && FA(o) ? cA(o, 1) : 1;
|
|
8969
8969
|
if (l === 0)
|
|
8970
8970
|
return Ne(s * 255, s * 255, s * 255, 1);
|
|
8971
|
-
var u = s <= 0.5 ? s * (l + 1) : s + l - s * l, d = s * 2 - u,
|
|
8972
|
-
return Ne(
|
|
8971
|
+
var u = s <= 0.5 ? s * (l + 1) : s + l - s * l, d = s * 2 - u, U = Ia(d, u, i + 1 / 3), f = Ia(d, u, i), B = Ia(d, u, i - 1 / 3);
|
|
8972
|
+
return Ne(U * 255, f * 255, B * 255, c);
|
|
8973
8973
|
}, CE = {
|
|
8974
8974
|
hsl: Hl,
|
|
8975
8975
|
hsla: Hl,
|
|
@@ -9169,14 +9169,14 @@ var Hl = function(e, A) {
|
|
|
9169
9169
|
if (c === null)
|
|
9170
9170
|
s === null && (s = o);
|
|
9171
9171
|
else if (s !== null) {
|
|
9172
|
-
for (var u = o - s, d = n[s - 1],
|
|
9173
|
-
n[s + f - 1] =
|
|
9172
|
+
for (var u = o - s, d = n[s - 1], U = (c - d) / (u + 1), f = 1; f <= u; f++)
|
|
9173
|
+
n[s + f - 1] = U * f;
|
|
9174
9174
|
s = null;
|
|
9175
9175
|
}
|
|
9176
9176
|
}
|
|
9177
|
-
return e.map(function(B,
|
|
9178
|
-
var
|
|
9179
|
-
return { color:
|
|
9177
|
+
return e.map(function(B, g) {
|
|
9178
|
+
var h = B.color;
|
|
9179
|
+
return { color: h, stop: Math.max(Math.min(1, n[g] / A), 0) };
|
|
9180
9180
|
});
|
|
9181
9181
|
}, vE = function(e, A, t) {
|
|
9182
9182
|
var r = A / 2, n = t / 2, a = cA(e[0], A) - r, o = n - cA(e[1], t);
|
|
@@ -9295,9 +9295,9 @@ var Hl = function(e, A) {
|
|
|
9295
9295
|
} else if (c.name === "color-stop") {
|
|
9296
9296
|
var d = c.values.filter(Nt);
|
|
9297
9297
|
if (d.length === 2) {
|
|
9298
|
-
var u = be.parse(e, d[1]),
|
|
9299
|
-
Ot(
|
|
9300
|
-
stop: { type: 16, number:
|
|
9298
|
+
var u = be.parse(e, d[1]), U = d[0];
|
|
9299
|
+
Ot(U) && r.push({
|
|
9300
|
+
stop: { type: 16, number: U.number * 100, flags: U.flags },
|
|
9301
9301
|
color: u
|
|
9302
9302
|
});
|
|
9303
9303
|
}
|
|
@@ -11587,18 +11587,18 @@ var Fv = 1, Ma = 2, ba = 3, Gl = 4, Yl = 5, Cv = 7, zl = 8, Ha = 9, xa = 10, jl
|
|
|
11587
11587
|
d.src = u.value, d.style.opacity = "1", s.appendChild(d);
|
|
11588
11588
|
} else if (u.type === 18) {
|
|
11589
11589
|
if (u.name === "attr") {
|
|
11590
|
-
var
|
|
11591
|
-
|
|
11590
|
+
var U = u.values.filter(lA);
|
|
11591
|
+
U.length && s.appendChild(i.createTextNode(A.getAttribute(U[0].value) || ""));
|
|
11592
11592
|
} else if (u.name === "counter") {
|
|
11593
|
-
var f = u.values.filter(Nt), B = f[0],
|
|
11593
|
+
var f = u.values.filter(Nt), B = f[0], g = f[1];
|
|
11594
11594
|
if (B && lA(B)) {
|
|
11595
|
-
var
|
|
11596
|
-
s.appendChild(i.createTextNode(gr(
|
|
11595
|
+
var h = a.counters.getCounterValue(B.value), p = g && lA(g) ? ho.parse(a.context, g.value) : 3;
|
|
11596
|
+
s.appendChild(i.createTextNode(gr(h, p, !1)));
|
|
11597
11597
|
}
|
|
11598
11598
|
} else if (u.name === "counters") {
|
|
11599
|
-
var
|
|
11599
|
+
var Q = u.values.filter(Nt), B = Q[0], F = Q[1], g = Q[2];
|
|
11600
11600
|
if (B && lA(B)) {
|
|
11601
|
-
var v = a.counters.getCounterValues(B.value), C =
|
|
11601
|
+
var v = a.counters.getCounterValues(B.value), C = g && lA(g) ? ho.parse(a.context, g.value) : 3, T = F && F.type === 0 ? F.value : "", M = v.map(function(D) {
|
|
11602
11602
|
return gr(D, C, !1);
|
|
11603
11603
|
}).join(T);
|
|
11604
11604
|
s.appendChild(i.createTextNode(M));
|
|
@@ -11823,12 +11823,12 @@ var ly = function(e, A) {
|
|
|
11823
11823
|
/** @class */
|
|
11824
11824
|
function() {
|
|
11825
11825
|
function e(A) {
|
|
11826
|
-
var t = A.styles, r = A.bounds, n = Ar(t.borderTopLeftRadius, r.width, r.height), a = n[0], o = n[1], i = Ar(t.borderTopRightRadius, r.width, r.height), l = i[0], s = i[1], c = Ar(t.borderBottomRightRadius, r.width, r.height), u = c[0], d = c[1],
|
|
11827
|
-
|
|
11828
|
-
var
|
|
11829
|
-
|
|
11830
|
-
var
|
|
11831
|
-
this.topLeftBorderDoubleOuterBox = a > 0 || o > 0 ? BA(r.left + y / 3, r.top + C / 3, a - y / 3, o - C / 3, oA.TOP_LEFT) : new x(r.left + y / 3, r.top + C / 3), this.topRightBorderDoubleOuterBox = a > 0 || o > 0 ? BA(r.left +
|
|
11826
|
+
var t = A.styles, r = A.bounds, n = Ar(t.borderTopLeftRadius, r.width, r.height), a = n[0], o = n[1], i = Ar(t.borderTopRightRadius, r.width, r.height), l = i[0], s = i[1], c = Ar(t.borderBottomRightRadius, r.width, r.height), u = c[0], d = c[1], U = Ar(t.borderBottomLeftRadius, r.width, r.height), f = U[0], B = U[1], g = [];
|
|
11827
|
+
g.push((a + l) / r.width), g.push((f + u) / r.width), g.push((o + B) / r.height), g.push((s + d) / r.height);
|
|
11828
|
+
var h = Math.max.apply(Math, g);
|
|
11829
|
+
h > 1 && (a /= h, o /= h, l /= h, s /= h, u /= h, d /= h, f /= h, B /= h);
|
|
11830
|
+
var p = r.width - l, Q = r.height - d, F = r.width - u, v = r.height - B, C = t.borderTopWidth, T = t.borderRightWidth, M = t.borderBottomWidth, y = t.borderLeftWidth, S = cA(t.paddingTop, A.bounds.width), D = cA(t.paddingRight, A.bounds.width), L = cA(t.paddingBottom, A.bounds.width), b = cA(t.paddingLeft, A.bounds.width);
|
|
11831
|
+
this.topLeftBorderDoubleOuterBox = a > 0 || o > 0 ? BA(r.left + y / 3, r.top + C / 3, a - y / 3, o - C / 3, oA.TOP_LEFT) : new x(r.left + y / 3, r.top + C / 3), this.topRightBorderDoubleOuterBox = a > 0 || o > 0 ? BA(r.left + p, r.top + C / 3, l - T / 3, s - C / 3, oA.TOP_RIGHT) : new x(r.left + r.width - T / 3, r.top + C / 3), this.bottomRightBorderDoubleOuterBox = u > 0 || d > 0 ? BA(r.left + F, r.top + Q, u - T / 3, d - M / 3, oA.BOTTOM_RIGHT) : new x(r.left + r.width - T / 3, r.top + r.height - M / 3), this.bottomLeftBorderDoubleOuterBox = f > 0 || B > 0 ? BA(r.left + y / 3, r.top + v, f - y / 3, B - M / 3, oA.BOTTOM_LEFT) : new x(r.left + y / 3, r.top + r.height - M / 3), this.topLeftBorderDoubleInnerBox = a > 0 || o > 0 ? BA(r.left + y * 2 / 3, r.top + C * 2 / 3, a - y * 2 / 3, o - C * 2 / 3, oA.TOP_LEFT) : new x(r.left + y * 2 / 3, r.top + C * 2 / 3), this.topRightBorderDoubleInnerBox = a > 0 || o > 0 ? BA(r.left + p, r.top + C * 2 / 3, l - T * 2 / 3, s - C * 2 / 3, oA.TOP_RIGHT) : new x(r.left + r.width - T * 2 / 3, r.top + C * 2 / 3), this.bottomRightBorderDoubleInnerBox = u > 0 || d > 0 ? BA(r.left + F, r.top + Q, u - T * 2 / 3, d - M * 2 / 3, oA.BOTTOM_RIGHT) : new x(r.left + r.width - T * 2 / 3, r.top + r.height - M * 2 / 3), this.bottomLeftBorderDoubleInnerBox = f > 0 || B > 0 ? BA(r.left + y * 2 / 3, r.top + v, f - y * 2 / 3, B - M * 2 / 3, oA.BOTTOM_LEFT) : new x(r.left + y * 2 / 3, r.top + r.height - M * 2 / 3), this.topLeftBorderStroke = a > 0 || o > 0 ? BA(r.left + y / 2, r.top + C / 2, a - y / 2, o - C / 2, oA.TOP_LEFT) : new x(r.left + y / 2, r.top + C / 2), this.topRightBorderStroke = a > 0 || o > 0 ? BA(r.left + p, r.top + C / 2, l - T / 2, s - C / 2, oA.TOP_RIGHT) : new x(r.left + r.width - T / 2, r.top + C / 2), this.bottomRightBorderStroke = u > 0 || d > 0 ? BA(r.left + F, r.top + Q, u - T / 2, d - M / 2, oA.BOTTOM_RIGHT) : new x(r.left + r.width - T / 2, r.top + r.height - M / 2), this.bottomLeftBorderStroke = f > 0 || B > 0 ? BA(r.left + y / 2, r.top + v, f - y / 2, B - M / 2, oA.BOTTOM_LEFT) : new x(r.left + y / 2, r.top + r.height - M / 2), this.topLeftBorderBox = a > 0 || o > 0 ? BA(r.left, r.top, a, o, oA.TOP_LEFT) : new x(r.left, r.top), this.topRightBorderBox = l > 0 || s > 0 ? BA(r.left + p, r.top, l, s, oA.TOP_RIGHT) : new x(r.left + r.width, r.top), this.bottomRightBorderBox = u > 0 || d > 0 ? BA(r.left + F, r.top + Q, u, d, oA.BOTTOM_RIGHT) : new x(r.left + r.width, r.top + r.height), this.bottomLeftBorderBox = f > 0 || B > 0 ? BA(r.left, r.top + v, f, B, oA.BOTTOM_LEFT) : new x(r.left, r.top + r.height), this.topLeftPaddingBox = a > 0 || o > 0 ? BA(r.left + y, r.top + C, Math.max(0, a - y), Math.max(0, o - C), oA.TOP_LEFT) : new x(r.left + y, r.top + C), this.topRightPaddingBox = l > 0 || s > 0 ? BA(r.left + Math.min(p, r.width - T), r.top + C, p > r.width + T ? 0 : Math.max(0, l - T), Math.max(0, s - C), oA.TOP_RIGHT) : new x(r.left + r.width - T, r.top + C), this.bottomRightPaddingBox = u > 0 || d > 0 ? BA(r.left + Math.min(F, r.width - y), r.top + Math.min(Q, r.height - M), Math.max(0, u - T), Math.max(0, d - M), oA.BOTTOM_RIGHT) : new x(r.left + r.width - T, r.top + r.height - M), this.bottomLeftPaddingBox = f > 0 || B > 0 ? BA(r.left + y, r.top + Math.min(v, r.height - M), Math.max(0, f - y), Math.max(0, B - M), oA.BOTTOM_LEFT) : new x(r.left + y, r.top + r.height - M), this.topLeftContentBox = a > 0 || o > 0 ? BA(r.left + y + b, r.top + C + S, Math.max(0, a - (y + b)), Math.max(0, o - (C + S)), oA.TOP_LEFT) : new x(r.left + y + b, r.top + C + S), this.topRightContentBox = l > 0 || s > 0 ? BA(r.left + Math.min(p, r.width + y + b), r.top + C + S, p > r.width + y + b ? 0 : l - y + b, s - (C + S), oA.TOP_RIGHT) : new x(r.left + r.width - (T + D), r.top + C + S), this.bottomRightContentBox = u > 0 || d > 0 ? BA(r.left + Math.min(F, r.width - (y + b)), r.top + Math.min(Q, r.height + C + S), Math.max(0, u - (T + D)), d - (M + L), oA.BOTTOM_RIGHT) : new x(r.left + r.width - (T + D), r.top + r.height - (M + L)), this.bottomLeftContentBox = f > 0 || B > 0 ? BA(r.left + y + b, r.top + v, Math.max(0, f - (y + b)), B - (M + L), oA.BOTTOM_LEFT) : new x(r.left + y + b, r.top + r.height - (M + L));
|
|
11832
11832
|
}
|
|
11833
11833
|
return e;
|
|
11834
11834
|
}()
|
|
@@ -12008,10 +12008,10 @@ var BA = function(e, A, t, r, n) {
|
|
|
12008
12008
|
return u > f.element.container.styles.zIndex.order ? (d = B, !1) : d > 0;
|
|
12009
12009
|
}), s.negativeZIndex.splice(d, 0, c);
|
|
12010
12010
|
} else if (u > 0) {
|
|
12011
|
-
var
|
|
12011
|
+
var U = 0;
|
|
12012
12012
|
s.positiveZIndex.some(function(f, B) {
|
|
12013
|
-
return u >= f.element.container.styles.zIndex.order ? (
|
|
12014
|
-
}), s.positiveZIndex.splice(
|
|
12013
|
+
return u >= f.element.container.styles.zIndex.order ? (U = B + 1, !1) : U > 0;
|
|
12014
|
+
}), s.positiveZIndex.splice(U, 0, c);
|
|
12015
12015
|
} else
|
|
12016
12016
|
s.zeroOrAutoZIndexOrTransformedOrOpacity.push(c);
|
|
12017
12017
|
} else
|
|
@@ -12125,19 +12125,19 @@ var BA = function(e, A, t, r, n) {
|
|
|
12125
12125
|
if (!l && !d)
|
|
12126
12126
|
return [t.width, t.height];
|
|
12127
12127
|
if (d && l) {
|
|
12128
|
-
var
|
|
12129
|
-
return [
|
|
12128
|
+
var U = c ? r : n * a, f = u ? n : r / a;
|
|
12129
|
+
return [U, f];
|
|
12130
12130
|
}
|
|
12131
|
-
var B = c ? r : t.width,
|
|
12132
|
-
return [B,
|
|
12131
|
+
var B = c ? r : t.width, g = u ? n : t.height;
|
|
12132
|
+
return [B, g];
|
|
12133
12133
|
}
|
|
12134
12134
|
if (l) {
|
|
12135
|
-
var
|
|
12136
|
-
return FA(o) ?
|
|
12135
|
+
var h = 0, p = 0;
|
|
12136
|
+
return FA(o) ? h = cA(o, t.width) : FA(i) && (p = cA(i, t.height)), gt(o) ? h = p * a : (!i || gt(i)) && (p = h / a), [h, p];
|
|
12137
12137
|
}
|
|
12138
|
-
var
|
|
12139
|
-
if (FA(o) ?
|
|
12140
|
-
return [
|
|
12138
|
+
var Q = null, F = null;
|
|
12139
|
+
if (FA(o) ? Q = cA(o, t.width) : i && FA(i) && (F = cA(i, t.height)), Q !== null && (!i || gt(i)) && (F = c && u ? Q / r * n : t.height), F !== null && gt(o) && (Q = c && u ? F / n * r : t.width), Q !== null && F !== null)
|
|
12140
|
+
return [Q, F];
|
|
12141
12141
|
throw new Error("Unable to calculate background-size for element");
|
|
12142
12142
|
}, pt = function(e, A) {
|
|
12143
12143
|
var t = e[A];
|
|
@@ -12281,17 +12281,17 @@ var BA = function(e, A, t, r, n) {
|
|
|
12281
12281
|
}, A.prototype.renderTextNode = function(t, r) {
|
|
12282
12282
|
return kA(this, void 0, void 0, function() {
|
|
12283
12283
|
var n, a, o, i, l, s, c, u, d = this;
|
|
12284
|
-
return MA(this, function(
|
|
12284
|
+
return MA(this, function(U) {
|
|
12285
12285
|
return n = this.createFontStyle(r), a = n[0], o = n[1], i = n[2], this.ctx.font = a, this.ctx.direction = r.direction === 1 ? "rtl" : "ltr", this.ctx.textAlign = "left", this.ctx.textBaseline = "alphabetic", l = this.fontMetrics.getMetrics(o, i), s = l.baseline, c = l.middle, u = r.paintOrder, t.textBounds.forEach(function(f) {
|
|
12286
12286
|
u.forEach(function(B) {
|
|
12287
12287
|
switch (B) {
|
|
12288
12288
|
case 0:
|
|
12289
12289
|
d.ctx.fillStyle = vA(r.color), d.renderTextWithLetterSpacing(f, r.letterSpacing, s);
|
|
12290
|
-
var
|
|
12291
|
-
|
|
12292
|
-
d.ctx.shadowColor = vA(
|
|
12293
|
-
}), d.ctx.shadowColor = "", d.ctx.shadowOffsetX = 0, d.ctx.shadowOffsetY = 0, d.ctx.shadowBlur = 0), r.textDecorationLine.length && (d.ctx.fillStyle = vA(r.textDecorationColor || r.color), r.textDecorationLine.forEach(function(
|
|
12294
|
-
switch (
|
|
12290
|
+
var g = r.textShadow;
|
|
12291
|
+
g.length && f.text.trim().length && (g.slice(0).reverse().forEach(function(h) {
|
|
12292
|
+
d.ctx.shadowColor = vA(h.color), d.ctx.shadowOffsetX = h.offsetX.number * d.options.scale, d.ctx.shadowOffsetY = h.offsetY.number * d.options.scale, d.ctx.shadowBlur = h.blur.number, d.renderTextWithLetterSpacing(f, r.letterSpacing, s);
|
|
12293
|
+
}), d.ctx.shadowColor = "", d.ctx.shadowOffsetX = 0, d.ctx.shadowOffsetY = 0, d.ctx.shadowBlur = 0), r.textDecorationLine.length && (d.ctx.fillStyle = vA(r.textDecorationColor || r.color), r.textDecorationLine.forEach(function(h) {
|
|
12294
|
+
switch (h) {
|
|
12295
12295
|
case 1:
|
|
12296
12296
|
d.ctx.fillRect(f.bounds.left, Math.round(f.bounds.top + s), f.bounds.width, 1);
|
|
12297
12297
|
break;
|
|
@@ -12322,7 +12322,7 @@ var BA = function(e, A, t, r, n) {
|
|
|
12322
12322
|
}
|
|
12323
12323
|
}, A.prototype.renderNodeContent = function(t) {
|
|
12324
12324
|
return kA(this, void 0, void 0, function() {
|
|
12325
|
-
var r, n, a, o, i, l,
|
|
12325
|
+
var r, n, a, o, i, l, p, p, s, c, u, d, F, U, f, v, B, g, h, p, Q, F, v;
|
|
12326
12326
|
return MA(this, function(C) {
|
|
12327
12327
|
switch (C.label) {
|
|
12328
12328
|
case 0:
|
|
@@ -12343,7 +12343,7 @@ var BA = function(e, A, t, r, n) {
|
|
|
12343
12343
|
case 5:
|
|
12344
12344
|
return C.trys.push([5, 7, , 8]), [4, this.context.cache.match(r.src)];
|
|
12345
12345
|
case 6:
|
|
12346
|
-
return
|
|
12346
|
+
return p = C.sent(), this.renderReplacedElement(r, n, p), [3, 8];
|
|
12347
12347
|
case 7:
|
|
12348
12348
|
return C.sent(), this.context.logger.error("Error loading image " + r.src), [3, 8];
|
|
12349
12349
|
case 8:
|
|
@@ -12353,7 +12353,7 @@ var BA = function(e, A, t, r, n) {
|
|
|
12353
12353
|
case 9:
|
|
12354
12354
|
return C.trys.push([9, 11, , 12]), [4, this.context.cache.match(r.svg)];
|
|
12355
12355
|
case 10:
|
|
12356
|
-
return
|
|
12356
|
+
return p = C.sent(), this.renderReplacedElement(r, n, p), [3, 12];
|
|
12357
12357
|
case 11:
|
|
12358
12358
|
return C.sent(), this.context.logger.error("Error loading svg " + r.svg.substring(0, 255)), [3, 12];
|
|
12359
12359
|
case 12:
|
|
@@ -12377,7 +12377,7 @@ var BA = function(e, A, t, r, n) {
|
|
|
12377
12377
|
new x(r.bounds.left + u * 0.84, r.bounds.top + u * 0.34085),
|
|
12378
12378
|
new x(r.bounds.left + u * 0.39363, r.bounds.top + u * 0.79)
|
|
12379
12379
|
]), this.ctx.fillStyle = vA(es), this.ctx.fill(), this.ctx.restore()) : r.type === yn && r.checked && (this.ctx.save(), this.ctx.beginPath(), this.ctx.arc(r.bounds.left + u / 2, r.bounds.top + u / 2, u / 4, 0, Math.PI * 2, !0), this.ctx.fillStyle = vA(es), this.ctx.fill(), this.ctx.restore())), Yy(r) && r.value.length) {
|
|
12380
|
-
switch (d = this.createFontStyle(a), F = d[0],
|
|
12380
|
+
switch (d = this.createFontStyle(a), F = d[0], U = d[1], f = this.fontMetrics.getMetrics(F, U).baseline, this.ctx.font = F, this.ctx.fillStyle = vA(a.color), this.ctx.textBaseline = "alphabetic", this.ctx.textAlign = jy(r.styles.textAlign), v = Nn(r), B = 0, r.styles.textAlign) {
|
|
12381
12381
|
case 1:
|
|
12382
12382
|
B += v.width / 2;
|
|
12383
12383
|
break;
|
|
@@ -12385,12 +12385,12 @@ var BA = function(e, A, t, r, n) {
|
|
|
12385
12385
|
B += v.width;
|
|
12386
12386
|
break;
|
|
12387
12387
|
}
|
|
12388
|
-
|
|
12388
|
+
g = v.add(B, 0, 0, -v.height / 2 + 1), this.ctx.save(), this.path([
|
|
12389
12389
|
new x(v.left, v.top),
|
|
12390
12390
|
new x(v.left + v.width, v.top),
|
|
12391
12391
|
new x(v.left + v.width, v.top + v.height),
|
|
12392
12392
|
new x(v.left, v.top + v.height)
|
|
12393
|
-
]), this.ctx.clip(), this.renderTextWithLetterSpacing(new ir(r.value,
|
|
12393
|
+
]), this.ctx.clip(), this.renderTextWithLetterSpacing(new ir(r.value, g), a.letterSpacing, f), this.ctx.restore(), this.ctx.textBaseline = "alphabetic", this.ctx.textAlign = "left";
|
|
12394
12394
|
}
|
|
12395
12395
|
if (!mA(
|
|
12396
12396
|
r.styles.display,
|
|
@@ -12400,15 +12400,15 @@ var BA = function(e, A, t, r, n) {
|
|
|
12400
12400
|
return [3, 20];
|
|
12401
12401
|
if (r.styles.listStyleImage === null)
|
|
12402
12402
|
return [3, 19];
|
|
12403
|
-
if (
|
|
12403
|
+
if (h = r.styles.listStyleImage, h.type !== 0)
|
|
12404
12404
|
return [3, 18];
|
|
12405
|
-
|
|
12405
|
+
p = void 0, Q = h.url, C.label = 15;
|
|
12406
12406
|
case 15:
|
|
12407
|
-
return C.trys.push([15, 17, , 18]), [4, this.context.cache.match(
|
|
12407
|
+
return C.trys.push([15, 17, , 18]), [4, this.context.cache.match(Q)];
|
|
12408
12408
|
case 16:
|
|
12409
|
-
return
|
|
12409
|
+
return p = C.sent(), this.ctx.drawImage(p, r.bounds.left - (p.width + 10), r.bounds.top), [3, 18];
|
|
12410
12410
|
case 17:
|
|
12411
|
-
return C.sent(), this.context.logger.error("Error loading list-style-image " +
|
|
12411
|
+
return C.sent(), this.context.logger.error("Error loading list-style-image " + Q), [3, 18];
|
|
12412
12412
|
case 18:
|
|
12413
12413
|
return [3, 20];
|
|
12414
12414
|
case 19:
|
|
@@ -12423,9 +12423,9 @@ var BA = function(e, A, t, r, n) {
|
|
|
12423
12423
|
});
|
|
12424
12424
|
}, A.prototype.renderStackContent = function(t) {
|
|
12425
12425
|
return kA(this, void 0, void 0, function() {
|
|
12426
|
-
var r, n,
|
|
12427
|
-
return MA(this, function(
|
|
12428
|
-
switch (
|
|
12426
|
+
var r, n, h, a, o, h, i, l, h, s, c, h, u, d, h, U, f, h, B, g, h;
|
|
12427
|
+
return MA(this, function(p) {
|
|
12428
|
+
switch (p.label) {
|
|
12429
12429
|
case 0:
|
|
12430
12430
|
if (mA(
|
|
12431
12431
|
t.element.container.flags,
|
|
@@ -12435,61 +12435,61 @@ var BA = function(e, A, t, r, n) {
|
|
|
12435
12435
|
debugger;
|
|
12436
12436
|
return [4, this.renderNodeBackgroundAndBorders(t.element)];
|
|
12437
12437
|
case 1:
|
|
12438
|
-
|
|
12438
|
+
p.sent(), r = 0, n = t.negativeZIndex, p.label = 2;
|
|
12439
12439
|
case 2:
|
|
12440
|
-
return r < n.length ? (
|
|
12440
|
+
return r < n.length ? (h = n[r], [4, this.renderStack(h)]) : [3, 5];
|
|
12441
12441
|
case 3:
|
|
12442
|
-
|
|
12442
|
+
p.sent(), p.label = 4;
|
|
12443
12443
|
case 4:
|
|
12444
12444
|
return r++, [3, 2];
|
|
12445
12445
|
case 5:
|
|
12446
12446
|
return [4, this.renderNodeContent(t.element)];
|
|
12447
12447
|
case 6:
|
|
12448
|
-
|
|
12448
|
+
p.sent(), a = 0, o = t.nonInlineLevel, p.label = 7;
|
|
12449
12449
|
case 7:
|
|
12450
|
-
return a < o.length ? (
|
|
12450
|
+
return a < o.length ? (h = o[a], [4, this.renderNode(h)]) : [3, 10];
|
|
12451
12451
|
case 8:
|
|
12452
|
-
|
|
12452
|
+
p.sent(), p.label = 9;
|
|
12453
12453
|
case 9:
|
|
12454
12454
|
return a++, [3, 7];
|
|
12455
12455
|
case 10:
|
|
12456
|
-
i = 0, l = t.nonPositionedFloats,
|
|
12456
|
+
i = 0, l = t.nonPositionedFloats, p.label = 11;
|
|
12457
12457
|
case 11:
|
|
12458
|
-
return i < l.length ? (
|
|
12458
|
+
return i < l.length ? (h = l[i], [4, this.renderStack(h)]) : [3, 14];
|
|
12459
12459
|
case 12:
|
|
12460
|
-
|
|
12460
|
+
p.sent(), p.label = 13;
|
|
12461
12461
|
case 13:
|
|
12462
12462
|
return i++, [3, 11];
|
|
12463
12463
|
case 14:
|
|
12464
|
-
s = 0, c = t.nonPositionedInlineLevel,
|
|
12464
|
+
s = 0, c = t.nonPositionedInlineLevel, p.label = 15;
|
|
12465
12465
|
case 15:
|
|
12466
|
-
return s < c.length ? (
|
|
12466
|
+
return s < c.length ? (h = c[s], [4, this.renderStack(h)]) : [3, 18];
|
|
12467
12467
|
case 16:
|
|
12468
|
-
|
|
12468
|
+
p.sent(), p.label = 17;
|
|
12469
12469
|
case 17:
|
|
12470
12470
|
return s++, [3, 15];
|
|
12471
12471
|
case 18:
|
|
12472
|
-
u = 0, d = t.inlineLevel,
|
|
12472
|
+
u = 0, d = t.inlineLevel, p.label = 19;
|
|
12473
12473
|
case 19:
|
|
12474
|
-
return u < d.length ? (
|
|
12474
|
+
return u < d.length ? (h = d[u], [4, this.renderNode(h)]) : [3, 22];
|
|
12475
12475
|
case 20:
|
|
12476
|
-
|
|
12476
|
+
p.sent(), p.label = 21;
|
|
12477
12477
|
case 21:
|
|
12478
12478
|
return u++, [3, 19];
|
|
12479
12479
|
case 22:
|
|
12480
|
-
|
|
12480
|
+
U = 0, f = t.zeroOrAutoZIndexOrTransformedOrOpacity, p.label = 23;
|
|
12481
12481
|
case 23:
|
|
12482
|
-
return
|
|
12482
|
+
return U < f.length ? (h = f[U], [4, this.renderStack(h)]) : [3, 26];
|
|
12483
12483
|
case 24:
|
|
12484
|
-
|
|
12484
|
+
p.sent(), p.label = 25;
|
|
12485
12485
|
case 25:
|
|
12486
|
-
return
|
|
12486
|
+
return U++, [3, 23];
|
|
12487
12487
|
case 26:
|
|
12488
|
-
B = 0,
|
|
12488
|
+
B = 0, g = t.positiveZIndex, p.label = 27;
|
|
12489
12489
|
case 27:
|
|
12490
|
-
return B <
|
|
12490
|
+
return B < g.length ? (h = g[B], [4, this.renderStack(h)]) : [3, 30];
|
|
12491
12491
|
case 28:
|
|
12492
|
-
|
|
12492
|
+
p.sent(), p.label = 29;
|
|
12493
12493
|
case 29:
|
|
12494
12494
|
return B++, [3, 27];
|
|
12495
12495
|
case 30:
|
|
@@ -12527,7 +12527,7 @@ var BA = function(e, A, t, r, n) {
|
|
|
12527
12527
|
switch (s.label) {
|
|
12528
12528
|
case 0:
|
|
12529
12529
|
r = t.styles.backgroundImage.length - 1, n = function(c) {
|
|
12530
|
-
var u, d,
|
|
12530
|
+
var u, d, U, S, G, _, b, P, M, f, S, G, _, b, P, B, g, h, p, Q, F, v, C, T, M, y, S, D, L, b, P, iA, G, _, rA, fA, uA, aA, X, z, NA, QA;
|
|
12531
12531
|
return MA(this, function(hA) {
|
|
12532
12532
|
switch (hA.label) {
|
|
12533
12533
|
case 0:
|
|
@@ -12541,13 +12541,13 @@ var BA = function(e, A, t, r, n) {
|
|
|
12541
12541
|
case 3:
|
|
12542
12542
|
return hA.sent(), a.context.logger.error("Error loading background-image " + d), [3, 4];
|
|
12543
12543
|
case 4:
|
|
12544
|
-
return u && (
|
|
12544
|
+
return u && (U = Ka(t, r, [
|
|
12545
12545
|
u.width,
|
|
12546
12546
|
u.height,
|
|
12547
12547
|
u.width / u.height
|
|
12548
|
-
]), S =
|
|
12548
|
+
]), S = U[0], G = U[1], _ = U[2], b = U[3], P = U[4], M = a.ctx.createPattern(a.resizeImage(u, b, P), "repeat"), a.renderRepeat(S, M, G, _)), [3, 6];
|
|
12549
12549
|
case 5:
|
|
12550
|
-
NE(c) ? (f = Ka(t, r, [null, null, null]), S = f[0], G = f[1], _ = f[2], b = f[3], P = f[4], B = yE(c.angle, b, P),
|
|
12550
|
+
NE(c) ? (f = Ka(t, r, [null, null, null]), S = f[0], G = f[1], _ = f[2], b = f[3], P = f[4], B = yE(c.angle, b, P), g = B[0], h = B[1], p = B[2], Q = B[3], F = B[4], v = document.createElement("canvas"), v.width = b, v.height = P, C = v.getContext("2d"), T = C.createLinearGradient(h, Q, p, F), xl(c.stops, g).forEach(function(gA) {
|
|
12551
12551
|
return T.addColorStop(gA.stop, vA(gA.color));
|
|
12552
12552
|
}), C.fillStyle = T, C.fillRect(0, 0, b, P), b > 0 && P > 0 && (M = a.ctx.createPattern(v, "repeat"), a.renderRepeat(S, M, G, _))) : SE(c) && (y = Ka(t, r, [
|
|
12553
12553
|
null,
|
|
@@ -12623,10 +12623,10 @@ var BA = function(e, A, t, r, n) {
|
|
|
12623
12623
|
{ style: r.borderLeftStyle, color: r.borderLeftColor, width: r.borderLeftWidth }
|
|
12624
12624
|
], o = zy(pt(r.backgroundClip, 0), t.curves), n || r.boxShadow.length ? (this.ctx.save(), this.path(o), this.ctx.clip(), He(r.backgroundColor) || (this.ctx.fillStyle = vA(r.backgroundColor), this.ctx.fill()), [4, this.renderBackgroundImage(t.container)]) : [3, 2];
|
|
12625
12625
|
case 1:
|
|
12626
|
-
d.sent(), this.ctx.restore(), r.boxShadow.slice(0).reverse().forEach(function(
|
|
12626
|
+
d.sent(), this.ctx.restore(), r.boxShadow.slice(0).reverse().forEach(function(U) {
|
|
12627
12627
|
u.ctx.save();
|
|
12628
|
-
var f = Tn(t.curves), B =
|
|
12629
|
-
|
|
12628
|
+
var f = Tn(t.curves), B = U.inset ? 0 : Ly, g = My(f, -B + (U.inset ? 1 : -1) * U.spread.number, (U.inset ? 1 : -1) * U.spread.number, U.spread.number * (U.inset ? -2 : 2), U.spread.number * (U.inset ? -2 : 2));
|
|
12629
|
+
U.inset ? (u.path(f), u.ctx.clip(), u.mask(g)) : (u.mask(f), u.ctx.clip(), u.path(g)), u.ctx.shadowOffsetX = U.offsetX.number + B, u.ctx.shadowOffsetY = U.offsetY.number, u.ctx.shadowColor = vA(U.color), u.ctx.shadowBlur = U.blur.number, u.ctx.fillStyle = U.inset ? vA(U.color) : "rgba(0,0,0,1)", u.ctx.fill(), u.ctx.restore();
|
|
12630
12630
|
}), d.label = 2;
|
|
12631
12631
|
case 2:
|
|
12632
12632
|
i = 0, l = 0, s = a, d.label = 3;
|
|
@@ -12674,9 +12674,9 @@ var BA = function(e, A, t, r, n) {
|
|
|
12674
12674
|
});
|
|
12675
12675
|
}, A.prototype.renderDashedDottedBorder = function(t, r, n, a, o) {
|
|
12676
12676
|
return kA(this, void 0, void 0, function() {
|
|
12677
|
-
var i, l, s, c, u, d,
|
|
12677
|
+
var i, l, s, c, u, d, U, f, B, g, h, p, Q, F, v, C, v, C;
|
|
12678
12678
|
return MA(this, function(T) {
|
|
12679
|
-
return this.ctx.save(), i = Zy(a, n), l = Bs(a, n), o === 2 && (this.path(l), this.ctx.clip()), qA(l[0]) ? (s = l[0].start.x, c = l[0].start.y) : (s = l[0].x, c = l[0].y), qA(l[1]) ? (u = l[1].end.x, d = l[1].end.y) : (u = l[1].x, d = l[1].y), n === 0 || n === 2 ?
|
|
12679
|
+
return this.ctx.save(), i = Zy(a, n), l = Bs(a, n), o === 2 && (this.path(l), this.ctx.clip()), qA(l[0]) ? (s = l[0].start.x, c = l[0].start.y) : (s = l[0].x, c = l[0].y), qA(l[1]) ? (u = l[1].end.x, d = l[1].end.y) : (u = l[1].x, d = l[1].y), n === 0 || n === 2 ? U = Math.abs(s - u) : U = Math.abs(c - d), this.ctx.beginPath(), o === 3 ? this.formatPath(i) : this.formatPath(l.slice(0, 2)), f = r < 3 ? r * 3 : r * 2, B = r < 3 ? r * 2 : r, o === 3 && (f = r, B = r), g = !0, U <= f * 2 ? g = !1 : U <= f * 2 + B ? (h = U / (2 * f + B), f *= h, B *= h) : (p = Math.floor((U + B) / (f + B)), Q = (U - p * f) / (p - 1), F = (U - (p + 1) * f) / p, B = F <= 0 || Math.abs(B - Q) < Math.abs(B - F) ? Q : F), g && (o === 3 ? this.ctx.setLineDash([0, f + B]) : this.ctx.setLineDash([f, B])), o === 3 ? (this.ctx.lineCap = "round", this.ctx.lineWidth = r) : this.ctx.lineWidth = r * 2 + 1.1, this.ctx.strokeStyle = vA(t), this.ctx.stroke(), this.ctx.setLineDash([]), o === 2 && (qA(l[0]) && (v = l[3], C = l[0], this.ctx.beginPath(), this.formatPath([new x(v.end.x, v.end.y), new x(C.start.x, C.start.y)]), this.ctx.stroke()), qA(l[1]) && (v = l[1], C = l[2], this.ctx.beginPath(), this.formatPath([new x(v.end.x, v.end.y), new x(C.start.x, C.start.y)]), this.ctx.stroke())), this.ctx.restore(), [
|
|
12680
12680
|
2
|
|
12681
12681
|
/*return*/
|
|
12682
12682
|
];
|
|
@@ -12793,7 +12793,7 @@ var BA = function(e, A, t, r, n) {
|
|
|
12793
12793
|
typeof window < "u" && Su.setContext(window);
|
|
12794
12794
|
var tR = function(e, A) {
|
|
12795
12795
|
return kA(void 0, void 0, void 0, function() {
|
|
12796
|
-
var t, r, n, a, o, i, l, s, c, u, d,
|
|
12796
|
+
var t, r, n, a, o, i, l, s, c, u, d, U, f, B, g, h, p, Q, F, v, T, C, T, M, y, S, D, L, b, P, iA, G, _, rA, fA, uA, aA, X, z, NA;
|
|
12797
12797
|
return MA(this, function(QA) {
|
|
12798
12798
|
switch (QA.label) {
|
|
12799
12799
|
case 0:
|
|
@@ -12821,23 +12821,23 @@ var tR = function(e, A) {
|
|
|
12821
12821
|
copyStyles: s
|
|
12822
12822
|
}, l.logger.debug("Starting document clone with size " + i.width + "x" + i.height + " scrolled to " + -i.left + "," + -i.top), u = new cs(l, e, c), d = u.clonedReferenceElement, d ? [4, u.toIFrame(t, i)] : [2, Promise.reject("Unable to find element in cloned iframe")];
|
|
12823
12823
|
case 1:
|
|
12824
|
-
return
|
|
12824
|
+
return U = QA.sent(), f = Ci(d) || ry(d) ? MF(d.ownerDocument) : Xn(l, d), B = f.width, g = f.height, h = f.left, p = f.top, Q = rR(l, d, A.backgroundColor), F = {
|
|
12825
12825
|
canvas: A.canvas,
|
|
12826
|
-
backgroundColor:
|
|
12826
|
+
backgroundColor: Q,
|
|
12827
12827
|
scale: (fA = (rA = A.scale) !== null && rA !== void 0 ? rA : r.devicePixelRatio) !== null && fA !== void 0 ? fA : 1,
|
|
12828
|
-
x: ((uA = A.x) !== null && uA !== void 0 ? uA : 0) +
|
|
12829
|
-
y: ((aA = A.y) !== null && aA !== void 0 ? aA : 0) +
|
|
12828
|
+
x: ((uA = A.x) !== null && uA !== void 0 ? uA : 0) + h,
|
|
12829
|
+
y: ((aA = A.y) !== null && aA !== void 0 ? aA : 0) + p,
|
|
12830
12830
|
width: (X = A.width) !== null && X !== void 0 ? X : Math.ceil(B),
|
|
12831
|
-
height: (z = A.height) !== null && z !== void 0 ? z : Math.ceil(
|
|
12831
|
+
height: (z = A.height) !== null && z !== void 0 ? z : Math.ceil(g)
|
|
12832
12832
|
}, s ? (l.logger.debug("Document cloned, using foreign object rendering"), T = new _y(l, F), [4, T.render(d)]) : [3, 3];
|
|
12833
12833
|
case 2:
|
|
12834
12834
|
return v = QA.sent(), [3, 5];
|
|
12835
12835
|
case 3:
|
|
12836
|
-
return l.logger.debug("Document cloned, element located at " +
|
|
12836
|
+
return l.logger.debug("Document cloned, element located at " + h + "," + p + " with size " + B + "x" + g + " using computed rendering"), l.logger.debug("Starting DOM parsing"), C = mu(l, d), Q === C.styles.backgroundColor && (C.styles.backgroundColor = Ce.TRANSPARENT), l.logger.debug("Starting renderer for element at " + F.x + "," + F.y + " with size " + F.width + "x" + F.height), T = new Gy(l, F), [4, T.render(C)];
|
|
12837
12837
|
case 4:
|
|
12838
12838
|
v = QA.sent(), QA.label = 5;
|
|
12839
12839
|
case 5:
|
|
12840
|
-
return (!((NA = A.removeContainer) !== null && NA !== void 0) || NA) && (cs.destroy(
|
|
12840
|
+
return (!((NA = A.removeContainer) !== null && NA !== void 0) || NA) && (cs.destroy(U) || l.logger.error("Cannot detach cloned iframe as it is not in the DOM anymore")), l.logger.debug("Finished rendering"), [2, v];
|
|
12841
12841
|
}
|
|
12842
12842
|
});
|
|
12843
12843
|
});
|
|
@@ -12907,11 +12907,11 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
12907
12907
|
return ((E = r.value) == null ? void 0 : E.printHeight) || 0;
|
|
12908
12908
|
});
|
|
12909
12909
|
k(!1);
|
|
12910
|
-
const c = k(!1), u = k(!1), d = k(/* @__PURE__ */ new Map()),
|
|
12910
|
+
const c = k(!1), u = k(!1), d = k(/* @__PURE__ */ new Map()), U = k(/* @__PURE__ */ new Map()), f = new Map(Hc.map((E) => [E.type, E])), { selectedItems: B, selectItem: g, getCurrentSelected: h, clearSelection: p } = vF(), { dragging: Q, dragItem: F, startDrag: v } = EF({
|
|
12911
12911
|
scale: o,
|
|
12912
12912
|
canvasWidth: l,
|
|
12913
12913
|
canvasHeight: s,
|
|
12914
|
-
selectItem:
|
|
12914
|
+
selectItem: g,
|
|
12915
12915
|
onStartDrag: () => {
|
|
12916
12916
|
c.value = !0;
|
|
12917
12917
|
},
|
|
@@ -12926,15 +12926,15 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
12926
12926
|
}), { alignmentGuides: C, showGuides: T, updateAlignmentGuides: M, clearAlignmentGuides: y } = IF({
|
|
12927
12927
|
items: a,
|
|
12928
12928
|
dragItem: F,
|
|
12929
|
-
dragging:
|
|
12929
|
+
dragging: Q
|
|
12930
12930
|
}), { startResize: S } = mF(l, s, o, B), { startRotate: D } = yF();
|
|
12931
12931
|
CA(() => B.value, () => {
|
|
12932
12932
|
d.value.clear();
|
|
12933
12933
|
}, { deep: !0 });
|
|
12934
12934
|
const L = (E) => {
|
|
12935
12935
|
const w = `${E.id}_${E.props.x.toFixed(1)}_${E.props.y.toFixed(1)}_${E.props.width}_${E.props.height}_${E.props.rotation}`;
|
|
12936
|
-
if (
|
|
12937
|
-
return
|
|
12936
|
+
if (U.value.has(w))
|
|
12937
|
+
return U.value.get(w);
|
|
12938
12938
|
const q = (E.props.rotation || 0) * Math.PI / 180, K = [
|
|
12939
12939
|
{ x: 0, y: 0 },
|
|
12940
12940
|
// top-left
|
|
@@ -12951,9 +12951,9 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
12951
12951
|
y: Number((Je + Y + E.props.y).toFixed(2))
|
|
12952
12952
|
};
|
|
12953
12953
|
});
|
|
12954
|
-
if (
|
|
12955
|
-
const R =
|
|
12956
|
-
|
|
12954
|
+
if (U.value.set(w, eA), U.value.size > 100) {
|
|
12955
|
+
const R = U.value.keys().next().value;
|
|
12956
|
+
U.value.delete(R);
|
|
12957
12957
|
}
|
|
12958
12958
|
return eA;
|
|
12959
12959
|
}, b = (E) => {
|
|
@@ -13034,7 +13034,7 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13034
13034
|
}
|
|
13035
13035
|
return J;
|
|
13036
13036
|
}, fA = (E) => {
|
|
13037
|
-
const w = B.value.some((q) => q.id === E.id), O =
|
|
13037
|
+
const w = B.value.some((q) => q.id === E.id), O = h() === E;
|
|
13038
13038
|
return {
|
|
13039
13039
|
"component-selected": w,
|
|
13040
13040
|
"component-current": w && O,
|
|
@@ -13077,7 +13077,7 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13077
13077
|
const w = document.activeElement.tagName.toLowerCase();
|
|
13078
13078
|
if (w === "input" || w === "textarea")
|
|
13079
13079
|
return;
|
|
13080
|
-
const O =
|
|
13080
|
+
const O = h();
|
|
13081
13081
|
if (!O)
|
|
13082
13082
|
return;
|
|
13083
13083
|
const q = Number(O.props.width) || 0, K = Number(O.props.height) || 0;
|
|
@@ -13117,7 +13117,7 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13117
13117
|
type: O,
|
|
13118
13118
|
props: Nr
|
|
13119
13119
|
};
|
|
13120
|
-
a.value.push(mi),
|
|
13120
|
+
a.value.push(mi), g(mi);
|
|
13121
13121
|
};
|
|
13122
13122
|
function hA(E) {
|
|
13123
13123
|
let w = E.target;
|
|
@@ -13126,27 +13126,27 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13126
13126
|
return;
|
|
13127
13127
|
w = w.parentElement;
|
|
13128
13128
|
}
|
|
13129
|
-
|
|
13129
|
+
p();
|
|
13130
13130
|
}
|
|
13131
13131
|
const gA = (E, w) => {
|
|
13132
13132
|
if (B.value.length === 0) {
|
|
13133
|
-
|
|
13133
|
+
g(w), v(E, w);
|
|
13134
13134
|
return;
|
|
13135
13135
|
}
|
|
13136
|
-
if (
|
|
13136
|
+
if (h() === w) {
|
|
13137
13137
|
v(E, w);
|
|
13138
13138
|
return;
|
|
13139
13139
|
}
|
|
13140
|
-
|
|
13140
|
+
g(w), v(E, w);
|
|
13141
13141
|
}, SA = (E) => {
|
|
13142
13142
|
const w = [];
|
|
13143
13143
|
for (const K of d.value.keys())
|
|
13144
13144
|
K.includes(E) && w.push(K);
|
|
13145
13145
|
w.forEach((K) => d.value.delete(K));
|
|
13146
13146
|
const O = [];
|
|
13147
|
-
for (const K of
|
|
13147
|
+
for (const K of U.value.keys())
|
|
13148
13148
|
K.includes(E) && O.push(K);
|
|
13149
|
-
if (O.forEach((K) =>
|
|
13149
|
+
if (O.forEach((K) => U.value.delete(K)), d.value.clear(), U.value.clear(), a.value.find((K) => K.id === E) && (a.value = a.value.filter((K) => K.id !== E)), B.value.some((K) => K.id === E)) {
|
|
13150
13150
|
const K = B.value.filter((J) => J.id !== E);
|
|
13151
13151
|
B.value = K;
|
|
13152
13152
|
}
|
|
@@ -13155,7 +13155,7 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13155
13155
|
}, XA = (E) => {
|
|
13156
13156
|
var O;
|
|
13157
13157
|
const w = document.activeElement.tagName.toLowerCase();
|
|
13158
|
-
w === "input" || w === "textarea" || (E.key === "Delete" || E.key === "Backspace") && B.value.length > 0 && SA((O =
|
|
13158
|
+
w === "input" || w === "textarea" || (E.key === "Delete" || E.key === "Backspace") && B.value.length > 0 && SA((O = h()) == null ? void 0 : O.id);
|
|
13159
13159
|
}, { handleMouseWheel: se, handleInputChange: We, adjustRotation: Wt } = VF(B, l, s), ot = () => {
|
|
13160
13160
|
setTimeout(() => {
|
|
13161
13161
|
const E = document.querySelector(".center-container");
|
|
@@ -13177,7 +13177,7 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13177
13177
|
};
|
|
13178
13178
|
CA(() => t.templateType, async (E) => {
|
|
13179
13179
|
try {
|
|
13180
|
-
await me(E),
|
|
13180
|
+
await me(E), p(), d.value.clear(), U.value.clear(), console.log("配置切换成功:", E);
|
|
13181
13181
|
} catch (w) {
|
|
13182
13182
|
console.error("配置切换失败:", w);
|
|
13183
13183
|
}
|
|
@@ -13211,7 +13211,7 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13211
13211
|
const E = SF(r.value.graphData) || "";
|
|
13212
13212
|
E && ((w = document.querySelector("#design")) == null || w.appendChild(E));
|
|
13213
13213
|
}, Ei = () => new Promise((E, w) => {
|
|
13214
|
-
|
|
13214
|
+
p(), JSON.parse(JSON.stringify(a.value));
|
|
13215
13215
|
const O = JSON.parse(JSON.stringify(a.value));
|
|
13216
13216
|
O == null || O.forEach((K) => {
|
|
13217
13217
|
var J, Y;
|
|
@@ -13287,7 +13287,7 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13287
13287
|
getJson: () => HA().then(() => Tr()),
|
|
13288
13288
|
// 清空画布
|
|
13289
13289
|
clear: () => {
|
|
13290
|
-
a.value = [],
|
|
13290
|
+
a.value = [], p();
|
|
13291
13291
|
},
|
|
13292
13292
|
// 生成快照
|
|
13293
13293
|
snapshot: () => HA().then(() => Ei())
|
|
@@ -13351,7 +13351,7 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13351
13351
|
}, ["prevent"])),
|
|
13352
13352
|
onPointerdown: hA
|
|
13353
13353
|
}, [
|
|
13354
|
-
I(
|
|
13354
|
+
I(Q) && I(F) ? (V(), N("div", fR, [
|
|
13355
13355
|
m("div", {
|
|
13356
13356
|
class: "drag-extend-line vertical",
|
|
13357
13357
|
style: $(P(I(F), "left"))
|
|
@@ -13397,9 +13397,9 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13397
13397
|
style: $(rA(R)),
|
|
13398
13398
|
"data-item-id": R.id,
|
|
13399
13399
|
onMousedown: ZA((nA) => gA(nA, R), ["stop"]),
|
|
13400
|
-
onClick: ZA((nA) => I(
|
|
13400
|
+
onClick: ZA((nA) => I(g)(R), ["stop"])
|
|
13401
13401
|
}, [
|
|
13402
|
-
I(
|
|
13402
|
+
I(h)() === R ? (V(), N(TA, { key: 0 }, [
|
|
13403
13403
|
R.props.lockAspectRatio ? tA("", !0) : (V(), N(TA, { key: 0 }, [
|
|
13404
13404
|
R.type !== "verline" && R.type !== "horline" ? (V(), N("div", {
|
|
13405
13405
|
key: 0,
|
|
@@ -13467,7 +13467,7 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13467
13467
|
], 64)) : tA("", !0),
|
|
13468
13468
|
R.props && ae.value ? (V(), yA(cr(((sA = _(R.type)) == null ? void 0 : sA.component) || null), {
|
|
13469
13469
|
key: `${R.id}-${R.type}`,
|
|
13470
|
-
modelValue: { ...R.props, __selected: I(
|
|
13470
|
+
modelValue: { ...R.props, __selected: I(h)() === R },
|
|
13471
13471
|
propsConfig: EA.value,
|
|
13472
13472
|
"onUpdate:modelValue": (nA) => {
|
|
13473
13473
|
const { __selected: De, ...Je } = nA;
|
|
@@ -13494,12 +13494,12 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13494
13494
|
}, "-"),
|
|
13495
13495
|
YA(m("input", {
|
|
13496
13496
|
type: "number",
|
|
13497
|
-
"onUpdate:modelValue": w[3] || (w[3] = (R) => I(
|
|
13497
|
+
"onUpdate:modelValue": w[3] || (w[3] = (R) => I(h)().props.x = R),
|
|
13498
13498
|
onInput: w[4] || (w[4] = (R) => I(We)("x", R.target.value))
|
|
13499
13499
|
}, null, 544), [
|
|
13500
13500
|
[
|
|
13501
13501
|
Ge,
|
|
13502
|
-
I(
|
|
13502
|
+
I(h)().props.x,
|
|
13503
13503
|
void 0,
|
|
13504
13504
|
{ number: !0 }
|
|
13505
13505
|
]
|
|
@@ -13517,12 +13517,12 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13517
13517
|
}, "-"),
|
|
13518
13518
|
YA(m("input", {
|
|
13519
13519
|
type: "number",
|
|
13520
|
-
"onUpdate:modelValue": w[7] || (w[7] = (R) => I(
|
|
13520
|
+
"onUpdate:modelValue": w[7] || (w[7] = (R) => I(h)().props.y = R),
|
|
13521
13521
|
onInput: w[8] || (w[8] = (R) => I(We)("y", R.target.value))
|
|
13522
13522
|
}, null, 544), [
|
|
13523
13523
|
[
|
|
13524
13524
|
Ge,
|
|
13525
|
-
I(
|
|
13525
|
+
I(h)().props.y,
|
|
13526
13526
|
void 0,
|
|
13527
13527
|
{ number: !0 }
|
|
13528
13528
|
]
|
|
@@ -13532,7 +13532,7 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13532
13532
|
}, "+")
|
|
13533
13533
|
])
|
|
13534
13534
|
]),
|
|
13535
|
-
I(
|
|
13535
|
+
I(h)().type !== "verline" ? (V(), N("div", NR, [
|
|
13536
13536
|
w[27] || (w[27] = m("label", null, "宽度:", -1)),
|
|
13537
13537
|
m("div", SR, [
|
|
13538
13538
|
m("button", {
|
|
@@ -13540,12 +13540,12 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13540
13540
|
}, "-"),
|
|
13541
13541
|
YA(m("input", {
|
|
13542
13542
|
type: "number",
|
|
13543
|
-
"onUpdate:modelValue": w[11] || (w[11] = (R) => I(
|
|
13543
|
+
"onUpdate:modelValue": w[11] || (w[11] = (R) => I(h)().props.width = R),
|
|
13544
13544
|
onInput: w[12] || (w[12] = (R) => I(We)("width", R.target.value))
|
|
13545
13545
|
}, null, 544), [
|
|
13546
13546
|
[
|
|
13547
13547
|
Ge,
|
|
13548
|
-
I(
|
|
13548
|
+
I(h)().props.width,
|
|
13549
13549
|
void 0,
|
|
13550
13550
|
{ number: !0 }
|
|
13551
13551
|
]
|
|
@@ -13555,7 +13555,7 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13555
13555
|
}, "+")
|
|
13556
13556
|
])
|
|
13557
13557
|
])) : tA("", !0),
|
|
13558
|
-
I(
|
|
13558
|
+
I(h)().type !== "horline" ? (V(), N("div", MR, [
|
|
13559
13559
|
w[28] || (w[28] = m("label", null, "高度:", -1)),
|
|
13560
13560
|
m("div", bR, [
|
|
13561
13561
|
m("button", {
|
|
@@ -13563,12 +13563,12 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13563
13563
|
}, "-"),
|
|
13564
13564
|
YA(m("input", {
|
|
13565
13565
|
type: "number",
|
|
13566
|
-
"onUpdate:modelValue": w[15] || (w[15] = (R) => I(
|
|
13566
|
+
"onUpdate:modelValue": w[15] || (w[15] = (R) => I(h)().props.height = R),
|
|
13567
13567
|
onInput: w[16] || (w[16] = (R) => I(We)("height", R.target.value))
|
|
13568
13568
|
}, null, 544), [
|
|
13569
13569
|
[
|
|
13570
13570
|
Ge,
|
|
13571
|
-
I(
|
|
13571
|
+
I(h)().props.height,
|
|
13572
13572
|
void 0,
|
|
13573
13573
|
{ number: !0 }
|
|
13574
13574
|
]
|
|
@@ -13586,12 +13586,12 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13586
13586
|
}, "-"),
|
|
13587
13587
|
YA(m("input", {
|
|
13588
13588
|
type: "number",
|
|
13589
|
-
"onUpdate:modelValue": w[19] || (w[19] = (R) => I(
|
|
13589
|
+
"onUpdate:modelValue": w[19] || (w[19] = (R) => I(h)().props.rotation = R),
|
|
13590
13590
|
onInput: w[20] || (w[20] = (R) => I(We)("rotation", R.target.value))
|
|
13591
13591
|
}, null, 544), [
|
|
13592
13592
|
[
|
|
13593
13593
|
Ge,
|
|
13594
|
-
I(
|
|
13594
|
+
I(h)().props.rotation,
|
|
13595
13595
|
void 0,
|
|
13596
13596
|
{ number: !0 }
|
|
13597
13597
|
]
|
|
@@ -13601,23 +13601,23 @@ const nR = { class: "label-designer" }, aR = { class: "toolbar" }, oR = { class:
|
|
|
13601
13601
|
}, "+")
|
|
13602
13602
|
])
|
|
13603
13603
|
]),
|
|
13604
|
-
I(
|
|
13604
|
+
I(h)().type !== "horline" ? (V(), N("div", ZR, [
|
|
13605
13605
|
w[30] || (w[30] = m("label", null, "锁定宽高比:", -1)),
|
|
13606
13606
|
m("div", kR, [
|
|
13607
13607
|
W(J, {
|
|
13608
|
-
modelValue: I(
|
|
13609
|
-
"onUpdate:modelValue": w[22] || (w[22] = (R) => I(
|
|
13608
|
+
modelValue: I(h)().props.lockAspectRatio,
|
|
13609
|
+
"onUpdate:modelValue": w[22] || (w[22] = (R) => I(h)().props.lockAspectRatio = R),
|
|
13610
13610
|
"active-value": !0,
|
|
13611
13611
|
"inactive-value": !1
|
|
13612
13612
|
}, null, 8, ["modelValue"])
|
|
13613
13613
|
])
|
|
13614
13614
|
])) : tA("", !0)
|
|
13615
13615
|
]),
|
|
13616
|
-
(V(), yA(cr(((eA = _(I(
|
|
13617
|
-
modelValue: I(
|
|
13618
|
-
"onUpdate:modelValue": w[23] || (w[23] = (R) => I(
|
|
13616
|
+
(V(), yA(cr(((eA = _(I(h)().type)) == null ? void 0 : eA.propertyPanel) || null), {
|
|
13617
|
+
modelValue: I(h)().props,
|
|
13618
|
+
"onUpdate:modelValue": w[23] || (w[23] = (R) => I(h)().props = R),
|
|
13619
13619
|
options: e.options,
|
|
13620
|
-
"props-config": oa(I(
|
|
13620
|
+
"props-config": oa(I(h)().type)
|
|
13621
13621
|
}, null, 8, ["modelValue", "options", "props-config"]))
|
|
13622
13622
|
], 64)) : tA("", !0)
|
|
13623
13623
|
])
|
|
@@ -13645,13 +13645,13 @@ const DR = {
|
|
|
13645
13645
|
}
|
|
13646
13646
|
},
|
|
13647
13647
|
setup(e) {
|
|
13648
|
-
const A = qe(), t = e, r = k(!1), n = k({}), a = k(), o = k(0), i = k(!1), l = (
|
|
13649
|
-
let
|
|
13650
|
-
return function(...
|
|
13651
|
-
const
|
|
13652
|
-
clearTimeout(
|
|
13648
|
+
const A = qe(), t = e, r = k(!1), n = k({}), a = k(), o = k(0), i = k(!1), l = (g, h) => {
|
|
13649
|
+
let p;
|
|
13650
|
+
return function(...F) {
|
|
13651
|
+
const v = () => {
|
|
13652
|
+
clearTimeout(p), g(...F);
|
|
13653
13653
|
};
|
|
13654
|
-
clearTimeout(
|
|
13654
|
+
clearTimeout(p), p = setTimeout(v, h);
|
|
13655
13655
|
};
|
|
13656
13656
|
}, s = k({
|
|
13657
13657
|
rectTop: 0,
|
|
@@ -13659,37 +13659,37 @@ const DR = {
|
|
|
13659
13659
|
}), c = () => {
|
|
13660
13660
|
if (!a.value)
|
|
13661
13661
|
return;
|
|
13662
|
-
const
|
|
13663
|
-
let
|
|
13664
|
-
if (
|
|
13665
|
-
|
|
13666
|
-
else if (
|
|
13667
|
-
const Q =
|
|
13668
|
-
|
|
13662
|
+
const g = a.value.getBoundingClientRect(), h = d(a.value);
|
|
13663
|
+
let p = 0;
|
|
13664
|
+
if (g.top > 0)
|
|
13665
|
+
p = g.top;
|
|
13666
|
+
else if (h) {
|
|
13667
|
+
const Q = U(a.value);
|
|
13668
|
+
p = Q > 0 ? Q : 60;
|
|
13669
13669
|
} else {
|
|
13670
13670
|
const Q = a.value.offsetTop;
|
|
13671
|
-
Q > 0 ?
|
|
13671
|
+
Q > 0 ? p = Q : p = 60;
|
|
13672
13672
|
}
|
|
13673
|
-
(
|
|
13674
|
-
rectTop:
|
|
13675
|
-
isInModal:
|
|
13673
|
+
(p !== s.value.rectTop || h !== s.value.isInModal) && (o.value = p, i.value = h, s.value = {
|
|
13674
|
+
rectTop: p,
|
|
13675
|
+
isInModal: h
|
|
13676
13676
|
});
|
|
13677
|
-
}, u = l(c, 100), d = (
|
|
13678
|
-
let
|
|
13679
|
-
for (;
|
|
13680
|
-
if (
|
|
13677
|
+
}, u = l(c, 100), d = (g) => {
|
|
13678
|
+
let h = g.parentElement;
|
|
13679
|
+
for (; h; ) {
|
|
13680
|
+
if (h.classList && (h.classList.contains("el-dialog") || h.classList.contains("el-drawer") || h.classList.contains("sc-dialog")))
|
|
13681
13681
|
return !0;
|
|
13682
|
-
|
|
13682
|
+
h = h.parentElement;
|
|
13683
13683
|
}
|
|
13684
13684
|
return !1;
|
|
13685
|
-
},
|
|
13686
|
-
let
|
|
13687
|
-
for (;
|
|
13688
|
-
if (
|
|
13689
|
-
const
|
|
13690
|
-
return
|
|
13685
|
+
}, U = (g) => {
|
|
13686
|
+
let h = g.parentElement;
|
|
13687
|
+
for (; h; ) {
|
|
13688
|
+
if (h.classList && (h.classList.contains("el-dialog") || h.classList.contains("el-drawer") || h.classList.contains("sc-dialog"))) {
|
|
13689
|
+
const p = h.getBoundingClientRect();
|
|
13690
|
+
return p.top > 0 ? p.top : 60;
|
|
13691
13691
|
}
|
|
13692
|
-
|
|
13692
|
+
h = h.parentElement;
|
|
13693
13693
|
}
|
|
13694
13694
|
return 60;
|
|
13695
13695
|
};
|
|
@@ -13697,32 +13697,56 @@ const DR = {
|
|
|
13697
13697
|
setTimeout(() => c(), 100), setTimeout(() => c(), 300), window.addEventListener("resize", u), Ur(() => {
|
|
13698
13698
|
window.removeEventListener("resize", u);
|
|
13699
13699
|
});
|
|
13700
|
-
}), CA(() => r.value, (
|
|
13701
|
-
|
|
13702
|
-
}), CA(() => t.templateData,
|
|
13703
|
-
|
|
13704
|
-
|
|
13705
|
-
|
|
13706
|
-
|
|
13700
|
+
}), CA(() => r.value, (g) => {
|
|
13701
|
+
g && ue(() => setTimeout(() => c(), 50));
|
|
13702
|
+
}), CA(() => t.templateData, (g) => f(g), { deep: !0, immediate: !0 });
|
|
13703
|
+
function f(g) {
|
|
13704
|
+
if (r.value = (g == null ? void 0 : g.width) > 0 && (g == null ? void 0 : g.height) > 0, !r.value)
|
|
13705
|
+
return;
|
|
13706
|
+
const h = { ...g };
|
|
13707
|
+
h != null && h.graphData || Object.assign(h, {
|
|
13708
|
+
graphData: {
|
|
13709
|
+
printList: [{
|
|
13710
|
+
x: 0,
|
|
13711
|
+
y: 0,
|
|
13712
|
+
width: g.width,
|
|
13713
|
+
height: g.height,
|
|
13714
|
+
topLeftRadius: 4,
|
|
13715
|
+
topRightRadius: 4,
|
|
13716
|
+
bottomLeftRadius: 4,
|
|
13717
|
+
bottomRightRadius: 4
|
|
13718
|
+
}],
|
|
13719
|
+
punchingList: []
|
|
13720
|
+
}
|
|
13721
|
+
}), h != null && h.items || Object.assign(h, {
|
|
13722
|
+
items: []
|
|
13723
|
+
}), h.printWidth || Object.assign(h, {
|
|
13724
|
+
printWidth: h.width
|
|
13725
|
+
}), h.printHeight || Object.assign(h, {
|
|
13726
|
+
printHeight: h.height
|
|
13727
|
+
}), n.value = h;
|
|
13728
|
+
}
|
|
13729
|
+
function B(g) {
|
|
13730
|
+
A.exposed = g || {}, A.exposeProxy = g || {};
|
|
13707
13731
|
}
|
|
13708
|
-
return (
|
|
13709
|
-
const
|
|
13732
|
+
return (g, h) => {
|
|
13733
|
+
const p = $u("loading");
|
|
13710
13734
|
return YA((V(), N("div", {
|
|
13711
13735
|
ref_key: "templateDesignerRef",
|
|
13712
13736
|
ref: a,
|
|
13713
13737
|
class: _A(["template-designer", { "template-designer-border-top": i.value }]),
|
|
13714
13738
|
style: $({ height: "calc(100vh - " + (o.value + 1) + "px)" })
|
|
13715
13739
|
}, [
|
|
13716
|
-
r.value ? (V(), yA(cr(Ad(WR, { ...
|
|
13740
|
+
r.value ? (V(), yA(cr(Ad(WR, { ...g.$attrs, ...t, ref: B }, g.$slots)), {
|
|
13717
13741
|
key: 0,
|
|
13718
13742
|
"template-info": n.value
|
|
13719
13743
|
}, null, 8, ["template-info"])) : tA("", !0)
|
|
13720
13744
|
], 6)), [
|
|
13721
|
-
[
|
|
13745
|
+
[p, !r.value]
|
|
13722
13746
|
]);
|
|
13723
13747
|
};
|
|
13724
13748
|
}
|
|
13725
|
-
}, La = /* @__PURE__ */ RA(DR, [["__scopeId", "data-v-
|
|
13749
|
+
}, La = /* @__PURE__ */ RA(DR, [["__scopeId", "data-v-7efcb65e"]]);
|
|
13726
13750
|
La.install = (e) => {
|
|
13727
13751
|
e.component(La.name || "TemplateDesigner", La);
|
|
13728
13752
|
};
|