@web-utils/form-ui 1.0.0-beta77 → 1.0.0-beta79

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 (225) hide show
  1. package/address-input/index.d.ts +52 -0
  2. package/affix/index.d.ts +30 -0
  3. package/awesome-button/index.d.ts +60 -0
  4. package/capsule-tab/index.d.ts +30 -0
  5. package/card/index.d.ts +41 -0
  6. package/chunks/{Dhdoa4M6.mjs → 22GsbC-1.mjs} +1 -1
  7. package/chunks/{DRXM1Mt22.mjs → B4GsYMXo.mjs} +1 -1
  8. package/chunks/{l5bfIjYm.mjs → B8NokGUg.mjs} +4715 -5034
  9. package/chunks/{CWaId08S2.mjs → BEghYt1s2.mjs} +1 -1
  10. package/chunks/{CGVBF4Ml.mjs → BQytQPLa.mjs} +58 -51
  11. package/chunks/{D5_ezGUV2.mjs → BVUClQOx.mjs} +2 -2
  12. package/chunks/{Dpzw7Rtp.mjs → BWTQ3qdg.mjs} +1 -1
  13. package/chunks/{uDwSrV7X2.mjs → Bo8lYN4n2.mjs} +2 -2
  14. package/chunks/{D6qJXu04.mjs → Bs926z902.mjs} +48 -49
  15. package/chunks/{BVsvRLea2.mjs → Bu1M7um22.mjs} +2 -2
  16. package/chunks/{CeEYChF4.mjs → Bvn6wnku.mjs} +2 -2
  17. package/chunks/{CyQmVphZ.mjs → C-zPVdz-.mjs} +35 -35
  18. package/chunks/{BZRmdKBG.mjs → CDalOJtl2.mjs} +65 -66
  19. package/chunks/{lPQBM7xc2.mjs → CGmbnjKL.mjs} +2 -2
  20. package/chunks/{kAaQhLJs2.mjs → COA3tHyu2.mjs} +1 -1
  21. package/chunks/{CVM0lwn22.mjs → CONqKD47.mjs} +2 -2
  22. package/chunks/{BTNnujZA2.mjs → CTYReSXN.mjs} +1 -1
  23. package/chunks/{BK6DiJfX2.mjs → ChP-pNSi2.mjs} +3 -3
  24. package/chunks/{DMDsZeqv.mjs → CiMBKxeJ.mjs} +1 -1
  25. package/chunks/{Dgwcljur.mjs → CkLpOk7H.mjs} +1 -1
  26. package/chunks/{CI-pH-gR2.mjs → Co0M4G3P.mjs} +1 -1
  27. package/chunks/{DS4Iw8Y42.mjs → D6mInNk02.mjs} +80 -78
  28. package/chunks/{BM8snKHN2.mjs → DH-B0Lkz2.mjs} +2 -2
  29. package/chunks/{Bq9KMIsC.mjs → DMSbDBCP.mjs} +143 -143
  30. package/chunks/{Cg6ahpHk.mjs → DQMWqQFe2.mjs} +2 -2
  31. package/chunks/{DFa2J7ul.mjs → D_q3C3v4.mjs} +130 -130
  32. package/chunks/{DyGddGTO.mjs → DbcxJ45j.mjs} +96 -97
  33. package/chunks/{B-WTB0ce2.mjs → DcgE9SF_2.mjs} +1 -1
  34. package/chunks/{Bh2SlzOo.mjs → DgH_4qOn2.mjs} +3 -0
  35. package/chunks/{CeI6Qrij.mjs → DhqOVe4S.mjs} +100 -99
  36. package/chunks/{285I1DfO.mjs → Dnb8jUG_.mjs} +14 -15
  37. package/chunks/{BaB0bq4I2.mjs → DxeRdYI82.mjs} +1 -1
  38. package/chunks/{JjnlFlI02.mjs → Dz_TTgwF2.mjs} +92 -90
  39. package/chunks/{C3pzNRoU2.mjs → T2V8nxIu.mjs} +363 -362
  40. package/chunks/{BLBHnUme2.mjs → Zdhb_SRi2.mjs} +1 -1
  41. package/chunks/{BvlU_Z6D2.mjs → eX0Esdvw2.mjs} +1 -1
  42. package/chunks/{CoPlnbwi2.mjs → hBvPGqka.mjs} +2 -2
  43. package/chunks/{BkoWiWEW.mjs → mqi8hesW2.mjs} +190 -191
  44. package/chunks/{DP7eF99m2.mjs → oXiNltCq.mjs} +1 -1
  45. package/chunks/{x2jJ6cfy2.mjs → shY1VkIE2.mjs} +1 -1
  46. package/chunks/{ohCkWdwS.mjs → tSaeUhnr.mjs} +1 -1
  47. package/chunks/{C0gLPKS8.mjs → tqW2DSco.mjs} +48 -47
  48. package/code-mirror-editor/index.d.ts +50 -0
  49. package/confirm-button/index.d.ts +122 -0
  50. package/confirmable/index.d.ts +93 -0
  51. package/context-menu/index.d.ts +183 -0
  52. package/count-up/index.d.ts +70 -0
  53. package/custom-scrollbar/index.d.ts +49 -0
  54. package/data-box/index.d.ts +30 -0
  55. package/data-card/index.d.ts +20 -0
  56. package/data-card-text/index.d.ts +21 -0
  57. package/data-display/index.d.ts +20 -0
  58. package/data-icons/index.d.ts +21 -0
  59. package/data-imgtext/index.d.ts +18 -0
  60. package/data-operatext/index.d.ts +17 -0
  61. package/data-panel/index.d.ts +19 -0
  62. package/data-pay/index.d.ts +19 -0
  63. package/data-price/index.d.ts +17 -0
  64. package/data-progress/index.d.ts +19 -0
  65. package/data-rotate/index.d.ts +21 -0
  66. package/data-table-picker/index.d.ts +61 -0
  67. package/data-table-picker/index.mjs +16 -15
  68. package/data-tabs/index.d.ts +21 -0
  69. package/dict-render/index.d.ts +28 -0
  70. package/e-charts/index.d.ts +79 -0
  71. package/easy-popup/index.d.ts +114 -0
  72. package/editable-progress/index.d.ts +68 -0
  73. package/editable-tree/index.d.ts +281 -0
  74. package/editable-tree/index.mjs +111 -110
  75. package/element-dialog/index.d.ts +376 -0
  76. package/element-resize-observer/index.d.ts +8 -0
  77. package/empty-view/index.d.ts +29 -0
  78. package/error-view/index.d.ts +25 -0
  79. package/flex-box/index.d.ts +44 -0
  80. package/flex-column/index.d.ts +41 -0
  81. package/flex-item/index.d.ts +77 -0
  82. package/flex-row/index.d.ts +41 -0
  83. package/flex-scroll-area/index.d.ts +22 -0
  84. package/flex-scroller/index.d.ts +26 -0
  85. package/flow-designer/index.d.ts +286 -0
  86. package/flow-designer/index.mjs +1 -1
  87. package/flow-designer/style.css +1 -1
  88. package/flow-viewer/index.d.ts +62 -0
  89. package/form-advice/index.d.ts +9 -0
  90. package/form-button/index.d.ts +123 -0
  91. package/form-card/index.d.ts +14 -0
  92. package/form-cascader/index.d.ts +478 -0
  93. package/form-cascader/index.mjs +1 -1
  94. package/form-cell/index.d.ts +25 -0
  95. package/form-checkbox/index.d.ts +314 -0
  96. package/form-checkbox/index.mjs +1 -1
  97. package/form-checkbox-group/index.d.ts +373 -0
  98. package/form-checkbox-group/index.mjs +1 -1
  99. package/form-date-picker/index.d.ts +480 -0
  100. package/form-date-picker/index.mjs +1 -1
  101. package/form-holder/index.d.ts +162 -0
  102. package/form-holder/index.mjs +1 -1
  103. package/form-image/index.d.ts +220 -0
  104. package/form-image/index.mjs +1 -1
  105. package/form-input/index.d.ts +378 -0
  106. package/form-input/index.mjs +1 -1
  107. package/form-input-cron-expression/index.d.ts +223 -0
  108. package/form-input-cron-expression/index.mjs +1 -1
  109. package/form-input-email/index.d.ts +376 -0
  110. package/form-input-email/index.mjs +1 -1
  111. package/form-input-id-card/index.d.ts +376 -0
  112. package/form-input-id-card/index.mjs +1 -1
  113. package/form-input-number/index.d.ts +329 -0
  114. package/form-input-number/index.mjs +1 -1
  115. package/form-input-phone-number/index.d.ts +376 -0
  116. package/form-input-phone-number/index.mjs +1 -1
  117. package/form-input-tag/index.d.ts +270 -0
  118. package/form-input-tag/index.mjs +1 -1
  119. package/form-input-time/index.d.ts +441 -0
  120. package/form-input-time/index.mjs +1 -1
  121. package/form-item-config-provider/index.d.ts +40 -0
  122. package/form-item-group/index.d.ts +92 -0
  123. package/form-item-group/index.mjs +1 -1
  124. package/form-item-x/index.d.ts +190 -0
  125. package/form-item-x/index.mjs +1 -1
  126. package/form-radio-group/index.d.ts +374 -0
  127. package/form-radio-group/index.mjs +1 -1
  128. package/form-rate/index.d.ts +325 -0
  129. package/form-rate/index.mjs +1 -1
  130. package/form-red-table/index.d.ts +21 -0
  131. package/form-row/index.d.ts +11 -0
  132. package/form-row/index.mjs +1 -1
  133. package/form-select/index.d.ts +606 -0
  134. package/form-select/index.mjs +1 -1
  135. package/form-slider/index.d.ts +352 -0
  136. package/form-slider/index.mjs +1 -1
  137. package/form-switch/index.d.ts +343 -0
  138. package/form-switch/index.mjs +1 -1
  139. package/form-table/index.d.ts +287 -0
  140. package/form-table/index.mjs +1 -1
  141. package/form-table-plus/index.d.ts +266 -0
  142. package/form-table-plus/index.mjs +1 -1
  143. package/form-text/index.d.ts +235 -0
  144. package/form-text/index.mjs +1 -1
  145. package/form-textarea/index.d.ts +351 -0
  146. package/form-textarea/index.mjs +1 -1
  147. package/form-time-select/index.d.ts +325 -0
  148. package/form-time-select/index.mjs +1 -1
  149. package/form-tree-select/index.d.ts +715 -0
  150. package/form-tree-select/index.mjs +1 -1
  151. package/form-tree-select-multiple/index.d.ts +717 -0
  152. package/form-tree-select-multiple/index.mjs +1 -1
  153. package/form-view/index.d.ts +226 -0
  154. package/form-view/index.mjs +2 -2
  155. package/guide-steps/index.d.ts +31 -0
  156. package/helper/input.mjs +1 -1
  157. package/highlight-j-s/index.d.ts +18 -0
  158. package/iframe-window/index.d.ts +9 -0
  159. package/image-cropper/index.d.ts +365 -0
  160. package/image-preview/index.d.ts +61 -0
  161. package/image-viewer/index.d.ts +25 -0
  162. package/index.css +1 -1
  163. package/index.d.ts +119 -119
  164. package/index.mjs +121 -121
  165. package/input-number-range/index.d.ts +41 -0
  166. package/keyboard/index.d.ts +64 -0
  167. package/keyboard/index.mjs +1 -1
  168. package/loading-view/index.d.ts +65 -0
  169. package/name-avatar/index.d.ts +62 -0
  170. package/nav-bar/index.d.ts +21 -0
  171. package/package.json +1 -1
  172. package/page/index.d.ts +21 -0
  173. package/page-header/index.d.ts +27 -0
  174. package/page-index/index.d.ts +82 -0
  175. package/page-index-top/index.d.ts +38 -0
  176. package/page-skeleton/index.d.ts +30 -0
  177. package/page-skeleton-new/index.d.ts +34 -0
  178. package/pageable-table/index.d.ts +400 -0
  179. package/photo-swipe/index.d.ts +18 -0
  180. package/photo-swipe/index.mjs +1 -1
  181. package/props/date.d.ts +1 -4
  182. package/props/date.mjs +18 -5
  183. package/sign-panel/index.d.ts +85 -0
  184. package/skeleton-panel/index.d.ts +27 -0
  185. package/split-pane/index.d.ts +106 -0
  186. package/split-pane/index.mjs +1 -1
  187. package/stateful/index.d.ts +92 -0
  188. package/sub-table/index.d.ts +109 -0
  189. package/sub-table/index.mjs +1 -1
  190. package/sub-table-plus/index.d.ts +109 -0
  191. package/sub-table-plus/index.mjs +1 -1
  192. package/swiper/index.d.ts +27 -0
  193. package/table-column/index.d.ts +163 -0
  194. package/table-column-def/index.d.ts +97 -0
  195. package/table-view/index.d.ts +346 -0
  196. package/table-view/index.mjs +92 -90
  197. package/tag-render/index.d.ts +48 -0
  198. package/text-ellipsis/index.d.ts +111 -0
  199. package/toolbar/index.d.ts +129 -0
  200. package/toolbar/index.mjs +1 -1
  201. package/toolbar-button/index.d.ts +189 -0
  202. package/vue-cron/index.d.ts +191 -0
  203. package/vue-cron/index.mjs +1 -1
  204. package/vue-qr-code/index.d.ts +47 -0
  205. package/vue-tags-input/index.d.ts +373 -0
  206. package/vue-tree-select/index.d.ts +1489 -0
  207. package/vue-tree-select/index.mjs +1 -1
  208. package/vue-video-player/index.d.ts +117 -0
  209. package/watermark/index.d.ts +97 -0
  210. package/watermark/index.mjs +1 -1
  211. package/web-types.json +1 -1
  212. package/x-input-tag/index.d.ts +2 -0
  213. package/year-calendar/index.d.ts +99 -0
  214. package/year-calendar/index.mjs +1 -1
  215. package/chunks/CjjJimnU.mjs +0 -20
  216. /package/chunks/{tJ_t87kJ.mjs → 6dNVtIN32.mjs} +0 -0
  217. /package/chunks/{CJ7Ai-mH2.mjs → B1luuf_A2.mjs} +0 -0
  218. /package/chunks/{B1jgu0ci.mjs → BAG_R87k2.mjs} +0 -0
  219. /package/chunks/{gNfZhMJk2.mjs → BM5LdxU72.mjs} +0 -0
  220. /package/chunks/{CZeL7oiY2.mjs → BhHMGhJ8.mjs} +0 -0
  221. /package/chunks/{z6tpYT0z.mjs → BwL9Xz1F.mjs} +0 -0
  222. /package/chunks/{B2Y1LWJ3.mjs → Dkw6LNCq2.mjs} +0 -0
  223. /package/chunks/{b_78-Wov2.mjs → FZqu01np2.mjs} +0 -0
  224. /package/chunks/{hPAfGilD.mjs → KOJEsarR2.mjs} +0 -0
  225. /package/chunks/{3UWcbJcG.mjs → PEU1JRcN2.mjs} +0 -0
