view-ui-plus-derive 0.2.0 → 0.2.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.
package/dist/index.js CHANGED
@@ -1,25 +1,25 @@
1
- import { defineComponent as U, shallowRef as Ce, computed as P, onMounted as se, watch as I, createElementBlock as j, openBlock as D, withDirectives as _, createVNode as O, unref as n, withCtx as C, createTextVNode as H, toDisplayString as z, vShow as ie, Fragment as W, renderList as Z, createBlock as E, renderSlot as w, ref as L, mergeProps as K, useSlots as Ge, normalizeClass as F, createCommentVNode as J, createElementVNode as Q, nextTick as G, shallowReactive as Ie, useTemplateRef as re, normalizeProps as Be, guardReactiveProps as Ve, getCurrentInstance as me, createSlots as ze, onBeforeUnmount as Fe, mergeModels as Ae, useModel as Je, reactive as qe } from "vue";
2
- import { Checkbox as ne, CheckboxGroup as We, Switch as Xe, InputNumber as Re, Select as Ze, Option as Qe, DatePicker as ke, Table as He, Button as X, Row as fe, Col as oe, Spin as _e, Dropdown as et, Icon as ce, DropdownMenu as tt, DropdownItem as at, Tooltip as Me, Page as lt } from "view-ui-plus";
3
- import { getPathValue as ge, setPathValue as nt, deepMerge as ot, makeObjectByPath as it, omitOwnKeys as ut } from "utils-where";
4
- import st from "./locale/zh-CN.js";
1
+ import { defineComponent as Y, shallowRef as Ce, computed as N, onMounted as de, watch as I, createElementBlock as j, openBlock as D, withDirectives as te, createVNode as $, unref as o, withCtx as C, createTextVNode as H, toDisplayString as z, vShow as ue, Fragment as X, renderList as _, createBlock as L, renderSlot as M, ref as E, mergeProps as U, useSlots as qe, normalizeClass as F, createCommentVNode as q, createElementVNode as ee, nextTick as G, shallowReactive as ze, useTemplateRef as ce, normalizeProps as Be, guardReactiveProps as Ve, getCurrentInstance as me, createSlots as Fe, onBeforeUnmount as He, mergeModels as Ae, useModel as We, reactive as Xe } from "vue";
2
+ import { Checkbox as oe, CheckboxGroup as Ze, Switch as Qe, InputNumber as Re, Select as _e, Option as et, DatePicker as ke, Table as je, Button as Z, Row as ge, Col as ie, Spin as tt, Dropdown as at, Icon as fe, DropdownMenu as lt, DropdownItem as nt, Tooltip as we, Page as ot } from "view-ui-plus";
3
+ import { getPathValue as Q, omitOwnKeys as Ne, isObject as Me, setPathValue as it, deepMerge as ut, makeObjectByPath as st } from "utils-where";
4
+ import dt from "./locale/zh-CN.js";
5
5
  /* empty css */
6
6
  /* empty css */
7
- import { i as je } from "./directives/v-iview-select.js";
7
+ import { i as Pe } from "./directives/v-iview-select.js";
8
8
  /* empty css */
9
9
  /* empty css */
10
10
  /* empty css */
11
11
  /* empty css */
