@guodun/antdv 1.4.8 → 1.5.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/src/ContractSigningLocation.vue.mjs +315 -286
- package/dist/es/components/contract-signing-location/src/ContractSigningLocationCanvas.vue.mjs +316 -285
- package/dist/es/components/contract-signing-location/src/ContractSigningTemplatePage.vue.mjs +62 -54
- package/dist/es/components/contract-signing-location/style/index.css +1 -1
- package/dist/es/components/index.mjs +1 -0
- package/dist/es/components/pro-contract-template-designer/index.mjs +1 -0
- package/dist/es/components/pro-contract-template-designer/src/ContractPrintIframe.mjs +7 -0
- package/dist/es/components/pro-contract-template-designer/src/ContractPrintIframe.vue.mjs +129 -0
- package/dist/es/components/pro-contract-template-designer/src/ContractPrintIframe.vue_vue_type_style_index_0_scoped_a9912ff0_lang.css +1 -0
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplatePreviewModal.vue.mjs +10 -5
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplatePreviewPage.vue.mjs +64 -43
- package/dist/es/components/pro-contract-template-designer/src/ContractTemplateRendererPage.vue.mjs +82 -53
- package/dist/es/components/pro-contract-template-designer/src/DesignerPage.vue.mjs +271 -265
- package/dist/es/components/pro-contract-template-designer/src/ProContractTemplateDesigner.vue.mjs +762 -751
- package/dist/es/components/pro-contract-template-designer/src/ProContractTemplateRenderer.vue.mjs +217 -197
- package/dist/es/components/pro-contract-template-designer/src/constants.mjs +29 -51
- package/dist/es/components/pro-contract-template-designer/src/extensions/template-variable.mjs +103 -103
- package/dist/es/components/pro-contract-template-designer/src/extensions/word-paste.mjs +24 -21
- package/dist/es/components/pro-contract-template-designer/src/utils/contract-print-document.mjs +314 -0
- package/dist/es/components/pro-contract-template-designer/src/utils/page-decorations.mjs +1 -1
- package/dist/es/components/pro-contract-template-designer/src/utils/template-variable-render.mjs +47 -47
- package/dist/es/components/pro-contract-template-designer/src/utils/word-paste.mjs +216 -148
- package/dist/es/components/pro-contract-template-designer/style/index.css +1 -1
- package/dist/es/index.mjs +27 -26
- 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/ContractSigningTemplatePage.vue.cjs +1 -1
- 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-template-designer/index.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/ContractPrintIframe.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/ContractPrintIframe.vue.cjs +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/ContractPrintIframe.vue_vue_type_style_index_0_scoped_a9912ff0_lang.css +1 -0
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplatePreviewModal.vue.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplatePreviewPage.vue.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/ContractTemplateRendererPage.vue.cjs +1 -1
- 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/constants.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/extensions/template-variable.cjs +1 -1
- 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/contract-print-document.cjs +211 -0
- package/dist/lib/components/pro-contract-template-designer/src/utils/page-decorations.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/utils/template-variable-render.cjs +1 -1
- package/dist/lib/components/pro-contract-template-designer/src/utils/word-paste.cjs +2 -2
- 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/types/components/contract-signing-location/src/ContractSigningLocation.vue.d.ts +7 -0
- package/dist/types/components/contract-signing-location/src/ContractSigningLocationCanvas.vue.d.ts +4 -0
- package/dist/types/components/contract-signing-location/src/ContractSigningTemplatePage.vue.d.ts +9 -3
- package/dist/types/components/contract-signing-location/src/types.d.ts +5 -0
- package/dist/types/components/pro-contract-template-designer/index.d.ts +1 -0
- package/dist/types/components/pro-contract-template-designer/src/ContractPrintIframe.vue.d.ts +35 -0
- package/dist/types/components/pro-contract-template-designer/src/ContractTemplateDesignerToolbar.vue.d.ts +2 -2
- package/dist/types/components/pro-contract-template-designer/src/ContractTemplatePreviewModal.vue.d.ts +1 -0
- package/dist/types/components/pro-contract-template-designer/src/ContractTemplatePreviewPage.vue.d.ts +1 -0
- package/dist/types/components/pro-contract-template-designer/src/ContractTemplateRendererPage.vue.d.ts +13 -1
- package/dist/types/components/pro-contract-template-designer/src/DesignerPage.vue.d.ts +6 -0
- package/dist/types/components/pro-contract-template-designer/src/ProContractTemplateDesigner.vue.d.ts +1 -0
- package/dist/types/components/pro-contract-template-designer/src/ProContractTemplateRenderer.vue.d.ts +1 -0
- package/dist/types/components/pro-contract-template-designer/src/constants.d.ts +4 -4
- package/dist/types/components/pro-contract-template-designer/src/extensions/word-paste.d.ts +8 -0
- package/dist/types/components/pro-contract-template-designer/src/types.d.ts +10 -0
- package/dist/types/components/pro-contract-template-designer/src/utils/contract-print-document.d.ts +119 -0
- package/dist/types/components/pro-contract-template-designer/src/utils/word-paste.d.ts +2 -0
- package/package.json +4 -3
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import "../../pro-contract-template-designer/src/utils/contract-print-document.mjs";
|
|
1
2
|
import { CONTRACT_SIGNING_SEAL_TYPE_OPTIONS as e } from "./constants.mjs";
|
|
2
3
|
import { clampContractSigningPlacement as t, clampContractSigningZoom as n, normalizeContractSigningCoordinateScale as r, resolveContractSigningSealSizeLimit as i } from "./coordinates.mjs";
|
|
3
4
|
import { isContractSigningTemplateFile as a } from "./template-source.mjs";
|
|
@@ -6,15 +7,15 @@ import ce from "./ContractSigningLocationCanvas.mjs";
|
|
|
6
7
|
import le from "./ContractSigningLocationInspector.mjs";
|
|
7
8
|
import ue from "./ContractSigningLocationNavigator.mjs";
|
|
8
9
|
import { ContractSigningPreviewRequests as de } from "./preview-requests.mjs";
|
|
9
|
-
import { computed as d, createBlock as f, createCommentVNode as p, createElementBlock as
|
|
10
|
-
import { Button as
|
|
11
|
-
import { LeftOutlined as
|
|
10
|
+
import { computed as d, createBlock as f, createCommentVNode as p, createElementBlock as m, createElementVNode as h, createTextVNode as fe, createVNode as g, defineComponent as pe, nextTick as _, normalizeClass as me, normalizeStyle as he, onBeforeUnmount as ge, openBlock as v, ref as y, shallowRef as b, toDisplayString as _e, unref as x, watch as S, withCtx as C } from "vue";
|
|
11
|
+
import { Button as w, Tooltip as ve } from "ant-design-vue";
|
|
12
|
+
import { LeftOutlined as ye, ReloadOutlined as be, RightOutlined as xe } from "@ant-design/icons-vue";
|
|
12
13
|
//#region src/components/contract-signing-location/src/ContractSigningLocation.vue?vue&type=script&setup=true&lang.ts
|
|
13
|
-
var
|
|
14
|
+
var Se = { class: "gd-ant-contract-signing-location__header" }, Ce = { class: "gd-ant-contract-signing-location__title" }, we = { class: "gd-ant-contract-signing-location__header-actions" }, Te = { class: "gd-ant-contract-signing-location__placement-count" }, Ee = {
|
|
14
15
|
key: 0,
|
|
15
16
|
class: "gd-ant-contract-signing-location__error",
|
|
16
17
|
role: "alert"
|
|
17
|
-
},
|
|
18
|
+
}, De = ["aria-label", "aria-expanded"], Oe = { class: "gd-ant-contract-signing-location__panel-stack" }, ke = ["aria-label", "aria-expanded"], Ae = { class: "gd-ant-contract-signing-location__panel-stack" }, je = /* @__PURE__ */ pe({
|
|
18
19
|
name: "ContractSigningLocation",
|
|
19
20
|
__name: "ContractSigningLocation",
|
|
20
21
|
props: {
|
|
@@ -58,7 +59,8 @@ var xe = { class: "gd-ant-contract-signing-location__header" }, Se = { class: "g
|
|
|
58
59
|
showInspector: {
|
|
59
60
|
type: Boolean,
|
|
60
61
|
default: void 0
|
|
61
|
-
}
|
|
62
|
+
},
|
|
63
|
+
contractFontBaseUrl: { default: void 0 }
|
|
62
64
|
},
|
|
63
65
|
emits: [
|
|
64
66
|
"update:modelValue",
|
|
@@ -70,117 +72,119 @@ var xe = { class: "gd-ant-contract-signing-location__header" }, Se = { class: "g
|
|
|
70
72
|
"submit",
|
|
71
73
|
"error"
|
|
72
74
|
],
|
|
73
|
-
setup(e, { expose: pe, emit:
|
|
74
|
-
let
|
|
75
|
-
sealSizeLimit:
|
|
76
|
-
sealTypeOptions:
|
|
77
|
-
}),
|
|
75
|
+
setup(e, { expose: pe, emit: je }) {
|
|
76
|
+
let T = e, E = je, D = d(() => i(T.sealMinSize, T.sealMaxSize)), O = u(T.modelValue ?? c(T.contractId), {
|
|
77
|
+
sealSizeLimit: D.value,
|
|
78
|
+
sealTypeOptions: T.sealTypeOptions
|
|
79
|
+
}), k = b(O), Me = b(s(O)), A = b(O.files[0]?.fileId ?? ""), j = b(O.files[0]?.pages[0]?.pageIndex ?? 0), M = b(""), N = b(!1), P = b(""), F = y([]), I = y({}), L = b(Je(T.zoom)), R = y(null), z = y(!1), B = y(!1), V = b("loading"), Ne = b(""), H = 0, U = !1, Pe, W = [], Fe = 0, G = new de(), K = d(() => T.mode === "preview"), Ie = d(() => K.value || T.readonly || T.disabled), Le = d(() => T.showInspector ?? !K.value), Re = d(() => !K.value && T.showSubmitButton), ze = d(() => k.value.files.length <= 1), Be = d(() => Ot(T.height)), q = d(() => k.value.files.find((e) => e.fileId === A.value) ?? k.value.files[0]), J = d(() => a(q.value) && V.value !== "ready"), Y = d(() => Ie.value || J.value), Ve = d(() => q.value?.pages.find((e) => e.pageIndex === j.value) ?? q.value?.pages[0]), He = d(() => {
|
|
80
|
+
let e = q.value;
|
|
81
|
+
return e ? k.value.placements.filter((t) => t.fileId === e.fileId) : [];
|
|
82
|
+
}), X = d(() => k.value.placements.find((e) => e.id === M.value)), Ue = d(() => {
|
|
78
83
|
let e = X.value;
|
|
79
|
-
return e ?
|
|
80
|
-
}),
|
|
81
|
-
let e = Z.value;
|
|
82
|
-
return e ? l(A.value, e.fileId, e.pageIndex) ?? Ie.value : Ie.value;
|
|
83
|
-
}), ze = d(() => I.value.filter((e) => e.endsWith(":thumbnail")).map((e) => e.slice(0, -10))), Be = d(() => Object.keys(L.value).filter((e) => e.endsWith(":thumbnail")).map((e) => e.slice(0, -10))), Ve = d(() => I.value.filter((e) => e.endsWith(":preview")).map((e) => e.slice(0, -8))), He = d(() => {
|
|
84
|
+
return e ? l(k.value, e.fileId, e.pageIndex) ?? Ve.value : Ve.value;
|
|
85
|
+
}), We = d(() => F.value.filter((e) => e.endsWith(":thumbnail")).map((e) => e.slice(0, -10))), Ge = d(() => Object.keys(I.value).filter((e) => e.endsWith(":thumbnail")).map((e) => e.slice(0, -10))), Ke = d(() => F.value.filter((e) => e.endsWith(":preview")).map((e) => e.slice(0, -8))), qe = d(() => {
|
|
84
86
|
let e = {};
|
|
85
|
-
return Object.entries(
|
|
87
|
+
return Object.entries(I.value).forEach(([t, n]) => {
|
|
86
88
|
t.endsWith(":preview") && (e[t.slice(0, -8)] = n);
|
|
87
89
|
}), e;
|
|
88
90
|
});
|
|
89
|
-
|
|
91
|
+
S(() => T.modelValue, (e) => {
|
|
90
92
|
if (!e) return;
|
|
91
93
|
let t = u(e, {
|
|
92
|
-
sealSizeLimit:
|
|
93
|
-
sealTypeOptions:
|
|
94
|
+
sealSizeLimit: D.value,
|
|
95
|
+
sealTypeOptions: T.sealTypeOptions
|
|
94
96
|
});
|
|
95
|
-
|
|
96
|
-
}, { deep: !0 }),
|
|
97
|
-
|
|
98
|
-
sealSizeLimit:
|
|
99
|
-
sealTypeOptions:
|
|
100
|
-
})) !==
|
|
101
|
-
}),
|
|
102
|
-
|
|
103
|
-
}),
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
97
|
+
$(t) !== $(k.value) && (Ct(), k.value = t, Me.value = s(t), vt(), _(() => R.value?.scrollToPage(j.value)));
|
|
98
|
+
}, { deep: !0 }), S(D, () => {
|
|
99
|
+
$(u(k.value, {
|
|
100
|
+
sealSizeLimit: D.value,
|
|
101
|
+
sealTypeOptions: T.sealTypeOptions
|
|
102
|
+
})) !== $(k.value) && Z(k.value);
|
|
103
|
+
}), S(() => T.zoom, (e) => {
|
|
104
|
+
L.value = Je(e);
|
|
105
|
+
}), S(() => q.value?.fileId, () => {
|
|
106
|
+
V.value = a(q.value) ? "loading" : "ready", Ne.value = "";
|
|
107
|
+
}), S(() => [
|
|
108
|
+
T.contractId,
|
|
109
|
+
T.dataProvider,
|
|
110
|
+
T.autoLoad
|
|
107
111
|
], ([e, t, n], r) => {
|
|
108
|
-
!n || !t || !e || (!r || e !== r[0] || t !== r[1]) &&
|
|
109
|
-
}, { immediate: !0 }),
|
|
110
|
-
U = !0, H += 1,
|
|
112
|
+
!n || !t || !e || (!r || e !== r[0] || t !== r[1]) && Ze();
|
|
113
|
+
}, { immediate: !0 }), ge(() => {
|
|
114
|
+
U = !0, H += 1, St(), Ct();
|
|
111
115
|
});
|
|
112
|
-
function
|
|
113
|
-
return n(e, Math.min(
|
|
114
|
-
}
|
|
115
|
-
function
|
|
116
|
-
let t =
|
|
117
|
-
|
|
118
|
-
}
|
|
119
|
-
function
|
|
120
|
-
return
|
|
121
|
-
}
|
|
122
|
-
function
|
|
123
|
-
|
|
124
|
-
sealSizeLimit:
|
|
125
|
-
sealTypeOptions:
|
|
126
|
-
}), t.clearError !== !1 && (
|
|
127
|
-
let n = s(
|
|
128
|
-
return
|
|
129
|
-
}
|
|
130
|
-
async function
|
|
131
|
-
let e = String(
|
|
132
|
-
if (!
|
|
116
|
+
function Je(e) {
|
|
117
|
+
return n(e, Math.min(T.minZoom, T.maxZoom), Math.max(T.minZoom, T.maxZoom));
|
|
118
|
+
}
|
|
119
|
+
function Ye(e) {
|
|
120
|
+
let t = Je(e);
|
|
121
|
+
L.value = t, E("update:zoom", t);
|
|
122
|
+
}
|
|
123
|
+
function Xe() {
|
|
124
|
+
return R.value?.fitWidth() ?? L.value;
|
|
125
|
+
}
|
|
126
|
+
function Z(e, t = {}) {
|
|
127
|
+
k.value = u(e, {
|
|
128
|
+
sealSizeLimit: D.value,
|
|
129
|
+
sealTypeOptions: T.sealTypeOptions
|
|
130
|
+
}), t.clearError !== !1 && (P.value = ""), vt();
|
|
131
|
+
let n = s(k.value);
|
|
132
|
+
return E("update:modelValue", n), E("change", n), n;
|
|
133
|
+
}
|
|
134
|
+
async function Ze() {
|
|
135
|
+
let e = String(T.contractId || k.value.contractId || "").trim();
|
|
136
|
+
if (!T.dataProvider) return Q({
|
|
133
137
|
code: "CONTRACT_PROVIDER_MISSING",
|
|
134
138
|
message: "未配置合同数据提供器,请由宿主传入文件数据"
|
|
135
139
|
}), !1;
|
|
136
|
-
if (!e) return
|
|
140
|
+
if (!e) return Q({
|
|
137
141
|
code: "CONTRACT_ID_MISSING",
|
|
138
142
|
message: "缺少用于加载合同的 PaaS contractId"
|
|
139
143
|
}), !1;
|
|
140
144
|
let t = ++H;
|
|
141
|
-
|
|
145
|
+
Ct(), N.value = !0, P.value = "";
|
|
142
146
|
try {
|
|
143
|
-
let n = await
|
|
147
|
+
let n = await T.dataProvider.loadContract({ contractId: e });
|
|
144
148
|
if (U || t !== H) return !1;
|
|
145
|
-
let i = ie(n, r(
|
|
149
|
+
let i = ie(n, r(T.dataProvider.coordinateScale)), a = u({
|
|
146
150
|
...i,
|
|
147
151
|
contractId: e,
|
|
148
|
-
placements: i.placements.length ? i.placements :
|
|
152
|
+
placements: i.placements.length ? i.placements : k.value.contractId === e ? k.value.placements : []
|
|
149
153
|
}, {
|
|
150
|
-
sealSizeLimit:
|
|
151
|
-
sealTypeOptions:
|
|
154
|
+
sealSizeLimit: D.value,
|
|
155
|
+
sealTypeOptions: T.sealTypeOptions
|
|
152
156
|
});
|
|
153
|
-
|
|
157
|
+
k.value = a, Me.value = s(a), M.value = "", vt();
|
|
154
158
|
let o = s(a);
|
|
155
|
-
return
|
|
159
|
+
return E("update:modelValue", o), E("change", o), E("ready", o), Qe(), _(() => R.value?.scrollToPage(j.value)), o;
|
|
156
160
|
} catch (e) {
|
|
157
|
-
return U || t !== H ||
|
|
161
|
+
return U || t !== H || Q(yt(e, "CONTRACT_LOAD_FAILED", "合同加载失败,请检查授权后重试")), !1;
|
|
158
162
|
} finally {
|
|
159
|
-
!U && t === H && (
|
|
163
|
+
!U && t === H && (N.value = !1);
|
|
160
164
|
}
|
|
161
165
|
}
|
|
162
|
-
async function
|
|
163
|
-
|
|
166
|
+
async function Qe() {
|
|
167
|
+
T.dataProvider?.loadPagePreview && await Promise.allSettled(k.value.files.map((e) => {
|
|
164
168
|
if (a(e)) return Promise.resolve();
|
|
165
169
|
let t = ne(e.pages);
|
|
166
|
-
return t && !t.thumbnailUrl ?
|
|
170
|
+
return t && !t.thumbnailUrl ? $e(e.fileId, t.pageIndex, !0) : Promise.resolve();
|
|
167
171
|
}));
|
|
168
172
|
}
|
|
169
|
-
async function
|
|
170
|
-
let i =
|
|
171
|
-
if (!i || a(o) || !ee ||
|
|
172
|
-
|
|
173
|
-
let c =
|
|
173
|
+
async function $e(e, t, n) {
|
|
174
|
+
let i = T.dataProvider?.loadPagePreview, o = k.value.files.find((t) => t.fileId === e), ee = l(k.value, e, t), s = bt(e, t, n);
|
|
175
|
+
if (!i || a(o) || !ee || F.value.includes(s)) return;
|
|
176
|
+
xt(s), F.value = [...F.value, s];
|
|
177
|
+
let c = G.start(s);
|
|
174
178
|
try {
|
|
175
179
|
let a = await i({
|
|
176
|
-
contractId:
|
|
180
|
+
contractId: k.value.contractId || T.contractId,
|
|
177
181
|
fileId: e,
|
|
178
182
|
pageIndex: t,
|
|
179
183
|
thumbnail: n,
|
|
180
184
|
signal: c.signal
|
|
181
185
|
});
|
|
182
|
-
if (U || !
|
|
183
|
-
let o = oe(l(
|
|
186
|
+
if (U || !G.isCurrent(s, c) || !l(k.value, e, t)) return;
|
|
187
|
+
let o = oe(l(k.value, e, t), a, r(T.dataProvider?.coordinateScale), n), ee = k.value.files.map((r) => r.fileId === e ? {
|
|
184
188
|
...r,
|
|
185
189
|
pages: r.pages.map((e) => e.pageIndex === t ? {
|
|
186
190
|
...e,
|
|
@@ -188,74 +192,74 @@ var xe = { class: "gd-ant-contract-signing-location__header" }, Se = { class: "g
|
|
|
188
192
|
...n ? { thumbnailUrl: a.url } : { previewUrl: a.url }
|
|
189
193
|
} : e)
|
|
190
194
|
} : r);
|
|
191
|
-
|
|
192
|
-
...
|
|
195
|
+
Z({
|
|
196
|
+
...k.value,
|
|
193
197
|
files: ee
|
|
194
198
|
}, { clearError: !1 });
|
|
195
199
|
} catch (n) {
|
|
196
|
-
if (!
|
|
197
|
-
let r =
|
|
200
|
+
if (!G.isCurrent(s, c) || wt(n)) return;
|
|
201
|
+
let r = yt(n, "CONTRACT_PREVIEW_FAILED", "合同页面预览加载失败,可切换页面或重试", {
|
|
198
202
|
fileId: e,
|
|
199
203
|
pageIndex: t
|
|
200
204
|
});
|
|
201
|
-
|
|
202
|
-
...
|
|
205
|
+
E("error", r), I.value = {
|
|
206
|
+
...I.value,
|
|
203
207
|
[s]: r.message
|
|
204
208
|
};
|
|
205
209
|
} finally {
|
|
206
|
-
|
|
210
|
+
G.finish(s, c) && (F.value = F.value.filter((e) => e !== s));
|
|
207
211
|
}
|
|
208
212
|
}
|
|
209
|
-
function
|
|
210
|
-
if (e ===
|
|
211
|
-
let t =
|
|
212
|
-
|
|
213
|
+
function et(e) {
|
|
214
|
+
if (e === A.value) return;
|
|
215
|
+
let t = A.value;
|
|
216
|
+
St(), t && (Ct((e) => e.startsWith(`${t}:`) && e.endsWith(":preview")), W = W.filter((t) => t.fileId === e)), A.value = e, j.value = ne(k.value.files.find((t) => t.fileId === e)?.pages)?.pageIndex ?? 0, M.value = "", E("file-change", e), E("page-change", e, j.value), _(() => R.value?.scrollToPage(j.value));
|
|
213
217
|
}
|
|
214
|
-
function
|
|
215
|
-
|
|
218
|
+
function tt(e) {
|
|
219
|
+
j.value = e;
|
|
216
220
|
}
|
|
217
|
-
function
|
|
218
|
-
|
|
221
|
+
function nt(e) {
|
|
222
|
+
j.value !== e && (j.value = e), E("page-change", A.value, e);
|
|
219
223
|
}
|
|
220
|
-
function
|
|
221
|
-
|
|
222
|
-
let t =
|
|
223
|
-
|
|
224
|
-
|
|
224
|
+
function rt(e) {
|
|
225
|
+
St();
|
|
226
|
+
let t = A.value;
|
|
227
|
+
Pe = setTimeout(() => {
|
|
228
|
+
Pe = void 0, A.value === t && it(t, e);
|
|
225
229
|
}, 150);
|
|
226
230
|
}
|
|
227
|
-
function
|
|
228
|
-
let n =
|
|
229
|
-
!n || a(n) || e !==
|
|
231
|
+
function it(e, t) {
|
|
232
|
+
let n = k.value.files.find((t) => t.fileId === e);
|
|
233
|
+
!n || a(n) || e !== A.value || (t.forEach((e) => {
|
|
230
234
|
let t = n.pages.find((t) => t.pageIndex === e);
|
|
231
|
-
!t || t.previewUrl ||
|
|
235
|
+
!t || t.previewUrl || F.value.includes(bt(n.fileId, e, !1)) || W.some((t) => t.fileId === n.fileId && t.pageIndex === e) || W.push({
|
|
232
236
|
fileId: n.fileId,
|
|
233
237
|
pageIndex: e
|
|
234
238
|
});
|
|
235
|
-
}),
|
|
239
|
+
}), at());
|
|
236
240
|
}
|
|
237
|
-
async function
|
|
238
|
-
let e =
|
|
239
|
-
for (
|
|
240
|
-
let t =
|
|
241
|
+
async function at() {
|
|
242
|
+
let e = A.value;
|
|
243
|
+
for (W = W.filter((t) => t.fileId === e); Fe < 3 && W.length;) {
|
|
244
|
+
let t = W.shift();
|
|
241
245
|
if (!t || t.fileId !== e) continue;
|
|
242
|
-
let n = l(
|
|
243
|
-
!n || a(r) || n.previewUrl ||
|
|
244
|
-
|
|
246
|
+
let n = l(k.value, t.fileId, t.pageIndex), r = k.value.files.find((e) => e.fileId === t.fileId);
|
|
247
|
+
!n || a(r) || n.previewUrl || F.value.includes(bt(t.fileId, t.pageIndex, !1)) || (Fe += 1, $e(t.fileId, t.pageIndex, !1).finally(() => {
|
|
248
|
+
Fe = Math.max(0, Fe - 1), at();
|
|
245
249
|
}));
|
|
246
250
|
}
|
|
247
251
|
}
|
|
248
|
-
function
|
|
249
|
-
let t =
|
|
250
|
-
t && (t.fileId !==
|
|
252
|
+
function ot(e) {
|
|
253
|
+
let t = k.value.placements.find((t) => t.id === e);
|
|
254
|
+
t && (t.fileId !== A.value && et(t.fileId), M.value = e, _(() => R.value?.scrollToPlacement(e)));
|
|
251
255
|
}
|
|
252
|
-
function
|
|
253
|
-
if (Y.value || !
|
|
254
|
-
let n = t.fileId ??
|
|
256
|
+
function st(e, t = {}) {
|
|
257
|
+
if (Y.value || !T.allowedPlacementTypes.includes(e)) return;
|
|
258
|
+
let n = t.fileId ?? q.value?.fileId, r = t.pageIndex ?? Ve.value?.pageIndex;
|
|
255
259
|
if (!n || r === void 0) return;
|
|
256
|
-
let i = l(
|
|
260
|
+
let i = l(k.value, n, r);
|
|
257
261
|
if (!i || !re(i)) {
|
|
258
|
-
|
|
262
|
+
Q({
|
|
259
263
|
code: "CONTRACT_PAGE_SIZE_INVALID",
|
|
260
264
|
message: "当前页面缺少有效的原始宽高,暂时不能添加签署位置",
|
|
261
265
|
fileId: n,
|
|
@@ -263,9 +267,9 @@ var xe = { class: "gd-ant-contract-signing-location__header" }, Se = { class: "g
|
|
|
263
267
|
});
|
|
264
268
|
return;
|
|
265
269
|
}
|
|
266
|
-
let a =
|
|
270
|
+
let a = T.sealTypeOptions.find((e) => String(e.value).trim())?.value;
|
|
267
271
|
if (e === "seal" && !a) {
|
|
268
|
-
|
|
272
|
+
Q({
|
|
269
273
|
code: "CONTRACT_SEAL_TYPES_MISSING",
|
|
270
274
|
message: "当前未配置可用的印章类型,暂时不能添加印章位置",
|
|
271
275
|
fileId: n,
|
|
@@ -276,83 +280,105 @@ var xe = { class: "gd-ant-contract-signing-location__header" }, Se = { class: "g
|
|
|
276
280
|
let o = te(e, n, i, {
|
|
277
281
|
signLeft: t.signLeft,
|
|
278
282
|
signTop: t.signTop,
|
|
279
|
-
sizeProfile:
|
|
280
|
-
sealSizeLimit:
|
|
281
|
-
sealTypeOptions:
|
|
283
|
+
sizeProfile: T.sizeProfile,
|
|
284
|
+
sealSizeLimit: D.value,
|
|
285
|
+
sealTypeOptions: T.sealTypeOptions,
|
|
282
286
|
...e === "seal" ? { sealType: [String(a)] } : {}
|
|
283
287
|
});
|
|
284
|
-
return
|
|
285
|
-
...
|
|
286
|
-
placements: [...
|
|
287
|
-
}),
|
|
288
|
-
}
|
|
289
|
-
function
|
|
290
|
-
Y.value ||
|
|
291
|
-
...
|
|
292
|
-
placements:
|
|
288
|
+
return Z({
|
|
289
|
+
...k.value,
|
|
290
|
+
placements: [...k.value.placements, o]
|
|
291
|
+
}), A.value = n, j.value = r, M.value = o.id, Et(o);
|
|
292
|
+
}
|
|
293
|
+
function ct(e, t) {
|
|
294
|
+
Y.value || Z({
|
|
295
|
+
...k.value,
|
|
296
|
+
placements: k.value.placements.map((n) => {
|
|
293
297
|
if (n.id !== e) return n;
|
|
294
298
|
let r = t.pageIndex === void 0 ? n.pageIndex : t.pageIndex;
|
|
295
|
-
return ae(n, t, l(
|
|
296
|
-
sealSizeLimit:
|
|
297
|
-
sealTypeOptions:
|
|
299
|
+
return ae(n, t, l(k.value, n.fileId, r), {
|
|
300
|
+
sealSizeLimit: D.value,
|
|
301
|
+
sealTypeOptions: T.sealTypeOptions
|
|
298
302
|
});
|
|
299
303
|
})
|
|
300
304
|
});
|
|
301
305
|
}
|
|
302
|
-
function
|
|
303
|
-
let e =
|
|
306
|
+
function lt() {
|
|
307
|
+
let e = X.value;
|
|
304
308
|
if (!e || Y.value) return;
|
|
305
|
-
let n = l(
|
|
309
|
+
let n = l(k.value, e.fileId, e.pageIndex);
|
|
306
310
|
if (!n) return;
|
|
307
311
|
let r = t({
|
|
308
|
-
...
|
|
309
|
-
id:
|
|
312
|
+
...Et(e),
|
|
313
|
+
id: Dt(),
|
|
310
314
|
signLeft: e.signLeft + 16,
|
|
311
315
|
signTop: e.signTop + 16
|
|
312
|
-
}, n, { sealSizeLimit:
|
|
313
|
-
|
|
314
|
-
...
|
|
315
|
-
placements: [...
|
|
316
|
-
}),
|
|
317
|
-
}
|
|
318
|
-
function
|
|
319
|
-
Y.value || (
|
|
320
|
-
...
|
|
321
|
-
placements:
|
|
322
|
-
}),
|
|
323
|
-
}
|
|
324
|
-
function
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
316
|
+
}, n, { sealSizeLimit: D.value });
|
|
317
|
+
Z({
|
|
318
|
+
...k.value,
|
|
319
|
+
placements: [...k.value.placements, r]
|
|
320
|
+
}), M.value = r.id;
|
|
321
|
+
}
|
|
322
|
+
function ut(e) {
|
|
323
|
+
Y.value || (Z({
|
|
324
|
+
...k.value,
|
|
325
|
+
placements: k.value.placements.filter((t) => t.id !== e)
|
|
326
|
+
}), M.value === e && (M.value = ""));
|
|
327
|
+
}
|
|
328
|
+
function dt() {
|
|
329
|
+
let e = se(k.value, { allowedSealTypes: T.sealTypeOptions.map((e) => e.value) });
|
|
330
|
+
return J.value ? [...e, {
|
|
331
|
+
code: "CONTRACT_TEMPLATE_FONT_UNAVAILABLE",
|
|
332
|
+
message: gt()
|
|
333
|
+
}] : e;
|
|
334
|
+
}
|
|
335
|
+
function ft() {
|
|
336
|
+
return s(k.value);
|
|
337
|
+
}
|
|
338
|
+
function pt() {
|
|
339
|
+
if (J.value) throw new o([{
|
|
340
|
+
code: "CONTRACT_TEMPLATE_FONT_UNAVAILABLE",
|
|
341
|
+
message: gt()
|
|
342
|
+
}]);
|
|
343
|
+
return ee(ft(), { allowedSealTypes: T.sealTypeOptions.map((e) => e.value) });
|
|
344
|
+
}
|
|
345
|
+
function mt() {
|
|
346
|
+
if (J.value) {
|
|
347
|
+
let e = gt();
|
|
348
|
+
return console.error("[GD-SIGN-COORD]", e), Q({
|
|
349
|
+
code: "CONTRACT_TEMPLATE_FONT_UNAVAILABLE",
|
|
350
|
+
message: e
|
|
351
|
+
}), !1;
|
|
352
|
+
}
|
|
334
353
|
try {
|
|
335
|
-
let e =
|
|
336
|
-
return
|
|
354
|
+
let e = pt();
|
|
355
|
+
return P.value = "", E("submit", e), e;
|
|
337
356
|
} catch (e) {
|
|
338
|
-
return
|
|
357
|
+
return Q(e instanceof o ? {
|
|
339
358
|
...e.errors[0],
|
|
340
359
|
cause: e
|
|
341
|
-
} :
|
|
360
|
+
} : yt(e, "CONTRACT_SIGNING_LOCATION_INVALID", "指定签署位置数据不完整")), !1;
|
|
342
361
|
}
|
|
343
362
|
}
|
|
344
|
-
function
|
|
345
|
-
|
|
346
|
-
return N.value = "", dt(!0), _(() => z.value?.scrollToPage(M.value)), e;
|
|
363
|
+
function ht(e, t) {
|
|
364
|
+
V.value = e, Ne.value = e === "error" ? t || "合同排版度量校验失败" : "";
|
|
347
365
|
}
|
|
348
|
-
function
|
|
349
|
-
|
|
350
|
-
j.value = t?.fileId ?? "", M.value = ((e ? void 0 : t?.pages.find((e) => e.pageIndex === M.value)) ?? t?.pages[0])?.pageIndex ?? 0, A.value.placements.some((e) => e.id === N.value) || (N.value = "");
|
|
366
|
+
function gt() {
|
|
367
|
+
return V.value === "error" ? Ne.value || "合同排版度量校验失败,禁止生成签署坐标" : "合同排版度量校验中,请稍后再保存签署坐标";
|
|
351
368
|
}
|
|
352
|
-
function
|
|
353
|
-
|
|
369
|
+
function _t() {
|
|
370
|
+
if (Y.value) return s(k.value);
|
|
371
|
+
let e = Z(s(Me.value));
|
|
372
|
+
return M.value = "", vt(!0), _(() => R.value?.scrollToPage(j.value)), e;
|
|
373
|
+
}
|
|
374
|
+
function vt(e = !1) {
|
|
375
|
+
let t = (e ? void 0 : k.value.files.find((e) => e.fileId === A.value)) ?? k.value.files[0];
|
|
376
|
+
A.value = t?.fileId ?? "", j.value = ((e ? void 0 : t?.pages.find((e) => e.pageIndex === j.value)) ?? t?.pages[0])?.pageIndex ?? 0, k.value.placements.some((e) => e.id === M.value) || (M.value = "");
|
|
377
|
+
}
|
|
378
|
+
function Q(e) {
|
|
379
|
+
P.value = e.message, E("error", e);
|
|
354
380
|
}
|
|
355
|
-
function
|
|
381
|
+
function yt(e, t, n, r = {}) {
|
|
356
382
|
let i = typeof e == "object" && e && "status" in e ? Number(e.status) : void 0;
|
|
357
383
|
return {
|
|
358
384
|
code: t,
|
|
@@ -361,131 +387,131 @@ var xe = { class: "gd-ant-contract-signing-location__header" }, Se = { class: "g
|
|
|
361
387
|
cause: e
|
|
362
388
|
};
|
|
363
389
|
}
|
|
364
|
-
function
|
|
390
|
+
function bt(e, t, n) {
|
|
365
391
|
return `${e}:${t}:${n ? "thumbnail" : "preview"}`;
|
|
366
392
|
}
|
|
367
|
-
function
|
|
368
|
-
if (!(e in
|
|
369
|
-
let t = { ...
|
|
370
|
-
delete t[e],
|
|
393
|
+
function xt(e) {
|
|
394
|
+
if (!(e in I.value)) return;
|
|
395
|
+
let t = { ...I.value };
|
|
396
|
+
delete t[e], I.value = t;
|
|
371
397
|
}
|
|
372
|
-
function
|
|
373
|
-
|
|
398
|
+
function St() {
|
|
399
|
+
Pe &&= (clearTimeout(Pe), void 0);
|
|
374
400
|
}
|
|
375
|
-
function
|
|
376
|
-
let t = e ?? (() => !0), n = new Set(
|
|
377
|
-
n.size && (
|
|
401
|
+
function Ct(e) {
|
|
402
|
+
let t = e ?? (() => !0), n = new Set(G.abort(t));
|
|
403
|
+
n.size && (F.value = F.value.filter((e) => !n.has(e))), e || (W = []);
|
|
378
404
|
}
|
|
379
|
-
function
|
|
405
|
+
function wt(e) {
|
|
380
406
|
return !!(e && typeof e == "object" && "cancelled" in e && e.cancelled) || e instanceof DOMException && e.name === "AbortError";
|
|
381
407
|
}
|
|
382
|
-
function
|
|
383
|
-
let t =
|
|
384
|
-
t &&
|
|
408
|
+
function Tt(e) {
|
|
409
|
+
let t = q.value;
|
|
410
|
+
t && $e(t.fileId, e, !1);
|
|
385
411
|
}
|
|
386
|
-
function
|
|
412
|
+
function Et(e) {
|
|
387
413
|
return {
|
|
388
414
|
...e,
|
|
389
415
|
sealType: e.sealType ? [...e.sealType] : void 0
|
|
390
416
|
};
|
|
391
417
|
}
|
|
392
|
-
function
|
|
418
|
+
function $(e) {
|
|
393
419
|
return JSON.stringify(e);
|
|
394
420
|
}
|
|
395
|
-
function
|
|
421
|
+
function Dt() {
|
|
396
422
|
return typeof crypto < "u" && "randomUUID" in crypto ? `contract-signing-placement-${crypto.randomUUID()}` : `contract-signing-placement-${Date.now()}-${Math.random().toString(36).slice(2, 8)}`;
|
|
397
423
|
}
|
|
398
|
-
function
|
|
424
|
+
function Ot(e) {
|
|
399
425
|
if (typeof e == "number" && Number.isFinite(e) && e > 0) return { "--gd-ant-contract-signing-location-height": `${e}px` };
|
|
400
426
|
if (typeof e == "string" && e.trim()) return { "--gd-ant-contract-signing-location-height": e.trim() };
|
|
401
427
|
}
|
|
402
428
|
return pe({
|
|
403
|
-
load:
|
|
404
|
-
validate:
|
|
405
|
-
getValue:
|
|
406
|
-
getOutput:
|
|
407
|
-
submit:
|
|
408
|
-
reset:
|
|
409
|
-
addPlacement:
|
|
410
|
-
removePlacement:
|
|
411
|
-
fitWidth:
|
|
412
|
-
}), (t, n) => (
|
|
413
|
-
class:
|
|
414
|
-
"is-readonly":
|
|
429
|
+
load: Ze,
|
|
430
|
+
validate: dt,
|
|
431
|
+
getValue: ft,
|
|
432
|
+
getOutput: pt,
|
|
433
|
+
submit: mt,
|
|
434
|
+
reset: _t,
|
|
435
|
+
addPlacement: st,
|
|
436
|
+
removePlacement: ut,
|
|
437
|
+
fitWidth: Xe
|
|
438
|
+
}), (t, n) => (v(), m("section", {
|
|
439
|
+
class: me(["gd-ant-contract-signing-location", {
|
|
440
|
+
"is-readonly": Ie.value,
|
|
415
441
|
"is-disabled": e.disabled,
|
|
416
|
-
"is-preview":
|
|
442
|
+
"is-preview": K.value
|
|
417
443
|
}]),
|
|
418
|
-
style:
|
|
444
|
+
style: he(Be.value)
|
|
419
445
|
}, [
|
|
420
|
-
|
|
446
|
+
h("header", Se, [h("div", Ce, [n[6] ||= h("span", {
|
|
421
447
|
class: "gd-ant-contract-signing-location__title-bar",
|
|
422
448
|
"aria-hidden": "true"
|
|
423
|
-
}, null, -1),
|
|
424
|
-
|
|
425
|
-
e.dataProvider ? (
|
|
449
|
+
}, null, -1), h("div", null, [h("strong", null, _e(K.value ? "合同预览" : "指定合同签署位置"), 1)])]), h("div", we, [
|
|
450
|
+
h("span", Te, _e(k.value.placements.length) + " 个位置", 1),
|
|
451
|
+
e.dataProvider ? (v(), f(x(w), {
|
|
426
452
|
key: 0,
|
|
427
|
-
loading:
|
|
428
|
-
onClick:
|
|
453
|
+
loading: N.value,
|
|
454
|
+
onClick: Ze
|
|
429
455
|
}, {
|
|
430
|
-
default:
|
|
456
|
+
default: C(() => [g(x(be), { "aria-hidden": "true" }), n[7] ||= fe(" 重新加载 ", -1)]),
|
|
431
457
|
_: 1
|
|
432
458
|
}, 8, ["loading"])) : p("", !0),
|
|
433
|
-
|
|
459
|
+
K.value ? p("", !0) : (v(), f(x(w), {
|
|
434
460
|
key: 1,
|
|
435
461
|
disabled: Y.value,
|
|
436
|
-
onClick:
|
|
462
|
+
onClick: _t
|
|
437
463
|
}, {
|
|
438
|
-
default:
|
|
464
|
+
default: C(() => [...n[8] ||= [fe("重置", -1)]]),
|
|
439
465
|
_: 1
|
|
440
466
|
}, 8, ["disabled"])),
|
|
441
|
-
|
|
467
|
+
Re.value ? (v(), f(x(w), {
|
|
442
468
|
key: 2,
|
|
443
469
|
type: "primary",
|
|
444
|
-
loading:
|
|
445
|
-
disabled: e.disabled,
|
|
446
|
-
onClick:
|
|
470
|
+
loading: N.value,
|
|
471
|
+
disabled: e.disabled || J.value,
|
|
472
|
+
onClick: mt
|
|
447
473
|
}, {
|
|
448
|
-
default:
|
|
474
|
+
default: C(() => [...n[9] ||= [fe("确认并生成规则", -1)]]),
|
|
449
475
|
_: 1
|
|
450
476
|
}, 8, ["loading", "disabled"])) : p("", !0)
|
|
451
477
|
])]),
|
|
452
|
-
|
|
478
|
+
P.value ? (v(), m("div", Ee, [h("span", null, _e(P.value), 1), e.dataProvider && e.contractId ? (v(), f(x(w), {
|
|
453
479
|
key: 0,
|
|
454
480
|
type: "link",
|
|
455
481
|
size: "small",
|
|
456
|
-
onClick:
|
|
482
|
+
onClick: Ze
|
|
457
483
|
}, {
|
|
458
|
-
default:
|
|
484
|
+
default: C(() => [...n[10] ||= [fe("重试", -1)]]),
|
|
459
485
|
_: 1
|
|
460
486
|
})) : p("", !0)])) : p("", !0),
|
|
461
|
-
|
|
462
|
-
"is-single-file":
|
|
463
|
-
"is-inspector-hidden": !
|
|
487
|
+
h("div", { class: me(["gd-ant-contract-signing-location__body", {
|
|
488
|
+
"is-single-file": ze.value,
|
|
489
|
+
"is-inspector-hidden": !Le.value
|
|
464
490
|
}]) }, [
|
|
465
|
-
|
|
491
|
+
ze.value ? p("", !0) : (v(), m("div", {
|
|
466
492
|
key: 0,
|
|
467
|
-
class:
|
|
468
|
-
}, [g(
|
|
469
|
-
default:
|
|
493
|
+
class: me(["gd-ant-contract-signing-location__navigator-wrap", { "is-collapsed": B.value }])
|
|
494
|
+
}, [g(x(ve), { title: B.value ? "展开页面栏" : "收起页面栏" }, {
|
|
495
|
+
default: C(() => [h("button", {
|
|
470
496
|
type: "button",
|
|
471
497
|
class: "gd-ant-contract-signing-location__panel-handle",
|
|
472
|
-
"aria-label":
|
|
473
|
-
"aria-expanded": !
|
|
474
|
-
onClick: n[0] ||= (e) =>
|
|
475
|
-
}, [
|
|
498
|
+
"aria-label": B.value ? "展开页面栏" : "收起页面栏",
|
|
499
|
+
"aria-expanded": !B.value,
|
|
500
|
+
onClick: n[0] ||= (e) => B.value = !B.value
|
|
501
|
+
}, [B.value ? (v(), f(x(xe), {
|
|
476
502
|
key: 0,
|
|
477
503
|
"aria-hidden": "true"
|
|
478
|
-
})) : (
|
|
504
|
+
})) : (v(), f(x(ye), {
|
|
479
505
|
key: 1,
|
|
480
506
|
"aria-hidden": "true"
|
|
481
|
-
}))], 8,
|
|
507
|
+
}))], 8, De)]),
|
|
482
508
|
_: 1
|
|
483
|
-
}, 8, ["title"]),
|
|
484
|
-
files:
|
|
485
|
-
"active-file-id":
|
|
486
|
-
"loading-preview-keys":
|
|
487
|
-
"error-preview-keys":
|
|
488
|
-
onSelect:
|
|
509
|
+
}, 8, ["title"]), h("div", Oe, [g(ue, {
|
|
510
|
+
files: k.value.files,
|
|
511
|
+
"active-file-id": A.value,
|
|
512
|
+
"loading-preview-keys": We.value,
|
|
513
|
+
"error-preview-keys": Ge.value,
|
|
514
|
+
onSelect: et
|
|
489
515
|
}, null, 8, [
|
|
490
516
|
"files",
|
|
491
517
|
"active-file-id",
|
|
@@ -494,34 +520,36 @@ var xe = { class: "gd-ant-contract-signing-location__header" }, Se = { class: "g
|
|
|
494
520
|
])])], 2)),
|
|
495
521
|
g(ce, {
|
|
496
522
|
ref_key: "canvasRef",
|
|
497
|
-
ref:
|
|
498
|
-
file:
|
|
499
|
-
pages:
|
|
500
|
-
placements:
|
|
501
|
-
"selected-placement-id":
|
|
523
|
+
ref: R,
|
|
524
|
+
file: q.value,
|
|
525
|
+
pages: q.value?.pages ?? [],
|
|
526
|
+
placements: He.value,
|
|
527
|
+
"selected-placement-id": M.value,
|
|
502
528
|
readonly: Y.value,
|
|
503
529
|
resizable: e.resizable,
|
|
504
|
-
"seal-size-limit":
|
|
530
|
+
"seal-size-limit": D.value,
|
|
505
531
|
"seal-type-options": e.sealTypeOptions,
|
|
506
|
-
zoom:
|
|
507
|
-
"preview-loading-keys":
|
|
508
|
-
"preview-error-map":
|
|
509
|
-
"active-page-index":
|
|
532
|
+
zoom: L.value,
|
|
533
|
+
"preview-loading-keys": Ke.value,
|
|
534
|
+
"preview-error-map": qe.value,
|
|
535
|
+
"active-page-index": j.value,
|
|
510
536
|
"min-zoom": e.minZoom,
|
|
511
537
|
"max-zoom": e.maxZoom,
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
538
|
+
"font-base-url": e.contractFontBaseUrl,
|
|
539
|
+
onSelect: n[1] ||= (e) => M.value = e,
|
|
540
|
+
onRetry: Tt,
|
|
541
|
+
onAdd: n[2] ||= (e, t, n, r) => st(e, {
|
|
515
542
|
signLeft: t,
|
|
516
543
|
signTop: n,
|
|
517
544
|
pageIndex: r
|
|
518
545
|
}),
|
|
519
|
-
onUpdate: n[3] ||= (e) =>
|
|
520
|
-
onRemove:
|
|
521
|
-
onVisiblePages:
|
|
522
|
-
onViewPage:
|
|
523
|
-
onPageChange:
|
|
524
|
-
onZoomChange:
|
|
546
|
+
onUpdate: n[3] ||= (e) => ct(e.id, e),
|
|
547
|
+
onRemove: ut,
|
|
548
|
+
onVisiblePages: rt,
|
|
549
|
+
onViewPage: tt,
|
|
550
|
+
onPageChange: nt,
|
|
551
|
+
onZoomChange: Ye,
|
|
552
|
+
onTemplateStatus: ht
|
|
525
553
|
}, null, 8, [
|
|
526
554
|
"file",
|
|
527
555
|
"pages",
|
|
@@ -536,42 +564,43 @@ var xe = { class: "gd-ant-contract-signing-location__header" }, Se = { class: "g
|
|
|
536
564
|
"preview-error-map",
|
|
537
565
|
"active-page-index",
|
|
538
566
|
"min-zoom",
|
|
539
|
-
"max-zoom"
|
|
567
|
+
"max-zoom",
|
|
568
|
+
"font-base-url"
|
|
540
569
|
]),
|
|
541
|
-
|
|
570
|
+
Le.value ? (v(), m("div", {
|
|
542
571
|
key: 1,
|
|
543
|
-
class:
|
|
544
|
-
}, [g(
|
|
545
|
-
default:
|
|
572
|
+
class: me(["gd-ant-contract-signing-location__inspector-wrap", { "is-collapsed": z.value }])
|
|
573
|
+
}, [g(x(ve), { title: z.value ? "展开属性栏" : "收起属性栏" }, {
|
|
574
|
+
default: C(() => [h("button", {
|
|
546
575
|
type: "button",
|
|
547
576
|
class: "gd-ant-contract-signing-location__panel-handle",
|
|
548
|
-
"aria-label":
|
|
549
|
-
"aria-expanded": !
|
|
550
|
-
onClick: n[4] ||= (e) =>
|
|
551
|
-
}, [
|
|
577
|
+
"aria-label": z.value ? "展开属性栏" : "收起属性栏",
|
|
578
|
+
"aria-expanded": !z.value,
|
|
579
|
+
onClick: n[4] ||= (e) => z.value = !z.value
|
|
580
|
+
}, [z.value ? (v(), f(x(ye), {
|
|
552
581
|
key: 0,
|
|
553
582
|
"aria-hidden": "true"
|
|
554
|
-
})) : (
|
|
583
|
+
})) : (v(), f(x(xe), {
|
|
555
584
|
key: 1,
|
|
556
585
|
"aria-hidden": "true"
|
|
557
|
-
}))], 8,
|
|
586
|
+
}))], 8, ke)]),
|
|
558
587
|
_: 1
|
|
559
|
-
}, 8, ["title"]),
|
|
560
|
-
placement:
|
|
561
|
-
page:
|
|
562
|
-
pages:
|
|
563
|
-
placements:
|
|
588
|
+
}, 8, ["title"]), h("div", Ae, [g(le, {
|
|
589
|
+
placement: X.value,
|
|
590
|
+
page: Ue.value,
|
|
591
|
+
pages: q.value?.pages ?? [],
|
|
592
|
+
placements: He.value,
|
|
564
593
|
readonly: Y.value,
|
|
565
594
|
resizable: e.resizable,
|
|
566
|
-
"seal-size-limit":
|
|
595
|
+
"seal-size-limit": D.value,
|
|
567
596
|
"seal-type-options": e.sealTypeOptions,
|
|
568
597
|
"allowed-placement-types": e.allowedPlacementTypes,
|
|
569
598
|
"size-profile": e.sizeProfile,
|
|
570
|
-
onAdd:
|
|
571
|
-
onUpdate: n[5] ||= (e) =>
|
|
572
|
-
onDuplicate:
|
|
573
|
-
onRemove:
|
|
574
|
-
onLocate:
|
|
599
|
+
onAdd: st,
|
|
600
|
+
onUpdate: n[5] ||= (e) => X.value && ct(X.value.id, e),
|
|
601
|
+
onDuplicate: lt,
|
|
602
|
+
onRemove: ut,
|
|
603
|
+
onLocate: ot
|
|
575
604
|
}, null, 8, [
|
|
576
605
|
"placement",
|
|
577
606
|
"page",
|
|
@@ -589,4 +618,4 @@ var xe = { class: "gd-ant-contract-signing-location__header" }, Se = { class: "g
|
|
|
589
618
|
}
|
|
590
619
|
});
|
|
591
620
|
//#endregion
|
|
592
|
-
export {
|
|
621
|
+
export { je as default };
|