@farris/ui-vue 1.3.0 → 1.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (201) hide show
  1. package/components/accordion/index.esm.js +1 -1
  2. package/components/accordion/index.umd.cjs +1 -1
  3. package/components/avatar/index.esm.js +472 -366
  4. package/components/avatar/index.umd.cjs +1 -1
  5. package/components/button-edit/index.esm.js +1 -1
  6. package/components/button-edit/index.umd.cjs +1 -1
  7. package/components/calendar/index.esm.js +472 -480
  8. package/components/calendar/index.umd.cjs +1 -1
  9. package/components/capsule/index.esm.js +225 -233
  10. package/components/capsule/index.umd.cjs +1 -1
  11. package/components/checkbox/index.esm.js +615 -517
  12. package/components/checkbox/index.umd.cjs +1 -1
  13. package/components/color-picker/index.esm.js +325 -333
  14. package/components/color-picker/index.umd.cjs +2 -2
  15. package/components/combo-list/index.esm.js +578 -472
  16. package/components/combo-list/index.umd.cjs +1 -1
  17. package/components/combo-tree/index.esm.js +49 -49
  18. package/components/combo-tree/index.umd.cjs +1 -1
  19. package/components/common/index.esm.js +832 -722
  20. package/components/common/index.umd.cjs +1 -1
  21. package/components/component/index.esm.js +303 -981
  22. package/components/component/index.umd.cjs +1 -1
  23. package/components/condition/index.esm.js +8 -8
  24. package/components/condition/index.umd.cjs +1 -1
  25. package/components/content-container/index.esm.js +335 -1002
  26. package/components/content-container/index.umd.cjs +1 -1
  27. package/components/data-grid/index.esm.js +4429 -4312
  28. package/components/data-grid/index.umd.cjs +1 -1
  29. package/components/data-view/index.esm.js +3037 -3020
  30. package/components/data-view/index.umd.cjs +1 -1
  31. package/components/date-picker/index.esm.js +2216 -2119
  32. package/components/date-picker/index.umd.cjs +1 -1
  33. package/components/designer-canvas/index.css +1 -1
  34. package/components/designer-canvas/index.esm.js +914 -883
  35. package/components/designer-canvas/index.umd.cjs +1 -1
  36. package/components/dropdown/index.esm.js +223 -231
  37. package/components/dropdown/index.umd.cjs +2 -2
  38. package/components/dynamic-form/index.esm.js +1691 -2187
  39. package/components/dynamic-form/index.umd.cjs +1 -1
  40. package/components/dynamic-resolver/index.esm.js +143 -136
  41. package/components/dynamic-resolver/index.umd.cjs +1 -1
  42. package/components/events-editor/index.esm.js +250 -258
  43. package/components/events-editor/index.umd.cjs +1 -1
  44. package/components/expression-editor/index.esm.js +1 -1
  45. package/components/expression-editor/index.umd.cjs +1 -1
  46. package/components/external-container/index.esm.js +2672 -3438
  47. package/components/external-container/index.umd.cjs +1 -1
  48. package/components/field-selector/index.esm.js +2965 -2970
  49. package/components/field-selector/index.umd.cjs +1 -1
  50. package/components/filter-bar/index.esm.js +1650 -1602
  51. package/components/filter-bar/index.umd.cjs +1 -1
  52. package/components/flow-canvas/index.css +1 -1
  53. package/components/flow-canvas/index.esm.js +684 -675
  54. package/components/flow-canvas/index.umd.cjs +1 -1
  55. package/components/image-cropper/index.esm.js +453 -461
  56. package/components/image-cropper/index.umd.cjs +1 -1
  57. package/components/input-group/index.esm.js +604 -507
  58. package/components/input-group/index.umd.cjs +1 -1
  59. package/components/layout/index.esm.js +402 -378
  60. package/components/layout/index.umd.cjs +1 -1
  61. package/components/list-nav/index.esm.js +348 -1019
  62. package/components/list-nav/index.umd.cjs +1 -1
  63. package/components/list-view/index.esm.js +1658 -1666
  64. package/components/list-view/index.umd.cjs +1 -1
  65. package/components/lookup/index.esm.js +5209 -5088
  66. package/components/lookup/index.umd.cjs +1 -1
  67. package/components/mapping-editor/index.esm.js +4329 -4213
  68. package/components/mapping-editor/index.umd.cjs +1 -1
  69. package/components/nav/index.esm.js +905 -1357
  70. package/components/nav/index.umd.cjs +3 -3
  71. package/components/number-range/index.esm.js +517 -420
  72. package/components/number-range/index.umd.cjs +1 -1
  73. package/components/number-spinner/index.esm.js +588 -491
  74. package/components/number-spinner/index.umd.cjs +1 -1
  75. package/components/order/index.esm.js +1376 -1965
  76. package/components/order/index.umd.cjs +1 -1
  77. package/components/page-footer/index.esm.js +1 -1
  78. package/components/page-footer/index.umd.cjs +1 -1
  79. package/components/page-header/index.esm.js +1073 -1905
  80. package/components/page-header/index.umd.cjs +1 -1
  81. package/components/pagination/index.esm.js +809 -1237
  82. package/components/pagination/index.umd.cjs +1 -1
  83. package/components/progress/index.esm.js +198 -206
  84. package/components/progress/index.umd.cjs +3 -3
  85. package/components/property-editor/index.esm.js +1297 -1200
  86. package/components/property-editor/index.umd.cjs +2 -2
  87. package/components/property-panel/index.esm.js +609 -507
  88. package/components/property-panel/index.umd.cjs +1 -1
  89. package/components/query-solution/index.esm.js +3391 -3758
  90. package/components/query-solution/index.umd.cjs +1 -1
  91. package/components/radio-button/index.esm.js +1 -1
  92. package/components/radio-button/index.umd.cjs +1 -1
  93. package/components/radio-group/index.esm.js +544 -447
  94. package/components/radio-group/index.umd.cjs +1 -1
  95. package/components/rate/index.esm.js +247 -255
  96. package/components/rate/index.umd.cjs +1 -1
  97. package/components/response-layout/index.esm.js +146 -154
  98. package/components/response-layout/index.umd.cjs +1 -1
  99. package/components/response-layout-editor/index.esm.js +700 -675
  100. package/components/response-layout-editor/index.umd.cjs +1 -1
  101. package/components/response-toolbar/index.esm.js +956 -1786
  102. package/components/response-toolbar/index.umd.cjs +1 -1
  103. package/components/schema-selector/index.esm.js +4963 -5617
  104. package/components/schema-selector/index.umd.cjs +2 -2
  105. package/components/search-box/index.esm.js +158 -161
  106. package/components/search-box/index.umd.cjs +1 -1
  107. package/components/section/index.esm.js +436 -1124
  108. package/components/section/index.umd.cjs +1 -1
  109. package/components/smoke-detector/index.esm.js +92 -100
  110. package/components/smoke-detector/index.umd.cjs +1 -1
  111. package/components/splitter/index.esm.js +571 -1210
  112. package/components/splitter/index.umd.cjs +1 -1
  113. package/components/splitter/style.js +2 -0
  114. package/components/step/index.esm.js +239 -247
  115. package/components/step/index.umd.cjs +1 -1
  116. package/components/switch/index.esm.js +445 -348
  117. package/components/switch/index.umd.cjs +1 -1
  118. package/components/tabs/index.esm.js +2278 -3031
  119. package/components/tabs/index.umd.cjs +1 -1
  120. package/components/tags/index.esm.js +311 -319
  121. package/components/tags/index.umd.cjs +1 -1
  122. package/components/text/index.esm.js +215 -223
  123. package/components/text/index.umd.cjs +1 -1
  124. package/components/textarea/index.esm.js +468 -371
  125. package/components/textarea/index.umd.cjs +1 -1
  126. package/components/time-picker/index.esm.js +1271 -1174
  127. package/components/time-picker/index.umd.cjs +1 -1
  128. package/components/transfer/index.esm.js +469 -477
  129. package/components/transfer/index.umd.cjs +1 -1
  130. package/components/tree-grid/index.esm.js +3060 -3065
  131. package/components/tree-grid/index.umd.cjs +1 -1
  132. package/components/tree-view/index.esm.js +2476 -2481
  133. package/components/tree-view/index.umd.cjs +1 -1
  134. package/components/uploader/index.esm.js +374 -382
  135. package/components/uploader/index.umd.cjs +2 -2
  136. package/components/verify-detail/index.esm.js +248 -256
  137. package/components/verify-detail/index.umd.cjs +1 -1
  138. package/components/video/index.esm.js +414 -1093
  139. package/components/video/index.umd.cjs +1 -1
  140. package/components/weather/index.esm.js +498 -506
  141. package/components/weather/index.umd.cjs +5 -5
  142. package/farris.all.esm.js +20216 -21844
  143. package/farris.all.umd.cjs +9 -9
  144. package/index.css +1 -1
  145. package/package.json +1 -1
  146. package/types/common/directive/area-response.d.ts +10 -0
  147. package/types/common/index.d.ts +8 -0
  148. package/types/common/radio-checkbox/radio-checkbox.props.d.ts +1 -0
  149. package/types/common/utils/resolve-field.d.ts +2 -0
  150. package/types/common/utils/use-class.d.ts +7 -0
  151. package/types/component/src/designer/use-designer-rules.d.ts +2 -2
  152. package/types/condition/src/types.d.ts +2 -1
  153. package/types/content-container/src/designer/use-designer-rules.d.ts +3 -3
  154. package/types/data-grid/index.d.ts +8 -5
  155. package/types/data-grid/src/data-grid.component.d.ts +3 -2
  156. package/types/data-grid/src/designer/data-grid.design.component.d.ts +2 -2
  157. package/types/data-grid/src/designer/use-designer-rules.d.ts +2 -2
  158. package/types/data-view/components/row/hierarchy-row.component.d.ts +2 -2
  159. package/types/data-view/composition/data/use-tree-data.d.ts +1 -1
  160. package/types/data-view/composition/types.d.ts +7 -9
  161. package/types/designer-canvas/index.d.ts +2 -1
  162. package/types/designer-canvas/src/composition/rule/use-dragula-common-rule.d.ts +4 -0
  163. package/types/designer-canvas/src/composition/rule/use-template-rule.d.ts +30 -0
  164. package/types/designer-canvas/src/composition/types.d.ts +1 -2
  165. package/types/designer-canvas/src/types.d.ts +2 -1
  166. package/types/dynamic-form/src/designer/response-form.design.component.d.ts +7 -1
  167. package/types/dynamic-form/src/designer/use-designer-rules.d.ts +2 -2
  168. package/types/dynamic-form/src/property-config/form.property-config.d.ts +1 -1
  169. package/types/dynamic-resolver/src/common/toolbar-resolver.d.ts +1 -1
  170. package/types/external-container/src/designer/use-designer-rules.d.ts +3 -3
  171. package/types/layout/src/designer/layout-pane-use-designer-rules.d.ts +3 -3
  172. package/types/list-nav/src/designer/use-designer-rules.d.ts +3 -0
  173. package/types/pagination/src/components/buttons/goto-buttons.component.d.ts +2 -2
  174. package/types/pagination/src/components/buttons/next-buttons.component.d.ts +2 -2
  175. package/types/pagination/src/components/buttons/previous-buttons.component.d.ts +2 -2
  176. package/types/pagination/src/components/pages/page-list.component.d.ts +2 -2
  177. package/types/pagination/src/components/pages/page-number.component.d.ts +2 -2
  178. package/types/property-panel/index.d.ts +2 -1
  179. package/types/property-panel/src/composition/entity/input-base-property.d.ts +1 -1
  180. package/types/query-solution/src/designer/query-solution-config/composition/types.d.ts +34 -27
  181. package/types/query-solution/src/designer/query-solution-config/composition/use-panel.d.ts +2 -16
  182. package/types/query-solution/src/designer/query-solution-config/composition/use-property.d.ts +19 -0
  183. package/types/query-solution/src/designer/query-solution-config/composition/use-querysolution-rules.d.ts +3 -0
  184. package/types/query-solution/src/designer/query-solution-config/composition/use-transfer.d.ts +1 -1
  185. package/types/query-solution/src/property-config/query-solution.property-config.d.ts +60 -0
  186. package/types/query-solution/src/solutions.d.ts +108 -509
  187. package/types/response-layout-editor/index.d.ts +3 -1
  188. package/types/response-toolbar/src/designer/use-designer-rules.d.ts +3 -3
  189. package/types/response-toolbar/src/property-config/response-toolbar-item.property-config.d.ts +1 -0
  190. package/types/section/src/designer/use-designer-rules.d.ts +3 -3
  191. package/types/splitter/src/components/splitter-pane.component.d.ts +1 -1
  192. package/types/splitter/src/designer/splitter-pane-use-designer-rules.d.ts +3 -3
  193. package/types/splitter/src/designer/splitter-use-designer-rules.d.ts +3 -3
  194. package/types/tabs/src/designer/tab-page-use-designer-rules.d.ts +3 -3
  195. package/types/tabs/src/designer/tab-use-designer-rules.d.ts +3 -3
  196. package/types/tree-grid/index.d.ts +3 -3
  197. package/types/tree-grid/src/tree-grid.component.d.ts +1 -1
  198. package/types/designer-canvas/src/composition/rule/use-drag-drop-rules.d.ts +0 -19
  199. package/types/designer-canvas/src/composition/use-dragula-common-rule.d.ts +0 -4
  200. package/types/list-nav/src/composition/use-designer-rules.d.ts +0 -3
  201. package/types/query-solution/src/designer/query-solution-config/composition/mock-data.d.ts +0 -6
