@web-utils/component 3.8.3 → 4.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (211) hide show
  1. package/awesome-button/index.mjs +25 -55
  2. package/base.css +1 -1
  3. package/card/index.mjs +13 -13
  4. package/card/style.css +1 -1
  5. package/carousel/style.css +1 -1
  6. package/chat/index.mjs +2 -2
  7. package/chat/style.css +1 -1
  8. package/chunks/{ElementForm.8w6UkiuU.mjs → ElementForm.CQ3PN5qj.mjs} +17 -35
  9. package/chunks/{ElementListeners.DOy8wyD2.mjs → ElementListeners.De_PRuIm.mjs} +56 -95
  10. package/chunks/{ElementMultiInstance.3Z28ewuh.mjs → ElementMultiInstance.DQo2wuAQ.mjs} +16 -26
  11. package/chunks/{ElementProperties.B2I48muA.mjs → ElementProperties.CosfDrlW.mjs} +16 -16
  12. package/chunks/{ElementTaskConfig.MBbkLrth.mjs → ElementTaskConfig.Bko0kgTp.mjs} +104 -113
  13. package/chunks/{FlowCondition.BfU9kw6h.mjs → FlowCondition.Y6qEYi1T.mjs} +36 -66
  14. package/chunks/{FormTemp.BSpnNput.mjs → FormTemp.Bu2VCxUh.mjs} +2 -2
  15. package/chunks/{SignalAndMessage.CH6L7cYu.mjs → SignalAndMessage.Bb5PFX0N.mjs} +11 -22
  16. package/chunks/{UserTaskListeners.XXe5dC5I.mjs → UserTaskListeners.Bv3BDfEI.mjs} +45 -86
  17. package/chunks/configComponents.BDhlZU8F.mjs +23 -0
  18. package/chunks/confirmable-mixin.D9aKzKZ9.mjs +85 -0
  19. package/chunks/core.DJEgjQW6.mjs +54 -0
  20. package/chunks/{dataformat.B9UvztrQ.mjs → dataformat.CpqOeGBl.mjs} +2 -2
  21. package/chunks/{dic.CET0XdKP.mjs → dic.Dkl-leRW.mjs} +43 -43
  22. package/chunks/dictionary.DqiP9x2m.mjs +25 -0
  23. package/chunks/{event.BT1F_1vF.mjs → event.9aDS6jcw.mjs} +2 -2
  24. package/chunks/form-input.B8z37eqj.mjs +31 -0
  25. package/chunks/form-item.D-H-wCPE.mjs +233 -0
  26. package/chunks/form-validate.CVarNHKX.mjs +12 -0
  27. package/chunks/helper.BiMLcEEk.mjs +41 -0
  28. package/chunks/index.9OxHjTIE.mjs +16 -0
  29. package/chunks/{index.MAFc4eFi.mjs → index.d3MV3Wq2.mjs} +43 -47
  30. package/chunks/{init.ofpxEyAI.mjs → init.DAsXSoLW.mjs} +2 -2
  31. package/chunks/{packages.CWPkeLu9.mjs → packages.ByyangTp.mjs} +3 -3
  32. package/chunks/sub-table-plus-props.BVsD71hT.mjs +30 -0
  33. package/chunks/{tab-mixin.CVr9bZtn.mjs → tab-mixin.BNK6dxLN.mjs} +1 -1
  34. package/chunks/{util.CoahLDYn.mjs → util.DqFv_pWg.mjs} +54 -55
  35. package/chunks/utilSelf.Csq1766E.mjs +48 -0
  36. package/color-picker/index.mjs +19 -37
  37. package/comment/style.css +1 -1
  38. package/confirm-button/index.mjs +1 -1
  39. package/confirmable/index.mjs +1 -1
  40. package/context-menu/style.css +1 -1
  41. package/count-up/index.mjs +13 -24
  42. package/custom-scrollbar/index.mjs +1 -2
  43. package/data-operatext/style.css +1 -1
  44. package/data-panel/style.css +1 -1
  45. package/data-pay/style.css +1 -1
  46. package/data-price/style.css +1 -1
  47. package/data-rotate/style.css +1 -1
  48. package/data-table-picker/index.mjs +1 -1
  49. package/data-tabs/style.css +1 -1
  50. package/dialog-form/index.mjs +16 -28
  51. package/dynamic-table/style.css +1 -1
  52. package/easy-popup/index.mjs +22 -40
  53. package/easy-popup/style.css +1 -1
  54. package/editable-tree/index.mjs +203 -250
  55. package/editable-tree/style.css +1 -1
  56. package/element-dialog/index.mjs +30 -52
  57. package/element-dialog/style.css +1 -1
  58. package/flex-column/index.mjs +13 -25
  59. package/flex-item/index.mjs +15 -27
  60. package/flex-row/index.mjs +13 -25
  61. package/flow/index.mjs +30 -32
  62. package/flow-designer/index.mjs +344 -375
  63. package/flow-designer/style.css +1 -1
  64. package/flow-node/index.mjs +1 -1
  65. package/flow-viewer/index.mjs +64 -91
  66. package/form-block/index.mjs +33 -26
  67. package/form-card/index.mjs +25 -0
  68. package/form-cascader/index.mjs +70 -67
  69. package/form-checkbox/index.mjs +71 -0
  70. package/form-checkbox-group/index.mjs +33 -53
  71. package/form-date-picker/index.mjs +44 -73
  72. package/form-holder/index.mjs +60 -64
  73. package/form-holder/style.css +1 -0
  74. package/form-input/index.mjs +62 -40
  75. package/form-input-cron-expression/index.mjs +77 -0
  76. package/form-input-cron-expression/style.css +1 -0
  77. package/form-input-email/index.mjs +21 -33
  78. package/form-input-id-card/index.mjs +25 -38
  79. package/form-input-number/index.mjs +39 -42
  80. package/form-input-number/style.css +1 -1
  81. package/form-input-phone-number/index.mjs +26 -37
  82. package/form-input-tag/index.mjs +32 -34
  83. package/form-input-time/index.mjs +22 -37
  84. package/form-item/index.mjs +109 -101
  85. package/form-item/style.css +1 -1
  86. package/form-item-config-provider/index.mjs +18 -10
  87. package/form-item-group/index.mjs +73 -69
  88. package/form-item-group/style.css +1 -1
  89. package/form-radio-group/index.mjs +41 -36
  90. package/form-radio-group/style.css +1 -1
  91. package/form-select/index.mjs +142 -75
  92. package/form-select/style.css +1 -0
  93. package/form-switch/index.mjs +29 -34
  94. package/form-table/index.mjs +85 -0
  95. package/form-table-plus/index.mjs +109 -0
  96. package/form-textarea/index.mjs +23 -35
  97. package/form-tree-select/index.mjs +72 -0
  98. package/form-tree-select/style.css +1 -0
  99. package/form-tree-select-multiple/index.mjs +78 -0
  100. package/form-view/index.mjs +43 -77
  101. package/form-view/style.css +1 -1
  102. package/fy-array/index.mjs +2 -2
  103. package/fy-cascader/index.mjs +1 -1
  104. package/fy-checkbox/index.mjs +1 -1
  105. package/fy-code/index.mjs +1 -1
  106. package/fy-curd/index.mjs +12 -17
  107. package/fy-curd/style.css +1 -1
  108. package/fy-date/index.mjs +1 -1
  109. package/fy-draggable/index.mjs +5 -7
  110. package/fy-draggable/style.css +1 -1
  111. package/fy-dynamic/index.mjs +14 -16
  112. package/fy-empty/index.mjs +1 -1
  113. package/fy-empty/style.css +1 -1
  114. package/fy-form/index.mjs +117 -136
  115. package/fy-form/style.css +1 -1
  116. package/fy-form-design/index.mjs +319 -345
  117. package/fy-form-design/style.css +1 -1
  118. package/fy-input/index.mjs +2 -2
  119. package/fy-input-color/index.mjs +1 -1
  120. package/fy-input-icon/index.mjs +1 -1
  121. package/fy-input-map/index.mjs +21 -26
  122. package/fy-input-map/style.css +1 -1
  123. package/fy-input-number/index.mjs +1 -1
  124. package/fy-input-table/index.mjs +10 -12
  125. package/fy-input-tree/index.mjs +1 -1
  126. package/fy-radio/index.mjs +1 -1
  127. package/fy-rate/index.mjs +1 -1
  128. package/fy-select/index.mjs +4 -4
  129. package/fy-slider/index.mjs +2 -2
  130. package/fy-switch/index.mjs +1 -1
  131. package/fy-tabs/index.mjs +0 -1
  132. package/fy-time/index.mjs +1 -1
  133. package/fy-title/index.mjs +1 -1
  134. package/fy-tree/index.mjs +1 -1
  135. package/fy-u-editor/index.mjs +77 -103
  136. package/fy-upload/index.mjs +3 -3
  137. package/fy-upload/style.css +1 -1
  138. package/highlight-j-s/index.mjs +1 -1
  139. package/highlight-j-s/style.css +1 -1
  140. package/image-cropper/index.mjs +14 -65
  141. package/image-preview/index.mjs +17 -45
  142. package/image-preview/style.css +1 -1
  143. package/image-viewer/style.css +1 -1
  144. package/index.mjs +666 -496
  145. package/input-number/index.mjs +64 -9
  146. package/keyboard/style.css +1 -1
  147. package/license/index.mjs +1 -1
  148. package/login/index.mjs +1 -1
  149. package/monaco-editor/index.mjs +44 -74
  150. package/name-avatar/style.css +1 -1
  151. package/package.json +18 -17
  152. package/page-index/index.mjs +30 -54
  153. package/page-index-top/index.mjs +25 -47
  154. package/pageable-table/index.mjs +354 -226
  155. package/pageable-table/style.css +1 -1
  156. package/pageable-view/index.mjs +63 -106
  157. package/photo-swipe/index.mjs +51 -74
  158. package/picker-table-view/index.mjs +117 -0
  159. package/present-view/index.mjs +43 -77
  160. package/present-view/style.css +1 -1
  161. package/record-video/index.mjs +1 -1
  162. package/resize-observer/index.mjs +1 -1
  163. package/resize-observer/style.css +1 -1
  164. package/search/index.mjs +2 -2
  165. package/search/style.css +1 -1
  166. package/search-popover/index.mjs +28 -48
  167. package/search-popover/style.css +1 -1
  168. package/sign/index.mjs +2 -2
  169. package/sign-panel/style.css +1 -1
  170. package/skeleton-panel/index.mjs +38 -0
  171. package/skeleton-panel/style.css +1 -0
  172. package/split-pane/index.mjs +31 -49
  173. package/split-pane/style.css +1 -1
  174. package/sub-table/index.mjs +206 -0
  175. package/sub-table/style.css +1 -0
  176. package/sub-table-plus/index.mjs +231 -0
  177. package/sub-table-plus/style.css +1 -0
  178. package/swiper/index.mjs +18 -38
  179. package/swiper/style.css +1 -1
  180. package/tab/index.mjs +1 -1
  181. package/tab/style.css +1 -1
  182. package/tab-item/index.mjs +2 -2
  183. package/table-column/index.mjs +112 -37
  184. package/table-column/style.css +1 -0
  185. package/table-view/index.mjs +178 -135
  186. package/table-view/style.css +1 -1
  187. package/tabs-view/index.mjs +104 -0
  188. package/tabs-view/style.css +1 -0
  189. package/tag-render/index.mjs +13 -24
  190. package/text-ellipsis/index.mjs +1 -1
  191. package/toolbar/index.mjs +115 -58
  192. package/toolbar/style.css +1 -1
  193. package/toolbar-button/index.mjs +92 -48
  194. package/verify/index.mjs +1 -1
  195. package/vue-cron/index.mjs +48 -66
  196. package/vue-qr-code/index.mjs +14 -32
  197. package/vue-quill-editor/index.mjs +3 -3
  198. package/vue-tags-input/index.mjs +1 -1
  199. package/vue-tree-select/index.mjs +352 -393
  200. package/vue-tree-select/style.css +1 -1
  201. package/vue-video-player/index.mjs +36 -67
  202. package/watermark/index.mjs +21 -31
  203. package/web-types.json +9240 -3843
  204. package/x-input-tag/index.mjs +29 -61
  205. package/chunks/confirmable-mixin.D4LAArE5.mjs +0 -114
  206. package/chunks/form-input-mixin.BkKiqJhi.mjs +0 -24
  207. package/chunks/form-item-mixin.CG4ZwzMC.mjs +0 -140
  208. package/chunks/input-number-mixin.CzjtGf2n.mjs +0 -60
  209. package/chunks/utilSelf.CRqpl0Cz.mjs +0 -56
  210. package/toolbar-button/style.css +0 -1
  211. /package/chunks/{form-pick-mixin.BFTIVn_i.mjs → form-pick.BFTIVn_i.mjs} +0 -0
