zjh-web-ui 1.0.10 → 1.0.11

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 (121) hide show
  1. package/config/resolver.js +1 -1
  2. package/dist/components/HuiAMapMassMarkers/HuiAMapMassMarkers.vue.js +23 -23
  3. package/dist/components/HuiAMapSearchAddress/HuiAMapSearchAddress.vue.js +2 -2
  4. package/dist/components/HuiAMapSearchAddress/HuiAMapSearchAddress.vue2.js +27 -27
  5. package/dist/components/HuiAMapSearchAddressDialog/HuiAMapSearchAddressDialog.vue.js +38 -38
  6. package/dist/components/HuiAMapSelectAddress/HuiAMapSelectAddress.vue.js +2 -2
  7. package/dist/components/HuiAMapSelectAddress/HuiAMapSelectAddress.vue2.js +80 -80
  8. package/dist/components/HuiAMapSelectAddressDialog/HuiAMapSelectAddressDialog.vue.js +23 -23
  9. package/dist/components/HuiCountDownButton/HuiCountDownButton.vue.js +14 -14
  10. package/dist/components/HuiDataView/HuiDataView.vue2.js +37 -37
  11. package/dist/components/HuiGridForm/HuiGridForm.vue.js +2 -2
  12. package/dist/components/HuiGridForm/HuiGridForm.vue2.js +103 -103
  13. package/dist/components/HuiGridForm/HuiGridFormHooks.js +1 -1
  14. package/dist/components/HuiLineEditDialog/HuiLineEditDialog.vue2.js +69 -69
  15. package/dist/components/HuiLineEditPopover/HuiLineEditPopover.vue2.js +47 -47
  16. package/dist/components/HuiPreviewRichTextDialog/HuiPreviewRichTextDialog.vue.js +21 -21
  17. package/dist/components/HuiRegionTreeDialog/HuiRegionTreeDialog.vue.js +49 -49
  18. package/dist/components/HuiRegionTreeSelect/HuiRegionTreeSelect.vue2.js +2 -2
  19. package/dist/components/HuiSelectLoadStatus/HuiSelectLoadStatus.vue.js +14 -14
  20. package/dist/components/HuiShowUrlDialog/HuiShowUrlDialog.vue.js +18 -18
  21. package/dist/components/HuiStringArrayInputDialog/HuiStringArrayInputDialog.vue.js +50 -50
  22. package/dist/components/HuiTags/HuiTags.vue2.js +9 -9
  23. package/dist/components/HuiTagsMore/HuiTagsMore.vue.js +12 -16
  24. package/dist/components/HuiTinymce/HuiTinymce.vue.js +10 -10
  25. package/dist/components/HuiTinymceDialog/HuiTinymceDialog.vue.js +43 -43
  26. package/dist/components/HuiTip/HuiTip.vue.js +15 -15
  27. package/dist/hooks/useHuiFormDialog/useHuiFormDialog.js +1 -1
  28. package/dist/index.d.ts +2116 -0
  29. package/dist/style.css +1 -1
  30. package/dist/utils/hui-rules.js +1 -1
  31. package/dist/utils/hui-tool/message-box/index.js +3 -3
  32. package/dist/utils/hui-tool/message-box/message-box.vue2.js +112 -0
  33. package/dist/utils/hui-tool/message-box/message-box.vue3.js +2 -2
  34. package/global.d.ts +21 -21
  35. package/package.json +1 -1
  36. package/types/index.d.ts +2115 -12
  37. package/dist/utils/hui-tool/message-box/message-box.vue.js +0 -112
  38. package/types/components/AMapConfig.d.ts +0 -2
  39. package/types/components/HuiAMapMassMarkers/HuiAMapMassMarkers.vue.d.ts +0 -105
  40. package/types/components/HuiAMapMassMarkers/index.d.ts +0 -107
  41. package/types/components/HuiAMapMassMarkers/type.d.ts +0 -58
  42. package/types/components/HuiAMapSearchAddress/HuiAMapSearchAddress.vue.d.ts +0 -76
  43. package/types/components/HuiAMapSearchAddress/index.d.ts +0 -77
  44. package/types/components/HuiAMapSearchAddress/type.d.ts +0 -19
  45. package/types/components/HuiAMapSearchAddressDialog/HuiAMapSearchAddressDialog.vue.d.ts +0 -38
  46. package/types/components/HuiAMapSearchAddressDialog/index.d.ts +0 -71
  47. package/types/components/HuiAMapSearchAddressDialog/type.d.ts +0 -17
  48. package/types/components/HuiAMapSelectAddress/HuiAMapSelectAddress.vue.d.ts +0 -76
  49. package/types/components/HuiAMapSelectAddress/index.d.ts +0 -77
  50. package/types/components/HuiAMapSelectAddress/type.d.ts +0 -19
  51. package/types/components/HuiAMapSelectAddressDialog/HuiAMapSelectAddressDialog.vue.d.ts +0 -38
  52. package/types/components/HuiAMapSelectAddressDialog/index.d.ts +0 -71
  53. package/types/components/HuiAMapSelectAddressDialog/type.d.ts +0 -17
  54. package/types/components/HuiCountDownButton/HuiCountDownButton.vue.d.ts +0 -44
  55. package/types/components/HuiCountDownButton/index.d.ts +0 -76
  56. package/types/components/HuiCountDownButton/type.d.ts +0 -20
  57. package/types/components/HuiDataView/HuiDataView.vue.d.ts +0 -60
  58. package/types/components/HuiDataView/index.d.ts +0 -109
  59. package/types/components/HuiDataView/type.d.ts +0 -49
  60. package/types/components/HuiGridForm/HuiGridForm.vue.d.ts +0 -77
  61. package/types/components/HuiGridForm/HuiGridFormHooks.d.ts +0 -4
  62. package/types/components/HuiGridForm/index.d.ts +0 -175
  63. package/types/components/HuiGridForm/type.d.ts +0 -67
  64. package/types/components/HuiLineEditDialog/HuiLineEditDialog.vue.d.ts +0 -75
  65. package/types/components/HuiLineEditDialog/index.d.ts +0 -173
  66. package/types/components/HuiLineEditDialog/type.d.ts +0 -86
  67. package/types/components/HuiLineEditPopover/HuiLineEditPopover.vue.d.ts +0 -74
  68. package/types/components/HuiLineEditPopover/index.d.ts +0 -133
  69. package/types/components/HuiLineEditPopover/type.d.ts +0 -23
  70. package/types/components/HuiPreviewRichTextDialog/HuiPreviewRichTextDialog.vue.d.ts +0 -31
  71. package/types/components/HuiPreviewRichTextDialog/index.d.ts +0 -22
  72. package/types/components/HuiPreviewRichTextDialog/type.d.ts +0 -4
  73. package/types/components/HuiRegionTreeDialog/HuiRegionTreeDialog.vue.d.ts +0 -53
  74. package/types/components/HuiRegionTreeDialog/index.d.ts +0 -68
  75. package/types/components/HuiRegionTreeDialog/type.d.ts +0 -24
  76. package/types/components/HuiRegionTreeSelect/HuiRegionTreeSelect.vue.d.ts +0 -25
  77. package/types/components/HuiRegionTreeSelect/index.d.ts +0 -29
  78. package/types/components/HuiRegionTreeSelect/type.d.ts +0 -6
  79. package/types/components/HuiSelectLoadStatus/HuiSelectLoadStatus.vue.d.ts +0 -14
  80. package/types/components/HuiSelectLoadStatus/index.d.ts +0 -33
  81. package/types/components/HuiSelectLoadStatus/type.d.ts +0 -11
  82. package/types/components/HuiShowUrlDialog/HuiShowUrlDialog.vue.d.ts +0 -37
  83. package/types/components/HuiShowUrlDialog/index.d.ts +0 -40
  84. package/types/components/HuiShowUrlDialog/type.d.ts +0 -11
  85. package/types/components/HuiStringArrayInputDialog/HuiStringArrayInputDialog.vue.d.ts +0 -44
  86. package/types/components/HuiStringArrayInputDialog/index.d.ts +0 -67
  87. package/types/components/HuiStringArrayInputDialog/type.d.ts +0 -33
  88. package/types/components/HuiTags/HuiTags.vue.d.ts +0 -37
  89. package/types/components/HuiTags/index.d.ts +0 -36
  90. package/types/components/HuiTagsMore/HuiTagsMore.vue.d.ts +0 -93
  91. package/types/components/HuiTagsMore/index.d.ts +0 -92
  92. package/types/components/HuiTinymce/HuiTinymce.vue.d.ts +0 -62
  93. package/types/components/HuiTinymce/HuiTinymceLinkHooks.d.ts +0 -3
  94. package/types/components/HuiTinymce/HuiTinymceSettingHooks.d.ts +0 -3
  95. package/types/components/HuiTinymce/index.d.ts +0 -66
  96. package/types/components/HuiTinymce/type.d.ts +0 -51
  97. package/types/components/HuiTinymceDialog/HuiTinymceDialog.vue.d.ts +0 -53
  98. package/types/components/HuiTinymceDialog/index.d.ts +0 -78
  99. package/types/components/HuiTinymceDialog/type.d.ts +0 -12
  100. package/types/components/HuiTip/HuiTip.vue.d.ts +0 -22
  101. package/types/components/HuiTip/index.d.ts +0 -99
  102. package/types/components/HuiTip/type.d.ts +0 -14
  103. package/types/components-install-list.d.ts +0 -3328
  104. package/types/components.d.ts +0 -21
  105. package/types/delegate.d.ts +0 -41
  106. package/types/directives/index.d.ts +0 -4
  107. package/types/directives/install-loadmore.d.ts +0 -7
  108. package/types/directives/select-loadmore.d.ts +0 -7
  109. package/types/hooks/index.d.ts +0 -3
  110. package/types/hooks/useHuiDialog/useHuiDialog.d.ts +0 -18
  111. package/types/hooks/useHuiFormDialog/formDialogPropsDef.d.ts +0 -3
  112. package/types/hooks/useHuiFormDialog/type.d.ts +0 -90
  113. package/types/hooks/useHuiFormDialog/useHuiFormDialog.d.ts +0 -32
  114. package/types/install-helper/install.d.ts +0 -18
  115. package/types/install-helper/typescript.d.ts +0 -14
  116. package/types/utils/hui-rules.d.ts +0 -80
  117. package/types/utils/hui-tool/index.d.ts +0 -8
  118. package/types/utils/hui-tool/message-box/index.d.ts +0 -18
  119. package/types/utils/hui-tool/message-box/message-box.vue.d.ts +0 -36
  120. package/types/utils/hui-tool/msg-tool.d.ts +0 -26
  121. package/types/utils/index.d.ts +0 -2