@@ -1,96 +1,95 @@
1
- var Q = Object.defineProperty;
2
- var Y = (e, t, n) => t in e ? Q(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
- var S = (e, t, n) => Y(e, typeof t != "symbol" ? t + "" : t, n);
4
- import { defineComponent as O, ref as g, computed as F, watch as M, createVNode as k, Teleport as Z, createApp as _, onUnmounted as K, inject as E, nextTick as A, onMounted as D, mergeProps as ee } from "vue";
5
- import { isPlainObject as j, cloneDeep as $ } from "lodash-es";
6
- import te from "../list-view/index.esm.js";
7
- import ne from "../button-edit/index.esm.js";
8
- import { resolveAppearance as oe, getSchemaByType as R } from "../dynamic-resolver/index.esm.js";
9
- import { useDesignerComponent as U } from "../designer-canvas/index.esm.js";
10
- import { useResponseLayoutEditorSetting as ie } from "../response-layout-editor/index.esm.js/src/composition/converter/use-response-layout-editor-setting";
11
- const ae = {}, le = {};
12
- function N(e) {
13
- const { properties: t, title: n, ignore: o } = e, i = o && Array.isArray(o), l = Object.keys(t).reduce((u, d) => ((!i || !o.find((c) => c == d)) && (u[d] = t[d].type === "object" && t[d].properties ? N(t[d]) : $(t[d].default)), u), {});
14
- return (!i || !o.find((u) => u == "id")) && (l.id = `${n}-${Date.now()}`), l;
1
+ var Y = Object.defineProperty;
2
+ var Z = (e, t, n) => t in e ? Y(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
+ var v = (e, t, n) => Z(e, typeof t != "symbol" ? t + "" : t, n);
4
+ import { defineComponent as E, ref as C, computed as k, watch as O, createVNode as F, Teleport as _, createApp as K, onUnmounted as ee, inject as T, nextTick as $, onMounted as G, mergeProps as te } from "vue";
5
+ import { isPlainObject as N, cloneDeep as R } from "lodash-es";
6
+ import ne from "../list-view/index.esm.js";
7
+ import oe from "../button-edit/index.esm.js";
8
+ import { resolveAppearance as ie } from "../dynamic-resolver/index.esm.js";
9
+ import { useDesignerComponent as W, DgControl as U } from "../designer-canvas/index.esm.js";
10
+ const le = {}, ae = {};
11
+ function q(e) {
12
+ const { properties: t, title: n, ignore: i } = e, l = i && Array.isArray(i), r = Object.keys(t).reduce((c, d) => ((!l || !i.find((p) => p == d)) && (c[d] = t[d].type === "object" && t[d].properties ? q(t[d]) : R(t[d].default)), c), {});
13
+ return n && (!l || !i.find((c) => c == "id")) && (r.id = `${n}-${Date.now()}`), r;
15
14
  }
16
15
  function re(e, t) {
17
- const n = N(t);
18
- return Object.keys(e).reduce((o, i) => (o[i] && j(o[i]) && j(e[i]) ? Object.assign(o[i], e[i]) : o[i] = e[i], o), n), n;
16
+ const n = q(t);
17
+ return Object.keys(e).reduce((i, l) => (i[l] && N(i[l]) && N(e[l]) ? Object.assign(i[l], e[l]) : i[l] = e[l], i), n), n;
19
18
  }
20
19
  function se(e, t) {
21
- return Object.keys(e).filter((o) => e[o] != null).reduce((o, i) => {
22
- if (t.has(i)) {
23
- const l = t.get(i);
24
- if (typeof l == "string")
25
- o[l] = e[i];
20
+ return Object.keys(e).filter((i) => e[i] != null).reduce((i, l) => {
21
+ if (t.has(l)) {
22
+ const r = t.get(l);
23
+ if (typeof r == "string")
24
+ i[r] = e[l];
26
25
  else {
27
- const u = l(i, e[i], e);
28
- Object.assign(o, u);
26
+ const c = r(l, e[l], e);
27
+ Object.assign(i, c);
29
28
  }
30
29
  } else
31
- o[i] = e[i];
32
- return o;
30
+ i[l] = e[l];
31
+ return i;
33
32
  }, {});
34
33
  }
35
34
  function ue(e, t, n = /* @__PURE__ */ new Map()) {
36
- const o = re(e, t);
37
- return se(o, n);
35
+ const i = re(e, t);
36
+ return se(i, n);
38
37
  }
39
38
  function ce(e = {}) {
40
- function t(r, p, a, s) {
41
- if (typeof a == "number")
42
- return s[r].length === a;
43
- if (typeof a == "object") {
44
- const y = Object.keys(a)[0], m = a[y];
45
- if (y === "not")
46
- return Number(s[r].length) !== Number(m);
47
- if (y === "moreThan")
48
- return Number(s[r].length) >= Number(m);
49
- if (y === "lessThan")
50
- return Number(s[r].length) <= Number(m);
39
+ function t(s, u, o, a) {
40
+ if (typeof o == "number")
41
+ return a[s].length === o;
42
+ if (typeof o == "object") {
43
+ const f = Object.keys(o)[0], m = o[f];
44
+ if (f === "not")
45
+ return Number(a[s].length) !== Number(m);
46
+ if (f === "moreThan")
47
+ return Number(a[s].length) >= Number(m);
48
+ if (f === "lessThan")
49
+ return Number(a[s].length) <= Number(m);
51
50
  }
52
51
  return !1;
53
52
  }
54
- function n(r, p, a, s) {
55
- return s[r] && s[r].propertyValue && String(s[r].propertyValue.value) === String(a);
53
+ function n(s, u, o, a) {
54
+ return a[s] && a[s].propertyValue && String(a[s].propertyValue.value) === String(o);
56
55
  }
57
- const o = /* @__PURE__ */ new Map([
56
+ const i = /* @__PURE__ */ new Map([
58
57
  ["length", t],
59
58
  ["getProperty", n]
60
59
  ]);
61
- Object.keys(e).reduce((r, p) => (r.set(p, e[p]), r), o);
62
- function i(r, p) {
63
- const a = r;
64
- return typeof p == "number" ? [{ target: a, operator: "length", param: null, value: Number(p) }] : typeof p == "boolean" ? [{ target: a, operator: "getProperty", param: r, value: !!p }] : typeof p == "object" ? Object.keys(p).map((s) => {
65
- if (s === "length")
66
- return { target: a, operator: "length", param: null, value: p[s] };
67
- const y = s, m = p[s];
68
- return { target: a, operator: "getProperty", param: y, value: m };
60
+ Object.keys(e).reduce((s, u) => (s.set(u, e[u]), s), i);
61
+ function l(s, u) {
62
+ const o = s;
63
+ return typeof u == "number" ? [{ target: o, operator: "length", param: null, value: Number(u) }] : typeof u == "boolean" ? [{ target: o, operator: "getProperty", param: s, value: !!u }] : typeof u == "object" ? Object.keys(u).map((a) => {
64
+ if (a === "length")
65
+ return { target: o, operator: "length", param: null, value: u[a] };
66
+ const f = a, m = u[a];
67
+ return { target: o, operator: "getProperty", param: f, value: m };
69
68
  }) : [];
70
69
  }
71
- function l(r) {
72
- return Object.keys(r).reduce((a, s) => {
73
- const y = i(s, r[s]);
74
- return a.push(...y), a;
70
+ function r(s) {
71
+ return Object.keys(s).reduce((o, a) => {
72
+ const f = l(a, s[a]);
73
+ return o.push(...f), o;
75
74
  }, []);
76
75
  }
77
- function u(r, p) {
78
- if (o.has(r.operator)) {
79
- const a = o.get(r.operator);
80
- return a && a(r.target, r.param, r.value, p) || !1;
76
+ function c(s, u) {
77
+ if (i.has(s.operator)) {
78
+ const o = i.get(s.operator);
79
+ return o && o(s.target, s.param, s.value, u) || !1;
81
80
  }
82
81
  return !1;
83
82
  }
84
- function d(r, p) {
85
- return l(r).reduce((y, m) => y && u(m, p), !0);
83
+ function d(s, u) {
84
+ return r(s).reduce((f, m) => f && c(m, u), !0);
86
85
  }
87
- function c(r, p) {
88
- const a = Object.keys(r), s = a.includes("allOf"), y = a.includes("anyOf"), m = s || y, h = (m ? r[m ? s ? "allOf" : "anyOf" : "allOf"] : [r]).map((x) => d(x, p));
89
- return s ? !h.includes(!1) : h.includes(!0);
86
+ function p(s, u) {
87
+ const o = Object.keys(s), a = o.includes("allOf"), f = o.includes("anyOf"), m = a || f, h = (m ? s[m ? a ? "allOf" : "anyOf" : "allOf"] : [s]).map((B) => d(B, u));
88
+ return a ? !h.includes(!1) : h.includes(!0);
90
89
  }
91
- return { parseValueSchema: c };
90
+ return { parseValueSchema: p };
92
91
  }
93
- const f = {
92
+ const g = {
94
93
  button: { type: "button", name: "按钮", icon: "Button" },
95
94
  "response-toolbar": { type: "response-toolbar", name: "工具栏", icon: "ButtonGroup" },
96
95
  "response-toolbar-item": { type: "response-toolbar-item", name: "按钮", icon: "Button" },
@@ -131,18 +130,18 @@ const f = {
131
130
  fieldset: { type: "fieldset", name: "分组", icon: "fieldset" }
132
131
  }, de = {}, pe = {};
133
132
  ce();
134
- function q(e, t, n = /* @__PURE__ */ new Map(), o = (u, d, c) => d, i = {}, l = (u) => u) {
135
- return ae[t.title] = t, le[t.title] = o, de[t.title] = i, pe[t.title] = l, (u = {}) => {
136
- const d = ue(u, t, n), c = Object.keys(e).reduce((r, p) => (r[p] = e[p].default, r), {});
137
- return Object.assign(c, d);
133
+ function H(e, t, n = /* @__PURE__ */ new Map(), i = (c, d, p) => d, l = {}, r = (c) => c) {
134
+ return le[t.title] = t, ae[t.title] = i, de[t.title] = l, pe[t.title] = r, (c = {}) => {
135
+ const d = ue(c, t, n), p = Object.keys(e).reduce((s, u) => (s[u] = e[u].default, s), {});
136
+ return Object.assign(p, d);
138
137
  };
139
138
  }
140
139
  function fe(e, t) {
141
140
  return { customClass: t.class, customStyle: t.style };
142
141
  }
143
- const ye = /* @__PURE__ */ new Map([
142
+ const me = /* @__PURE__ */ new Map([
144
143
  ["appearance", fe]
145
- ]), me = "https://json-schema.org/draft/2020-12/schema", ge = "https://farris-design.gitee.io/combo-list.schema.json", be = "combo-list", he = "A Farris Input Component", ve = "object", Ce = {
144
+ ]), ye = "https://json-schema.org/draft/2020-12/schema", ge = "https://farris-design.gitee.io/combo-list.schema.json", he = "combo-list", be = "A Farris Input Component", Ce = "object", ve = {
146
145
  id: {
147
146
  description: "The unique identifier for a combo list",
148
147
  type: "string"
@@ -261,25 +260,25 @@ const ye = /* @__PURE__ */ new Map([
261
260
  }, Se = [
262
261
  "id",
263
262
  "type"
264
- ], ke = [
263
+ ], Ie = [
265
264
  "id",
266
265
  "appearance",
267
266
  "binding"
268
267
  ], Fe = {
269
- $schema: me,
268
+ $schema: ye,
270
269
  $id: ge,
271
- title: be,
272
- description: he,
273
- type: ve,
274
- properties: Ce,
270
+ title: he,
271
+ description: be,
272
+ type: Ce,
273
+ properties: ve,
275
274
  required: Se,
276
- ignore: ke
275
+ ignore: Ie
277
276
  };
278
- function Be(e, t, n) {
277
+ function ke(e, t, n) {
279
278
  return t;
280
279
  }
281
- var xe = /* @__PURE__ */ ((e) => (e.Text = "text", e.Tag = "tag", e))(xe || {}), we = /* @__PURE__ */ ((e) => (e.top = "top", e.bottom = "bottom", e.auto = "auto", e))(we || {});
282
- const V = {
280
+ var Be = /* @__PURE__ */ ((e) => (e.Text = "text", e.Tag = "tag", e))(Be || {}), we = /* @__PURE__ */ ((e) => (e.top = "top", e.bottom = "bottom", e.auto = "auto", e))(we || {});
281
+ const j = {
283
282
  /**
284
283
  * 组件标识
285
284
  */
@@ -445,7 +444,7 @@ const V = {
445
444
  },
446
445
  // 搜索启用高亮
447
446
  enableHighlightSearch: { type: Boolean, default: !0 }
448
- }, H = q(V, Fe, ye, Be), Ie = {
447
+ }, z = H(j, Fe, me, ke), Me = {
449
448
  dataSource: { type: Array, default: [] },
450
449
  enableSearch: { type: Boolean, default: !1 },
451
450
  idField: { type: String, default: "id" },
@@ -466,196 +465,196 @@ const V = {
466
465
  },
467
466
  // 搜索启用高亮
468
467
  enableHighlightSearch: { type: Boolean, default: !0 }
469
- }, Me = /* @__PURE__ */ O({
468
+ }, xe = /* @__PURE__ */ E({
470
469
  name: "FComboListContainer",
471
- props: Ie,
470
+ props: Me,
472
471
  emits: ["selectionChange"],
473
472
  setup(e, t) {
474
- const n = g(), o = g(e.dataSource), i = g([]), l = g(e.separator), u = g(e.width), d = g(e.maxHeight), c = g(String(e.selectedValues).split(l.value)), r = F(() => e.multiSelect), p = F(() => ({
473
+ const n = C(), i = C(e.dataSource), l = C([]), r = C(e.separator), c = C(e.width), d = C(e.maxHeight), p = C(String(e.selectedValues).split(r.value)), s = k(() => e.multiSelect), u = k(() => ({
475
474
  enableSelectRow: !0,
476
475
  multiSelect: e.multiSelect,
477
476
  multiSelectMode: "OnCheckAndClick",
478
- showCheckbox: r.value,
477
+ showCheckbox: s.value,
479
478
  showSelectAll: !1,
480
479
  showSelection: !0
481
480
  }));
482
- M(e.dataSource, () => {
483
- o.value = e.dataSource;
481
+ O(e.dataSource, () => {
482
+ i.value = e.dataSource;
484
483
  });
485
- const a = F(() => e.enableSearch ? "SearchBar" : "ContentHeader"), s = F(() => {
486
- const b = {};
487
- return u.value !== void 0 && (b.width = `${u.value}px`), d.value !== void 0 && d.value > 0 && (b.maxHeight = `${d.value}px`), b;
484
+ const o = k(() => e.enableSearch ? "SearchBar" : "ContentHeader"), a = k(() => {
485
+ const y = {};
486
+ return c.value !== void 0 && (y.width = `${c.value}px`), d.value !== void 0 && d.value > 0 && (y.maxHeight = `${d.value}px`), y;
488
487
  });
489
- function y(b) {
490
- i.value = b.map((v) => Object.assign({}, v)), c.value = b.map((v) => v[e.idField]), t.emit("selectionChange", i.value);
488
+ function f(y) {
489
+ l.value = y.map((b) => Object.assign({}, b)), p.value = y.map((b) => b[e.idField]), t.emit("selectionChange", l.value);
491
490
  }
492
- function m(b) {
491
+ function m(y) {
493
492
  if (e.enableHighlightSearch)
494
493
  return;
495
- let v = [];
496
- typeof e.searchOption == "function" ? v = o.value.filter((h) => e.searchOption(b, h)) : v = o.value.filter((h) => h[e.valueField].indexOf(b) > -1 || h[e.textField].indexOf(b) > -1), n.value.updateDataSource(v);
494
+ let b = [];
495
+ typeof e.searchOption == "function" ? b = i.value.filter((h) => e.searchOption(y, h)) : b = i.value.filter((h) => h[e.valueField].indexOf(y) > -1 || h[e.textField].indexOf(y) > -1), n.value.updateDataSource(b);
497
496
  }
498
- return M([() => e.selectedValues], ([b]) => {
499
- c.value = b.split(l.value);
500
- }), () => k("div", {
497
+ return O([() => e.selectedValues], ([y]) => {
498
+ p.value = y.split(r.value);
499
+ }), () => F("div", {
501
500
  class: "f-combo-list-container pl-1",
502
- style: s.value
503
- }, [k(te, {
501
+ style: a.value
502
+ }, [F(ne, {
504
503
  ref: n,
505
504
  size: "small",
506
505
  itemClass: "f-combo-list-item",
507
- header: a.value,
506
+ header: o.value,
508
507
  headerClass: "f-combo-list-search-box",
509
- data: o.value,
508
+ data: i.value,
510
509
  idField: e.idField,
511
510
  textField: e.textField,
512
511
  titleField: e.titleField,
513
512
  multiSelect: e.multiSelect,
514
- selection: p.value,
513
+ selection: u.value,
515
514
  enableHighlightSearch: e.enableHighlightSearch,
516
- selectionValues: c.value,
517
- onSelectionChange: y,
515
+ selectionValues: p.value,
516
+ onSelectionChange: f,
518
517
  onAfterSearch: m
519
518
  }, null)]);
520
519
  }
521
520
  });
522
521
  function Oe(e) {
523
- const t = g(""), n = g(e.modelValue), o = g(e.data || []), i = g(e.editable);
524
- function l(a) {
525
- const s = String(a).split(e.separator), y = s.map((v) => [v, !0]), m = new Map(y);
526
- return o.value.filter((v) => m.has(String(v[e.valueField]))).sort((v, h) => {
527
- const B = s.indexOf(v[e.valueField]), x = s.indexOf(h[e.valueField]);
528
- return B - x;
522
+ const t = C(""), n = C(e.modelValue), i = C(e.data || []), l = C(e.editable);
523
+ function r(o) {
524
+ const a = String(o).split(e.separator), f = a.map((b) => [b, !0]), m = new Map(f);
525
+ return i.value.filter((b) => m.has(String(b[e.valueField]))).sort((b, h) => {
526
+ const S = a.indexOf(b[e.valueField]), B = a.indexOf(h[e.valueField]);
527
+ return S - B;
529
528
  });
530
529
  }
531
- function u(a) {
532
- const s = l(a).map((y) => y[e.textField]).join(e.separator);
533
- t.value = i.value ? s || a : s;
530
+ function c(o) {
531
+ const a = r(o).map((f) => f[e.textField]).join(e.separator);
532
+ t.value = l.value ? a || o : a;
534
533
  }
535
- function d(a) {
536
- const s = a.split(e.separator).map((m) => [m, !0]), y = new Map(s);
537
- return o.value.filter((m) => y.has(m[e.textField]));
534
+ function d(o) {
535
+ const a = o.split(e.separator).map((m) => [m, !0]), f = new Map(a);
536
+ return i.value.filter((m) => f.has(m[e.textField]));
538
537
  }
539
- function c(a) {
540
- const s = {};
541
- return s[e.idField] = a, s[e.textField] = a, [s];
538
+ function p(o) {
539
+ const a = {};
540
+ return a[e.idField] = o, a[e.textField] = o, [a];
542
541
  }
543
- function r(a) {
544
- let s = d(a);
545
- const y = s && s.length > 0;
546
- return i.value && !y && (s = c(a)), s;
542
+ function s(o) {
543
+ let a = d(o);
544
+ const f = a && a.length > 0;
545
+ return l.value && !f && (a = p(o)), a;
547
546
  }
548
- function p() {
549
- const { url: a, method: s = "GET", headers: y = {}, body: m = null } = e.remote, b = s.toLowerCase() == "get" ? { method: s, headers: y } : { method: s, headers: y, body: m };
550
- let v = !1;
551
- fetch(a, b).then((h) => {
552
- var x, T;
547
+ function u() {
548
+ const { url: o, method: a = "GET", headers: f = {}, body: m = null } = e.remote, y = a.toLowerCase() == "get" ? { method: a, headers: f } : { method: a, headers: f, body: m };
549
+ let b = !1;
550
+ fetch(o, y).then((h) => {
551
+ var B, w;
553
552
  if (h.status === 200)
554
- return v = !!((T = (x = h.headers) == null ? void 0 : x.get("content-type")) != null && T.includes("application/json")), v ? h.text() : h.json();
553
+ return b = !!((w = (B = h.headers) == null ? void 0 : B.get("content-type")) != null && w.includes("application/json")), b ? h.text() : h.json();
555
554
  throw new Error(h.statusText);
556
555
  }).then((h) => {
557
- o.value = v ? JSON.parse(h) : h;
556
+ i.value = b ? JSON.parse(h) : h;
558
557
  }).catch((h) => {
559
558
  console.error(h);
560
559
  });
561
560
  }
562
- return e.remote && p(), M(() => e.data, () => {
563
- o.value = e.data;
564
- }), M([o], ([a]) => {
561
+ return e.remote && u(), O(() => e.data, () => {
562
+ i.value = e.data;
563
+ }), O([i], ([o]) => {
565
564
  if (e.modelValue != null) {
566
- const s = a.find((y) => y[e.valueField] === e.modelValue);
567
- s && (t.value = s[e.textField]);
565
+ const a = o.find((f) => f[e.valueField] === e.modelValue);
566
+ a && (t.value = a[e.textField]);
568
567
  }
569
- }), M(() => e.modelValue, (a) => {
570
- n.value = a, u(a);
571
- }), u(e.modelValue), { dataSource: o, displayText: t, editable: i, modelValue: n, getItemsByDisplayText: d, getItemsByValue: l, getSelectedItemsByDisplayText: r };
568
+ }), O(() => e.modelValue, (o) => {
569
+ n.value = o, c(o);
570
+ }), c(e.modelValue), { dataSource: i, displayText: t, editable: l, modelValue: n, getItemsByDisplayText: d, getItemsByValue: r, getSelectedItemsByDisplayText: s };
572
571
  }
573
- const P = /* @__PURE__ */ O({
572
+ const P = /* @__PURE__ */ E({
574
573
  name: "FComboList",
575
- props: V,
574
+ props: j,
576
575
  emits: ["clear", "update:modelValue", "change", "input"],
577
576
  setup(e, t) {
578
- const n = g(), o = g(e.disabled), i = g(e.enableClear), l = g(e.enableSearch), u = g(e.readonly), {
577
+ const n = C(), i = C(e.disabled), l = C(e.enableClear), r = C(e.enableSearch), c = C(e.readonly), {
579
578
  dataSource: d,
580
- displayText: c,
581
- editable: r,
582
- modelValue: p,
583
- getSelectedItemsByDisplayText: a
584
- } = Oe(e), s = F(() => e.multiSelect), y = F(() => n.value ? n.value.elementRef.getBoundingClientRect().width : 0);
579
+ displayText: p,
580
+ editable: s,
581
+ modelValue: u,
582
+ getSelectedItemsByDisplayText: o
583
+ } = Oe(e), a = k(() => e.multiSelect), f = k(() => n.value ? n.value.elementRef.getBoundingClientRect().width : 0);
585
584
  function m() {
586
- !s.value && n.value && n.value.hidePopup();
585
+ !a.value && n.value && n.value.hidePopup();
587
586
  }
588
- function b(C) {
589
- c.value = C.map((w) => w[e.textField]).join(e.separator), C.length === 1 ? p.value = C[0][e.valueField] : p.value = C.map((w) => w[e.valueField]).join(e.separator), t.emit("update:modelValue", p.value), t.emit("change", C, p.value), m();
587
+ function y(I) {
588
+ p.value = I.map((M) => M[e.textField]).join(e.separator), I.length === 1 ? u.value = I[0][e.valueField] : u.value = I.map((M) => M[e.valueField]).join(e.separator), t.emit("update:modelValue", u.value), t.emit("change", I, u.value), m();
590
589
  }
591
- function v() {
592
- u.value || n.value.togglePopup();
590
+ function b() {
591
+ c.value || n.value.togglePopup();
593
592
  }
594
- function h(C) {
595
- p.value = "", t.emit("update:modelValue", ""), t.emit("clear");
593
+ function h(I) {
594
+ u.value = "", t.emit("update:modelValue", ""), t.emit("clear");
596
595
  }
597
- function B(C) {
598
- const w = a(C);
599
- b(w);
596
+ function S(I) {
597
+ const M = o(I);
598
+ y(M);
600
599
  }
601
- function x() {
602
- return c.value;
600
+ function B() {
601
+ return p.value;
603
602
  }
604
- function T(C) {
605
- t.emit("input", C);
603
+ function w(I) {
604
+ t.emit("input", I);
606
605
  }
607
606
  return t.expose({
608
- getDisplayText: x
609
- }), M([() => e.disabled, () => e.editable, () => e.enableClear, () => e.enableSearch, () => e.readonly], ([C, w, z, J, X]) => {
610
- o.value = C, r.value = w, i.value = z, l.value = J, u.value = X;
611
- }), () => k(ne, {
607
+ getDisplayText: B
608
+ }), O([() => e.disabled, () => e.editable, () => e.enableClear, () => e.enableSearch, () => e.readonly], ([I, M, V, A, D]) => {
609
+ i.value = I, s.value = M, l.value = V, r.value = A, c.value = D;
610
+ }), () => F(oe, {
612
611
  ref: n,
613
612
  id: e.id,
614
- disable: o.value,
615
- readonly: u.value,
613
+ disable: i.value,
614
+ readonly: c.value,
616
615
  forcePlaceholder: e.forcePlaceholder,
617
- editable: r.value,
616
+ editable: s.value,
618
617
  buttonContent: e.dropDownIcon,
619
618
  placeholder: e.placeholder,
620
- enableClear: i.value,
619
+ enableClear: l.value,
621
620
  maxLength: e.maxLength,
622
621
  tabIndex: e.tabIndex,
623
622
  enableTitle: e.enableTitle,
624
623
  multiSelect: e.multiSelect,
625
624
  inputType: e.multiSelect ? e.viewType : "text",
626
- modelValue: c.value,
627
- "onUpdate:modelValue": (C) => c.value = C,
625
+ modelValue: p.value,
626
+ "onUpdate:modelValue": (I) => p.value = I,
628
627
  focusOnCreated: e.focusOnCreated,
629
628
  selectOnCreated: e.selectOnCreated,
630
629
  onClear: h,
631
- onClick: v,
632
- onChange: B,
633
- onInput: T,
630
+ onClick: b,
631
+ onChange: S,
632
+ onInput: w,
634
633
  beforeOpen: e.beforeOpen
635
634
  }, {
636
- default: () => [k(Me, {
635
+ default: () => [F(xe, {
637
636
  idField: e.idField,
638
637
  valueField: e.valueField,
639
638
  textField: e.textField,
640
639
  titleField: e.titleField,
641
640
  dataSource: d.value,
642
- selectedValues: p.value,
641
+ selectedValues: u.value,
643
642
  multiSelect: e.multiSelect,
644
- enableSearch: l.value,
643
+ enableSearch: r.value,
645
644
  maxHeight: e.maxHeight,
646
645
  enableHighlightSearch: e.enableHighlightSearch,
647
- width: e.fitEditor ? y.value : void 0,
648
- onSelectionChange: b
646
+ width: e.fitEditor ? f.value : void 0,
647
+ onSelectionChange: y
649
648
  }, null)]
650
649
  });
651
650
  }
652
- }), Te = /* @__PURE__ */ new Map([
653
- ["appearance", oe]
651
+ }), Ee = /* @__PURE__ */ new Map([
652
+ ["appearance", ie]
654
653
  ]);
655
- function Ee(e, t, n) {
654
+ function Te(e, t, n) {
656
655
  return t;
657
656
  }
658
- const Pe = "https://json-schema.org/draft/2020-12/schema", Le = "https://farris-design.gitee.io/button-edit.schema.json", Ve = "button-edit", Ae = "A Farris Input Component", je = "object", Re = {
657
+ const Pe = "https://json-schema.org/draft/2020-12/schema", Le = "https://farris-design.gitee.io/button-edit.schema.json", Ve = "button-edit", Ae = "A Farris Input Component", De = "object", je = {
659
658
  id: {
660
659
  description: "The unique identifier for a Input Group",
661
660
  type: "string"
@@ -839,18 +838,18 @@ const Pe = "https://json-schema.org/draft/2020-12/schema", Le = "https://farris-
839
838
  type: "string",
840
839
  default: ""
841
840
  }
842
- }, De = [
841
+ }, $e = [
843
842
  "id",
844
843
  "type"
845
- ], $e = {
844
+ ], Ne = {
846
845
  $schema: Pe,
847
846
  $id: Le,
848
847
  title: Ve,
849
848
  description: Ae,
850
- type: je,
851
- properties: Re,
852
- required: De
853
- }, Ue = "buttonEdit", Ne = "A Farris Component", qe = "object", He = {
849
+ type: De,
850
+ properties: je,
851
+ required: $e
852
+ }, Ue = "buttonEdit", Ge = "A Farris Component", Re = "object", We = {
854
853
  basic: {
855
854
  description: "Basic Infomation",
856
855
  title: "基本信息",
@@ -932,12 +931,12 @@ const Pe = "https://json-schema.org/draft/2020-12/schema", Le = "https://farris-
932
931
  }
933
932
  }
934
933
  }
935
- }, Ge = {
934
+ }, qe = {
936
935
  title: Ue,
937
- description: Ne,
938
- type: qe,
939
- categories: He
940
- }, G = {
936
+ description: Ge,
937
+ type: Re,
938
+ categories: We
939
+ }, X = {
941
940
  /**
942
941
  * 组件标识
943
942
  */
@@ -1046,282 +1045,282 @@ const Pe = "https://json-schema.org/draft/2020-12/schema", Le = "https://farris-
1046
1045
  /** 更新方式 blur | change */
1047
1046
  updateOn: { type: String, default: "change" }
1048
1047
  };
1049
- q(G, $e, Te, Ee, Ge);
1050
- const We = {
1048
+ H(X, Ne, Ee, Te, qe);
1049
+ const He = {
1051
1050
  popupContentPosition: { type: Object, default: { left: 0, top: 0 } },
1052
1051
  host: { type: Object },
1053
1052
  backgroundColor: { type: String, default: "" }
1054
- }, ze = /* @__PURE__ */ O({
1053
+ }, ze = /* @__PURE__ */ E({
1055
1054
  name: "FOverlay",
1056
- props: We,
1055
+ props: He,
1057
1056
  emits: ["click"],
1058
1057
  setup(e, t) {
1059
- const n = g(e.popupContentPosition), o = g(e.host), i = F(() => ({
1058
+ const n = C(e.popupContentPosition), i = C(e.host), l = k(() => ({
1060
1059
  backgroundColor: e.backgroundColor || "",
1061
1060
  pointerEvents: "auto"
1062
1061
  }));
1063
- function l(d) {
1062
+ function r(d) {
1064
1063
  t.emit("click"), d.preventDefault(), d.stopPropagation();
1065
1064
  }
1066
- F(() => {
1067
- const d = o.value;
1065
+ k(() => {
1066
+ const d = i.value;
1068
1067
  if (d) {
1069
- const c = d.getBoundingClientRect(), {
1070
- left: r,
1071
- top: p,
1072
- height: a
1073
- } = c;
1068
+ const p = d.getBoundingClientRect(), {
1069
+ left: s,
1070
+ top: u,
1071
+ height: o
1072
+ } = p;
1074
1073
  return {
1075
- left: r,
1076
- top: p + a
1074
+ left: s,
1075
+ top: u + o
1077
1076
  };
1078
1077
  }
1079
1078
  return n.value;
1080
1079
  });
1081
- const u = F(() => ({
1080
+ const c = k(() => ({
1082
1081
  // position: 'relative',
1083
1082
  // left: `${position.value.left}px`,
1084
1083
  // top: `${position.value.top}px`
1085
1084
  }));
1086
- return () => k(Z, {
1085
+ return () => F(_, {
1087
1086
  to: "body"
1088
1087
  }, {
1089
1088
  default: () => {
1090
- var d, c;
1091
- return [k("div", {
1089
+ var d, p;
1090
+ return [F("div", {
1092
1091
  class: "overlay-container",
1093
- onClick: (r) => l(r),
1094
- style: i.value
1095
- }, [k("div", {
1096
- style: u.value
1097
- }, [(c = (d = t.slots).default) == null ? void 0 : c.call(d)])])];
1092
+ onClick: (s) => r(s),
1093
+ style: l.value
1094
+ }, [F("div", {
1095
+ style: c.value
1096
+ }, [(p = (d = t.slots).default) == null ? void 0 : p.call(d)])])];
1098
1097
  }
1099
1098
  });
1100
1099
  }
1101
1100
  });
1102
- function Je(e) {
1101
+ function Xe(e) {
1103
1102
  if (e.content && e.content.render)
1104
1103
  return e.content.render;
1105
1104
  if (e.render && typeof e.render == "function")
1106
1105
  return e.render;
1107
1106
  }
1108
- function Xe(e) {
1107
+ function Je(e) {
1109
1108
  const t = document.createElement("div");
1110
1109
  t.style.display = "contents";
1111
1110
  let n;
1112
- const o = e.onClickCallback || (() => {
1113
- }), i = () => {
1114
- o(), n && n.unmount();
1111
+ const i = e.onClickCallback || (() => {
1112
+ }), l = () => {
1113
+ i(), n && n.unmount();
1115
1114
  };
1116
- return n = _({
1115
+ return n = K({
1117
1116
  setup() {
1118
- K(() => {
1117
+ ee(() => {
1119
1118
  document.body.removeChild(t);
1120
1119
  });
1121
- const l = Je(e);
1122
- return () => k(ze, {
1120
+ const r = Xe(e);
1121
+ return () => F(ze, {
1123
1122
  "popup-content-position": e.popupPosition,
1124
1123
  host: e.host,
1125
- onClick: i,
1124
+ onClick: l,
1126
1125
  backgroundColor: e.backgroundColor
1127
1126
  }, {
1128
- default: () => [l && l()]
1127
+ default: () => [r && r()]
1129
1128
  });
1130
1129
  }
1131
1130
  }), document.body.appendChild(t), n.mount(t), n;
1132
1131
  }
1133
1132
  class Qe {
1134
1133
  static show(t) {
1135
- return Xe(t);
1134
+ return Je(t);
1136
1135
  }
1137
1136
  }
1138
1137
  const Ye = Symbol("FModalService");
1139
- function W(e, t) {
1138
+ function J(e, t) {
1140
1139
  function n() {
1141
- const o = e.beforeOpen || e.beforeClickButton || null;
1142
- let i = Promise.resolve(!0);
1143
- if (o) {
1144
- const l = o(t.value);
1145
- if (typeof l > "u")
1146
- return i;
1147
- typeof l == "boolean" ? i = Promise.resolve(l) : i = l;
1140
+ const i = e.beforeOpen || e.beforeClickButton || null;
1141
+ let l = Promise.resolve(!0);
1142
+ if (i) {
1143
+ const r = i(t.value);
1144
+ if (typeof r > "u")
1145
+ return l;
1146
+ typeof r == "boolean" ? l = Promise.resolve(r) : l = r;
1148
1147
  }
1149
- return i;
1148
+ return l;
1150
1149
  }
1151
1150
  return { judgeCanOpen: n };
1152
1151
  }
1153
- function Ze(e, t, n, o, i) {
1154
- const l = g(e.buttonBehavior), u = g(e.popupOnInput), d = F(() => ({
1152
+ function Ze(e, t, n, i, l) {
1153
+ const r = C(e.buttonBehavior), c = C(e.popupOnInput), d = k(() => ({
1155
1154
  "input-group-append": !0,
1156
1155
  "append-force-show": e.showButtonWhenDisabled && (e.readonly || e.disable)
1157
- })), { judgeCanOpen: c } = W(e, i), r = F(() => e.showButtonWhenDisabled || (!e.editable || !e.readonly) && !e.disable), p = E(Ye, null), a = g();
1158
- async function s(b) {
1159
- if (await c() && r.value) {
1160
- const v = !!t.slots.default;
1161
- if (l.value === "Modal") {
1162
- const h = e.modalOptions, B = p == null ? void 0 : p.open({
1156
+ })), { judgeCanOpen: p } = J(e, l), s = k(() => e.showButtonWhenDisabled || (!e.editable || !e.readonly) && !e.disable), u = T(Ye, null), o = C();
1157
+ async function a(y) {
1158
+ if (await p() && s.value) {
1159
+ const b = !!t.slots.default;
1160
+ if (r.value === "Modal") {
1161
+ const h = e.modalOptions, S = u == null ? void 0 : u.open({
1163
1162
  ...h,
1164
1163
  render: () => t.slots.default && t.slots.default()
1165
1164
  });
1166
- a.value = B == null ? void 0 : B.modalRef;
1165
+ o.value = S == null ? void 0 : S.modalRef;
1167
1166
  }
1168
- l.value === "Overlay" && Qe.show({
1167
+ r.value === "Overlay" && Qe.show({
1169
1168
  // host: buttonEditRef.value,
1170
1169
  host: document.body,
1171
1170
  backgroundColor: "rgba(0,0,0,.15)",
1172
1171
  render: () => t.slots.default && t.slots.default()
1173
- }), v && l.value === "Popup" && o.togglePopup(!0), v && u.value && o.hidePopup(), t.emit("clickButton", { origin: b, value: e.modelValue });
1172
+ }), b && r.value === "Popup" && i.togglePopup(!0), b && c.value && i.hidePopup(), t.emit("clickButton", { origin: y, value: e.modelValue });
1174
1173
  }
1175
1174
  }
1176
- function y(b) {
1177
- t.emit("mouseEnterIcon", b);
1175
+ function f(y) {
1176
+ t.emit("mouseEnterIcon", y);
1178
1177
  }
1179
- function m(b) {
1180
- t.emit("mouseLeaveIcon", b);
1178
+ function m(y) {
1179
+ t.emit("mouseLeaveIcon", y);
1181
1180
  }
1182
1181
  return {
1183
1182
  buttonGroupClass: d,
1184
- onClickButton: s,
1185
- onMouseEnterButton: y,
1183
+ onClickButton: a,
1184
+ onMouseEnterButton: f,
1186
1185
  onMouseLeaveButton: m,
1187
- modalRef: a
1186
+ modalRef: o
1188
1187
  };
1189
1188
  }
1190
- function _e(e, t, n, o) {
1191
- const i = g(), l = g(!1), { judgeCanOpen: u } = W(e, o);
1189
+ function _e(e, t, n, i) {
1190
+ const l = C(), r = C(!1), { judgeCanOpen: c } = J(e, i);
1192
1191
  function d() {
1193
- const a = i.value;
1194
- a && a.show(n.value);
1192
+ const o = l.value;
1193
+ o && o.show(n.value);
1195
1194
  }
1196
- async function c(a = !1) {
1195
+ async function p(o = !1) {
1197
1196
  if (!!t.slots.default) {
1198
- if (!a && !l.value && !await u())
1197
+ if (!o && !r.value && !await c())
1199
1198
  return;
1200
- l.value = !l.value, await A(), d();
1199
+ r.value = !r.value, await $(), d();
1201
1200
  }
1202
1201
  }
1203
- async function r(a = !1) {
1202
+ async function s(o = !1) {
1204
1203
  if (!!t.slots.default) {
1205
- if (!a && !await u())
1204
+ if (!o && !await c())
1206
1205
  return;
1207
- l.value = !0, await A(), d();
1206
+ r.value = !0, await $(), d();
1208
1207
  }
1209
1208
  }
1210
- function p() {
1211
- l.value = !1;
1209
+ function u() {
1210
+ r.value = !1;
1212
1211
  }
1213
- return { hidePopup: p, popup: r, shouldPopupContent: l, togglePopup: c, popoverRef: i };
1212
+ return { hidePopup: u, popup: s, shouldPopupContent: r, togglePopup: p, popoverRef: l };
1214
1213
  }
1215
1214
  function Ke(e, t, n) {
1216
1215
  const {
1217
- buttonGroupClass: o
1218
- } = n, i = g();
1216
+ buttonGroupClass: i
1217
+ } = n, l = C();
1219
1218
  return {
1220
- renderButtonGroup: () => k("div", {
1219
+ renderButtonGroup: () => F("div", {
1221
1220
  id: `${e.id}-button-group`,
1222
- class: o.value
1223
- }, [t.slots.buttonContent ? k("span", {
1221
+ class: i.value
1222
+ }, [t.slots.buttonContent ? F("span", {
1224
1223
  class: "input-group-text input-group-append-button"
1225
- }, [t.slots.buttonContent()]) : e.buttonContent ? k("span", {
1224
+ }, [t.slots.buttonContent()]) : e.buttonContent ? F("span", {
1226
1225
  class: "input-group-text input-group-append-button",
1227
1226
  innerHTML: e.buttonContent,
1228
- ref: i
1227
+ ref: l
1229
1228
  }, null) : null]),
1230
- buttonHandleElement: i
1229
+ buttonHandleElement: l
1231
1230
  };
1232
1231
  }
1233
- const et = /* @__PURE__ */ O({
1232
+ const et = /* @__PURE__ */ E({
1234
1233
  name: "FButtonEdit",
1235
- props: G,
1234
+ props: X,
1236
1235
  emits: ["updateExtendInfo", "clear", "change", "click", "clickButton", "blur", "focus", "mouseEnterIcon", "mouseLeaveIcon", "keyup", "keydown", "inputClick", "input", "update:modelValue"],
1237
1236
  setup(e, t) {
1238
- const n = g(), o = E("design-item-context"), i = U(n, o), l = g(e.customClass), u = g(e.modelValue), d = _e(e, t, n, u), c = Ze(e, t, n, d, u), r = g(), p = F(() => ({
1237
+ const n = C(), i = T("design-item-context"), l = W(n, i), r = C(e.customClass), c = C(e.modelValue), d = _e(e, t, n, c), p = Ze(e, t, n, d, c), s = C(), u = k(() => ({
1239
1238
  "f-cmp-inputgroup": !0,
1240
1239
  "input-group": !0,
1241
1240
  "f-state-disable": !0,
1242
1241
  "f-state-editable": !1,
1243
1242
  "f-state-readonly": !0
1244
1243
  }));
1245
- D(() => {
1246
- n.value.componentInstance = i;
1247
- }), t.expose(i.value);
1248
- const a = F(() => {
1249
- const y = {
1244
+ G(() => {
1245
+ n.value.componentInstance = l;
1246
+ }), t.expose(l.value);
1247
+ const o = k(() => {
1248
+ const f = {
1250
1249
  "f-button-edit": !0,
1251
1250
  "f-cmp-inputgroup": !0,
1252
1251
  "f-button-edit-nowrap": !e.wrapText
1253
1252
  };
1254
- return l.value && l.value.split(" ").reduce((m, b) => (m[b] = !0, m), y), y;
1253
+ return r.value && r.value.split(" ").reduce((m, y) => (m[y] = !0, m), f), f;
1255
1254
  }), {
1256
- renderButtonGroup: s
1257
- } = Ke(e, t, c);
1258
- return () => k("div", ee(t.attrs, {
1255
+ renderButtonGroup: a
1256
+ } = Ke(e, t, p);
1257
+ return () => F("div", te(t.attrs, {
1259
1258
  ref: n,
1260
- class: a.value,
1259
+ class: o.value,
1261
1260
  id: e.id
1262
- }), [k("div", {
1263
- class: p.value
1264
- }, [k("input", {
1265
- ref: r,
1261
+ }), [F("div", {
1262
+ class: u.value
1263
+ }, [F("input", {
1264
+ ref: s,
1266
1265
  class: "form-control",
1267
1266
  readonly: !0,
1268
1267
  placeholder: e.placeholder
1269
- }, null), s()])]);
1268
+ }, null), a()])]);
1270
1269
  }
1271
1270
  });
1272
1271
  function tt(e, t) {
1273
1272
  e.schema;
1274
- const n = g(!0), o = g(!0);
1275
- function i(a) {
1273
+ const n = C(!0), i = C(!0);
1274
+ function l(o) {
1276
1275
  return !1;
1277
1276
  }
1278
- function l() {
1277
+ function r() {
1279
1278
  return !1;
1280
1279
  }
1281
- function u() {
1280
+ function c() {
1282
1281
  return !1;
1283
1282
  }
1284
1283
  function d() {
1285
1284
  return !0;
1286
1285
  }
1287
- function c(a) {
1286
+ function p(o) {
1288
1287
  }
1289
- function r() {
1288
+ function s() {
1290
1289
  }
1291
- function p(a) {
1290
+ function u(o) {
1292
1291
  return null;
1293
1292
  }
1294
1293
  return {
1295
- canAccepts: i,
1296
- checkCanDeleteComponent: l,
1297
- checkCanMoveComponent: u,
1294
+ canAccepts: l,
1295
+ checkCanDeleteComponent: r,
1296
+ checkCanMoveComponent: c,
1298
1297
  hideNestedPaddingInDesginerView: d,
1299
- onAcceptMovedChildElement: c,
1300
- resolveComponentContext: r,
1298
+ onAcceptMovedChildElement: p,
1299
+ resolveComponentContext: s,
1301
1300
  triggerBelongedComponentToMoveWhenMoved: n,
1302
- triggerBelongedComponentToDeleteWhenDeleted: o,
1303
- getPropsConfig: p
1301
+ triggerBelongedComponentToDeleteWhenDeleted: i,
1302
+ getPropsConfig: u
1304
1303
  };
1305
1304
  }
1306
1305
  class nt {
1307
1306
  constructor(t, n) {
1308
- S(this, "componentId");
1309
- S(this, "viewModelId");
1310
- S(this, "eventsEditorUtils");
1311
- S(this, "formSchemaUtils");
1312
- S(this, "formMetadataConverter");
1313
- S(this, "designViewModelUtils");
1314
- S(this, "designViewModelField");
1315
- S(this, "controlCreatorUtils");
1316
- S(this, "designerHostService");
1317
- S(this, "schemaService", null);
1318
- S(this, "metadataService", null);
1319
- S(this, "propertyConfig", {
1307
+ v(this, "componentId");
1308
+ v(this, "viewModelId");
1309
+ v(this, "eventsEditorUtils");
1310
+ v(this, "formSchemaUtils");
1311
+ v(this, "formMetadataConverter");
1312
+ v(this, "designViewModelUtils");
1313
+ v(this, "designViewModelField");
1314
+ v(this, "controlCreatorUtils");
1315
+ v(this, "designerHostService");
1316
+ v(this, "schemaService", null);
1317
+ v(this, "metadataService", null);
1318
+ v(this, "propertyConfig", {
1320
1319
  type: "object",
1321
1320
  categories: {}
1322
1321
  });
1323
- var o;
1324
- this.componentId = t, this.designerHostService = n, this.eventsEditorUtils = n.eventsEditorUtils, this.formSchemaUtils = n.formSchemaUtils, this.formMetadataConverter = n.formMetadataConverter, this.viewModelId = ((o = this.formSchemaUtils) == null ? void 0 : o.getViewModelIdByComponentId(t)) || "", this.designViewModelUtils = n.designViewModelUtils, this.controlCreatorUtils = n.controlCreatorUtils, this.metadataService = n.metadataService, this.schemaService = n.schemaService;
1322
+ var i;
1323
+ this.componentId = t, this.designerHostService = n, this.eventsEditorUtils = n.eventsEditorUtils, this.formSchemaUtils = n.formSchemaUtils, this.formMetadataConverter = n.formMetadataConverter, this.viewModelId = ((i = this.formSchemaUtils) == null ? void 0 : i.getViewModelIdByComponentId(t)) || "", this.designViewModelUtils = n.designViewModelUtils, this.controlCreatorUtils = n.controlCreatorUtils, this.metadataService = n.metadataService, this.schemaService = n.schemaService;
1325
1324
  }
1326
1325
  getTableInfo() {
1327
1326
  var t;
@@ -1331,8 +1330,8 @@ class nt {
1331
1330
  const n = t.binding && t.binding.type === "Form" && t.binding.field;
1332
1331
  if (n) {
1333
1332
  if (!this.designViewModelField) {
1334
- const o = this.designViewModelUtils.getDgViewModel(this.viewModelId);
1335
- this.designViewModelField = o.fields.find((i) => i.id === n);
1333
+ const i = this.designViewModelUtils.getDgViewModel(this.viewModelId);
1334
+ this.designViewModelField = i.fields.find((l) => l.id === n);
1336
1335
  }
1337
1336
  t.updateOn = this.designViewModelField.updateOn;
1338
1337
  }
@@ -1358,7 +1357,7 @@ class nt {
1358
1357
  type: "combo-list",
1359
1358
  textField: "name",
1360
1359
  valueField: "value",
1361
- data: [{ value: t.type, name: f[t.type].name }]
1360
+ data: [{ value: t.type, name: g[t.type].name }]
1362
1361
  }
1363
1362
  }
1364
1363
  }
@@ -1391,19 +1390,19 @@ class nt {
1391
1390
  * @returns
1392
1391
  */
1393
1392
  updateElementByParentContainer(t, n) {
1394
- const o = n && n.parent && n.parent.schema;
1395
- if (!o)
1393
+ const i = n && n.parent && n.parent.schema;
1394
+ if (!i)
1396
1395
  return;
1397
- const i = o.contents.findIndex((u) => u.id === t), l = $(o.contents[i]);
1398
- o.contents.splice(i, 1), o.contents.splice(i, 0, l);
1396
+ const l = i.contents.findIndex((c) => c.id === t), r = R(i.contents[l]);
1397
+ i.contents.splice(l, 1), i.contents.splice(l, 0, r);
1399
1398
  }
1400
1399
  }
1401
- const I = class I {
1400
+ const x = class x {
1402
1401
  /**
1403
1402
  * 根据绑定字段类型获取可用的输入类控件
1404
1403
  */
1405
1404
  static getEditorTypesByMDataType(t) {
1406
- const n = I.fieldControlTypeMapping[t];
1405
+ const n = x.fieldControlTypeMapping[t];
1407
1406
  return n || [{ key: "", value: "" }];
1408
1407
  }
1409
1408
  /**
@@ -1411,9 +1410,9 @@ const I = class I {
1411
1410
  */
1412
1411
  static getAllInputTypes() {
1413
1412
  const t = [];
1414
- for (let n in I.fieldControlTypeMapping)
1415
- I.fieldControlTypeMapping[n].forEach((o) => {
1416
- t.find((i) => i.key === o.key && i.value === o.value) || t.push({ key: o.key, value: o.value });
1413
+ for (let n in x.fieldControlTypeMapping)
1414
+ x.fieldControlTypeMapping[n].forEach((i) => {
1415
+ t.find((l) => l.key === i.key && l.value === i.value) || t.push({ key: i.key, value: i.value });
1417
1416
  });
1418
1417
  return t;
1419
1418
  }
@@ -1421,68 +1420,175 @@ const I = class I {
1421
1420
  /**
1422
1421
  * <字段类型,可配置的控件类型列表>的映射
1423
1422
  */
1424
- S(I, "fieldControlTypeMapping", {
1423
+ v(x, "fieldControlTypeMapping", {
1425
1424
  String: [
1426
- { key: f["input-group"].type, value: f["input-group"].name },
1427
- { key: f.lookup.type, value: f.lookup.name },
1428
- { key: f["date-picker"].type, value: f["date-picker"].name },
1429
- { key: f["check-box"].type, value: f["check-box"].name },
1430
- { key: f["radio-group"].type, value: f["radio-group"].name },
1431
- { key: f["combo-list"].type, value: f["combo-list"].name },
1432
- { key: f.textarea.type, value: f.textarea.name }
1425
+ { key: g["input-group"].type, value: g["input-group"].name },
1426
+ { key: g.lookup.type, value: g.lookup.name },
1427
+ { key: g["date-picker"].type, value: g["date-picker"].name },
1428
+ { key: g["check-box"].type, value: g["check-box"].name },
1429
+ { key: g["check-group"].type, value: g["check-group"].name },
1430
+ { key: g["radio-group"].type, value: g["radio-group"].name },
1431
+ { key: g["combo-list"].type, value: g["combo-list"].name },
1432
+ { key: g.textarea.type, value: g.textarea.name }
1433
1433
  ],
1434
1434
  Text: [
1435
- { key: f.textarea.type, value: f.textarea.name },
1436
- { key: f.lookup.type, value: f.lookup.name }
1435
+ { key: g.textarea.type, value: g.textarea.name },
1436
+ { key: g.lookup.type, value: g.lookup.name }
1437
1437
  ],
1438
1438
  Decimal: [
1439
- { key: f["number-spinner"].type, value: f["number-spinner"].name }
1439
+ { key: g["number-spinner"].type, value: g["number-spinner"].name }
1440
1440
  ],
1441
1441
  Integer: [
1442
- { key: f["number-spinner"].type, value: f["number-spinner"].name }
1442
+ { key: g["number-spinner"].type, value: g["number-spinner"].name }
1443
1443
  ],
1444
1444
  Number: [
1445
- { key: f["number-spinner"].type, value: f["number-spinner"].name }
1445
+ { key: g["number-spinner"].type, value: g["number-spinner"].name }
1446
1446
  ],
1447
1447
  BigNumber: [
1448
- { key: f["number-spinner"].type, value: f["number-spinner"].name }
1448
+ { key: g["number-spinner"].type, value: g["number-spinner"].name }
1449
1449
  ],
1450
1450
  Date: [
1451
- { key: f["date-picker"].type, value: f["date-picker"].name }
1451
+ { key: g["date-picker"].type, value: g["date-picker"].name }
1452
1452
  ],
1453
1453
  DateTime: [
1454
- { key: f["date-picker"].type, value: f["date-picker"].name }
1454
+ { key: g["date-picker"].type, value: g["date-picker"].name }
1455
1455
  ],
1456
1456
  Boolean: [
1457
- { key: f.switch.type, value: f.switch.name },
1458
- { key: f["check-box"].type, value: f["check-box"].name }
1457
+ { key: g.switch.type, value: g.switch.name },
1458
+ { key: g["check-box"].type, value: g["check-box"].name }
1459
1459
  ],
1460
1460
  Enum: [
1461
- { key: f["combo-list"].type, value: f["combo-list"].name },
1462
- { key: f["radio-group"].type, value: f["radio-group"].name }
1461
+ { key: g["combo-list"].type, value: g["combo-list"].name },
1462
+ { key: g["radio-group"].type, value: g["radio-group"].name }
1463
1463
  ],
1464
1464
  Object: [
1465
- { key: f.lookup.type, value: f.lookup.name },
1466
- { key: f["combo-list"].type, value: f["combo-list"].name },
1467
- { key: f["radio-group"].type, value: f["radio-group"].name }
1465
+ { key: g.lookup.type, value: g.lookup.name },
1466
+ { key: g["combo-list"].type, value: g["combo-list"].name },
1467
+ { key: g["radio-group"].type, value: g["radio-group"].name }
1468
1468
  ]
1469
1469
  });
1470
- let L = I;
1471
- const ot = g(0);
1472
- class it extends nt {
1473
- constructor(n, o) {
1474
- super(n, o);
1475
- S(this, "responseLayoutEditorFunction");
1476
- this.responseLayoutEditorFunction = ie(this.formSchemaUtils);
1477
- }
1478
- getPropertyConfig(n, o) {
1479
- return this.propertyConfig.categories.basic = this.getBasicProperties(n, o), this.propertyConfig.categories.appearance = this.getAppearanceProperties(n, o), this.propertyConfig.categories.editor = this.getEditorProperties(n), this.propertyConfig;
1480
- }
1481
- getBasicProperties(n, o) {
1470
+ let L = x;
1471
+ const ot = C(0);
1472
+ class it {
1473
+ constructor() {
1474
+ /** 控件标题 */
1475
+ v(this, "label", "");
1476
+ /** 控件id */
1477
+ v(this, "id", "");
1478
+ /** 每个控件占用的栅格数 */
1479
+ v(this, "columnInSM", 12);
1480
+ v(this, "columnInMD", 6);
1481
+ v(this, "columnInLG", 3);
1482
+ v(this, "columnInEL", 2);
1483
+ /** 每个控件占用的列数 */
1484
+ v(this, "displayWidthInSM", 1);
1485
+ v(this, "displayWidthInMD", 1);
1486
+ v(this, "displayWidthInLG", 1);
1487
+ v(this, "displayWidthInEL", 1);
1488
+ /** 编辑器内部默认显示的屏幕大小-----可以去掉 */
1489
+ v(this, "displayColumnCountAtBreakPoint", "md");
1490
+ /** 控件所在行,传0即可-----编辑器内部使用 */
1491
+ v(this, "tagRow", 0);
1492
+ /** 控件是否显示上方空白:传0即可-----编辑器内部使用 */
1493
+ v(this, "showTopBorder", 0);
1494
+ /** 区域,从1开始。卡片内的控件从上往下,从左往右划分区域,遇到分组fieldSet时group+1,分组结束后group+1 */
1495
+ v(this, "group", 1);
1496
+ /** 控件是否符合标准的class配置(设计器用的) */
1497
+ v(this, "isSupportedClass", !0);
1498
+ /** 控件所在分组id(设计器用的) */
1499
+ v(this, "fieldSetId", "");
1500
+ }
1501
+ }
1502
+ function lt(e) {
1503
+ let t, n;
1504
+ const i = /* @__PURE__ */ new Map();
1505
+ let l = [];
1506
+ function r(u, o) {
1507
+ const f = u.split(" ").filter((S) => S.startsWith("col-"));
1508
+ if (f.length === 0) {
1509
+ o.isSupportedClass = !1;
1510
+ return;
1511
+ }
1512
+ let m = f.find((S) => /^col-([1-9]|10|11|12)$/.test(S)), y = f.find((S) => /^col-md-([1-9]|10|11|12)$/.test(S)), b = f.find((S) => /^col-xl-([1-9]|10|11|12)$/.test(S)), h = f.find((S) => /^col-el-([1-9]|10|11|12)$/.test(S));
1513
+ m = m || "col-12", o.columnInSM = parseInt(m.replace("col-", ""), 10), o.displayWidthInSM = o.columnInSM / 12, o.displayWidthInSM !== 1 && (o.isSupportedClass = !1), y = y || "col-md-" + o.columnInSM, o.columnInMD = parseInt(y.replace("col-md-", ""), 10), o.displayWidthInMD = o.columnInMD / 6, [1, 2].includes(o.displayWidthInMD) || (o.isSupportedClass = !1), b = b || "col-xl-" + o.columnInMD, o.columnInLG = parseInt(b.replace("col-xl-", ""), 10), o.displayWidthInLG = o.columnInLG / 3, [1, 2, 3, 4].includes(o.displayWidthInLG) || (o.isSupportedClass = !1), h = h || "col-el-" + o.columnInLG, o.columnInEL = parseInt(h.replace("col-el-", ""), 10), o.displayWidthInEL = o.columnInEL / 2, [1, 2, 3, 4, 5, 6].includes(o.displayWidthInEL) || (o.isSupportedClass = !1);
1514
+ }
1515
+ function c(u, o, a, f = !1) {
1516
+ let m = !1;
1517
+ u.contents.forEach((y) => {
1518
+ if (y.type === "fieldset") {
1519
+ a += 1, c(y, o, a, !0), m = !0;
1520
+ return;
1521
+ }
1522
+ m && (a += 1, m = !1);
1523
+ const b = y.appearance && y.appearance.class, h = new it();
1524
+ b ? r(b, h) : h.isSupportedClass = !1, h.label = y.label || y.id, h.id = y.id, h.group = a, f && (h.fieldSetId = u.id), n === y.id && (t = a), i.set(y.id, y), o.push(h);
1525
+ });
1526
+ }
1527
+ function d(u) {
1528
+ const o = e.getComponentById(u);
1529
+ if (!o || !o.componentType || !o.componentType.startsWith("form"))
1530
+ return { result: !1, message: "只可以在响应式表单组件中调整响应式布局配置" };
1531
+ const a = e.selectNode(o, (f) => f.type === U["response-form"].type);
1532
+ return !a || !a.contents || a.contents.length === 0 ? { result: !1, message: "Form区域内没有控件,请先添加控件" } : { result: !0, message: "", formNode: a };
1533
+ }
1534
+ function p(u, o) {
1535
+ o = o || u.id;
1536
+ const { result: a, message: f, formNode: m } = d(o);
1537
+ if (!a)
1538
+ return { result: a, message: f };
1539
+ n = u.id, l = [], i.clear();
1540
+ const y = m.contents[0].type === U.fieldset.type ? 0 : 1;
1541
+ c(m, l, y);
1542
+ const b = l.find((S) => !S.isSupportedClass);
1543
+ return {
1544
+ defaultState: {
1545
+ defaultGroupNumber: t || 1,
1546
+ model: b ? "customize" : "standard"
1547
+ },
1548
+ importData: l
1549
+ };
1550
+ }
1551
+ function s(u, o) {
1552
+ o = o;
1553
+ const { result: a, formNode: f } = d(o);
1554
+ if (!a)
1555
+ return "";
1556
+ const m = [];
1557
+ return u.forEach((y) => {
1558
+ var S;
1559
+ const b = i.get(y.id), h = b.appearance && b.appearance.class;
1560
+ if (h) {
1561
+ const w = h.split(" ").filter((Q) => !Q.startsWith("col-")), I = "col-" + y.columnInSM, M = "col-md-" + y.columnInMD, V = "col-xl-" + y.columnInLG, A = "col-el-" + y.columnInEL, D = [I, M, V, A].concat(w);
1562
+ b.appearance.class = D.join(" ");
1563
+ }
1564
+ if (y.fieldSetId) {
1565
+ const B = f.contents.find((I) => I.id === y.fieldSetId), w = m.find((I) => I.id === y.fieldSetId);
1566
+ w ? (S = w.contents) == null || S.push(b) : (m.push(B), B.contents = [b]);
1567
+ } else
1568
+ m.push(b);
1569
+ }), f.contents = m, f.id;
1570
+ }
1571
+ return {
1572
+ checkCanFindFormNode: d,
1573
+ checkCanOpenLayoutEditor: p,
1574
+ changeFormControlsByResponseLayoutConfig: s,
1575
+ getResonseFormLayoutConfig: c
1576
+ };
1577
+ }
1578
+ class at extends nt {
1579
+ constructor(n, i) {
1580
+ super(n, i);
1581
+ v(this, "responseLayoutEditorFunction");
1582
+ this.responseLayoutEditorFunction = lt(this.formSchemaUtils);
1583
+ }
1584
+ getPropertyConfig(n, i) {
1585
+ return this.propertyConfig.categories.basic = this.getBasicProperties(n, i), this.propertyConfig.categories.appearance = this.getAppearanceProperties(n, i), this.propertyConfig.categories.editor = this.getEditorProperties(n), this.propertyConfig;
1586
+ }
1587
+ getBasicProperties(n, i) {
1482
1588
  var d;
1483
- var i = this;
1589
+ var l = this;
1484
1590
  this.setDesignViewModelField(n);
1485
- const l = this.formSchemaUtils.getFormMetadataBasicInfo(), u = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
1591
+ const r = this.formSchemaUtils.getFormMetadataBasicInfo(), c = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
1486
1592
  return {
1487
1593
  description: "Basic Information",
1488
1594
  title: "基本信息",
@@ -1504,7 +1610,7 @@ class it extends nt {
1504
1610
  textField: "value",
1505
1611
  valueField: "key",
1506
1612
  editable: !1,
1507
- data: i.designViewModelField ? L.getEditorTypesByMDataType((d = i.designViewModelField.type) == null ? void 0 : d.name) : L.getAllInputTypes()
1613
+ data: l.designViewModelField ? L.getEditorTypesByMDataType((d = l.designViewModelField.type) == null ? void 0 : d.name) : L.getAllInputTypes()
1508
1614
  }
1509
1615
  },
1510
1616
  label: {
@@ -1521,7 +1627,7 @@ class it extends nt {
1521
1627
  bindingType: { enable: !1 },
1522
1628
  editorParams: {
1523
1629
  propertyData: n,
1524
- formBasicInfo: l
1630
+ formBasicInfo: r
1525
1631
  },
1526
1632
  columns: [
1527
1633
  { field: "name", title: "字段名称" },
@@ -1529,27 +1635,27 @@ class it extends nt {
1529
1635
  { field: "fieldType", title: "字段类型" }
1530
1636
  ],
1531
1637
  textField: "bindingField",
1532
- data: u
1638
+ data: c
1533
1639
  }
1534
1640
  }
1535
1641
  },
1536
- setPropertyRelates(c, r) {
1537
- if (c)
1538
- switch (c && c.propertyID) {
1642
+ setPropertyRelates(p, s) {
1643
+ if (p)
1644
+ switch (p && p.propertyID) {
1539
1645
  case "type": {
1540
- i.changeControlType(n, c, o);
1646
+ l.changeControlType(n, p, i);
1541
1647
  break;
1542
1648
  }
1543
1649
  case "label": {
1544
- c.needRefreshControlTree = !0;
1650
+ p.needRefreshControlTree = !0;
1545
1651
  break;
1546
1652
  }
1547
1653
  }
1548
1654
  }
1549
1655
  };
1550
1656
  }
1551
- getAppearanceProperties(n, o) {
1552
- var i = this;
1657
+ getAppearanceProperties(n, i) {
1658
+ var l = this;
1553
1659
  return {
1554
1660
  title: "样式",
1555
1661
  description: "Appearance",
@@ -1575,18 +1681,18 @@ class it extends nt {
1575
1681
  refreshPanelAfterChanged: !0,
1576
1682
  editor: {
1577
1683
  type: "response-layout-editor-setting",
1578
- initialState: i.responseLayoutEditorFunction.checkCanOpenLayoutEditor(n, i.componentId)
1684
+ initialState: l.responseLayoutEditorFunction.checkCanOpenLayoutEditor(n, l.componentId)
1579
1685
  }
1580
1686
  }
1581
1687
  },
1582
- setPropertyRelates(l, u) {
1583
- if (l)
1584
- switch (l && l.propertyID) {
1688
+ setPropertyRelates(r, c) {
1689
+ if (r)
1690
+ switch (r && r.propertyID) {
1585
1691
  case "responseLayout":
1586
- i.responseLayoutEditorFunction.changeFormControlsByResponseLayoutConfig(l.propertyValue, i.componentId || n.id), i.updateUnifiedLayoutAfterResponseLayoutChanged(i.componentId), i.updateElementByParentContainer(n.id, o), delete n.responseLayout;
1692
+ l.responseLayoutEditorFunction.changeFormControlsByResponseLayoutConfig(r.propertyValue, l.componentId || n.id), l.updateUnifiedLayoutAfterResponseLayoutChanged(l.componentId), l.updateElementByParentContainer(n.id, i), delete n.responseLayout;
1587
1693
  break;
1588
1694
  case "class":
1589
- i.updateUnifiedLayoutAfterControlChanged(l.propertyValue, n.id, this.componentId), i.updateElementByParentContainer(n.id, o);
1695
+ l.updateUnifiedLayoutAfterControlChanged(r.propertyValue, n.id, this.componentId), l.updateElementByParentContainer(n.id, i);
1590
1696
  break;
1591
1697
  }
1592
1698
  }
@@ -1600,44 +1706,44 @@ class it extends nt {
1600
1706
  * @param propertyData 控件DOM属性
1601
1707
  * @param newControlType 新控件类型
1602
1708
  */
1603
- changeControlType(n, o, i) {
1604
- var p, a, s, y;
1605
- const l = o.propertyValue, u = i && i.parent && i.parent.schema;
1606
- if (!u)
1709
+ changeControlType(n, i, l) {
1710
+ var u, o, a, f;
1711
+ const r = i.propertyValue, c = l && l.parent && l.parent.schema;
1712
+ if (!c)
1607
1713
  return;
1608
- const d = u.contents.findIndex((m) => m.id === n.id), c = u.contents[d];
1609
- let r;
1714
+ const d = c.contents.findIndex((m) => m.id === n.id), p = c.contents[d];
1715
+ let s;
1610
1716
  this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
1611
1717
  editor: {
1612
- $type: l
1718
+ $type: r
1613
1719
  },
1614
1720
  name: this.designViewModelField.name,
1615
1721
  require: this.designViewModelField.require,
1616
1722
  readonly: this.designViewModelField.readonly
1617
- }, !1), r = this.controlCreatorUtils.setFormFieldProperty(this.designViewModelField, l)), r || (r = R("form-group") || {}, r.editor = R(l) || {}, delete r.editor.id, delete r.editor.binding, delete r.editor.appearance), Object.assign(r, {
1618
- id: c.id,
1619
- appearance: c.appearance,
1620
- size: c.size,
1621
- label: c.label,
1622
- binding: c.binding,
1623
- visible: c.visible
1624
- }), Object.assign(r.editor, {
1625
- isTextArea: r.isTextArea && c.isTextArea,
1626
- placeholder: (p = c.editor) == null ? void 0 : p.placeholder,
1627
- holdPlace: (a = c.editor) == null ? void 0 : a.holdPlace,
1628
- readonly: (s = c.editor) == null ? void 0 : s.readonly,
1629
- require: (y = c.editor) == null ? void 0 : y.require
1630
- }), u.contents.splice(d, 1), u.contents.splice(d, 0, r), i.schema = Object.assign(c, r), Array.from(document.getElementsByClassName("dgComponentSelected")).forEach(
1723
+ }, !1), s = this.controlCreatorUtils.setFormFieldProperty(this.designViewModelField, r)), s || (s = this.controlCreatorUtils.createFormGroupWithoutField(r)), Object.assign(s, {
1724
+ id: p.id,
1725
+ appearance: p.appearance,
1726
+ size: p.size,
1727
+ label: p.label,
1728
+ binding: p.binding,
1729
+ visible: p.visible
1730
+ }), Object.assign(s.editor, {
1731
+ isTextArea: s.isTextArea && p.isTextArea,
1732
+ placeholder: (u = p.editor) == null ? void 0 : u.placeholder,
1733
+ holdPlace: (o = p.editor) == null ? void 0 : o.holdPlace,
1734
+ readonly: (a = p.editor) == null ? void 0 : a.readonly,
1735
+ require: (f = p.editor) == null ? void 0 : f.require
1736
+ }), c.contents.splice(d, 1), c.contents.splice(d, 0, s), l.schema = Object.assign(p, s), Array.from(document.getElementsByClassName("dgComponentSelected")).forEach(
1631
1737
  (m) => m.classList.remove("dgComponentSelected")
1632
1738
  ), ot.value++;
1633
1739
  }
1634
- getComponentConfig(n, o = {}, i = {}) {
1635
- const l = Object.assign({
1740
+ getComponentConfig(n, i = {}, l = {}) {
1741
+ const r = Object.assign({
1636
1742
  description: "编辑器",
1637
1743
  title: "编辑器",
1638
1744
  type: "input-group",
1639
1745
  $converter: "/converter/property-editor.converter"
1640
- }, o), u = Object.assign({
1746
+ }, i), c = Object.assign({
1641
1747
  readonly: {
1642
1748
  description: "",
1643
1749
  title: "只读",
@@ -1658,8 +1764,8 @@ class it extends nt {
1658
1764
  title: "提示文本",
1659
1765
  type: "string"
1660
1766
  }
1661
- }, i);
1662
- return { ...l, properties: { ...u } };
1767
+ }, l);
1768
+ return { ...r, properties: { ...c } };
1663
1769
  }
1664
1770
  /**
1665
1771
  * 修改某一输入控件的样式后更新Form的统一布局配置
@@ -1667,50 +1773,50 @@ class it extends nt {
1667
1773
  * @param controlId 控件Id
1668
1774
  * @param componentId 控件所在组件id
1669
1775
  */
1670
- updateUnifiedLayoutAfterControlChanged(n, o, i) {
1671
- const l = n.split(" ");
1672
- let u = l.find((a) => /^col-([1-9]|10|11|12)$/.test(a)), d = l.find((a) => /^col-md-([1-9]|10|11|12)$/.test(a)), c = l.find((a) => /^col-xl-([1-9]|10|11|12)$/.test(a)), r = l.find((a) => /^col-el-([1-9]|10|11|12)$/.test(a));
1673
- u = u || "col-12", d = d || "col-md-" + u.replace("col-", ""), c = c || "col-xl-" + d.replace("col-md-", ""), r = r || "col-el-" + c.replace("col-xl-", "");
1674
- const p = {
1675
- id: o,
1676
- columnInSM: parseInt(u.replace("col-", ""), 10),
1776
+ updateUnifiedLayoutAfterControlChanged(n, i, l) {
1777
+ const r = n.split(" ");
1778
+ let c = r.find((o) => /^col-([1-9]|10|11|12)$/.test(o)), d = r.find((o) => /^col-md-([1-9]|10|11|12)$/.test(o)), p = r.find((o) => /^col-xl-([1-9]|10|11|12)$/.test(o)), s = r.find((o) => /^col-el-([1-9]|10|11|12)$/.test(o));
1779
+ c = c || "col-12", d = d || "col-md-" + c.replace("col-", ""), p = p || "col-xl-" + d.replace("col-md-", ""), s = s || "col-el-" + p.replace("col-xl-", "");
1780
+ const u = {
1781
+ id: i,
1782
+ columnInSM: parseInt(c.replace("col-", ""), 10),
1677
1783
  columnInMD: parseInt(d.replace("col-md-", ""), 10),
1678
- columnInLG: parseInt(c.replace("col-xl-", ""), 10),
1679
- columnInEL: parseInt(r.replace("col-el-", ""), 10)
1784
+ columnInLG: parseInt(p.replace("col-xl-", ""), 10),
1785
+ columnInEL: parseInt(s.replace("col-el-", ""), 10)
1680
1786
  };
1681
- this.updateUnifiedLayoutAfterResponseLayoutChanged(i, p);
1787
+ this.updateUnifiedLayoutAfterResponseLayoutChanged(l, u);
1682
1788
  }
1683
1789
  /**
1684
1790
  * 修改控件布局配置后更新Form统一布局配置
1685
1791
  * @param componentId 组件Id
1686
1792
  * @param controlLayoutConfig 某单独变动的控件配置项,FormResponseLayoutContext类型
1687
1793
  */
1688
- updateUnifiedLayoutAfterResponseLayoutChanged(n, o) {
1689
- const { formNode: i } = this.responseLayoutEditorFunction.checkCanFindFormNode(n);
1690
- if (!i || !i.unifiedLayout)
1794
+ updateUnifiedLayoutAfterResponseLayoutChanged(n, i) {
1795
+ const { formNode: l } = this.responseLayoutEditorFunction.checkCanFindFormNode(n);
1796
+ if (!l || !l.unifiedLayout)
1691
1797
  return;
1692
- const l = [];
1693
- if (this.responseLayoutEditorFunction.getResonseFormLayoutConfig(i, l, 1), o) {
1694
- const m = l.find((b) => b.id === o.id);
1695
- Object.assign(m || {}, o);
1798
+ const r = [];
1799
+ if (this.responseLayoutEditorFunction.getResonseFormLayoutConfig(l, r, 1), i) {
1800
+ const m = r.find((y) => y.id === i.id);
1801
+ Object.assign(m || {}, i);
1696
1802
  }
1697
- const u = l.map((m) => m.columnInSM), d = l.map((m) => m.columnInMD), c = l.map((m) => m.columnInLG), r = l.map((m) => m.columnInEL), p = this.checkIsUniqueColumn(u) ? u[0] : null, a = this.checkIsUniqueColumn(d) ? d[0] : null, s = this.checkIsUniqueColumn(c) ? c[0] : null, y = this.checkIsUniqueColumn(r) ? r[0] : null;
1698
- Object.assign(i.unifiedLayout, {
1699
- uniqueColClassInSM: p,
1700
- uniqueColClassInMD: a,
1701
- uniqueColClassInLG: s,
1702
- uniqueColClassInEL: y
1803
+ const c = r.map((m) => m.columnInSM), d = r.map((m) => m.columnInMD), p = r.map((m) => m.columnInLG), s = r.map((m) => m.columnInEL), u = this.checkIsUniqueColumn(c) ? c[0] : null, o = this.checkIsUniqueColumn(d) ? d[0] : null, a = this.checkIsUniqueColumn(p) ? p[0] : null, f = this.checkIsUniqueColumn(s) ? s[0] : null;
1804
+ Object.assign(l.unifiedLayout, {
1805
+ uniqueColClassInSM: u,
1806
+ uniqueColClassInMD: o,
1807
+ uniqueColClassInLG: a,
1808
+ uniqueColClassInEL: f
1703
1809
  });
1704
1810
  }
1705
1811
  /**
1706
1812
  * 校验宽度样式值是否一致
1707
1813
  */
1708
1814
  checkIsUniqueColumn(n) {
1709
- const o = new Set(n);
1710
- return Array.from(o).length === 1;
1815
+ const i = new Set(n);
1816
+ return Array.from(i).length === 1;
1711
1817
  }
1712
1818
  }
1713
- class at extends it {
1819
+ class rt extends at {
1714
1820
  constructor(t, n) {
1715
1821
  super(t, n);
1716
1822
  }
@@ -1734,41 +1840,41 @@ class at extends it {
1734
1840
  });
1735
1841
  }
1736
1842
  }
1737
- function lt(e, t) {
1843
+ function st(e, t) {
1738
1844
  const {
1739
1845
  canAccepts: n,
1740
- checkCanDeleteComponent: o,
1741
- checkCanMoveComponent: i,
1742
- hideNestedPaddingInDesginerView: l,
1743
- onAcceptMovedChildElement: u,
1846
+ checkCanDeleteComponent: i,
1847
+ checkCanMoveComponent: l,
1848
+ hideNestedPaddingInDesginerView: r,
1849
+ onAcceptMovedChildElement: c,
1744
1850
  resolveComponentContext: d,
1745
- triggerBelongedComponentToMoveWhenMoved: c,
1746
- triggerBelongedComponentToDeleteWhenDeleted: r
1747
- } = tt(e), p = e.schema;
1748
- function a(s, y) {
1749
- return new at(s, t).getPropertyConfig(p, y);
1851
+ triggerBelongedComponentToMoveWhenMoved: p,
1852
+ triggerBelongedComponentToDeleteWhenDeleted: s
1853
+ } = tt(e), u = e.schema;
1854
+ function o(a, f) {
1855
+ return new rt(a, t).getPropertyConfig(u, f);
1750
1856
  }
1751
1857
  return {
1752
1858
  canAccepts: n,
1753
- checkCanDeleteComponent: o,
1754
- checkCanMoveComponent: i,
1755
- hideNestedPaddingInDesginerView: l,
1756
- onAcceptMovedChildElement: u,
1859
+ checkCanDeleteComponent: i,
1860
+ checkCanMoveComponent: l,
1861
+ hideNestedPaddingInDesginerView: r,
1862
+ onAcceptMovedChildElement: c,
1757
1863
  resolveComponentContext: d,
1758
- triggerBelongedComponentToMoveWhenMoved: c,
1759
- triggerBelongedComponentToDeleteWhenDeleted: r,
1760
- getPropsConfig: a
1864
+ triggerBelongedComponentToMoveWhenMoved: p,
1865
+ triggerBelongedComponentToDeleteWhenDeleted: s,
1866
+ getPropsConfig: o
1761
1867
  };
1762
1868
  }
1763
- const rt = /* @__PURE__ */ O({
1869
+ const ut = /* @__PURE__ */ E({
1764
1870
  name: "FComboListDesign",
1765
- props: V,
1871
+ props: j,
1766
1872
  emits: ["clear", "update:modelValue", "change"],
1767
1873
  setup(e, t) {
1768
- const n = g(), o = E("designer-host-service"), i = E("design-item-context"), l = lt(i, o), u = U(n, i, l);
1769
- return D(() => {
1770
- n.value.componentInstance = u;
1771
- }), t.expose(u.value), () => k(et, {
1874
+ const n = C(), i = T("designer-host-service"), l = T("design-item-context"), r = st(l, i), c = W(n, l, r);
1875
+ return G(() => {
1876
+ n.value.componentInstance = c;
1877
+ }), t.expose(c.value), () => F(et, {
1772
1878
  ref: n,
1773
1879
  buttonContent: e.dropDownIcon,
1774
1880
  readonly: !0,
@@ -1778,24 +1884,24 @@ const rt = /* @__PURE__ */ O({
1778
1884
  enableClear: !0
1779
1885
  }, null);
1780
1886
  }
1781
- }), st = (e) => {
1887
+ }), ct = (e) => {
1782
1888
  const t = e;
1783
1889
  return t.install = function(n) {
1784
1890
  n.component(t.name, e);
1785
1891
  }, e;
1786
1892
  };
1787
- P.register = (e, t, n, o) => {
1788
- e["combo-list"] = P, t["combo-list"] = H;
1893
+ P.register = (e, t, n, i) => {
1894
+ e["combo-list"] = P, t["combo-list"] = z;
1789
1895
  };
1790
1896
  P.registerDesigner = (e, t, n) => {
1791
- e["combo-list"] = rt, t["combo-list"] = H;
1897
+ e["combo-list"] = ut, t["combo-list"] = z;
1792
1898
  };
1793
- const bt = st(P);
1899
+ const bt = ct(P);
1794
1900
  export {
1795
1901
  P as FComboList,
1796
1902
  we as Placement,
1797
- xe as ViewType,
1798
- V as comboListProps,
1903
+ Be as ViewType,
1904
+ j as comboListProps,
1799
1905
  bt as default,
1800
- H as propsResolver
1906
+ z as propsResolver
1801
1907
  };