@guodun/antdv 1.3.2 → 1.4.1
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/es/components/contract-signing-location/index.mjs +1 -0
- package/dist/es/components/contract-signing-location/src/ContractSigningLocation.vue.mjs +311 -289
- package/dist/es/components/contract-signing-location/src/ContractSigningLocationCanvas.vue.mjs +337 -326
- package/dist/es/components/contract-signing-location/src/ContractSigningLocationInspector.vue.mjs +3 -2
- package/dist/es/components/contract-signing-location/src/ContractSigningLocationNavigator.vue.mjs +41 -33
- package/dist/es/components/contract-signing-location/src/ContractSigningTemplatePage.mjs +5 -0
- package/dist/es/components/contract-signing-location/src/ContractSigningTemplatePage.vue.mjs +23 -0
- package/dist/es/components/contract-signing-location/src/location-rules.mjs +115 -77
- package/dist/es/components/contract-signing-location/src/template-source.mjs +85 -0
- package/dist/es/components/contract-signing-location/style/index.css +1 -1
- package/dist/es/components/index.mjs +8 -6
- package/dist/es/components/pro-contract-signing-flow/src/ContractSigningFlowCanvas.vue.mjs +164 -57
- package/dist/es/components/pro-contract-signing-flow/src/ContractSigningFlowInspector.vue.mjs +132 -126
- package/dist/es/components/pro-contract-signing-flow/src/ContractSigningFlowNodeCard.vue.mjs +75 -49
- package/dist/es/components/pro-contract-signing-flow/src/ProContractSigningFlow.vue.mjs +136 -91
- package/dist/es/components/pro-contract-signing-flow/src/constants.mjs +25 -5
- package/dist/es/components/pro-contract-signing-flow/style/index.css +1 -1
- package/dist/es/components/pro-contract-template-designer/index.mjs +5 -4
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplateDesignerInspector.mjs +5 -0
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplateDesignerInspector.vue.mjs +347 -0
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplateDesignerSidebar.mjs +5 -0
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplateDesignerSidebar.vue.mjs +171 -0
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplateFileBar.mjs +5 -0
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplateFileBar.vue.mjs +166 -0
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplateRendererField.vue.mjs +4 -4
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplateRendererValidation.mjs +5 -0
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplateRendererValidation.vue.mjs +36 -0
- package/dist/es/components/pro-contract-template-designer/src/DesignerPage.vue.mjs +202 -202
- package/dist/es/components/pro-contract-template-designer/src/ProContractTemplateDesigner.vue.mjs +1591 -1612
- package/dist/es/components/pro-contract-template-designer/src/ProContractTemplateRenderer.vue.mjs +235 -239
- package/dist/es/components/pro-contract-template-designer/src/SigningPlacementLayer.vue.mjs +16 -16
- package/dist/es/components/pro-contract-template-designer/src/composables/use-template-designer.mjs +166 -166
- package/dist/es/components/pro-contract-template-designer/src/composables/use-template-draft-cache.mjs +100 -33
- package/dist/es/components/pro-contract-template-designer/src/composables/use-template-files.mjs +77 -0
- package/dist/es/components/pro-contract-template-designer/src/extensions/word-paste.mjs +23 -23
- package/dist/es/components/pro-contract-template-designer/src/utils/file-tabs.mjs +14 -0
- package/dist/es/components/pro-contract-template-designer/src/utils/template-renderer.mjs +121 -121
- package/dist/es/components/pro-contract-template-designer/src/utils/toolbar-overflow.mjs +19 -0
- package/dist/es/components/pro-contract-template-designer/style/index.css +1 -1
- package/dist/es/index.mjs +23 -21
- package/dist/lib/components/contract-signing-location/index.cjs +1 -1
- package/dist/lib/components/contract-signing-location/src/ContractSigningLocation.vue.cjs +1 -1
- package/dist/lib/components/contract-signing-location/src/ContractSigningLocationCanvas.vue.cjs +1 -1
- package/dist/lib/components/contract-signing-location/src/ContractSigningLocationInspector.vue.cjs +1 -1
- package/dist/lib/components/contract-signing-location/src/ContractSigningLocationNavigator.vue.cjs +1 -1
- package/dist/lib/components/contract-signing-location/src/ContractSigningTemplatePage.cjs +1 -0
- package/dist/lib/components/contract-signing-location/src/ContractSigningTemplatePage.vue.cjs +1 -0
- package/dist/lib/components/contract-signing-location/src/location-rules.cjs +1 -1
- package/dist/lib/components/contract-signing-location/src/template-source.cjs +1 -0
- package/dist/lib/components/contract-signing-location/style/index.css +1 -1
- package/dist/lib/components/index.cjs +1 -1
- package/dist/lib/components/pro-contract-signing-flow/src/ContractSigningFlowCanvas.vue.cjs +1 -1
- package/dist/lib/components/pro-contract-signing-flow/src/ContractSigningFlowInspector.vue.cjs +1 -1
- package/dist/lib/components/pro-contract-signing-flow/src/ContractSigningFlowNodeCard.vue.cjs +1 -1
- package/dist/lib/components/pro-contract-signing-flow/src/ProContractSigningFlow.vue.cjs +1 -1
- package/dist/lib/components/pro-contract-signing-flow/src/constants.cjs +1 -1
- package/dist/lib/components/pro-contract-signing-flow/style/index.css +1 -1
- package/dist/lib/components/pro-contract-template-designer/index.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplateDesignerInspector.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplateDesignerInspector.vue.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplateDesignerSidebar.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplateDesignerSidebar.vue.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplateFileBar.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplateFileBar.vue.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplateRendererField.vue.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplateRendererValidation.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplateRendererValidation.vue.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/DesignerPage.vue.cjs +2 -2
- package/dist/lib/components/pro-contract-template-designer/src/ProContractTemplateDesigner.vue.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/ProContractTemplateRenderer.vue.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/SigningPlacementLayer.vue.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/composables/use-template-designer.cjs +2 -2
- package/dist/lib/components/pro-contract-template-designer/src/composables/use-template-draft-cache.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/composables/use-template-files.cjs +2 -0
- package/dist/lib/components/pro-contract-template-designer/src/extensions/word-paste.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/utils/file-tabs.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/utils/template-renderer.cjs +2 -2
- package/dist/lib/components/pro-contract-template-designer/src/utils/toolbar-overflow.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/style/index.css +1 -1
- package/dist/lib/index.cjs +1 -1
- package/dist/theme/contract-signing-location.css +1 -1
- package/dist/theme/icon.css +1 -1
- package/dist/theme/index.css +1 -1
- package/dist/theme/pro-contract-signing-flow.css +1 -1
- package/dist/types/components/contract-signing-location/index.d.ts +1 -0
- package/dist/types/components/contract-signing-location/src/ContractSigningLocation.vue.d.ts +4 -1
- package/dist/types/components/contract-signing-location/src/ContractSigningLocationInspector.vue.d.ts +3 -2
- package/dist/types/components/contract-signing-location/src/ContractSigningTemplatePage.vue.d.ts +6 -0
- package/dist/types/components/contract-signing-location/src/location-rules.d.ts +3 -3
- package/dist/types/components/contract-signing-location/src/template-source.d.ts +20 -0
- package/dist/types/components/contract-signing-location/src/types.d.ts +49 -2
- package/dist/types/components/pro-contract-signing-flow/src/ContractSigningFlowCanvas.vue.d.ts +19 -3
- package/dist/types/components/pro-contract-signing-flow/src/ProContractSigningFlow.vue.d.ts +223 -2
- package/dist/types/components/pro-contract-signing-flow/src/constants.d.ts +15 -0
- package/dist/types/components/pro-contract-signing-flow/src/types.d.ts +14 -0
- package/dist/types/components/pro-contract-template-designer/index.d.ts +1 -0
- package/dist/types/components/pro-contract-template-designer/src/ContractTemplateDesignerInspector.vue.d.ts +103 -0
- package/dist/types/components/pro-contract-template-designer/src/ContractTemplateDesignerSidebar.vue.d.ts +48 -0
- package/dist/types/components/pro-contract-template-designer/src/ContractTemplateFileBar.vue.d.ts +231 -0
- package/dist/types/components/pro-contract-template-designer/src/ContractTemplateRendererValidation.vue.d.ts +15 -0
- package/dist/types/components/pro-contract-template-designer/src/DesignerPage.vue.d.ts +1 -1
- package/dist/types/components/pro-contract-template-designer/src/ProContractTemplateDesigner.vue.d.ts +25 -2
- package/dist/types/components/pro-contract-template-designer/src/SigningPlacementInspector.vue.d.ts +2 -2
- package/dist/types/components/pro-contract-template-designer/src/composables/use-template-designer.d.ts +1 -1
- package/dist/types/components/pro-contract-template-designer/src/composables/use-template-draft-cache.d.ts +29 -1
- package/dist/types/components/pro-contract-template-designer/src/composables/use-template-files.d.ts +24 -0
- package/dist/types/components/pro-contract-template-designer/src/constants.d.ts +2 -2
- package/dist/types/components/pro-contract-template-designer/src/types.d.ts +59 -1
- package/dist/types/components/pro-contract-template-designer/src/utils/file-tabs.d.ts +3 -0
- package/dist/types/components/pro-contract-template-designer/src/utils/toolbar-overflow.d.ts +11 -0
- package/package.json +4 -3
package/dist/es/components/pro-contract-template-designer/src/composables/use-template-designer.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
1
|
+
import { isContractTemplateFieldType as e } from "../types.mjs";
|
|
2
|
+
import { canUseDomHtml as t, createElementAttributeReader as n, createTagAttributeReader as r, escapeHtmlAttribute as i, escapeHtmlText as a, forEachHtmlTag as o, readNumberAttribute as s, readOptionalBoolean as c, readOptionalNumber as l, replaceTemplateVariableSpans as u } from "../utils/html.mjs";
|
|
3
|
+
import { normalizeSigningPlacements as d, scaleSigningPlacementToPage as ee, validateSigningPlacements as te } from "../utils/signing-placement.mjs";
|
|
4
|
+
import { DEFAULT_CONTRACT_FONT_FAMILY as ne } from "../constants.mjs";
|
|
5
|
+
import { resolveTemplateVariablePresentation as re } from "../utils/template-variable-render.mjs";
|
|
6
6
|
//#region src/components/pro-contract-template-designer/src/composables/use-template-designer.ts
|
|
7
|
-
var
|
|
7
|
+
var f = [
|
|
8
8
|
{
|
|
9
9
|
format: "A0",
|
|
10
10
|
width: 3178,
|
|
@@ -53,22 +53,22 @@ var p = [
|
|
|
53
53
|
height: 1344,
|
|
54
54
|
label: "Legal"
|
|
55
55
|
}
|
|
56
|
-
],
|
|
56
|
+
], p = { ...f[4] }, m = {
|
|
57
57
|
color: "#1f2937",
|
|
58
58
|
background: "transparent",
|
|
59
59
|
fontSize: 14,
|
|
60
|
-
fontFamily:
|
|
60
|
+
fontFamily: ne,
|
|
61
61
|
placeholderColor: "#7a818b",
|
|
62
62
|
lineColor: "#565b66",
|
|
63
63
|
textAlign: "left",
|
|
64
64
|
borderStyle: "solid",
|
|
65
65
|
objectFit: "contain"
|
|
66
|
-
},
|
|
67
|
-
function
|
|
66
|
+
}, ie = 3, h = 28, g = "contract-template-renderer-1.0.0", _ = "contract-render-css-1.0.0";
|
|
67
|
+
function v(e) {
|
|
68
68
|
let t = Number(e);
|
|
69
|
-
return Number.isFinite(t) && t >= 1 ? Math.max(1, Math.floor(t)) :
|
|
69
|
+
return Number.isFinite(t) && t >= 1 ? Math.max(1, Math.floor(t)) : 20;
|
|
70
70
|
}
|
|
71
|
-
var
|
|
71
|
+
var y = [
|
|
72
72
|
{
|
|
73
73
|
type: "text",
|
|
74
74
|
label: "输入框",
|
|
@@ -99,11 +99,11 @@ var b = [
|
|
|
99
99
|
defaultWidth: 96,
|
|
100
100
|
defaultHeight: 28
|
|
101
101
|
}
|
|
102
|
-
],
|
|
103
|
-
function
|
|
104
|
-
return
|
|
102
|
+
], b = 0;
|
|
103
|
+
function x(e) {
|
|
104
|
+
return b += 1, `${e}-${Date.now().toString(36)}-${b.toString(36)}`;
|
|
105
105
|
}
|
|
106
|
-
function
|
|
106
|
+
function S(e) {
|
|
107
107
|
let t = JSON.parse(JSON.stringify(e));
|
|
108
108
|
return Array.isArray(t.signingPlacements) && (t.signingPlacements = t.signingPlacements.map((e) => ({
|
|
109
109
|
id: e.id,
|
|
@@ -117,14 +117,14 @@ function C(e) {
|
|
|
117
117
|
...e.sealTypes?.length ? { sealTypes: [...e.sealTypes] } : {}
|
|
118
118
|
}))), t;
|
|
119
119
|
}
|
|
120
|
-
function
|
|
121
|
-
return
|
|
120
|
+
function C(e) {
|
|
121
|
+
return f.find((t) => t.format === e);
|
|
122
122
|
}
|
|
123
|
-
function
|
|
124
|
-
if (e) return e.format && e.format !== "Custom" ? e.format :
|
|
123
|
+
function w(e) {
|
|
124
|
+
if (e) return e.format && e.format !== "Custom" ? e.format : f.find((t) => t.width === e.width && t.height === e.height)?.format;
|
|
125
125
|
}
|
|
126
|
-
function
|
|
127
|
-
let n =
|
|
126
|
+
function T(e, t = p) {
|
|
127
|
+
let n = w(t) ?? t.format, r = e?.format ?? w(e) ?? n ?? "Custom", i = r === "Custom" ? void 0 : C(r), a = A(i?.width ?? e?.width, t.width), o = A(i?.height ?? e?.height, t.height);
|
|
128
128
|
return {
|
|
129
129
|
format: i?.format ?? r,
|
|
130
130
|
width: a,
|
|
@@ -132,22 +132,22 @@ function E(e, t = m) {
|
|
|
132
132
|
label: e?.label ?? i?.label ?? t.label ?? r
|
|
133
133
|
};
|
|
134
134
|
}
|
|
135
|
-
function
|
|
135
|
+
function E(e) {
|
|
136
136
|
return `${e.format ?? "Custom"}:${e.width}:${e.height}`;
|
|
137
137
|
}
|
|
138
|
-
function
|
|
139
|
-
let t = (Array.isArray(e) ? e :
|
|
138
|
+
function D(e) {
|
|
139
|
+
let t = (Array.isArray(e) ? e : f).map((e) => {
|
|
140
140
|
let t = Number(e?.width), n = Number(e?.height);
|
|
141
141
|
if (!Number.isFinite(t) || t <= 0 || !Number.isFinite(n) || n <= 0) return;
|
|
142
142
|
let r = e?.format;
|
|
143
143
|
if (r && r !== "Custom") {
|
|
144
|
-
let t =
|
|
144
|
+
let t = C(r);
|
|
145
145
|
return t ? {
|
|
146
146
|
...t,
|
|
147
147
|
label: e.label ?? t.label
|
|
148
148
|
} : void 0;
|
|
149
149
|
}
|
|
150
|
-
let i = r ? void 0 :
|
|
150
|
+
let i = r ? void 0 : w(e), a = i ? C(i) : void 0;
|
|
151
151
|
if (a) return {
|
|
152
152
|
...a,
|
|
153
153
|
label: e.label ?? a.label
|
|
@@ -161,19 +161,19 @@ function O(e) {
|
|
|
161
161
|
label: e.label ?? "Custom"
|
|
162
162
|
};
|
|
163
163
|
}).filter(Boolean), n = /* @__PURE__ */ new Set(), r = t.filter((e) => {
|
|
164
|
-
let t =
|
|
164
|
+
let t = E(e);
|
|
165
165
|
return n.has(t) ? !1 : (n.add(t), !0);
|
|
166
166
|
});
|
|
167
|
-
return (r.length ? r :
|
|
167
|
+
return (r.length ? r : f).map((e) => ({ ...e }));
|
|
168
168
|
}
|
|
169
|
-
function
|
|
170
|
-
let n =
|
|
171
|
-
return t.find((e) =>
|
|
169
|
+
function O(e, t) {
|
|
170
|
+
let n = E(e);
|
|
171
|
+
return t.find((e) => E(e) === n);
|
|
172
172
|
}
|
|
173
|
-
function
|
|
174
|
-
let n =
|
|
175
|
-
let t =
|
|
176
|
-
return
|
|
173
|
+
function k(e, t) {
|
|
174
|
+
let n = D(t), r = n[0], i = T(e.pageSize, r), a = O(i, n) ?? r, o = /* @__PURE__ */ new Map(), s = e.pages.map((e) => {
|
|
175
|
+
let t = T(e.pageSize, i), a = O(t, n) ?? r;
|
|
176
|
+
return E(t) !== E(a) && o.set(e.id, {
|
|
177
177
|
source: t,
|
|
178
178
|
target: a
|
|
179
179
|
}), {
|
|
@@ -182,7 +182,7 @@ function ie(e, t) {
|
|
|
182
182
|
};
|
|
183
183
|
}), c = [], l = (e.signingPlacements ?? []).map((e) => {
|
|
184
184
|
let t = o.get(e.pageId);
|
|
185
|
-
return t ? (c.push(e.id),
|
|
185
|
+
return t ? (c.push(e.id), ee(e, t.source, t.target)) : e;
|
|
186
186
|
});
|
|
187
187
|
return {
|
|
188
188
|
value: {
|
|
@@ -200,23 +200,23 @@ function A(e, t) {
|
|
|
200
200
|
}
|
|
201
201
|
function j(e = 1, t) {
|
|
202
202
|
return {
|
|
203
|
-
id:
|
|
203
|
+
id: x("page"),
|
|
204
204
|
title: `第 ${e} 页`,
|
|
205
|
-
pageSize: t ?
|
|
205
|
+
pageSize: t ? T(t) : void 0,
|
|
206
206
|
contentHtml: "<p>请输入合同正文,也可以从 WPS / Word 复制内容粘贴到这里。</p>"
|
|
207
207
|
};
|
|
208
208
|
}
|
|
209
209
|
function M(e = 1, t, n = "<p></p>", r) {
|
|
210
210
|
return {
|
|
211
|
-
id:
|
|
211
|
+
id: x("page"),
|
|
212
212
|
title: `第 ${e} 页`,
|
|
213
|
-
pageSize: t ?
|
|
213
|
+
pageSize: t ? T(t) : void 0,
|
|
214
214
|
contentHtml: n,
|
|
215
215
|
contentJson: r
|
|
216
216
|
};
|
|
217
217
|
}
|
|
218
|
-
function N(e =
|
|
219
|
-
let t =
|
|
218
|
+
function N(e = p) {
|
|
219
|
+
let t = T(e);
|
|
220
220
|
return {
|
|
221
221
|
pages: [j(1, t)],
|
|
222
222
|
variables: [],
|
|
@@ -224,8 +224,8 @@ function N(e = m) {
|
|
|
224
224
|
signingPlacements: []
|
|
225
225
|
};
|
|
226
226
|
}
|
|
227
|
-
function
|
|
228
|
-
let t =
|
|
227
|
+
function ae(e = p) {
|
|
228
|
+
let t = T(e);
|
|
229
229
|
return {
|
|
230
230
|
pages: [M(1, t, "<p></p>")],
|
|
231
231
|
variables: [],
|
|
@@ -233,13 +233,13 @@ function P(e = m) {
|
|
|
233
233
|
signingPlacements: []
|
|
234
234
|
};
|
|
235
235
|
}
|
|
236
|
-
function
|
|
237
|
-
return t.find((t) => t.type === e) ??
|
|
236
|
+
function P(e, t = y) {
|
|
237
|
+
return t.find((t) => t.type === e) ?? y[0];
|
|
238
238
|
}
|
|
239
|
-
function
|
|
240
|
-
let r = e.type === void 0 ? "text" : e.type, i =
|
|
239
|
+
function F(e, t = y, n = {}) {
|
|
240
|
+
let r = e.type === void 0 ? "text" : e.type, i = P(r, t), a = oe(r);
|
|
241
241
|
return {
|
|
242
|
-
id: e.id ??
|
|
242
|
+
id: e.id ?? x("variable"),
|
|
243
243
|
key: e.key,
|
|
244
244
|
label: e.label ?? i.label ?? e.key,
|
|
245
245
|
type: r,
|
|
@@ -257,14 +257,14 @@ function I(e, t = b, n = {}) {
|
|
|
257
257
|
rows: Math.max(1, Math.round(e.rows ?? 3)),
|
|
258
258
|
lineHeight: Math.max(18, Math.round(e.lineHeight ?? 28)),
|
|
259
259
|
style: {
|
|
260
|
-
...
|
|
260
|
+
...m,
|
|
261
261
|
...a.style,
|
|
262
262
|
...n,
|
|
263
263
|
...e.style
|
|
264
264
|
}
|
|
265
265
|
};
|
|
266
266
|
}
|
|
267
|
-
function
|
|
267
|
+
function oe(e) {
|
|
268
268
|
return e === "date" ? {
|
|
269
269
|
placeholder: "年 月 日",
|
|
270
270
|
format: "YYYY年MM月DD日",
|
|
@@ -306,32 +306,32 @@ function ae(e) {
|
|
|
306
306
|
underline: !0
|
|
307
307
|
} };
|
|
308
308
|
}
|
|
309
|
-
function
|
|
310
|
-
return
|
|
309
|
+
function I(t) {
|
|
310
|
+
return t !== void 0 && !e(t);
|
|
311
311
|
}
|
|
312
|
-
function
|
|
312
|
+
function se(e, t = p) {
|
|
313
313
|
if (!e) return N(t);
|
|
314
|
-
let n =
|
|
315
|
-
id: e.id ||
|
|
314
|
+
let n = T(e.pageSize, t), r = (e.pages?.length ? e.pages : [j(1, n)]).map((e, t) => ({
|
|
315
|
+
id: e.id || x("page"),
|
|
316
316
|
title: e.title || `第 ${t + 1} 页`,
|
|
317
|
-
pageSize:
|
|
317
|
+
pageSize: T(e.pageSize, n),
|
|
318
318
|
contentHtml: e.contentHtml || "<p></p>",
|
|
319
319
|
contentJson: e.contentJson
|
|
320
|
-
})), i = /* @__PURE__ */ new Map(), a = Object.fromEntries(r.map((e) => [e.id,
|
|
320
|
+
})), i = /* @__PURE__ */ new Map(), a = Object.fromEntries(r.map((e) => [e.id, T(e.pageSize, n)]));
|
|
321
321
|
return (e.variables ?? []).forEach((e) => {
|
|
322
|
-
e.key && i.set(e.key,
|
|
322
|
+
e.key && i.set(e.key, F({
|
|
323
323
|
...e,
|
|
324
|
-
id: e.id ||
|
|
324
|
+
id: e.id || x("variable")
|
|
325
325
|
}));
|
|
326
326
|
}), r.forEach((e) => {
|
|
327
|
-
|
|
327
|
+
fe(e).forEach((e) => {
|
|
328
328
|
if (!e.key) return;
|
|
329
329
|
let t = i.get(e.key);
|
|
330
330
|
if (!t) {
|
|
331
|
-
i.set(e.key,
|
|
331
|
+
i.set(e.key, F(e));
|
|
332
332
|
return;
|
|
333
333
|
}
|
|
334
|
-
|
|
334
|
+
I(e.type) && i.set(e.key, F({
|
|
335
335
|
...t,
|
|
336
336
|
type: e.type
|
|
337
337
|
}));
|
|
@@ -340,29 +340,29 @@ function oe(e, t = m) {
|
|
|
340
340
|
pages: r,
|
|
341
341
|
variables: Array.from(i.values()),
|
|
342
342
|
pageSize: n,
|
|
343
|
-
signingPlacements:
|
|
343
|
+
signingPlacements: d(e.signingPlacements, a, n)
|
|
344
344
|
};
|
|
345
345
|
}
|
|
346
|
-
function
|
|
347
|
-
return e.pages.map((t) => `<section ${
|
|
346
|
+
function ce(e) {
|
|
347
|
+
return e.pages.map((t) => `<section ${G(t, e.pageSize)}>${t.contentHtml}</section>`).join("\n");
|
|
348
348
|
}
|
|
349
|
-
function
|
|
350
|
-
return e.pages.map((t) => `<section ${
|
|
349
|
+
function L(e) {
|
|
350
|
+
return e.pages.map((t) => `<section ${G(t, e.pageSize)}>${be(t.contentHtml)}</section>`).join("\n");
|
|
351
351
|
}
|
|
352
|
-
function
|
|
353
|
-
return
|
|
354
|
-
let r =
|
|
355
|
-
return `<section ${
|
|
352
|
+
function R(e) {
|
|
353
|
+
return z(e).map(({ page: t, contentHtml: n }) => {
|
|
354
|
+
let r = T(t.pageSize, e.pageSize);
|
|
355
|
+
return `<section ${G(t, e.pageSize)} style="width:${r.width}px;min-height:${r.height}px">${n}</section>`;
|
|
356
356
|
}).join("\n");
|
|
357
357
|
}
|
|
358
|
-
function
|
|
358
|
+
function z(e) {
|
|
359
359
|
let t = new Map(e.variables.map((e) => [e.key, e])), n = Array.isArray(e.signingPlacements) ? e.signingPlacements : [];
|
|
360
360
|
return e.pages.map((e) => ({
|
|
361
361
|
page: {
|
|
362
362
|
...e,
|
|
363
363
|
...e.pageSize ? { pageSize: { ...e.pageSize } } : {}
|
|
364
364
|
},
|
|
365
|
-
contentHtml:
|
|
365
|
+
contentHtml: me(e.contentHtml, t),
|
|
366
366
|
signingPlacements: n.filter((t) => t.pageId === e.id).map((e) => ({
|
|
367
367
|
id: e.id,
|
|
368
368
|
pageId: e.pageId,
|
|
@@ -376,16 +376,16 @@ function B(e) {
|
|
|
376
376
|
}))
|
|
377
377
|
}));
|
|
378
378
|
}
|
|
379
|
-
function
|
|
380
|
-
let t =
|
|
379
|
+
function B(e) {
|
|
380
|
+
let t = S(e);
|
|
381
381
|
return {
|
|
382
382
|
...t,
|
|
383
|
-
rendererVersion:
|
|
384
|
-
styleVersion:
|
|
385
|
-
html:
|
|
383
|
+
rendererVersion: g,
|
|
384
|
+
styleVersion: _,
|
|
385
|
+
html: L(t)
|
|
386
386
|
};
|
|
387
387
|
}
|
|
388
|
-
function
|
|
388
|
+
function V(e, t = {}) {
|
|
389
389
|
let n = [], r = /* @__PURE__ */ new Map();
|
|
390
390
|
typeof t.maxPages == "number" && e.pages.length > t.maxPages && n.push({
|
|
391
391
|
type: "page",
|
|
@@ -406,7 +406,7 @@ function H(e, t = {}) {
|
|
|
406
406
|
message: `变量标识 ${e.key} 重复`
|
|
407
407
|
}), r.set(e.key, e.id);
|
|
408
408
|
}
|
|
409
|
-
|
|
409
|
+
I(e.type) && n.push({
|
|
410
410
|
type: "variable",
|
|
411
411
|
id: e.id,
|
|
412
412
|
variableKey: e.key,
|
|
@@ -416,7 +416,7 @@ function H(e, t = {}) {
|
|
|
416
416
|
});
|
|
417
417
|
let i = new Set(e.variables.map((e) => e.key).filter(Boolean)), a = /* @__PURE__ */ new Set();
|
|
418
418
|
return e.pages.forEach((e) => {
|
|
419
|
-
|
|
419
|
+
H(e).forEach((t) => {
|
|
420
420
|
a.add(t), i.has(t) || n.push({
|
|
421
421
|
type: "variable",
|
|
422
422
|
id: e.id,
|
|
@@ -429,14 +429,14 @@ function H(e, t = {}) {
|
|
|
429
429
|
id: e.id,
|
|
430
430
|
message: `${e.label || e.key} 缺少对应正文变量节点`
|
|
431
431
|
});
|
|
432
|
-
}), n.push(...
|
|
432
|
+
}), n.push(...te(e)), n;
|
|
433
433
|
}
|
|
434
|
-
function
|
|
434
|
+
function H(e) {
|
|
435
435
|
let t = /* @__PURE__ */ new Set();
|
|
436
436
|
function n(e) {
|
|
437
437
|
if (!e || typeof e != "object") return;
|
|
438
438
|
let r = e;
|
|
439
|
-
|
|
439
|
+
U(r.type) && r.attrs?.key && t.add(r.attrs.key), r.content?.forEach(n);
|
|
440
440
|
}
|
|
441
441
|
n(e.contentJson);
|
|
442
442
|
let r = e.contentHtml || "", i = /data-template-variable=["']true["'][^>]*data-key=["']([^"']+)["']|data-key=["']([^"']+)["'][^>]*data-template-variable=["']true["']/g, a = i.exec(r);
|
|
@@ -446,23 +446,23 @@ function U(e) {
|
|
|
446
446
|
}
|
|
447
447
|
return t;
|
|
448
448
|
}
|
|
449
|
-
function
|
|
449
|
+
function U(e) {
|
|
450
450
|
return e === "templateVariable" || e === "templateField";
|
|
451
451
|
}
|
|
452
|
-
function
|
|
452
|
+
function W(e) {
|
|
453
453
|
let t = /* @__PURE__ */ new Set();
|
|
454
454
|
return e.pages.forEach((e) => {
|
|
455
|
-
|
|
455
|
+
H(e).forEach((e) => t.add(e));
|
|
456
456
|
}), t;
|
|
457
457
|
}
|
|
458
|
-
function
|
|
459
|
-
let t =
|
|
458
|
+
function le(e) {
|
|
459
|
+
let t = W(e);
|
|
460
460
|
return {
|
|
461
461
|
...e,
|
|
462
462
|
variables: e.variables.filter((e) => e.key && t.has(e.key))
|
|
463
463
|
};
|
|
464
464
|
}
|
|
465
|
-
function
|
|
465
|
+
function ue(e, t, n) {
|
|
466
466
|
let r = e ?? [];
|
|
467
467
|
if (r.length <= 1 || n <= 0) return;
|
|
468
468
|
let i = Math.min(r.length, t.length), a = -1;
|
|
@@ -479,47 +479,47 @@ function le(e, t, n) {
|
|
|
479
479
|
overflowContent: r.slice(a)
|
|
480
480
|
};
|
|
481
481
|
}
|
|
482
|
-
function
|
|
483
|
-
let n =
|
|
482
|
+
function G(e, t) {
|
|
483
|
+
let n = T(e.pageSize, t);
|
|
484
484
|
return [
|
|
485
485
|
"class=\"gd-contract-template-page\"",
|
|
486
|
-
`data-page-id="${
|
|
487
|
-
`data-page-format="${
|
|
488
|
-
`data-page-label="${
|
|
486
|
+
`data-page-id="${i(e.id)}"`,
|
|
487
|
+
`data-page-format="${i(n.format ?? "Custom")}"`,
|
|
488
|
+
`data-page-label="${i(n.label ?? n.format ?? "自定义")}"`,
|
|
489
489
|
`data-page-width="${n.width}"`,
|
|
490
490
|
`data-page-height="${n.height}"`
|
|
491
491
|
].join(" ");
|
|
492
492
|
}
|
|
493
|
-
var
|
|
494
|
-
function
|
|
495
|
-
let
|
|
493
|
+
var de = /<span\b[^>]*data-template-variable=["']true["'][^>]*>/g;
|
|
494
|
+
function fe(e) {
|
|
495
|
+
let i = /* @__PURE__ */ new Map();
|
|
496
496
|
function a(e) {
|
|
497
497
|
if (!e.key) return;
|
|
498
|
-
let
|
|
499
|
-
(!
|
|
498
|
+
let t = i.get(e.key);
|
|
499
|
+
(!t || I(e.type) && !I(t.type)) && i.set(e.key, e);
|
|
500
500
|
}
|
|
501
|
-
function
|
|
501
|
+
function s(e) {
|
|
502
502
|
if (!e || typeof e != "object") return;
|
|
503
503
|
let t = e;
|
|
504
|
-
t.type === "templateVariable" && typeof t.attrs?.key == "string" && a(
|
|
504
|
+
t.type === "templateVariable" && typeof t.attrs?.key == "string" && a(pe(t.attrs, t.attrs.key)), t.content?.forEach(s);
|
|
505
505
|
}
|
|
506
|
-
|
|
506
|
+
s(e.contentJson);
|
|
507
507
|
let c = e.contentHtml || "";
|
|
508
|
-
return
|
|
509
|
-
a(
|
|
510
|
-
}) :
|
|
511
|
-
a(
|
|
512
|
-
}), Array.from(
|
|
508
|
+
return t() ? new DOMParser().parseFromString(c, "text/html").querySelectorAll("[data-template-variable]").forEach((e) => {
|
|
509
|
+
a(K(n(e)));
|
|
510
|
+
}) : o(c, de, (e) => {
|
|
511
|
+
a(K(r(e)));
|
|
512
|
+
}), Array.from(i.values());
|
|
513
513
|
}
|
|
514
|
-
function
|
|
514
|
+
function K(e) {
|
|
515
515
|
let t = e("data-key") ?? "", n = e("data-variable-type"), r = e("data-precision"), i = e("data-use-grouping");
|
|
516
516
|
return {
|
|
517
517
|
key: t,
|
|
518
518
|
label: e("data-label") ?? t,
|
|
519
519
|
type: n ?? "text",
|
|
520
520
|
placeholder: e("data-placeholder") ?? "",
|
|
521
|
-
width:
|
|
522
|
-
height:
|
|
521
|
+
width: s(e("data-width"), 160),
|
|
522
|
+
height: s(e("data-height"), 32),
|
|
523
523
|
required: e("data-required") === "true",
|
|
524
524
|
defaultValue: e("data-default-value") ?? "",
|
|
525
525
|
format: e("data-format") ?? "",
|
|
@@ -528,14 +528,14 @@ function q(e) {
|
|
|
528
528
|
checkedText: e("data-checked-text") ?? "",
|
|
529
529
|
uncheckedText: e("data-unchecked-text") ?? "",
|
|
530
530
|
multiline: e("data-multiline") === "true",
|
|
531
|
-
rows:
|
|
532
|
-
lineHeight:
|
|
531
|
+
rows: s(e("data-rows"), 3),
|
|
532
|
+
lineHeight: s(e("data-line-height"), 28),
|
|
533
533
|
style: {
|
|
534
|
-
border:
|
|
535
|
-
underline:
|
|
534
|
+
border: c(e("data-border")),
|
|
535
|
+
underline: c(e("data-underline")),
|
|
536
536
|
color: e("data-color"),
|
|
537
537
|
background: e("data-background"),
|
|
538
|
-
fontSize:
|
|
538
|
+
fontSize: s(e("data-font-size"), 14),
|
|
539
539
|
fontFamily: e("data-font-family"),
|
|
540
540
|
placeholderColor: e("data-placeholder-color"),
|
|
541
541
|
lineColor: e("data-line-color"),
|
|
@@ -545,15 +545,15 @@ function q(e) {
|
|
|
545
545
|
}
|
|
546
546
|
};
|
|
547
547
|
}
|
|
548
|
-
function
|
|
548
|
+
function pe(e, t) {
|
|
549
549
|
let n = (t) => typeof e[t] == "string" ? e[t] : void 0;
|
|
550
550
|
return {
|
|
551
551
|
key: t,
|
|
552
552
|
label: n("label") ?? t,
|
|
553
553
|
type: e.type === void 0 ? "text" : e.type,
|
|
554
554
|
placeholder: n("placeholder") ?? "",
|
|
555
|
-
width:
|
|
556
|
-
height:
|
|
555
|
+
width: s(e.width, 160),
|
|
556
|
+
height: s(e.height, 32),
|
|
557
557
|
required: e.required === !0,
|
|
558
558
|
defaultValue: n("defaultValue") ?? "",
|
|
559
559
|
format: n("format") ?? "",
|
|
@@ -562,14 +562,14 @@ function fe(e, t) {
|
|
|
562
562
|
checkedText: n("checkedText") ?? "",
|
|
563
563
|
uncheckedText: n("uncheckedText") ?? "",
|
|
564
564
|
multiline: e.multiline === !0,
|
|
565
|
-
rows:
|
|
566
|
-
lineHeight:
|
|
565
|
+
rows: s(e.rows, 3),
|
|
566
|
+
lineHeight: s(e.lineHeight, 28),
|
|
567
567
|
style: {
|
|
568
568
|
border: typeof e.border == "boolean" ? e.border : void 0,
|
|
569
569
|
underline: typeof e.underline == "boolean" ? e.underline : void 0,
|
|
570
570
|
color: n("color"),
|
|
571
571
|
background: n("background"),
|
|
572
|
-
fontSize:
|
|
572
|
+
fontSize: s(e.fontSize, 14),
|
|
573
573
|
fontFamily: n("fontFamily"),
|
|
574
574
|
placeholderColor: n("placeholderColor"),
|
|
575
575
|
lineColor: n("lineColor"),
|
|
@@ -579,20 +579,20 @@ function fe(e, t) {
|
|
|
579
579
|
}
|
|
580
580
|
};
|
|
581
581
|
}
|
|
582
|
-
function
|
|
582
|
+
function me(e, n) {
|
|
583
583
|
if (!e) return e;
|
|
584
|
-
if (
|
|
585
|
-
let
|
|
586
|
-
return
|
|
587
|
-
he(e,
|
|
588
|
-
}),
|
|
584
|
+
if (t()) {
|
|
585
|
+
let t = new DOMParser().parseFromString(e, "text/html");
|
|
586
|
+
return q(t), t.querySelectorAll("[data-template-variable]").forEach((e) => {
|
|
587
|
+
he(e, n);
|
|
588
|
+
}), t.body.innerHTML;
|
|
589
589
|
}
|
|
590
|
-
return
|
|
591
|
-
let
|
|
592
|
-
return
|
|
590
|
+
return u(_e(e), (e, t) => {
|
|
591
|
+
let i = r(t);
|
|
592
|
+
return i("data-key") ? ge(i, n) : e;
|
|
593
593
|
});
|
|
594
594
|
}
|
|
595
|
-
function
|
|
595
|
+
function q(e) {
|
|
596
596
|
e.querySelectorAll("script,style,meta,link").forEach((e) => e.remove()), e.querySelectorAll("*").forEach((e) => {
|
|
597
597
|
Array.from(e.attributes).forEach((t) => {
|
|
598
598
|
let n = t.name.toLowerCase(), r = t.value;
|
|
@@ -608,48 +608,48 @@ function me(e) {
|
|
|
608
608
|
});
|
|
609
609
|
});
|
|
610
610
|
}
|
|
611
|
-
function J(e,
|
|
612
|
-
let
|
|
613
|
-
type:
|
|
614
|
-
width:
|
|
615
|
-
height:
|
|
616
|
-
defaultValue:
|
|
617
|
-
placeholder:
|
|
618
|
-
format:
|
|
619
|
-
precision:
|
|
620
|
-
useGrouping:
|
|
621
|
-
checkedText:
|
|
622
|
-
uncheckedText:
|
|
623
|
-
multiline:
|
|
624
|
-
rows:
|
|
625
|
-
lineHeight:
|
|
626
|
-
style: ve(
|
|
611
|
+
function J(e, t) {
|
|
612
|
+
let n = e("data-key") ?? "", r = t.get(n), i = r?.type ?? e("data-variable-type") ?? "text", a = ye(i, r?.defaultValue ?? e("data-default-value") ?? ""), o = re({
|
|
613
|
+
type: i,
|
|
614
|
+
width: r?.width ?? e("data-width"),
|
|
615
|
+
height: r?.height ?? e("data-height"),
|
|
616
|
+
defaultValue: a,
|
|
617
|
+
placeholder: r?.placeholder ?? e("data-placeholder") ?? "",
|
|
618
|
+
format: r?.format ?? e("data-format") ?? "",
|
|
619
|
+
precision: r?.precision ?? l(e("data-precision")),
|
|
620
|
+
useGrouping: r?.useGrouping ?? c(e("data-use-grouping")),
|
|
621
|
+
checkedText: r?.checkedText ?? e("data-checked-text") ?? "",
|
|
622
|
+
uncheckedText: r?.uncheckedText ?? e("data-unchecked-text") ?? "",
|
|
623
|
+
multiline: r?.multiline ?? c(e("data-multiline")) ?? !1,
|
|
624
|
+
rows: r?.rows ?? e("data-rows"),
|
|
625
|
+
lineHeight: r?.lineHeight ?? e("data-line-height"),
|
|
626
|
+
style: ve(r, e)
|
|
627
627
|
});
|
|
628
628
|
return {
|
|
629
|
-
key:
|
|
630
|
-
label:
|
|
631
|
-
presentation:
|
|
632
|
-
text:
|
|
629
|
+
key: n,
|
|
630
|
+
label: r?.label ?? e("data-label") ?? n,
|
|
631
|
+
presentation: o,
|
|
632
|
+
text: o.type === "image" && o.hasDefaultValue ? " " : o.displayText || " "
|
|
633
633
|
};
|
|
634
634
|
}
|
|
635
635
|
function he(e, t) {
|
|
636
|
-
let { key:
|
|
637
|
-
e.setAttribute("data-template-variable", "true"), e.setAttribute("data-key",
|
|
636
|
+
let { key: r, label: i, presentation: a, text: o } = J(n(e), t);
|
|
637
|
+
e.setAttribute("data-template-variable", "true"), e.setAttribute("data-key", r), e.setAttribute("data-label", i), e.setAttribute("data-variable-type", a.type), e.setAttribute("data-width", String(a.width)), e.setAttribute("data-height", String(a.height)), e.setAttribute("data-border", String(a.border)), e.setAttribute("data-underline", String(a.underline)), e.setAttribute("data-color", a.color), e.setAttribute("data-background", a.background), e.setAttribute("data-font-size", String(a.fontSize)), e.setAttribute("data-font-family", a.fontFamily), e.setAttribute("data-placeholder-color", a.placeholderColor), e.setAttribute("data-line-color", a.lineColor), e.setAttribute("data-text-align", a.textAlign), e.setAttribute("data-border-style", a.borderStyle), e.setAttribute("data-object-fit", a.objectFit), e.className = a.classes.join(" "), e.setAttribute("style", a.styleText), e.textContent = o;
|
|
638
638
|
}
|
|
639
639
|
function ge(e, t) {
|
|
640
|
-
let { key: n, label: r, presentation:
|
|
641
|
-
return `<span data-template-variable="true" data-key="${
|
|
640
|
+
let { key: n, label: r, presentation: o, text: s } = J(e, t);
|
|
641
|
+
return `<span data-template-variable="true" data-key="${i(n)}" data-label="${i(r)}" data-variable-type="${i(o.type)}" data-width="${o.width}" data-height="${o.height}" data-border="${o.border}" data-underline="${o.underline}" data-font-family="${i(o.fontFamily)}" class="${i(o.classes.join(" "))}" style="${i(o.styleText)}">${a(s)}</span>`;
|
|
642
642
|
}
|
|
643
643
|
function _e(e) {
|
|
644
644
|
return e.replace(/<\s*(script|style|meta|link)\b[\s\S]*?<\s*\/\s*\1\s*>/gi, "").replace(/<\s*(meta|link)\b[^>]*>/gi, "").replace(/\s+on[a-z]+\s*=\s*(?:"[^"]*"|'[^']*'|[^\s>]+)/gi, "").replace(/\s+srcdoc\s*=\s*(?:"[^"]*"|'[^']*'|[^\s>]+)/gi, "").replace(/\s+(href|src)\s*=\s*(["'])(.*?)\2/gi, (e, t, n, r) => Y(r) ? "" : ` ${t}=${n}${r}${n}`).replace(/\s+style\s*=\s*(["'])(.*?)\1/gi, (e, t, n) => X(n) ? "" : ` style=${t}${n}${t}`);
|
|
645
645
|
}
|
|
646
646
|
function ve(e, t) {
|
|
647
647
|
return {
|
|
648
|
-
border: e?.style?.border ??
|
|
649
|
-
underline: e?.style?.underline ??
|
|
648
|
+
border: e?.style?.border ?? c(t("data-border")),
|
|
649
|
+
underline: e?.style?.underline ?? c(t("data-underline")),
|
|
650
650
|
color: e?.style?.color ?? t("data-color"),
|
|
651
651
|
background: e?.style?.background ?? t("data-background"),
|
|
652
|
-
fontSize: e?.style?.fontSize ??
|
|
652
|
+
fontSize: e?.style?.fontSize ?? l(t("data-font-size")),
|
|
653
653
|
fontFamily: e?.style?.fontFamily ?? t("data-font-family"),
|
|
654
654
|
placeholderColor: e?.style?.placeholderColor ?? t("data-placeholder-color"),
|
|
655
655
|
lineColor: e?.style?.lineColor ?? t("data-line-color"),
|
|
@@ -670,15 +670,15 @@ function X(e) {
|
|
|
670
670
|
}
|
|
671
671
|
function be(e) {
|
|
672
672
|
if (!e) return e;
|
|
673
|
-
if (
|
|
673
|
+
if (t()) {
|
|
674
674
|
let t = new DOMParser().parseFromString(e, "text/html");
|
|
675
675
|
return t.querySelectorAll("[data-template-variable]").forEach((e) => {
|
|
676
676
|
let t = e.dataset.key || "";
|
|
677
677
|
t && (e.textContent = `\${{${t}}}`);
|
|
678
678
|
}), t.body.innerHTML;
|
|
679
679
|
}
|
|
680
|
-
return
|
|
681
|
-
let n =
|
|
680
|
+
return u(e, (e, t) => {
|
|
681
|
+
let n = r(t)("data-key");
|
|
682
682
|
return n ? `<span${t}>\${{${n}}}</span>` : e;
|
|
683
683
|
});
|
|
684
684
|
}
|
|
@@ -701,11 +701,11 @@ function $(e) {
|
|
|
701
701
|
return Ce(e) ? e : void 0;
|
|
702
702
|
}
|
|
703
703
|
function we(e, t = []) {
|
|
704
|
-
let n = [...t, ...
|
|
704
|
+
let n = [...t, ...V(e)], r = /* @__PURE__ */ new Set();
|
|
705
705
|
return n.filter((e) => {
|
|
706
706
|
let t = `${e.code ?? ""}|${e.id}|${e.pageId ?? ""}|${e.message}`;
|
|
707
707
|
return r.has(t) ? !1 : (r.add(t), !0);
|
|
708
708
|
});
|
|
709
709
|
}
|
|
710
710
|
//#endregion
|
|
711
|
-
export {
|
|
711
|
+
export { g as CONTRACT_TEMPLATE_RENDERER_VERSION, _ as CONTRACT_TEMPLATE_STYLE_VERSION, m as DEFAULT_FIELD_STYLE, y as DEFAULT_FIELD_TYPES, h as DEFAULT_MULTILINE_LINE_HEIGHT, ie as DEFAULT_MULTILINE_ROWS, p as DEFAULT_PAGE_SIZE, f as PAGE_SIZE_OPTIONS, L as buildTemplateExpressionHtml, ce as buildTemplateHtml, R as buildTemplatePreviewHtml, z as buildTemplatePreviewPages, S as cloneTemplateValue, we as collectTemplateLocationRuleExportErrors, W as collectTemplateValueVariableKeys, H as collectTemplateVariableKeys, k as constrainTemplatePageSizes, M as createBlankPage, ae as createBlankTemplate, j as createDefaultPage, N as createDefaultTemplate, x as createDesignerId, F as createTemplateVariable, B as exportTemplateValue, O as findPageSizeOption, P as getFieldOption, E as getPageSizeKey, C as getPageSizeOption, w as inferPageFormat, v as normalizeContractTemplateMaxPages, D as normalizePageSizeOptions, se as normalizeTemplateValue, T as resolvePageSize, ue as splitPageContentByMeasurements, le as syncTemplateVariablesWithPages, V as validateTemplateValue };
|