@farris/ui-vue 1.2.6 → 1.2.8

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 (210) hide show
  1. package/components/accordion/index.esm.js +150 -142
  2. package/components/avatar/index.esm.js +393 -457
  3. package/components/border-editor/index.esm.js +4 -4
  4. package/components/button/index.esm.js +1 -1
  5. package/components/button-edit/index.esm.js +353 -444
  6. package/components/button-group/index.esm.js +5 -5
  7. package/components/calendar/index.esm.js +176 -176
  8. package/components/capsule/index.esm.js +93 -93
  9. package/components/checkbox/index.esm.js +491 -554
  10. package/components/color-picker/index.esm.js +1 -1
  11. package/components/combo-list/index.esm.js +479 -513
  12. package/components/combo-tree/index.esm.js +8 -8
  13. package/components/component/index.esm.js +89 -89
  14. package/components/condition/index.esm.js +857 -743
  15. package/components/content-container/index.esm.js +61 -61
  16. package/components/data-grid/index.esm.js +4883 -5182
  17. package/components/data-view/index.esm.js +3072 -2949
  18. package/components/date-picker/index.esm.js +2626 -2689
  19. package/components/dependent-base/style.js +1 -0
  20. package/components/dependent-fluid/style.js +1 -0
  21. package/components/dependent-icon/style.js +1 -0
  22. package/components/dependent-input/style.js +1 -0
  23. package/components/dependent-table/style.js +1 -0
  24. package/components/designer-canvas/index.esm.js +478 -475
  25. package/components/designer-outline/index.esm.js +173 -131
  26. package/components/discussion-editor/index.esm.js +1 -1
  27. package/components/dropdown/index.esm.js +73 -73
  28. package/components/dynamic-form/index.esm.js +940 -998
  29. package/components/dynamic-resolver/index.esm.js +67 -35
  30. package/components/dynamic-view/index.esm.js +307 -293
  31. package/components/enum-editor/index.esm.js +3 -3
  32. package/components/events-editor/index.esm.js +178 -178
  33. package/components/expression-editor/index.esm.js +105 -105
  34. package/components/external-container/index.esm.js +1747 -1627
  35. package/components/field-selector/index.css +1 -1
  36. package/components/field-selector/index.esm.js +5877 -6176
  37. package/components/filter-bar/index.css +1 -1
  38. package/components/filter-bar/index.esm.js +1454 -1524
  39. package/components/flow-canvas/index.esm.js +678 -675
  40. package/components/image-cropper/index.esm.js +266 -266
  41. package/components/input-group/index.esm.js +659 -722
  42. package/components/layout/index.esm.js +148 -148
  43. package/components/list-nav/index.esm.js +109 -109
  44. package/components/list-view/index.esm.js +1643 -1524
  45. package/components/lookup/index.css +1 -1
  46. package/components/lookup/index.esm.js +6502 -6770
  47. package/components/mapping-editor/index.esm.js +5639 -5939
  48. package/components/message-box/index.esm.js +1 -1
  49. package/components/modal/index.esm.js +1 -1
  50. package/components/nav/index.esm.js +86 -86
  51. package/components/number-range/index.esm.js +1120 -0
  52. package/components/number-range/package.json +8 -0
  53. package/components/number-range/style.js +6 -0
  54. package/components/number-spinner/index.esm.js +1146 -0
  55. package/components/number-spinner/package.json +8 -0
  56. package/components/number-spinner/style.js +4 -0
  57. package/components/order/index.esm.js +1098 -1130
  58. package/components/page-footer/index.esm.js +106 -106
  59. package/components/page-header/index.esm.js +1088 -1317
  60. package/components/pagination/index.esm.js +252 -252
  61. package/components/progress/index.esm.js +37 -37
  62. package/components/property-editor/index.esm.js +1479 -1513
  63. package/components/property-panel/index.css +1 -1
  64. package/components/property-panel/index.esm.js +706 -778
  65. package/components/query-solution/index.css +1 -0
  66. package/components/query-solution/index.esm.js +6935 -0
  67. package/components/query-solution/package.json +8 -0
  68. package/components/query-solution/style.js +2 -0
  69. package/components/radio-button/index.esm.js +64 -64
  70. package/components/radio-group/index.esm.js +453 -516
  71. package/components/rate/index.esm.js +92 -92
  72. package/components/response-layout/index.esm.js +33 -33
  73. package/components/response-layout-editor/index.esm.js +555 -526
  74. package/components/response-toolbar/index.esm.js +1009 -1247
  75. package/components/schema-selector/index.esm.js +3261 -3373
  76. package/components/search-box/index.esm.js +143 -143
  77. package/components/section/index.esm.js +209 -209
  78. package/components/smoke-detector/index.esm.js +22 -22
  79. package/components/spacing-editor/index.esm.js +2 -2
  80. package/components/splitter/index.esm.js +1097 -394
  81. package/components/step/index.esm.js +153 -153
  82. package/components/switch/index.esm.js +441 -504
  83. package/components/tabs/index.esm.js +1849 -2039
  84. package/components/tags/index.esm.js +215 -215
  85. package/components/text/index.esm.js +53 -53
  86. package/components/textarea/index.esm.js +445 -493
  87. package/components/time-picker/index.esm.js +1350 -1414
  88. package/components/transfer/index.esm.js +146 -144
  89. package/components/tree-grid/index.css +1 -1
  90. package/components/tree-grid/index.esm.js +5948 -6237
  91. package/components/tree-view/index.esm.js +2381 -2255
  92. package/components/uploader/index.esm.js +1 -1
  93. package/components/verify-detail/index.esm.js +232 -232
  94. package/components/video/index.esm.js +136 -136
  95. package/components/weather/index.esm.js +2 -2
  96. package/farris.all.esm.js +27221 -26804
  97. package/farris.all.umd.cjs +9 -9
  98. package/index.css +1 -1
  99. package/package.json +1 -1
  100. package/types/checkbox/index.d.ts +1 -0
  101. package/types/combo-list/src/components/list-container.component.d.ts +6 -0
  102. package/types/combo-list/src/components/list-container.props.d.ts +9 -1
  103. package/types/data-grid/src/data-grid.props.d.ts +1 -0
  104. package/types/data-grid/src/designer/column-header.design.component.d.ts +1 -1
  105. package/types/data-grid/src/designer/data-grid-column.props.d.ts +1 -0
  106. package/types/data-view/composition/types.d.ts +1 -1
  107. package/types/designer-canvas/src/composition/dg-control.d.ts +16 -350
  108. package/types/designer-canvas/src/types.d.ts +1 -1
  109. package/types/dynamic-form/index.d.ts +1 -0
  110. package/types/dynamic-form/src/types.d.ts +1 -1
  111. package/types/dynamic-resolver/index.d.ts +1 -0
  112. package/types/dynamic-resolver/src/binding-resolver.d.ts +1 -0
  113. package/types/dynamic-view/src/dynamic-view.component.d.ts +1 -1
  114. package/types/lookup/src/property-config/converters/lookup-property.converter.d.ts +0 -4
  115. package/types/lookup/src/property-config/lookup.property-config.d.ts +4 -3
  116. package/types/modal/src/modal.props.d.ts +1 -4
  117. package/types/property-panel/src/composition/entity/base-property.d.ts +0 -28
  118. package/types/property-panel/src/composition/entity/input-base-property.d.ts +11 -5
  119. package/types/property-panel/src/composition/entity/schema-dom-mapping.d.ts +10 -8
  120. package/types/tabs/src/designer/tab-toolbar-item.props.d.ts +19 -0
  121. package/types/tabs/src/property-config/tabs.property-config.d.ts +6 -6
  122. package/types/tree-grid/src/designer/use-designer-rules.d.ts +3 -0
  123. package/types/tree-grid/src/property-config/tree-grid.property-config.d.ts +11 -0
  124. package/types/tree-grid/src/schema/column-resolver.d.ts +1 -1
  125. package/types/tree-grid/src/tree-grid.props.d.ts +8 -0
  126. package/components/accordion/index.umd.cjs +0 -1
  127. package/components/avatar/index.umd.cjs +0 -1
  128. package/components/border-editor/index.umd.cjs +0 -1
  129. package/components/button/index.umd.cjs +0 -1
  130. package/components/button-edit/index.umd.cjs +0 -1
  131. package/components/button-group/index.umd.cjs +0 -1
  132. package/components/calculator/index.umd.cjs +0 -1
  133. package/components/calendar/index.umd.cjs +0 -1
  134. package/components/capsule/index.umd.cjs +0 -1
  135. package/components/checkbox/index.umd.cjs +0 -1
  136. package/components/color-picker/index.umd.cjs +0 -3
  137. package/components/combo-list/index.umd.cjs +0 -1
  138. package/components/combo-tree/index.umd.cjs +0 -1
  139. package/components/common/index.umd.cjs +0 -1
  140. package/components/component/index.umd.cjs +0 -1
  141. package/components/condition/index.umd.cjs +0 -1
  142. package/components/content-container/index.umd.cjs +0 -1
  143. package/components/data-grid/index.umd.cjs +0 -1
  144. package/components/data-view/index.umd.cjs +0 -1
  145. package/components/date-picker/index.umd.cjs +0 -1
  146. package/components/designer-canvas/index.umd.cjs +0 -1
  147. package/components/designer-outline/index.umd.cjs +0 -1
  148. package/components/designer-toolbox/index.umd.cjs +0 -1
  149. package/components/discussion-editor/index.umd.cjs +0 -3
  150. package/components/discussion-list/index.umd.cjs +0 -1
  151. package/components/drawer/index.umd.cjs +0 -1
  152. package/components/dropdown/index.umd.cjs +0 -2
  153. package/components/dynamic-form/index.umd.cjs +0 -1
  154. package/components/dynamic-resolver/index.umd.cjs +0 -1
  155. package/components/dynamic-view/index.umd.cjs +0 -1
  156. package/components/enum-editor/index.umd.cjs +0 -1
  157. package/components/events-editor/index.umd.cjs +0 -1
  158. package/components/expression-editor/index.umd.cjs +0 -1
  159. package/components/external-container/index.umd.cjs +0 -1
  160. package/components/field-selector/index.umd.cjs +0 -1
  161. package/components/filter-bar/index.umd.cjs +0 -1
  162. package/components/flow-canvas/index.umd.cjs +0 -1
  163. package/components/image-cropper/index.umd.cjs +0 -1
  164. package/components/input-group/index.umd.cjs +0 -1
  165. package/components/layout/index.umd.cjs +0 -1
  166. package/components/list-nav/index.umd.cjs +0 -1
  167. package/components/list-view/index.umd.cjs +0 -1
  168. package/components/loading/index.umd.cjs +0 -8
  169. package/components/locale/index.umd.cjs +0 -1
  170. package/components/lookup/index.umd.cjs +0 -1
  171. package/components/mapping-editor/index.umd.cjs +0 -1
  172. package/components/message-box/index.umd.cjs +0 -1
  173. package/components/modal/index.umd.cjs +0 -1
  174. package/components/nav/index.umd.cjs +0 -3
  175. package/components/notify/index.umd.cjs +0 -1
  176. package/components/order/index.umd.cjs +0 -1
  177. package/components/page-footer/index.umd.cjs +0 -1
  178. package/components/page-header/index.umd.cjs +0 -1
  179. package/components/pagination/index.umd.cjs +0 -1
  180. package/components/popover/index.umd.cjs +0 -1
  181. package/components/progress/index.umd.cjs +0 -3
  182. package/components/property-editor/index.umd.cjs +0 -3
  183. package/components/property-panel/index.umd.cjs +0 -1
  184. package/components/radio-button/index.umd.cjs +0 -1
  185. package/components/radio-group/index.umd.cjs +0 -1
  186. package/components/rate/index.umd.cjs +0 -1
  187. package/components/response-layout/index.umd.cjs +0 -1
  188. package/components/response-layout-editor/index.umd.cjs +0 -1
  189. package/components/response-toolbar/index.umd.cjs +0 -1
  190. package/components/schema-selector/index.umd.cjs +0 -8
  191. package/components/search-box/index.umd.cjs +0 -1
  192. package/components/section/index.umd.cjs +0 -1
  193. package/components/smoke-detector/index.umd.cjs +0 -1
  194. package/components/spacing-editor/index.umd.cjs +0 -1
  195. package/components/splitter/index.umd.cjs +0 -1
  196. package/components/step/index.umd.cjs +0 -1
  197. package/components/switch/index.umd.cjs +0 -1
  198. package/components/tabs/index.umd.cjs +0 -1
  199. package/components/tags/index.umd.cjs +0 -1
  200. package/components/text/index.umd.cjs +0 -1
  201. package/components/textarea/index.umd.cjs +0 -1
  202. package/components/time-picker/index.umd.cjs +0 -1
  203. package/components/tooltip/index.umd.cjs +0 -1
  204. package/components/transfer/index.umd.cjs +0 -1
  205. package/components/tree-grid/index.umd.cjs +0 -1
  206. package/components/tree-view/index.umd.cjs +0 -1
  207. package/components/uploader/index.umd.cjs +0 -2
  208. package/components/verify-detail/index.umd.cjs +0 -1
  209. package/components/video/index.umd.cjs +0 -1
  210. package/components/weather/index.umd.cjs +0 -16