@@ -2,7 +2,7 @@
2
2
  function getHuiResolved(name) {
3
3
  return {
4
4
  name,
5
- from: '@hua5/hua5-web-ui',
5
+ from: 'zjh-web-ui',
6
6
  }
7
7
  }
8
8
 
@@ -1,7 +1,7 @@
1
- import { defineComponent as h, mergeModels as d, ref as w, useModel as M, onMounted as k, openBlock as v, createElementBlock as y, normalizeStyle as b, nextTick as g } from "vue";
2
- import { testUtils as s } from "@hua5/hua5-utils";
3
- import { addAMap as C } from "../AMapConfig.js";
4
- const x = /* @__PURE__ */ h({
1
+ import { defineComponent as h, mergeModels as d, ref as M, useModel as w, onMounted as k, createElementBlock as v, openBlock as y, normalizeStyle as b, nextTick as g } from "vue";
2
+ import { testUtils as s } from "zjh-utils";
3
+ import { addAMap as x } from "../AMapConfig.js";
4
+ const A = /* @__PURE__ */ h({
5
5
  name: "HuiAMapMassMarkers",
6
6
  __name: "HuiAMapMassMarkers",
7
7
  props: /* @__PURE__ */ d({
@@ -12,8 +12,8 @@ const x = /* @__PURE__ */ h({
12
12
  direction: { default: "top" },
13
13
  textStyle: { default: () => ({
14
14
  fontSize: 12,
15
- fillColor: window.theme.colors.white,
16
- backgroundColor: window.theme.colors.ccc,
15
+ // fillColor: window.theme.colors.white,
16
+ // backgroundColor: window.theme.colors.ccc,
17
17
  borderRadius: 2
18
18
  }) },
19
19
  iconPath: { default: "//a.amap.com/jsapi_demos/static/demo-center/icons/poi-marker-default.png" },
@@ -24,20 +24,20 @@ const x = /* @__PURE__ */ h({
24
24
  modelModifiers: {}
25
25
  }),
26
26
  emits: /* @__PURE__ */ d(["pointClick"], ["update:modelValue"]),
27
- setup(i, { expose: c, emit: m }) {
28
- const u = m, a = i, n = w(null), t = M(i, "modelValue");
29
- function l(e, o) {
30
- u("pointClick", o);
27
+ setup(i, { expose: c, emit: u }) {
28
+ const m = u, a = i, n = M(null), o = w(i, "modelValue");
29
+ function l(t, e) {
30
+ m("pointClick", e);
31
31
  }
32
32
  function p() {
33
33
  g(() => {
34
34
  n.value = new window.AMap.Map("mapContainer", {
35
35
  zoom: 10,
36
36
  viewMode: "3D",
37
- center: t.value.length ? t.value[0].position : a.mapCenter,
37
+ center: o.value.length ? o.value[0].position : a.mapCenter,
38
38
  showLabel: a.showLabel
39
39
  });
40
- const e = new window.AMap.LabelsLayer({
40
+ const t = new window.AMap.LabelsLayer({
41
41
  zooms: [3, 20],
42
42
  // 缩放范围
43
43
  zIndex: 1e3,
@@ -45,11 +45,11 @@ const x = /* @__PURE__ */ h({
45
45
  collision: !1
46
46
  // 该层内标注是否避让
47
47
  });
48
- n.value.add(e), s.isArray(t.value) && s.isNotEmpty(t.value) && t.value.forEach((o) => {
48
+ n.value.add(t), s.isArray(o.value) && s.isNotEmpty(o.value) && o.value.forEach((e) => {
49
49
  const r = new window.AMap.LabelMarker({
50
- position: o.position,
50
+ position: e.position,
51
51
  text: {
52
- content: o.name,
52
+ content: e.name,
53
53
  direction: a.direction,
54
54
  style: {
55
55
  ...a.textStyle
@@ -57,26 +57,26 @@ const x = /* @__PURE__ */ h({
57
57
  },
58
58
  icon: {
59
59
  type: "iamge",
60
- image: o.iconPath || a.iconPath,
60
+ image: e.iconPath || a.iconPath,
61
61
  size: a.iconSize
62
62
  }
63
63
  });
64
- e.add(r), r.on("click", (f) => l(f, o));
64
+ t.add(r), r.on("click", (f) => l(f, e));
65
65
  });
66
66
  });
67
67
  }
68
68
  return k(async () => {
69
69
  try {
70
- await C(), p();
71
- } catch (e) {
72
- console.error("Error loading map:", e);
70
+ await x(), p();
71
+ } catch (t) {
72
+ console.error("Error loading map:", t);
73
73
  }
74
- }), c({ handleLabelMarkerClick: l }), (e, o) => (v(), y("div", {
74
+ }), c({ handleLabelMarkerClick: l }), (t, e) => (y(), v("div", {
75
75
  id: "mapContainer",
76
- style: b({ height: e.height, width: e.width })
76
+ style: b({ height: i.height, width: i.width })
77
77
  }, null, 4));
78
78
  }
79
79
  });
80
80
  export {
81
- x as default
81
+ A as default
82
82
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./HuiAMapSearchAddress.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const e = /* @__PURE__ */ r(o, [["__scopeId", "data-v-c1edc60f"]]);
4
+ const p = /* @__PURE__ */ r(o, [["__scopeId", "data-v-c7f1eb0d"]]);
5
5
  export {
6
- e as default
6
+ p as default
7
7
  };
@@ -1,10 +1,10 @@
1
- import { defineComponent as J, mergeModels as Q, ref as s, useModel as W, onMounted as X, nextTick as x, watch as N, reactive as Y, computed as $, openBlock as h, createElementBlock as P, createElementVNode as i, createVNode as ee, unref as g, withDirectives as ae, createBlock as H, withCtx as z, Fragment as te, renderList as le, toDisplayString as D, normalizeStyle as oe } from "vue";
1
+ import { defineComponent as J, mergeModels as Q, ref as s, useModel as W, onMounted as X, nextTick as N, watch as b, reactive as Y, computed as $, createElementBlock as P, openBlock as h, createElementVNode as i, createVNode as ee, unref as g, withDirectives as ae, createBlock as H, withCtx as z, Fragment as te, renderList as le, toDisplayString as D, normalizeStyle as oe } from "vue";
2
2
  import { addAMap as ne } from "../AMapConfig.js";
3
- import { testUtils as d } from "@hua5/hua5-utils";
3
+ import { testUtils as d } from "zjh-utils";
4
4
  import { HuiTool as se } from "../../utils/hui-tool/index.js";
5
5
  import { selectLoadmore as ie } from "../../directives/select-loadmore.js";
6
6
  import { ElCascader as re, ElSelect as de, ElOption as ue } from "element-plus";
7
- const ce = { class: "AMap" }, pe = { class: "flex h-32 lh-32 mb-20" }, me = { class: "flex h-32 lh-32 mb-20" }, ve = { class: "flex justify-between text-14" }, fe = { class: "c-regular" }, he = { class: "c-disabled" }, ge = ["id"], xe = /* @__PURE__ */ J({
7
+ const ce = { class: "AMap" }, pe = { class: "flex h-32 lh-32 mb-20" }, me = { class: "flex h-32 lh-32 mb-20" }, ve = { class: "flex justify-between text-14" }, fe = { class: "c-regular" }, he = { class: "c-disabled" }, ge = ["id"], ke = /* @__PURE__ */ J({
8
8
  name: "HuiAMapSearchAddress",
9
9
  __name: "HuiAMapSearchAddress",
10
10
  props: /* @__PURE__ */ Q({
@@ -20,8 +20,8 @@ const ce = { class: "AMap" }, pe = { class: "flex h-32 lh-32 mb-20" }, me = { cl
20
20
  modelModifiers: {}
21
21
  }),
22
22
  emits: ["update:modelValue"],
23
- setup(b, { expose: K }) {
24
- const C = b, O = s(""), u = s(null), c = s(null), t = W(b, "modelValue"), m = s(""), r = s([]), E = s([]), p = s([]), w = s(""), S = s(F(2));
23
+ setup(w, { expose: K }) {
24
+ const C = w, O = s(""), u = s(null), c = s(null), t = W(w, "modelValue"), m = s(""), r = s([]), E = s([]), p = s([]), M = s(""), S = s(F(2));
25
25
  X(async () => {
26
26
  E.value = await window.huiDelegate.getRegionTree(), V();
27
27
  });
@@ -31,14 +31,14 @@ const ce = { class: "AMap" }, pe = { class: "flex h-32 lh-32 mb-20" }, me = { cl
31
31
  });
32
32
  }
33
33
  function L() {
34
- x(() => {
34
+ N(() => {
35
35
  R(() => {
36
36
  var l, e, a, o;
37
37
  if (d.isNotEmpty(t.value)) {
38
- const { provinceName: n, cityName: _, districtName: f, street: k, streetShort: q } = t.value;
39
- r.value = [{ ...t.value, pname: n, cityname: _, adname: f, address: q, name: k }], m.value = t.value.id, p.value = t.value.regionCode;
38
+ const { provinceName: n, cityName: x, districtName: f, street: k, streetShort: q } = t.value;
39
+ r.value = [{ ...t.value, pname: n, cityname: x, adname: f, address: q, name: k }], m.value = t.value.id, p.value = t.value.regionCode;
40
40
  }
41
- (l = t.value) != null && l.longitude && ((e = t.value) != null && e.latitude) && (y(t.value.longitude, t.value.latitude), A(t.value.longitude, t.value.latitude)), (a = t.value) != null && a.lon && ((o = t.value) != null && o.lat) && (y(t.value.lon, t.value.lat), A(t.value.lon, t.value.lat));
41
+ (l = t.value) != null && l.longitude && ((e = t.value) != null && e.latitude) && (A(t.value.longitude, t.value.latitude), _(t.value.longitude, t.value.latitude)), (a = t.value) != null && a.lon && ((o = t.value) != null && o.lat) && (A(t.value.lon, t.value.lat), _(t.value.lon, t.value.lat));
42
42
  });
43
43
  });
44
44
  }
@@ -54,31 +54,31 @@ const ce = { class: "AMap" }, pe = { class: "flex h-32 lh-32 mb-20" }, me = { cl
54
54
  })()
55
55
  }), c.value.setMapStyle('amap://styles/f695f9484e6fb466b6680b7806a5eae6")'), l();
56
56
  }
57
- N(p, (l) => {
58
- d.isArray(l) ? w.value = l[l.length - 1] : w.value = l;
59
- }), N(t, (l) => {
57
+ b(p, (l) => {
58
+ d.isArray(l) ? M.value = l[l.length - 1] : M.value = l;
59
+ }), b(t, (l) => {
60
60
  O.value = l.formattedAddress;
61
61
  }, { deep: !0 });
62
- const M = Y({
63
- city: $(() => w.value),
62
+ const y = Y({
63
+ city: $(() => M.value),
64
64
  citylimit: !1,
65
65
  pageSize: 20,
66
66
  pageIndex: 1,
67
67
  extensions: "all"
68
68
  }), I = s(0), v = s("");
69
- N(v, () => {
70
- r.value = [], M.pageIndex = 1;
69
+ b(v, () => {
70
+ r.value = [], y.pageIndex = 1;
71
71
  });
72
72
  function U(l) {
73
73
  const e = r.value.find((n) => n.id == l) || {};
74
74
  t.value = e, p.value = e.adcode;
75
75
  const a = e.location.KT || e.location.lat, o = e.location.KL || e.location.lng;
76
- B(), y(o, a), A(o, a), c.value.setCenter([o, a]), c.value.setZoom(18);
76
+ B(), A(o, a), _(o, a), c.value.setCenter([o, a]), c.value.setZoom(18);
77
77
  }
78
78
  function T(l) {
79
79
  d.isEmpty(l) || (v.value = l, window.AMap.plugin("AMap.PlaceSearch", async function() {
80
- await x();
81
- var e = new window.AMap.PlaceSearch(M);
80
+ await N();
81
+ var e = new window.AMap.PlaceSearch(y);
82
82
  e.search(v.value, function(a, o) {
83
83
  d.isEmpty(o) || d.isEmpty(o.poiList.pois) || (o.poiList.pois.forEach((n) => {
84
84
  n.provinceName = n.pname, n.cityName = n.cityname, n.districtName = n.adname, n.street = n.address, n.streetShort = n.name, n.addressName = n.name;
@@ -87,9 +87,9 @@ const ce = { class: "AMap" }, pe = { class: "flex h-32 lh-32 mb-20" }, me = { cl
87
87
  }));
88
88
  }
89
89
  function j() {
90
- r.value.length >= I.value || (M.pageIndex++, T(v.value));
90
+ r.value.length >= I.value || (y.pageIndex++, T(v.value));
91
91
  }
92
- function y(l, e) {
92
+ function A(l, e) {
93
93
  B(), u.value = new window.AMap.Marker({
94
94
  position: [l, e],
95
95
  map: c.value
@@ -104,13 +104,13 @@ const ce = { class: "AMap" }, pe = { class: "flex h-32 lh-32 mb-20" }, me = { cl
104
104
  const o = document.createElement("span");
105
105
  o.className = "AMap__marker top-0 abs", o.innerHTML = l, e.appendChild(o), u.value.setContent(e);
106
106
  }
107
- function A(l, e) {
107
+ function _(l, e) {
108
108
  window.AMap.plugin("AMap.Geocoder", function() {
109
109
  new window.AMap.Geocoder().getAddress([l, e], (o, n) => {
110
- o === "complete" && n.info === "OK" ? x(() => {
110
+ o === "complete" && n.info === "OK" ? N(() => {
111
111
  var f;
112
- const _ = ((f = r.value.find((k) => k.id == m.value)) == null ? void 0 : f.name) || "";
113
- G(_);
112
+ const x = ((f = r.value.find((k) => k.id == m.value)) == null ? void 0 : f.name) || "";
113
+ G(x);
114
114
  }) : console.error("获取地址失败", n);
115
115
  });
116
116
  });
@@ -174,7 +174,7 @@ const ce = { class: "AMap" }, pe = { class: "flex h-32 lh-32 mb-20" }, me = { cl
174
174
  ]),
175
175
  i("div", {
176
176
  class: "AMap__content-box",
177
- style: oe({ height: l.height })
177
+ style: oe({ height: w.height })
178
178
  }, [
179
179
  i("div", {
180
180
  id: S.value,
@@ -186,5 +186,5 @@ const ce = { class: "AMap" }, pe = { class: "flex h-32 lh-32 mb-20" }, me = { cl
186
186
  }
187
187
  });
188
188
  export {
189
- xe as default
189
+ ke as default
190
190
  };
@@ -1,10 +1,10 @@
1
- import { defineComponent as V, ref as d, openBlock as C, createBlock as S, unref as o, isRef as k, withCtx as a, createVNode as s, createTextVNode as p, mergeProps as H, toValue as M } from "vue";
1
+ import { defineComponent as C, ref as p, createBlock as S, openBlock as k, unref as o, isRef as H, withCtx as l, createVNode as d, mergeProps as M, createTextVNode as m, toValue as x } from "vue";
2
2
  import { useHuiDialog as B } from "../../hooks/useHuiDialog/useHuiDialog.js";
3
- import { ElDialog as D, ElButton as m } from "element-plus";
4
- import "@hua5/hua5-utils";
5
- /* empty css */
6
- import x from "../HuiAMapSearchAddress/HuiAMapSearchAddress.vue.js";
7
- const L = /* @__PURE__ */ V({
3
+ import { ElDialog as D, ElButton as f } from "element-plus";
4
+ import "zjh-utils";
5
+ /* empty css */
6
+ import R from "../HuiAMapSearchAddress/HuiAMapSearchAddress.vue.js";
7
+ const L = /* @__PURE__ */ C({
8
8
  name: "HuiAMapSearchAddressDialog",
9
9
  __name: "HuiAMapSearchAddressDialog",
10
10
  props: {
@@ -18,57 +18,57 @@ const L = /* @__PURE__ */ V({
18
18
  title: { default: "地图位置选择" }
19
19
  },
20
20
  emits: ["onSubmit"],
21
- setup(R, { expose: f, emit: c }) {
22
- const y = c, n = d(null), { show: i, open: h, close: u, payload: v, confirmLoading: w } = B(), t = d(null);
23
- async function A() {
24
- n.value.loadMap(), t.value = M(v) || "";
21
+ setup(r, { expose: c, emit: y }) {
22
+ const h = y, a = p(null), { show: n, open: v, close: i, payload: w, confirmLoading: A } = B(), t = p(null);
23
+ async function b() {
24
+ a.value.loadMap(), t.value = x(w) || "";
25
25
  }
26
- function b() {
26
+ function g() {
27
27
  t.value = "";
28
28
  }
29
- function g() {
30
- n.value.submitInfo() && (y("onSubmit", t.value), u());
29
+ function V() {
30
+ a.value.submitInfo() && (h("onSubmit", t.value), i());
31
31
  }
32
- return f({
33
- open: h,
34
- close: u
35
- }), (l, e) => (C(), S(o(D), {
36
- modelValue: o(i),
37
- "onUpdate:modelValue": e[1] || (e[1] = (r) => k(i) ? i.value = r : null),
38
- title: l.title,
39
- width: l.width,
32
+ return c({
33
+ open: v,
34
+ close: i
35
+ }), (s, e) => (k(), S(o(D), {
36
+ modelValue: o(n),
37
+ "onUpdate:modelValue": e[1] || (e[1] = (u) => H(n) ? n.value = u : null),
38
+ title: r.title,
39
+ width: r.width,
40
40
  top: "5vh",
41
41
  "modal-append-to-body": !1,
42
42
  "append-to-body": "",
43
43
  "destroy-on-close": "",
44
- onOpen: A,
45
- onClose: b
44
+ onOpen: b,
45
+ onClose: g
46
46
  }, {
47
- footer: a(() => [
48
- s(o(m), { onClick: o(u) }, {
49
- default: a(() => e[2] || (e[2] = [
50
- p("取 消")
51
- ])),
47
+ footer: l(() => [
48
+ d(o(f), { onClick: o(i) }, {
49
+ default: l(() => [...e[2] || (e[2] = [
50
+ m("取 消", -1)
51
+ ])]),
52
52
  _: 1
53
53
  }, 8, ["onClick"]),
54
- s(o(m), {
54
+ d(o(f), {
55
55
  type: "primary",
56
56
  class: "w-100",
57
- loading: o(w),
58
- onClick: g
57
+ loading: o(A),
58
+ onClick: V
59
59
  }, {
60
- default: a(() => e[3] || (e[3] = [
61
- p("确定")
62
- ])),
60
+ default: l(() => [...e[3] || (e[3] = [
61
+ m("确定", -1)
62
+ ])]),
63
63
  _: 1
64
64
  }, 8, ["loading"])
65
65
  ]),
66
- default: a(() => [
67
- s(x, H(l.$props, {
66
+ default: l(() => [
67
+ d(R, M(s.$props, {
68
68
  ref_key: "HuiAMapSelectAddressRef",
69
- ref: n,
69
+ ref: a,
70
70
  modelValue: t.value,
71
- "onUpdate:modelValue": e[0] || (e[0] = (r) => t.value = r),
71
+ "onUpdate:modelValue": e[0] || (e[0] = (u) => t.value = u),
72
72
  class: "m-y-20",
73
73
  "show-input": !0,
74
74
  width: "100%"
@@ -1,7 +1,7 @@
1
1
  import o from "./HuiAMapSelectAddress.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../_virtual/_plugin-vue_export-helper.js";
4
- const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-04e6bda1"]]);
4
+ const s = /* @__PURE__ */ t(o, [["__scopeId", "data-v-b22c1e3b"]]);
5
5
  export {
6
- p as default
6
+ s as default
7
7
  };
@@ -1,12 +1,12 @@
1
- import { defineComponent as z, mergeModels as L, ref as s, useModel as O, watch as U, onMounted as j, openBlock as m, createElementBlock as _, normalizeStyle as f, createBlock as x, unref as R, createCommentVNode as y, createElementVNode as v, normalizeClass as D, nextTick as h } from "vue";
1
+ import { defineComponent as K, mergeModels as z, ref as s, useModel as L, watch as O, onMounted as U, createElementBlock as y, openBlock as f, normalizeStyle as v, createBlock as j, createCommentVNode as I, createElementVNode as h, unref as R, normalizeClass as D, nextTick as g } from "vue";
2
2
  import { addAMap as G } from "../AMapConfig.js";
3
- import { testUtils as I } from "@hua5/hua5-utils";
3
+ import { testUtils as _ } from "zjh-utils";
4
4
  import { HuiTool as q } from "../../utils/hui-tool/index.js";
5
5
  import { ElInput as F } from "element-plus";
6
- const J = ["id"], $ = /* @__PURE__ */ z({
6
+ const J = ["id"], $ = /* @__PURE__ */ K({
7
7
  name: "HuiAMapSelectAddress",
8
8
  __name: "HuiAMapSelectAddress",
9
- props: /* @__PURE__ */ L({
9
+ props: /* @__PURE__ */ z({
10
10
  disabled: { type: Boolean, default: !1 },
11
11
  value: {},
12
12
  width: { default: "40vw" },
@@ -19,16 +19,16 @@ const J = ["id"], $ = /* @__PURE__ */ z({
19
19
  modelModifiers: {}
20
20
  }),
21
21
  emits: ["update:modelValue"],
22
- setup(g, { expose: b }) {
23
- const r = g, c = s(""), l = s(null), i = s(null), a = O(g, "modelValue");
24
- U(a, (e) => {
25
- c.value = e.formattedAddress;
22
+ setup(l, { expose: b }) {
23
+ const r = l, d = s(""), i = s(null), u = s(null), a = L(l, "modelValue");
24
+ O(a, (t) => {
25
+ d.value = t.formattedAddress;
26
26
  }, { deep: !0 });
27
27
  function w() {
28
- h(() => {
29
- V(() => {
30
- var e, t, n;
31
- (e = a.value) != null && e.longitude && ((t = a.value) != null && t.latitude) && (d(a.value.longitude, a.value.latitude), p(a.value.longitude, a.value.latitude)), (n = a.value) != null && n.location && (d(a.value.location.lng, a.value.location.lat), p(a.value.location.lng, a.value.location.lat));
28
+ g(() => {
29
+ T(() => {
30
+ var t, e, n;
31
+ (t = a.value) != null && t.longitude && ((e = a.value) != null && e.latitude) && (m(a.value.longitude, a.value.latitude), p(a.value.longitude, a.value.latitude)), (n = a.value) != null && n.location && (m(a.value.location.lng, a.value.location.lat), p(a.value.location.lng, a.value.location.lat));
32
32
  });
33
33
  });
34
34
  }
@@ -37,88 +37,88 @@ const J = ["id"], $ = /* @__PURE__ */ z({
37
37
  }
38
38
  function C() {
39
39
  if (!r.showInput) return;
40
- const e = document.getElementById("map__result");
40
+ const t = document.getElementById("map__result");
41
41
  setTimeout(() => {
42
- const t = document.querySelector(".amap_lib_placeSearch");
43
- e.innerHTML = t ? "" : '<h3 class="w-full text-center text-12">暂无搜索结果</h3>';
42
+ const e = document.querySelector(".amap_lib_placeSearch");
43
+ t.innerHTML = e ? "" : '<h3 class="w-full text-center text-12">暂无搜索结果</h3>';
44
44
  }, 200);
45
45
  }
46
46
  function S() {
47
- return I.isNotEmpty(a.value) ? !0 : (q.err("请选择地址"), !1);
47
+ return _.isNotEmpty(a.value) ? !0 : (q.err("请选择地址"), !1);
48
48
  }
49
- function d(e, t) {
50
- M(), l.value = new window.AMap.Marker({
51
- position: [e, t],
52
- map: i.value
53
- }), l.value.setMap(i.value);
49
+ function m(t, e) {
50
+ M(), i.value = new window.AMap.Marker({
51
+ position: [t, e],
52
+ map: u.value
53
+ }), i.value.setMap(u.value);
54
54
  }
55
55
  function M() {
56
- l.value && (l.value.setMap(null), l.value = null);
56
+ i.value && (i.value.setMap(null), i.value = null);
57
57
  }
58
- function E(e) {
59
- const t = document.createElement("div"), n = document.createElement("img");
60
- if (n.className = r.iconClass, n.src = r.iconPath, t.appendChild(n), !e) return;
58
+ function x(t) {
59
+ const e = document.createElement("div"), n = document.createElement("img");
60
+ if (n.className = r.iconClass, n.src = r.iconPath, e.appendChild(n), !t) return;
61
61
  const o = document.createElement("span");
62
- o.className = "AMap__marker", o.innerHTML = e, t.appendChild(o), l.value.setContent(t);
62
+ o.className = "AMap__marker", o.innerHTML = t, e.appendChild(o), i.value.setContent(e);
63
63
  }
64
- function p(e, t) {
64
+ function p(t, e) {
65
65
  window.AMap.plugin("AMap.Geocoder", function() {
66
- new window.AMap.Geocoder().getAddress([e, t], (o, u) => {
67
- if (o === "complete" && u.info === "OK") {
68
- const K = u.regeocode;
69
- a.value = Object.assign(K, {
70
- longitude: e,
71
- latitude: t
72
- }), h(() => {
73
- E(a.value.formattedAddress);
66
+ new window.AMap.Geocoder().getAddress([t, e], (o, c) => {
67
+ if (o === "complete" && c.info === "OK") {
68
+ const H = c.regeocode;
69
+ a.value = Object.assign(H, {
70
+ longitude: t,
71
+ latitude: e
72
+ }), g(() => {
73
+ x(a.value.formattedAddress);
74
74
  });
75
75
  } else
76
- console.error("获取地址失败", u);
76
+ console.error("获取地址失败", c);
77
77
  });
78
78
  });
79
79
  }
80
- function T() {
81
- i.value.on("click", (e) => {
82
- const t = e.lnglat, n = t.KT || t.lat, o = t.KL || t.lng;
83
- d(o, n), p(o, n);
80
+ function E() {
81
+ u.value.on("click", (t) => {
82
+ const e = t.lnglat, n = e.KT || e.lat, o = e.KL || e.lng;
83
+ m(o, n), p(o, n);
84
84
  });
85
85
  }
86
- function V(e) {
87
- i.value = new window.AMap.Map(A.value, {
88
- zoom: I.isNotEmpty(a.value) ? 23 : 13,
86
+ function T(t) {
87
+ u.value = new window.AMap.Map(A.value, {
88
+ zoom: _.isNotEmpty(a.value) ? 23 : 13,
89
89
  center: (() => {
90
- var t, n, o;
91
- if ((t = a.value) != null && t.longitude && ((n = a.value) != null && n.latitude))
90
+ var e, n, o;
91
+ if ((e = a.value) != null && e.longitude && ((n = a.value) != null && n.latitude))
92
92
  return [a.value.longitude, a.value.latitude];
93
93
  if ((o = a.value) != null && o.location)
94
94
  return [a.value.location.lng, a.value.location.lat];
95
95
  })()
96
- }), i.value.setMapStyle('amap://styles/f695f9484e6fb466b6680b7806a5eae6")'), setTimeout(() => {
97
- B();
98
- }), T(), e();
96
+ }), u.value.setMapStyle('amap://styles/f695f9484e6fb466b6680b7806a5eae6")'), setTimeout(() => {
97
+ V();
98
+ }), E(), t();
99
99
  }
100
- function B() {
101
- r.showInput && window.AMapUI.loadUI(["misc/PoiPicker"], (e) => {
102
- window.poiPicker = new e({
100
+ function V() {
101
+ r.showInput && window.AMapUI.loadUI(["misc/PoiPicker"], (t) => {
102
+ window.poiPicker = new t({
103
103
  input: "map__input",
104
104
  placeSearchOptions: {
105
- map: i.value,
105
+ map: u.value,
106
106
  pageSize: 10
107
107
  },
108
108
  searchResultsContainer: "map__result"
109
- }), window.poiPicker.on("poiPicked", N);
109
+ }), window.poiPicker.on("poiPicked", B);
110
110
  });
111
111
  }
112
- function N(e) {
112
+ function B(t) {
113
113
  M();
114
- const t = e.source, n = e.item;
115
- h(() => {
116
- var o, u;
114
+ const e = t.source, n = t.item;
115
+ g(() => {
116
+ var o, c;
117
117
  a.value = Object.assign(n, {
118
118
  formattedAddress: n.name,
119
119
  longitude: (o = n.location) == null ? void 0 : o.KL,
120
- latitude: (u = n.location) == null ? void 0 : u.kT
121
- }), t !== "search" && window.poiPicker.searchByKeyword(n.name);
120
+ latitude: (c = n.location) == null ? void 0 : c.kT
121
+ }), e !== "search" && window.poiPicker.searchByKeyword(n.name);
122
122
  });
123
123
  }
124
124
  function k() {
@@ -126,49 +126,49 @@ const J = ["id"], $ = /* @__PURE__ */ z({
126
126
  w();
127
127
  });
128
128
  }
129
- j(() => {
129
+ U(() => {
130
130
  k();
131
131
  });
132
- function H(e) {
133
- const t = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
132
+ function N(t) {
133
+ const e = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
134
134
  let n = "";
135
- for (let o = 0; o < e; o++)
136
- n += t.charAt(Math.floor(Math.random() * t.length));
135
+ for (let o = 0; o < t; o++)
136
+ n += e.charAt(Math.floor(Math.random() * e.length));
137
137
  return "map__container" + n;
138
138
  }
139
- const A = s(H(2));
140
- return b({ loadMap: k, setupMap: w, poi: a, submitInfo: S }), (e, t) => (m(), _("div", {
139
+ const A = s(N(2));
140
+ return b({ loadMap: k, setupMap: w, poi: a, submitInfo: S }), (t, e) => (f(), y("div", {
141
141
  class: "AMap",
142
- style: f({ width: e.width, height: e.height })
142
+ style: v({ width: l.width, height: l.height })
143
143
  }, [
144
- e.showInput ? (m(), x(R(F), {
144
+ l.showInput ? (f(), j(R(F), {
145
145
  key: 0,
146
146
  id: "map__input",
147
- modelValue: c.value,
148
- "onUpdate:modelValue": t[0] || (t[0] = (n) => c.value = n),
147
+ modelValue: d.value,
148
+ "onUpdate:modelValue": e[0] || (e[0] = (n) => d.value = n),
149
149
  class: "AMap__content-input",
150
150
  readonly: r.disabled,
151
151
  clearable: "",
152
152
  placeholder: "输入关键字选取地点",
153
153
  onInput: P
154
- }, null, 8, ["modelValue", "readonly"])) : y("", !0),
155
- v("div", {
156
- class: D(["AMap__content-box", e.showInput ? "" : "noEvents"])
154
+ }, null, 8, ["modelValue", "readonly"])) : I("", !0),
155
+ h("div", {
156
+ class: D(["AMap__content-box", l.showInput ? "" : "noEvents"])
157
157
  }, [
158
- v("div", {
158
+ h("div", {
159
159
  id: A.value,
160
- style: f({ height: e.height }),
160
+ style: v({ height: l.height }),
161
161
  class: "AMap__content-container",
162
162
  tabindex: "0"
163
163
  }, null, 12, J),
164
- e.showInput ? (m(), _("div", {
164
+ l.showInput ? (f(), y("div", {
165
165
  key: 0,
166
166
  id: "map__result",
167
- style: f({ height: e.height }),
167
+ style: v({ height: l.height }),
168
168
  class: "AMap__content-result"
169
- }, t[1] || (t[1] = [
170
- v("h3", { class: "w-full text-center text-12" }, "暂无搜索结果", -1)
171
- ]), 4)) : y("", !0)
169
+ }, [...e[1] || (e[1] = [
170
+ h("h3", { class: "w-full text-center text-12" }, "暂无搜索结果", -1)
171
+ ])], 4)) : I("", !0)
172
172
  ], 2)
173
173
  ], 4));
174
174
  }