@das-fed/ui 6.4.0-dev.55.15 → 6.4.0-dev.55.16
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/esm-map.json +1 -0
- package/package.json +5 -5
- package/packages/business-components/change-pwd/index.js +21 -21
- package/packages/business-components/change-pwd/index.js.gz +0 -0
- package/packages/components/cascader/index.d.ts +225 -7
- package/packages/components/cascader/index.js +65 -64
- package/packages/components/cascader/index.js.gz +0 -0
- package/packages/components/cascader/src/Index.vue.d.ts +2 -2
- package/packages/components/cascader/style.css +1 -1
- package/packages/components/cascader/style.css.gz +0 -0
- package/packages/components/date-picker/index.d.ts +3 -3
- package/packages/components/date-picker/src/DateRangePicker.vue.d.ts +1 -1
- package/packages/components/form-item/index.js +823 -821
- package/packages/components/form-item/index.js.gz +0 -0
- package/packages/components/form-item/src/type.d.ts +2 -0
- package/packages/components/form-item/style.css +1 -1
- package/packages/components/form-item/style.css.gz +0 -0
- package/packages/components/map/i18n/index.d.ts +10 -0
- package/packages/components/map/index.js +1101 -838
- package/packages/components/map/index.js.gz +0 -0
- package/packages/components/map/src/get-sdk-config.d.ts +1 -1
- package/packages/components/map/src/hooks/use-baidu.d.ts +1 -11
- package/packages/components/map/src/hooks/use-gaode.d.ts +1 -11
- package/packages/components/map/src/hooks/use-google.d.ts +16 -0
- package/packages/components/map/src/hooks/use-map.d.ts +2 -0
- package/packages/components/map/src/type.d.ts +1 -1
- package/packages/components/map/style.css +1 -1
- package/packages/components/rich-editor/index.js +1049 -1048
- package/packages/components/rich-editor/index.js.gz +0 -0
- package/packages/components/rich-editor/src/type.d.ts +3 -0
- package/packages/components/search-form/index.js +436 -435
- package/packages/components/search-form/index.js.gz +0 -0
- package/packages/components/search-form/style.css +1 -1
- package/packages/components/search-form/style.css.gz +0 -0
|
@@ -1,43 +1,44 @@
|
|
|
1
1
|
import '@das-fed/ui/packages/components/map/style.css';
|
|
2
|
-
import { ref as
|
|
3
|
-
import { withInstall as
|
|
4
|
-
import { ElAutocomplete as
|
|
2
|
+
import { ref as S, defineComponent as Ae, shallowRef as I, computed as Se, onMounted as Oe, openBlock as Te, createElementBlock as je, normalizeStyle as Le, createElementVNode as W, withDirectives as Z, createVNode as de, unref as D, withKeys as $e, h as Qt, render as ea, isRef as ta, vShow as Fe, withCtx as aa, createTextVNode as oa, toDisplayString as ra } from "vue";
|
|
3
|
+
import { withInstall as Ee } from "@das-fed/utils/with-install/index";
|
|
4
|
+
import { ElAutocomplete as Pe, ElLoadingDirective as ke } from "element-plus/es";
|
|
5
5
|
import "element-plus/es/components/base/style/css";
|
|
6
6
|
import "element-plus/es/components/loading/style/css";
|
|
7
7
|
import "element-plus/es/components/autocomplete/style/css";
|
|
8
|
-
import { t as
|
|
9
|
-
import { vDasTooltip as
|
|
10
|
-
import { DasMessage as
|
|
11
|
-
import { createService as
|
|
12
|
-
|
|
8
|
+
import { t as E, setI18nRule as na } from "@das-fed/web/packages/i18n/index";
|
|
9
|
+
import { vDasTooltip as Re } from "@das-fed/ui/packages/components/text-tooltip/index";
|
|
10
|
+
import { DasMessage as z } from "@das-fed/ui/packages/components/message/index";
|
|
11
|
+
import { createService as ct } from "@das-fed/utils/create-api-service";
|
|
12
|
+
import { DasButton as la } from "@das-fed/ui/packages/components/button/index";
|
|
13
|
+
const Q = (e) => {
|
|
13
14
|
if (e)
|
|
14
15
|
return typeof e == "string" && hasCssUnit(e) ? e : e + "px";
|
|
15
|
-
},
|
|
16
|
-
const
|
|
17
|
-
let
|
|
18
|
-
const
|
|
19
|
-
|
|
20
|
-
const
|
|
21
|
-
if (
|
|
22
|
-
const
|
|
23
|
-
|
|
24
|
-
securityJsCode: "${
|
|
25
|
-
}`, document.head.appendChild(
|
|
16
|
+
}, st = ({ MapGL: e, map: t, marker: a, mapLoading: n, $autocomplete: u, searchResultList: l, innerInput: r, innerPoint: o, adCode: s, addressInfo: v }, b) => {
|
|
17
|
+
const C = S();
|
|
18
|
+
let M;
|
|
19
|
+
const k = (O, g, p, w) => {
|
|
20
|
+
C.value = p, w && (M = w);
|
|
21
|
+
const L = document.createElement("script");
|
|
22
|
+
if (L.src = `${location.protocol}//webapi.amap.com/maps?v=1.4.15&key=${O}&plugin=AMap.CitySearch&callback=onLoad`, g) {
|
|
23
|
+
const d = document.createElement("script");
|
|
24
|
+
d.innerHTML = `window._AMapSecurityConfig = {
|
|
25
|
+
securityJsCode: "${g}",
|
|
26
|
+
}`, document.head.appendChild(d);
|
|
26
27
|
}
|
|
27
|
-
document.head.appendChild(
|
|
28
|
-
|
|
28
|
+
document.head.appendChild(L), window.onLoad = () => {
|
|
29
|
+
$();
|
|
29
30
|
};
|
|
30
|
-
},
|
|
31
|
-
var
|
|
31
|
+
}, $ = () => {
|
|
32
|
+
var O, g;
|
|
32
33
|
if (e.value = AMap, !(typeof e.value > "u")) {
|
|
33
34
|
try {
|
|
34
|
-
const
|
|
35
|
+
const p = ((O = C.value) == null ? void 0 : O.mapOpt) ?? {};
|
|
35
36
|
t.value = new AMap.Map("map", {
|
|
36
37
|
zoom: 15,
|
|
37
|
-
...
|
|
38
|
+
...p
|
|
38
39
|
});
|
|
39
40
|
} catch {
|
|
40
|
-
|
|
41
|
+
n.value = !1, z.error(E("thirdPartyMapErrorRetry"));
|
|
41
42
|
}
|
|
42
43
|
AMap.plugin(["AMap.ToolBar"], () => {
|
|
43
44
|
t.value.addControl(
|
|
@@ -47,159 +48,160 @@ const W = (e) => {
|
|
|
47
48
|
liteStyle: !0
|
|
48
49
|
})
|
|
49
50
|
);
|
|
50
|
-
}), i(), (
|
|
51
|
+
}), i(), (g = C.value) != null && g.clickStream || c(), n.value = !1, M && M();
|
|
51
52
|
}
|
|
52
|
-
},
|
|
53
|
-
t.value.on("click", (
|
|
54
|
-
a.value && t.value.remove(a.value),
|
|
53
|
+
}, c = () => {
|
|
54
|
+
t.value.on("click", (O) => {
|
|
55
|
+
a.value && t.value.remove(a.value), o.value = [O.lnglat.getLng(), O.lnglat.getLat()], h(o.value, !0).then(() => {
|
|
55
56
|
a.value = new AMap.Marker({
|
|
56
|
-
position:
|
|
57
|
-
title:
|
|
58
|
-
}), t.value.add(a.value), t.value.setCenter(
|
|
57
|
+
position: o.value,
|
|
58
|
+
title: r.value
|
|
59
|
+
}), t.value.add(a.value), t.value.setCenter(o.value);
|
|
59
60
|
});
|
|
60
61
|
});
|
|
61
62
|
}, i = async () => {
|
|
62
|
-
!
|
|
63
|
-
if (
|
|
64
|
-
const
|
|
65
|
-
(
|
|
63
|
+
!r.value && !o.value.length && B(), r.value && o.value.length > 0 ? await h(o.value) : r.value ? await A(r.value) : o.value.length > 0 && await h(o.value, !0), r.value && _(r.value, (O, g) => {
|
|
64
|
+
if (g && g.length) {
|
|
65
|
+
const p = g.find(
|
|
66
|
+
(w) => w.value === r.value || w.info.name === r.value
|
|
66
67
|
);
|
|
67
|
-
|
|
68
|
+
p ? v.value = p.info : v.value = {
|
|
68
69
|
district: "",
|
|
69
70
|
address: "",
|
|
70
|
-
name:
|
|
71
|
+
name: r.value
|
|
71
72
|
};
|
|
72
73
|
}
|
|
73
74
|
}), a.value = new AMap.Marker({
|
|
74
|
-
position:
|
|
75
|
-
title:
|
|
76
|
-
}), t.value.add(a.value),
|
|
77
|
-
},
|
|
78
|
-
const
|
|
79
|
-
return new Promise((
|
|
75
|
+
position: o.value,
|
|
76
|
+
title: r.value
|
|
77
|
+
}), t.value.add(a.value), o.value.length && t.value.setCenter(o.value);
|
|
78
|
+
}, h = (O, g = !1) => {
|
|
79
|
+
const p = O.join(",");
|
|
80
|
+
return new Promise((w, L) => {
|
|
80
81
|
AMap.service("AMap.Geocoder", () => {
|
|
81
82
|
new AMap.Geocoder({
|
|
82
83
|
city: "全国"
|
|
83
|
-
}).getAddress(
|
|
84
|
-
var
|
|
85
|
-
if (
|
|
86
|
-
if (
|
|
87
|
-
const { province:
|
|
88
|
-
|
|
89
|
-
district:
|
|
90
|
-
address:
|
|
91
|
-
name:
|
|
84
|
+
}).getAddress(p, (f, y) => {
|
|
85
|
+
var x, m;
|
|
86
|
+
if (f === "complete" && (y != null && y.regeocode)) {
|
|
87
|
+
if (g) {
|
|
88
|
+
const { province: T = "", city: N = "", district: G = "", township: ne = "" } = y.regeocode.addressComponent;
|
|
89
|
+
r.value = y.regeocode.formattedAddress ?? "", v.value = {
|
|
90
|
+
district: T + N + G,
|
|
91
|
+
address: ne,
|
|
92
|
+
name: r.value.replace(T, "").replace(N, "").replace(G, "").replace(ne, "")
|
|
92
93
|
};
|
|
93
94
|
}
|
|
94
|
-
|
|
95
|
+
s.value = ((m = (x = y.regeocode) == null ? void 0 : x.addressComponent) == null ? void 0 : m.adcode) ?? "", w(y.regeocode);
|
|
95
96
|
} else
|
|
96
|
-
|
|
97
|
+
z.error(E("thirdPartyMapErrorRetry")), L();
|
|
97
98
|
});
|
|
98
99
|
});
|
|
99
100
|
});
|
|
100
|
-
},
|
|
101
|
+
}, A = (O) => new Promise((g, p) => {
|
|
101
102
|
AMap.service("AMap.Geocoder", () => {
|
|
102
103
|
new AMap.Geocoder({
|
|
103
104
|
city: "全国"
|
|
104
|
-
}).getLocation(
|
|
105
|
-
var
|
|
106
|
-
if (
|
|
107
|
-
const
|
|
108
|
-
|
|
105
|
+
}).getLocation(O, (L, d) => {
|
|
106
|
+
var f, y;
|
|
107
|
+
if (L === "complete" && ((f = d.geocodes) != null && f.length)) {
|
|
108
|
+
const x = d.geocodes[0].location;
|
|
109
|
+
o.value[0] = x.lng, o.value[1] = x.lat, s.value = ((y = d.geocodes[0]) == null ? void 0 : y.adcode) ?? "", g(d.geocodes[0].location);
|
|
109
110
|
} else
|
|
110
|
-
|
|
111
|
+
z.error(E("thirdPartyMapErrorRetry")), p();
|
|
111
112
|
});
|
|
112
113
|
});
|
|
113
|
-
}),
|
|
114
|
-
new AMap.CitySearch().getLocalCity((
|
|
115
|
-
if (
|
|
116
|
-
if (
|
|
117
|
-
const
|
|
118
|
-
t.value.setBounds(
|
|
114
|
+
}), B = () => {
|
|
115
|
+
new AMap.CitySearch().getLocalCity((g, p) => {
|
|
116
|
+
if (g === "complete" && p.info === "OK") {
|
|
117
|
+
if (p && p.city && p.bounds) {
|
|
118
|
+
const w = p.bounds;
|
|
119
|
+
t.value.setBounds(w);
|
|
119
120
|
}
|
|
120
121
|
} else
|
|
121
|
-
|
|
122
|
+
z.error(E("thirdPartyMapErrorRetry"));
|
|
122
123
|
});
|
|
123
|
-
},
|
|
124
|
-
if (
|
|
125
|
-
l.value = [],
|
|
124
|
+
}, _ = (O, g) => {
|
|
125
|
+
if (u.value.activated = !0, !O) {
|
|
126
|
+
l.value = [], g([]);
|
|
126
127
|
return;
|
|
127
128
|
}
|
|
128
129
|
AMap.plugin("AMap.Autocomplete", function() {
|
|
129
|
-
var
|
|
130
|
+
var p = {
|
|
130
131
|
city: "全国"
|
|
131
|
-
},
|
|
132
|
-
|
|
133
|
-
if (l.value = [], !
|
|
134
|
-
let
|
|
135
|
-
if (
|
|
136
|
-
|
|
137
|
-
const { district:
|
|
132
|
+
}, w = new AMap.Autocomplete(p);
|
|
133
|
+
w.search(O, function(L, d) {
|
|
134
|
+
if (l.value = [], !d || !d.tips) return g([]);
|
|
135
|
+
let f = d.tips;
|
|
136
|
+
if (!f || !f.length) return g([]);
|
|
137
|
+
f = f.map((y) => {
|
|
138
|
+
const { district: x = "", address: m = "", name: T = "", location: N = "" } = y;
|
|
138
139
|
return {
|
|
139
|
-
value:
|
|
140
|
-
point:
|
|
140
|
+
value: x + m + T,
|
|
141
|
+
point: N,
|
|
141
142
|
info: {
|
|
142
|
-
district:
|
|
143
|
-
address:
|
|
144
|
-
name:
|
|
143
|
+
district: x,
|
|
144
|
+
address: m,
|
|
145
|
+
name: T
|
|
145
146
|
}
|
|
146
147
|
};
|
|
147
|
-
}), l.value =
|
|
148
|
+
}), l.value = f.length > 5 ? f.slice(0, 5) : f, g(l.value, f);
|
|
148
149
|
});
|
|
149
150
|
});
|
|
150
151
|
};
|
|
151
152
|
return {
|
|
152
|
-
getLocationByInputSearch:
|
|
153
|
-
handleSelectAddress: (
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
position:
|
|
157
|
-
title:
|
|
153
|
+
getLocationByInputSearch: _,
|
|
154
|
+
handleSelectAddress: (O) => {
|
|
155
|
+
r.value = O.value, v.value = O.info, A(O.value).then((g) => {
|
|
156
|
+
o.value = [g.lng, g.lat], a.value && t.value.remove(a.value), a.value = new AMap.Marker({
|
|
157
|
+
position: o.value,
|
|
158
|
+
title: r.value
|
|
158
159
|
// 鼠标移上去时显示的内容
|
|
159
|
-
}), t.value.add(a.value), t.value.setCenter(
|
|
160
|
+
}), t.value.add(a.value), t.value.setCenter(o.value);
|
|
160
161
|
});
|
|
161
162
|
},
|
|
162
163
|
getLocationParse: async () => {
|
|
163
|
-
var
|
|
164
|
-
if (!l.value.length) return
|
|
165
|
-
if (
|
|
166
|
-
return
|
|
167
|
-
|
|
168
|
-
position:
|
|
169
|
-
title:
|
|
164
|
+
var O;
|
|
165
|
+
if (!l.value.length) return z.error(E("thirdPartyMapErrorRetry"));
|
|
166
|
+
if (r.value = l.value[0].value, !((O = l.value[0]) != null && O.point))
|
|
167
|
+
return z.error(E("thirdPartyMapErrorRetry"));
|
|
168
|
+
o.value = [l.value[0].point.lng, l.value[0].point.lat], v.value = l.value[0].info, await h(o.value), a.value = new AMap.Marker({
|
|
169
|
+
position: o.value,
|
|
170
|
+
title: r.value
|
|
170
171
|
// 鼠标移上去时显示的内容
|
|
171
|
-
}), t.value.add(a.value), t.value.setCenter(
|
|
172
|
+
}), t.value.add(a.value), t.value.setCenter(o.value), u.value.activated = !1;
|
|
172
173
|
},
|
|
173
174
|
getMapInfo: () => ({
|
|
174
|
-
longitude:
|
|
175
|
-
latitude:
|
|
176
|
-
adCode:
|
|
177
|
-
address:
|
|
178
|
-
addressInfo:
|
|
175
|
+
longitude: o.value[0],
|
|
176
|
+
latitude: o.value[1],
|
|
177
|
+
adCode: s.value,
|
|
178
|
+
address: r.value,
|
|
179
|
+
addressInfo: v.value
|
|
179
180
|
}),
|
|
180
|
-
loadJavascript:
|
|
181
|
+
loadJavascript: k
|
|
181
182
|
};
|
|
182
|
-
},
|
|
183
|
-
var
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
if ((
|
|
190
|
-
|
|
191
|
-
|
|
183
|
+
}, dt = "v1", ua = ct(`/api/tool/map/${dt}`), ia = ct(`/api/system-config/${dt}`), ca = ua.get("/regeo"), sa = ia.get("/platform/map/list"), Ge = async (e) => {
|
|
184
|
+
var r, o, s, v, b;
|
|
185
|
+
const t = ["", "baidu", "gaode", "google"];
|
|
186
|
+
let a = null, [n, u] = await sa().run();
|
|
187
|
+
if (n)
|
|
188
|
+
return [n, a];
|
|
189
|
+
const l = u.filter((C) => C.enable) || [];
|
|
190
|
+
if ((l == null ? void 0 : l.length) == 0) return [null, a];
|
|
191
|
+
if ((l == null ? void 0 : l.length) > 1) {
|
|
192
|
+
const C = l.filter((M) => t[M.serviceProvider] == e);
|
|
193
|
+
a = {
|
|
192
194
|
mapType: e,
|
|
193
|
-
akVal: (
|
|
194
|
-
secretK: (
|
|
195
|
+
akVal: (r = C[0]) == null ? void 0 : r.akValue,
|
|
196
|
+
secretK: (o = C[0]) == null ? void 0 : o.securityKey
|
|
195
197
|
};
|
|
196
|
-
} else (
|
|
197
|
-
mapType: (
|
|
198
|
-
akVal: (
|
|
199
|
-
secretK: (
|
|
198
|
+
} else (l == null ? void 0 : l.length) == 1 && (a = {
|
|
199
|
+
mapType: t[(s = l[0]) == null ? void 0 : s.serviceProvider],
|
|
200
|
+
akVal: (v = l[0]) == null ? void 0 : v.akValue,
|
|
201
|
+
secretK: (b = l[0]) == null ? void 0 : b.securityKey
|
|
200
202
|
});
|
|
201
|
-
return [null,
|
|
202
|
-
},
|
|
203
|
+
return [null, a];
|
|
204
|
+
}, da = { class: "search-input" }, fa = { id: "map" }, va = /* @__PURE__ */ Ae({
|
|
203
205
|
__name: "gaodeMap",
|
|
204
206
|
props: {
|
|
205
207
|
akValue: {},
|
|
@@ -212,76 +214,77 @@ const W = (e) => {
|
|
|
212
214
|
dev: { type: Boolean }
|
|
213
215
|
},
|
|
214
216
|
setup(e, { expose: t }) {
|
|
215
|
-
const a = e,
|
|
216
|
-
width: a.width ?
|
|
217
|
-
height: a.height ?
|
|
218
|
-
})),
|
|
217
|
+
const a = e, n = I(null), u = I(null), l = I(null), r = S(!0), o = S(null), s = S([]), v = Se(() => ({
|
|
218
|
+
width: a.width ? Q(a.width) : "100%",
|
|
219
|
+
height: a.height ? Q(a.height) : "100%"
|
|
220
|
+
})), b = S(""), C = S([]), M = S(""), k = S(), { getLocationByInputSearch: $, handleSelectAddress: c, getLocationParse: i, getMapInfo: h, loadJavascript: A } = st(
|
|
219
221
|
{
|
|
220
|
-
MapGL:
|
|
221
|
-
map:
|
|
222
|
+
MapGL: n,
|
|
223
|
+
map: u,
|
|
222
224
|
marker: l,
|
|
223
|
-
mapLoading:
|
|
224
|
-
$autocomplete:
|
|
225
|
-
searchResultList:
|
|
226
|
-
innerInput:
|
|
227
|
-
innerPoint:
|
|
228
|
-
adCode:
|
|
225
|
+
mapLoading: r,
|
|
226
|
+
$autocomplete: o,
|
|
227
|
+
searchResultList: s,
|
|
228
|
+
innerInput: b,
|
|
229
|
+
innerPoint: C,
|
|
230
|
+
adCode: M,
|
|
231
|
+
addressInfo: k
|
|
229
232
|
}
|
|
230
|
-
),
|
|
231
|
-
const
|
|
233
|
+
), B = async () => {
|
|
234
|
+
const _ = {
|
|
232
235
|
akValue: a.akValue ?? "",
|
|
233
236
|
secretKey: a.secretKey ?? ""
|
|
234
237
|
};
|
|
235
238
|
{
|
|
236
|
-
const [
|
|
237
|
-
|
|
239
|
+
const [j, R] = await Ge("gaode");
|
|
240
|
+
j && z.error(E("获取地图配置信息失败")), !j && !R && z.error(E("暂未配置地图")), R && (_.akValue || (_.akValue = R.akVal), _.secretKey || (_.secretKey = R.secretK));
|
|
238
241
|
}
|
|
239
|
-
return
|
|
242
|
+
return _;
|
|
240
243
|
};
|
|
241
|
-
return
|
|
242
|
-
a.defaultLongitude && a.defaultLatitude && (
|
|
243
|
-
const { akValue:
|
|
244
|
-
|
|
244
|
+
return Oe(async () => {
|
|
245
|
+
a.defaultLongitude && a.defaultLatitude && (C.value = [a.defaultLongitude, a.defaultLatitude]), b.value = a.defaultAddress ?? "";
|
|
246
|
+
const { akValue: _, secretKey: j } = await B();
|
|
247
|
+
A(_, j);
|
|
245
248
|
}), t({
|
|
246
249
|
/** 获取经纬度、地址、行政区划编码 */
|
|
247
|
-
getMapInfo:
|
|
248
|
-
}), (
|
|
249
|
-
const
|
|
250
|
-
return
|
|
250
|
+
getMapInfo: h
|
|
251
|
+
}), (_, j) => {
|
|
252
|
+
const R = Pe, V = ke;
|
|
253
|
+
return Te(), je(
|
|
251
254
|
"div",
|
|
252
255
|
{
|
|
253
256
|
class: "das-map",
|
|
254
|
-
style:
|
|
257
|
+
style: Le(v.value)
|
|
255
258
|
},
|
|
256
259
|
[
|
|
257
|
-
|
|
258
|
-
|
|
260
|
+
W("div", da, [
|
|
261
|
+
Z(de(R, {
|
|
259
262
|
ref_key: "$autocomplete",
|
|
260
|
-
ref:
|
|
261
|
-
modelValue:
|
|
262
|
-
"onUpdate:modelValue":
|
|
263
|
+
ref: o,
|
|
264
|
+
modelValue: b.value,
|
|
265
|
+
"onUpdate:modelValue": j[0] || (j[0] = (O) => b.value = O),
|
|
263
266
|
modelModifiers: { trim: !0 },
|
|
264
|
-
"fetch-suggestions":
|
|
265
|
-
placeholder:
|
|
267
|
+
"fetch-suggestions": D($),
|
|
268
|
+
placeholder: D(E)("请输入位置"),
|
|
266
269
|
style: { width: "100%" },
|
|
267
270
|
"trigger-on-focus": !1,
|
|
268
|
-
onSelect:
|
|
269
|
-
onKeyup:
|
|
271
|
+
onSelect: D(c),
|
|
272
|
+
onKeyup: $e(D(i), ["enter", "native"]),
|
|
270
273
|
clearable: ""
|
|
271
274
|
}, null, 8, ["modelValue", "fetch-suggestions", "placeholder", "onSelect", "onKeyup"]), [
|
|
272
|
-
[
|
|
275
|
+
[D(Re)]
|
|
273
276
|
])
|
|
274
277
|
]),
|
|
275
|
-
|
|
278
|
+
Z(W(
|
|
276
279
|
"div",
|
|
277
|
-
|
|
280
|
+
fa,
|
|
278
281
|
null,
|
|
279
282
|
512
|
|
280
283
|
/* NEED_PATCH */
|
|
281
284
|
), [
|
|
282
285
|
[
|
|
283
|
-
|
|
284
|
-
|
|
286
|
+
V,
|
|
287
|
+
r.value,
|
|
285
288
|
void 0,
|
|
286
289
|
{ lock: !0 }
|
|
287
290
|
]
|
|
@@ -292,135 +295,135 @@ const W = (e) => {
|
|
|
292
295
|
);
|
|
293
296
|
};
|
|
294
297
|
}
|
|
295
|
-
}),
|
|
298
|
+
}), Be = (e, t) => {
|
|
296
299
|
const a = e.__vccOpts || e;
|
|
297
|
-
for (const [
|
|
298
|
-
a[
|
|
300
|
+
for (const [n, u] of t)
|
|
301
|
+
a[n] = u;
|
|
299
302
|
return a;
|
|
300
|
-
},
|
|
301
|
-
const
|
|
302
|
-
let
|
|
303
|
-
const
|
|
304
|
-
|
|
305
|
-
const
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
}, document.body.append(
|
|
309
|
-
},
|
|
310
|
-
var
|
|
303
|
+
}, ga = /* @__PURE__ */ Be(va, [["__scopeId", "data-v-e88a8400"]]), ft = ({ BMap: e, map: t, marker: a, mapLoading: n, $autocomplete: u, searchResultList: l, innerInput: r, innerPoint: o, adCode: s, addressInfo: v }, b) => {
|
|
304
|
+
const C = S();
|
|
305
|
+
let M;
|
|
306
|
+
const k = (g, p, w) => {
|
|
307
|
+
C.value = p, w && (M = w);
|
|
308
|
+
const L = document.createElement("script");
|
|
309
|
+
L.src = `${location.protocol}//api.map.baidu.com/getscript?type=webgl&v=3.0&ak=${g}&services=&t=20200109192240`, L.onload = () => {
|
|
310
|
+
$();
|
|
311
|
+
}, document.body.append(L);
|
|
312
|
+
}, $ = () => {
|
|
313
|
+
var p, w;
|
|
311
314
|
e.value = window.BMapGL;
|
|
312
315
|
try {
|
|
313
|
-
t.value = new e.value.Map("map", ((
|
|
316
|
+
t.value = new e.value.Map("map", ((p = C.value) == null ? void 0 : p.mapOpt) ?? {});
|
|
314
317
|
} catch {
|
|
315
|
-
|
|
318
|
+
n.value = !1, z.error(E("thirdPartyMapErrorRetry"));
|
|
316
319
|
}
|
|
317
|
-
const
|
|
320
|
+
const g = new e.value.NavigationControl({
|
|
318
321
|
// @ts-ignore
|
|
319
322
|
anchor: BMAP_ANCHOR_BOTTOM_RIGHT,
|
|
320
323
|
// @ts-ignore
|
|
321
324
|
type: BMAP_NAVIGATION_CONTROL_ZOOM
|
|
322
325
|
});
|
|
323
|
-
t.value.addControl(
|
|
324
|
-
},
|
|
325
|
-
new e.value.Geocoder().getPoint(
|
|
326
|
-
!
|
|
326
|
+
t.value.addControl(g), t.value.enableScrollWheelZoom(!0), i(), (w = C.value) != null && w.clickStream || h(), n.value = !1, M && M();
|
|
327
|
+
}, c = (g) => new Promise((p, w) => {
|
|
328
|
+
new e.value.Geocoder().getPoint(g, (d) => {
|
|
329
|
+
!d || JSON.stringify(d) == "{}" ? (z.error(E("thirdPartyMapErrorRetry")), w()) : (o.value[0] = d.lng, o.value[1] = d.lat, p(d));
|
|
327
330
|
});
|
|
328
331
|
}), i = async () => {
|
|
329
|
-
!
|
|
330
|
-
if (
|
|
331
|
-
const
|
|
332
|
-
(
|
|
332
|
+
!r.value && !o.value.length && B(), r.value && o.value.length > 0 ? await A(o.value[0], o.value[1]) : r.value ? await c(r.value) : o.value.length > 0 && await A(o.value[0], o.value[1], !0), r.value && _(r.value, (g, p) => {
|
|
333
|
+
if (p && p.length) {
|
|
334
|
+
const w = p.find(
|
|
335
|
+
(L) => L.value === r.value || L.info.name === r.value
|
|
333
336
|
);
|
|
334
|
-
|
|
337
|
+
w ? v.value = w.info : v.value = {
|
|
335
338
|
province: "",
|
|
336
339
|
city: "",
|
|
337
340
|
address: "",
|
|
338
|
-
name:
|
|
341
|
+
name: r.value
|
|
339
342
|
};
|
|
340
343
|
}
|
|
341
344
|
});
|
|
342
|
-
},
|
|
343
|
-
t.value.addEventListener("click", (
|
|
345
|
+
}, h = () => {
|
|
346
|
+
t.value.addEventListener("click", (g) => {
|
|
344
347
|
a.value && t.value.clearOverlays();
|
|
345
|
-
const
|
|
346
|
-
|
|
348
|
+
const p = g.latlng.lng, w = g.latlng.lat;
|
|
349
|
+
o.value = [p, w], A(p, w, !0);
|
|
347
350
|
});
|
|
348
|
-
},
|
|
349
|
-
const
|
|
350
|
-
|
|
351
|
-
if (
|
|
352
|
-
|
|
353
|
-
const { province:
|
|
354
|
-
|
|
355
|
-
province:
|
|
356
|
-
city:
|
|
357
|
-
address:
|
|
358
|
-
name:
|
|
351
|
+
}, A = (g, p, w = !1, L = "default") => new Promise((d, f) => {
|
|
352
|
+
const y = new e.value.Geocoder(), x = new e.value.Point(g, p);
|
|
353
|
+
y.getLocation(x, (m) => {
|
|
354
|
+
if (w) {
|
|
355
|
+
r.value = m.address;
|
|
356
|
+
const { province: T = "", city: N = "", district: G = "" } = m.addressComponents;
|
|
357
|
+
v.value = {
|
|
358
|
+
province: T,
|
|
359
|
+
city: N,
|
|
360
|
+
address: N + G,
|
|
361
|
+
name: m.address.replace(T, "").replace(N, "").replace(G, "")
|
|
359
362
|
};
|
|
360
363
|
}
|
|
361
|
-
|
|
364
|
+
m && m.address ? (L == "default" && (o.value[0] = m.point.lng, o.value[1] = m.point.lat, a.value && t.value.clearOverlays(), a.value = new e.value.Marker(x, { title: r.value }), t.value.addOverlay(a.value), t.value.centerAndZoom(x, 16)), V(g, p), d(m.address)) : (z.error(E("thirdPartyMapErrorRetry")), f());
|
|
362
365
|
});
|
|
363
|
-
}),
|
|
364
|
-
new e.value.LocalCity().get((
|
|
365
|
-
const
|
|
366
|
-
if (!
|
|
366
|
+
}), B = () => {
|
|
367
|
+
new e.value.LocalCity().get((p) => {
|
|
368
|
+
const w = p.center;
|
|
369
|
+
if (!p.center) return z.error(E("thirdPartyMapErrorRetry"));
|
|
367
370
|
a.value && t.value.clearOverlays();
|
|
368
|
-
const
|
|
369
|
-
t.value.centerAndZoom(
|
|
371
|
+
const L = new e.value.Point(w.lng, w.lat);
|
|
372
|
+
t.value.centerAndZoom(L, 13);
|
|
370
373
|
});
|
|
371
|
-
},
|
|
372
|
-
if (
|
|
373
|
-
|
|
374
|
+
}, _ = (g, p) => {
|
|
375
|
+
if (u.value.activated = !0, l.value = [], !g) {
|
|
376
|
+
p([]);
|
|
374
377
|
return;
|
|
375
378
|
}
|
|
376
379
|
new e.value.LocalSearch(t.value, {
|
|
377
|
-
onSearchComplete: (
|
|
378
|
-
let
|
|
379
|
-
for (let
|
|
380
|
-
|
|
381
|
-
if (!
|
|
382
|
-
|
|
383
|
-
const { address:
|
|
380
|
+
onSearchComplete: (L) => {
|
|
381
|
+
let d = [];
|
|
382
|
+
for (let f = 0; f < L.getCurrentNumPois(); f++)
|
|
383
|
+
d.push(L.getPoi(f));
|
|
384
|
+
if (!d.length) return p([]);
|
|
385
|
+
d = d.map((f) => {
|
|
386
|
+
const { address: y = "", title: x = "", province: m = "", city: T = "", point: N = {} } = f;
|
|
384
387
|
return {
|
|
385
|
-
value:
|
|
386
|
-
point:
|
|
388
|
+
value: y == x ? y : y + x,
|
|
389
|
+
point: N,
|
|
387
390
|
info: {
|
|
388
|
-
province:
|
|
389
|
-
city:
|
|
390
|
-
address:
|
|
391
|
-
name:
|
|
391
|
+
province: m,
|
|
392
|
+
city: T,
|
|
393
|
+
address: y,
|
|
394
|
+
name: x
|
|
392
395
|
}
|
|
393
396
|
};
|
|
394
|
-
}), l.value =
|
|
397
|
+
}), l.value = d.length > 5 ? d.slice(0, 5) : d, p(l.value, d);
|
|
395
398
|
}
|
|
396
|
-
}).search(
|
|
397
|
-
},
|
|
398
|
-
var
|
|
399
|
-
|
|
400
|
-
},
|
|
401
|
-
var
|
|
402
|
-
if (!l.value.length) return
|
|
403
|
-
if (
|
|
404
|
-
return
|
|
405
|
-
|
|
406
|
-
},
|
|
407
|
-
const [
|
|
408
|
-
|
|
399
|
+
}).search(g);
|
|
400
|
+
}, j = (g) => {
|
|
401
|
+
var p, w;
|
|
402
|
+
r.value = g.value, v.value = g.info, A((p = g.point) == null ? void 0 : p.lng, (w = g.point) == null ? void 0 : w.lat);
|
|
403
|
+
}, R = () => {
|
|
404
|
+
var g;
|
|
405
|
+
if (!l.value.length) return z.error(E("thirdPartyMapErrorRetry"));
|
|
406
|
+
if (r.value = l.value[0].value, v.value = l.value[0].info, !((g = l.value[0]) != null && g.point))
|
|
407
|
+
return z.error(E("thirdPartyMapErrorRetry"));
|
|
408
|
+
o.value = [l.value[0].point.lng, l.value[0].point.lat], A(o.value[0], o.value[1]), u.value.activated = !1;
|
|
409
|
+
}, V = async (g, p) => {
|
|
410
|
+
const [w, L] = await ca().run({ longitude: g, latitude: p });
|
|
411
|
+
w || (s.value = L.areaCode);
|
|
409
412
|
};
|
|
410
413
|
return {
|
|
411
|
-
getLocationByInputSearch:
|
|
412
|
-
handleSelectAddress:
|
|
413
|
-
getLocationParse:
|
|
414
|
+
getLocationByInputSearch: _,
|
|
415
|
+
handleSelectAddress: j,
|
|
416
|
+
getLocationParse: R,
|
|
414
417
|
getMapInfo: () => ({
|
|
415
|
-
longitude:
|
|
416
|
-
latitude:
|
|
417
|
-
adCode:
|
|
418
|
-
address:
|
|
419
|
-
addressInfo:
|
|
418
|
+
longitude: o.value[0],
|
|
419
|
+
latitude: o.value[1],
|
|
420
|
+
adCode: s.value,
|
|
421
|
+
address: r.value,
|
|
422
|
+
addressInfo: v.value
|
|
420
423
|
}),
|
|
421
|
-
loadJavascript:
|
|
424
|
+
loadJavascript: k
|
|
422
425
|
};
|
|
423
|
-
},
|
|
426
|
+
}, pa = { class: "search-input" }, ha = { id: "map" }, ya = /* @__PURE__ */ Ae({
|
|
424
427
|
__name: "baiduMap",
|
|
425
428
|
props: {
|
|
426
429
|
akValue: {},
|
|
@@ -433,70 +436,71 @@ const W = (e) => {
|
|
|
433
436
|
dev: { type: Boolean }
|
|
434
437
|
},
|
|
435
438
|
setup(e, { expose: t }) {
|
|
436
|
-
const a = e,
|
|
437
|
-
width: a.width ?
|
|
438
|
-
height: a.height ?
|
|
439
|
-
})),
|
|
439
|
+
const a = e, n = I(null), u = I(null), l = I(null), r = S(!0), o = S(null), s = S([]), v = Se(() => ({
|
|
440
|
+
width: a.width ? Q(a.width) : "100%",
|
|
441
|
+
height: a.height ? Q(a.height) : "100%"
|
|
442
|
+
})), b = S(""), C = S([]), M = S(""), k = S(), { getLocationByInputSearch: $, handleSelectAddress: c, getLocationParse: i, getMapInfo: h, loadJavascript: A } = ft(
|
|
440
443
|
{
|
|
441
|
-
BMap:
|
|
442
|
-
map:
|
|
444
|
+
BMap: n,
|
|
445
|
+
map: u,
|
|
443
446
|
marker: l,
|
|
444
|
-
mapLoading:
|
|
445
|
-
$autocomplete:
|
|
446
|
-
searchResultList:
|
|
447
|
-
innerInput:
|
|
448
|
-
innerPoint:
|
|
449
|
-
adCode:
|
|
447
|
+
mapLoading: r,
|
|
448
|
+
$autocomplete: o,
|
|
449
|
+
searchResultList: s,
|
|
450
|
+
innerInput: b,
|
|
451
|
+
innerPoint: C,
|
|
452
|
+
adCode: M,
|
|
453
|
+
addressInfo: k
|
|
450
454
|
}
|
|
451
|
-
),
|
|
455
|
+
), B = async () => {
|
|
452
456
|
if (a.akValue) return a.akValue;
|
|
453
|
-
const [
|
|
454
|
-
return
|
|
457
|
+
const [_, j] = await Ge("baidu");
|
|
458
|
+
return _ ? (z.error(E("获取地图配置信息失败")), "") : !_ && !j ? (z.error(E("暂未配置地图")), "") : j.akVal;
|
|
455
459
|
};
|
|
456
|
-
return
|
|
457
|
-
a.defaultLongitude && a.defaultLatitude && (
|
|
458
|
-
const
|
|
459
|
-
|
|
460
|
+
return Oe(async () => {
|
|
461
|
+
a.defaultLongitude && a.defaultLatitude && (C.value = [a.defaultLongitude, a.defaultLatitude]), b.value = a.defaultAddress ?? "";
|
|
462
|
+
const _ = await B();
|
|
463
|
+
A(_);
|
|
460
464
|
}), t({
|
|
461
465
|
// 获取经纬度、地址、行政区划信息
|
|
462
|
-
getMapInfo:
|
|
463
|
-
}), (
|
|
464
|
-
const
|
|
465
|
-
return
|
|
466
|
+
getMapInfo: h
|
|
467
|
+
}), (_, j) => {
|
|
468
|
+
const R = Pe, V = ke;
|
|
469
|
+
return Te(), je(
|
|
466
470
|
"div",
|
|
467
471
|
{
|
|
468
472
|
class: "das-map",
|
|
469
|
-
style:
|
|
473
|
+
style: Le(v.value)
|
|
470
474
|
},
|
|
471
475
|
[
|
|
472
|
-
|
|
473
|
-
|
|
476
|
+
W("div", pa, [
|
|
477
|
+
Z(de(R, {
|
|
474
478
|
ref_key: "$autocomplete",
|
|
475
|
-
ref:
|
|
476
|
-
modelValue:
|
|
477
|
-
"onUpdate:modelValue":
|
|
479
|
+
ref: o,
|
|
480
|
+
modelValue: b.value,
|
|
481
|
+
"onUpdate:modelValue": j[0] || (j[0] = (O) => b.value = O),
|
|
478
482
|
modelModifiers: { trim: !0 },
|
|
479
|
-
"fetch-suggestions":
|
|
480
|
-
placeholder:
|
|
483
|
+
"fetch-suggestions": D($),
|
|
484
|
+
placeholder: D(E)("请输入位置"),
|
|
481
485
|
style: { width: "100%" },
|
|
482
486
|
"trigger-on-focus": !1,
|
|
483
|
-
onSelect:
|
|
484
|
-
onKeyup:
|
|
487
|
+
onSelect: D(c),
|
|
488
|
+
onKeyup: $e(D(i), ["enter", "native"]),
|
|
485
489
|
clearable: ""
|
|
486
490
|
}, null, 8, ["modelValue", "fetch-suggestions", "placeholder", "onSelect", "onKeyup"]), [
|
|
487
|
-
[
|
|
491
|
+
[D(Re)]
|
|
488
492
|
])
|
|
489
493
|
]),
|
|
490
|
-
|
|
494
|
+
Z(W(
|
|
491
495
|
"div",
|
|
492
|
-
|
|
496
|
+
ha,
|
|
493
497
|
null,
|
|
494
498
|
512
|
|
495
499
|
/* NEED_PATCH */
|
|
496
500
|
), [
|
|
497
501
|
[
|
|
498
|
-
|
|
499
|
-
|
|
502
|
+
V,
|
|
503
|
+
r.value,
|
|
500
504
|
void 0,
|
|
501
505
|
{ lock: !0 }
|
|
502
506
|
]
|
|
@@ -507,102 +511,102 @@ const W = (e) => {
|
|
|
507
511
|
);
|
|
508
512
|
};
|
|
509
513
|
}
|
|
510
|
-
}),
|
|
511
|
-
function
|
|
514
|
+
}), ma = /* @__PURE__ */ Be(ya, [["__scopeId", "data-v-6ea9d854"]]);
|
|
515
|
+
function ba() {
|
|
512
516
|
this.__data__ = [], this.size = 0;
|
|
513
517
|
}
|
|
514
|
-
function
|
|
518
|
+
function ge(e, t) {
|
|
515
519
|
return e === t || e !== e && t !== t;
|
|
516
520
|
}
|
|
517
|
-
function
|
|
521
|
+
function pe(e, t) {
|
|
518
522
|
for (var a = e.length; a--; )
|
|
519
|
-
if (
|
|
523
|
+
if (ge(e[a][0], t))
|
|
520
524
|
return a;
|
|
521
525
|
return -1;
|
|
522
526
|
}
|
|
523
|
-
var
|
|
524
|
-
function
|
|
525
|
-
var t = this.__data__, a =
|
|
527
|
+
var _a = Array.prototype, wa = _a.splice;
|
|
528
|
+
function Ma(e) {
|
|
529
|
+
var t = this.__data__, a = pe(t, e);
|
|
526
530
|
if (a < 0)
|
|
527
531
|
return !1;
|
|
528
|
-
var
|
|
529
|
-
return a ==
|
|
532
|
+
var n = t.length - 1;
|
|
533
|
+
return a == n ? t.pop() : wa.call(t, a, 1), --this.size, !0;
|
|
530
534
|
}
|
|
531
|
-
function
|
|
532
|
-
var t = this.__data__, a =
|
|
535
|
+
function xa(e) {
|
|
536
|
+
var t = this.__data__, a = pe(t, e);
|
|
533
537
|
return a < 0 ? void 0 : t[a][1];
|
|
534
538
|
}
|
|
535
|
-
function
|
|
536
|
-
return
|
|
539
|
+
function Ca(e) {
|
|
540
|
+
return pe(this.__data__, e) > -1;
|
|
537
541
|
}
|
|
538
|
-
function
|
|
539
|
-
var a = this.__data__,
|
|
540
|
-
return
|
|
542
|
+
function Aa(e, t) {
|
|
543
|
+
var a = this.__data__, n = pe(a, e);
|
|
544
|
+
return n < 0 ? (++this.size, a.push([e, t])) : a[n][1] = t, this;
|
|
541
545
|
}
|
|
542
|
-
function
|
|
546
|
+
function H(e) {
|
|
543
547
|
var t = -1, a = e == null ? 0 : e.length;
|
|
544
548
|
for (this.clear(); ++t < a; ) {
|
|
545
|
-
var
|
|
546
|
-
this.set(
|
|
549
|
+
var n = e[t];
|
|
550
|
+
this.set(n[0], n[1]);
|
|
547
551
|
}
|
|
548
552
|
}
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
function
|
|
555
|
-
this.__data__ = new
|
|
553
|
+
H.prototype.clear = ba;
|
|
554
|
+
H.prototype.delete = Ma;
|
|
555
|
+
H.prototype.get = xa;
|
|
556
|
+
H.prototype.has = Ca;
|
|
557
|
+
H.prototype.set = Aa;
|
|
558
|
+
function Sa() {
|
|
559
|
+
this.__data__ = new H(), this.size = 0;
|
|
556
560
|
}
|
|
557
|
-
function
|
|
561
|
+
function Oa(e) {
|
|
558
562
|
var t = this.__data__, a = t.delete(e);
|
|
559
563
|
return this.size = t.size, a;
|
|
560
564
|
}
|
|
561
|
-
function
|
|
565
|
+
function Ta(e) {
|
|
562
566
|
return this.__data__.get(e);
|
|
563
567
|
}
|
|
564
|
-
function
|
|
568
|
+
function ja(e) {
|
|
565
569
|
return this.__data__.has(e);
|
|
566
570
|
}
|
|
567
|
-
var
|
|
568
|
-
function
|
|
569
|
-
var t =
|
|
571
|
+
var vt = typeof global == "object" && global && global.Object === Object && global, La = typeof self == "object" && self && self.Object === Object && self, te = vt || La || Function("return this")(), ee = te.Symbol, gt = Object.prototype, $a = gt.hasOwnProperty, Ea = gt.toString, ue = ee ? ee.toStringTag : void 0;
|
|
572
|
+
function Pa(e) {
|
|
573
|
+
var t = $a.call(e, ue), a = e[ue];
|
|
570
574
|
try {
|
|
571
|
-
e[
|
|
572
|
-
var
|
|
575
|
+
e[ue] = void 0;
|
|
576
|
+
var n = !0;
|
|
573
577
|
} catch {
|
|
574
578
|
}
|
|
575
|
-
var
|
|
576
|
-
return
|
|
579
|
+
var u = Ea.call(e);
|
|
580
|
+
return n && (t ? e[ue] = a : delete e[ue]), u;
|
|
577
581
|
}
|
|
578
|
-
var
|
|
579
|
-
function
|
|
580
|
-
return
|
|
582
|
+
var ka = Object.prototype, Ra = ka.toString;
|
|
583
|
+
function Ga(e) {
|
|
584
|
+
return Ra.call(e);
|
|
581
585
|
}
|
|
582
|
-
var
|
|
583
|
-
function
|
|
584
|
-
return e == null ? e === void 0 ?
|
|
586
|
+
var Ba = "[object Null]", Da = "[object Undefined]", Ke = ee ? ee.toStringTag : void 0;
|
|
587
|
+
function se(e) {
|
|
588
|
+
return e == null ? e === void 0 ? Da : Ba : Ke && Ke in Object(e) ? Pa(e) : Ga(e);
|
|
585
589
|
}
|
|
586
|
-
function
|
|
590
|
+
function Y(e) {
|
|
587
591
|
var t = typeof e;
|
|
588
592
|
return e != null && (t == "object" || t == "function");
|
|
589
593
|
}
|
|
590
|
-
var
|
|
591
|
-
function
|
|
592
|
-
if (!
|
|
594
|
+
var za = "[object AsyncFunction]", Na = "[object Function]", Va = "[object GeneratorFunction]", Ua = "[object Proxy]";
|
|
595
|
+
function De(e) {
|
|
596
|
+
if (!Y(e))
|
|
593
597
|
return !1;
|
|
594
|
-
var t =
|
|
595
|
-
return t ==
|
|
598
|
+
var t = se(e);
|
|
599
|
+
return t == Na || t == Va || t == za || t == Ua;
|
|
596
600
|
}
|
|
597
|
-
var
|
|
598
|
-
var e = /[^.]+$/.exec(
|
|
601
|
+
var me = te["__core-js_shared__"], Ie = function() {
|
|
602
|
+
var e = /[^.]+$/.exec(me && me.keys && me.keys.IE_PROTO || "");
|
|
599
603
|
return e ? "Symbol(src)_1." + e : "";
|
|
600
604
|
}();
|
|
601
|
-
function
|
|
602
|
-
return !!
|
|
605
|
+
function Fa(e) {
|
|
606
|
+
return !!Ie && Ie in e;
|
|
603
607
|
}
|
|
604
|
-
var
|
|
605
|
-
function
|
|
608
|
+
var Ka = Function.prototype, Ia = Ka.toString;
|
|
609
|
+
function Ha(e) {
|
|
606
610
|
if (e != null) {
|
|
607
611
|
try {
|
|
608
612
|
return Ia.call(e);
|
|
@@ -615,335 +619,335 @@ function ka(e) {
|
|
|
615
619
|
}
|
|
616
620
|
return "";
|
|
617
621
|
}
|
|
618
|
-
var
|
|
619
|
-
"^" +
|
|
622
|
+
var Ja = /[\\^$.*+?()[\]{}|]/g, Za = /^\[object .+?Constructor\]$/, Wa = Function.prototype, qa = Object.prototype, Ya = Wa.toString, Xa = qa.hasOwnProperty, Qa = RegExp(
|
|
623
|
+
"^" + Ya.call(Xa).replace(Ja, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
|
|
620
624
|
);
|
|
621
|
-
function
|
|
622
|
-
if (!
|
|
625
|
+
function eo(e) {
|
|
626
|
+
if (!Y(e) || Fa(e))
|
|
623
627
|
return !1;
|
|
624
|
-
var t =
|
|
625
|
-
return t.test(
|
|
628
|
+
var t = De(e) ? Qa : Za;
|
|
629
|
+
return t.test(Ha(e));
|
|
626
630
|
}
|
|
627
|
-
function
|
|
631
|
+
function to(e, t) {
|
|
628
632
|
return e == null ? void 0 : e[t];
|
|
629
633
|
}
|
|
630
|
-
function
|
|
631
|
-
var a =
|
|
632
|
-
return
|
|
634
|
+
function ze(e, t) {
|
|
635
|
+
var a = to(e, t);
|
|
636
|
+
return eo(a) ? a : void 0;
|
|
633
637
|
}
|
|
634
|
-
var
|
|
635
|
-
function
|
|
636
|
-
this.__data__ =
|
|
638
|
+
var pt = ze(te, "Map"), ce = ze(Object, "create");
|
|
639
|
+
function ao() {
|
|
640
|
+
this.__data__ = ce ? ce(null) : {}, this.size = 0;
|
|
637
641
|
}
|
|
638
|
-
function
|
|
642
|
+
function oo(e) {
|
|
639
643
|
var t = this.has(e) && delete this.__data__[e];
|
|
640
644
|
return this.size -= t ? 1 : 0, t;
|
|
641
645
|
}
|
|
642
|
-
var
|
|
643
|
-
function
|
|
646
|
+
var ro = "__lodash_hash_undefined__", no = Object.prototype, lo = no.hasOwnProperty;
|
|
647
|
+
function uo(e) {
|
|
644
648
|
var t = this.__data__;
|
|
645
|
-
if (
|
|
649
|
+
if (ce) {
|
|
646
650
|
var a = t[e];
|
|
647
|
-
return a ===
|
|
651
|
+
return a === ro ? void 0 : a;
|
|
648
652
|
}
|
|
649
|
-
return
|
|
653
|
+
return lo.call(t, e) ? t[e] : void 0;
|
|
650
654
|
}
|
|
651
|
-
var
|
|
652
|
-
function
|
|
655
|
+
var io = Object.prototype, co = io.hasOwnProperty;
|
|
656
|
+
function so(e) {
|
|
653
657
|
var t = this.__data__;
|
|
654
|
-
return
|
|
658
|
+
return ce ? t[e] !== void 0 : co.call(t, e);
|
|
655
659
|
}
|
|
656
|
-
var
|
|
657
|
-
function
|
|
660
|
+
var fo = "__lodash_hash_undefined__";
|
|
661
|
+
function vo(e, t) {
|
|
658
662
|
var a = this.__data__;
|
|
659
|
-
return this.size += this.has(e) ? 0 : 1, a[e] =
|
|
663
|
+
return this.size += this.has(e) ? 0 : 1, a[e] = ce && t === void 0 ? fo : t, this;
|
|
660
664
|
}
|
|
661
|
-
function
|
|
665
|
+
function q(e) {
|
|
662
666
|
var t = -1, a = e == null ? 0 : e.length;
|
|
663
667
|
for (this.clear(); ++t < a; ) {
|
|
664
|
-
var
|
|
665
|
-
this.set(
|
|
668
|
+
var n = e[t];
|
|
669
|
+
this.set(n[0], n[1]);
|
|
666
670
|
}
|
|
667
671
|
}
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
function
|
|
672
|
+
q.prototype.clear = ao;
|
|
673
|
+
q.prototype.delete = oo;
|
|
674
|
+
q.prototype.get = uo;
|
|
675
|
+
q.prototype.has = so;
|
|
676
|
+
q.prototype.set = vo;
|
|
677
|
+
function go() {
|
|
674
678
|
this.size = 0, this.__data__ = {
|
|
675
|
-
hash: new
|
|
676
|
-
map: new (
|
|
677
|
-
string: new
|
|
679
|
+
hash: new q(),
|
|
680
|
+
map: new (pt || H)(),
|
|
681
|
+
string: new q()
|
|
678
682
|
};
|
|
679
683
|
}
|
|
680
|
-
function
|
|
684
|
+
function po(e) {
|
|
681
685
|
var t = typeof e;
|
|
682
686
|
return t == "string" || t == "number" || t == "symbol" || t == "boolean" ? e !== "__proto__" : e === null;
|
|
683
687
|
}
|
|
684
|
-
function
|
|
688
|
+
function he(e, t) {
|
|
685
689
|
var a = e.__data__;
|
|
686
|
-
return
|
|
690
|
+
return po(t) ? a[typeof t == "string" ? "string" : "hash"] : a.map;
|
|
687
691
|
}
|
|
688
|
-
function
|
|
689
|
-
var t =
|
|
692
|
+
function ho(e) {
|
|
693
|
+
var t = he(this, e).delete(e);
|
|
690
694
|
return this.size -= t ? 1 : 0, t;
|
|
691
695
|
}
|
|
692
|
-
function
|
|
693
|
-
return
|
|
696
|
+
function yo(e) {
|
|
697
|
+
return he(this, e).get(e);
|
|
694
698
|
}
|
|
695
|
-
function
|
|
696
|
-
return
|
|
699
|
+
function mo(e) {
|
|
700
|
+
return he(this, e).has(e);
|
|
697
701
|
}
|
|
698
|
-
function
|
|
699
|
-
var a =
|
|
700
|
-
return a.set(e, t), this.size += a.size ==
|
|
702
|
+
function bo(e, t) {
|
|
703
|
+
var a = he(this, e), n = a.size;
|
|
704
|
+
return a.set(e, t), this.size += a.size == n ? 0 : 1, this;
|
|
701
705
|
}
|
|
702
|
-
function
|
|
706
|
+
function ae(e) {
|
|
703
707
|
var t = -1, a = e == null ? 0 : e.length;
|
|
704
708
|
for (this.clear(); ++t < a; ) {
|
|
705
|
-
var
|
|
706
|
-
this.set(
|
|
709
|
+
var n = e[t];
|
|
710
|
+
this.set(n[0], n[1]);
|
|
707
711
|
}
|
|
708
712
|
}
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
var
|
|
715
|
-
function
|
|
713
|
+
ae.prototype.clear = go;
|
|
714
|
+
ae.prototype.delete = ho;
|
|
715
|
+
ae.prototype.get = yo;
|
|
716
|
+
ae.prototype.has = mo;
|
|
717
|
+
ae.prototype.set = bo;
|
|
718
|
+
var _o = 200;
|
|
719
|
+
function wo(e, t) {
|
|
716
720
|
var a = this.__data__;
|
|
717
|
-
if (a instanceof
|
|
718
|
-
var
|
|
719
|
-
if (!
|
|
720
|
-
return
|
|
721
|
-
a = this.__data__ = new
|
|
721
|
+
if (a instanceof H) {
|
|
722
|
+
var n = a.__data__;
|
|
723
|
+
if (!pt || n.length < _o - 1)
|
|
724
|
+
return n.push([e, t]), this.size = ++a.size, this;
|
|
725
|
+
a = this.__data__ = new ae(n);
|
|
722
726
|
}
|
|
723
727
|
return a.set(e, t), this.size = a.size, this;
|
|
724
728
|
}
|
|
725
|
-
function
|
|
726
|
-
var t = this.__data__ = new
|
|
729
|
+
function oe(e) {
|
|
730
|
+
var t = this.__data__ = new H(e);
|
|
727
731
|
this.size = t.size;
|
|
728
732
|
}
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
var
|
|
733
|
+
oe.prototype.clear = Sa;
|
|
734
|
+
oe.prototype.delete = Oa;
|
|
735
|
+
oe.prototype.get = Ta;
|
|
736
|
+
oe.prototype.has = ja;
|
|
737
|
+
oe.prototype.set = wo;
|
|
738
|
+
var fe = function() {
|
|
735
739
|
try {
|
|
736
|
-
var e =
|
|
740
|
+
var e = ze(Object, "defineProperty");
|
|
737
741
|
return e({}, "", {}), e;
|
|
738
742
|
} catch {
|
|
739
743
|
}
|
|
740
744
|
}();
|
|
741
|
-
function
|
|
742
|
-
t == "__proto__" &&
|
|
745
|
+
function Ne(e, t, a) {
|
|
746
|
+
t == "__proto__" && fe ? fe(e, t, {
|
|
743
747
|
configurable: !0,
|
|
744
748
|
enumerable: !0,
|
|
745
749
|
value: a,
|
|
746
750
|
writable: !0
|
|
747
751
|
}) : e[t] = a;
|
|
748
752
|
}
|
|
749
|
-
function
|
|
750
|
-
(a !== void 0 && !
|
|
753
|
+
function _e(e, t, a) {
|
|
754
|
+
(a !== void 0 && !ge(e[t], a) || a === void 0 && !(t in e)) && Ne(e, t, a);
|
|
751
755
|
}
|
|
752
|
-
function
|
|
753
|
-
return function(t, a,
|
|
754
|
-
for (var
|
|
755
|
-
var
|
|
756
|
-
if (a(l[
|
|
756
|
+
function Mo(e) {
|
|
757
|
+
return function(t, a, n) {
|
|
758
|
+
for (var u = -1, l = Object(t), r = n(t), o = r.length; o--; ) {
|
|
759
|
+
var s = r[++u];
|
|
760
|
+
if (a(l[s], s, l) === !1)
|
|
757
761
|
break;
|
|
758
762
|
}
|
|
759
763
|
return t;
|
|
760
764
|
};
|
|
761
765
|
}
|
|
762
|
-
var
|
|
763
|
-
|
|
764
|
-
function
|
|
766
|
+
var xo = Mo(), ht = typeof exports == "object" && exports && !exports.nodeType && exports, He = ht && typeof module == "object" && module && !module.nodeType && module, Co = He && He.exports === ht, Je = Co ? te.Buffer : void 0;
|
|
767
|
+
Je && Je.allocUnsafe;
|
|
768
|
+
function Ao(e, t) {
|
|
765
769
|
return e.slice();
|
|
766
770
|
}
|
|
767
|
-
var
|
|
768
|
-
function
|
|
771
|
+
var Ze = te.Uint8Array;
|
|
772
|
+
function So(e) {
|
|
769
773
|
var t = new e.constructor(e.byteLength);
|
|
770
|
-
return new
|
|
774
|
+
return new Ze(t).set(new Ze(e)), t;
|
|
771
775
|
}
|
|
772
|
-
function
|
|
773
|
-
var a =
|
|
776
|
+
function Oo(e, t) {
|
|
777
|
+
var a = So(e.buffer);
|
|
774
778
|
return new e.constructor(a, e.byteOffset, e.length);
|
|
775
779
|
}
|
|
776
|
-
function
|
|
777
|
-
var a = -1,
|
|
778
|
-
for (t || (t = Array(
|
|
780
|
+
function To(e, t) {
|
|
781
|
+
var a = -1, n = e.length;
|
|
782
|
+
for (t || (t = Array(n)); ++a < n; )
|
|
779
783
|
t[a] = e[a];
|
|
780
784
|
return t;
|
|
781
785
|
}
|
|
782
|
-
var
|
|
786
|
+
var We = Object.create, jo = /* @__PURE__ */ function() {
|
|
783
787
|
function e() {
|
|
784
788
|
}
|
|
785
789
|
return function(t) {
|
|
786
|
-
if (!
|
|
790
|
+
if (!Y(t))
|
|
787
791
|
return {};
|
|
788
|
-
if (
|
|
789
|
-
return
|
|
792
|
+
if (We)
|
|
793
|
+
return We(t);
|
|
790
794
|
e.prototype = t;
|
|
791
795
|
var a = new e();
|
|
792
796
|
return e.prototype = void 0, a;
|
|
793
797
|
};
|
|
794
798
|
}();
|
|
795
|
-
function
|
|
799
|
+
function Lo(e, t) {
|
|
796
800
|
return function(a) {
|
|
797
801
|
return e(t(a));
|
|
798
802
|
};
|
|
799
803
|
}
|
|
800
|
-
var
|
|
801
|
-
function
|
|
802
|
-
var t = e && e.constructor, a = typeof t == "function" && t.prototype ||
|
|
804
|
+
var yt = Lo(Object.getPrototypeOf, Object), $o = Object.prototype;
|
|
805
|
+
function mt(e) {
|
|
806
|
+
var t = e && e.constructor, a = typeof t == "function" && t.prototype || $o;
|
|
803
807
|
return e === a;
|
|
804
808
|
}
|
|
805
|
-
function
|
|
806
|
-
return typeof e.constructor == "function" && !
|
|
809
|
+
function Eo(e) {
|
|
810
|
+
return typeof e.constructor == "function" && !mt(e) ? jo(yt(e)) : {};
|
|
807
811
|
}
|
|
808
|
-
function
|
|
812
|
+
function re(e) {
|
|
809
813
|
return e != null && typeof e == "object";
|
|
810
814
|
}
|
|
811
|
-
var
|
|
812
|
-
function
|
|
813
|
-
return
|
|
815
|
+
var Po = "[object Arguments]";
|
|
816
|
+
function qe(e) {
|
|
817
|
+
return re(e) && se(e) == Po;
|
|
814
818
|
}
|
|
815
|
-
var
|
|
819
|
+
var bt = Object.prototype, ko = bt.hasOwnProperty, Ro = bt.propertyIsEnumerable, we = qe(/* @__PURE__ */ function() {
|
|
816
820
|
return arguments;
|
|
817
|
-
}()) ?
|
|
818
|
-
return
|
|
819
|
-
},
|
|
820
|
-
function
|
|
821
|
-
return typeof e == "number" && e > -1 && e % 1 == 0 && e <=
|
|
821
|
+
}()) ? qe : function(e) {
|
|
822
|
+
return re(e) && ko.call(e, "callee") && !Ro.call(e, "callee");
|
|
823
|
+
}, ve = Array.isArray, Go = 9007199254740991;
|
|
824
|
+
function _t(e) {
|
|
825
|
+
return typeof e == "number" && e > -1 && e % 1 == 0 && e <= Go;
|
|
822
826
|
}
|
|
823
|
-
function
|
|
824
|
-
return e != null &&
|
|
827
|
+
function Ve(e) {
|
|
828
|
+
return e != null && _t(e.length) && !De(e);
|
|
825
829
|
}
|
|
826
|
-
function
|
|
827
|
-
return
|
|
830
|
+
function Bo(e) {
|
|
831
|
+
return re(e) && Ve(e);
|
|
828
832
|
}
|
|
829
|
-
function
|
|
833
|
+
function Do() {
|
|
830
834
|
return !1;
|
|
831
835
|
}
|
|
832
|
-
var
|
|
833
|
-
function
|
|
834
|
-
if (!
|
|
836
|
+
var wt = typeof exports == "object" && exports && !exports.nodeType && exports, Ye = wt && typeof module == "object" && module && !module.nodeType && module, zo = Ye && Ye.exports === wt, Xe = zo ? te.Buffer : void 0, No = Xe ? Xe.isBuffer : void 0, Mt = No || Do, Vo = "[object Object]", Uo = Function.prototype, Fo = Object.prototype, xt = Uo.toString, Ko = Fo.hasOwnProperty, Io = xt.call(Object);
|
|
837
|
+
function Ho(e) {
|
|
838
|
+
if (!re(e) || se(e) != Vo)
|
|
835
839
|
return !1;
|
|
836
|
-
var t =
|
|
840
|
+
var t = yt(e);
|
|
837
841
|
if (t === null)
|
|
838
842
|
return !0;
|
|
839
|
-
var a =
|
|
840
|
-
return typeof a == "function" && a instanceof a &&
|
|
843
|
+
var a = Ko.call(t, "constructor") && t.constructor;
|
|
844
|
+
return typeof a == "function" && a instanceof a && xt.call(a) == Io;
|
|
841
845
|
}
|
|
842
|
-
var
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
function
|
|
846
|
-
return
|
|
846
|
+
var Jo = "[object Arguments]", Zo = "[object Array]", Wo = "[object Boolean]", qo = "[object Date]", Yo = "[object Error]", Xo = "[object Function]", Qo = "[object Map]", er = "[object Number]", tr = "[object Object]", ar = "[object RegExp]", or = "[object Set]", rr = "[object String]", nr = "[object WeakMap]", lr = "[object ArrayBuffer]", ur = "[object DataView]", ir = "[object Float32Array]", cr = "[object Float64Array]", sr = "[object Int8Array]", dr = "[object Int16Array]", fr = "[object Int32Array]", vr = "[object Uint8Array]", gr = "[object Uint8ClampedArray]", pr = "[object Uint16Array]", hr = "[object Uint32Array]", P = {};
|
|
847
|
+
P[ir] = P[cr] = P[sr] = P[dr] = P[fr] = P[vr] = P[gr] = P[pr] = P[hr] = !0;
|
|
848
|
+
P[Jo] = P[Zo] = P[lr] = P[Wo] = P[ur] = P[qo] = P[Yo] = P[Xo] = P[Qo] = P[er] = P[tr] = P[ar] = P[or] = P[rr] = P[nr] = !1;
|
|
849
|
+
function yr(e) {
|
|
850
|
+
return re(e) && _t(e.length) && !!P[se(e)];
|
|
847
851
|
}
|
|
848
|
-
function
|
|
852
|
+
function mr(e) {
|
|
849
853
|
return function(t) {
|
|
850
854
|
return e(t);
|
|
851
855
|
};
|
|
852
856
|
}
|
|
853
|
-
var
|
|
857
|
+
var Ct = typeof exports == "object" && exports && !exports.nodeType && exports, ie = Ct && typeof module == "object" && module && !module.nodeType && module, br = ie && ie.exports === Ct, be = br && vt.process, Qe = function() {
|
|
854
858
|
try {
|
|
855
|
-
var e =
|
|
856
|
-
return e ||
|
|
859
|
+
var e = ie && ie.require && ie.require("util").types;
|
|
860
|
+
return e || be && be.binding && be.binding("util");
|
|
857
861
|
} catch {
|
|
858
862
|
}
|
|
859
|
-
}(),
|
|
860
|
-
function
|
|
863
|
+
}(), et = Qe && Qe.isTypedArray, At = et ? mr(et) : yr;
|
|
864
|
+
function Me(e, t) {
|
|
861
865
|
if (!(t === "constructor" && typeof e[t] == "function") && t != "__proto__")
|
|
862
866
|
return e[t];
|
|
863
867
|
}
|
|
864
|
-
var
|
|
865
|
-
function
|
|
866
|
-
var
|
|
867
|
-
(!(
|
|
868
|
+
var _r = Object.prototype, wr = _r.hasOwnProperty;
|
|
869
|
+
function Mr(e, t, a) {
|
|
870
|
+
var n = e[t];
|
|
871
|
+
(!(wr.call(e, t) && ge(n, a)) || a === void 0 && !(t in e)) && Ne(e, t, a);
|
|
868
872
|
}
|
|
869
|
-
function
|
|
870
|
-
var
|
|
873
|
+
function xr(e, t, a, n) {
|
|
874
|
+
var u = !a;
|
|
871
875
|
a || (a = {});
|
|
872
|
-
for (var l = -1,
|
|
873
|
-
var
|
|
874
|
-
|
|
876
|
+
for (var l = -1, r = t.length; ++l < r; ) {
|
|
877
|
+
var o = t[l], s = void 0;
|
|
878
|
+
s === void 0 && (s = e[o]), u ? Ne(a, o, s) : Mr(a, o, s);
|
|
875
879
|
}
|
|
876
880
|
return a;
|
|
877
881
|
}
|
|
878
|
-
function
|
|
879
|
-
for (var a = -1,
|
|
880
|
-
|
|
881
|
-
return
|
|
882
|
+
function Cr(e, t) {
|
|
883
|
+
for (var a = -1, n = Array(e); ++a < e; )
|
|
884
|
+
n[a] = t(a);
|
|
885
|
+
return n;
|
|
882
886
|
}
|
|
883
|
-
var
|
|
884
|
-
function
|
|
887
|
+
var Ar = 9007199254740991, Sr = /^(?:0|[1-9]\d*)$/;
|
|
888
|
+
function St(e, t) {
|
|
885
889
|
var a = typeof e;
|
|
886
|
-
return t = t ??
|
|
887
|
-
}
|
|
888
|
-
function
|
|
889
|
-
var a =
|
|
890
|
-
for (var
|
|
891
|
-
|
|
892
|
-
(
|
|
893
|
-
|
|
894
|
-
l && (
|
|
895
|
-
|
|
896
|
-
return
|
|
890
|
+
return t = t ?? Ar, !!t && (a == "number" || a != "symbol" && Sr.test(e)) && e > -1 && e % 1 == 0 && e < t;
|
|
891
|
+
}
|
|
892
|
+
function Or(e, t) {
|
|
893
|
+
var a = ve(e), n = !a && we(e), u = !a && !n && Mt(e), l = !a && !n && !u && At(e), r = a || n || u || l, o = r ? Cr(e.length, String) : [], s = o.length;
|
|
894
|
+
for (var v in e)
|
|
895
|
+
r && // Safari 9 has enumerable `arguments.length` in strict mode.
|
|
896
|
+
(v == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
|
|
897
|
+
u && (v == "offset" || v == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
|
|
898
|
+
l && (v == "buffer" || v == "byteLength" || v == "byteOffset") || // Skip index properties.
|
|
899
|
+
St(v, s)) || o.push(v);
|
|
900
|
+
return o;
|
|
897
901
|
}
|
|
898
|
-
function
|
|
902
|
+
function Tr(e) {
|
|
899
903
|
var t = [];
|
|
900
904
|
if (e != null)
|
|
901
905
|
for (var a in Object(e))
|
|
902
906
|
t.push(a);
|
|
903
907
|
return t;
|
|
904
908
|
}
|
|
905
|
-
var
|
|
906
|
-
function
|
|
907
|
-
if (!
|
|
908
|
-
return
|
|
909
|
-
var t =
|
|
910
|
-
for (var
|
|
911
|
-
|
|
909
|
+
var jr = Object.prototype, Lr = jr.hasOwnProperty;
|
|
910
|
+
function $r(e) {
|
|
911
|
+
if (!Y(e))
|
|
912
|
+
return Tr(e);
|
|
913
|
+
var t = mt(e), a = [];
|
|
914
|
+
for (var n in e)
|
|
915
|
+
n == "constructor" && (t || !Lr.call(e, n)) || a.push(n);
|
|
912
916
|
return a;
|
|
913
917
|
}
|
|
914
|
-
function
|
|
915
|
-
return
|
|
918
|
+
function Ot(e) {
|
|
919
|
+
return Ve(e) ? Or(e) : $r(e);
|
|
916
920
|
}
|
|
917
|
-
function
|
|
918
|
-
return
|
|
921
|
+
function Er(e) {
|
|
922
|
+
return xr(e, Ot(e));
|
|
919
923
|
}
|
|
920
|
-
function
|
|
921
|
-
var
|
|
922
|
-
if (
|
|
923
|
-
|
|
924
|
+
function Pr(e, t, a, n, u, l, r) {
|
|
925
|
+
var o = Me(e, a), s = Me(t, a), v = r.get(s);
|
|
926
|
+
if (v) {
|
|
927
|
+
_e(e, a, v);
|
|
924
928
|
return;
|
|
925
929
|
}
|
|
926
|
-
var
|
|
927
|
-
if (
|
|
928
|
-
var
|
|
929
|
-
|
|
930
|
+
var b = l ? l(o, s, a + "", e, t, r) : void 0, C = b === void 0;
|
|
931
|
+
if (C) {
|
|
932
|
+
var M = ve(s), k = !M && Mt(s), $ = !M && !k && At(s);
|
|
933
|
+
b = s, M || k || $ ? ve(o) ? b = o : Bo(o) ? b = To(o) : k ? (C = !1, b = Ao(s)) : $ ? (C = !1, b = Oo(s)) : b = [] : Ho(s) || we(s) ? (b = o, we(o) ? b = Er(o) : (!Y(o) || De(o)) && (b = Eo(s))) : C = !1;
|
|
930
934
|
}
|
|
931
|
-
|
|
935
|
+
C && (r.set(s, b), u(b, s, n, l, r), r.delete(s)), _e(e, a, b);
|
|
932
936
|
}
|
|
933
|
-
function
|
|
934
|
-
e !== t &&
|
|
935
|
-
if (
|
|
936
|
-
|
|
937
|
+
function Tt(e, t, a, n, u) {
|
|
938
|
+
e !== t && xo(t, function(l, r) {
|
|
939
|
+
if (u || (u = new oe()), Y(l))
|
|
940
|
+
Pr(e, t, r, a, Tt, n, u);
|
|
937
941
|
else {
|
|
938
|
-
var
|
|
939
|
-
|
|
942
|
+
var o = n ? n(Me(e, r), l, r + "", e, t, u) : void 0;
|
|
943
|
+
o === void 0 && (o = l), _e(e, r, o);
|
|
940
944
|
}
|
|
941
|
-
},
|
|
945
|
+
}, Ot);
|
|
942
946
|
}
|
|
943
|
-
function
|
|
947
|
+
function jt(e) {
|
|
944
948
|
return e;
|
|
945
949
|
}
|
|
946
|
-
function
|
|
950
|
+
function kr(e, t, a) {
|
|
947
951
|
switch (a.length) {
|
|
948
952
|
case 0:
|
|
949
953
|
return e.call(t);
|
|
@@ -956,241 +960,251 @@ function An(e, t, a) {
|
|
|
956
960
|
}
|
|
957
961
|
return e.apply(t, a);
|
|
958
962
|
}
|
|
959
|
-
var
|
|
960
|
-
function
|
|
961
|
-
return t =
|
|
962
|
-
for (var
|
|
963
|
-
u
|
|
964
|
-
|
|
965
|
-
for (var
|
|
966
|
-
|
|
967
|
-
return
|
|
963
|
+
var tt = Math.max;
|
|
964
|
+
function Rr(e, t, a) {
|
|
965
|
+
return t = tt(t === void 0 ? e.length - 1 : t, 0), function() {
|
|
966
|
+
for (var n = arguments, u = -1, l = tt(n.length - t, 0), r = Array(l); ++u < l; )
|
|
967
|
+
r[u] = n[t + u];
|
|
968
|
+
u = -1;
|
|
969
|
+
for (var o = Array(t + 1); ++u < t; )
|
|
970
|
+
o[u] = n[u];
|
|
971
|
+
return o[t] = a(r), kr(e, this, o);
|
|
968
972
|
};
|
|
969
973
|
}
|
|
970
|
-
function
|
|
974
|
+
function Gr(e) {
|
|
971
975
|
return function() {
|
|
972
976
|
return e;
|
|
973
977
|
};
|
|
974
978
|
}
|
|
975
|
-
var
|
|
976
|
-
return
|
|
979
|
+
var Br = fe ? function(e, t) {
|
|
980
|
+
return fe(e, "toString", {
|
|
977
981
|
configurable: !0,
|
|
978
982
|
enumerable: !1,
|
|
979
|
-
value:
|
|
983
|
+
value: Gr(t),
|
|
980
984
|
writable: !0
|
|
981
985
|
});
|
|
982
|
-
} :
|
|
983
|
-
function
|
|
986
|
+
} : jt, Dr = 800, zr = 16, Nr = Date.now;
|
|
987
|
+
function Vr(e) {
|
|
984
988
|
var t = 0, a = 0;
|
|
985
989
|
return function() {
|
|
986
|
-
var
|
|
987
|
-
if (a =
|
|
988
|
-
if (++t >=
|
|
990
|
+
var n = Nr(), u = zr - (n - a);
|
|
991
|
+
if (a = n, u > 0) {
|
|
992
|
+
if (++t >= Dr)
|
|
989
993
|
return arguments[0];
|
|
990
994
|
} else
|
|
991
995
|
t = 0;
|
|
992
996
|
return e.apply(void 0, arguments);
|
|
993
997
|
};
|
|
994
998
|
}
|
|
995
|
-
var
|
|
996
|
-
function
|
|
997
|
-
return
|
|
999
|
+
var Ur = Vr(Br);
|
|
1000
|
+
function Fr(e, t) {
|
|
1001
|
+
return Ur(Rr(e, t, jt), e + "");
|
|
998
1002
|
}
|
|
999
|
-
function
|
|
1000
|
-
if (!
|
|
1003
|
+
function Kr(e, t, a) {
|
|
1004
|
+
if (!Y(a))
|
|
1001
1005
|
return !1;
|
|
1002
|
-
var
|
|
1003
|
-
return (
|
|
1004
|
-
}
|
|
1005
|
-
function
|
|
1006
|
-
return
|
|
1007
|
-
var
|
|
1008
|
-
for (l = e.length > 3 && typeof l == "function" ? (
|
|
1009
|
-
var
|
|
1010
|
-
|
|
1006
|
+
var n = typeof t;
|
|
1007
|
+
return (n == "number" ? Ve(a) && St(t, a.length) : n == "string" && t in a) ? ge(a[t], e) : !1;
|
|
1008
|
+
}
|
|
1009
|
+
function Ir(e) {
|
|
1010
|
+
return Fr(function(t, a) {
|
|
1011
|
+
var n = -1, u = a.length, l = u > 1 ? a[u - 1] : void 0, r = u > 2 ? a[2] : void 0;
|
|
1012
|
+
for (l = e.length > 3 && typeof l == "function" ? (u--, l) : void 0, r && Kr(a[0], a[1], r) && (l = u < 3 ? void 0 : l, u = 1), t = Object(t); ++n < u; ) {
|
|
1013
|
+
var o = a[n];
|
|
1014
|
+
o && e(t, o, n, l);
|
|
1011
1015
|
}
|
|
1012
1016
|
return t;
|
|
1013
1017
|
});
|
|
1014
1018
|
}
|
|
1015
|
-
var
|
|
1016
|
-
|
|
1017
|
-
}),
|
|
1018
|
-
function
|
|
1019
|
+
var Hr = Ir(function(e, t, a, n) {
|
|
1020
|
+
Tt(e, t, a, n);
|
|
1021
|
+
}), Jr = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
1022
|
+
function Zr(e) {
|
|
1019
1023
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
1020
1024
|
}
|
|
1021
|
-
var
|
|
1025
|
+
var Lt = { exports: {} };
|
|
1022
1026
|
(function(e) {
|
|
1023
1027
|
(function(t, a) {
|
|
1024
1028
|
e.exports ? e.exports = a() : t.coordtransform = a();
|
|
1025
|
-
})(
|
|
1026
|
-
var t = 52.35987755982988, a = 3.141592653589793,
|
|
1027
|
-
var
|
|
1028
|
-
return [
|
|
1029
|
-
},
|
|
1030
|
-
var
|
|
1031
|
-
return [
|
|
1032
|
-
},
|
|
1033
|
-
var
|
|
1034
|
-
if (
|
|
1035
|
-
return [i,
|
|
1036
|
-
var
|
|
1037
|
-
|
|
1038
|
-
var
|
|
1039
|
-
|
|
1040
|
-
var
|
|
1041
|
-
return [
|
|
1042
|
-
},
|
|
1043
|
-
var
|
|
1044
|
-
if (
|
|
1045
|
-
return [i,
|
|
1046
|
-
var
|
|
1047
|
-
|
|
1048
|
-
var
|
|
1049
|
-
|
|
1050
|
-
var
|
|
1051
|
-
return [i * 2 -
|
|
1052
|
-
},
|
|
1053
|
-
var
|
|
1054
|
-
return
|
|
1055
|
-
},
|
|
1056
|
-
var
|
|
1057
|
-
return
|
|
1058
|
-
},
|
|
1059
|
-
var
|
|
1060
|
-
return !(i > 73.66 && i < 135.05 &&
|
|
1029
|
+
})(Jr, function() {
|
|
1030
|
+
var t = 52.35987755982988, a = 3.141592653589793, n = 6378245, u = 0.006693421622965943, l = function(c, i) {
|
|
1031
|
+
var c = +c, i = +i, h = c - 65e-4, A = i - 6e-3, B = Math.sqrt(h * h + A * A) - 2e-5 * Math.sin(A * t), _ = Math.atan2(A, h) - 3e-6 * Math.cos(h * t), j = B * Math.cos(_), R = B * Math.sin(_);
|
|
1032
|
+
return [j, R];
|
|
1033
|
+
}, r = function(i, c) {
|
|
1034
|
+
var c = +c, i = +i, h = Math.sqrt(i * i + c * c) + 2e-5 * Math.sin(c * t), A = Math.atan2(c, i) + 3e-6 * Math.cos(i * t), B = h * Math.cos(A) + 65e-4, _ = h * Math.sin(A) + 6e-3;
|
|
1035
|
+
return [B, _];
|
|
1036
|
+
}, o = function(i, c) {
|
|
1037
|
+
var c = +c, i = +i;
|
|
1038
|
+
if (C(i, c))
|
|
1039
|
+
return [i, c];
|
|
1040
|
+
var h = v(i - 105, c - 35), A = b(i - 105, c - 35), B = c / 180 * a, _ = Math.sin(B);
|
|
1041
|
+
_ = 1 - u * _ * _;
|
|
1042
|
+
var j = Math.sqrt(_);
|
|
1043
|
+
h = h * 180 / (n * (1 - u) / (_ * j) * a), A = A * 180 / (n / j * Math.cos(B) * a);
|
|
1044
|
+
var R = c + h, V = i + A;
|
|
1045
|
+
return [V, R];
|
|
1046
|
+
}, s = function(i, c) {
|
|
1047
|
+
var c = +c, i = +i;
|
|
1048
|
+
if (C(i, c))
|
|
1049
|
+
return [i, c];
|
|
1050
|
+
var h = v(i - 105, c - 35), A = b(i - 105, c - 35), B = c / 180 * a, _ = Math.sin(B);
|
|
1051
|
+
_ = 1 - u * _ * _;
|
|
1052
|
+
var j = Math.sqrt(_);
|
|
1053
|
+
h = h * 180 / (n * (1 - u) / (_ * j) * a), A = A * 180 / (n / j * Math.cos(B) * a);
|
|
1054
|
+
var R = c + h, V = i + A;
|
|
1055
|
+
return [i * 2 - V, c * 2 - R];
|
|
1056
|
+
}, v = function(i, c) {
|
|
1057
|
+
var c = +c, i = +i, h = -100 + 2 * i + 3 * c + 0.2 * c * c + 0.1 * i * c + 0.2 * Math.sqrt(Math.abs(i));
|
|
1058
|
+
return h += (20 * Math.sin(6 * i * a) + 20 * Math.sin(2 * i * a)) * 2 / 3, h += (20 * Math.sin(c * a) + 40 * Math.sin(c / 3 * a)) * 2 / 3, h += (160 * Math.sin(c / 12 * a) + 320 * Math.sin(c * a / 30)) * 2 / 3, h;
|
|
1059
|
+
}, b = function(i, c) {
|
|
1060
|
+
var c = +c, i = +i, h = 300 + i + 2 * c + 0.1 * i * i + 0.1 * i * c + 0.1 * Math.sqrt(Math.abs(i));
|
|
1061
|
+
return h += (20 * Math.sin(6 * i * a) + 20 * Math.sin(2 * i * a)) * 2 / 3, h += (20 * Math.sin(i * a) + 40 * Math.sin(i / 3 * a)) * 2 / 3, h += (150 * Math.sin(i / 12 * a) + 300 * Math.sin(i / 30 * a)) * 2 / 3, h;
|
|
1062
|
+
}, C = function(i, c) {
|
|
1063
|
+
var c = +c, i = +i;
|
|
1064
|
+
return !(i > 73.66 && i < 135.05 && c > 3.86 && c < 53.55);
|
|
1061
1065
|
};
|
|
1062
1066
|
return {
|
|
1063
1067
|
bd09togcj02: l,
|
|
1064
|
-
gcj02tobd09:
|
|
1065
|
-
wgs84togcj02:
|
|
1066
|
-
gcj02towgs84:
|
|
1068
|
+
gcj02tobd09: r,
|
|
1069
|
+
wgs84togcj02: o,
|
|
1070
|
+
gcj02towgs84: s
|
|
1067
1071
|
};
|
|
1068
1072
|
});
|
|
1069
|
-
})(
|
|
1070
|
-
var
|
|
1071
|
-
const
|
|
1072
|
-
const l = (
|
|
1073
|
-
const
|
|
1074
|
-
|
|
1075
|
-
const
|
|
1076
|
-
return
|
|
1073
|
+
})(Lt);
|
|
1074
|
+
var Wr = Lt.exports;
|
|
1075
|
+
const $t = /* @__PURE__ */ Zr(Wr), qr = (e, t, { type: a, MapGL: n, map: u }) => {
|
|
1076
|
+
const l = (r, o) => {
|
|
1077
|
+
const s = document.createElement("div");
|
|
1078
|
+
s.style.cursor = "pointer";
|
|
1079
|
+
const v = Qt(r, o);
|
|
1080
|
+
return ea(v, s), s;
|
|
1077
1081
|
};
|
|
1078
|
-
e.addCustomComponent = (
|
|
1079
|
-
!Array.isArray(
|
|
1080
|
-
const { component:
|
|
1082
|
+
e.addCustomComponent = (r) => {
|
|
1083
|
+
!Array.isArray(r) || (r == null ? void 0 : r.length) === 0 || r.forEach((o) => {
|
|
1084
|
+
const { component: s, componentProps: v, lng: b, lat: C, markerOptions: M = {} } = o, k = typeof v == "function" ? v() : v, $ = typeof s == "function" ? s() : s, c = () => l($, k);
|
|
1081
1085
|
if (a.value === "baidu") {
|
|
1082
|
-
const i =
|
|
1086
|
+
const i = $t.gcj02tobd09(b, C), h = new n.value.CustomOverlay(c, {
|
|
1083
1087
|
point: { lng: i[0], lat: i[1] },
|
|
1084
|
-
...
|
|
1088
|
+
...M
|
|
1085
1089
|
});
|
|
1086
|
-
|
|
1087
|
-
t("click-custom-component",
|
|
1090
|
+
u.value.addOverlay(h), h.addEventListener("click", function(A) {
|
|
1091
|
+
t("click-custom-component", o, A);
|
|
1088
1092
|
});
|
|
1089
1093
|
}
|
|
1090
1094
|
if (a.value === "gaode") {
|
|
1091
|
-
const i = l(
|
|
1092
|
-
|
|
1093
|
-
t("click-custom-component",
|
|
1095
|
+
const i = l($, k), h = new n.value.Marker({ content: i, position: [b, C], ...M });
|
|
1096
|
+
u.value.add(h), n.value.event.addListener(h, "click", function(A) {
|
|
1097
|
+
t("click-custom-component", o, A);
|
|
1094
1098
|
});
|
|
1095
1099
|
}
|
|
1096
1100
|
});
|
|
1097
1101
|
};
|
|
1098
|
-
},
|
|
1102
|
+
}, Yr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1099
1103
|
__proto__: null,
|
|
1100
|
-
default:
|
|
1101
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
1104
|
+
default: qr
|
|
1105
|
+
}, Symbol.toStringTag, { value: "Module" })), Xr = (e, t, { type: a, MapGL: n, map: u, innerPoint: l, innerInput: r, adCode: o, addressInfo: s }) => {
|
|
1102
1106
|
e.getMapInfo = () => {
|
|
1103
1107
|
if (a.value === "baidu") {
|
|
1104
|
-
const
|
|
1108
|
+
const v = $t.bd09togcj02(l.value[0], l.value[1]);
|
|
1105
1109
|
return {
|
|
1106
|
-
longitude:
|
|
1107
|
-
latitude:
|
|
1108
|
-
address:
|
|
1109
|
-
adCode:
|
|
1110
|
+
longitude: v[0],
|
|
1111
|
+
latitude: v[1],
|
|
1112
|
+
address: r.value,
|
|
1113
|
+
adCode: o.value,
|
|
1114
|
+
addressInfo: s.value
|
|
1110
1115
|
};
|
|
1111
1116
|
}
|
|
1112
1117
|
if (a.value === "gaode")
|
|
1113
1118
|
return {
|
|
1114
1119
|
longitude: l.value[0],
|
|
1115
1120
|
latitude: l.value[1],
|
|
1116
|
-
address:
|
|
1117
|
-
adCode:
|
|
1121
|
+
address: r.value,
|
|
1122
|
+
adCode: o.value,
|
|
1123
|
+
addressInfo: s.value
|
|
1124
|
+
};
|
|
1125
|
+
if (a.value === "google")
|
|
1126
|
+
return {
|
|
1127
|
+
longitude: l.value[0],
|
|
1128
|
+
latitude: l.value[1],
|
|
1129
|
+
address: r.value,
|
|
1130
|
+
adCode: o.value,
|
|
1131
|
+
addressInfo: s.value
|
|
1118
1132
|
};
|
|
1119
1133
|
};
|
|
1120
|
-
},
|
|
1134
|
+
}, Qr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1121
1135
|
__proto__: null,
|
|
1122
|
-
default:
|
|
1136
|
+
default: Xr
|
|
1123
1137
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
1124
|
-
function
|
|
1125
|
-
for (var a = -1,
|
|
1126
|
-
|
|
1127
|
-
return
|
|
1138
|
+
function en(e, t) {
|
|
1139
|
+
for (var a = -1, n = e == null ? 0 : e.length, u = Array(n); ++a < n; )
|
|
1140
|
+
u[a] = t(e[a], a, e);
|
|
1141
|
+
return u;
|
|
1128
1142
|
}
|
|
1129
|
-
var
|
|
1130
|
-
function
|
|
1131
|
-
return typeof e == "symbol" ||
|
|
1143
|
+
var tn = "[object Symbol]";
|
|
1144
|
+
function an(e) {
|
|
1145
|
+
return typeof e == "symbol" || re(e) && se(e) == tn;
|
|
1132
1146
|
}
|
|
1133
|
-
var
|
|
1134
|
-
function
|
|
1147
|
+
var on = 1 / 0, at = ee ? ee.prototype : void 0, ot = at ? at.toString : void 0;
|
|
1148
|
+
function Et(e) {
|
|
1135
1149
|
if (typeof e == "string")
|
|
1136
1150
|
return e;
|
|
1137
|
-
if (
|
|
1138
|
-
return
|
|
1139
|
-
if (
|
|
1140
|
-
return
|
|
1151
|
+
if (ve(e))
|
|
1152
|
+
return en(e, Et) + "";
|
|
1153
|
+
if (an(e))
|
|
1154
|
+
return ot ? ot.call(e) : "";
|
|
1141
1155
|
var t = e + "";
|
|
1142
|
-
return t == "0" && 1 / e == -
|
|
1156
|
+
return t == "0" && 1 / e == -on ? "-0" : t;
|
|
1143
1157
|
}
|
|
1144
|
-
function
|
|
1145
|
-
return e == null ? "" :
|
|
1158
|
+
function ye(e) {
|
|
1159
|
+
return e == null ? "" : Et(e);
|
|
1146
1160
|
}
|
|
1147
|
-
function
|
|
1148
|
-
var
|
|
1149
|
-
t < 0 && (t = -t >
|
|
1150
|
-
for (var l = Array(
|
|
1151
|
-
l[
|
|
1161
|
+
function rn(e, t, a) {
|
|
1162
|
+
var n = -1, u = e.length;
|
|
1163
|
+
t < 0 && (t = -t > u ? 0 : u + t), a = a > u ? u : a, a < 0 && (a += u), u = t > a ? 0 : a - t >>> 0, t >>>= 0;
|
|
1164
|
+
for (var l = Array(u); ++n < u; )
|
|
1165
|
+
l[n] = e[n + t];
|
|
1152
1166
|
return l;
|
|
1153
1167
|
}
|
|
1154
|
-
function
|
|
1155
|
-
var
|
|
1156
|
-
return a = a === void 0 ?
|
|
1168
|
+
function nn(e, t, a) {
|
|
1169
|
+
var n = e.length;
|
|
1170
|
+
return a = a === void 0 ? n : a, !t && a >= n ? e : rn(e, t, a);
|
|
1157
1171
|
}
|
|
1158
|
-
var
|
|
1159
|
-
function
|
|
1160
|
-
return
|
|
1172
|
+
var ln = "\\ud800-\\udfff", un = "\\u0300-\\u036f", cn = "\\ufe20-\\ufe2f", sn = "\\u20d0-\\u20ff", dn = un + cn + sn, fn = "\\ufe0e\\ufe0f", vn = "\\u200d", gn = RegExp("[" + vn + ln + dn + fn + "]");
|
|
1173
|
+
function Pt(e) {
|
|
1174
|
+
return gn.test(e);
|
|
1161
1175
|
}
|
|
1162
|
-
function
|
|
1176
|
+
function pn(e) {
|
|
1163
1177
|
return e.split("");
|
|
1164
1178
|
}
|
|
1165
|
-
var
|
|
1166
|
-
function
|
|
1167
|
-
return e.match(
|
|
1179
|
+
var kt = "\\ud800-\\udfff", hn = "\\u0300-\\u036f", yn = "\\ufe20-\\ufe2f", mn = "\\u20d0-\\u20ff", bn = hn + yn + mn, _n = "\\ufe0e\\ufe0f", wn = "[" + kt + "]", xe = "[" + bn + "]", Ce = "\\ud83c[\\udffb-\\udfff]", Mn = "(?:" + xe + "|" + Ce + ")", Rt = "[^" + kt + "]", Gt = "(?:\\ud83c[\\udde6-\\uddff]){2}", Bt = "[\\ud800-\\udbff][\\udc00-\\udfff]", xn = "\\u200d", Dt = Mn + "?", zt = "[" + _n + "]?", Cn = "(?:" + xn + "(?:" + [Rt, Gt, Bt].join("|") + ")" + zt + Dt + ")*", An = zt + Dt + Cn, Sn = "(?:" + [Rt + xe + "?", xe, Gt, Bt, wn].join("|") + ")", On = RegExp(Ce + "(?=" + Ce + ")|" + Sn + An, "g");
|
|
1180
|
+
function Tn(e) {
|
|
1181
|
+
return e.match(On) || [];
|
|
1168
1182
|
}
|
|
1169
|
-
function
|
|
1170
|
-
return
|
|
1183
|
+
function jn(e) {
|
|
1184
|
+
return Pt(e) ? Tn(e) : pn(e);
|
|
1171
1185
|
}
|
|
1172
|
-
function
|
|
1186
|
+
function Ln(e) {
|
|
1173
1187
|
return function(t) {
|
|
1174
|
-
t =
|
|
1175
|
-
var a =
|
|
1176
|
-
return
|
|
1188
|
+
t = ye(t);
|
|
1189
|
+
var a = Pt(t) ? jn(t) : void 0, n = a ? a[0] : t.charAt(0), u = a ? nn(a, 1).join("") : t.slice(1);
|
|
1190
|
+
return n[e]() + u;
|
|
1177
1191
|
};
|
|
1178
1192
|
}
|
|
1179
|
-
var
|
|
1180
|
-
function
|
|
1181
|
-
return
|
|
1193
|
+
var $n = Ln("toUpperCase");
|
|
1194
|
+
function En(e) {
|
|
1195
|
+
return $n(ye(e).toLowerCase());
|
|
1182
1196
|
}
|
|
1183
|
-
function
|
|
1184
|
-
for (var
|
|
1185
|
-
a = t(a, e[
|
|
1197
|
+
function Pn(e, t, a, n) {
|
|
1198
|
+
for (var u = -1, l = e == null ? 0 : e.length; ++u < l; )
|
|
1199
|
+
a = t(a, e[u], u, e);
|
|
1186
1200
|
return a;
|
|
1187
1201
|
}
|
|
1188
|
-
function
|
|
1202
|
+
function kn(e) {
|
|
1189
1203
|
return function(t) {
|
|
1190
1204
|
return e == null ? void 0 : e[t];
|
|
1191
1205
|
};
|
|
1192
1206
|
}
|
|
1193
|
-
var
|
|
1207
|
+
var Rn = {
|
|
1194
1208
|
// Latin-1 Supplement block.
|
|
1195
1209
|
À: "A",
|
|
1196
1210
|
Á: "A",
|
|
@@ -1383,147 +1397,359 @@ var Co = {
|
|
|
1383
1397
|
œ: "oe",
|
|
1384
1398
|
ʼn: "'n",
|
|
1385
1399
|
ſ: "s"
|
|
1386
|
-
},
|
|
1387
|
-
function
|
|
1388
|
-
return e =
|
|
1389
|
-
}
|
|
1390
|
-
var
|
|
1391
|
-
function
|
|
1392
|
-
return e.match(
|
|
1393
|
-
}
|
|
1394
|
-
var
|
|
1395
|
-
function
|
|
1396
|
-
return
|
|
1397
|
-
}
|
|
1398
|
-
var
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1400
|
+
}, Gn = kn(Rn), Bn = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g, Dn = "\\u0300-\\u036f", zn = "\\ufe20-\\ufe2f", Nn = "\\u20d0-\\u20ff", Vn = Dn + zn + Nn, Un = "[" + Vn + "]", Fn = RegExp(Un, "g");
|
|
1401
|
+
function Kn(e) {
|
|
1402
|
+
return e = ye(e), e && e.replace(Bn, Gn).replace(Fn, "");
|
|
1403
|
+
}
|
|
1404
|
+
var In = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;
|
|
1405
|
+
function Hn(e) {
|
|
1406
|
+
return e.match(In) || [];
|
|
1407
|
+
}
|
|
1408
|
+
var Jn = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;
|
|
1409
|
+
function Zn(e) {
|
|
1410
|
+
return Jn.test(e);
|
|
1411
|
+
}
|
|
1412
|
+
var Nt = "\\ud800-\\udfff", Wn = "\\u0300-\\u036f", qn = "\\ufe20-\\ufe2f", Yn = "\\u20d0-\\u20ff", Xn = Wn + qn + Yn, Vt = "\\u2700-\\u27bf", Ut = "a-z\\xdf-\\xf6\\xf8-\\xff", Qn = "\\xac\\xb1\\xd7\\xf7", el = "\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf", tl = "\\u2000-\\u206f", al = " \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000", Ft = "A-Z\\xc0-\\xd6\\xd8-\\xde", ol = "\\ufe0e\\ufe0f", Kt = Qn + el + tl + al, It = "['’]", rt = "[" + Kt + "]", rl = "[" + Xn + "]", Ht = "\\d+", nl = "[" + Vt + "]", Jt = "[" + Ut + "]", Zt = "[^" + Nt + Kt + Ht + Vt + Ut + Ft + "]", ll = "\\ud83c[\\udffb-\\udfff]", ul = "(?:" + rl + "|" + ll + ")", il = "[^" + Nt + "]", Wt = "(?:\\ud83c[\\udde6-\\uddff]){2}", qt = "[\\ud800-\\udbff][\\udc00-\\udfff]", X = "[" + Ft + "]", cl = "\\u200d", nt = "(?:" + Jt + "|" + Zt + ")", sl = "(?:" + X + "|" + Zt + ")", lt = "(?:" + It + "(?:d|ll|m|re|s|t|ve))?", ut = "(?:" + It + "(?:D|LL|M|RE|S|T|VE))?", Yt = ul + "?", Xt = "[" + ol + "]?", dl = "(?:" + cl + "(?:" + [il, Wt, qt].join("|") + ")" + Xt + Yt + ")*", fl = "\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])", vl = "\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])", gl = Xt + Yt + dl, pl = "(?:" + [nl, Wt, qt].join("|") + ")" + gl, hl = RegExp([
|
|
1413
|
+
X + "?" + Jt + "+" + lt + "(?=" + [rt, X, "$"].join("|") + ")",
|
|
1414
|
+
sl + "+" + ut + "(?=" + [rt, X + nt, "$"].join("|") + ")",
|
|
1415
|
+
X + "?" + nt + "+" + lt,
|
|
1416
|
+
X + "+" + ut,
|
|
1417
|
+
vl,
|
|
1418
|
+
fl,
|
|
1419
|
+
Ht,
|
|
1420
|
+
pl
|
|
1407
1421
|
].join("|"), "g");
|
|
1408
|
-
function
|
|
1409
|
-
return e.match(
|
|
1422
|
+
function yl(e) {
|
|
1423
|
+
return e.match(hl) || [];
|
|
1410
1424
|
}
|
|
1411
|
-
function
|
|
1412
|
-
return e =
|
|
1425
|
+
function ml(e, t, a) {
|
|
1426
|
+
return e = ye(e), t = t, t === void 0 ? Zn(e) ? yl(e) : Hn(e) : e.match(t) || [];
|
|
1413
1427
|
}
|
|
1414
|
-
var
|
|
1415
|
-
function
|
|
1428
|
+
var bl = "['’]", _l = RegExp(bl, "g");
|
|
1429
|
+
function wl(e) {
|
|
1416
1430
|
return function(t) {
|
|
1417
|
-
return
|
|
1431
|
+
return Pn(ml(Kn(t).replace(_l, "")), e, "");
|
|
1418
1432
|
};
|
|
1419
1433
|
}
|
|
1420
|
-
var
|
|
1421
|
-
return t = t.toLowerCase(), e + (a ?
|
|
1434
|
+
var Ml = wl(function(e, t, a) {
|
|
1435
|
+
return t = t.toLowerCase(), e + (a ? En(t) : t);
|
|
1422
1436
|
});
|
|
1423
|
-
const
|
|
1424
|
-
const a =
|
|
1425
|
-
return e[a] =
|
|
1426
|
-
}, {}),
|
|
1427
|
-
const
|
|
1428
|
-
return { mapElement:
|
|
1429
|
-
const
|
|
1430
|
-
if (Array.isArray(
|
|
1437
|
+
const it = /* @__PURE__ */ Object.assign({ "./add-custom-dom/index.ts": Yr, "./get-map-info/index.ts": Qr }), xl = Object.keys(it).reduce((e, t) => {
|
|
1438
|
+
const a = Ml(t.replace("./", "").split("/")[0]);
|
|
1439
|
+
return e[a] = it[t].default, e;
|
|
1440
|
+
}, {}), Cl = (e, t, a) => {
|
|
1441
|
+
const n = S({});
|
|
1442
|
+
return { mapElement: n, addPlugins: () => {
|
|
1443
|
+
const r = Hr({}, (e == null ? void 0 : e.options) || {}, (o, s) => {
|
|
1444
|
+
if (Array.isArray(o)) return o.concat(s);
|
|
1431
1445
|
});
|
|
1432
|
-
Object.values(
|
|
1446
|
+
Object.values(xl).forEach((o) => o(n.value, t, a, r.plugins || {}));
|
|
1433
1447
|
} };
|
|
1434
|
-
},
|
|
1435
|
-
const
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1448
|
+
}, Al = ({ MapGL: e, map: t, marker: a, mapLoading: n, $autocomplete: u, searchResultList: l, innerInput: r, innerPoint: o, adCode: s, addressInfo: v }, b) => {
|
|
1449
|
+
const C = S(), M = S(), k = S();
|
|
1450
|
+
let $ = null;
|
|
1451
|
+
const c = S(!1), i = S();
|
|
1452
|
+
let h;
|
|
1453
|
+
const A = async (d, f, y, x) => {
|
|
1454
|
+
i.value = y, x && (h = x);
|
|
1455
|
+
const m = document.createElement("script");
|
|
1456
|
+
m.src = `https://maps.googleapis.com/maps/api/js?key=${d}&loading=async&libraries=map,marker&callback=onLoad`, document.body.appendChild(m), window.onLoad = () => {
|
|
1457
|
+
B();
|
|
1458
|
+
};
|
|
1459
|
+
}, B = async () => {
|
|
1460
|
+
var N, G;
|
|
1461
|
+
const { Map: d } = await google.maps.importLibrary("maps");
|
|
1462
|
+
e.value = d;
|
|
1463
|
+
const { Place: f, AutocompleteSessionToken: y, AutocompleteSuggestion: x } = await google.maps.importLibrary("places");
|
|
1464
|
+
M.value = new y(), k.value = x, C.value = f;
|
|
1465
|
+
const { AdvancedMarkerElement: m } = await google.maps.importLibrary("marker");
|
|
1466
|
+
$ = m;
|
|
1467
|
+
const T = ((N = i.value) == null ? void 0 : N.mapOpt) ?? {};
|
|
1468
|
+
t.value = new d(document.getElementById("map"), {
|
|
1469
|
+
zoom: 11,
|
|
1470
|
+
mapId: "DEMO_MAP_ID",
|
|
1471
|
+
fullscreenControl: !1,
|
|
1472
|
+
// 全屏
|
|
1473
|
+
streetViewControl: !1,
|
|
1474
|
+
// 街景
|
|
1475
|
+
mapTypeControl: !1,
|
|
1476
|
+
// 左上角地图类型
|
|
1477
|
+
gestureHandling: "greedy",
|
|
1478
|
+
// 谷歌地图api缩放去掉ctrl+滚轮缩放,直接鼠标缩放
|
|
1479
|
+
...T
|
|
1480
|
+
}), await j(), (G = i.value) != null && G.clickStream || _(), n.value = !1, c.value = !r.value && !o.value.length, h && h();
|
|
1481
|
+
}, _ = () => {
|
|
1482
|
+
var d;
|
|
1483
|
+
(d = t.value) == null || d.addListener("click", (f) => {
|
|
1484
|
+
var y, x;
|
|
1485
|
+
a.value && a.value.setMap(null), o.value = [(y = f == null ? void 0 : f.latLng) == null ? void 0 : y.lng(), (x = f == null ? void 0 : f.latLng) == null ? void 0 : x.lat()], R(o.value, !0).then(() => {
|
|
1486
|
+
var T;
|
|
1487
|
+
const m = {
|
|
1488
|
+
lng: parseFloat(o.value[0]),
|
|
1489
|
+
lat: parseFloat(o.value[1])
|
|
1490
|
+
};
|
|
1491
|
+
a.value = new $({
|
|
1492
|
+
map: t.value,
|
|
1493
|
+
position: m,
|
|
1494
|
+
title: r.value
|
|
1495
|
+
// 鼠标移上去时显示的内容
|
|
1496
|
+
}), (T = t.value) == null || T.panTo(m);
|
|
1497
|
+
});
|
|
1498
|
+
});
|
|
1499
|
+
}, j = async () => {
|
|
1500
|
+
var d;
|
|
1501
|
+
if (!r.value && o.value.length, r.value && o.value.length > 0 ? await R(o.value) : r.value ? await V(r.value) : o.value.length > 0 && await R(o.value, !0), r.value && g(r.value, (f, y) => {
|
|
1502
|
+
if (y && y.length) {
|
|
1503
|
+
const x = y.find(
|
|
1504
|
+
(m) => m.value === r.value || m.info.name === r.value
|
|
1505
|
+
);
|
|
1506
|
+
x ? v.value = x.info : v.value = {
|
|
1507
|
+
district: "",
|
|
1508
|
+
address: "",
|
|
1509
|
+
name: r.value
|
|
1510
|
+
};
|
|
1511
|
+
}
|
|
1512
|
+
}), o.value.length) {
|
|
1513
|
+
const f = {
|
|
1514
|
+
lng: parseFloat(o.value[0]),
|
|
1515
|
+
lat: parseFloat(o.value[1])
|
|
1516
|
+
};
|
|
1517
|
+
a.value = new $({
|
|
1518
|
+
map: t.value,
|
|
1519
|
+
position: f,
|
|
1520
|
+
title: r.value
|
|
1521
|
+
// 鼠标移上去时显示的内容
|
|
1522
|
+
}), o.value.length && ((d = t.value) == null || d.setCenter(f));
|
|
1523
|
+
}
|
|
1524
|
+
}, R = (d, f = !1) => (d.join(","), new Promise((y, x) => {
|
|
1525
|
+
new google.maps.Geocoder().geocode({
|
|
1526
|
+
location: {
|
|
1527
|
+
lng: parseFloat(d[0]),
|
|
1528
|
+
lat: parseFloat(d[1])
|
|
1529
|
+
}
|
|
1530
|
+
}, (T, N) => {
|
|
1531
|
+
N === "OK" && (T != null && T.length) ? (f && (r.value = T[0].formatted_address ?? "", v.value = {
|
|
1532
|
+
district: "",
|
|
1533
|
+
address: "",
|
|
1534
|
+
name: r.value
|
|
1535
|
+
}), y(T[0])) : (z.error(E("thirdPartyMapErrorRetry")), x());
|
|
1536
|
+
});
|
|
1537
|
+
})), V = (d) => new Promise((f, y) => {
|
|
1538
|
+
new google.maps.Geocoder().geocode({
|
|
1539
|
+
address: r.value
|
|
1540
|
+
}, (m, T) => {
|
|
1541
|
+
T === "OK" && (m != null && m.length) ? (o.value[0] = m[0].geometry.location.lng(), o.value[1] = m[0].geometry.location.lat(), f({ lng: o.value[0], lat: o.value[1] })) : (z.error(E("thirdPartyMapErrorRetry")), y());
|
|
1542
|
+
});
|
|
1543
|
+
}), O = async () => {
|
|
1544
|
+
var d;
|
|
1545
|
+
navigator.geolocation && ((d = navigator.geolocation) == null || d.getCurrentPosition((f) => {
|
|
1546
|
+
var x;
|
|
1547
|
+
const y = {
|
|
1548
|
+
lat: f.coords.latitude,
|
|
1549
|
+
lng: f.coords.longitude
|
|
1550
|
+
};
|
|
1551
|
+
(x = t.value) == null || x.panTo(y), c.value = !1;
|
|
1552
|
+
}, (f) => {
|
|
1553
|
+
z.error(E("获取定位失败"));
|
|
1554
|
+
}, {
|
|
1555
|
+
// enableHighAccuracy: true,
|
|
1556
|
+
// timeout: 5000,
|
|
1557
|
+
// maximumAge: 0,
|
|
1558
|
+
// enableHighAccuracy: true
|
|
1559
|
+
}));
|
|
1560
|
+
}, g = async (d, f) => {
|
|
1561
|
+
if (u.value.activated = !0, !d) {
|
|
1562
|
+
l.value = [], f([]);
|
|
1563
|
+
return;
|
|
1564
|
+
}
|
|
1565
|
+
let y = {
|
|
1566
|
+
input: d,
|
|
1567
|
+
origin: { lng: parseFloat(o.value[0]), lat: parseFloat(o.value[1]) },
|
|
1568
|
+
sessionToken: M.value
|
|
1569
|
+
};
|
|
1570
|
+
const { suggestions: x } = await k.value.fetchAutocompleteSuggestions(y);
|
|
1571
|
+
if (l.value = [], !x) return f([]);
|
|
1572
|
+
let m = [];
|
|
1573
|
+
await Promise.all(
|
|
1574
|
+
x.map((T) => (async () => {
|
|
1575
|
+
var J, le;
|
|
1576
|
+
let G = (T == null ? void 0 : T.placePrediction).toPlace();
|
|
1577
|
+
await G.fetchFields({
|
|
1578
|
+
fields: [
|
|
1579
|
+
"displayName",
|
|
1580
|
+
"formattedAddress",
|
|
1581
|
+
"location"
|
|
1582
|
+
]
|
|
1583
|
+
});
|
|
1584
|
+
const ne = (J = G == null ? void 0 : G.location) == null ? void 0 : J.lng(), U = (le = G == null ? void 0 : G.location) == null ? void 0 : le.lat(), F = {
|
|
1585
|
+
// value: placePrediction?.text?.toString() || '',
|
|
1586
|
+
value: G == null ? void 0 : G.formattedAddress,
|
|
1587
|
+
point: { lng: ne, lat: U },
|
|
1588
|
+
info: {
|
|
1589
|
+
name: G == null ? void 0 : G.displayName
|
|
1590
|
+
}
|
|
1591
|
+
};
|
|
1592
|
+
m.push(F);
|
|
1593
|
+
})())
|
|
1594
|
+
), l.value = m.length > 5 ? m.slice(0, 5) : m, f(l.value, m);
|
|
1595
|
+
};
|
|
1596
|
+
return {
|
|
1597
|
+
getLocationByInputSearch: g,
|
|
1598
|
+
handleSelectAddress: (d) => {
|
|
1599
|
+
r.value = d.value, v.value = d.info, V(d.value).then((f) => {
|
|
1600
|
+
var y;
|
|
1601
|
+
o.value = [f.lng, f.lat], a.value && a.value.setMap(null), a.value = new $({
|
|
1602
|
+
map: t.value,
|
|
1603
|
+
position: f,
|
|
1604
|
+
title: r.value
|
|
1605
|
+
// 鼠标移上去时显示的内容
|
|
1606
|
+
}), (y = t.value) == null || y.panTo(f), c.value = !1;
|
|
1607
|
+
});
|
|
1608
|
+
},
|
|
1609
|
+
getLocationParse: async () => {
|
|
1610
|
+
var d, f;
|
|
1611
|
+
if (!l.value.length) return z.error(E("thirdPartyMapErrorRetry"));
|
|
1612
|
+
if (r.value = l.value[0].value, !((d = l.value[0]) != null && d.point))
|
|
1613
|
+
return z.error(E("thirdPartyMapErrorRetry"));
|
|
1614
|
+
o.value = [l.value[0].point.lng, l.value[0].point.lat], v.value = l.value[0].info, a.value = new $({
|
|
1615
|
+
map: t.value,
|
|
1616
|
+
position: l.value[0].point,
|
|
1617
|
+
title: r.value
|
|
1618
|
+
// 鼠标移上去时显示的内容
|
|
1619
|
+
}), (f = t.value) == null || f.panTo(l.value[0].point), c.value = !1, u.value.activated = !1;
|
|
1620
|
+
},
|
|
1621
|
+
getMapInfo: () => ({
|
|
1622
|
+
longitude: o.value[0],
|
|
1623
|
+
latitude: o.value[1],
|
|
1624
|
+
adCode: s.value,
|
|
1625
|
+
address: r.value,
|
|
1626
|
+
addressInfo: v.value
|
|
1627
|
+
}),
|
|
1628
|
+
loadJavascript: A,
|
|
1629
|
+
positionCityLocal: O,
|
|
1630
|
+
showGetLocationBtn: c
|
|
1631
|
+
};
|
|
1632
|
+
}, Sl = (e, t) => {
|
|
1633
|
+
const a = S("gaode"), n = S(), u = S(), l = I(null), r = I(null), o = I(null), s = S(!0), v = S(null), b = S([]), C = Se(() => ({
|
|
1634
|
+
width: e.width ? Q(e.width) : "100%",
|
|
1635
|
+
height: e.height ? Q(e.height) : "100%"
|
|
1636
|
+
})), M = S(""), k = S([]), $ = S(""), c = S(), {
|
|
1637
|
+
loadJavascript: i,
|
|
1638
|
+
getLocationByInputSearch: h,
|
|
1639
|
+
handleSelectAddress: A,
|
|
1640
|
+
getLocationParse: B
|
|
1641
|
+
} = ft({
|
|
1444
1642
|
BMap: l,
|
|
1445
|
-
map:
|
|
1446
|
-
marker:
|
|
1447
|
-
mapLoading:
|
|
1448
|
-
$autocomplete:
|
|
1449
|
-
searchResultList:
|
|
1450
|
-
innerInput:
|
|
1451
|
-
innerPoint:
|
|
1452
|
-
adCode:
|
|
1643
|
+
map: r,
|
|
1644
|
+
marker: o,
|
|
1645
|
+
mapLoading: s,
|
|
1646
|
+
$autocomplete: v,
|
|
1647
|
+
searchResultList: b,
|
|
1648
|
+
innerInput: M,
|
|
1649
|
+
innerPoint: k,
|
|
1650
|
+
adCode: $,
|
|
1651
|
+
addressInfo: c
|
|
1453
1652
|
}), {
|
|
1454
|
-
loadJavascript:
|
|
1455
|
-
getLocationByInputSearch:
|
|
1456
|
-
handleSelectAddress:
|
|
1457
|
-
getLocationParse:
|
|
1458
|
-
} =
|
|
1653
|
+
loadJavascript: _,
|
|
1654
|
+
getLocationByInputSearch: j,
|
|
1655
|
+
handleSelectAddress: R,
|
|
1656
|
+
getLocationParse: V
|
|
1657
|
+
} = st({
|
|
1459
1658
|
MapGL: l,
|
|
1460
|
-
map:
|
|
1461
|
-
marker:
|
|
1462
|
-
mapLoading:
|
|
1463
|
-
$autocomplete:
|
|
1464
|
-
searchResultList:
|
|
1465
|
-
innerInput:
|
|
1466
|
-
innerPoint:
|
|
1467
|
-
adCode:
|
|
1468
|
-
|
|
1659
|
+
map: r,
|
|
1660
|
+
marker: o,
|
|
1661
|
+
mapLoading: s,
|
|
1662
|
+
$autocomplete: v,
|
|
1663
|
+
searchResultList: b,
|
|
1664
|
+
innerInput: M,
|
|
1665
|
+
innerPoint: k,
|
|
1666
|
+
adCode: $,
|
|
1667
|
+
addressInfo: c
|
|
1668
|
+
}), {
|
|
1669
|
+
loadJavascript: O,
|
|
1670
|
+
getLocationByInputSearch: g,
|
|
1671
|
+
handleSelectAddress: p,
|
|
1672
|
+
getLocationParse: w,
|
|
1673
|
+
positionCityLocal: L,
|
|
1674
|
+
showGetLocationBtn: d
|
|
1675
|
+
} = Al({
|
|
1676
|
+
MapGL: l,
|
|
1677
|
+
map: r,
|
|
1678
|
+
marker: o,
|
|
1679
|
+
mapLoading: s,
|
|
1680
|
+
$autocomplete: v,
|
|
1681
|
+
searchResultList: b,
|
|
1682
|
+
innerInput: M,
|
|
1683
|
+
innerPoint: k,
|
|
1684
|
+
adCode: $,
|
|
1685
|
+
addressInfo: c
|
|
1686
|
+
}), { mapElement: f, addPlugins: y } = Cl(e, t, {
|
|
1469
1687
|
type: a,
|
|
1470
1688
|
MapGL: l,
|
|
1471
|
-
map:
|
|
1472
|
-
innerPoint:
|
|
1473
|
-
innerInput:
|
|
1474
|
-
adCode:
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1689
|
+
map: r,
|
|
1690
|
+
innerPoint: k,
|
|
1691
|
+
innerInput: M,
|
|
1692
|
+
adCode: $,
|
|
1693
|
+
addressInfo: c
|
|
1694
|
+
}), x = () => {
|
|
1695
|
+
a.value === "baidu" && i(n.value, { clickStream: !e.clickStream, mapOpt: e.mapOpt }, T), a.value === "gaode" && _(
|
|
1696
|
+
n.value,
|
|
1697
|
+
u.value,
|
|
1479
1698
|
{ clickStream: !e.clickStream, mapOpt: e.mapOpt },
|
|
1480
|
-
|
|
1699
|
+
T
|
|
1700
|
+
), a.value === "google" && O(
|
|
1701
|
+
n.value,
|
|
1702
|
+
u.value,
|
|
1703
|
+
{ clickStream: !e.clickStream, mapOpt: e.mapOpt },
|
|
1704
|
+
T
|
|
1481
1705
|
);
|
|
1482
|
-
},
|
|
1483
|
-
const [
|
|
1484
|
-
if (
|
|
1485
|
-
|
|
1706
|
+
}, m = async (U) => {
|
|
1707
|
+
const [F, J] = await Ge(U);
|
|
1708
|
+
if (F) {
|
|
1709
|
+
s.value = !1;
|
|
1486
1710
|
return;
|
|
1487
1711
|
}
|
|
1488
|
-
if (!
|
|
1489
|
-
t("no-config-map",
|
|
1712
|
+
if (!F && !J) {
|
|
1713
|
+
t("no-config-map", E("暂未配置地图")), s.value = !1;
|
|
1490
1714
|
return;
|
|
1491
1715
|
}
|
|
1492
|
-
return
|
|
1716
|
+
return J;
|
|
1493
1717
|
};
|
|
1494
|
-
|
|
1495
|
-
var
|
|
1496
|
-
if (e.defaultLongitude && e.defaultLatitude && (
|
|
1497
|
-
a.value = ((
|
|
1718
|
+
Oe(async () => {
|
|
1719
|
+
var U, F, J, le, Ue;
|
|
1720
|
+
if (e.defaultLongitude && e.defaultLatitude && (k.value = [e.defaultLongitude, e.defaultLatitude]), M.value = e.defaultAddress ?? "", e != null && e.sdkConfig && ((U = e == null ? void 0 : e.sdkConfig) != null && U.akValue))
|
|
1721
|
+
a.value = ((F = e.sdkConfig) == null ? void 0 : F.mapType) ?? "gaode", n.value = (J = e.sdkConfig) == null ? void 0 : J.akValue, u.value = (le = e.sdkConfig) == null ? void 0 : le.secretKey;
|
|
1498
1722
|
else {
|
|
1499
|
-
const
|
|
1500
|
-
|
|
1723
|
+
const K = await m((Ue = e == null ? void 0 : e.sdkConfig) == null ? void 0 : Ue.mapType);
|
|
1724
|
+
K && (a.value = (K == null ? void 0 : K.mapType) ?? "gaode", n.value = K == null ? void 0 : K.akVal, u.value = K == null ? void 0 : K.secretK);
|
|
1501
1725
|
}
|
|
1502
|
-
|
|
1726
|
+
x();
|
|
1503
1727
|
});
|
|
1504
|
-
const
|
|
1505
|
-
|
|
1506
|
-
t("update:mapElement",
|
|
1507
|
-
}), a.value === "gaode" &&
|
|
1508
|
-
t("update:mapElement",
|
|
1509
|
-
});
|
|
1728
|
+
const T = () => {
|
|
1729
|
+
f.value = r.value, y(), a.value === "baidu" && r.value.addEventListener("tilesloaded", () => {
|
|
1730
|
+
t("update:mapElement", f.value);
|
|
1731
|
+
}), a.value === "gaode" && r.value.on("complete", () => {
|
|
1732
|
+
t("update:mapElement", f.value);
|
|
1733
|
+
}), a.value === "google" && t("update:mapElement", f.value);
|
|
1510
1734
|
};
|
|
1511
1735
|
return {
|
|
1512
|
-
mapStyle:
|
|
1513
|
-
innerInput:
|
|
1514
|
-
getLocationByInputSearch: (
|
|
1515
|
-
a.value === "baidu" &&
|
|
1736
|
+
mapStyle: C,
|
|
1737
|
+
innerInput: M,
|
|
1738
|
+
getLocationByInputSearch: (U, F) => {
|
|
1739
|
+
a.value === "baidu" && h(U, F), a.value === "gaode" && j(U, F), a.value === "google" && g(U, F);
|
|
1516
1740
|
},
|
|
1517
|
-
handleSelectAddress: (
|
|
1518
|
-
a.value === "baidu" &&
|
|
1741
|
+
handleSelectAddress: (U) => {
|
|
1742
|
+
a.value === "baidu" && A(U), a.value === "gaode" && R(U), a.value === "google" && p(U);
|
|
1519
1743
|
},
|
|
1520
1744
|
getLocationParse: () => {
|
|
1521
|
-
a.value === "baidu" &&
|
|
1745
|
+
a.value === "baidu" && B(), a.value === "gaode" && V(), a.value === "google" && w();
|
|
1522
1746
|
},
|
|
1523
|
-
mapLoading:
|
|
1524
|
-
$autocomplete:
|
|
1747
|
+
mapLoading: s,
|
|
1748
|
+
$autocomplete: v,
|
|
1749
|
+
googlePositionCityLocal: L,
|
|
1750
|
+
showGetLocationBtn: d
|
|
1525
1751
|
};
|
|
1526
|
-
},
|
|
1752
|
+
}, Ol = { class: "search-input" }, Tl = { class: "location-icon1" }, jl = { id: "map" }, Ll = /* @__PURE__ */ Ae({
|
|
1527
1753
|
__name: "mixMap",
|
|
1528
1754
|
props: {
|
|
1529
1755
|
defaultAddress: {},
|
|
@@ -1540,60 +1766,87 @@ const tt = /* @__PURE__ */ Object.assign({ "./add-custom-dom/index.ts": Bn, "./g
|
|
|
1540
1766
|
},
|
|
1541
1767
|
emits: ["update:mapElement", "no-config-map", "click-custom-component"],
|
|
1542
1768
|
setup(e, { emit: t }) {
|
|
1543
|
-
const a = e,
|
|
1544
|
-
mapStyle:
|
|
1769
|
+
const a = e, n = t, {
|
|
1770
|
+
mapStyle: u,
|
|
1545
1771
|
innerInput: l,
|
|
1546
|
-
getLocationByInputSearch:
|
|
1547
|
-
handleSelectAddress:
|
|
1548
|
-
getLocationParse:
|
|
1549
|
-
mapLoading:
|
|
1550
|
-
$autocomplete:
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1772
|
+
getLocationByInputSearch: r,
|
|
1773
|
+
handleSelectAddress: o,
|
|
1774
|
+
getLocationParse: s,
|
|
1775
|
+
mapLoading: v,
|
|
1776
|
+
$autocomplete: b,
|
|
1777
|
+
googlePositionCityLocal: C,
|
|
1778
|
+
showGetLocationBtn: M
|
|
1779
|
+
} = Sl(a, n);
|
|
1780
|
+
return (k, $) => {
|
|
1781
|
+
const c = Pe, i = ke;
|
|
1782
|
+
return Te(), je(
|
|
1555
1783
|
"div",
|
|
1556
1784
|
{
|
|
1557
1785
|
class: "das-map",
|
|
1558
|
-
style:
|
|
1786
|
+
style: Le(D(u))
|
|
1559
1787
|
},
|
|
1560
1788
|
[
|
|
1561
|
-
|
|
1789
|
+
Z(W(
|
|
1562
1790
|
"div",
|
|
1563
|
-
|
|
1791
|
+
Ol,
|
|
1564
1792
|
[
|
|
1565
|
-
|
|
1793
|
+
Z(de(c, {
|
|
1566
1794
|
ref_key: "$autocomplete",
|
|
1567
|
-
ref:
|
|
1568
|
-
modelValue:
|
|
1569
|
-
"onUpdate:modelValue":
|
|
1795
|
+
ref: b,
|
|
1796
|
+
modelValue: D(l),
|
|
1797
|
+
"onUpdate:modelValue": $[0] || ($[0] = (h) => ta(l) ? l.value = h : null),
|
|
1570
1798
|
modelModifiers: { trim: !0 },
|
|
1571
|
-
"fetch-suggestions":
|
|
1572
|
-
placeholder:
|
|
1799
|
+
"fetch-suggestions": D(r),
|
|
1800
|
+
placeholder: D(E)("请输入位置"),
|
|
1573
1801
|
style: { width: "100%" },
|
|
1574
1802
|
"trigger-on-focus": !1,
|
|
1575
|
-
onSelect:
|
|
1576
|
-
onKeyup:
|
|
1803
|
+
onSelect: D(o),
|
|
1804
|
+
onKeyup: $e(D(s), ["enter", "native"]),
|
|
1577
1805
|
clearable: ""
|
|
1578
1806
|
}, null, 8, ["modelValue", "fetch-suggestions", "placeholder", "onSelect", "onKeyup"]), [
|
|
1579
|
-
[
|
|
1807
|
+
[D(Re)]
|
|
1580
1808
|
])
|
|
1581
1809
|
],
|
|
1582
1810
|
512
|
|
1583
1811
|
/* NEED_PATCH */
|
|
1584
1812
|
), [
|
|
1585
|
-
[
|
|
1813
|
+
[Fe, a.showSearch]
|
|
1586
1814
|
]),
|
|
1587
|
-
|
|
1815
|
+
Z(W(
|
|
1588
1816
|
"div",
|
|
1589
|
-
|
|
1817
|
+
Tl,
|
|
1818
|
+
[
|
|
1819
|
+
de(D(la), {
|
|
1820
|
+
block: "",
|
|
1821
|
+
size: "large",
|
|
1822
|
+
onClick: D(C)
|
|
1823
|
+
}, {
|
|
1824
|
+
default: aa(() => [
|
|
1825
|
+
oa(
|
|
1826
|
+
ra(D(E)("Please-Click-Get-Location")),
|
|
1827
|
+
1
|
|
1828
|
+
/* TEXT */
|
|
1829
|
+
)
|
|
1830
|
+
]),
|
|
1831
|
+
_: 1
|
|
1832
|
+
/* STABLE */
|
|
1833
|
+
}, 8, ["onClick"])
|
|
1834
|
+
],
|
|
1835
|
+
512
|
|
1836
|
+
/* NEED_PATCH */
|
|
1837
|
+
), [
|
|
1838
|
+
[Fe, D(M)]
|
|
1839
|
+
]),
|
|
1840
|
+
Z(W(
|
|
1841
|
+
"div",
|
|
1842
|
+
jl,
|
|
1590
1843
|
null,
|
|
1591
1844
|
512
|
|
1592
1845
|
/* NEED_PATCH */
|
|
1593
1846
|
), [
|
|
1594
1847
|
[
|
|
1595
|
-
|
|
1596
|
-
|
|
1848
|
+
i,
|
|
1849
|
+
D(v),
|
|
1597
1850
|
void 0,
|
|
1598
1851
|
{ lock: !0 }
|
|
1599
1852
|
]
|
|
@@ -1604,7 +1857,7 @@ const tt = /* @__PURE__ */ Object.assign({ "./add-custom-dom/index.ts": Bn, "./g
|
|
|
1604
1857
|
);
|
|
1605
1858
|
};
|
|
1606
1859
|
}
|
|
1607
|
-
}),
|
|
1860
|
+
}), $l = /* @__PURE__ */ Be(Ll, [["__scopeId", "data-v-3bb806bb"]]), El = {
|
|
1608
1861
|
请输入位置: { "zh-CN": "请输入位置", en: "Please enter location", _appCode: "framework" },
|
|
1609
1862
|
获取地图配置信息失败: {
|
|
1610
1863
|
"zh-CN": "获取地图配置信息失败",
|
|
@@ -1616,16 +1869,26 @@ const tt = /* @__PURE__ */ Object.assign({ "./add-custom-dom/index.ts": Bn, "./g
|
|
|
1616
1869
|
"zh-CN": "第三方地图配置参数错误或地址信息无效,请检查后再重试",
|
|
1617
1870
|
en: "The configuration parameters of the third-party map are incorrect or the address information is invalid. please check and try again",
|
|
1618
1871
|
_appCode: "framework"
|
|
1872
|
+
},
|
|
1873
|
+
"Please-Click-Get-Location": {
|
|
1874
|
+
"zh-CN": "请点击获取位置",
|
|
1875
|
+
en: "Please click get location",
|
|
1876
|
+
_appCode: "framework"
|
|
1877
|
+
},
|
|
1878
|
+
获取定位失败: {
|
|
1879
|
+
"zh-CN": "获取定位失败",
|
|
1880
|
+
en: "Failed to obtain the location",
|
|
1881
|
+
_appCode: "framework"
|
|
1619
1882
|
}
|
|
1620
1883
|
};
|
|
1621
|
-
|
|
1622
|
-
const
|
|
1884
|
+
na(El);
|
|
1885
|
+
const Kl = Ee(ga), Il = () => S(null), Hl = Ee(ma), Jl = () => S(null), Zl = Ee($l), Wl = () => S(null), ql = { title: "Map 地图" };
|
|
1623
1886
|
export {
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1887
|
+
Hl as DasBaiduMap,
|
|
1888
|
+
Jl as DasBaiduMapRef,
|
|
1889
|
+
Kl as DasGaodeMap,
|
|
1890
|
+
Il as DasGaodeMapRef,
|
|
1891
|
+
Zl as DasMap,
|
|
1892
|
+
Wl as DasMapRef,
|
|
1893
|
+
ql as default
|
|
1631
1894
|
};
|