@farris/ui-vue 1.3.1 → 1.3.3

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 (259) hide show
  1. package/components/accordion/index.esm.js +103 -99
  2. package/components/accordion/index.umd.cjs +1 -1
  3. package/components/avatar/index.esm.js +301 -351
  4. package/components/avatar/index.umd.cjs +1 -1
  5. package/components/binding-selector/index.esm.js +444 -0
  6. package/components/binding-selector/index.umd.cjs +1 -0
  7. package/components/binding-selector/package.json +8 -0
  8. package/components/border-editor/index.esm.js +5 -3
  9. package/components/border-editor/index.umd.cjs +1 -1
  10. package/components/button-edit/index.esm.js +143 -139
  11. package/components/button-edit/index.umd.cjs +1 -1
  12. package/components/calendar/index.esm.js +407 -396
  13. package/components/calendar/index.umd.cjs +1 -1
  14. package/components/capsule/index.esm.js +266 -255
  15. package/components/capsule/index.umd.cjs +1 -1
  16. package/components/checkbox/index.esm.js +628 -641
  17. package/components/checkbox/index.umd.cjs +1 -1
  18. package/components/color-picker/index.esm.js +379 -374
  19. package/components/color-picker/index.umd.cjs +2 -2
  20. package/components/combo-list/index.esm.js +471 -471
  21. package/components/combo-list/index.umd.cjs +1 -1
  22. package/components/combo-tree/index.esm.js +155 -148
  23. package/components/combo-tree/index.umd.cjs +1 -1
  24. package/components/common/index.esm.js +487 -478
  25. package/components/common/index.umd.cjs +1 -1
  26. package/components/component/index.esm.js +330 -279
  27. package/components/component/index.umd.cjs +1 -1
  28. package/components/condition/index.esm.js +1171 -1277
  29. package/components/condition/index.umd.cjs +1 -1
  30. package/components/content-container/index.esm.js +220 -204
  31. package/components/content-container/index.umd.cjs +1 -1
  32. package/components/data-grid/index.esm.js +4743 -4641
  33. package/components/data-grid/index.umd.cjs +1 -1
  34. package/components/data-view/index.esm.js +2916 -3019
  35. package/components/data-view/index.umd.cjs +1 -1
  36. package/components/date-picker/index.esm.js +2375 -2590
  37. package/components/date-picker/index.umd.cjs +1 -1
  38. package/components/designer-canvas/index.css +1 -1
  39. package/components/designer-canvas/index.esm.js +9518 -1198
  40. package/components/designer-canvas/index.umd.cjs +1 -1
  41. package/components/designer-outline/index.esm.js +2 -1
  42. package/components/designer-outline/index.umd.cjs +1 -1
  43. package/components/drawer/index.esm.js +34 -38
  44. package/components/drawer/index.umd.cjs +1 -1
  45. package/components/dropdown/index.esm.js +149 -138
  46. package/components/dropdown/index.umd.cjs +2 -2
  47. package/components/dynamic-form/index.esm.js +1602 -1740
  48. package/components/dynamic-form/index.umd.cjs +1 -1
  49. package/components/dynamic-resolver/index.esm.js +159 -151
  50. package/components/dynamic-resolver/index.umd.cjs +1 -1
  51. package/components/dynamic-view/index.esm.js +218 -218
  52. package/components/dynamic-view/index.umd.cjs +1 -1
  53. package/components/event-parameter/index.esm.js +311 -0
  54. package/components/event-parameter/index.umd.cjs +1 -0
  55. package/components/event-parameter/package.json +8 -0
  56. package/components/events-editor/index.css +1 -1
  57. package/components/events-editor/index.esm.js +533 -563
  58. package/components/events-editor/index.umd.cjs +1 -1
  59. package/components/expression-editor/index.esm.js +95 -91
  60. package/components/expression-editor/index.umd.cjs +1 -1
  61. package/components/external-container/index.esm.js +2356 -2455
  62. package/components/external-container/index.umd.cjs +1 -1
  63. package/components/field-selector/index.esm.js +3048 -3308
  64. package/components/field-selector/index.umd.cjs +1 -1
  65. package/components/filter-bar/index.css +1 -1
  66. package/components/filter-bar/index.esm.js +10537 -3249
  67. package/components/filter-bar/index.umd.cjs +1 -1
  68. package/components/flow-canvas/index.css +1 -1
  69. package/components/flow-canvas/index.esm.js +9781 -1327
  70. package/components/flow-canvas/index.umd.cjs +1 -1
  71. package/components/image-cropper/index.esm.js +353 -341
  72. package/components/image-cropper/index.umd.cjs +1 -1
  73. package/components/input-group/index.esm.js +510 -827
  74. package/components/input-group/index.umd.cjs +1 -1
  75. package/components/layout/index.esm.js +278 -268
  76. package/components/layout/index.umd.cjs +1 -1
  77. package/components/list-nav/index.esm.js +144 -136
  78. package/components/list-nav/index.umd.cjs +1 -1
  79. package/components/list-view/index.esm.js +2139 -2237
  80. package/components/list-view/index.umd.cjs +1 -1
  81. package/components/lookup/index.esm.js +6414 -6367
  82. package/components/lookup/index.umd.cjs +1 -1
  83. package/components/mapping-editor/index.esm.js +5216 -5114
  84. package/components/mapping-editor/index.umd.cjs +1 -1
  85. package/components/message-box/index.esm.js +252 -252
  86. package/components/message-box/index.umd.cjs +1 -1
  87. package/components/modal/index.esm.js +70 -70
  88. package/components/modal/index.umd.cjs +1 -1
  89. package/components/nav/index.esm.js +486 -984
  90. package/components/nav/index.umd.cjs +3 -3
  91. package/components/number-range/index.esm.js +446 -498
  92. package/components/number-range/index.umd.cjs +1 -1
  93. package/components/number-spinner/index.esm.js +363 -388
  94. package/components/number-spinner/index.umd.cjs +1 -1
  95. package/components/order/index.esm.js +1050 -1308
  96. package/components/order/index.umd.cjs +1 -1
  97. package/components/page-footer/index.esm.js +134 -131
  98. package/components/page-footer/index.umd.cjs +1 -1
  99. package/components/page-header/index.esm.js +1072 -1082
  100. package/components/page-header/index.umd.cjs +1 -1
  101. package/components/pagination/index.esm.js +412 -910
  102. package/components/pagination/index.umd.cjs +1 -1
  103. package/components/progress/index.esm.js +214 -203
  104. package/components/progress/index.umd.cjs +3 -3
  105. package/components/property-editor/index.esm.js +1361 -1536
  106. package/components/property-editor/index.umd.cjs +2 -2
  107. package/components/property-panel/index.esm.js +650 -677
  108. package/components/property-panel/index.umd.cjs +1 -1
  109. package/components/query-solution/index.css +1 -1
  110. package/components/query-solution/index.esm.js +12344 -5048
  111. package/components/query-solution/index.umd.cjs +6 -1
  112. package/components/radio-button/index.esm.js +97 -97
  113. package/components/radio-button/index.umd.cjs +1 -1
  114. package/components/radio-group/index.css +1 -1
  115. package/components/radio-group/index.esm.js +1821 -565
  116. package/components/radio-group/index.umd.cjs +1 -1
  117. package/components/rate/index.esm.js +251 -244
  118. package/components/rate/index.umd.cjs +1 -1
  119. package/components/response-layout/index.esm.js +151 -140
  120. package/components/response-layout/index.umd.cjs +1 -1
  121. package/components/response-layout-editor/index.esm.js +707 -676
  122. package/components/response-layout-editor/index.umd.cjs +1 -1
  123. package/components/response-toolbar/index.esm.js +719 -740
  124. package/components/response-toolbar/index.umd.cjs +1 -1
  125. package/components/schema-selector/index.esm.js +4977 -5249
  126. package/components/schema-selector/index.umd.cjs +2 -2
  127. package/components/search-box/index.esm.js +145 -134
  128. package/components/search-box/index.umd.cjs +1 -1
  129. package/components/section/index.esm.js +348 -337
  130. package/components/section/index.umd.cjs +1 -1
  131. package/components/smoke-detector/index.esm.js +141 -130
  132. package/components/smoke-detector/index.umd.cjs +1 -1
  133. package/components/splitter/index.esm.js +311 -301
  134. package/components/splitter/index.umd.cjs +1 -1
  135. package/components/step/index.esm.js +231 -220
  136. package/components/step/index.umd.cjs +1 -1
  137. package/components/switch/index.esm.js +385 -432
  138. package/components/switch/index.umd.cjs +1 -1
  139. package/components/tabs/index.esm.js +1932 -1914
  140. package/components/tabs/index.umd.cjs +1 -1
  141. package/components/tags/index.esm.js +351 -340
  142. package/components/tags/index.umd.cjs +1 -1
  143. package/components/text/index.esm.js +209 -199
  144. package/components/text/index.umd.cjs +1 -1
  145. package/components/textarea/index.esm.js +388 -415
  146. package/components/textarea/index.umd.cjs +1 -1
  147. package/components/time-picker/index.esm.js +619 -666
  148. package/components/time-picker/index.umd.cjs +1 -1
  149. package/components/transfer/index.esm.js +493 -486
  150. package/components/transfer/index.umd.cjs +1 -1
  151. package/components/tree-grid/index.esm.js +3169 -3278
  152. package/components/tree-grid/index.umd.cjs +1 -1
  153. package/components/tree-view/index.esm.js +2320 -2418
  154. package/components/tree-view/index.umd.cjs +1 -1
  155. package/components/uploader/index.esm.js +563 -554
  156. package/components/uploader/index.umd.cjs +2 -2
  157. package/components/verify-detail/index.esm.js +287 -276
  158. package/components/verify-detail/index.umd.cjs +1 -1
  159. package/components/video/index.esm.js +368 -324
  160. package/components/video/index.umd.cjs +1 -1
  161. package/components/weather/index.esm.js +498 -487
  162. package/components/weather/index.umd.cjs +5 -5
  163. package/farris.all.esm.js +51302 -47651
  164. package/farris.all.umd.cjs +14 -9
  165. package/index.css +1 -1
  166. package/package.json +1 -1
  167. package/types/binding-selector/index.d.ts +55 -0
  168. package/types/binding-selector/src/binding-selector.component.d.ts +11 -0
  169. package/types/binding-selector/src/binding-selector.props.d.ts +52 -0
  170. package/types/binding-selector/src/components/binding-selector-container.component.d.ts +13 -0
  171. package/types/binding-selector/src/composition/use-field-selection.d.ts +9 -0
  172. package/types/combo-list/src/components/list-container.component.d.ts +6 -6
  173. package/types/combo-list/src/components/list-container.props.d.ts +1 -1
  174. package/types/combo-tree/src/components/tree-container.component.d.ts +5 -5
  175. package/types/common/entity/entity-schema.d.ts +26 -11
  176. package/types/common/index.d.ts +1 -0
  177. package/types/common/types.d.ts +2 -2
  178. package/types/condition/src/condition-fields.design.component.d.ts +18 -0
  179. package/types/condition/src/types.d.ts +6 -6
  180. package/types/data-grid/src/composition/data-grid-component-creator.service.d.ts +20 -0
  181. package/types/data-grid/src/{designer/data-grid-column.props.d.ts → data-grid-column.props.d.ts} +1 -1
  182. package/types/data-grid/src/data-grid.props.d.ts +2 -2
  183. package/types/data-grid/src/designer/grid-field-editor.component.d.ts +14 -14
  184. package/types/data-grid/src/schema/schema-resolver.d.ts +1 -1
  185. package/types/data-view/composition/types.d.ts +2 -2
  186. package/types/date-picker/src/components/calendar/calendar.component.d.ts +3 -3
  187. package/types/date-picker/src/components/month/month.component.d.ts +3 -3
  188. package/types/date-picker/src/components/year/year.component.d.ts +3 -3
  189. package/types/designer-canvas/index.d.ts +2 -1
  190. package/types/designer-canvas/src/composition/dg-control.d.ts +5 -0
  191. package/types/designer-canvas/src/composition/function/drag-resolve.d.ts +5 -0
  192. package/types/designer-canvas/src/composition/types.d.ts +49 -40
  193. package/types/designer-canvas/src/types.d.ts +8 -20
  194. package/types/dynamic-form/index.d.ts +1 -1
  195. package/types/dynamic-form/src/designer/form-group-use-designer-rules.d.ts +3 -0
  196. package/types/dynamic-form/src/schema/{schema-resolver.d.ts → response-form-schema-resolver.d.ts} +1 -1
  197. package/types/dynamic-form/src/types.d.ts +1 -1
  198. package/types/dynamic-resolver/src/common/toolbar-resolver.d.ts +5 -0
  199. package/types/dynamic-resolver/src/converter/row-number.converter.d.ts +3 -0
  200. package/types/entity-binding-selector/composition/use-entity-tree.d.ts +7 -0
  201. package/types/entity-binding-selector/entity-binding-selector.component.d.ts +11 -0
  202. package/types/entity-binding-selector/entity-binding-selector.props.d.ts +3 -0
  203. package/types/enum-editor/src/components/enum-editor-container.component.d.ts +3 -3
  204. package/types/enum-editor/src/enum-editor.component.d.ts +3 -3
  205. package/types/event-parameter/index.d.ts +31 -0
  206. package/types/event-parameter/src/composition/type.d.ts +77 -0
  207. package/types/event-parameter/src/composition/use-editor-combotree.d.ts +3 -0
  208. package/types/event-parameter/src/composition/use-editor-input.d.ts +3 -0
  209. package/types/event-parameter/src/composition/use-editor-select.d.ts +3 -0
  210. package/types/event-parameter/src/composition/use-editor-switch.d.ts +3 -0
  211. package/types/event-parameter/src/composition/use-editor.d.ts +3 -0
  212. package/types/event-parameter/src/event-parameter.component.d.ts +8 -0
  213. package/types/event-parameter/src/event-parameter.props.d.ts +34 -0
  214. package/types/external-container/src/designer/import-external-schema.component.d.ts +1 -1
  215. package/types/field-selector/src/field-selector.component.d.ts +1 -2
  216. package/types/field-selector/src/field-selector.props.d.ts +0 -9
  217. package/types/input-group/src/designer/use-input-group-rules.d.ts +1 -2
  218. package/types/list-view/src/designer/list-view-table.design.component.d.ts +15 -0
  219. package/types/list-view/src/list-view-table.component.d.ts +15 -0
  220. package/types/lookup/src/composition/use-user-data.d.ts +2 -2
  221. package/types/lookup/src/property-config/lookup.property-config.d.ts +2 -6
  222. package/types/modal/src/composition/modal.service.d.ts +2 -1
  223. package/types/page-header/src/designer/page-header.design.component.d.ts +1 -1
  224. package/types/page-header/src/page-header.component.d.ts +1 -1
  225. package/types/property-panel/index.d.ts +2 -1
  226. package/types/property-panel/src/composition/entity/property-entity.d.ts +1 -1
  227. package/types/property-panel/src/composition/type.d.ts +0 -13
  228. package/types/query-solution/src/composition/types.d.ts +35 -4
  229. package/types/query-solution/src/composition/use-header.d.ts +21 -0
  230. package/types/query-solution/src/composition/{use-filter.d.ts → use-http.d.ts} +2 -2
  231. package/types/query-solution/src/composition/use-solution.d.ts +20 -0
  232. package/types/query-solution/src/designer/query-solution-config/composition/types.d.ts +17 -16
  233. package/types/query-solution/src/designer/query-solution-config/query-solution-config.props.d.ts +14 -14
  234. package/types/query-solution/src/property-config/query-solution.property-config.d.ts +3 -51
  235. package/types/query-solution/src/query-solution.d.ts +10 -2
  236. package/types/radio-group/src/designer/item-collection-editor-inner.component.d.ts +29 -0
  237. package/types/radio-group/src/designer/item-collection-editor.component.d.ts +29 -0
  238. package/types/radio-group/src/designer/item-collection-editor.props.d.ts +21 -0
  239. package/types/radio-group/src/schema/schema-mapper.d.ts +1 -0
  240. package/types/radio-group/src/schema/schema-resolver.d.ts +1 -0
  241. package/types/response-toolbar/src/property-config/response-toolbar.property-config.d.ts +1 -0
  242. package/types/section/src/property-config/section.property-config.d.ts +17 -17
  243. package/types/section/src/schema/schema-resolver.d.ts +1 -2
  244. package/types/section/src/schema/toolbar-resolver.d.ts +1 -1
  245. package/types/tabs/src/composition/types.d.ts +4 -1
  246. package/types/tabs/src/property-config/tab-page.property-config.d.ts +9 -59
  247. package/types/tabs/src/property-config/tabs.property-config.d.ts +8 -71
  248. package/types/tabs/src/schema/schema-resolver.d.ts +1 -2
  249. package/types/text/src/composition/types.d.ts +4 -4
  250. package/types/textarea/src/property-config/textarea.property-config.d.ts +23 -0
  251. package/types/weather/src/composition/use-weather-charts.d.ts +15 -0
  252. package/types/weather/src/composition/use-weather-color.d.ts +15 -0
  253. package/types/weather/src/composition/use-weather-data.d.ts +15 -0
  254. package/types/weather/src/composition/use-weather-format-number.d.ts +15 -0
  255. package/types/property-panel/src/composition/entity/use-input-rules.d.ts +0 -3
  256. package/types/tree-grid/src/schema/column-resolver.d.ts +0 -3
  257. package/types/weather/src/composition/types.d.ts +0 -2
  258. /package/types/dynamic-form/src/designer/{use-designer-rules.d.ts → response-form-use-designer-rules.d.ts} +0 -0
  259. /package/types/dynamic-form/src/property-config/{form.property-config.d.ts → response-form.property-config.d.ts} +0 -0