@@ -2,18 +2,19 @@ import { m as e, t } from "../chunks/ClVh1Lek.mjs";
2
2
  import { t as n } from "../chunks/B1MSrc6f.mjs";
3
3
  import { t as r } from "../chunks/mnqSaATq.mjs";
4
4
  import { allProps as i, predicate as a } from "../props/tree.mjs";
5
- import { ElInput as o, ElMessageBox as s, ElPopconfirm as c, ElTree as l } from "element-plus/es";
5
+ import { ElInput as o, ElMessage as s, ElMessageBox as c, ElPopconfirm as l, ElTree as u } from "element-plus/es";
6
6
  import "element-plus/es/components/base/style/css";
7
7
  import "element-plus/es/components/input/style/css";
8
- import { Fragment as u, createBlock as d, createCommentVNode as f, createElementBlock as p, createElementVNode as m, createTextVNode as h, createVNode as g, mergeProps as _, normalizeClass as v, normalizeStyle as y, openBlock as b, renderSlot as x, toDisplayString as S, toHandlers as C, vShow as w, withCtx as T, withDirectives as E, withModifiers as D } from "vue";
9
- import { computePosition as O, delay as k, fastClone as A, findTreeChildren as j, isFunction as M, isNotEmpty as N, isPlainObject as P, isUndefined as F, isVerticalScrollbarVisible as I, patch as L, scrollbarWidth as R } from "@web-utils/core";
8
+ import { Fragment as d, createBlock as f, createCommentVNode as p, createElementBlock as m, createElementVNode as h, createTextVNode as g, createVNode as _, mergeProps as v, normalizeClass as y, normalizeStyle as b, openBlock as x, renderSlot as S, toDisplayString as C, toHandlers as w, vShow as T, withCtx as E, withDirectives as D, withModifiers as O } from "vue";
9
+ import { computePosition as k, delay as A, fastClone as j, findTreeChildren as M, isFunction as N, isNotEmpty as P, isPlainObject as F, isUndefined as I, isVerticalScrollbarVisible as L, patch as R, scrollbarWidth as z } from "@web-utils/core";
10
+ import "element-plus/es/components/message/style/css";
10
11
  import "element-plus/es/components/message-box/style/css";