@@ -1,41 +1,25 @@
1
- var l = (e, t, s) => new Promise((o, i) => {
2
- var n = (r) => {
3
- try {
4
- a(s.next(r));
5
- } catch (f) {
6
- i(f);
7
- }
8
- }, c = (r) => {
9
- try {
10
- a(s.throw(r));
11
- } catch (f) {
12
- i(f);
13
- }
14
- }, a = (r) => r.done ? o(r.value) : Promise.resolve(r.value).then(n, c);
15
- a((s = s.apply(e, t)).next());
16
- });
17
- import { n as u } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
18
- import d from "../resize-observer/index.mjs";
1
+ import { n as f } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
2
+ import l from "../resize-observer/index.mjs";
19
3
  import "../resize-observer/style.css";
20
- function g(e, t) {
4
+ function h(e, t) {
21
5
  for (let s = 0; s < t.length; s++)
22
6
  if (e === t[s])
23
7
  return !0;
24
8
  return !1;
25
9
  }
26
- const h = function() {
10
+ const n = (function() {
27
11
  return document.addEventListener ? function(e, t, s) {
28
12
  e && t && s && e.addEventListener(t, s, !1);
29
13
  } : function(e, t, s) {
30
14
  e && t && s && e.attachEvent(`on${t}`, s);
31
15
  };
32
- }(), p = function() {
16
+ })(), a = (function() {
33
17
  return document.removeEventListener ? function(e, t, s) {
34
18
  e && t && e.removeEventListener(t, s, !1);
35
19
  } : function(e, t, s) {
36
20
  e && t && e.detachEvent(`on${t}`, s);
37
21
  };
38
- }(), m = {
22
+ })(), p = {
39
23
  name: "Trigger",
40
24
  props: {
41
25
  mode: String,
@@ -66,27 +50,27 @@ const h = function() {
66
50
  }
67
51
  }
68
52
  };
69
- var v = function() {
53
+ var u = function() {
70
54
  var t = this, s = t._self._c;
71
55
  return s("div", { class: t.classes }, [t.showIcon ? s("div", { class: t.barConClasses }, t._m(0), 0) : t._e()]);
72
- }, x = [function() {
56
+ }, c = [function() {
73
57
  var e = this, t = e._self._c;
74
58
  return e._l(8, function(s) {
75
59
  return t("i", { key: `trigger-${s}`, class: `${e.prefix}-bar` });
76
60
  });
77
- }], $ = /* @__PURE__ */ u(
78
- m,
79
- v,
80
- x,
61
+ }], d = /* @__PURE__ */ f(
62
+ p,
63
+ u,
64
+ c,
81
65
  !1,
82
66
  null,
83
67
  null
84
68
  );
85
- const _ = $.exports, z = {
69
+ const g = d.exports, m = {
86
70
  name: "SplitPane",
87
71
  components: {
88
- Trigger: _,
89
- ResizeObserver: d
72
+ Trigger: g,
73
+ ResizeObserver: l
90
74
  },
91
75
  props: {
92
76
  value: {
@@ -95,7 +79,7 @@ const _ = $.exports, z = {
95
79
  },
96
80
  mode: {
97
81
  validator(e) {
98
- return g(e, ["horizontal", "vertical"]);
82
+ return h(e, ["horizontal", "vertical"]);
99
83
  },
100
84
  default: "horizontal"
101
85
  },
@@ -153,10 +137,8 @@ const _ = $.exports, z = {
153
137
  watch: {
154
138
  value: "resetOffset"
155
139
  },
156
- mounted() {
157
- return l(this, null, function* () {
158
- yield this.$nextTick(), this.resetOffset();
159
- });
140
+ async mounted() {
141
+ await this.$nextTick(), this.resetOffset();
160
142
  },
161
143
  methods: {
162
144
  resetOffset() {
@@ -180,35 +162,35 @@ const _ = $.exports, z = {
180
162
  return this.valueIsPx ? t = `${this.$refs.outerWrapper[this.offsetSize] - parseFloat(e)}px` : t = 1 - e, t;
181
163
  },
182
164
  handleMove(e) {
183
- const s = (this.isHorizontal ? e.pageX : e.pageY) - this.initOffset, o = this.$refs.outerWrapper[this.offsetSize];
184
- let i = this.valueIsPx ? `${parseFloat(this.oldOffset) + s}px` : this.px2percent(o * this.oldOffset + s, o);
185
- const n = this.getAnotherOffset(i);
186
- parseFloat(i) <= parseFloat(this.computedMin) && (i = this.getMax(i, this.computedMin)), parseFloat(n) <= parseFloat(this.computedMax) && (i = this.getAnotherOffset(this.getMax(n, this.computedMax))), e.atMin = this.value === this.computedMin, e.atMax = this.valueIsPx ? this.getAnotherOffset(this.value) === this.computedMax : this.getAnotherOffset(this.value).toFixed(5) === this.computedMax.toFixed(5), this.$emit("input", i), this.$emit("on-moving", e);
165
+ const s = (this.isHorizontal ? e.pageX : e.pageY) - this.initOffset, r = this.$refs.outerWrapper[this.offsetSize];
166
+ let i = this.valueIsPx ? `${parseFloat(this.oldOffset) + s}px` : this.px2percent(r * this.oldOffset + s, r);
167
+ const o = this.getAnotherOffset(i);
168
+ parseFloat(i) <= parseFloat(this.computedMin) && (i = this.getMax(i, this.computedMin)), parseFloat(o) <= parseFloat(this.computedMax) && (i = this.getAnotherOffset(this.getMax(o, this.computedMax))), e.atMin = this.value === this.computedMin, e.atMax = this.valueIsPx ? this.getAnotherOffset(this.value) === this.computedMax : this.getAnotherOffset(this.value).toFixed(5) === this.computedMax.toFixed(5), this.$emit("input", i), this.$emit("on-moving", e);
187
169
  },
188
170
  handleUp() {
189
- this.isMoving = !1, p(window, "mousemove", this.handleMove), p(window, "mouseup", this.handleUp), this.$emit("on-move-end");
171
+ this.isMoving = !1, a(window, "mousemove", this.handleMove), a(window, "mouseup", this.handleUp), this.$emit("on-move-end");
190
172
  },
191
173
  handleMousedown(e) {
192
- this.initOffset = this.isHorizontal ? e.pageX : e.pageY, this.oldOffset = this.value, this.isMoving = !0, h(window, "mousemove", this.handleMove), h(window, "mouseup", this.handleUp), this.$emit("on-move-start");
174
+ this.initOffset = this.isHorizontal ? e.pageX : e.pageY, this.oldOffset = this.value, this.isMoving = !0, n(window, "mousemove", this.handleMove), n(window, "mouseup", this.handleUp), this.$emit("on-move-start");
193
175
  }
194
176
  }
195
177
  };
196
- var M = function() {
178
+ var v = function() {
197
179
  var t = this, s = t._self._c;
198
180
  return s("div", { ref: "outerWrapper", class: t.wrapperClasses }, [t.isHorizontal ? s("div", { class: `${t.prefix}-horizontal` }, [t.hideLeft ? s("div", { class: [`${t.prefix}-pane`, "right-pane"], staticStyle: { left: "0" } }, [t._t("right")], 2) : [s("div", { class: [`${t.prefix}-pane`, "left-pane"], style: { right: `${t.anotherOffset}%` } }, [t._t("left")], 2), s("div", { class: `${t.prefix}-trigger-con`, style: { left: `calc(${t.offset}% + ${t.triggerSize / 2}px)`, width: `${t.triggerSize}px` }, on: { mousedown: t.handleMousedown } }, [t._t("trigger", function() {
199
181
  return [s("Trigger", { attrs: { mode: "vertical" } })];
200
182
  })], 2), s("div", { class: [`${t.prefix}-pane`, "right-pane"], style: { left: `calc(${t.offset}% + ${t.triggerSize}px)` } }, [t._t("right")], 2)]], 2) : s("div", { class: `${t.prefix}-vertical` }, [s("div", { class: [`${t.prefix}-pane`, "top-pane"], style: { bottom: `${t.anotherOffset}%` } }, [t._t("top")], 2), s("div", { class: `${t.prefix}-trigger-con`, style: { top: `calc(${t.offset}% + ${t.triggerSize / 2}px)`, height: `${t.triggerSize}px` }, on: { mousedown: t.handleMousedown } }, [t._t("trigger", function() {
201
183
  return [s("Trigger", { attrs: { mode: "horizontal" } })];
202
184
  })], 2), s("div", { class: [`${t.prefix}-pane`, "bottom-pane"], style: { top: `calc(${t.offset}% + ${t.triggerSize}px)` } }, [t._t("bottom")], 2)]), s("ResizeObserver", { on: { notify: t.resetOffset } })], 1);
203
- }, O = [], w = /* @__PURE__ */ u(
204
- z,
205
- M,
206
- O,
185
+ }, x = [], $ = /* @__PURE__ */ f(
186
+ m,
187
+ v,
188
+ x,
207
189
  !1,
208
190
  null,
209
191
  null
210
192
  );
211
- const C = w.exports;
193
+ const O = $.exports;
212
194
  export {
213
- C as default
195
+ O as default
214
196
  };
@@ -1 +1 @@
1
- .egd-split-wrapper{width:100%;height:100%;position:relative}.egd-split-pane{position:absolute}.egd-split-pane.left-pane,.egd-split-pane.right-pane{top:0;bottom:0}.egd-split-pane.left-pane{left:0}.egd-split-pane.right-pane{right:0}.egd-split-pane.top-pane,.egd-split-pane.bottom-pane{left:0;right:0}.egd-split-pane.top-pane{top:0}.egd-split-pane.bottom-pane{bottom:0}.egd-split-trigger-con{z-index:10;position:absolute;transform:translate(-50%,-50%)}.egd-split-trigger-bar-con{position:absolute;overflow:hidden}.egd-split-trigger-bar-con.vertical{height:32px;top:50%;left:1px;transform:translateY(-50%)}.egd-split-trigger-bar-con.horizontal{width:32px;top:1px;left:50%;transform:translate(-50%)}.egd-split-trigger-vertical{cursor:ew-resize;background:#f8f8f9;width:6px;height:100%;box-shadow:0 0 4px rgba(28,36,56,.4)}.egd-split-trigger-vertical .egd-split-trigger-bar{float:left;background:rgba(23,35,61,.25);width:4px;height:1px;margin-top:3px}.egd-split-trigger-horizontal{cursor:ns-resize;background:#f8f8f9;width:100%;height:6px;box-shadow:0 0 4px rgba(28,36,56,.4)}.egd-split-trigger-horizontal .egd-split-trigger-bar{float:left;background:rgba(23,35,61,.25);width:1px;height:4px;margin-right:3px}.egd-split-horizontal .egd-split-trigger-con{border-right:1px solid #d7dae0;height:100%;top:50%}.egd-split-vertical .egd-split-trigger-con{border-bottom:1px solid #d7dae0;width:100%;left:50%}.egd-split-trigger-vertical-line,.egd-split-trigger-horizontal-line{box-shadow:none;background-color:transparent}.egd-split .no-select{-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}
1
+ .egd-split-wrapper{width:100%;height:100%;position:relative}.egd-split-pane{position:absolute}.egd-split-pane.left-pane,.egd-split-pane.right-pane{top:0;bottom:0}.egd-split-pane.left-pane{left:0}.egd-split-pane.right-pane{right:0}.egd-split-pane.top-pane,.egd-split-pane.bottom-pane{left:0;right:0}.egd-split-pane.top-pane{top:0}.egd-split-pane.bottom-pane{bottom:0}.egd-split-trigger-con{z-index:10;position:absolute;transform:translate(-50%,-50%)}.egd-split-trigger-bar-con{position:absolute;overflow:hidden}.egd-split-trigger-bar-con.vertical{height:32px;top:50%;left:1px;transform:translateY(-50%)}.egd-split-trigger-bar-con.horizontal{width:32px;top:1px;left:50%;transform:translate(-50%)}.egd-split-trigger-vertical{cursor:ew-resize;background:#f8f8f9;width:6px;height:100%;box-shadow:0 0 4px #1c243866}.egd-split-trigger-vertical .egd-split-trigger-bar{float:left;background:#17233d40;width:4px;height:1px;margin-top:3px}.egd-split-trigger-horizontal{cursor:ns-resize;background:#f8f8f9;width:100%;height:6px;box-shadow:0 0 4px #1c243866}.egd-split-trigger-horizontal .egd-split-trigger-bar{float:left;background:#17233d40;width:1px;height:4px;margin-right:3px}.egd-split-horizontal .egd-split-trigger-con{border-right:1px solid #d7dae0;height:100%;top:50%}.egd-split-vertical .egd-split-trigger-con{border-bottom:1px solid #d7dae0;width:100%;left:50%}.egd-split-trigger-vertical-line,.egd-split-trigger-horizontal-line{box-shadow:none;background-color:#0000}.egd-split .no-select{-webkit-touch-callout:none;-webkit-user-select:none;user-select:none}
@@ -0,0 +1,206 @@
1
+ import { findTreeChildren as u, isFunction as d } from "@web-utils/core";
2
+ import { cloneDeep as i } from "@web-utils/integrations/lodash";
3
+ import { n as b } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
4
+ const c = {
5
+ name: "SubTable",
6
+ emits: ["add-row"],
7
+ inject: {
8
+ elForm: {
9
+ default: ""
10
+ },
11
+ elFormItem: {
12
+ default: ""
13
+ }
14
+ },
15
+ props: {
16
+ value: Array,
17
+ prop: String,
18
+ columns: Array,
19
+ limit: {
20
+ type: Number,
21
+ default: 1 / 0
22
+ },
23
+ maxLimit: {
24
+ type: Number,
25
+ default: 1 / 0
26
+ },
27
+ disabled: Boolean,
28
+ showSummary: Boolean,
29
+ selectionWidth: String,
30
+ allowEmpty: Boolean,
31
+ handleColumn: {
32
+ type: Boolean,
33
+ default: !0
34
+ },
35
+ editable: Boolean,
36
+ fetchApi: Function,
37
+ delApi: Function,
38
+ showHandleColumnAddButton: {
39
+ type: Boolean,
40
+ default: !0
41
+ },
42
+ showEmptyAddButton: {
43
+ type: Boolean,
44
+ default: !0
45
+ }
46
+ },
47
+ data() {
48
+ return {
49
+ rows: [],
50
+ selectedRows: []
51
+ };
52
+ },
53
+ computed: {
54
+ available() {
55
+ return this.editable && this.enabled;
56
+ },
57
+ enabled() {
58
+ return !this.disabled;
59
+ },
60
+ rowProps() {
61
+ const n = {};
62
+ return this.columns && this.columns.map((e) => e.prop).forEach((e) => {
63
+ n[e] = null;
64
+ }), n;
65
+ },
66
+ inputDisabled() {
67
+ return this.disabled || (this.elForm || {}).disabled;
68
+ }
69
+ },
70
+ watch: {
71
+ value: {
72
+ deep: !0,
73
+ immediate: !0,
74
+ handler(n) {
75
+ this.rows = n || [];
76
+ }
77
+ },
78
+ rows: {
79
+ deep: !0,
80
+ immediate: !0,
81
+ handler(n) {
82
+ this.$emit("input", n);
83
+ }
84
+ }
85
+ },
86
+ methods: {
87
+ getCellType(n, e) {
88
+ return d(e.getType) ? e.getType(n, e) : e.type;
89
+ },
90
+ getInputAttr(n, e) {
91
+ return { ...e.attrs, ...e.getAttrs ? e.getAttrs(n) : {} };
92
+ },
93
+ isInputDisabled(n, e) {
94
+ return e.isDisabled && e.isDisabled(n);
95
+ },
96
+ onInput(n, e, a) {
97
+ a.setValue ? a.setValue(n, e, a, this.rows) : n[a.prop] = e;
98
+ },
99
+ onSelectionChange(n) {
100
+ this.selectedRows = n;
101
+ },
102
+ remove(n, e) {
103
+ try {
104
+ this.rows.splice(e, 1);
105
+ } catch {
106
+ }
107
+ },
108
+ add(n, e) {
109
+ const a = i(this.rowProps);
110
+ this.rows.splice(e + 1, 0, a);
111
+ },
112
+ addRow() {
113
+ this.$emit("add-row");
114
+ },
115
+ async delRow() {
116
+ if (!this.selectedRows.length) {
117
+ this.$message.warning("请选择要删除的记录!");
118
+ return;
119
+ }
120
+ try {
121
+ if (this.delApi)
122
+ try {
123
+ await this.delApi(this.selectedRows.map((n) => n.id).join(",")), this.refresh();
124
+ } catch {
125
+ this.$message.error("删除失败!");
126
+ }
127
+ else
128
+ this.$emit(
129
+ "input",
130
+ this.rows.filter((n) => !this.selectedRows.includes(n))
131
+ );
132
+ this.$message.success("删除成功!");
133
+ } catch {
134
+ }
135
+ },
136
+ refresh() {
137
+ this.$refs.table.getPage();
138
+ },
139
+ getVal(n, e, a) {
140
+ var t, r;
141
+ if (a.type === "select" && ((t = a.attrs) != null && t.options)) {
142
+ const s = a.attrs.options.find((p) => p.code === n[e.property]);
143
+ if (s)
144
+ return s.name;
145
+ }
146
+ if (a.type === "cascader" && ((r = a.attrs) != null && r.options)) {
147
+ const [s] = u(a.attrs.options, (p) => p[a.attrs.valueKey || "value"] === n[e.property]);
148
+ if (s)
149
+ return s[a.attrs.valueKey || "label"];
150
+ }
151
+ return n[e.property];
152
+ }
153
+ }
154
+ };
155
+ var h = function() {
156
+ var e = this, a = e._self._c;
157
+ return a("PageableTable", e._g(e._b({ ref: "table", staticClass: "sub-table", attrs: { "auto-height": "", data: e.rows, api: e.fetchApi, "show-summary": e.showSummary, "selection-width": e.selectionWidth, "hide-on-single-page": "", selection: e.enabled }, on: { "selection-change": e.onSelectionChange }, scopedSlots: e._u([e.editable ? null : { key: "toolbar", fn: function() {
158
+ return [e.enabled || e.fetchApi ? a("div", { staticClass: "table-header" }, [e._t("toolbar", function() {
159
+ return [e.enabled ? [a("ElButton", { staticClass: "table-header-button add", attrs: { size: "mini", icon: "el-icon-circle-plus", type: "text" }, on: { click: e.addRow } }, [e._v("添加")]), a("ConfirmButton", { staticClass: "table-header-button remove", attrs: { size: "mini", message: "您确定要删除选中的记录吗?", icon: "el-icon-error", type: "text" }, on: { click: e.delRow } }, [e._v(" 删除 ")])] : e._e(), e.fetchApi ? a("ElButton", { staticClass: "table-header-button refresh", attrs: { size: "mini", icon: "el-icon-refresh-left", type: "text", disabled: !1 }, on: { click: e.refresh } }, [e._v(" 刷新 ")]) : e._e()];
160
+ }, { addRow: e.addRow, delRow: e.delRow, refresh: e.refresh })], 2) : e._e()];
161
+ }, proxy: !0 }, e.allowEmpty && !e.inputDisabled && e.showEmptyAddButton ? { key: "empty", fn: function() {
162
+ return [a("i", { staticClass: "el-icon-circle-plus sub-table-handle-button table-button-add", staticStyle: { "font-size": "20px", cursor: "pointer" }, attrs: { title: "添加" }, on: { click: function(t) {
163
+ return t.stopPropagation(), e.add(null, 0);
164
+ } } })];
165
+ }, proxy: !0 } : null], null, !0) }, "PageableTable", e.$attrs, !1), e.$listeners), [e._t("columns", function() {
166
+ return [e._l(e.columns, function(t) {
167
+ return [t.label && !t.hide && !t.slot ? a("TableColumn", { key: `${t.prop}-${e.enabled}-${t.type}`, attrs: { label: t.label, width: t.width, align: t.align, prop: t.prop, options: t.options, "show-overflow-tooltip": !e.available && t.showOverflowTooltip }, scopedSlots: e._u([{ key: "header", fn: function() {
168
+ return [!e.inputDisabled && t.required ? a("span", { staticStyle: { color: "#f56c6c" } }, [e._v("*")]) : e._e(), e._v(" " + e._s(t.label) + " ")];
169
+ }, proxy: !0 }, { key: "default", fn: function({ row: r, column: s, $index: p }) {
170
+ return [e._t("tag", null, { row: r, column: s, index: p }), e._t(t.prop, function() {
171
+ var o;
172
+ return [e.available && e.getCellType(r, t) === "input" ? [a("FormInput", e._b({ attrs: { value: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, required: t.required }, on: { input: (l) => e.onInput(r, l, t) } }, "FormInput", e.getInputAttr(r, t), !1))] : e.available && e.getCellType(r, t) === "inputPhoneNumber" ? [a("FormInputPhoneNumber", e._b({ attrs: { value: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, required: t.required }, on: { input: (l) => e.onInput(r, l, t) } }, "FormInputPhoneNumber", e.getInputAttr(r, t), !1))] : e.available && e.getCellType(r, t) === "user" ? [t.single ? a("FormInputUser", e._b({ attrs: { name: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, required: t.required }, on: { "update:name": function(l) {
173
+ return e.$set(r, s.property, l);
174
+ }, input: (l) => e.onInput(r, l, t) } }, "FormInputUser", e.getInputAttr(r, t), !1)) : a("FormInputUser", e._b({ attrs: { value: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, required: t.required }, on: { input: (l) => e.onInput(r, l, t) } }, "FormInputUser", e.getInputAttr(r, t), !1))] : e.available && e.getCellType(r, t) === "department" ? [t.single ? a("FormInputDepartment", e._b({ attrs: { "ou-type": t.ouType, name: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, required: t.required }, on: { "update:name": function(l) {
175
+ return e.$set(r, s.property, l);
176
+ }, input: (l) => e.onInput(r, l, t) } }, "FormInputDepartment", e.getInputAttr(r, t), !1)) : a("FormInputDepartment", e._b({ attrs: { value: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, required: t.required }, on: { input: (l) => e.onInput(r, l, t) } }, "FormInputDepartment", e.getInputAttr(r, t), !1))] : e.available && e.getCellType(r, t) === "select" ? [a("FormSelect", e._b({ attrs: { value: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, options: t.options, required: t.required }, on: { input: (l) => e.onInput(r, l, t) } }, "FormSelect", e.getInputAttr(r, t), !1))] : e.available && e.getCellType(r, t) === "datePicker" ? [a("FormDatePicker", e._b({ attrs: { value: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, required: t.required, start: r[t.start], end: r[t.end] }, on: { "update:start": function(l) {
177
+ return e.$set(r, t.start, l);
178
+ }, "update:end": function(l) {
179
+ return e.$set(r, t.end, l);
180
+ }, input: (l) => e.onInput(r, l, t) } }, "FormDatePicker", e.getInputAttr(r, t), !1))] : e.available && e.getCellType(r, t) === "cascader" ? [a("FormCascader", e._b({ attrs: { value: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, required: t.required, "label-key": t.labelKey, "value-key": t.valueKey }, on: { input: (l) => e.onInput(r, l, t) } }, "FormCascader", e.getInputAttr(r, t), !1))] : e.available && e.getCellType(r, t) === "checkbox" ? [a("FormCheckboxGroup", e._b({ attrs: { value: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, required: t.required }, on: { input: (l) => e.onInput(r, l, t) } }, "FormCheckboxGroup", e.getInputAttr(r, t), !1))] : e.available && e.getCellType(r, t) === "number" ? [a("FormInputNumber", e._b({ attrs: { value: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, required: t.required }, on: { input: (l) => e.onInput(r, l, t) } }, "FormInputNumber", e.getInputAttr(r, t), !1))] : e.available && e.getCellType(r, t) === "textarea" ? [a("FormTextarea", e._b({ attrs: { rows: t.rows || "3", value: r[s.property], disabled: e.isInputDisabled(r, t), prop: `${e.prop}[${p}].${t.prop}`, required: t.required }, on: { input: (l) => e.onInput(r, l, t) } }, "FormTextarea", e.getInputAttr(r, t), !1))] : t.dicType || (o = t.options) != null && o.length ? [a("DictRender", { attrs: { "dict-type": t.dicType, "id-as-value": t.idAsValue, "label-as-value": t.labelAsValue, column: s, row: r, options: t.options } })] : [e._v(e._s(e.getVal(r, s, t)))]];
181
+ }, { row: r, column: s, index: p })];
182
+ } }], null, !0) }) : t.slot ? e._t("default") : e._e()];
183
+ })];
184
+ }, { columns: e.columns }), e._t("handle", null, { add: e.add, remove: e.remove }), (!e.value || e.value.length < e.limit) && !e.inputDisabled && e.enabled && e.editable && e.handleColumn ? a("TableColumn", { attrs: { label: "操作", fixed: "right", width: "80", align: "center", prop: "menu" }, scopedSlots: e._u([{ key: "header", fn: function({ column: t, $index: r }) {
185
+ return [e._t("handle-column-header", function() {
186
+ return [e._v(" " + e._s(t.label) + " ")];
187
+ }, { column: t, index: r })];
188
+ } }, { key: "default", fn: function({ row: t, $index: r }) {
189
+ return [e.showHandleColumnAddButton && e.value.length < e.maxLimit ? a("i", { staticClass: "el-icon-circle-plus sub-table-handle-button table-button-add", staticStyle: { "margin-right": "5px", "font-size": "20px", cursor: "pointer" }, attrs: { title: "添加" }, on: { click: function(s) {
190
+ return s.stopPropagation(), e.add(t, r);
191
+ } } }) : e._e(), e.value && e.value.length > 1 || e.allowEmpty ? a("Confirmable", { staticClass: "el-icon-error sub-table-handle-button table-button-remove", attrs: { title: "删除", message: "您确定要删除该行吗?" }, on: { click: function(s) {
192
+ return s.stopPropagation(), e.remove(t, r);
193
+ } } }) : e._e()];
194
+ } }], null, !0) }) : e._e()], 2);
195
+ }, f = [], y = /* @__PURE__ */ b(
196
+ c,
197
+ h,
198
+ f,
199
+ !1,
200
+ null,
201
+ null
202
+ );
203
+ const I = y.exports;
204
+ export {
205
+ I as default
206
+ };
@@ -0,0 +1 @@
1
+ .sub-table.pageable-table.auto-height .el-table{min-height:0}.sub-table .el-form-item{width:100%;margin-bottom:0}.sub-table .el-col{width:100%}.sub-table .table-header{background-color:#f3f5fb;border:1px solid #dfe6ec;border-bottom:none;padding:2px 10px}.sub-table .table-header-button:hover,.sub-table .table-header-button:focus{color:#595959}.sub-table .table-header-button i+span{margin-left:0}.sub-table .table-header-button i{font-size:15px}.sub-table .table-header-button.add i{color:#4886ec}.sub-table .table-header-button.remove i{color:#e34e55}.sub-table .table-header-button.refresh i{color:#1eb91e}.sub-table .table-button-add{color:#5add7a;opacity:.8}.sub-table .table-button-add:hover{opacity:1}.sub-table .table-button-remove{color:#ddd}.sub-table .table-button-remove:hover{color:#ef6666}.sub-table .el-table__header-wrapper .el-table__header th{background-color:#f3f5fb;padding:5px 0}.sub-table .el-table{border-top-color:#dde1e5}.sub-table .el-table td{border-color:#dfe6ec}.sub-table .el-col{padding:0!important}.sub-table .row-indicator{border:6px solid #0000;border-bottom-color:#f5690c;width:0;height:0;display:inline-block;position:absolute;top:-6px;right:-6px;transform:rotate(45deg)}.sub-table .sub-table-handle-button{cursor:pointer;font-size:20px}.sub-table .sub-table-handle-button+.sub-table-handle-button{margin-left:5px}.sub-table .el-table .el-table__header th{line-height:inherit;padding:5px 0;background:#f3f5fb!important}
@@ -0,0 +1,231 @@
1
+ import { findTreeChildren as i, isFunction as c } from "@web-utils/core";
2
+ import { cloneDeep as b } from "@web-utils/integrations/lodash";
3
+ import { S as h } from "../chunks/sub-table-plus-props.BVsD71hT.mjs";
4
+ import { n as f } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
5
+ const y = {
6
+ name: "SubTablePlus",
7
+ mixins: [h],
8
+ inject: {
9
+ elForm: {
10
+ default: ""
11
+ },
12
+ elFormItem: {
13
+ default: ""
14
+ }
15
+ },
16
+ props: {
17
+ onRowDbClick: Function,
18
+ showMessage: Boolean,
19
+ pageSize: Number
20
+ },
21
+ data() {
22
+ return {
23
+ rows: [],
24
+ selectedRows: []
25
+ };
26
+ },
27
+ computed: {
28
+ enabled() {
29
+ return !this.inputDisabled;
30
+ },
31
+ hasToolBarMenu() {
32
+ var s;
33
+ return (s = this.toolbarMenus) == null ? void 0 : s.length;
34
+ },
35
+ hasHandleMenus() {
36
+ var s;
37
+ return (s = this.handleMenus) == null ? void 0 : s.length;
38
+ },
39
+ rowProps() {
40
+ const s = {};
41
+ return this.columns && this.columns.map((e) => e.prop).forEach((e) => {
42
+ s[e] = null;
43
+ }), s;
44
+ },
45
+ inputDisabled() {
46
+ return this.disabled || (this.elForm || {}).disabled;
47
+ }
48
+ },
49
+ watch: {
50
+ value: {
51
+ deep: !0,
52
+ immediate: !0,
53
+ handler(s) {
54
+ this.rows = s || [];
55
+ }
56
+ },
57
+ rows: {
58
+ deep: !0,
59
+ immediate: !0,
60
+ handler(s) {
61
+ this.$emit("input", s);
62
+ }
63
+ }
64
+ },
65
+ methods: {
66
+ getCellType(s, e) {
67
+ return c(e.getType) ? e.getType(s, e) : e.type;
68
+ },
69
+ getInputAttr(s, e) {
70
+ return e.attrs && e.getAttrs ? { ...e.attrs, ...e.getAttrs(s) } : e.attrs ? e.attrs : e.getAttrs ? e.getAttrs(s) : {};
71
+ },
72
+ isInputDisabled(s, e) {
73
+ var l;
74
+ return (l = e.isDisabled) == null ? void 0 : l.call(e, s);
75
+ },
76
+ onInput(s, e, l) {
77
+ l.setValue ? l.setValue(s, e, l, this.rows) : l.setVal !== !1 && (s[l.prop] = e);
78
+ },
79
+ onBlur(s, e) {
80
+ e.onBlur && e.onBlur(s, e, this.rows);
81
+ },
82
+ onSelectionChange(s) {
83
+ this.selectedRows = s;
84
+ },
85
+ async remove(s, e) {
86
+ try {
87
+ if (this.delApi)
88
+ try {
89
+ await this.delApi([s.id]), this.$message.success("删除成功!"), this.refresh();
90
+ } catch {
91
+ this.$message.error("删除失败!");
92
+ }
93
+ else
94
+ this.rows.splice(e, 1);
95
+ } catch {
96
+ }
97
+ },
98
+ async add(s, e) {
99
+ var l;
100
+ if (this.fetchApi)
101
+ this.addRow();
102
+ else {
103
+ const o = b(this.rowProps), u = await ((l = this.initRow) == null ? void 0 : l.call(this, o, e));
104
+ e === -1 ? this.rows.push(u || o) : this.rows.splice(e + 1, 0, u || o);
105
+ }
106
+ },
107
+ addRow() {
108
+ this.$emit("add-row");
109
+ },
110
+ async delRow() {
111
+ if (!this.selectedRows.length) {
112
+ this.$message.warning("请选择要删除的记录!");
113
+ return;
114
+ }
115
+ try {
116
+ if (this.delApi)
117
+ try {
118
+ await this.delApi(this.selectedRows.map((s) => s.id)), this.$message.success("删除成功!"), this.refresh();
119
+ } catch {
120
+ this.$message.error("删除失败!");
121
+ }
122
+ else
123
+ this.$emit(
124
+ "input",
125
+ this.rows.filter((s) => !this.selectedRows.includes(s))
126
+ );
127
+ } catch {
128
+ }
129
+ },
130
+ refresh() {
131
+ this.$refs.table.getPage();
132
+ },
133
+ getVal(s, e, l) {
134
+ var o, u;
135
+ if (l.type === "select" && ((o = l.attrs) != null && o.options)) {
136
+ const t = l.attrs.options.find((r) => r.value === s[e.property] || r.code === s[e.property]);
137
+ if (t)
138
+ return t.label || t.name;
139
+ }
140
+ if (l.type === "checkbox1")
141
+ return s[e.property] === !0 || s[e.property] === "1" || s[e.property] === "Y" ? "是" : "否";
142
+ if (l.type === "cascader" && ((u = l.attrs) != null && u.options)) {
143
+ const [t] = i(l.attrs.options, (r) => r[l.attrs.valueKey || "value"] === s[e.property]);
144
+ if (t)
145
+ return t[l.attrs.valueKey || "label"];
146
+ }
147
+ return s[e.property];
148
+ },
149
+ reloadTable() {
150
+ var s;
151
+ (s = this.$refs.table) == null || s.reload();
152
+ },
153
+ async refreshTable() {
154
+ var s;
155
+ await ((s = this.$refs.table) == null ? void 0 : s.getPage());
156
+ },
157
+ removeSelectedRows() {
158
+ this.$emit(
159
+ "input",
160
+ this.value.filter((s) => !this.selectedRows.includes(s))
161
+ );
162
+ },
163
+ rowDbClick(...s) {
164
+ var e;
165
+ (e = this.onRowDbClick) == null || e.call(this, ...s);
166
+ }
167
+ }
168
+ };
169
+ var g = function() {
170
+ var o, u;
171
+ var e = this, l = e._self._c;
172
+ return l("div", { class: ["sub-table-plus", { "hide-message": !e.showMessage }] }, [l("PageableTable", e._g(e._b({ ref: "table", attrs: { "auto-height": "", data: e.fetchApi ? !1 : e.rows, api: e.fetchApi, "payload-style": "body", "show-summary": e.showSummary, descs: e.descs, ascs: e.ascs, "page-size": e.pageSize, "selection-width": e.selectionWidth, "hide-on-single-page": "", selection: e.selection, index: e.index }, on: { "selection-change": e.onSelectionChange }, scopedSlots: e._u([!e.inputDisabled || e.hasToolBarMenu ? { key: "toolbar", fn: function() {
173
+ return [l("div", { staticClass: "table-header flex-row" }, [e._t("toolbar", function() {
174
+ return [l("div", { staticClass: "flex-item" }, [e._t("toolbar-left", function() {
175
+ var t, r, n;
176
+ return [(t = e.toolbarMenus) != null && t.includes("add") ? l("ElButton", { staticClass: "table-header-button add", attrs: { size: "mini", icon: "el-icon-circle-plus", type: "text" }, on: { click: e.addRow } }, [e._v(" 添加 ")]) : e._e(), (r = e.toolbarMenus) != null && r.includes("delete") ? l("ConfirmButton", { staticClass: "table-header-button remove", attrs: { size: "mini", disabled: e.selectedRows.length <= 0, message: "您确定要删除选中的记录吗?", icon: "el-icon-error", type: "text" }, on: { click: e.delRow } }, [e._v(" 删除 ")]) : e._e(), (n = e.toolbarMenus) != null && n.includes("refresh") ? l("ElButton", { staticClass: "table-header-button refresh", attrs: { size: "mini", icon: "el-icon-refresh-left", type: "text", disabled: !1 }, on: { click: e.refresh } }, [e._v(" 刷新 ")]) : e._e()];
177
+ }, { addRow: e.addRow, delRow: e.delRow, refresh: e.refresh }), e._t("toolbar-left-append", null, { addRow: e.addRow, delRow: e.delRow, refresh: e.refresh })], 2), l("div", { staticClass: "flex-not-shrink" }, [e._t("toolbar-right", null, { removeSelectedRows: e.removeSelectedRows, selectedRows: e.selectedRows })], 2)];
178
+ }, { addRow: e.addRow, delRow: e.delRow, refresh: e.refresh })], 2)];
179
+ }, proxy: !0 } : null, e.bottomAddButton ? { key: "empty", fn: function() {
180
+ return [l("i", { staticClass: "el-icon-circle-plus sub-table-handle-button table-button-add", staticStyle: { "font-size": "20px", cursor: "pointer" }, attrs: { title: "添加" }, on: { click: function(t) {
181
+ var r;
182
+ return t.stopPropagation(), e.add(null, ((r = e.value) == null ? void 0 : r.length) ?? 0);
183
+ } } })];
184
+ }, proxy: !0 } : null], null, !0) }, "PageableTable", e.$attrs, !1), e.$listeners), [e._t("columns", function() {
185
+ return [e._l(e.columns, function(t) {
186
+ return [t.label && !t.hide && !t.slot ? l("TableColumn", { key: `${t.prop}-${e.enabled}${t.type ? `-${t.type}` : ""}${t.required ? `-${t.required}` : ""}`, attrs: { label: t.label, width: t.width, "dict-type": t.dictType, clickable: t.clickable, align: t.align, prop: t.prop, options: t.options, "show-overflow-tooltip": !t.editable && t.showOverflowTooltip }, scopedSlots: e._u([{ key: "header", fn: function() {
187
+ return [!e.inputDisabled && t.required ? l("span", { staticStyle: { color: "#f56c6c" } }, [e._v("*")]) : e._e(), l("span", { attrs: { title: t.label } }, [e._v(e._s(t.label))])];
188
+ }, proxy: !0 }, { key: "default", fn: function({ row: r, column: n, $index: p }) {
189
+ return [e._t("tag", null, { row: r, column: n, index: p }), e._t(t.prop, function() {
190
+ var d;
191
+ return [e.enabled && t.editable === !0 ? [e.getCellType(r, t) === "input" ? [l("FormInput", e._b({ attrs: { "wrap-col": !1, value: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required }, on: { blur: () => e.onBlur(r, t), input: (a) => e.onInput(r, a, t) } }, "FormInput", e.getInputAttr(r, t), !1))] : e.getCellType(r, t) === "checkbox1" ? [l("FormCheckbox", e._b({ attrs: { "wrap-col": !1, value: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required }, on: { input: (a) => e.onInput(r, a, t) } }, "FormCheckbox", e.getInputAttr(r, t), !1))] : e.getCellType(r, t) === "inputPhoneNumber" ? [l("FormInputPhoneNumber", e._b({ attrs: { "wrap-col": !1, value: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required }, on: { input: (a) => e.onInput(r, a, t) } }, "FormInputPhoneNumber", e.getInputAttr(r, t), !1))] : e.getCellType(r, t) === "user" ? [t.single ? l("FormInputUser", e._b({ attrs: { id: r[n.idProp || `${n.property}Id`], "wrap-col": !1, name: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required }, on: { "update:id": function(a) {
192
+ return e.$set(r, n.idProp || `${n.property}Id`, a);
193
+ }, "update:name": function(a) {
194
+ return e.$set(r, n.property, a);
195
+ }, input: (a) => e.onInput(r, a, t) } }, "FormInputUser", e.getInputAttr(r, t), !1)) : l("FormInputUser", e._b({ attrs: { "wrap-col": !1, value: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required }, on: { input: (a) => e.onInput(r, a, t) } }, "FormInputUser", e.getInputAttr(r, t), !1))] : e.getCellType(r, t) === "department" ? [t.single ? l("FormInputDepartment", e._b({ attrs: { "wrap-col": !1, "ou-type": t.ouType, name: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required }, on: { "update:name": function(a) {
196
+ return e.$set(r, n.property, a);
197
+ }, input: (a) => e.onInput(r, a, t) } }, "FormInputDepartment", e.getInputAttr(r, t), !1)) : l("FormInputDepartment", e._b({ attrs: { "wrap-col": !1, value: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required }, on: { input: (a) => e.onInput(r, a, t) } }, "FormInputDepartment", e.getInputAttr(r, t), !1))] : e.getCellType(r, t) === "select" ? [l("FormSelect", e._b({ attrs: { "wrap-col": !1, value: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required }, on: { input: (a) => e.onInput(r, a, t) } }, "FormSelect", e.getInputAttr(r, t), !1))] : e.getCellType(r, t) === "datePicker" ? [l("FormDatePicker", e._b({ attrs: { "wrap-col": !1, value: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required, start: r[t.start], end: r[t.end] }, on: { "update:start": function(a) {
198
+ return e.$set(r, t.start, a);
199
+ }, "update:end": function(a) {
200
+ return e.$set(r, t.end, a);
201
+ }, input: (a) => e.onInput(r, a, t) } }, "FormDatePicker", e.getInputAttr(r, t), !1))] : e.getCellType(r, t) === "cascader" ? [l("FormCascader", e._b({ attrs: { "wrap-col": !1, value: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required, "label-key": t.labelKey, "value-key": t.valueKey }, on: { input: (a) => e.onInput(r, a, t) } }, "FormCascader", e.getInputAttr(r, t), !1))] : e.getCellType(r, t) === "checkbox" ? [l("FormCheckboxGroup", e._b({ attrs: { "wrap-col": !1, value: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required }, on: { input: (a) => e.onInput(r, a, t) } }, "FormCheckboxGroup", e.getInputAttr(r, t), !1))] : e.getCellType(r, t) === "number" ? [l("FormInputNumber", e._b({ attrs: { "wrap-col": !1, value: r[n.property], disabled: e.isInputDisabled(r, t), prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required }, on: { input: (a) => e.onInput(r, a, t) } }, "FormInputNumber", e.getInputAttr(r, t), !1))] : e._e()] : t.dictType || (d = t.options) != null && d.length ? [l("DictRender", { attrs: { "dict-type": t.dictType, "id-as-value": t.idAsValue, "label-as-value": t.labelAsValue, column: n, row: r, options: t.options } })] : [e._v(e._s(e.getVal(r, n, t)))]];
202
+ }, { row: r, column: n, wrapCol: !1, index: p, prop: e.prop ? `${e.prop}[${p}].${t.prop}` : null, required: t.required, editable: t.editable })];
203
+ } }], null, !0) }) : t.slot ? e._t(t.slot) : e._e()];
204
+ })];
205
+ }, { columns: e.columns }), e._t("handle", null, { add: e.add, remove: e.remove }), !e.inputDisabled && e.hasHandleMenus ? l("TableColumn", { attrs: { label: "操作", width: "80", align: "center", prop: "menu" }, scopedSlots: e._u([{ key: "header", fn: function({ column: t, $index: r }) {
206
+ return [e._t("handle-column-header", function() {
207
+ return [e._v(" " + e._s(t.label) + " ")];
208
+ }, { column: t, index: r })];
209
+ } }, { key: "default", fn: function({ row: t, $index: r }) {
210
+ var n, p, d;
211
+ return [(n = e.handleMenus) != null && n.includes("add") && ((p = e.value) == null ? void 0 : p.length) < e.limit ? l("i", { staticClass: "el-icon-circle-plus sub-table-handle-button table-button-add", staticStyle: { "margin-right": "5px", "font-size": "20px", cursor: "pointer" }, attrs: { title: "添加" }, on: { click: function(a) {
212
+ return a.stopPropagation(), e.add(t, r);
213
+ } } }) : e._e(), (d = e.handleMenus) != null && d.includes("delete") ? l("Confirmable", { staticClass: "el-icon-error sub-table-handle-button table-button-remove", attrs: { title: "删除", message: "您确定要删除该行吗?" }, on: { click: function(a) {
214
+ return a.stopPropagation(), e.remove(t, r);
215
+ } } }) : e._e()];
216
+ } }], null, !0) }) : e._e()], 2), !e.inputDisabled && e.bottomAddButton && ((o = e.value) == null ? void 0 : o.length) < e.limit && ((u = e.value) == null ? void 0 : u.length) > 0 ? l("div", { staticClass: "flex-row vertical-center horizon-center", staticStyle: { padding: "10px", border: "1px solid #ebeef5", "border-top": "none" } }, [l("i", { staticClass: "el-icon-circle-plus sub-table-handle-button table-button-add", staticStyle: { "font-size": "20px", cursor: "pointer" }, attrs: { title: "添加" }, on: { click: function(t) {
217
+ var r;
218
+ return t.stopPropagation(), e.add(null, ((r = e.value) == null ? void 0 : r.length) ?? 0);
219
+ } } })]) : e._e()], 1);
220
+ }, _ = [], I = /* @__PURE__ */ f(
221
+ y,
222
+ g,
223
+ _,
224
+ !1,
225
+ null,
226
+ null
227
+ );
228
+ const k = I.exports;
229
+ export {
230
+ k as default
231
+ };
@@ -0,0 +1 @@
1
+ .sub-table-plus.hide-message .el-form-item__error{display:none}.sub-table-plus .pageable-table.auto-height .el-table{min-height:0}.sub-table-plus .el-form-item{width:100%;margin-bottom:0}.sub-table-plus .el-col{width:100%}.sub-table-plus .table-header{background-color:#f3f5fb;border:1px solid #dfe6ec;border-bottom:none;padding:2px 10px}.sub-table-plus .table-header-button:hover,.sub-table-plus .table-header-button:focus{color:#595959}.sub-table-plus .table-header-button i+span{margin-left:0}.sub-table-plus .table-header-button i{font-size:15px}.sub-table-plus .table-header-button.add i{color:#4886ec}.sub-table-plus .table-header-button.remove i{color:#e34e55}.sub-table-plus .table-header-button.refresh i{color:#1eb91e}.sub-table-plus .table-button-add{color:#5add7a;opacity:.8}.sub-table-plus .table-button-add:hover{opacity:1}.sub-table-plus .table-button-remove{color:#ddd}.sub-table-plus .table-button-remove:hover{color:#ef6666}.sub-table-plus .el-table__header-wrapper .el-table__header th{background-color:#f3f5fb;padding:5px 0}.sub-table-plus .el-table{border-top-color:#dde1e5}.sub-table-plus .el-table td{border-color:#dfe6ec}.sub-table-plus .el-col{padding:0!important}.sub-table-plus .row-indicator{border:6px solid #0000;border-bottom-color:#f5690c;width:0;height:0;display:inline-block;position:absolute;top:-6px;right:-6px;transform:rotate(45deg)}.sub-table-plus .sub-table-handle-button{cursor:pointer;font-size:20px}.sub-table-plus .sub-table-handle-button+.sub-table-handle-button{margin-left:5px}.sub-table-plus .el-table .el-table__header th{line-height:inherit;padding:5px 0;background:#f3f5fb!important}.sub-table-plus .form-item{padding-top:4px;padding-bottom:4px}