zhihao-ui 1.3.46 → 1.3.50
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/es/{Map-CXkF901e.js → Map-BnrPdkzo.js} +25 -24
- package/dist/es/index.js +1 -1
- package/dist/index.css +1 -1
- package/dist/umd/index.css +1 -1
- package/dist/umd/index.umd.cjs +17 -17
- package/package.json +1 -1
|
@@ -64,13 +64,13 @@ const oo = { id: "scale-line-container" }, no = /* @__PURE__ */ Ue({
|
|
|
64
64
|
shipModelMax: 18,
|
|
65
65
|
//根据原系统canvas图片转换svg长宽比例计算缩放值
|
|
66
66
|
scaleNum: 0.555
|
|
67
|
-
},
|
|
67
|
+
}, ee = {
|
|
68
68
|
// 经纬度 源数据 地理坐标 WGS84
|
|
69
69
|
data: "EPSG:4326",
|
|
70
70
|
// 墨卡托投影坐标 渲染坐标
|
|
71
71
|
mercator: "EPSG:3857"
|
|
72
72
|
}, co = [114.84, 30.52], mt = "https://static.zhihaoscm.cn/", He = 2003750834e-2;
|
|
73
|
-
var xe = ((e) => (e.vectorTile = `https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&TILEMATRIXSET=w&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=${Ae}`, e.vectorTileMark = `https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&TILEMATRIXSET=w&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=${Ae}`, e.satelliteImgTile = `https://t0.tianditu.gov.cn/img_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=img&TILEMATRIXSET=w&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=${Ae}`, e.satelliteImgTileMark = `https://t0.tianditu.gov.cn/cia_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cia&TILEMATRIXSET=w&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=${Ae}`, e.greenTile = `${mt}/map/tile/{z}/{x}/{y}.png`, e))(xe || {}), Ne = /* @__PURE__ */ ((e) => (e[e.M = 1] = "M", e[e.KM = 2] = "KM", e[e.NM = 3] = "NM", e))(Ne || {}),
|
|
73
|
+
var xe = ((e) => (e.vectorTile = `https://t0.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&TILEMATRIXSET=w&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=${Ae}`, e.vectorTileMark = `https://t0.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&TILEMATRIXSET=w&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=${Ae}`, e.satelliteImgTile = `https://t0.tianditu.gov.cn/img_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=img&TILEMATRIXSET=w&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=${Ae}`, e.satelliteImgTileMark = `https://t0.tianditu.gov.cn/cia_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cia&TILEMATRIXSET=w&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=${Ae}`, e.greenTile = `${mt}/map/tile/{z}/{x}/{y}.png`, e))(xe || {}), Ne = /* @__PURE__ */ ((e) => (e[e.M = 1] = "M", e[e.KM = 2] = "KM", e[e.NM = 3] = "NM", e))(Ne || {}), I = /* @__PURE__ */ ((e) => (e.PORT = "port", e.SHIP = "ship", e.TRACK = "track", e))(I || {});
|
|
74
74
|
function ao() {
|
|
75
75
|
const e = ne(), r = () => e.value, n = () => r().getView(), l = () => {
|
|
76
76
|
var g;
|
|
@@ -167,7 +167,7 @@ const nt = function(e, r) {
|
|
|
167
167
|
n[1] - l,
|
|
168
168
|
n[0] + l,
|
|
169
169
|
n[1] + l
|
|
170
|
-
], d = qt(a,
|
|
170
|
+
], d = qt(a, ee.mercator, ee.data);
|
|
171
171
|
return {
|
|
172
172
|
leftTopPoint: { lng: d[0], lat: d[3] },
|
|
173
173
|
rightTopPoint: { lng: d[2], lat: d[3] },
|
|
@@ -228,7 +228,7 @@ const dt = (e) => {
|
|
|
228
228
|
const g = Math.abs(Number(o.lon)) > 180 ? nt(o.lon, o.lat) : [o.lon, o.lat];
|
|
229
229
|
a(o, ie(g));
|
|
230
230
|
const k = e == null ? void 0 : e.getView(), $ = new te(g);
|
|
231
|
-
k.setCenter(Ve($.getCoordinates(),
|
|
231
|
+
k.setCenter(Ve($.getCoordinates(), ee.data, ee.mercator));
|
|
232
232
|
}, a = (o, g) => {
|
|
233
233
|
const k = `${mt}map/car-icon.gif`;
|
|
234
234
|
n || (n = new pe({
|
|
@@ -316,7 +316,7 @@ const yo = (e) => {
|
|
|
316
316
|
// 默认隐藏
|
|
317
317
|
className: `track-layer-${c}`,
|
|
318
318
|
renderBuffer: 1024,
|
|
319
|
-
properties: { layerType:
|
|
319
|
+
properties: { layerType: I.TRACK },
|
|
320
320
|
zIndex: 10
|
|
321
321
|
});
|
|
322
322
|
}, w = (c) => {
|
|
@@ -662,7 +662,7 @@ const yo = (e) => {
|
|
|
662
662
|
id: c,
|
|
663
663
|
length: "--"
|
|
664
664
|
}, y = (n[c] || []).map(
|
|
665
|
-
(R) => Ve([R.lon, R.lat],
|
|
665
|
+
(R) => Ve([R.lon, R.lat], ee.data, ee.mercator)
|
|
666
666
|
), D = new Ge(y);
|
|
667
667
|
return v.length = go(D, f) || "--", v;
|
|
668
668
|
}, $t = (c, f) => {
|
|
@@ -709,8 +709,8 @@ const yo = (e) => {
|
|
|
709
709
|
}).writeGeometry(new Ge(c)), t = new ct({
|
|
710
710
|
factor: 1e6
|
|
711
711
|
}).readGeometry(x, {
|
|
712
|
-
dataProjection:
|
|
713
|
-
featureProjection:
|
|
712
|
+
dataProjection: ee.data,
|
|
713
|
+
featureProjection: ee.mercator
|
|
714
714
|
}), o = new le({
|
|
715
715
|
type: "icon",
|
|
716
716
|
geometry: new te(t.getFirstCoordinate())
|
|
@@ -1118,13 +1118,14 @@ const ft = (e, r) => {
|
|
|
1118
1118
|
className: "zh-map--ship-layer",
|
|
1119
1119
|
renderBuffer: 300,
|
|
1120
1120
|
zIndex: 101,
|
|
1121
|
-
properties: { layerType:
|
|
1121
|
+
properties: { layerType: I.SHIP }
|
|
1122
1122
|
}), d = new ue(), s = new he({
|
|
1123
1123
|
source: d,
|
|
1124
1124
|
className: "zh-map--ship-label-layer",
|
|
1125
1125
|
zIndex: 102,
|
|
1126
1126
|
updateWhileInteracting: !1,
|
|
1127
1127
|
updateWhileAnimating: !1,
|
|
1128
|
+
properties: { layerType: I.SHIP },
|
|
1128
1129
|
declutter: !0
|
|
1129
1130
|
}), h = new ue(), x = new he({
|
|
1130
1131
|
source: h,
|
|
@@ -1253,13 +1254,13 @@ const ft = (e, r) => {
|
|
|
1253
1254
|
try {
|
|
1254
1255
|
if (i) {
|
|
1255
1256
|
const L = i.get("shipData"), F = i.get("id");
|
|
1256
|
-
if (
|
|
1257
|
+
if (T === "click" && (X(L), w && w(F)), T === "hover") {
|
|
1257
1258
|
o && o !== F && q(), o = F;
|
|
1258
1259
|
const Z = l.getFeatures().find((W) => W.get("id") === o);
|
|
1259
1260
|
Z == null || Z.set("isHighlight", !0), Z == null || Z.setStyle(Ee(e, Z));
|
|
1260
1261
|
}
|
|
1261
1262
|
} else
|
|
1262
|
-
|
|
1263
|
+
q();
|
|
1263
1264
|
} catch (L) {
|
|
1264
1265
|
console.log("handleShipMapEvent", L);
|
|
1265
1266
|
}
|
|
@@ -1698,7 +1699,7 @@ const ft = (e, r) => {
|
|
|
1698
1699
|
u && !n && (u.innerHTML += '<span class="delete-icon"><i class="map-iconfont icon-delete" /></div>'), n = N.feature, m.setOffset([10, 0]);
|
|
1699
1700
|
const i = N.feature.getGeometry().getCoordinates(), T = i[0][i[0].length - 2];
|
|
1700
1701
|
if (m.setPosition(T), b != null && b.parentNode && b.parentNode.removeChild(b), (w = r.getProps()) != null && w.areaDrawEnd) {
|
|
1701
|
-
const W = i[0].map((H) => Ve(H,
|
|
1702
|
+
const W = i[0].map((H) => Ve(H, ee.mercator, ee.data));
|
|
1702
1703
|
(F = (L = r.getProps()) == null ? void 0 : L.areaDrawEnd) == null || F.call(L, W);
|
|
1703
1704
|
}
|
|
1704
1705
|
k && (k.setActive(!1), e == null || e.removeInteraction(k), (e == null ? void 0 : e.getInteractions()).forEach((H) => {
|
|
@@ -1754,7 +1755,7 @@ const ft = (e, r) => {
|
|
|
1754
1755
|
zIndex: 100,
|
|
1755
1756
|
updateWhileInteracting: !0,
|
|
1756
1757
|
updateWhileAnimating: !0,
|
|
1757
|
-
properties: { layerType:
|
|
1758
|
+
properties: { layerType: I.PORT }
|
|
1758
1759
|
});
|
|
1759
1760
|
e == null || e.addLayer(n);
|
|
1760
1761
|
let l = null, a = null;
|
|
@@ -1883,28 +1884,28 @@ const ft = (e, r) => {
|
|
|
1883
1884
|
}
|
|
1884
1885
|
});
|
|
1885
1886
|
const x = {
|
|
1886
|
-
[
|
|
1887
|
-
[
|
|
1888
|
-
[
|
|
1887
|
+
[I.PORT]: null,
|
|
1888
|
+
[I.SHIP]: null,
|
|
1889
|
+
[I.TRACK]: null
|
|
1889
1890
|
}, t = (g, k, $) => {
|
|
1890
1891
|
switch (ve(h, "pointer"), g) {
|
|
1891
|
-
case
|
|
1892
|
+
case I.SHIP:
|
|
1892
1893
|
l == null || l.handleShipMapEvent(k, "hover");
|
|
1893
1894
|
break;
|
|
1894
|
-
case
|
|
1895
|
+
case I.PORT:
|
|
1895
1896
|
break;
|
|
1896
|
-
case
|
|
1897
|
+
case I.TRACK:
|
|
1897
1898
|
n == null || n.handleTrackMapEvent(k, "hover", $);
|
|
1898
1899
|
break;
|
|
1899
1900
|
}
|
|
1900
1901
|
}, o = (g) => {
|
|
1901
1902
|
switch (ve(h, "grab"), g) {
|
|
1902
|
-
case
|
|
1903
|
+
case I.PORT:
|
|
1903
1904
|
break;
|
|
1904
|
-
case
|
|
1905
|
+
case I.SHIP:
|
|
1905
1906
|
l == null || l.handleShipMapEvent(null, "hover");
|
|
1906
1907
|
break;
|
|
1907
|
-
case
|
|
1908
|
+
case I.TRACK:
|
|
1908
1909
|
n == null || n.handleTrackMapEvent(null, "hover");
|
|
1909
1910
|
break;
|
|
1910
1911
|
}
|
|
@@ -1974,7 +1975,7 @@ const ft = (e, r) => {
|
|
|
1974
1975
|
const t = yo(s), o = vo(s, t), g = To(s), k = Fo(s), $ = Ro(s, x), C = $o(s, x), z = zo(s);
|
|
1975
1976
|
Oo(d, x, t, g, z, $, C);
|
|
1976
1977
|
const u = () => {
|
|
1977
|
-
const P = s.getView().calculateExtent(d.getSize()), b = Ve([P[0], P[1]],
|
|
1978
|
+
const P = s.getView().calculateExtent(d.getSize()), b = Ve([P[0], P[1]], ee.mercator, ee.data), V = Ve([P[2], P[3]], ee.mercator, ee.data);
|
|
1978
1979
|
return [b[0], b[1], V[0], V[1]];
|
|
1979
1980
|
}, m = {
|
|
1980
1981
|
id: Symbol("map-instance"),
|
|
@@ -2273,7 +2274,7 @@ const ft = (e, r) => {
|
|
|
2273
2274
|
}, null, 8, ["map-instance"])
|
|
2274
2275
|
]));
|
|
2275
2276
|
}
|
|
2276
|
-
}), Go = /* @__PURE__ */ ot(Ao, [["__scopeId", "data-v-
|
|
2277
|
+
}), Go = /* @__PURE__ */ ot(Ao, [["__scopeId", "data-v-a0c7f7b1"]]), Xo = to(Go);
|
|
2277
2278
|
export {
|
|
2278
2279
|
Xo as Z
|
|
2279
2280
|
};
|
package/dist/es/index.js
CHANGED
|
@@ -17,7 +17,7 @@ import { Z as B } from "./BaseInfo-Cu3ME-K_.js";
|
|
|
17
17
|
import { Z as g } from "./DetailHeader-DTHE-pQa.js";
|
|
18
18
|
import { Z as x } from "./DiyDataTable-BQaaClFf.js";
|
|
19
19
|
import { D as V } from "./DiyDataTable-BQaaClFf.js";
|
|
20
|
-
import { Z as G } from "./Map-
|
|
20
|
+
import { Z as G } from "./Map-BnrPdkzo.js";
|
|
21
21
|
import { Z as M } from "./Table-CzNjEPnP.js";
|
|
22
22
|
import { Z as $ } from "./BaseItem-Co7KlYD6.js";
|
|
23
23
|
const A = [
|