zhihao-ui 1.2.19 → 1.2.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (61) hide show
  1. package/dist/es/{BaseInfo-Dr298ctb.js → BaseInfo-DCB7xgRw.js} +1 -1
  2. package/dist/es/{Button-CDKNl8Xy.js → Button-Va8xfPJd.js} +11 -8
  3. package/dist/es/{DatePicker-vGQGWrmB.js → DatePicker-BrD1XS6-.js} +2 -2
  4. package/dist/es/DetailHeader-B9ttfBlv.js +59 -0
  5. package/dist/es/{DetailSubTitle-Cgs5HrKC.js → DetailSubTitle-BgbefcLD.js} +2 -2
  6. package/dist/es/{Dialog-cXRhcAJo.js → Dialog-CnqJMaPI.js} +31 -34
  7. package/dist/es/{DiyDataTable-DnUtQ2uX.js → DiyDataTable-uIkGrO_i.js} +80 -78
  8. package/dist/es/{EditInfoPair-B5_ufxbs.js → EditInfoPair-XiseN2F2.js} +3 -3
  9. package/dist/es/{FileWrapper-D7yKH6Y4.js → FileWrapper-CAwHicjK.js} +4 -4
  10. package/dist/es/{Grid-CIMCXeIw.js → Grid-CshEwvAH.js} +1 -1
  11. package/dist/es/{InfoPair-65CeKiUv.js → InfoPair-DhVT8u-f.js} +3 -3
  12. package/dist/es/{Input-Bg2G2kBm.js → Input-CeiPnMtt.js} +3 -3
  13. package/dist/es/{Loading-CBGHPT0Z.js → Loading-bv2DpqBO.js} +2 -2
  14. package/dist/es/Map-DhceUygQ.js +2020 -0
  15. package/dist/es/{MessageBox-d6upGeyX.js → MessageBox-2Vpy3Mva.js} +2 -2
  16. package/dist/es/{MoneyInput-CQBBD25d.js → MoneyInput-Deg1aj66.js} +7 -7
  17. package/dist/es/{PageHeadPanel-C1mqeOzI.js → PageHeadPanel-BWjWkx8n.js} +2 -2
  18. package/dist/es/{Table-BxjxzoXm.js → Table-KSl_JT2q.js} +182 -182
  19. package/dist/es/{ToolTips-C5Cm96bx.js → ToolTips-Bw2lHQxC.js} +3 -3
  20. package/dist/es/index.js +21 -21
  21. package/dist/es/{utils-CbI5IWJJ.js → utils-D-zYpBSZ.js} +3 -3
  22. package/dist/es/{vendor-AIl6iHcE.js → vendor-gTOtiVzA.js} +6895 -6495
  23. package/dist/index.css +1 -1
  24. package/dist/types/components/Button/Button.vue.d.ts +15 -2
  25. package/dist/types/components/Button/index.d.ts +15 -3
  26. package/dist/types/components/DetailHeader/index.d.ts +9 -0
  27. package/dist/types/components/DetailHeader/types.d.ts +1 -0
  28. package/dist/types/components/Dialog/Dialog.vue.d.ts +2 -4
  29. package/dist/types/components/Dialog/index.d.ts +5 -10
  30. package/dist/types/components/DiyDataTable/DiyDataTable.vue.d.ts +2 -1
  31. package/dist/types/components/DiyDataTable/index.d.ts +3 -0
  32. package/dist/types/components/DiyDataTable/type.d.ts +3 -1
  33. package/dist/types/components/Map/Map.vue.d.ts +60 -5
  34. package/dist/types/components/Map/components/scaleLine.vue.d.ts +3 -1
  35. package/dist/types/components/Map/components/toolPanel.vue.d.ts +4 -0
  36. package/dist/types/components/Map/config.d.ts +2 -0
  37. package/dist/types/components/Map/index.d.ts +174 -9
  38. package/dist/types/components/Map/interface/entity/render.d.ts +12 -0
  39. package/dist/types/components/Map/interface/entity/shipInfoVo.d.ts +21 -3
  40. package/dist/types/components/Map/interface/entity/shipMapData.d.ts +2 -1
  41. package/dist/types/components/Map/render/canvasRender/canvasRender.d.ts +2 -1
  42. package/dist/types/components/Map/render/canvasRender/geometry.d.ts +3 -0
  43. package/dist/types/components/Map/render/canvasRender/renderCustomOverlay.d.ts +3 -1
  44. package/dist/types/components/Map/render/canvasRender/renderShipStyle.d.ts +3 -1
  45. package/dist/types/components/Map/render/canvasRender/renderTrackStyle.d.ts +5 -1
  46. package/dist/types/components/Map/render/drawPolygon.d.ts +4 -0
  47. package/dist/types/components/Map/render/renderDashboard.d.ts +3 -0
  48. package/dist/types/components/Map/render/renderMarker.d.ts +4 -3
  49. package/dist/types/components/Map/render/renderShip.d.ts +5 -2
  50. package/dist/types/components/Map/render/renderTrack.d.ts +3 -4
  51. package/dist/types/components/Map/render/renderTruck.d.ts +3 -1
  52. package/dist/types/components/Map/utils/common.d.ts +4 -8
  53. package/dist/types/components/Map/utils/format.d.ts +6 -14
  54. package/dist/types/components/Map/utils/store.d.ts +7 -1
  55. package/dist/types/components/Map/utils/transform.d.ts +13 -5
  56. package/dist/types/components/Table/types.d.ts +1 -0
  57. package/dist/umd/index.css +1 -1
  58. package/dist/umd/index.umd.cjs +23 -23
  59. package/package.json +1 -1
  60. package/dist/es/DetailHeader-AxeEUXrE.js +0 -58
  61. package/dist/es/Map-BRt4EWtt.js +0 -1803
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as h, ref as o, provide as n, watch as i, resolveComponent as p, openBlock as m, createBlock as W, withCtx as v, renderSlot as b } from "vue";
2
- import { w as g } from "./utils-CbI5IWJJ.js";
2
+ import { w as g } from "./utils-D-zYpBSZ.js";
3
3
  const C = /* @__PURE__ */ h({
4
4
  name: "ZhBaseInfo",
5
5
  __name: "BaseInfo",
@@ -1,31 +1,34 @@
1
- import { defineComponent as r, openBlock as a, createBlock as u, unref as c, mergeProps as p, withCtx as l, renderSlot as i } from "vue";
2
- import { E as m, a as d } from "./vendor-AIl6iHcE.js";
3
- import { w as _ } from "./utils-CbI5IWJJ.js";
1
+ import { defineComponent as r, openBlock as a, createBlock as p, unref as u, mergeProps as c, withCtx as l, renderSlot as i } from "vue";
2
+ import { E as m, a as d } from "./vendor-gTOtiVzA.js";
3
+ import { w as _ } from "./utils-D-zYpBSZ.js";
4
4
  const h = /* @__PURE__ */ r({
5
5
  name: "ZhButton",
6
6
  inheritAttrs: !1,
7
7
  __name: "Button",
8
+ props: {
9
+ p20: { type: Boolean }
10
+ },
8
11
  emits: ["click"],
9
12
  setup(n, { emit: t }) {
10
13
  const e = t, s = (o) => {
11
14
  e("click", o);
12
15
  };
13
- return (o, Z) => (a(), u(c(m), p(o.$attrs, {
14
- class: "zh-button",
16
+ return (o, Z) => (a(), p(u(m), c(o.$attrs, {
17
+ class: ["zh-button", { "plr-20": o.p20 }],
15
18
  onClick: s
16
19
  }), {
17
20
  default: l(() => [
18
21
  i(o.$slots, "default", {}, void 0, !0)
19
22
  ]),
20
23
  _: 3
21
- }, 16));
24
+ }, 16, ["class"]));
22
25
  }
23
26
  }), f = (n, t) => {
24
27
  const e = n.__vccOpts || n;
25
28
  for (const [s, o] of t)
26
29
  e[s] = o;
27
30
  return e;
28
- }, B = /* @__PURE__ */ f(h, [["__scopeId", "data-v-59ad2ca5"]]), C = _(B), k = /* @__PURE__ */ r({
31
+ }, B = /* @__PURE__ */ f(h, [["__scopeId", "data-v-ce0229f5"]]), C = _(B), k = /* @__PURE__ */ r({
29
32
  name: "ZhButtonGroup",
30
33
  inheritAttrs: !1,
31
34
  __name: "ButtonGroup",
@@ -33,7 +36,7 @@ const h = /* @__PURE__ */ r({
33
36
  template: { default: "" }
34
37
  },
35
38
  setup(n) {
36
- return (t, e) => (a(), u(c(d), p(t.$attrs, {
39
+ return (t, e) => (a(), p(u(d), c(t.$attrs, {
37
40
  class: ["zh-button-group", { "operation-fix-button": t.template === "operation-fix-button" }]
38
41
  }), {
39
42
  default: l(() => [
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as d, openBlock as u, createElementBlock as h, normalizeClass as f, createVNode as D, unref as M, mergeProps as _ } from "vue";
2
- import { h as g, b as Y } from "./vendor-AIl6iHcE.js";
3
- import { w as A } from "./utils-CbI5IWJJ.js";
2
+ import { h as g, b as Y } from "./vendor-gTOtiVzA.js";
3
+ import { w as A } from "./utils-D-zYpBSZ.js";
4
4
  const p = "--", m = "YYYY-MM-DDTHH:mm:ss", T = "YYYY-MM-DDT23:59:59", E = "YYYY-MM-DD", C = "https://static.zhihaoscm.cn/", i = (e, l = E) => e ? g(e).format(l).replace("Invalid date", p) : p, N = (e) => typeof e == "number" ? !0 : typeof e == "string" ? !isNaN(parseFloat(e)) : !1;
5
5
  function U(e) {
6
6
  const l = ["角", "分"], c = ["零", "壹", "贰", "叁", "肆", "伍", "陆", "柒", "捌", "玖"], s = [
@@ -0,0 +1,59 @@
1
+ import { defineComponent as p, useSlots as _, openBlock as a, createElementBlock as o, createElementVNode as t, renderSlot as l, toDisplayString as i, Fragment as m, renderList as u, unref as n, normalizeClass as D, createCommentVNode as g } from "vue";
2
+ import { D as v } from "./DatePicker-BrD1XS6-.js";
3
+ import { _ as k } from "./Button-Va8xfPJd.js";
4
+ import { w as y } from "./utils-D-zYpBSZ.js";
5
+ const I = { class: "common-card" }, b = { class: "detail-header" }, E = { class: "detail-header--left" }, H = { class: "title common-title" }, M = { class: "info-pair--label" }, $ = { class: "info-pair--value" }, C = {
6
+ key: 1,
7
+ class: "detail-header--right"
8
+ }, L = { class: "info-pair--label" }, S = { class: "info-pair--value" }, V = /* @__PURE__ */ p({
9
+ name: "ZhDetailHeader",
10
+ __name: "DetailHeader",
11
+ props: {
12
+ title: {},
13
+ leftInfos: {},
14
+ rightInfos: {},
15
+ stateMeta: {},
16
+ stateDesc: {}
17
+ },
18
+ setup(f) {
19
+ const h = _(), r = f;
20
+ return (e, w) => {
21
+ var d, c;
22
+ return a(), o("div", I, [
23
+ t("div", null, [
24
+ l(e.$slots, "menu", {}, void 0, !0)
25
+ ]),
26
+ t("div", b, [
27
+ t("div", E, [
28
+ t("div", H, i(r.title), 1),
29
+ l(e.$slots, "extra-info", {}, void 0, !0),
30
+ (a(!0), o(m, null, u(r.leftInfos, (s) => (a(), o("div", {
31
+ class: "info-pair",
32
+ key: s.value
33
+ }, [
34
+ t("div", M, i(s.label), 1),
35
+ t("div", $, i(s.value ?? n(v)), 1)
36
+ ]))), 128))
37
+ ]),
38
+ l(e.$slots, "default", {}, void 0, !0),
39
+ n(h)["right-infos"] ? l(e.$slots, "right-infos", { key: 0 }, void 0, !0) : (a(), o("div", C, [
40
+ (a(!0), o(m, null, u(r.rightInfos, (s) => (a(), o("div", {
41
+ class: "info-pair",
42
+ key: s.value
43
+ }, [
44
+ t("div", L, i(s.label), 1),
45
+ t("div", S, i(s.value ?? n(v)), 1)
46
+ ]))), 128)),
47
+ e.stateDesc || e.stateMeta ? (a(), o("div", {
48
+ key: 0,
49
+ class: D(["state common-title", (d = e.stateMeta) == null ? void 0 : d.state])
50
+ }, i(e.stateDesc || ((c = e.stateMeta) == null ? void 0 : c.intro)), 3)) : g("", !0)
51
+ ]))
52
+ ])
53
+ ]);
54
+ };
55
+ }
56
+ }), Z = /* @__PURE__ */ k(V, [["__scopeId", "data-v-e58ec09d"]]), U = y(Z);
57
+ export {
58
+ U as Z
59
+ };
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as r, openBlock as o, createElementBlock as s, createElementVNode as l, createTextVNode as a, toDisplayString as t, createCommentVNode as p, normalizeClass as c, renderSlot as m, unref as d } from "vue";
2
- import { D as u } from "./DatePicker-vGQGWrmB.js";
3
- import { w as f } from "./utils-CbI5IWJJ.js";
2
+ import { D as u } from "./DatePicker-BrD1XS6-.js";
3
+ import { w as f } from "./utils-D-zYpBSZ.js";
4
4
  const _ = { class: "info-pair" }, v = { class: "info-pair--title" }, h = {
5
5
  key: 0,
6
6
  class: "info-pair--title--tip"
@@ -1,11 +1,11 @@
1
- import { defineComponent as v, useModel as b, computed as w, openBlock as r, createBlock as T, unref as D, mergeProps as M, withCtx as o, renderSlot as s, createElementVNode as c, createVNode as u, createTextVNode as p, toDisplayString as t, createElementBlock as z, createCommentVNode as E, mergeModels as m } from "vue";
2
- import { Z as f } from "./Button-CDKNl8Xy.js";
3
- import { c as Z } from "./vendor-AIl6iHcE.js";
4
- import { w as I } from "./utils-CbI5IWJJ.js";
5
- const N = { class: "title" }, O = {
1
+ import { defineComponent as V, useModel as k, computed as w, openBlock as r, createBlock as T, unref as v, mergeProps as D, withCtx as o, renderSlot as a, createElementVNode as c, createVNode as u, createTextVNode as p, toDisplayString as l, createElementBlock as M, createCommentVNode as z, mergeModels as m } from "vue";
2
+ import { Z as f } from "./Button-Va8xfPJd.js";
3
+ import { c as E } from "./vendor-gTOtiVzA.js";
4
+ import { w as Z } from "./utils-D-zYpBSZ.js";
5
+ const I = { class: "title" }, N = {
6
6
  key: 0,
7
7
  class: "sub-title"
8
- }, S = { class: "zh-dialog__footer" }, _ = /* @__PURE__ */ v({
8
+ }, O = { class: "zh-dialog__footer" }, S = /* @__PURE__ */ V({
9
9
  __name: "Dialog",
10
10
  props: /* @__PURE__ */ m({
11
11
  title: {},
@@ -43,54 +43,51 @@ const N = { class: "title" }, O = {
43
43
  modelValue: { type: Boolean, default: !0 },
44
44
  modelModifiers: {}
45
45
  }),
46
- emits: /* @__PURE__ */ m(["cancel", "confirm", "close"], ["update:modelValue"]),
47
- setup(d, { emit: B }) {
48
- const a = d, l = b(d, "modelValue"), n = B, y = () => {
49
- n("close");
46
+ emits: /* @__PURE__ */ m(["submit", "close"], ["update:modelValue"]),
47
+ setup(n, { emit: B }) {
48
+ const t = n, s = k(n, "modelValue"), d = B, y = () => {
49
+ d("close");
50
50
  }, h = () => {
51
- l.value = !1, n("cancel");
52
- }, C = () => {
53
- l.value = !1, n("confirm");
54
- }, g = {
51
+ d("submit");
52
+ }, C = {
55
53
  small: "400px",
56
54
  middle: "600px",
57
55
  large: "800px",
58
56
  extraLarge: "920px"
59
- }, V = w(() => a.width ? a.width : g[a.size]);
60
- return (e, i) => (r(), T(D(Z), M({
61
- modelValue: l.value,
62
- "onUpdate:modelValue": i[0] || (i[0] = (k) => l.value = k),
57
+ }, g = w(() => t.width ? t.width : C[t.size]);
58
+ return (e, i) => (r(), T(v(E), D({
59
+ modelValue: s.value,
60
+ "onUpdate:modelValue": i[0] || (i[0] = (b) => s.value = b),
63
61
  class: "zh-dialog"
64
62
  }, e.$attrs, {
65
- width: V.value,
66
- "close-on-click-modal": e.closeOnClickModal,
67
- onClose: y
63
+ width: g.value,
64
+ "close-on-click-modal": e.closeOnClickModal
68
65
  }), {
69
66
  header: o(() => [
70
- s(e.$slots, "header", {}, () => [
71
- c("div", N, t(e.title), 1),
72
- e.subTitle ? (r(), z("div", O, t(e.subTitle), 1)) : E("", !0)
67
+ a(e.$slots, "header", {}, () => [
68
+ c("div", I, l(e.title), 1),
69
+ e.subTitle ? (r(), M("div", N, l(e.subTitle), 1)) : z("", !0)
73
70
  ])
74
71
  ]),
75
72
  footer: o(() => [
76
- s(e.$slots, "footer", {}, () => [
77
- c("div", S, [
73
+ a(e.$slots, "footer", {}, () => [
74
+ c("div", O, [
78
75
  u(f, {
79
76
  plain: "",
80
- onClick: h
77
+ onClick: y
81
78
  }, {
82
79
  default: o(() => [
83
- p(t(e.cancelButtonText), 1)
80
+ p(l(e.cancelButtonText), 1)
84
81
  ]),
85
82
  _: 1
86
83
  }),
87
84
  u(f, {
88
85
  type: "primary",
89
86
  disabled: e.confirmButtonDisabled,
90
- onClick: C
87
+ onClick: h
91
88
  }, {
92
89
  default: o(() => [
93
- p(t(e.confirmButtonText), 1)
90
+ p(l(e.confirmButtonText), 1)
94
91
  ]),
95
92
  _: 1
96
93
  }, 8, ["disabled"])
@@ -98,13 +95,13 @@ const N = { class: "title" }, O = {
98
95
  ])
99
96
  ]),
100
97
  default: o(() => [
101
- s(e.$slots, "default")
98
+ a(e.$slots, "default")
102
99
  ]),
103
100
  _: 3
104
101
  }, 16, ["modelValue", "width", "close-on-click-modal"]));
105
102
  }
106
- }), A = I(_);
103
+ }), P = Z(S);
107
104
  export {
108
- A as Z,
109
- _
105
+ P as Z,
106
+ S as _
110
107
  };
@@ -1,13 +1,13 @@
1
- import { defineComponent as H, useModel as N, ref as b, openBlock as d, createBlock as g, unref as s, withCtx as p, createVNode as v, createElementBlock as f, Fragment as W, renderList as Z, normalizeClass as D, toDisplayString as m, renderSlot as C, createCommentVNode as k, createElementVNode as y, createTextVNode as V, mergeModels as z } from "vue";
2
- import { D as P } from "./DatePicker-vGQGWrmB.js";
3
- import { d as E, e as $, f as X, g as j, i as _, j as T, k as K, l as M, E as A } from "./vendor-AIl6iHcE.js";
4
- import { _ as G } from "./Button-CDKNl8Xy.js";
5
- import { w as J } from "./utils-CbI5IWJJ.js";
6
- var c = /* @__PURE__ */ ((u) => (u.AUTOCOMPLETE = "autocomplete", u.FORMAT = "format", u.TEXT = "text", u))(c || {});
1
+ import { defineComponent as H, useModel as N, ref as b, openBlock as d, createBlock as g, unref as s, withCtx as p, createVNode as v, createElementBlock as f, Fragment as W, renderList as Z, normalizeClass as D, toDisplayString as c, renderSlot as C, createCommentVNode as k, createElementVNode as y, createTextVNode as V, mergeModels as z } from "vue";
2
+ import { D as P } from "./DatePicker-BrD1XS6-.js";
3
+ import { d as w, e as $, f as X, g as j, i as E, j as T, k as K, l as M, E as A } from "./vendor-gTOtiVzA.js";
4
+ import { _ as G } from "./Button-Va8xfPJd.js";
5
+ import { w as J } from "./utils-D-zYpBSZ.js";
6
+ var m = /* @__PURE__ */ ((u) => (u.AUTOCOMPLETE = "autocomplete", u.FORMAT = "format", u.TEXT = "text", u))(m || {});
7
7
  const Q = { key: 0 }, Y = {
8
8
  key: 1,
9
9
  class: "col-edit-header"
10
- }, ee = ["onClick"], te = { key: 0 }, ae = { key: 2 }, le = { class: "header-operation-container" }, re = { class: "operation-container" }, oe = ["onClick"], L = "$ZH_DIV$", ie = /* @__PURE__ */ H({
10
+ }, ee = ["onClick"], te = { key: 0 }, ae = { key: 2 }, re = { class: "header-operation-container" }, le = { class: "operation-container" }, oe = ["onClick"], L = "$ZH_DIV$", ie = /* @__PURE__ */ H({
11
11
  name: "zh-diy-data-table",
12
12
  __name: "DiyDataTable",
13
13
  props: /* @__PURE__ */ z({
@@ -21,26 +21,26 @@ const Q = { key: 0 }, Y = {
21
21
  }),
22
22
  emits: ["update:rawData"],
23
23
  setup(u, { expose: R }) {
24
- const h = u, n = N(u, "rawData"), o = b([]), U = () => {
24
+ const h = u, n = N(u, "rawData"), o = b([]), F = () => {
25
25
  if (n.value.length === h.maxRowLength) {
26
- E({
26
+ w({
27
27
  message: `最多添加${h.maxRowLength}行`,
28
28
  type: "warning"
29
29
  });
30
30
  return;
31
31
  }
32
32
  n.value.push({});
33
- }, F = () => {
33
+ }, U = () => {
34
34
  if (o.value.filter((e) => e.isAdd).length >= h.maxColLength) {
35
- E({
35
+ w({
36
36
  message: `最多添加${h.maxColLength}列`,
37
37
  type: "warning"
38
38
  });
39
39
  return;
40
40
  }
41
- const l = String(Date.now());
41
+ const r = String(Date.now());
42
42
  o.value.push({
43
- prop: l,
43
+ prop: r,
44
44
  label: "",
45
45
  isEditHeader: !0,
46
46
  isAdd: !0,
@@ -48,76 +48,76 @@ const Q = { key: 0 }, Y = {
48
48
  minWidth: 150,
49
49
  headerMaxlength: 15
50
50
  });
51
- }, S = (a, l) => {
51
+ }, S = (a, r) => {
52
52
  o.value.splice(a, 1), n.value.forEach((e) => {
53
- delete e[l.prop];
53
+ delete e[r.prop];
54
54
  });
55
55
  }, I = (a) => {
56
56
  n.value.splice(a, 1);
57
- }, O = (a, l, e) => {
58
- l(
59
- e.completeList.filter((r) => r.includes(a)).map((r) => ({ value: r }))
57
+ }, O = (a, r, e) => {
58
+ r(
59
+ e.completeList.filter((l) => l.includes(a)).map((l) => ({ value: l }))
60
60
  );
61
61
  }, q = (a) => [
62
62
  {
63
- validator: (l, e, r) => {
63
+ validator: (r, e, l) => {
64
64
  if (!o.value[a].label) {
65
- r(new Error("请输入表头"));
65
+ l(new Error("请输入表头"));
66
66
  return;
67
67
  }
68
- r();
68
+ l();
69
69
  },
70
70
  message: "请输入表头",
71
71
  trigger: ["blur", "change"]
72
72
  }
73
73
  ], B = (a) => {
74
- const l = [];
75
- return a.required && l.push({
74
+ const r = [];
75
+ return a.required && r.push({
76
76
  required: !0,
77
77
  message: "请输入" + a.label,
78
78
  trigger: a.slot ? void 0 : "blur"
79
- }), a.varidate && l.push({
80
- validator: (e, r, t) => {
81
- const i = a.varidate(r);
79
+ }), a.varidate && r.push({
80
+ validator: (e, l, t) => {
81
+ const i = a.varidate(l);
82
82
  i !== !0 ? t(new Error(i)) : t();
83
83
  },
84
84
  trigger: a.slot ? void 0 : "blur"
85
- }), l;
86
- }, w = b();
85
+ }), r;
86
+ }, _ = b();
87
87
  return R({
88
88
  /** 初始化数据 */
89
- initData: (a, l) => {
90
- console.log("initData", a, l), a = $(a) || [], a.length === 0 && a.push({}), l = [...l];
89
+ initData: (a, r) => {
90
+ console.log("initData", a, r), a = $(a) || [], a.length === 0 && a.push({}), r = [...r];
91
91
  for (const e in a[0])
92
- if (!l.some(
93
- (r) => r.prop === e
92
+ if (!r.some(
93
+ (l) => l.prop === e
94
94
  )) {
95
- const r = Date.now() + e, t = e.split(L);
95
+ const l = Date.now() + e, t = e.split(L);
96
96
  if (t.length !== 2) {
97
97
  console.log("keySplit 失败", e);
98
98
  continue;
99
99
  }
100
100
  const i = Number(t[1]);
101
- l[i] = {
101
+ r[i] = {
102
102
  prop: e,
103
103
  isEditHeader: !0,
104
104
  label: t[0],
105
- key: r,
105
+ key: l,
106
106
  isAdd: !0,
107
107
  maxlength: 15,
108
108
  headerMaxlength: 15
109
109
  };
110
110
  }
111
- n.value = a, o.value = l;
111
+ n.value = a, o.value = r;
112
112
  },
113
113
  /** 获取数据 */
114
114
  getData: async () => {
115
- await w.value.validate();
116
- for (const l in o.value) {
117
- const e = o.value[l];
118
- for (const r of o.value)
119
- if (e.prop !== r.prop && e.label === r.label) {
120
- E({
115
+ await _.value.validate();
116
+ for (const r in o.value) {
117
+ const e = o.value[r];
118
+ for (const l of o.value)
119
+ if (e.prop !== l.prop && e.label === l.label) {
120
+ w({
121
121
  message: "所有列的表头不可重复",
122
122
  type: "warning"
123
123
  });
@@ -125,17 +125,17 @@ const Q = { key: 0 }, Y = {
125
125
  }
126
126
  }
127
127
  const a = $(n.value);
128
- for (const l in a) {
129
- const e = a[l];
130
- for (const r in o.value) {
131
- const t = o.value[r];
132
- if (t.isSameData && l !== "0" && (e[t.prop] = a[0][t.prop]), t.varidate && !t.varidate(e[t.prop]))
128
+ for (const r in a) {
129
+ const e = a[r];
130
+ for (const l in o.value) {
131
+ const t = o.value[l];
132
+ if (t.isSameData && r !== "0" && (e[t.prop] = a[0][t.prop]), t.varidate && !t.varidate(e[t.prop]))
133
133
  return;
134
134
  if (t.isAdd) {
135
- const i = t.label + L + r;
135
+ const i = t.label + L + l;
136
136
  e[i] = e[t.prop], delete e[t.prop];
137
137
  }
138
- t.formatter && t.type === c.FORMAT && (e[t.prop] = t.formatter(e));
138
+ t.formatter && t.type === m.FORMAT && (e[t.prop] = t.formatter(e));
139
139
  }
140
140
  }
141
141
  return console.log("DiyDataTable 获取数据", a, o.value), {
@@ -144,13 +144,13 @@ const Q = { key: 0 }, Y = {
144
144
  };
145
145
  },
146
146
  /** 更新列配置数据 */
147
- updateColumn: (a, l) => {
147
+ updateColumn: (a, r) => {
148
148
  const e = o.value[a].prop;
149
- if (o.value[a] = l, e !== l.prop)
150
- for (const r of n.value)
151
- r[l.prop] = r[e], delete r[e];
149
+ if (o.value[a] = r, e !== r.prop)
150
+ for (const l of n.value)
151
+ l[r.prop] = l[e], delete l[e];
152
152
  },
153
- /** 重置列配置数据 */
153
+ /** 重置默认列配置数据 */
154
154
  resetColumns: (a) => {
155
155
  const e = o.value.filter((t) => !t.isAdd).reduce((t, i) => (a.some((x) => x.prop === i.prop) || t.push(i.prop), t), []);
156
156
  n.value.forEach((t) => {
@@ -158,26 +158,26 @@ const Q = { key: 0 }, Y = {
158
158
  delete t[i];
159
159
  });
160
160
  });
161
- const r = a.filter((t) => t.isAdd);
162
- o.value = [...a, ...r];
161
+ const l = a.filter((t) => t.isAdd);
162
+ o.value = [...a, ...l];
163
163
  }
164
- }), (a, l) => (d(), g(s(X), {
164
+ }), (a, r) => (d(), g(s(X), {
165
165
  class: "diy-data-table",
166
166
  model: u.rawData,
167
167
  ref_key: "formRef",
168
- ref: w
168
+ ref: _
169
169
  }, {
170
170
  default: p(() => [
171
171
  v(s(j), { data: n.value }, {
172
172
  default: p(() => [
173
- v(s(_), {
173
+ v(s(E), {
174
174
  type: "index",
175
175
  label: "序号",
176
176
  width: "132",
177
177
  fixed: "left"
178
178
  }),
179
- (d(!0), f(W, null, Z(o.value, (e, r) => (d(), g(s(_), {
180
- key: e.key || r,
179
+ (d(!0), f(W, null, Z(o.value, (e, l) => (d(), g(s(E), {
180
+ key: e.key || l,
181
181
  prop: e.prop,
182
182
  label: e.label,
183
183
  width: e.width,
@@ -187,8 +187,8 @@ const Q = { key: 0 }, Y = {
187
187
  header: p(() => [
188
188
  a.isEdit ? e.isEditHeader ? (d(), f("div", Y, [
189
189
  v(s(T), {
190
- prop: `columns.${r}`,
191
- rules: q(r)
190
+ prop: `columns.${l}`,
191
+ rules: q(l)
192
192
  }, {
193
193
  default: p(() => [
194
194
  v(s(M), {
@@ -203,22 +203,24 @@ const Q = { key: 0 }, Y = {
203
203
  e.isAdd ? (d(), f("i", {
204
204
  key: 0,
205
205
  class: "iconfont icon-close",
206
- onClick: (t) => S(r, e)
206
+ onClick: (t) => S(l, e)
207
207
  }, null, 8, ee)) : k("", !0)
208
208
  ])) : (d(), f("div", {
209
209
  key: 2,
210
210
  class: D({ "is-required-label": e.required })
211
- }, m(e.label), 3)) : (d(), f("div", Q, m(e.label), 1))
211
+ }, c(e.label), 3)) : (d(), f("div", Q, c(e.label), 1))
212
212
  ]),
213
213
  default: p((t) => [
214
- h.isEdit && (!e.isSameData || t.$index === 0) && e.type !== s(c).TEXT ? (d(), g(s(T), {
214
+ h.isEdit && (!e.isSameData || t.$index === 0) && e.type !== s(m).TEXT ? (d(), g(s(T), {
215
215
  key: 0,
216
216
  prop: `${t.$index}.${e.prop}`,
217
217
  rules: B(e),
218
218
  class: D(["col-edit-container", { "close-padding": e.isAdd }])
219
219
  }, {
220
220
  default: p(() => [
221
- e.type === s(c).FORMAT && e.formatter ? (d(), f("div", te, m(e.formatter(t.row)), 1)) : e.type === s(c).AUTOCOMPLETE ? (d(), g(s(K), {
221
+ e.type === s(m).FORMAT && e.formatter ? (d(), f("div", te, c(e.showFormatter ? e.showFormatter(
222
+ e.formatter(t.row)
223
+ ) : e.formatter(t.row)), 1)) : e.type === s(m).AUTOCOMPLETE ? (d(), g(s(K), {
222
224
  key: 1,
223
225
  modelValue: t.row[e.prop],
224
226
  "onUpdate:modelValue": (i) => t.row[e.prop] = i,
@@ -244,23 +246,23 @@ const Q = { key: 0 }, Y = {
244
246
  key: 1,
245
247
  row: t.row,
246
248
  $index: t.$index
247
- }, void 0, !0) : (d(), f("div", ae, m((e.isSameData ? n.value[0][e.prop] : t.row[e.prop]) || s(P)), 1))
249
+ }, void 0, !0) : (d(), f("div", ae, c((e.isSameData ? n.value[0][e.prop] : t.row[e.prop]) || s(P)), 1))
248
250
  ]),
249
251
  _: 2
250
252
  }, 1032, ["prop", "label", "width", "min-width", "fixed"]))), 128)),
251
- h.isEdit ? (d(), g(s(_), {
253
+ h.isEdit ? (d(), g(s(E), {
252
254
  key: 0,
253
255
  width: "150",
254
256
  fixed: "right"
255
257
  }, {
256
258
  header: p(() => [
257
- y("div", le, [
259
+ y("div", re, [
258
260
  v(s(A), {
259
261
  type: "primary",
260
262
  link: "",
261
- onClick: U
263
+ onClick: F
262
264
  }, {
263
- default: p(() => l[0] || (l[0] = [
265
+ default: p(() => r[0] || (r[0] = [
264
266
  y("i", { class: "iconfont icon-Frame1" }, null, -1),
265
267
  V("增行")
266
268
  ])),
@@ -269,9 +271,9 @@ const Q = { key: 0 }, Y = {
269
271
  v(s(A), {
270
272
  type: "primary",
271
273
  link: "",
272
- onClick: F
274
+ onClick: U
273
275
  }, {
274
- default: p(() => l[1] || (l[1] = [
276
+ default: p(() => r[1] || (r[1] = [
275
277
  y("i", { class: "iconfont icon-Frame-11" }, null, -1),
276
278
  V("增列")
277
279
  ])),
@@ -280,11 +282,11 @@ const Q = { key: 0 }, Y = {
280
282
  ])
281
283
  ]),
282
284
  default: p(({ $index: e }) => [
283
- y("div", re, [
285
+ y("div", le, [
284
286
  n.value.length > 1 ? (d(), f("i", {
285
287
  key: 0,
286
288
  class: "iconfont icon-close",
287
- onClick: (r) => I(e)
289
+ onClick: (l) => I(e)
288
290
  }, null, 8, oe)) : k("", !0)
289
291
  ])
290
292
  ]),
@@ -297,8 +299,8 @@ const Q = { key: 0 }, Y = {
297
299
  _: 3
298
300
  }, 8, ["model"]));
299
301
  }
300
- }), se = /* @__PURE__ */ G(ie, [["__scopeId", "data-v-a77561c1"]]), he = J(se);
302
+ }), se = /* @__PURE__ */ G(ie, [["__scopeId", "data-v-74d07c51"]]), he = J(se);
301
303
  export {
302
- c as D,
304
+ m as D,
303
305
  he as Z
304
306
  };
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as l, openBlock as o, createElementBlock as s, createElementVNode as a, createTextVNode as r, toDisplayString as t, createCommentVNode as p, normalizeClass as c, renderSlot as d, unref as m } from "vue";
2
- import { D as f } from "./DatePicker-vGQGWrmB.js";
3
- import { _ } from "./Button-CDKNl8Xy.js";
4
- import { w as u } from "./utils-CbI5IWJJ.js";
2
+ import { D as f } from "./DatePicker-BrD1XS6-.js";
3
+ import { _ } from "./Button-Va8xfPJd.js";
4
+ import { w as u } from "./utils-D-zYpBSZ.js";
5
5
  const v = { class: "info-pair" }, h = { class: "info-pair--title" }, E = {
6
6
  key: 0,
7
7
  class: "info-pair--title--tip"
@@ -1,8 +1,8 @@
1
1
  import { defineComponent as f, openBlock as i, createElementBlock as o, toDisplayString as n, createCommentVNode as s, createElementVNode as t, createVNode as p, unref as m, withCtx as _, createTextVNode as u } from "vue";
2
- import { D as w } from "./DatePicker-vGQGWrmB.js";
3
- import { m as y } from "./vendor-AIl6iHcE.js";
4
- import { _ as h } from "./Button-CDKNl8Xy.js";
5
- import { w as v } from "./utils-CbI5IWJJ.js";
2
+ import { D as w } from "./DatePicker-BrD1XS6-.js";
3
+ import { m as y } from "./vendor-gTOtiVzA.js";
4
+ import { _ as h } from "./Button-Va8xfPJd.js";
5
+ import { w as v } from "./utils-D-zYpBSZ.js";
6
6
  const k = { class: "file_wrapper" }, x = {
7
7
  key: 0,
8
8
  class: "header"
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as $, onBeforeMount as B, useSlots as C, ref as k, computed as f, onMounted as L, onActivated as S, onUnmounted as j, onDeactivated as M, provide as p, watch as z, openBlock as P, createElementBlock as R, normalizeStyle as Z, renderSlot as D } from "vue";
2
- import { w as H } from "./utils-CbI5IWJJ.js";
2
+ import { w as H } from "./utils-D-zYpBSZ.js";
3
3
  const N = /* @__PURE__ */ $({
4
4
  name: "zh-grid",
5
5
  __name: "Grid",
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as l, openBlock as i, createElementBlock as s, createElementVNode as a, createTextVNode as r, toDisplayString as t, createCommentVNode as p, normalizeClass as c, renderSlot as m, unref as f } from "vue";
2
- import { D as d } from "./DatePicker-vGQGWrmB.js";
3
- import { _ } from "./Button-CDKNl8Xy.js";
4
- import { w as u } from "./utils-CbI5IWJJ.js";
2
+ import { D as d } from "./DatePicker-BrD1XS6-.js";
3
+ import { _ } from "./Button-Va8xfPJd.js";
4
+ import { w as u } from "./utils-D-zYpBSZ.js";
5
5
  const v = { class: "info-pair" }, h = { class: "info-pair--title" }, I = {
6
6
  key: 0,
7
7
  class: "info-pair--title--tip"
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as b, useAttrs as v, useModel as k, openBlock as h, createElementBlock as I, normalizeClass as z, createVNode as S, unref as $, mergeProps as N, createSlots as x, renderList as _, withCtx as y, renderSlot as B, normalizeProps as M, guardReactiveProps as C, mergeModels as E, normalizeStyle as j } from "vue";
2
- import { l as P } from "./vendor-AIl6iHcE.js";
3
- import { _ as U } from "./Button-CDKNl8Xy.js";
4
- import { w as Z } from "./utils-CbI5IWJJ.js";
2
+ import { l as P } from "./vendor-gTOtiVzA.js";
3
+ import { _ as U } from "./Button-Va8xfPJd.js";
4
+ import { w as Z } from "./utils-D-zYpBSZ.js";
5
5
  const A = /* @__PURE__ */ b({
6
6
  name: "zh-input",
7
7
  __name: "Input",