@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,30 +1,17 @@
1
- var s = Object.defineProperty;
2
- var i = Object.getOwnPropertySymbols;
3
- var m = Object.prototype.hasOwnProperty, p = Object.prototype.propertyIsEnumerable;
4
- var l = (r, e, t) => e in r ? s(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t, a = (r, e) => {
5
- for (var t in e || (e = {}))
6
- m.call(e, t) && l(r, t, e[t]);
7
- if (i)
8
- for (var t of i(e))
9
- p.call(e, t) && l(r, t, e[t]);
10
- return r;
11
- };
12
- import { f as u } from "../chunks/form-input-mixin.BkKiqJhi.mjs";
13
- import o from "element-ui/lib/time-picker";
14
- import { d as f, n as d } from "../chunks/index.MAFc4eFi.mjs";
15
- import { n as c } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
16
- const _ = Object.keys(o.props || o.default.props).filter((r) => !["value", "placeholder", "disabled"].includes(r)), g = {
1
+ import { f as a } from "../chunks/form-input.B8z37eqj.mjs";
2
+ import i from "element-ui/lib/time-picker";
3
+ import { c as l, n as o } from "../chunks/index.d3MV3Wq2.mjs";
4
+ import { n as s } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
5
+ const m = Object.keys(i.props).filter((r) => !["value", "placeholder", "disabled"].includes(r)), p = {
17
6
  name: "FormInputTime",
18
- mixins: [u],
7
+ mixins: [a],
19
8
  props: {
20
9
  range: Boolean,
21
10
  format: {
22
11
  type: String,
23
12
  default: "HH:mm:ss"
24
13
  },
25
- valueFormat: {
26
- type: String
27
- },
14
+ valueFormat: String,
28
15
  start: {
29
16
  type: String,
30
17
  default: "09:00"
@@ -45,44 +32,42 @@ const _ = Object.keys(o.props || o.default.props).filter((r) => !["value", "plac
45
32
  type: String,
46
33
  default: ""
47
34
  },
48
- selectableRange: {
49
- type: String
50
- }
35
+ selectableRange: String
51
36
  },
52
37
  computed: {
53
38
  prefix() {
54
39
  return "请选择";
55
40
  },
56
41
  inputProps() {
57
- return f(a(a({}, d(this.$attrs)), this.$props), _);
42
+ return l({ ...o(this.$attrs), ...this.$props }, m);
58
43
  }
59
44
  }
60
45
  };
61
- var y = function() {
62
- var e = this, t = e._self._c;
63
- return t("FormItem", e._b({ attrs: { rules: e.computeRules, disabled: e.inputDisabled }, scopedSlots: e._u([{ key: "default", fn: function() {
64
- return [t("ElTimePicker", e._g(e._b({ attrs: { "is-range": e.range, value: e.value, disabled: e.inputDisabled, format: e.format, "value-format": e.valueFormat || e.format, clearable: "", "picker-options": {
46
+ var u = function() {
47
+ var e = this, n = e._self._c;
48
+ return n("FormItem", e._b({ attrs: { rules: e.computeRules, disabled: e.inputDisabled }, scopedSlots: e._u([{ key: "default", fn: function() {
49
+ return [n("ElTimePicker", e._g(e._b({ staticStyle: { width: "100%" }, attrs: { "is-range": e.range, value: e.value, disabled: e.inputDisabled, format: e.format, "value-format": e.valueFormat || e.format, clearable: "", "picker-options": {
65
50
  start: e.start,
66
51
  end: e.end,
67
52
  step: e.step,
68
53
  minTime: e.minTime,
69
54
  maxTime: e.maxTime,
70
55
  selectableRange: e.selectableRange
71
- }, "start-placeholder": "开始时间", "end-placeholder": "结束时间", placeholder: e.computePlaceholder }, on: { input: (n) => e.$emit("input", n) } }, "ElTimePicker", e.inputProps, !1), e.listeners))];
72
- }, proxy: !0 }, { key: "error", fn: function({ error: n }) {
73
- return [e._t("error", null, { error: n })];
56
+ }, "start-placeholder": "开始时间", "end-placeholder": "结束时间", placeholder: e.computePlaceholder }, on: { input: (t) => e.$emit("input", t) } }, "ElTimePicker", e.inputProps, !1), e.listeners))];
57
+ }, proxy: !0 }, { key: "error", fn: function({ error: t }) {
58
+ return [e._t("error", null, { error: t })];
74
59
  } }, { key: "label", fn: function() {
75
60
  return [e._t("label")];
76
61
  }, proxy: !0 }], null, !0) }, "FormItem", e.formItemProps, !1));
77
- }, b = [], v = /* @__PURE__ */ c(
78
- g,
79
- y,
80
- b,
62
+ }, f = [], c = /* @__PURE__ */ s(
63
+ p,
64
+ u,
65
+ f,
81
66
  !1,
82
67
  null,
83
68
  null
84
69
  );
85
- const k = v.exports;
70
+ const y = c.exports;
86
71
  export {
87
- k as default
72
+ y as default
88
73
  };
@@ -1,39 +1,13 @@
1
- var T = Object.defineProperty;
2
- var k = Object.getOwnPropertySymbols;
3
- var V = Object.prototype.hasOwnProperty, j = Object.prototype.propertyIsEnumerable;
4
- var x = (e, r, t) => r in e ? T(e, r, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[r] = t, h = (e, r) => {
5
- for (var t in r || (r = {}))
6
- V.call(r, t) && x(e, t, r[t]);
7
- if (k)
8
- for (var t of k(r))
9
- j.call(r, t) && x(e, t, r[t]);
10
- return e;
11
- };
12
- var w = (e, r, t) => new Promise((d, a) => {
13
- var o = (i) => {
14
- try {
15
- l(t.next(i));
16
- } catch (m) {
17
- a(m);
18
- }
19
- }, s = (i) => {
20
- try {
21
- l(t.throw(i));
22
- } catch (m) {
23
- a(m);
24
- }
25
- }, l = (i) => i.done ? d(i.value) : Promise.resolve(i.value).then(o, s);
26
- l((t = t.apply(e, r)).next());
27
- });
28
- import { h as p } from "vue";
29
- import { f as B } from "../chunks/form-item-mixin.CG4ZwzMC.mjs";
30
- import { hasOwn as I } from "@web-utils/core";
31
- const A = {
1
+ import { h as m } from "vue";
2
+ import { f as B } from "../chunks/form-item.D-H-wCPE.mjs";
3
+ import { hasOwn as I, isDef as D } from "@web-utils/core";
4
+ import { n as L } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
5
+ const N = {
32
6
  name: "FormItem",
33
7
  mixins: [B],
34
8
  inject: {
35
9
  formHolder: {
36
- default: ""
10
+ default: {}
37
11
  },
38
12
  formItemConfig: {
39
13
  default: null
@@ -41,94 +15,128 @@ const A = {
41
15
  },
42
16
  computed: {
43
17
  gutter() {
44
- var r;
45
18
  let e = this.$parent;
46
19
  for (; e && e.$options.componentName !== "ElRow"; )
47
20
  e = e.$parent;
48
- return (r = e == null ? void 0 : e.gutter) != null ? r : 0;
21
+ return (e == null ? void 0 : e.gutter) ?? 0;
49
22
  }
50
23
  },
51
24
  methods: {
52
25
  renderFormItem() {
53
- var q, g, F;
26
+ var x, k, R, y, E, T, H;
54
27
  const {
55
- label: e,
56
- labelWidth: r,
28
+ hideLabel: e,
29
+ label: l,
30
+ labelWidth: u,
57
31
  prop: t,
58
- rules: d,
59
- $scopedSlots: a,
60
- elFormItemProps: o,
61
- elForm: s,
62
- formHolder: l,
63
- formItemClass: i,
64
- required: m,
65
- block: $,
66
- half: v,
67
- wrapCol: y,
68
- wrapFormItem: R,
69
- disabled: E,
70
- formItemConfig: n,
71
- getRequireRule: W
32
+ rules: p,
33
+ $scopedSlots: r,
34
+ elFormItemProps: i,
35
+ elForm: n,
36
+ formHolder: a,
37
+ formItemClass: c,
38
+ required: f,
39
+ block: h,
40
+ half: w,
41
+ wrapCol: W,
42
+ wrapFormItem: P,
43
+ disabled: V,
44
+ formItemConfig: s,
45
+ getRequireRule: j
72
46
  } = this;
73
- let f = d, u = m, c = m, C = $, b = y;
74
- n && (I(n, "block") && (C = n.block), I(n, "wrapCol") && (b = n.wrapCol));
75
- const H = C && v && b ? `calc( 50% - ${this.gutter / 2}px)` : "";
76
- return E || s != null && s.disabled ? (f = [], l && !l.required && !((q = l.requiredFields) != null && q.includes(t)) && (c = !1)) : (l && !l.required && !((g = l.requiredFields) != null && g.includes(t)) && (u = !1), u && !(f != null && f.length) && t ? f = [W()] : u || (c = !1, f && (f = f.filter((P) => !P.required)))), R ? (
77
- // eslint-disable-next-line no-undef
78
- p("ElFormItem", {
79
- style: {
80
- width: H
81
- },
82
- key: `${t}-${u}`,
83
- class: c ? `form-item required ${i || ""}` : `${i || ""}`,
84
- scopedSlots: a,
85
- props: h({}, o),
86
- attrs: {
87
- label: e,
88
- "label-width": r,
89
- prop: t,
90
- rules: f
91
- },
92
- ref: "formItem"
93
- })
94
- ) : p("div", [(F = a.default) == null ? void 0 : F.call(a)]);
47
+ let o = p, d = f, b = f, v = h, g = W;
48
+ s && (I(s, "block") && (v = s.block), I(s, "wrapCol") && (g = s.wrapCol));
49
+ const z = a.tableForm ? "" : v && w && g ? `calc( 50% - ${this.gutter / 2}px)` : "";
50
+ (x = a.requiredFields) != null && x.includes(t) && (d = !0), (V || n != null && n.disabled) && !((k = a.requiredFields) != null && k.includes(t)) ? (o = [], !a.required && !((R = a.requiredFields) != null && R.includes(t)) && (b = !1)) : (!a.required && !((y = a.requiredFields) != null && y.includes(t)) && (d = !1), d && !(o != null && o.length) && t ? o = [j()] : d || (b = !1, o && (o = o.filter((C) => !C.required))));
51
+ const F = (E = r.tips) == null ? void 0 : E.call(r), q = F || this.tips, _ = q ? m("ElTooltip", {
52
+ attrs: {
53
+ effect: "light",
54
+ content: this.tips
55
+ }
56
+ }, [F ? m("div", {
57
+ slot: "content"
58
+ }, [F]) : null, m("i", {
59
+ class: "el-icon-info form-item-input-info"
60
+ })]) : null;
61
+ return P ? m("ElFormItem", {
62
+ style: {
63
+ width: z
64
+ },
65
+ key: `${t}-${d}`,
66
+ class: ["form-item", c, {
67
+ required: b,
68
+ "form-item-hide-label": e
69
+ }],
70
+ scopedSlots: {
71
+ ...r,
72
+ default: q ? () => {
73
+ var C;
74
+ return m("div", {
75
+ class: "form-item-input-wrapper"
76
+ }, [(C = r.default) == null ? void 0 : C.call(r), _]);
77
+ } : r.default
78
+ },
79
+ props: {
80
+ ...i
81
+ },
82
+ attrs: {
83
+ label: l,
84
+ "label-width": e ? "0" : u,
85
+ prop: t,
86
+ rules: o
87
+ },
88
+ ref: "formItem"
89
+ }) : q ? m("div", {
90
+ class: "form-item-input-wrapper"
91
+ }, [(T = r.default) == null ? void 0 : T.call(r), _]) : m("div", [(H = r.default) == null ? void 0 : H.call(r)]);
95
92
  },
96
- clearValidate() {
97
- return w(this, null, function* () {
98
- var e, r;
99
- yield this.$nextTick(), (r = (e = this.$refs.formItem).clearValidate) == null || r.call(e);
100
- });
93
+ async clearValidate() {
94
+ var e, l;
95
+ await this.$nextTick(), (l = (e = this.$refs.formItem).clearValidate) == null || l.call(e);
101
96
  },
102
- validate() {
103
- return w(this, null, function* () {
104
- var e, r;
105
- yield this.$nextTick(), (r = (e = this.$refs.formItem).validate) == null || r.call(e);
106
- });
97
+ async validate() {
98
+ var e, l;
99
+ await this.$nextTick(), (l = (e = this.$refs.formItem).validate) == null || l.call(e);
107
100
  }
108
101
  },
109
102
  render() {
110
- var i, m;
103
+ var h, w;
111
104
  const {
112
105
  computeSpan: e,
113
- wrapCol: r,
106
+ wrapCol: l,
107
+ fixedSpan: u,
114
108
  formItemConfig: t,
115
- renderFormItem: d,
116
- elColProps: a,
117
- $scopedSlots: o,
118
- unwrap: s
109
+ renderFormItem: p,
110
+ elColProps: r,
111
+ $scopedSlots: i,
112
+ unwrap: n,
113
+ formHolder: a
119
114
  } = this;
120
- let l = r;
121
- return t && I(t, "wrapCol") && (l = t.wrapCol), s ? p("div", [(i = o.default) == null ? void 0 : i.call(o)]) : l ? (
122
- // eslint-disable-next-line no-undef
123
- p("ElCol", {
124
- props: h({}, a),
125
- attrs: {
126
- span: e
127
- }
128
- }, [d(), (m = o == null ? void 0 : o.below) == null ? void 0 : m.call(o)])
129
- ) : d();
115
+ let c = !a.tableForm && l, f = !1;
116
+ return t && (I(t, "wrapCol") && (c = t.wrapCol), I(t, "reactive") && (f = t.reactive)), n ? m("div", [(h = i.default) == null ? void 0 : h.call(i)]) : c ? m("ElCol", {
117
+ props: {
118
+ ...r,
119
+ span: u || e,
120
+ ...!D(u) && f ? {
121
+ xs: 24,
122
+ sm: 12,
123
+ md: 12,
124
+ lg: 8,
125
+ xl: 6
126
+ } : {}
127
+ }
128
+ }, [p(), (w = i == null ? void 0 : i.below) == null ? void 0 : w.call(i)]) : p();
130
129
  }
131
- };
130
+ }, O = null, A = null;
131
+ var G = /* @__PURE__ */ L(
132
+ N,
133
+ O,
134
+ A,
135
+ !1,
136
+ null,
137
+ null
138
+ );
139
+ const U = G.exports;
132
140
  export {
133
- A as default
141
+ U as default
134
142
  };
@@ -1 +1 @@
1
- .form-item.el-form-item.required:not(.is-no-asterisk) .el-form-item__label:before{color:#f56c6c;content:"*";margin-right:4px}
1
+ .form-item.el-form-item.is-required:not(.is-no-asterisk) .el-form-item__label:before{color:#f56c6c;content:"*";margin-right:4px;display:inline}.form-item.el-form-item .el-form-item__content{min-height:29px}.form-item.el-form-item.el-form-item--mini .el-form-item__content{line-height:27px}.form-item.el-form-item.form-item-hide-label .el-form-item__label{display:none}.form-item-input-wrapper{flex-direction:row;align-items:center;display:flex}.form-item-input-wrapper>div,.form-item-input-wrapper>form{width:100%}.form-item-input-wrapper .el-input{flex:auto}.form-item-input-wrapper .form-item-input-info{color:gray;cursor:help;margin-left:4px;font-size:16px}
@@ -1,4 +1,4 @@
1
- import { n as e } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
1
+ import { n as o } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
2
2
  const r = {
3
3
  name: "FormItemConfigProvider",
4
4
  provide() {
@@ -7,6 +7,7 @@ const r = {
7
7
  };
8
8
  },
9
9
  props: {
10
+ reactive: Boolean,
10
11
  block: Boolean,
11
12
  wrapCol: {
12
13
  type: Boolean,
@@ -17,6 +18,7 @@ const r = {
17
18
  return {
18
19
  config: {
19
20
  block: !1,
21
+ reactive: !1,
20
22
  wrapCol: !0
21
23
  }
22
24
  };
@@ -24,30 +26,36 @@ const r = {
24
26
  watch: {
25
27
  block: {
26
28
  immediate: !0,
27
- handler(o) {
28
- this.config.block = o;
29
+ handler(e) {
30
+ this.config.block = e;
29
31
  }
30
32
  },
31
33
  wrapCol: {
32
34
  immediate: !0,
33
- handler(o) {
34
- this.config.wrapCol = o;
35
+ handler(e) {
36
+ this.config.wrapCol = e;
37
+ }
38
+ },
39
+ reactive: {
40
+ immediate: !0,
41
+ handler(e) {
42
+ this.config.reactive = e;
35
43
  }
36
44
  }
37
45
  },
38
46
  render() {
39
47
  return this.$scopedSlots.default();
40
48
  }
41
- }, n = null, t = null;
42
- var l = /* @__PURE__ */ e(
49
+ }, t = null, n = null;
50
+ var a = /* @__PURE__ */ o(
43
51
  r,
44
- n,
45
52
  t,
53
+ n,
46
54
  !1,
47
55
  null,
48
56
  null
49
57
  );
50
- const i = l.exports;
58
+ const l = a.exports;
51
59
  export {
52
- i as default
60
+ l as default
53
61
  };
@@ -1,22 +1,25 @@
1
- import { h as o } from "vue";
2
- import { isFunction as n } from "@web-utils/core";
3
- const a = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth", "hideRequiredAsterisk", "$emit", "validate", "clearValidate"], m = ["$emit", "validate", "clearValidate"], p = {
1
+ import { h as s } from "vue";
2
+ import { n as a } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
3
+ const r = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth", "hideRequiredAsterisk", "$emit", "validate", "clearValidate"], d = ["$emit", "validate", "clearValidate"], n = {
4
4
  name: "FormItemGroup",
5
5
  inject: {
6
6
  elForm: {
7
7
  default: {}
8
+ },
9
+ formHolder: {
10
+ default: {}
8
11
  }
9
12
  },
10
13
  provide() {
11
14
  return {
12
- elForm: this.formConfig,
15
+ elForm: this.proxyForm,
13
16
  formItemGroup: this
14
17
  };
15
18
  },
16
19
  props: {
17
- blockTitle: {
18
- type: String
19
- },
20
+ blockTitle: String,
21
+ size: String,
22
+ tips: String,
20
23
  active: Boolean,
21
24
  enabled: Boolean,
22
25
  disabled: Boolean,
@@ -28,15 +31,20 @@ const a = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth",
28
31
  type: Number,
29
32
  default: 20
30
33
  },
31
- collapse: Boolean
34
+ collapse: Boolean,
35
+ showTitle: {
36
+ type: Boolean,
37
+ default: !0
38
+ },
39
+ notDispatch: Boolean
32
40
  },
33
41
  data() {
34
42
  const e = {};
35
- return a.forEach((i) => {
36
- e[i] = null;
43
+ return r.forEach((t) => {
44
+ e[t] = null;
37
45
  }), {
38
46
  expand: !0,
39
- formConfig: e
47
+ proxyForm: e
40
48
  };
41
49
  },
42
50
  computed: {
@@ -45,9 +53,12 @@ const a = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth",
45
53
  enabled: this.enabled,
46
54
  forbidden: this.disabled
47
55
  };
48
- return a.forEach((i) => {
49
- e[i] = this.elForm[i];
56
+ return r.forEach((t) => {
57
+ e[t] = this.elForm[t];
50
58
  }), e;
59
+ },
60
+ isDisabled() {
61
+ return this.disabled ? this.disabled : this.enabled ? !this.enabled : this.elForm.disabled;
51
62
  }
52
63
  },
53
64
  watch: {
@@ -60,49 +71,36 @@ const a = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth",
60
71
  formCfg: {
61
72
  immediate: !0,
62
73
  handler() {
63
- this.formConfig.disabled = this.isDisabled(), a.forEach((e) => {
64
- var i;
65
- e !== "disabled" && (m.includes(e) ? this.formConfig[e] = (i = this.elForm[e]) == null ? void 0 : i.bind(this.elForm) : this.formConfig[e] = this.elForm[e]);
66
- });
74
+ this.proxyForm.disabled = this.isDisabled, r.forEach((e) => {
75
+ var t;
76
+ e !== "disabled" && (d.includes(e) ? this.proxyForm[e] = (t = this.elForm[e]) == null ? void 0 : t.bind(this.elForm) : this.proxyForm[e] = this.elForm[e]);
77
+ }), this.size && (this.proxyForm.size = this.size);
67
78
  }
68
79
  }
69
80
  },
70
81
  mounted() {
71
- this.dispatch("FormView", "FormView.addGroup", [this]);
82
+ this.notDispatch || this.dispatch("FormView", "FormView.addGroup", [this]);
72
83
  },
73
84
  beforeDestroy() {
74
- this.dispatch("FormView", "FormView.removeGroup", [this]);
85
+ this.notDispatch || this.dispatch("FormView", "FormView.removeGroup", [this]);
75
86
  },
76
87
  methods: {
77
- isDisabled() {
78
- return this.disabled ? this.disabled : this.enabled ? !this.enabled : this.elForm.disabled;
79
- },
80
- dispatch(e, i, r) {
81
- let t = this.$parent || this.$root, s = t.$options.name;
82
- for (; t && (!s || s !== e); )
83
- t = t.$parent, t && (s = t.$options.name);
84
- t && t.$emit.apply(t, [i].concat(r));
88
+ dispatch(e, t, l) {
89
+ let i = this.$parent || this.$root, o = i.$options.name;
90
+ for (; i && (!o || o !== e); )
91
+ i = i.$parent, i && (o = i.$options.name);
92
+ i && i.$emit.apply(i, [t].concat(l));
85
93
  },
86
94
  renderDefault() {
87
- const {
88
- wrapRow: e,
89
- gutter: i,
90
- formConfig: r,
91
- $scopedSlots: t
92
- } = this;
93
- return n(t.default) ? e ? (
94
- // eslint-disable-next-line no-undef
95
- o("ElRow", {
96
- attrs: {
97
- gutter: i
98
- },
99
- class: "form-item-group-row"
100
- }, [t.default({
101
- disabled: r.disabled
102
- })])
103
- ) : t.default({
104
- disabled: r.disabled
105
- }) : o("EmptyView", {
95
+ return this.$scopedSlots.default ? !this.formHolder.tableForm && this.wrapRow ? s("ElRow", {
96
+ attrs: {
97
+ gutter: this.gutter
98
+ }
99
+ }, [this.$scopedSlots.default({
100
+ disabled: this.proxyForm.disabled
101
+ })]) : this.$scopedSlots.default({
102
+ disabled: this.proxyForm.disabled
103
+ }) : s("EmptyView", {
106
104
  attrs: {
107
105
  "font-size": "14px",
108
106
  "empty-tips": "暂无信息"
@@ -117,37 +115,43 @@ const a = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth",
117
115
  }
118
116
  },
119
117
  render() {
120
- const {
121
- renderDefault: e,
122
- blockTitle: i,
123
- active: r,
124
- expand: t,
125
- toggle: s,
126
- $scopedSlots: l,
127
- isDisabled: d
128
- } = this;
129
- return o("div", {
118
+ return s("div", {
130
119
  class: ["form-item-group", {
131
- "default-active": r,
132
- "is-disabled": d()
120
+ "default-active": this.active,
121
+ "is-disabled": this.isDisabled
133
122
  }]
134
- }, [o("div", {
123
+ }, [s("div", {
135
124
  class: "form-item-group-title",
136
125
  on: {
137
- click: s
138
- }
139
- }, [o("span", {
126
+ click: this.toggle
127
+ },
128
+ directives: [{
129
+ name: "show",
130
+ value: this.showTitle
131
+ }]
132
+ }, [s("span", {
140
133
  class: "flex-item"
141
- }, [i, l["title-right"] ? l["title-right"]() : null]), " ", o("i", {
142
- class: t ? "el-icon-arrow-down" : "el-icon-arrow-right"
143
- })]), o("ElCollapseTransition", [o("div", {
134
+ }, [this.$scopedSlots.title ? this.$scopedSlots.title() : this.blockTitle, this.tips ? s("span", {
135
+ style: "color:#ff0000;font-size:14px;"
136
+ }, [" (", this.tips, ")"]) : null, this.$scopedSlots["title-right"] ? this.$scopedSlots["title-right"]() : null]), " ", s("i", {
137
+ class: this.expand ? "el-icon-arrow-down" : "el-icon-arrow-right"
138
+ })]), s("ElCollapseTransition", [s("div", {
144
139
  directives: [{
145
140
  name: "show",
146
- value: t
141
+ value: this.expand
147
142
  }]
148
- }, [e()])])]);
143
+ }, [this.renderDefault()])])]);
149
144
  }
150
- };
145
+ }, h = null, p = null;
146
+ var m = /* @__PURE__ */ a(
147
+ n,
148
+ h,
149
+ p,
150
+ !1,
151
+ null,
152
+ null
153
+ );
154
+ const f = m.exports;
151
155
  export {
152
- p as default
156
+ f as default
153
157
  };
@@ -1 +1 @@
1
- .form-item-group{background-color:#fff;margin-bottom:10px}.form-item-group.is-disabled .is-required .el-form-item__label:before,.form-item-group.is-disabled .required .el-form-item__label:before{display:none}.form-item-group .form-item-group-row{margin:0!important}.form-item-group .form-item-group-title{color:#333;cursor:pointer;background-color:#f3f5fb;flex-direction:row;align-items:center;height:30px;margin:0 0 10px;padding:0 10px;font-size:14px;font-weight:700;line-height:30px;display:flex}
1
+ .form-item-group{background-color:#fff;margin-bottom:10px}.form-item-group.is-disabled .is-required .el-form-item__label:before,.form-item-group.is-disabled .required .el-form-item__label:before{display:none}.form-item-group .form-item-group-title{color:#333;height:30px;font-weight:700;font-size:var(--gloal-font-size);cursor:pointer;background-color:#f3f5fb;flex-direction:row;align-items:center;margin:0 0 10px;padding:0 10px;line-height:30px;display:flex}