hldesigner 0.0.294 → 0.0.296

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 (215) hide show
  1. package/{_pdf-6d272319.js → _pdf-1b95fb5d.js} +13 -12
  2. package/{_share_image-707deb7b.js → _share_image-0ca0ad96.js} +2 -2
  3. package/{_share_size.vue_vue_type_script_setup_true_lang-198b6412.js → _share_size.vue_vue_type_script_setup_true_lang-25e38d41.js} +3 -3
  4. package/{_txt-14955ea9.js → _txt-170bb7d6.js} +8 -7
  5. package/{_unsupport-8b411d51.js → _unsupport-1309283f.js} +2 -2
  6. package/{affix-widget-b164f66f.js → affix-widget-a1e94961.js} +25 -24
  7. package/{alert-widget-a5b38a7f.js → alert-widget-e89962f3.js} +25 -24
  8. package/{anchor-widget-cb79aead.js → anchor-widget-2666cfcb.js} +22 -21
  9. package/{auto-complete-widget-2b5c9b04.js → auto-complete-widget-f19efc93.js} +25 -24
  10. package/avatar-widget-d1f582e7.js +49 -0
  11. package/{backtop-widget-54df7811.js → backtop-widget-800b83e2.js} +25 -24
  12. package/{badge-widget-b3e2b84e.js → badge-widget-3dfede47.js} +28 -27
  13. package/{barcode-widget-c9539f20.js → barcode-widget-1a9a8e4a.js} +23 -22
  14. package/{baseImp-7f0c4121.js → baseCommonField-607f46b1.js} +3567 -3903
  15. package/baseDataType-af503f9f.js +4 -0
  16. package/{breadcrumb-widget-966a5b98.js → breadcrumb-widget-72fc4371.js} +28 -27
  17. package/{button-widget-b29f2836.js → button-widget-3f9aebd6.js} +25 -24
  18. package/{cache-widget-8cdf6bb3.js → cache-widget-4446b135.js} +24 -23
  19. package/{card-widget-635325c2.js → card-widget-ce3e3897.js} +40 -39
  20. package/{carousel-widget-a7f37b1e.js → carousel-widget-cc0ed1e7.js} +23 -22
  21. package/{cascader-widget-8bb5f9db.js → cascader-widget-d1fc3ca0.js} +24 -23
  22. package/{chart-widget-fb1a670b.js → chart-widget-85cb8854.js} +48 -47
  23. package/{checkbox-widget-52c61029.js → checkbox-widget-db3afa9b.js} +31 -30
  24. package/codeType-e06c2bb4.js +4 -0
  25. package/{collapse-widget-a4d2945d.js → collapse-widget-8779845e.js} +29 -28
  26. package/{color-picker-widget-c7d26f46.js → color-picker-widget-f745a9cd.js} +24 -23
  27. package/common-editor-353641ab.js +30 -0
  28. package/{common-editor.vue_vue_type_script_setup_true_name_common-editor_lang-cd2508fd.js → common-editor.vue_vue_type_script_setup_true_name_common-editor_lang-8352d795.js} +2 -2
  29. package/{configItem-e39cd3bb.js → configItem-7889264b.js} +51 -50
  30. package/{cont-cell-widget-d4a89c8a.js → cont-cell-widget-d44e04d3.js} +1 -1
  31. package/{cont-cell-widget.vue_vue_type_script_setup_true_name_cont-cell-widget_lang-a72224f3.js → cont-cell-widget.vue_vue_type_script_setup_true_name_cont-cell-widget_lang-b5288fd3.js} +5 -5
  32. package/{cont-widget-c1e4feae.js → cont-widget-18cd3de8.js} +5 -5
  33. package/content-wrapper-36adcccb.js +19 -0
  34. package/{content-wrapper.vue_vue_type_script_setup_true_lang-74a9ce66.js → content-wrapper.vue_vue_type_script_setup_true_lang-88a3a92e.js} +7 -7
  35. package/countdown-widget-8716e1ba.js +61 -0
  36. package/{css-editor-1b37b14b.js → css-editor-53b67144.js} +80 -77
  37. package/{cssClass-de753b04.js → cssClass-1492660e.js} +2 -2
  38. package/cssIndex-4c169331.js +160 -0
  39. package/{customClass-editor-30844eef.js → customClass-editor-b910c95b.js} +22 -20
  40. package/{date-picker-range-widget-68c22748.js → date-picker-range-widget-2278cad8.js} +33 -32
  41. package/{date-picker-widget-4532430c.js → date-picker-widget-d361f6f3.js} +34 -33
  42. package/default-slot-widget-9312050d.js +33 -0
  43. package/{default-slot-widget.vue_vue_type_script_setup_true_name_default-slot-widget_lang-7903c803.js → default-slot-widget.vue_vue_type_script_setup_true_name_default-slot-widget_lang-7e67d1a4.js} +8 -8
  44. package/{descriptions-widget-ec41f960.js → descriptions-widget-e3e0d806.js} +23 -22
  45. package/designer.es.js +40 -40
  46. package/designer.style.css +2 -2
  47. package/designer.umd.js +327 -327
  48. package/{dialog-f67b0d8f.js → dialog-abd1055d.js} +2 -2
  49. package/dialog-widget-3e040d0f.js +41 -0
  50. package/divider-widget-4037971b.js +55 -0
  51. package/{drag-wrapper-04c5f241.js → drag-wrapper-a7ac11e7.js} +21 -21
  52. package/drawer-widget-3b223a9b.js +41 -0
  53. package/{dropdown-widget-9c81e135.js → dropdown-widget-7b107117.js} +23 -22
  54. package/{editor-wrapper-e4b65100.js → editor-wrapper-412921da.js} +99 -100
  55. package/{emitter-2e6d5612.js → emitter-752d9612.js} +1 -1
  56. package/{empty-widget-631442f5.js → empty-widget-03dc45a4.js} +25 -24
  57. package/{enum-type-e32f6d55.js → enum-669d691c.js} +344 -351
  58. package/{expression-5df4780f.js → expression-185552e1.js} +1562 -1386
  59. package/feedback-widget-c555aa07.js +34 -0
  60. package/{feedback-widget.vue_vue_type_script_setup_true_name_feedback-widget_lang-a365a6c2.js → feedback-widget.vue_vue_type_script_setup_true_name_feedback-widget_lang-664151d2.js} +6 -6
  61. package/{field-editor-98dd0a48.js → field-editor-01ad04f5.js} +22 -20
  62. package/{fieldobj-e04fe3b7.js → fieldobj-097a7c28.js} +7 -7
  63. package/{file-upload-widget-2a7f1bc3.js → file-upload-widget-132d811f.js} +29 -28
  64. package/{form-item-wrapper-fd97d391.js → form-item-wrapper-e095f173.js} +18 -17
  65. package/{form-widget-8289b9c1.js → form-widget-3e609e45.js} +45 -45
  66. package/{global-provide-inject-f7c2434f.js → globalProvideInject-f72c46e1.js} +1 -1
  67. package/{grid-col-widget-1bce9b22.js → grid-col-widget-07f9934e.js} +1 -1
  68. package/{grid-col-widget.vue_vue_type_script_setup_true_name_grid-col-widget_lang-91bc4542.js → grid-col-widget.vue_vue_type_script_setup_true_name_grid-col-widget_lang-e758879c.js} +5 -5
  69. package/{grid-widget-6d7246c3.js → grid-widget-fcdf2ff1.js} +5 -5
  70. package/{hcard-widget-64f8b247.js → hcard-widget-25a74183.js} +29 -28
  71. package/{html-text-widget-4783ce1e.js → html-text-widget-3f9a7049.js} +23 -22
  72. package/{icon-widget-6bdfa4d3.js → icon-widget-6428cc00.js} +26 -25
  73. package/iframe-widget-beb764f8.js +138 -0
  74. package/image-editor-82e3d316.js +55 -0
  75. package/{image-widget-8158689d.js → image-widget-e340b551.js} +22 -21
  76. package/{index-3e27dbc2.js → index-05b3b9ca.js} +32 -31
  77. package/{enum-type-eeb2dcbd.js → index-0fea97a8.js} +311 -111
  78. package/index-1071c4c7.js +83 -0
  79. package/{index-3dabfdc0.js → index-1a4f56dd.js} +63 -62
  80. package/index-436cc07a.js +265 -0
  81. package/{index-bcac9980.js → index-5728cd3c.js} +24 -23
  82. package/{index-e0d0fa2e.js → index-61d6c848.js} +1 -1
  83. package/{index-a26bf6de.js → index-68c3c04e.js} +219 -218
  84. package/{index-6f2e7cc2.js → index-69b23b46.js} +46 -45
  85. package/index-6fb8d595.js +80 -0
  86. package/{index-397967db.js → index-730f8497.js} +18 -16
  87. package/{index-6aa18a15.js → index-7766bc2f.js} +106 -106
  88. package/{index-0504bd3a.js → index-79a0163e.js} +12 -11
  89. package/{index-73758a90.js → index-8cfb6a9c.js} +1 -1
  90. package/{index-290ac037.js → index-9254507b.js} +27 -26
  91. package/{index-afd82448.js → index-9b56c1e6.js} +22 -20
  92. package/index-a1324d15.js +1350 -0
  93. package/{index-03c22bc5.js → index-a1c1b668.js} +45 -43
  94. package/{index-74ce0e3c.js → index-a565454e.js} +7 -7
  95. package/{index-1878e33f.js → index-ac413547.js} +46 -45
  96. package/index-b55657c0.js +351 -0
  97. package/{index-bca6580c.js → index-b82a7942.js} +32 -30
  98. package/index-cd781075.js +239 -0
  99. package/{index-b236e386.js → index-e207955c.js} +22 -21
  100. package/{index-cd822487.js → index-f5e76d4f.js} +13 -12
  101. package/{index-0409d23f.js → index-fcc4373b.js} +59 -59
  102. package/{input-number-widget-0f414e2c.js → input-number-widget-8cc70bb5.js} +27 -26
  103. package/{input-tag-widget-ad3eb896.js → input-tag-widget-f9b11b33.js} +25 -24
  104. package/{input-widget-469c5464.js → input-widget-f29e34fc.js} +25 -24
  105. package/{install-designer-13ab516e.js → install-designer-90c18b43.js} +1911 -1799
  106. package/{item-fb474622.js → item-20a8e244.js} +11 -10
  107. package/{itemDetail-f887bfaf.js → itemDetail-b08a6256.js} +17 -16
  108. package/{label-wrapper-acfc937a.js → label-wrapper-cc5b374b.js} +7 -6
  109. package/{label-wrapper.vue_vue_type_style_index_0_lang-e81392d8.js → label-wrapper.vue_vue_type_style_index_0_lang-270c6e23.js} +3 -3
  110. package/{link-widget-ad7f38d9.js → link-widget-46bb53ba.js} +25 -24
  111. package/{ltable-col-widget-dcd79046.js → ltable-col-widget-85158af5.js} +1 -1
  112. package/{ltable-col-widget.vue_vue_type_script_setup_true_name_ltable-col-widget_lang-d48e107e.js → ltable-col-widget.vue_vue_type_script_setup_true_name_ltable-col-widget_lang-d200a6a8.js} +9 -9
  113. package/{ltable-widget-80a365bc.js → ltable-widget-58330976.js} +11 -11
  114. package/{mask-bdcecc2d.js → mask-38100676.js} +1 -1
  115. package/{mention-widget-1d31da3b.js → mention-widget-6c235170.js} +25 -24
  116. package/{menu-widget-b47ae070.js → menu-widget-bd1fa158.js} +42 -41
  117. package/{model-widget-151836f0.js → model-widget-b4364744.js} +22 -21
  118. package/multirow-7d028dd0.js +182 -0
  119. package/{multirow-widget-b7c6bc11.js → multirow-widget-aeb02101.js} +87 -86
  120. package/{name-editor-9862d519.js → name-editor-3a3747f6.js} +52 -50
  121. package/nameCase-2134ee3e.js +33 -0
  122. package/object-751045cf.js +44 -0
  123. package/{optionItem-0afcf797.js → optionItem-8e1d0080.js} +809 -474
  124. package/package.json +1 -1
  125. package/{pagination-widget-4af8fa55.js → pagination-widget-bcbb95e0.js} +29 -28
  126. package/{picture-upload-widget-01d4477b.js → picture-upload-widget-1e2240d2.js} +47 -46
  127. package/{progress-widget-87bf7089.js → progress-widget-d3e2e116.js} +30 -29
  128. package/{property-base-9cb6f0af.js → property-base-eaed8cbe.js} +15 -16
  129. package/px-8e97b0e9.js +10 -0
  130. package/{qrcode-widget-e8a010b5.js → qrcode-widget-3ea4613b.js} +29 -28
  131. package/{radio-widget-d3d350f1.js → radio-widget-63540761.js} +33 -32
  132. package/{range-widget-0c8453ad.js → range-widget-e115e075.js} +30 -29
  133. package/{rate-widget-7c9f360b.js → rate-widget-2af29296.js} +24 -23
  134. package/{reg-editor.vue_vue_type_script_setup_true_lang-472581e2.js → reg-editor.vue_vue_type_script_setup_true_lang-420ed8ba.js} +4 -4
  135. package/{result-widget-c1ae2079.js → result-widget-e4217327.js} +23 -22
  136. package/{rich-editor-widget-31f4fd68.js → rich-editor-widget-e42dc6a2.js} +30 -29
  137. package/{router-widget-2889ec23.js → router-widget-7859980a.js} +22 -21
  138. package/{schemaData-7d14e9de.js → schemaData-602ab58d.js} +70 -69
  139. package/{segmented-widget-21f8a5c8.js → segmented-widget-4d90e11a.js} +40 -39
  140. package/{select-widget-f2e60d59.js → select-widget-268e6778.js} +24 -23
  141. package/{sfc-ca2f1573.js → sfc-c8bdbcc3.js} +32 -32
  142. package/{sfcview-79a20801.js → sfcview-7f974f98.js} +24 -23
  143. package/{share-editor-79be0fe3.js → share-editor-3caefde2.js} +55 -54
  144. package/{share-event-77717d69.js → share-event-0ac319f0.js} +2 -2
  145. package/share-field-f51ccb41.js +863 -0
  146. package/{share-file-bc8f56f8.js → share-file-ea94d84e.js} +20 -21
  147. package/size-editor-511e40a5.js +57 -0
  148. package/{skeleton-widget-c593fe7a.js → skeleton-widget-379c1a23.js} +25 -24
  149. package/{skeletonItem-widget-4550c4fe.js → skeletonItem-widget-70f95048.js} +22 -21
  150. package/{slider-widget-74a31030.js → slider-widget-e16ceea7.js} +24 -23
  151. package/{slot-2cdc3b54.js → slot-a11ba403.js} +5 -5
  152. package/{space-widget-ffc9eabc.js → space-widget-79e1ee5e.js} +40 -39
  153. package/{splitter-widget-fca00f2b.js → splitter-widget-6cde3a4c.js} +23 -22
  154. package/{static-text-widget-c682f482.js → static-text-widget-48a223a0.js} +23 -22
  155. package/{statistic-widget-1a8051c0.js → statistic-widget-04dbb84c.js} +25 -24
  156. package/{steps-widget-a445a201.js → steps-widget-ff9c8112.js} +22 -21
  157. package/{subMenu-widget-87d583a9.js → subMenu-widget-75b5b885.js} +10 -9
  158. package/{subMenu-widget.vue_vue_type_script_setup_true_lang-0255e3d5.js → subMenu-widget.vue_vue_type_script_setup_true_lang-dff950d1.js} +18 -18
  159. package/{switch-widget-de893bf9.js → switch-widget-b4dfb30f.js} +29 -28
  160. package/{tab-pane-widget-a7374d75.js → tab-pane-widget-12393cec.js} +1 -1
  161. package/{tab-pane-widget.vue_vue_type_script_setup_true_name_tab-pane-widget_lang-434f9cf7.js → tab-pane-widget.vue_vue_type_script_setup_true_name_tab-pane-widget_lang-07a3da71.js} +5 -5
  162. package/table-col-widget-565631d2.js +30 -0
  163. package/{table-col-widget.vue_vue_type_script_setup_true_name_table-col-widget_lang-8c799d0f.js → table-col-widget.vue_vue_type_script_setup_true_name_table-col-widget_lang-b83a4a39.js} +26 -27
  164. package/{table-widget-05b53a5f.js → table-widget-dba1ef32.js} +50 -48
  165. package/{tabs-widget-65ed6426.js → tabs-widget-8d497cb7.js} +8 -8
  166. package/{tag-widget-85bcce8f.js → tag-widget-7c023bb0.js} +25 -24
  167. package/{target-code-9a4699b1.js → target-code-24346bfc.js} +12 -11
  168. package/{target-datasource-94c64cbb.js → target-datasource-14df6047.js} +66 -65
  169. package/{target-link-88b4fd89.js → target-link-9472348b.js} +56 -55
  170. package/{target-saveForm-e1115d3f.js → target-saveForm-ddd0b24a.js} +71 -70
  171. package/{target-widget-5cf4403e.js → target-widget-426dbfe8.js} +2 -2
  172. package/{target-window-fb793bc8.js → target-window-bb03d3b5.js} +24 -23
  173. package/{text-widget-dd4f6b97.js → text-widget-e241f6be.js} +25 -24
  174. package/{textarea-widget-953b39e8.js → textarea-widget-5c288e26.js} +24 -23
  175. package/{time-picker-range-widget-30903551.js → time-picker-range-widget-4c18e0cf.js} +35 -35
  176. package/time-picker-widget-1e695b27.js +72 -0
  177. package/{time-select-widget-4dbe95ff.js → time-select-widget-055a902a.js} +24 -23
  178. package/{timeline-widget-476e9ea8.js → timeline-widget-881bf090.js} +23 -22
  179. package/{tmpl-widget-2cbd418b.js → tmpl-widget-f1bdf0a4.js} +36 -35
  180. package/{tooltip-widget-8b022a6d.js → tooltip-widget-32af6ae1.js} +23 -22
  181. package/{tour-widget-be2ef78d.js → tour-widget-18697c7d.js} +37 -36
  182. package/{transfer-widget-31ea801d.js → transfer-widget-04bb21a2.js} +25 -24
  183. package/{tree-select-widget-691c9cb6.js → tree-select-widget-4c63a180.js} +24 -23
  184. package/{tree-widget-15cddec7.js → tree-widget-9a8da624.js} +31 -30
  185. package/uuid-1013bfdd.js +16 -0
  186. package/{value-editor-676d7ca0.js → value-editor-ad4a9472.js} +29 -27
  187. package/{verifycode-widget-2cbb68e2.js → verifycode-widget-1e2f11f6.js} +49 -48
  188. package/{widget-wrapper.vue_vue_type_script_setup_true_name_form-item-wrapper_lang-ddcbea59.js → widget-wrapper.vue_vue_type_script_setup_true_name_form-item-wrapper_lang-b7eb5c4b.js} +30 -30
  189. package/{wrapper-widget-40c40291.js → wrapper-widget-03be4616.js} +7 -7
  190. package/avatar-widget-00d2f77a.js +0 -48
  191. package/common-editor-96af86ea.js +0 -28
  192. package/content-wrapper-feb05971.js +0 -18
  193. package/countdown-widget-87ab2577.js +0 -60
  194. package/cssIndex-77da0ec7.js +0 -185
  195. package/default-slot-widget-4be80302.js +0 -32
  196. package/dialog-widget-bae25ba7.js +0 -40
  197. package/divider-widget-643e5787.js +0 -54
  198. package/drawer-widget-73902c82.js +0 -40
  199. package/feedback-widget-90fe8e26.js +0 -33
  200. package/iframe-widget-c6d453cc.js +0 -137
  201. package/image-editor-1e8036ad.js +0 -53
  202. package/index-08436ce4.js +0 -1445
  203. package/index-1c33c886.js +0 -230
  204. package/index-54eed7c3.js +0 -334
  205. package/index-64486ab5.js +0 -43
  206. package/index-fa15e4c8.js +0 -240
  207. package/index-fc1c67a3.js +0 -46
  208. package/multirow-89ec2174.js +0 -183
  209. package/obj-cc64f79c.js +0 -230
  210. package/setView-de8aaf40.js +0 -84
  211. package/share-field-4f3d4a0b.js +0 -879
  212. package/size-editor-99257b84.js +0 -54
  213. package/table-col-widget-35d0c1ba.js +0 -29
  214. package/time-picker-widget-3398f837.js +0 -71
  215. package/uuid-2f7814e3.js +0 -203
