@agile-team/mach-report 2.23.0 → 2.24.0
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/README.md +9 -2
- package/dist/ExcelBindingWizard-BV12hGiK.cjs +1 -0
- package/dist/ExcelBindingWizard-Cy_lPjWV.js +1486 -0
- package/dist/ParamEditor-DenKjvKu.cjs +1 -0
- package/dist/ParamEditor-PyOqHzzw.js +750 -0
- package/dist/ReportBatchPanel-8EFtMrKk.js +351 -0
- package/dist/ReportBatchPanel-pQ6d0yqJ.cjs +1 -0
- package/dist/ReportLabelStudio-B_KF3Zc_.cjs +1 -0
- package/dist/ReportLabelStudio-HUeo2TsU.js +784 -0
- package/dist/ReportParamPanel-8xR85nz-.cjs +1 -0
- package/dist/{ReportParamPanel-Dgmqro1Y.js → ReportParamPanel-DA-YpkvC.js} +342 -307
- package/dist/ReportPreview-CyUXJSVX.cjs +6 -0
- package/dist/ReportPreview-_wTJnsG1.js +7120 -0
- package/dist/ReportTemplateLibrary-CjArKxRG.cjs +1 -0
- package/dist/ReportTemplateLibrary-DH8jl9IF.js +312 -0
- package/dist/RuleEditor-Bmj98oC4.cjs +1 -0
- package/dist/RuleEditor-GDydlEHz.js +2354 -0
- package/dist/TemplateOutlinePanel-B554_qk1.cjs +1 -0
- package/dist/TemplateOutlinePanel-DjPqzU9h.js +97 -0
- package/dist/TemplateReusePanel-D0628OYc.cjs +1 -0
- package/dist/TemplateReusePanel-DtYbCN7U.js +389 -0
- package/dist/TemplateReviewPanel-CSwvCz3f.cjs +1 -0
- package/dist/TemplateReviewPanel-D_FR4ISq.js +602 -0
- package/dist/artifact-integrity.json +94 -94
- package/dist/assets-B4AJIOTB.cjs +1 -0
- package/dist/assets-D0FbszhB.js +137 -0
- package/dist/{auto-CTIJ6PnR.js → auto-BksreoKc.js} +5 -5
- package/dist/auto-C3mGqzJ8.cjs +1 -0
- package/dist/capabilities-CTwlcl8q.cjs +1 -0
- package/dist/capabilities-lqDEZSq5.js +121 -0
- package/dist/data-bar-2NLRzOCQ.cjs +1 -0
- package/dist/{data-bar-IkI6VvMQ.js → data-bar-BnGtnJ82.js} +1 -1
- package/dist/designer-BNf7NWd6.js +7589 -0
- package/dist/designer-DWnZZ_ej.cjs +2 -0
- package/dist/designer.cjs +1 -1
- package/dist/designer.d.cts +144 -4
- package/dist/designer.d.ts +144 -4
- package/dist/designer.js +6 -6
- package/dist/diagnostic-collector-1sqd7DQP.js +355 -0
- package/dist/diagnostic-collector-D3rlvxm3.cjs +1 -0
- package/dist/{dom-JWrchIre.js → dom-C90cTM6Y.js} +4 -4
- package/dist/dom-CxOkm_Sy.cjs +1 -0
- package/dist/{encoding-BefcaHdp.cjs → encoding-CkziAnZI.cjs} +1 -1
- package/dist/{encoding-CL6rXEkR.js → encoding-DSc9zv2F.js} +2 -2
- package/dist/{font-loader-Ga51c2VC.cjs → font-loader-D-znWNWS.cjs} +1 -1
- package/dist/{font-loader-BT5baV-o.js → font-loader-i7lZbqH_.js} +1 -1
- package/dist/{grid-strokes-EoY66L2f.js → grid-strokes-BPiV1WHe.js} +1 -1
- package/dist/grid-strokes-DYf-6DMl.cjs +1 -0
- package/dist/index.cjs +5 -5
- package/dist/index.d.cts +46 -7
- package/dist/index.d.ts +46 -7
- package/dist/index.js +69 -68
- package/dist/{json-snapshot-OqkPyUk5.js → json-snapshot-BJWZNryO.js} +919 -791
- package/dist/json-snapshot-C7QZrRBf.cjs +2 -0
- package/dist/{pdf-aobetCsy.js → pdf-0_5XiTCx.js} +2499 -2492
- package/dist/{pdf-HiEeXe9H.cjs → pdf-DWuq6uxx.cjs} +31 -31
- package/dist/pdf.cjs +1 -1
- package/dist/pdf.d.cts +18 -0
- package/dist/pdf.d.ts +18 -0
- package/dist/pdf.js +2 -2
- package/dist/{plugin-DeYYAL6F.js → plugin-B1ydqEmS.js} +1 -1
- package/dist/{plugin-BFANt-i8.cjs → plugin-BQBz2vLG.cjs} +1 -1
- package/dist/prefill-2p9wrpn9.cjs +1 -0
- package/dist/{prefill-Dk4C6S5R.js → prefill-Cuzh1wxf.js} +13 -13
- package/dist/prepared-CVbgO9KR.js +128 -0
- package/dist/prepared-DAwe8Il2.cjs +1 -0
- package/dist/protocol-BOri9qJL.js +105 -0
- package/dist/protocol-DD5dHSz-.cjs +1 -0
- package/dist/record-bindings-CAyM5tGg.cjs +1 -0
- package/dist/{record-bindings-DatJZv_e.js → record-bindings-fhav-NLG.js} +1 -1
- package/dist/{region-binding-workflow-DjrXuR1q.js → region-binding-workflow-Cm4mqhih.js} +2 -2
- package/dist/{region-binding-workflow-l7NGfagJ.cjs → region-binding-workflow-DWCUgjZl.cjs} +1 -1
- package/dist/report-encoding-worker.cjs +1 -1
- package/dist/report-encoding-worker.js +1 -1
- package/dist/rich-text-layout-X9YOz1JD.cjs +3 -0
- package/dist/{rich-text-layout-Ciwa6D2o.js → rich-text-layout-YJHtCWQI.js} +1 -1
- package/dist/runtime-BpSAgOw1.js +201 -0
- package/dist/runtime-Cd2UTnwe.cjs +1 -0
- package/dist/sbom.cdx.json +1 -1
- package/dist/server/node.d.cts +55 -7
- package/dist/server/node.d.ts +55 -7
- package/dist/server-node.cjs +5 -5
- package/dist/server-node.js +2710 -2418
- package/dist/server.cjs +1 -1
- package/dist/server.d.cts +47 -12
- package/dist/server.d.ts +47 -12
- package/dist/server.js +8 -8
- package/dist/style.css +1 -1
- package/dist/{template-catalog-CoT7jm_6.cjs → template-catalog--yBX169M.cjs} +1 -1
- package/dist/{template-catalog--cjxzgH7.js → template-catalog-Bu7s7ReF.js} +3 -3
- package/dist/template-fragments-5EzVn7bm.cjs +1 -0
- package/dist/{template-fragments-CPpGpQoz.js → template-fragments-Di2vDFnx.js} +2 -2
- package/dist/{template-registry-O0hNIOfB.js → template-registry-BCBF2b8j.js} +10 -10
- package/dist/template-registry-Bnh5aEYf.cjs +1 -0
- package/dist/textwrap-BPFxhpOw.cjs +4 -0
- package/dist/textwrap-CmVkhMhx.js +111 -0
- package/dist/vue/async.d.cts +104 -18
- package/dist/vue/async.d.ts +104 -18
- package/dist/vue/index.d.cts +134 -28
- package/dist/vue/index.d.ts +134 -28
- package/dist/vue-async.cjs +1 -1
- package/dist/vue-async.js +3 -3
- package/dist/vue.cjs +1 -1
- package/dist/vue.js +192 -162
- package/dist/{workbook-session-C9ZmCBwY.js → workbook-session-B6P_-5a4.js} +2 -2
- package/dist/{workbook-session-C6-SrnCT.cjs → workbook-session-BnPK3T58.cjs} +1 -1
- package/dist/worker.cjs +1 -1
- package/dist/worker.d.cts +55 -7
- package/dist/worker.d.ts +55 -7
- package/dist/worker.js +4 -4
- package/dist/xlsx.cjs +4 -4
- package/dist/xlsx.d.cts +18 -1
- package/dist/xlsx.d.ts +18 -1
- package/dist/xlsx.js +279 -272
- package/package.json +1 -1
- package/dist/ExcelBindingWizard-D4FLind-.js +0 -1485
- package/dist/ExcelBindingWizard-D4RS5Bpg.cjs +0 -1
- package/dist/ParamEditor-C-6C9rd2.cjs +0 -1
- package/dist/ParamEditor-CASZt-Ma.js +0 -732
- package/dist/ReportBatchPanel-Bq7t8a5r.js +0 -350
- package/dist/ReportBatchPanel-YVj5IO5y.cjs +0 -1
- package/dist/ReportLabelStudio-Cqhita1b.cjs +0 -1
- package/dist/ReportLabelStudio-Dj7GXhuv.js +0 -783
- package/dist/ReportParamPanel-DZbFVmDL.cjs +0 -1
- package/dist/ReportPreview-DeWzG8jQ.js +0 -6257
- package/dist/ReportPreview-FFIryrIr.cjs +0 -6
- package/dist/ReportTemplateLibrary-BaWodmpm.cjs +0 -1
- package/dist/ReportTemplateLibrary-DdAAAD2I.js +0 -311
- package/dist/RuleEditor-D2UwQGF6.js +0 -2341
- package/dist/RuleEditor-DcT9xI1v.cjs +0 -1
- package/dist/TemplateOutlinePanel-CUHFFiNM.cjs +0 -1
- package/dist/TemplateOutlinePanel-DrT7XN0m.js +0 -96
- package/dist/TemplateReusePanel-4eejkNqi.js +0 -388
- package/dist/TemplateReusePanel-DZMyiX5I.cjs +0 -1
- package/dist/TemplateReviewPanel-BIhNLeNw.js +0 -592
- package/dist/TemplateReviewPanel-DnYImiXu.cjs +0 -1
- package/dist/assets-D2gHc4Mz.cjs +0 -1
- package/dist/assets-T_gDeFaz.js +0 -132
- package/dist/auto-4pK9HePf.cjs +0 -1
- package/dist/capabilities-DiBj4Qgl.cjs +0 -1
- package/dist/capabilities-pg7j7VLT.js +0 -106
- package/dist/data-bar-CeZuFmYl.cjs +0 -1
- package/dist/designer-DhrE7jzw.js +0 -7169
- package/dist/designer-IAZu6kBX.cjs +0 -2
- package/dist/dom-ChE5D-L-.cjs +0 -1
- package/dist/grid-strokes-Be24LGuV.cjs +0 -1
- package/dist/json-snapshot-1tvQNzQE.cjs +0 -2
- package/dist/prefill-DsUD5OoK.cjs +0 -1
- package/dist/prepared-DCIxhKFo.js +0 -94
- package/dist/prepared-Dv-XM3i1.cjs +0 -1
- package/dist/progress-ByiOxUD3.js +0 -250
- package/dist/progress-WomPRP3B.cjs +0 -1
- package/dist/protocol-B9YgfQ_d.cjs +0 -1
- package/dist/protocol-DxeUKGYG.js +0 -90
- package/dist/record-bindings-MBxbeBsi.cjs +0 -1
- package/dist/rich-text-layout-DK7A_a5r.cjs +0 -3
- package/dist/runtime-75Y5Oq5B.js +0 -171
- package/dist/runtime-DKlGd_D4.cjs +0 -1
- package/dist/template-fragments-GVjpew_q.cjs +0 -1
- package/dist/template-registry-DI59PXVK.cjs +0 -1
- package/dist/textwrap-BIjtEWmq.js +0 -110
- package/dist/textwrap-Cy7o1hIR.cjs +0 -4
|
@@ -1,388 +0,0 @@
|
|
|
1
|
-
import { computed as f, ref as S, watch as q, defineComponent as J, openBlock as d, createElementBlock as r, unref as e, createElementVNode as i, toDisplayString as a, createCommentVNode as w, Fragment as x, createTextVNode as U, withDirectives as $, isRef as D, renderList as O, vModelSelect as P, vModelText as M, normalizeStyle as L } from "vue";
|
|
2
|
-
import { b as G, c as H, i as W, a as K } from "./template-fragments-CPpGpQoz.js";
|
|
3
|
-
import { b as Q } from "./designer-DhrE7jzw.js";
|
|
4
|
-
import { _ as X } from "./_plugin-vue_export-helper-8SL1F89S.js";
|
|
5
|
-
function Y(l, A) {
|
|
6
|
-
const m = f(() => ({
|
|
7
|
-
...Q,
|
|
8
|
-
...l.messages
|
|
9
|
-
})), I = S([]), s = S(""), v = S("body"), g = S(""), C = S(""), V = S(), p = S({}), h = f(() => [
|
|
10
|
-
...l.fragments ?? [],
|
|
11
|
-
...I.value
|
|
12
|
-
]);
|
|
13
|
-
q(
|
|
14
|
-
h,
|
|
15
|
-
(o) => {
|
|
16
|
-
o.some((n) => n.id === s.value) || (s.value = o[0]?.id ?? "");
|
|
17
|
-
},
|
|
18
|
-
{ immediate: !0 }
|
|
19
|
-
);
|
|
20
|
-
const u = f(
|
|
21
|
-
() => h.value.find((o) => o.id === s.value) ?? h.value[0]
|
|
22
|
-
), E = f(() => {
|
|
23
|
-
try {
|
|
24
|
-
return u.value ? G(u.value) : [];
|
|
25
|
-
} catch (o) {
|
|
26
|
-
return [{ dataset: "", fields: [], error: String(o) }];
|
|
27
|
-
}
|
|
28
|
-
});
|
|
29
|
-
q(
|
|
30
|
-
u,
|
|
31
|
-
() => {
|
|
32
|
-
p.value = {
|
|
33
|
-
datasets: Object.fromEntries(
|
|
34
|
-
E.value.map((o) => [
|
|
35
|
-
o.dataset,
|
|
36
|
-
l.document.template.repeat?.dataset ?? o.dataset
|
|
37
|
-
])
|
|
38
|
-
),
|
|
39
|
-
fields: Object.fromEntries(
|
|
40
|
-
E.value.map((o) => [
|
|
41
|
-
o.dataset,
|
|
42
|
-
Object.fromEntries(o.fields.map((n) => [n, n]))
|
|
43
|
-
])
|
|
44
|
-
)
|
|
45
|
-
};
|
|
46
|
-
},
|
|
47
|
-
{ immediate: !0 }
|
|
48
|
-
);
|
|
49
|
-
const c = f(
|
|
50
|
-
() => l.selection?.pageIndex === l.pageIndex ? l.document.template.pages[l.pageIndex]?.components[l.selection.componentIndex] : void 0
|
|
51
|
-
), _ = f(
|
|
52
|
-
() => c.value?.meta?.fragment
|
|
53
|
-
), B = f(
|
|
54
|
-
() => _.value && u.value?.id === _.value.id && u.value.revision !== _.value.revision
|
|
55
|
-
), k = f(
|
|
56
|
-
() => l.styles?.length ? l.styles : [
|
|
57
|
-
{
|
|
58
|
-
id: "title",
|
|
59
|
-
name: m.value.styleText,
|
|
60
|
-
style: { fontSize: 18, bold: !0, color: "#183b65" }
|
|
61
|
-
},
|
|
62
|
-
{
|
|
63
|
-
id: "heading",
|
|
64
|
-
name: m.value.styleHeading,
|
|
65
|
-
target: "header",
|
|
66
|
-
style: {
|
|
67
|
-
fontSize: 10,
|
|
68
|
-
bold: !0,
|
|
69
|
-
color: "#21466e",
|
|
70
|
-
backgroundColor: "#eaf2fb",
|
|
71
|
-
align: "center",
|
|
72
|
-
verticalAlign: "middle"
|
|
73
|
-
}
|
|
74
|
-
},
|
|
75
|
-
{
|
|
76
|
-
id: "body",
|
|
77
|
-
name: m.value.styleBody,
|
|
78
|
-
style: { fontSize: 10, color: "#334155", bold: !1 }
|
|
79
|
-
},
|
|
80
|
-
{
|
|
81
|
-
id: "number",
|
|
82
|
-
name: m.value.styleNumber,
|
|
83
|
-
style: { fontSize: 10, align: "right", color: "#334155" }
|
|
84
|
-
},
|
|
85
|
-
{
|
|
86
|
-
id: "note",
|
|
87
|
-
name: m.value.styleNote,
|
|
88
|
-
style: { fontSize: 8, color: "#64748b", bold: !1 }
|
|
89
|
-
}
|
|
90
|
-
]
|
|
91
|
-
), b = f(
|
|
92
|
-
() => k.value.find((o) => o.id === v.value) ?? k.value[0]
|
|
93
|
-
);
|
|
94
|
-
q(
|
|
95
|
-
k,
|
|
96
|
-
(o) => {
|
|
97
|
-
o.some((n) => n.id === v.value) || (v.value = o[0]?.id ?? "");
|
|
98
|
-
},
|
|
99
|
-
{ immediate: !0 }
|
|
100
|
-
);
|
|
101
|
-
function T(o) {
|
|
102
|
-
if (!l.disabled) {
|
|
103
|
-
C.value = "";
|
|
104
|
-
try {
|
|
105
|
-
o();
|
|
106
|
-
} catch (n) {
|
|
107
|
-
C.value = n instanceof Error ? n.message : String(n);
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
function z() {
|
|
112
|
-
T(() => {
|
|
113
|
-
if (!l.selection || !c.value) throw new Error(m.value.select);
|
|
114
|
-
if (!g.value.trim()) throw new Error(m.value.nameRequired);
|
|
115
|
-
let o = I.value.length + 1;
|
|
116
|
-
const n = new Set(h.value.map((y) => y.id));
|
|
117
|
-
for (; n.has(`session-fragment-${o}`); ) o++;
|
|
118
|
-
const t = `session-fragment-${o}`;
|
|
119
|
-
I.value.push(
|
|
120
|
-
H(
|
|
121
|
-
l.document,
|
|
122
|
-
l.pageIndex,
|
|
123
|
-
[l.selection.componentIndex],
|
|
124
|
-
{ id: t, name: g.value.trim(), revision: "1" }
|
|
125
|
-
)
|
|
126
|
-
), s.value = t, g.value = "";
|
|
127
|
-
});
|
|
128
|
-
}
|
|
129
|
-
function N(o = !1) {
|
|
130
|
-
T(() => {
|
|
131
|
-
if (!u.value) return;
|
|
132
|
-
const n = W(l.document, u.value, {
|
|
133
|
-
pageIndex: l.pageIndex,
|
|
134
|
-
bindings: p.value,
|
|
135
|
-
...o ? { replaceInstance: _.value?.instance } : {}
|
|
136
|
-
});
|
|
137
|
-
l.accept((t) => {
|
|
138
|
-
t.template = n.document.template;
|
|
139
|
-
}) && A({
|
|
140
|
-
pageIndex: l.pageIndex,
|
|
141
|
-
componentIndex: n.componentIndices[0]
|
|
142
|
-
});
|
|
143
|
-
});
|
|
144
|
-
}
|
|
145
|
-
function R(o = b.value) {
|
|
146
|
-
T(() => {
|
|
147
|
-
if (!l.selection || !c.value) return;
|
|
148
|
-
const n = K(
|
|
149
|
-
l.document,
|
|
150
|
-
l.pageIndex,
|
|
151
|
-
[l.selection.componentIndex],
|
|
152
|
-
o
|
|
153
|
-
);
|
|
154
|
-
l.accept((t) => {
|
|
155
|
-
t.template = n.template;
|
|
156
|
-
});
|
|
157
|
-
});
|
|
158
|
-
}
|
|
159
|
-
function F() {
|
|
160
|
-
c.value && (V.value = JSON.parse(
|
|
161
|
-
JSON.stringify(
|
|
162
|
-
c.value.kind === "list" ? c.value.columns[0]?.style ?? {} : c.value.style ?? {}
|
|
163
|
-
)
|
|
164
|
-
));
|
|
165
|
-
}
|
|
166
|
-
return {
|
|
167
|
-
m,
|
|
168
|
-
local: I,
|
|
169
|
-
name: g,
|
|
170
|
-
fragmentId: s,
|
|
171
|
-
fragments: h,
|
|
172
|
-
fragment: u,
|
|
173
|
-
bindings: p,
|
|
174
|
-
required: E,
|
|
175
|
-
active: c,
|
|
176
|
-
instance: _,
|
|
177
|
-
canUpdate: B,
|
|
178
|
-
error: C,
|
|
179
|
-
styles: k,
|
|
180
|
-
styleId: v,
|
|
181
|
-
style: b,
|
|
182
|
-
clipboard: V,
|
|
183
|
-
capture: z,
|
|
184
|
-
insert: N,
|
|
185
|
-
apply: R,
|
|
186
|
-
copyStyle: F
|
|
187
|
-
};
|
|
188
|
-
}
|
|
189
|
-
const Z = ["aria-label"], ee = {
|
|
190
|
-
key: 0,
|
|
191
|
-
role: "alert",
|
|
192
|
-
class: "mr-reuse-error"
|
|
193
|
-
}, te = { class: "mr-reuse-layout" }, ne = {
|
|
194
|
-
key: 0,
|
|
195
|
-
class: "mr-product-note"
|
|
196
|
-
}, le = ["value"], ae = { class: "mr-product-note" }, se = { key: 0 }, oe = {
|
|
197
|
-
key: 0,
|
|
198
|
-
class: "mr-reuse-bindings"
|
|
199
|
-
}, ie = {
|
|
200
|
-
key: 0,
|
|
201
|
-
role: "alert"
|
|
202
|
-
}, de = ["onUpdate:modelValue", "disabled"], re = ["onUpdate:modelValue", "aria-label", "disabled"], ue = { class: "mr-reuse-actions" }, ce = ["disabled"], me = ["disabled"], ve = {
|
|
203
|
-
key: 1,
|
|
204
|
-
class: "mr-product-note"
|
|
205
|
-
}, be = { class: "mr-reuse-bindings" }, ye = ["disabled"], fe = ["disabled"], ge = { class: "mr-product-note" }, pe = ["value"], he = {
|
|
206
|
-
key: 0,
|
|
207
|
-
class: "mr-product-note"
|
|
208
|
-
}, _e = { class: "mr-reuse-actions" }, ke = ["disabled"], Se = ["disabled"], xe = ["disabled"], Ie = /* @__PURE__ */ J({
|
|
209
|
-
__name: "TemplateReusePanel",
|
|
210
|
-
props: {
|
|
211
|
-
document: {},
|
|
212
|
-
pageIndex: {},
|
|
213
|
-
selection: {},
|
|
214
|
-
fragments: {},
|
|
215
|
-
styles: {},
|
|
216
|
-
disabled: { type: Boolean },
|
|
217
|
-
messages: {},
|
|
218
|
-
accept: { type: Function }
|
|
219
|
-
},
|
|
220
|
-
emits: ["select"],
|
|
221
|
-
setup(l, { emit: A }) {
|
|
222
|
-
const m = l, I = A, {
|
|
223
|
-
m: s,
|
|
224
|
-
name: v,
|
|
225
|
-
fragmentId: g,
|
|
226
|
-
fragments: C,
|
|
227
|
-
fragment: V,
|
|
228
|
-
bindings: p,
|
|
229
|
-
required: h,
|
|
230
|
-
active: u,
|
|
231
|
-
instance: E,
|
|
232
|
-
canUpdate: c,
|
|
233
|
-
error: _,
|
|
234
|
-
styles: B,
|
|
235
|
-
styleId: k,
|
|
236
|
-
style: b,
|
|
237
|
-
clipboard: T,
|
|
238
|
-
capture: z,
|
|
239
|
-
insert: N,
|
|
240
|
-
apply: R,
|
|
241
|
-
copyStyle: F
|
|
242
|
-
} = Y(m, (o) => I("select", o));
|
|
243
|
-
return (o, n) => (d(), r("section", {
|
|
244
|
-
class: "mr-product-panel",
|
|
245
|
-
"aria-label": e(s).reuse
|
|
246
|
-
}, [
|
|
247
|
-
i("header", null, [
|
|
248
|
-
i("strong", null, a(e(s).reuse), 1),
|
|
249
|
-
i("small", null, a(e(s).preserve), 1)
|
|
250
|
-
]),
|
|
251
|
-
e(_) ? (d(), r("p", ee, a(e(_)), 1)) : w("", !0),
|
|
252
|
-
i("div", te, [
|
|
253
|
-
i("section", null, [
|
|
254
|
-
i("h3", null, a(e(s).fragments), 1),
|
|
255
|
-
e(C).length ? (d(), r(x, { key: 1 }, [
|
|
256
|
-
i("label", null, [
|
|
257
|
-
U(a(e(s).fragments), 1),
|
|
258
|
-
$(i("select", {
|
|
259
|
-
"onUpdate:modelValue": n[0] || (n[0] = (t) => D(g) ? g.value = t : null)
|
|
260
|
-
}, [
|
|
261
|
-
(d(!0), r(x, null, O(e(C), (t) => (d(), r("option", {
|
|
262
|
-
key: t.id,
|
|
263
|
-
value: t.id
|
|
264
|
-
}, a(t.name) + " · " + a(t.revision), 9, le))), 128))
|
|
265
|
-
], 512), [
|
|
266
|
-
[P, e(g)]
|
|
267
|
-
])
|
|
268
|
-
]),
|
|
269
|
-
i("p", ae, [
|
|
270
|
-
U(a(e(s).revision) + " " + a(e(V)?.revision), 1),
|
|
271
|
-
e(E) ? (d(), r("span", se, " · " + a(e(s).instance) + " " + a(e(E).revision), 1)) : w("", !0)
|
|
272
|
-
]),
|
|
273
|
-
e(h).length ? (d(), r("div", oe, [
|
|
274
|
-
i("h3", null, a(e(s).bindings), 1),
|
|
275
|
-
(d(!0), r(x, null, O(e(h), (t) => (d(), r(x, {
|
|
276
|
-
key: t.dataset
|
|
277
|
-
}, [
|
|
278
|
-
"error" in t ? (d(), r("p", ie, a(t.error), 1)) : (d(), r(x, { key: 1 }, [
|
|
279
|
-
i("label", null, [
|
|
280
|
-
U(a(e(s).dataset) + " · " + a(t.dataset), 1),
|
|
281
|
-
$(i("input", {
|
|
282
|
-
"onUpdate:modelValue": (y) => e(p).datasets[t.dataset] = y,
|
|
283
|
-
disabled: l.disabled
|
|
284
|
-
}, null, 8, de), [
|
|
285
|
-
[M, e(p).datasets[t.dataset]]
|
|
286
|
-
])
|
|
287
|
-
]),
|
|
288
|
-
(d(!0), r(x, null, O(t.fields, (y) => (d(), r("label", { key: y }, [
|
|
289
|
-
U(a(y), 1),
|
|
290
|
-
$(i("input", {
|
|
291
|
-
"onUpdate:modelValue": (j) => e(p).fields[t.dataset][y] = j,
|
|
292
|
-
"aria-label": `${e(s).target} ${y}`,
|
|
293
|
-
disabled: l.disabled
|
|
294
|
-
}, null, 8, re), [
|
|
295
|
-
[M, e(p).fields[t.dataset][y]]
|
|
296
|
-
])
|
|
297
|
-
]))), 128))
|
|
298
|
-
], 64))
|
|
299
|
-
], 64))), 128))
|
|
300
|
-
])) : w("", !0),
|
|
301
|
-
i("div", ue, [
|
|
302
|
-
i("button", {
|
|
303
|
-
type: "button",
|
|
304
|
-
class: "mr-reuse-primary",
|
|
305
|
-
disabled: l.disabled || !e(V),
|
|
306
|
-
onClick: n[1] || (n[1] = (t) => e(N)())
|
|
307
|
-
}, a(e(s).insert), 9, ce),
|
|
308
|
-
e(c) ? (d(), r("button", {
|
|
309
|
-
key: 0,
|
|
310
|
-
type: "button",
|
|
311
|
-
disabled: l.disabled,
|
|
312
|
-
onClick: n[2] || (n[2] = (t) => e(N)(!0))
|
|
313
|
-
}, a(e(s).update), 9, me)) : w("", !0)
|
|
314
|
-
]),
|
|
315
|
-
e(c) ? (d(), r("p", ve, a(e(s).newRevision), 1)) : w("", !0)
|
|
316
|
-
], 64)) : (d(), r("p", ne, a(e(s).noFragments), 1)),
|
|
317
|
-
i("div", be, [
|
|
318
|
-
i("label", null, [
|
|
319
|
-
U(a(e(s).fragmentName), 1),
|
|
320
|
-
$(i("input", {
|
|
321
|
-
"onUpdate:modelValue": n[3] || (n[3] = (t) => D(v) ? v.value = t : null),
|
|
322
|
-
disabled: l.disabled || !e(u)
|
|
323
|
-
}, null, 8, ye), [
|
|
324
|
-
[M, e(v)]
|
|
325
|
-
])
|
|
326
|
-
]),
|
|
327
|
-
i("button", {
|
|
328
|
-
type: "button",
|
|
329
|
-
disabled: l.disabled || !e(u) || !e(v).trim(),
|
|
330
|
-
onClick: n[4] || (n[4] = //@ts-ignore
|
|
331
|
-
(...t) => e(z) && e(z)(...t))
|
|
332
|
-
}, a(e(s).capture), 9, fe)
|
|
333
|
-
])
|
|
334
|
-
]),
|
|
335
|
-
i("section", null, [
|
|
336
|
-
i("h3", null, a(e(s).styles), 1),
|
|
337
|
-
i("p", ge, a(e(s).noStyles), 1),
|
|
338
|
-
i("label", null, [
|
|
339
|
-
U(a(e(s).role), 1),
|
|
340
|
-
$(i("select", {
|
|
341
|
-
"onUpdate:modelValue": n[5] || (n[5] = (t) => D(k) ? k.value = t : null)
|
|
342
|
-
}, [
|
|
343
|
-
(d(!0), r(x, null, O(e(B), (t) => (d(), r("option", {
|
|
344
|
-
key: t.id,
|
|
345
|
-
value: t.id
|
|
346
|
-
}, a(t.name), 9, pe))), 128))
|
|
347
|
-
], 512), [
|
|
348
|
-
[P, e(k)]
|
|
349
|
-
])
|
|
350
|
-
]),
|
|
351
|
-
i("div", {
|
|
352
|
-
class: "mr-reuse-swatch",
|
|
353
|
-
style: L({
|
|
354
|
-
color: e(b).style.color,
|
|
355
|
-
backgroundColor: e(b).style.backgroundColor,
|
|
356
|
-
fontSize: `${e(b).style.fontSize ?? 10}pt`,
|
|
357
|
-
fontWeight: e(b).style.bold ? 600 : 400,
|
|
358
|
-
textAlign: e(b).style.align
|
|
359
|
-
})
|
|
360
|
-
}, a(e(b).name) + " · Aa 0123 ", 5),
|
|
361
|
-
e(u) ? w("", !0) : (d(), r("p", he, a(e(s).select), 1)),
|
|
362
|
-
i("div", _e, [
|
|
363
|
-
i("button", {
|
|
364
|
-
type: "button",
|
|
365
|
-
class: "mr-reuse-primary",
|
|
366
|
-
disabled: l.disabled || !e(u),
|
|
367
|
-
onClick: n[6] || (n[6] = (t) => e(R)())
|
|
368
|
-
}, a(e(s).apply), 9, ke),
|
|
369
|
-
i("button", {
|
|
370
|
-
type: "button",
|
|
371
|
-
disabled: !e(u),
|
|
372
|
-
onClick: n[7] || (n[7] = //@ts-ignore
|
|
373
|
-
(...t) => e(F) && e(F)(...t))
|
|
374
|
-
}, a(e(s).copy), 9, Se),
|
|
375
|
-
i("button", {
|
|
376
|
-
type: "button",
|
|
377
|
-
disabled: l.disabled || !e(u) || !e(T),
|
|
378
|
-
onClick: n[8] || (n[8] = (t) => e(R)({ id: "clipboard", name: e(s).paste, style: e(T) }))
|
|
379
|
-
}, a(e(s).paste), 9, xe)
|
|
380
|
-
])
|
|
381
|
-
])
|
|
382
|
-
])
|
|
383
|
-
], 8, Z));
|
|
384
|
-
}
|
|
385
|
-
}), Ue = /* @__PURE__ */ X(Ie, [["__scopeId", "data-v-45be4c24"]]);
|
|
386
|
-
export {
|
|
387
|
-
Ue as default
|
|
388
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),h=require("./template-fragments-GVjpew_q.cjs"),T=require("./designer-IAZu6kBX.cjs"),C=require("./_plugin-vue_export-helper-BLmdZLlg.cjs");function w(l,_){const i=e.computed(()=>({...T.TEMPLATE_PRODUCT_MESSAGES,...l.messages})),v=e.ref([]),a=e.ref(""),d=e.ref("body"),m=e.ref(""),b=e.ref(""),S=e.ref(),f=e.ref({}),p=e.computed(()=>[...l.fragments??[],...v.value]);e.watch(p,o=>{o.some(n=>n.id===a.value)||(a.value=o[0]?.id??"")},{immediate:!0});const r=e.computed(()=>p.value.find(o=>o.id===a.value)??p.value[0]),k=e.computed(()=>{try{return r.value?h.inspectTemplateFragmentBindings(r.value):[]}catch(o){return[{dataset:"",fields:[],error:String(o)}]}});e.watch(r,()=>{f.value={datasets:Object.fromEntries(k.value.map(o=>[o.dataset,l.document.template.repeat?.dataset??o.dataset])),fields:Object.fromEntries(k.value.map(o=>[o.dataset,Object.fromEntries(o.fields.map(n=>[n,n]))]))}},{immediate:!0});const s=e.computed(()=>l.selection?.pageIndex===l.pageIndex?l.document.template.pages[l.pageIndex]?.components[l.selection.componentIndex]:void 0),y=e.computed(()=>s.value?.meta?.fragment),x=e.computed(()=>y.value&&r.value?.id===y.value.id&&r.value.revision!==y.value.revision),g=e.computed(()=>l.styles?.length?l.styles:[{id:"title",name:i.value.styleText,style:{fontSize:18,bold:!0,color:"#183b65"}},{id:"heading",name:i.value.styleHeading,target:"header",style:{fontSize:10,bold:!0,color:"#21466e",backgroundColor:"#eaf2fb",align:"center",verticalAlign:"middle"}},{id:"body",name:i.value.styleBody,style:{fontSize:10,color:"#334155",bold:!1}},{id:"number",name:i.value.styleNumber,style:{fontSize:10,align:"right",color:"#334155"}},{id:"note",name:i.value.styleNote,style:{fontSize:8,color:"#64748b",bold:!1}}]),u=e.computed(()=>g.value.find(o=>o.id===d.value)??g.value[0]);e.watch(g,o=>{o.some(n=>n.id===d.value)||(d.value=o[0]?.id??"")},{immediate:!0});function E(o){if(!l.disabled){b.value="";try{o()}catch(n){b.value=n instanceof Error?n.message:String(n)}}}function V(){E(()=>{if(!l.selection||!s.value)throw new Error(i.value.select);if(!m.value.trim())throw new Error(i.value.nameRequired);let o=v.value.length+1;const n=new Set(p.value.map(c=>c.id));for(;n.has(`session-fragment-${o}`);)o++;const t=`session-fragment-${o}`;v.value.push(h.captureTemplateFragment(l.document,l.pageIndex,[l.selection.componentIndex],{id:t,name:m.value.trim(),revision:"1"})),a.value=t,m.value=""})}function N(o=!1){E(()=>{if(!r.value)return;const n=h.insertTemplateFragment(l.document,r.value,{pageIndex:l.pageIndex,bindings:f.value,...o?{replaceInstance:y.value?.instance}:{}});l.accept(t=>{t.template=n.document.template})&&_({pageIndex:l.pageIndex,componentIndex:n.componentIndices[0]})})}function B(o=u.value){E(()=>{if(!l.selection||!s.value)return;const n=h.applyReportDocumentStyle(l.document,l.pageIndex,[l.selection.componentIndex],o);l.accept(t=>{t.template=n.template})})}function D(){s.value&&(S.value=JSON.parse(JSON.stringify(s.value.kind==="list"?s.value.columns[0]?.style??{}:s.value.style??{})))}return{m:i,local:v,name:m,fragmentId:a,fragments:p,fragment:r,bindings:f,required:k,active:s,instance:y,canUpdate:x,error:b,styles:g,styleId:d,style:u,clipboard:S,capture:V,insert:N,apply:B,copyStyle:D}}const F=["aria-label"],R={key:0,role:"alert",class:"mr-reuse-error"},U={class:"mr-reuse-layout"},$={key:0,class:"mr-product-note"},q=["value"],z={class:"mr-product-note"},M={key:0},O={key:0,class:"mr-reuse-bindings"},A={key:0,role:"alert"},L=["onUpdate:modelValue","disabled"],P=["onUpdate:modelValue","aria-label","disabled"],j={class:"mr-reuse-actions"},H=["disabled"],J=["disabled"],G={key:1,class:"mr-product-note"},W={class:"mr-reuse-bindings"},K=["disabled"],Q=["disabled"],X={class:"mr-product-note"},Y=["value"],Z={key:0,class:"mr-product-note"},ee={class:"mr-reuse-actions"},te=["disabled"],ne=["disabled"],le=["disabled"],ae=e.defineComponent({__name:"TemplateReusePanel",props:{document:{},pageIndex:{},selection:{},fragments:{},styles:{},disabled:{type:Boolean},messages:{},accept:{type:Function}},emits:["select"],setup(l,{emit:_}){const i=l,v=_,{m:a,name:d,fragmentId:m,fragments:b,fragment:S,bindings:f,required:p,active:r,instance:k,canUpdate:s,error:y,styles:x,styleId:g,style:u,clipboard:E,capture:V,insert:N,apply:B,copyStyle:D}=w(i,o=>v("select",o));return(o,n)=>(e.openBlock(),e.createElementBlock("section",{class:"mr-product-panel","aria-label":e.unref(a).reuse},[e.createElementVNode("header",null,[e.createElementVNode("strong",null,e.toDisplayString(e.unref(a).reuse),1),e.createElementVNode("small",null,e.toDisplayString(e.unref(a).preserve),1)]),e.unref(y)?(e.openBlock(),e.createElementBlock("p",R,e.toDisplayString(e.unref(y)),1)):e.createCommentVNode("",!0),e.createElementVNode("div",U,[e.createElementVNode("section",null,[e.createElementVNode("h3",null,e.toDisplayString(e.unref(a).fragments),1),e.unref(b).length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("label",null,[e.createTextVNode(e.toDisplayString(e.unref(a).fragments),1),e.withDirectives(e.createElementVNode("select",{"onUpdate:modelValue":n[0]||(n[0]=t=>e.isRef(m)?m.value=t:null)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(b),t=>(e.openBlock(),e.createElementBlock("option",{key:t.id,value:t.id},e.toDisplayString(t.name)+" · "+e.toDisplayString(t.revision),9,q))),128))],512),[[e.vModelSelect,e.unref(m)]])]),e.createElementVNode("p",z,[e.createTextVNode(e.toDisplayString(e.unref(a).revision)+" "+e.toDisplayString(e.unref(S)?.revision),1),e.unref(k)?(e.openBlock(),e.createElementBlock("span",M," · "+e.toDisplayString(e.unref(a).instance)+" "+e.toDisplayString(e.unref(k).revision),1)):e.createCommentVNode("",!0)]),e.unref(p).length?(e.openBlock(),e.createElementBlock("div",O,[e.createElementVNode("h3",null,e.toDisplayString(e.unref(a).bindings),1),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(p),t=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:t.dataset},["error"in t?(e.openBlock(),e.createElementBlock("p",A,e.toDisplayString(t.error),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("label",null,[e.createTextVNode(e.toDisplayString(e.unref(a).dataset)+" · "+e.toDisplayString(t.dataset),1),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":c=>e.unref(f).datasets[t.dataset]=c,disabled:l.disabled},null,8,L),[[e.vModelText,e.unref(f).datasets[t.dataset]]])]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.fields,c=>(e.openBlock(),e.createElementBlock("label",{key:c},[e.createTextVNode(e.toDisplayString(c),1),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":I=>e.unref(f).fields[t.dataset][c]=I,"aria-label":`${e.unref(a).target} ${c}`,disabled:l.disabled},null,8,P),[[e.vModelText,e.unref(f).fields[t.dataset][c]]])]))),128))],64))],64))),128))])):e.createCommentVNode("",!0),e.createElementVNode("div",j,[e.createElementVNode("button",{type:"button",class:"mr-reuse-primary",disabled:l.disabled||!e.unref(S),onClick:n[1]||(n[1]=t=>e.unref(N)())},e.toDisplayString(e.unref(a).insert),9,H),e.unref(s)?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",disabled:l.disabled,onClick:n[2]||(n[2]=t=>e.unref(N)(!0))},e.toDisplayString(e.unref(a).update),9,J)):e.createCommentVNode("",!0)]),e.unref(s)?(e.openBlock(),e.createElementBlock("p",G,e.toDisplayString(e.unref(a).newRevision),1)):e.createCommentVNode("",!0)],64)):(e.openBlock(),e.createElementBlock("p",$,e.toDisplayString(e.unref(a).noFragments),1)),e.createElementVNode("div",W,[e.createElementVNode("label",null,[e.createTextVNode(e.toDisplayString(e.unref(a).fragmentName),1),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":n[3]||(n[3]=t=>e.isRef(d)?d.value=t:null),disabled:l.disabled||!e.unref(r)},null,8,K),[[e.vModelText,e.unref(d)]])]),e.createElementVNode("button",{type:"button",disabled:l.disabled||!e.unref(r)||!e.unref(d).trim(),onClick:n[4]||(n[4]=(...t)=>e.unref(V)&&e.unref(V)(...t))},e.toDisplayString(e.unref(a).capture),9,Q)])]),e.createElementVNode("section",null,[e.createElementVNode("h3",null,e.toDisplayString(e.unref(a).styles),1),e.createElementVNode("p",X,e.toDisplayString(e.unref(a).noStyles),1),e.createElementVNode("label",null,[e.createTextVNode(e.toDisplayString(e.unref(a).role),1),e.withDirectives(e.createElementVNode("select",{"onUpdate:modelValue":n[5]||(n[5]=t=>e.isRef(g)?g.value=t:null)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(x),t=>(e.openBlock(),e.createElementBlock("option",{key:t.id,value:t.id},e.toDisplayString(t.name),9,Y))),128))],512),[[e.vModelSelect,e.unref(g)]])]),e.createElementVNode("div",{class:"mr-reuse-swatch",style:e.normalizeStyle({color:e.unref(u).style.color,backgroundColor:e.unref(u).style.backgroundColor,fontSize:`${e.unref(u).style.fontSize??10}pt`,fontWeight:e.unref(u).style.bold?600:400,textAlign:e.unref(u).style.align})},e.toDisplayString(e.unref(u).name)+" · Aa 0123 ",5),e.unref(r)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("p",Z,e.toDisplayString(e.unref(a).select),1)),e.createElementVNode("div",ee,[e.createElementVNode("button",{type:"button",class:"mr-reuse-primary",disabled:l.disabled||!e.unref(r),onClick:n[6]||(n[6]=t=>e.unref(B)())},e.toDisplayString(e.unref(a).apply),9,te),e.createElementVNode("button",{type:"button",disabled:!e.unref(r),onClick:n[7]||(n[7]=(...t)=>e.unref(D)&&e.unref(D)(...t))},e.toDisplayString(e.unref(a).copy),9,ne),e.createElementVNode("button",{type:"button",disabled:l.disabled||!e.unref(r)||!e.unref(E),onClick:n[8]||(n[8]=t=>e.unref(B)({id:"clipboard",name:e.unref(a).paste,style:e.unref(E)}))},e.toDisplayString(e.unref(a).paste),9,le)])])])],8,F))}}),oe=C._export_sfc(ae,[["__scopeId","data-v-45be4c24"]]);exports.default=oe;
|