12
- const M = {
12
+ const w = {
13
13
  i18n: null,
14
14
  prefix: "d",
15
- msg: st,
15
+ msg: dt,
16
16
  t(t, ...S) {
17
- return M.i18n?.global.t(M.prefix + "." + t, ...S) ?? ge(M.msg, M.prefix + "." + t) ?? t;
17
+ return w.i18n?.global.t(w.prefix + "." + t, ...S) ?? Q(w.msg, w.prefix + "." + t) ?? t;
18
18
  }
19
- }, dt = {
19
+ }, rt = {
20
20
  name: "AllCheckbox"
21
- }, rt = /* @__PURE__ */ U({
22
- ...dt,
21
+ }, ct = /* @__PURE__ */ Y({
22
+ ...rt,
23
23
  props: {
24
24
  modelValue: Array,
25
25
  /**
@@ -70,54 +70,54 @@ const M = {
70
70
  },
71
71
  emits: ["update:modelValue", "update:all", "change"],
72
72
  setup(t, { emit: S }) {
73
- const a = t, e = S, l = Ce(a.modelValue || []), o = P({
73
+ const a = t, e = S, l = Ce(a.modelValue || []), i = N({
74
74
  get() {
75
75
  return l.value.length === a.list.length;
76
76
  },
77
- set(p) {
78
- l.value = p ? a.list.map((b) => b[a.keyMap.value]) : [];
77
+ set(c) {
78
+ l.value = c ? a.list.map((v) => v[a.keyMap.value]) : [];
79
79
  }
80
- }), i = P(
80
+ }), u = N(
81
81
  () => l.value.length > 0 && l.value.length < a.list.length
82
82
  );
83
- function h() {
84
- e("update:modelValue", l.value), e("update:all", o.value), e("change", l.value, o.value);
83
+ function p() {
84
+ e("update:modelValue", l.value), e("update:all", i.value), e("change", l.value, i.value);
85
85
  }
86
- return se(() => {
87
- e("update:all", o.value);
86
+ return de(() => {
87
+ e("update:all", i.value);
88
88
  }), I(
89
89
  () => a.modelValue,
90
- (p) => {
91
- l.value !== p && (l.value = p || [], e("update:all", o.value));
90
+ (c) => {
91
+ l.value !== c && (l.value = c || [], e("update:all", i.value));
92
92
  }
93
- ), (p, b) => (D(), j("div", null, [
94
- _(O(n(ne), {
95
- modelValue: o.value,
96
- "onUpdate:modelValue": b[0] || (b[0] = (v) => o.value = v),
97
- indeterminate: i.value,
98
- onOnChange: h
93
+ ), (c, v) => (D(), j("div", null, [
94
+ te($(o(oe), {
95
+ modelValue: i.value,
96
+ "onUpdate:modelValue": v[0] || (v[0] = (b) => i.value = b),
97
+ indeterminate: u.value,
98
+ onOnChange: p
99
99
  }, {
100
100
  default: C(() => [
101
- H(z(t.title ?? n(M).t("allCheckbox.title")), 1)
101
+ H(z(t.title ?? o(w).t("allCheckbox.title")), 1)
102
102
  ]),
103
103
  _: 1
104
104
  }, 8, ["modelValue", "indeterminate"]), [
105
- [ie, !t.hideAll]
105
+ [ue, !t.hideAll]
106
106
  ]),
107
- O(n(We), {
107
+ $(o(Ze), {
108
108
  modelValue: l.value,
109
- "onUpdate:modelValue": b[1] || (b[1] = (v) => l.value = v),
109
+ "onUpdate:modelValue": v[1] || (v[1] = (b) => l.value = b),
110
110
  class: "ivu-inline-block",
111
- onOnChange: h
111
+ onOnChange: p
112
112
  }, {
113
113
  default: C(() => [
114
- (D(!0), j(W, null, Z(t.list, (v) => (D(), E(n(ne), {
115
- key: v[t.keyMap.value],
116
- label: v[t.keyMap.value]
114
+ (D(!0), j(X, null, _(t.list, (b) => (D(), L(o(oe), {
115
+ key: b[t.keyMap.value],
116
+ label: b[t.keyMap.value]
117
117
  }, {
118
118
  default: C(() => [
119
- w(p.$slots, "default", { item: v }, () => [
120
- H(z(v[t.keyMap.label]), 1)
119
+ M(c.$slots, "default", { item: b }, () => [
120
+ H(z(b[t.keyMap.label]), 1)
121
121
  ])
122
122
  ]),
123
123
  _: 2
@@ -127,10 +127,10 @@ const M = {
127
127
  }, 8, ["modelValue"])
128
128
  ]));
129
129
  }
130
- }), ct = {
130
+ }), ft = {
131
131
  name: "BaseSwitch"
132
- }, ft = /* @__PURE__ */ U({
133
- ...ct,
132
+ }, gt = /* @__PURE__ */ Y({
133
+ ...ft,
134
134
  props: {
135
135
  modelValue: [String, Number, Boolean],
136
136
  /**
@@ -158,29 +158,29 @@ const M = {
158
158
  },
159
159
  emits: ["update:modelValue", "change"],
160
160
  setup(t, { emit: S }) {
161
- const a = t, e = S, l = L(a.modelValue), o = (i) => {
162
- e("update:modelValue", i), e("change", i);
161
+ const a = t, e = S, l = E(a.modelValue), i = (u) => {
162
+ e("update:modelValue", u), e("change", u);
163
163
  };
164
164
  return I(
165
165
  () => a.modelValue,
166
- (i) => {
167
- l.value !== i && (l.value = i);
166
+ (u) => {
167
+ l.value !== u && (l.value = u);
168
168
  }
169
- ), (i, h) => (D(), E(n(Xe), K({
169
+ ), (u, p) => (D(), L(o(Qe), U({
170
170
  modelValue: l.value,
171
- "onUpdate:modelValue": h[0] || (h[0] = (p) => l.value = p),
172
- onOnChange: o
173
- }, i.$attrs, {
171
+ "onUpdate:modelValue": p[0] || (p[0] = (c) => l.value = c),
172
+ onOnChange: i
173
+ }, u.$attrs, {
174
174
  trueValue: t.trueValue,
175
175
  falseValue: t.falseValue
176
176
  }), {
177
177
  open: C(() => [
178
- w(i.$slots, "open", {}, () => [
178
+ M(u.$slots, "open", {}, () => [
179
179
  H(z(t.trueLabel), 1)
180
180
  ])
181
181
  ]),
182
182
  close: C(() => [
183
- w(i.$slots, "close", {}, () => [
183
+ M(u.$slots, "close", {}, () => [
184
184
  H(z(t.falseLabel), 1)
185
185
  ])
186
186
  ]),
@@ -190,16 +190,16 @@ const M = {
190
190
  }), Se = [], R = (t) => (
191
191
  // const prefix = inject(classSymbol, '') as string
192
192
  Se[0] ? Se[0].replace(/\B([A-Z])/g, "-$1").toLowerCase() + "-" + t : t
193
- ), gt = {
193
+ ), mt = {
194
194
  key: 0,
195
195
  class: "ivu-input-group-prepend"
196
- }, mt = {
196
+ }, ht = {
197
197
  key: 1,
198
198
  class: "ivu-input-group-append"
199
- }, ht = {
199
+ }, pt = {
200
200
  name: "Combi"
201
- }, pt = /* @__PURE__ */ U({
202
- ...ht,
201
+ }, bt = /* @__PURE__ */ Y({
202
+ ...pt,
203
203
  props: {
204
204
  /**
205
205
  * 前置文本
@@ -211,30 +211,30 @@ const M = {
211
211
  append: String
212
212
  },
213
213
  setup(t) {
214
- const S = Ge(), a = t, e = P(() => !!a.prepend || !!S.prepend?.().length), l = P(() => !!a.append || !!S.append?.().length);
215
- return (o, i) => (D(), j("div", {
216
- class: F([n(R)("combi"), "ivu-input-group"])
214
+ const S = qe(), a = t, e = N(() => !!a.prepend || !!S.prepend?.().length), l = N(() => !!a.append || !!S.append?.().length);
215
+ return (i, u) => (D(), j("div", {
216
+ class: F([o(R)("combi"), "ivu-input-group"])
217
217
  }, [
218
- e.value ? (D(), j("div", gt, [
219
- w(o.$slots, "prepend", {}, () => [
218
+ e.value ? (D(), j("div", mt, [
219
+ M(i.$slots, "prepend", {}, () => [
220
220
  H(z(t.prepend), 1)
221
221
  ])
222
- ])) : J("", !0),
223
- Q("div", {
224
- class: F([n(R)("combi-cell"), { "with-append": l.value, "with-prepend": e.value }])
222
+ ])) : q("", !0),
223
+ ee("div", {
224
+ class: F([o(R)("combi-cell"), { "with-append": l.value, "with-prepend": e.value }])
225
225
  }, [
226
- w(o.$slots, "default")
226
+ M(i.$slots, "default")
227
227
  ], 2),
228
- l.value ? (D(), j("div", mt, [
229
- w(o.$slots, "append", {}, () => [
228
+ l.value ? (D(), j("div", ht, [
229
+ M(i.$slots, "append", {}, () => [
230
230
  H(z(t.append), 1)
231
231
  ])
232
- ])) : J("", !0)
232
+ ])) : q("", !0)
233
233
  ], 2));
234
234
  }
235
235
  }), vt = {
236
236
  name: "CountRange"
237
- }, bt = /* @__PURE__ */ U({
237
+ }, yt = /* @__PURE__ */ Y({
238
238
  ...vt,
239
239
  props: {
240
240
  /**
@@ -326,10 +326,10 @@ const M = {
326
326
  },
327
327
  emits: ["update:begin", "update:end", "change-min", "change-max", "change"],
328
328
  setup(t, { emit: S }) {
329
- const a = t, e = S, l = L(a.begin), o = L(a.end), i = P(() => ({
329
+ const a = t, e = S, l = E(a.begin), i = E(a.end), u = N(() => ({
330
330
  min: a.min,
331
331
  max: a.max,
332
- placeholder: a.minHolder ?? M.t("countRange.minHolder"),
332
+ placeholder: a.minHolder ?? w.t("countRange.minHolder"),
333
333
  disabled: a.disabled || a.minDisabled,
334
334
  class: a.minClass,
335
335
  controlsOutside: a.controlsOutside,
@@ -341,10 +341,10 @@ const M = {
341
341
  parser: a.parser,
342
342
  activeChange: a.activeChange,
343
343
  ...a.minAttr
344
- })), h = P(() => ({
344
+ })), p = N(() => ({
345
345
  min: l.value,
346
346
  max: a.max,
347
- placeholder: a.maxHolder ?? M.t("countRange.maxHolder"),
347
+ placeholder: a.maxHolder ?? w.t("countRange.maxHolder"),
348
348
  disabled: a.disabled || a.maxDisabled,
349
349
  class: a.maxClass,
350
350
  controlsOutside: a.controlsOutside,
@@ -356,40 +356,40 @@ const M = {
356
356
  parser: a.parser,
357
357
  activeChange: l.value ? !1 : a.activeChange,
358
358
  ...a.maxAttr
359
- })), p = () => {
360
- e("update:begin", l.value), e("update:end", o.value);
361
- }, b = (d) => {
362
- o.value != null && d > o.value && (o.value = d + 1 > h.value.max ? h.value.max : d + 1), p(), e("change-min", d), e("change", d, o.value, !1);
363
- }, v = (d) => {
364
- p(), e("change-max", d), e("change", l.value, d, !0);
365
- }, c = (d) => {
366
- l.value !== d && (l.value = d !== void 0 ? d : null);
367
- }, T = (d) => {
368
- o.value !== d && (o.value = d !== void 0 ? d : null);
359
+ })), c = () => {
360
+ e("update:begin", l.value), e("update:end", i.value);
361
+ }, v = (r) => {
362
+ i.value != null && r > i.value && (i.value = r + 1 > p.value.max ? p.value.max : r + 1), c(), e("change-min", r), e("change", r, i.value, !1);
363
+ }, b = (r) => {
364
+ c(), e("change-max", r), e("change", l.value, r, !0);
365
+ }, d = (r) => {
366
+ l.value !== r && (l.value = r !== void 0 ? r : null);
367
+ }, T = (r) => {
368
+ i.value !== r && (i.value = r !== void 0 ? r : null);
369
369
  };
370
- return I(() => a.begin, c), I(() => a.end, T), (d, y) => (D(), j("div", {
371
- class: F(n(R)("count-range"))
370
+ return I(() => a.begin, d), I(() => a.end, T), (r, y) => (D(), j("div", {
371
+ class: F(o(R)("count-range"))
372
372
  }, [
373
- O(n(Re), K({
373
+ $(o(Re), U({
374
374
  modelValue: l.value,
375
375
  "onUpdate:modelValue": y[0] || (y[0] = (B) => l.value = B)
376
- }, i.value, { onOnChange: b }), null, 16, ["modelValue"]),
377
- _(Q("span", {
378
- class: F([n(R)("count-range-joiner"), t.joinerClass])
376
+ }, u.value, { onOnChange: v }), null, 16, ["modelValue"]),
377
+ te(ee("span", {
378
+ class: F([o(R)("count-range-joiner"), t.joinerClass])
379
379
  }, null, 2), [
380
- [ie, !t.hideJoiner]
380
+ [ue, !t.hideJoiner]
381
381
  ]),
382
- O(n(Re), K({
383
- modelValue: o.value,
384
- "onUpdate:modelValue": y[1] || (y[1] = (B) => o.value = B)
385
- }, h.value, { onOnChange: v }), null, 16, ["modelValue"])
382
+ $(o(Re), U({
383
+ modelValue: i.value,
384
+ "onUpdate:modelValue": y[1] || (y[1] = (B) => i.value = B)
385
+ }, p.value, { onOnChange: b }), null, 16, ["modelValue"])
386
386
  ], 2));
387
387
  }
388
- }), yt = { key: 1 }, kt = {
388
+ }), kt = { key: 1 }, St = {
389
389
  name: "RemoteSelect",
390
390
  inheritAttrs: !1
391
- }, Pe = /* @__PURE__ */ U({
392
- ...kt,
391
+ }, Ee = /* @__PURE__ */ Y({
392
+ ...St,
393
393
  props: {
394
394
  modelValue: [String, Array, Number],
395
395
  list: Array,
@@ -480,106 +480,106 @@ const M = {
480
480
  },
481
481
  emits: ["update:modelValue", "update:chosen", "update:list", "update:refresh", "load"],
482
482
  setup(t, { expose: S, emit: a }) {
483
- const e = t, l = a, o = L(e.modelValue ?? ""), i = L([]), h = L(!1), p = L({}), b = P(
484
- () => p.value && Object.keys(p.value).length > 0 ? typeof e.textFormat != "function" ? e.multiple ? p.value.map((u) => u[e.keyMap.label]).join(",") : p.value[e.keyMap.label] : e.textFormat(p.value) : ""
485
- ), v = L(!1);
486
- let c, T, d, y;
483
+ const e = t, l = a, i = E(e.modelValue ?? ""), u = E([]), p = E(!1), c = E({}), v = N(
484
+ () => c.value && Object.keys(c.value).length > 0 ? typeof e.textFormat != "function" ? e.multiple ? c.value.map((s) => s[e.keyMap.label]).join(",") : c.value[e.keyMap.label] : e.textFormat(c.value) : ""
485
+ ), b = E(!1);
486
+ let d, T, r, y;
487
487
  async function B() {
488
- let u;
488
+ let s;
489
489
  if (typeof e.loader != "function") {
490
490
  if (typeof e.method != "function") {
491
491
  console.warn("typeof method isn't function");
492
492
  return;
493
493
  }
494
- if (h.value = !0, u = await e.method(typeof e.param != "function" ? e.param : e.param()), h.value = !1, u && typeof e.process == "function") {
495
- const k = e.process(u);
496
- k != null && (u = k);
494
+ if (p.value = !0, s = await e.method(typeof e.param != "function" ? e.param : e.param()), p.value = !1, s && typeof e.process == "function") {
495
+ const k = e.process(s);
496
+ k != null && (s = k);
497
497
  }
498
498
  } else
499
- h.value = !0, u = await e.loader(), h.value = !1;
500
- u && (v.value = !0, i.value = u, l("update:list", u), V() && N(o.value), c = !0, G(() => {
501
- c = null;
502
- }), l("load", u));
499
+ p.value = !0, s = await e.loader(), p.value = !1;
500
+ s && (b.value = !0, u.value = s, l("update:list", s), V() && P(i.value), d = !0, G(() => {
501
+ d = null;
502
+ }), l("load", s));
503
503
  }
504
- function N(u) {
504
+ function P(s) {
505
505
  T = !0, G(() => {
506
506
  T = null;
507
- }), d && (e.multiple ? !u.toString().length : u === void 0) && (o.value = u = d), p.value = e.getSelected({
507
+ }), r && (e.multiple ? !s.toString().length : s === void 0) && (i.value = s = r), c.value = e.getSelected({
508
508
  multiple: e.multiple,
509
509
  keyMap: e.keyMap,
510
- list: i.value,
511
- value: o.value
512
- }), l("update:modelValue", u ?? ""), l("update:chosen", p.value);
510
+ list: u.value,
511
+ value: i.value
512
+ }), l("update:modelValue", s ?? ""), l("update:chosen", c.value);
513
513
  }
514
- function f(u) {
515
- u && !e.autoGet && !h.value && !v.value && (!e.check || e.check()) && (!e.strict || e.parentCode) && B();
514
+ function f(s) {
515
+ s && !e.autoGet && !p.value && !b.value && (!e.check || e.check()) && (!e.strict || e.parentCode) && B();
516
516
  }
517
517
  function V() {
518
- return o.value != null && o.value.toString().length > 0;
518
+ return i.value != null && i.value.toString().length > 0;
519
519
  }
520
- return l("update:refresh", B), se(() => {
521
- e.autoGet ? B() : V() && !i.value.length && f(!0);
520
+ return l("update:refresh", B), de(() => {
521
+ e.autoGet ? B() : V() && !u.value.length && f(!0);
522
522
  }), S({
523
- code: o,
524
- changeCode: N,
525
- loaded: v,
526
- codes: i,
523
+ code: i,
524
+ changeCode: P,
525
+ loaded: b,
526
+ codes: u,
527
527
  search: B
528
528
  }), I(
529
529
  () => e.list,
530
- (u) => {
531
- c || (u && u.length ? (i.value = u, v.value = !!e.cache) : (i.value = [], v.value = !1));
530
+ (s) => {
531
+ d || (s && s.length ? (u.value = s, b.value = !!e.cache) : (u.value = [], b.value = !1));
532
532
  },
533
533
  { immediate: !0 }
534
534
  ), I(
535
535
  () => e.modelValue,
536
- (u) => {
536
+ (s) => {
537
537
  if (!T && (y = !0, G(() => {
538
538
  y = null;
539
- }), o.value = u ?? "", N(o.value), e.refresh !== B)) {
540
- for (const k in p.value)
539
+ }), i.value = s ?? "", P(i.value), e.refresh !== B)) {
540
+ for (const k in c.value)
541
541
  return;
542
542
  f(V());
543
543
  }
544
544
  }
545
545
  ), I(
546
546
  () => e.parentCode,
547
- (u) => {
548
- y ? (d = e.modelValue, setTimeout(() => {
549
- d = null;
550
- })) : o.value = e.multiple ? [] : "", i.value = [], v.value = !1, l("update:list", i.value), V() && u && /* !this.opening && */
547
+ (s) => {
548
+ y ? (r = e.modelValue, setTimeout(() => {
549
+ r = null;
550
+ })) : i.value = e.multiple ? [] : "", u.value = [], b.value = !1, l("update:list", u.value), V() && s && /* !this.opening && */
551
551
  f(!0);
552
552
  }
553
- ), (u, k) => t.textMode ? (D(), j("span", yt, [
554
- w(u.$slots, "text", { text: b.value }, () => [
555
- H(z(b.value), 1)
553
+ ), (s, k) => t.textMode ? (D(), j("span", kt, [
554
+ M(s.$slots, "text", { text: v.value }, () => [
555
+ H(z(v.value), 1)
556
556
  ])
557
- ])) : _((D(), E(n(Ze), K({
557
+ ])) : te((D(), L(o(_e), U({
558
558
  key: 0,
559
- modelValue: o.value,
560
- "onUpdate:modelValue": k[0] || (k[0] = (r) => o.value = r),
559
+ modelValue: i.value,
560
+ "onUpdate:modelValue": k[0] || (k[0] = (h) => i.value = h),
561
561
  onOnOpenChange: f,
562
- onOnChange: N
563
- }, u.$attrs, {
562
+ onOnChange: P
563
+ }, s.$attrs, {
564
564
  multiple: t.multiple,
565
- loading: h.value,
566
- "not-found-text": h.value ? null : void 0
565
+ loading: p.value,
566
+ "not-found-text": p.value ? null : void 0
567
567
  }), {
568
568
  default: C(() => [
569
- w(u.$slots, "dropdown", { list: i.value }, () => [
570
- (D(!0), j(W, null, Z(i.value, (r, s) => (D(), E(n(Qe), {
571
- key: e.valueAsKey ? r[t.keyMap.value] : s,
572
- value: r[t.keyMap.value],
573
- label: t.formatLabel && t.formatLabel(r, s),
574
- disabled: t.optionDisabled && t.optionDisabled(r, s),
575
- tag: t.optionTag && t.optionTag(r, s)
569
+ M(s.$slots, "dropdown", { list: u.value }, () => [
570
+ (D(!0), j(X, null, _(u.value, (h, n) => (D(), L(o(et), {
571
+ key: e.valueAsKey ? h[t.keyMap.value] : n,
572
+ value: h[t.keyMap.value],
573
+ label: t.formatLabel && t.formatLabel(h, n),
574
+ disabled: t.optionDisabled && t.optionDisabled(h, n),
575
+ tag: t.optionTag && t.optionTag(h, n)
576
576
  }, {
577
577
  default: C(() => [
578
- w(u.$slots, "default", {
579
- item: r,
580
- index: s
578
+ M(s.$slots, "default", {
579
+ item: h,
580
+ index: n
581
581
  }, () => [
582
- H(z(r[t.keyMap.label]), 1)
582
+ H(z(h[t.keyMap.label]), 1)
583
583
  ])
584
584
  ]),
585
585
  _: 2
@@ -588,20 +588,20 @@ const M = {
588
588
  ]),
589
589
  _: 3
590
590
  }, 16, ["modelValue", "multiple", "loading", "not-found-text"])), [
591
- [n(je), t.all, "all"]
591
+ [o(Pe), t.all, "all"]
592
592
  ]);
593
593
  }
594
- }), be = {
594
+ }), ve = {
595
595
  list: null
596
- }, te = Ie({}), ae = {
596
+ }, ae = ze({}), le = {
597
597
  list: []
598
- }, le = {
598
+ }, ne = {
599
599
  list: []
600
- }, ye = {}, St = {
600
+ }, ye = {}, Ct = {
601
601
  name: "CacheSelect",
602
602
  inheritAttrs: !1
603
- }, Ct = /* @__PURE__ */ U({
604
- ...St,
603
+ }, Bt = /* @__PURE__ */ Y({
604
+ ...Ct,
605
605
  props: {
606
606
  modelValue: [String, Array, Number],
607
607
  /**
@@ -614,64 +614,64 @@ const M = {
614
614
  },
615
615
  emits: ["update:modelValue", "update:chosen", "update:list", "load", "change"],
616
616
  setup(t, { emit: S }) {
617
- const a = t, e = S, l = L(""), o = re("sel"), i = (b) => {
618
- e("update:modelValue", b), e("change", b);
619
- }, h = (b) => {
617
+ const a = t, e = S, l = E(""), i = ce("sel"), u = (v) => {
618
+ e("update:modelValue", v), e("change", v);
619
+ }, p = (v) => {
620
620
  G(() => {
621
- ae[a.cacheId] && (ae[a.cacheId].forEach((v) => {
622
- v.changeCode(v.code);
623
- }), ae[a.cacheId] = []), le[a.cacheId] && (le[a.cacheId].forEach((v) => {
624
- v !== o.value && v.$emit("update:list", v.codes);
625
- }), le[a.cacheId] = []);
626
- }), e("load", b);
627
- }, p = () => l.value != null && l.value.toString().length > 0;
621
+ le[a.cacheId] && (le[a.cacheId].forEach((b) => {
622
+ b.changeCode(b.code);
623
+ }), le[a.cacheId] = []), ne[a.cacheId] && (ne[a.cacheId].forEach((b) => {
624
+ b !== i.value && b.$emit("update:list", b.codes);
625
+ }), ne[a.cacheId] = []);
626
+ }), e("load", v);
627
+ }, c = () => l.value != null && l.value.toString().length > 0;
628
628
  return I(
629
629
  () => a.modelValue,
630
- (b) => {
631
- l.value !== b && (l.value = b ?? "");
630
+ (v) => {
631
+ l.value !== v && (l.value = v ?? "");
632
632
  }
633
- ), te[a.cacheId] || (te[a.cacheId] = [], be[a.cacheId] = null), se(() => {
634
- te[a.cacheId].length && (o.value.loaded = !0), a.modelValue && (l.value = a.modelValue), be[a.cacheId] ? (p() && (ae[a.cacheId] || (ae[a.cacheId] = []), ae[a.cacheId].push(o.value)), o.value.loaded = ye[a.cacheId]) : be[a.cacheId] = !0, le[a.cacheId] || (le[a.cacheId] = []), le[a.cacheId].push(o.value), ye[a.cacheId] || (ye[a.cacheId] = p()), I(
635
- () => te[a.cacheId],
636
- (b) => {
637
- b.length && (o.value.loaded = !0);
633
+ ), ae[a.cacheId] || (ae[a.cacheId] = [], ve[a.cacheId] = null), de(() => {
634
+ ae[a.cacheId].length && (i.value.loaded = !0), a.modelValue && (l.value = a.modelValue), ve[a.cacheId] ? (c() && (le[a.cacheId] || (le[a.cacheId] = []), le[a.cacheId].push(i.value)), i.value.loaded = ye[a.cacheId]) : ve[a.cacheId] = !0, ne[a.cacheId] || (ne[a.cacheId] = []), ne[a.cacheId].push(i.value), ye[a.cacheId] || (ye[a.cacheId] = c()), I(
635
+ () => ae[a.cacheId],
636
+ (v) => {
637
+ v.length && (i.value.loaded = !0);
638
638
  },
639
639
  {
640
640
  immediate: !0
641
641
  }
642
642
  );
643
- }), (b, v) => (D(), E(Pe, K({
643
+ }), (v, b) => (D(), L(Ee, U({
644
644
  ref: "sel",
645
645
  modelValue: l.value,
646
- "onUpdate:modelValue": v[0] || (v[0] = (c) => l.value = c),
647
- list: n(te)[t.cacheId],
646
+ "onUpdate:modelValue": b[0] || (b[0] = (d) => l.value = d),
647
+ list: o(ae)[t.cacheId],
648
648
  "onUpdate:list": [
649
- v[1] || (v[1] = (c) => n(te)[t.cacheId] = c),
650
- v[3] || (v[3] = (c) => b.$emit("update:list", c))
649
+ b[1] || (b[1] = (d) => o(ae)[t.cacheId] = d),
650
+ b[3] || (b[3] = (d) => v.$emit("update:list", d))
651
651
  ],
652
- onLoad: h,
653
- onOnChange: i,
654
- "onUpdate:chosen": v[2] || (v[2] = (c) => b.$emit("update:chosen", c))
655
- }, b.$attrs, { cache: "" }), {
656
- default: C(({ item: c, index: T }) => [
657
- w(b.$slots, "default", {
658
- item: c,
652
+ onLoad: p,
653
+ onOnChange: u,
654
+ "onUpdate:chosen": b[2] || (b[2] = (d) => v.$emit("update:chosen", d))
655
+ }, v.$attrs, { cache: "" }), {
656
+ default: C(({ item: d, index: T }) => [
657
+ M(v.$slots, "default", {
658
+ item: d,
659
659
  index: T
660
660
  })
661
661
  ]),
662
- dropdown: C(({ list: c }) => [
663
- w(b.$slots, "dropdown", { list: c })
662
+ dropdown: C(({ list: d }) => [
663
+ M(v.$slots, "dropdown", { list: d })
664
664
  ]),
665
- text: C((c) => [
666
- w(b.$slots, "text", Be(Ve(c)))
665
+ text: C((d) => [
666
+ M(v.$slots, "text", Be(Ve(d)))
667
667
  ]),
668
668
  _: 3
669
669
  }, 16, ["modelValue", "list"]));
670
670
  }
671
- }), Bt = {
671
+ }), Vt = {
672
672
  name: "DateRange"
673
- }, Vt = /* @__PURE__ */ U({
674
- ...Bt,
673
+ }, Dt = /* @__PURE__ */ Y({
674
+ ...Vt,
675
675
  props: {
676
676
  /**
677
677
  * 双向绑定开始时间
@@ -761,64 +761,64 @@ const M = {
761
761
  month: "month",
762
762
  year: "year",
763
763
  datetime: "day"
764
- }, l = t, o = S, i = L(l.begin), h = L(l.end), p = P(() => ({
764
+ }, l = t, i = S, u = E(l.begin), p = E(l.end), c = N(() => ({
765
765
  options: l.limitBegin ? {
766
766
  disabledDate: (B) => B && a(B).isBefore(Date.now(), e[l.type])
767
767
  // date.valueOf() < Date.now() - (props.disableToday ? 0 : 86400000)
768
768
  } : void 0,
769
769
  disabled: l.disabled || l.beginDisabled,
770
- placeholder: l.beginHolder ?? M.t("dateRange.beginHolder"),
770
+ placeholder: l.beginHolder ?? w.t("dateRange.beginHolder"),
771
771
  class: l.beginClass,
772
772
  clearable: l.clearable,
773
773
  transfer: l.transfer,
774
774
  format: l.format,
775
775
  ...l.beginAttr
776
- })), b = P(() => ({
776
+ })), v = N(() => ({
777
777
  options: {
778
- disabledDate: (B) => i.value && B && a(B).isBefore(i.value, e[l.type])
778
+ disabledDate: (B) => u.value && B && a(B).isBefore(u.value, e[l.type])
779
779
  },
780
780
  disabled: l.disabled || l.endDisabled,
781
- placeholder: l.endHolder ?? M.t("dateRange.endHolder"),
781
+ placeholder: l.endHolder ?? w.t("dateRange.endHolder"),
782
782
  class: l.endClass,
783
783
  clearable: l.clearable,
784
784
  transfer: l.transfer,
785
785
  format: l.format,
786
786
  ...l.endAttr
787
- })), v = () => {
788
- o("update:begin", i.value), o("update:end", h.value);
789
- }, c = (B) => {
790
- i.value > h.value && (h.value = l.autoNext ? a(i.value).add(1, e[l.type]).toDate() : ""), v(), o("change-begin", B), o("change", i.value, h.value, !1);
791
- }, T = (B) => {
792
- l.type === "datetime" && B && a(B).isBefore(i.value) && (h.value = a(i.value).add(1, "hour").toDate(), B = a(h.value).format("YYYY-MM-DD HH:mm:ss")), v(), o("change-end", B), o("change", i.value, h.value, !0);
787
+ })), b = () => {
788
+ i("update:begin", u.value), i("update:end", p.value);
793
789
  }, d = (B) => {
794
- i.value !== B && (i.value = B || "");
790
+ u.value > p.value && (p.value = l.autoNext ? a(u.value).add(1, e[l.type]).toDate() : ""), b(), i("change-begin", B), i("change", u.value, p.value, !1);
791
+ }, T = (B) => {
792
+ l.type === "datetime" && B && a(B).isBefore(u.value) && (p.value = a(u.value).add(1, "hour").toDate(), B = a(p.value).format("YYYY-MM-DD HH:mm:ss")), b(), i("change-end", B), i("change", u.value, p.value, !0);
793
+ }, r = (B) => {
794
+ u.value !== B && (u.value = B || "");
795
795
  }, y = (B) => {
796
- h.value !== B && (h.value = B || "");
796
+ p.value !== B && (p.value = B || "");
797
797
  };
798
- return I(() => l.begin, d), I(() => l.end, y), (B, N) => (D(), j("div", {
799
- class: F(n(R)("date-range"))
798
+ return I(() => l.begin, r), I(() => l.end, y), (B, P) => (D(), j("div", {
799
+ class: F(o(R)("date-range"))
800
800
  }, [
801
- O(n(ke), K({
802
- modelValue: i.value,
803
- "onUpdate:modelValue": N[0] || (N[0] = (f) => i.value = f),
804
- onOnChange: c
805
- }, p.value, { type: t.type }), null, 16, ["modelValue", "type"]),
806
- _(Q("span", {
807
- class: F([n(R)("date-range-joiner"), t.joinerClass])
801
+ $(o(ke), U({
802
+ modelValue: u.value,
803
+ "onUpdate:modelValue": P[0] || (P[0] = (f) => u.value = f),
804
+ onOnChange: d
805
+ }, c.value, { type: t.type }), null, 16, ["modelValue", "type"]),
806
+ te(ee("span", {
807
+ class: F([o(R)("date-range-joiner"), t.joinerClass])
808
808
  }, null, 2), [
809
- [ie, !t.hideJoiner]
809
+ [ue, !t.hideJoiner]
810
810
  ]),
811
- O(n(ke), K({
812
- modelValue: h.value,
813
- "onUpdate:modelValue": N[1] || (N[1] = (f) => h.value = f),
811
+ $(o(ke), U({
812
+ modelValue: p.value,
813
+ "onUpdate:modelValue": P[1] || (P[1] = (f) => p.value = f),
814
814
  onOnChange: T
815
- }, b.value, { type: t.type }), null, 16, ["modelValue", "type"])
815
+ }, v.value, { type: t.type }), null, 16, ["modelValue", "type"])
816
816
  ], 2));
817
817
  }
818
- }), Dt = {
818
+ }), Ot = {
819
819
  name: "DateRangePicker"
820
- }, xt = /* @__PURE__ */ U({
821
- ...Dt,
820
+ }, xt = /* @__PURE__ */ Y({
821
+ ...Ot,
822
822
  props: {
823
823
  /**
824
824
  * 双向绑定开始时间
@@ -875,40 +875,40 @@ const M = {
875
875
  },
876
876
  emits: ["update:begin", "update:end", "change"],
877
877
  setup(t, { emit: S }) {
878
- const a = me().appContext.config.globalProperties.$Date, e = t, l = S, o = P(
878
+ const a = me().appContext.config.globalProperties.$Date, e = t, l = S, i = N(
879
879
  () => e.options || (e.limitBegin ? {
880
- disabledDate: (p) => p && p.valueOf() < Date.now() - (e.disableToday ? 0 : 864e5)
880
+ disabledDate: (c) => c && c.valueOf() < Date.now() - (e.disableToday ? 0 : 864e5)
881
881
  } : void 0)
882
- ), i = P({
882
+ ), u = N({
883
883
  get() {
884
- const p = e.begin, b = e.end;
885
- return p && b ? [a(p).toDate(), a(b).toDate()] : [];
884
+ const c = e.begin, v = e.end;
885
+ return c && v ? [a(c).toDate(), a(v).toDate()] : [];
886
886
  },
887
- set(p) {
888
- let b, v;
889
- p[0] && p[1] ? (b = a(p[0]).format(e.valueFormat), v = a(p[1]).format(e.valueFormat)) : b = v = "", l("update:begin", b), l("update:end", v);
887
+ set(c) {
888
+ let v, b;
889
+ c[0] && c[1] ? (v = a(c[0]).format(e.valueFormat), b = a(c[1]).format(e.valueFormat)) : v = b = "", l("update:begin", v), l("update:end", b);
890
890
  }
891
- }), h = (p, b) => {
892
- l("change", p, b);
891
+ }), p = (c, v) => {
892
+ l("change", c, v);
893
893
  };
894
- return (p, b) => (D(), E(n(ke), {
895
- modelValue: i.value,
896
- "onUpdate:modelValue": b[0] || (b[0] = (v) => i.value = v),
894
+ return (c, v) => (D(), L(o(ke), {
895
+ modelValue: u.value,
896
+ "onUpdate:modelValue": v[0] || (v[0] = (b) => u.value = b),
897
897
  type: t.type,
898
898
  clearable: t.clearable,
899
899
  "split-panels": t.splitPanels,
900
- options: o.value,
900
+ options: i.value,
901
901
  transfer: t.transfer,
902
902
  placeholder: t.placeholder,
903
903
  disabled: t.disabled,
904
904
  placement: t.placement,
905
- onOnChange: h
905
+ onOnChange: p
906
906
  }, null, 8, ["modelValue", "type", "clearable", "split-panels", "options", "transfer", "placeholder", "disabled", "placement", "onOnChange"]));
907
907
  }
908
- }), Ot = {
908
+ }), $t = {
909
909
  name: "CurdTable"
910
- }, $t = /* @__PURE__ */ U({
911
- ...Ot,
910
+ }, Tt = /* @__PURE__ */ Y({
911
+ ...$t,
912
912
  props: {
913
913
  modelValue: {
914
914
  type: Array,
@@ -962,6 +962,7 @@ const M = {
962
962
  default(t) {
963
963
  return {
964
964
  // title: props.actionText,
965
+ key: "_action",
965
966
  slot: "action",
966
967
  width: t.actionWidth,
967
968
  align: t.actionAlign,
@@ -1038,83 +1039,83 @@ const M = {
1038
1039
  },
1039
1040
  emits: ["update:modelValue", "add", "remove", "change"],
1040
1041
  setup(t, { emit: S }) {
1041
- const a = t, e = S, l = L(a.modelValue), o = P(
1042
+ const a = t, e = S, l = E(a.modelValue), i = N(
1042
1043
  () => a.disabled ? a.columns : a.columns.concat(
1043
1044
  Object.assign(
1044
1045
  {
1045
- title: a.actionText ?? M.t("curdTable.actionText")
1046
+ title: a.actionText ?? w.t("curdTable.actionText")
1046
1047
  },
1047
1048
  a.actionCol
1048
1049
  )
1049
1050
  )
1050
- ), i = P(() => {
1051
- const c = [], T = (d) => {
1052
- d.slot && c.push(d), d.children && d.children.forEach((y) => {
1051
+ ), u = N(() => {
1052
+ const d = [], T = (r) => {
1053
+ r.slot && d.push(r), r.children && r.children.forEach((y) => {
1053
1054
  T(y);
1054
1055
  });
1055
1056
  };
1056
- return a.columns.forEach((d) => {
1057
- T(d);
1058
- }), c;
1057
+ return a.columns.forEach((r) => {
1058
+ T(r);
1059
+ }), d;
1059
1060
  });
1060
- function h() {
1061
- typeof a.beforeAdd != "function" ? p() : a.beforeAdd().then(p).catch();
1061
+ function p() {
1062
+ typeof a.beforeAdd != "function" ? c() : a.beforeAdd().then(c).catch();
1062
1063
  }
1063
- function p(c) {
1064
- l.value.push(...a.addRow(c)), e("update:modelValue", l.value), e("add", l.value[l.value.length - 1]), e("change", !0);
1064
+ function c(d) {
1065
+ l.value.push(...a.addRow(d)), e("update:modelValue", l.value), e("add", l.value[l.value.length - 1]), e("change", !0);
1065
1066
  }
1066
- function b(c) {
1067
- typeof a.beforeRemove != "function" ? v(c) : a.beforeRemove(l.value[c], c).then(() => {
1068
- v(c);
1067
+ function v(d) {
1068
+ typeof a.beforeRemove != "function" ? b(d) : a.beforeRemove(l.value[d], d).then(() => {
1069
+ b(d);
1069
1070
  });
1070
1071
  }
1071
- function v(c) {
1072
- const [T] = l.value.splice(c, 1);
1072
+ function b(d) {
1073
+ const [T] = l.value.splice(d, 1);
1073
1074
  e("update:modelValue", l.value), e("remove", T), e("change", !1);
1074
1075
  }
1075
1076
  return I(
1076
1077
  () => a.modelValue,
1077
- (c) => {
1078
- l.value = c;
1078
+ (d) => {
1079
+ l.value = d;
1079
1080
  }
1080
- ), (c, T) => (D(), j("div", null, [
1081
- O(n(He), {
1081
+ ), (d, T) => (D(), j("div", null, [
1082
+ $(o(je), U(o(Ne)(d.$attrs, ["id", "class", "style"]), {
1082
1083
  border: t.border,
1083
- columns: o.value,
1084
+ columns: i.value,
1084
1085
  data: l.value,
1085
1086
  size: t.size,
1086
1087
  style: { "z-index": "0" }
1087
- }, ze({
1088
- action: C(({ row: d, index: y }) => [
1089
- w(c.$slots, "moreAction", {
1090
- row: d,
1088
+ }), Fe({
1089
+ action: C(({ row: r, index: y }) => [
1090
+ M(d.$slots, "moreAction", {
1091
+ row: r,
1091
1092
  index: y
1092
1093
  }),
1093
- !t.hideDelBtn || !t.hideDelBtn(d, y) ? (D(), E(n(X), K({
1094
+ !t.hideDelBtn || !t.hideDelBtn(r, y) ? (D(), L(o(Z), U({
1094
1095
  key: 0,
1095
1096
  type: t.delBtnType,
1096
1097
  size: t.delBtnSize,
1097
1098
  ghost: t.delBtnGhost
1098
1099
  }, t.delBtn, {
1099
- disabled: t.delBtnDisabled(d, y),
1100
- onClick: (B) => b(y)
1100
+ disabled: t.delBtnDisabled(r, y),
1101
+ onClick: (B) => v(y)
1101
1102
  }), {
1102
1103
  default: C(() => [
1103
- H(z(n(M).t("curdTable.del")), 1)
1104
+ H(z(o(w).t("curdTable.del")), 1)
1104
1105
  ]),
1105
1106
  _: 1
1106
- }, 16, ["type", "size", "ghost", "disabled", "onClick"])) : J("", !0)
1107
+ }, 16, ["type", "size", "ghost", "disabled", "onClick"])) : q("", !0)
1107
1108
  ]),
1108
1109
  _: 2
1109
1110
  }, [
1110
- Z(i.value, (d) => ({
1111
- name: d.slot,
1111
+ _(u.value, (r) => ({
1112
+ name: r.slot,
1112
1113
  fn: C((y) => [
1113
- w(c.$slots, d.slot, Be(Ve(y)))
1114
+ M(d.$slots, r.slot, Be(Ve(y)))
1114
1115
  ])
1115
1116
  }))
1116
- ]), 1032, ["border", "columns", "data", "size"]),
1117
- t.disabled ? J("", !0) : _((D(), E(n(X), K({
1117
+ ]), 1040, ["border", "columns", "data", "size"]),
1118
+ t.disabled ? q("", !0) : te((D(), L(o(Z), U({
1118
1119
  key: 0,
1119
1120
  type: t.addBtnType,
1120
1121
  size: t.addBtnSize,
@@ -1124,21 +1125,21 @@ const M = {
1124
1125
  long: "",
1125
1126
  icon: "md-add",
1126
1127
  style: { display: "block", position: "relative", "margin-top": "-1px" },
1127
- onClick: h
1128
+ onClick: p
1128
1129
  }), {
1129
1130
  default: C(() => [
1130
- H(z(t.addText ?? n(M).t("curdTable.addText")), 1)
1131
+ H(z(t.addText ?? o(w).t("curdTable.addText")), 1)
1131
1132
  ]),
1132
1133
  _: 1
1133
1134
  }, 16, ["type", "size", "ghost", "disabled"])), [
1134
- [ie, t.addable]
1135
+ [ue, t.addable]
1135
1136
  ])
1136
1137
  ]));
1137
1138
  }
1138
- }), Tt = {
1139
+ }), At = {
1139
1140
  name: "MCalendar"
1140
- }, At = /* @__PURE__ */ U({
1141
- ...Tt,
1141
+ }, Rt = /* @__PURE__ */ Y({
1142
+ ...At,
1142
1143
  props: {
1143
1144
  /**
1144
1145
  * 指定日期,默认显示该日期所在月份
@@ -1245,172 +1246,172 @@ const M = {
1245
1246
  },
1246
1247
  emits: ["update:range", "select-range", "click-day", "dblclick-day"],
1247
1248
  setup(t, { emit: S }) {
1248
- const a = me().appContext.config.globalProperties.$Date, e = t, l = S, o = L(), i = L(null), h = L(null), p = P(() => {
1249
+ const a = me().appContext.config.globalProperties.$Date, e = t, l = S, i = E(), u = E(null), p = E(null), c = N(() => {
1249
1250
  let f = Math.floor(e.startDay);
1250
1251
  return (isNaN(f) || f < 0 || f > 6) && (f = 0), f;
1251
- }), b = P(() => {
1252
+ }), v = N(() => {
1252
1253
  let f;
1253
- const V = [], u = p.value + 7;
1254
- for (let k = p.value; k < u; k++)
1254
+ const V = [], s = c.value + 7;
1255
+ for (let k = c.value; k < s; k++)
1255
1256
  f = k % 7, V.push({
1256
- title: e.weekMap?.[f] || M.t(`mCalendar.${e.weekType}.${f}`),
1257
+ title: e.weekMap?.[f] || w.t(`mCalendar.${e.weekType}.${f}`),
1257
1258
  order: f
1258
1259
  });
1259
1260
  return V;
1260
- }), v = (f) => {
1261
+ }), b = (f) => {
1261
1262
  let V = a(
1262
1263
  e.date || e.dates && e.dates[0] && e.dates[0][e.dateKey]
1263
- ), u, k, r;
1264
- return e.isOnFirstLine ? u = V : (u = V.startOf("month"), k = V.endOf("month")), r = u.day(), p.value !== 0 && r === 0 && (r = 7), V = u.subtract(r - p.value, "day"), e.isOnFirstLine && (k = V.add(41, "day")), {
1264
+ ), s, k, h;
1265
+ return e.isOnFirstLine ? s = V : (s = V.startOf("month"), k = V.endOf("month")), h = s.day(), c.value !== 0 && h === 0 && (h = 7), V = s.subtract(h - c.value, "day"), e.isOnFirstLine && (k = V.add(41, "day")), {
1265
1266
  beginDate: V.format("YYYY-MM-DD"),
1266
1267
  endDate: k?.format("YYYY-MM-DD"),
1267
- extra: [V, e.isOnFirstLine ? V : u, k]
1268
+ extra: [V, e.isOnFirstLine ? V : s, k]
1268
1269
  };
1269
- }, c = () => {
1270
- e.hasRange && (i.value = h.value = null);
1270
+ }, d = () => {
1271
+ e.hasRange && (u.value = p.value = null);
1271
1272
  const {
1272
- extra: [f, V, u]
1273
- } = v(), k = e.dates?.[0] ? e.dates.slice() : [], r = /* @__PURE__ */ new Date();
1274
- let s, $, q;
1275
- for (o.value = [], s = 0; s < 42; s++)
1276
- $ = f.add(s, "day"), q = k.find((ee) => $.isSame(ee[e.dateKey], "day")), o.value.push({
1277
- _date: $.toDate(),
1278
- _text: $.format(e.textFormat),
1279
- _isOuter: $.isBefore(V, "day") || $.isAfter(u, "day"),
1273
+ extra: [f, V, s]
1274
+ } = b(), k = e.dates?.[0] ? e.dates.slice() : [], h = /* @__PURE__ */ new Date();
1275
+ let n, x, K;
1276
+ for (i.value = [], n = 0; n < 42; n++)
1277
+ x = f.add(n, "day"), K = k.find((W) => x.isSame(W[e.dateKey], "day")), i.value.push({
1278
+ _date: x.toDate(),
1279
+ _text: x.format(e.textFormat),
1280
+ _isOuter: x.isBefore(V, "day") || x.isAfter(s, "day"),
1280
1281
  //!eachDay.isBetween(start, end, 'day', '[]'),
1281
- _isToday: $.isSame(r, "day"),
1282
+ _isToday: x.isSame(h, "day"),
1282
1283
  // _rangeStart: undefined,
1283
1284
  // _rangeEnd: undefined,
1284
1285
  _inRange: void 0,
1285
- ...q
1286
+ ...K
1286
1287
  });
1287
1288
  };
1288
1289
  let T;
1289
- const d = (f, V) => {
1290
- const u = e.hasRange && (!f._isOuter || e.outerInRange);
1291
- if (u)
1292
- if (!i.value)
1293
- i.value = f, f._inRange = !0;
1294
- else if (h.value)
1295
- i.value = h.value = null, o.value.forEach((k) => {
1290
+ const r = (f, V) => {
1291
+ const s = e.hasRange && (!f._isOuter || e.outerInRange);
1292
+ if (s)
1293
+ if (!u.value)
1294
+ u.value = f, f._inRange = !0;
1295
+ else if (p.value)
1296
+ u.value = p.value = null, i.value.forEach((k) => {
1296
1297
  k._inRange = !1;
1297
- }), e.clearable || (i.value = f);
1298
+ }), e.clearable || (u.value = f);
1298
1299
  else {
1299
- if (f._date < i.value._date) {
1300
- const k = i.value;
1301
- i.value = f, f = k;
1300
+ if (f._date < u.value._date) {
1301
+ const k = u.value;
1302
+ u.value = f, f = k;
1302
1303
  }
1303
- h.value = f, f._inRange = !0;
1304
+ p.value = f, f._inRange = !0;
1304
1305
  }
1305
- l("click-day", f, V), u && (T = !0, G(() => {
1306
+ l("click-day", f, V), s && (T = !0, G(() => {
1306
1307
  T = null;
1307
- }), l("update:range", [i.value, h.value]), l(
1308
+ }), l("update:range", [u.value, p.value]), l(
1308
1309
  "select-range",
1309
- [i.value, h.value],
1310
- o.value.slice(
1311
- o.value.indexOf(i.value),
1312
- o.value.indexOf(h.value) + 1
1310
+ [u.value, p.value],
1311
+ i.value.slice(
1312
+ i.value.indexOf(u.value),
1313
+ i.value.indexOf(p.value) + 1
1313
1314
  )
1314
1315
  ));
1315
1316
  }, y = (f, V) => {
1316
1317
  l("dblclick-day", f, V);
1317
1318
  }, B = (f, V) => {
1318
- if (!e.hasRange || !i.value || h.value || f._isOuter && !e.outerInRange)
1319
+ if (!e.hasRange || !u.value || p.value || f._isOuter && !e.outerInRange)
1319
1320
  return;
1320
- let u = o.value.indexOf(i.value);
1321
- if (V < u) {
1322
- const k = u;
1323
- u = V, V = k;
1321
+ let s = i.value.indexOf(u.value);
1322
+ if (V < s) {
1323
+ const k = s;
1324
+ s = V, V = k;
1324
1325
  }
1325
- o.value.forEach((k, r) => {
1326
- k._inRange = r >= u && r <= V;
1326
+ i.value.forEach((k, h) => {
1327
+ k._inRange = h >= s && h <= V;
1327
1328
  });
1328
- }, N = (f) => {
1329
+ }, P = (f) => {
1329
1330
  if (!e.hasRange || T) return;
1330
1331
  if (!f || !f.length) {
1331
- i.value = h.value = null, o.value.forEach((s) => {
1332
- s._inRange = !1;
1332
+ u.value = p.value = null, i.value.forEach((n) => {
1333
+ n._inRange = !1;
1333
1334
  });
1334
1335
  return;
1335
1336
  }
1336
1337
  if (!f[0] || !f[1]) return;
1337
1338
  if (a(f[0]._date).isAfter(f[1]._date)) {
1338
- const s = f[1];
1339
- f[1] = f[0], f[0] = s;
1339
+ const n = f[1];
1340
+ f[1] = f[0], f[0] = n;
1340
1341
  }
1341
- const V = o.value.length;
1342
- let u, k = -1, r = V;
1343
- for (let s = 0; s < V; s++)
1344
- if (u = a(o.value[s]._date), k < 0 && u.isSame(f[0]._date, "day") && (i.value = o.value[s], k = s), u.isSame(f[1]._date, "day")) {
1345
- h.value = o.value[s], r = s;
1342
+ const V = i.value.length;
1343
+ let s, k = -1, h = V;
1344
+ for (let n = 0; n < V; n++)
1345
+ if (s = a(i.value[n]._date), k < 0 && s.isSame(f[0]._date, "day") && (u.value = i.value[n], k = n), s.isSame(f[1]._date, "day")) {
1346
+ p.value = i.value[n], h = n;
1346
1347
  break;
1347
1348
  }
1348
- o.value.forEach((s, $) => {
1349
- s._inRange = $ >= k && $ <= r;
1349
+ i.value.forEach((n, x) => {
1350
+ n._inRange = x >= k && x <= h;
1350
1351
  });
1351
1352
  };
1352
- return c(), e.range && (i.value = e.range[0], h.value = e.range[1], N(e.range)), I(
1353
+ return d(), e.range && (u.value = e.range[0], p.value = e.range[1], P(e.range)), I(
1353
1354
  () => e.date,
1354
1355
  (f) => {
1355
- !e.dates && f instanceof Date && c();
1356
+ !e.dates && f instanceof Date && d();
1356
1357
  }
1357
1358
  ), I(
1358
1359
  () => e.dates,
1359
1360
  (f) => {
1360
- f && c();
1361
+ f && d();
1361
1362
  }
1362
1363
  ), I(
1363
1364
  () => e.startDay,
1364
1365
  () => {
1365
- c();
1366
+ d();
1366
1367
  }
1367
- ), I(() => e.range, N), (f, V) => (D(), j("div", {
1368
- class: F(n(R)("mcalendar"))
1368
+ ), I(() => e.range, P), (f, V) => (D(), j("div", {
1369
+ class: F(o(R)("mcalendar"))
1369
1370
  }, [
1370
- O(n(fe), null, {
1371
+ $(o(ge), null, {
1371
1372
  default: C(() => [
1372
- (D(!0), j(W, null, Z(b.value, (u, k) => (D(), E(n(oe), {
1373
+ (D(!0), j(X, null, _(v.value, (s, k) => (D(), L(o(ie), {
1373
1374
  key: k,
1374
1375
  span: "4",
1375
1376
  class: F([
1376
- n(R)("mcalendar-title"),
1377
- { weekend: t.offDay.includes(u.order) },
1378
- t.titleClass && t.titleClass(u, k)
1377
+ o(R)("mcalendar-title"),
1378
+ { weekend: t.offDay.includes(s.order) },
1379
+ t.titleClass && t.titleClass(s, k)
1379
1380
  ])
1380
1381
  }, {
1381
1382
  default: C(() => [
1382
- H(z(u.title), 1)
1383
+ H(z(s.title), 1)
1383
1384
  ]),
1384
1385
  _: 2
1385
1386
  }, 1032, ["class"]))), 128))
1386
1387
  ]),
1387
1388
  _: 1
1388
1389
  }),
1389
- O(n(fe), null, {
1390
+ $(o(ge), null, {
1390
1391
  default: C(() => [
1391
- (D(!0), j(W, null, Z(o.value, (u, k) => (D(), E(n(oe), {
1392
+ (D(!0), j(X, null, _(i.value, (s, k) => (D(), L(o(ie), {
1392
1393
  key: k,
1393
1394
  span: "4",
1394
1395
  class: F([
1395
- n(R)("mcalendar-cell"),
1396
- u._isToday && n(R)("mcalendar-cell_today"),
1397
- { outer: u._isOuter },
1398
- { "range-start": u === i.value },
1399
- { "in-range": u._inRange },
1400
- { "range-end": u === h.value },
1401
- t.dateClass && t.dateClass(u, k),
1402
- u.className
1396
+ o(R)("mcalendar-cell"),
1397
+ s._isToday && o(R)("mcalendar-cell_today"),
1398
+ { outer: s._isOuter },
1399
+ { "range-start": s === u.value },
1400
+ { "in-range": s._inRange },
1401
+ { "range-end": s === p.value },
1402
+ t.dateClass && t.dateClass(s, k),
1403
+ s.className
1403
1404
  ]),
1404
- onClick: (r) => d(u, k),
1405
- onDblclick: (r) => y(u, k),
1406
- onMouseenter: (r) => B(u, k)
1405
+ onClick: (h) => r(s, k),
1406
+ onDblclick: (h) => y(s, k),
1407
+ onMouseenter: (h) => B(s, k)
1407
1408
  }, {
1408
1409
  default: C(() => [
1409
- w(f.$slots, "cell", {
1410
- day: u,
1410
+ M(f.$slots, "cell", {
1411
+ day: s,
1411
1412
  index: k
1412
1413
  }, () => [
1413
- H(z(u._text), 1)
1414
+ H(z(s._text), 1)
1414
1415
  ])
1415
1416
  ]),
1416
1417
  _: 2
@@ -1418,16 +1419,16 @@ const M = {
1418
1419
  ]),
1419
1420
  _: 3
1420
1421
  }),
1421
- _(O(n(_e), { fix: "" }, null, 512), [
1422
- [ie, t.loading]
1422
+ te($(o(tt), { fix: "" }, null, 512), [
1423
+ [ue, t.loading]
1423
1424
  ])
1424
1425
  ], 2));
1425
1426
  }
1426
- }), Rt = {
1427
- name: "ModalFooter",
1428
- inheritAttrs: !1
1429
- }, Mt = /* @__PURE__ */ U({
1430
- ...Rt,
1427
+ }), wt = {
1428
+ name: "ModalFooter"
1429
+ // inheritAttrs: false
1430
+ }, Mt = /* @__PURE__ */ Y({
1431
+ ...wt,
1431
1432
  props: {
1432
1433
  modelValue: Boolean,
1433
1434
  /**
@@ -1486,69 +1487,69 @@ const M = {
1486
1487
  const a = S, e = me(), l = () => {
1487
1488
  e.vnode.props.onCancel ? a("cancel") : a("update:modelValue", !1);
1488
1489
  };
1489
- return (o, i) => (D(), E(n(fe), {
1490
+ return (i, u) => (D(), L(o(ge), {
1490
1491
  justify: "space-between",
1491
1492
  align: "middle"
1492
1493
  }, {
1493
1494
  default: C(() => [
1494
- O(n(oe), null, {
1495
+ $(o(ie), null, {
1495
1496
  default: C(() => [
1496
- w(o.$slots, "other")
1497
+ M(i.$slots, "other")
1497
1498
  ]),
1498
1499
  _: 3
1499
1500
  }),
1500
- O(n(oe), null, {
1501
+ $(o(ie), null, {
1501
1502
  default: C(() => [
1502
- t.rightCancel ? (D(), j(W, { key: 1 }, [
1503
- t.hasOk ? (D(), E(n(X), K({
1503
+ t.rightCancel ? (D(), j(X, { key: 1 }, [
1504
+ t.hasOk ? (D(), L(o(Z), U({
1504
1505
  key: 0,
1505
1506
  disabled: t.okDisabled,
1506
1507
  loading: t.okLoading
1507
1508
  }, t.ok, {
1508
1509
  type: "primary",
1509
- onClick: i[1] || (i[1] = (h) => o.$emit("ok"))
1510
+ onClick: u[1] || (u[1] = (p) => i.$emit("ok"))
1510
1511
  }), {
1511
1512
  default: C(() => [
1512
- H(z(t.okText ?? n(M).t("modalFooter.ok")), 1)
1513
+ H(z(t.okText ?? o(w).t("modalFooter.ok")), 1)
1513
1514
  ]),
1514
1515
  _: 1
1515
- }, 16, ["disabled", "loading"])) : J("", !0),
1516
- O(n(X), K({
1516
+ }, 16, ["disabled", "loading"])) : q("", !0),
1517
+ $(o(Z), U({
1517
1518
  disabled: t.cancelDisabled,
1518
1519
  loading: t.cancelLoading,
1519
1520
  type: t.cancelType
1520
1521
  }, t.cancel, { onClick: l }), {
1521
1522
  default: C(() => [
1522
- H(z(t.cancelText ?? n(M).t("modalFooter.cancel")), 1)
1523
+ H(z(t.cancelText ?? o(w).t("modalFooter.cancel")), 1)
1523
1524
  ]),
1524
1525
  _: 1
1525
1526
  }, 16, ["disabled", "loading", "type"])
1526
- ], 64)) : (D(), j(W, { key: 0 }, [
1527
- O(n(X), K({
1527
+ ], 64)) : (D(), j(X, { key: 0 }, [
1528
+ $(o(Z), U({
1528
1529
  disabled: t.cancelDisabled,
1529
1530
  loading: t.cancelLoading,
1530
1531
  type: t.cancelType
1531
1532
  }, t.cancel, { onClick: l }), {
1532
1533
  default: C(() => [
1533
- H(z(t.cancelText ?? n(M).t("modalFooter.cancel")), 1)
1534
+ H(z(t.cancelText ?? o(w).t("modalFooter.cancel")), 1)
1534
1535
  ]),
1535
1536
  _: 1
1536
1537
  }, 16, ["disabled", "loading", "type"]),
1537
- t.hasOk ? (D(), E(n(X), K({
1538
+ t.hasOk ? (D(), L(o(Z), U({
1538
1539
  key: 0,
1539
1540
  disabled: t.okDisabled,
1540
1541
  loading: t.okLoading
1541
1542
  }, t.ok, {
1542
1543
  type: "primary",
1543
- onClick: i[0] || (i[0] = (h) => o.$emit("ok"))
1544
+ onClick: u[0] || (u[0] = (p) => i.$emit("ok"))
1544
1545
  }), {
1545
1546
  default: C(() => [
1546
- H(z(t.okText ?? n(M).t("modalFooter.ok")), 1)
1547
+ H(z(t.okText ?? o(w).t("modalFooter.ok")), 1)
1547
1548
  ]),
1548
1549
  _: 1
1549
- }, 16, ["disabled", "loading"])) : J("", !0)
1550
+ }, 16, ["disabled", "loading"])) : q("", !0)
1550
1551
  ], 64)),
1551
- w(o.$slots, "action")
1552
+ M(i.$slots, "action")
1552
1553
  ]),
1553
1554
  _: 3
1554
1555
  })
@@ -1556,13 +1557,13 @@ const M = {
1556
1557
  _: 3
1557
1558
  }));
1558
1559
  }
1559
- }), wt = {
1560
+ }), It = {
1560
1561
  key: 0,
1561
1562
  class: "ivu-dropdown-item"
1562
- }, Y = {}, It = {
1563
+ }, J = {}, zt = {
1563
1564
  name: "ToggleColumn"
1564
- }, Ne = /* @__PURE__ */ U({
1565
- ...It,
1565
+ }, Le = /* @__PURE__ */ Y({
1566
+ ...zt,
1566
1567
  props: {
1567
1568
  modelValue: {
1568
1569
  type: Array
@@ -1590,130 +1591,170 @@ const M = {
1590
1591
  * @example
1591
1592
  * // 组件会尝试将显示状态读写至 localStorage.app.main.cols
1592
1593
  * storeAt='app.main.cols'
1594
+ *
1595
+ * 特殊情况:如读写至 localStorage.app.page1['part1.list'].cols
1596
+ * storeAt='app.page1.[part1.list].cols'
1593
1597
  */
1594
- storeAt: String
1598
+ storeAt: String,
1599
+ /**
1600
+ * 最小可见列数
1601
+ */
1602
+ minVisible: {
1603
+ type: Number,
1604
+ default: 1
1605
+ },
1606
+ /**
1607
+ * 切换列时是否实时读取本地存储
1608
+ *
1609
+ * 在启用storeAt时,默认只在初始化时从本地读取一次之前保存的状态 \
1610
+ * 若需要每次切换列时都实时从本地获取最新的数据,则可以开启此项 \
1611
+ * 一般在搭配其它逻辑共享同一数据结构时适用,如拖拽列宽后需要将列宽存至同一对象中以节省存储空间 \
1612
+ * 当在循环中使用(即存在cacheId)时,建议开启此项,否则可能会出现列显示异常的情况
1613
+ *
1614
+ * @default
1615
+ * !!props.storeAt && !!props.cacheId
1616
+ */
1617
+ realtime: {
1618
+ type: Boolean,
1619
+ default: (t) => !!t.storeAt && !!t.cacheId
1620
+ }
1595
1621
  },
1596
1622
  emits: ["update:modelValue", "change"],
1597
1623
  setup(t, { emit: S }) {
1598
1624
  const a = t, e = S;
1599
- let l, o, i;
1600
- const h = (r) => {
1625
+ let l, i, u;
1626
+ const p = (h) => {
1601
1627
  clearTimeout(l);
1602
- let s = localStorage.getItem(o);
1603
- s = s ? JSON.parse(s) : {}, r ? ot(s, it(i, p)) : nt(s, i, p), l = setTimeout(() => {
1604
- l = null, localStorage.setItem(o, JSON.stringify(s));
1628
+ let n = localStorage.getItem(i);
1629
+ n = n ? JSON.parse(n) : {}, h ? ut(n, st(u, c)) : it(n, u, c), l = setTimeout(() => {
1630
+ l = null, localStorage.setItem(i, JSON.stringify(n));
1605
1631
  });
1606
1632
  };
1607
- let p;
1608
- a.storeAt && (o = a.storeAt.split(".")[0], i = a.storeAt.slice(o.length + 1), p = localStorage.getItem(o) && ge(JSON.parse(localStorage[o]), i), p || (p = {}, h(!0)));
1609
- const b = L(!1), v = Ce([]), c = L([]), T = P(() => {
1610
- const r = c.value.filter((s) => s._switchable);
1611
- return r.some((s) => s._visible) && r.some((s) => !s._visible);
1612
- }), d = P({
1633
+ let c;
1634
+ a.storeAt && (i = a.storeAt.split(".")[0], u = a.storeAt.slice(i.length + 1), c = localStorage.getItem(i) && Q(JSON.parse(localStorage[i]), u), c || (c = {}, p(!0)));
1635
+ const v = E(!1), b = Ce([]), d = E([]), T = N(() => {
1636
+ const h = d.value.filter((n) => n._switchable);
1637
+ return h.some((n) => n._visible) && h.some((n) => !n._visible);
1638
+ }), r = N({
1613
1639
  get() {
1614
- const r = c.value.filter((s) => s._switchable);
1615
- return r.length > 0 && r.every((s) => s._visible);
1640
+ const h = d.value.filter((n) => n._switchable);
1641
+ return h.length > 0 && h.every((n) => n._visible);
1616
1642
  },
1617
- set(r) {
1618
- c.value.forEach((s, $) => {
1619
- s._switchable && (v.value[$]._visible = s._visible = r);
1620
- }), a.storeAt && (c.value.forEach((s, $) => {
1621
- p[s.key] = s._visible;
1622
- }), h()), k(), e("change", v.value);
1643
+ set(h) {
1644
+ if (h)
1645
+ d.value.forEach((n, x) => {
1646
+ if (n._switchable) {
1647
+ b.value[x]._visible = n._visible = h;
1648
+ return;
1649
+ }
1650
+ n._switchable = n.initSwitchable;
1651
+ });
1652
+ else {
1653
+ const n = a.minVisible - d.value.filter((K) => !K._switchable).length;
1654
+ let x = 0;
1655
+ d.value.forEach((K, W) => {
1656
+ K._switchable && (b.value[W]._visible = K._visible = x < n, K._visible && (K._switchable = !1, x++));
1657
+ });
1658
+ }
1659
+ a.storeAt && (a.realtime && (c = Q(JSON.parse(localStorage[i]), u)), d.value.forEach((n, x) => {
1660
+ Me(c[n.key]) ? c[n.key].visible = n._visible : c[n.key] = { visible: n._visible };
1661
+ }), p()), k(), e("change", b.value);
1623
1662
  }
1624
1663
  });
1625
1664
  function y() {
1626
- const r = c.value.filter((s) => s._visible);
1627
- if (!a.all && r.length === 1) {
1628
- r[0]._switchable = !1;
1665
+ const h = d.value.filter((n) => n._visible);
1666
+ if (h.length <= a.minVisible) {
1667
+ h.forEach((n) => {
1668
+ n._switchable = !1;
1669
+ });
1629
1670
  return;
1630
1671
  }
1631
- r.forEach((s) => {
1632
- s.initSwitchable && !s._switchable && (s._switchable = !0);
1672
+ h.forEach((n) => {
1673
+ n.initSwitchable && !n._switchable && (n._switchable = !0);
1633
1674
  });
1634
1675
  }
1635
- function B(r, s) {
1636
- v.value[s]._visible = r._visible, a.storeAt && (p[r.key] = r._visible, h()), k(), y(), e("change", v.value[s]);
1676
+ function B(h, n) {
1677
+ b.value[n]._visible = h._visible, a.storeAt && (a.realtime && (c = Q(JSON.parse(localStorage[i]), u)), Me(c[h.key]) ? c[h.key].visible = h._visible : c[h.key] = { visible: h._visible }, p()), k(), y(), e("change", b.value[n]);
1637
1678
  }
1638
- let N;
1639
- function f(r) {
1640
- clearTimeout(N), N = setTimeout(() => {
1641
- b.value = r, N = null;
1679
+ let P;
1680
+ function f(h) {
1681
+ clearTimeout(P), P = setTimeout(() => {
1682
+ v.value = h, P = null;
1642
1683
  }, 200);
1643
1684
  }
1644
- function V() {
1645
- (Y[a.cacheId]?.cols || a.modelValue).forEach((r) => {
1646
- r.hasOwnProperty("_visible") || (a.storeAt ? r._visible = p[r.key] === void 0 || p[r.key] : r._visible = !0), r.hasOwnProperty("_switchable") || (r._switchable = !0), v.value.push(r), c.value.push({
1647
- title: r.title || "",
1648
- key: r.key,
1649
- initSwitchable: r._switchable,
1650
- _switchable: r._switchable,
1651
- _visible: r._visible
1685
+ function V(h) {
1686
+ !h && a.storeAt && a.realtime && (c = Q(JSON.parse(localStorage[i]), u)), (J[a.cacheId]?.cols || a.modelValue).forEach((n) => {
1687
+ n.hasOwnProperty("_visible") || (n._visible = a.storeAt ? c[n.key] == null || (c[n.key].visible ?? !0) : !0), n.hasOwnProperty("_switchable") || (n._switchable = !0), b.value.push(n), d.value.push({
1688
+ title: n.title || "",
1689
+ key: n.key,
1690
+ initSwitchable: n._switchable,
1691
+ _switchable: n._switchable,
1692
+ _visible: n._visible
1652
1693
  });
1653
1694
  }), y(), k();
1654
1695
  }
1655
- let u;
1696
+ let s;
1656
1697
  function k() {
1657
- a.cacheId != null && (Y[a.cacheId].flag = !0, setTimeout(() => {
1658
- Y[a.cacheId].flag = null;
1659
- })), u = !0, setTimeout(() => {
1660
- u = null;
1698
+ a.cacheId != null && (J[a.cacheId].flag = !0, setTimeout(() => {
1699
+ J[a.cacheId].flag = null;
1700
+ })), s = !0, setTimeout(() => {
1701
+ s = null;
1661
1702
  }), e(
1662
1703
  "update:modelValue",
1663
- v.value.filter((r) => r._visible)
1704
+ b.value.filter((h) => h._visible)
1664
1705
  );
1665
1706
  }
1666
- return se(() => {
1667
- a.cacheId != null && (Y[a.cacheId] ? Y[a.cacheId].all++ : Y[a.cacheId] = { cols: a.modelValue, all: 1 }, Fe(() => {
1668
- Y[a.cacheId] && --Y[a.cacheId].all < 1 && delete Y[a.cacheId];
1669
- })), V();
1707
+ return de(() => {
1708
+ a.cacheId != null && (J[a.cacheId] ? J[a.cacheId].all++ : J[a.cacheId] = { cols: a.modelValue, all: 1 }, He(() => {
1709
+ J[a.cacheId] && --J[a.cacheId].all < 1 && delete J[a.cacheId];
1710
+ })), V(!0);
1670
1711
  }), I(
1671
1712
  () => a.modelValue,
1672
- (r) => {
1673
- u || (Y[a.cacheId] && !Y[a.cacheId].flag && (Y[a.cacheId].cols = r), v.value = [], c.value = [], V());
1713
+ (h) => {
1714
+ s || (J[a.cacheId] && !J[a.cacheId].flag && (J[a.cacheId].cols = h), b.value = [], d.value = [], V());
1674
1715
  }
1675
- ), (r, s) => (D(), E(n(et), {
1716
+ ), (h, n) => (D(), L(o(at), {
1676
1717
  trigger: "custom",
1677
- visible: b.value,
1718
+ visible: v.value,
1678
1719
  placement: "bottom-end",
1679
1720
  transfer: t.transfer,
1680
- "transfer-class-name": n(R)("toggle-column-pop"),
1681
- class: F(n(R)("toggle-column"))
1721
+ "transfer-class-name": o(R)("toggle-column-pop"),
1722
+ class: F(o(R)("toggle-column"))
1682
1723
  }, {
1683
1724
  list: C(() => [
1684
- Q("div", {
1685
- onMouseenter: s[3] || (s[3] = ($) => f(!0)),
1686
- onMouseleave: s[4] || (s[4] = ($) => f(!1))
1725
+ ee("div", {
1726
+ onMouseenter: n[3] || (n[3] = (x) => f(!0)),
1727
+ onMouseleave: n[4] || (n[4] = (x) => f(!1))
1687
1728
  }, [
1688
- t.all ? (D(), j("div", wt, [
1689
- O(n(ne), {
1690
- modelValue: d.value,
1691
- "onUpdate:modelValue": s[2] || (s[2] = ($) => d.value = $),
1729
+ t.all ? (D(), j("div", It, [
1730
+ $(o(oe), {
1731
+ modelValue: r.value,
1732
+ "onUpdate:modelValue": n[2] || (n[2] = (x) => r.value = x),
1692
1733
  indeterminate: T.value
1693
1734
  }, {
1694
1735
  default: C(() => [
1695
- H(z(n(M).t("toggleColumn.checkAll")), 1)
1736
+ H(z(o(w).t("toggleColumn.checkAll")), 1)
1696
1737
  ]),
1697
1738
  _: 1
1698
1739
  }, 8, ["modelValue", "indeterminate"])
1699
- ])) : J("", !0),
1700
- O(n(tt), {
1701
- class: F(n(R)("toggle-column-list"))
1740
+ ])) : q("", !0),
1741
+ $(o(lt), {
1742
+ class: F(o(R)("toggle-column-list"))
1702
1743
  }, {
1703
1744
  default: C(() => [
1704
- (D(!0), j(W, null, Z(c.value, ($, q) => (D(), E(n(at), {
1705
- key: q,
1706
- disabled: !$._switchable
1745
+ (D(!0), j(X, null, _(d.value, (x, K) => (D(), L(o(nt), {
1746
+ key: K,
1747
+ disabled: !x._switchable
1707
1748
  }, {
1708
1749
  default: C(() => [
1709
- O(n(ne), {
1710
- modelValue: $._visible,
1711
- "onUpdate:modelValue": (ee) => $._visible = ee,
1712
- disabled: !$._switchable,
1713
- onOnChange: (ee) => B($, q)
1750
+ $(o(oe), {
1751
+ modelValue: x._visible,
1752
+ "onUpdate:modelValue": (W) => x._visible = W,
1753
+ disabled: !x._switchable,
1754
+ onOnChange: (W) => B(x, K)
1714
1755
  }, {
1715
1756
  default: C(() => [
1716
- H(z($.title), 1)
1757
+ H(z(x.title), 1)
1717
1758
  ]),
1718
1759
  _: 2
1719
1760
  }, 1032, ["modelValue", "onUpdate:modelValue", "disabled", "onOnChange"])
@@ -1726,20 +1767,20 @@ const M = {
1726
1767
  ], 32)
1727
1768
  ]),
1728
1769
  default: C(() => [
1729
- Q("span", {
1730
- onMouseover: s[0] || (s[0] = ($) => f(!0)),
1731
- onMouseout: s[1] || (s[1] = ($) => f(!1)),
1732
- class: F(n(R)("toggle-column-btn"))
1770
+ ee("span", {
1771
+ onMouseover: n[0] || (n[0] = (x) => f(!0)),
1772
+ onMouseout: n[1] || (n[1] = (x) => f(!1)),
1773
+ class: F(o(R)("toggle-column-btn"))
1733
1774
  }, [
1734
- w(r.$slots, "default", {}, () => [
1735
- O(n(X), {
1775
+ M(h.$slots, "default", {}, () => [
1776
+ $(o(Z), {
1736
1777
  type: "default",
1737
1778
  icon: t.icon
1738
1779
  }, {
1739
1780
  default: C(() => [
1740
- t.icon ? J("", !0) : (D(), j(W, { key: 0 }, [
1741
- H(z(t.title ?? n(M).t("toggleColumn.title")) + " ", 1),
1742
- O(n(ce), { type: "ios-arrow-down" })
1781
+ t.icon ? q("", !0) : (D(), j(X, { key: 0 }, [
1782
+ H(z(t.title ?? o(w).t("toggleColumn.title")) + " ", 1),
1783
+ $(o(fe), { type: "ios-arrow-down" })
1743
1784
  ], 64))
1744
1785
  ]),
1745
1786
  _: 1
@@ -1750,11 +1791,11 @@ const M = {
1750
1791
  _: 3
1751
1792
  }, 8, ["visible", "transfer", "transfer-class-name", "class"]));
1752
1793
  }
1753
- }), zt = {
1794
+ }), Ft = {
1754
1795
  name: "PageTable"
1755
1796
  // inheritAttrs: false
1756
- }, Ft = /* @__PURE__ */ U({
1757
- ...zt,
1797
+ }, Ht = /* @__PURE__ */ Y({
1798
+ ...Ft,
1758
1799
  props: /* @__PURE__ */ Ae({
1759
1800
  columns: {
1760
1801
  type: Array,
@@ -1933,8 +1974,8 @@ const M = {
1933
1974
  emit: a
1934
1975
  }) {
1935
1976
  const e = t, l = a;
1936
- let o, i;
1937
- const h = Je(t, "loading"), p = re("tableRef"), b = re("elRef"), v = re("pageRef"), c = L(!1), T = Ce(), d = qe({
1977
+ let i, u;
1978
+ const p = We(t, "loading"), c = ce("tableRef"), v = ce("elRef"), b = ce("pageRef"), d = E(!1), T = Ce(), r = Xe({
1938
1979
  data: [],
1939
1980
  // rows: [] as Obj[],
1940
1981
  // selections: [],
@@ -1945,46 +1986,46 @@ const M = {
1945
1986
  align: "center",
1946
1987
  className: R("page-table-mr0"),
1947
1988
  renderHeader: (g) => {
1948
- const m = d.data.filter((A) => A._checkable && !A._disabled), x = m.length;
1989
+ const m = r.data.filter((A) => A._checkable && !A._disabled), O = m.length;
1949
1990
  return (
1950
1991
  // table.rows.some((e) => e._checkable) && (
1951
- d.data.some((A) => A._checkable) && O(ne, {
1952
- "model-value": !!x && m.every((A) => A._checked),
1953
- disabled: !x,
1992
+ r.data.some((A) => A._checkable) && $(oe, {
1993
+ "model-value": !!O && m.every((A) => A._checked),
1994
+ disabled: !O,
1954
1995
  "onUpdate:model-value": (A) => {
1955
- m.forEach((ue) => {
1956
- ue._checked = A;
1996
+ m.forEach((se) => {
1997
+ se._checked = A;
1957
1998
  });
1958
1999
  },
1959
2000
  onOnChange: (A) => {
1960
- he(), l("select-all", e.pure ? m.map((ue) => de(ue)) : m, A);
2001
+ he(), l("select-all", e.pure ? m.map((se) => re(se)) : m, A);
1961
2002
  }
1962
2003
  }, null)
1963
2004
  );
1964
2005
  },
1965
2006
  render: (g, {
1966
2007
  row: m,
1967
- index: x
1968
- }) => m._checkable && O(ne, {
2008
+ index: O
2009
+ }) => m._checkable && $(oe, {
1969
2010
  "model-value": m._checked,
1970
2011
  disabled: m._disabled,
1971
2012
  "onUpdate:model-value": (A) => {
1972
- Ke(d.data[x], A);
2013
+ Ye(r.data[O], A);
1973
2014
  }
1974
2015
  }, null)
1975
2016
  }
1976
- }), y = Ie({
2017
+ }), y = ze({
1977
2018
  curr: 1,
1978
2019
  size: e.initSize || e.pageSizeOpts[0],
1979
2020
  total: 0
1980
- }), B = P(() => c.value ? !1 : e.transfer), N = P(() => {
1981
- const g = [], m = (x) => {
1982
- x.slot && g.push(x), x.children && x.children.forEach((A) => {
2021
+ }), B = N(() => d.value ? !1 : e.transfer), P = N(() => {
2022
+ const g = [], m = (O) => {
2023
+ O.slot && g.push(O), O.children && O.children.forEach((A) => {
1983
2024
  m(A);
1984
2025
  });
1985
2026
  };
1986
- return e.columns.forEach((x) => {
1987
- m(x);
2027
+ return e.columns.forEach((O) => {
2028
+ m(O);
1988
2029
  }), g;
1989
2030
  });
1990
2031
  function f() {
@@ -1996,75 +2037,75 @@ const M = {
1996
2037
  ...g,
1997
2038
  width: g.width || 54,
1998
2039
  type: void 0,
1999
- ...d.selectType
2040
+ ...r.selectType
2000
2041
  };
2001
2042
  T.value = [m].concat(e.columns.slice(1));
2002
2043
  } else
2003
2044
  T.value = e.columns;
2004
2045
  }
2005
- let V, u, k = 0;
2006
- async function r() {
2046
+ let V, s, k = 0;
2047
+ async function h() {
2007
2048
  if (typeof e.method != "function") return console.warn("typeof method isn't function");
2008
- u && (k = (k + 1) % Number.MAX_SAFE_INTEGER);
2049
+ s && (k = (k + 1) % Number.MAX_SAFE_INTEGER);
2009
2050
  const g = k;
2010
- u = !0, h.value = !0, l("update:selection", []);
2051
+ s = !0, p.value = !0, l("update:selection", []);
2011
2052
  const m = await e.method(Object.assign(Te(), typeof e.param != "function" ? e.param : e.param()));
2012
2053
  if (k !== g) return;
2013
- if (h.value = !1, u = null, !m) {
2054
+ if (p.value = !1, s = null, !m) {
2014
2055
  e.autoRemain || (y.total = 0, l("update:modelValue", []));
2015
2056
  return;
2016
2057
  }
2017
- let x = ge(m, e.dataKey) || [];
2018
- if (s(x), typeof e.process == "function") {
2019
- const A = e.process(x);
2020
- Array.isArray(A) && (x = A);
2058
+ let O = Q(m, e.dataKey) || [];
2059
+ if (n(O), typeof e.process == "function") {
2060
+ const A = e.process(O);
2061
+ Array.isArray(A) && (O = A);
2021
2062
  }
2022
- d.data = x, y.total = ge(m, e.totalKey) || 0, V = !0, l("update:modelValue", d.data), l("load", m), setTimeout(() => {
2063
+ r.data = O, y.total = Q(m, e.totalKey) || 0, V = !0, l("update:modelValue", r.data), l("load", m), setTimeout(() => {
2023
2064
  V = null;
2024
2065
  });
2025
2066
  }
2026
- function s(g) {
2067
+ function n(g) {
2027
2068
  e.columns.some((m) => m.type === "selection") && g.forEach((m) => {
2028
2069
  m._checkable = !0, m._checked = m._disabled = !1;
2029
2070
  });
2030
2071
  }
2031
- function $(g) {
2032
- typeof e.check == "function" && !e.check() || (e.isLocal ? q(g) : r());
2072
+ function x(g) {
2073
+ typeof e.check == "function" && !e.check() || (e.isLocal ? K(g) : h());
2033
2074
  }
2034
- function q(g) {
2075
+ function K(g) {
2035
2076
  let m = g ? y.size * (y.curr - 1) : 0;
2036
- const x = [], A = m + y.size, ue = A > y.total ? y.total : A, ve = e.modelValue;
2037
- for (; m < ue; m++)
2038
- ve[m]._checked = ve[m]._disabled = !1, x.push(ve[m]);
2039
- d.data = x, l("update:selection", []);
2077
+ const O = [], A = m + y.size, se = A > y.total ? y.total : A, be = e.modelValue;
2078
+ for (; m < se; m++)
2079
+ be[m]._checked = be[m]._disabled = !1, O.push(be[m]);
2080
+ r.data = O, l("update:selection", []);
2040
2081
  }
2041
- function ee() {
2042
- $(!0);
2082
+ function W() {
2083
+ x(!0);
2043
2084
  }
2044
- function Le(g) {
2045
- y.size = g, y.curr === 1 && $();
2085
+ function Ke(g) {
2086
+ y.size = g, y.curr === 1 && x();
2046
2087
  }
2047
2088
  function De(g) {
2048
- g !== !0 && (y.curr = 1), G(r);
2089
+ g !== !0 && (y.curr = 1), G(h);
2049
2090
  }
2050
2091
  function he(g, m) {
2051
2092
  g && (g._checked = m);
2052
- let x = d.data.filter((A) => A._checked);
2053
- e.pure && (x = x.map((A) => de(A))), l("update:selection", x), l("selection-change", x);
2093
+ let O = r.data.filter((A) => A._checked);
2094
+ e.pure && (O = O.map((A) => re(A))), l("update:selection", O), l("selection-change", O);
2054
2095
  }
2055
- function xe() {
2056
- return window.innerHeight - +e.bottomDis - p.value.$el.getBoundingClientRect().top - v.value.$el.offsetHeight;
2096
+ function Oe() {
2097
+ return window.innerHeight - +e.bottomDis - c.value.$el.getBoundingClientRect().top - b.value.$el.offsetHeight;
2057
2098
  }
2058
- function Oe(g) {
2099
+ function xe(g) {
2059
2100
  G(() => {
2060
- const m = xe();
2061
- d[g ? "height" : "maxHeight"] = m > 0 ? m : 0;
2101
+ const m = Oe();
2102
+ r[g ? "height" : "maxHeight"] = m > 0 ? m : 0;
2062
2103
  });
2063
2104
  }
2064
2105
  function $e() {
2065
2106
  (e.maximizeHeightType === "height" || e.maximizeHeightType === "maxHeight") && G(() => {
2066
- const g = xe();
2067
- d[e.maximizeHeightType] = g > 0 ? g : 0;
2107
+ const g = Oe();
2108
+ r[e.maximizeHeightType] = g > 0 ? g : 0;
2068
2109
  });
2069
2110
  }
2070
2111
  function Te() {
@@ -2074,125 +2115,125 @@ const M = {
2074
2115
  };
2075
2116
  }
2076
2117
  let pe;
2077
- function Ee(g, m) {
2078
- !e.clickToCheck || !g._checkable || g._disabled || (pe = !0, g = d.data[m], g._checked = !g._checked, he(g, g._checked), l("select", e.pure ? de(g) : g, g._checked), setTimeout(() => {
2118
+ function Ue(g, m) {
2119
+ !e.clickToCheck || !g._checkable || g._disabled || (pe = !0, g = r.data[m], g._checked = !g._checked, he(g, g._checked), l("select", e.pure ? re(g) : g, g._checked), setTimeout(() => {
2079
2120
  pe = null;
2080
2121
  }));
2081
2122
  }
2082
- function Ke(g, m) {
2083
- pe || (he(g, m), l("select", e.pure ? de(g) : g, m));
2123
+ function Ye(g, m) {
2124
+ pe || (he(g, m), l("select", e.pure ? re(g) : g, m));
2084
2125
  }
2085
- function de(g) {
2126
+ function re(g) {
2086
2127
  const m = {
2087
2128
  ...g
2088
2129
  };
2089
2130
  return delete m._checkable, delete m._checked, delete m._disabled, m;
2090
2131
  }
2091
- function Ue() {
2132
+ function Je() {
2092
2133
  if (e.fullscreen) {
2093
- c.value ? document.exitFullscreen() : b.value.requestFullscreen();
2134
+ d.value ? document.exitFullscreen() : v.value.requestFullscreen();
2094
2135
  return;
2095
2136
  }
2096
- c.value = !c.value, c.value ? ($e(), document.body.classList.add("clip")) : (d.height = e.height ?? o, d.maxHeight = e.maxHeight ?? i, document.body.classList.remove("clip")), G(() => {
2097
- l("maximize-change", c.value);
2137
+ d.value = !d.value, d.value ? ($e(), document.body.classList.add("clip")) : (r.height = e.height ?? i, r.maxHeight = e.maxHeight ?? u, document.body.classList.remove("clip")), G(() => {
2138
+ l("maximize-change", d.value);
2098
2139
  });
2099
2140
  }
2100
- function Ye() {
2101
- h.value || (e.isLocal ? l("reload") : De());
2141
+ function Ge() {
2142
+ p.value || (e.isLocal ? l("reload") : De());
2102
2143
  }
2103
2144
  return S({
2104
2145
  search: De,
2105
- setMaxHeight: Oe,
2106
- table: d,
2146
+ setMaxHeight: xe,
2147
+ table: r,
2107
2148
  sizer: y,
2108
2149
  getPage: () => ({
2109
2150
  ...Te(),
2110
2151
  curr: y.curr,
2111
2152
  total: y.total
2112
2153
  })
2113
- }), f(), se(() => {
2114
- !e.maxHeight && !e.height && (e.autoMaxHeight || e.autoHeight) && (Oe(e.autoHeight), G(() => {
2115
- i = d.maxHeight, o = d.height;
2116
- })), e.fullscreen && (b.value.onfullscreenchange = () => {
2117
- c.value = !!document.fullscreenElement, c.value ? setTimeout($e) : (d.height = e.height ?? o, d.maxHeight = e.maxHeight ?? i), setTimeout(() => {
2118
- l("maximize-change", c.value);
2154
+ }), f(), de(() => {
2155
+ !e.maxHeight && !e.height && (e.autoMaxHeight || e.autoHeight) && (xe(e.autoHeight), G(() => {
2156
+ u = r.maxHeight, i = r.height;
2157
+ })), e.fullscreen && (v.value.onfullscreenchange = () => {
2158
+ d.value = !!document.fullscreenElement, d.value ? setTimeout($e) : (r.height = e.height ?? i, r.maxHeight = e.maxHeight ?? u), setTimeout(() => {
2159
+ l("maximize-change", d.value);
2119
2160
  });
2120
2161
  });
2121
- }), Fe(() => {
2122
- b.value.onfullscreenchange = null;
2162
+ }), He(() => {
2163
+ v.value.onfullscreenchange = null;
2123
2164
  }), I(() => e.modelValue, (g) => {
2124
2165
  const m = Array.isArray(g) ? g : [];
2125
2166
  if (e.isLocal) {
2126
- y.curr = 1, y.total = m.length, s(m), q();
2167
+ y.curr = 1, y.total = m.length, n(m), K();
2127
2168
  return;
2128
2169
  }
2129
- V || (y.curr = 1, y.total = m.length, d.data = m);
2170
+ V || (y.curr = 1, y.total = m.length, r.data = m);
2130
2171
  }, {
2131
2172
  immediate: !0
2132
2173
  }), I(() => e.maxHeight, (g) => {
2133
- d.maxHeight = g;
2174
+ r.maxHeight = g;
2134
2175
  }), I(() => e.height, (g) => {
2135
- d.height = g;
2176
+ r.height = g;
2136
2177
  }), I(() => e.columns, () => {
2137
2178
  f();
2138
2179
  }), (g, m) => (D(), j("div", {
2139
2180
  ref: "elRef",
2140
2181
  class: F([
2141
- n(R)("page-table-container"),
2182
+ o(R)("page-table-container"),
2142
2183
  // {
2143
2184
  // 'page-table-bordered': border && showHeader,
2144
2185
  // 'page-table-maximized': maximized,
2145
2186
  // 'page-table-fullscreen': maximized && fullscreen
2146
2187
  // }
2147
- t.border && t.showHeader && n(R)("page-table-bordered"),
2148
- c.value && n(R)("page-table-maximized"),
2149
- c.value && t.fullscreen && n(R)("page-table-fullscreen")
2188
+ t.border && t.showHeader && o(R)("page-table-bordered"),
2189
+ d.value && o(R)("page-table-maximized"),
2190
+ d.value && t.fullscreen && o(R)("page-table-fullscreen")
2150
2191
  ])
2151
- }, [t.showHeader ? (D(), E(n(fe), {
2192
+ }, [t.showHeader ? (D(), L(o(ge), {
2152
2193
  key: 0,
2153
2194
  justify: "space-between",
2154
2195
  align: "middle",
2155
- class: F(n(R)("page-table-header"))
2196
+ class: F(o(R)("page-table-header"))
2156
2197
  }, {
2157
- default: C(() => [O(n(oe), null, {
2158
- default: C(() => [w(g.$slots, "title", {}, () => [Q("h1", {
2159
- class: F(n(R)("page-table-header-title"))
2160
- }, z(t.title ?? n(M).t("pageTable.title")), 3)])]),
2198
+ default: C(() => [$(o(ie), null, {
2199
+ default: C(() => [M(g.$slots, "title", {}, () => [ee("h1", {
2200
+ class: F(o(R)("page-table-header-title"))
2201
+ }, z(t.title ?? o(w).t("pageTable.title")), 3)])]),
2161
2202
  _: 3
2162
- }), O(n(oe), null, {
2163
- default: C(() => [w(g.$slots, "headerAction"), O(n(Me), {
2203
+ }), $(o(ie), null, {
2204
+ default: C(() => [M(g.$slots, "headerAction"), $(o(we), {
2164
2205
  placement: "top",
2165
- content: n(M).t("pageTable.reload"),
2206
+ content: o(w).t("pageTable.reload"),
2166
2207
  transfer: B.value,
2167
- class: F(n(R)("page-table-action"))
2208
+ class: F(o(R)("page-table-action"))
2168
2209
  }, {
2169
- default: C(() => [O(n(ce), {
2210
+ default: C(() => [$(o(fe), {
2170
2211
  type: "md-refresh",
2171
2212
  size: "20",
2172
- onClick: Ye
2213
+ onClick: Ge
2173
2214
  })]),
2174
2215
  _: 1
2175
- }, 8, ["content", "transfer", "class"]), O(n(Me), {
2216
+ }, 8, ["content", "transfer", "class"]), $(o(we), {
2176
2217
  placement: "top",
2177
- content: n(M).t(`pageTable.${c.value ? "restore" : "maxmize"}`),
2218
+ content: o(w).t(`pageTable.${d.value ? "restore" : "maxmize"}`),
2178
2219
  transfer: B.value,
2179
- class: F(n(R)("page-table-action"))
2220
+ class: F(o(R)("page-table-action"))
2180
2221
  }, {
2181
- default: C(() => [O(n(ce), {
2182
- type: c.value ? "md-contract" : "md-expand",
2222
+ default: C(() => [$(o(fe), {
2223
+ type: d.value ? "md-contract" : "md-expand",
2183
2224
  size: "20",
2184
- onClick: Ue
2225
+ onClick: Je
2185
2226
  }, null, 8, ["type"])]),
2186
2227
  _: 1
2187
- }, 8, ["content", "transfer", "class"]), O(Ne, {
2228
+ }, 8, ["content", "transfer", "class"]), $(Le, {
2188
2229
  modelValue: T.value,
2189
- "onUpdate:modelValue": m[0] || (m[0] = (x) => T.value = x),
2230
+ "onUpdate:modelValue": m[0] || (m[0] = (O) => T.value = O),
2190
2231
  size: "20",
2191
2232
  transfer: B.value,
2192
2233
  "store-at": t.storeAt,
2193
- onChange: m[1] || (m[1] = (x) => g.$emit("change-col", x))
2234
+ onChange: m[1] || (m[1] = (O) => g.$emit("change-col", O))
2194
2235
  }, {
2195
- default: C(() => [O(n(ce), {
2236
+ default: C(() => [$(o(fe), {
2196
2237
  type: "md-settings",
2197
2238
  size: "20"
2198
2239
  })]),
@@ -2201,92 +2242,92 @@ const M = {
2201
2242
  _: 3
2202
2243
  })]),
2203
2244
  _: 3
2204
- }, 8, ["class"])) : J("", !0), Q("div", {
2205
- class: F([n(R)("page-table-list"), !n(y).total && !d.data.length && n(R)("page-table-list-empty")])
2206
- }, [O(n(He), K({
2245
+ }, 8, ["class"])) : q("", !0), ee("div", {
2246
+ class: F([o(R)("page-table-list"), !o(y).total && !r.data.length && o(R)("page-table-list-empty")])
2247
+ }, [$(o(je), U({
2207
2248
  ref: "tableRef"
2208
- }, n(ut)(g.$attrs, ["id", "class", "style"]), {
2249
+ }, o(Ne)(g.$attrs, ["id", "class", "style"]), {
2209
2250
  border: t.border,
2210
2251
  columns: T.value,
2211
- data: d.data,
2212
- loading: h.value,
2213
- height: d.height,
2214
- "max-height": d.maxHeight,
2215
- onOnRowClick: Ee
2216
- }), ze({
2252
+ data: r.data,
2253
+ loading: p.value,
2254
+ height: r.height,
2255
+ "max-height": r.maxHeight,
2256
+ onOnRowClick: Ue
2257
+ }), Fe({
2217
2258
  _: 2
2218
2259
  }, [g.$slots.header ? {
2219
2260
  name: "header",
2220
- fn: C(() => [w(g.$slots, "header")]),
2261
+ fn: C(() => [M(g.$slots, "header")]),
2221
2262
  key: "0"
2222
- } : void 0, Z(N.value, (x) => ({
2223
- name: x.slot,
2224
- fn: C((A) => [w(g.$slots, x.slot, Be(Ve(A)))])
2263
+ } : void 0, _(P.value, (O) => ({
2264
+ name: O.slot,
2265
+ fn: C((A) => [M(g.$slots, O.slot, Be(Ve(A)))])
2225
2266
  })), g.$slots.footer ? {
2226
2267
  name: "footer",
2227
- fn: C(() => [w(g.$slots, "footer")]),
2268
+ fn: C(() => [M(g.$slots, "footer")]),
2228
2269
  key: "1"
2229
- } : void 0]), 1040, ["border", "columns", "data", "loading", "height", "max-height", "onOnRowClick"]), _(O(n(lt), {
2270
+ } : void 0]), 1040, ["border", "columns", "data", "loading", "height", "max-height", "onOnRowClick"]), te($(o(ot), {
2230
2271
  ref: "pageRef",
2231
- modelValue: n(y).curr,
2232
- "onUpdate:modelValue": m[2] || (m[2] = (x) => n(y).curr = x),
2233
- total: n(y).total,
2234
- "page-size": n(y).size,
2272
+ modelValue: o(y).curr,
2273
+ "onUpdate:modelValue": m[2] || (m[2] = (O) => o(y).curr = O),
2274
+ total: o(y).total,
2275
+ "page-size": o(y).size,
2235
2276
  "show-total": "",
2236
2277
  "show-sizer": "",
2237
2278
  "show-elevator": "",
2238
2279
  transfer: B.value,
2239
2280
  "page-size-opts": t.pageSizeOpts,
2240
- class: F(n(R)("page-table-paginator")),
2241
- onOnChange: ee,
2242
- onOnPageSizeChange: Le
2243
- }, null, 8, ["modelValue", "total", "page-size", "transfer", "page-size-opts", "class"]), [[ie, !t.hidePage]])], 2)], 2));
2281
+ class: F(o(R)("page-table-paginator")),
2282
+ onOnChange: W,
2283
+ onOnPageSizeChange: Ke
2284
+ }, null, 8, ["modelValue", "total", "page-size", "transfer", "page-size-opts", "class"]), [[ue, !t.hidePage]])], 2)], 2));
2244
2285
  }
2245
- }), Ht = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2286
+ }), jt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2246
2287
  __proto__: null,
2247
- AllCheckbox: rt,
2248
- BaseSwitch: ft,
2249
- CacheSelect: Ct,
2250
- Combi: pt,
2251
- CountRange: bt,
2252
- CurdTable: $t,
2253
- DateRange: Vt,
2288
+ AllCheckbox: ct,
2289
+ BaseSwitch: gt,
2290
+ CacheSelect: Bt,
2291
+ Combi: bt,
2292
+ CountRange: yt,
2293
+ CurdTable: Tt,
2294
+ DateRange: Dt,
2254
2295
  DateRangePicker: xt,
2255
- MCalendar: At,
2296
+ MCalendar: Rt,
2256
2297
  ModalFooter: Mt,
2257
- PageTable: Ft,
2258
- RemoteSelect: Pe,
2259
- ToggleColumn: Ne
2260
- }, Symbol.toStringTag, { value: "Module" })), we = Object.values(Ht), jt = Object.entries({ iviewSelect: je });
2298
+ PageTable: Ht,
2299
+ RemoteSelect: Ee,
2300
+ ToggleColumn: Le
2301
+ }, Symbol.toStringTag, { value: "Module" })), Ie = Object.values(jt), Nt = Object.entries({ iviewSelect: Pe });
2261
2302
  function Pt(t, S = {}) {
2262
- if (S.prefix && (Se[0] = S.prefix, we.forEach((a) => a.name = S.prefix + a.name)), we.forEach((a) => {
2303
+ if (S.prefix && (Se[0] = S.prefix, Ie.forEach((a) => a.name = S.prefix + a.name)), Ie.forEach((a) => {
2263
2304
  t.component(a.name, a);
2264
- }), jt.forEach((a) => {
2305
+ }), Nt.forEach((a) => {
2265
2306
  t.directive(a[0], a[1]);
2266
2307
  }), S.i18n) {
2267
- M.i18n = S.i18n, S.msgPrefix && S.msgPrefix !== "d" && (M.prefix = S.msgPrefix);
2308
+ w.i18n = S.i18n, S.msgPrefix && S.msgPrefix !== "d" && (w.prefix = S.msgPrefix);
2268
2309
  return;
2269
2310
  }
2270
- S.msg && (M.msg = S.msg);
2311
+ S.msg && (w.msg = S.msg);
2271
2312
  }
2272
- const Zt = {
2313
+ const Qt = {
2273
2314
  install: Pt
2274
2315
  };
2275
2316
  export {
2276
- rt as AllCheckbox,
2277
- ft as BaseSwitch,
2278
- Ct as CacheSelect,
2279
- pt as Combi,
2280
- bt as CountRange,
2281
- $t as CurdTable,
2282
- Vt as DateRange,
2317
+ ct as AllCheckbox,
2318
+ gt as BaseSwitch,
2319
+ Bt as CacheSelect,
2320
+ bt as Combi,
2321
+ yt as CountRange,
2322
+ Tt as CurdTable,
2323
+ Dt as DateRange,
2283
2324
  xt as DateRangePicker,
2284
- At as MCalendar,
2325
+ Rt as MCalendar,
2285
2326
  Mt as ModalFooter,
2286
- Ft as PageTable,
2287
- Pe as RemoteSelect,
2288
- Ne as ToggleColumn,
2289
- Zt as default,
2327
+ Ht as PageTable,
2328
+ Ee as RemoteSelect,
2329
+ Le as ToggleColumn,
2330
+ Qt as default,
2290
2331
  Pt as install,
2291
- je as iviewSelect
2332
+ Pe as iviewSelect
2292
2333
  };