@agentprismform/render-vue 1.2.0 → 1.3.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/dist/index.mjs CHANGED
@@ -1,9 +1,11 @@
1
- import { defineComponent as L, ref as D, watch as G, computed as C, openBlock as s, createElementBlock as r, createCommentVNode as I, createElementVNode as l, normalizeClass as R, toDisplayString as A, createVNode as X, Transition as Q, withCtx as Z, withModifiers as W, Fragment as B, renderList as U, createBlock as J, Teleport as re, normalizeStyle as oe, createTextVNode as Y, withDirectives as ce, vModelText as ue, useCssVars as de, nextTick as ve, resolveDynamicComponent as ee, inject as q, onBeforeUnmount as fe, unref as te, provide as z, renderSlot as me, reactive as pe, getCurrentInstance as he, onUnmounted as ge } from "vue";
2
- import { FORM_UI_HOST_HANDLERS_KEY as ae } from "@agentprismform/render-ui";
3
- import { resolveLabelPosition as ye, createFormRenderState as ke } from "@agentprismform/render";
4
- import { completeTask as K, getTaskHandlers as be, classifyTask as Ce, resolveTaskByKey as se } from "@agentprismform/render-task";
5
- import { setTaskHandlers as ba } from "@agentprismform/render-task";
6
- const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disabled", "maxlength"], Te = ["type", "value", "placeholder", "disabled", "maxlength"], we = /* @__PURE__ */ L({
1
+ import { defineComponent as U, ref as E, watch as Z, computed as b, openBlock as s, createElementBlock as i, createCommentVNode as x, createElementVNode as l, normalizeClass as K, toDisplayString as $, createVNode as se, Transition as ie, withCtx as te, withModifiers as ae, Fragment as q, renderList as W, createBlock as ee, Teleport as Ie, normalizeStyle as re, createTextVNode as X, withDirectives as Oe, vModelText as Me, useCssVars as Ve, nextTick as Ee, resolveDynamicComponent as ce, inject as le, onBeforeUnmount as Pe, unref as ne, provide as G, renderSlot as ye, shallowRef as Fe, reactive as ke, onUnmounted as be, mergeProps as De, getCurrentInstance as Re } from "vue";
2
+ import { FormCore as he } from "@agentprismform/core";
3
+ import { resolveLabelPosition as Ne, createFormRenderState as _e } from "@agentprismform/render";
4
+ import { createFetchHostHandlers as yn } from "@agentprismform/render";
5
+ import { FORM_UI_HOST_HANDLERS_KEY as ue, normalizeModernLocale as Le, resolveModernThemeVars as je, getModernShellComponents as Be, MODERN_SHELL_SKIN_KEY as Ke, MODERN_THEME_OVERRIDE_KEY as Ue, MODERN_COLLAPSIBLE_KEY as He, MODERN_KEYBOARD_POLICY_KEY as Ye, MODERN_READONLY_KEY as qe, MODERN_TELEMETRY_KEY as ze, MODERN_LOCALE_KEY as Ge, MODERN_CUSTOM_CONTROLS_KEY as We, computeFormProgress as Je } from "@agentprismform/render-ui";
6
+ import { completeTask as Q, getTaskHandlers as Xe, classifyTask as Qe, resolveTaskByKey as Ce } from "@agentprismform/render-task";
7
+ import { setTaskHandlers as bn } from "@agentprismform/render-task";
8
+ const Ze = { class: "ctrl-input-wrapper" }, et = ["value", "placeholder", "disabled", "maxlength"], tt = ["type", "value", "placeholder", "disabled", "maxlength"], lt = /* @__PURE__ */ U({
7
9
  __name: "InputControl",
8
10
  props: {
9
11
  item: {},
@@ -13,64 +15,64 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
13
15
  emits: ["change"],
14
16
  setup(t, { emit: n }) {
15
17
  var g;
16
- const e = t, y = n, u = D(((g = e.field) == null ? void 0 : g.value) || "");
17
- G(() => {
18
+ const e = t, r = n, f = E(((g = e.field) == null ? void 0 : g.value) || "");
19
+ Z(() => {
18
20
  var a;
19
21
  return (a = e.field) == null ? void 0 : a.value;
20
22
  }, (a) => {
21
- u.value = a || "";
23
+ f.value = a || "";
22
24
  });
23
- const m = C(() => e.item.type === "textarea");
24
- function p(a) {
25
+ const p = b(() => e.item.type === "textarea");
26
+ function m(a) {
25
27
  const o = a.target;
26
- u.value = o.value;
28
+ f.value = o.value;
27
29
  }
28
- function f(a) {
29
- var h;
30
- const i = ((h = a.target.value) == null ? void 0 : h.trim()) || "";
31
- u.value = i, y("change", { value: i, eventType: "inputBlur" });
30
+ function h(a) {
31
+ var y;
32
+ const c = ((y = a.target.value) == null ? void 0 : y.trim()) || "";
33
+ f.value = c, r("change", { value: c, eventType: "inputBlur" });
32
34
  }
33
35
  return (a, o) => {
34
- var i, h, V, v, b;
35
- return s(), r("div", _e, [
36
- m.value ? (s(), r("textarea", {
36
+ var c, y, M, v, T;
37
+ return s(), i("div", Ze, [
38
+ p.value ? (s(), i("textarea", {
37
39
  key: 0,
38
40
  class: "ctrl-input ctrl-textarea",
39
- value: u.value,
41
+ value: f.value,
40
42
  placeholder: t.item.placeholder || "请输入",
41
- disabled: (i = t.field) == null ? void 0 : i.disabled,
42
- maxlength: (h = t.item.props) == null ? void 0 : h.maxlength,
43
+ disabled: (c = t.field) == null ? void 0 : c.disabled,
44
+ maxlength: (y = t.item.props) == null ? void 0 : y.maxlength,
43
45
  rows: "3",
44
- onInput: p,
45
- onBlur: f
46
- }, null, 40, $e)) : (s(), r("input", {
46
+ onInput: m,
47
+ onBlur: h
48
+ }, null, 40, et)) : (s(), i("input", {
47
49
  key: 1,
48
50
  class: "ctrl-input",
49
51
  type: t.item.type === "number" ? "number" : t.item.type === "phone" ? "tel" : "text",
50
- value: u.value,
52
+ value: f.value,
51
53
  placeholder: t.item.placeholder || "请输入",
52
- disabled: (V = t.field) == null ? void 0 : V.disabled,
54
+ disabled: (M = t.field) == null ? void 0 : M.disabled,
53
55
  maxlength: (v = t.item.props) == null ? void 0 : v.maxlength,
54
- onInput: p,
55
- onBlur: f
56
- }, null, 40, Te)),
57
- (b = t.item.props) != null && b.guideText ? (s(), r("span", {
56
+ onInput: m,
57
+ onBlur: h
58
+ }, null, 40, tt)),
59
+ (T = t.item.props) != null && T.guideText ? (s(), i("span", {
58
60
  key: 2,
59
61
  class: "ctrl-guide",
60
- onClick: o[0] || (o[0] = (w) => y("change", { eventType: "guideClick" }))
61
- }, "查看示例")) : I("v-if", !0)
62
+ onClick: o[0] || (o[0] = (A) => r("change", { eventType: "guideClick" }))
63
+ }, "查看示例")) : x("v-if", !0)
62
64
  ]);
63
65
  };
64
66
  }
65
- }), N = (t, n) => {
67
+ }), Y = (t, n) => {
66
68
  const e = t.__vccOpts || t;
67
- for (const [y, u] of n)
68
- e[y] = u;
69
+ for (const [r, f] of n)
70
+ e[r] = f;
69
71
  return e;
70
- }, xe = /* @__PURE__ */ N(we, [["__scopeId", "data-v-c8af62aa"]]), Se = { class: "ctrl-select" }, Ie = { class: "panel-header" }, Ae = { class: "panel-title" }, Ve = {
72
+ }, at = /* @__PURE__ */ Y(lt, [["__scopeId", "data-v-c8af62aa"]]), nt = { class: "ctrl-select" }, ot = { class: "panel-header" }, st = { class: "panel-title" }, it = {
71
73
  class: "panel-body",
72
74
  role: "listbox"
73
- }, Fe = ["aria-selected", "onClick"], De = { class: "option-text" }, Me = /* @__PURE__ */ L({
75
+ }, rt = ["aria-selected", "onClick"], ct = { class: "option-text" }, ut = /* @__PURE__ */ U({
74
76
  __name: "SelectControl",
75
77
  props: {
76
78
  item: {},
@@ -79,50 +81,50 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
79
81
  },
80
82
  emits: ["change"],
81
83
  setup(t, { emit: n }) {
82
- const e = t, y = n, u = D(!1), m = C(() => {
83
- var V, v;
84
- const i = ((V = e.item) == null ? void 0 : V.initOptions) || [], h = (v = e.field) == null ? void 0 : v.value;
85
- return h ? i.map((b) => {
86
- var w;
84
+ const e = t, r = n, f = E(!1), p = b(() => {
85
+ var M, v;
86
+ const c = ((M = e.item) == null ? void 0 : M.initOptions) || [], y = (v = e.field) == null ? void 0 : v.value;
87
+ return y ? c.map((T) => {
88
+ var A;
87
89
  return {
88
- ...b,
89
- _selected: ((w = e.item.props) == null ? void 0 : w.isSingle) !== !1 ? (h == null ? void 0 : h.code) === b.code : Array.isArray(h) ? h.some((P) => P.code === b.code) : h === b.code
90
+ ...T,
91
+ _selected: ((A = e.item.props) == null ? void 0 : A.isSingle) !== !1 ? (y == null ? void 0 : y.code) === T.code : Array.isArray(y) ? y.some((L) => L.code === T.code) : y === T.code
90
92
  };
91
- }) : i;
92
- }), p = C(() => {
93
- var h, V;
94
- const i = (h = e.field) == null ? void 0 : h.value;
95
- return i ? typeof i == "object" && i.name ? i.name : (V = e.field) != null && V.showValue ? e.field.showValue : String(i) : "";
96
- }), f = C(() => {
97
- var i;
98
- return ((i = e.item.props) == null ? void 0 : i.dialogTitle) || "请选择";
93
+ }) : c;
94
+ }), m = b(() => {
95
+ var y, M;
96
+ const c = (y = e.field) == null ? void 0 : y.value;
97
+ return c ? typeof c == "object" && c.name ? c.name : (M = e.field) != null && M.showValue ? e.field.showValue : String(c) : "";
98
+ }), h = b(() => {
99
+ var c;
100
+ return ((c = e.item.props) == null ? void 0 : c.dialogTitle) || "请选择";
99
101
  });
100
102
  function g() {
101
- var i;
102
- (i = e.field) != null && i.disabled || (u.value = !0);
103
+ var c;
104
+ (c = e.field) != null && c.disabled || (f.value = !0);
103
105
  }
104
106
  function a() {
105
- u.value = !1;
107
+ f.value = !1;
106
108
  }
107
- function o(i) {
108
- var V;
109
- ((V = e.item.props) == null ? void 0 : V.isSingle) !== !1 && (y("change", { value: { code: i.code, name: i.name }, eventType: "pickChange" }), u.value = !1);
109
+ function o(c) {
110
+ var M;
111
+ ((M = e.item.props) == null ? void 0 : M.isSingle) !== !1 && (r("change", { value: { code: c.code, name: c.name }, eventType: "pickChange" }), f.value = !1);
110
112
  }
111
- return (i, h) => {
112
- var V;
113
- return s(), r("div", Se, [
114
- I(" 触发器 "),
113
+ return (c, y) => {
114
+ var M;
115
+ return s(), i("div", nt, [
116
+ x(" 触发器 "),
115
117
  l(
116
118
  "div",
117
119
  {
118
- class: R(["select-trigger", { disabled: (V = t.field) == null ? void 0 : V.disabled, placeholder: !p.value }]),
120
+ class: K(["select-trigger", { disabled: (M = t.field) == null ? void 0 : M.disabled, placeholder: !m.value }]),
119
121
  onClick: g
120
122
  },
121
123
  [
122
124
  l(
123
125
  "span",
124
126
  null,
125
- A(p.value || t.item.placeholder || "请选择"),
127
+ $(m.value || t.item.placeholder || "请选择"),
126
128
  1
127
129
  /* TEXT */
128
130
  )
@@ -130,10 +132,10 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
130
132
  2
131
133
  /* CLASS */
132
134
  ),
133
- I(" 遮罩 + 底部弹窗 "),
134
- X(Q, { name: "panel" }, {
135
- default: Z(() => [
136
- u.value ? (s(), r("div", {
135
+ x(" 遮罩 + 底部弹窗 "),
136
+ se(ie, { name: "panel" }, {
137
+ default: te(() => [
138
+ f.value ? (s(), i("div", {
137
139
  key: 0,
138
140
  class: "select-overlay",
139
141
  onClick: a
@@ -142,15 +144,15 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
142
144
  class: "select-panel",
143
145
  role: "dialog",
144
146
  "aria-label": "选择选项",
145
- onClick: h[0] || (h[0] = W(() => {
147
+ onClick: y[0] || (y[0] = ae(() => {
146
148
  }, ["stop"]))
147
149
  }, [
148
- I(" 头部 "),
149
- l("div", Ie, [
150
+ x(" 头部 "),
151
+ l("div", ot, [
150
152
  l(
151
153
  "span",
152
- Ae,
153
- A(f.value),
154
+ st,
155
+ $(h.value),
154
156
  1
155
157
  /* TEXT */
156
158
  ),
@@ -160,41 +162,41 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
160
162
  "aria-label": "关闭"
161
163
  }, "×")
162
164
  ]),
163
- I(" 选项列表 "),
164
- l("div", Ve, [
165
- (s(!0), r(
166
- B,
165
+ x(" 选项列表 "),
166
+ l("div", it, [
167
+ (s(!0), i(
168
+ q,
167
169
  null,
168
- U(m.value, (v) => (s(), r("div", {
170
+ W(p.value, (v) => (s(), i("div", {
169
171
  key: v.code,
170
- class: R(["option-card", { "option-selected": v._selected }]),
172
+ class: K(["option-card", { "option-selected": v._selected }]),
171
173
  role: "option",
172
174
  "aria-selected": v._selected,
173
- onClick: (b) => o(v)
175
+ onClick: (T) => o(v)
174
176
  }, [
175
177
  l(
176
178
  "span",
177
- De,
178
- A(v.name),
179
+ ct,
180
+ $(v.name),
179
181
  1
180
182
  /* TEXT */
181
183
  ),
182
184
  l(
183
185
  "span",
184
186
  {
185
- class: R(["option-btn", { "option-btn-selected": v._selected }])
187
+ class: K(["option-btn", { "option-btn-selected": v._selected }])
186
188
  },
187
- A(v._selected ? "✓ 已选" : "选择"),
189
+ $(v._selected ? "✓ 已选" : "选择"),
188
190
  3
189
191
  /* TEXT, CLASS */
190
192
  )
191
- ], 10, Fe))),
193
+ ], 10, rt))),
192
194
  128
193
195
  /* KEYED_FRAGMENT */
194
196
  ))
195
197
  ]),
196
- I(" iOS 安全区占位 "),
197
- h[1] || (h[1] = l(
198
+ x(" iOS 安全区占位 "),
199
+ y[1] || (y[1] = l(
198
200
  "div",
199
201
  { class: "safe-area-bottom" },
200
202
  null,
@@ -202,7 +204,7 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
202
204
  /* CACHED */
203
205
  ))
204
206
  ])
205
- ])) : I("v-if", !0)
207
+ ])) : x("v-if", !0)
206
208
  ]),
207
209
  _: 1
208
210
  /* STABLE */
@@ -210,19 +212,19 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
210
212
  ]);
211
213
  };
212
214
  }
213
- }), Pe = /* @__PURE__ */ N(Me, [["__scopeId", "data-v-352c2c2f"]]), Oe = { class: "ctrl-cascader" }, je = ["aria-label"], Re = { class: "panel-header" }, Le = { class: "panel-title" }, Ne = {
215
+ }), dt = /* @__PURE__ */ Y(ut, [["__scopeId", "data-v-352c2c2f"]]), vt = { class: "ctrl-cascader" }, ft = ["aria-label"], mt = { class: "panel-header" }, pt = { class: "panel-title" }, ht = {
214
216
  key: 0,
215
217
  class: "panel-path"
216
- }, Be = {
218
+ }, gt = {
217
219
  class: "panel-body",
218
220
  role: "listbox"
219
- }, Ee = ["onClick"], Ue = { class: "option-text" }, He = {
221
+ }, yt = ["onClick"], kt = { class: "option-text" }, bt = {
220
222
  key: 0,
221
223
  class: "option-arrow"
222
- }, Ke = {
224
+ }, _t = {
223
225
  key: 0,
224
226
  class: "option-empty"
225
- }, Ge = /* @__PURE__ */ L({
227
+ }, Ct = /* @__PURE__ */ U({
226
228
  __name: "CascaderControl",
227
229
  props: {
228
230
  item: {},
@@ -231,66 +233,66 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
231
233
  },
232
234
  emits: ["change"],
233
235
  setup(t, { emit: n }) {
234
- const e = t, y = n, u = D(!1), m = D([]), p = C(() => {
236
+ const e = t, r = n, f = E(!1), p = E([]), m = b(() => {
235
237
  var v;
236
238
  return ((v = e.item) == null ? void 0 : v.initOptions) || [];
237
- }), f = C(() => {
239
+ }), h = b(() => {
238
240
  var v;
239
- return m.value.length === 0 ? p.value : ((v = m.value[m.value.length - 1]) == null ? void 0 : v.child) || [];
240
- }), g = C(() => {
241
- var b, w;
242
- const v = (b = e.field) == null ? void 0 : b.value;
241
+ return p.value.length === 0 ? m.value : ((v = p.value[p.value.length - 1]) == null ? void 0 : v.child) || [];
242
+ }), g = b(() => {
243
+ var T, A;
244
+ const v = (T = e.field) == null ? void 0 : T.value;
243
245
  if (!v) return "";
244
246
  if (typeof v == "object" && v !== null) {
245
247
  if (Array.isArray(v.pathNames)) return v.pathNames.join(" / ");
246
248
  if (v.name) return String(v.name);
247
249
  if (v.showValue) return String(v.showValue);
248
250
  }
249
- return (w = e.field) != null && w.showValue ? String(e.field.showValue) : String(v);
250
- }), a = C(() => {
251
+ return (A = e.field) != null && A.showValue ? String(e.field.showValue) : String(v);
252
+ }), a = b(() => {
251
253
  var v;
252
254
  return ((v = e.item.props) == null ? void 0 : v.dialogTitle) || e.item.label || "请选择";
253
255
  });
254
256
  function o() {
255
257
  var v;
256
- (v = e.field) != null && v.disabled || (m.value = [], u.value = !0);
258
+ (v = e.field) != null && v.disabled || (p.value = [], f.value = !0);
257
259
  }
258
- function i() {
259
- u.value = !1;
260
+ function c() {
261
+ f.value = !1;
260
262
  }
261
- function h(v) {
262
- const b = [...m.value, v];
263
+ function y(v) {
264
+ const T = [...p.value, v];
263
265
  if (v.child && v.child.length > 0) {
264
- m.value = b;
266
+ p.value = T;
265
267
  return;
266
268
  }
267
- y("change", {
269
+ r("change", {
268
270
  value: {
269
271
  code: v.code,
270
272
  name: v.name,
271
- pathCodes: b.map((w) => w.code),
272
- pathNames: b.map((w) => w.name)
273
+ pathCodes: T.map((A) => A.code),
274
+ pathNames: T.map((A) => A.name)
273
275
  },
274
276
  eventType: "pickChange"
275
- }), u.value = !1;
277
+ }), f.value = !1;
276
278
  }
277
- function V() {
278
- m.value = m.value.slice(0, -1);
279
+ function M() {
280
+ p.value = p.value.slice(0, -1);
279
281
  }
280
- return (v, b) => {
281
- var w;
282
- return s(), r("div", Oe, [
282
+ return (v, T) => {
283
+ var A;
284
+ return s(), i("div", vt, [
283
285
  l(
284
286
  "div",
285
287
  {
286
- class: R(["cascader-trigger", { disabled: (w = t.field) == null ? void 0 : w.disabled, placeholder: !g.value }]),
288
+ class: K(["cascader-trigger", { disabled: (A = t.field) == null ? void 0 : A.disabled, placeholder: !g.value }]),
287
289
  onClick: o
288
290
  },
289
291
  [
290
292
  l(
291
293
  "span",
292
294
  null,
293
- A(g.value || t.item.placeholder || "请选择"),
295
+ $(g.value || t.item.placeholder || "请选择"),
294
296
  1
295
297
  /* TEXT */
296
298
  )
@@ -298,32 +300,32 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
298
300
  2
299
301
  /* CLASS */
300
302
  ),
301
- X(Q, { name: "panel" }, {
302
- default: Z(() => [
303
- u.value ? (s(), r("div", {
303
+ se(ie, { name: "panel" }, {
304
+ default: te(() => [
305
+ f.value ? (s(), i("div", {
304
306
  key: 0,
305
307
  class: "cascader-overlay",
306
- onClick: i
308
+ onClick: c
307
309
  }, [
308
310
  l("div", {
309
311
  class: "cascader-panel",
310
312
  role: "dialog",
311
313
  "aria-label": a.value,
312
- onClick: b[0] || (b[0] = W(() => {
314
+ onClick: T[0] || (T[0] = ae(() => {
313
315
  }, ["stop"]))
314
316
  }, [
315
- l("div", Re, [
316
- m.value.length ? (s(), r("button", {
317
+ l("div", mt, [
318
+ p.value.length ? (s(), i("button", {
317
319
  key: 0,
318
320
  type: "button",
319
321
  class: "panel-back",
320
322
  "aria-label": "返回上一级",
321
- onClick: V
322
- }, " ‹ ")) : I("v-if", !0),
323
+ onClick: M
324
+ }, " ‹ ")) : x("v-if", !0),
323
325
  l(
324
326
  "span",
325
- Le,
326
- A(a.value),
327
+ pt,
328
+ $(a.value),
327
329
  1
328
330
  /* TEXT */
329
331
  ),
@@ -331,52 +333,52 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
331
333
  type: "button",
332
334
  class: "panel-close",
333
335
  "aria-label": "关闭",
334
- onClick: i
336
+ onClick: c
335
337
  }, "×")
336
338
  ]),
337
- m.value.length ? (s(), r(
339
+ p.value.length ? (s(), i(
338
340
  "div",
339
- Ne,
340
- A(m.value.map((P) => P.name).join(" / ")),
341
+ ht,
342
+ $(p.value.map((L) => L.name).join(" / ")),
341
343
  1
342
344
  /* TEXT */
343
- )) : I("v-if", !0),
344
- l("div", Be, [
345
- (s(!0), r(
346
- B,
345
+ )) : x("v-if", !0),
346
+ l("div", gt, [
347
+ (s(!0), i(
348
+ q,
347
349
  null,
348
- U(f.value, (P) => {
349
- var O;
350
- return s(), r("div", {
351
- key: P.code,
350
+ W(h.value, (L) => {
351
+ var P;
352
+ return s(), i("div", {
353
+ key: L.code,
352
354
  class: "option-card",
353
355
  role: "option",
354
- onClick: (c) => h(P)
356
+ onClick: (u) => y(L)
355
357
  }, [
356
358
  l(
357
359
  "span",
358
- Ue,
359
- A(P.name),
360
+ kt,
361
+ $(L.name),
360
362
  1
361
363
  /* TEXT */
362
364
  ),
363
- (O = P.child) != null && O.length ? (s(), r("span", He, "›")) : I("v-if", !0)
364
- ], 8, Ee);
365
+ (P = L.child) != null && P.length ? (s(), i("span", bt, "›")) : x("v-if", !0)
366
+ ], 8, yt);
365
367
  }),
366
368
  128
367
369
  /* KEYED_FRAGMENT */
368
370
  )),
369
- f.value.length ? I("v-if", !0) : (s(), r("div", Ke, "暂无选项"))
371
+ h.value.length ? x("v-if", !0) : (s(), i("div", _t, "暂无选项"))
370
372
  ]),
371
- b[1] || (b[1] = l(
373
+ T[1] || (T[1] = l(
372
374
  "div",
373
375
  { class: "safe-area-bottom" },
374
376
  null,
375
377
  -1
376
378
  /* CACHED */
377
379
  ))
378
- ], 8, je)
379
- ])) : I("v-if", !0)
380
+ ], 8, ft)
381
+ ])) : x("v-if", !0)
380
382
  ]),
381
383
  _: 1
382
384
  /* STABLE */
@@ -384,16 +386,16 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
384
386
  ]);
385
387
  };
386
388
  }
387
- }), ze = /* @__PURE__ */ N(Ge, [["__scopeId", "data-v-a66f7439"]]), Ye = { class: "ctrl-search" }, qe = ["value", "placeholder", "disabled"], We = {
389
+ }), $t = /* @__PURE__ */ Y(Ct, [["__scopeId", "data-v-a66f7439"]]), Tt = { class: "ctrl-search" }, wt = ["value", "placeholder", "disabled"], St = {
388
390
  key: 0,
389
391
  class: "search-icon loading"
390
- }, Je = ["onClick"], Xe = { class: "result-name" }, Qe = {
392
+ }, xt = ["onClick"], At = { class: "result-name" }, It = {
391
393
  key: 0,
392
394
  class: "result-code"
393
- }, Ze = {
395
+ }, Ot = {
394
396
  key: 0,
395
397
  class: "search-hint"
396
- }, et = /* @__PURE__ */ L({
398
+ }, Mt = /* @__PURE__ */ U({
397
399
  __name: "SearchControl",
398
400
  props: {
399
401
  item: {},
@@ -402,62 +404,62 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
402
404
  },
403
405
  emits: ["change"],
404
406
  setup(t, { emit: n }) {
405
- const e = t, y = n, u = D(""), m = D([]), p = D(!1), f = D(!1), g = D(!1), a = C(() => {
406
- var c;
407
- return ((c = e.item.props) == null ? void 0 : c.searchApi) || "";
408
- }), o = D(null), i = D({});
409
- G(() => {
410
- var c;
411
- return (c = e.field) == null ? void 0 : c.value;
412
- }, (c) => {
413
- g.value || (c && typeof c == "object" && c.name ? u.value = c.name : typeof c == "string" && c ? u.value = c : u.value = "");
414
- }, { immediate: !0 }), C(() => {
415
- var k, M;
416
- const c = (k = e.field) == null ? void 0 : k.value;
417
- return c ? typeof c == "object" && c.name ? c.name : (M = e.field) != null && M.showValue ? e.field.showValue : String(c) : "";
407
+ const e = t, r = n, f = E(""), p = E([]), m = E(!1), h = E(!1), g = E(!1), a = b(() => {
408
+ var u;
409
+ return ((u = e.item.props) == null ? void 0 : u.searchApi) || "";
410
+ }), o = E(null), c = E({});
411
+ Z(() => {
412
+ var u;
413
+ return (u = e.field) == null ? void 0 : u.value;
414
+ }, (u) => {
415
+ g.value || (u && typeof u == "object" && u.name ? f.value = u.name : typeof u == "string" && u ? f.value = u : f.value = "");
416
+ }, { immediate: !0 }), b(() => {
417
+ var k, V;
418
+ const u = (k = e.field) == null ? void 0 : k.value;
419
+ return u ? typeof u == "object" && u.name ? u.name : (V = e.field) != null && V.showValue ? e.field.showValue : String(u) : "";
418
420
  });
419
- function h() {
421
+ function y() {
420
422
  if (!o.value) return;
421
- const c = o.value.getBoundingClientRect();
422
- i.value = {
423
+ const u = o.value.getBoundingClientRect();
424
+ c.value = {
423
425
  position: "fixed",
424
- top: `${c.bottom + 2}px`,
425
- left: `${c.left}px`,
426
- width: `${c.width}px`
426
+ top: `${u.bottom + 2}px`,
427
+ left: `${u.left}px`,
428
+ width: `${u.width}px`
427
429
  };
428
430
  }
429
- let V = null;
430
- function v(c) {
431
- const k = c.target;
432
- u.value = k.value, g.value = !0, V && clearTimeout(V), V = setTimeout(() => {
433
- u.value.trim() ? b(u.value.trim()) : (m.value = [], p.value = !1);
431
+ let M = null;
432
+ function v(u) {
433
+ const k = u.target;
434
+ f.value = k.value, g.value = !0, M && clearTimeout(M), M = setTimeout(() => {
435
+ f.value.trim() ? T(f.value.trim()) : (p.value = [], m.value = !1);
434
436
  }, 200);
435
437
  }
436
- async function b(c) {
438
+ async function T(u) {
437
439
  if (a.value) {
438
- f.value = !0;
440
+ h.value = !0;
439
441
  try {
440
- const k = await e.formCore.fetchApi(a.value, { keywords: c }), M = Array.isArray(k) ? k : (k == null ? void 0 : k.data) || (k == null ? void 0 : k.list) || [];
441
- m.value = M, M.length > 0 && (h(), p.value = !0);
442
+ const k = await e.formCore.fetchApi(a.value, { keywords: u }), V = Array.isArray(k) ? k : (k == null ? void 0 : k.data) || (k == null ? void 0 : k.list) || [];
443
+ p.value = V, V.length > 0 && (y(), m.value = !0);
442
444
  } catch {
443
- m.value = [], p.value = !1;
445
+ p.value = [], m.value = !1;
444
446
  } finally {
445
- f.value = !1;
447
+ h.value = !1;
446
448
  }
447
449
  }
448
450
  }
449
- function w(c) {
450
- y("change", { value: c.name, eventType: "searchChange" }), u.value = c.name, g.value = !1, p.value = !1;
451
+ function A(u) {
452
+ r("change", { value: u.name, eventType: "searchChange" }), f.value = u.name, g.value = !1, m.value = !1;
451
453
  }
452
- function P() {
453
- m.value.length > 0 && u.value && (h(), p.value = !0);
454
+ function L() {
455
+ p.value.length > 0 && f.value && (y(), m.value = !0);
454
456
  }
455
- function O() {
456
- p.value = !1, m.value = [], g.value && y("change", { value: u.value.trim(), eventType: "inputBlur" }), g.value = !1;
457
+ function P() {
458
+ m.value = !1, p.value = [], g.value && r("change", { value: f.value.trim(), eventType: "inputBlur" }), g.value = !1;
457
459
  }
458
- return (c, k) => {
459
- var M;
460
- return s(), r("div", Ye, [
460
+ return (u, k) => {
461
+ var V;
462
+ return s(), i("div", Tt, [
461
463
  l(
462
464
  "div",
463
465
  {
@@ -469,75 +471,75 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
469
471
  l("input", {
470
472
  class: "search-input",
471
473
  type: "text",
472
- value: u.value,
474
+ value: f.value,
473
475
  placeholder: t.item.placeholder || "请输入关键词搜索",
474
- disabled: (M = t.field) == null ? void 0 : M.disabled,
476
+ disabled: (V = t.field) == null ? void 0 : V.disabled,
475
477
  onInput: v,
476
- onFocus: P,
477
- onBlur: O
478
- }, null, 40, qe),
479
- f.value ? (s(), r("span", We, "⏳")) : I("v-if", !0)
478
+ onFocus: L,
479
+ onBlur: P
480
+ }, null, 40, wt),
481
+ h.value ? (s(), i("span", St, "⏳")) : x("v-if", !0)
480
482
  ],
481
483
  512
482
484
  /* NEED_PATCH */
483
485
  ),
484
- I(" 下拉结果列表 — Teleport 到 body,fixed 定位避免被父容器裁剪 "),
485
- (s(), J(re, { to: "body" }, [
486
- p.value && m.value.length > 0 ? (s(), r(
486
+ x(" 下拉结果列表 — Teleport 到 body,fixed 定位避免被父容器裁剪 "),
487
+ (s(), ee(Ie, { to: "body" }, [
488
+ m.value && p.value.length > 0 ? (s(), i(
487
489
  "div",
488
490
  {
489
491
  key: 0,
490
492
  class: "search-dropdown",
491
- style: oe(i.value)
493
+ style: re(c.value)
492
494
  },
493
495
  [
494
- (s(!0), r(
495
- B,
496
+ (s(!0), i(
497
+ q,
496
498
  null,
497
- U(m.value, (d) => (s(), r("div", {
499
+ W(p.value, (d) => (s(), i("div", {
498
500
  key: d.code,
499
501
  class: "search-result-item",
500
- onMousedown: k[0] || (k[0] = W(() => {
502
+ onMousedown: k[0] || (k[0] = ae(() => {
501
503
  }, ["prevent"])),
502
- onClick: (T) => w(d)
504
+ onClick: (_) => A(d)
503
505
  }, [
504
506
  l(
505
507
  "span",
506
- Xe,
507
- A(d.name),
508
+ At,
509
+ $(d.name),
508
510
  1
509
511
  /* TEXT */
510
512
  ),
511
- d.code ? (s(), r(
513
+ d.code ? (s(), i(
512
514
  "span",
513
- Qe,
514
- A(d.code),
515
+ It,
516
+ $(d.code),
515
517
  1
516
518
  /* TEXT */
517
- )) : I("v-if", !0)
518
- ], 40, Je))),
519
+ )) : x("v-if", !0)
520
+ ], 40, xt))),
519
521
  128
520
522
  /* KEYED_FRAGMENT */
521
523
  ))
522
524
  ],
523
525
  4
524
526
  /* STYLE */
525
- )) : I("v-if", !0)
527
+ )) : x("v-if", !0)
526
528
  ])),
527
- a.value ? I("v-if", !0) : (s(), r("div", Ze, " ⚠ 未配置 searchApi "))
529
+ a.value ? x("v-if", !0) : (s(), i("div", Ot, " ⚠ 未配置 searchApi "))
528
530
  ]);
529
531
  };
530
532
  }
531
- }), tt = /* @__PURE__ */ N(et, [["__scopeId", "data-v-1e915735"]]), lt = { class: "ctrl-address" }, at = { class: "addr-hd" }, nt = { class: "addr-crumbs" }, ot = ["onClick"], st = { class: "addr-body" }, it = {
533
+ }), Vt = /* @__PURE__ */ Y(Mt, [["__scopeId", "data-v-1e915735"]]), Et = { class: "ctrl-address" }, Pt = { class: "addr-hd" }, Ft = { class: "addr-crumbs" }, Dt = ["onClick"], Rt = { class: "addr-body" }, Nt = {
532
534
  key: 0,
533
535
  class: "addr-loading"
534
- }, rt = ["onClick"], ct = {
536
+ }, Lt = ["onClick"], jt = {
535
537
  key: 0,
536
538
  class: "addr-check"
537
- }, ut = {
539
+ }, Bt = {
538
540
  key: 1,
539
541
  class: "addr-empty"
540
- }, dt = /* @__PURE__ */ L({
542
+ }, Kt = /* @__PURE__ */ U({
541
543
  __name: "AddressControl",
542
544
  props: {
543
545
  item: {},
@@ -547,117 +549,117 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
547
549
  },
548
550
  emits: ["change"],
549
551
  setup(t, { emit: n }) {
550
- const e = t, y = n, u = C(() => {
551
- var d, T;
552
- return ((T = (d = e.item) == null ? void 0 : d.props) == null ? void 0 : T.linkageUrl) || "service/geo_code";
553
- }), m = C(() => {
554
- var d, T;
555
- return ((T = (d = e.item) == null ? void 0 : d.props) == null ? void 0 : T.mapLevel) || 3;
556
- }), p = D(!1), f = D(0), g = D(!1), a = D(!1), o = D([]), i = D([{ adcode: "", name: "请选择" }]), h = /* @__PURE__ */ new Map(), V = C(() => {
557
- var T, S, $;
558
- const d = (T = e.field) == null ? void 0 : T.value;
559
- if (Array.isArray(d) && d.length) return d.map((F) => F.name).join("");
560
- if ((S = e.field) != null && S.showValue) return e.field.showValue;
552
+ const e = t, r = n, f = b(() => {
553
+ var d, _;
554
+ return ((_ = (d = e.item) == null ? void 0 : d.props) == null ? void 0 : _.linkageUrl) || "service/geo_code";
555
+ }), p = b(() => {
556
+ var d, _;
557
+ return ((_ = (d = e.item) == null ? void 0 : d.props) == null ? void 0 : _.mapLevel) || 3;
558
+ }), m = E(!1), h = E(0), g = E(!1), a = E(!1), o = E([]), c = E([{ adcode: "", name: "请选择" }]), y = /* @__PURE__ */ new Map(), M = b(() => {
559
+ var _, I, w;
560
+ const d = (_ = e.field) == null ? void 0 : _.value;
561
+ if (Array.isArray(d) && d.length) return d.map((O) => O.name).join("");
562
+ if ((I = e.field) != null && I.showValue) return e.field.showValue;
561
563
  if (d && typeof d == "object") {
562
- const F = [d.province, d.city, d.country].filter(Boolean);
563
- if (F.length) return F.join("");
564
+ const O = [d.province, d.city, d.country].filter(Boolean);
565
+ if (O.length) return O.join("");
564
566
  }
565
- return ($ = e.field) != null && $.province ? [e.field.province, e.field.city, e.field.country].filter(Boolean).join("") : typeof d == "string" && d ? d : "";
566
- }), v = C(() => i.value.slice(0, m.value));
567
- function b() {
567
+ return (w = e.field) != null && w.province ? [e.field.province, e.field.city, e.field.country].filter(Boolean).join("") : typeof d == "string" && d ? d : "";
568
+ }), v = b(() => c.value.slice(0, p.value));
569
+ function T() {
568
570
  var d;
569
571
  return e.onFetchLinkage ? e.onFetchLinkage : (d = e.formCore) != null && d._linkageFetcher ? e.formCore._linkageFetcher : async () => ({ data: [] });
570
572
  }
571
- async function w(d) {
572
- var F, x, _;
573
+ async function A(d) {
574
+ var O, S, C;
573
575
  g.value = !0;
574
- const T = b(), S = i.value.filter((j) => j.adcode), $ = {
575
- province_code: ((F = S[0]) == null ? void 0 : F.adcode) || "",
576
- city_code: ((x = S[1]) == null ? void 0 : x.adcode) || "",
577
- district_code: ((_ = S[2]) == null ? void 0 : _.adcode) || ""
576
+ const _ = T(), I = c.value.filter((j) => j.adcode), w = {
577
+ province_code: ((O = I[0]) == null ? void 0 : O.adcode) || "",
578
+ city_code: ((S = I[1]) == null ? void 0 : S.adcode) || "",
579
+ district_code: ((C = I[2]) == null ? void 0 : C.adcode) || ""
578
580
  };
579
581
  try {
580
- const j = await T($, u.value);
582
+ const j = await _(w, f.value);
581
583
  if (j.data === null) {
582
- i.value = i.value.filter((H) => H.adcode), a.value = !0, g.value = !1, M();
584
+ c.value = c.value.filter((B) => B.adcode), a.value = !0, g.value = !1, V();
583
585
  return;
584
586
  }
585
587
  o.value = j.data || [];
586
- const E = d || $.district_code || $.city_code || $.province_code || "root";
587
- o.value.length > 0 && h.set(E, o.value);
588
+ const z = d || w.district_code || w.city_code || w.province_code || "root";
589
+ o.value.length > 0 && y.set(z, o.value);
588
590
  } catch {
589
591
  } finally {
590
592
  g.value = !1;
591
593
  }
592
594
  }
595
+ function L() {
596
+ var I, w;
597
+ if ((I = e.field) != null && I.disabled) return;
598
+ h.value = 0;
599
+ const d = (w = e.field) == null ? void 0 : w.value;
600
+ Array.isArray(d) && d.length && d[0].code ? (c.value = d.map((O) => ({ adcode: O.code, name: O.name })), a.value = c.value.length >= 2) : (c.value = [{ adcode: "", name: "请选择" }], a.value = !1), m.value = !0;
601
+ const _ = y.get("root");
602
+ _ ? o.value = _ : A("root");
603
+ }
593
604
  function P() {
594
- var S, $;
595
- if ((S = e.field) != null && S.disabled) return;
596
- f.value = 0;
597
- const d = ($ = e.field) == null ? void 0 : $.value;
598
- Array.isArray(d) && d.length && d[0].code ? (i.value = d.map((F) => ({ adcode: F.code, name: F.name })), a.value = i.value.length >= 2) : (i.value = [{ adcode: "", name: "请选择" }], a.value = !1), p.value = !0;
599
- const T = h.get("root");
600
- T ? o.value = T : w("root");
601
- }
602
- function O() {
603
- p.value = !1;
605
+ m.value = !1;
604
606
  }
605
- function c(d) {
607
+ function u(d) {
606
608
  if (g.value || !d.adcode) return;
607
- const T = { 71e4: 1, 81e4: 2, 82e4: 2 }, S = [...i.value];
608
- d.brother = o.value, S[f.value] = d;
609
- const $ = T[d.adcode];
610
- if ($ !== void 0) {
611
- S.splice($, S.length - $), i.value = S.filter((_) => _.adcode), a.value = !0, M();
609
+ const _ = { 71e4: 1, 81e4: 2, 82e4: 2 }, I = [...c.value];
610
+ d.brother = o.value, I[h.value] = d;
611
+ const w = _[d.adcode];
612
+ if (w !== void 0) {
613
+ I.splice(w, I.length - w), c.value = I.filter((C) => C.adcode), a.value = !0, V();
612
614
  return;
613
615
  }
614
- if (f.value < m.value - 1 && (S[f.value + 1] = { adcode: "", name: "" }, S.splice(f.value + 2)), f.value += 1, i.value = S.slice(0, m.value), S.filter((_) => _.adcode).length >= m.value) {
615
- a.value = !0, M();
616
+ if (h.value < p.value - 1 && (I[h.value + 1] = { adcode: "", name: "" }, I.splice(h.value + 2)), h.value += 1, c.value = I.slice(0, p.value), I.filter((C) => C.adcode).length >= p.value) {
617
+ a.value = !0, V();
616
618
  return;
617
619
  }
618
- const x = h.get(d.adcode);
619
- x ? o.value = x : w(d.adcode);
620
+ const S = y.get(d.adcode);
621
+ S ? o.value = S : A(d.adcode);
620
622
  }
621
623
  function k(d) {
622
- var $;
623
- f.value = d, a.value = !1;
624
- const T = i.value.slice(0, d + 1);
625
- T[d].adcode || (T[d] = { adcode: "", name: "请选择" }), i.value = T;
626
- const S = i.value[d];
627
- if (S.adcode && S.brother)
628
- o.value = S.brother;
624
+ var w;
625
+ h.value = d, a.value = !1;
626
+ const _ = c.value.slice(0, d + 1);
627
+ _[d].adcode || (_[d] = { adcode: "", name: "请选择" }), c.value = _;
628
+ const I = c.value[d];
629
+ if (I.adcode && I.brother)
630
+ o.value = I.brother;
629
631
  else {
630
- const F = d > 0 ? ($ = i.value[d - 1]) == null ? void 0 : $.adcode : "root", x = h.get(F);
631
- x ? o.value = x : w(F);
632
+ const O = d > 0 ? (w = c.value[d - 1]) == null ? void 0 : w.adcode : "root", S = y.get(O);
633
+ S ? o.value = S : A(O);
632
634
  }
633
635
  }
634
- function M() {
635
- const d = i.value.filter(($) => $.adcode);
636
+ function V() {
637
+ const d = c.value.filter((w) => w.adcode);
636
638
  if (d.length === 0) return;
637
- const T = d.map(($) => ({ code: $.adcode, name: $.name })), S = { showValue: "" };
638
- T.forEach(($, F) => {
639
- S.showValue += $.name, F === 0 && (S.province_code = $.code, S.province = $.name), F === 1 && (S.city_code = $.code, S.city = $.name), F === 2 && (S.country_code = $.code, S.country = $.name);
640
- }), y("change", { value: T, eventType: "pickChange", ...S }), p.value = !1;
639
+ const _ = d.map((w) => ({ code: w.adcode, name: w.name })), I = { showValue: "" };
640
+ _.forEach((w, O) => {
641
+ I.showValue += w.name, O === 0 && (I.province_code = w.code, I.province = w.name), O === 1 && (I.city_code = w.code, I.city = w.name), O === 2 && (I.country_code = w.code, I.country = w.name);
642
+ }), r("change", { value: _, eventType: "pickChange", ...I }), m.value = !1;
641
643
  }
642
- return G(() => {
644
+ return Z(() => {
643
645
  var d;
644
646
  return (d = e.field) == null ? void 0 : d.value;
645
647
  }, (d) => {
646
- !p.value && Array.isArray(d) && d.length && (i.value = d.map((T) => ({ adcode: T.code, name: T.name })));
647
- }), (d, T) => {
648
- var S;
649
- return s(), r("div", lt, [
648
+ !m.value && Array.isArray(d) && d.length && (c.value = d.map((_) => ({ adcode: _.code, name: _.name })));
649
+ }), (d, _) => {
650
+ var I;
651
+ return s(), i("div", Et, [
650
652
  l(
651
653
  "div",
652
654
  {
653
- class: R(["address-trigger", { disabled: (S = t.field) == null ? void 0 : S.disabled, placeholder: !V.value }]),
654
- onClick: P
655
+ class: K(["address-trigger", { disabled: (I = t.field) == null ? void 0 : I.disabled, placeholder: !M.value }]),
656
+ onClick: L
655
657
  },
656
658
  [
657
659
  l(
658
660
  "span",
659
661
  null,
660
- A(V.value || t.item.placeholder || "请选择省市区"),
662
+ $(M.value || t.item.placeholder || "请选择省市区"),
661
663
  1
662
664
  /* TEXT */
663
665
  )
@@ -665,27 +667,27 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
665
667
  2
666
668
  /* CLASS */
667
669
  ),
668
- X(Q, { name: "addr-fade" }, {
669
- default: Z(() => [
670
- p.value ? (s(), r("div", {
670
+ se(ie, { name: "addr-fade" }, {
671
+ default: te(() => [
672
+ m.value ? (s(), i("div", {
671
673
  key: 0,
672
674
  class: "addr-mask",
673
- onClick: O
675
+ onClick: P
674
676
  }, [
675
- X(Q, { name: "addr-slide" }, {
676
- default: Z(() => [
677
- p.value ? (s(), r("div", {
677
+ se(ie, { name: "addr-slide" }, {
678
+ default: te(() => [
679
+ m.value ? (s(), i("div", {
678
680
  key: 0,
679
681
  class: "addr-panel",
680
- onClick: T[1] || (T[1] = W(() => {
682
+ onClick: _[1] || (_[1] = ae(() => {
681
683
  }, ["stop"]))
682
684
  }, [
683
- l("div", at, [
685
+ l("div", Pt, [
684
686
  l("span", {
685
687
  class: "addr-hd-cancel",
686
- onClick: O
688
+ onClick: P
687
689
  }, "取消"),
688
- T[2] || (T[2] = l(
690
+ _[2] || (_[2] = l(
689
691
  "span",
690
692
  { class: "addr-hd-title" },
691
693
  "选择地址",
@@ -695,45 +697,45 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
695
697
  l(
696
698
  "span",
697
699
  {
698
- class: R(["addr-hd-ok", { on: a.value }]),
699
- onClick: T[0] || (T[0] = ($) => a.value ? M() : null)
700
+ class: K(["addr-hd-ok", { on: a.value }]),
701
+ onClick: _[0] || (_[0] = (w) => a.value ? V() : null)
700
702
  },
701
703
  "确定",
702
704
  2
703
705
  /* CLASS */
704
706
  )
705
707
  ]),
706
- l("div", nt, [
707
- (s(!0), r(
708
- B,
708
+ l("div", Ft, [
709
+ (s(!0), i(
710
+ q,
709
711
  null,
710
- U(v.value, ($, F) => (s(), r(
711
- B,
712
- { key: F },
712
+ W(v.value, (w, O) => (s(), i(
713
+ q,
714
+ { key: O },
713
715
  [
714
716
  l(
715
717
  "span",
716
718
  {
717
- class: R(["addr-dot", { cur: F === f.value, done: !!$.adcode && F < f.value }])
719
+ class: K(["addr-dot", { cur: O === h.value, done: !!w.adcode && O < h.value }])
718
720
  },
719
721
  null,
720
722
  2
721
723
  /* CLASS */
722
724
  ),
723
725
  l("span", {
724
- class: R(["addr-label", { cur: F === f.value, done: !!$.adcode }]),
725
- onClick: (x) => $.adcode ? k(F) : null
726
- }, A($.adcode ? $.name : "请选择"), 11, ot),
727
- F < v.value.length - 1 ? (s(), r(
726
+ class: K(["addr-label", { cur: O === h.value, done: !!w.adcode }]),
727
+ onClick: (S) => w.adcode ? k(O) : null
728
+ }, $(w.adcode ? w.name : "请选择"), 11, Dt),
729
+ O < v.value.length - 1 ? (s(), i(
728
730
  "span",
729
731
  {
730
732
  key: 0,
731
- class: R(["addr-line", { done: !!$.adcode && F < f.value }])
733
+ class: K(["addr-line", { done: !!w.adcode && O < h.value }])
732
734
  },
733
735
  null,
734
736
  2
735
737
  /* CLASS */
736
- )) : I("v-if", !0)
738
+ )) : x("v-if", !0)
737
739
  ],
738
740
  64
739
741
  /* STABLE_FRAGMENT */
@@ -742,8 +744,8 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
742
744
  /* KEYED_FRAGMENT */
743
745
  ))
744
746
  ]),
745
- l("div", st, [
746
- g.value ? (s(), r("div", it, [...T[3] || (T[3] = [
747
+ l("div", Rt, [
748
+ g.value ? (s(), i("div", Nt, [..._[3] || (_[3] = [
747
749
  l(
748
750
  "span",
749
751
  { class: "addr-spinner" },
@@ -751,50 +753,50 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
751
753
  -1
752
754
  /* CACHED */
753
755
  ),
754
- Y(
756
+ X(
755
757
  "加载中...",
756
758
  -1
757
759
  /* CACHED */
758
760
  )
759
- ])])) : I("v-if", !0),
760
- (s(!0), r(
761
- B,
761
+ ])])) : x("v-if", !0),
762
+ (s(!0), i(
763
+ q,
762
764
  null,
763
- U(o.value, ($) => {
764
- var F, x;
765
- return s(), r("div", {
766
- key: $.adcode,
767
- class: R(["addr-item", { sel: ((F = i.value[f.value]) == null ? void 0 : F.adcode) === $.adcode }]),
768
- onClick: (_) => c($)
765
+ W(o.value, (w) => {
766
+ var O, S;
767
+ return s(), i("div", {
768
+ key: w.adcode,
769
+ class: K(["addr-item", { sel: ((O = c.value[h.value]) == null ? void 0 : O.adcode) === w.adcode }]),
770
+ onClick: (C) => u(w)
769
771
  }, [
770
772
  l(
771
773
  "span",
772
774
  null,
773
- A($.name),
775
+ $(w.name),
774
776
  1
775
777
  /* TEXT */
776
778
  ),
777
- ((x = i.value[f.value]) == null ? void 0 : x.adcode) === $.adcode ? (s(), r("span", ct, "✓")) : I("v-if", !0)
778
- ], 10, rt);
779
+ ((S = c.value[h.value]) == null ? void 0 : S.adcode) === w.adcode ? (s(), i("span", jt, "✓")) : x("v-if", !0)
780
+ ], 10, Lt);
779
781
  }),
780
782
  128
781
783
  /* KEYED_FRAGMENT */
782
784
  )),
783
- !g.value && o.value.length === 0 ? (s(), r("div", ut, "暂无数据")) : I("v-if", !0)
785
+ !g.value && o.value.length === 0 ? (s(), i("div", Bt, "暂无数据")) : x("v-if", !0)
784
786
  ]),
785
- T[4] || (T[4] = l(
787
+ _[4] || (_[4] = l(
786
788
  "div",
787
789
  { class: "addr-safe" },
788
790
  null,
789
791
  -1
790
792
  /* CACHED */
791
793
  ))
792
- ])) : I("v-if", !0)
794
+ ])) : x("v-if", !0)
793
795
  ]),
794
796
  _: 1
795
797
  /* STABLE */
796
798
  })
797
- ])) : I("v-if", !0)
799
+ ])) : x("v-if", !0)
798
800
  ]),
799
801
  _: 1
800
802
  /* STABLE */
@@ -802,10 +804,10 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
802
804
  ]);
803
805
  };
804
806
  }
805
- }), vt = /* @__PURE__ */ N(dt, [["__scopeId", "data-v-e9b83ac3"]]), ft = { class: "ctrl-agreement" }, mt = {
807
+ }), Ut = /* @__PURE__ */ Y(Kt, [["__scopeId", "data-v-e9b83ac3"]]), Ht = { class: "ctrl-agreement" }, Yt = {
806
808
  key: 0,
807
809
  class: "check-mark"
808
- }, pt = { class: "agreement-text" }, ht = /* @__PURE__ */ L({
810
+ }, qt = { class: "agreement-text" }, zt = /* @__PURE__ */ U({
809
811
  __name: "AgreementControl",
810
812
  props: {
811
813
  item: {},
@@ -814,17 +816,17 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
814
816
  },
815
817
  emits: ["change"],
816
818
  setup(t, { emit: n }) {
817
- const e = t, y = n, u = C(() => {
819
+ const e = t, r = n, f = b(() => {
818
820
  var a;
819
821
  return ((a = e.item.props) == null ? void 0 : a.trueValue) ?? "true";
820
- }), m = C(() => {
822
+ }), p = b(() => {
821
823
  var a;
822
824
  return ((a = e.item.props) == null ? void 0 : a.falseValue) ?? "";
823
- }), p = C(() => {
825
+ }), m = b(() => {
824
826
  var o;
825
827
  const a = (o = e.field) == null ? void 0 : o.value;
826
- return a === u.value || a === !0 || a === 1 || a === "1";
827
- }), f = C(
828
+ return a === f.value || a === !0 || a === 1 || a === "1";
829
+ }), h = b(
828
830
  () => {
829
831
  var a;
830
832
  return e.item.label || ((a = e.item.props) == null ? void 0 : a.guideText) || "本人已阅读并同意相关协议";
@@ -833,31 +835,31 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
833
835
  function g() {
834
836
  var o;
835
837
  if ((o = e.field) != null && o.disabled) return;
836
- const a = p.value ? m.value : u.value;
837
- y("change", { value: a, eventType: "pickChange" });
838
+ const a = m.value ? p.value : f.value;
839
+ r("change", { value: a, eventType: "pickChange" });
838
840
  }
839
841
  return (a, o) => {
840
- var i;
841
- return s(), r("div", ft, [
842
+ var c;
843
+ return s(), i("div", Ht, [
842
844
  l("label", {
843
845
  class: "agreement-row",
844
- onClick: W(g, ["prevent"])
846
+ onClick: ae(g, ["prevent"])
845
847
  }, [
846
848
  l(
847
849
  "span",
848
850
  {
849
- class: R(["checkbox", { checked: p.value, disabled: (i = t.field) == null ? void 0 : i.disabled }])
851
+ class: K(["checkbox", { checked: m.value, disabled: (c = t.field) == null ? void 0 : c.disabled }])
850
852
  },
851
853
  [
852
- p.value ? (s(), r("span", mt, "✓")) : I("v-if", !0)
854
+ m.value ? (s(), i("span", Yt, "✓")) : x("v-if", !0)
853
855
  ],
854
856
  2
855
857
  /* CLASS */
856
858
  ),
857
859
  l(
858
860
  "span",
859
- pt,
860
- A(f.value),
861
+ qt,
862
+ $(h.value),
861
863
  1
862
864
  /* TEXT */
863
865
  )
@@ -865,7 +867,7 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
865
867
  ]);
866
868
  };
867
869
  }
868
- }), gt = /* @__PURE__ */ N(ht, [["__scopeId", "data-v-16bbffa8"]]), yt = { class: "task-label" }, kt = { class: "modal-card" }, bt = { class: "modal-header" }, Ct = { class: "modal-body" }, _t = ["onUpdate:modelValue", "placeholder"], $t = /* @__PURE__ */ L({
870
+ }), Gt = /* @__PURE__ */ Y(zt, [["__scopeId", "data-v-16bbffa8"]]), Wt = { class: "task-label" }, Jt = { class: "modal-card" }, Xt = { class: "modal-header" }, Qt = { class: "modal-body" }, Zt = ["onUpdate:modelValue", "placeholder"], el = /* @__PURE__ */ U({
869
871
  __name: "SubFormTask",
870
872
  props: {
871
873
  item: {},
@@ -873,9 +875,9 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
873
875
  formCore: {}
874
876
  },
875
877
  setup(t) {
876
- const n = t, e = D(!1), y = D({}), u = C(() => {
877
- var h;
878
- const o = (h = n.item.props) == null ? void 0 : h.taskType, i = {
878
+ const n = t, e = E(!1), r = E({}), f = b(() => {
879
+ var y;
880
+ const o = (y = n.item.props) == null ? void 0 : y.taskType, c = {
879
881
  contact_info: [
880
882
  { label: "联系人姓名", key: "name", placeholder: "请输入姓名" },
881
883
  { label: "关系", key: "relation", placeholder: "如:朋友、同事" },
@@ -894,42 +896,42 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
894
896
  { label: "字段2", key: "field2", placeholder: "请输入" }
895
897
  ]
896
898
  };
897
- return i[o] || i.default;
899
+ return c[o] || c.default;
898
900
  });
899
- function m() {
900
- y.value = {}, u.value.forEach((o) => {
901
- y.value[o.key] = "";
901
+ function p() {
902
+ r.value = {}, f.value.forEach((o) => {
903
+ r.value[o.key] = "";
902
904
  }), e.value = !0;
903
905
  }
904
- function p() {
905
- e.value = !1, K(n.formCore, n.item.key, {
906
- ...y.value,
906
+ function m() {
907
+ e.value = !1, Q(n.formCore, n.item.key, {
908
+ ...r.value,
907
909
  _completed: !0,
908
910
  _completedAt: (/* @__PURE__ */ new Date()).toISOString()
909
911
  });
910
912
  }
911
- function f() {
913
+ function h() {
912
914
  e.value = !1;
913
915
  }
914
916
  function g(o) {
915
- o.stopPropagation(), o.target === o.currentTarget && f();
917
+ o.stopPropagation(), o.target === o.currentTarget && h();
916
918
  }
917
- const a = C(() => {
918
- var i;
919
- const o = (i = n.field) == null ? void 0 : i.value;
919
+ const a = b(() => {
920
+ var c;
921
+ const o = (c = n.field) == null ? void 0 : c.value;
920
922
  return o && typeof o == "object" && o._completed;
921
923
  });
922
- return (o, i) => (s(), r("div", {
924
+ return (o, c) => (s(), i("div", {
923
925
  class: "task-subform",
924
- onClick: m
926
+ onClick: p
925
927
  }, [
926
928
  l(
927
929
  "div",
928
930
  {
929
- class: R(["task-trigger", { completed: a.value }])
931
+ class: K(["task-trigger", { completed: a.value }])
930
932
  },
931
933
  [
932
- i[0] || (i[0] = l(
934
+ c[0] || (c[0] = l(
933
935
  "span",
934
936
  { class: "task-icon" },
935
937
  "📋",
@@ -938,12 +940,12 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
938
940
  )),
939
941
  l(
940
942
  "span",
941
- yt,
942
- A(a.value ? "✅ 已完成" : t.item.placeholder || "点击填写子表单"),
943
+ Wt,
944
+ $(a.value ? "✅ 已完成" : t.item.placeholder || "点击填写子表单"),
943
945
  1
944
946
  /* TEXT */
945
947
  ),
946
- i[1] || (i[1] = l(
948
+ c[1] || (c[1] = l(
947
949
  "span",
948
950
  { class: "task-arrow" },
949
951
  "▸",
@@ -954,47 +956,47 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
954
956
  2
955
957
  /* CLASS */
956
958
  ),
957
- I(" Modal "),
958
- e.value ? (s(), r("div", {
959
+ x(" Modal "),
960
+ e.value ? (s(), i("div", {
959
961
  key: 0,
960
962
  class: "modal-overlay",
961
963
  onClick: g
962
964
  }, [
963
- l("div", kt, [
964
- l("div", bt, [
965
+ l("div", Jt, [
966
+ l("div", Xt, [
965
967
  l(
966
968
  "span",
967
969
  null,
968
- A(t.item.label || "子表单"),
970
+ $(t.item.label || "子表单"),
969
971
  1
970
972
  /* TEXT */
971
973
  ),
972
974
  l("button", {
973
975
  class: "modal-close",
974
- onClick: f
976
+ onClick: h
975
977
  }, "✕")
976
978
  ]),
977
- l("div", Ct, [
978
- (s(!0), r(
979
- B,
979
+ l("div", Qt, [
980
+ (s(!0), i(
981
+ q,
980
982
  null,
981
- U(u.value, (h) => (s(), r("div", {
982
- key: h.key,
983
+ W(f.value, (y) => (s(), i("div", {
984
+ key: y.key,
983
985
  class: "modal-field"
984
986
  }, [
985
987
  l(
986
988
  "label",
987
989
  null,
988
- A(h.label),
990
+ $(y.label),
989
991
  1
990
992
  /* TEXT */
991
993
  ),
992
- ce(l("input", {
993
- "onUpdate:modelValue": (V) => y.value[h.key] = V,
994
- placeholder: h.placeholder,
994
+ Oe(l("input", {
995
+ "onUpdate:modelValue": (M) => r.value[y.key] = M,
996
+ placeholder: y.placeholder,
995
997
  class: "modal-input"
996
- }, null, 8, _t), [
997
- [ue, y.value[h.key]]
998
+ }, null, 8, Zt), [
999
+ [Me, r.value[y.key]]
998
1000
  ])
999
1001
  ]))),
1000
1002
  128
@@ -1004,18 +1006,18 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1004
1006
  l("div", { class: "modal-footer" }, [
1005
1007
  l("button", {
1006
1008
  class: "btn-cancel",
1007
- onClick: f
1009
+ onClick: h
1008
1010
  }, "取消"),
1009
1011
  l("button", {
1010
1012
  class: "btn-confirm",
1011
- onClick: p
1013
+ onClick: m
1012
1014
  }, "确认")
1013
1015
  ])
1014
1016
  ])
1015
- ])) : I("v-if", !0)
1017
+ ])) : x("v-if", !0)
1016
1018
  ]));
1017
1019
  }
1018
- }), ne = /* @__PURE__ */ N($t, [["__scopeId", "data-v-f15e7819"]]), Tt = { class: "task-label" }, wt = { class: "confirm-card" }, xt = { class: "confirm-url" }, St = /* @__PURE__ */ L({
1020
+ }), ge = /* @__PURE__ */ Y(el, [["__scopeId", "data-v-f15e7819"]]), tl = { class: "task-label" }, ll = { class: "confirm-card" }, al = { class: "confirm-url" }, nl = /* @__PURE__ */ U({
1019
1021
  __name: "H5JumpTask",
1020
1022
  props: {
1021
1023
  item: {},
@@ -1023,42 +1025,42 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1023
1025
  formCore: {}
1024
1026
  },
1025
1027
  setup(t) {
1026
- const n = t, e = D(!1), y = C(() => {
1028
+ const n = t, e = E(!1), r = b(() => {
1027
1029
  var a, o;
1028
1030
  return ((a = n.item.props) == null ? void 0 : a.h5link) || ((o = n.item.props) == null ? void 0 : o.taxLink) || "https://example.com/task";
1029
1031
  });
1030
- function u() {
1032
+ function f() {
1031
1033
  e.value = !0;
1032
1034
  }
1033
- function m() {
1035
+ function p() {
1034
1036
  e.value = !1, setTimeout(() => {
1035
- K(n.formCore, n.item.key, {
1036
- url: y.value,
1037
+ Q(n.formCore, n.item.key, {
1038
+ url: r.value,
1037
1039
  _completed: !0,
1038
1040
  _completedAt: (/* @__PURE__ */ new Date()).toISOString(),
1039
1041
  _mock: "模拟 H5 跳转已返回"
1040
1042
  });
1041
1043
  }, 500);
1042
1044
  }
1043
- function p() {
1045
+ function m() {
1044
1046
  e.value = !1;
1045
1047
  }
1046
- function f(a, o) {
1048
+ function h(a, o) {
1047
1049
  a.stopPropagation(), a.target === a.currentTarget && o();
1048
1050
  }
1049
- const g = C(() => {
1051
+ const g = b(() => {
1050
1052
  var o;
1051
1053
  const a = (o = n.field) == null ? void 0 : o.value;
1052
1054
  return a && typeof a == "object" && a._completed;
1053
1055
  });
1054
- return (a, o) => (s(), r("div", {
1056
+ return (a, o) => (s(), i("div", {
1055
1057
  class: "task-h5",
1056
- onClick: u
1058
+ onClick: f
1057
1059
  }, [
1058
1060
  l(
1059
1061
  "div",
1060
1062
  {
1061
- class: R(["task-trigger", { completed: g.value }])
1063
+ class: K(["task-trigger", { completed: g.value }])
1062
1064
  },
1063
1065
  [
1064
1066
  o[1] || (o[1] = l(
@@ -1070,8 +1072,8 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1070
1072
  )),
1071
1073
  l(
1072
1074
  "span",
1073
- Tt,
1074
- A(g.value ? "✅ 已完成" : t.item.placeholder || "点击跳转 H5 页面"),
1075
+ tl,
1076
+ $(g.value ? "✅ 已完成" : t.item.placeholder || "点击跳转 H5 页面"),
1075
1077
  1
1076
1078
  /* TEXT */
1077
1079
  ),
@@ -1093,13 +1095,13 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1093
1095
  2
1094
1096
  /* CLASS */
1095
1097
  ),
1096
- I(" 确认弹窗 "),
1097
- e.value ? (s(), r("div", {
1098
+ x(" 确认弹窗 "),
1099
+ e.value ? (s(), i("div", {
1098
1100
  key: 0,
1099
1101
  class: "modal-overlay",
1100
- onClick: o[0] || (o[0] = (i) => f(i, p))
1102
+ onClick: o[0] || (o[0] = (c) => h(c, m))
1101
1103
  }, [
1102
- l("div", wt, [
1104
+ l("div", ll, [
1103
1105
  o[4] || (o[4] = l(
1104
1106
  "div",
1105
1107
  { class: "confirm-icon" },
@@ -1116,8 +1118,8 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1116
1118
  )),
1117
1119
  l(
1118
1120
  "div",
1119
- xt,
1120
- A(y.value),
1121
+ al,
1122
+ $(r.value),
1121
1123
  1
1122
1124
  /* TEXT */
1123
1125
  ),
@@ -1131,21 +1133,21 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1131
1133
  l("div", { class: "confirm-actions" }, [
1132
1134
  l("button", {
1133
1135
  class: "btn-cancel",
1134
- onClick: p
1136
+ onClick: m
1135
1137
  }, "取消"),
1136
1138
  l("button", {
1137
1139
  class: "btn-confirm",
1138
- onClick: m
1140
+ onClick: p
1139
1141
  }, "确认跳转")
1140
1142
  ])
1141
1143
  ])
1142
- ])) : I("v-if", !0)
1144
+ ])) : x("v-if", !0)
1143
1145
  ]));
1144
1146
  }
1145
- }), It = /* @__PURE__ */ N(St, [["__scopeId", "data-v-2f7717cb"]]), At = { class: "task-icon" }, Vt = { class: "task-label" }, Ft = { class: "sig-card" }, Dt = { class: "sig-header" }, Mt = { class: "sig-body" }, Pt = {
1147
+ }), ol = /* @__PURE__ */ Y(nl, [["__scopeId", "data-v-2f7717cb"]]), sl = { class: "task-icon" }, il = { class: "task-label" }, rl = { class: "sig-card" }, cl = { class: "sig-header" }, ul = { class: "sig-body" }, dl = {
1146
1148
  key: 0,
1147
1149
  class: "sig-placeholder"
1148
- }, Ot = { class: "sig-footer" }, jt = ["disabled"], Rt = { class: "map-card" }, Lt = { class: "map-header" }, Nt = { class: "native-card" }, Bt = { class: "native-icon" }, Et = { class: "native-title" }, Ut = { class: "native-desc" }, Ht = { class: "native-actions" }, Kt = /* @__PURE__ */ L({
1150
+ }, vl = { class: "sig-footer" }, fl = ["disabled"], ml = { class: "map-card" }, pl = { class: "map-header" }, hl = { class: "native-card" }, gl = { class: "native-icon" }, yl = { class: "native-title" }, kl = { class: "native-desc" }, bl = { class: "native-actions" }, _l = /* @__PURE__ */ U({
1149
1151
  __name: "NativeTask",
1150
1152
  props: {
1151
1153
  item: {},
@@ -1153,61 +1155,61 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1153
1155
  formCore: {}
1154
1156
  },
1155
1157
  setup(t) {
1156
- de((x) => ({
1157
- v9ce02c4c: F.value
1158
+ Ve((S) => ({
1159
+ v9ce02c4c: O.value
1158
1160
  }));
1159
- const n = t, e = C(() => {
1160
- var x;
1161
- return ((x = n.item.props) == null ? void 0 : x.taskType) || "";
1162
- }), y = D(!1), u = D(null), m = D(!1), p = D(null), f = D(!1);
1161
+ const n = t, e = b(() => {
1162
+ var S;
1163
+ return ((S = n.item.props) == null ? void 0 : S.taskType) || "";
1164
+ }), r = E(!1), f = E(null), p = E(!1), m = E(null), h = E(!1);
1163
1165
  function g() {
1164
- y.value = !0, f.value = !1, ve(() => {
1165
- const x = u.value;
1166
- if (!x) return;
1167
- const _ = window.devicePixelRatio || 1, j = x.getBoundingClientRect();
1168
- x.width = j.width * _, x.height = j.height * _;
1169
- const E = x.getContext("2d");
1170
- E.scale(_, _), E.strokeStyle = "#333", E.lineWidth = 3, E.lineCap = "round", E.lineJoin = "round", p.value = E;
1166
+ r.value = !0, h.value = !1, Ee(() => {
1167
+ const S = f.value;
1168
+ if (!S) return;
1169
+ const C = window.devicePixelRatio || 1, j = S.getBoundingClientRect();
1170
+ S.width = j.width * C, S.height = j.height * C;
1171
+ const z = S.getContext("2d");
1172
+ z.scale(C, C), z.strokeStyle = "#333", z.lineWidth = 3, z.lineCap = "round", z.lineJoin = "round", m.value = z;
1171
1173
  });
1172
1174
  }
1173
- function a(x) {
1174
- const j = u.value.getBoundingClientRect(), E = "touches" in x ? x.touches[0].clientX : x.clientX, H = "touches" in x ? x.touches[0].clientY : x.clientY;
1175
- return { x: E - j.left, y: H - j.top };
1175
+ function a(S) {
1176
+ const j = f.value.getBoundingClientRect(), z = "touches" in S ? S.touches[0].clientX : S.clientX, B = "touches" in S ? S.touches[0].clientY : S.clientY;
1177
+ return { x: z - j.left, y: B - j.top };
1176
1178
  }
1177
- function o(x) {
1178
- x.preventDefault(), m.value = !0, f.value = !0;
1179
- const { x: _, y: j } = a(x);
1180
- p.value.beginPath(), p.value.moveTo(_, j);
1179
+ function o(S) {
1180
+ S.preventDefault(), p.value = !0, h.value = !0;
1181
+ const { x: C, y: j } = a(S);
1182
+ m.value.beginPath(), m.value.moveTo(C, j);
1181
1183
  }
1182
- function i(x) {
1183
- if (x.preventDefault(), !m.value) return;
1184
- const { x: _, y: j } = a(x);
1185
- p.value.lineTo(_, j), p.value.stroke();
1184
+ function c(S) {
1185
+ if (S.preventDefault(), !p.value) return;
1186
+ const { x: C, y: j } = a(S);
1187
+ m.value.lineTo(C, j), m.value.stroke();
1186
1188
  }
1187
- function h() {
1188
- m.value = !1;
1189
+ function y() {
1190
+ p.value = !1;
1189
1191
  }
1190
- function V() {
1191
- const x = u.value;
1192
- p.value.clearRect(0, 0, x.width, x.height), f.value = !1;
1192
+ function M() {
1193
+ const S = f.value;
1194
+ m.value.clearRect(0, 0, S.width, S.height), h.value = !1;
1193
1195
  }
1194
1196
  function v() {
1195
- const x = u.value.toDataURL("image/png");
1196
- y.value = !1, K(n.formCore, n.item.key, {
1197
- signatureDataUrl: x,
1197
+ const S = f.value.toDataURL("image/png");
1198
+ r.value = !1, Q(n.formCore, n.item.key, {
1199
+ signatureDataUrl: S,
1198
1200
  _completed: !0,
1199
1201
  _completedAt: (/* @__PURE__ */ new Date()).toISOString()
1200
1202
  });
1201
1203
  }
1202
- function b() {
1203
- y.value = !1;
1204
+ function T() {
1205
+ r.value = !1;
1204
1206
  }
1205
- const w = D(!1);
1206
- function P() {
1207
- w.value = !0;
1207
+ const A = E(!1);
1208
+ function L() {
1209
+ A.value = !0;
1208
1210
  }
1209
- function O() {
1210
- w.value = !1, K(n.formCore, n.item.key, {
1211
+ function P() {
1212
+ A.value = !1, Q(n.formCore, n.item.key, {
1211
1213
  lng: 116.404 + Math.random() * 0.1,
1212
1214
  lat: 39.915 + Math.random() * 0.1,
1213
1215
  address: `模拟选点地址 ${Date.now()}`,
@@ -1215,53 +1217,53 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1215
1217
  _completedAt: (/* @__PURE__ */ new Date()).toISOString()
1216
1218
  });
1217
1219
  }
1218
- const c = D(!1);
1220
+ const u = E(!1);
1219
1221
  function k() {
1220
- c.value = !0;
1222
+ u.value = !0;
1221
1223
  }
1222
- function M() {
1223
- c.value = !1, K(n.formCore, n.item.key, {
1224
+ function V() {
1225
+ u.value = !1, Q(n.formCore, n.item.key, {
1224
1226
  _completed: !0,
1225
1227
  _completedAt: (/* @__PURE__ */ new Date()).toISOString(),
1226
1228
  _mock: `已完成原生任务: ${e.value}`
1227
1229
  });
1228
1230
  }
1229
- function d(x, _) {
1230
- x.stopPropagation(), x.target === x.currentTarget && _();
1231
+ function d(S, C) {
1232
+ S.stopPropagation(), S.target === S.currentTarget && C();
1231
1233
  }
1232
- function T() {
1233
- e.value === "signature" ? g() : e.value === "map" ? P() : k();
1234
- }
1235
- const S = C(() => {
1236
- var _;
1237
- const x = (_ = n.field) == null ? void 0 : _.value;
1238
- return x && typeof x == "object" && x._completed;
1239
- }), $ = C(() => e.value === "signature" ? "✍️" : e.value === "map" ? "📍" : "📱"), F = C(() => e.value === "signature" ? "#eb2f96" : e.value === "map" ? "#2f54eb" : "#fa8c16");
1240
- return (x, _) => (s(), r("div", {
1234
+ function _() {
1235
+ e.value === "signature" ? g() : e.value === "map" ? L() : k();
1236
+ }
1237
+ const I = b(() => {
1238
+ var C;
1239
+ const S = (C = n.field) == null ? void 0 : C.value;
1240
+ return S && typeof S == "object" && S._completed;
1241
+ }), w = b(() => e.value === "signature" ? "✍️" : e.value === "map" ? "📍" : "📱"), O = b(() => e.value === "signature" ? "#eb2f96" : e.value === "map" ? "#2f54eb" : "#fa8c16");
1242
+ return (S, C) => (s(), i("div", {
1241
1243
  class: "task-native",
1242
- onClick: T
1244
+ onClick: _
1243
1245
  }, [
1244
1246
  l(
1245
1247
  "div",
1246
1248
  {
1247
- class: R(["task-trigger", { completed: S.value }])
1249
+ class: K(["task-trigger", { completed: I.value }])
1248
1250
  },
1249
1251
  [
1250
1252
  l(
1251
1253
  "span",
1252
- At,
1253
- A($.value),
1254
+ sl,
1255
+ $(w.value),
1254
1256
  1
1255
1257
  /* TEXT */
1256
1258
  ),
1257
1259
  l(
1258
1260
  "span",
1259
- Vt,
1260
- A(S.value ? "✅ 已完成" : t.item.placeholder || `点击完成${t.item.label}`),
1261
+ il,
1262
+ $(I.value ? "✅ 已完成" : t.item.placeholder || `点击完成${t.item.label}`),
1261
1263
  1
1262
1264
  /* TEXT */
1263
1265
  ),
1264
- _[4] || (_[4] = l(
1266
+ C[4] || (C[4] = l(
1265
1267
  "span",
1266
1268
  { class: "task-arrow" },
1267
1269
  "▸",
@@ -1272,81 +1274,81 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1272
1274
  2
1273
1275
  /* CLASS */
1274
1276
  ),
1275
- I(" Signature Modal "),
1276
- y.value ? (s(), r("div", {
1277
+ x(" Signature Modal "),
1278
+ r.value ? (s(), i("div", {
1277
1279
  key: 0,
1278
1280
  class: "modal-overlay",
1279
- onClick: _[0] || (_[0] = (j) => d(j, b))
1281
+ onClick: C[0] || (C[0] = (j) => d(j, T))
1280
1282
  }, [
1281
- l("div", Ft, [
1282
- l("div", Dt, [
1283
+ l("div", rl, [
1284
+ l("div", cl, [
1283
1285
  l(
1284
1286
  "span",
1285
1287
  null,
1286
- A(t.item.label || "手写签名"),
1288
+ $(t.item.label || "手写签名"),
1287
1289
  1
1288
1290
  /* TEXT */
1289
1291
  ),
1290
1292
  l("button", {
1291
1293
  class: "modal-close",
1292
- onClick: b
1294
+ onClick: T
1293
1295
  }, "✕")
1294
1296
  ]),
1295
- l("div", Mt, [
1297
+ l("div", ul, [
1296
1298
  l(
1297
1299
  "canvas",
1298
1300
  {
1299
1301
  ref_key: "canvasRef",
1300
- ref: u,
1302
+ ref: f,
1301
1303
  class: "sig-canvas",
1302
1304
  onMousedown: o,
1303
- onMousemove: i,
1304
- onMouseup: h,
1305
- onMouseleave: h,
1305
+ onMousemove: c,
1306
+ onMouseup: y,
1307
+ onMouseleave: y,
1306
1308
  onTouchstart: o,
1307
- onTouchmove: i,
1308
- onTouchend: h
1309
+ onTouchmove: c,
1310
+ onTouchend: y
1309
1311
  },
1310
1312
  null,
1311
1313
  544
1312
1314
  /* NEED_HYDRATION, NEED_PATCH */
1313
1315
  ),
1314
- f.value ? I("v-if", !0) : (s(), r("div", Pt, "在此处签名"))
1316
+ h.value ? x("v-if", !0) : (s(), i("div", dl, "在此处签名"))
1315
1317
  ]),
1316
- l("div", Ot, [
1318
+ l("div", vl, [
1317
1319
  l("button", {
1318
1320
  class: "btn-clear",
1319
- onClick: V
1321
+ onClick: M
1320
1322
  }, "清除"),
1321
1323
  l("button", {
1322
1324
  class: "btn-confirm-sig",
1323
1325
  onClick: v,
1324
- disabled: !f.value
1325
- }, "确认签名", 8, jt)
1326
+ disabled: !h.value
1327
+ }, "确认签名", 8, fl)
1326
1328
  ])
1327
1329
  ])
1328
- ])) : I("v-if", !0),
1329
- I(" Map Modal "),
1330
- w.value ? (s(), r("div", {
1330
+ ])) : x("v-if", !0),
1331
+ x(" Map Modal "),
1332
+ A.value ? (s(), i("div", {
1331
1333
  key: 1,
1332
1334
  class: "modal-overlay",
1333
- onClick: _[1] || (_[1] = (j) => d(j, O))
1335
+ onClick: C[1] || (C[1] = (j) => d(j, P))
1334
1336
  }, [
1335
- l("div", Rt, [
1336
- l("div", Lt, [
1337
+ l("div", ml, [
1338
+ l("div", pl, [
1337
1339
  l(
1338
1340
  "span",
1339
1341
  null,
1340
- A(t.item.label || "地图选点"),
1342
+ $(t.item.label || "地图选点"),
1341
1343
  1
1342
1344
  /* TEXT */
1343
1345
  ),
1344
1346
  l("button", {
1345
1347
  class: "modal-close",
1346
- onClick: O
1348
+ onClick: P
1347
1349
  }, "✕")
1348
1350
  ]),
1349
- _[5] || (_[5] = l(
1351
+ C[5] || (C[5] = l(
1350
1352
  "div",
1351
1353
  { class: "map-placeholder" },
1352
1354
  [
@@ -1360,33 +1362,33 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1360
1362
  l("div", { class: "map-footer" }, [
1361
1363
  l("button", {
1362
1364
  class: "btn-confirm-sig",
1363
- onClick: O
1365
+ onClick: P
1364
1366
  }, "在此位置选点")
1365
1367
  ])
1366
1368
  ])
1367
- ])) : I("v-if", !0),
1368
- I(" Generic Native Modal "),
1369
- c.value ? (s(), r("div", {
1369
+ ])) : x("v-if", !0),
1370
+ x(" Generic Native Modal "),
1371
+ u.value ? (s(), i("div", {
1370
1372
  key: 2,
1371
1373
  class: "modal-overlay",
1372
- onClick: _[3] || (_[3] = (j) => d(j, () => c.value = !1))
1374
+ onClick: C[3] || (C[3] = (j) => d(j, () => u.value = !1))
1373
1375
  }, [
1374
- l("div", Nt, [
1376
+ l("div", hl, [
1375
1377
  l(
1376
1378
  "div",
1377
- Bt,
1378
- A($.value),
1379
+ gl,
1380
+ $(w.value),
1379
1381
  1
1380
1382
  /* TEXT */
1381
1383
  ),
1382
1384
  l(
1383
1385
  "div",
1384
- Et,
1385
- A(t.item.label || "原生页面任务"),
1386
+ yl,
1387
+ $(t.item.label || "原生页面任务"),
1386
1388
  1
1387
1389
  /* TEXT */
1388
1390
  ),
1389
- _[6] || (_[6] = l(
1391
+ C[6] || (C[6] = l(
1390
1392
  "div",
1391
1393
  { class: "native-hint" },
1392
1394
  "(Demo 模拟:实际将拉起原生页面)",
@@ -1395,32 +1397,32 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1395
1397
  )),
1396
1398
  l(
1397
1399
  "div",
1398
- Ut,
1399
- "taskType: " + A(e.value),
1400
+ kl,
1401
+ "taskType: " + $(e.value),
1400
1402
  1
1401
1403
  /* TEXT */
1402
1404
  ),
1403
- l("div", Ht, [
1405
+ l("div", bl, [
1404
1406
  l("button", {
1405
1407
  class: "btn-cancel",
1406
- onClick: _[2] || (_[2] = (j) => c.value = !1)
1408
+ onClick: C[2] || (C[2] = (j) => u.value = !1)
1407
1409
  }, "取消"),
1408
1410
  l("button", {
1409
1411
  class: "btn-confirm-sig",
1410
- onClick: M
1412
+ onClick: V
1411
1413
  }, "模拟完成")
1412
1414
  ])
1413
1415
  ])
1414
- ])) : I("v-if", !0)
1416
+ ])) : x("v-if", !0)
1415
1417
  ]));
1416
1418
  }
1417
- }), le = /* @__PURE__ */ N(Kt, [["__scopeId", "data-v-d1a3f489"]]), Gt = { class: "task-icon" }, zt = { class: "task-label" }, Yt = {
1419
+ }), ve = /* @__PURE__ */ Y(_l, [["__scopeId", "data-v-d1a3f489"]]), Cl = { class: "task-icon" }, $l = { class: "task-label" }, Tl = {
1418
1420
  key: 0,
1419
1421
  class: "spinner"
1420
- }, qt = {
1422
+ }, wl = {
1421
1423
  key: 1,
1422
1424
  class: "task-arrow"
1423
- }, Wt = /* @__PURE__ */ L({
1425
+ }, Sl = /* @__PURE__ */ U({
1424
1426
  __name: "ApiTask",
1425
1427
  props: {
1426
1428
  item: {},
@@ -1428,92 +1430,92 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1428
1430
  formCore: {}
1429
1431
  },
1430
1432
  setup(t) {
1431
- const n = t, e = D(!1), y = D(""), u = C(() => {
1433
+ const n = t, e = E(!1), r = E(""), f = b(() => {
1432
1434
  var g;
1433
1435
  return ((g = n.item.props) == null ? void 0 : g.taskType) || "";
1434
- }), m = C(() => be()[u.value]);
1435
- async function p() {
1436
+ }), p = b(() => Xe()[f.value]);
1437
+ async function m() {
1436
1438
  if (!e.value) {
1437
- e.value = !0, y.value = "";
1439
+ e.value = !0, r.value = "";
1438
1440
  try {
1439
- if (m.value) {
1440
- const g = await m.value(n.formCore, n.item.key);
1441
- e.value = !1, K(n.formCore, n.item.key, {
1441
+ if (p.value) {
1442
+ const g = await p.value(n.formCore, n.item.key);
1443
+ e.value = !1, Q(n.formCore, n.item.key, {
1442
1444
  ...g,
1443
1445
  _completed: !0,
1444
1446
  _completedAt: (/* @__PURE__ */ new Date()).toISOString()
1445
1447
  });
1446
1448
  } else
1447
- await new Promise((g) => setTimeout(g, 800)), e.value = !1, K(n.formCore, n.item.key, {
1449
+ await new Promise((g) => setTimeout(g, 800)), e.value = !1, Q(n.formCore, n.item.key, {
1448
1450
  code: "00",
1449
1451
  data: { id: `mock_${Date.now()}`, name: `模拟${n.item.label}结果` },
1450
1452
  _completed: !0,
1451
1453
  _completedAt: (/* @__PURE__ */ new Date()).toISOString()
1452
1454
  });
1453
1455
  } catch (g) {
1454
- e.value = !1, y.value = (g == null ? void 0 : g.message) || "请求失败", setTimeout(() => {
1455
- y.value = "";
1456
+ e.value = !1, r.value = (g == null ? void 0 : g.message) || "请求失败", setTimeout(() => {
1457
+ r.value = "";
1456
1458
  }, 3e3);
1457
1459
  }
1458
1460
  }
1459
1461
  }
1460
- const f = C(() => {
1462
+ const h = b(() => {
1461
1463
  var a;
1462
1464
  const g = (a = n.field) == null ? void 0 : a.value;
1463
1465
  return g && typeof g == "object" && g._completed;
1464
1466
  });
1465
- return (g, a) => (s(), r("div", {
1467
+ return (g, a) => (s(), i("div", {
1466
1468
  class: "task-api",
1467
- onClick: p
1469
+ onClick: m
1468
1470
  }, [
1469
1471
  l(
1470
1472
  "div",
1471
1473
  {
1472
- class: R(["task-trigger", { completed: f.value, loading: e.value, error: !!y.value }])
1474
+ class: K(["task-trigger", { completed: h.value, loading: e.value, error: !!r.value }])
1473
1475
  },
1474
1476
  [
1475
1477
  l(
1476
1478
  "span",
1477
- Gt,
1478
- A(e.value ? "⏳" : y.value ? "⚠️" : "🔌"),
1479
+ Cl,
1480
+ $(e.value ? "⏳" : r.value ? "⚠️" : "🔌"),
1479
1481
  1
1480
1482
  /* TEXT */
1481
1483
  ),
1482
- l("span", zt, [
1483
- e.value ? (s(), r(
1484
- B,
1484
+ l("span", $l, [
1485
+ e.value ? (s(), i(
1486
+ q,
1485
1487
  { key: 0 },
1486
1488
  [
1487
- Y("请求中...")
1489
+ X("请求中...")
1488
1490
  ],
1489
1491
  64
1490
1492
  /* STABLE_FRAGMENT */
1491
- )) : y.value ? (s(), r(
1492
- B,
1493
+ )) : r.value ? (s(), i(
1494
+ q,
1493
1495
  { key: 1 },
1494
1496
  [
1495
- Y(
1496
- A(y.value),
1497
+ X(
1498
+ $(r.value),
1497
1499
  1
1498
1500
  /* TEXT */
1499
1501
  )
1500
1502
  ],
1501
1503
  64
1502
1504
  /* STABLE_FRAGMENT */
1503
- )) : f.value ? (s(), r(
1504
- B,
1505
+ )) : h.value ? (s(), i(
1506
+ q,
1505
1507
  { key: 2 },
1506
1508
  [
1507
- Y("✅ 已完成")
1509
+ X("✅ 已完成")
1508
1510
  ],
1509
1511
  64
1510
1512
  /* STABLE_FRAGMENT */
1511
- )) : (s(), r(
1512
- B,
1513
+ )) : (s(), i(
1514
+ q,
1513
1515
  { key: 3 },
1514
1516
  [
1515
- Y(
1516
- A(t.item.placeholder || `点击获取${t.item.label}`),
1517
+ X(
1518
+ $(t.item.placeholder || `点击获取${t.item.label}`),
1517
1519
  1
1518
1520
  /* TEXT */
1519
1521
  )
@@ -1522,17 +1524,17 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1522
1524
  /* STABLE_FRAGMENT */
1523
1525
  ))
1524
1526
  ]),
1525
- e.value ? (s(), r("span", Yt)) : (s(), r("span", qt, "▸"))
1527
+ e.value ? (s(), i("span", Tl)) : (s(), i("span", wl, "▸"))
1526
1528
  ],
1527
1529
  2
1528
1530
  /* CLASS */
1529
1531
  )
1530
1532
  ]));
1531
1533
  }
1532
- }), Jt = /* @__PURE__ */ N(Wt, [["__scopeId", "data-v-33fee019"]]), Xt = { class: "task-icon" }, Qt = { class: "task-label" }, Zt = {
1534
+ }), xl = /* @__PURE__ */ Y(Sl, [["__scopeId", "data-v-33fee019"]]), Al = { class: "task-icon" }, Il = { class: "task-label" }, Ol = {
1533
1535
  key: 0,
1534
1536
  class: "progress-bar"
1535
- }, el = /* @__PURE__ */ L({
1537
+ }, Ml = /* @__PURE__ */ U({
1536
1538
  __name: "CustomerTask",
1537
1539
  props: {
1538
1540
  item: {},
@@ -1540,15 +1542,15 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1540
1542
  formCore: {}
1541
1543
  },
1542
1544
  setup(t) {
1543
- const n = t, e = D(!1), y = D(0), u = C(() => {
1545
+ const n = t, e = E(!1), r = E(0), f = b(() => {
1544
1546
  var g;
1545
1547
  return ((g = n.item.props) == null ? void 0 : g.taskType) || "";
1546
1548
  });
1547
- function m() {
1549
+ function p() {
1548
1550
  if (e.value) return;
1549
- e.value = !0, y.value = 0;
1551
+ e.value = !0, r.value = 0;
1550
1552
  const g = setInterval(() => {
1551
- y.value += 20, y.value >= 100 && (clearInterval(g), e.value = !1, K(n.formCore, n.item.key, {
1553
+ r.value += 20, r.value >= 100 && (clearInterval(g), e.value = !1, Q(n.formCore, n.item.key, {
1552
1554
  score: Math.floor(Math.random() * 30) + 70,
1553
1555
  passed: !0,
1554
1556
  _completed: !0,
@@ -1556,32 +1558,32 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1556
1558
  }));
1557
1559
  }, 400);
1558
1560
  }
1559
- const p = C(() => {
1561
+ const m = b(() => {
1560
1562
  var a;
1561
1563
  const g = (a = n.field) == null ? void 0 : a.value;
1562
1564
  return g && typeof g == "object" && g._completed;
1563
- }), f = C(() => u.value === "face_verify_sign" ? "👤" : "📷");
1564
- return (g, a) => (s(), r("div", {
1565
+ }), h = b(() => f.value === "face_verify_sign" ? "👤" : "📷");
1566
+ return (g, a) => (s(), i("div", {
1565
1567
  class: "task-customer",
1566
- onClick: m
1568
+ onClick: p
1567
1569
  }, [
1568
1570
  l(
1569
1571
  "div",
1570
1572
  {
1571
- class: R(["task-trigger", { completed: p.value, loading: e.value }])
1573
+ class: K(["task-trigger", { completed: m.value, loading: e.value }])
1572
1574
  },
1573
1575
  [
1574
1576
  l(
1575
1577
  "span",
1576
- Xt,
1577
- A(f.value),
1578
+ Al,
1579
+ $(h.value),
1578
1580
  1
1579
1581
  /* TEXT */
1580
1582
  ),
1581
1583
  l(
1582
1584
  "span",
1583
- Qt,
1584
- A(e.value ? "检测中..." : p.value ? "✅ 已完成" : t.item.placeholder || `点击启动${t.item.label}`),
1585
+ Il,
1586
+ $(e.value ? "检测中..." : m.value ? "✅ 已完成" : t.item.placeholder || `点击启动${t.item.label}`),
1585
1587
  1
1586
1588
  /* TEXT */
1587
1589
  ),
@@ -1596,22 +1598,22 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1596
1598
  2
1597
1599
  /* CLASS */
1598
1600
  ),
1599
- I(" Progress overlay "),
1600
- e.value ? (s(), r("div", Zt, [
1601
+ x(" Progress overlay "),
1602
+ e.value ? (s(), i("div", Ol, [
1601
1603
  l(
1602
1604
  "div",
1603
1605
  {
1604
1606
  class: "progress-fill",
1605
- style: oe({ width: y.value + "%" })
1607
+ style: re({ width: r.value + "%" })
1606
1608
  },
1607
1609
  null,
1608
1610
  4
1609
1611
  /* STYLE */
1610
1612
  )
1611
- ])) : I("v-if", !0)
1613
+ ])) : x("v-if", !0)
1612
1614
  ]));
1613
1615
  }
1614
- }), tl = /* @__PURE__ */ N(el, [["__scopeId", "data-v-bb43982b"]]), ll = { class: "task-label" }, al = { class: "inline-card" }, nl = { class: "inline-link" }, ol = /* @__PURE__ */ L({
1616
+ }), Vl = /* @__PURE__ */ Y(Ml, [["__scopeId", "data-v-bb43982b"]]), El = { class: "task-label" }, Pl = { class: "inline-card" }, Fl = { class: "inline-link" }, Dl = /* @__PURE__ */ U({
1615
1617
  __name: "InlineTask",
1616
1618
  props: {
1617
1619
  item: {},
@@ -1619,42 +1621,42 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1619
1621
  formCore: {}
1620
1622
  },
1621
1623
  setup(t) {
1622
- const n = t, e = D(!1), y = C(() => {
1624
+ const n = t, e = E(!1), r = b(() => {
1623
1625
  var a;
1624
1626
  return ((a = n.item.props) == null ? void 0 : a.taxLink) || `https://tax.example.com/copy?id=${Date.now()}`;
1625
1627
  });
1626
- function u() {
1628
+ function f() {
1627
1629
  e.value = !0;
1628
1630
  }
1629
- function m() {
1631
+ function p() {
1630
1632
  var a;
1631
- e.value = !1, (a = navigator.clipboard) == null || a.writeText(y.value).catch(() => {
1632
- }), K(n.formCore, n.item.key, {
1633
+ e.value = !1, (a = navigator.clipboard) == null || a.writeText(r.value).catch(() => {
1634
+ }), Q(n.formCore, n.item.key, {
1633
1635
  copied: !0,
1634
- url: y.value,
1636
+ url: r.value,
1635
1637
  _completed: !0,
1636
1638
  _completedAt: (/* @__PURE__ */ new Date()).toISOString()
1637
1639
  });
1638
1640
  }
1639
- function p() {
1641
+ function m() {
1640
1642
  e.value = !1;
1641
1643
  }
1642
- function f(a, o) {
1644
+ function h(a, o) {
1643
1645
  a.stopPropagation(), a.target === a.currentTarget && o();
1644
1646
  }
1645
- const g = C(() => {
1647
+ const g = b(() => {
1646
1648
  var o;
1647
1649
  const a = (o = n.field) == null ? void 0 : o.value;
1648
1650
  return a && typeof a == "object" && a._completed;
1649
1651
  });
1650
- return (a, o) => (s(), r("div", {
1652
+ return (a, o) => (s(), i("div", {
1651
1653
  class: "task-inline",
1652
- onClick: u
1654
+ onClick: f
1653
1655
  }, [
1654
1656
  l(
1655
1657
  "div",
1656
1658
  {
1657
- class: R(["task-trigger", { completed: g.value }])
1659
+ class: K(["task-trigger", { completed: g.value }])
1658
1660
  },
1659
1661
  [
1660
1662
  o[1] || (o[1] = l(
@@ -1666,8 +1668,8 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1666
1668
  )),
1667
1669
  l(
1668
1670
  "span",
1669
- ll,
1670
- A(g.value ? "✅ 已复制" : t.item.placeholder || "复制链接"),
1671
+ El,
1672
+ $(g.value ? "✅ 已复制" : t.item.placeholder || "复制链接"),
1671
1673
  1
1672
1674
  /* TEXT */
1673
1675
  ),
@@ -1682,13 +1684,13 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1682
1684
  2
1683
1685
  /* CLASS */
1684
1686
  ),
1685
- I(" Confirm "),
1686
- e.value ? (s(), r("div", {
1687
+ x(" Confirm "),
1688
+ e.value ? (s(), i("div", {
1687
1689
  key: 0,
1688
1690
  class: "modal-overlay",
1689
- onClick: o[0] || (o[0] = (i) => f(i, p))
1691
+ onClick: o[0] || (o[0] = (c) => h(c, m))
1690
1692
  }, [
1691
- l("div", al, [
1693
+ l("div", Pl, [
1692
1694
  o[3] || (o[3] = l(
1693
1695
  "div",
1694
1696
  { class: "inline-icon" },
@@ -1705,8 +1707,8 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1705
1707
  )),
1706
1708
  l(
1707
1709
  "div",
1708
- nl,
1709
- A(y.value),
1710
+ Fl,
1711
+ $(r.value),
1710
1712
  1
1711
1713
  /* TEXT */
1712
1714
  ),
@@ -1720,18 +1722,18 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1720
1722
  l("div", { class: "inline-actions" }, [
1721
1723
  l("button", {
1722
1724
  class: "btn-cancel",
1723
- onClick: p
1725
+ onClick: m
1724
1726
  }, "取消"),
1725
1727
  l("button", {
1726
1728
  class: "btn-confirm",
1727
- onClick: m
1729
+ onClick: p
1728
1730
  }, "复制并完成")
1729
1731
  ])
1730
1732
  ])
1731
- ])) : I("v-if", !0)
1733
+ ])) : x("v-if", !0)
1732
1734
  ]));
1733
1735
  }
1734
- }), sl = /* @__PURE__ */ N(ol, [["__scopeId", "data-v-612f91c9"]]), il = /* @__PURE__ */ L({
1736
+ }), Rl = /* @__PURE__ */ Y(Dl, [["__scopeId", "data-v-612f91c9"]]), Nl = /* @__PURE__ */ U({
1735
1737
  __name: "TaskControl",
1736
1738
  props: {
1737
1739
  item: {},
@@ -1739,32 +1741,32 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1739
1741
  formCore: {}
1740
1742
  },
1741
1743
  setup(t) {
1742
- const n = t, e = C(() => {
1743
- const y = Ce(n.item.props);
1744
+ const n = t, e = b(() => {
1745
+ const r = Qe(n.item.props);
1744
1746
  return {
1745
- subForm: ne,
1746
- h5: It,
1747
- signature: le,
1748
- map: le,
1749
- native: le,
1750
- api: Jt,
1751
- customer: tl,
1752
- inline: sl
1753
- }[y] || ne;
1747
+ subForm: ge,
1748
+ h5: ol,
1749
+ signature: ve,
1750
+ map: ve,
1751
+ native: ve,
1752
+ api: xl,
1753
+ customer: Vl,
1754
+ inline: Rl
1755
+ }[r] || ge;
1754
1756
  });
1755
- return (y, u) => (s(), J(ee(e.value), {
1757
+ return (r, f) => (s(), ee(ce(e.value), {
1756
1758
  item: t.item,
1757
1759
  field: t.field,
1758
1760
  formCore: t.formCore
1759
1761
  }, null, 8, ["item", "field", "formCore"]));
1760
1762
  }
1761
- }), rl = { class: "list-row-head" }, cl = ["disabled", "onClick"], ul = ["value", "disabled", "onChange"], dl = { value: "" }, vl = ["value"], fl = ["type", "value", "placeholder", "disabled", "onBlur"], ml = {
1763
+ }), Ll = { class: "list-row-head" }, jl = ["disabled", "onClick"], Bl = ["value", "disabled", "onChange"], Kl = { value: "" }, Ul = ["value"], Hl = ["type", "value", "placeholder", "disabled", "onBlur"], Yl = {
1762
1764
  key: 2,
1763
1765
  class: "list-error"
1764
- }, pl = {
1766
+ }, ql = {
1765
1767
  key: 0,
1766
1768
  class: "list-summary-error"
1767
- }, hl = ["disabled"], gl = { class: "list-hint" }, yl = /* @__PURE__ */ L({
1769
+ }, zl = ["disabled"], Gl = { class: "list-hint" }, Wl = /* @__PURE__ */ U({
1768
1770
  __name: "ListControl",
1769
1771
  props: {
1770
1772
  item: {},
@@ -1773,150 +1775,150 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1773
1775
  },
1774
1776
  emits: ["change"],
1775
1777
  setup(t, { emit: n }) {
1776
- const e = t, y = n, u = C(
1778
+ const e = t, r = n, f = b(
1777
1779
  () => {
1778
- var c;
1779
- return Array.isArray((c = e.field) == null ? void 0 : c.value) ? e.field.value : [];
1780
+ var u;
1781
+ return Array.isArray((u = e.field) == null ? void 0 : u.value) ? e.field.value : [];
1780
1782
  }
1781
- ), m = C(() => e.item.subItems ?? []), p = C(() => {
1782
- var c;
1783
- return ((c = e.item.listMeta) == null ? void 0 : c.minItems) ?? 1;
1784
- }), f = C(() => {
1785
- var c;
1786
- return (c = e.item.listMeta) == null ? void 0 : c.maxItems;
1787
- }), g = C(() => f.value === void 0 || u.value.length < f.value), a = C(() => {
1788
- var c;
1789
- return ((c = e.item.listMeta) == null ? void 0 : c.removable) !== !1 && u.value.length > p.value;
1790
- }), o = C(
1783
+ ), p = b(() => e.item.subItems ?? []), m = b(() => {
1784
+ var u;
1785
+ return ((u = e.item.listMeta) == null ? void 0 : u.minItems) ?? 1;
1786
+ }), h = b(() => {
1787
+ var u;
1788
+ return (u = e.item.listMeta) == null ? void 0 : u.maxItems;
1789
+ }), g = b(() => h.value === void 0 || f.value.length < h.value), a = b(() => {
1790
+ var u;
1791
+ return ((u = e.item.listMeta) == null ? void 0 : u.removable) !== !1 && f.value.length > m.value;
1792
+ }), o = b(
1791
1793
  () => {
1792
- var c;
1793
- return ((c = e.field) == null ? void 0 : c.collectionErrors) ?? {};
1794
+ var u;
1795
+ return ((u = e.field) == null ? void 0 : u.collectionErrors) ?? {};
1794
1796
  }
1795
1797
  );
1796
- function i(c, k) {
1797
- var M;
1798
- return ((M = u.value[c]) == null ? void 0 : M[k.key]) ?? "";
1798
+ function c(u, k) {
1799
+ var V;
1800
+ return ((V = f.value[u]) == null ? void 0 : V[k.key]) ?? "";
1799
1801
  }
1800
- function h(c) {
1801
- return c && typeof c == "object" ? c.code || "" : c == null ? "" : String(c);
1802
+ function y(u) {
1803
+ return u && typeof u == "object" ? u.code || "" : u == null ? "" : String(u);
1802
1804
  }
1803
- function V(c, k, M) {
1804
- const d = u.value.map((T) => ({ ...T }));
1805
- d[c] = { ...d[c] ?? {}, [k.key]: M }, y("change", { value: d, eventType: "inputBlur" });
1805
+ function M(u, k, V) {
1806
+ const d = f.value.map((_) => ({ ..._ }));
1807
+ d[u] = { ...d[u] ?? {}, [k.key]: V }, r("change", { value: d, eventType: "inputBlur" });
1806
1808
  }
1807
- function v(c, k, M) {
1808
- const d = M.target;
1809
- V(c, k, d.value.trim());
1809
+ function v(u, k, V) {
1810
+ const d = V.target;
1811
+ M(u, k, d.value.trim());
1810
1812
  }
1811
- function b(c, k, M) {
1812
- const d = M.target, T = (k.initOptions ?? []).find((S) => S.code === d.value);
1813
- V(c, k, T ? { code: T.code, name: T.name } : "");
1813
+ function T(u, k, V) {
1814
+ const d = V.target, _ = (k.initOptions ?? []).find((I) => I.code === d.value);
1815
+ M(u, k, _ ? { code: _.code, name: _.name } : "");
1814
1816
  }
1815
- function w() {
1816
- var c;
1817
- !g.value || (c = e.field) != null && c.disabled || y("change", { value: [...u.value, {}], eventType: "inputChange" });
1817
+ function A() {
1818
+ var u;
1819
+ !g.value || (u = e.field) != null && u.disabled || r("change", { value: [...f.value, {}], eventType: "inputChange" });
1818
1820
  }
1819
- function P(c) {
1821
+ function L(u) {
1820
1822
  var k;
1821
- !a.value || (k = e.field) != null && k.disabled || y("change", {
1822
- value: u.value.filter((M, d) => d !== c),
1823
+ !a.value || (k = e.field) != null && k.disabled || r("change", {
1824
+ value: f.value.filter((V, d) => d !== u),
1823
1825
  eventType: "inputChange"
1824
1826
  });
1825
1827
  }
1826
- function O(c, k) {
1827
- return o.value[`${e.item.key}[${c}].${k}`];
1828
+ function P(u, k) {
1829
+ return o.value[`${e.item.key}[${u}].${k}`];
1828
1830
  }
1829
- return (c, k) => {
1830
- var M, d, T;
1831
- return s(), r(
1831
+ return (u, k) => {
1832
+ var V, d, _;
1833
+ return s(), i(
1832
1834
  "div",
1833
1835
  {
1834
- class: R(["ctrl-list", { disabled: (M = t.field) == null ? void 0 : M.disabled }])
1836
+ class: K(["ctrl-list", { disabled: (V = t.field) == null ? void 0 : V.disabled }])
1835
1837
  },
1836
1838
  [
1837
- (s(!0), r(
1838
- B,
1839
+ (s(!0), i(
1840
+ q,
1839
1841
  null,
1840
- U(u.value, (S, $) => {
1841
- var F, x;
1842
- return s(), r("article", {
1843
- key: $,
1842
+ W(f.value, (I, w) => {
1843
+ var O, S;
1844
+ return s(), i("article", {
1845
+ key: w,
1844
1846
  class: "list-row"
1845
1847
  }, [
1846
- l("div", rl, [
1848
+ l("div", Ll, [
1847
1849
  l(
1848
1850
  "strong",
1849
1851
  null,
1850
- "联系人 " + A($ + 1),
1852
+ "联系人 " + $(w + 1),
1851
1853
  1
1852
1854
  /* TEXT */
1853
1855
  ),
1854
- ((F = t.item.listMeta) == null ? void 0 : F.removable) !== !1 ? (s(), r("button", {
1856
+ ((O = t.item.listMeta) == null ? void 0 : O.removable) !== !1 ? (s(), i("button", {
1855
1857
  key: 0,
1856
1858
  type: "button",
1857
1859
  class: "remove-button",
1858
- disabled: !a.value || ((x = t.field) == null ? void 0 : x.disabled),
1859
- onClick: (_) => P($)
1860
- }, " 删除 ", 8, cl)) : I("v-if", !0)
1860
+ disabled: !a.value || ((S = t.field) == null ? void 0 : S.disabled),
1861
+ onClick: (C) => L(w)
1862
+ }, " 删除 ", 8, jl)) : x("v-if", !0)
1861
1863
  ]),
1862
- (s(!0), r(
1863
- B,
1864
+ (s(!0), i(
1865
+ q,
1864
1866
  null,
1865
- U(m.value, (_) => {
1866
- var j, E;
1867
- return s(), r("label", {
1868
- key: _.key,
1867
+ W(p.value, (C) => {
1868
+ var j, z;
1869
+ return s(), i("label", {
1870
+ key: C.key,
1869
1871
  class: "list-field"
1870
1872
  }, [
1871
1873
  l(
1872
1874
  "span",
1873
1875
  {
1874
- class: R(["list-field-label", { required: _.required }])
1876
+ class: K(["list-field-label", { required: C.required }])
1875
1877
  },
1876
- A(_.label || _.key),
1878
+ $(C.label || C.key),
1877
1879
  3
1878
1880
  /* TEXT, CLASS */
1879
1881
  ),
1880
- _.type === "select" || _.type === "cascader" ? (s(), r("select", {
1882
+ C.type === "select" || C.type === "cascader" ? (s(), i("select", {
1881
1883
  key: 0,
1882
1884
  class: "list-input",
1883
- value: h(i($, _)),
1884
- disabled: ((j = t.field) == null ? void 0 : j.disabled) || _.disabled,
1885
- onChange: (H) => b($, _, H)
1885
+ value: y(c(w, C)),
1886
+ disabled: ((j = t.field) == null ? void 0 : j.disabled) || C.disabled,
1887
+ onChange: (B) => T(w, C, B)
1886
1888
  }, [
1887
1889
  l(
1888
1890
  "option",
1889
- dl,
1890
- A(_.placeholder || "请选择"),
1891
+ Kl,
1892
+ $(C.placeholder || "请选择"),
1891
1893
  1
1892
1894
  /* TEXT */
1893
1895
  ),
1894
- (s(!0), r(
1895
- B,
1896
+ (s(!0), i(
1897
+ q,
1896
1898
  null,
1897
- U(_.initOptions || [], (H) => (s(), r("option", {
1898
- key: H.code,
1899
- value: H.code
1900
- }, A(H.name), 9, vl))),
1899
+ W(C.initOptions || [], (B) => (s(), i("option", {
1900
+ key: B.code,
1901
+ value: B.code
1902
+ }, $(B.name), 9, Ul))),
1901
1903
  128
1902
1904
  /* KEYED_FRAGMENT */
1903
1905
  ))
1904
- ], 40, ul)) : (s(), r("input", {
1906
+ ], 40, Bl)) : (s(), i("input", {
1905
1907
  key: 1,
1906
1908
  class: "list-input",
1907
- type: _.type === "number" ? "number" : _.type === "phone" ? "tel" : "text",
1908
- value: i($, _),
1909
- placeholder: _.placeholder || "请输入",
1910
- disabled: ((E = t.field) == null ? void 0 : E.disabled) || _.disabled,
1911
- onBlur: (H) => v($, _, H)
1912
- }, null, 40, fl)),
1913
- O($, _.key) ? (s(), r(
1909
+ type: C.type === "number" ? "number" : C.type === "phone" ? "tel" : "text",
1910
+ value: c(w, C),
1911
+ placeholder: C.placeholder || "请输入",
1912
+ disabled: ((z = t.field) == null ? void 0 : z.disabled) || C.disabled,
1913
+ onBlur: (B) => v(w, C, B)
1914
+ }, null, 40, Hl)),
1915
+ P(w, C.key) ? (s(), i(
1914
1916
  "span",
1915
- ml,
1916
- A(O($, _.key)),
1917
+ Yl,
1918
+ $(P(w, C.key)),
1917
1919
  1
1918
1920
  /* TEXT */
1919
- )) : I("v-if", !0)
1921
+ )) : x("v-if", !0)
1920
1922
  ]);
1921
1923
  }),
1922
1924
  128
@@ -1927,17 +1929,17 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1927
1929
  128
1928
1930
  /* KEYED_FRAGMENT */
1929
1931
  )),
1930
- Object.keys(o.value).length ? (s(), r("p", pl, " 请修改重复或冲突的联系人手机号。 ")) : I("v-if", !0),
1932
+ Object.keys(o.value).length ? (s(), i("p", ql, " 请修改重复或冲突的联系人手机号。 ")) : x("v-if", !0),
1931
1933
  l("button", {
1932
1934
  type: "button",
1933
1935
  class: "add-button",
1934
1936
  disabled: !g.value || ((d = t.field) == null ? void 0 : d.disabled),
1935
- onClick: w
1936
- }, A(((T = t.item.listMeta) == null ? void 0 : T.addButtonText) || "+ 添加联系人"), 9, hl),
1937
+ onClick: A
1938
+ }, $(((_ = t.item.listMeta) == null ? void 0 : _.addButtonText) || "+ 添加联系人"), 9, zl),
1937
1939
  l(
1938
1940
  "p",
1939
- gl,
1940
- A(p.value) + "–" + A(f.value ?? "∞") + " 项,当前 " + A(u.value.length) + " 项",
1941
+ Gl,
1942
+ $(m.value) + "–" + $(h.value ?? "∞") + " 项,当前 " + $(f.value.length) + " 项",
1941
1943
  1
1942
1944
  /* TEXT */
1943
1945
  )
@@ -1947,7 +1949,7 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1947
1949
  );
1948
1950
  };
1949
1951
  }
1950
- }), kl = /* @__PURE__ */ N(yl, [["__scopeId", "data-v-e320f716"]]), bl = { class: "ctrl-date" }, Cl = ["value", "disabled", "aria-label"], _l = ["value", "disabled", "aria-label"], $l = ["value", "disabled", "aria-label"], Tl = /* @__PURE__ */ L({
1952
+ }), Jl = /* @__PURE__ */ Y(Wl, [["__scopeId", "data-v-e320f716"]]), Xl = { class: "ctrl-date" }, Ql = ["value", "disabled", "aria-label"], Zl = ["value", "disabled", "aria-label"], ea = ["value", "disabled", "aria-label"], ta = /* @__PURE__ */ U({
1951
1953
  __name: "DateControl",
1952
1954
  props: {
1953
1955
  item: {},
@@ -1956,58 +1958,58 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
1956
1958
  },
1957
1959
  emits: ["change"],
1958
1960
  setup(t, { emit: n }) {
1959
- var h, V, v;
1960
- const e = t, y = n, u = C(() => e.item.type === "dateRange"), m = D(g((h = e.field) == null ? void 0 : h.value)), p = D(a((V = e.field) == null ? void 0 : V.value)[0]), f = D(a((v = e.field) == null ? void 0 : v.value)[1]);
1961
- G(
1961
+ var y, M, v;
1962
+ const e = t, r = n, f = b(() => e.item.type === "dateRange"), p = E(g((y = e.field) == null ? void 0 : y.value)), m = E(a((M = e.field) == null ? void 0 : M.value)[0]), h = E(a((v = e.field) == null ? void 0 : v.value)[1]);
1963
+ Z(
1962
1964
  () => {
1963
- var b;
1964
- return (b = e.field) == null ? void 0 : b.value;
1965
+ var T;
1966
+ return (T = e.field) == null ? void 0 : T.value;
1965
1967
  },
1966
- (b) => {
1967
- if (u.value) {
1968
- const [w, P] = a(b);
1969
- p.value = w, f.value = P;
1968
+ (T) => {
1969
+ if (f.value) {
1970
+ const [A, L] = a(T);
1971
+ m.value = A, h.value = L;
1970
1972
  } else
1971
- m.value = g(b);
1973
+ p.value = g(T);
1972
1974
  }
1973
1975
  );
1974
- function g(b) {
1975
- return b == null || b === "" ? "" : String(b);
1976
- }
1977
- function a(b) {
1978
- if (Array.isArray(b)) return [String(b[0] || ""), String(b[1] || "")];
1979
- if (b && typeof b == "object") {
1980
- const w = b;
1981
- return [String(w.start || ""), String(w.end || "")];
1976
+ function g(T) {
1977
+ return T == null || T === "" ? "" : String(T);
1978
+ }
1979
+ function a(T) {
1980
+ if (Array.isArray(T)) return [String(T[0] || ""), String(T[1] || "")];
1981
+ if (T && typeof T == "object") {
1982
+ const A = T;
1983
+ return [String(A.start || ""), String(A.end || "")];
1982
1984
  }
1983
1985
  return ["", ""];
1984
1986
  }
1985
- function o(b) {
1986
- const w = b.target.value || "";
1987
- m.value = w, y("change", { value: w, eventType: "pickChange" });
1987
+ function o(T) {
1988
+ const A = T.target.value || "";
1989
+ p.value = A, r("change", { value: A, eventType: "pickChange" });
1988
1990
  }
1989
- function i() {
1990
- const b = p.value, w = f.value;
1991
- y("change", { value: b || w ? [b, w] : "", eventType: "pickChange" });
1991
+ function c() {
1992
+ const T = m.value, A = h.value;
1993
+ r("change", { value: T || A ? [T, A] : "", eventType: "pickChange" });
1992
1994
  }
1993
- return (b, w) => {
1994
- var P, O, c;
1995
- return s(), r("div", bl, [
1996
- u.value ? (s(), r(
1997
- B,
1995
+ return (T, A) => {
1996
+ var L, P, u;
1997
+ return s(), i("div", Xl, [
1998
+ f.value ? (s(), i(
1999
+ q,
1998
2000
  { key: 0 },
1999
2001
  [
2000
2002
  l("input", {
2001
2003
  class: "ctrl-date-input",
2002
2004
  type: "date",
2003
- value: p.value,
2004
- disabled: (P = t.field) == null ? void 0 : P.disabled,
2005
+ value: m.value,
2006
+ disabled: (L = t.field) == null ? void 0 : L.disabled,
2005
2007
  "aria-label": (t.item.label || "日期") + "开始",
2006
- onChange: w[0] || (w[0] = (k) => {
2007
- p.value = k.target.value, i();
2008
+ onChange: A[0] || (A[0] = (k) => {
2009
+ m.value = k.target.value, c();
2008
2010
  })
2009
- }, null, 40, Cl),
2010
- w[2] || (w[2] = l(
2011
+ }, null, 40, Ql),
2012
+ A[2] || (A[2] = l(
2011
2013
  "span",
2012
2014
  { class: "ctrl-date-sep" },
2013
2015
  "至",
@@ -2017,32 +2019,32 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
2017
2019
  l("input", {
2018
2020
  class: "ctrl-date-input",
2019
2021
  type: "date",
2020
- value: f.value,
2021
- disabled: (O = t.field) == null ? void 0 : O.disabled,
2022
+ value: h.value,
2023
+ disabled: (P = t.field) == null ? void 0 : P.disabled,
2022
2024
  "aria-label": (t.item.label || "日期") + "结束",
2023
- onChange: w[1] || (w[1] = (k) => {
2024
- f.value = k.target.value, i();
2025
+ onChange: A[1] || (A[1] = (k) => {
2026
+ h.value = k.target.value, c();
2025
2027
  })
2026
- }, null, 40, _l)
2028
+ }, null, 40, Zl)
2027
2029
  ],
2028
2030
  64
2029
2031
  /* STABLE_FRAGMENT */
2030
- )) : (s(), r("input", {
2032
+ )) : (s(), i("input", {
2031
2033
  key: 1,
2032
2034
  class: "ctrl-date-input",
2033
2035
  type: "date",
2034
- value: m.value,
2035
- disabled: (c = t.field) == null ? void 0 : c.disabled,
2036
+ value: p.value,
2037
+ disabled: (u = t.field) == null ? void 0 : u.disabled,
2036
2038
  "aria-label": t.item.label || "日期",
2037
2039
  onChange: o
2038
- }, null, 40, $l))
2040
+ }, null, 40, ea))
2039
2041
  ]);
2040
2042
  };
2041
2043
  }
2042
- }), wl = /* @__PURE__ */ N(Tl, [["__scopeId", "data-v-fdf889db"]]), xl = { class: "ctrl-verify-wrap" }, Sl = { class: "ctrl-verify" }, Il = ["value", "placeholder", "disabled", "maxlength"], Al = ["disabled"], Vl = {
2044
+ }), la = /* @__PURE__ */ Y(ta, [["__scopeId", "data-v-fdf889db"]]), aa = { class: "ctrl-verify-wrap" }, na = { class: "ctrl-verify" }, oa = ["value", "placeholder", "disabled", "maxlength"], sa = ["disabled"], ia = {
2043
2045
  key: 0,
2044
2046
  class: "ctrl-verify-error"
2045
- }, Fl = /* @__PURE__ */ L({
2047
+ }, ra = /* @__PURE__ */ U({
2046
2048
  __name: "VerifyCodeControl",
2047
2049
  props: {
2048
2050
  item: {},
@@ -2051,99 +2053,99 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
2051
2053
  },
2052
2054
  emits: ["change"],
2053
2055
  setup(t, { emit: n }) {
2054
- var c;
2055
- const e = t, y = n, u = q(ae, null), m = D(String(((c = e.field) == null ? void 0 : c.value) || "")), p = D(0), f = D(!1), g = D("");
2056
+ var u;
2057
+ const e = t, r = n, f = le(ue, null), p = E(String(((u = e.field) == null ? void 0 : u.value) || "")), m = E(0), h = E(!1), g = E("");
2056
2058
  let a = null;
2057
- G(
2059
+ Z(
2058
2060
  () => {
2059
2061
  var k;
2060
2062
  return (k = e.field) == null ? void 0 : k.value;
2061
2063
  },
2062
2064
  (k) => {
2063
- m.value = k == null ? "" : String(k);
2065
+ p.value = k == null ? "" : String(k);
2064
2066
  }
2065
2067
  );
2066
- const o = C(() => {
2068
+ const o = b(() => {
2067
2069
  var k;
2068
2070
  return Number((k = e.item.props) == null ? void 0 : k.countTime) || 60;
2069
- }), i = C(
2071
+ }), c = b(
2070
2072
  () => {
2071
- var k, M;
2072
- return ((k = e.item.props) == null ? void 0 : k.verifyText) || ((M = e.item.props) == null ? void 0 : M.reVerifyText) || "获取验证码";
2073
+ var k, V;
2074
+ return ((k = e.item.props) == null ? void 0 : k.verifyText) || ((V = e.item.props) == null ? void 0 : V.reVerifyText) || "获取验证码";
2073
2075
  }
2074
- ), h = C(() => p.value > 0), V = C(() => p.value > 0 ? `${p.value}s` : f.value ? "发送中" : i.value);
2076
+ ), y = b(() => m.value > 0), M = b(() => m.value > 0 ? `${m.value}s` : h.value ? "发送中" : c.value);
2075
2077
  function v(k) {
2076
- m.value = k.target.value;
2078
+ p.value = k.target.value;
2077
2079
  }
2078
- function b() {
2079
- const k = m.value.trim();
2080
- m.value = k, y("change", { value: k, eventType: "inputBlur" });
2080
+ function T() {
2081
+ const k = p.value.trim();
2082
+ p.value = k, r("change", { value: k, eventType: "inputBlur" });
2081
2083
  }
2082
- function w() {
2084
+ function A() {
2083
2085
  a && (clearInterval(a), a = null);
2084
2086
  }
2085
- function P() {
2086
- p.value = o.value, w(), a = setInterval(() => {
2087
- p.value -= 1, p.value <= 0 && w();
2087
+ function L() {
2088
+ m.value = o.value, A(), a = setInterval(() => {
2089
+ m.value -= 1, m.value <= 0 && A();
2088
2090
  }, 1e3);
2089
2091
  }
2090
- async function O() {
2091
- var k, M, d, T, S, $;
2092
- if (!(h.value || f.value || (k = e.field) != null && k.disabled)) {
2093
- g.value = "", f.value = !0;
2092
+ async function P() {
2093
+ var k, V, d, _, I, w;
2094
+ if (!(y.value || h.value || (k = e.field) != null && k.disabled)) {
2095
+ g.value = "", h.value = !0;
2094
2096
  try {
2095
- const F = te(u);
2096
- if (F != null && F.sendVerifyCode) {
2097
- const x = ((M = e.item.props) == null ? void 0 : M.mobileKey) || ((d = e.item.props) == null ? void 0 : d.bindMobileKey), _ = x && (($ = (S = (T = e.formCore) == null ? void 0 : T.fields) == null ? void 0 : S[x]) == null ? void 0 : $.value) != null ? String(e.formCore.fields[x].value) : void 0;
2098
- await F.sendVerifyCode({ item: e.item, mobile: _ });
2097
+ const O = ne(f);
2098
+ if (O != null && O.sendVerifyCode) {
2099
+ const S = ((V = e.item.props) == null ? void 0 : V.mobileKey) || ((d = e.item.props) == null ? void 0 : d.bindMobileKey), C = S && ((w = (I = (_ = e.formCore) == null ? void 0 : _.fields) == null ? void 0 : I[S]) == null ? void 0 : w.value) != null ? String(e.formCore.fields[S].value) : void 0;
2100
+ await O.sendVerifyCode({ item: e.item, mobile: C });
2099
2101
  }
2100
- P();
2101
- } catch (F) {
2102
- g.value = (F == null ? void 0 : F.message) || "发送失败";
2102
+ L();
2103
+ } catch (O) {
2104
+ g.value = (O == null ? void 0 : O.message) || "发送失败";
2103
2105
  } finally {
2104
- f.value = !1;
2106
+ h.value = !1;
2105
2107
  }
2106
2108
  }
2107
2109
  }
2108
- return fe(w), (k, M) => {
2109
- var d, T, S;
2110
- return s(), r("div", xl, [
2111
- l("div", Sl, [
2110
+ return Pe(A), (k, V) => {
2111
+ var d, _, I;
2112
+ return s(), i("div", aa, [
2113
+ l("div", na, [
2112
2114
  l("input", {
2113
2115
  class: "ctrl-verify-input",
2114
2116
  type: "text",
2115
2117
  inputmode: "numeric",
2116
- value: m.value,
2118
+ value: p.value,
2117
2119
  placeholder: t.item.placeholder || "请输入验证码",
2118
2120
  disabled: (d = t.field) == null ? void 0 : d.disabled,
2119
- maxlength: ((T = t.item.props) == null ? void 0 : T.maxlength) || 6,
2121
+ maxlength: ((_ = t.item.props) == null ? void 0 : _.maxlength) || 6,
2120
2122
  onInput: v,
2121
- onBlur: b
2122
- }, null, 40, Il),
2123
+ onBlur: T
2124
+ }, null, 40, oa),
2123
2125
  l("button", {
2124
2126
  type: "button",
2125
2127
  class: "ctrl-verify-btn",
2126
- disabled: ((S = t.field) == null ? void 0 : S.disabled) || h.value || f.value,
2127
- onClick: O
2128
- }, A(V.value), 9, Al)
2128
+ disabled: ((I = t.field) == null ? void 0 : I.disabled) || y.value || h.value,
2129
+ onClick: P
2130
+ }, $(M.value), 9, sa)
2129
2131
  ]),
2130
- g.value ? (s(), r(
2132
+ g.value ? (s(), i(
2131
2133
  "div",
2132
- Vl,
2133
- A(g.value),
2134
+ ia,
2135
+ $(g.value),
2134
2136
  1
2135
2137
  /* TEXT */
2136
- )) : I("v-if", !0)
2138
+ )) : x("v-if", !0)
2137
2139
  ]);
2138
2140
  };
2139
2141
  }
2140
- }), Dl = /* @__PURE__ */ N(Fl, [["__scopeId", "data-v-53229668"]]), Ml = { class: "ctrl-upload-wrap" }, Pl = { class: "ctrl-upload" }, Ol = ["src"], jl = ["onClick"], Rl = {
2142
+ }), ca = /* @__PURE__ */ Y(ra, [["__scopeId", "data-v-53229668"]]), ua = { class: "ctrl-upload-wrap" }, da = { class: "ctrl-upload" }, va = ["src"], fa = ["onClick"], ma = {
2141
2143
  key: 0,
2142
2144
  class: "ctrl-upload-add"
2143
- }, Ll = { class: "ctrl-upload-hint" }, Nl = ["multiple"], Bl = {
2145
+ }, pa = { class: "ctrl-upload-hint" }, ha = ["multiple"], ga = {
2144
2146
  key: 0,
2145
2147
  class: "ctrl-upload-error"
2146
- }, El = /* @__PURE__ */ L({
2148
+ }, ya = /* @__PURE__ */ U({
2147
2149
  __name: "ImageUploadControl",
2148
2150
  props: {
2149
2151
  item: {},
@@ -2152,95 +2154,95 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
2152
2154
  },
2153
2155
  emits: ["change"],
2154
2156
  setup(t, { emit: n }) {
2155
- var V;
2156
- const e = t, y = n, u = q(ae, null), m = D(o((V = e.field) == null ? void 0 : V.value)), p = D(!1), f = D("");
2157
- G(
2157
+ var M;
2158
+ const e = t, r = n, f = le(ue, null), p = E(o((M = e.field) == null ? void 0 : M.value)), m = E(!1), h = E("");
2159
+ Z(
2158
2160
  () => {
2159
2161
  var v;
2160
2162
  return (v = e.field) == null ? void 0 : v.value;
2161
2163
  },
2162
2164
  (v) => {
2163
- m.value = o(v);
2165
+ p.value = o(v);
2164
2166
  }
2165
2167
  );
2166
- const g = C(() => {
2168
+ const g = b(() => {
2167
2169
  var v;
2168
2170
  return Number((v = e.item.props) == null ? void 0 : v.maxCount) || 1;
2169
- }), a = C(
2171
+ }), a = b(
2170
2172
  () => {
2171
2173
  var v;
2172
- return m.value.length < g.value && !((v = e.field) != null && v.disabled) && !p.value;
2174
+ return p.value.length < g.value && !((v = e.field) != null && v.disabled) && !m.value;
2173
2175
  }
2174
2176
  );
2175
2177
  function o(v) {
2176
2178
  return Array.isArray(v) ? v.map(String).filter(Boolean) : typeof v == "string" && v ? [v] : [];
2177
2179
  }
2178
- async function i(v) {
2179
- var c;
2180
- const b = v.target, w = Array.from(b.files || []);
2181
- if (b.value = "", !w.length || (c = e.field) != null && c.disabled) return;
2182
- const P = g.value - m.value.length, O = w.slice(0, Math.max(0, P));
2183
- if (O.length) {
2184
- f.value = "", p.value = !0;
2180
+ async function c(v) {
2181
+ var u;
2182
+ const T = v.target, A = Array.from(T.files || []);
2183
+ if (T.value = "", !A.length || (u = e.field) != null && u.disabled) return;
2184
+ const L = g.value - p.value.length, P = A.slice(0, Math.max(0, L));
2185
+ if (P.length) {
2186
+ h.value = "", m.value = !0;
2185
2187
  try {
2186
- const k = te(u);
2187
- let M;
2188
+ const k = ne(f);
2189
+ let V;
2188
2190
  if (k != null && k.uploadFile) {
2189
2191
  const d = [];
2190
- for (const T of O) {
2191
- const S = await k.uploadFile(
2192
- { name: T.name, size: T.size, raw: T },
2192
+ for (const _ of P) {
2193
+ const I = await k.uploadFile(
2194
+ { name: _.name, size: _.size, raw: _ },
2193
2195
  { item: e.item }
2194
2196
  );
2195
- if (!(S != null && S.url)) throw new Error("上传未返回 url");
2196
- d.push(S.url);
2197
+ if (!(I != null && I.url)) throw new Error("上传未返回 url");
2198
+ d.push(I.url);
2197
2199
  }
2198
- M = [...m.value, ...d];
2200
+ V = [...p.value, ...d];
2199
2201
  } else
2200
- M = [...m.value, ...O.map((d) => URL.createObjectURL(d))];
2201
- m.value = M, y("change", { value: M, eventType: "pickChange" });
2202
+ V = [...p.value, ...P.map((d) => URL.createObjectURL(d))];
2203
+ p.value = V, r("change", { value: V, eventType: "pickChange" });
2202
2204
  } catch (k) {
2203
- f.value = (k == null ? void 0 : k.message) || "上传失败";
2205
+ h.value = (k == null ? void 0 : k.message) || "上传失败";
2204
2206
  } finally {
2205
- p.value = !1;
2207
+ m.value = !1;
2206
2208
  }
2207
2209
  }
2208
2210
  }
2209
- function h(v) {
2210
- var w;
2211
- if ((w = e.field) != null && w.disabled) return;
2212
- const b = m.value.filter((P, O) => O !== v);
2213
- m.value = b, y("change", { value: b, eventType: "pickChange" });
2214
- }
2215
- return (v, b) => (s(), r("div", Ml, [
2216
- l("div", Pl, [
2217
- (s(!0), r(
2218
- B,
2211
+ function y(v) {
2212
+ var A;
2213
+ if ((A = e.field) != null && A.disabled) return;
2214
+ const T = p.value.filter((L, P) => P !== v);
2215
+ p.value = T, r("change", { value: T, eventType: "pickChange" });
2216
+ }
2217
+ return (v, T) => (s(), i("div", ua, [
2218
+ l("div", da, [
2219
+ (s(!0), i(
2220
+ q,
2219
2221
  null,
2220
- U(m.value, (w, P) => {
2221
- var O;
2222
- return s(), r("div", {
2223
- key: w + P,
2222
+ W(p.value, (A, L) => {
2223
+ var P;
2224
+ return s(), i("div", {
2225
+ key: A + L,
2224
2226
  class: "ctrl-upload-thumb"
2225
2227
  }, [
2226
2228
  l("img", {
2227
- src: w,
2229
+ src: A,
2228
2230
  alt: ""
2229
- }, null, 8, Ol),
2230
- (O = t.field) != null && O.disabled ? I("v-if", !0) : (s(), r("button", {
2231
+ }, null, 8, va),
2232
+ (P = t.field) != null && P.disabled ? x("v-if", !0) : (s(), i("button", {
2231
2233
  key: 0,
2232
2234
  type: "button",
2233
2235
  class: "ctrl-upload-remove",
2234
2236
  "aria-label": "删除图片",
2235
- onClick: (c) => h(P)
2236
- }, " × ", 8, jl))
2237
+ onClick: (u) => y(L)
2238
+ }, " × ", 8, fa))
2237
2239
  ]);
2238
2240
  }),
2239
2241
  128
2240
2242
  /* KEYED_FRAGMENT */
2241
2243
  )),
2242
- a.value ? (s(), r("label", Rl, [
2243
- b[0] || (b[0] = l(
2244
+ a.value ? (s(), i("label", ma, [
2245
+ T[0] || (T[0] = l(
2244
2246
  "span",
2245
2247
  null,
2246
2248
  "+",
@@ -2249,8 +2251,8 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
2249
2251
  )),
2250
2252
  l(
2251
2253
  "span",
2252
- Ll,
2253
- A(p.value ? "…" : t.item.placeholder || "上传"),
2254
+ pa,
2255
+ $(m.value ? "…" : t.item.placeholder || "上传"),
2254
2256
  1
2255
2257
  /* TEXT */
2256
2258
  ),
@@ -2259,20 +2261,20 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
2259
2261
  accept: "image/*",
2260
2262
  multiple: g.value > 1,
2261
2263
  hidden: "",
2262
- onChange: i
2263
- }, null, 40, Nl)
2264
- ])) : I("v-if", !0)
2264
+ onChange: c
2265
+ }, null, 40, ha)
2266
+ ])) : x("v-if", !0)
2265
2267
  ]),
2266
- f.value ? (s(), r(
2268
+ h.value ? (s(), i(
2267
2269
  "div",
2268
- Bl,
2269
- A(f.value),
2270
+ ga,
2271
+ $(h.value),
2270
2272
  1
2271
2273
  /* TEXT */
2272
- )) : I("v-if", !0)
2274
+ )) : x("v-if", !0)
2273
2275
  ]));
2274
2276
  }
2275
- }), Ul = /* @__PURE__ */ N(El, [["__scopeId", "data-v-f549efb4"]]), Hl = { class: "ctrl-slider" }, Kl = ["min", "max", "step", "value", "disabled", "aria-label"], Gl = { class: "ctrl-slider-value" }, zl = /* @__PURE__ */ L({
2277
+ }), ka = /* @__PURE__ */ Y(ya, [["__scopeId", "data-v-f549efb4"]]), ba = { class: "ctrl-slider" }, _a = ["min", "max", "step", "value", "disabled", "aria-label"], Ca = { class: "ctrl-slider-value" }, $a = /* @__PURE__ */ U({
2276
2278
  __name: "SliderControl",
2277
2279
  props: {
2278
2280
  item: {},
@@ -2281,63 +2283,63 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
2281
2283
  },
2282
2284
  emits: ["change"],
2283
2285
  setup(t, { emit: n }) {
2284
- var i;
2285
- const e = t, y = n, u = C(() => {
2286
- var h;
2287
- return Number(((h = e.item.props) == null ? void 0 : h.min) ?? 0);
2288
- }), m = C(() => {
2289
- var h;
2290
- return Number(((h = e.item.props) == null ? void 0 : h.max) ?? 100);
2291
- }), p = C(() => {
2292
- var h;
2293
- return Number(((h = e.item.props) == null ? void 0 : h.step) ?? 1);
2294
- }), f = D(g((i = e.field) == null ? void 0 : i.value, u.value));
2295
- G(
2286
+ var c;
2287
+ const e = t, r = n, f = b(() => {
2288
+ var y;
2289
+ return Number(((y = e.item.props) == null ? void 0 : y.min) ?? 0);
2290
+ }), p = b(() => {
2291
+ var y;
2292
+ return Number(((y = e.item.props) == null ? void 0 : y.max) ?? 100);
2293
+ }), m = b(() => {
2294
+ var y;
2295
+ return Number(((y = e.item.props) == null ? void 0 : y.step) ?? 1);
2296
+ }), h = E(g((c = e.field) == null ? void 0 : c.value, f.value));
2297
+ Z(
2296
2298
  () => {
2297
- var h;
2298
- return (h = e.field) == null ? void 0 : h.value;
2299
+ var y;
2300
+ return (y = e.field) == null ? void 0 : y.value;
2299
2301
  },
2300
- (h) => {
2301
- f.value = g(h, u.value);
2302
+ (y) => {
2303
+ h.value = g(y, f.value);
2302
2304
  }
2303
2305
  );
2304
- function g(h, V) {
2305
- const v = Number(h);
2306
- return Number.isFinite(v) ? v : V;
2306
+ function g(y, M) {
2307
+ const v = Number(y);
2308
+ return Number.isFinite(v) ? v : M;
2307
2309
  }
2308
- function a(h) {
2309
- f.value = Number(h.target.value);
2310
+ function a(y) {
2311
+ h.value = Number(y.target.value);
2310
2312
  }
2311
- function o(h) {
2312
- const V = Number(h.target.value);
2313
- f.value = V, y("change", { value: V, eventType: "pickChange" });
2313
+ function o(y) {
2314
+ const M = Number(y.target.value);
2315
+ h.value = M, r("change", { value: M, eventType: "pickChange" });
2314
2316
  }
2315
- return (h, V) => {
2317
+ return (y, M) => {
2316
2318
  var v;
2317
- return s(), r("div", Hl, [
2319
+ return s(), i("div", ba, [
2318
2320
  l("input", {
2319
2321
  class: "ctrl-slider-input",
2320
2322
  type: "range",
2321
- min: u.value,
2322
- max: m.value,
2323
- step: p.value,
2324
- value: f.value,
2323
+ min: f.value,
2324
+ max: p.value,
2325
+ step: m.value,
2326
+ value: h.value,
2325
2327
  disabled: (v = t.field) == null ? void 0 : v.disabled,
2326
2328
  "aria-label": t.item.label || "滑块",
2327
2329
  onInput: a,
2328
2330
  onChange: o
2329
- }, null, 40, Kl),
2331
+ }, null, 40, _a),
2330
2332
  l(
2331
2333
  "span",
2332
- Gl,
2333
- A(f.value),
2334
+ Ca,
2335
+ $(h.value),
2334
2336
  1
2335
2337
  /* TEXT */
2336
2338
  )
2337
2339
  ]);
2338
2340
  };
2339
2341
  }
2340
- }), Yl = /* @__PURE__ */ N(zl, [["__scopeId", "data-v-ac8f0c27"]]), ql = {
2342
+ }), Ta = /* @__PURE__ */ Y($a, [["__scopeId", "data-v-ac8f0c27"]]), wa = {
2341
2343
  input: "InputControl",
2342
2344
  textarea: "InputControl",
2343
2345
  number: "InputControl",
@@ -2361,30 +2363,30 @@ const _e = { class: "ctrl-input-wrapper" }, $e = ["value", "placeholder", "disab
2361
2363
  custom: "InputControl",
2362
2364
  list: "ListControl"
2363
2365
  };
2364
- function Wl(t, n) {
2365
- return se(t) ? "TaskControl" : ql[n] || "InputControl";
2366
+ function Sa(t, n) {
2367
+ return Ce(t) ? "TaskControl" : wa[n] || "InputControl";
2366
2368
  }
2367
- function Jl(t, n, e) {
2368
- const y = se(t);
2369
- return y ? {
2369
+ function xa(t, n, e) {
2370
+ const r = Ce(t);
2371
+ return r ? {
2370
2372
  ...e || {},
2371
2373
  taskType: t,
2372
- taskCategory: y === "customer" ? "CUSTOMER_TASK" : y === "inline" ? "inline" : "TASKS"
2374
+ taskCategory: r === "customer" ? "CUSTOMER_TASK" : r === "inline" ? "inline" : "TASKS"
2373
2375
  } : e;
2374
2376
  }
2375
- function Xl(t) {
2377
+ function Aa(t) {
2376
2378
  if (typeof t != "object" || t === null)
2377
2379
  return { value: t };
2378
- const n = t.value !== void 0 ? t.value : t, e = t.eventType, { value: y, eventType: u, ...m } = t;
2379
- return Object.keys(m).length > 0 ? { value: n, eventType: e, extraFields: m } : { value: n, eventType: e };
2380
+ const n = t.value !== void 0 ? t.value : t, e = t.eventType, { value: r, eventType: f, ...p } = t;
2381
+ return Object.keys(p).length > 0 ? { value: n, eventType: e, extraFields: p } : { value: n, eventType: e };
2380
2382
  }
2381
- const Ql = ["data-label-position", "data-field-key"], Zl = {
2383
+ const Ia = ["data-label-position", "data-field-key"], Oa = {
2382
2384
  key: 0,
2383
2385
  class: "form-error"
2384
- }, ea = {
2386
+ }, Ma = {
2385
2387
  key: 1,
2386
2388
  class: "form-icon"
2387
- }, ta = { key: 0 }, la = { key: 1 }, aa = { key: 2 }, na = /* @__PURE__ */ L({
2389
+ }, Va = { key: 0 }, Ea = { key: 1 }, Pa = { key: 2 }, Fa = /* @__PURE__ */ U({
2388
2390
  __name: "FormItem",
2389
2391
  props: {
2390
2392
  item: {},
@@ -2392,21 +2394,21 @@ const Ql = ["data-label-position", "data-field-key"], Zl = {
2392
2394
  formCore: {}
2393
2395
  },
2394
2396
  setup(t) {
2395
- const n = t, e = q("customControls", {}), y = q("themeLabelPosition", void 0), u = {
2396
- InputControl: xe,
2397
- SelectControl: Pe,
2398
- CascaderControl: ze,
2399
- SearchControl: tt,
2400
- AddressControl: vt,
2401
- AgreementControl: gt,
2402
- TaskControl: il,
2403
- ListControl: kl,
2404
- DateControl: wl,
2405
- VerifyCodeControl: Dl,
2406
- ImageUploadControl: Ul,
2407
- SliderControl: Yl
2408
- }, m = C(() => {
2409
- const a = Jl(
2397
+ const n = t, e = le("customControls", {}), r = le("themeLabelPosition", void 0), f = {
2398
+ InputControl: at,
2399
+ SelectControl: dt,
2400
+ CascaderControl: $t,
2401
+ SearchControl: Vt,
2402
+ AddressControl: Ut,
2403
+ AgreementControl: Gt,
2404
+ TaskControl: Nl,
2405
+ ListControl: Jl,
2406
+ DateControl: la,
2407
+ VerifyCodeControl: ca,
2408
+ ImageUploadControl: ka,
2409
+ SliderControl: Ta
2410
+ }, p = b(() => {
2411
+ const a = xa(
2410
2412
  n.item.key,
2411
2413
  n.item.type,
2412
2414
  n.item.raw.props || {}
@@ -2418,84 +2420,84 @@ const Ql = ["data-label-position", "data-field-key"], Zl = {
2418
2420
  props: a
2419
2421
  }
2420
2422
  };
2421
- }), p = C(
2423
+ }), m = b(
2422
2424
  () => {
2423
2425
  var a;
2424
- return ye(
2426
+ return Ne(
2425
2427
  (a = n.item.raw) == null ? void 0 : a.labelPosition,
2426
- te(y)
2428
+ ne(r)
2427
2429
  );
2428
2430
  }
2429
- ), f = C(() => {
2431
+ ), h = b(() => {
2430
2432
  var o;
2431
2433
  if (n.item.type === "custom") {
2432
- const i = (o = n.item.raw) == null ? void 0 : o.customRender;
2433
- if (i && e[i])
2434
- return e[i];
2435
- if (i && typeof i != "string")
2436
- return i;
2434
+ const c = (o = n.item.raw) == null ? void 0 : o.customRender;
2435
+ if (c && e[c])
2436
+ return e[c];
2437
+ if (c && typeof c != "string")
2438
+ return c;
2437
2439
  }
2438
- const a = Wl(n.item.key, n.item.type);
2439
- return u[a];
2440
+ const a = Sa(n.item.key, n.item.type);
2441
+ return f[a];
2440
2442
  });
2441
2443
  function g(a) {
2442
- const { value: o, eventType: i, extraFields: h } = Xl(a);
2444
+ const { value: o, eventType: c, extraFields: y } = Aa(a);
2443
2445
  n.formCore.setControlData(n.item.key, o, {
2444
- eventType: i,
2445
- ...h ? { extraFields: h } : {}
2446
+ eventType: c,
2447
+ ...y ? { extraFields: y } : {}
2446
2448
  });
2447
2449
  }
2448
2450
  return (a, o) => {
2449
- var i, h;
2450
- return s(), r("div", {
2451
- class: R(["form-item", {
2452
- "form-item-error": (i = t.field) == null ? void 0 : i.errMsg,
2453
- "form-item--top": p.value === "top",
2454
- "form-item--left": p.value === "left"
2451
+ var c, y;
2452
+ return s(), i("div", {
2453
+ class: K(["form-item", {
2454
+ "form-item-error": (c = t.field) == null ? void 0 : c.errMsg,
2455
+ "form-item--top": m.value === "top",
2456
+ "form-item--left": m.value === "left"
2455
2457
  }]),
2456
- "data-label-position": p.value,
2458
+ "data-label-position": m.value,
2457
2459
  "data-field-key": t.item.key
2458
2460
  }, [
2459
- t.item.hideLabel ? I("v-if", !0) : (s(), r(
2461
+ t.item.hideLabel ? x("v-if", !0) : (s(), i(
2460
2462
  "label",
2461
2463
  {
2462
2464
  key: 0,
2463
- class: R(["form-label", { required: t.item.required }])
2465
+ class: K(["form-label", { required: t.item.required }])
2464
2466
  },
2465
- A(t.item.label),
2467
+ $(t.item.label),
2466
2468
  3
2467
2469
  /* TEXT, CLASS */
2468
2470
  )),
2469
2471
  l(
2470
2472
  "div",
2471
2473
  {
2472
- class: R(["form-control", { "form-control-full": t.item.hideLabel }])
2474
+ class: K(["form-control", { "form-control-full": t.item.hideLabel }])
2473
2475
  },
2474
2476
  [
2475
- (s(), J(ee(f.value), {
2476
- item: m.value.raw,
2477
+ (s(), ee(ce(h.value), {
2478
+ item: p.value.raw,
2477
2479
  field: t.field,
2478
2480
  formCore: t.formCore,
2479
2481
  onChange: g
2480
2482
  }, null, 40, ["item", "field", "formCore"])),
2481
- (h = t.field) != null && h.errMsg ? (s(), r(
2483
+ (y = t.field) != null && y.errMsg ? (s(), i(
2482
2484
  "div",
2483
- Zl,
2484
- A(t.field.errMsg),
2485
+ Oa,
2486
+ $(t.field.errMsg),
2485
2487
  1
2486
2488
  /* TEXT */
2487
- )) : I("v-if", !0)
2489
+ )) : x("v-if", !0)
2488
2490
  ],
2489
2491
  2
2490
2492
  /* CLASS */
2491
2493
  ),
2492
- t.item.rightIcon && !t.item.hideLabel && p.value === "left" ? (s(), r("span", ea, [
2493
- t.item.rightIcon === "arrow" ? (s(), r("span", ta, "›")) : t.item.rightIcon === "location" ? (s(), r("span", la, "📍")) : t.item.rightIcon === "search" ? (s(), r("span", aa, "🔍")) : I("v-if", !0)
2494
- ])) : I("v-if", !0)
2495
- ], 10, Ql);
2494
+ t.item.rightIcon && !t.item.hideLabel && m.value === "left" ? (s(), i("span", Ma, [
2495
+ t.item.rightIcon === "arrow" ? (s(), i("span", Va, "›")) : t.item.rightIcon === "location" ? (s(), i("span", Ea, "📍")) : t.item.rightIcon === "search" ? (s(), i("span", Pa, "🔍")) : x("v-if", !0)
2496
+ ])) : x("v-if", !0)
2497
+ ], 10, Ia);
2496
2498
  };
2497
2499
  }
2498
- }), ie = /* @__PURE__ */ N(na, [["__scopeId", "data-v-177bcff2"]]), oa = { class: "form-group" }, sa = { class: "group-body" }, ia = /* @__PURE__ */ L({
2500
+ }), $e = /* @__PURE__ */ Y(Fa, [["__scopeId", "data-v-177bcff2"]]), Da = { class: "form-group" }, Ra = { class: "group-body" }, Na = /* @__PURE__ */ U({
2499
2501
  __name: "FormGroup",
2500
2502
  props: {
2501
2503
  group: {},
@@ -2503,26 +2505,26 @@ const Ql = ["data-label-position", "data-field-key"], Zl = {
2503
2505
  formCore: {}
2504
2506
  },
2505
2507
  setup(t) {
2506
- const n = t, e = q(
2508
+ const n = t, e = le(
2507
2509
  "FormItemComponent",
2508
2510
  void 0
2509
- ), y = C(
2510
- () => e ? te(e) : ie
2511
- ), u = C(
2512
- () => n.group.items.filter((m) => {
2513
- const p = n.fields[m.key];
2514
- return !p || p.visible;
2511
+ ), r = b(
2512
+ () => e ? ne(e) : $e
2513
+ ), f = b(
2514
+ () => n.group.items.filter((p) => {
2515
+ const m = n.fields[p.key];
2516
+ return !m || m.visible;
2515
2517
  })
2516
2518
  );
2517
- return (m, p) => (s(), r("div", oa, [
2518
- l("div", sa, [
2519
- (s(!0), r(
2520
- B,
2519
+ return (p, m) => (s(), i("div", Da, [
2520
+ l("div", Ra, [
2521
+ (s(!0), i(
2522
+ q,
2521
2523
  null,
2522
- U(u.value, (f) => (s(), J(ee(y.value), {
2523
- key: f.key,
2524
- item: f,
2525
- field: t.fields[f.key],
2524
+ W(f.value, (h) => (s(), ee(ce(r.value), {
2525
+ key: h.key,
2526
+ item: h,
2527
+ field: t.fields[h.key],
2526
2528
  formCore: t.formCore
2527
2529
  }, null, 8, ["item", "field", "formCore"]))),
2528
2530
  128
@@ -2531,10 +2533,10 @@ const Ql = ["data-label-position", "data-field-key"], Zl = {
2531
2533
  ])
2532
2534
  ]));
2533
2535
  }
2534
- }), ra = /* @__PURE__ */ N(ia, [["__scopeId", "data-v-83eda13b"]]), ca = ["data-shell", "data-label-align", "data-content-align"], ua = {
2536
+ }), La = /* @__PURE__ */ Y(Na, [["__scopeId", "data-v-83eda13b"]]), ja = ["data-shell", "data-label-align", "data-content-align"], Ba = {
2535
2537
  key: 0,
2536
2538
  class: "form-render__title"
2537
- }, da = /* @__PURE__ */ L({
2539
+ }, Ka = /* @__PURE__ */ U({
2538
2540
  __name: "FormRender",
2539
2541
  props: {
2540
2542
  groups: {},
@@ -2551,82 +2553,443 @@ const Ql = ["data-label-position", "data-field-key"], Zl = {
2551
2553
  hostHandlers: {}
2552
2554
  },
2553
2555
  setup(t) {
2554
- const n = t, e = C(() => n.labelAlign === "left" || n.labelAlign === "right" || n.labelAlign === "top" ? n.labelAlign : n.labelPosition === "top" ? "top" : (n.labelPosition === "left", "left")), y = C(
2556
+ const n = t, e = b(() => n.labelAlign === "left" || n.labelAlign === "right" || n.labelAlign === "top" ? n.labelAlign : n.labelPosition === "top" ? "top" : (n.labelPosition === "left", "left")), r = b(
2555
2557
  () => e.value === "top" ? "top" : "left"
2556
2558
  );
2557
- z("customControls", n.customControls || {}), z("themeLabelPosition", y), z("formUiLayout", C(() => ({
2559
+ G("customControls", n.customControls || {}), G("themeLabelPosition", r), G("formUiLayout", b(() => ({
2558
2560
  labelAlign: e.value,
2559
2561
  labelWidth: n.labelWidth ?? "81px",
2560
2562
  contentAlign: n.contentAlign ?? "left"
2561
- }))), z(
2563
+ }))), G(
2562
2564
  "FormItemComponent",
2563
- C(() => n.FormItemComponent || ie)
2564
- ), z(
2565
- ae,
2566
- C(() => n.hostHandlers ?? null)
2565
+ b(() => n.FormItemComponent || $e)
2566
+ ), G(
2567
+ ue,
2568
+ b(() => n.hostHandlers ?? null)
2567
2569
  );
2568
- const u = C(() => n.FormGroupComponent || ra);
2569
- return (m, p) => (s(), r("div", {
2570
+ const f = b(() => n.FormGroupComponent || La);
2571
+ return (p, m) => (s(), i("div", {
2570
2572
  class: "form-render",
2571
2573
  "data-shell": t.FormGroupComponent ? "override" : "default",
2572
2574
  "data-label-align": e.value,
2573
2575
  "data-content-align": t.contentAlign || "left"
2574
2576
  }, [
2575
- t.title ? (s(), r(
2577
+ t.title ? (s(), i(
2576
2578
  "div",
2577
- ua,
2578
- A(t.title),
2579
+ Ba,
2580
+ $(t.title),
2579
2581
  1
2580
2582
  /* TEXT */
2581
- )) : I("v-if", !0),
2582
- (s(!0), r(
2583
- B,
2583
+ )) : x("v-if", !0),
2584
+ (s(!0), i(
2585
+ q,
2584
2586
  null,
2585
- U(t.groups, (f) => (s(), J(ee(u.value), {
2586
- key: f.key,
2587
- group: f,
2587
+ W(t.groups, (h) => (s(), ee(ce(f.value), {
2588
+ key: h.key,
2589
+ group: h,
2588
2590
  fields: t.fields,
2589
2591
  formCore: t.formCore
2590
2592
  }, null, 8, ["group", "fields", "formCore"]))),
2591
2593
  128
2592
2594
  /* KEYED_FRAGMENT */
2593
2595
  )),
2594
- me(m.$slots, "footer", {}, void 0, !0)
2595
- ], 8, ca));
2596
+ ye(p.$slots, "footer", {}, void 0, !0)
2597
+ ], 8, ja));
2598
+ }
2599
+ }), Ua = /* @__PURE__ */ Y(Ka, [["__scopeId", "data-v-c936694c"]]), Ha = ["data-modern-skin"], Ya = {
2600
+ key: 0,
2601
+ class: "apf-prism-form__header"
2602
+ }, qa = { class: "apf-prism-form__title" }, za = {
2603
+ key: 0,
2604
+ class: "apf-prism-form__desc"
2605
+ }, Ga = {
2606
+ key: 1,
2607
+ class: "apf-prism-form__progress",
2608
+ "data-testid": "prism-form-progress"
2609
+ }, Wa = { class: "apf-prism-form__progress-row" }, Ja = { key: 0 }, Xa = { key: 1 }, Qa = { class: "apf-prism-form__bar" }, Za = {
2610
+ key: 2,
2611
+ class: "apf-prism-form__steps",
2612
+ "data-testid": "prism-form-steps"
2613
+ }, en = ["onClick"], tn = {
2614
+ key: 0,
2615
+ class: "apf-prism-form__step-nav"
2616
+ }, ln = ["disabled"], an = { class: "apf-prism-form__step-count" }, nn = ["disabled"], on = {
2617
+ key: 0,
2618
+ class: "apf-prism-form__footer"
2619
+ }, sn = ["disabled"], rn = /* @__PURE__ */ U({
2620
+ __name: "PrismForm",
2621
+ props: {
2622
+ schema: { default: null },
2623
+ bundle: { default: null },
2624
+ themeConfig: { default: null },
2625
+ initialValues: { default: void 0 },
2626
+ skin: { default: void 0 },
2627
+ themeOverride: { default: void 0 },
2628
+ formMode: { default: void 0 },
2629
+ showProgressBar: { type: Boolean, default: void 0 },
2630
+ readOnly: { type: Boolean, default: void 0 },
2631
+ keyboardPolicy: { default: void 0 },
2632
+ locale: { default: void 0 },
2633
+ hostHandlers: { default: null },
2634
+ customControls: { default: void 0 },
2635
+ onTelemetry: { default: void 0 },
2636
+ storageAdapter: { default: void 0 },
2637
+ submitText: { default: void 0 },
2638
+ showSubmit: { type: Boolean, default: !0 },
2639
+ submitting: { type: Boolean, default: !1 },
2640
+ maxWidth: { default: "680px" }
2641
+ },
2642
+ emits: ["submit", "change", "validate-error"],
2643
+ setup(t, { expose: n, emit: e }) {
2644
+ const r = t, f = e, p = b(() => {
2645
+ var F;
2646
+ return r.schema || ((F = r.bundle) == null ? void 0 : F.schema) || null;
2647
+ }), m = b(() => {
2648
+ var F;
2649
+ return {
2650
+ ...((F = r.bundle) == null ? void 0 : F.themeConfig) || {},
2651
+ ...r.themeConfig || {}
2652
+ };
2653
+ }), h = b(
2654
+ () => r.skin || m.value.skin || "fin-minimal"
2655
+ ), g = b(
2656
+ () => r.themeOverride ?? m.value.override ?? null
2657
+ ), a = b(
2658
+ () => r.formMode || m.value.formMode || "flat"
2659
+ ), o = b(() => typeof r.showProgressBar == "boolean" ? r.showProgressBar : typeof m.value.showProgressBar == "boolean" ? m.value.showProgressBar : !0), c = b(() => typeof r.readOnly == "boolean" ? r.readOnly : !!m.value.readOnly), y = b(
2660
+ () => r.keyboardPolicy || m.value.keyboardPolicy || "auto"
2661
+ ), M = b(
2662
+ () => Le(r.locale || m.value.locale || "zh-CN")
2663
+ ), v = b(() => M.value === "en-US"), T = b(() => je(h.value, g.value)), A = Be();
2664
+ G(Ke, h), G(Ue, g), G(
2665
+ He,
2666
+ b(() => a.value === "collapsible")
2667
+ ), G(Ye, y), G(qe, c), G(
2668
+ ze,
2669
+ b(() => r.onTelemetry || null)
2670
+ ), G(Ge, M), G(
2671
+ We,
2672
+ b(() => r.customControls || {})
2673
+ ), G(
2674
+ ue,
2675
+ b(() => r.hostHandlers ?? null)
2676
+ );
2677
+ const L = E(null), P = Fe(null), u = ke({}), k = E([]), V = E(0), d = E(!1);
2678
+ let _ = null;
2679
+ function I() {
2680
+ const F = /* @__PURE__ */ new Map();
2681
+ return {
2682
+ get: (D) => F.get(D),
2683
+ set: (D, R) => F.set(D, R),
2684
+ remove: (D) => F.delete(D)
2685
+ };
2686
+ }
2687
+ function w(F) {
2688
+ return JSON.parse(JSON.stringify(F));
2689
+ }
2690
+ function O(F, D) {
2691
+ const R = new Set(Object.keys(F.fields));
2692
+ for (const H of Object.keys(u))
2693
+ R.has(H) || delete u[H];
2694
+ const N = {};
2695
+ for (const H of R) {
2696
+ const J = { ...F.fields[H] };
2697
+ u[H] = J, N[H] = J;
2698
+ }
2699
+ k.value = _e(D, N, { excludeTaskAndAgreement: !1 }).groups;
2700
+ }
2701
+ async function S(F) {
2702
+ if (_ && (_(), _ = null), d.value = !1, V.value = 0, !F) {
2703
+ P.value = null, k.value = [];
2704
+ return;
2705
+ }
2706
+ const D = w(F), R = new he(D, r.storageAdapter || I());
2707
+ P.value = R;
2708
+ const N = () => {
2709
+ O(R, D), f("change", {
2710
+ values: R.collectFormData({ skipVerify: !0 }),
2711
+ fields: { ...u }
2712
+ });
2713
+ };
2714
+ await R.init(r.initialValues ? { ...r.initialValues } : {}), R.on("afterChange", N), _ = () => {
2715
+ R.off("afterChange", N);
2716
+ }, O(R, D), d.value = !0;
2717
+ }
2718
+ Z(
2719
+ p,
2720
+ (F) => {
2721
+ S(F);
2722
+ },
2723
+ { immediate: !0 }
2724
+ ), be(() => {
2725
+ _ && (_(), _ = null);
2726
+ });
2727
+ const C = b(() => a.value === "step" && k.value.length > 1), j = b(() => Math.min(V.value, Math.max(0, k.value.length - 1))), z = b(
2728
+ () => C.value ? [k.value[j.value]].filter(Boolean) : k.value
2729
+ ), B = b(
2730
+ () => o.value ? Je(k.value, u) : null
2731
+ ), Te = b(
2732
+ () => r.submitText || m.value.submitText || (v.value ? "Submit Form" : "提交表单")
2733
+ );
2734
+ function fe(F) {
2735
+ var H;
2736
+ if (!F || typeof document > "u") return;
2737
+ if (C.value) {
2738
+ const J = k.value.findIndex((oe) => (oe.items || []).some((Ae) => Ae.key === F));
2739
+ J >= 0 && (V.value = J);
2740
+ }
2741
+ const D = L.value || document, R = D.querySelector(`[data-field-key="${F}"]`) || D.querySelector('[data-has-error="1"], .m-field-error');
2742
+ R && typeof R.scrollIntoView == "function" && R.scrollIntoView({ behavior: "smooth", block: "center" });
2743
+ const N = R == null ? void 0 : R.querySelector("input, textarea, select");
2744
+ (H = N == null ? void 0 : N.focus) == null || H.call(N, { preventScroll: !0 });
2745
+ }
2746
+ function we(F) {
2747
+ var N;
2748
+ const D = {};
2749
+ let R = null;
2750
+ for (const H of k.value)
2751
+ for (const J of H.items || []) {
2752
+ const oe = (N = F.fields[J.key]) == null ? void 0 : N.errMsg;
2753
+ oe && (D[J.key] = String(oe), R || (R = J.key));
2754
+ }
2755
+ return { firstErrorKey: R, errors: D };
2756
+ }
2757
+ function de() {
2758
+ const F = P.value, D = p.value;
2759
+ if (!F || !D) return !1;
2760
+ const R = F.validateAll();
2761
+ if (O(F, D), !R) {
2762
+ const N = we(F);
2763
+ f("validate-error", N), fe(N.firstErrorKey);
2764
+ }
2765
+ return R;
2766
+ }
2767
+ function me() {
2768
+ return P.value ? P.value.collectFormData({ skipVerify: !0 }) : {};
2769
+ }
2770
+ function Se(F, D, R) {
2771
+ var N;
2772
+ (N = P.value) == null || N.setControlData(F, D, R);
2773
+ }
2774
+ async function xe(F) {
2775
+ const D = p.value;
2776
+ if (D) {
2777
+ if (F !== void 0) {
2778
+ const R = w(D);
2779
+ _ && (_(), _ = null);
2780
+ const N = new he(R, r.storageAdapter || I());
2781
+ P.value = N;
2782
+ const H = () => {
2783
+ O(N, R), f("change", {
2784
+ values: N.collectFormData({ skipVerify: !0 }),
2785
+ fields: { ...u }
2786
+ });
2787
+ };
2788
+ await N.init({ ...F }), N.on("afterChange", H), _ = () => N.off("afterChange", H), O(N, R), d.value = !0;
2789
+ return;
2790
+ }
2791
+ await S(D);
2792
+ }
2793
+ }
2794
+ function pe() {
2795
+ r.submitting || c.value || de() && f("submit", me());
2796
+ }
2797
+ return n({
2798
+ validate: de,
2799
+ getValues: me,
2800
+ setValue: Se,
2801
+ reset: xe,
2802
+ getCore: () => P.value
2803
+ }), (F, D) => {
2804
+ var R;
2805
+ return s(), i("div", {
2806
+ ref_key: "rootEl",
2807
+ ref: L,
2808
+ class: "apf-prism-form",
2809
+ "data-modern-skin": h.value,
2810
+ style: re({ ...T.value, maxWidth: t.maxWidth })
2811
+ }, [
2812
+ (R = p.value) != null && R.title ? (s(), i("div", Ya, [
2813
+ l(
2814
+ "div",
2815
+ qa,
2816
+ $(p.value.title),
2817
+ 1
2818
+ /* TEXT */
2819
+ ),
2820
+ p.value.description ? (s(), i(
2821
+ "div",
2822
+ za,
2823
+ $(p.value.description),
2824
+ 1
2825
+ /* TEXT */
2826
+ )) : x("v-if", !0)
2827
+ ])) : x("v-if", !0),
2828
+ d.value && B.value && B.value.total > 0 ? (s(), i("div", Ga, [
2829
+ l("div", Wa, [
2830
+ v.value ? (s(), i("span", Ja, [
2831
+ D[3] || (D[3] = X(
2832
+ " Progress ",
2833
+ -1
2834
+ /* CACHED */
2835
+ )),
2836
+ l(
2837
+ "strong",
2838
+ null,
2839
+ $(B.value.percent) + "%",
2840
+ 1
2841
+ /* TEXT */
2842
+ ),
2843
+ X(
2844
+ " (Required " + $(B.value.requiredFilled) + "/" + $(B.value.requiredTotal) + ") ",
2845
+ 1
2846
+ /* TEXT */
2847
+ )
2848
+ ])) : (s(), i("span", Xa, [
2849
+ D[4] || (D[4] = X(
2850
+ " 填写进度 ",
2851
+ -1
2852
+ /* CACHED */
2853
+ )),
2854
+ l(
2855
+ "strong",
2856
+ null,
2857
+ $(B.value.percent) + "%",
2858
+ 1
2859
+ /* TEXT */
2860
+ ),
2861
+ X(
2862
+ "(必填 " + $(B.value.requiredFilled) + "/" + $(B.value.requiredTotal) + ") ",
2863
+ 1
2864
+ /* TEXT */
2865
+ )
2866
+ ])),
2867
+ B.value.firstMissingRequiredKey ? (s(), i(
2868
+ "button",
2869
+ {
2870
+ key: 2,
2871
+ type: "button",
2872
+ class: "apf-prism-form__jump",
2873
+ onClick: D[0] || (D[0] = (N) => fe(B.value.firstMissingRequiredKey))
2874
+ },
2875
+ $(v.value ? "Next required ›" : "定位未填 ›"),
2876
+ 1
2877
+ /* TEXT */
2878
+ )) : x("v-if", !0)
2879
+ ]),
2880
+ l("div", Qa, [
2881
+ l(
2882
+ "div",
2883
+ {
2884
+ class: "apf-prism-form__bar-fill",
2885
+ style: re({ width: `${B.value.percent}%` })
2886
+ },
2887
+ null,
2888
+ 4
2889
+ /* STYLE */
2890
+ )
2891
+ ])
2892
+ ])) : x("v-if", !0),
2893
+ d.value && C.value ? (s(), i("div", Za, [
2894
+ (s(!0), i(
2895
+ q,
2896
+ null,
2897
+ W(k.value, (N, H) => (s(), i("button", {
2898
+ key: N.key || H,
2899
+ type: "button",
2900
+ class: K(["apf-prism-form__step-pill", { "is-active": j.value === H }]),
2901
+ onClick: (J) => V.value = H
2902
+ }, $(H + 1) + ". " + $(N.title || (v.value ? `Step ${H + 1}` : `第${H + 1}步`)), 11, en))),
2903
+ 128
2904
+ /* KEYED_FRAGMENT */
2905
+ ))
2906
+ ])) : x("v-if", !0),
2907
+ d.value && P.value ? (s(), ee(Ua, De({
2908
+ key: 3,
2909
+ groups: z.value,
2910
+ fields: u,
2911
+ "form-core": P.value,
2912
+ "custom-controls": t.customControls,
2913
+ "host-handlers": t.hostHandlers
2914
+ }, ne(A)), {
2915
+ footer: te(() => [
2916
+ C.value ? (s(), i("div", tn, [
2917
+ l("button", {
2918
+ type: "button",
2919
+ class: "apf-prism-form__step-btn",
2920
+ disabled: j.value <= 0,
2921
+ onClick: D[1] || (D[1] = (N) => V.value = Math.max(0, j.value - 1))
2922
+ }, $(v.value ? "Previous" : "上一步"), 9, ln),
2923
+ l(
2924
+ "span",
2925
+ an,
2926
+ $(j.value + 1) + " / " + $(k.value.length),
2927
+ 1
2928
+ /* TEXT */
2929
+ ),
2930
+ l("button", {
2931
+ type: "button",
2932
+ class: "apf-prism-form__step-btn is-primary",
2933
+ disabled: j.value >= k.value.length - 1,
2934
+ onClick: D[2] || (D[2] = (N) => V.value = Math.min(k.value.length - 1, j.value + 1))
2935
+ }, $(v.value ? "Next" : "下一步"), 9, nn)
2936
+ ])) : x("v-if", !0),
2937
+ ye(F.$slots, "footer", {
2938
+ submit: pe,
2939
+ validate: de,
2940
+ submitting: t.submitting
2941
+ }, () => [
2942
+ t.showSubmit && !c.value ? (s(), i("div", on, [
2943
+ l("button", {
2944
+ type: "button",
2945
+ class: "apf-prism-form__submit",
2946
+ disabled: t.submitting,
2947
+ onClick: pe
2948
+ }, $(t.submitting ? v.value ? "Submitting…" : "提交中…" : Te.value), 9, sn)
2949
+ ])) : x("v-if", !0)
2950
+ ], !0)
2951
+ ]),
2952
+ _: 3
2953
+ /* FORWARDED */
2954
+ }, 16, ["groups", "fields", "form-core", "custom-controls", "host-handlers"])) : x("v-if", !0)
2955
+ ], 12, Ha);
2956
+ };
2596
2957
  }
2597
- }), ha = /* @__PURE__ */ N(da, [["__scopeId", "data-v-c936694c"]]);
2598
- function ga(t, n, e) {
2599
- const y = ke(t, void 0, e), u = pe({
2600
- groups: y.groups,
2958
+ }), mn = /* @__PURE__ */ Y(rn, [["__scopeId", "data-v-0355ca79"]]);
2959
+ function pn(t, n, e) {
2960
+ const r = _e(t, void 0, e), f = ke({
2961
+ groups: r.groups,
2601
2962
  fields: {}
2602
2963
  });
2603
- function m() {
2964
+ function p() {
2604
2965
  const a = {};
2605
2966
  for (const o of Object.keys(n.fields))
2606
2967
  a[o] = { ...n.fields[o] };
2607
- Object.assign(u.fields, a);
2968
+ Object.assign(f.fields, a);
2608
2969
  }
2609
- function p() {
2610
- m();
2970
+ function m() {
2971
+ p();
2611
2972
  const a = {};
2612
2973
  for (const o of Object.keys(n.fields))
2613
2974
  a[o] = n.fields[o];
2614
- y.update(a), u.groups.splice(0, u.groups.length, ...y.groups);
2975
+ r.update(a), f.groups.splice(0, f.groups.length, ...r.groups);
2615
2976
  }
2616
- n.on("afterChange", p);
2617
- function f() {
2618
- n.off("afterChange", p);
2977
+ n.on("afterChange", m);
2978
+ function h() {
2979
+ n.off("afterChange", m);
2619
2980
  }
2620
- he() && ge(f), m();
2981
+ Re() && be(h), p();
2621
2982
  const g = {};
2622
2983
  for (const a of Object.keys(n.fields))
2623
2984
  g[a] = n.fields[a];
2624
- return y.update(g), u.groups = y.groups, { groups: u.groups, fields: u.fields, formCore: n, destroy: f };
2985
+ return r.update(g), f.groups = r.groups, { groups: f.groups, fields: f.fields, formCore: n, destroy: h };
2625
2986
  }
2626
2987
  export {
2627
- ra as FormGroup,
2628
- ie as FormItem,
2629
- ha as FormRender,
2630
- ba as setTaskHandlers,
2631
- ga as useFormRender
2988
+ La as FormGroup,
2989
+ $e as FormItem,
2990
+ Ua as FormRender,
2991
+ mn as PrismForm,
2992
+ yn as createFetchHostHandlers,
2993
+ bn as setTaskHandlers,
2994
+ pn as useFormRender
2632
2995
  };