@@ -0,0 +1,1350 @@
1
+ var Lt = Object.defineProperty;
2
+ var Et = (e, t, n) => t in e ? Lt(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
+ var E = (e, t, n) => (Et(e, typeof t != "symbol" ? t + "" : t, n), n);
4
+ import { o as ke, h as Te, i as at } from "./object-751045cf.js";
5
+ import { reactive as ct, computed as be, nextTick as Pt, watch as Ft } from "vue";
6
+ import { m as Be, d as pe, f as tt, e as H, c as k, a as J, q as He } from "./index-0fea97a8.js";
7
+ import { i as St, g as xe, B as _, W as L, C as Dt, j as Z, P as M, k as A } from "./baseCommonField-607f46b1.js";
8
+ import { w as $t, C as Rt, I as _t, g as nt } from "./optionItem-8e1d0080.js";
9
+ import { b as N, r as st, z as Bt, p as ft, d as it, A as Gt, a as Wt } from "./expression-185552e1.js";
10
+ import { C as U, c as he, R as Ht, d as It, e as Vt, S as Mt, L as kt, P as Ve, D as xt } from "./enum-669d691c.js";
11
+ import { q as Fe } from "./index-61d6c848.js";
12
+ function Ut(e) {
13
+ return e = e || /* @__PURE__ */ Object.create(null), {
14
+ /**
15
+ * Register an event handler for the given type.
16
+ *
17
+ * @param {String} type Type of event to listen for, or `"*"` for all events
18
+ * @param {Function} handler Function to call in response to given event
19
+ * @memberOf mitt
20
+ */
21
+ on: function(n, l) {
22
+ (e[n] || (e[n] = [])).push(l);
23
+ },
24
+ /**
25
+ * Remove an event handler for the given type.
26
+ *
27
+ * @param {String} type Type of event to unregister `handler` from, or `"*"`
28
+ * @param {Function} handler Handler function to remove
29
+ * @memberOf mitt
30
+ */
31
+ off: function(n, l) {
32
+ e[n] && e[n].splice(e[n].indexOf(l) >>> 0, 1);
33
+ },
34
+ /**
35
+ * Invoke all handlers for the given type.
36
+ * If present, `"*"` handlers are invoked after type-matched handlers.
37
+ *
38
+ * @param {String} type The event type to invoke
39
+ * @param {Any} [evt] Any value (object is recommended and powerful), passed to each handler
40
+ * @memberof mitt
41
+ */
42
+ emit: function(n, l) {
43
+ (e[n] || []).map(function(c) {
44
+ c(l);
45
+ }), (e["*"] || []).map(function(c) {
46
+ c(n, l);
47
+ });
48
+ }
49
+ };
50
+ }
51
+ const Ie = new Ut(), lt = {
52
+ $on: Ie.on,
53
+ $off: Ie.off,
54
+ $emit: Ie.emit
55
+ };
56
+ function qt(e) {
57
+ var t = {
58
+ index: -1,
59
+ maxStep: 20,
60
+ steps: []
61
+ };
62
+ e && !(e != null && e.historyData) && (e.historyData = t);
63
+ const n = ct((e == null ? void 0 : e.historyData) || t), l = `widget__list__backup__${e == null ? void 0 : e.key}`, c = `form__config__backup__${e == null ? void 0 : e.key}`, p = be({
64
+ get: () => (n.index < 0 && (n.index = 0), n.steps[n.index]),
65
+ set: (R) => {
66
+ n.index < 0 && (n.index = 0), n.steps[n.index] = R;
67
+ }
68
+ }), C = () => {
69
+ const R = p == null ? void 0 : p.value;
70
+ e.version = St(), e.widgetList = H(R == null ? void 0 : R.widgetList), e.pageConfig = H(R == null ? void 0 : R.pageConfig);
71
+ }, g = (R) => {
72
+ const m = p;
73
+ m.value = H({
74
+ detail: R,
75
+ widgetList: e.widgetList,
76
+ pageConfig: e.pageConfig
77
+ });
78
+ }, G = () => {
79
+ le(), n.index = n.index + 1, g("initHistory");
80
+ }, v = () => {
81
+ e.historyData = t;
82
+ }, P = (R) => {
83
+ var m;
84
+ n.index == n.maxStep - 1 ? (m = n.steps) == null || m.shift() : n.index = n.index + 1, y(R), n.index < n.steps.length - 1 && (n.steps = n.steps.slice(0, n.index + 1));
85
+ }, y = (R) => {
86
+ g(R), ee();
87
+ }, D = () => {
88
+ n.index !== 0 && n.index--, C();
89
+ }, I = () => {
90
+ var R;
91
+ n.index !== ((R = n.steps) == null ? void 0 : R.length) - 1 && n.index++, C();
92
+ }, Q = () => {
93
+ var R;
94
+ return n.index > 0 && ((R = n.steps) == null ? void 0 : R.length) > 0;
95
+ }, ce = () => {
96
+ var R;
97
+ return n.index < ((R = n.steps) == null ? void 0 : R.length) - 1;
98
+ }, ee = () => {
99
+ Be.set(l, e.widgetList), Be.set(c, e.pageConfig);
100
+ }, le = () => {
101
+ let R = Be.get(l);
102
+ R && pe(e.widgetList, tt(R));
103
+ let m = Be.get(c);
104
+ m && pe(e.pageConfig, tt(m));
105
+ };
106
+ return {
107
+ clearHistoryData: v,
108
+ initHistoryData: G,
109
+ emitHistoryChange: P,
110
+ saveCurrentHistoryStep: y,
111
+ undoHistoryStep: D,
112
+ redoHistoryStep: I,
113
+ undoEnabled: Q,
114
+ redoEnabled: ce,
115
+ saveFormContentToStorage: ee,
116
+ loadFormContentFromStorage: le
117
+ };
118
+ }
119
+ const zt = (e, t) => {
120
+ var l;
121
+ if (!e || !t)
122
+ return !1;
123
+ let n = ue(e == null ? void 0 : e.type);
124
+ return !n || !(n != null && n.options) ? !1 : ((l = ke(n == null ? void 0 : n.options)) == null ? void 0 : l.indexOf(t)) > -1;
125
+ }, ue = (e) => {
126
+ var t;
127
+ return (t = $t.allWidgets) == null ? void 0 : t.find((n) => n.type === e);
128
+ }, jt = (e) => {
129
+ const t = e.id;
130
+ if (!t)
131
+ return null;
132
+ const n = _.getName(e);
133
+ return { id: t, name: n };
134
+ }, w = (e, t, n) => {
135
+ if (!e)
136
+ return k(e);
137
+ var l = e == null ? void 0 : e.id, c = e.type + xe(), p = c;
138
+ n && (p = n(l, c));
139
+ const C = jt(e);
140
+ return Kt(e, p, t), C && (t != null && t.recordSource) && pe(e, { _source: C }), k(e);
141
+ }, Kt = (e, t, n) => (Te(e, N.id) && (e.id = t), e.options = Jt(e.options, t, n), e), Jt = (e, t, n) => (Te(e, N.name) && (n == null ? void 0 : n.newName) != !1 && (e.name = st(t, "-", "")), Te(e, N.label) && !(e != null && e.label) && (n == null ? void 0 : n.newLabel) != !1 && (e.label = st(t, "-", "")), e), bn = (e) => {
142
+ const t = "id@";
143
+ return {
144
+ idClass: `${t}${e == null ? void 0 : e.id}`,
145
+ getIdByIdClass: (p) => p == null ? void 0 : p.substring(t.length),
146
+ isIdClass: (p) => p == null ? void 0 : p.startsWith(t)
147
+ };
148
+ }, yn = (e) => {
149
+ var t = [];
150
+ if (!e)
151
+ return t;
152
+ var n = Fe("$..widgetList[*]", e);
153
+ return e.type == L.tabs ? (t = e.tabs, t = [...n, ...t]) : e.type == L.grid && (t = Fe("$..cols[*]", e), t = [...n, ...t]), t = [...n], t == null ? void 0 : t.filter((l) => !!(l != null && l.type));
154
+ }, me = (e, t, n, l) => {
155
+ e == null || e.forEach((c) => {
156
+ c && (t == null || t.push(c), !(l != null && l(c)) && Qt(c, t, n, l));
157
+ });
158
+ }, Qt = (e, t, n, l) => {
159
+ var c, p, C, g, G, v, P;
160
+ if (e.type === L.tabs)
161
+ (c = e.tabs) == null || c.forEach((y) => {
162
+ t == null || t.push(y), me(y.widgetList, t, n, l);
163
+ });
164
+ else if (e.type === L.table)
165
+ (p = e.rows) == null || p.forEach((y) => {
166
+ var D;
167
+ t == null || t.push(y), (D = y == null ? void 0 : y.cols) == null || D.forEach((I) => {
168
+ t == null || t.push(I), me(I.widgetList, t, n, l);
169
+ });
170
+ });
171
+ else if (e.type === L.grid)
172
+ (C = e.cols) == null || C.forEach((y) => {
173
+ t == null || t.push(y), me(y.widgetList, t, n, l);
174
+ });
175
+ else if (e.type === L.cont) {
176
+ const y = (D) => {
177
+ var I;
178
+ me(D.widgetList, t, n, l), (I = D == null ? void 0 : D.children) == null || I.map((Q) => {
179
+ y(Q);
180
+ });
181
+ };
182
+ (g = e.cols) == null || g.forEach((D) => {
183
+ y(D);
184
+ });
185
+ } else if (((G = e.widgetList) == null ? void 0 : G.length) > 0 && me(e.widgetList, t, n, l), !n) {
186
+ const y = (P = (v = ke(e.options)) == null ? void 0 : v.filter((D) => {
187
+ var I;
188
+ return ((I = e.options[D]) == null ? void 0 : I.type) === U.slot;
189
+ })) == null ? void 0 : P.map((D) => e.options[D]);
190
+ y == null || y.forEach((D) => {
191
+ me(D == null ? void 0 : D.widgetList, t, n, l);
192
+ });
193
+ }
194
+ }, Ue = (e, t, n) => {
195
+ let l = [];
196
+ return pt(e, (p) => {
197
+ l.push(p);
198
+ }, t, n), l;
199
+ }, pt = (e, t, n, l, c) => {
200
+ if (!e)
201
+ return;
202
+ const p = [];
203
+ me(e, p, l, c), p == null || p.forEach((C) => {
204
+ n ? n(C) && t(C) : t(C);
205
+ });
206
+ }, Xt = (e, t) => {
207
+ if (!e)
208
+ return;
209
+ const n = Ue(e, (l) => !!(l != null && l.formItemFlag), !0);
210
+ return n == null || n.forEach((l) => t == null ? void 0 : t(l)), n;
211
+ }, Yt = (e, t) => {
212
+ if (!t || (e == null ? void 0 : e.length) <= 0)
213
+ return;
214
+ const n = Ue(e, (c) => (c == null ? void 0 : c.id) === t);
215
+ return n == null ? void 0 : n[0];
216
+ }, On = (e, t) => Ue(e, (n) => (n == null ? void 0 : n.type) === t), Ln = (e, t) => {
217
+ var c;
218
+ if (!e)
219
+ return [];
220
+ let n = [], l = (p) => {
221
+ p && (n.find((C) => (C == null ? void 0 : C.name) === _.getName(p)) || n.push({
222
+ type: p.type,
223
+ name: _.getName(p),
224
+ field: p
225
+ }));
226
+ };
227
+ return t ? (c = Fe("$..*[?(@property === 'formItemFlag' && @ === true)]^", e)) == null || c.forEach((p) => {
228
+ l(p);
229
+ }) : Xt(e, l), n;
230
+ }, ae = (e, t, n, l = !1, c = !1, p) => {
231
+ var P, y, D, I, Q, ce, ee, le, R;
232
+ if (!e)
233
+ return;
234
+ let C = {
235
+ id: e.id,
236
+ type: e.type,
237
+ label: _.getOptions(e, "label") || _.getOptions(e, "name") || e.type,
238
+ widget: l ? e : null,
239
+ parent: t,
240
+ children: [],
241
+ selectable: !0,
242
+ draggable: c,
243
+ droppable: !1,
244
+ matched: !p || (p == null ? void 0 : p(e))
245
+ };
246
+ if (Te(e, N.widgetList) && pe(C, {
247
+ droppable: !0,
248
+ addNode: (m, $ = -1) => Ce(e, m, $),
249
+ removeNode: (m, $ = -1) => ge(e, $),
250
+ moveNode: (m, $ = -1, q = -1) => ve(e, $, q)
251
+ }), n == null || n.push(C), e.category === void 0)
252
+ return;
253
+ if (C.children = [], e.type === L.grid)
254
+ (P = e == null ? void 0 : e.cols) == null || P.map((m) => {
255
+ var q, j;
256
+ let $ = {
257
+ id: m.id,
258
+ type: m.type,
259
+ draggable: !0,
260
+ droppable: !0,
261
+ label: _.getOptions(m, "name") || m.id || m.type,
262
+ children: [],
263
+ parent: C,
264
+ widget: l ? m : null,
265
+ addNode: (B, W = -1) => Ce(m, B, W),
266
+ removeNode: (B, W = -1) => ge(m, W),
267
+ moveNode: (B, W = -1, z = -1) => ve(m, W, z)
268
+ };
269
+ (q = C.children) == null || q.push($), (j = m.widgetList) == null || j.map((B) => {
270
+ ae(B, $, $.children, l, !0, p);
271
+ });
272
+ });
273
+ else if (e.type === L.table)
274
+ (y = e == null ? void 0 : e.rows) == null || y.map((m) => {
275
+ var q, j;
276
+ let $ = {
277
+ id: m.id,
278
+ type: L.tableRow,
279
+ label: L.tableRow,
280
+ selectable: !1,
281
+ children: [],
282
+ parent: C,
283
+ widget: l ? m : null
284
+ };
285
+ (q = m == null ? void 0 : m.cols) == null || q.map((B) => {
286
+ var oe;
287
+ if (B.merged)
288
+ return;
289
+ let W = $.children, z = {
290
+ id: B.id,
291
+ type: L.tableCol,
292
+ label: L.tableCol,
293
+ draggable: !1,
294
+ droppable: !0,
295
+ children: [],
296
+ parent: $,
297
+ widget: l ? B : null,
298
+ addNode: (fe, te = -1) => Ce(B, fe, te),
299
+ removeNode: (fe, te = -1) => ge(B, te),
300
+ moveNode: (fe, te = -1, i = -1) => ve(B, te, i)
301
+ };
302
+ (oe = B.widgetList) == null || oe.map((fe) => {
303
+ ae(fe, z, z.children, l, !0, p);
304
+ }), W == null || W.push(z);
305
+ }), (j = C.children) == null || j.push($);
306
+ });
307
+ else if (e.type === L.tabs)
308
+ (D = e == null ? void 0 : e.tabs) == null || D.map((m) => {
309
+ var q, j;
310
+ let $ = {
311
+ id: m.id,
312
+ type: m.type,
313
+ label: _.getOptions(m, "label") || m.type,
314
+ selectable: !0,
315
+ draggable: !1,
316
+ droppable: !0,
317
+ children: [],
318
+ parent: C,
319
+ widget: l ? m : null,
320
+ addNode: (B, W = -1) => Ce(m, B, W),
321
+ removeNode: (B, W = -1) => ge(m, W),
322
+ moveNode: (B, W = -1, z = -1) => ve(m, W, z)
323
+ };
324
+ (q = C.children) == null || q.push($), (j = m == null ? void 0 : m.widgetList) == null || j.map((B) => {
325
+ ae(B, $, $.children, l, !0, p);
326
+ });
327
+ });
328
+ else if (e.type === L.cont) {
329
+ const m = ($) => {
330
+ var q, j;
331
+ (q = $.widgetList) == null || q.map((B) => {
332
+ ae(B, C, C.children, l, !1, p);
333
+ }), (j = $ == null ? void 0 : $.children) == null || j.map((B) => m(B));
334
+ };
335
+ (I = e == null ? void 0 : e.cols) == null || I.map(($) => {
336
+ m($);
337
+ });
338
+ } else if ([L.eltable, L.collapse, L.carousel].includes(e.type)) {
339
+ var g = Fe("$..widgetList[*]", (Q = e.options) == null ? void 0 : Q.optionItems.value);
340
+ (g == null ? void 0 : g.length) > 0 && (g == null || g.map((m) => {
341
+ ae(m, C, C.children, l, !1, p);
342
+ }));
343
+ } else
344
+ e.category === Dt.container && ((ce = e == null ? void 0 : e.widgetList) == null ? void 0 : ce.length) > 0 && ((ee = e == null ? void 0 : e.widgetList) == null || ee.map((m) => {
345
+ ae(m, C, C.children, l, !1, p);
346
+ }));
347
+ const G = _.getOptions(e, N.widgetList);
348
+ G && (G == null || G.map((m) => {
349
+ ae(m, C, C.children, l, !1, p);
350
+ }));
351
+ const v = (R = (le = ke(e.options)) == null ? void 0 : le.filter((m) => {
352
+ var $;
353
+ return (($ = e.options[m]) == null ? void 0 : $.type) === U.slot;
354
+ })) == null ? void 0 : R.map((m) => e.options[m]);
355
+ v == null || v.forEach((m) => {
356
+ var $, q, j;
357
+ if ((($ = m == null ? void 0 : m.widgetList) == null ? void 0 : $.length) > 0) {
358
+ let B = {
359
+ id: m.slotName + "_" + (e == null ? void 0 : e.id),
360
+ type: m.type,
361
+ label: m.slotName || m.type,
362
+ children: [],
363
+ parent: C,
364
+ widget: l ? m : null,
365
+ selectable: !1,
366
+ draggable: !1,
367
+ droppable: !0,
368
+ addNode: (W, z = -1) => Ce(m, W, z),
369
+ removeNode: (W, z = -1) => ge(m, z),
370
+ moveNode: (W, z = -1, oe = -1) => ve(m, z, oe)
371
+ };
372
+ (q = C.children) == null || q.push(B), (j = m == null ? void 0 : m.widgetList) == null || j.map((W) => {
373
+ ae(W, B, B.children, l, !0, p);
374
+ });
375
+ }
376
+ });
377
+ }, Ce = (e, t, n = -1) => {
378
+ var l, c;
379
+ return n < 0 || at(n) ? (l = e == null ? void 0 : e.widgetList) == null || l.push(t) : (c = e == null ? void 0 : e.widgetList) == null || c.splice(n, 0, t), !0;
380
+ }, ge = (e, t = -1) => {
381
+ var n;
382
+ return at(t) || t < 0 ? !1 : ((n = e == null ? void 0 : e.widgetList) == null || n.splice(t, 1), !0);
383
+ }, ve = (e, t = -1, n = -1) => {
384
+ const l = e == null ? void 0 : e.widgetList, c = Bt(l || [], t, n);
385
+ return (c == null ? void 0 : c.length) != (l == null ? void 0 : l.length) ? !1 : (e.widgetList.splice(0, l == null ? void 0 : l.length), c == null || c.forEach((p) => {
386
+ e == null || e.widgetList.push(p);
387
+ }), !0);
388
+ }, ut = (e, t = !1, n) => {
389
+ const l = [];
390
+ let c = {
391
+ label: L.page,
392
+ id: L.page,
393
+ type: L.page,
394
+ draggable: !1,
395
+ droppable: !0,
396
+ addNode(p, C) {
397
+ return Ce({ widgetList: e }, p, C);
398
+ },
399
+ removeNode(p, C) {
400
+ return ge({ widgetList: e }, C);
401
+ },
402
+ moveNode: (p, C = -1, g = -1) => ve({ widgetList: e }, C, g)
403
+ };
404
+ return e == null || e.forEach((p) => {
405
+ ae(p, c, l, t, !0, n);
406
+ }), pe(c, { children: l }), [c];
407
+ }, ht = (e, t, n) => {
408
+ !e || e.length <= 0 || e.forEach((l) => {
409
+ l.id === t ? n == null || n(l) : ht(l == null ? void 0 : l.children, t, n);
410
+ });
411
+ }, Ge = (e, t) => {
412
+ let n = null;
413
+ return ht(e, t, (l) => {
414
+ n = l;
415
+ }), n;
416
+ }, Me = (e, t) => {
417
+ const n = Ge(e, t);
418
+ let l = [];
419
+ const c = (p) => {
420
+ p && (l.push(p), p != null && p.parent && c(p == null ? void 0 : p.parent));
421
+ };
422
+ return c(n), l;
423
+ }, Zt = (e, t, n) => {
424
+ !e || e.length <= 0 || (t || (t = []), e.forEach((l) => {
425
+ var c;
426
+ n != null && n(l) && t.push(l), l != null && l.children && ((c = l == null ? void 0 : l.children) == null ? void 0 : c.length) > 0 && Zt(l == null ? void 0 : l.children, t, n);
427
+ }));
428
+ }, Se = (e, t, n, l) => {
429
+ const c = H(e);
430
+ return w(c, t, n), pt([c], (p) => {
431
+ w(p, t, n);
432
+ }, void 0, void 0, l), c;
433
+ }, En = (e, t, n, l) => {
434
+ var g;
435
+ const c = Fe("$..widgetList[?(@.id==='" + e + "')]^", H(n)), p = (g = c == null ? void 0 : c[0]) == null ? void 0 : g.find((G) => {
436
+ var v;
437
+ return ((v = G == null ? void 0 : G._source) == null ? void 0 : v.name) === t;
438
+ }), C = p == null ? void 0 : p.id;
439
+ return l == null ? void 0 : l(C);
440
+ };
441
+ function Nt() {
442
+ const e = (i) => _.getOptions(i, "rowspan") || 1, t = (i) => _.getOptions(i, "colspan") || 1, n = (i, a) => {
443
+ _.setOptions(i, "rowspan", a);
444
+ }, l = (i, a) => {
445
+ _.setOptions(i, "colspan", a);
446
+ }, c = (i, a, d) => {
447
+ let T = H(i.rows[a]);
448
+ return W(T), i.rows.splice(d, 0, T), !0;
449
+ }, p = (i, a) => (i.rows.forEach((d) => {
450
+ let T = z();
451
+ d.cols.splice(a, 0, T);
452
+ }), !0), C = (i) => {
453
+ let a = i.rows.length;
454
+ return c(i, a - 1, a), !0;
455
+ }, g = (i) => {
456
+ let a = i.rows[0].cols.length;
457
+ return p(i, a), !0;
458
+ }, G = (i, a, d, T, b) => {
459
+ let f = b ? a : a + 1;
460
+ if (!b) {
461
+ let F = f, V = !1;
462
+ for (; F < i.rows.length; )
463
+ if (i.rows[F].cols[T].merged)
464
+ F++;
465
+ else {
466
+ f = F, V = !0;
467
+ break;
468
+ }
469
+ V && (f = i.rows.length);
470
+ }
471
+ c(i, d, f);
472
+ let u = 0;
473
+ for (; f < i.rows.length - 1 && u < i.rows[0].cols.length; ) {
474
+ const F = i.rows[f + 1].cols[u];
475
+ if (F.merged) {
476
+ let x = i.rows, ne = {}, X = 0;
477
+ for (let se = f; se >= 0; se--)
478
+ if (!x[se].cols[u].merged && e(x[se].cols[u]) > 1) {
479
+ X = se, ne = x[se].cols[u];
480
+ break;
481
+ }
482
+ if (ne.options) {
483
+ let se = e(ne) + 1;
484
+ y(i.rows, X, u, t(ne), se), u += t(ne);
485
+ } else
486
+ u += 1;
487
+ } else
488
+ u += t(F);
489
+ }
490
+ return !0;
491
+ }, v = (i, a, d, T) => {
492
+ let b = T ? a : a + 1;
493
+ if (!T) {
494
+ let u = b, F = !1;
495
+ for (; u < i.rows[d].cols.length; ) {
496
+ if (i.rows[d].cols[u].merged)
497
+ u++;
498
+ else {
499
+ b = u, F = !0;
500
+ break;
501
+ }
502
+ F || (b = i.rows[d].cols.length);
503
+ }
504
+ }
505
+ p(i, b);
506
+ let f = 0;
507
+ for (; b < i.rows[0].cols.length - 1 && f < i.rows.length; ) {
508
+ const u = i.rows[f].cols[b + 1];
509
+ if (u.merged) {
510
+ let V = i.rows[f].cols, x = {}, ne = null;
511
+ for (let X = b; X >= 0; X--)
512
+ if (!V[X].merged && t(V[X]) > 1) {
513
+ ne = X, x = V[X];
514
+ break;
515
+ }
516
+ if (x.options) {
517
+ let X = t(x) + 1;
518
+ P(i.rows, f, ne, X, e(x)), f += e(x);
519
+ } else
520
+ f += 1;
521
+ } else
522
+ f += e(u);
523
+ }
524
+ return !0;
525
+ }, P = (i, a, d, T, b) => {
526
+ for (let f = a; f < a + b; f++)
527
+ for (let u = d; u < d + T; u++) {
528
+ if (f === a && u === d) {
529
+ l(i[f].cols[u], T);
530
+ continue;
531
+ }
532
+ i[f].cols[u].merged = !0, l(i[f].cols[u], T), i[f].cols[u].widgetList = [];
533
+ }
534
+ }, y = (i, a, d, T, b) => {
535
+ for (let f = a; f < a + b; f++)
536
+ for (let u = d; u < d + T; u++) {
537
+ if (f === a && u === d) {
538
+ n(i[f].cols[u], b);
539
+ continue;
540
+ }
541
+ i[f].cols[u].merged = !0, n(i[f].cols[u], b), i[f].cols[u].widgetList = [];
542
+ }
543
+ }, D = (i, a, d, T, b) => {
544
+ for (let f = a; f < a + b; f++)
545
+ for (let u = d; u < d + T; u++)
546
+ i[f].cols[u].merged = !1, n(i[f].cols[u], 1), l(i[f].cols[u], 1);
547
+ }, I = (i, a, d, T, b) => {
548
+ for (let f = a; f < a + b; f++)
549
+ for (let u = d; u < d + T; u++)
550
+ i[f].cols[u].merged = !1, n(i[f].cols[u], 1), l(i[f].cols[u], 1);
551
+ }, Q = (i, a, d, T) => {
552
+ let b = _.getOptions(i[d].cols[0], "rowspan"), f = !1;
553
+ for (let F = 1; F < i[d].cols.length; F++)
554
+ if (e(i[d].cols[F]) !== b) {
555
+ f = !0;
556
+ break;
557
+ }
558
+ if (f)
559
+ return Z.info(J.i18nt("designer.hint.rowspanNotConsistentForMergeEntireRow")), !1;
560
+ let u = a.filter((F) => !F.merged && !!F.widgetList && F.widgetList.length > 0);
561
+ return u && u.length > 0 && u[0].id !== a[0].id && (!a[0].widgetList || a[0].widgetList.length <= 0) && (a[0].widgetList = H(u[0].widgetList)), P(i, d, 0, a.length, e(a[T])), !0;
562
+ }, ce = (i, a, d, T, b) => {
563
+ let f = T ? a : a + e(b), u = T ? a - 1 : a;
564
+ if (T) {
565
+ let V = u;
566
+ for (; V >= 0; )
567
+ if (i[V].cols[d].merged)
568
+ V--;
569
+ else {
570
+ u = V;
571
+ break;
572
+ }
573
+ }
574
+ i[f].cols[d].widgetList && i[f].cols[d].widgetList.length > 0 && (!i[u].cols[d].widgetList || i[u].cols[d].widgetList.length === 0) && (i[u].cols[d].widgetList = H(i[f].cols[d].widgetList));
575
+ let F = e(i[f].cols[d]) * 1 + e(i[u].cols[d]) * 1;
576
+ return y(i, u, d, t(b), F), !0;
577
+ }, ee = (i, a, d, T) => {
578
+ let b = _.getOptions(i[0].cols[T], "colspan"), f = !1;
579
+ for (let V = 1; V < i.length; V++)
580
+ if (t(i[V].cols[T]) !== b) {
581
+ f = !0;
582
+ break;
583
+ }
584
+ if (f)
585
+ return Z.info(J.i18nt("designer.hint.colspanNotConsistentForMergeEntireColumn")), !1;
586
+ let u = [];
587
+ i.forEach((V) => {
588
+ let x = V.cols[T];
589
+ !x.merged && x.widgetList && x.widgetList.length > 0 && u.push(x);
590
+ });
591
+ let F = i[0].cols[T];
592
+ return u && u.length > 0 && u[0].id !== F.id && (!F.widgetList || F.widgetList.length <= 0) && (F.widgetList = H(u[0].widgetList)), y(i, 0, T, t(F), i.length), !0;
593
+ }, le = (i, a, d, T, b, f) => {
594
+ let u = b ? T : T + (_.getOptions(a[T], "colspan") || 1), F = b ? T - 1 : T;
595
+ if (b) {
596
+ let x = F;
597
+ for (; x >= 0; )
598
+ if (i[d].cols[x].merged)
599
+ x--;
600
+ else {
601
+ F = x;
602
+ break;
603
+ }
604
+ }
605
+ a[u].widgetList && a[u].widgetList.length > 0 && (!a[F].widgetList || a[F].widgetList.length === 0) && (a[F].widgetList = H(a[u].widgetList));
606
+ let V = t(a[u]) * 1 + t(a[F]) * 1;
607
+ return P(i, d, F, V, e(f)), !0;
608
+ }, R = (i, a, d, T, b) => (D(i, a, d, T, b), !0), m = (i, a, d, T, b) => (I(i, a, d, T, b), !0), $ = (i, a) => {
609
+ let d = !0;
610
+ if (i.forEach((f) => {
611
+ t(f.cols[0]) !== i[0].cols.length && (d = !1);
612
+ }), d)
613
+ return Z.info(J.i18nt("designer.hint.lastColCannotBeDeleted")), !1;
614
+ let T = t(i[0].cols[a]), b = !1;
615
+ for (let f = 1; f < i.length; f++)
616
+ if (t(i[f].cols[a]) !== T) {
617
+ b = !0;
618
+ break;
619
+ }
620
+ return b ? (Z.info(J.i18nt("designer.hint.colspanNotConsistentForDeleteEntireColumn")), !1) : (i.forEach((f) => {
621
+ f.cols.splice(a, T);
622
+ }), !0);
623
+ }, q = (i, a) => {
624
+ let d = !0;
625
+ if (i[0].cols.forEach((f) => {
626
+ e(f) !== i.length && (d = !1);
627
+ }), d)
628
+ return Z.info(J.i18nt("designer.hint.lastRowCannotBeDeleted")), !1;
629
+ let T = e(i[a].cols[0]), b = !1;
630
+ for (let f = 1; f < i[a].cols.length; f++)
631
+ if (e(i[a].cols[f]) !== T) {
632
+ b = !0;
633
+ break;
634
+ }
635
+ return b ? (Z.info(J.i18nt("designer.hint.rowspanNotConsistentForDeleteEntireRow")), !1) : (i.splice(a, T), !0);
636
+ }, j = (i, a) => {
637
+ var u;
638
+ let d = e(i[a].cols[0]), T = !1;
639
+ for (let F = 1; F < i[a].cols.length; F++)
640
+ if (e(i[a].cols[F]) !== d) {
641
+ T = !0;
642
+ break;
643
+ }
644
+ if (T)
645
+ return Z.info(J.i18nt("designer.hint.rowspanNotConsistentForDeleteEntireRow")), !1;
646
+ let b = H(i[a]);
647
+ var f = (u = b == null ? void 0 : b.cols) == null ? void 0 : u.map((F) => Se(F, { recordSource: !1 }));
648
+ return b.cols = f, i.splice(a + 1, 0, b), !0;
649
+ }, B = (i, a) => {
650
+ let d = t(i[0].cols[a]), T = !1;
651
+ for (let b = 1; b < i.length; b++)
652
+ if (t(i[b].cols[a]) !== d) {
653
+ T = !0;
654
+ break;
655
+ }
656
+ return T ? (Z.info(J.i18nt("designer.hint.colspanNotConsistentForDeleteEntireColumn")), !1) : (i.forEach((b) => {
657
+ let f = H(b.cols[a]);
658
+ f = Se(f, { recordSource: !1 }), b.cols.splice(a + 1, 0, f);
659
+ }), !0);
660
+ }, W = (i) => {
661
+ let a = i || { cols: [] };
662
+ return a = w({ ...a, type: L.tableRow, id: "" }), a.merged = !1, i ? a.cols.forEach((d) => {
663
+ z(d);
664
+ }) : a.cols.push(z()), a;
665
+ }, z = (i) => {
666
+ let a = i || H(ue(L.tableCol));
667
+ return w(a), a.merged = !1, l(a, 1), n(a, 1), a.widgetList.length = 0, a;
668
+ }, oe = (i) => {
669
+ let a = i || H(ue(L.table));
670
+ return w(a), a;
671
+ };
672
+ return {
673
+ appendTableRow: C,
674
+ appendTableCol: g,
675
+ insertTableRow: G,
676
+ insertTableCol: v,
677
+ mergeTableWholeRow: Q,
678
+ mergeTableRow: ce,
679
+ mergeTableCol: le,
680
+ mergeTableWholeCol: ee,
681
+ undoMergeTableCol: R,
682
+ undoMergeTableRow: m,
683
+ deleteTableWholeCol: $,
684
+ deleteTableWholeRow: q,
685
+ copyTableWholeRow: j,
686
+ copyTableWholeCol: B,
687
+ initTableRow: W,
688
+ initTable: oe,
689
+ initCloneTable: (i) => {
690
+ let a = oe();
691
+ return k(i).rows.forEach((d) => {
692
+ let T = k(H(d));
693
+ w(T), T.cols.forEach((b) => {
694
+ w(b), b.widgetList = [];
695
+ }), k(a).rows.push(T);
696
+ }), a;
697
+ },
698
+ isTable: (i) => (i == null ? void 0 : i.type) === L.table
699
+ };
700
+ }
701
+ function At() {
702
+ const e = () => {
703
+ let v = k(H(ue(L.tabs)));
704
+ return v = w(v), v;
705
+ }, t = (v, P) => {
706
+ let y = k(H(ue(L.tabPane)));
707
+ var D = w(y);
708
+ return v && _.setOptions(D, N.label, v), P !== void 0 && _.setOptions(D, N.isdefault, P), D;
709
+ }, n = (v) => {
710
+ var y;
711
+ let P = e();
712
+ return (y = k(v).tabs) == null || y.forEach((D) => {
713
+ var Q;
714
+ let I = l(D);
715
+ (Q = k(P).tabs) == null || Q.push(I);
716
+ }), P;
717
+ }, l = (v) => {
718
+ var P = H(v);
719
+ return w(P), _.setOptions(P, N.isdefault, !1), P.widgetList = [], P;
720
+ };
721
+ return {
722
+ initTab: e,
723
+ initCloneTab: n,
724
+ initTabPane: t,
725
+ initCloneTabPane: l,
726
+ addTabPaneOfTabs: (v, P) => {
727
+ let y = v == null ? void 0 : v.tabs;
728
+ return y || (y = []), P = P || t(), P && y.push(P), !0;
729
+ },
730
+ deleteTabPaneOfTabs: (v, P) => {
731
+ var y;
732
+ if (((y = v.tabs) == null ? void 0 : y.length) === 1) {
733
+ Z.info(J.i18nt("designer.hint.lastPaneCannotBeDeleted"));
734
+ return;
735
+ }
736
+ return v.tabs.splice(P, 1), !0;
737
+ },
738
+ // cloneTabPane,
739
+ findTabPaneOfTabs: (v, P) => {
740
+ var y;
741
+ return (y = v.tabs) == null ? void 0 : y.findIndex((D) => _.getName(D) === P);
742
+ },
743
+ getActiveTab: (v) => {
744
+ var y, D;
745
+ let P = (y = v == null ? void 0 : v.tabs) == null ? void 0 : y[0];
746
+ return (D = v == null ? void 0 : v.tabs) == null || D.forEach((I) => {
747
+ _.getOptions(I, N.isdefault) && (P = I);
748
+ }), P;
749
+ },
750
+ isTabs: (v) => (v == null ? void 0 : v.type) === L.tabs
751
+ };
752
+ }
753
+ function wt() {
754
+ const e = () => {
755
+ let g = k(H(ue(L.grid)));
756
+ return g = w(g), g;
757
+ }, t = () => {
758
+ let g = k(H(ue(L.gridCol)));
759
+ return g = w(g), g;
760
+ }, n = (g) => {
761
+ let G = H(g);
762
+ return Se(G);
763
+ };
764
+ return {
765
+ initGrid: e,
766
+ initCloneGrid: (g) => {
767
+ var v;
768
+ let G = e();
769
+ return (v = k(g).cols) == null || v.forEach((P) => {
770
+ let y = n(P);
771
+ k(G).cols.push(y);
772
+ }), G;
773
+ },
774
+ initGridCol: t,
775
+ initCloneGridCol: n,
776
+ // cloneGridCol,
777
+ deleteColOfGrid: (g, G) => (g && g.cols && g.cols.splice(G, 1), !0),
778
+ addNewColOfGrid: (g) => {
779
+ const G = g.cols;
780
+ let v = t();
781
+ if (G && G.length > 0) {
782
+ let P = 0;
783
+ G.forEach((y) => {
784
+ P += _.getOptions(y, "span") || 0;
785
+ }), P >= 24 || _.setOptions(v, "span", 24 - P > 12 ? 12 : 24 - P), g.cols.push(v);
786
+ } else
787
+ g.cols = [v];
788
+ return !0;
789
+ },
790
+ isGrid: (g) => (g == null ? void 0 : g.type) === L.grid
791
+ };
792
+ }
793
+ function en() {
794
+ return {
795
+ initCloneContCell: (c) => {
796
+ let p = H(c);
797
+ return Se(p);
798
+ },
799
+ initContCell: (c = he.main, p) => {
800
+ let C = new Rt();
801
+ return pe(C, p), C.partName = new M(U.placer, c), C;
802
+ },
803
+ initCont: () => {
804
+ let c = H(ue(L.cont));
805
+ return c.id = c.type + xe(), _.setName(c, c.id), c;
806
+ },
807
+ isCont: (c) => (c == null ? void 0 : c.type) === L.cont
808
+ };
809
+ }
810
+ class tn extends _t {
811
+ constructor() {
812
+ super(...arguments);
813
+ E(this, "protocal", Ve.VALUE);
814
+ // id: string = '';
815
+ E(this, "name", "");
816
+ E(this, "description", "");
817
+ E(this, "isReadonly", !1);
818
+ }
819
+ }
820
+ class nn extends tn {
821
+ constructor() {
822
+ super(...arguments);
823
+ /**
824
+ * URL
825
+ */
826
+ E(this, "url", "");
827
+ /**
828
+ * 数据
829
+ */
830
+ E(this, "data", "");
831
+ /**
832
+ * 加载方式
833
+ */
834
+ // loadType: LoadType = LoadType.auto;
835
+ /**
836
+ * URL参数
837
+ */
838
+ E(this, "params", []);
839
+ /**
840
+ * headers
841
+ */
842
+ E(this, "headers", []);
843
+ /**
844
+ * 允许的http请求内容的最大字节数
845
+ */
846
+ E(this, "maxBodyLength", 2e3);
847
+ /**
848
+ * 允许的HTTP响应内容的最大字节数
849
+ */
850
+ E(this, "maxContentLength", 2e3);
851
+ /**
852
+ * 指定请求超时的毫秒数。
853
+ * 如果请求时间超过 `timeout` 的值,则请求会被中断
854
+ */
855
+ E(this, "timeout", 0);
856
+ /**
857
+ * 方法
858
+ */
859
+ E(this, "method", Ht.jsonp);
860
+ /**
861
+ * 响应数据编码
862
+ */
863
+ E(this, "responseEncoding", It.UTF8);
864
+ /**
865
+ * 响应数据类型
866
+ */
867
+ E(this, "responseType", Vt.json);
868
+ /**
869
+ * 跨域请求时是否需要使用凭证
870
+ */
871
+ E(this, "withCredentials", !1);
872
+ /**
873
+ * 判断是否执行远程的表达式或变量
874
+ */
875
+ E(this, "shouldFetch", "");
876
+ /**
877
+ * 请求发送前的处理函数
878
+ */
879
+ E(this, "willFetch", new M(U.hook, void 0, new A()));
880
+ /**
881
+ * 请求返回时的数据适配
882
+ */
883
+ E(this, "fitFetch", new M(U.hook, void 0, new A()));
884
+ /**
885
+ * 请求错误处理函数
886
+ */
887
+ E(this, "errorFetch", new M(U.hook, void 0, new A()));
888
+ /**
889
+ * 请求完成时的回调函数
890
+ */
891
+ E(this, "didFetch", new M(U.hook, void 0, new A()));
892
+ }
893
+ }
894
+ class Pn extends nn {
895
+ //#endregion
896
+ constructor(n) {
897
+ super();
898
+ //#region value
899
+ E(this, "initialData", null);
900
+ this.id = "source" + xe(), n && pe(this, n);
901
+ }
902
+ }
903
+ class mt {
904
+ constructor() {
905
+ /**
906
+ * 全局组件大小
907
+ */
908
+ E(this, "size", Mt.default);
909
+ /**
910
+ * 布局类型
911
+ */
912
+ E(this, "layoutType", kt.PC);
913
+ /**
914
+ * JSON版本号
915
+ */
916
+ E(this, "jsonVersion", ft.pageJsonVersion);
917
+ /**
918
+ * 自定义CSS样式
919
+ */
920
+ E(this, "customClass", new M(U.placer, []));
921
+ /**
922
+ * 组件容器css样式
923
+ */
924
+ E(this, "componentWrapperClass", new M(U.placer, []));
925
+ /**
926
+ * 是否正在加载
927
+ */
928
+ E(this, "showLoading", !1);
929
+ /**
930
+ * 加载提示
931
+ */
932
+ E(this, "loadingText", "");
933
+ /**
934
+ * 页面创建时事件
935
+ */
936
+ E(this, "pageCreated", new M(U.event, void 0, new A()));
937
+ /**
938
+ * 页面挂载完成后事件
939
+ */
940
+ E(this, "pageMounted", new M(U.event, void 0, new A()));
941
+ /**
942
+ * 自定义CSS代码
943
+ */
944
+ E(this, "cssCode", new M(U.placer, void 0, new A()));
945
+ /**
946
+ * 全局函数
947
+ */
948
+ E(this, "functions", new M(U.placer, void 0, new A()));
949
+ /**
950
+ * 请求发送前的处理函数
951
+ */
952
+ E(this, "willFetch", new M(U.hook, void 0, new A()));
953
+ /**
954
+ * 请求返回时的数据适配
955
+ */
956
+ E(this, "fitFetch", new M(U.hook, void 0, new A()));
957
+ /**
958
+ * 请求错误处理函数
959
+ */
960
+ E(this, "errorFetch", new M(U.hook, void 0, new A()));
961
+ /**
962
+ * 请求完成时的回调函数
963
+ */
964
+ E(this, "didFetch", new M(U.hook, void 0, new A()));
965
+ /**
966
+ * 数据源
967
+ */
968
+ E(this, "schema", new M(U.dataObject, [{
969
+ protocal: Ve.URI,
970
+ name: it.urlParams,
971
+ description: J.i18nt("designer.hint.varibaleURL"),
972
+ isReadonly: !0
973
+ }, {
974
+ protocal: Ve.CONFIG,
975
+ name: it.compParams,
976
+ description: J.i18nt("designer.hint.varibaleConfig"),
977
+ isReadonly: !0
978
+ }]));
979
+ }
980
+ //字段扩展声明
981
+ }
982
+ function ot(e, t) {
983
+ return {
984
+ widgetTree: be(() => ct(ut(e, t)))
985
+ };
986
+ }
987
+ function rt(e, t) {
988
+ const n = be(() => {
989
+ var g;
990
+ const C = Me(e, t == null ? void 0 : t.id);
991
+ return (C == null ? void 0 : C.length) <= 0 && (t != null && t._source) ? Me(e, (g = t == null ? void 0 : t._source) == null ? void 0 : g.id) : C;
992
+ }), l = be(() => {
993
+ var C;
994
+ return (C = n.value) == null ? void 0 : C.map((g) => ({ id: g == null ? void 0 : g.id, selectable: g.selectable, label: _.getWidgetTypeName(k(g.type)) })).filter((g) => g.id !== (t == null ? void 0 : t.id));
995
+ }), { parentForm: c, parentFormId: p } = sn(n.value);
996
+ return {
997
+ widgetTree: e,
998
+ parentForm: c,
999
+ parentFormId: p,
1000
+ parentTree: l,
1001
+ pathNodes: n
1002
+ };
1003
+ }
1004
+ const sn = (e) => {
1005
+ const t = be(() => {
1006
+ var l;
1007
+ return (l = e == null ? void 0 : e.find((c) => c.type === L.form)) == null ? void 0 : l.widget;
1008
+ }), n = be(() => {
1009
+ var l;
1010
+ return (l = t == null ? void 0 : t.value) == null ? void 0 : l.id;
1011
+ });
1012
+ return {
1013
+ parentForm: t,
1014
+ parentFormId: n
1015
+ };
1016
+ };
1017
+ class ln {
1018
+ constructor() {
1019
+ /**
1020
+ * 唯一标识符
1021
+ */
1022
+ E(this, "key", "");
1023
+ /**
1024
+ * 当前版本号
1025
+ */
1026
+ E(this, "version", "");
1027
+ /**
1028
+ * 操作历史记录
1029
+ */
1030
+ E(this, "historyData");
1031
+ /**
1032
+ * 组件列表
1033
+ */
1034
+ E(this, "widgetList", []);
1035
+ /**
1036
+ * 表单配置项集
1037
+ */
1038
+ E(this, "pageConfig", new mt());
1039
+ /**
1040
+ * 表单设计容器Ref
1041
+ * 主要用于调用设计组件的函数
1042
+ */
1043
+ E(this, "pageWidget");
1044
+ /**
1045
+ * 自定义样式列表
1046
+ */
1047
+ E(this, "cssClassList", []);
1048
+ /**
1049
+ * 选中组件
1050
+ */
1051
+ E(this, "selectedWidget");
1052
+ }
1053
+ }
1054
+ function Fn(e, t = !1, n = !1) {
1055
+ const l = !e;
1056
+ var c = l ? new ln() : e;
1057
+ if (n && (c.key = Gt().toString()), l) {
1058
+ const { initDesigner: p } = on(c);
1059
+ p(t);
1060
+ }
1061
+ return c;
1062
+ }
1063
+ function on(e) {
1064
+ const t = qt(e), { initHistoryData: n, clearHistoryData: l, emitHistoryChange: c, saveCurrentHistoryStep: p, saveFormContentToStorage: C } = t, { initGridCol: g, isGrid: G } = wt(), { initContCell: v, isCont: P } = en(), { initTabPane: y, getActiveTab: D, isTabs: I } = At(), { initTableRow: Q, isTable: ce } = Nt(), ee = new mt(), le = (s = !0) => {
1065
+ e.widgetList = [], e.pageConfig = H(ee), s || n();
1066
+ }, R = (s) => {
1067
+ var o, S;
1068
+ let r = e.widgetList.length === 0;
1069
+ (S = e.widgetList) == null || S.splice(0, (o = e.widgetList) == null ? void 0 : o.length), e.pageConfig = ee, u(), l(), s || (r ? p("clearDesigner") : c("clearDesigner"));
1070
+ }, m = (s) => {
1071
+ e.pageWidget = s;
1072
+ }, $ = (s) => Yt(e.widgetList, s), q = (s, r) => {
1073
+ s && c(r);
1074
+ }, j = () => ({
1075
+ widgetList: [],
1076
+ pageConfig: He(ee)
1077
+ }), B = () => ({
1078
+ widgetList: He(e.widgetList),
1079
+ pageConfig: He(e.pageConfig)
1080
+ }), W = (s) => {
1081
+ let r = !1;
1082
+ return R(), s && s.widgetList && (e.widgetList = s.widgetList, r = !0), s && s.pageConfig && (pe(e.pageConfig, s.pageConfig), r = !0), r && d(ft.pageJsonImported, []), r;
1083
+ }, z = (s) => {
1084
+ e && (e.cssClassList = s);
1085
+ }, oe = () => e == null ? void 0 : e.cssClassList, fe = (s) => {
1086
+ M.getValue(e.pageConfig.cssCode) === "" && s && M.setValue(e.pageConfig, "cssCode", s);
1087
+ }, te = (s = !1, r) => ut(e.widgetList, s, r), i = () => {
1088
+ var s = te(!1, (h) => !!(h != null && h.formItemFlag));
1089
+ const r = (h, O) => {
1090
+ [
1091
+ L.page,
1092
+ L.form,
1093
+ U.slot,
1094
+ L.grid,
1095
+ L.gridCol,
1096
+ L.table,
1097
+ L.tableRow,
1098
+ L.tableCol,
1099
+ L.card,
1100
+ L.wrapper,
1101
+ L.cont,
1102
+ L.contCell
1103
+ ].includes(O == null ? void 0 : O.type) || O != null && O.label && (h == null || h.push((O == null ? void 0 : O.label) || "")), O != null && O.parent && r(h, O.parent);
1104
+ };
1105
+ let o = [];
1106
+ const S = (h) => {
1107
+ h == null || h.forEach((O) => {
1108
+ if (O.matched) {
1109
+ const K = [];
1110
+ r(K, O);
1111
+ const ie = Object.assign({}, O);
1112
+ ie.label = `${K.reverse().join(".")}`, delete ie.children, delete ie.parent, o.push(ie);
1113
+ }
1114
+ S(O.children);
1115
+ });
1116
+ };
1117
+ return S(s), o;
1118
+ }, a = (s, r) => {
1119
+ var ie, ye, Oe, Le, Ee, Pe, re, de, Xe, Ye, Ze, $e, Ne, Ae, we, Re, et;
1120
+ const o = $(s == null ? void 0 : s.id);
1121
+ if (!o)
1122
+ return;
1123
+ const S = te(), h = Ge(S, s.id), O = Ge(S, r.id);
1124
+ if (((ie = h == null ? void 0 : h.parent) == null ? void 0 : ie.id) === ((ye = O == null ? void 0 : O.parent) == null ? void 0 : ye.id)) {
1125
+ const _e = (Le = (Oe = h == null ? void 0 : h.parent) == null ? void 0 : Oe.children) == null ? void 0 : Le.findIndex((Y) => (Y == null ? void 0 : Y.id) === (h == null ? void 0 : h.id)), Ot = (Pe = (Ee = h == null ? void 0 : h.parent) == null ? void 0 : Ee.children) == null ? void 0 : Pe.findIndex((Y) => (Y == null ? void 0 : Y.id) === (O == null ? void 0 : O.id));
1126
+ var K = (de = (re = h == null ? void 0 : h.parent) == null ? void 0 : re.moveNode) == null ? void 0 : de.call(re, h, _e, Ot);
1127
+ K && c(`moveNode ${s == null ? void 0 : s.id}`);
1128
+ } else {
1129
+ const _e = (Ye = (Xe = O == null ? void 0 : O.parent) == null ? void 0 : Xe.children) == null ? void 0 : Ye.findIndex((Y) => (Y == null ? void 0 : Y.id) === (O == null ? void 0 : O.id));
1130
+ var K = !1;
1131
+ if (K = (Ze = O == null ? void 0 : O.addNode) == null ? void 0 : Ze.call(O, o, _e), K || (K = (Ne = ($e = O == null ? void 0 : O.parent) == null ? void 0 : $e.addNode) == null ? void 0 : Ne.call($e, o, _e)), K) {
1132
+ const Y = (we = (Ae = h == null ? void 0 : h.parent) == null ? void 0 : Ae.children) == null ? void 0 : we.findIndex((We) => (We == null ? void 0 : We.id) === (h == null ? void 0 : h.id));
1133
+ (et = (Re = h == null ? void 0 : h.parent) == null ? void 0 : Re.removeNode) == null || et.call(Re, h, Y), c(`moveNode ${s == null ? void 0 : s.id}`);
1134
+ }
1135
+ }
1136
+ }, d = (s, r) => {
1137
+ lt.$emit(s, r);
1138
+ }, T = (s, r) => {
1139
+ lt.$on(s, (o) => r(o));
1140
+ }, b = (s, r, o) => {
1141
+ s && (o && Te(s.options, "label") ? _.setOptions(s, "label", o) : o && Te(s.options, "content") && _.setOptions(s, "content", o));
1142
+ }, f = (s) => {
1143
+ if (!s) {
1144
+ u();
1145
+ return;
1146
+ }
1147
+ e.selectedWidget = s;
1148
+ }, u = () => {
1149
+ e.selectedWidget = void 0;
1150
+ }, F = (s, r, o) => {
1151
+ const S = s == null ? void 0 : s.newIndex, h = r == null ? void 0 : r[S];
1152
+ h && f(h), c(`drag add ${h == null ? void 0 : h.id}`), o == null || o(r);
1153
+ }, V = (s, r) => {
1154
+ }, x = (s, r, o) => {
1155
+ c("drag update"), o == null || o(r);
1156
+ }, ne = (s, r, o) => {
1157
+ c("drag remove"), o == null || o(r);
1158
+ }, X = (s) => !0, se = (s) => {
1159
+ const r = (o, S, h) => {
1160
+ if (!zt(s, o) || h != null && !(h != null && h(s)))
1161
+ return;
1162
+ const O = _.getOrgOption(s, o);
1163
+ _.setOptions(s, o, S(s, O));
1164
+ };
1165
+ r(N.name, (o) => o.id), r(N.label, (o) => {
1166
+ var S;
1167
+ return _.getOptions(o, "label") || ((S = o.type) == null ? void 0 : S.toLowerCase());
1168
+ }), r(N.content, (o) => {
1169
+ var S;
1170
+ return _.getOptions(o, "content") || ((S = o.type) == null ? void 0 : S.toLowerCase());
1171
+ }, (o) => (o == null ? void 0 : o.type) !== L.tooltip), r(N.optionItems, (o, S) => {
1172
+ var h = M.getValue(S);
1173
+ return h == null || h.splice(1, 0, nt(o.type)), h;
1174
+ }, (o) => (o == null ? void 0 : o.type) !== L.image), r("repeatOptionItems", (o, S) => {
1175
+ var h = M.getValue(S);
1176
+ return h == null || h.splice(1, 0, nt(o.type)), h;
1177
+ }, (o) => (o == null ? void 0 : o.type) === L.timeline);
1178
+ }, qe = (s) => {
1179
+ let r = k(H(s));
1180
+ return r ? (r.id = _.newId(r.type), se(r), r) : null;
1181
+ }, ze = () => {
1182
+ var r, o, S;
1183
+ let s = e.widgetList;
1184
+ return e.selectedWidget && (I(e.selectedWidget) ? s = (r = D(k(e.selectedWidget))) == null ? void 0 : r.widgetList : (o = k(e.selectedWidget)) != null && o.widgetList && (s = (S = e.selectedWidget) == null ? void 0 : S.widgetList)), s;
1185
+ }, dt = (s) => {
1186
+ let r = qe(s);
1187
+ if (!r)
1188
+ return;
1189
+ const o = ze();
1190
+ o == null || o.push(r), f(r), c(`addFieldByDbClick ${s == null ? void 0 : s.id}`);
1191
+ }, Ct = (s, r) => {
1192
+ var o = De(s, r);
1193
+ if (s) {
1194
+ if (o === 0) {
1195
+ Z.info(J.i18nt("designer.hint.moveUpFirstChildHint"));
1196
+ return;
1197
+ }
1198
+ let S = s[o];
1199
+ s.splice(o, 1), s.splice(o - 1, 0, S);
1200
+ }
1201
+ c(`moveUpWidget ${r == null ? void 0 : r.id}`);
1202
+ }, gt = (s, r) => {
1203
+ var o = De(s, r);
1204
+ if (s) {
1205
+ if (o === s.length - 1) {
1206
+ Z.info(J.i18nt("designer.hint.moveDownLastChildHint"));
1207
+ return;
1208
+ }
1209
+ let S = s[o];
1210
+ s.splice(o, 1), s.splice(o + 1, 0, S);
1211
+ }
1212
+ c(`moveDownWidget ${r == null ? void 0 : r.id}`);
1213
+ }, je = (s) => {
1214
+ var S, h, O, K, ie, ye, Oe, Le, Ee, Pe;
1215
+ let r = null, o = H(s);
1216
+ if (G(s))
1217
+ r = k(o), (S = r.cols) == null || S.push(g()), (h = r.cols) == null || h.push(g());
1218
+ else if (P(s)) {
1219
+ r = k(o);
1220
+ const re = v(he.container);
1221
+ (O = re.children) == null || O.push(v(he.header));
1222
+ let de = v(he.container, { direction: xt.horizontal });
1223
+ (K = de.children) == null || K.push(v(he.aside, { cellWidth: new M(U.placer, "20%") })), (ie = de.children) == null || ie.push(v(he.main, { cellWidth: new M(U.placer, "80%") })), (ye = re.children) == null || ye.push(de), (Oe = re.children) == null || Oe.push(v(he.footer)), (Le = r.cols) == null || Le.push(re);
1224
+ } else
1225
+ ce(s) ? (r = k(o), (Ee = r.rows) == null || Ee.push(Q())) : I(s) ? (r = k(o), (Pe = r.tabs) == null || Pe.push(y(void 0, !0))) : r = k(o);
1226
+ return r.id = _.newId(r.type), _.setName(r, r.id), r;
1227
+ }, vt = (s) => {
1228
+ let r = je(s);
1229
+ const o = ze();
1230
+ o == null || o.push(r), f(r), c(`addContainerByDbClick ${s == null ? void 0 : s.id}`);
1231
+ }, Ke = (s, r) => {
1232
+ var o = null;
1233
+ if (s) {
1234
+ o = Se(s, { recordSource: !1 });
1235
+ var S = De(r, s);
1236
+ return r == null || r.splice(S + 1, 0, o), f(o), c(`cloneWidget ${s == null ? void 0 : s.id}`), o;
1237
+ }
1238
+ }, Je = (s, r, o) => {
1239
+ var S = De(o, s);
1240
+ if (o) {
1241
+ let h = null;
1242
+ o.length === 1 ? r && (h = r) : o.length === 1 + S ? h = o[S - 1] : h = o[S + 1], Pt(() => {
1243
+ o.splice(S, 1), f(h), c(`removeWidget ${s == null ? void 0 : s.id}`);
1244
+ });
1245
+ }
1246
+ }, De = (s, r) => !r || !s ? -1 : s == null ? void 0 : s.indexOf(r), Tt = (s, r, o) => {
1247
+ e && (f(s), d(Wt.fieldSelected, r));
1248
+ }, bt = (s) => {
1249
+ s ? f(s) : u();
1250
+ }, yt = (s) => {
1251
+ var h;
1252
+ const { widgetTree: r } = ot(e.widgetList, !0), { pathNodes: o } = rt(r.value, s);
1253
+ return (h = o.value) == null ? void 0 : h[1].widget;
1254
+ }, Qe = (s) => {
1255
+ var h, O, K;
1256
+ const { widgetTree: r } = ot(e.widgetList, !0), { pathNodes: o } = rt(r.value, s);
1257
+ return ((K = (O = (h = o.value) == null ? void 0 : h[1]) == null ? void 0 : O.widget) == null ? void 0 : K.widgetList) || e.widgetList;
1258
+ };
1259
+ return {
1260
+ ...t,
1261
+ initDesigner: le,
1262
+ clearDesigner: R,
1263
+ registerPageWidget: m,
1264
+ setSelected: f,
1265
+ clearSelected: u,
1266
+ updateSelectedWidgetLabel: b,
1267
+ copyNewFieldWidget: qe,
1268
+ copyNewContainerWidget: je,
1269
+ addContainerByDbClick: vt,
1270
+ addFieldByDbClick: dt,
1271
+ selectWidget: Tt,
1272
+ removeSelectedWidget: () => {
1273
+ const s = e.selectedWidget;
1274
+ if (!s)
1275
+ return !1;
1276
+ if (s != null && s.internal)
1277
+ return Z.info(J.i18nt("designer.hint.currentNodeCannotBeSelected")), !1;
1278
+ const r = yt(s), o = Qe(s);
1279
+ return Je(s, r, o), !0;
1280
+ },
1281
+ cloneSelectedWidget: () => {
1282
+ var s;
1283
+ if ((s = e.selectedWidget) != null && s.internal) {
1284
+ Z.info(J.i18nt("designer.hint.currentNodeCannotBeSelected"));
1285
+ return;
1286
+ }
1287
+ return e.selectedWidget;
1288
+ },
1289
+ pasteSelectedWidget: (s) => {
1290
+ const r = e.selectedWidget, o = Qe(r);
1291
+ return Ke(s, o), !0;
1292
+ },
1293
+ selectParentWidget: bt,
1294
+ moveUpWidget: Ct,
1295
+ moveDownWidget: gt,
1296
+ cloneWidget: Ke,
1297
+ removeWidget: Je,
1298
+ checkWidgetMove: X,
1299
+ onWidgetDragAdd: F,
1300
+ onWidgetDragEnd: V,
1301
+ onWidgetDragUpdate: x,
1302
+ onWidgetDragRemove: ne,
1303
+ setCssClassList: z,
1304
+ getCssClassList: oe,
1305
+ getImportTemplate: j,
1306
+ emitEvent: d,
1307
+ handleEvent: T,
1308
+ loadPageJson: W,
1309
+ getPageJson: B,
1310
+ loadPresetCssCode: fe,
1311
+ getNodeTree: te,
1312
+ findTreeNode: Ge,
1313
+ findWidgetById: $,
1314
+ findToRootFromNode: Me,
1315
+ buildFormItemList: i,
1316
+ moveNode: a,
1317
+ emitHistoryChangeAfter: q,
1318
+ watchPropAndSaveHistory: (s) => {
1319
+ s && Ft(() => {
1320
+ var r;
1321
+ return (r = e == null ? void 0 : e.selectedWidget) == null ? void 0 : r[s];
1322
+ }, (r) => {
1323
+ C();
1324
+ }, { deep: !0 });
1325
+ }
1326
+ };
1327
+ }
1328
+ export {
1329
+ Pn as S,
1330
+ At as a,
1331
+ bn as b,
1332
+ Fn as c,
1333
+ Nt as d,
1334
+ En as e,
1335
+ Ue as f,
1336
+ Ln as g,
1337
+ zt as h,
1338
+ ot as i,
1339
+ rt as j,
1340
+ wt as k,
1341
+ ue as l,
1342
+ On as m,
1343
+ yn as n,
1344
+ me as o,
1345
+ Qt as p,
1346
+ Zt as q,
1347
+ Se as r,
1348
+ pt as t,
1349
+ on as u
1350
+ };