@@ -1,39 +1,40 @@
1
- var Ce = Object.defineProperty;
2
- var Se = (e, t, n) => t in e ? Ce(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
- var $ = (e, t, n) => Se(e, typeof t != "symbol" ? t + "" : t, n);
4
- import { ref as b, computed as O, createVNode as h, Fragment as Q, watch as N, withModifiers as we, withDirectives as Fe, vModelText as Te, defineComponent as H, inject as q, onMounted as ie, nextTick as ke } from "vue";
5
- import { cloneDeep as Me } from "lodash-es";
6
- import { useIdentify as Ve, useHierarchy as De, useGroupData as Ie, usePagination as je, useDataView as Pe, useSelection as Be, useEdit as Oe, useVisualDataBound as Ae, useVisualDataCell as xe, useVisualDataRow as Le, useVisualGroupRow as $e, useVisualSummaryRow as Ee, useVisualData as Ne } from "@farris/ui-vue/components/data-view";
7
- import { FCheckBox as X } from "@farris/ui-vue/components/checkbox";
8
- import He from "@farris/ui-vue/components/list-view";
9
- import le from "@farris/ui-vue/components/button-edit";
10
- import { useDesignerComponent as Re } from "@farris/ui-vue/components/designer-canvas/src/composition/function/use-designer-component";
11
- const se = {}, ce = {};
12
- function Y(e) {
13
- const { properties: t, title: n } = e, o = Object.keys(t).reduce((c, i) => (c[i] = t[i].type === "object" && t[i].properties ? Y(t[i]) : Me(t[i].default), c), {});
1
+ var Se = Object.defineProperty;
2
+ var ke = (e, t, n) => t in e ? Se(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
+ var L = (e, t, n) => ke(e, typeof t != "symbol" ? t + "" : t, n);
4
+ import { ref as C, computed as B, createVNode as v, Fragment as Q, watch as N, withModifiers as Fe, withDirectives as Te, vModelText as Me, defineComponent as H, inject as X, onMounted as ce, nextTick as je } from "vue";
5
+ import { cloneDeep as Ve } from "lodash-es";
6
+ import { useIdentify as De, useHierarchy as Oe, useGroupData as Ie, usePagination as Pe, useDataView as Be, useSelection as Ae, useEdit as $e, useVisualDataBound as xe, useVisualDataCell as Le, useVisualDataRow as Ee, useVisualGroupRow as Ne, useVisualSummaryRow as He, useVisualData as Re } from "../data-view/index.esm.js";
7
+ import { FCheckBox as Y } from "../checkbox/index.esm.js";
8
+ import Ue from "../list-view/index.esm.js";
9
+ import ue from "../button-edit/index.esm.js";
10
+ import { getSchemaByType as re } from "../dynamic-resolver/index.esm.js";
11
+ import { useDesignerComponent as Ge } from "../designer-canvas/index.esm.js";
12
+ const de = {}, pe = {};
13
+ function Z(e) {
14
+ const { properties: t, title: n } = e, o = Object.keys(t).reduce((c, l) => (c[l] = t[l].type === "object" && t[l].properties ? Z(t[l]) : Ve(t[l].default), c), {});
14
15
  return o.id = `${n}-${Date.now()}`, o;
15
16
  }
16
- function R(e, t = {}) {
17
- const n = se[e];
17
+ function U(e, t = {}) {
18
+ const n = de[e];
18
19
  if (n) {
19
- let o = Y(n);
20
- const c = ce[e];
21
- return o = c ? c({ getSchemaByType: R }, o, t) : o, o;
20
+ let o = Z(n);
21
+ const c = pe[e];
22
+ return o = c ? c({ getSchemaByType: U }, o, t) : o, o;
22
23
  }
23
24
  return null;
24
25
  }
25
- function Ue(e, t) {
26
- const n = Y(t);
27
- return Object.keys(e).reduce((o, c) => (o[c] = e[c], o), n), n;
26
+ function _e(e, t) {
27
+ const n = Z(t);
28
+ return Object.keys(e).reduce((o, c) => (o[c] && typeof o[c] == "object" ? Object.assign(o[c], e[c]) : o[c] = e[c], o), n), n;
28
29
  }
29
- function ze(e, t) {
30
+ function qe(e, t) {
30
31
  return Object.keys(e).filter((o) => e[o] != null).reduce((o, c) => {
31
32
  if (t.has(c)) {
32
- const i = t.get(c);
33
- if (typeof i == "string")
34
- o[i] = e[c];
33
+ const l = t.get(c);
34
+ if (typeof l == "string")
35
+ o[l] = e[c];
35
36
  else {
36
- const u = i(c, e[c], e);
37
+ const u = l(c, e[c], e);
37
38
  Object.assign(o, u);
38
39
  }
39
40
  } else
@@ -41,71 +42,69 @@ function ze(e, t) {
41
42
  return o;
42
43
  }, {});
43
44
  }
44
- function Ge(e, t, n = /* @__PURE__ */ new Map()) {
45
- const o = Ue(e, t);
46
- return ze(o, n);
45
+ function We(e, t, n = /* @__PURE__ */ new Map()) {
46
+ const o = _e(e, t);
47
+ return qe(o, n);
47
48
  }
48
- function _e(e = {}) {
49
- function t(f, y, a, r) {
50
- if (typeof a == "number")
51
- return r[f].length === a;
52
- if (typeof a == "object") {
53
- const w = Object.keys(a)[0], s = a[w];
54
- if (w === "not")
55
- return Number(r[f].length) !== Number(s);
56
- if (w === "moreThan")
57
- return Number(r[f].length) >= Number(s);
58
- if (w === "lessThan")
59
- return Number(r[f].length) <= Number(s);
49
+ function ze(e = {}) {
50
+ function t(y, h, i, r) {
51
+ if (typeof i == "number")
52
+ return r[y].length === i;
53
+ if (typeof i == "object") {
54
+ const g = Object.keys(i)[0], a = i[g];
55
+ if (g === "not")
56
+ return Number(r[y].length) !== Number(a);
57
+ if (g === "moreThan")
58
+ return Number(r[y].length) >= Number(a);
59
+ if (g === "lessThan")
60
+ return Number(r[y].length) <= Number(a);
60
61
  }
61
62
  return !1;
62
63
  }
63
- function n(f, y, a, r) {
64
- return r[f] && r[f].propertyValue && String(r[f].propertyValue.value) === String(a);
64
+ function n(y, h, i, r) {
65
+ return r[y] && r[y].propertyValue && String(r[y].propertyValue.value) === String(i);
65
66
  }
66
67
  const o = /* @__PURE__ */ new Map([
67
68
  ["length", t],
68
69
  ["getProperty", n]
69
70
  ]);
70
- Object.keys(e).reduce((f, y) => (f.set(y, e[y]), f), o);
71
- function c(f, y) {
72
- const a = f;
73
- return typeof y == "number" ? [{ target: a, operator: "length", param: null, value: Number(y) }] : typeof y == "boolean" ? [{ target: a, operator: "getProperty", param: f, value: !!y }] : typeof y == "object" ? Object.keys(y).map((r) => {
71
+ Object.keys(e).reduce((y, h) => (y.set(h, e[h]), y), o);
72
+ function c(y, h) {
73
+ const i = y;
74
+ return typeof h == "number" ? [{ target: i, operator: "length", param: null, value: Number(h) }] : typeof h == "boolean" ? [{ target: i, operator: "getProperty", param: y, value: !!h }] : typeof h == "object" ? Object.keys(h).map((r) => {
74
75
  if (r === "length")
75
- return { target: a, operator: "length", param: null, value: y[r] };
76
- const w = r, s = y[r];
77
- return { target: a, operator: "getProperty", param: w, value: s };
76
+ return { target: i, operator: "length", param: null, value: h[r] };
77
+ const g = r, a = h[r];
78
+ return { target: i, operator: "getProperty", param: g, value: a };
78
79
  }) : [];
79
80
  }
80
- function i(f) {
81
- return Object.keys(f).reduce((a, r) => {
82
- const w = c(r, f[r]);
83
- return a.push(...w), a;
81
+ function l(y) {
82
+ return Object.keys(y).reduce((i, r) => {
83
+ const g = c(r, y[r]);
84
+ return i.push(...g), i;
84
85
  }, []);
85
86
  }
86
- function u(f, y) {
87
- if (o.has(f.operator)) {
88
- const a = o.get(f.operator);
89
- return a && a(f.target, f.param, f.value, y) || !1;
87
+ function u(y, h) {
88
+ if (o.has(y.operator)) {
89
+ const i = o.get(y.operator);
90
+ return i && i(y.target, y.param, y.value, h) || !1;
90
91
  }
91
92
  return !1;
92
93
  }
93
- function m(f, y) {
94
- return i(f).reduce((w, s) => w && u(s, y), !0);
94
+ function f(y, h) {
95
+ return l(y).reduce((g, a) => g && u(a, h), !0);
95
96
  }
96
- function S(f, y) {
97
- const a = Object.keys(f), r = a.includes("allOf"), w = a.includes("anyOf"), s = r || w, d = (s ? f[s ? r ? "allOf" : "anyOf" : "allOf"] : [f]).map((T) => m(T, y));
97
+ function b(y, h) {
98
+ const i = Object.keys(y), r = i.includes("allOf"), g = i.includes("anyOf"), a = r || g, d = (a ? y[a ? r ? "allOf" : "anyOf" : "allOf"] : [y]).map((F) => f(F, h));
98
99
  return r ? !d.includes(!1) : d.includes(!0);
99
100
  }
100
- return { parseValueSchema: S };
101
+ return { parseValueSchema: b };
101
102
  }
102
- const M = {
103
- Button: { type: "Button", name: "按钮", icon: "Button" },
104
- ButtonGroup: { type: "ButtonGroup", name: "按钮组", icon: "ButtonGroup" },
103
+ const j = {
104
+ button: { type: "button", name: "按钮", icon: "Button" },
105
105
  "response-toolbar": { type: "response-toolbar", name: "工具栏", icon: "ButtonGroup" },
106
- "response-toolbar-item": { type: "response-toolbar-item", name: "工具栏项", icon: "Button" },
106
+ "response-toolbar-item": { type: "response-toolbar-item", name: "按钮", icon: "Button" },
107
107
  "content-container": { type: "content-container", name: "容器", icon: "ContentContainer" },
108
- DisplayField: { type: "DisplayField", name: "标签", icon: "DisplayField" },
109
108
  "input-group": { type: "input-group", name: "文本", icon: "TextBox" },
110
109
  textarea: { type: "textarea", name: "多行文本", icon: "MultiTextBox" },
111
110
  lookup: { type: "lookup", name: "帮助", icon: "LookupEdit" },
@@ -116,114 +115,43 @@ const M = {
116
115
  "check-box": { type: "check-box", name: "复选框", icon: "CheckBox" },
117
116
  "check-group": { type: "check-group", name: "复选框组", icon: "CheckGroup" },
118
117
  "combo-list": { type: "combo-list", name: "下拉列表", icon: "EnumField" },
119
- /** 暂时没用 */
120
- FlexLayout: { type: "FlexLayout", name: "弹性布局" },
121
- /** 暂时没用 */
122
- FlowLayout: { type: "FlowLayout", name: "流布局" },
123
- ResponseLayout: { type: "ResponseLayout", name: "布局容器", icon: "ResponseLayout3" },
124
- ResponseLayoutItem: { type: "ResponseLayoutItem", name: "布局", icon: "ResponseLayout1" },
118
+ "response-form": { type: "response-form", name: "卡片面板", icon: "Form" },
119
+ "response-layout": { type: "response-layout", name: "布局容器", icon: "ResponseLayout3" },
120
+ "response-layout-item": { type: "response-layout-item", name: "布局", icon: "ResponseLayout1" },
125
121
  "tree-grid": { type: "tree-grid", name: "树表格", icon: "TreeGrid" },
126
- TreeGridField: { type: "TreeGridField", name: "树表格列" },
127
- FieldSet: { type: "FieldSet", name: "分组", icon: "FieldSet" },
128
- Form: { type: "Form", name: "卡片面板", icon: "Form" },
129
- QueryForm: { type: "QueryForm", name: "查询面板", icon: "Form" },
122
+ "tree-grid-column": { type: "tree-grid-column", name: "树表格列" },
130
123
  "data-grid": { type: "data-grid", name: "表格", icon: "DataGrid" },
131
124
  "data-grid-column": { type: "data-grid-column", name: "表格列" },
132
- Panel: { type: "Panel", name: "面板", icon: "ContentContainer" },
133
- Module: { type: "Module", name: "模块", icon: "Module" },
125
+ module: { type: "Module", name: "模块", icon: "Module" },
134
126
  component: { type: "component", name: "组件", icon: "Component" },
135
- ExternalContainer: { type: "ExternalContainer", name: "外部容器", icon: "ContentContainer" },
136
- Image: { type: "Image", name: "图像", icon: "Image" },
137
- ImageUpload: { type: "ImageUpload", name: "图片上传", icon: "imageupload" },
138
- HiddenContainer: { type: "HiddenContainer", name: "隐藏区域", icon: "ContentContainer" },
139
- ModalContainer: { type: "ModalContainer", name: "弹窗容器", icon: "ContentContainer" },
140
- RouteContainer: { type: "RouteContainer", name: "路由区域", icon: "ContentContainer" },
141
127
  tabs: { type: "tabs", name: "标签页", icon: "Tab" },
142
128
  "tab-page": { type: "tab-page", name: "标签页项", dependentParentControl: "Tab" },
143
129
  "tab-toolbar-item": { type: "tab-toolbar-item", name: "标签页工具栏按钮", icon: "Button" },
144
- Tag: { type: "Tag", name: "Tag", icon: "Tag" },
145
- Sidebar: { type: "Sidebar", name: "侧边栏", icon: "Sidebar" },
146
- HtmlTemplate: { type: "HtmlTemplate", name: "模版容器", icon: "HtmlTemplate" },
147
- ListView: { type: "ListView", name: "列表", icon: "ListView" },
148
- RichTextBox: { type: "RichTextBox", name: "富文本", icon: "RichTextBox" },
149
- TimeSpinner: { type: "TimeSpinner", name: "时间调节器", icon: "TimePicker" },
150
- TimePicker: { type: "TimePicker", name: "时间选择", icon: "TimePicker" },
130
+ "time-picker": { type: "time-picker", name: "时间选择", icon: "TimePicker" },
151
131
  section: { type: "section", name: "分组面板", icon: "Section" },
152
- SectionToolbar: { type: "SectionToolbar", name: "分组面板工具栏" },
153
- SectionToolbarItem: { type: "SectionToolbarItem", name: "分组面板按钮" },
154
- QueryScheme: { type: "QueryScheme", name: "筛选方案", icon: "QueryScheme" },
155
- FormHeader: { type: "FormHeader", name: "翻页" },
156
- Splitter: { type: "Splitter", name: "分栏面板", icon: "Splitter" },
157
- SplitterPane: { type: "SplitterPane", name: "分栏面板项", dependentParentControl: "Splitter" },
158
- WizardDetail: { type: "WizardDetail", name: "向导详情页" },
159
- WizardDetailContainer: { type: "WizardDetailContainer", name: "向导详情容器" },
160
- Wizard: { type: "Wizard", name: "向导", icon: "Wizard" },
161
- MultiSelect: { type: "MultiSelect", name: "数据分配", icon: "MultiSelect" },
162
- Steps: { type: "Steps", name: "步骤条", icon: "Steps" },
163
- avatar: { type: "avatar", name: "头像", icon: "Avatar" },
164
- ListFilter: { type: "ListFilter", name: "筛选条", icon: "ListFilter" },
165
- ListNav: { type: "ListNav", name: "列表导航", icon: "ListNav" },
166
- NumberRange: { type: "NumberRange", name: "数字区间选择", icon: "NumericBox" },
167
- Scrollspy: { type: "Scrollspy", name: "滚动监听", icon: "Scrollspy" },
168
- LanguageTextBox: { type: "LanguageTextBox", name: "多语言输入框", icon: "LanguageTextBox" },
169
- ComponentRef: { type: "ComponentRef", name: "组件引用节点" },
170
- FileUpload: { type: "FileUpload", name: "附件上传", icon: "FileUpload" },
171
- FilePreview: { type: "FilePreview", name: "附件预览", icon: "FilePreview" },
172
- ViewChange: { type: "ViewChange", name: "多视图切换", icon: "Button" },
173
- MultiViewContainer: { type: "MultiViewContainer", name: "多视图", icon: "MultiViewContainer" },
174
- MultiViewItem: { type: "MultiViewItem", name: "多视图项", dependentParentControl: "MultiViewContainer" },
175
- Footer: { type: "Footer", name: "页脚" },
176
- DiscussionEditor: { type: "DiscussionEditor", name: "评论编辑区", icon: "DiscussionEditor" },
177
- DiscussionList: { type: "DiscussionList", name: "评论列表", icon: "DiscussionList" },
178
- NavTab: { type: "NavTab", name: "标签类导航", icon: "NavTab" },
179
- Tags: { type: "Tags", name: "标记组", icon: "Tags" },
180
- Portlet: { type: "Portlet", name: "小部件", icon: "dingzhi" },
132
+ "section-toolbar": { type: "section-toolbar", name: "分组面板工具栏" },
133
+ "section-toolbar-item": { type: "section-toolbar-item", name: "分组面板按钮" },
134
+ splitter: { type: "splitter", name: "分栏面板", icon: "Splitter" },
135
+ "splitter-pane": { type: "splitter-pane", name: "分栏面板项", dependentParentControl: "Splitter" },
136
+ "component-ref": { type: "component-ref", name: "组件引用节点" },
137
+ uploader: { type: "uploader", name: "附件上传", icon: "FileUpload" },
181
138
  "page-header": { type: "page-header", name: "页头", icon: "Header" },
182
- ModalFooter: { type: "ModalFooter", name: "弹窗页脚", icon: "ModalFooter" },
183
- ScrollCollapsibleArea: { type: "ScrollCollapsibleArea", name: "滚动收折区域", icon: "ScrollCollapsibleArea" },
184
- PersonnelSelector: { type: "PersonnelSelector", name: "人员选择", icon: "PersonnelSelector" },
185
- Table: { type: "Table", name: "表格", icon: "DataGrid" },
186
- LoopContainer: { type: "LoopContainer", name: "循环容器", icon: "ContentContainer" },
187
- FileUploadPreview: { type: "FileUploadPreview", name: "附件上传预览", icon: "FileUpload" },
188
- DynamicArea: { type: "DynamicArea", name: "动态区域", icon: "ContentContainer" },
189
- DynamicAreaItem: { type: "DynamicAreaItem", name: "动态区域项", icon: "ContentContainer" },
190
- TabToolbar: { type: "TabToolbar", name: "标签页工具栏", icon: "TabToolbar" },
191
- HeaderToolBar: { type: "HeaderToolBar", name: "头部组件工具栏", icon: "HeaderToolBar" },
192
- ModalFooterToolBar: { type: "ModalFooterToolBar", name: "底部组件工具栏", icon: "ModalFooterToolBar" },
193
- HeaderToolBarItem: { type: "HeaderToolBarItem", name: "头部组件工具栏按钮", icon: "HeaderToolBarItem" },
194
- ModalFooterToolBarItem: { type: "ModalFooterToolBarItem", name: "底部组件工具栏按钮", icon: "ModalFooterToolBarItem" },
195
- OrganizationSelector: { type: "OrganizationSelector", name: "组织选择", icon: "OrganizationSelector" },
196
- AdminOrganizationSelector: { type: "AdminOrganizationSelector", name: "组织选择", icon: "OrganizationSelector" },
197
- EmployeeSelector: { type: "EmployeeSelector", name: "人员选择", icon: "PersonnelSelector" },
198
- OaRelation: { type: "OaRelation", name: "关联行政审批", icon: "TextBox" },
199
- CitySelector: { type: "CitySelector", name: "城市选择", icon: "CitySelector" },
200
- ExtIntergration: { type: "ExtIntergration", name: "外部服务集成", icon: "ViewModel" },
201
- AppointmentCalendar: { type: "AppointmentCalendar", name: "预约日历", icon: "DateBox" },
202
- /** 查询类 start */
203
- Charts: { type: "Charts", name: "图表", icon: "Charts" },
204
- QdpFramework: { type: "QdpFramework", name: "查询结果工具栏", icon: "QdpFramework" },
205
- SpreadSheet: { type: "SpreadSheet", name: "查询表格控件", icon: "Charts" },
206
- QdpConditionDialog: { type: "QdpConditionDialog", name: "查询筛选对话框", icon: "ContentContainer" },
207
- QdpConditionDialogTab: { type: "QdpConditionDialogTab", name: "查询筛选标签页", icon: "Tab" },
208
- /** 查询类 end */
209
- /** 审批类 start */
210
- ApprovalLogs: { type: "ApprovalLogs", name: "审批记录", icon: "ApprovalLogs" },
211
- ApprovalComments: { type: "ApprovalComments", name: "审批意见", icon: "shenpiyijian" }
212
- /** 审批类 end */
213
- }, We = {}, qe = {};
214
- _e();
215
- function Z(e, t, n = /* @__PURE__ */ new Map(), o = (u, m, S) => m, c = {}, i = (u) => u) {
216
- return se[t.title] = t, ce[t.title] = o, We[t.title] = c, qe[t.title] = i, (u = {}) => {
217
- const m = Ge(u, t, n), S = Object.keys(e).reduce((f, y) => (f[y] = e[y].default, f), {});
218
- return Object.assign(S, m);
139
+ "page-footer": { type: "page-footer", name: "页脚", icon: "ModalFooter" },
140
+ "tab-toolbar": { type: "tab-toolbar", name: "标签页工具栏", icon: "TabToolbar" }
141
+ }, Je = {}, Xe = {};
142
+ ze();
143
+ function K(e, t, n = /* @__PURE__ */ new Map(), o = (u, f, b) => f, c = {}, l = (u) => u) {
144
+ return de[t.title] = t, pe[t.title] = o, Je[t.title] = c, Xe[t.title] = l, (u = {}) => {
145
+ const f = We(u, t, n), b = Object.keys(e).reduce((y, h) => (y[h] = e[h].default, y), {});
146
+ return Object.assign(b, f);
219
147
  };
220
148
  }
221
- function J(e, t) {
149
+ function ee(e, t) {
222
150
  return { customClass: t.class, customStyle: t.style };
223
151
  }
224
152
  const Qe = /* @__PURE__ */ new Map([
225
- ["appearance", J]
226
- ]), Xe = "https://json-schema.org/draft/2020-12/schema", Ye = "https://farris-design.gitee.io/order.schema.json", Ze = "order", Je = "A Farris Component", Ke = "object", et = {
153
+ ["appearance", ee]
154
+ ]), Ye = "https://json-schema.org/draft/2020-12/schema", Ze = "https://farris-design.gitee.io/order.schema.json", Ke = "order", et = "A Farris Component", tt = "object", nt = {
227
155
  id: {
228
156
  description: "The unique identifier for a order",
229
157
  type: "string"
@@ -315,22 +243,22 @@ const Qe = /* @__PURE__ */ new Map([
315
243
  type: "sting",
316
244
  default: ""
317
245
  }
318
- }, tt = [
246
+ }, ot = [
319
247
  "id",
320
248
  "type"
321
- ], nt = {
322
- $schema: Xe,
323
- $id: Ye,
324
- title: Ze,
325
- description: Je,
326
- type: Ke,
327
- properties: et,
328
- required: tt
249
+ ], at = {
250
+ $schema: Ye,
251
+ $id: Ze,
252
+ title: Ke,
253
+ description: et,
254
+ type: tt,
255
+ properties: nt,
256
+ required: ot
329
257
  };
330
- function ot(e, t, n) {
258
+ function rt(e, t, n) {
331
259
  return t;
332
260
  }
333
- const at = "order", rt = "A Farris Component", it = "object", lt = {
261
+ const it = "order", lt = "A Farris Component", st = "object", ct = {
334
262
  basic: {
335
263
  description: "Basic Infomation",
336
264
  title: "基本信息",
@@ -412,12 +340,12 @@ const at = "order", rt = "A Farris Component", it = "object", lt = {
412
340
  }
413
341
  }
414
342
  }
415
- }, st = {
416
- title: at,
417
- description: rt,
418
- type: it,
419
- categories: lt
420
- }, K = {
343
+ }, ut = {
344
+ title: it,
345
+ description: lt,
346
+ type: st,
347
+ categories: ct
348
+ }, te = {
421
349
  dataSource: {
422
350
  type: Array,
423
351
  default: [
@@ -436,13 +364,13 @@ const at = "order", rt = "A Farris Component", it = "object", lt = {
436
364
  { id: "3", name: "开票日期", order: "asc" }
437
365
  ]
438
366
  }
439
- }, oe = Z(K, nt, Qe, ot, st), ct = /* @__PURE__ */ new Map([
440
- ["appearance", J]
367
+ }, ie = K(te, at, Qe, rt, ut), dt = /* @__PURE__ */ new Map([
368
+ ["appearance", ee]
441
369
  ]);
442
- function ut(e, t, n) {
370
+ function pt(e, t, n) {
443
371
  return t;
444
372
  }
445
- const dt = "https://json-schema.org/draft/2020-12/schema", pt = "https://farris-design.gitee.io/list-view.schema.json", ft = "list-view", mt = "A Farris Component", yt = "object", gt = {
373
+ const ft = "https://json-schema.org/draft/2020-12/schema", mt = "https://farris-design.gitee.io/list-view.schema.json", yt = "list-view", gt = "A Farris Component", ht = "object", bt = {
446
374
  id: {
447
375
  description: "The unique identifier for list-view",
448
376
  type: "string"
@@ -504,18 +432,18 @@ const dt = "https://json-schema.org/draft/2020-12/schema", pt = "https://farris-
504
432
  type: "boolean",
505
433
  default: !0
506
434
  }
507
- }, ht = [
435
+ }, vt = [
508
436
  "id",
509
437
  "type"
510
- ], vt = {
511
- $schema: dt,
512
- $id: pt,
513
- title: ft,
514
- description: mt,
515
- type: yt,
516
- properties: gt,
517
- required: ht
518
- }, bt = "list-view", Ct = "A Farris Component", St = "object", wt = {
438
+ ], Ct = {
439
+ $schema: ft,
440
+ $id: mt,
441
+ title: yt,
442
+ description: gt,
443
+ type: ht,
444
+ properties: bt,
445
+ required: vt
446
+ }, wt = "list-view", St = "A Farris Component", kt = "object", Ft = {
519
447
  basic: {
520
448
  description: "Basic Infomation",
521
449
  title: "基本信息",
@@ -537,12 +465,12 @@ const dt = "https://json-schema.org/draft/2020-12/schema", pt = "https://farris-
537
465
  }
538
466
  }
539
467
  }
540
- }, Ft = {
541
- title: bt,
542
- description: Ct,
543
- type: St,
544
- categories: wt
545
- }, ue = {
468
+ }, Tt = {
469
+ title: wt,
470
+ description: St,
471
+ type: kt,
472
+ categories: Ft
473
+ }, fe = {
546
474
  /** 列集合 */
547
475
  columns: {
548
476
  type: Array,
@@ -580,247 +508,249 @@ const dt = "https://json-schema.org/draft/2020-12/schema", pt = "https://farris-
580
508
  }
581
509
  },
582
510
  keepOrder: { type: Boolean, default: !1 },
583
- disableField: { type: String, default: "disabled" }
511
+ disableField: { type: String, default: "disabled" },
512
+ // 搜索启用高亮
513
+ enableHighlightSearch: { type: Boolean, default: !0 }
584
514
  };
585
- Z(ue, vt, ct, ut, Ft);
586
- function Tt(e, t) {
587
- function n(i) {
515
+ K(fe, Ct, dt, pt, Tt);
516
+ function Mt(e, t) {
517
+ function n(l) {
588
518
  const u = [];
589
- let m = i.nextNode();
590
- for (; m; )
591
- u.push(m), m = i.nextNode();
519
+ let f = l.nextNode();
520
+ for (; f; )
521
+ u.push(f), f = l.nextNode();
592
522
  return u;
593
523
  }
594
- function o(i, u) {
595
- const m = document.createTreeWalker(i, NodeFilter.SHOW_TEXT);
596
- return n(m).map((a) => ({ textNode: a, text: (a.textContent || "").toLocaleLowerCase() })).map(({ textNode: a, text: r }) => {
597
- const w = [];
598
- let s = 0;
599
- for (; s < r.length; ) {
600
- const g = r.indexOf(u, s);
601
- if (g === -1)
524
+ function o(l, u) {
525
+ const f = document.createTreeWalker(l, NodeFilter.SHOW_TEXT);
526
+ return n(f).map((i) => ({ textNode: i, text: (i.textContent || "").toLocaleLowerCase() })).map(({ textNode: i, text: r }) => {
527
+ const g = [];
528
+ let a = 0;
529
+ for (; a < r.length; ) {
530
+ const m = r.indexOf(u, a);
531
+ if (m === -1)
602
532
  break;
603
- w.push(g), s = g + u.length;
533
+ g.push(m), a = m + u.length;
604
534
  }
605
- return w.map((g) => {
606
- const l = new Range();
607
- return l.setStart(a, g), l.setEnd(a, g + u.length), l;
535
+ return g.map((m) => {
536
+ const s = new Range();
537
+ return s.setStart(i, m), s.setEnd(i, m + u.length), s;
608
538
  });
609
539
  }).flat();
610
540
  }
611
- function c(i) {
612
- if (!CSS.highlights || (CSS.highlights.clear(), !i || !t))
541
+ function c(l) {
542
+ if (!CSS.highlights || (CSS.highlights.clear(), !l || !t))
613
543
  return;
614
- const u = o(t.value, i.toLocaleLowerCase()), m = new Highlight(...u);
615
- CSS.highlights.set("search-result", m);
544
+ const u = o(t.value, l.toLocaleLowerCase()), f = new Highlight(...u);
545
+ CSS.highlights.set("search-result", f);
616
546
  }
617
547
  return { search: c };
618
548
  }
619
- function ae(e, t, n, o, c, i, u, m, S, f) {
620
- const y = b(e.size), a = b(e.textField), r = b(e.titleField), w = b(e.multiSelect), s = b(e.disableField), {
621
- onMouseenterItem: g,
622
- onMouseoverItem: l,
549
+ function le(e, t, n, o, c, l, u, f, b, y) {
550
+ const h = C(e.size), i = C(e.textField), r = C(e.titleField), g = C(e.multiSelect), a = C(e.disableField), {
551
+ onMouseenterItem: m,
552
+ onMouseoverItem: s,
623
553
  onMouseoutItem: d
624
- } = i, {
625
- getKey: F,
626
- listViewItemClass: T,
627
- onCheckItem: I,
628
- onClickItem: C
629
- } = u, v = O(() => ({
630
- margin: y.value === "small" ? "0.25rem 0" : "10px 0"
554
+ } = l, {
555
+ getKey: k,
556
+ listViewItemClass: F,
557
+ onCheckItem: D,
558
+ onClickItem: S
559
+ } = u, w = B(() => ({
560
+ margin: h.value === "small" ? "0.25rem 0" : "10px 0"
631
561
  }));
632
- function D(p, V, A) {
633
- return p.checked = m.findIndexInSelectedItems(p) > -1, h("li", {
634
- class: T(p, V),
635
- id: F(p, V),
636
- key: F(p, V),
637
- onClick: (k) => C(k, p, V),
638
- onMouseenter: (k) => g(k, p, V),
639
- onMouseover: (k) => l(k, p, V),
640
- onMouseout: (k) => d(k, p, V)
641
- }, [w.value && h("div", {
562
+ function V(p, M, A) {
563
+ return p.checked = f.findIndexInSelectedItems(p) > -1, v("li", {
564
+ class: F(p, M),
565
+ id: k(p, M),
566
+ key: k(p, M),
567
+ onClick: (T) => S(T, p, M),
568
+ onMouseenter: (T) => m(T, p, M),
569
+ onMouseover: (T) => s(T, p, M),
570
+ onMouseout: (T) => d(T, p, M)
571
+ }, [g.value && v("div", {
642
572
  class: "f-list-select",
643
- onClick: (k) => k.stopPropagation()
644
- }, [h(X, {
645
- id: "list-" + F(p, V),
573
+ onClick: (T) => T.stopPropagation()
574
+ }, [v(Y, {
575
+ id: "list-" + k(p, M),
646
576
  customClass: "listview-checkbox",
647
- disabled: p[s.value],
577
+ disabled: p[a.value],
648
578
  checked: p.checked,
649
- "onUpdate:checked": (k) => p.checked = k,
650
- onChange: (k) => {
651
- I(p, V, !k.checked);
579
+ "onUpdate:checked": (T) => p.checked = T,
580
+ onChange: (T) => {
581
+ D(p, M, !T.checked);
652
582
  }
653
- }, null)]), h("div", {
583
+ }, null)]), v("div", {
654
584
  class: "f-list-content"
655
- }, [h("div", {
656
- style: v.value,
657
- title: p.raw[r.value] || p.raw[a.value]
658
- }, [p.raw[a.value]])])]);
585
+ }, [v("div", {
586
+ style: w.value,
587
+ title: p.raw[r.value] || p.raw[i.value]
588
+ }, [p.raw[i.value]])])]);
659
589
  }
660
590
  return {
661
- renderItem: D
591
+ renderItem: V
662
592
  };
663
593
  }
664
- function kt(e, t, n, o, c, i, u, m, S, f) {
665
- const y = b(e.multiSelect), a = b(e.disableField), {
594
+ function jt(e, t, n, o, c, l, u, f, b, y) {
595
+ const h = C(e.multiSelect), i = C(e.disableField), {
666
596
  onMouseenterItem: r,
667
- onMouseoverItem: w,
668
- onMouseoutItem: s
669
- } = i, {
670
- getKey: g,
671
- listViewItemClass: l,
597
+ onMouseoverItem: g,
598
+ onMouseoutItem: a
599
+ } = l, {
600
+ getKey: m,
601
+ listViewItemClass: s,
672
602
  onCheckItem: d,
673
- onClickItem: F
603
+ onClickItem: k
674
604
  } = u;
675
- function T(C, v, D) {
676
- return t.slots.content ? h(Q, null, [t.slots.content && t.slots.content({
677
- item: C.raw,
678
- index: v,
679
- selectedItem: D
680
- })]) : h("div", {
605
+ function F(S, w, V) {
606
+ return t.slots.content ? v(Q, null, [t.slots.content && t.slots.content({
607
+ item: S.raw,
608
+ index: w,
609
+ selectedItem: V
610
+ })]) : v("div", {
681
611
  style: "margin: 10px 0;"
682
- }, [C.raw.name]);
683
- }
684
- function I(C, v, D) {
685
- return h("li", {
686
- class: l(C, v),
687
- id: g(C, v),
688
- key: g(C, v),
689
- onClick: (p) => F(p, C, v),
690
- onMouseenter: (p) => r(p, C, v),
691
- onMouseover: (p) => w(p, C, v),
692
- onMouseout: (p) => s(p, C, v)
693
- }, [y.value && h("div", {
612
+ }, [S.raw.name]);
613
+ }
614
+ function D(S, w, V) {
615
+ return v("li", {
616
+ class: s(S, w),
617
+ id: m(S, w),
618
+ key: m(S, w),
619
+ onClick: (p) => k(p, S, w),
620
+ onMouseenter: (p) => r(p, S, w),
621
+ onMouseover: (p) => g(p, S, w),
622
+ onMouseout: (p) => a(p, S, w)
623
+ }, [h.value && v("div", {
694
624
  class: "f-list-select",
695
625
  onClick: (p) => p.stopPropagation()
696
- }, [h(X, {
697
- id: "list-" + g(C, v),
626
+ }, [v(Y, {
627
+ id: "list-" + m(S, w),
698
628
  customClass: "listview-checkbox",
699
- disabled: C[a.value] || !C.checked,
700
- checked: C.checked,
701
- "onUpdate:checked": (p) => C.checked = p,
702
- onChange: (p) => d(C, v, !p.checked)
703
- }, null)]), h("div", {
629
+ disabled: S[i.value] || !S.checked,
630
+ checked: S.checked,
631
+ "onUpdate:checked": (p) => S.checked = p,
632
+ onChange: (p) => d(S, w, !p.checked)
633
+ }, null)]), v("div", {
704
634
  class: "f-list-content"
705
- }, [T(C, v, D)])]);
635
+ }, [F(S, w, V)])]);
706
636
  }
707
637
  return {
708
- renderItem: I
638
+ renderItem: D
709
639
  };
710
640
  }
711
- function Mt(e, t, n, o, c, i, u, m, S, f) {
712
- const y = b(e.multiSelect), a = b(e.disableField), {
641
+ function Vt(e, t, n, o, c, l, u, f, b, y) {
642
+ const h = C(e.multiSelect), i = C(e.disableField), {
713
643
  onMouseenterItem: r,
714
- onMouseoverItem: w,
715
- onMouseoutItem: s
716
- } = i, {
717
- getKey: g,
718
- listViewItemClass: l,
644
+ onMouseoverItem: g,
645
+ onMouseoutItem: a
646
+ } = l, {
647
+ getKey: m,
648
+ listViewItemClass: s,
719
649
  onCheckItem: d,
720
- onClickItem: F
650
+ onClickItem: k
721
651
  } = u, {
722
- dragstart: T,
723
- dragenter: I,
724
- dragover: C,
725
- dragend: v
652
+ dragstart: F,
653
+ dragenter: D,
654
+ dragover: S,
655
+ dragend: w
726
656
  } = o, {
727
- removeItem: D
728
- } = S, p = O(() => ({
729
- margin: y.value ? "10px 0" : "10px 0px 10px 14px"
657
+ removeItem: V
658
+ } = b, p = B(() => ({
659
+ margin: h.value ? "10px 0" : "10px 0px 10px 14px"
730
660
  }));
731
- function V(j) {
732
- return h("div", {
661
+ function M(O) {
662
+ return v("div", {
733
663
  style: p.value
734
- }, [j.raw.name]);
664
+ }, [O.raw.name]);
735
665
  }
736
666
  function A() {
737
- return t.slots.itemContent ? t.slots.itemContent : V;
738
- }
739
- const k = A();
740
- function x(j, B, E) {
741
- return h("li", {
742
- class: l(j, B),
743
- id: g(j, B),
744
- key: g(j, B),
745
- onClick: (P) => F(P, j, B),
746
- onMouseenter: (P) => r(P, j, B),
747
- onMouseover: (P) => w(P, j, B),
748
- onMouseout: (P) => s(P, j, B),
667
+ return t.slots.itemContent ? t.slots.itemContent : M;
668
+ }
669
+ const T = A();
670
+ function $(O, P, E) {
671
+ return v("li", {
672
+ class: s(O, P),
673
+ id: m(O, P),
674
+ key: m(O, P),
675
+ onClick: (I) => k(I, O, P),
676
+ onMouseenter: (I) => r(I, O, P),
677
+ onMouseover: (I) => g(I, O, P),
678
+ onMouseout: (I) => a(I, O, P),
749
679
  draggable: "true",
750
- onDragstart: (P) => T(P, j, B),
751
- onDragenter: (P) => I(P, B),
752
- onDragend: (P) => v(P, j),
753
- onDragover: (P) => C(P, B)
754
- }, [y.value && h("div", {
680
+ onDragstart: (I) => F(I, O, P),
681
+ onDragenter: (I) => D(I, P),
682
+ onDragend: (I) => w(I, O),
683
+ onDragover: (I) => S(I, P)
684
+ }, [h.value && v("div", {
755
685
  class: "f-list-select",
756
- onClick: (P) => P.stopPropagation()
757
- }, [h(X, {
758
- id: "list-" + g(j, B),
686
+ onClick: (I) => I.stopPropagation()
687
+ }, [v(Y, {
688
+ id: "list-" + m(O, P),
759
689
  customClass: "listview-checkbox",
760
- disabled: j[a.value] || !j.checked,
761
- checked: j.checked,
762
- "onUpdate:checked": (P) => j.checked = P,
763
- onChange: (P) => d(j, B, !P.checked)
764
- }, null)]), h("div", {
690
+ disabled: O[i.value] || !O.checked,
691
+ checked: O.checked,
692
+ "onUpdate:checked": (I) => O.checked = I,
693
+ onChange: (I) => d(O, P, !I.checked)
694
+ }, null)]), v("div", {
765
695
  class: "f-list-content"
766
- }, [k(j)]), h("div", {
696
+ }, [T(O)]), v("div", {
767
697
  class: "f-list-remove",
768
- onClick: (P) => D(B)
769
- }, [h("div", {
698
+ onClick: (I) => V(P)
699
+ }, [v("div", {
770
700
  class: "f-list-remove-icon"
771
- }, [h("i", {
701
+ }, [v("i", {
772
702
  class: "f-icon f-icon-remove_face"
773
- }, null)])]), h("div", {
703
+ }, null)])]), v("div", {
774
704
  class: "f-list-handle"
775
- }, [h("div", null, [h("i", {
705
+ }, [v("div", null, [v("i", {
776
706
  class: "f-icon f-icon-drag-vertical"
777
707
  }, null)])])]);
778
708
  }
779
709
  return {
780
- renderItem: x
710
+ renderItem: $
781
711
  };
782
712
  }
783
- function Vt(e, t, n, o, c, i, u, m, S, f) {
784
- var g;
785
- const y = b(((g = e.group) == null ? void 0 : g.groupFields) || []), {
786
- collpaseGroupIconClass: a
713
+ function Dt(e, t, n, o, c, l, u, f, b, y) {
714
+ var m;
715
+ const h = C(((m = e.group) == null ? void 0 : m.groupFields) || []), {
716
+ collpaseGroupIconClass: i
787
717
  } = c, {
788
718
  toggleGroupRow: r
789
- } = f;
790
- function w(l, d) {
719
+ } = y;
720
+ function g(s, d) {
791
721
  d.collapse = !d.collapse, n.value = r(d.collapse ? "collapse" : "expand", d, n.value);
792
722
  }
793
- function s(l, d, F) {
794
- return l.layer > -1 && h("div", {
723
+ function a(s, d, k) {
724
+ return s.layer > -1 && v("div", {
795
725
  class: "f-navlookup-recentHeader",
796
- onClick: (T) => w(T, l)
797
- }, [h("div", {
726
+ onClick: (F) => g(F, s)
727
+ }, [v("div", {
798
728
  class: "fv-grid-group-row-icon"
799
- }, [h("span", {
800
- class: a(l)
801
- }, null)]), h("div", {
729
+ }, [v("span", {
730
+ class: i(s)
731
+ }, null)]), v("div", {
802
732
  class: "f-navlookup-recommandLabel"
803
- }, [l.raw[y.value[l.layer]]])]);
733
+ }, [s.raw[h.value[s.layer]]])]);
804
734
  }
805
735
  return {
806
- renderItem: s
736
+ renderItem: a
807
737
  };
808
738
  }
809
- function Dt() {
810
- const e = b(-1), t = b(""), n = b(-1), o = b(!1);
811
- function c(f, y, a) {
812
- n.value = a;
739
+ function Ot() {
740
+ const e = C(-1), t = C(""), n = C(-1), o = C(!1);
741
+ function c(y, h, i) {
742
+ n.value = i;
813
743
  }
814
- function i(f, y, a) {
815
- o.value || (n.value = a);
744
+ function l(y, h, i) {
745
+ o.value || (n.value = i);
816
746
  }
817
- function u(f, y, a) {
747
+ function u(y, h, i) {
818
748
  n.value = -1;
819
749
  }
820
- function m() {
750
+ function f() {
821
751
  o.value = !0;
822
752
  }
823
- function S() {
753
+ function b() {
824
754
  o.value = !1;
825
755
  }
826
756
  return {
@@ -828,126 +758,126 @@ function Dt() {
828
758
  focusedItemId: t,
829
759
  hoverIndex: n,
830
760
  onMouseenterItem: c,
831
- onMouseoverItem: i,
761
+ onMouseoverItem: l,
832
762
  onMouseoutItem: u,
833
- resumeHover: S,
834
- suspendHover: m
763
+ resumeHover: b,
764
+ suspendHover: f
835
765
  };
836
766
  }
837
767
  function It(e, t, n, o) {
838
- const c = b(e.idField), { dataView: i } = n, u = b(-1), m = b(!1), { activeIndex: S, focusedItemId: f, hoverIndex: y, resumeHover: a, suspendHover: r } = o;
839
- function w(d, F, T) {
840
- d.stopPropagation(), r(), F && setTimeout(() => {
841
- u.value = T, m.value = !0, F.moving = !0;
768
+ const c = C(e.idField), { dataView: l } = n, u = C(-1), f = C(!1), { activeIndex: b, focusedItemId: y, hoverIndex: h, resumeHover: i, suspendHover: r } = o;
769
+ function g(d, k, F) {
770
+ d.stopPropagation(), r(), k && setTimeout(() => {
771
+ u.value = F, f.value = !0, k.moving = !0;
842
772
  });
843
773
  }
844
- function s(d, F) {
845
- if (d.preventDefault(), u.value !== F) {
846
- const T = i.value[u.value], I = i.value;
847
- I.splice(u.value, 1), I.splice(F, 0, T), u.value = F;
774
+ function a(d, k) {
775
+ if (d.preventDefault(), u.value !== k) {
776
+ const F = l.value[u.value], D = l.value;
777
+ D.splice(u.value, 1), D.splice(k, 0, F), u.value = k;
848
778
  }
849
779
  }
850
- function g(d, F) {
780
+ function m(d, k) {
851
781
  d.preventDefault(), d.dataTransfer && (d.dataTransfer.dropEffect = "move");
852
782
  }
853
- function l(d, F) {
854
- F && (F.moving = !1), i.value.forEach((T, I) => {
855
- T.__fv_index__ = I;
856
- }), m.value = !1, a(), y.value = F.raw.__fv_index__, S.value = F.raw.__fv_index__, f.value = F.raw[c.value], t.emit("change", i.value), t.emit("activeChange", F);
783
+ function s(d, k) {
784
+ k && (k.moving = !1), l.value.forEach((F, D) => {
785
+ F.__fv_index__ = D;
786
+ }), f.value = !1, i(), h.value = k.raw.__fv_index__, b.value = k.raw.__fv_index__, y.value = k.raw[c.value], t.emit("change", l.value), t.emit("activeChange", k);
857
787
  }
858
788
  return {
859
- dragstart: w,
860
- dragenter: s,
861
- dragover: g,
862
- dragend: l,
863
- isDragging: m
789
+ dragstart: g,
790
+ dragenter: a,
791
+ dragover: m,
792
+ dragend: s,
793
+ isDragging: f
864
794
  };
865
795
  }
866
- function jt(e, t, n) {
796
+ function Pt(e, t, n) {
867
797
  const { dataView: o } = n;
868
- function c(i) {
869
- if (i > -1 && i < o.value.length) {
870
- const u = o.value.splice(i, 1);
798
+ function c(l) {
799
+ if (l > -1 && l < o.value.length) {
800
+ const u = o.value.splice(l, 1);
871
801
  t.emit("removeItem", u[0]);
872
802
  }
873
803
  }
874
804
  return { removeItem: c };
875
805
  }
876
- function Pt(e, t, n, o, c, i) {
877
- const u = b(e.idField), m = b(e.disableField), S = b(e.draggable), f = b(e.itemClass), y = b(e.selection.multiSelect ?? !1), a = b(e.selection.multiSelectMode);
878
- b(!0);
879
- const { isDragging: r } = o, { activeIndex: w, focusedItemId: s, hoverIndex: g } = c, { clearSelection: l, getSelectedItems: d, toggleSelectItem: F } = i, T = b(d());
880
- function I(k, x) {
881
- const j = {
806
+ function Bt(e, t, n, o, c, l) {
807
+ const u = C(e.idField), f = C(e.disableField), b = C(e.draggable), y = C(e.itemClass), h = C(e.selection.multiSelect ?? !1), i = C(e.selection.multiSelectMode);
808
+ C(!0);
809
+ const { isDragging: r } = o, { activeIndex: g, focusedItemId: a, hoverIndex: m } = c, { clearSelection: s, getSelectedItems: d, toggleSelectItem: k } = l, F = C(d());
810
+ function D(T, $) {
811
+ const O = {
882
812
  "f-list-view-group-item": !0,
883
- "f-list-view-draggable-item": S.value,
884
- "f-un-click": !k.checked,
885
- "f-un-select": !!k.raw[m.value],
886
- "f-listview-active": k.raw.__fv_index__ === w.value,
887
- "f-listview-hover": !r.value && x === g.value,
888
- moving: !!k.moving
813
+ "f-list-view-draggable-item": b.value,
814
+ "f-un-click": !T.checked,
815
+ "f-un-select": !!T.raw[f.value],
816
+ "f-listview-active": T.raw.__fv_index__ === g.value,
817
+ "f-listview-hover": !r.value && $ === m.value,
818
+ moving: !!T.moving
889
819
  };
890
- return f.value.split(" ").reduce((E, P) => (E[P] = !0, E), j), j;
820
+ return y.value.split(" ").reduce((E, I) => (E[I] = !0, E), O), O;
891
821
  }
892
- function C(k, x) {
893
- return k.raw[u.value] || "";
822
+ function S(T, $) {
823
+ return T.raw[u.value] || "";
894
824
  }
895
- const v = O(() => !y.value);
896
- function D(k, x, j) {
897
- k.checked = j, !k.raw[m.value] && (v.value && (s.value = k.raw[u.value]), F(k));
825
+ const w = B(() => !h.value);
826
+ function V(T, $, O) {
827
+ T.checked = O, !T.raw[f.value] && (w.value && (a.value = T.raw[u.value]), k(T));
898
828
  }
899
- const p = O(() => y.value && a.value === "OnCheckClearByClick"), V = O(() => !y.value || y.value && (a.value === "OnCheckAndClick" || a.value === "OnClick"));
900
- function A(k, x, j) {
901
- if (x.raw[m.value]) {
902
- k.preventDefault(), k.stopPropagation();
829
+ const p = B(() => h.value && i.value === "OnCheckClearByClick"), M = B(() => !h.value || h.value && (i.value === "OnCheckAndClick" || i.value === "OnClick"));
830
+ function A(T, $, O) {
831
+ if ($.raw[f.value]) {
832
+ T.preventDefault(), T.stopPropagation();
903
833
  return;
904
834
  }
905
- s.value = x.raw[u.value], w.value = j, p.value && l(n.value), V.value && (F(x), T.value = d()), t.emit("clickItem", { data: T.value, index: j }), t.emit("activeChange", T.value);
835
+ a.value = $.raw[u.value], g.value = O, p.value && s(n.value), M.value && (k($), F.value = d()), t.emit("clickItem", { data: F.value, index: O }), t.emit("activeChange", F.value);
906
836
  }
907
837
  return {
908
- getKey: C,
909
- listViewItemClass: I,
910
- onCheckItem: D,
838
+ getKey: S,
839
+ listViewItemClass: D,
840
+ onCheckItem: V,
911
841
  onClickItem: A
912
842
  };
913
843
  }
914
- function Bt(e, t, n, o, c, i, u) {
915
- const m = b(e.view), S = b(e.view === "CardView"), f = b({}), y = b("暂无数据"), a = Dt(), r = It(e, t, o, a), w = jt(e, t, o), s = Pt(e, t, n, r, a, i), g = O(() => ({
844
+ function At(e, t, n, o, c, l, u) {
845
+ const f = C(e.view), b = C(e.view === "CardView"), y = C({}), h = C("暂无数据"), i = Ot(), r = It(e, t, o, i), g = Pt(e, t, o), a = Bt(e, t, n, r, i, l), m = B(() => ({
916
846
  "f-list-view-group": !0,
917
- "d-flex": S.value,
918
- "flex-wrap": S.value
919
- })), l = O(() => !!n.value && n.value.length > 0), d = O(() => n.value.length === 0), F = O(() => d.value && !t.slots.empty);
920
- function T() {
921
- return m.value === "SingleView" ? ae : m.value === "DraggableView" ? Mt : (m.value === "ContentView" || m.value === "CardView") && t.slots.content ? kt : ae;
922
- }
923
- const I = T(), {
924
- renderItem: C
925
- } = I(e, t, n, r, c, a, s, i, w, u), {
926
- renderItem: v
927
- } = Vt(e, t, n, r, c, a, s, i, w, u), D = [C, v];
847
+ "d-flex": b.value,
848
+ "flex-wrap": b.value
849
+ })), s = B(() => !!n.value && n.value.length > 0), d = B(() => n.value.length === 0), k = B(() => d.value && !t.slots.empty);
850
+ function F() {
851
+ return f.value === "SingleView" ? le : f.value === "DraggableView" ? Vt : (f.value === "ContentView" || f.value === "CardView") && t.slots.content ? jt : le;
852
+ }
853
+ const D = F(), {
854
+ renderItem: S
855
+ } = D(e, t, n, r, c, i, a, l, g, u), {
856
+ renderItem: w
857
+ } = Dt(e, t, n, r, c, i, a, l, g, u), V = [S, w];
928
858
  function p() {
929
- return n.value.filter((k) => k.visible !== !1).map((k, x) => D[k.type](k, x, f));
859
+ return n.value.filter((T) => T.visible !== !1).map((T, $) => V[T.type](T, $, y));
930
860
  }
931
- function V() {
932
- return h("div", {
861
+ function M() {
862
+ return v("div", {
933
863
  class: "f-list-view-emptydata"
934
- }, [h("p", {
864
+ }, [v("p", {
935
865
  class: "f-empty-title"
936
- }, [y.value])]);
866
+ }, [h.value])]);
937
867
  }
938
868
  function A() {
939
- return h("ul", {
940
- class: g.value,
869
+ return v("ul", {
870
+ class: m.value,
941
871
  style: "list-style: none;"
942
- }, [l.value && p(), F.value && V(), t.slots.empty && t.slots.empty()]);
872
+ }, [s.value && p(), k.value && M(), t.slots.empty && t.slots.empty()]);
943
873
  }
944
874
  return {
945
875
  renderListArea: A
946
876
  };
947
877
  }
948
- function Ot(e, t, n) {
878
+ function $t(e, t, n) {
949
879
  function o() {
950
- return t.slots.header && h("div", {
880
+ return t.slots.header && v("div", {
951
881
  class: "f-list-view-header"
952
882
  }, [t.slots.header()]);
953
883
  }
@@ -955,100 +885,100 @@ function Ot(e, t, n) {
955
885
  renderHeader: o
956
886
  };
957
887
  }
958
- function re(e, t, n) {
959
- const o = b(e.headerClass), c = b(e.placeholder), i = b(""), u = O(() => !i.value), m = O(() => !!i.value);
960
- function S(r) {
961
- i.value = "";
888
+ function se(e, t, n) {
889
+ const o = C(e.headerClass), c = C(e.placeholder), l = C(""), u = B(() => !l.value), f = B(() => !!l.value);
890
+ function b(r) {
891
+ l.value = "";
962
892
  }
963
- N(i, (r) => {
964
- n.search(r);
893
+ N(l, (r) => {
894
+ e.enableHighlightSearch && n.search(r), t.emit("afterSearch", r);
965
895
  });
966
- const f = O(() => {
896
+ const y = B(() => {
967
897
  const r = {
968
898
  "form-group": !0,
969
899
  "farris-form-group": !0
970
900
  };
971
- return o.value && o.value.split(" ").reduce((s, g) => (s[g] = !0, s), r), r;
901
+ return o.value && o.value.split(" ").reduce((a, m) => (a[m] = !0, a), r), r;
972
902
  });
973
- function y(r) {
903
+ function h(r) {
974
904
  }
975
- function a() {
976
- return h("div", {
905
+ function i() {
906
+ return v("div", {
977
907
  class: "f-list-view-header",
978
- onClick: we(() => y, ["prevent", "stop"])
979
- }, [h("div", {
980
- class: f.value
981
- }, [h("div", {
908
+ onClick: Fe(() => h, ["prevent", "stop"])
909
+ }, [v("div", {
910
+ class: y.value
911
+ }, [v("div", {
982
912
  class: "farris-input-wrap"
983
- }, [h("div", {
913
+ }, [v("div", {
984
914
  class: "f-cmp-inputgroup"
985
- }, [h("div", {
915
+ }, [v("div", {
986
916
  class: "input-group f-state-editable"
987
- }, [Fe(h("input", {
917
+ }, [Te(v("input", {
988
918
  class: "form-control f-utils-fill text-left",
989
- "onUpdate:modelValue": (r) => i.value = r,
919
+ "onUpdate:modelValue": (r) => l.value = r,
990
920
  name: "input-group-value",
991
921
  type: "text",
992
922
  placeholder: c.value,
993
923
  autocomplete: "off"
994
- }, null), [[Te, i.value]]), h("div", {
924
+ }, null), [[Me, l.value]]), v("div", {
995
925
  class: "input-group-append"
996
- }, [m.value && h("span", {
926
+ }, [f.value && v("span", {
997
927
  class: "input-group-text input-group-clear",
998
- onClick: (r) => S()
999
- }, [h("i", {
928
+ onClick: (r) => b()
929
+ }, [v("i", {
1000
930
  class: "f-icon f-icon-close-circle"
1001
- }, null)]), u.value && h("span", {
931
+ }, null)]), u.value && v("span", {
1002
932
  class: "input-group-text"
1003
- }, [h("span", {
933
+ }, [v("span", {
1004
934
  class: "f-icon f-icon-search"
1005
935
  }, null)])])])])])])]);
1006
936
  }
1007
937
  return {
1008
- renderHeader: a
938
+ renderHeader: i
1009
939
  };
1010
940
  }
1011
- const de = /* @__PURE__ */ H({
941
+ const me = /* @__PURE__ */ H({
1012
942
  name: "FListView",
1013
- props: ue,
1014
- emits: ["checkValuesChange", "clickItem", "selectionChange", "removeItem", "change", "activeChange"],
943
+ props: fe,
944
+ emits: ["afterSearch", "checkValuesChange", "clickItem", "selectionChange", "removeItem", "change", "activeChange"],
1015
945
  setup(e, t) {
1016
- const n = b(), o = b(!0), c = b(!1), i = b([]), u = 0, m = b(e.columns), S = Ve(e), f = De(e), y = Ie(e, S), a = je(e), r = Pe(e, /* @__PURE__ */ new Map(), f, S, a), w = Be(e, r, S, i, t), s = Tt(e, n), g = O(() => r.dataView.value.length), l = Oe(e, S), d = Ae(), F = xe(e, {}, d), T = Le(e, l, f, S, d, F), I = $e(e, S, F, T), C = Ee(e, S, F, T), v = Ne(e, m, r, g, u, T, I, C), {
1017
- getVisualData: D
1018
- } = v;
1019
- i.value = D(0, g.value + u - 1);
1020
- const p = O(() => {
1021
- const L = {
946
+ const n = C(), o = C(!0), c = C(!1), l = C([]), u = 0, f = C(e.columns), b = De(e), y = Oe(e), h = Ie(e, b), i = Pe(e), r = Be(e, /* @__PURE__ */ new Map(), y, b, i), g = Ae(e, r, b, l, t), a = Mt(e, n), m = B(() => r.dataView.value.length), s = $e(e, b), d = xe(), k = Le(e, {}, d), F = Ee(e, s, y, b, d, k), D = Ne(e, b, k, F), S = He(e, b, k, F), w = Re(e, f, r, m, u, F, D, S), {
947
+ getVisualData: V
948
+ } = w;
949
+ l.value = V(0, m.value + u - 1);
950
+ const p = B(() => {
951
+ const x = {
1022
952
  "f-list-view": !0,
1023
953
  "f-list-view-multiple": e.multiSelect
1024
954
  };
1025
- return e.size !== "default" && (L[`${e.size}-item`] = !0), L;
1026
- }), V = O(() => !!t.slots.footer || o.value);
955
+ return e.size !== "default" && (x[`${e.size}-item`] = !0), x;
956
+ }), M = B(() => !!t.slots.footer || o.value);
1027
957
  function A() {
1028
- return e.header === "SearchBar" ? re : e.header === "ContentHeader" ? Ot : re;
958
+ return e.header === "SearchBar" ? se : e.header === "ContentHeader" ? $t : se;
1029
959
  }
1030
- const k = A(), {
1031
- renderHeader: x
1032
- } = k(e, t, s), {
1033
- renderListArea: j
1034
- } = Bt(e, t, i, r, y, w, v);
1035
- function B(L) {
1036
- s.search(L);
960
+ const T = A(), {
961
+ renderHeader: $
962
+ } = T(e, t, a), {
963
+ renderListArea: O
964
+ } = At(e, t, l, r, h, g, w);
965
+ function P(x) {
966
+ a.search(x);
1037
967
  }
1038
- function E(L) {
1039
- L && (r.load(L), i.value = D(0, g.value + u - 1));
968
+ function E(x) {
969
+ x && (r.load(x), l.value = V(0, m.value + u - 1));
1040
970
  }
1041
971
  t.expose({
1042
- search: B,
972
+ search: P,
1043
973
  updateDataSource: E
1044
974
  });
1045
- function P(L) {
1046
- e.multiSelect && (L.preventDefault(), L.stopPropagation());
975
+ function I(x) {
976
+ e.multiSelect && (x.preventDefault(), x.stopPropagation());
1047
977
  }
1048
- return () => h("div", {
978
+ return () => v("div", {
1049
979
  class: p.value,
1050
- onClick: P
1051
- }, [x(), h("div", {
980
+ onClick: I
981
+ }, [$(), v("div", {
1052
982
  ref: n,
1053
983
  class: "f-list-view-content",
1054
984
  onMouseover: () => {
@@ -1057,11 +987,11 @@ const de = /* @__PURE__ */ H({
1057
987
  onMouseleave: () => {
1058
988
  c.value = !1;
1059
989
  }
1060
- }, [j()]), V.value && h("div", {
990
+ }, [O()]), M.value && v("div", {
1061
991
  class: "f-list-view-footer"
1062
992
  }, [t.slots.footer && t.slots.footer()])]);
1063
993
  }
1064
- }), At = {
994
+ }), xt = {
1065
995
  /**
1066
996
  * 组件标识
1067
997
  */
@@ -1087,7 +1017,7 @@ const de = /* @__PURE__ */ H({
1087
1017
  */
1088
1018
  customClass: { type: Object, default: {} }
1089
1019
  };
1090
- function xt(e, t) {
1020
+ function Lt(e, t) {
1091
1021
  function n(o) {
1092
1022
  o.stopPropagation(), e.disabled || t.emit("click", o);
1093
1023
  }
@@ -1095,30 +1025,30 @@ function xt(e, t) {
1095
1025
  onClickButton: n
1096
1026
  };
1097
1027
  }
1098
- function Lt(e) {
1099
- const t = O(() => {
1028
+ function Et(e) {
1029
+ const t = B(() => {
1100
1030
  const o = {
1101
1031
  "f-icon": !0
1102
1032
  };
1103
1033
  if (e.icon) {
1104
1034
  const c = e.icon.trim().split(" ");
1105
- c && c.length && c.reduce((i, u) => (i[u] = !0, i), o);
1035
+ c && c.length && c.reduce((l, u) => (l[u] = !0, l), o);
1106
1036
  }
1107
1037
  return o;
1108
- }), n = O(() => !!(e.icon && e.icon.trim()));
1038
+ }), n = B(() => !!(e.icon && e.icon.trim()));
1109
1039
  return { iconClass: t, shouldShowIcon: n };
1110
1040
  }
1111
- const pe = /* @__PURE__ */ H({
1041
+ const ye = /* @__PURE__ */ H({
1112
1042
  name: "FButton",
1113
- props: At,
1043
+ props: xt,
1114
1044
  emits: ["click"],
1115
1045
  setup(e, t) {
1116
1046
  const {
1117
1047
  onClickButton: n
1118
- } = xt(e, t), {
1048
+ } = Lt(e, t), {
1119
1049
  iconClass: o,
1120
1050
  shouldShowIcon: c
1121
- } = Lt(e), i = O(() => {
1051
+ } = Et(e), l = B(() => {
1122
1052
  const u = {
1123
1053
  btn: !0,
1124
1054
  "btn-lg": e.size === "large",
@@ -1126,19 +1056,19 @@ const pe = /* @__PURE__ */ H({
1126
1056
  "btn-sm": e.size === "small",
1127
1057
  "btn-icontext": c.value
1128
1058
  };
1129
- return u[`btn-${e.type}`] = !0, e.customClass && Object.keys(e.customClass).reduce((m, S) => (m[S] = e.customClass[S], m), u), u;
1059
+ return u[`btn-${e.type}`] = !0, e.customClass && Object.keys(e.customClass).reduce((f, b) => (f[b] = e.customClass[b], f), u), u;
1130
1060
  });
1131
- return () => h("button", {
1132
- class: i.value,
1061
+ return () => v("button", {
1062
+ class: l.value,
1133
1063
  disabled: e.disabled,
1134
1064
  onClick: (u) => n(u)
1135
- }, [c.value && h("i", {
1065
+ }, [c.value && v("i", {
1136
1066
  class: o.value
1137
1067
  }, null), t.slots.default && t.slots.default()]);
1138
1068
  }
1139
- }), $t = /* @__PURE__ */ new Map([
1140
- ["appearance", J]
1141
- ]), Et = "https://json-schema.org/draft/2020-12/schema", Nt = "https://farris-design.gitee.io/combo-list.schema.json", Ht = "combo-list", Rt = "A Farris Input Component", Ut = "object", zt = {
1069
+ }), Nt = /* @__PURE__ */ new Map([
1070
+ ["appearance", ee]
1071
+ ]), Ht = "https://json-schema.org/draft/2020-12/schema", Rt = "https://farris-design.gitee.io/combo-list.schema.json", Ut = "combo-list", Gt = "A Farris Input Component", _t = "object", qt = {
1142
1072
  id: {
1143
1073
  description: "The unique identifier for a combo list",
1144
1074
  type: "string"
@@ -1249,22 +1179,22 @@ const pe = /* @__PURE__ */ H({
1249
1179
  type: "sting",
1250
1180
  default: ""
1251
1181
  }
1252
- }, Gt = [
1182
+ }, Wt = [
1253
1183
  "id",
1254
1184
  "type"
1255
- ], _t = {
1256
- $schema: Et,
1257
- $id: Nt,
1258
- title: Ht,
1259
- description: Rt,
1260
- type: Ut,
1261
- properties: zt,
1262
- required: Gt
1185
+ ], zt = {
1186
+ $schema: Ht,
1187
+ $id: Rt,
1188
+ title: Ut,
1189
+ description: Gt,
1190
+ type: _t,
1191
+ properties: qt,
1192
+ required: Wt
1263
1193
  };
1264
- function Wt(e, t, n) {
1194
+ function Jt(e, t, n) {
1265
1195
  return t;
1266
1196
  }
1267
- const ee = {
1197
+ const ne = {
1268
1198
  /**
1269
1199
  * 组件标识
1270
1200
  */
@@ -1423,8 +1353,14 @@ const ee = {
1423
1353
  /**
1424
1354
  * 打开前
1425
1355
  */
1426
- beforeOpen: { type: Function, default: null }
1427
- }, fe = Z(ee, _t, $t, Wt), qt = {
1356
+ beforeOpen: { type: Function, default: null },
1357
+ searchOption: {
1358
+ type: Object,
1359
+ default: !1
1360
+ },
1361
+ // 搜索启用高亮
1362
+ enableHighlightSearch: { type: Boolean, default: !0 }
1363
+ }, ge = K(ne, zt, Nt, Jt), Xt = {
1428
1364
  dataSource: { type: Array, default: [] },
1429
1365
  enableSearch: { type: Boolean, default: !1 },
1430
1366
  idField: { type: String, default: "id" },
@@ -1438,137 +1374,159 @@ const ee = {
1438
1374
  valueField: { type: String, default: "id" },
1439
1375
  /** 值变化事件 */
1440
1376
  onSelectionChange: { type: Function, default: () => {
1441
- } }
1377
+ } },
1378
+ searchOption: {
1379
+ type: Object,
1380
+ default: !1
1381
+ },
1382
+ // 搜索启用高亮
1383
+ enableHighlightSearch: { type: Boolean, default: !0 }
1442
1384
  }, Qt = /* @__PURE__ */ H({
1443
1385
  name: "FComboListContainer",
1444
- props: qt,
1386
+ props: Xt,
1445
1387
  emits: ["selectionChange"],
1446
1388
  setup(e, t) {
1447
- const n = b(e.dataSource), o = b([]), c = b(e.separator), i = b(e.width), u = b(e.maxHeight), m = b(String(e.selectedValues).split(c.value));
1389
+ const n = C(), o = C(e.dataSource), c = C([]), l = C(e.separator), u = C(e.width), f = C(e.maxHeight), b = C(String(e.selectedValues).split(l.value));
1448
1390
  N(e.dataSource, () => {
1449
- n.value = e.dataSource;
1391
+ o.value = e.dataSource;
1450
1392
  });
1451
- const S = O(() => e.enableSearch ? "SearchBar" : "ContentHeader"), f = O(() => {
1452
- const a = {};
1453
- return i.value !== void 0 && (a.width = `${i.value}px`), u.value !== void 0 && u.value > 0 && (a.maxHeight = `${u.value}px`), a;
1393
+ const y = B(() => e.enableSearch ? "SearchBar" : "ContentHeader"), h = B(() => {
1394
+ const g = {};
1395
+ return u.value !== void 0 && (g.width = `${u.value}px`), f.value !== void 0 && f.value > 0 && (g.maxHeight = `${f.value}px`), g;
1454
1396
  });
1455
- function y(a) {
1456
- o.value = a.map((r) => Object.assign({}, r)), m.value = a.map((r) => r[e.idField]), t.emit("selectionChange", o.value);
1397
+ function i(g) {
1398
+ c.value = g.map((a) => Object.assign({}, a)), b.value = g.map((a) => a[e.idField]), t.emit("selectionChange", c.value);
1399
+ }
1400
+ function r(g) {
1401
+ if (e.enableHighlightSearch)
1402
+ return;
1403
+ let a = [];
1404
+ typeof e.searchOption == "function" ? a = o.value.filter((m) => e.searchOption(g, m)) : a = o.value.filter((m) => m[e.valueField].indexOf(g) > -1 || m[e.textField].indexOf(g) > -1), n.value.updateDataSource(a);
1457
1405
  }
1458
- return N([() => e.selectedValues], ([a]) => {
1459
- m.value = a.split(c.value);
1460
- }), () => h("div", {
1406
+ return N([() => e.selectedValues], ([g]) => {
1407
+ b.value = g.split(l.value);
1408
+ }), () => v("div", {
1461
1409
  class: "f-combo-list-container pl-3",
1462
- style: f.value
1463
- }, [h(He, {
1410
+ style: h.value
1411
+ }, [v(Ue, {
1412
+ ref: n,
1464
1413
  size: "small",
1465
1414
  itemClass: "f-combo-list-item",
1466
- header: S.value,
1415
+ header: y.value,
1467
1416
  headerClass: "f-combo-list-search-box",
1468
- data: n.value,
1417
+ data: o.value,
1469
1418
  idField: e.idField,
1470
1419
  textField: e.textField,
1471
1420
  titleField: e.titleField,
1472
1421
  multiSelect: e.multiSelect,
1473
- multiSelectMode: "OnCheckAndClick",
1474
- selectionValues: m.value,
1475
- onSelectionChange: y
1422
+ selection: {
1423
+ enableSelectRow: !0,
1424
+ multiSelect: !0,
1425
+ multiSelectMode: "OnCheckAndClick",
1426
+ showCheckbox: !0,
1427
+ showSelectAll: !1,
1428
+ showSelection: !0
1429
+ },
1430
+ enableHighlightSearch: e.enableHighlightSearch,
1431
+ selectionValues: b.value,
1432
+ onSelectionChange: i,
1433
+ onAfterSearch: r
1476
1434
  }, null)]);
1477
1435
  }
1478
1436
  });
1479
- function Xt(e) {
1480
- const t = b(""), n = b(e.modelValue), o = b(e.data || []), c = b(e.editable);
1481
- function i(a) {
1482
- const r = String(a).split(e.separator).map((s) => [s, !0]), w = new Map(r);
1483
- return o.value.filter((s) => w.has(String(s[e.valueField])));
1437
+ function Yt(e) {
1438
+ const t = C(""), n = C(e.modelValue), o = C(e.data || []), c = C(e.editable);
1439
+ function l(i) {
1440
+ const r = String(i).split(e.separator).map((a) => [a, !0]), g = new Map(r);
1441
+ return o.value.filter((a) => g.has(String(a[e.valueField])));
1484
1442
  }
1485
- function u(a) {
1486
- const r = i(a).map((w) => w[e.textField]).join(e.separator);
1487
- t.value = c.value ? r || a : r;
1443
+ function u(i) {
1444
+ const r = l(i).map((g) => g[e.textField]).join(e.separator);
1445
+ t.value = c.value ? r || i : r;
1488
1446
  }
1489
- function m(a) {
1490
- const r = a.split(e.separator).map((s) => [s, !0]), w = new Map(r);
1491
- return o.value.filter((s) => w.has(s[e.textField]));
1447
+ function f(i) {
1448
+ const r = i.split(e.separator).map((a) => [a, !0]), g = new Map(r);
1449
+ return o.value.filter((a) => g.has(a[e.textField]));
1492
1450
  }
1493
- function S(a) {
1451
+ function b(i) {
1494
1452
  const r = {};
1495
- return r[e.idField] = a, r[e.textField] = a, [r];
1496
- }
1497
- function f(a) {
1498
- let r = m(a);
1499
- const w = r && r.length > 0;
1500
- return c.value && !w && (r = S(a)), r;
1501
- }
1502
- function y() {
1503
- const { url: a, method: r = "GET", headers: w = {}, body: s = null } = e.remote, g = r.toLowerCase() == "get" ? { method: r, headers: w } : { method: r, headers: w, body: s };
1504
- let l = !1;
1505
- fetch(a, g).then((d) => {
1506
- var T, I;
1453
+ return r[e.idField] = i, r[e.textField] = i, [r];
1454
+ }
1455
+ function y(i) {
1456
+ let r = f(i);
1457
+ const g = r && r.length > 0;
1458
+ return c.value && !g && (r = b(i)), r;
1459
+ }
1460
+ function h() {
1461
+ const { url: i, method: r = "GET", headers: g = {}, body: a = null } = e.remote, m = r.toLowerCase() == "get" ? { method: r, headers: g } : { method: r, headers: g, body: a };
1462
+ let s = !1;
1463
+ fetch(i, m).then((d) => {
1464
+ var F, D;
1507
1465
  if (d.status === 200)
1508
- return l = !!((I = (T = d.headers) == null ? void 0 : T.get("content-type")) != null && I.includes("application/json")), l ? d.text() : d.json();
1466
+ return s = !!((D = (F = d.headers) == null ? void 0 : F.get("content-type")) != null && D.includes("application/json")), s ? d.text() : d.json();
1509
1467
  throw new Error(d.statusText);
1510
1468
  }).then((d) => {
1511
- o.value = l ? JSON.parse(d) : d;
1469
+ o.value = s ? JSON.parse(d) : d;
1512
1470
  }).catch((d) => {
1513
1471
  console.error(d);
1514
1472
  });
1515
1473
  }
1516
- return e.remote && y(), N(() => e.data, () => {
1474
+ return e.remote && h(), N(() => e.data, () => {
1517
1475
  o.value = e.data;
1518
- }), N([o], ([a]) => {
1476
+ }), N([o], ([i]) => {
1519
1477
  if (e.modelValue) {
1520
- const r = a.find((w) => w[e.valueField] === e.modelValue);
1478
+ const r = i.find((g) => g[e.valueField] === e.modelValue);
1521
1479
  r && (t.value = r[e.textField]);
1522
1480
  }
1523
- }), N(() => e.modelValue, (a) => {
1524
- n.value = a, u(a);
1525
- }), u(e.modelValue), { dataSource: o, displayText: t, editable: c, modelValue: n, getItemsByDisplayText: m, getItemsByValue: i, getSelectedItemsByDisplayText: f };
1481
+ }), N(() => e.modelValue, (i) => {
1482
+ n.value = i, u(i);
1483
+ }), u(e.modelValue), { dataSource: o, displayText: t, editable: c, modelValue: n, getItemsByDisplayText: f, getItemsByValue: l, getSelectedItemsByDisplayText: y };
1526
1484
  }
1527
- const U = /* @__PURE__ */ H({
1485
+ const G = /* @__PURE__ */ H({
1528
1486
  name: "FComboList",
1529
- props: ee,
1487
+ props: ne,
1530
1488
  emits: ["clear", "update:modelValue", "change", "input"],
1531
1489
  setup(e, t) {
1532
- const n = b(), o = b(e.disabled), c = b(e.enableClear), i = b(e.enableSearch), u = b(e.readonly), {
1533
- dataSource: m,
1534
- displayText: S,
1535
- editable: f,
1536
- modelValue: y,
1537
- getSelectedItemsByDisplayText: a
1538
- } = Xt(e), r = O(() => e.multiSelect), w = O(() => n.value ? n.value.elementRef.getBoundingClientRect().width : 0);
1539
- function s() {
1490
+ const n = C(), o = C(e.disabled), c = C(e.enableClear), l = C(e.enableSearch), u = C(e.readonly), {
1491
+ dataSource: f,
1492
+ displayText: b,
1493
+ editable: y,
1494
+ modelValue: h,
1495
+ getSelectedItemsByDisplayText: i
1496
+ } = Yt(e), r = B(() => e.multiSelect), g = B(() => n.value ? n.value.elementRef.getBoundingClientRect().width : 0);
1497
+ function a() {
1540
1498
  !r.value && n.value && n.value.hidePopup();
1541
1499
  }
1542
- function g(C) {
1543
- S.value = C.map((v) => v[e.textField]).join(e.separator), C.length === 1 ? y.value = C[0][e.valueField] : y.value = C.map((v) => v[e.valueField]).join(e.separator), t.emit("update:modelValue", y.value), t.emit("change", C, y.value), s();
1500
+ function m(S) {
1501
+ b.value = S.map((w) => w[e.textField]).join(e.separator), S.length === 1 ? h.value = S[0][e.valueField] : h.value = S.map((w) => w[e.valueField]).join(e.separator), t.emit("update:modelValue", h.value), t.emit("change", S, h.value), a();
1544
1502
  }
1545
- function l() {
1503
+ function s() {
1546
1504
  u.value || n.value.togglePopup();
1547
1505
  }
1548
- function d(C) {
1549
- y.value = "", t.emit("update:modelValue", ""), t.emit("clear");
1506
+ function d(S) {
1507
+ h.value = "", t.emit("update:modelValue", ""), t.emit("clear");
1550
1508
  }
1551
- function F(C) {
1552
- const v = a(C);
1553
- g(v);
1509
+ function k(S) {
1510
+ const w = i(S);
1511
+ m(w);
1554
1512
  }
1555
- function T() {
1556
- return S.value;
1513
+ function F() {
1514
+ return b.value;
1557
1515
  }
1558
- function I(C) {
1559
- t.emit("input", C);
1516
+ function D(S) {
1517
+ t.emit("input", S);
1560
1518
  }
1561
1519
  return t.expose({
1562
- getDisplayText: T
1563
- }), N([() => e.disabled, () => e.editable, () => e.enableClear, () => e.enableSearch, () => e.readonly], ([C, v, D, p, V]) => {
1564
- o.value = C, f.value = v, c.value = D, i.value = p, u.value = V;
1565
- }), () => h(le, {
1520
+ getDisplayText: F
1521
+ }), N([() => e.disabled, () => e.editable, () => e.enableClear, () => e.enableSearch, () => e.readonly], ([S, w, V, p, M]) => {
1522
+ o.value = S, y.value = w, c.value = V, l.value = p, u.value = M;
1523
+ }), () => v(ue, {
1566
1524
  ref: n,
1567
1525
  id: e.id,
1568
1526
  disable: o.value,
1569
1527
  readonly: u.value,
1570
1528
  forcePlaceholder: e.forcePlaceholder,
1571
- editable: f.value,
1529
+ editable: y.value,
1572
1530
  buttonContent: e.dropDownIcon,
1573
1531
  placeholder: e.placeholder,
1574
1532
  enableClear: c.value,
@@ -1577,170 +1535,233 @@ const U = /* @__PURE__ */ H({
1577
1535
  enableTitle: e.enableTitle,
1578
1536
  multiSelect: e.multiSelect,
1579
1537
  inputType: e.multiSelect ? e.viewType : "text",
1580
- modelValue: S.value,
1581
- "onUpdate:modelValue": (C) => S.value = C,
1538
+ modelValue: b.value,
1539
+ "onUpdate:modelValue": (S) => b.value = S,
1582
1540
  focusOnCreated: e.focusOnCreated,
1583
1541
  selectOnCreated: e.selectOnCreated,
1584
1542
  onClear: d,
1585
- onClick: l,
1586
- onChange: F,
1587
- onInput: I,
1543
+ onClick: s,
1544
+ onChange: k,
1545
+ onInput: D,
1588
1546
  beforeOpen: e.beforeOpen
1589
1547
  }, {
1590
- default: () => [h(Qt, {
1548
+ default: () => [v(Qt, {
1591
1549
  idField: e.idField,
1592
1550
  valueField: e.valueField,
1593
1551
  textField: e.textField,
1594
1552
  titleField: e.titleField,
1595
- dataSource: m.value,
1596
- selectedValues: y.value,
1553
+ dataSource: f.value,
1554
+ selectedValues: h.value,
1597
1555
  multiSelect: e.multiSelect,
1598
- enableSearch: i.value,
1556
+ enableSearch: l.value,
1599
1557
  maxHeight: e.maxHeight,
1600
- width: e.fitEditor ? w.value : void 0,
1601
- onSelectionChange: g
1558
+ enableHighlightSearch: e.enableHighlightSearch,
1559
+ width: e.fitEditor ? g.value : void 0,
1560
+ onSelectionChange: m
1602
1561
  }, null)]
1603
1562
  });
1604
1563
  }
1605
1564
  });
1606
- function Yt(e, t) {
1565
+ function Zt(e, t) {
1607
1566
  e.schema;
1608
- const n = b(!0), o = b(!0);
1609
- function c(a) {
1567
+ const n = C(!0), o = C(!0);
1568
+ function c(i) {
1610
1569
  return !1;
1611
1570
  }
1612
- function i() {
1571
+ function l() {
1613
1572
  return !1;
1614
1573
  }
1615
1574
  function u() {
1616
1575
  return !1;
1617
1576
  }
1618
- function m() {
1577
+ function f() {
1619
1578
  return !0;
1620
1579
  }
1621
- function S(a) {
1580
+ function b(i) {
1622
1581
  }
1623
- function f() {
1582
+ function y() {
1624
1583
  }
1625
- function y(a) {
1584
+ function h(i) {
1626
1585
  return null;
1627
1586
  }
1628
1587
  return {
1629
1588
  canAccepts: c,
1630
- checkCanDeleteComponent: i,
1589
+ checkCanDeleteComponent: l,
1631
1590
  checkCanMoveComponent: u,
1632
- hideNestedPaddingInDesginerView: m,
1633
- onAcceptMovedChildElement: S,
1634
- resolveComponentContext: f,
1591
+ hideNestedPaddingInDesginerView: f,
1592
+ onAcceptMovedChildElement: b,
1593
+ resolveComponentContext: y,
1635
1594
  triggerBelongedComponentToMoveWhenMoved: n,
1636
1595
  triggerBelongedComponentToDeleteWhenDeleted: o,
1637
- getPropsConfig: y
1596
+ getPropsConfig: h
1638
1597
  };
1639
1598
  }
1640
- class me {
1599
+ class Kt {
1600
+ constructor(t, n) {
1601
+ L(this, "componentId");
1602
+ L(this, "viewModelId");
1603
+ L(this, "eventsEditorUtils");
1604
+ L(this, "formSchemaUtils");
1605
+ L(this, "formMetadataConverter");
1606
+ L(this, "designViewModelUtils");
1607
+ L(this, "designViewModelField");
1608
+ L(this, "controlCreatorUtils");
1609
+ L(this, "designerHostService");
1610
+ L(this, "schemaService", null);
1611
+ L(this, "metadataService", null);
1612
+ L(this, "propertyConfig", {
1613
+ type: "object",
1614
+ categories: {}
1615
+ });
1616
+ var o;
1617
+ 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;
1618
+ }
1619
+ getTableInfo() {
1620
+ var t;
1621
+ return (t = this.schemaService) == null ? void 0 : t.getTableInfoByViewModelId(this.viewModelId);
1622
+ }
1623
+ setDesignViewModelField(t) {
1624
+ const n = t.binding && t.binding.type === "Form" && t.binding.field;
1625
+ if (n) {
1626
+ if (!this.designViewModelField) {
1627
+ const o = this.designViewModelUtils.getDgViewModel(this.viewModelId);
1628
+ this.designViewModelField = o.fields.find((c) => c.id === n);
1629
+ }
1630
+ t.updateOn = this.designViewModelField.updateOn;
1631
+ }
1632
+ }
1633
+ changeFieldEditorType(t, n) {
1634
+ }
1635
+ getBasicPropConfig(t) {
1636
+ return {
1637
+ description: "Basic Information",
1638
+ title: "基本信息",
1639
+ properties: {
1640
+ id: {
1641
+ description: "组件标识",
1642
+ title: "标识",
1643
+ type: "string",
1644
+ readonly: !0
1645
+ },
1646
+ type: {
1647
+ description: "组件类型",
1648
+ title: "控件类型",
1649
+ type: "select",
1650
+ editor: {
1651
+ type: "combo-list",
1652
+ textField: "name",
1653
+ valueField: "value",
1654
+ data: [{ value: t.type, name: j[t.type].name }]
1655
+ }
1656
+ }
1657
+ }
1658
+ };
1659
+ }
1660
+ getAppearanceConfig(t = null) {
1661
+ return {
1662
+ title: "样式",
1663
+ description: "Appearance",
1664
+ properties: {
1665
+ class: {
1666
+ title: "class样式",
1667
+ type: "string",
1668
+ description: "组件的CSS样式",
1669
+ $converter: "/converter/appearance.converter"
1670
+ },
1671
+ style: {
1672
+ title: "style样式",
1673
+ type: "string",
1674
+ description: "组件的样式",
1675
+ $converter: "/converter/appearance.converter"
1676
+ }
1677
+ }
1678
+ };
1679
+ }
1680
+ }
1681
+ const R = class R {
1682
+ /**
1683
+ * 根据绑定字段类型获取可用的输入类控件
1684
+ */
1641
1685
  static getEditorTypesByMDataType(t) {
1642
- const n = this.fieldControlTypeMapping[t];
1686
+ const n = R.fieldControlTypeMapping[t];
1643
1687
  return n || [{ key: "", value: "" }];
1644
1688
  }
1645
- }
1689
+ /**
1690
+ * 获取所有输入类控件
1691
+ */
1692
+ static getAllInputTypes() {
1693
+ const t = [];
1694
+ for (let n in R.fieldControlTypeMapping)
1695
+ R.fieldControlTypeMapping[n].forEach((o) => {
1696
+ t.find((c) => c.key === o.key && c.value === o.value) || t.push({ key: o.key, value: o.value });
1697
+ });
1698
+ return t;
1699
+ }
1700
+ };
1646
1701
  /**
1647
1702
  * <字段类型,可配置的控件类型列表>的映射
1648
1703
  */
1649
- $(me, "fieldControlTypeMapping", {
1704
+ L(R, "fieldControlTypeMapping", {
1650
1705
  String: [
1651
- { key: M["input-group"].type, value: M["input-group"].name },
1652
- { key: M.lookup.type, value: M.lookup.name },
1653
- { key: M.Image.type, value: M.Image.name },
1654
- { key: M["date-picker"].type, value: M["date-picker"].name },
1655
- { key: M["check-box"].type, value: M["check-box"].name },
1656
- { key: M["radio-group"].type, value: M["radio-group"].name },
1657
- { key: M["combo-list"].type, value: M["combo-list"].name },
1658
- { key: M.textarea.type, value: M.textarea.name }
1659
- // { key: DgControl.Tags.type, value: DgControl.Tags.name },
1706
+ { key: j["input-group"].type, value: j["input-group"].name },
1707
+ { key: j.lookup.type, value: j.lookup.name },
1708
+ { key: j["date-picker"].type, value: j["date-picker"].name },
1709
+ { key: j["check-box"].type, value: j["check-box"].name },
1710
+ { key: j["radio-group"].type, value: j["radio-group"].name },
1711
+ { key: j["combo-list"].type, value: j["combo-list"].name },
1712
+ { key: j.textarea.type, value: j.textarea.name }
1660
1713
  ],
1661
1714
  Text: [
1662
- { key: M.textarea.type, value: M.textarea.name },
1663
- { key: M.avatar.type, value: M.avatar.name },
1664
- { key: M.lookup.type, value: M.lookup.name }
1715
+ { key: j.textarea.type, value: j.textarea.name },
1716
+ { key: j.lookup.type, value: j.lookup.name }
1665
1717
  ],
1666
1718
  Decimal: [
1667
- { key: M["number-spinner"].type, value: M["number-spinner"].name }
1719
+ { key: j["number-spinner"].type, value: j["number-spinner"].name }
1668
1720
  ],
1669
1721
  Integer: [
1670
- { key: M["number-spinner"].type, value: M["number-spinner"].name }
1722
+ { key: j["number-spinner"].type, value: j["number-spinner"].name }
1671
1723
  ],
1672
1724
  Number: [
1673
- { key: M["number-spinner"].type, value: M["number-spinner"].name }
1725
+ { key: j["number-spinner"].type, value: j["number-spinner"].name }
1674
1726
  ],
1675
1727
  BigNumber: [
1676
- { key: M["number-spinner"].type, value: M["number-spinner"].name }
1728
+ { key: j["number-spinner"].type, value: j["number-spinner"].name }
1677
1729
  ],
1678
1730
  Date: [
1679
- { key: M["date-picker"].type, value: M["date-picker"].name }
1731
+ { key: j["date-picker"].type, value: j["date-picker"].name }
1680
1732
  ],
1681
1733
  DateTime: [
1682
- { key: M["date-picker"].type, value: M["date-picker"].name }
1734
+ { key: j["date-picker"].type, value: j["date-picker"].name }
1683
1735
  ],
1684
1736
  Boolean: [
1685
- { key: M.switch.type, value: M.switch.name },
1686
- { key: M["check-box"].type, value: M["check-box"].name }
1737
+ { key: j.switch.type, value: j.switch.name },
1738
+ { key: j["check-box"].type, value: j["check-box"].name }
1687
1739
  ],
1688
1740
  Enum: [
1689
- { key: M["combo-list"].type, value: M["combo-list"].name },
1690
- { key: M["radio-group"].type, value: M["radio-group"].name }
1741
+ { key: j["combo-list"].type, value: j["combo-list"].name },
1742
+ { key: j["radio-group"].type, value: j["radio-group"].name }
1691
1743
  ],
1692
1744
  Object: [
1693
- { key: M.lookup.type, value: M.lookup.name },
1694
- { key: M["combo-list"].type, value: M["combo-list"].name },
1695
- { key: M["radio-group"].type, value: M["radio-group"].name }
1696
- ],
1697
- EmployeeSelector: [
1698
- { key: M.EmployeeSelector.type, value: M.EmployeeSelector.name }
1699
- ],
1700
- AdminOrganizationSelector: [
1701
- { key: M.AdminOrganizationSelector.type, value: M.AdminOrganizationSelector.name }
1745
+ { key: j.lookup.type, value: j.lookup.name },
1746
+ { key: j["combo-list"].type, value: j["combo-list"].name },
1747
+ { key: j["radio-group"].type, value: j["radio-group"].name }
1702
1748
  ]
1703
1749
  });
1704
- class Zt {
1750
+ let _ = R;
1751
+ const en = C(0);
1752
+ class tn extends Kt {
1705
1753
  constructor(t, n) {
1706
- $(this, "componentId");
1707
- $(this, "viewModelId");
1708
- $(this, "eventsEditorUtils");
1709
- $(this, "formSchemaUtils");
1710
- $(this, "formMetadataConverter");
1711
- $(this, "designViewModelUtils");
1712
- $(this, "designViewModelField");
1713
- $(this, "controlCreatorUtils");
1714
- $(this, "designerHostService");
1715
- $(this, "schemaService", null);
1716
- $(this, "metadataService", null);
1717
- $(this, "propertyConfig", {
1718
- type: "object",
1719
- categories: {}
1720
- });
1721
- var o;
1722
- 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;
1723
- }
1724
- getTableInfo() {
1725
- var t;
1726
- return (t = this.schemaService) == null ? void 0 : t.getTableInfoByViewModelId(this.viewModelId);
1727
- }
1728
- setDesignViewModelField(t) {
1729
- const n = t.binding && t.binding.type === "Form" && t.binding.field;
1730
- if (n) {
1731
- if (!this.designViewModelField) {
1732
- const o = this.designViewModelUtils.getDgViewModel(this.viewModelId);
1733
- this.designViewModelField = o.fields.find((c) => c.id === n);
1734
- }
1735
- t.updateOn = this.designViewModelField.updateOn;
1736
- }
1754
+ super(t, n);
1737
1755
  }
1738
- changeFieldEditorType(t, n) {
1756
+ getPropertyConfig(t, n) {
1757
+ return this.propertyConfig.categories.basic = this.getBasicProperties(t, n), this.propertyConfig.categories.appearance = this.getAppearanceProperties(t), this.propertyConfig.categories.editor = this.getEditorProperties(t), this.propertyConfig;
1739
1758
  }
1740
- getBasicPropConfig(t) {
1741
- var o, c;
1742
- var n = this;
1743
- return this.setDesignViewModelField(t), {
1759
+ getBasicProperties(t, n) {
1760
+ var u;
1761
+ var o = this;
1762
+ this.setDesignViewModelField(t);
1763
+ const c = this.formSchemaUtils.getFormMetadataBasicInfo(), l = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
1764
+ return {
1744
1765
  description: "Basic Information",
1745
1766
  title: "基本信息",
1746
1767
  properties: {
@@ -1760,63 +1781,48 @@ class Zt {
1760
1781
  type: "combo-list",
1761
1782
  textField: "value",
1762
1783
  valueField: "key",
1763
- data: me.getEditorTypesByMDataType(((c = (o = n.designViewModelField) == null ? void 0 : o.type) == null ? void 0 : c.name) || ""),
1764
- editable: !1
1784
+ editable: !1,
1785
+ data: o.designViewModelField ? _.getEditorTypesByMDataType((u = o.designViewModelField.type) == null ? void 0 : u.name) : _.getAllInputTypes()
1765
1786
  }
1766
1787
  },
1767
1788
  label: {
1768
1789
  title: "标签",
1769
1790
  type: "string",
1770
1791
  $converter: "/converter/form-group-label.converter"
1792
+ },
1793
+ binding: {
1794
+ description: "绑定的表单字段",
1795
+ title: "绑定",
1796
+ $converter: "/converter/field-selector.converter",
1797
+ editor: {
1798
+ type: "field-selector",
1799
+ bindingType: { enable: !1 },
1800
+ editorParams: {
1801
+ propertyData: t,
1802
+ formBasicInfo: c
1803
+ },
1804
+ columns: [
1805
+ { field: "name", title: "字段名称" },
1806
+ { field: "bindingField", title: "绑定字段" },
1807
+ { field: "fieldType", title: "字段类型" }
1808
+ ],
1809
+ textField: "bindingField",
1810
+ data: l
1811
+ }
1771
1812
  }
1772
1813
  },
1773
- setPropertyRelates(i, u) {
1774
- if (i)
1775
- switch (i && i.propertyID) {
1814
+ setPropertyRelates(f, b) {
1815
+ if (f)
1816
+ switch (f && f.propertyID) {
1776
1817
  case "type": {
1777
- n.changeControlType(t, i);
1818
+ o.changeControlType(t, f, n);
1778
1819
  break;
1779
1820
  }
1780
1821
  }
1781
1822
  }
1782
1823
  };
1783
1824
  }
1784
- /**
1785
- * 卡片控件:切换控件类型后事件
1786
- * @param propertyData 控件DOM属性
1787
- * @param newControlType 新控件类型
1788
- */
1789
- changeControlType(t, n) {
1790
- var f, y, a, r, w;
1791
- const o = n.propertyValue, c = this.formSchemaUtils.getComponentById(this.componentId);
1792
- let i = this.getControlParentContainer(t.id, c);
1793
- if (!i)
1794
- return;
1795
- const u = i.contents.findIndex((s) => s.id === t.id), m = i.contents[u];
1796
- let S;
1797
- this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
1798
- editor: {
1799
- $type: o
1800
- },
1801
- name: this.designViewModelField.name,
1802
- require: this.designViewModelField.require,
1803
- readonly: this.designViewModelField.readonly
1804
- }, !1), S = this.controlCreatorUtils.setFormFieldProperty("Form", this.designViewModelField, null, o)), Object.assign(S, {
1805
- id: m.id,
1806
- appearance: m.appearance,
1807
- size: m.size,
1808
- label: m.label
1809
- }), Object.assign(S.editor, {
1810
- isTextArea: S.isTextArea && m.isTextArea,
1811
- type: o || "",
1812
- placeHolder: (f = m.editor) == null ? void 0 : f.placeHolder,
1813
- holdPlace: (y = m.editor) == null ? void 0 : y.holdPlace,
1814
- readonly: (a = m.editor) == null ? void 0 : a.readonly,
1815
- require: (r = m.editor) == null ? void 0 : r.require,
1816
- visible: (w = m.editor) == null ? void 0 : w.visible
1817
- }), i.contents.splice(u, 1, S);
1818
- }
1819
- getAppearanceConfig(t = null) {
1825
+ getAppearanceProperties(t) {
1820
1826
  return {
1821
1827
  title: "样式",
1822
1828
  description: "Appearance",
@@ -1846,82 +1852,44 @@ class Zt {
1846
1852
  }
1847
1853
  };
1848
1854
  }
1849
- /**
1850
- * 获取控件:以contents为节点进行定位
1851
- * @param controlId 控件ID
1852
- * @param domJson 容器
1853
- */
1854
- getControlParentContainer(t, n) {
1855
- let o;
1856
- if (!n || !n.contents || n.contents.length === 0)
1857
- return null;
1858
- for (const c of n.contents) {
1859
- if (c.id === t)
1860
- return o = n, n;
1861
- if (o = this.getControlParentContainer(t, c), o)
1862
- return o;
1863
- }
1864
- }
1865
- getBindingFieldEditorOptions(t) {
1866
- const n = this.formSchemaUtils.getFormMetadataBasicInfo();
1867
- return {
1868
- type: "field-selector",
1869
- bindingType: { enable: !1 },
1870
- editorParams: {
1871
- propertyData: t,
1872
- formBasicInfo: n
1873
- },
1874
- columns: [
1875
- { field: "name", title: "字段名称" },
1876
- { field: "bindingField", title: "绑定字段" },
1877
- { field: "fieldType", title: "字段类型" }
1878
- ],
1879
- beforeOpenDialog: (o) => {
1880
- const c = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
1881
- o.instance.loadData(c);
1882
- },
1883
- textField: "bindingField"
1884
- };
1885
- }
1886
- }
1887
- class Jt extends Zt {
1888
- constructor(t, n) {
1889
- super(t, n);
1890
- }
1891
- getBasicProperties(t) {
1892
- let n = this.getBasicPropConfig(t);
1893
- return n.properties.binding = this.getFieldSelectorOptions(t), n;
1894
- }
1895
- getAppearanceProperties(t) {
1896
- return this.getAppearanceConfig(t);
1897
- }
1898
1855
  getEditorProperties(t) {
1899
1856
  return this.getComponentConfig(t);
1900
1857
  }
1901
- getPropertyConfig(t) {
1902
- return this.propertyConfig.categories.basic = this.getBasicProperties(t), this.propertyConfig.categories.appearance = this.getAppearanceProperties(t), this.propertyConfig.categories.editor = this.getEditorProperties(t), this.propertyConfig;
1903
- }
1904
- getFieldSelectorOptions(t) {
1905
- const n = this.formSchemaUtils.getFormMetadataBasicInfo(), o = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
1906
- return {
1907
- description: "绑定的表单字段",
1908
- title: "绑定",
1909
- $converter: "/converter/field-selector.converter",
1858
+ /**
1859
+ * 卡片控件:切换控件类型后事件
1860
+ * @param propertyData 控件DOM属性
1861
+ * @param newControlType 新控件类型
1862
+ */
1863
+ changeControlType(t, n, o) {
1864
+ var y, h, i, r;
1865
+ const c = n.propertyValue, l = o && o.parent && o.parent.schema;
1866
+ if (!l)
1867
+ return;
1868
+ const u = l.contents.findIndex((g) => g.id === t.id), f = l.contents[u];
1869
+ let b;
1870
+ this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
1910
1871
  editor: {
1911
- type: "field-selector",
1912
- bindingType: { enable: !1 },
1913
- editorParams: {
1914
- propertyData: t,
1915
- formBasicInfo: n
1916
- },
1917
- columns: [
1918
- { field: "name", title: "字段名称" },
1919
- { field: "bindingField", title: "绑定字段" },
1920
- { field: "fieldType", title: "字段类型" }
1921
- ],
1922
- data: o
1923
- }
1924
- };
1872
+ $type: c
1873
+ },
1874
+ name: this.designViewModelField.name,
1875
+ require: this.designViewModelField.require,
1876
+ readonly: this.designViewModelField.readonly
1877
+ }, !1), b = this.controlCreatorUtils.setFormFieldProperty(this.designViewModelField, c)), b || (b = re("form-group") || {}, b.editor = re(c) || {}, delete b.editor.id, delete b.editor.binding, delete b.editor.appearance), Object.assign(b, {
1878
+ id: f.id,
1879
+ appearance: f.appearance,
1880
+ size: f.size,
1881
+ label: f.label,
1882
+ binding: f.binding,
1883
+ visible: f.visible
1884
+ }), Object.assign(b.editor, {
1885
+ isTextArea: b.isTextArea && f.isTextArea,
1886
+ placeholder: (y = f.editor) == null ? void 0 : y.placeholder,
1887
+ holdPlace: (h = f.editor) == null ? void 0 : h.holdPlace,
1888
+ readonly: (i = f.editor) == null ? void 0 : i.readonly,
1889
+ require: (r = f.editor) == null ? void 0 : r.require
1890
+ }), l.contents.splice(u, 1), l.contents.splice(u, 0, b), o.schema = Object.assign(f, b), Array.from(document.getElementsByClassName("dgComponentSelected")).forEach(
1891
+ (g) => g.classList.remove("dgComponentSelected")
1892
+ ), en.value++;
1925
1893
  }
1926
1894
  getComponentConfig(t, n = {}, o = {}) {
1927
1895
  const c = Object.assign({
@@ -1929,7 +1897,7 @@ class Jt extends Zt {
1929
1897
  title: "组件信息",
1930
1898
  type: "input-group",
1931
1899
  $converter: "/converter/property-editor.converter"
1932
- }, n), i = Object.assign({
1900
+ }, n), l = Object.assign({
1933
1901
  readonly: {
1934
1902
  description: "",
1935
1903
  title: "只读",
@@ -1951,10 +1919,10 @@ class Jt extends Zt {
1951
1919
  type: "string"
1952
1920
  }
1953
1921
  }, o);
1954
- return { ...c, properties: { ...i } };
1922
+ return { ...c, properties: { ...l } };
1955
1923
  }
1956
1924
  }
1957
- class Kt extends Jt {
1925
+ class nn extends tn {
1958
1926
  constructor(t, n) {
1959
1927
  super(t, n);
1960
1928
  }
@@ -1978,41 +1946,41 @@ class Kt extends Jt {
1978
1946
  });
1979
1947
  }
1980
1948
  }
1981
- function en(e, t) {
1949
+ function on(e, t) {
1982
1950
  const {
1983
1951
  canAccepts: n,
1984
1952
  checkCanDeleteComponent: o,
1985
1953
  checkCanMoveComponent: c,
1986
- hideNestedPaddingInDesginerView: i,
1954
+ hideNestedPaddingInDesginerView: l,
1987
1955
  onAcceptMovedChildElement: u,
1988
- resolveComponentContext: m,
1989
- triggerBelongedComponentToMoveWhenMoved: S,
1990
- triggerBelongedComponentToDeleteWhenDeleted: f
1991
- } = Yt(e), y = e.schema;
1992
- function a(r) {
1993
- return new Kt(r, t).getPropertyConfig(y);
1956
+ resolveComponentContext: f,
1957
+ triggerBelongedComponentToMoveWhenMoved: b,
1958
+ triggerBelongedComponentToDeleteWhenDeleted: y
1959
+ } = Zt(e), h = e.schema;
1960
+ function i(r, g) {
1961
+ return new nn(r, t).getPropertyConfig(h, g);
1994
1962
  }
1995
1963
  return {
1996
1964
  canAccepts: n,
1997
1965
  checkCanDeleteComponent: o,
1998
1966
  checkCanMoveComponent: c,
1999
- hideNestedPaddingInDesginerView: i,
1967
+ hideNestedPaddingInDesginerView: l,
2000
1968
  onAcceptMovedChildElement: u,
2001
- resolveComponentContext: m,
2002
- triggerBelongedComponentToMoveWhenMoved: S,
2003
- triggerBelongedComponentToDeleteWhenDeleted: f,
2004
- getPropsConfig: a
1969
+ resolveComponentContext: f,
1970
+ triggerBelongedComponentToMoveWhenMoved: b,
1971
+ triggerBelongedComponentToDeleteWhenDeleted: y,
1972
+ getPropsConfig: i
2005
1973
  };
2006
1974
  }
2007
- const tn = /* @__PURE__ */ H({
1975
+ const an = /* @__PURE__ */ H({
2008
1976
  name: "FComboListDesign",
2009
- props: ee,
1977
+ props: ne,
2010
1978
  emits: ["clear", "update:modelValue", "change"],
2011
1979
  setup(e, t) {
2012
- const n = b(), o = q("designer-host-service"), c = q("design-item-context"), i = en(c, o), u = Re(n, c, i);
2013
- return ie(() => {
1980
+ const n = C(), o = X("designer-host-service"), c = X("design-item-context"), l = on(c, o), u = Ge(n, c, l);
1981
+ return ce(() => {
2014
1982
  n.value.componentInstance = u;
2015
- }), t.expose(u.value), () => h(le, {
1983
+ }), t.expose(u.value), () => v(ue, {
2016
1984
  ref: n,
2017
1985
  id: e.id,
2018
1986
  disable: e.disabled,
@@ -2029,222 +1997,222 @@ const tn = /* @__PURE__ */ H({
2029
1997
  inputType: e.multiSelect ? "tag" : "text"
2030
1998
  }, null);
2031
1999
  }
2032
- }), nn = (e) => {
2000
+ }), rn = (e) => {
2033
2001
  const t = e;
2034
2002
  return t.install = function(n) {
2035
2003
  n.component(t.name, e);
2036
2004
  }, e;
2037
2005
  };
2038
- U.register = (e, t, n, o) => {
2039
- e["combo-list"] = U, t["combo-list"] = fe;
2006
+ G.register = (e, t, n, o) => {
2007
+ e["combo-list"] = G, t["combo-list"] = ge;
2040
2008
  };
2041
- U.registerDesigner = (e, t, n) => {
2042
- e["combo-list"] = tn, t["combo-list"] = fe;
2009
+ G.registerDesigner = (e, t, n) => {
2010
+ e["combo-list"] = an, t["combo-list"] = ge;
2043
2011
  };
2044
- const z = nn(U), _ = /* @__PURE__ */ H({
2012
+ const q = rn(G), z = /* @__PURE__ */ H({
2045
2013
  name: "FOrder",
2046
- props: K,
2014
+ props: te,
2047
2015
  emits: ["change"],
2048
2016
  setup(e, t) {
2049
- const n = b(e.items), o = b("排序列"), c = b("排序方式"), i = b("添加排序列"), u = [{
2017
+ const n = C(e.items), o = C("排序列"), c = C("排序方式"), l = C("添加排序列"), u = [{
2050
2018
  id: "asc",
2051
2019
  name: "升序"
2052
2020
  }, {
2053
2021
  id: "desc",
2054
2022
  name: "降序"
2055
- }], m = b(/* @__PURE__ */ new Map());
2056
- function S() {
2057
- const l = n.value.map((d) => [d.id, !0]);
2058
- m.value = new Map(l);
2023
+ }], f = C(/* @__PURE__ */ new Map());
2024
+ function b() {
2025
+ const s = n.value.map((d) => [d.id, !0]);
2026
+ f.value = new Map(s);
2059
2027
  }
2060
- S();
2061
- const f = O(() => e.dataSource.map((l) => (l.disabled = m.value.has(l.id), l))), y = O(() => ({
2028
+ b();
2029
+ const y = B(() => e.dataSource.map((s) => (s.disabled = f.value.has(s.id), s))), h = B(() => ({
2062
2030
  "f-order": !0
2063
2031
  }));
2064
- function a(l) {
2065
- n.value = n.value.filter((d) => d.id !== l.id), S(), t.emit("change", n.value);
2032
+ function i(s) {
2033
+ n.value = n.value.filter((d) => d.id !== s.id), b(), t.emit("change", n.value);
2066
2034
  }
2067
2035
  function r() {
2068
2036
  n.value = [...n.value, {
2069
2037
  id: Date.now().toString(),
2070
2038
  name: "",
2071
2039
  order: "asc"
2072
- }], S(), t.emit("change", n.value);
2040
+ }], b(), t.emit("change", n.value);
2073
2041
  }
2074
- function w(l) {
2075
- if (l && l.length === 1) {
2076
- const d = l[0], F = n.value.find((T) => T.id === d.id);
2077
- F && (F.name = d.name);
2042
+ function g(s) {
2043
+ if (s && s.length === 1) {
2044
+ const d = s[0], k = n.value.find((F) => F.id === d.id);
2045
+ k && (k.name = d.name);
2078
2046
  }
2079
- S(), t.emit("change", n.value);
2047
+ b(), t.emit("change", n.value);
2080
2048
  }
2081
- function s(l) {
2082
- if (l && l.length) {
2049
+ function a(s) {
2050
+ if (s && s.length) {
2083
2051
  const d = /* @__PURE__ */ new Map();
2084
- l.reduce((F, T) => (F.set(T.id, T), F), d), n.value = l.map((F) => d.get(F.id)), t.emit("change", n.value);
2052
+ s.reduce((k, F) => (k.set(F.id, F), k), d), n.value = s.map((k) => d.get(k.id)), t.emit("change", n.value);
2085
2053
  }
2086
2054
  }
2087
- function g() {
2088
- return h(de, {
2055
+ function m() {
2056
+ return v(me, {
2089
2057
  style: "flex:1",
2090
2058
  data: n.value,
2091
2059
  draggable: !0,
2092
2060
  view: "DraggableView",
2093
2061
  "keep-order": !0,
2094
2062
  itemClass: "f-order-item",
2095
- onRemoveItem: a,
2096
- onChange: s
2063
+ onRemoveItem: i,
2064
+ onChange: a
2097
2065
  }, {
2098
- header: () => h("div", {
2066
+ header: () => v("div", {
2099
2067
  class: "f-order-header"
2100
- }, [h("span", {
2068
+ }, [v("span", {
2101
2069
  class: "f-order-header-order-field"
2102
- }, [o.value]), h("span", {
2070
+ }, [o.value]), v("span", {
2103
2071
  class: "f-order-header-order-type"
2104
2072
  }, [c.value])]),
2105
- itemContent: (l) => h("div", {
2073
+ itemContent: (s) => v("div", {
2106
2074
  class: "f-order-item-content"
2107
- }, [h(z, {
2075
+ }, [v(q, {
2108
2076
  class: "f-order-item-content-order-field",
2109
- data: f.value,
2077
+ data: y.value,
2110
2078
  valueField: "id",
2111
2079
  textField: "name",
2112
2080
  idField: "id",
2113
- modelValue: l.id,
2114
- "onUpdate:modelValue": (d) => l.id = d,
2115
- onChange: w,
2116
- onClear: w
2117
- }, null), h(z, {
2081
+ modelValue: s.id,
2082
+ "onUpdate:modelValue": (d) => s.id = d,
2083
+ onChange: g,
2084
+ onClear: g
2085
+ }, null), v(q, {
2118
2086
  class: "f-order-item-content-order-type",
2119
2087
  data: u,
2120
2088
  valueField: "id",
2121
2089
  textField: "name",
2122
2090
  idField: "id",
2123
- modelValue: l.order,
2124
- "onUpdate:modelValue": (d) => l.order = d,
2125
- onChange: w
2091
+ modelValue: s.order,
2092
+ "onUpdate:modelValue": (d) => s.order = d,
2093
+ onChange: g
2126
2094
  }, null)]),
2127
- footer: () => h("div", {
2095
+ footer: () => v("div", {
2128
2096
  class: "f-order-footer"
2129
- }, [h(pe, {
2097
+ }, [v(ye, {
2130
2098
  type: "link",
2131
2099
  class: "f-order-add-button",
2132
2100
  onClick: r
2133
2101
  }, {
2134
- default: () => h(Q, null, [h("span", {
2102
+ default: () => v(Q, null, [v("span", {
2135
2103
  class: "f-order-add-icon"
2136
- }, [h("i", {
2104
+ }, [v("i", {
2137
2105
  class: "f-icon f-icon-add"
2138
- }, null)]), i.value])
2106
+ }, null)]), l.value])
2139
2107
  })])
2140
2108
  });
2141
2109
  }
2142
- return () => h("div", {
2143
- class: y.value
2144
- }, [g()]);
2110
+ return () => v("div", {
2111
+ class: h.value
2112
+ }, [m()]);
2145
2113
  }
2146
2114
  });
2147
- function on(e, t, n) {
2148
- var C;
2115
+ function ln(e, t, n) {
2116
+ var S;
2149
2117
  function o() {
2150
2118
  n != null && n.resolveComponentContext && n.resolveComponentContext();
2151
2119
  }
2152
2120
  o();
2153
- const c = n && n.getStyles && n.getStyles() || "", i = n && n.getDesignerClass && n.getDesignerClass() || "", u = b();
2154
- function m() {
2121
+ const c = n && n.getStyles && n.getStyles() || "", l = n && n.getDesignerClass && n.getDesignerClass() || "", u = C();
2122
+ function f() {
2155
2123
  return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 : n && n.checkCanMoveComponent ? n.checkCanMoveComponent() : !0;
2156
2124
  }
2157
- function S() {
2125
+ function b() {
2158
2126
  return !1;
2159
2127
  }
2160
- function f() {
2128
+ function y() {
2161
2129
  return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 : n && n.checkCanDeleteComponent ? n.checkCanDeleteComponent() : !0;
2162
2130
  }
2163
- function y() {
2131
+ function h() {
2164
2132
  return (t == null ? void 0 : t.schema.componentType) === "frame" ? !0 : n && n.hideNestedPaddingInDesginerView ? n.hideNestedPaddingInDesginerView() : !1;
2165
2133
  }
2166
- function a(v) {
2167
- if (!v || !v.value)
2134
+ function i(w) {
2135
+ if (!w || !w.value)
2168
2136
  return null;
2169
- if (v.value.schema && v.value.schema.type === "component")
2170
- return v.value;
2171
- const D = b(v == null ? void 0 : v.value.parent), p = a(D);
2137
+ if (w.value.schema && w.value.schema.type === "component")
2138
+ return w.value;
2139
+ const V = C(w == null ? void 0 : w.value.parent), p = i(V);
2172
2140
  return p || null;
2173
2141
  }
2174
- function r(v = t) {
2175
- const { componentInstance: D, designerItemElementRef: p } = v;
2176
- return !D || !D.value ? null : D.value.canMove ? p : r(v.parent);
2142
+ function r(w = t) {
2143
+ const { componentInstance: V, designerItemElementRef: p } = w;
2144
+ return !V || !V.value ? null : V.value.canMove ? p : r(w.parent);
2177
2145
  }
2178
- function w(v) {
2179
- return !!n && n.canAccepts(v);
2146
+ function g(w) {
2147
+ return !!n && n.canAccepts(w);
2180
2148
  }
2181
- function s() {
2149
+ function a() {
2182
2150
  return (t == null ? void 0 : t.schema.label) || (t == null ? void 0 : t.schema.title) || (t == null ? void 0 : t.schema.name);
2183
2151
  }
2184
- function g() {
2152
+ function m() {
2185
2153
  }
2186
- function l(v, D) {
2187
- D && n != null && n.onAcceptMovedChildElement && n.onAcceptMovedChildElement(D);
2154
+ function s(w, V) {
2155
+ V && n != null && n.onAcceptMovedChildElement && n.onAcceptMovedChildElement(V);
2188
2156
  }
2189
- function d(v) {
2190
- const { componentType: D } = v;
2191
- let p = R(D, v);
2192
- n && n.onResolveNewComponentSchema && (p = n.onResolveNewComponentSchema(v, p));
2193
- const V = D.toLowerCase().replace("-", "_");
2194
- return p && !p.id && p.type === D && (p.id = `${V}_${Math.random().toString().slice(2, 6)}`), p;
2157
+ function d(w) {
2158
+ const { componentType: V } = w;
2159
+ let p = U(V, w);
2160
+ n && n.onResolveNewComponentSchema && (p = n.onResolveNewComponentSchema(w, p));
2161
+ const M = V.toLowerCase().replace("-", "_");
2162
+ return p && !p.id && p.type === V && (p.id = `${M}_${Math.random().toString().slice(2, 6)}`), p;
2195
2163
  }
2196
- function F(v, D) {
2197
- const p = String(v.getAttribute("data-controltype")), V = v.getAttribute("data-feature"), A = V ? JSON.parse(V) : {};
2164
+ function k(w, V) {
2165
+ const p = String(w.getAttribute("data-controltype")), M = w.getAttribute("data-feature"), A = M ? JSON.parse(M) : {};
2198
2166
  A.parentComponentInstance = u.value;
2199
- let k = R(p, A);
2200
- n && n.onAcceptNewChildElement && (k = n.onAcceptNewChildElement(v, D, k));
2201
- const x = p.toLowerCase().replace("-", "_");
2202
- return k && !k.id && k.type === p && (k.id = `${x}_${Math.random().toString().slice(2, 6)}`), k;
2167
+ let T = U(p, A);
2168
+ n && n.onAcceptNewChildElement && (T = n.onAcceptNewChildElement(w, V, T));
2169
+ const $ = p.toLowerCase().replace("-", "_");
2170
+ return T && !T.id && T.type === p && (T.id = `${$}_${Math.random().toString().slice(2, 6)}`), T;
2203
2171
  }
2204
- function T(v) {
2172
+ function F(w) {
2205
2173
  }
2206
- function I(...v) {
2174
+ function D(...w) {
2207
2175
  if (n && n.getPropsConfig)
2208
- return n.getPropsConfig(...v);
2176
+ return n.getPropsConfig(...w);
2209
2177
  }
2210
2178
  return u.value = {
2211
- canMove: m(),
2212
- canSelectParent: S(),
2213
- canDelete: f(),
2214
- canNested: !y(),
2179
+ canMove: f(),
2180
+ canSelectParent: b(),
2181
+ canDelete: y(),
2182
+ canNested: !h(),
2215
2183
  contents: t == null ? void 0 : t.schema.contents,
2216
2184
  elementRef: e,
2217
- parent: (C = t == null ? void 0 : t.parent) == null ? void 0 : C.componentInstance,
2185
+ parent: (S = t == null ? void 0 : t.parent) == null ? void 0 : S.componentInstance,
2218
2186
  schema: t == null ? void 0 : t.schema,
2219
2187
  styles: c,
2220
- designerClass: i,
2221
- canAccepts: w,
2222
- getBelongedComponentInstance: a,
2188
+ designerClass: l,
2189
+ canAccepts: g,
2190
+ getBelongedComponentInstance: i,
2223
2191
  getDraggableDesignItemElement: r,
2224
- getDraggingDisplayText: s,
2225
- getPropConfig: I,
2226
- getDragScopeElement: g,
2227
- onAcceptMovedChildElement: l,
2228
- onAcceptNewChildElement: F,
2229
- onChildElementMovedOut: T,
2192
+ getDraggingDisplayText: a,
2193
+ getPropConfig: D,
2194
+ getDragScopeElement: m,
2195
+ onAcceptMovedChildElement: s,
2196
+ onAcceptNewChildElement: k,
2197
+ onChildElementMovedOut: F,
2230
2198
  addNewChildComponentSchema: d,
2231
2199
  updateDragAndDropRules: o,
2232
- triggerBelongedComponentToMoveWhenMoved: !!n && n.triggerBelongedComponentToMoveWhenMoved || b(!1),
2233
- triggerBelongedComponentToDeleteWhenDeleted: !!n && n.triggerBelongedComponentToDeleteWhenDeleted || b(!1)
2200
+ triggerBelongedComponentToMoveWhenMoved: !!n && n.triggerBelongedComponentToMoveWhenMoved || C(!1),
2201
+ triggerBelongedComponentToDeleteWhenDeleted: !!n && n.triggerBelongedComponentToDeleteWhenDeleted || C(!1)
2234
2202
  }, u;
2235
2203
  }
2236
- function an() {
2204
+ function sn() {
2237
2205
  function e(t) {
2238
- var c, i;
2206
+ var c, l;
2239
2207
  if (!t)
2240
2208
  return !1;
2241
2209
  const n = ((c = t.targetContainer) == null ? void 0 : c.componentInstance) && t.targetContainer.componentInstance.value;
2242
2210
  if (!n)
2243
2211
  return !1;
2244
- const o = (i = n.schema.appearance) == null ? void 0 : i.class;
2212
+ const o = (l = n.schema.appearance) == null ? void 0 : l.class;
2245
2213
  if (t.controlCategory === "input" || t.controlType === "form-group") {
2246
- const u = n.schema.type, m = (u === "response-form" || u === "content-container") && o && o.includes("farris-form");
2247
- if (n.schema.type !== "response-layout-item" && !m)
2214
+ const u = n.schema.type, f = (u === "response-form" || u === "content-container") && o && o.includes("farris-form");
2215
+ if (n.schema.type !== "response-layout-item" && !f)
2248
2216
  return !1;
2249
2217
  }
2250
2218
  return t.controlType !== "field-set";
@@ -2253,7 +2221,7 @@ function an() {
2253
2221
  basalDragulaRuleForContainer: e
2254
2222
  };
2255
2223
  }
2256
- const rn = "https://json-schema.org/draft/2020-12/schema", ln = "https://farris-design.gitee.io/dragging-rules.schema.json", sn = "Dragging Rules", cn = "The rules of designer canvas", un = "object", dn = {
2224
+ const cn = "https://json-schema.org/draft/2020-12/schema", un = "https://farris-design.gitee.io/dragging-rules.schema.json", dn = "Dragging Rules", pn = "The rules of designer canvas", fn = "object", mn = {
2257
2225
  "f-page": {
2258
2226
  description: "The root class of page designed by farris.",
2259
2227
  type: "object",
@@ -2817,39 +2785,39 @@ const rn = "https://json-schema.org/draft/2020-12/schema", ln = "https://farris-
2817
2785
  description: "",
2818
2786
  type: "object"
2819
2787
  }
2820
- }, pn = [], fn = {
2821
- $schema: rn,
2822
- $id: ln,
2823
- title: sn,
2824
- description: cn,
2825
- type: un,
2826
- properties: dn,
2827
- required: pn
2828
- }, W = /* @__PURE__ */ new Map();
2829
- function mn() {
2830
- function e(s, g, l, d) {
2831
- var F;
2832
- if (typeof l == "number")
2833
- return ((F = d[s]) == null ? void 0 : F.length) === l;
2834
- if (typeof l == "object") {
2835
- const T = Object.keys(l)[0], I = l[T];
2836
- if (T === "not")
2837
- return Number(d[s].length) !== Number(I);
2838
- if (T === "moreThan")
2839
- return Number(d[s].length) >= Number(I);
2840
- if (T === "lessThan")
2841
- return Number(d[s].length) <= Number(I);
2788
+ }, yn = [], gn = {
2789
+ $schema: cn,
2790
+ $id: un,
2791
+ title: dn,
2792
+ description: pn,
2793
+ type: fn,
2794
+ properties: mn,
2795
+ required: yn
2796
+ }, J = /* @__PURE__ */ new Map();
2797
+ function hn() {
2798
+ function e(a, m, s, d) {
2799
+ var k;
2800
+ if (typeof s == "number")
2801
+ return ((k = d[a]) == null ? void 0 : k.length) === s;
2802
+ if (typeof s == "object") {
2803
+ const F = Object.keys(s)[0], D = s[F];
2804
+ if (F === "not")
2805
+ return Number(d[a].length) !== Number(D);
2806
+ if (F === "moreThan")
2807
+ return Number(d[a].length) >= Number(D);
2808
+ if (F === "lessThan")
2809
+ return Number(d[a].length) <= Number(D);
2842
2810
  }
2843
2811
  return !1;
2844
2812
  }
2845
- function t(s, g, l, d) {
2846
- return typeof l == "boolean" ? d.childrenClassList.includes(g) === !!l : !1;
2813
+ function t(a, m, s, d) {
2814
+ return typeof s == "boolean" ? d.childrenClassList.includes(m) === !!s : !1;
2847
2815
  }
2848
- function n(s, g, l, d) {
2849
- return typeof l == "boolean" ? d.parentClassList.includes(g) === !!l : !1;
2816
+ function n(a, m, s, d) {
2817
+ return typeof s == "boolean" ? d.parentClassList.includes(m) === !!s : !1;
2850
2818
  }
2851
- function o(s, g, l, d) {
2852
- return typeof l == "boolean" ? d.parentClassList.includes(g) === !!l : !1;
2819
+ function o(a, m, s, d) {
2820
+ return typeof s == "boolean" ? d.parentClassList.includes(m) === !!s : !1;
2853
2821
  }
2854
2822
  const c = /* @__PURE__ */ new Map([
2855
2823
  ["length", e],
@@ -2857,300 +2825,300 @@ function mn() {
2857
2825
  ["hasSibling", o],
2858
2826
  ["hasParent", n]
2859
2827
  ]);
2860
- function i(s, g) {
2861
- const l = s;
2862
- return typeof g == "number" ? [{ target: l, operator: "length", param: null, value: Number(g) }] : typeof g == "object" ? Object.keys(g).map((d) => {
2828
+ function l(a, m) {
2829
+ const s = a;
2830
+ return typeof m == "number" ? [{ target: s, operator: "length", param: null, value: Number(m) }] : typeof m == "object" ? Object.keys(m).map((d) => {
2863
2831
  if (d === "length")
2864
- return { target: l, operator: "length", param: null, value: g[d] };
2865
- const F = d, T = g[d];
2866
- return { target: l, operator: s === "children" ? "hasChildren" : s === "parent" ? "hasParent" : "hasSibling", param: F, value: T };
2832
+ return { target: s, operator: "length", param: null, value: m[d] };
2833
+ const k = d, F = m[d];
2834
+ return { target: s, operator: a === "children" ? "hasChildren" : a === "parent" ? "hasParent" : "hasSibling", param: k, value: F };
2867
2835
  }) : [];
2868
2836
  }
2869
- function u(s, g) {
2870
- if (c.has(s.operator)) {
2871
- const l = c.get(s.operator);
2872
- return l && l(s.target, s.param, s.value, g) || !1;
2837
+ function u(a, m) {
2838
+ if (c.has(a.operator)) {
2839
+ const s = c.get(a.operator);
2840
+ return s && s(a.target, a.param, a.value, m) || !1;
2873
2841
  }
2874
2842
  return !1;
2875
2843
  }
2876
- function m(s, g) {
2877
- return Object.keys(s).reduce((T, I) => {
2878
- const C = i(I, s[I]);
2879
- return T.push(...C), T;
2880
- }, []).reduce((T, I) => T && u(I, g), !0);
2881
- }
2882
- function S(s, g) {
2883
- const l = Object.keys(s), d = l.includes("allOf"), F = l.includes("anyOf"), T = d || F, v = (T ? s[T ? d ? "allOf" : "anyOf" : "allOf"] : [s]).map((p) => m(p, g));
2884
- return d ? !v.includes(!1) : v.includes(!0);
2885
- }
2886
- function f(s, g) {
2887
- const l = s.const;
2888
- return l ? typeof l == "boolean" ? l : typeof l == "object" ? S(l, g) : !1 : !1;
2889
- }
2890
- function y(s) {
2891
- return (g) => {
2892
- const l = { canAccept: !0, fixed: !1, hidePadding: !1 };
2893
- return s && s.properties && Object.keys(s.properties).reduce((d, F) => {
2894
- const T = s.properties[F];
2895
- return d[F] = f(T, g), d;
2896
- }, l), l;
2844
+ function f(a, m) {
2845
+ return Object.keys(a).reduce((F, D) => {
2846
+ const S = l(D, a[D]);
2847
+ return F.push(...S), F;
2848
+ }, []).reduce((F, D) => F && u(D, m), !0);
2849
+ }
2850
+ function b(a, m) {
2851
+ const s = Object.keys(a), d = s.includes("allOf"), k = s.includes("anyOf"), F = d || k, w = (F ? a[F ? d ? "allOf" : "anyOf" : "allOf"] : [a]).map((p) => f(p, m));
2852
+ return d ? !w.includes(!1) : w.includes(!0);
2853
+ }
2854
+ function y(a, m) {
2855
+ const s = a.const;
2856
+ return s ? typeof s == "boolean" ? s : typeof s == "object" ? b(s, m) : !1 : !1;
2857
+ }
2858
+ function h(a) {
2859
+ return (m) => {
2860
+ const s = { canAccept: !0, fixed: !1, hidePadding: !1 };
2861
+ return a && a.properties && Object.keys(a.properties).reduce((d, k) => {
2862
+ const F = a.properties[k];
2863
+ return d[k] = y(F, m), d;
2864
+ }, s), s;
2897
2865
  };
2898
2866
  }
2899
- function a(s, g, l) {
2900
- if (g.type === "object" && g.properties) {
2901
- const { rules: d, contents: F } = g.properties;
2902
- l.set(s, y(d)), F && Object.keys(F.properties).forEach(
2903
- (T) => a(T, F.properties[T], l)
2867
+ function i(a, m, s) {
2868
+ if (m.type === "object" && m.properties) {
2869
+ const { rules: d, contents: k } = m.properties;
2870
+ s.set(a, h(d)), k && Object.keys(k.properties).forEach(
2871
+ (F) => i(F, k.properties[F], s)
2904
2872
  );
2905
2873
  }
2906
2874
  }
2907
2875
  function r() {
2908
- const { properties: s } = fn;
2909
- Object.keys(s).forEach((g) => {
2910
- a(g, s[g], W);
2876
+ const { properties: a } = gn;
2877
+ Object.keys(a).forEach((m) => {
2878
+ i(m, a[m], J);
2911
2879
  });
2912
2880
  }
2913
- function w(s, g) {
2914
- const l = { canAccept: !0, fixed: !1, hidePadding: !0 };
2915
- return W.has(s) ? W.get(s)(g) : l;
2881
+ function g(a, m) {
2882
+ const s = { canAccept: !0, fixed: !1, hidePadding: !0 };
2883
+ return J.has(a) ? J.get(a)(m) : s;
2916
2884
  }
2917
- return r(), { getRuleValue: w };
2885
+ return r(), { getRuleValue: g };
2918
2886
  }
2919
- function yn(e, t) {
2920
- var D;
2921
- const n = e.schema, o = (D = e.parent) == null ? void 0 : D.schema, c = mn(), i = b(!1), u = b(!1);
2922
- let m = !0, S = !1, f, y = !1;
2923
- function a(p) {
2924
- return f && f.componentClassList && f.componentClassList.includes("f-form-layout") && f.componentClassList.includes("farris-form") ? p.sourceType === "control" && p.controlCategory === "input" || p.sourceType === "move" && p.controlType === "form-group" : !0;
2887
+ function bn(e, t) {
2888
+ var V;
2889
+ const n = e.schema, o = (V = e.parent) == null ? void 0 : V.schema, c = hn(), l = C(!1), u = C(!1);
2890
+ let f = !0, b = !1, y, h = !1;
2891
+ function i(p) {
2892
+ return y && y.componentClassList && y.componentClassList.includes("f-form-layout") && y.componentClassList.includes("farris-form") ? p.sourceType === "control" && p.controlCategory === "input" || p.sourceType === "move" && p.controlType === "form-group" : !0;
2925
2893
  }
2926
2894
  function r(p) {
2927
- return !(!an().basalDragulaRuleForContainer(p) || !m || !a(p));
2895
+ return !(!sn().basalDragulaRuleForContainer(p) || !f || !i(p));
2928
2896
  }
2929
- function w() {
2930
- i.value = !1, u.value = !1;
2931
- const p = n, V = p.appearance && p.appearance.class || "", A = V.split(" "), k = p.contents || [], x = k.length ? k[0] : null, j = x && x.appearance ? x.appearance.class : "", B = j ? j.split(" ") : [], E = k.length ? k.reduce((te, G) => {
2932
- const ne = G && G.appearance ? G.appearance.class : "", be = ne ? ne.split(" ") : [];
2933
- return te.push(...be), te;
2934
- }, []) : [], P = o, L = P && P.appearance && P.appearance.class || "", ye = L ? L.split(" ") : [];
2935
- f = {
2936
- componentClass: V,
2897
+ function g() {
2898
+ l.value = !1, u.value = !1;
2899
+ const p = n, M = p.appearance && p.appearance.class || "", A = M.split(" "), T = p.contents || [], $ = T.length ? T[0] : null, O = $ && $.appearance ? $.appearance.class : "", P = O ? O.split(" ") : [], E = T.length ? T.reduce((oe, W) => {
2900
+ const ae = W && W.appearance ? W.appearance.class : "", we = ae ? ae.split(" ") : [];
2901
+ return oe.push(...we), oe;
2902
+ }, []) : [], I = o, x = I && I.appearance && I.appearance.class || "", he = x ? x.split(" ") : [];
2903
+ y = {
2904
+ componentClass: M,
2937
2905
  componentClassList: A,
2938
- childContents: k,
2939
- firstChildContent: x,
2940
- firstChildClass: j,
2941
- firstChildClassList: B,
2942
- parent: P,
2943
- parentClass: L,
2944
- parentClassList: ye,
2945
- children: k,
2906
+ childContents: T,
2907
+ firstChildContent: $,
2908
+ firstChildClass: O,
2909
+ firstChildClassList: P,
2910
+ parent: I,
2911
+ parentClass: x,
2912
+ parentClassList: he,
2913
+ children: T,
2946
2914
  childrenClassList: E
2947
2915
  };
2948
- const { canAccept: ge, fixed: he, hidePadding: ve } = c.getRuleValue(A[0], f);
2949
- return m = ge, S = ve, y = he, !0;
2916
+ const { canAccept: be, fixed: ve, hidePadding: Ce } = c.getRuleValue(A[0], y);
2917
+ return f = be, b = Ce, h = ve, !0;
2950
2918
  }
2951
- function s(p) {
2952
- ke();
2919
+ function a(p) {
2920
+ je();
2953
2921
  }
2954
- function g() {
2922
+ function m() {
2955
2923
  return n.componentType ? "display:inherit;flex-direction:inherit;margin-bottom:10px" : "";
2956
2924
  }
2957
- function l(p, V) {
2925
+ function s(p, M) {
2958
2926
  const A = n;
2959
2927
  if ((A.appearance && A.appearance.class || "").split(" ").includes("f-form-layout")) {
2960
- const { label: j } = p, B = R("form-group");
2961
- return B.editor = V, B.label = j, d(B), delete B.editor.id, delete B.editor.binding, delete B.editor.appearance, delete B.editor.visible, B;
2928
+ const { label: O } = p, P = U("form-group");
2929
+ return P.editor = M, P.label = O, d(P), delete P.editor.id, delete P.editor.binding, delete P.editor.appearance, delete P.editor.visible, P;
2962
2930
  }
2963
- return V;
2931
+ return M;
2964
2932
  }
2965
2933
  function d(p) {
2966
- const V = e.componentInstance.value.getBelongedComponentInstance(e.componentInstance);
2967
- if (V && V.schema && V.schema.componentType) {
2968
- const A = V.schema.componentType, k = F(A);
2969
- p.appearance || (p.appearance = {}), p.appearance.class = k;
2934
+ const M = e.componentInstance.value.getBelongedComponentInstance(e.componentInstance);
2935
+ if (M && M.schema && M.schema.componentType) {
2936
+ const A = M.schema.componentType, T = k(A);
2937
+ p.appearance || (p.appearance = {}), p.appearance.class = T;
2970
2938
  }
2971
2939
  }
2972
- function F(p) {
2973
- let V = "";
2940
+ function k(p) {
2941
+ let M = "";
2974
2942
  switch (p) {
2975
2943
  case "form-col-1": {
2976
- V = "col-12 col-md-12 col-xl-12 col-el-12";
2944
+ M = "col-12 col-md-12 col-xl-12 col-el-12";
2977
2945
  break;
2978
2946
  }
2979
2947
  case "form-col-12": {
2980
- V = "col-12 col-md-12 col-xl-12 col-el-12";
2948
+ M = "col-12 col-md-12 col-xl-12 col-el-12";
2981
2949
  break;
2982
2950
  }
2983
2951
  case "form-col-2": {
2984
- V = "col-12 col-md-6 col-xl-6 col-el-6";
2952
+ M = "col-12 col-md-6 col-xl-6 col-el-6";
2985
2953
  break;
2986
2954
  }
2987
2955
  case "form-col-3": {
2988
- V = "col-12 col-md-6 col-xl-4 col-el-4";
2956
+ M = "col-12 col-md-6 col-xl-4 col-el-4";
2989
2957
  break;
2990
2958
  }
2991
2959
  case "form-col-4": {
2992
- V = "col-12 col-md-6 col-xl-3 col-el-2";
2960
+ M = "col-12 col-md-6 col-xl-3 col-el-2";
2993
2961
  break;
2994
2962
  }
2995
2963
  case "form-col-6": {
2996
- V = "col-12 col-md-6 col-xl-6 col-el-6";
2964
+ M = "col-12 col-md-6 col-xl-6 col-el-6";
2997
2965
  break;
2998
2966
  }
2999
2967
  case "frame": {
3000
- V = "col-12";
2968
+ M = "col-12";
3001
2969
  break;
3002
2970
  }
3003
2971
  }
3004
- return V;
2972
+ return M;
3005
2973
  }
3006
- function T(p, V, A) {
3007
- const k = n;
3008
- if ((k.appearance && k.appearance.class || "").split(" ").includes("f-form-layout")) {
3009
- const B = String(p.innerText), E = R("form-group");
3010
- return E.editor = A, E.label = B, E;
2974
+ function F(p, M, A) {
2975
+ const T = n;
2976
+ if ((T.appearance && T.appearance.class || "").split(" ").includes("f-form-layout")) {
2977
+ const P = String(p.innerText), E = U("form-group");
2978
+ return E.editor = A, E.label = P, E;
3011
2979
  }
3012
2980
  return A;
3013
2981
  }
3014
- function I() {
3015
- return !y;
2982
+ function D() {
2983
+ return !h;
3016
2984
  }
3017
- function C() {
3018
- return !y;
2985
+ function S() {
2986
+ return !h;
3019
2987
  }
3020
- function v() {
3021
- return S;
2988
+ function w() {
2989
+ return b;
3022
2990
  }
3023
2991
  return {
3024
2992
  canAccepts: r,
3025
- checkCanDeleteComponent: C,
3026
- checkCanMoveComponent: I,
3027
- getStyles: g,
3028
- hideNestedPaddingInDesginerView: v,
3029
- onAcceptNewChildElement: T,
3030
- onAcceptMovedChildElement: s,
3031
- resolveComponentContext: w,
3032
- onResolveNewComponentSchema: l,
3033
- triggerBelongedComponentToMoveWhenMoved: i,
2993
+ checkCanDeleteComponent: S,
2994
+ checkCanMoveComponent: D,
2995
+ getStyles: m,
2996
+ hideNestedPaddingInDesginerView: w,
2997
+ onAcceptNewChildElement: F,
2998
+ onAcceptMovedChildElement: a,
2999
+ resolveComponentContext: g,
3000
+ onResolveNewComponentSchema: s,
3001
+ triggerBelongedComponentToMoveWhenMoved: l,
3034
3002
  triggerBelongedComponentToDeleteWhenDeleted: u
3035
3003
  };
3036
3004
  }
3037
- const gn = /* @__PURE__ */ H({
3005
+ const vn = /* @__PURE__ */ H({
3038
3006
  name: "FOrderDesign",
3039
- props: K,
3007
+ props: te,
3040
3008
  emits: ["change"],
3041
3009
  setup(e, t) {
3042
- var I;
3043
- const n = b(e.items), o = b("排序列"), c = b("排序方式"), i = b("添加排序列"), u = [{
3010
+ var D;
3011
+ const n = C(e.items), o = C("排序列"), c = C("排序方式"), l = C("添加排序列"), u = [{
3044
3012
  id: "asc",
3045
3013
  name: "升序"
3046
3014
  }, {
3047
3015
  id: "desc",
3048
3016
  name: "降序"
3049
- }], m = b(/* @__PURE__ */ new Map()), S = b(), f = q("design-item-context"), y = yn(f.schema, (I = f.parent) == null ? void 0 : I.schema), a = on(S, f, y);
3050
- ie(() => {
3051
- S.value.componentInstance = a;
3052
- }), t.expose(a.value);
3017
+ }], f = C(/* @__PURE__ */ new Map()), b = C(), y = X("design-item-context"), h = bn(y.schema, (D = y.parent) == null ? void 0 : D.schema), i = ln(b, y, h);
3018
+ ce(() => {
3019
+ b.value.componentInstance = i;
3020
+ }), t.expose(i.value);
3053
3021
  function r() {
3054
- const C = n.value.map((v) => [v.id, !0]);
3055
- m.value = new Map(C);
3022
+ const S = n.value.map((w) => [w.id, !0]);
3023
+ f.value = new Map(S);
3056
3024
  }
3057
3025
  r();
3058
- const w = O(() => e.dataSource.map((C) => (C.disabled = m.value.has(C.id), C))), s = O(() => ({
3026
+ const g = B(() => e.dataSource.map((S) => (S.disabled = f.value.has(S.id), S))), a = B(() => ({
3059
3027
  "f-order": !0
3060
3028
  }));
3061
- function g(C) {
3062
- n.value = n.value.filter((v) => v.id !== C.id), r(), t.emit("change", n.value);
3029
+ function m(S) {
3030
+ n.value = n.value.filter((w) => w.id !== S.id), r(), t.emit("change", n.value);
3063
3031
  }
3064
- function l() {
3032
+ function s() {
3065
3033
  n.value = [...n.value, {
3066
3034
  id: Date.now().toString(),
3067
3035
  name: "",
3068
3036
  order: "asc"
3069
3037
  }], r(), t.emit("change", n.value);
3070
3038
  }
3071
- function d(C) {
3039
+ function d(S) {
3072
3040
  r(), t.emit("change", n.value);
3073
3041
  }
3074
- function F(C) {
3075
- if (C && C.length) {
3076
- const v = /* @__PURE__ */ new Map();
3077
- C.reduce((D, p) => (D.set(p.id, p), D), v), n.value = C.map((D) => v.get(D.id)), t.emit("change", n.value);
3042
+ function k(S) {
3043
+ if (S && S.length) {
3044
+ const w = /* @__PURE__ */ new Map();
3045
+ S.reduce((V, p) => (V.set(p.id, p), V), w), n.value = S.map((V) => w.get(V.id)), t.emit("change", n.value);
3078
3046
  }
3079
3047
  }
3080
- function T() {
3081
- return h(de, {
3048
+ function F() {
3049
+ return v(me, {
3082
3050
  style: "flex:1",
3083
3051
  data: n.value,
3084
3052
  draggable: !0,
3085
3053
  view: "DraggableView",
3086
3054
  "keep-order": !0,
3087
3055
  itemClass: "f-order-item",
3088
- onRemoveItem: g,
3089
- onChange: F
3056
+ onRemoveItem: m,
3057
+ onChange: k
3090
3058
  }, {
3091
- header: () => h("div", {
3059
+ header: () => v("div", {
3092
3060
  class: "f-order-header"
3093
- }, [h("span", {
3061
+ }, [v("span", {
3094
3062
  class: "f-order-header-order-field"
3095
- }, [o.value]), h("span", {
3063
+ }, [o.value]), v("span", {
3096
3064
  class: "f-order-header-order-type"
3097
3065
  }, [c.value])]),
3098
- itemContent: (C) => h("div", {
3066
+ itemContent: (S) => v("div", {
3099
3067
  class: "f-order-item-content"
3100
- }, [h(z, {
3068
+ }, [v(q, {
3101
3069
  class: "f-order-item-content-order-field",
3102
- data: w.value,
3070
+ data: g.value,
3103
3071
  valueField: "id",
3104
3072
  textField: "name",
3105
3073
  idField: "id",
3106
- modelValue: C.id,
3107
- "onUpdate:modelValue": (v) => C.id = v,
3074
+ modelValue: S.id,
3075
+ "onUpdate:modelValue": (w) => S.id = w,
3108
3076
  onChange: d,
3109
3077
  onClear: d
3110
- }, null), h(z, {
3078
+ }, null), v(q, {
3111
3079
  class: "f-order-item-content-order-type",
3112
3080
  data: u,
3113
3081
  valueField: "id",
3114
3082
  textField: "name",
3115
3083
  idField: "id",
3116
- modelValue: C.order,
3117
- "onUpdate:modelValue": (v) => C.order = v,
3084
+ modelValue: S.order,
3085
+ "onUpdate:modelValue": (w) => S.order = w,
3118
3086
  onChange: d
3119
3087
  }, null)]),
3120
- footer: () => h("div", {
3088
+ footer: () => v("div", {
3121
3089
  class: "f-order-footer"
3122
- }, [h(pe, {
3090
+ }, [v(ye, {
3123
3091
  type: "link",
3124
3092
  class: "f-order-add-button",
3125
- onClick: l
3093
+ onClick: s
3126
3094
  }, {
3127
- default: () => h(Q, null, [h("span", {
3095
+ default: () => v(Q, null, [v("span", {
3128
3096
  class: "f-order-add-icon"
3129
- }, [h("i", {
3097
+ }, [v("i", {
3130
3098
  class: "f-icon f-icon-add"
3131
- }, null)]), i.value])
3099
+ }, null)]), l.value])
3132
3100
  })])
3133
3101
  });
3134
3102
  }
3135
- return () => h("div", {
3136
- ref: S,
3137
- class: s.value
3138
- }, [T()]);
3103
+ return () => v("div", {
3104
+ ref: b,
3105
+ class: a.value
3106
+ }, [F()]);
3139
3107
  }
3140
- }), kn = {
3108
+ }), Dn = {
3141
3109
  install(e) {
3142
- e.component(_.name, _);
3110
+ e.component(z.name, z);
3143
3111
  },
3144
3112
  register(e, t, n, o) {
3145
- e.order = _, t.order = oe;
3113
+ e.order = z, t.order = ie;
3146
3114
  },
3147
3115
  registerDesigner(e, t, n) {
3148
- e.order = gn, t.order = oe;
3116
+ e.order = vn, t.order = ie;
3149
3117
  }
3150
3118
  };
3151
3119
  export {
3152
- _ as FOrder,
3153
- kn as default,
3154
- K as orderProps,
3155
- oe as propsResolver
3120
+ z as FOrder,
3121
+ Dn as default,
3122
+ te as orderProps,
3123
+ ie as propsResolver
3156
3124
  };