mwl-components 0.0.20 → 0.0.22

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.
@@ -14,6 +14,7 @@ export interface buttonType {
14
14
  disabled?: (row: any) => boolean;
15
15
  show?: (row: any) => boolean;
16
16
  click?: (row: any) => void;
17
+ link?: (row: any) => boolean;
17
18
  }
18
19
  declare function __VLS_template(): {
19
20
  attrs: Partial<{}>;
@@ -113,11 +114,11 @@ declare const __VLS_component: import('vue').DefineComponent<globalThis.ExtractP
113
114
  }>> & Readonly<{}>, {
114
115
  data: Record<string, any>[];
115
116
  maxHeight: string;
117
+ height: number;
116
118
  align: string;
117
119
  tableColumns: TableColumn[];
118
120
  buttons: buttonType[];
119
121
  buttonWidth: string | number;
120
- height: number;
121
122
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {
122
123
  tableRef: HTMLDivElement;
123
124
  }, HTMLDivElement>;
package/dist/index.js CHANGED
@@ -1,11 +1,11 @@
1
- import { defineComponent as $, useSlots as j, ref as U, resolveComponent as u, createBlock as r, openBlock as a, normalizeClass as G, createSlots as N, withCtx as d, renderSlot as k, createElementVNode as x, createElementBlock as v, createCommentVNode as f, toDisplayString as _, createVNode as E, watch as J, nextTick as K, computed as R, unref as L, mergeProps as w, normalizeStyle as A, createTextVNode as Y, Fragment as V, renderList as D, getCurrentInstance as Q, onMounted as X, onUnmounted as Z, resolveDynamicComponent as ee, normalizeProps as te, guardReactiveProps as ae, withDirectives as le, vShow as ne } from "vue";
1
+ import { defineComponent as S, useSlots as j, ref as U, resolveComponent as u, createBlock as r, openBlock as a, normalizeClass as K, createSlots as N, withCtx as d, renderSlot as k, createElementVNode as H, createElementBlock as v, createCommentVNode as p, toDisplayString as $, createVNode as E, watch as Q, nextTick as X, computed as R, unref as L, mergeProps as D, normalizeStyle as A, createTextVNode as Y, Fragment as x, renderList as V, getCurrentInstance as Z, onMounted as ee, onUnmounted as te, withDirectives as G, vShow as J, resolveDynamicComponent as ae, normalizeProps as le, guardReactiveProps as ne } from "vue";
2
2
  const oe = { class: "flex items-center justify-between" }, re = { class: "flex items-center" }, ue = { class: "text-16px font-700" }, de = { class: "max-w-200px" }, se = {
3
3
  key: 0,
4
4
  class: "flex justify-end"
5
5
  }, ce = {
6
6
  key: 0,
7
7
  class: "mt-8px flex items-center"
8
- }, ie = /* @__PURE__ */ $({
8
+ }, ie = /* @__PURE__ */ S({
9
9
  name: "ContentWarp",
10
10
  __name: "index",
11
11
  props: {
@@ -15,9 +15,9 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
15
15
  setup(t) {
16
16
  const i = j(), o = U("content-wrap");
17
17
  return (s, l) => {
18
- const m = u("ElIcon"), g = u("ElTooltip"), p = u("ElCard");
19
- return a(), r(p, {
20
- class: G([o.value, "mb-[10px]"]),
18
+ const m = u("ElIcon"), g = u("ElTooltip"), f = u("ElCard");
19
+ return a(), r(f, {
20
+ class: K([o.value, "mb-[10px]"]),
21
21
  shadow: "never"
22
22
  }, N({
23
23
  default: d(() => [
@@ -28,16 +28,16 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
28
28
  t.title ? {
29
29
  name: "header",
30
30
  fn: d(() => [
31
- x("div", oe, [
32
- x("div", re, [
33
- x("span", ue, _(t.title), 1),
31
+ H("div", oe, [
32
+ H("div", re, [
33
+ H("span", ue, $(t.title), 1),
34
34
  t.message ? (a(), r(g, {
35
35
  key: 0,
36
36
  effect: "dark",
37
37
  placement: "right"
38
38
  }, {
39
39
  content: d(() => [
40
- x("div", de, _(t.message), 1)
40
+ H("div", de, $(t.message), 1)
41
41
  ]),
42
42
  default: d(() => [
43
43
  E(m, {
@@ -47,15 +47,15 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
47
47
  })
48
48
  ]),
49
49
  _: 1
50
- })) : f("", !0)
50
+ })) : p("", !0)
51
51
  ]),
52
52
  i.buttonTip ? (a(), v("div", se, [
53
53
  k(s.$slots, "buttonTip", {}, void 0, !0)
54
- ])) : f("", !0)
54
+ ])) : p("", !0)
55
55
  ]),
56
56
  i.descTip ? (a(), v("div", ce, [
57
57
  k(s.$slots, "descTip", {}, void 0, !0)
58
- ])) : f("", !0)
58
+ ])) : p("", !0)
59
59
  ]),
60
60
  key: "0"
61
61
  } : void 0
@@ -67,7 +67,7 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
67
67
  for (const [s, l] of i)
68
68
  o[s] = l;
69
69
  return o;
70
- }, me = /* @__PURE__ */ T(ie, [["__scopeId", "data-v-15c93817"]]), pe = { class: "dialog-header" }, he = /* @__PURE__ */ $({
70
+ }, me = /* @__PURE__ */ T(ie, [["__scopeId", "data-v-15c93817"]]), fe = { class: "dialog-header" }, he = /* @__PURE__ */ S({
71
71
  name: "Dialog",
72
72
  __name: "index",
73
73
  props: {
@@ -96,10 +96,10 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
96
96
  const i = j(), o = t, s = U(!1), l = () => {
97
97
  s.value = !L(s);
98
98
  }, m = U(o.maxHeight);
99
- J(
99
+ Q(
100
100
  () => s.value,
101
- async (p) => {
102
- if (await K(), p) {
101
+ async (f) => {
102
+ if (await X(), f) {
103
103
  const c = document.documentElement.offsetHeight;
104
104
  m.value = `${c - 55 - 40 - (i.footer ? 63 : 0)}px`;
105
105
  } else
@@ -115,9 +115,9 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
115
115
  height: L(m)
116
116
  };
117
117
  });
118
- return (p, c) => {
118
+ return (f, c) => {
119
119
  const b = u("el-button"), y = u("ElScrollbar"), C = u("ElDialog");
120
- return a(), r(C, w(p.$attrs, {
120
+ return a(), r(C, D(f.$attrs, {
121
121
  "close-on-click-modal": !1,
122
122
  fullscreen: s.value,
123
123
  width: t.width,
@@ -128,15 +128,14 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
128
128
  "append-to-body": ""
129
129
  }), N({
130
130
  header: d(() => [
131
- x("div", pe, [
132
- k(p.$slots, "title", {}, () => [
133
- Y(_(t.title), 1)
131
+ H("div", fe, [
132
+ k(f.$slots, "title", {}, () => [
133
+ Y($(t.title), 1)
134
134
  ]),
135
- x("div", { onClick: l }, [
135
+ H("div", { onClick: l }, [
136
136
  E(b, {
137
137
  link: "",
138
- icon: "FullScreen",
139
- color: "#909399"
138
+ icon: "FullScreen"
140
139
  })
141
140
  ])
142
141
  ])
@@ -147,25 +146,24 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
147
146
  style: A(g.value)
148
147
  }, {
149
148
  default: d(() => [
150
- k(p.$slots, "default")
149
+ k(f.$slots, "default")
151
150
  ]),
152
151
  _: 3
153
- }, 8, ["style"])) : k(p.$slots, "default", { key: 1 })
152
+ }, 8, ["style"])) : k(f.$slots, "default", { key: 1 })
154
153
  ]),
155
154
  _: 2
156
155
  }, [
157
156
  i.footer ? {
158
157
  name: "footer",
159
158
  fn: d(() => [
160
- k(p.$slots, "footer")
159
+ k(f.$slots, "footer")
161
160
  ]),
162
161
  key: "0"
163
162
  } : void 0
164
163
  ]), 1040, ["fullscreen", "width"]);
165
164
  };
166
165
  }
167
- }), fe = {}, ge = /* @__PURE__ */ $({
168
- ...fe,
166
+ }), pe = /* @__PURE__ */ S({
169
167
  name: "EasyForm",
170
168
  __name: "index",
171
169
  props: {
@@ -205,7 +203,7 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
205
203
  return m || null;
206
204
  }
207
205
  }), (m, g) => {
208
- const p = u("el-input"), c = u("el-input-number"), b = u("el-radio"), y = u("el-radio-group"), C = u("el-checkbox"), H = u("el-checkbox-group"), P = u("el-option"), W = u("el-select"), S = u("el-cascader"), M = u("el-switch"), z = u("el-date-picker"), I = u("el-form-item"), B = u("el-form");
206
+ const f = u("el-input"), c = u("el-input-number"), b = u("el-radio"), y = u("el-radio-group"), C = u("el-checkbox"), M = u("el-checkbox-group"), P = u("el-option"), W = u("el-select"), _ = u("el-cascader"), w = u("el-switch"), z = u("el-date-picker"), I = u("el-form-item"), B = u("el-form");
209
207
  return a(), r(B, {
210
208
  ref_key: "formRef",
211
209
  ref: o,
@@ -215,7 +213,7 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
215
213
  "scroll-to-error": ""
216
214
  }, {
217
215
  default: d(() => [
218
- (a(!0), v(V, null, D(t.formItems, ({ type: h, ...e }) => (a(), v(V, null, [
216
+ (a(!0), v(x, null, V(t.formItems, ({ type: h, ...e }) => (a(), v(x, null, [
219
217
  h != "custom" && !e.hidden ? (a(), r(I, {
220
218
  key: 0,
221
219
  label: e.label,
@@ -223,16 +221,17 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
223
221
  rules: e.rule
224
222
  }, {
225
223
  default: d(() => [
226
- h == "text" || h == "" ? (a(), r(p, w({
224
+ h == "text" || h == "" ? (a(), r(f, D({
227
225
  key: 0,
228
226
  placeholder: "请输入" + e.label
229
227
  }, { ref_for: !0 }, { ...e }, {
230
228
  modelValue: t.formData[e.prop],
231
229
  "onUpdate:modelValue": (n) => t.formData[e.prop] = n,
230
+ modelModifiers: { trim: !0 },
232
231
  "show-word-limit": "",
233
232
  style: { width: e.width ? e.width : t.itemWidth }
234
- }), null, 16, ["placeholder", "modelValue", "onUpdate:modelValue", "style"])) : f("", !0),
235
- h == "textarea" ? (a(), r(p, w({
233
+ }), null, 16, ["placeholder", "modelValue", "onUpdate:modelValue", "style"])) : p("", !0),
234
+ h == "textarea" ? (a(), r(f, D({
236
235
  key: 1,
237
236
  ref_for: !0
238
237
  }, { ...e }, {
@@ -240,16 +239,16 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
240
239
  "onUpdate:modelValue": (n) => t.formData[e.prop] = n,
241
240
  type: "textarea",
242
241
  style: { width: e.width ? e.width : t.itemWidth }
243
- }), null, 16, ["modelValue", "onUpdate:modelValue", "style"])) : f("", !0),
244
- h == "number" ? (a(), r(c, w({
242
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "style"])) : p("", !0),
243
+ h == "number" ? (a(), r(c, D({
245
244
  key: 2,
246
245
  "controls-position": "right"
247
246
  }, { ref_for: !0 }, { ...e }, {
248
247
  modelValue: t.formData[e.prop],
249
248
  "onUpdate:modelValue": (n) => t.formData[e.prop] = n,
250
249
  style: { width: e.width ? e.width : t.itemWidth }
251
- }), null, 16, ["modelValue", "onUpdate:modelValue", "style"])) : f("", !0),
252
- h == "radio" ? (a(), r(y, w({
250
+ }), null, 16, ["modelValue", "onUpdate:modelValue", "style"])) : p("", !0),
251
+ h == "radio" ? (a(), r(y, D({
253
252
  key: 3,
254
253
  modelValue: t.formData[e.prop],
255
254
  "onUpdate:modelValue": (n) => t.formData[e.prop] = n,
@@ -257,19 +256,19 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
257
256
  onChange: (n) => e.change && e.change(t.formData[e.prop])
258
257
  }, { ref_for: !0 }, { ...e }), {
259
258
  default: d(() => [
260
- (a(!0), v(V, null, D(e.options, (n, F) => (a(), r(b, {
259
+ (a(!0), v(x, null, V(e.options, (n, F) => (a(), r(b, {
261
260
  key: F,
262
261
  value: n.value
263
262
  }, {
264
263
  default: d(() => [
265
- Y(_(n.label), 1)
264
+ Y($(n.label), 1)
266
265
  ]),
267
266
  _: 2
268
267
  }, 1032, ["value"]))), 128))
269
268
  ]),
270
269
  _: 2
271
- }, 1040, ["modelValue", "onUpdate:modelValue", "style", "onChange"])) : f("", !0),
272
- h == "checkbox" ? (a(), r(H, w({
270
+ }, 1040, ["modelValue", "onUpdate:modelValue", "style", "onChange"])) : p("", !0),
271
+ h == "checkbox" ? (a(), r(M, D({
273
272
  key: 4,
274
273
  modelValue: t.formData[e.prop],
275
274
  "onUpdate:modelValue": (n) => t.formData[e.prop] = n,
@@ -277,19 +276,19 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
277
276
  onChange: (n) => e.change && e.change(t.formData[e.prop])
278
277
  }, { ref_for: !0 }, { ...e }), {
279
278
  default: d(() => [
280
- (a(!0), v(V, null, D(e.options, (n, F) => (a(), r(C, {
279
+ (a(!0), v(x, null, V(e.options, (n, F) => (a(), r(C, {
281
280
  key: F,
282
281
  value: n.value
283
282
  }, {
284
283
  default: d(() => [
285
- Y(_(n.label), 1)
284
+ Y($(n.label), 1)
286
285
  ]),
287
286
  _: 2
288
287
  }, 1032, ["value"]))), 128))
289
288
  ]),
290
289
  _: 2
291
- }, 1040, ["modelValue", "onUpdate:modelValue", "style", "onChange"])) : f("", !0),
292
- h == "select" || h == "multipleselect" ? (a(), r(W, w({
290
+ }, 1040, ["modelValue", "onUpdate:modelValue", "style", "onChange"])) : p("", !0),
291
+ h == "select" || h == "multipleselect" ? (a(), r(W, D({
293
292
  key: 5,
294
293
  modelValue: t.formData[e.prop],
295
294
  "onUpdate:modelValue": (n) => t.formData[e.prop] = n,
@@ -298,15 +297,15 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
298
297
  onChange: (n) => e.change && e.change(t.formData[e.prop])
299
298
  }, { ref_for: !0 }, { ...e }), {
300
299
  default: d(() => [
301
- (a(!0), v(V, null, D(e.options, (n, F) => (a(), r(P, {
300
+ (a(!0), v(x, null, V(e.options, (n, F) => (a(), r(P, {
302
301
  key: F,
303
302
  label: e.defaultProp ? n[e.defaultProp.label] : n.label,
304
303
  value: e.defaultProp ? n[e.defaultProp.value] : n.value
305
304
  }, null, 8, ["label", "value"]))), 128))
306
305
  ]),
307
306
  _: 2
308
- }, 1040, ["modelValue", "onUpdate:modelValue", "style", "onChange"])) : f("", !0),
309
- h == "cascader" ? (a(), r(S, {
307
+ }, 1040, ["modelValue", "onUpdate:modelValue", "style", "onChange"])) : p("", !0),
308
+ h == "cascader" ? (a(), r(_, {
310
309
  key: 6,
311
310
  modelValue: t.formData[e.prop],
312
311
  "onUpdate:modelValue": (n) => t.formData[e.prop] = n,
@@ -320,16 +319,16 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
320
319
  teleported: e.teleported,
321
320
  "disabled-date": e.disabledDate,
322
321
  onChange: (n) => e.change && e.change(t.formData[e.prop])
323
- }, null, 8, ["modelValue", "onUpdate:modelValue", "options", "props", "style", "disabled", "clearable", "placeholder", "popper-class", "teleported", "disabled-date", "onChange"])) : f("", !0),
324
- h === "switch" ? (a(), r(M, {
322
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "options", "props", "style", "disabled", "clearable", "placeholder", "popper-class", "teleported", "disabled-date", "onChange"])) : p("", !0),
323
+ h === "switch" ? (a(), r(w, {
325
324
  key: 7,
326
325
  modelValue: t.formData[e.prop],
327
326
  "onUpdate:modelValue": (n) => t.formData[e.prop] = n,
328
327
  disabled: e.disabled,
329
328
  style: A({ width: e.width ? e.width : t.itemWidth }),
330
329
  onChange: (n) => e.change && e.change(t.formData[e.prop])
331
- }, null, 8, ["modelValue", "onUpdate:modelValue", "disabled", "style", "onChange"])) : f("", !0),
332
- h == "date" || h == "datetime" || h == "year" || h == "month" ? (a(), r(z, w({
330
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "disabled", "style", "onChange"])) : p("", !0),
331
+ h == "date" || h == "datetime" || h == "year" || h == "month" ? (a(), r(z, D({
333
332
  key: 8,
334
333
  style: { width: e.width ? e.width : t.itemWidth },
335
334
  modelValue: t.formData[e.prop],
@@ -343,7 +342,7 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
343
342
  "disabled-date": e.disabledDate,
344
343
  type: h,
345
344
  onChange: (n) => e.change && e.change(t.formData[e.prop])
346
- }), null, 16, ["style", "modelValue", "onUpdate:modelValue", "format", "value-format", "disabled", "clearable", "placeholder", "disabled-date", "type", "onChange"])) : f("", !0),
345
+ }), null, 16, ["style", "modelValue", "onUpdate:modelValue", "format", "value-format", "disabled", "clearable", "placeholder", "disabled-date", "type", "onChange"])) : p("", !0),
347
346
  h == "daterange" ? (a(), r(z, {
348
347
  key: 9,
349
348
  modelValue: t.formData[e.prop],
@@ -356,14 +355,14 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
356
355
  "start-placeholder": "开始日期",
357
356
  "end-placeholder": "结束日期",
358
357
  onChange: (n) => e.change && e.change(t.formData[e.prop])
359
- }, null, 8, ["modelValue", "onUpdate:modelValue", "format", "value-format", "type", "disabled", "onChange"])) : f("", !0)
358
+ }, null, 8, ["modelValue", "onUpdate:modelValue", "format", "value-format", "type", "disabled", "onChange"])) : p("", !0)
360
359
  ]),
361
360
  _: 2
362
- }, 1032, ["label", "prop", "rules"])) : f("", !0),
361
+ }, 1032, ["label", "prop", "rules"])) : p("", !0),
363
362
  h == "custom" ? k(m.$slots, e.prop, {
364
363
  key: 1,
365
364
  item: e
366
- }, void 0, !0) : f("", !0)
365
+ }, void 0, !0) : p("", !0)
367
366
  ], 64))), 256)),
368
367
  E(I, null, {
369
368
  default: d(() => [
@@ -376,7 +375,7 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
376
375
  }, 8, ["model", "label-width", "inline"]);
377
376
  };
378
377
  }
379
- }), be = /* @__PURE__ */ T(ge, [["__scopeId", "data-v-f33bee61"]]), ye = /* @__PURE__ */ $({
378
+ }), ge = /* @__PURE__ */ T(pe, [["__scopeId", "data-v-8dcb57aa"]]), be = /* @__PURE__ */ S({
380
379
  __name: "tableColumnItem",
381
380
  props: {
382
381
  tableColumn: {}
@@ -387,8 +386,8 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
387
386
  return l.children?.length || delete l.children, l;
388
387
  };
389
388
  return (l, m) => {
390
- const g = u("el-table-column"), p = u("tableColumnItem", !0);
391
- return !l.tableColumn.children || l.tableColumn.children?.length == 0 ? (a(), r(g, w({ key: 0 }, { ...s() }, {
389
+ const g = u("el-table-column"), f = u("tableColumnItem", !0);
390
+ return !l.tableColumn.children || l.tableColumn.children?.length == 0 ? (a(), r(g, D({ key: 0 }, { ...s() }, {
392
391
  prop: l.tableColumn.prop,
393
392
  label: l.tableColumn.label
394
393
  }), N({ _: 2 }, [
@@ -407,15 +406,15 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
407
406
  label: l.tableColumn.label
408
407
  }, {
409
408
  default: d(() => [
410
- (a(!0), v(V, null, D(l.tableColumn.children, (c, b) => (a(), r(p, {
409
+ (a(!0), v(x, null, V(l.tableColumn.children, (c, b) => (a(), r(f, {
411
410
  key: b,
412
411
  "table-column": { align: c.align || l.tableColumn.align, ...c }
413
412
  }, N({ _: 2 }, [
414
- D(i, (y, C) => ({
413
+ V(i, (y, C) => ({
415
414
  name: C,
416
- fn: d(({ row: H }) => [
417
- k(l.$slots, C, { row: H }, () => [
418
- Y(_(H[C]), 1)
415
+ fn: d(({ row: M }) => [
416
+ k(l.$slots, C, { row: M }, () => [
417
+ Y($(M[C]), 1)
419
418
  ])
420
419
  ])
421
420
  }))
@@ -425,7 +424,7 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
425
424
  }, 8, ["align", "label"]));
426
425
  };
427
426
  }
428
- }), ve = /* @__PURE__ */ $({
427
+ }), ye = /* @__PURE__ */ S({
429
428
  name: "EasyTable",
430
429
  __name: "index",
431
430
  props: {
@@ -461,13 +460,13 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
461
460
  },
462
461
  setup(t) {
463
462
  const i = t, o = R(() => (i.buttonWidth.toString().indexOf("px") > -1 ? i.buttonWidth.toString().slice(0, -2) : i.buttonWidth, i.buttonWidth)), s = j(), l = U(), m = U("auto");
464
- let g = Q();
465
- const p = () => {
463
+ let g = Z();
464
+ const f = () => {
466
465
  let y = "auto";
467
466
  if (g?.parent?.attrs?.class?.indexOf("content-wrap") > -1) {
468
467
  try {
469
- const W = g?.refs.tableRef, { top: S } = W?.getBoundingClientRect();
470
- y = document.documentElement.clientHeight - S - 65 - 20;
468
+ const W = g?.refs.tableRef, { top: _ } = W?.getBoundingClientRect();
469
+ y = document.documentElement.clientHeight - _ - 65 - 20;
471
470
  } catch {
472
471
  }
473
472
  return y;
@@ -475,34 +474,34 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
475
474
  return y;
476
475
  }, c = U(), b = () => {
477
476
  c.value && clearTimeout(c.value), c.value = setTimeout(() => {
478
- m.value = p(), c.value = null;
477
+ m.value = f(), c.value = null;
479
478
  }, 100);
480
479
  };
481
- return X(() => {
482
- m.value = p(), window.addEventListener("resize", b);
483
- }), Z(() => {
480
+ return ee(() => {
481
+ m.value = f(), window.addEventListener("resize", b);
482
+ }), te(() => {
484
483
  window.removeEventListener("resize", b);
485
484
  }), (y, C) => {
486
- const H = u("el-button"), P = u("el-table-column"), W = u("el-table");
485
+ const M = u("el-button"), P = u("el-table-column"), W = u("el-table");
487
486
  return a(), v("div", {
488
487
  ref_key: "tableRef",
489
488
  ref: l
490
489
  }, [
491
- E(W, w({ style: { width: "100%" } }, y.$attrs, {
490
+ E(W, D({ style: { width: "100%" } }, y.$attrs, {
492
491
  data: t.data,
493
492
  height: t.height,
494
493
  maxHeight: t.maxHeight ? t.maxHeight : m.value
495
494
  }), {
496
495
  default: d(() => [
497
- (a(!0), v(V, null, D(t.tableColumns, (S, M) => (a(), r(ye, {
498
- key: M,
499
- "table-column": { align: t.align, ...S }
496
+ (a(!0), v(x, null, V(t.tableColumns, (_, w) => (a(), r(be, {
497
+ key: w,
498
+ "table-column": { align: t.align, ..._ }
500
499
  }, N({ _: 2 }, [
501
- D(s, (z, I) => ({
500
+ V(s, (z, I) => ({
502
501
  name: I,
503
502
  fn: d(({ row: B }) => [
504
503
  k(y.$slots, I, { row: B }, () => [
505
- Y(_(B[I]), 1)
504
+ Y($(B[I]), 1)
506
505
  ], !0)
507
506
  ])
508
507
  }))
@@ -514,30 +513,33 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
514
513
  label: "操作",
515
514
  width: o.value
516
515
  }, {
517
- default: d((S) => [
518
- (a(!0), v(V, null, D(t.buttons, (M, z) => (a(), r(H, {
516
+ default: d((_) => [
517
+ (a(!0), v(x, null, V(t.buttons, (w, z) => G((a(), r(M, D({ ref_for: !0 }, { ...w }, {
519
518
  key: z,
520
- type: M.type.includes("del") ? "danger" : "primary",
519
+ type: w.type.includes("del") ? "danger" : "primary",
521
520
  onClick: () => {
522
- M.click?.(S.row);
521
+ w.click?.(_.row);
523
522
  },
524
- link: ""
525
- }, {
523
+ disabled: w.disabled?.(_.row) || !1,
524
+ link: w.link?.(_.row) || !0
525
+ }), {
526
526
  default: d(() => [
527
- Y(_(M.label), 1)
527
+ Y($(w.label), 1)
528
528
  ]),
529
529
  _: 2
530
- }, 1032, ["type", "onClick"]))), 128))
530
+ }, 1040, ["type", "onClick", "disabled", "link"])), [
531
+ [J, w.show?.(_.row) || !0]
532
+ ])), 128))
531
533
  ]),
532
534
  _: 1
533
- }, 8, ["width"])) : f("", !0)
535
+ }, 8, ["width"])) : p("", !0)
534
536
  ]),
535
537
  _: 3
536
538
  }, 16, ["data", "height", "maxHeight"])
537
539
  ], 512);
538
540
  };
539
541
  }
540
- }), Ce = /* @__PURE__ */ T(ve, [["__scopeId", "data-v-1906630b"]]), ke = {
542
+ }), ve = /* @__PURE__ */ T(ye, [["__scopeId", "data-v-721c94d4"]]), Ce = {
541
543
  name: "",
542
544
  components: {},
543
545
  props: {
@@ -547,13 +549,13 @@ const oe = { class: "flex items-center justify-between" }, re = { class: "flex i
547
549
  }
548
550
  }
549
551
  };
550
- function De(t, i, o, s, l, m) {
551
- return o.icon ? (a(), r(ee(o.icon), {
552
+ function ke(t, i, o, s, l, m) {
553
+ return o.icon ? (a(), r(ae(o.icon), {
552
554
  key: 0,
553
555
  class: "menu_icon"
554
- })) : f("", !0);
556
+ })) : p("", !0);
555
557
  }
556
- const O = /* @__PURE__ */ T(ke, [["render", De], ["__scopeId", "data-v-261ce99a"]]), we = /* @__PURE__ */ $({
558
+ const O = /* @__PURE__ */ T(Ce, [["render", ke], ["__scopeId", "data-v-261ce99a"]]), we = /* @__PURE__ */ S({
557
559
  name: "subMenu",
558
560
  __name: "subMenu",
559
561
  props: {
@@ -569,8 +571,8 @@ const O = /* @__PURE__ */ T(ke, [["render", De], ["__scopeId", "data-v-261ce99a"
569
571
  o("handleMenuItemClick", l);
570
572
  }
571
573
  return (l, m) => {
572
- const g = u("subMenu", !0), p = u("el-sub-menu"), c = u("el-menu-item");
573
- return t.routeData.children && t.routeData.children.length > 0 ? (a(), r(p, {
574
+ const g = u("subMenu", !0), f = u("el-sub-menu"), c = u("el-menu-item");
575
+ return t.routeData.children && t.routeData.children.length > 0 ? (a(), r(f, {
574
576
  key: 0,
575
577
  index: t.routeData.path
576
578
  }, {
@@ -578,10 +580,10 @@ const O = /* @__PURE__ */ T(ke, [["render", De], ["__scopeId", "data-v-261ce99a"
578
580
  E(O, {
579
581
  icon: t.routeData.meta.icon
580
582
  }, null, 8, ["icon"]),
581
- x("span", null, _(t.routeData.meta.title), 1)
583
+ H("span", null, $(t.routeData.meta.title), 1)
582
584
  ]),
583
585
  default: d(() => [
584
- (a(!0), v(V, null, D(t.routeData.children, (b, y) => (a(), r(g, {
586
+ (a(!0), v(x, null, V(t.routeData.children, (b, y) => (a(), r(g, {
585
587
  onHandleMenuItemClick: s,
586
588
  routeData: b,
587
589
  key: y
@@ -596,7 +598,7 @@ const O = /* @__PURE__ */ T(ke, [["render", De], ["__scopeId", "data-v-261ce99a"
596
598
  index: t.routeData.path
597
599
  }, {
598
600
  title: d(() => [
599
- x("span", null, _(t.routeData.meta.title), 1)
601
+ H("span", null, $(t.routeData.meta.title), 1)
600
602
  ]),
601
603
  default: d(() => [
602
604
  E(O, {
@@ -608,7 +610,7 @@ const O = /* @__PURE__ */ T(ke, [["render", De], ["__scopeId", "data-v-261ce99a"
608
610
  ]));
609
611
  };
610
612
  }
611
- }), Ve = /* @__PURE__ */ $({
613
+ }), De = /* @__PURE__ */ S({
612
614
  name: "MenuTree",
613
615
  __name: "index",
614
616
  props: {
@@ -624,10 +626,10 @@ const O = /* @__PURE__ */ T(ke, [["render", De], ["__scopeId", "data-v-261ce99a"
624
626
  };
625
627
  return (l, m) => {
626
628
  const g = u("el-menu");
627
- return a(), r(g, te(ae(l.$attrs)), {
629
+ return a(), r(g, le(ne(l.$attrs)), {
628
630
  default: d(() => [
629
- (a(!0), v(V, null, D(t.menuList, (p) => (a(), r(we, {
630
- routeData: p,
631
+ (a(!0), v(x, null, V(t.menuList, (f) => (a(), r(we, {
632
+ routeData: f,
631
633
  onHandleMenuItemClick: s
632
634
  }, null, 8, ["routeData"]))), 256))
633
635
  ]),
@@ -635,7 +637,7 @@ const O = /* @__PURE__ */ T(ke, [["render", De], ["__scopeId", "data-v-261ce99a"
635
637
  }, 16);
636
638
  };
637
639
  }
638
- }), _e = /* @__PURE__ */ $({
640
+ }), Ve = /* @__PURE__ */ S({
639
641
  name: "Pagination",
640
642
  __name: "index",
641
643
  props: {
@@ -680,12 +682,12 @@ const O = /* @__PURE__ */ T(ke, [["render", De], ["__scopeId", "data-v-261ce99a"
680
682
  }
681
683
  }), g = (c) => {
682
684
  l.value * c > o.total && (l.value = 1), s("pagination", { page: l.value, limit: c });
683
- }, p = (c) => {
685
+ }, f = (c) => {
684
686
  s("pagination", { page: c, limit: m.value });
685
687
  };
686
688
  return (c, b) => {
687
689
  const y = u("el-pagination");
688
- return le((a(), r(y, {
690
+ return G((a(), r(y, {
689
691
  "current-page": l.value,
690
692
  "onUpdate:currentPage": b[0] || (b[0] = (C) => l.value = C),
691
693
  "page-size": m.value,
@@ -697,31 +699,31 @@ const O = /* @__PURE__ */ T(ke, [["render", De], ["__scopeId", "data-v-261ce99a"
697
699
  class: "pagination",
698
700
  layout: "total, sizes, prev, pager, next, jumper",
699
701
  onSizeChange: g,
700
- onCurrentChange: p
702
+ onCurrentChange: f
701
703
  }, null, 8, ["current-page", "page-size", "pager-count", "total"])), [
702
- [ne, t.total > 0]
704
+ [J, t.total > 0]
703
705
  ]);
704
706
  };
705
707
  }
706
- }), xe = /* @__PURE__ */ T(_e, [["__scopeId", "data-v-1e34e383"]]), $e = [
708
+ }), _e = /* @__PURE__ */ T(Ve, [["__scopeId", "data-v-1e34e383"]]), xe = [
707
709
  me,
708
710
  he,
709
- be,
710
- Ce,
711
- Ve,
712
- xe
713
- ], q = [], He = (t, i) => {
714
- $e.forEach((o) => {
711
+ ge,
712
+ ve,
713
+ De,
714
+ _e
715
+ ], q = [], $e = (t, i) => {
716
+ xe.forEach((o) => {
715
717
  q.push(o.name), t.component(o.name, o);
716
718
  }), console.log("mwl-components", q);
717
- }, Me = { install: He };
719
+ }, Se = { install: $e };
718
720
  export {
719
721
  me as ContentWarp,
720
722
  he as Dialog,
721
- be as EasyForm,
722
- Ce as EasyTable,
723
- Ve as MenuTree,
724
- xe as Pagination,
725
- Me as default,
726
- He as install
723
+ ge as EasyForm,
724
+ ve as EasyTable,
725
+ De as MenuTree,
726
+ _e as Pagination,
727
+ Se as default,
728
+ $e as install
727
729
  };
@@ -1 +1 @@
1
- .el-card[data-v-15c93817]{background-color:transparent;margin-bottom:10px}[data-v-15c93817] .el-card__body:has(>.el-form){padding:18px 20px 0}[data-v-15c93817] .el-card__body{padding:20px}.custom-dialog{padding:0}.custom-dialog .el-dialog__header{--el-dialog-padding-primary: 20px;margin-right:0!important;border-bottom:1px solid #eee;padding:var(--el-dialog-padding-primary);padding-bottom:10px}.dialog-header{display:flex;align-items:center;justify-content:space-between;margin-right:30px}.dialog-header .fullScreen{cursor:pointer;z-index:99}.el-dialog__headerbtn{top:8px}.el-dialog__body{padding:20px 30px;color:#606266;font-size:14px}.el-dialog__footer{padding:10px 20px 20px;border-top:1px solid #eee}[data-v-f33bee61] .el-form-item__label{font-size:var(--el-font-size-base)}[data-v-1906630b] .el-table,[data-v-1906630b] th.el-table__cell,[data-v-1906630b] tr{background-color:transparent!important}.menu_icon[data-v-261ce99a]{width:22px;height:22px;margin-right:5px;fill:currentColor;display:inline-block;font-size:16px}.pagination[data-v-1e34e383]{margin-top:15px;margin-bottom:15px;float:right}@media screen and (max-width: 1370px){.pagination[data-v-1e34e383]{margin-top:8px;margin-bottom:8px}}
1
+ .el-card[data-v-15c93817]{background-color:transparent;margin-bottom:10px}[data-v-15c93817] .el-card__body:has(>.el-form){padding:18px 20px 0}[data-v-15c93817] .el-card__body{padding:20px}.custom-dialog{padding:0}.custom-dialog .el-dialog__header{--el-dialog-padding-primary: 20px;margin-right:0!important;border-bottom:1px solid var(--el-border-color);padding:var(--el-dialog-padding-primary);padding-bottom:10px}.dialog-header{display:flex;align-items:center;justify-content:space-between;margin-right:30px}.dialog-header .fullScreen{cursor:pointer;z-index:99}.el-dialog__headerbtn{top:8px}.el-dialog__body{padding:20px 30px}.el-dialog__footer{padding:10px 20px 20px;border-top:1px solid var(--el-border-color)}[data-v-8dcb57aa] .el-form-item__label{font-size:var(--el-font-size-base)}[data-v-721c94d4] .el-table,[data-v-721c94d4] th.el-table__cell,[data-v-721c94d4] tr{background-color:transparent!important}.menu_icon[data-v-261ce99a]{width:22px;height:22px;margin-right:5px;fill:currentColor;display:inline-block;font-size:16px}.pagination[data-v-1e34e383]{margin-top:15px;margin-bottom:15px;float:right}@media screen and (max-width: 1370px){.pagination[data-v-1e34e383]{margin-top:8px;margin-bottom:8px}}