@@ -1,33 +1,37 @@
1
- import { ref as C, computed as P, defineComponent as k, provide as W, createVNode as w, inject as O, onMounted as q } from "vue";
1
+ import { ref as g, computed as C, defineComponent as M, provide as W, createVNode as w, inject as k, onMounted as q } from "vue";
2
2
  import { isPlainObject as $, cloneDeep as I } from "lodash-es";
3
3
  import "bignumber.js";
4
4
  const G = {}, X = {};
5
5
  function E(t) {
6
- const { properties: e, title: n, ignore: a } = t, i = a && Array.isArray(a), o = Object.keys(e).reduce((s, d) => ((!i || !a.find((h) => h == d)) && (s[d] = e[d].type === "object" && e[d].properties ? E(e[d]) : I(e[d].default)), s), {});
7
- return n && (!i || !a.find((s) => s == "id")) && (o.id = `${n}-${Date.now()}`), o;
6
+ const { properties: e, title: n, ignore: a } = t, i = a && Array.isArray(a), s = Object.keys(e).reduce((o, f) => ((!i || !a.find((v) => v === f)) && (o[f] = e[f].type === "object" && e[f].properties ? E(e[f]) : I(e[f].default)), o), {});
7
+ if (n && (!i || !a.find((o) => o === "id"))) {
8
+ const o = n.toLowerCase().replace(/-/g, "_");
9
+ s.id = `${o}_${Math.random().toString().slice(2, 6)}`;
10
+ }
11
+ return s;
8
12
  }
