mwl-components 0.0.14 → 0.0.15

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.
package/dist/index.js CHANGED
@@ -1,12 +1,12 @@
1
- import { defineComponent as w, useSlots as Y, ref as V, createBlock as u, openBlock as l, unref as r, normalizeClass as q, createSlots as M, withCtx as i, renderSlot as b, createElementVNode as D, createElementBlock as g, createCommentVNode as h, toDisplayString as k, createVNode as x, watch as G, nextTick as J, computed as F, mergeProps as v, normalizeStyle as N, createTextVNode as $, Fragment as C, renderList as y, resolveComponent as A, getCurrentInstance as K, onMounted as Q, onUnmounted as X, resolveDynamicComponent as Z, normalizeProps as _, guardReactiveProps as ee, withDirectives as te, vShow as ae } from "vue";
2
- import { ElCard as le, ElTooltip as ne, ElIcon as oe, ElDialog as re, ElScrollbar as ue, ElButton as L, ElForm as de, ElFormItem as z, ElInput as R, ElInputNumber as se, ElRadioGroup as ie, ElRadio as ce, ElCheckboxGroup as me, ElCheckbox as fe, ElSelect as he, ElOption as ge, ElCascader as pe, ElSwitch as be, ElDatePicker as B, ElTableColumn as P, ElTable as ye, ElSubMenu as ve, ElMenuItem as Ce, ElMenu as ke, ElPagination as De } from "element-plus";
3
- const we = { class: "flex items-center justify-between" }, Ve = { class: "flex items-center" }, xe = { class: "text-16px font-700" }, Ee = { class: "max-w-200px" }, $e = {
1
+ import { defineComponent as V, useSlots as Y, ref as x, createBlock as r, openBlock as l, unref as u, normalizeClass as q, createSlots as I, withCtx as i, renderSlot as b, createElementVNode as w, createElementBlock as p, createCommentVNode as h, toDisplayString as k, createVNode as $, watch as G, nextTick as J, computed as F, mergeProps as v, normalizeStyle as N, createTextVNode as S, Fragment as C, renderList as y, resolveComponent as z, getCurrentInstance as K, onMounted as Q, onUnmounted as X, resolveDynamicComponent as Z, normalizeProps as _, guardReactiveProps as ee, withDirectives as te, vShow as ae } from "vue";
2
+ import { ElCard as le, ElTooltip as ne, ElIcon as oe, ElDialog as re, ElScrollbar as ue, ElButton as L, ElForm as de, ElFormItem as R, ElInput as B, ElInputNumber as se, ElRadioGroup as ie, ElRadio as ce, ElCheckboxGroup as me, ElCheckbox as fe, ElSelect as he, ElOption as pe, ElCascader as ge, ElSwitch as be, ElDatePicker as O, ElTableColumn as T, ElTable as ye, ElSubMenu as ve, ElMenuItem as Ce, ElMenu as ke } from "element-plus";
3
+ const De = { class: "flex items-center justify-between" }, we = { class: "flex items-center" }, Ve = { class: "text-16px font-700" }, xe = { class: "max-w-200px" }, $e = {
4
4
  key: 0,
5
5
  class: "flex justify-end"
6
- }, Se = {
6
+ }, Ee = {
7
7
  key: 0,
8
8
  class: "mt-8px flex items-center"
9
- }, He = /* @__PURE__ */ w({
9
+ }, Se = /* @__PURE__ */ V({
10
10
  name: "ContentWarp",
11
11
  __name: "index",
12
12
  props: {
@@ -14,11 +14,11 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
14
14
  message: String
15
15
  },
16
16
  setup(t) {
17
- const d = Y(), s = V("content-wrap");
18
- return (c, o) => (l(), u(r(le), {
17
+ const d = Y(), s = x("content-wrap");
18
+ return (c, o) => (l(), r(u(le), {
19
19
  class: q([s.value, "mb-[10px]"]),
20
20
  shadow: "never"
21
- }, M({
21
+ }, I({
22
22
  default: i(() => [
23
23
  b(c.$slots, "default", {}, void 0, !0)
24
24
  ]),
@@ -27,19 +27,19 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
27
27
  t.title ? {
28
28
  name: "header",
29
29
  fn: i(() => [
30
- D("div", we, [
31
- D("div", Ve, [
32
- D("span", xe, k(t.title), 1),
33
- t.message ? (l(), u(r(ne), {
30
+ w("div", De, [
31
+ w("div", we, [
32
+ w("span", Ve, k(t.title), 1),
33
+ t.message ? (l(), r(u(ne), {
34
34
  key: 0,
35
35
  effect: "dark",
36
36
  placement: "right"
37
37
  }, {
38
38
  content: i(() => [
39
- D("div", Ee, k(t.message), 1)
39
+ w("div", xe, k(t.message), 1)
40
40
  ]),
41
41
  default: i(() => [
42
- x(r(oe), {
42
+ $(u(oe), {
43
43
  size: 14,
44
44
  class: "ml-5px",
45
45
  icon: "ep:question-filled"
@@ -48,11 +48,11 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
48
48
  _: 1
49
49
  })) : h("", !0)
50
50
  ]),
51
- d.buttonTip ? (l(), g("div", $e, [
51
+ d.buttonTip ? (l(), p("div", $e, [
52
52
  b(c.$slots, "buttonTip", {}, void 0, !0)
53
53
  ])) : h("", !0)
54
54
  ]),
55
- d.descTip ? (l(), g("div", Se, [
55
+ d.descTip ? (l(), p("div", Ee, [
56
56
  b(c.$slots, "descTip", {}, void 0, !0)
57
57
  ])) : h("", !0)
58
58
  ]),
@@ -60,12 +60,12 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
60
60
  } : void 0
61
61
  ]), 1032, ["class"]));
62
62
  }
63
- }), I = (t, d) => {
63
+ }), U = (t, d) => {
64
64
  const s = t.__vccOpts || t;
65
65
  for (const [c, o] of d)
66
66
  s[c] = o;
67
67
  return s;
68
- }, Me = /* @__PURE__ */ I(He, [["__scopeId", "data-v-cce44bc6"]]), Ie = { class: "dialog-header" }, Ue = /* @__PURE__ */ w({
68
+ }, He = /* @__PURE__ */ U(Se, [["__scopeId", "data-v-cce44bc6"]]), Me = { class: "dialog-header" }, Ie = /* @__PURE__ */ V({
69
69
  name: "Dialog",
70
70
  __name: "index",
71
71
  props: {
@@ -91,9 +91,9 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
91
91
  }
92
92
  },
93
93
  setup(t) {
94
- const d = Y(), s = t, c = V(!1), o = () => {
94
+ const d = Y(), s = t, c = x(!1), o = () => {
95
95
  c.value = !unref(c);
96
- }, m = V(s.maxHeight);
96
+ }, m = x(s.maxHeight);
97
97
  G(
98
98
  () => c.value,
99
99
  async (n) => {
@@ -107,13 +107,13 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
107
107
  immediate: !0
108
108
  }
109
109
  );
110
- const p = F(() => {
110
+ const g = F(() => {
111
111
  if (s.maxHeight)
112
112
  return {
113
113
  height: unref(m)
114
114
  };
115
115
  });
116
- return console.log(s), (n, e) => (l(), u(r(re), v(n.$attrs, {
116
+ return console.log(s), (n, e) => (l(), r(u(re), v(n.$attrs, {
117
117
  "close-on-click-modal": !1,
118
118
  fullscreen: c.value,
119
119
  width: t.width,
@@ -122,14 +122,14 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
122
122
  "lock-scroll": "",
123
123
  class: "custom-dialog",
124
124
  "append-to-body": ""
125
- }), M({
125
+ }), I({
126
126
  header: i(() => [
127
- D("div", Ie, [
127
+ w("div", Me, [
128
128
  b(n.$slots, "title", {}, () => [
129
- $(k(t.title), 1)
129
+ S(k(t.title), 1)
130
130
  ]),
131
- D("div", { onClick: o }, [
132
- x(r(L), {
131
+ w("div", { onClick: o }, [
132
+ $(u(L), {
133
133
  link: "",
134
134
  icon: "FullScreen",
135
135
  color: "#909399"
@@ -138,9 +138,9 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
138
138
  ])
139
139
  ]),
140
140
  default: i(() => [
141
- t.scroll ? (l(), u(r(ue), {
141
+ t.scroll ? (l(), r(u(ue), {
142
142
  key: 0,
143
- style: N(p.value)
143
+ style: N(g.value)
144
144
  }, {
145
145
  default: i(() => [
146
146
  b(n.$slots, "default")
@@ -159,8 +159,8 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
159
159
  } : void 0
160
160
  ]), 1040, ["fullscreen", "width"]));
161
161
  }
162
- }), We = {}, Fe = /* @__PURE__ */ w({
163
- ...We,
162
+ }), Ue = {}, We = /* @__PURE__ */ V({
163
+ ...Ue,
164
164
  name: "EasyForm",
165
165
  __name: "index",
166
166
  props: {
@@ -190,7 +190,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
190
190
  }
191
191
  },
192
192
  setup(t, { expose: d }) {
193
- const s = V();
193
+ const s = x();
194
194
  return d({
195
195
  resetFields: () => {
196
196
  s.value?.resetFields();
@@ -199,7 +199,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
199
199
  const m = await s.value.validate();
200
200
  return m || null;
201
201
  }
202
- }), (m, p) => (l(), u(r(de), {
202
+ }), (m, g) => (l(), r(u(de), {
203
203
  ref_key: "formRef",
204
204
  ref: s,
205
205
  model: t.formData,
@@ -208,15 +208,15 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
208
208
  "scroll-to-error": ""
209
209
  }, {
210
210
  default: i(() => [
211
- (l(!0), g(C, null, y(t.formItems, ({ type: n, ...e }) => (l(), g(C, null, [
212
- n != "custom" && !e.hidden ? (l(), u(r(z), {
211
+ (l(!0), p(C, null, y(t.formItems, ({ type: n, ...e }) => (l(), p(C, null, [
212
+ n != "custom" && !e.hidden ? (l(), r(u(R), {
213
213
  key: 0,
214
214
  label: e.label,
215
215
  prop: e.prop,
216
216
  rules: e.rule
217
217
  }, {
218
218
  default: i(() => [
219
- n == "text" || n == "" ? (l(), u(r(R), v({
219
+ n == "text" || n == "" ? (l(), r(u(B), v({
220
220
  key: 0,
221
221
  placeholder: "请输入" + e.label
222
222
  }, { ref_for: !0 }, { ...e }, {
@@ -225,7 +225,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
225
225
  "show-word-limit": "",
226
226
  style: { width: e.width ? e.width : t.itemWidth }
227
227
  }), null, 16, ["placeholder", "modelValue", "onUpdate:modelValue", "style"])) : h("", !0),
228
- n == "textarea" ? (l(), u(r(R), v({
228
+ n == "textarea" ? (l(), r(u(B), v({
229
229
  key: 1,
230
230
  ref_for: !0
231
231
  }, { ...e }, {
@@ -234,7 +234,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
234
234
  type: "textarea",
235
235
  style: { width: e.width ? e.width : t.itemWidth }
236
236
  }), null, 16, ["modelValue", "onUpdate:modelValue", "style"])) : h("", !0),
237
- n == "number" ? (l(), u(r(se), v({
237
+ n == "number" ? (l(), r(u(se), v({
238
238
  key: 2,
239
239
  "controls-position": "right"
240
240
  }, { ref_for: !0 }, { ...e }, {
@@ -242,7 +242,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
242
242
  "onUpdate:modelValue": (a) => t.formData[e.prop] = a,
243
243
  style: { width: e.width ? e.width : t.itemWidth }
244
244
  }), null, 16, ["modelValue", "onUpdate:modelValue", "style"])) : h("", !0),
245
- n == "radio" ? (l(), u(r(ie), v({
245
+ n == "radio" ? (l(), r(u(ie), v({
246
246
  key: 3,
247
247
  modelValue: t.formData[e.prop],
248
248
  "onUpdate:modelValue": (a) => t.formData[e.prop] = a,
@@ -250,19 +250,19 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
250
250
  onChange: (a) => e.change && e.change(t.formData[e.prop])
251
251
  }, { ref_for: !0 }, { ...e }), {
252
252
  default: i(() => [
253
- (l(!0), g(C, null, y(e.options, (a, f) => (l(), u(r(ce), {
253
+ (l(!0), p(C, null, y(e.options, (a, f) => (l(), r(u(ce), {
254
254
  key: f,
255
255
  value: a.value
256
256
  }, {
257
257
  default: i(() => [
258
- $(k(a.label), 1)
258
+ S(k(a.label), 1)
259
259
  ]),
260
260
  _: 2
261
261
  }, 1032, ["value"]))), 128))
262
262
  ]),
263
263
  _: 2
264
264
  }, 1040, ["modelValue", "onUpdate:modelValue", "style", "onChange"])) : h("", !0),
265
- n == "checkbox" ? (l(), u(r(me), v({
265
+ n == "checkbox" ? (l(), r(u(me), v({
266
266
  key: 4,
267
267
  modelValue: t.formData[e.prop],
268
268
  "onUpdate:modelValue": (a) => t.formData[e.prop] = a,
@@ -270,19 +270,19 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
270
270
  onChange: (a) => e.change && e.change(t.formData[e.prop])
271
271
  }, { ref_for: !0 }, { ...e }), {
272
272
  default: i(() => [
273
- (l(!0), g(C, null, y(e.options, (a, f) => (l(), u(r(fe), {
273
+ (l(!0), p(C, null, y(e.options, (a, f) => (l(), r(u(fe), {
274
274
  key: f,
275
275
  value: a.value
276
276
  }, {
277
277
  default: i(() => [
278
- $(k(a.label), 1)
278
+ S(k(a.label), 1)
279
279
  ]),
280
280
  _: 2
281
281
  }, 1032, ["value"]))), 128))
282
282
  ]),
283
283
  _: 2
284
284
  }, 1040, ["modelValue", "onUpdate:modelValue", "style", "onChange"])) : h("", !0),
285
- n == "select" || n == "multipleselect" ? (l(), u(r(he), v({
285
+ n == "select" || n == "multipleselect" ? (l(), r(u(he), v({
286
286
  key: 5,
287
287
  modelValue: t.formData[e.prop],
288
288
  "onUpdate:modelValue": (a) => t.formData[e.prop] = a,
@@ -291,7 +291,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
291
291
  onChange: (a) => e.change && e.change(t.formData[e.prop])
292
292
  }, { ref_for: !0 }, { ...e }), {
293
293
  default: i(() => [
294
- (l(!0), g(C, null, y(e.options, (a, f) => (l(), u(r(ge), {
294
+ (l(!0), p(C, null, y(e.options, (a, f) => (l(), r(u(pe), {
295
295
  key: f,
296
296
  label: e.defaultProp ? a[e.defaultProp.label] : a.label,
297
297
  value: e.defaultProp ? a[e.defaultProp.value] : a.value
@@ -299,7 +299,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
299
299
  ]),
300
300
  _: 2
301
301
  }, 1040, ["modelValue", "onUpdate:modelValue", "style", "onChange"])) : h("", !0),
302
- n == "cascader" ? (l(), u(r(pe), {
302
+ n == "cascader" ? (l(), r(u(ge), {
303
303
  key: 6,
304
304
  modelValue: t.formData[e.prop],
305
305
  "onUpdate:modelValue": (a) => t.formData[e.prop] = a,
@@ -314,7 +314,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
314
314
  "disabled-date": e.disabledDate,
315
315
  onChange: (a) => e.change && e.change(t.formData[e.prop])
316
316
  }, null, 8, ["modelValue", "onUpdate:modelValue", "options", "props", "style", "disabled", "clearable", "placeholder", "popper-class", "teleported", "disabled-date", "onChange"])) : h("", !0),
317
- n === "switch" ? (l(), u(r(be), {
317
+ n === "switch" ? (l(), r(u(be), {
318
318
  key: 7,
319
319
  modelValue: t.formData[e.prop],
320
320
  "onUpdate:modelValue": (a) => t.formData[e.prop] = a,
@@ -322,7 +322,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
322
322
  style: N({ width: e.width ? e.width : t.itemWidth }),
323
323
  onChange: (a) => e.change && e.change(t.formData[e.prop])
324
324
  }, null, 8, ["modelValue", "onUpdate:modelValue", "disabled", "style", "onChange"])) : h("", !0),
325
- n == "date" || n == "datetime" || n == "year" || n == "month" ? (l(), u(r(B), v({
325
+ n == "date" || n == "datetime" || n == "year" || n == "month" ? (l(), r(u(O), v({
326
326
  key: 8,
327
327
  style: { width: e.width ? e.width : t.itemWidth },
328
328
  modelValue: t.formData[e.prop],
@@ -337,7 +337,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
337
337
  type: n,
338
338
  onChange: (a) => e.change && e.change(t.formData[e.prop])
339
339
  }), null, 16, ["style", "modelValue", "onUpdate:modelValue", "format", "value-format", "disabled", "clearable", "placeholder", "disabled-date", "type", "onChange"])) : h("", !0),
340
- n == "daterange" ? (l(), u(r(B), {
340
+ n == "daterange" ? (l(), r(u(O), {
341
341
  key: 9,
342
342
  modelValue: t.formData[e.prop],
343
343
  "onUpdate:modelValue": (a) => t.formData[e.prop] = a,
@@ -358,7 +358,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
358
358
  item: e
359
359
  }, void 0, !0) : h("", !0)
360
360
  ], 64))), 256)),
361
- x(r(z), null, {
361
+ $(u(R), null, {
362
362
  default: i(() => [
363
363
  b(m.$slots, "append", {}, void 0, !0)
364
364
  ]),
@@ -368,7 +368,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
368
368
  _: 3
369
369
  }, 8, ["model", "label-width", "inline"]));
370
370
  }
371
- }), Ye = /* @__PURE__ */ I(Fe, [["__scopeId", "data-v-84850699"]]), Ne = /* @__PURE__ */ w({
371
+ }), Fe = /* @__PURE__ */ U(We, [["__scopeId", "data-v-84850699"]]), Ye = /* @__PURE__ */ V({
372
372
  __name: "tableColumnItem",
373
373
  props: {
374
374
  tableColumn: {}
@@ -379,11 +379,11 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
379
379
  return o.children?.length || delete o.children, o;
380
380
  };
381
381
  return (o, m) => {
382
- const p = A("tableColumnItem", !0);
383
- return !o.tableColumn.children || o.tableColumn.children?.length == 0 ? (l(), u(r(P), v({ key: 0 }, { ...c() }, {
382
+ const g = z("tableColumnItem", !0);
383
+ return !o.tableColumn.children || o.tableColumn.children?.length == 0 ? (l(), r(u(T), v({ key: 0 }, { ...c() }, {
384
384
  prop: o.tableColumn.prop,
385
385
  label: o.tableColumn.label
386
- }), M({ _: 2 }, [
386
+ }), I({ _: 2 }, [
387
387
  o.tableColumn.prop && d[o.tableColumn.prop] ? {
388
388
  name: "default",
389
389
  fn: i((n) => [
@@ -393,21 +393,21 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
393
393
  ]),
394
394
  key: "0"
395
395
  } : void 0
396
- ]), 1040, ["prop", "label"])) : (l(), u(r(P), {
396
+ ]), 1040, ["prop", "label"])) : (l(), r(u(T), {
397
397
  key: 1,
398
398
  align: o.tableColumn.align,
399
399
  label: o.tableColumn.label
400
400
  }, {
401
401
  default: i(() => [
402
- (l(!0), g(C, null, y(o.tableColumn.children, (n, e) => (l(), u(p, {
402
+ (l(!0), p(C, null, y(o.tableColumn.children, (n, e) => (l(), r(g, {
403
403
  key: e,
404
404
  "table-column": { align: n.align || o.tableColumn.align, ...n }
405
- }, M({ _: 2 }, [
405
+ }, I({ _: 2 }, [
406
406
  y(d, (a, f) => ({
407
407
  name: f,
408
- fn: i(({ row: U }) => [
409
- b(o.$slots, f, { row: U }, () => [
410
- $(k(U[f]), 1)
408
+ fn: i(({ row: D }) => [
409
+ b(o.$slots, f, { row: D }, () => [
410
+ S(k(D[f]), 1)
411
411
  ])
412
412
  ])
413
413
  }))
@@ -417,7 +417,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
417
417
  }, 8, ["align", "label"]));
418
418
  };
419
419
  }
420
- }), Pe = /* @__PURE__ */ w({
420
+ }), Ne = /* @__PURE__ */ V({
421
421
  name: "EasyTable",
422
422
  __name: "index",
423
423
  props: {
@@ -452,20 +452,20 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
452
452
  }
453
453
  },
454
454
  setup(t) {
455
- const d = t, s = F(() => (d.buttonWidth.toString().indexOf("px") > -1 ? d.buttonWidth.toString().slice(0, -2) : d.buttonWidth, d.buttonWidth)), c = Y(), o = V(), m = V("auto");
456
- let p = K();
455
+ const d = t, s = F(() => (d.buttonWidth.toString().indexOf("px") > -1 ? d.buttonWidth.toString().slice(0, -2) : d.buttonWidth, d.buttonWidth)), c = Y(), o = x(), m = x("auto");
456
+ let g = K();
457
457
  const n = () => {
458
458
  let f = "auto";
459
- if (p?.parent?.attrs?.class?.indexOf("content-wrap") > -1) {
459
+ if (g?.parent?.attrs?.class?.indexOf("content-wrap") > -1) {
460
460
  try {
461
- const S = p?.refs.tableRef, { top: H } = S?.getBoundingClientRect();
462
- f = document.documentElement.clientHeight - H - 65 - 20;
461
+ const H = g?.refs.tableRef, { top: M } = H?.getBoundingClientRect();
462
+ f = document.documentElement.clientHeight - M - 65 - 20;
463
463
  } catch {
464
464
  }
465
465
  return f;
466
466
  }
467
467
  return f;
468
- }, e = V(), a = () => {
468
+ }, e = x(), a = () => {
469
469
  e.value && clearTimeout(e.value), e.value = setTimeout(() => {
470
470
  m.value = n(), e.value = null;
471
471
  }, 100);
@@ -474,30 +474,30 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
474
474
  m.value = n(), window.addEventListener("resize", a);
475
475
  }), X(() => {
476
476
  window.removeEventListener("resize", a);
477
- }), (f, U) => (l(), g("div", {
477
+ }), (f, D) => (l(), p("div", {
478
478
  ref_key: "tableRef",
479
479
  ref: o
480
480
  }, [
481
- x(r(ye), v({ style: { width: "100%" } }, f.$attrs, {
481
+ $(u(ye), v({ style: { width: "100%" } }, f.$attrs, {
482
482
  data: t.data,
483
483
  height: t.height,
484
484
  maxHeight: t.maxHeight ? t.maxHeight : m.value
485
485
  }), {
486
486
  default: i(() => [
487
- (l(!0), g(C, null, y(t.tableColumns, (W, E) => (l(), u(Ne, {
487
+ (l(!0), p(C, null, y(t.tableColumns, (W, E) => (l(), r(Ye, {
488
488
  key: E,
489
489
  "table-column": { align: t.align, ...W }
490
- }, M({ _: 2 }, [
491
- y(c, (S, H) => ({
492
- name: H,
493
- fn: i(({ row: T }) => [
494
- b(f.$slots, H, { row: T }, () => [
495
- $(k(T[H]), 1)
490
+ }, I({ _: 2 }, [
491
+ y(c, (H, M) => ({
492
+ name: M,
493
+ fn: i(({ row: P }) => [
494
+ b(f.$slots, M, { row: P }, () => [
495
+ S(k(P[M]), 1)
496
496
  ], !0)
497
497
  ])
498
498
  }))
499
499
  ]), 1032, ["table-column"]))), 128)),
500
- t.buttons && t.buttons.length ? (l(), u(r(P), {
500
+ t.buttons && t.buttons.length ? (l(), r(u(T), {
501
501
  key: 0,
502
502
  align: "center",
503
503
  fixed: "right",
@@ -505,8 +505,8 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
505
505
  width: s.value
506
506
  }, {
507
507
  default: i((W) => [
508
- (l(!0), g(C, null, y(t.buttons, (E, S) => (l(), u(r(L), {
509
- key: S,
508
+ (l(!0), p(C, null, y(t.buttons, (E, H) => (l(), r(u(L), {
509
+ key: H,
510
510
  type: E.type.includes("del") ? "danger" : "primary",
511
511
  onClick: () => {
512
512
  E.click?.(W.row);
@@ -514,7 +514,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
514
514
  link: ""
515
515
  }, {
516
516
  default: i(() => [
517
- $(k(E.label), 1)
517
+ S(k(E.label), 1)
518
518
  ]),
519
519
  _: 2
520
520
  }, 1032, ["type", "onClick"]))), 128))
@@ -526,7 +526,7 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
526
526
  }, 16, ["data", "height", "maxHeight"])
527
527
  ], 512));
528
528
  }
529
- }), Te = /* @__PURE__ */ I(Pe, [["__scopeId", "data-v-283c4a1e"]]), ze = {
529
+ }), Te = /* @__PURE__ */ U(Ne, [["__scopeId", "data-v-283c4a1e"]]), ze = {
530
530
  name: "",
531
531
  components: {},
532
532
  props: {
@@ -536,13 +536,13 @@ const we = { class: "flex items-center justify-between" }, Ve = { class: "flex i
536
536
  }
537
537
  }
538
538
  };
539
- function Re(t, d, s, c, o, m) {
540
- return s.icon ? (l(), u(Z(s.icon), {
539
+ function Pe(t, d, s, c, o, m) {
540
+ return s.icon ? (l(), r(Z(s.icon), {
541
541
  key: 0,
542
542
  class: "menu_icon"
543
543
  })) : h("", !0);
544
544
  }
545
- const O = /* @__PURE__ */ I(ze, [["render", Re], ["__scopeId", "data-v-261ce99a"]]), Be = /* @__PURE__ */ w({
545
+ const j = /* @__PURE__ */ U(ze, [["render", Pe], ["__scopeId", "data-v-261ce99a"]]), Re = /* @__PURE__ */ V({
546
546
  name: "subMenu",
547
547
  __name: "subMenu",
548
548
  props: {
@@ -558,37 +558,37 @@ const O = /* @__PURE__ */ I(ze, [["render", Re], ["__scopeId", "data-v-261ce99a"
558
558
  s("handleMenuItemClick", o);
559
559
  }
560
560
  return (o, m) => {
561
- const p = A("subMenu", !0);
562
- return t.routeData.children && t.routeData.children.length > 0 ? (l(), u(r(ve), {
561
+ const g = z("subMenu", !0);
562
+ return t.routeData.children && t.routeData.children.length > 0 ? (l(), r(u(ve), {
563
563
  key: 0,
564
564
  index: t.routeData.path
565
565
  }, {
566
566
  title: i(() => [
567
- x(O, {
567
+ $(j, {
568
568
  icon: t.routeData.meta.icon
569
569
  }, null, 8, ["icon"]),
570
- D("span", null, k(t.routeData.meta.title), 1)
570
+ w("span", null, k(t.routeData.meta.title), 1)
571
571
  ]),
572
572
  default: i(() => [
573
- (l(!0), g(C, null, y(t.routeData.children, (n, e) => (l(), u(p, {
573
+ (l(!0), p(C, null, y(t.routeData.children, (n, e) => (l(), r(g, {
574
574
  onHandleMenuItemClick: c,
575
575
  routeData: n,
576
576
  key: e
577
577
  }, null, 8, ["routeData"]))), 128))
578
578
  ]),
579
579
  _: 1
580
- }, 8, ["index"])) : (l(), g("div", {
580
+ }, 8, ["index"])) : (l(), p("div", {
581
581
  key: 1,
582
582
  onClick: m[0] || (m[0] = (n) => c(t.routeData))
583
583
  }, [
584
- x(r(Ce), {
584
+ $(u(Ce), {
585
585
  index: t.routeData.path
586
586
  }, {
587
587
  title: i(() => [
588
- D("span", null, k(t.routeData.meta.title), 1)
588
+ w("span", null, k(t.routeData.meta.title), 1)
589
589
  ]),
590
590
  default: i(() => [
591
- x(O, {
591
+ $(j, {
592
592
  icon: t.routeData.meta.icon
593
593
  }, null, 8, ["icon"])
594
594
  ]),
@@ -597,7 +597,7 @@ const O = /* @__PURE__ */ I(ze, [["render", Re], ["__scopeId", "data-v-261ce99a"
597
597
  ]));
598
598
  };
599
599
  }
600
- }), Oe = /* @__PURE__ */ w({
600
+ }), Be = /* @__PURE__ */ V({
601
601
  name: "MenuTree",
602
602
  __name: "index",
603
603
  props: {
@@ -611,17 +611,17 @@ const O = /* @__PURE__ */ I(ze, [["render", Re], ["__scopeId", "data-v-261ce99a"
611
611
  const s = d, c = (o) => {
612
612
  s("handleMenuItemClick", o);
613
613
  };
614
- return (o, m) => (l(), u(r(ke), _(ee(o.$attrs)), {
614
+ return (o, m) => (l(), r(u(ke), _(ee(o.$attrs)), {
615
615
  default: i(() => [
616
- (l(!0), g(C, null, y(t.menuList, (p) => (l(), u(Be, {
617
- routeData: p,
616
+ (l(!0), p(C, null, y(t.menuList, (g) => (l(), r(Re, {
617
+ routeData: g,
618
618
  onHandleMenuItemClick: c
619
619
  }, null, 8, ["routeData"]))), 256))
620
620
  ]),
621
621
  _: 1
622
622
  }, 16));
623
623
  }
624
- }), je = /* @__PURE__ */ w({
624
+ }), Oe = /* @__PURE__ */ V({
625
625
  name: "Pagination",
626
626
  __name: "index",
627
627
  props: {
@@ -664,47 +664,50 @@ const O = /* @__PURE__ */ I(ze, [["render", Re], ["__scopeId", "data-v-261ce99a"
664
664
  set(e) {
665
665
  c("update:limit", e);
666
666
  }
667
- }), p = (e) => {
667
+ }), g = (e) => {
668
668
  o.value * e > s.total && (o.value = 1), c("pagination", { page: o.value, limit: e });
669
669
  }, n = (e) => {
670
670
  c("pagination", { page: e, limit: m.value });
671
671
  };
672
- return (e, a) => te((l(), u(r(De), {
673
- "current-page": o.value,
674
- "onUpdate:currentPage": a[0] || (a[0] = (f) => o.value = f),
675
- "page-size": m.value,
676
- "onUpdate:pageSize": a[1] || (a[1] = (f) => m.value = f),
677
- background: !0,
678
- "page-sizes": [10, 20, 30, 50, 100],
679
- "pager-count": t.pagerCount,
680
- total: t.total,
681
- class: "pagination",
682
- layout: "total, sizes, prev, pager, next, jumper",
683
- onSizeChange: p,
684
- onCurrentChange: n
685
- }, null, 8, ["current-page", "page-size", "pager-count", "total"])), [
686
- [ae, t.total > 0]
687
- ]);
672
+ return (e, a) => {
673
+ const f = z("el-pagination");
674
+ return te((l(), r(f, {
675
+ "current-page": o.value,
676
+ "onUpdate:currentPage": a[0] || (a[0] = (D) => o.value = D),
677
+ "page-size": m.value,
678
+ "onUpdate:pageSize": a[1] || (a[1] = (D) => m.value = D),
679
+ background: !0,
680
+ "page-sizes": [10, 20, 30, 50, 100],
681
+ "pager-count": t.pagerCount,
682
+ total: t.total,
683
+ class: "pagination",
684
+ layout: "total, sizes, prev, pager, next, jumper",
685
+ onSizeChange: g,
686
+ onCurrentChange: n
687
+ }, null, 8, ["current-page", "page-size", "pager-count", "total"])), [
688
+ [ae, t.total > 0]
689
+ ]);
690
+ };
688
691
  }
689
- }), Ae = /* @__PURE__ */ I(je, [["__scopeId", "data-v-e3fa4ed7"]]), Le = [
690
- Me,
691
- Ue,
692
- Ye,
692
+ }), je = /* @__PURE__ */ U(Oe, [["__scopeId", "data-v-1e34e383"]]), Ae = [
693
+ He,
694
+ Ie,
695
+ Fe,
693
696
  Te,
694
- Oe,
695
- Ae
696
- ], j = [], qe = (t) => {
697
- Le.forEach((d) => {
698
- j.push(d.name), t.component(d.name, d);
699
- }), console.log("mwl-components", j);
700
- }, Ke = { install: qe };
697
+ Be,
698
+ je
699
+ ], A = [], Le = (t) => {
700
+ Ae.forEach((d) => {
701
+ A.push(d.name), t.component(d.name, d);
702
+ }), console.log("mwl-components", A);
703
+ }, Je = { install: Le };
701
704
  export {
702
- Me as ContentWarp,
703
- Ue as Dialog,
704
- Ye as EasyForm,
705
+ He as ContentWarp,
706
+ Ie as Dialog,
707
+ Fe as EasyForm,
705
708
  Te as EasyTable,
706
- Oe as MenuTree,
707
- Ae as Pagination,
708
- Ke as default,
709
- qe as install
709
+ Be as MenuTree,
710
+ je as Pagination,
711
+ Je as default,
712
+ Le as install
710
713
  };
@@ -1 +1 @@
1
- .el-card[data-v-cce44bc6]{background-color:transparent;margin-bottom:10px}[data-v-cce44bc6] .el-card__body:has(>.el-form){padding:18px 20px 0}[data-v-cce44bc6] .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-84850699] .el-form-item__label{font-size:var(--el-font-size-base)}[data-v-283c4a1e] .el-table,[data-v-283c4a1e] th.el-table__cell,[data-v-283c4a1e] 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-e3fa4ed7]{margin-top:15px;margin-bottom:15px;float:right}@media screen and (max-width: 1370px){.pagination[data-v-e3fa4ed7]{margin-top:8px;margin-bottom:8px}}
1
+ .el-card[data-v-cce44bc6]{background-color:transparent;margin-bottom:10px}[data-v-cce44bc6] .el-card__body:has(>.el-form){padding:18px 20px 0}[data-v-cce44bc6] .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-84850699] .el-form-item__label{font-size:var(--el-font-size-base)}[data-v-283c4a1e] .el-table,[data-v-283c4a1e] th.el-table__cell,[data-v-283c4a1e] 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}}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mwl-components",
3
- "version": "0.0.14",
3
+ "version": "0.0.15",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "module": "dist/index.js",