11
- import { cloneDeep as z } from "@web-utils/integrations/lodash";
12
+ import { cloneDeep as B } from "@web-utils/integrations/lodash";
12
13
  import "element-plus/es/components/tree/style/css";
13
14
  import "element-plus/es/components/popconfirm/style/css";
14
- import { addResizeListener as B, removeResizeListener as V } from "@web-utils/integrations/resize";
15
+ import { addResizeListener as V, removeResizeListener as H } from "@web-utils/integrations/resize";
15
16
  //#region src/components/form/EditableTree.vue
16
- var H = {
17
+ var U = {
17
18
  name: "EditableTree",
18
19
  props: { ...i },
19
20
  emits: {
@@ -79,10 +80,10 @@ var H = {
79
80
  this.tryFetch();
80
81
  },
81
82
  mounted() {
82
- B(this.$refs.tree.$el, this.resize), B(this.$refs.treeWrapper, this.resize);
83
+ V(this.$refs.tree.$el, this.resize), V(this.$refs.treeWrapper, this.resize);
83
84
  },
84
85
  beforeUnmount() {
85
- V(this.$refs.tree.$el, this.resize), V(this.$refs.treeWrapper, this.resize);
86
+ H(this.$refs.tree.$el, this.resize), H(this.$refs.treeWrapper, this.resize);
86
87
  },
87
88
  methods: {
88
89
  addExpandKey(e) {
@@ -92,10 +93,10 @@ var H = {
92
93
  this.reserveExpandKey && (this.expandedKeys = this.expandedKeys.filter((t) => t !== e[this.nodeKey]));
93
94
  },
94
95
  resize() {
95
- I(this.$refs.treeWrapper) ? this.right = 4 + R : this.right = 4;
96
+ L(this.$refs.treeWrapper) ? this.right = 4 + z : this.right = 4;
96
97
  },
97
98
  async showContextMenu(e, t, n) {
98
- t.contextmenu === !1 || t.id === -1 || t.id === 0 || t.edit === !0 || this.readonly || this.contextMenu && (this.curNode = n, this.curData = t, this.showMenu = !0, this.$refs.tree.setCurrentKey(t.id), await this.$nextTick(), this.position = O(e, this.$refs.contextMenu), window.addEventListener("click", this.hideContextMenu));
99
+ t.contextmenu === !1 || t.id === -1 || t.id === 0 || t.edit === !0 || this.readonly || this.contextMenu && (this.curNode = n, this.curData = t, this.showMenu = !0, this.$refs.tree.setCurrentKey(t.id), await this.$nextTick(), this.position = k(e, this.$refs.contextMenu), window.addEventListener("click", this.hideContextMenu));
99
100
  },
100
101
  hideContextMenu() {
101
102
  this.showMenu = !1, window.removeEventListener("click", this.hideContextMenu);
@@ -111,14 +112,14 @@ var H = {
111
112
  return;
112
113
  }
113
114
  let i = r.data.data;
114
- P(i) && (i = [i]), i = i || [];
115
+ F(i) && (i = [i]), i = i || [];
115
116
  let a = [];
116
- if (this.empty = i.length === 0, P(this.customRootNode)) {
117
- let e = z(this.customRootNode);
117
+ if (this.empty = i.length === 0, F(this.customRootNode)) {
118
+ let e = B(this.customRootNode);
118
119
  e[this.treeProps.children || "children"] = i, a = [e];
119
- } else if (M(this.customRootNode)) {
120
+ } else if (N(this.customRootNode)) {
120
121
  let e = this.customRootNode(i);
121
- e[this.treeProps.children || "children"] = i, a = P(e) ? [e] : e;
122
+ e[this.treeProps.children || "children"] = i, a = F(e) ? [e] : e;
122
123
  } else a = i;
123
124
  if ((e = this.defaultExpandedKeys) != null && e.length) this.expandedKeys = [...this.defaultExpandedKeys];
124
125
  else if (this.expandFirstNode) {
@@ -132,12 +133,12 @@ var H = {
132
133
  if (e.level === 0) {
133
134
  var n, r;
134
135
  let o = (await this.fetchApi(((n = this.rootNode) == null ? void 0 : n.id) ?? -1, e)).data.data;
135
- if (this.empty = o.length === 0, P(this.customRootNode)) {
136
- let e = z(this.customRootNode);
136
+ if (this.empty = o.length === 0, F(this.customRootNode)) {
137
+ let e = B(this.customRootNode);
137
138
  e[this.treeProps.children || "children"] = o, o = [e], t(o);
138
- } else if (M(this.customRootNode)) {
139
+ } else if (N(this.customRootNode)) {
139
140
  let e = this.customRootNode(o);
140
- e[this.treeProps.children || "children"] = o, o = P(e) ? [e] : e;
141
+ e[this.treeProps.children || "children"] = o, o = F(e) ? [e] : e;
141
142
  } else t(o);
142
143
  if (await this.$nextTick(), this.$emit("root-node-loaded", o), (r = this.defaultExpandedKeys) != null && r.length) {
143
144
  var i;
@@ -162,10 +163,10 @@ var H = {
162
163
  this.newChild && this.newChild.id === -1 && (this.$refs.tree.remove(this.newChild), this.$emit("remove-new-node"));
163
164
  },
164
165
  cancelEdit() {
165
- this.editData && (F(this.editData.edit) ? this.editData.edit = !0 : this.editData.edit = !1);
166
+ this.editData && (I(this.editData.edit) ? this.editData.edit = !0 : this.editData.edit = !1);
166
167
  },
167
168
  async editNode(e, t) {
168
- !this.contextMenu || this.contextMenuIcon || this.contextMenuInline ? (this.clear(), this.editData = t, this.text = t[this.treeProps.label], F(t.edit), t.edit = !0, await this.$nextTick(), this.$refs.labelTxt.focus()) : await s.prompt(`请输入新的${this.label}名:`, {
169
+ !this.contextMenu || this.contextMenuIcon || this.contextMenuInline ? (this.clear(), this.editData = t, this.text = t[this.treeProps.label], I(t.edit), t.edit = !0, await this.$nextTick(), this.$refs.labelTxt.focus()) : await c.prompt(`请输入新的${this.label}名:`, {
169
170
  ...this.defaultOptions,
170
171
  inputValue: t[this.treeProps.label],
171
172
  beforeClose: async (e, t, n) => {
@@ -181,7 +182,7 @@ var H = {
181
182
  }).catch((e) => e);
182
183
  },
183
184
  async appendRootNode() {
184
- this.text = "", !this.contextMenu || this.contextMenuIcon || this.contextMenuInline ? (this.clear(), this.createNewChild(void 0), this.$refs.tree.root.insertChild({ data: this.newChild }, void 0, !0), await this.scrollIntoView(!0)) : await s.prompt(`请输入${this.label}名:`, {
185
+ this.text = "", !this.contextMenu || this.contextMenuIcon || this.contextMenuInline ? (this.clear(), this.createNewChild(void 0), this.$refs.tree.root.insertChild({ data: this.newChild }, void 0, !0), await this.scrollIntoView(!0)) : await c.prompt(`请输入${this.label}名:`, {
185
186
  ...this.defaultOptions,
186
187
  beforeClose: async (e, n, r) => {
187
188
  if (e === "confirm") {
@@ -201,7 +202,7 @@ var H = {
201
202
  this.text = "";
202
203
  let n = e.expanded;
203
204
  e.expand(async () => {
204
- !this.contextMenu || this.contextMenuIcon || this.contextMenuInline ? (this.clear(), this.createNewChild(e.data.id), this.$refs.tree.append(this.newChild, e), await this.scrollIntoView(n)) : await s.prompt(`请输入${this.label}名:`, {
205
+ !this.contextMenu || this.contextMenuIcon || this.contextMenuInline ? (this.clear(), this.createNewChild(e.data.id), this.$refs.tree.append(this.newChild, e), await this.scrollIntoView(n)) : await c.prompt(`请输入${this.label}名:`, {
205
206
  ...this.defaultOptions,
206
207
  beforeClose: async (n, r, i) => {
207
208
  if (n === "confirm") {
@@ -250,7 +251,7 @@ var H = {
250
251
  },
251
252
  updateNode(e) {
252
253
  let t = this.$refs.tree.getNode(e);
253
- t && L(t.data, e, !0);
254
+ t && R(t.data, e, !0);
254
255
  },
255
256
  setCurrentKey(e) {
256
257
  var t;
@@ -267,7 +268,7 @@ var H = {
267
268
  }, this.$emit("create-new-node", this.newChild);
268
269
  },
269
270
  async removeNodeModal(e) {
270
- await this.$confirm(`你确定要删除${this.label}[<span class="break-word" style="color: orange">${e.data[this.treeProps.label]}</span>]吗?`, "系统提示", {
271
+ await c.confirm(`你确定要删除${this.label}[<span class="break-word" style="color: orange">${e.data[this.treeProps.label]}</span>]吗?`, "系统提示", {
271
272
  type: "warning",
272
273
  modal: !0,
273
274
  dangerouslyUseHTMLString: !0,
@@ -280,7 +281,7 @@ var H = {
280
281
  try {
281
282
  n.confirmButtonLoading = !0, n.confirmButtonText = "删除...";
282
283
  let t = e.parent, i = await this.deleteApi(e.data.id);
283
- i.code === 0 ? (this.$message.success("删除成功!"), this.$refs.tree.remove(e), this.$emit("node-deleted", t, e.data), r()) : this.$message.error(i.message);
284
+ i.code === 0 ? (s.success("删除成功!"), this.$refs.tree.remove(e), this.$emit("node-deleted", t, e.data), r()) : s.error(i.message);
284
285
  } catch {}
285
286
  n.confirmButtonText = "确定", n.confirmButtonLoading = !1;
286
287
  } else r();
@@ -292,19 +293,19 @@ var H = {
292
293
  let t = e.parent;
293
294
  if (this.deleteApi) {
294
295
  let n = await this.deleteApi(e.data.id);
295
- n.code === 0 ? (this.$message.success("删除成功!"), this.$refs.tree.remove(e), this.$emit("node-deleted", t, e.data)) : this.$message.error(n.message);
296
+ n.code === 0 ? (s.success("删除成功!"), this.$refs.tree.remove(e), this.$emit("node-deleted", t, e.data)) : s.error(n.message);
296
297
  } else this.$refs.tree.remove(e);
297
298
  } catch {}
298
299
  },
299
300
  async onConfirm(e, n) {
300
- if (n[this.treeProps.label] === this.text || !N(this.text)) {
301
+ if (n[this.treeProps.label] === this.text || !P(this.text)) {
301
302
  this.clear();
302
303
  return;
303
304
  }
304
- F(n.loading), n.loading = !0;
305
+ I(n.loading), n.loading = !0;
305
306
  try {
306
307
  if (this.loading = !0, n.id === -1) {
307
- let r = await this.saveApi(this.newNodeBuilder(this.text, e.parent.data || { id: -1 })), i = A(n);
308
+ let r = await this.saveApi(this.newNodeBuilder(this.text, e.parent.data || { id: -1 })), i = j(n);
308
309
  t(n, {
309
310
  ...r.data,
310
311
  isTempNode: !1
@@ -321,7 +322,7 @@ var H = {
321
322
  t.id === -1 ? this.$refs.tree.remove(e) : t.edit = !1, this.text = "";
322
323
  },
323
324
  nodeClick(e, t, n) {
324
- this.hideContextMenu(), (F(e.loading) || !e.loading) && (this.curNode = t, this.curData = e, this.$emit("on-node-click", e, t, n));
325
+ this.hideContextMenu(), (I(e.loading) || !e.loading) && (this.curNode = t, this.curData = e, this.$emit("on-node-click", e, t, n));
325
326
  },
326
327
  getCurrentNode() {
327
328
  return this.$refs.tree.getCurrentNode();
@@ -333,7 +334,7 @@ var H = {
333
334
  },
334
335
  async scrollIntoView(e) {
335
336
  var t;
336
- await this.$nextTick(), e || await k(300), (t = this.$refs) == null || (t = t.labelTxt) == null || t.focus();
337
+ await this.$nextTick(), e || await A(300), (t = this.$refs) == null || (t = t.labelTxt) == null || t.focus();
337
338
  },
338
339
  inputKeyup(e, t, n) {
339
340
  e.keyCode === 13 && this.onConfirm(t, n), e.keyCode === 27 && this.clear();
@@ -360,7 +361,7 @@ var H = {
360
361
  return this.$refs.tree.root;
361
362
  },
362
363
  findTreeNode(e) {
363
- return j(this.$refs.tree.root.childNodes, (t) => t.data === e || t.data.id === e, "childNodes");
364
+ return M(this.$refs.tree.root.childNodes, (t) => t.data === e || t.data.id === e, "childNodes");
364
365
  },
365
366
  registerNode(e) {
366
367
  e.store.registerNode(e), delete e.store.nodesMap[-1];
@@ -369,32 +370,32 @@ var H = {
369
370
  this.lazy ? this.treeKey = Date.now() : await this.tryFetch();
370
371
  }
371
372
  }
372
- }, U = { class: "editable-tree" }, W = {
373
+ }, W = { class: "editable-tree" }, G = {
373
374
  ref: "treeWrapper",
374
375
  class: "et-tree-wrapper"
375
- }, G = {
376
+ }, K = {
376
377
  key: 0,
377
378
  style: { "padding-left": "24px" }
378
- }, K = ["data-id"], q = {
379
+ }, q = ["data-id"], J = {
379
380
  class: "node-label flex-row flex-item ellipsis-1",
380
381
  style: { overflow: "hidden" }
381
- }, J = {
382
+ }, Y = {
382
383
  class: "flex-item-relative",
383
384
  style: { height: "21px" }
384
- }, Y = ["title"], X = {
385
+ }, X = ["title"], Z = {
385
386
  key: 0,
386
387
  class: "handle-actions"
387
- }, Z = {
388
+ }, Q = {
388
389
  key: 1,
389
390
  class: "handle-actions",
390
391
  style: { display: "inline-block" }
391
- }, Q = ["data-id"], $ = { class: "menu-list" };
392
- function ee(e, t, n, i, a, s) {
393
- let O = r, k = c, A = o, j = l;
394
- return b(), p("div", U, [!e.readonly && e.addRootNodeButtonStyle === "top-right" ? (b(), d(O, {
392
+ }, $ = ["data-id"], ee = { class: "menu-list" };
393
+ function te(e, t, n, i, a, s) {
394
+ let c = r, k = l, A = o, j = u;
395
+ return x(), m("div", W, [!e.readonly && e.addRootNodeButtonStyle === "top-right" ? (x(), f(c, {
395
396
  key: 0,
396
397
  type: "primary",
397
- style: y([{
398
+ style: b([{
398
399
  position: "absolute",
399
400
  top: "4px",
400
401
  "z-index": "1"
@@ -402,17 +403,17 @@ function ee(e, t, n, i, a, s) {
402
403
  icon: "el-icon-plus",
403
404
  circle: "",
404
405
  plain: "",
405
- onClick: t[0] || (t[0] = D((t) => e.$emit("add-root-node"), ["stop"]))
406
- }, null, 8, ["style"])) : f("v-if", !0), m("div", W, [
407
- !e.readonly && e.addRootNodeButtonStyle === "top" ? (b(), p("div", G, [g(O, {
406
+ onClick: t[0] || (t[0] = O((t) => e.$emit("add-root-node"), ["stop"]))
407
+ }, null, 8, ["style"])) : p("v-if", !0), h("div", G, [
408
+ !e.readonly && e.addRootNodeButtonStyle === "top" ? (x(), m("div", K, [_(c, {
408
409
  disabled: a.loading,
409
410
  type: "text",
410
411
  onClick: s.appendRootNode
411
412
  }, {
412
- default: T(() => [t[8] || (t[8] = m("i", { class: "el-icon-lx-add" }, null, -1)), h(" " + S(e.addRootNodeLabel ? e.addRootNodeLabel : `添加${e.label}`), 1)]),
413
+ default: E(() => [t[8] || (t[8] = h("i", { class: "el-icon-lx-add" }, null, -1)), g(" " + C(e.addRootNodeLabel ? e.addRootNodeLabel : `添加${e.label}`), 1)]),
413
414
  _: 1
414
- }, 8, ["disabled", "onClick"])])) : f("v-if", !0),
415
- (b(), d(j, _(i.autoBindProps, {
415
+ }, 8, ["disabled", "onClick"])])) : p("v-if", !0),
416
+ (x(), f(j, v(i.autoBindProps, {
416
417
  key: a.treeKey,
417
418
  ref: "tree",
418
419
  "default-expand-all": e.defaultExpandAll,
@@ -425,25 +426,25 @@ function ee(e, t, n, i, a, s) {
425
426
  props: e.treeProps,
426
427
  lazy: e.lazy,
427
428
  "node-key": e.nodeKey
428
- }, C(i.listeners), {
429
+ }, w(i.listeners), {
429
430
  onNodeClick: s.nodeClick,
430
431
  onNodeContextmenu: s.showContextMenu,
431
432
  onNodeExpand: s.addExpandKey,
432
433
  onNodeCollapse: s.removeExpandKey
433
434
  }), {
434
- default: T(({ node: n, data: r }) => [x(e.$slots, "default", {
435
+ default: E(({ node: n, data: r }) => [S(e.$slots, "default", {
435
436
  node: n,
436
437
  data: r
437
- }, () => [f("非编辑模式"), r.edit ? (b(), p(u, { key: 1 }, [f("编辑模式"), m("span", {
438
+ }, () => [p("非编辑模式"), r.edit ? (x(), m(d, { key: 1 }, [p("编辑模式"), h("span", {
438
439
  "data-id": r.id,
439
440
  class: "custom-tree-node flex-row flex-item",
440
441
  style: { overflow: "hidden" }
441
442
  }, [
442
- e.icon ? (b(), p("i", {
443
+ e.icon ? (x(), m("i", {
443
444
  key: 0,
444
- class: v([r.loading ? "el-icon-loading" : "el-icon-edit-outline", "node-icon flex-not-shrink"])
445
- }, null, 2)) : f("v-if", !0),
446
- g(A, {
445
+ class: y([r.loading ? "el-icon-loading" : "el-icon-edit-outline", "node-icon flex-not-shrink"])
446
+ }, null, 2)) : p("v-if", !0),
447
+ _(A, {
447
448
  ref: "labelTxt",
448
449
  modelValue: a.text,
449
450
  "onUpdate:modelValue": t[2] || (t[2] = (e) => a.text = e),
@@ -451,91 +452,91 @@ function ee(e, t, n, i, a, s) {
451
452
  placeholder: s.defaultOptions.inputPlaceholder,
452
453
  onKeyup: (e) => s.inputKeyup(e, n, r),
453
454
  onBlur: (e) => s.inputBlur(e, n, r),
454
- onClick: t[3] || (t[3] = D(() => {}, ["stop"]))
455
+ onClick: t[3] || (t[3] = O(() => {}, ["stop"]))
455
456
  }, null, 8, [
456
457
  "modelValue",
457
458
  "placeholder",
458
459
  "onKeyup",
459
460
  "onBlur"
460
461
  ]),
461
- e.confirmButton ? (b(), p(u, { key: 1 }, [E(g(O, {
462
+ e.confirmButton ? (x(), m(d, { key: 1 }, [D(_(c, {
462
463
  class: "flex-not-shrink",
463
464
  type: "text",
464
- onClick: D((e) => s.onConfirm(n, r), ["stop"])
465
+ onClick: O((e) => s.onConfirm(n, r), ["stop"])
465
466
  }, {
466
- default: T(() => [...t[13] || (t[13] = [h(" 确定 ", -1)])]),
467
+ default: E(() => [...t[13] || (t[13] = [g(" 确定 ", -1)])]),
467
468
  _: 1
468
- }, 8, ["onClick"]), [[w, !r.loading]]), E(g(O, {
469
+ }, 8, ["onClick"]), [[T, !r.loading]]), D(_(c, {
469
470
  class: "flex-not-shrink",
470
471
  type: "text",
471
- onClick: D((e) => s.onCancel(n, r), ["stop"])
472
+ onClick: O((e) => s.onCancel(n, r), ["stop"])
472
473
  }, {
473
- default: T(() => [...t[14] || (t[14] = [h(" 取消 ", -1)])]),
474
+ default: E(() => [...t[14] || (t[14] = [g(" 取消 ", -1)])]),
474
475
  _: 1
475
- }, 8, ["onClick"]), [[w, !r.loading]])], 64)) : f("v-if", !0)
476
- ], 8, Q)], 64)) : (b(), p("span", {
476
+ }, 8, ["onClick"]), [[T, !r.loading]])], 64)) : p("v-if", !0)
477
+ ], 8, $)], 64)) : (x(), m("span", {
477
478
  key: 0,
478
479
  "data-id": r.id,
479
480
  class: "custom-tree-node"
480
481
  }, [
481
- m("span", q, [
482
- e.icon ? (b(), p("i", {
482
+ h("span", J, [
483
+ e.icon ? (x(), m("i", {
483
484
  key: 0,
484
- class: v([r.loading ? "el-icon-loading" : e.icon(r, n), "node-icon"])
485
- }, null, 2)) : f("v-if", !0),
486
- m("span", J, [m("span", {
485
+ class: y([r.loading ? "el-icon-loading" : e.icon(r, n), "node-icon"])
486
+ }, null, 2)) : p("v-if", !0),
487
+ h("span", Y, [h("span", {
487
488
  class: "ellipsis-1 absolute-box et-tree-label",
488
489
  title: n.label
489
- }, [x(e.$slots, "label", {
490
+ }, [S(e.$slots, "label", {
490
491
  data: r,
491
492
  node: n
492
- }, () => [h(S(n.label), 1)])], 8, Y)]),
493
- x(e.$slots, "label-suffix", {
493
+ }, () => [g(C(n.label), 1)])], 8, X)]),
494
+ S(e.$slots, "label-suffix", {
494
495
  node: n,
495
496
  data: r
496
497
  })
497
498
  ]),
498
- !e.contextMenu && !e.readonly ? E((b(), p("span", X, [
499
- g(O, {
499
+ !e.contextMenu && !e.readonly ? D((x(), m("span", Z, [
500
+ _(c, {
500
501
  type: "text",
501
- onClick: D((e) => s.appendChildNode(n, r), ["stop"])
502
+ onClick: O((e) => s.appendChildNode(n, r), ["stop"])
502
503
  }, {
503
- default: T(() => [...t[9] || (t[9] = [h("添加", -1)])]),
504
+ default: E(() => [...t[9] || (t[9] = [g("添加", -1)])]),
504
505
  _: 1
505
506
  }, 8, ["onClick"]),
506
- g(O, {
507
+ _(c, {
507
508
  type: "text",
508
- onClick: D((e) => s.editNode(n, r), ["stop"])
509
+ onClick: O((e) => s.editNode(n, r), ["stop"])
509
510
  }, {
510
- default: T(() => [...t[10] || (t[10] = [h("修改", -1)])]),
511
+ default: E(() => [...t[10] || (t[10] = [g("修改", -1)])]),
511
512
  _: 1
512
513
  }, 8, ["onClick"]),
513
- g(k, {
514
+ _(k, {
514
515
  class: "pop-confirm",
515
516
  "icon-color": "red",
516
517
  title: "你确定要删除吗?",
517
518
  onConfirm: (e) => s.removeNode(n, r)
518
519
  }, {
519
- reference: T(() => [E(g(O, {
520
+ reference: E(() => [D(_(c, {
520
521
  style: { "margin-left": "4px" },
521
522
  type: "text",
522
- onClick: t[1] || (t[1] = D(() => {}, ["stop"]))
523
+ onClick: t[1] || (t[1] = O(() => {}, ["stop"]))
523
524
  }, {
524
- default: T(() => [...t[11] || (t[11] = [h(" 删除 ", -1)])]),
525
+ default: E(() => [...t[11] || (t[11] = [g(" 删除 ", -1)])]),
525
526
  _: 1
526
- }, 512), [[w, n.isLeaf]])]),
527
+ }, 512), [[T, n.isLeaf]])]),
527
528
  _: 2
528
529
  }, 1032, ["onConfirm"])
529
- ], 512)), [[w, !r.loading && !a.loading]]) : f("v-if", !0),
530
- e.contextMenuIcon && e.contextMenu && !e.readonly ? E((b(), p("span", Z, [g(O, {
530
+ ], 512)), [[T, !r.loading && !a.loading]]) : p("v-if", !0),
531
+ e.contextMenuIcon && e.contextMenu && !e.readonly ? D((x(), m("span", Q, [_(c, {
531
532
  style: { padding: "6px 10px 0" },
532
533
  type: "text",
533
- onClick: D((e) => s.showContextMenu(e, r, n), ["stop"])
534
+ onClick: O((e) => s.showContextMenu(e, r, n), ["stop"])
534
535
  }, {
535
- default: T(() => [...t[12] || (t[12] = [h(" . . . ", -1)])]),
536
+ default: E(() => [...t[12] || (t[12] = [g(" . . . ", -1)])]),
536
537
  _: 1
537
- }, 8, ["onClick"])], 512)), [[w, !r.loading && !a.loading]]) : f("v-if", !0)
538
- ], 8, K))])]),
538
+ }, 8, ["onClick"])], 512)), [[T, !r.loading && !a.loading]]) : p("v-if", !0)
539
+ ], 8, q))])]),
539
540
  _: 3
540
541
  }, 16, [
541
542
  "default-expand-all",
@@ -550,46 +551,46 @@ function ee(e, t, n, i, a, s) {
550
551
  "onNodeExpand",
551
552
  "onNodeCollapse"
552
553
  ])),
553
- e.contextMenu && !e.readonly ? E((b(), p("div", {
554
+ e.contextMenu && !e.readonly ? D((x(), m("div", {
554
555
  key: 1,
555
556
  ref: "contextMenu",
556
- style: y(a.position),
557
+ style: b(a.position),
557
558
  class: "menu"
558
- }, [m("ul", $, [x(e.$slots, "context-menu", {
559
+ }, [h("ul", ee, [S(e.$slots, "context-menu", {
559
560
  curNode: a.curNode,
560
561
  curData: a.curData
561
562
  }, () => [
562
- E(m("li", {
563
+ D(h("li", {
563
564
  class: "menu-item",
564
565
  onClick: t[4] || (t[4] = (e) => s.appendPeerNode(a.curNode, a.curData))
565
- }, [t[15] || (t[15] = m("i", {
566
+ }, [t[15] || (t[15] = h("i", {
566
567
  class: "menu-item-icon el-icon-lx-add",
567
568
  style: { color: "#228b22" }
568
- }, null, -1)), h(" " + S(e.menuLabel.appendPeer), 1)], 512), [[w, a.curData.id > -1]]),
569
- m("li", {
569
+ }, null, -1)), g(" " + C(e.menuLabel.appendPeer), 1)], 512), [[T, a.curData.id > -1]]),
570
+ h("li", {
570
571
  class: "menu-item",
571
572
  onClick: t[5] || (t[5] = (e) => s.appendChildNode(a.curNode, a.curData))
572
- }, [t[16] || (t[16] = m("i", {
573
+ }, [t[16] || (t[16] = h("i", {
573
574
  class: "menu-item-icon el-icon-lx-add",
574
575
  style: { color: "#228b22" }
575
- }, null, -1)), h(" " + S(e.menuLabel.appendChild), 1)]),
576
- E(m("li", {
576
+ }, null, -1)), g(" " + C(e.menuLabel.appendChild), 1)]),
577
+ D(h("li", {
577
578
  class: "menu-item",
578
579
  onClick: t[6] || (t[6] = (e) => s.editNode(a.curNode, a.curData))
579
- }, [t[17] || (t[17] = m("i", {
580
+ }, [t[17] || (t[17] = h("i", {
580
581
  class: "menu-item-icon el-icon-edit-outline",
581
582
  style: { color: "#ffa500" }
582
- }, null, -1)), h(" " + S(e.menuLabel.editNode), 1)], 512), [[w, a.curData.id > -1]]),
583
- E(m("li", {
583
+ }, null, -1)), g(" " + C(e.menuLabel.editNode), 1)], 512), [[T, a.curData.id > -1]]),
584
+ D(h("li", {
584
585
  class: "menu-item",
585
586
  onClick: t[7] || (t[7] = (e) => s.removeNodeModal(a.curNode, a.curData))
586
- }, [t[18] || (t[18] = m("i", {
587
+ }, [t[18] || (t[18] = h("i", {
587
588
  class: "menu-item-icon el-icon-delete",
588
589
  style: { color: "#f00" }
589
- }, null, -1)), h(" " + S(e.menuLabel.removeNode), 1)], 512), [[w, a.curNode.isLeaf]])
590
- ])])], 4)), [[w, a.showMenu]]) : f("v-if", !0)
590
+ }, null, -1)), g(" " + C(e.menuLabel.removeNode), 1)], 512), [[T, a.curNode.isLeaf]])
591
+ ])])], 4)), [[T, a.showMenu]]) : p("v-if", !0)
591
592
  ], 512)]);
592
593
  }
593
- var te = /* @__PURE__ */ n(H, [["render", ee]]);
594
+ var ne = /* @__PURE__ */ n(U, [["render", te]]);
594
595
  //#endregion
595
- export { te as default };
596
+ export { ne as default };