9
13
  function Y(t, e = {}, n) {
10
14
  const a = G[t];
11
15
  if (a) {
12
16
  let i = E(a);
13
- const o = X[t];
14
- return i = o ? o({ getSchemaByType: Y }, i, e, n) : i, i;
17
+ const s = X[t];
18
+ return i = s ? s({ getSchemaByType: Y }, i, e, n) : i, i;
15
19
  }
16
20
  return null;
17
21
  }
18
22
  function ee(t, e) {
19
23
  const n = E(e);
20
- return Object.keys(t).reduce((a, i) => (a[i] && $(a[i]) && $(t[i]) ? Object.assign(a[i], t[i]) : a[i] = t[i], a), n), n;
24
+ return Object.keys(n).reduce((a, i) => (a[i] && $(a[i]) && $(t[i] || !t[i]) ? Object.assign(a[i], t[i] || {}) : a[i] = t[i], a), n), n;
21
25
  }
22
26
  function te(t, e) {
23
27
  return Object.keys(t).filter((a) => t[a] != null).reduce((a, i) => {
24
28
  if (e.has(i)) {
25
- const o = e.get(i);
26
- if (typeof o == "string")
27
- a[o] = t[i];
29
+ const s = e.get(i);
30
+ if (typeof s == "string")
31
+ a[s] = t[i];
28
32
  else {
29
- const s = o(i, t[i], t);
30
- Object.assign(a, s);
33
+ const o = s(i, t[i], t);
34
+ Object.assign(a, o);
31
35
  }
32
36
  } else
33
37
  a[i] = t[i];
@@ -43,13 +47,13 @@ function ae(t = {}) {
43
47
  if (typeof m == "number")
44
48
  return r[l].length === m;
45
49
  if (typeof m == "object") {
46
- const p = Object.keys(m)[0], y = m[p];
47
- if (p === "not")
48
- return Number(r[l].length) !== Number(y);
49
- if (p === "moreThan")
50
- return Number(r[l].length) >= Number(y);
51
- if (p === "lessThan")
52
- return Number(r[l].length) <= Number(y);
50
+ const y = Object.keys(m)[0], d = m[y];
51
+ if (y === "not")
52
+ return Number(r[l].length) !== Number(d);
53
+ if (y === "moreThan")
54
+ return Number(r[l].length) >= Number(d);
55
+ if (y === "lessThan")
56
+ return Number(r[l].length) <= Number(d);
53
57
  }
54
58
  return !1;
55
59
  }
@@ -66,33 +70,33 @@ function ae(t = {}) {
66
70
  return typeof c == "number" ? [{ target: m, operator: "length", param: null, value: Number(c) }] : typeof c == "boolean" ? [{ target: m, operator: "getProperty", param: l, value: !!c }] : typeof c == "object" ? Object.keys(c).map((r) => {
67
71
  if (r === "length")
68
72
  return { target: m, operator: "length", param: null, value: c[r] };
69
- const p = r, y = c[r];
70
- return { target: m, operator: "getProperty", param: p, value: y };
73
+ const y = r, d = c[r];
74
+ return { target: m, operator: "getProperty", param: y, value: d };
71
75
  }) : [];
72
76
  }
73
- function o(l) {
77
+ function s(l) {
74
78
  return Object.keys(l).reduce((m, r) => {
75
- const p = i(r, l[r]);
76
- return m.push(...p), m;
79
+ const y = i(r, l[r]);
80
+ return m.push(...y), m;
77
81
  }, []);
78
82
  }
79
- function s(l, c) {
83
+ function o(l, c) {
80
84
  if (a.has(l.operator)) {
81
85
  const m = a.get(l.operator);
82
86
  return m && m(l.target, l.param, l.value, c) || !1;
83
87
  }
84
88
  return !1;
85
89
  }
86
- function d(l, c) {
87
- return o(l).reduce((p, y) => p && s(y, c), !0);
90
+ function f(l, c) {
91
+ return s(l).reduce((y, d) => y && o(d, c), !0);
88
92
  }
89
- function h(l, c) {
90
- const m = Object.keys(l), r = m.includes("allOf"), p = m.includes("anyOf"), y = r || p, S = (y ? l[y ? r ? "allOf" : "anyOf" : "allOf"] : [l]).map((f) => d(f, c));
91
- return r ? !S.includes(!1) : S.includes(!0);
93
+ function v(l, c) {
94
+ const m = Object.keys(l), r = m.includes("allOf"), y = m.includes("anyOf"), d = r || y, R = (d ? l[d ? r ? "allOf" : "anyOf" : "allOf"] : [l]).map((u) => f(u, c));
95
+ return r ? !R.includes(!1) : R.includes(!0);
92
96
  }
93
- return { parseValueSchema: h };
97
+ return { parseValueSchema: v };
94
98
  }
95
- const L = {
99
+ const O = {
96
100
  button: { type: "button", name: "按钮", icon: "Button" },
97
101
  "response-toolbar": { type: "response-toolbar", name: "工具栏", icon: "ButtonGroup" },
98
102
  "response-toolbar-item": { type: "response-toolbar-item", name: "按钮", icon: "Button" },
@@ -130,20 +134,21 @@ const L = {
130
134
  "page-header": { type: "page-header", name: "页头", icon: "Header" },
131
135
  "page-footer": { type: "page-footer", name: "页脚", icon: "ModalFooter" },
132
136
  "tab-toolbar": { type: "tab-toolbar", name: "标签页工具栏", icon: "TabToolbar" },
133
- fieldset: { type: "fieldset", name: "分组", icon: "fieldset" }
134
- }, ie = {}, se = {};
137
+ fieldset: { type: "fieldset", name: "分组", icon: "fieldset" },
138
+ "query-solution": { type: "query-solution", name: "筛选方案", icon: "QueryScheme" }
139
+ }, ie = {}, oe = {};
135
140
  ae();
136
- function U(t, e, n = /* @__PURE__ */ new Map(), a = (s, d, h) => d, i = {}, o = (s) => s) {
137
- return G[e.title] = e, X[e.title] = a, ie[e.title] = i, se[e.title] = o, (s = {}) => {
138
- const d = ne(s, e, n), h = Object.keys(t).reduce((l, c) => (l[c] = t[c].default, l), {});
139
- return Object.assign(h, d);
141
+ function _(t, e, n = /* @__PURE__ */ new Map(), a = (o, f, v, l) => f, i = {}, s = (o) => o) {
142
+ return G[e.title] = e, X[e.title] = a, ie[e.title] = i, oe[e.title] = s, (o = {}) => {
143
+ const f = ne(o, e, n), v = Object.keys(t).reduce((l, c) => (l[c] = t[c].default, l), {});
144
+ return Object.assign(v, f);
140
145
  };
141
146
  }
142
- function _(t, e) {
147
+ function U(t, e) {
143
148
  return { customClass: e.class, customStyle: e.style };
144
149
  }
145
- const oe = /* @__PURE__ */ new Map([
146
- ["appearance", _]
150
+ const se = /* @__PURE__ */ new Map([
151
+ ["appearance", U]
147
152
  ]);
148
153
  function re(t, e, n) {
149
154
  const a = t.getSchemaByType("splitter-pane");
@@ -161,7 +166,7 @@ function ce(t, e, n) {
161
166
  const a = n.parentComponentInstance;
162
167
  return String(a.schema.appearance.class || "").split(" ").includes("f-page-main") && (e.appearance = { class: "f-page-content" }), re(t, e), le(t, e), e;
163
168
  }
164
- const ue = "https://json-schema.org/draft/2020-12/schema", pe = "https://farris-design.gitee.io/splitter.schema.json", fe = "splitter", me = "A Farris Container Component", de = "object", ye = {
169
+ const pe = "https://json-schema.org/draft/2020-12/schema", ue = "https://farris-design.gitee.io/splitter.schema.json", fe = "splitter", me = "A Farris Container Component", de = "object", ye = {
165
170
  id: {
166
171
  description: "The unique identifier for a splitter",
167
172
  type: "string"
@@ -199,13 +204,13 @@ const ue = "https://json-schema.org/draft/2020-12/schema", pe = "https://farris-
199
204
  ]
200
205
  }
201
206
  }, he = {
202
- $schema: ue,
203
- $id: pe,
207
+ $schema: pe,
208
+ $id: ue,
204
209
  title: fe,
205
210
  description: me,
206
211
  type: de,
207
212
  properties: ye
208
- }, ve = "splitter", be = "A Farris Container Component", ge = "object", Ce = {
213
+ }, ve = "splitter", be = "A Farris Container Component", ge = "object", ze = {
209
214
  basic: {
210
215
  description: "Basic Infomation",
211
216
  title: "基本信息",
@@ -248,46 +253,46 @@ const ue = "https://json-schema.org/draft/2020-12/schema", pe = "https://farris-
248
253
  }
249
254
  }
250
255
  }
251
- }, ze = {
256
+ }, Ce = {
252
257
  title: ve,
253
258
  description: be,
254
259
  type: ge,
255
- categories: Ce
256
- }, A = {
260
+ categories: ze
261
+ }, F = {
257
262
  customStyle: { type: String, default: "" },
258
263
  customClass: { type: String, default: "" },
259
264
  direction: { Type: String, default: "row" }
260
- }, N = U(A, he, oe, ce, ze);
261
- function J(t) {
262
- const e = C(-1), n = C(-1), a = C(0), i = C(0), o = C(!1), s = C(!1), d = P(() => ({
263
- display: o.value ? "block" : "none",
264
- left: `${a.value}px`
265
- })), h = P(() => ({
265
+ }, N = _(F, he, se, ce, Ce);
266
+ function Q(t) {
267
+ const e = g(-1), n = g(-1), a = g(0), i = g(0), s = g(!1), o = g(!1), f = C(() => ({
266
268
  display: s.value ? "block" : "none",
269
+ left: `${a.value}px`
270
+ })), v = C(() => ({
271
+ display: o.value ? "block" : "none",
267
272
  top: `${i.value}px`
268
- })), l = P(() => ({
269
- display: s.value || o.value ? "block" : "none"
273
+ })), l = C(() => ({
274
+ display: o.value || s.value ? "block" : "none"
270
275
  }));
271
276
  function c(r) {
272
- const p = t.value;
273
- if (p) {
274
- const { left: y } = p.getBoundingClientRect();
275
- a.value = r.clientX - y;
277
+ const y = t.value;
278
+ if (y) {
279
+ const { left: d } = y.getBoundingClientRect();
280
+ a.value = r.clientX - d;
276
281
  }
277
282
  }
278
283
  function m(r) {
279
- const p = t.value;
280
- if (p) {
281
- const { top: y } = p.getBoundingClientRect();
282
- i.value = r.clientY - y;
284
+ const y = t.value;
285
+ if (y) {
286
+ const { top: d } = y.getBoundingClientRect();
287
+ i.value = r.clientY - d;
283
288
  }
284
289
  }
285
290
  return {
286
- horizontalResizeHandleStyle: d,
287
- verticalResizeHandleStyle: h,
291
+ horizontalResizeHandleStyle: f,
292
+ verticalResizeHandleStyle: v,
288
293
  resizeOverlayStyle: l,
289
- showHorizontalResizeHandle: o,
290
- showVerticalResizeHandle: s,
294
+ showHorizontalResizeHandle: s,
295
+ showVerticalResizeHandle: o,
291
296
  horizontalResizeBarPosition: e,
292
297
  verticalResizeBarPosition: n,
293
298
  verticalResizeHandleOffset: i,
@@ -306,7 +311,7 @@ function we() {
306
311
  return t = n + a, i;
307
312
  };
308
313
  }
309
- function Se() {
314
+ function Re() {
310
315
  if (typeof window > "u")
311
316
  return () => 0;
312
317
  if (window.requestAnimationFrame)
@@ -314,58 +319,58 @@ function Se() {
314
319
  const t = Pe.filter((e) => `${e}RequestAnimationFrame` in window)[0];
315
320
  return t ? window[`${t}RequestAnimationFrame`] : we();
316
321
  }
317
- Se();
322
+ Re();
318
323
  function B(t, e) {
319
324
  return ((e == null ? void 0 : e.split(" ")) || []).reduce((a, i) => (i && (a[i] = !0), a), t), t;
320
325
  }
321
- function M(t, e) {
326
+ function L(t, e) {
322
327
  return ((e == null ? void 0 : e.split(";")) || []).reduce((a, i) => {
323
328
  if (i) {
324
- const o = i.split(":");
325
- a[o[0]] = o[1];
329
+ const s = i.split(":");
330
+ a[s[0]] = s[1];
326
331
  }
327
332
  return a;
328
333
  }, t), t;
329
334
  }
330
- const j = /* @__PURE__ */ k({
335
+ const H = /* @__PURE__ */ M({
331
336
  name: "FSplitter",
332
- props: A,
337
+ props: F,
333
338
  emits: [],
334
339
  setup(t, e) {
335
- const n = C(), a = J(n), {
340
+ const n = g(), a = Q(n), {
336
341
  horizontalResizeHandleStyle: i,
337
- verticalResizeHandleStyle: o,
338
- resizeOverlayStyle: s
342
+ verticalResizeHandleStyle: s,
343
+ resizeOverlayStyle: o
339
344
  } = a;
340
345
  W("splitter", {
341
346
  useResizeHandleComposition: a
342
347
  });
343
- const d = P(() => B({
348
+ const f = C(() => B({
344
349
  "f-splitter": !0
345
- }, t == null ? void 0 : t.customClass)), h = P(() => {
350
+ }, t == null ? void 0 : t.customClass)), v = C(() => {
346
351
  const l = {
347
352
  "flex-direction": t.direction === "row" ? "row" : "column"
348
353
  };
349
- return M(l, t == null ? void 0 : t.customStyle);
354
+ return L(l, t == null ? void 0 : t.customStyle);
350
355
  });
351
356
  return () => w("div", {
352
- class: d.value,
357
+ class: f.value,
353
358
  ref: n,
354
- style: h.value
359
+ style: v.value
355
360
  }, [e.slots.default && e.slots.default(), w("div", {
356
361
  class: "f-splitter-resize-overlay",
357
- style: s.value
362
+ style: o.value
358
363
  }, null), w("div", {
359
364
  class: "f-splitter-horizontal-resize-proxy",
360
365
  style: i.value
361
366
  }, null), w("div", {
362
367
  class: "f-splitter-vertical-resize-proxy",
363
- style: o.value
368
+ style: s.value
364
369
  }, null)]);
365
370
  }
366
- }), Re = /* @__PURE__ */ new Map([
367
- ["appearance", _]
368
- ]), De = "https://json-schema.org/draft/2020-12/schema", Te = "https://farris-design.gitee.io/splitter-pane.schema.json", Le = "splitter-pane", Oe = "A Farris Container Component", ke = "object", Be = {
371
+ }), Se = /* @__PURE__ */ new Map([
372
+ ["appearance", U]
373
+ ]), Te = "https://json-schema.org/draft/2020-12/schema", De = "https://farris-design.gitee.io/splitter-pane.schema.json", Oe = "splitter-pane", ke = "A Farris Container Component", Me = "object", Be = {
369
374
  id: {
370
375
  description: "The unique identifier for a splitter",
371
376
  type: "string"
@@ -441,14 +446,14 @@ const j = /* @__PURE__ */ k({
441
446
  type: "number",
442
447
  default: !0
443
448
  }
444
- }, Me = {
445
- $schema: De,
446
- $id: Te,
447
- title: Le,
448
- description: Oe,
449
- type: ke,
449
+ }, Le = {
450
+ $schema: Te,
451
+ $id: De,
452
+ title: Oe,
453
+ description: ke,
454
+ type: Me,
450
455
  properties: Be
451
- }, je = "splitter-pane", He = "A Farris Container Component", Ee = "object", Ae = {
456
+ }, He = "splitter-pane", je = "A Farris Container Component", Ee = "object", Fe = {
452
457
  basic: {
453
458
  description: "Basic Infomation",
454
459
  title: "基本信息",
@@ -548,12 +553,12 @@ const j = /* @__PURE__ */ k({
548
553
  }
549
554
  }
550
555
  }
551
- }, Fe = {
552
- title: je,
553
- description: He,
556
+ }, Ae = {
557
+ title: He,
558
+ description: je,
554
559
  type: Ee,
555
- categories: Ae
556
- }, F = {
560
+ categories: Fe
561
+ }, A = {
557
562
  customClass: { type: String, defaut: "" },
558
563
  customStyle: { type: String, default: "" },
559
564
  width: { type: Number },
@@ -565,7 +570,7 @@ const j = /* @__PURE__ */ k({
565
570
  visible: { type: Boolean, default: !0 },
566
571
  /** True to allow the pane can be resized. */
567
572
  resizable: { type: Boolean, default: !1 },
568
- /**指定拖拽的方向,可以指定多个方向,e向东,n向北,s向南,w向西
573
+ /** 指定拖拽的方向,可以指定多个方向,e向东,n向北,s向南,w向西
569
574
  * 因为位置在右侧,不一定就是w方向可拖拽的
570
575
  */
571
576
  resizeHandle: { type: String, default: "" },
@@ -575,203 +580,208 @@ const j = /* @__PURE__ */ k({
575
580
  minWidth: { type: Number, default: 0 },
576
581
  /** 面板最小高度 */
577
582
  minHeight: { type: Number, default: 0 }
578
- }, V = U(
579
- F,
580
- Me,
581
- Re,
583
+ }, V = _(
584
+ A,
585
+ Le,
586
+ Se,
582
587
  void 0,
583
- Fe
588
+ Ae
584
589
  );
585
- function Q(t, e) {
586
- const n = C(t.width), a = C(t.height), {
590
+ function J(t, e) {
591
+ const n = g(t.width), a = g(t.height), {
587
592
  horizontalResizeBarPosition: i,
588
- horizontalResizeHandleOffset: o,
589
- showHorizontalResizeHandle: s,
590
- showVerticalResizeHandle: d,
591
- verticalResizeBarPosition: h,
593
+ horizontalResizeHandleOffset: s,
594
+ showHorizontalResizeHandle: o,
595
+ showVerticalResizeHandle: f,
596
+ verticalResizeBarPosition: v,
592
597
  verticalResizeHandleOffset: l,
593
598
  draggingHorizontalResizeHandle: c,
594
599
  draggingVerticalResizeHandle: m
595
600
  } = e;
596
- let r = "", p, y;
597
- function g(u) {
598
- if ((r === "left" || r === "right") && y) {
599
- const { left: f } = y.getBoundingClientRect(), { width: z } = p.getBoundingClientRect(), v = u.clientX - f, b = r === "left" ? (z || 0) + (v - i.value) : (z || 0) - (v - i.value);
601
+ let r = "", y, d;
602
+ function P(p) {
603
+ if ((r === "left" || r === "right") && d) {
604
+ const { left: u } = d.getBoundingClientRect(), { width: z } = y.getBoundingClientRect(), h = p.clientX - u, b = r === "left" ? (z || 0) + (h - i.value) : (z || 0) - (h - i.value);
600
605
  n.value = t.minWidth > 0 ? Math.max(t.minWidth, b) : b;
601
606
  }
602
- if ((r === "top" || r === "bottom") && y) {
603
- const { top: f } = y.getBoundingClientRect(), { height: z } = p.getBoundingClientRect(), v = u.clientY - f, b = r === "top" ? (z || 0) + (v - h.value) : (z || 0) - (v - h.value);
607
+ if ((r === "top" || r === "bottom") && d) {
608
+ const { top: u } = d.getBoundingClientRect(), { height: z } = y.getBoundingClientRect(), h = p.clientY - u, b = r === "top" ? (z || 0) + (h - v.value) : (z || 0) - (h - v.value);
604
609
  a.value = t.minHeight > 0 ? Math.max(t.minHeight, b) : b;
605
610
  }
606
- o.value = 0, l.value = 0, i.value = -1, h.value = -1, s.value = !1, d.value = !1, document.removeEventListener("mousemove", c), document.removeEventListener("mouseup", g), document.body.style.userSelect = "", r = "", p = null, y = null;
611
+ s.value = 0, l.value = 0, i.value = -1, v.value = -1, o.value = !1, f.value = !1, document.removeEventListener("mousemove", c), document.removeEventListener("mouseup", P), document.body.style.userSelect = "", r = "", y = null, d = null;
607
612
  }
608
- function R(u, f, z) {
609
- if (r = f, p = z, s.value = !0, y = u.composedPath().find((b) => b.className.split(" ")[0] === "f-splitter"), y) {
610
- const { left: b } = y.getBoundingClientRect();
611
- o.value = u.clientX - b, i.value = u.clientX - b, document.addEventListener("mousemove", c), document.addEventListener("mouseup", g), document.body.style.userSelect = "none";
613
+ function T(p, u, z) {
614
+ if (r = u, y = z, o.value = !0, d = p.composedPath().find((b) => b.className.split(" ")[0] === "f-splitter"), d) {
615
+ const { left: b } = d.getBoundingClientRect();
616
+ s.value = p.clientX - b, i.value = p.clientX - b, document.addEventListener("mousemove", c), document.addEventListener("mouseup", P), document.body.style.userSelect = "none";
612
617
  }
613
618
  }
614
- function S(u, f, z) {
615
- if (r = f, p = z, d.value = !0, y = u.composedPath().find((b) => b.className.split(" ")[0] === "f-splitter"), y) {
616
- const { top: b } = y.getBoundingClientRect();
617
- l.value = u.clientY - b, h.value = u.clientY - b, document.addEventListener("mousemove", m), document.addEventListener("mouseup", g), document.body.style.userSelect = "none";
619
+ function R(p, u, z) {
620
+ if (r = u, y = z, f.value = !0, d = p.composedPath().find((b) => b.className.split(" ")[0] === "f-splitter"), d) {
621
+ const { top: b } = d.getBoundingClientRect();
622
+ l.value = p.clientY - b, v.value = p.clientY - b, document.addEventListener("mousemove", m), document.addEventListener("mouseup", P), document.body.style.userSelect = "none";
618
623
  }
619
624
  }
620
625
  return {
621
626
  actualWidth: n,
622
627
  actualHeight: a,
623
- onClickSplitterHorizontalResizeBar: R,
624
- onClickSplitterVerticalResizeBar: S
628
+ onClickSplitterHorizontalResizeBar: T,
629
+ onClickSplitterVerticalResizeBar: R
625
630
  };
626
631
  }
627
- const H = /* @__PURE__ */ k({
632
+ const j = /* @__PURE__ */ M({
628
633
  name: "FSplitterPane",
629
- props: F,
634
+ props: A,
630
635
  emits: [],
631
636
  setup(t, e) {
632
- const n = C(), a = O("splitter"), {
637
+ const n = g(), a = k("splitter"), {
633
638
  useResizeHandleComposition: i
634
- } = a, o = Q(t, i), {
635
- actualHeight: s,
636
- actualWidth: d,
637
- onClickSplitterHorizontalResizeBar: h,
639
+ } = a, s = J(t, i), {
640
+ actualHeight: o,
641
+ actualWidth: f,
642
+ onClickSplitterHorizontalResizeBar: v,
638
643
  onClickSplitterVerticalResizeBar: l
639
- } = o, c = C(t.position), m = P(() => {
640
- const u = {
644
+ } = s, c = g(t.position), m = C(() => {
645
+ const p = {
641
646
  "f-splitter-pane": !0,
642
647
  "f-splitter-pane-main": c.value === "center",
643
648
  "has-resize-bar": t.resizable
644
649
  };
645
- return u["f-splitter-pane-" + c.value] = !0, B(u, t == null ? void 0 : t.customClass);
646
- }), r = P(() => {
647
- const u = {};
648
- return (d.value && c.value === "left" || c.value === "right" || p.value.find((f) => f == "e") || p.value.find((f) => f == "w")) && (u.width = `${d.value}px`), (s.value && c.value === "bottom" || c.value === "top" || p.value.find((f) => f == "s") || p.value.find((f) => f == "n")) && (u.height = `${s.value}px`), M(u, t == null ? void 0 : t.customStyle);
649
- }), p = P(() => t.resizeHandle ? t.resizeHandle.split(",").filter((u) => ["e", "n", "s", "w"].find((f) => f == u)) : []), y = P(() => ({
650
+ return p["f-splitter-pane-" + c.value] = !0, B(p, t == null ? void 0 : t.customClass);
651
+ }), r = C(() => t.resizeHandle ? t.resizeHandle.split(",").filter((p) => ["e", "n", "s", "w"].find((u) => u === p)) : []), y = C(() => {
652
+ const p = {};
653
+ return (f.value && c.value === "left" || c.value === "right" || r.value.find((u) => u === "e") || r.value.find((u) => u === "w")) && (p.width = `${f.value}px`), (o.value && c.value === "bottom" || c.value === "top" || r.value.find((u) => u === "s") || r.value.find((u) => u === "n")) && (p.height = `${o.value}px`), L(p, t == null ? void 0 : t.customStyle);
654
+ }), d = C(() => ({
650
655
  "f-splitter-resize-bar": !0,
651
656
  "f-splitter-resize-bar-e": c.value === "left",
652
657
  "f-splitter-resize-bar-n": c.value === "bottom",
653
658
  "f-splitter-resize-bar-s": c.value === "top",
654
659
  "f-splitter-resize-bar-w": c.value === "right"
655
660
  }));
656
- function g(u, f) {
657
- f = R(f), ["left", "right"].find((z) => z == f) && h(u, f, n.value), ["top", "bottom"].find((z) => z == f) && l(u, f, n.value);
658
- }
659
- function R(u) {
661
+ function P(p) {
660
662
  return {
661
663
  e: "left",
662
664
  w: "right",
663
665
  s: "top",
664
666
  n: "bottom"
665
- }[u] || u;
667
+ }[p] || p;
668
+ }
669
+ function T(p, u) {
670
+ u = P(u), ["left", "right"].find((z) => z === u) && v(p, u, n.value), ["top", "bottom"].find((z) => z === u) && l(p, u, n.value);
666
671
  }
667
- function S() {
668
- return p.value.length > 0 ? p.value.map((u) => w("span", {
669
- class: "f-splitter-resize-bar f-splitter-resize-bar-" + u,
670
- onMousedown: (f) => g(f, u)
672
+ function R() {
673
+ return r.value.length > 0 ? r.value.map((p) => w("span", {
674
+ class: "f-splitter-resize-bar f-splitter-resize-bar-" + p,
675
+ onMousedown: (u) => T(u, p)
671
676
  }, null)) : w("span", {
672
- class: y.value,
673
- onMousedown: (u) => g(u, c.value)
677
+ class: d.value,
678
+ onMousedown: (p) => T(p, c.value)
674
679
  }, null);
675
680
  }
676
681
  return () => w("div", {
677
682
  ref: n,
678
683
  class: m.value,
679
- style: r.value
680
- }, [e.slots.default && e.slots.default(), t.resizable && S()]);
684
+ style: y.value
685
+ }, [e.slots.default && e.slots.default(), t.resizable && R()]);
681
686
  }
682
687
  });
683
688
  function Z(t, e, n) {
684
689
  var z;
685
- function a() {
686
- n != null && n.resolveComponentContext && n.resolveComponentContext();
687
- }
688
- a();
689
- const i = n && n.getStyles && n.getStyles() || "", o = n && n.getDesignerClass && n.getDesignerClass() || "", s = C();
690
- function d() {
690
+ const a = n && n.getStyles && n.getStyles() || "", i = n && n.getDesignerClass && n.getDesignerClass() || "", s = g();
691
+ function o() {
691
692
  return (e == null ? void 0 : e.schema.componentType) === "frame" ? !1 : n && n.checkCanMoveComponent ? n.checkCanMoveComponent() : !0;
692
693
  }
693
- function h() {
694
+ function f() {
694
695
  return !1;
695
696
  }
696
- function l() {
697
+ function v() {
697
698
  return (e == null ? void 0 : e.schema.componentType) === "frame" ? !1 : n && n.checkCanDeleteComponent ? n.checkCanDeleteComponent() : !0;
698
699
  }
699
- function c() {
700
+ function l() {
700
701
  return (e == null ? void 0 : e.schema.componentType) === "frame" ? !0 : n && n.hideNestedPaddingInDesginerView ? n.hideNestedPaddingInDesginerView() : !1;
701
702
  }
702
- function m(v) {
703
- if (!v || !v.value)
703
+ function c(h) {
704
+ if (!h || !h.value)
704
705
  return null;
705
- if (v.value.schema && v.value.schema.type === "component")
706
- return v.value;
707
- const b = C(v == null ? void 0 : v.value.parent), D = m(b);
708
- return D || null;
706
+ if (h.value.schema && h.value.schema.type === "component")
707
+ return h.value;
708
+ const b = g(h == null ? void 0 : h.value.parent), S = c(b);
709
+ return S || null;
709
710
  }
710
- function r(v = e) {
711
- const { componentInstance: b, designerItemElementRef: D } = v;
712
- return !b || !b.value ? null : b.value.canMove ? D : r(v.parent);
711
+ function m(h = e) {
712
+ const { componentInstance: b, designerItemElementRef: S } = h;
713
+ return !b || !b.value ? null : b.value.canMove ? S : m(h.parent);
713
714
  }
714
- function p(v) {
715
- return !!n && n.canAccepts(v);
715
+ function r(h) {
716
+ return !!n && n.canAccepts(h);
716
717
  }
717
718
  function y() {
718
719
  return (e == null ? void 0 : e.schema.label) || (e == null ? void 0 : e.schema.title) || (e == null ? void 0 : e.schema.name);
719
720
  }
720
- function g() {
721
+ function d() {
721
722
  }
722
- function R(v, b) {
723
+ function P(h, b) {
723
724
  b && n != null && n.onAcceptMovedChildElement && n.onAcceptMovedChildElement(b);
724
725
  }
725
- function S(v, b) {
726
- const { componentType: D } = v;
727
- let T = Y(D, v, b);
728
- n && n.onResolveNewComponentSchema && (T = n.onResolveNewComponentSchema(v, T));
729
- const K = D.toLowerCase().replace("-", "_");
730
- return T && !T.id && T.type === D && (T.id = `${K}_${Math.random().toString().slice(2, 6)}`), T;
726
+ function T(h, b) {
727
+ const { componentType: S } = h;
728
+ let D = Y(S, h, b);
729
+ n && n.onResolveNewComponentSchema && (D = n.onResolveNewComponentSchema(h, D));
730
+ const K = S.toLowerCase().replace(/-/g, "_");
731
+ return D && !D.id && D.type === S && (D.id = `${K}_${Math.random().toString().slice(2, 6)}`), D;
731
732
  }
732
- function u(v) {
733
+ function R(h) {
733
734
  }
734
- function f(...v) {
735
+ function p(...h) {
735
736
  if (n && n.getPropsConfig)
736
- return n.getPropsConfig(...v);
737
+ return n.getPropsConfig(...h);
738
+ }
739
+ function u() {
740
+ n && n.onRemoveComponent && n.onRemoveComponent(), e != null && e.schema.contents && e.schema.contents.map((h) => {
741
+ var D;
742
+ let b = h.id;
743
+ h.type === "component-ref" && (b = h.component);
744
+ const S = t.value.querySelector(`#${b}-design-item`);
745
+ (D = S == null ? void 0 : S.componentInstance) != null && D.value.onRemoveComponent && S.componentInstance.value.onRemoveComponent();
746
+ });
737
747
  }
738
748
  return s.value = {
739
- canMove: d(),
740
- canSelectParent: h(),
741
- canDelete: l(),
742
- canNested: !c(),
749
+ canMove: o(),
750
+ canSelectParent: f(),
751
+ canDelete: v(),
752
+ canNested: !l(),
743
753
  contents: e == null ? void 0 : e.schema.contents,
744
754
  elementRef: t,
745
755
  parent: (z = e == null ? void 0 : e.parent) == null ? void 0 : z.componentInstance,
746
756
  schema: e == null ? void 0 : e.schema,
747
- styles: i,
748
- designerClass: o,
749
- canAccepts: p,
750
- getBelongedComponentInstance: m,
751
- getDraggableDesignItemElement: r,
757
+ styles: a,
758
+ designerClass: i,
759
+ canAccepts: r,
760
+ getBelongedComponentInstance: c,
761
+ getDraggableDesignItemElement: m,
752
762
  getDraggingDisplayText: y,
753
- getPropConfig: f,
754
- getDragScopeElement: g,
755
- onAcceptMovedChildElement: R,
756
- onChildElementMovedOut: u,
757
- addNewChildComponentSchema: S,
758
- updateDragAndDropRules: a,
759
- triggerBelongedComponentToMoveWhenMoved: !!n && n.triggerBelongedComponentToMoveWhenMoved || C(!1),
760
- triggerBelongedComponentToDeleteWhenDeleted: !!n && n.triggerBelongedComponentToDeleteWhenDeleted || C(!1)
763
+ getPropConfig: p,
764
+ getDragScopeElement: d,
765
+ onAcceptMovedChildElement: P,
766
+ onChildElementMovedOut: R,
767
+ addNewChildComponentSchema: T,
768
+ triggerBelongedComponentToMoveWhenMoved: !!n && n.triggerBelongedComponentToMoveWhenMoved || g(!1),
769
+ triggerBelongedComponentToDeleteWhenDeleted: !!n && n.triggerBelongedComponentToDeleteWhenDeleted || g(!1),
770
+ onRemoveComponent: u
761
771
  }, s;
762
772
  }
763
773
  class x {
764
774
  getTemplateRule(e, n) {
765
- const a = n == null ? void 0 : n.formSchemaUtils, i = a == null ? void 0 : a.getFormTemplateRule(), o = { canAccept: !0, canDelete: !0, canMove: !0 };
775
+ const a = n == null ? void 0 : n.formSchemaUtils, i = a == null ? void 0 : a.getFormTemplateRule(), s = { canAccept: !0, canDelete: !0, canMove: !0 };
766
776
  if (!i)
767
- return o;
768
- const s = this.getComponentContext(e);
769
- return s.componentClassList.forEach((h) => {
770
- if (!h || !i[h])
777
+ return s;
778
+ const o = this.getComponentContext(e), { componentClassList: f } = o;
779
+ return f.forEach((v) => {
780
+ if (!v || !i[v])
771
781
  return;
772
- const { canMove: l, canDelete: c, canAccept: m } = i[h];
773
- o.canMove = o.canMove && this.resolveRuleValue(l, s), o.canDelete = o.canDelete && this.resolveRuleValue(c, s), o.canAccept = o.canAccept && this.resolveRuleValue(m, s);
774
- }), o;
782
+ const { canMove: l, canDelete: c, canAccept: m } = i[v];
783
+ s.canMove = s.canMove && this.resolveRuleValue(l, o), s.canDelete = s.canDelete && this.resolveRuleValue(c, o), s.canAccept = s.canAccept && this.resolveRuleValue(m, o);
784
+ }), s;
775
785
  }
776
786
  resolveRuleValue(e, n) {
777
787
  return typeof e == "boolean" ? e : this.parseRuleValueSchema(e, n);
@@ -779,50 +789,50 @@ class x {
779
789
  parseRuleValueSchema(e, n) {
780
790
  const a = e.invalidContext || [];
781
791
  let i = !0;
782
- for (const o of a) {
783
- if (o.firstLevelChild) {
784
- if (o.firstLevelChild.class) {
785
- const s = n.firstLevelChildClassList;
786
- if (s && !s.includes(o.firstLevelChild.class)) {
792
+ for (const s of a) {
793
+ if (s.firstLevelChild) {
794
+ if (s.firstLevelChild.class) {
795
+ const { firstLevelChildClassList: o } = n;
796
+ if (o && !o.includes(s.firstLevelChild.class)) {
787
797
  i = !1;
788
798
  continue;
789
799
  }
790
800
  }
791
- if (o.firstLevelChild.type) {
792
- const s = n.firstLevelChildSchema;
793
- if (s && s.type !== o.firstLevelChild.type) {
801
+ if (s.firstLevelChild.type) {
802
+ const { firstLevelChildSchema: o } = n;
803
+ if (!o || o.type !== s.firstLevelChild.type) {
794
804
  i = !1;
795
805
  continue;
796
806
  }
797
807
  }
798
808
  }
799
- if (o.secondLevelChild) {
800
- if (o.secondLevelChild.class) {
801
- const s = n.secondLevelChildClassList;
802
- if (s && !s.includes(o.secondLevelChild.class)) {
809
+ if (s.secondLevelChild) {
810
+ if (s.secondLevelChild.class) {
811
+ const { secondLevelChildClassList: o } = n;
812
+ if (o && !o.includes(s.secondLevelChild.class)) {
803
813
  i = !1;
804
814
  continue;
805
815
  }
806
816
  }
807
- if (o.secondLevelChild.type) {
808
- const s = n.secondLevelChildSchema;
809
- if (s && s.type !== o.secondLevelChild.type) {
817
+ if (s.secondLevelChild.type) {
818
+ const { secondLevelChildSchema: o } = n;
819
+ if (!o || o.type !== s.secondLevelChild.type) {
810
820
  i = !1;
811
821
  continue;
812
822
  }
813
823
  }
814
824
  }
815
- if (o.parent) {
816
- if (o.parent.class) {
817
- const s = n.parentClassList;
818
- if (s && !s.includes(o.parent.class)) {
825
+ if (s.parent) {
826
+ if (s.parent.class) {
827
+ const { parentClassList: o } = n;
828
+ if (o && !o.includes(s.parent.class)) {
819
829
  i = !1;
820
830
  continue;
821
831
  }
822
832
  }
823
- if (o.parent.type) {
824
- const s = n.parentSchema;
825
- if (s && s.type !== o.parent.type) {
833
+ if (s.parent.type) {
834
+ const { parentSchema: o } = n;
835
+ if (o && o.type !== s.parent.type) {
826
836
  i = !1;
827
837
  continue;
828
838
  }
@@ -834,66 +844,66 @@ class x {
834
844
  return !i;
835
845
  }
836
846
  getComponentContext(e) {
837
- var g, R, S, u;
838
- const n = e.schema, a = n.appearance && n.appearance.class || "", i = a.split(" ") || [], o = n.contents || [], s = o.length ? o[0] : null, d = s && s.appearance ? s.appearance.class : "", h = d ? d.split(" ") : [], l = (g = s == null ? void 0 : s.contents) != null && g.length ? s == null ? void 0 : s.contents[0] : null, c = l && l.appearance ? l.appearance.class : "", m = c ? c.split(" ") : [], r = n.type === "component" ? (S = (R = e.parent) == null ? void 0 : R.parent) == null ? void 0 : S.schema : (u = e.parent) == null ? void 0 : u.schema, p = r && r.appearance && r.appearance.class || "", y = p ? p.split(" ") : [];
847
+ var P, T, R, p;
848
+ const n = e.schema, a = n.appearance && n.appearance.class || "", i = a.split(" ") || [], s = n.contents || [], o = s.length ? s[0] : null, f = o && o.appearance ? o.appearance.class : "", v = f ? f.split(" ") : [], l = (P = o == null ? void 0 : o.contents) != null && P.length ? o == null ? void 0 : o.contents[0] : null, c = l && l.appearance ? l.appearance.class : "", m = c ? c.split(" ") : [], r = n.type === "component" ? (R = (T = e.parent) == null ? void 0 : T.parent) == null ? void 0 : R.schema : (p = e.parent) == null ? void 0 : p.schema, y = r && r.appearance && r.appearance.class || "", d = y ? y.split(" ") : [];
839
849
  return {
840
850
  componentClass: a,
841
851
  componentClassList: i,
842
- childContents: o,
843
- firstLevelChildSchema: s,
844
- firstLevelChildClass: d,
845
- firstLevelChildClassList: h,
852
+ childContents: s,
853
+ firstLevelChildSchema: o,
854
+ firstLevelChildClass: f,
855
+ firstLevelChildClassList: v,
846
856
  secondLevelChildSchema: l,
847
857
  secondLevelChildClass: c,
848
858
  secondLevelChildClassList: m,
849
859
  parentSchema: r,
850
- parentClass: p,
851
- parentClassList: y
860
+ parentClass: y,
861
+ parentClassList: d
852
862
  };
853
863
  }
854
864
  }
855
865
  function $e(t, e) {
856
866
  const n = new x(), { canMove: a, canDelete: i } = n.getTemplateRule(t, e);
857
- function o() {
867
+ function s() {
858
868
  return !1;
859
869
  }
860
- function s() {
870
+ function o() {
861
871
  return i;
862
872
  }
863
- function d() {
873
+ function f() {
864
874
  return a;
865
875
  }
866
- function h() {
876
+ function v() {
867
877
  return !0;
868
878
  }
869
- return { canAccepts: o, checkCanDeleteComponent: s, checkCanMoveComponent: d, hideNestedPaddingInDesginerView: h };
879
+ return { canAccepts: s, checkCanDeleteComponent: o, checkCanMoveComponent: f, hideNestedPaddingInDesginerView: v };
870
880
  }
871
- const Ne = /* @__PURE__ */ k({
881
+ const Ne = /* @__PURE__ */ M({
872
882
  name: "FSplitterDesign",
873
- props: A,
883
+ props: F,
874
884
  emits: [],
875
885
  setup(t, e) {
876
- const n = C(), a = O("designer-host-service"), i = O("design-item-context"), o = $e(i, a), s = Z(n, i, o);
877
- s.value.canNested = !1;
878
- const d = J(n), {
879
- horizontalResizeHandleStyle: h,
886
+ const n = g(), a = k("designer-host-service"), i = k("design-item-context"), s = $e(i, a), o = Z(n, i, s);
887
+ o.value.canNested = !1;
888
+ const f = Q(n), {
889
+ horizontalResizeHandleStyle: v,
880
890
  verticalResizeHandleStyle: l,
881
891
  resizeOverlayStyle: c
882
- } = d;
892
+ } = f;
883
893
  W("splitter", {
884
- useResizeHandleComposition: d
894
+ useResizeHandleComposition: f
885
895
  });
886
- const m = P(() => B({
896
+ const m = C(() => B({
887
897
  "f-splitter": !0
888
- }, t == null ? void 0 : t.customClass)), r = P(() => {
889
- const p = {
898
+ }, t == null ? void 0 : t.customClass)), r = C(() => {
899
+ const y = {
890
900
  "flex-direction": t.direction === "row" ? "row" : "column"
891
901
  };
892
- return M(p, t == null ? void 0 : t.customStyle);
902
+ return L(y, t == null ? void 0 : t.customStyle);
893
903
  });
894
904
  return q(() => {
895
- n.value.componentInstance = s;
896
- }), e.expose(s.value), () => w("div", {
905
+ n.value.componentInstance = o;
906
+ }), e.expose(o.value), () => w("div", {
897
907
  class: m.value,
898
908
  ref: n,
899
909
  style: r.value
@@ -902,7 +912,7 @@ const Ne = /* @__PURE__ */ k({
902
912
  style: c.value
903
913
  }, null), w("div", {
904
914
  class: "f-splitter-horizontal-resize-proxy",
905
- style: h.value
915
+ style: v.value
906
916
  }, null), w("div", {
907
917
  class: "f-splitter-vertical-resize-proxy",
908
918
  style: l.value
@@ -911,14 +921,14 @@ const Ne = /* @__PURE__ */ k({
911
921
  });
912
922
  function Ve() {
913
923
  function t(e, n) {
914
- var s;
924
+ var o;
915
925
  if (!e)
916
926
  return !1;
917
- const a = ((s = e.targetContainer) == null ? void 0 : s.componentInstance) && e.targetContainer.componentInstance.value;
927
+ const a = ((o = e.targetContainer) == null ? void 0 : o.componentInstance) && e.targetContainer.componentInstance.value;
918
928
  if (!a)
919
929
  return !1;
920
- const i = a.schema.type, o = n == null ? void 0 : n.formSchemaUtils.getComponentById(a.belongedComponentId);
921
- return !((e.controlCategory === "input" || e.controlType === "form-group") && ![L["response-layout-item"].type, L["response-form"].type].includes(i) || (e.controlType === L.tabs.type || e.controlType === L.section.type) && ((o == null ? void 0 : o.componentType) !== "frame" || ![L["content-container"].type, L["splitter-pane"].type, L["response-layout-item"].type].includes(i)));
930
+ const i = a.schema.type, s = n == null ? void 0 : n.formSchemaUtils.getComponentById(a.belongedComponentId);
931
+ return !((e.componentCategory === "input" || e.componentType === "form-group") && ![O["response-layout-item"].type, O["response-form"].type].includes(i) || (e.componentType === O.tabs.type || e.componentType === O.section.type) && ((s == null ? void 0 : s.componentType) !== "frame" || ![O["content-container"].type, O["splitter-pane"].type, O["response-layout-item"].type].includes(i)));
922
932
  }
923
933
  return {
924
934
  basalDragulaRuleForContainer: t
@@ -926,83 +936,83 @@ function Ve() {
926
936
  }
927
937
  function We(t, e) {
928
938
  const n = new x(), { canAccept: a } = n.getTemplateRule(t, e);
929
- function i(d) {
930
- return Ve().basalDragulaRuleForContainer(d, e) ? a : !1;
939
+ function i(f) {
940
+ return Ve().basalDragulaRuleForContainer(f, e) ? a : !1;
931
941
  }
932
- function o() {
942
+ function s() {
933
943
  return !1;
934
944
  }
935
- function s() {
945
+ function o() {
936
946
  return !1;
937
947
  }
938
948
  return {
939
949
  canAccepts: i,
940
- checkCanMoveComponent: o,
941
- checkCanDeleteComponent: s
950
+ checkCanMoveComponent: s,
951
+ checkCanDeleteComponent: o
942
952
  };
943
953
  }
944
- const qe = /* @__PURE__ */ k({
954
+ const qe = /* @__PURE__ */ M({
945
955
  name: "FSplitterPaneDesign",
946
- props: F,
956
+ props: A,
947
957
  emits: [],
948
958
  setup(t, e) {
949
- const n = C(), a = O("designer-host-service"), i = O("design-item-context"), o = We(i, a), s = Z(n, i, o);
950
- s.value.styles = "padding:0;box-shadow:none;", s.value.canNested = !1, s.value.canMove = !1, s.value.canDelete = !1, q(() => {
951
- n.value.componentInstance = s;
952
- }), e.expose(s.value);
953
- const d = O("splitter"), {
954
- useResizeHandleComposition: h
955
- } = d, l = Q(t, h), {
959
+ const n = g(), a = k("designer-host-service"), i = k("design-item-context"), s = We(i, a), o = Z(n, i, s);
960
+ o.value.styles = "padding:0;box-shadow:none;", o.value.canNested = !1, o.value.canMove = !1, o.value.canDelete = !1, q(() => {
961
+ n.value.componentInstance = o;
962
+ }), e.expose(o.value);
963
+ const f = k("splitter"), {
964
+ useResizeHandleComposition: v
965
+ } = f, l = J(t, v), {
956
966
  actualHeight: c,
957
967
  actualWidth: m
958
- } = l, r = C(t.position), p = P(() => {
959
- const u = {
968
+ } = l, r = g(t.position), y = C(() => {
969
+ const p = {
960
970
  "f-splitter-pane": !0,
961
971
  "f-splitter-pane-main": r.value === "center",
962
972
  "has-resize-bar": t.resizable,
963
973
  "f-component-splitter-pane": !0,
964
974
  "drag-container": !0
965
975
  };
966
- return u["f-splitter-pane-" + r.value] = !0, B(u, t == null ? void 0 : t.customClass);
967
- }), y = P(() => {
968
- const u = {};
969
- return (m.value && r.value === "left" || r.value === "right" || g.value.find((f) => f == "e") || g.value.find((f) => f == "w")) && (u.width = `${m.value}px`), (c.value && r.value === "bottom" || r.value === "top" || g.value.find((f) => f == "s") || g.value.find((f) => f == "n")) && (u.height = `${c.value}px`), M(u, t == null ? void 0 : t.customStyle);
970
- }), g = P(() => t.resizeHandle ? t.resizeHandle.split(",").filter((u) => ["e", "n", "s", "w"].find((f) => f == u)) : []), R = P(() => ({
976
+ return p["f-splitter-pane-" + r.value] = !0, B(p, t == null ? void 0 : t.customClass);
977
+ }), d = C(() => t.resizeHandle ? t.resizeHandle.split(",").filter((p) => ["e", "n", "s", "w"].find((u) => u === p)) : []), P = C(() => {
978
+ const p = {};
979
+ return (m.value && r.value === "left" || r.value === "right" || d.value.find((u) => u === "e") || d.value.find((u) => u === "w")) && (p.width = `${m.value}px`), (c.value && r.value === "bottom" || r.value === "top" || d.value.find((u) => u === "s") || d.value.find((u) => u === "n")) && (p.height = `${c.value}px`), L(p, t == null ? void 0 : t.customStyle);
980
+ }), T = C(() => ({
971
981
  "f-splitter-resize-bar": !0,
972
982
  "f-splitter-resize-bar-e": r.value === "left",
973
983
  "f-splitter-resize-bar-n": r.value === "bottom",
974
984
  "f-splitter-resize-bar-s": r.value === "top",
975
985
  "f-splitter-resize-bar-w": r.value === "right"
976
986
  }));
977
- function S() {
978
- return g.value.length > 0 ? g.value.map((u) => w("span", {
979
- class: "f-splitter-resize-bar f-splitter-resize-bar-" + u
987
+ function R() {
988
+ return d.value.length > 0 ? d.value.map((p) => w("span", {
989
+ class: "f-splitter-resize-bar f-splitter-resize-bar-" + p
980
990
  }, null)) : w("span", {
981
- class: R.value
991
+ class: T.value
982
992
  }, null);
983
993
  }
984
994
  return () => w("div", {
985
995
  ref: n,
986
996
  "data-dragref": `${i.schema.id}-container`,
987
- class: p.value,
988
- style: y.value
989
- }, [e.slots.default && e.slots.default(), t.resizable && S()]);
997
+ class: y.value,
998
+ style: P.value
999
+ }, [e.slots.default && e.slots.default(), t.resizable && R()]);
990
1000
  }
991
- }), Ue = {
1001
+ }), _e = {
992
1002
  install(t) {
993
- t.component(j.name, j), t.component(H.name, H);
1003
+ t.component(H.name, H), t.component(j.name, j);
994
1004
  },
995
1005
  register(t, e, n, a) {
996
- t.splitter = j, e.splitter = N, t["splitter-pane"] = H, e["splitter-pane"] = V;
1006
+ t.splitter = H, e.splitter = N, t["splitter-pane"] = j, e["splitter-pane"] = V;
997
1007
  },
998
1008
  registerDesigner(t, e, n) {
999
1009
  t.splitter = Ne, e.splitter = N, t["splitter-pane"] = qe, e["splitter-pane"] = V;
1000
1010
  }
1001
1011
  };
1002
1012
  export {
1003
- j as FSplitter,
1004
- H as FSplitterPane,
1005
- Ue as default,
1006
- A as splitterProps,
1013
+ H as FSplitter,
1014
+ j as FSplitterPane,
1015
+ _e as default,
1016
+ F as splitterProps,
1007
1017
  N as splitterPropsResolver
1008
1018
  };