@idmwx/idmui-gl3 4.4.3 → 4.4.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +243 -219
- package/dist/index.umd.cjs +4 -4
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var at = Object.defineProperty;
|
|
2
2
|
var it = (a, e, t) => e in a ? at(a, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : a[e] = t;
|
|
3
3
|
var R = (a, e, t) => (it(a, typeof e != "symbol" ? e + "" : e, t), t);
|
|
4
|
-
import { resolveComponent as
|
|
4
|
+
import { resolveComponent as z, openBlock as x, createElementBlock as C, createElementVNode as l, normalizeStyle as U, createVNode as k, withCtx as Y, normalizeClass as N, Fragment as Ae, renderList as $e, toDisplayString as S, createCommentVNode as j, createTextVNode as Fe, pushScopeId as H, popScopeId as G, withDirectives as je, vShow as Ne, createStaticVNode as rt, mergeProps as E } from "vue";
|
|
5
5
|
import * as L from "@turf/turf";
|
|
6
6
|
import ot from "@mapbox/sphericalmercator";
|
|
7
7
|
import Z from "moment";
|
|
@@ -646,7 +646,8 @@ const T = (a, e) => {
|
|
|
646
646
|
/* @__PURE__ */ l("i", { class: "iconfont close" }, "")
|
|
647
647
|
], -1), Ot = { class: "source-layers card-bg" }, Ft = /* @__PURE__ */ l("span", { class: "layers-title" }, "Forecast Model", -1), Vt = { class: "layers-body" };
|
|
648
648
|
function Ut(a, e, t, r, i, o) {
|
|
649
|
-
|
|
649
|
+
var p;
|
|
650
|
+
const s = z("ElTooltip"), n = z("ElRadio"), c = z("ElRadioGroup"), d = z("ElScrollbar");
|
|
650
651
|
return x(), C("div", ct, [
|
|
651
652
|
l("div", {
|
|
652
653
|
class: "menu-bar-box",
|
|
@@ -656,11 +657,12 @@ function Ut(a, e, t, r, i, o) {
|
|
|
656
657
|
k(s, {
|
|
657
658
|
placement: "left",
|
|
658
659
|
effect: "light",
|
|
659
|
-
content: "Menu"
|
|
660
|
+
content: "Menu",
|
|
661
|
+
"show-after": 2e3
|
|
660
662
|
}, {
|
|
661
|
-
default:
|
|
663
|
+
default: Y(() => [
|
|
662
664
|
l("div", {
|
|
663
|
-
class:
|
|
665
|
+
class: N(t.layerToggle ? "menu-icon active" : "menu-icon"),
|
|
664
666
|
onClick: e[0] || (e[0] = (...h) => o.handleMenuToggle && o.handleMenuToggle(...h))
|
|
665
667
|
}, pt, 2)
|
|
666
668
|
]),
|
|
@@ -678,9 +680,9 @@ function Ut(a, e, t, r, i, o) {
|
|
|
678
680
|
effect: "light",
|
|
679
681
|
content: "Measure"
|
|
680
682
|
}, {
|
|
681
|
-
default:
|
|
683
|
+
default: Y(() => [
|
|
682
684
|
l("div", {
|
|
683
|
-
class:
|
|
685
|
+
class: N(i.showMeasure ? "menu-icon active" : "menu-icon"),
|
|
684
686
|
onClick: e[1] || (e[1] = (...h) => o.handleMeasureToggle && o.handleMeasureToggle(...h))
|
|
685
687
|
}, yt, 2)
|
|
686
688
|
]),
|
|
@@ -691,9 +693,9 @@ function Ut(a, e, t, r, i, o) {
|
|
|
691
693
|
effect: "light",
|
|
692
694
|
content: "Point Meteo"
|
|
693
695
|
}, {
|
|
694
|
-
default:
|
|
696
|
+
default: Y(() => [
|
|
695
697
|
l("div", {
|
|
696
|
-
class:
|
|
698
|
+
class: N(i.showPoint ? "menu-icon active" : "menu-icon"),
|
|
697
699
|
onClick: e[2] || (e[2] = (...h) => o.handlePointToggle && o.handlePointToggle(...h))
|
|
698
700
|
}, gt, 2)
|
|
699
701
|
]),
|
|
@@ -704,9 +706,9 @@ function Ut(a, e, t, r, i, o) {
|
|
|
704
706
|
effect: "light",
|
|
705
707
|
content: "Grid"
|
|
706
708
|
}, {
|
|
707
|
-
default:
|
|
709
|
+
default: Y(() => [
|
|
708
710
|
l("div", {
|
|
709
|
-
class:
|
|
711
|
+
class: N(i.showCoord ? "menu-icon active" : "menu-icon"),
|
|
710
712
|
onClick: e[3] || (e[3] = (...h) => o.handleCoordToggle && o.handleCoordToggle(...h))
|
|
711
713
|
}, vt, 2)
|
|
712
714
|
]),
|
|
@@ -717,9 +719,9 @@ function Ut(a, e, t, r, i, o) {
|
|
|
717
719
|
effect: "light",
|
|
718
720
|
content: "3D"
|
|
719
721
|
}, {
|
|
720
|
-
default:
|
|
722
|
+
default: Y(() => [
|
|
721
723
|
l("div", {
|
|
722
|
-
class:
|
|
724
|
+
class: N(i.show3d ? "menu-icon active" : "menu-icon"),
|
|
723
725
|
onClick: e[4] || (e[4] = (...h) => o.handle3DToggle && o.handle3DToggle(...h))
|
|
724
726
|
}, _t, 2)
|
|
725
727
|
]),
|
|
@@ -727,25 +729,26 @@ function Ut(a, e, t, r, i, o) {
|
|
|
727
729
|
})
|
|
728
730
|
])
|
|
729
731
|
], 4),
|
|
730
|
-
|
|
732
|
+
((p = i.layers.weather.filter((h) => h.collected)) == null ? void 0 : p.length) > 0 ? (x(), C("div", {
|
|
733
|
+
key: 0,
|
|
731
734
|
class: "active-layers",
|
|
732
735
|
style: U({ right: i.right + "px", bottom: "100px" })
|
|
733
736
|
}, [
|
|
734
737
|
(x(!0), C(Ae, null, $e(i.layers.weather.filter((h) => h.collected), (h) => (x(), C("div", {
|
|
735
738
|
key: h.key,
|
|
736
|
-
class:
|
|
737
|
-
onClick: (
|
|
739
|
+
class: N(o.computeLayerClass(h, i.activeWeatherLayers)),
|
|
740
|
+
onClick: (g) => o.handleActiveWeatherLayerPick(h)
|
|
738
741
|
}, [
|
|
739
742
|
xt,
|
|
740
743
|
l("span", null, S(h.name), 1)
|
|
741
744
|
], 10, Lt))), 128))
|
|
742
|
-
], 4),
|
|
745
|
+
], 4)) : j("", !0),
|
|
743
746
|
l("div", {
|
|
744
747
|
class: "available-layers flex-center",
|
|
745
748
|
style: U({ top: t.top + "px", right: t.layerToggle ? "0px" : "-240px" })
|
|
746
749
|
}, [
|
|
747
750
|
l("div", {
|
|
748
|
-
class:
|
|
751
|
+
class: N(["list-box", t.layerToggle ? "right-bar" : ""])
|
|
749
752
|
}, [
|
|
750
753
|
l("div", Ct, [
|
|
751
754
|
kt,
|
|
@@ -755,26 +758,26 @@ function Ut(a, e, t, r, i, o) {
|
|
|
755
758
|
}, "")
|
|
756
759
|
]),
|
|
757
760
|
k(d, { style: { flex: "1" } }, {
|
|
758
|
-
default:
|
|
761
|
+
default: Y(() => [
|
|
759
762
|
l("div", St, [
|
|
760
763
|
zt,
|
|
761
764
|
l("div", Pt, [
|
|
762
765
|
(x(!0), C(Ae, null, $e(i.layers.weather, (h) => (x(), C(Ae, {
|
|
763
766
|
key: h.key
|
|
764
767
|
}, [
|
|
765
|
-
h.hide ?
|
|
768
|
+
h.hide ? j("", !0) : (x(), C("div", {
|
|
766
769
|
key: 0,
|
|
767
|
-
class:
|
|
770
|
+
class: N(o.computeLayerClass(h, i.weatherLayers))
|
|
768
771
|
}, [
|
|
769
772
|
l("div", {
|
|
770
773
|
class: "flex-start",
|
|
771
|
-
onClick: (
|
|
774
|
+
onClick: (g) => o.handleWeatherLayerPick(h)
|
|
772
775
|
}, [
|
|
773
776
|
It,
|
|
774
777
|
l("span", null, S(h.name), 1)
|
|
775
778
|
], 8, Tt),
|
|
776
779
|
l("div", {
|
|
777
|
-
onClick: (
|
|
780
|
+
onClick: (g) => o.handleWeatherLayerCollect(h)
|
|
778
781
|
}, [
|
|
779
782
|
h.collected ? (x(), C("i", Rt, "")) : (x(), C("i", At, ""))
|
|
780
783
|
], 8, Et)
|
|
@@ -788,8 +791,8 @@ function Ut(a, e, t, r, i, o) {
|
|
|
788
791
|
l("div", jt, [
|
|
789
792
|
(x(!0), C(Ae, null, $e(i.layers.other, (h) => (x(), C("div", {
|
|
790
793
|
key: h.key,
|
|
791
|
-
class:
|
|
792
|
-
onClick: (
|
|
794
|
+
class: N(o.computeLayerClass(h, i.otherLayers)),
|
|
795
|
+
onClick: (g) => o.handleOtherLayerPick(h)
|
|
793
796
|
}, [
|
|
794
797
|
l("div", Bt, [
|
|
795
798
|
Wt,
|
|
@@ -806,15 +809,15 @@ function Ut(a, e, t, r, i, o) {
|
|
|
806
809
|
"onUpdate:modelValue": e[6] || (e[6] = (h) => i.source = h),
|
|
807
810
|
class: "layer-radio flex-col-center-start"
|
|
808
811
|
}, {
|
|
809
|
-
default:
|
|
812
|
+
default: Y(() => [
|
|
810
813
|
k(n, { value: "GFS" }, {
|
|
811
|
-
default:
|
|
814
|
+
default: Y(() => [
|
|
812
815
|
Fe("GFS")
|
|
813
816
|
]),
|
|
814
817
|
_: 1
|
|
815
818
|
}),
|
|
816
819
|
k(n, { value: "CMEMS" }, {
|
|
817
|
-
default:
|
|
820
|
+
default: Y(() => [
|
|
818
821
|
Fe("CMEMS")
|
|
819
822
|
]),
|
|
820
823
|
_: 1
|
|
@@ -893,7 +896,7 @@ const Ht = {
|
|
|
893
896
|
toggleVersion: {
|
|
894
897
|
handler() {
|
|
895
898
|
var a, e, t, r;
|
|
896
|
-
this.right = (((a = document.getElementsByClassName("right-bar")[0]) == null ? void 0 : a.clientWidth) || 0) + 10, this.bottom = (e = this.current) != null && e.active ? (((t = document.getElementsByClassName("active-layers")[0]) == null ? void 0 : t.clientHeight) || 0) +
|
|
899
|
+
this.right = (((a = document.getElementsByClassName("right-bar")[0]) == null ? void 0 : a.clientWidth) || 0) + 10, this.bottom = (e = this.current) != null && e.active ? (((t = document.getElementsByClassName("active-layers")[0]) == null ? void 0 : t.clientHeight) || 0) + 148 : (((r = document.getElementsByClassName("active-layers")[0]) == null ? void 0 : r.clientHeight) || 0) + 110;
|
|
897
900
|
},
|
|
898
901
|
immediate: !0
|
|
899
902
|
}
|
|
@@ -916,22 +919,22 @@ const Ht = {
|
|
|
916
919
|
else {
|
|
917
920
|
this.map.addSource(this.source, { type: "geojson", data: n });
|
|
918
921
|
for (let c = 0; c < (this.barbs ?? []).length - 1; c++) {
|
|
919
|
-
const d = (this.barbs ?? [])[c] || 0,
|
|
922
|
+
const d = (this.barbs ?? [])[c] || 0, p = (this.barbs ?? [])[c + 1] || 0, h = d < 10 ? `00${d}kts` : d < 100 ? `0${d}kts` : `${d}kts`;
|
|
920
923
|
this.map.addLayer(
|
|
921
924
|
{
|
|
922
|
-
id:
|
|
925
|
+
id: h,
|
|
923
926
|
type: "symbol",
|
|
924
927
|
filter: [
|
|
925
928
|
"all",
|
|
926
929
|
// @ts-ignore
|
|
927
930
|
[">=", "spd", d],
|
|
928
931
|
// @ts-ignore
|
|
929
|
-
["<", "spd",
|
|
932
|
+
["<", "spd", p]
|
|
930
933
|
],
|
|
931
934
|
source: this.source,
|
|
932
935
|
layout: {
|
|
933
936
|
"symbol-placement": "point",
|
|
934
|
-
"icon-image":
|
|
937
|
+
"icon-image": h,
|
|
935
938
|
// mapbox sprite
|
|
936
939
|
"icon-size": 0.14,
|
|
937
940
|
"icon-offset": [0, -20],
|
|
@@ -990,15 +993,15 @@ function ea(a, e, t, r, i, o) {
|
|
|
990
993
|
}, [
|
|
991
994
|
t.mapProjection === "mercator" ? (x(), C("div", {
|
|
992
995
|
key: 0,
|
|
993
|
-
class:
|
|
996
|
+
class: N(["item-bar flex-start", t.showParticle ? "active" : "inactive"]),
|
|
994
997
|
onClick: e[0] || (e[0] = (...n) => o.handleParticle && o.handleParticle(...n))
|
|
995
|
-
}, Yt, 2)) :
|
|
998
|
+
}, Yt, 2)) : j("", !0),
|
|
996
999
|
l("div", {
|
|
997
|
-
class:
|
|
1000
|
+
class: N(["item-bar flex-start", i.showFeather ? "active" : "inactive"]),
|
|
998
1001
|
onClick: e[1] || (e[1] = (n) => i.showFeather = !i.showFeather)
|
|
999
1002
|
}, Kt, 2)
|
|
1000
1003
|
], 4)
|
|
1001
|
-
])) :
|
|
1004
|
+
])) : j("", !0);
|
|
1002
1005
|
}
|
|
1003
1006
|
const ta = /* @__PURE__ */ T(Ht, [["render", ea]]);
|
|
1004
1007
|
class Ve {
|
|
@@ -1046,8 +1049,8 @@ class Ve {
|
|
|
1046
1049
|
* @param [lb.x, lb.y, rt.x, rt.y]
|
|
1047
1050
|
*/
|
|
1048
1051
|
getBoundPixel() {
|
|
1049
|
-
const e = this.map.getBounds(), t = this.map.getZoom() + 1, r = [e._ne.lng, e._ne.lat], i = [e._sw.lng, e._sw.lat], [o, s] = this.convertNLng(r[0]), [n, c] = this.convertNLng(i[0]), [d,
|
|
1050
|
-
return [
|
|
1052
|
+
const e = this.map.getBounds(), t = this.map.getZoom() + 1, r = [e._ne.lng, e._ne.lat], i = [e._sw.lng, e._sw.lat], [o, s] = this.convertNLng(r[0]), [n, c] = this.convertNLng(i[0]), [d, p] = this.mercator.px([o, r[1]], t), [h, g] = this.mercator.px([n, i[1]], t), u = Math.round(this.mercator.size * Math.pow(2, t) * (s + c));
|
|
1053
|
+
return [h, g, d + u, p];
|
|
1051
1054
|
}
|
|
1052
1055
|
/**
|
|
1053
1056
|
* [视窗边界像素宽度]
|
|
@@ -1062,13 +1065,13 @@ class Ve {
|
|
|
1062
1065
|
* @param zoom
|
|
1063
1066
|
*/
|
|
1064
1067
|
getWorldCopy(e, t) {
|
|
1065
|
-
const r = 2 ** t, [i, o, s, n] = e.map((
|
|
1066
|
-
for (let
|
|
1067
|
-
for (let
|
|
1068
|
-
c.push([
|
|
1069
|
-
return c.map((
|
|
1070
|
-
const
|
|
1071
|
-
return [
|
|
1068
|
+
const r = 2 ** t, [i, o, s, n] = e.map((p) => ~~(p / (r * 256))), c = [];
|
|
1069
|
+
for (let p = n; p <= o; p++)
|
|
1070
|
+
for (let h = i; h <= s; h++)
|
|
1071
|
+
c.push([h, p]);
|
|
1072
|
+
return c.map((p) => {
|
|
1073
|
+
const h = 2 ** t * 256;
|
|
1074
|
+
return [p[0] * h, p[1] * h, h];
|
|
1072
1075
|
});
|
|
1073
1076
|
}
|
|
1074
1077
|
resize() {
|
|
@@ -1171,8 +1174,8 @@ class Le {
|
|
|
1171
1174
|
const n = s.getContext("2d");
|
|
1172
1175
|
if (n && e) {
|
|
1173
1176
|
const c = n == null ? void 0 : n.createLinearGradient(0, 0, 256, 0);
|
|
1174
|
-
return t.forEach(([d,
|
|
1175
|
-
c.addColorStop(d,
|
|
1177
|
+
return t.forEach(([d, p]) => {
|
|
1178
|
+
c.addColorStop(d, p);
|
|
1176
1179
|
}), n.fillStyle = c, n.fillRect(0, 0, 256, 1), {
|
|
1177
1180
|
canvas: s,
|
|
1178
1181
|
texture: this.createTexture(
|
|
@@ -1189,11 +1192,11 @@ class Le {
|
|
|
1189
1192
|
}
|
|
1190
1193
|
setupParticle(e, t = 1e3) {
|
|
1191
1194
|
const r = Math.ceil(Math.sqrt(t)), i = r * r, o = new Uint8Array(i * 4);
|
|
1192
|
-
for (let
|
|
1193
|
-
o[
|
|
1195
|
+
for (let p = 0; p < o.length; p++)
|
|
1196
|
+
o[p] = Math.floor(Math.random() * 256);
|
|
1194
1197
|
const s = this.createTexture(e, e.NEAREST, e.NEAREST, e.CLAMP_TO_EDGE, o, r, r), n = this.createTexture(e, e.NEAREST, e.NEAREST, e.CLAMP_TO_EDGE, o, r, r), c = new Float32Array(i);
|
|
1195
|
-
for (let
|
|
1196
|
-
c[
|
|
1198
|
+
for (let p = 0; p < i; p++)
|
|
1199
|
+
c[p] = p;
|
|
1197
1200
|
const d = this.createDataBuffer(e, "array", c);
|
|
1198
1201
|
return { resolution: r, total: i, texture0: s, texture1: n, indexBuffer: d };
|
|
1199
1202
|
}
|
|
@@ -1210,26 +1213,26 @@ class Le {
|
|
|
1210
1213
|
return {};
|
|
1211
1214
|
}
|
|
1212
1215
|
bindParticle(e, t, r, i, o, s) {
|
|
1213
|
-
const n = this.createProgramWrapper(e, t, r), c = this.createProgramWrapper(e, i, o), d = this.createProgramWrapper(e, i, s),
|
|
1214
|
-
return { particle: n, screen: c, update: d, quadBuffer:
|
|
1216
|
+
const n = this.createProgramWrapper(e, t, r), c = this.createProgramWrapper(e, i, o), d = this.createProgramWrapper(e, i, s), p = this.createDataBuffer(e, "array", new Float32Array([0, 0, 1, 0, 0, 1, 0, 1, 1, 0, 1, 1])), h = e.createFramebuffer();
|
|
1217
|
+
return { particle: n, screen: c, update: d, quadBuffer: p, frameBuffer: h };
|
|
1215
1218
|
}
|
|
1216
1219
|
draw(e, t, r, i, o, s, n) {
|
|
1217
1220
|
var c, d;
|
|
1218
1221
|
if (t && r) {
|
|
1219
1222
|
e.resize(), t == null || t.viewport(0, 0, (c = t == null ? void 0 : t.canvas) == null ? void 0 : c.width, (d = t == null ? void 0 : t.canvas) == null ? void 0 : d.height), t.clearColor(0, 0, 0, 0), t.clear(t.COLOR_BUFFER_BIT | t.DEPTH_BUFFER_BIT);
|
|
1220
1223
|
try {
|
|
1221
|
-
const
|
|
1222
|
-
if (t.useProgram(r), t.uniform2f(
|
|
1224
|
+
const p = t.getUniformLocation(r, "u_resolution"), h = t.getUniformLocation(r, "u_image"), g = t.getUniformLocation(r, "u_color");
|
|
1225
|
+
if (t.useProgram(r), t.uniform2f(p, t.canvas.width * e.ratio, t.canvas.height * e.ratio), t.activeTexture(t.TEXTURE0), t.bindTexture(t.TEXTURE_2D, i), t.uniform1i(h, 0), t.activeTexture(t.TEXTURE1), t.bindTexture(t.TEXTURE_2D, o), t.uniform1i(g, 1), n != null && n.uvRange && (n != null && n.sRange)) {
|
|
1223
1226
|
const m = t.getUniformLocation(r, "u_range_u_v"), v = t.getUniformLocation(r, "u_range_s");
|
|
1224
1227
|
t.uniform2f(m, n.uvRange[0], n.uvRange[1]), t.uniform2f(v, n.sRange[0], n.sRange[1]);
|
|
1225
1228
|
}
|
|
1226
1229
|
const u = e.getBoundPixel(), y = e.map.getZoom() + 1, f = e.getWorldCopy(u, y);
|
|
1227
1230
|
for (const m of f) {
|
|
1228
|
-
const v = (m[0] - u[0]) * e.ratio, b = (m[1] - u[3]) * e.ratio, _ = m[2] * e.ratio, [
|
|
1231
|
+
const v = (m[0] - u[0]) * e.ratio, b = (m[1] - u[3]) * e.ratio, _ = m[2] * e.ratio, [P, w, A, M] = [v, _ + v, b, _ + b], $ = new Float32Array([P, A, w, A, P, M, P, M, w, A, w, M]);
|
|
1229
1232
|
t.bindBuffer(t.ARRAY_BUFFER, s), t.bufferData(t.ARRAY_BUFFER, $, t.STATIC_DRAW), t.drawArrays(t.TRIANGLES, 0, 6);
|
|
1230
1233
|
}
|
|
1231
|
-
} catch (
|
|
1232
|
-
console.log(`render failed...${
|
|
1234
|
+
} catch (p) {
|
|
1235
|
+
console.log(`render failed...${p}`);
|
|
1233
1236
|
}
|
|
1234
1237
|
}
|
|
1235
1238
|
}
|
|
@@ -1274,10 +1277,10 @@ class Le {
|
|
|
1274
1277
|
});
|
|
1275
1278
|
}
|
|
1276
1279
|
}
|
|
1277
|
-
class
|
|
1280
|
+
class B {
|
|
1278
1281
|
}
|
|
1279
1282
|
// 顶点渲染
|
|
1280
|
-
R(
|
|
1283
|
+
R(B, "vertexSchema", `
|
|
1281
1284
|
//canvas 坐标系上的坐标 (x, y)
|
|
1282
1285
|
attribute vec2 a_position; //像素坐标
|
|
1283
1286
|
attribute vec2 a_texCoord; //纹理坐标
|
|
@@ -1292,7 +1295,7 @@ R(N, "vertexSchema", `
|
|
|
1292
1295
|
gl_Position = vec4(position * vec2(1, -1), 0.0, 1.0);
|
|
1293
1296
|
v_texCoord = a_texCoord;
|
|
1294
1297
|
}`), // 类如风、流等u v双变量片元渲染
|
|
1295
|
-
R(
|
|
1298
|
+
R(B, "uvFragmentSchema", `
|
|
1296
1299
|
precision mediump float;
|
|
1297
1300
|
uniform sampler2D u_image;
|
|
1298
1301
|
uniform vec2 u_range_u_v;
|
|
@@ -1311,7 +1314,7 @@ R(N, "uvFragmentSchema", `
|
|
|
1311
1314
|
|
|
1312
1315
|
gl_FragColor = color;
|
|
1313
1316
|
}`), // 类如浪、气压等单变量片元渲染
|
|
1314
|
-
R(
|
|
1317
|
+
R(B, "fragmentSchema", `
|
|
1315
1318
|
precision mediump float;
|
|
1316
1319
|
uniform sampler2D u_image; // 灰度
|
|
1317
1320
|
uniform sampler2D u_color; // 色值映射
|
|
@@ -3189,7 +3192,7 @@ const ia = {
|
|
|
3189
3192
|
[1, "rgb(91, 136, 161)"]
|
|
3190
3193
|
];
|
|
3191
3194
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
3192
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
3195
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.uvFragmentSchema);
|
|
3193
3196
|
this.program = e, this.aPositionBuffer = t;
|
|
3194
3197
|
}
|
|
3195
3198
|
this.handleParticleSetup();
|
|
@@ -3254,7 +3257,7 @@ function ua(a, e, t, r, i, o) {
|
|
|
3254
3257
|
class: "legend-bars flex-center",
|
|
3255
3258
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
3256
3259
|
}, ma, 4)
|
|
3257
|
-
])) :
|
|
3260
|
+
])) : j("", !0);
|
|
3258
3261
|
}
|
|
3259
3262
|
const ya = /* @__PURE__ */ T(ia, [["render", ua], ["__scopeId", "data-v-64887571"]]);
|
|
3260
3263
|
const fa = {
|
|
@@ -3320,7 +3323,7 @@ const fa = {
|
|
|
3320
3323
|
toggleVersion: {
|
|
3321
3324
|
handler() {
|
|
3322
3325
|
var a, e;
|
|
3323
|
-
this.right = (((a = document.getElementsByClassName("right-bar")[0]) == null ? void 0 : a.clientWidth) || 0) + 10, this.bottom = (((e = document.getElementsByClassName("active-layers")[0]) == null ? void 0 : e.clientHeight) || 0) +
|
|
3326
|
+
this.right = (((a = document.getElementsByClassName("right-bar")[0]) == null ? void 0 : a.clientWidth) || 0) + 10, this.bottom = (((e = document.getElementsByClassName("active-layers")[0]) == null ? void 0 : e.clientHeight) || 0) + 110;
|
|
3324
3327
|
},
|
|
3325
3328
|
immediate: !0
|
|
3326
3329
|
}
|
|
@@ -3423,15 +3426,15 @@ function Ca(a, e, t, r, i, o) {
|
|
|
3423
3426
|
}, [
|
|
3424
3427
|
t.mapProjection === "mercator" ? (x(), C("div", {
|
|
3425
3428
|
key: 0,
|
|
3426
|
-
class:
|
|
3429
|
+
class: N(["flex-start item-bar", t.showParticle ? "active" : "inactive"]),
|
|
3427
3430
|
onClick: e[0] || (e[0] = (n) => o.handleParticle(!t.showParticle))
|
|
3428
|
-
}, wa, 2)) :
|
|
3431
|
+
}, wa, 2)) : j("", !0),
|
|
3429
3432
|
l("div", {
|
|
3430
|
-
class:
|
|
3433
|
+
class: N(["flex-start item-bar", i.showJson ? "active" : "inactive"]),
|
|
3431
3434
|
onClick: e[1] || (e[1] = (n) => i.showJson = !i.showJson)
|
|
3432
3435
|
}, xa, 2)
|
|
3433
3436
|
], 4)
|
|
3434
|
-
])) :
|
|
3437
|
+
])) : j("", !0);
|
|
3435
3438
|
}
|
|
3436
3439
|
const ka = /* @__PURE__ */ T(fa, [["render", Ca]]);
|
|
3437
3440
|
const Sa = {
|
|
@@ -3539,7 +3542,7 @@ const Sa = {
|
|
|
3539
3542
|
[1, "rgb(195,194,194)"]
|
|
3540
3543
|
];
|
|
3541
3544
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
3542
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
3545
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.uvFragmentSchema);
|
|
3543
3546
|
this.program = e, this.aPositionBuffer = t;
|
|
3544
3547
|
}
|
|
3545
3548
|
this.handleParticleSetup();
|
|
@@ -3607,7 +3610,7 @@ function $a(a, e, t, r, i, o) {
|
|
|
3607
3610
|
class: "legend-bars flex-center",
|
|
3608
3611
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
3609
3612
|
}, Ma, 4)
|
|
3610
|
-
])) :
|
|
3613
|
+
])) : j("", !0);
|
|
3611
3614
|
}
|
|
3612
3615
|
const ja = /* @__PURE__ */ T(Sa, [["render", $a], ["__scopeId", "data-v-6d4fd206"]]), Na = {
|
|
3613
3616
|
name: "IdmSigWave",
|
|
@@ -4145,24 +4148,24 @@ const Ya = {
|
|
|
4145
4148
|
}), t.forEach((o) => {
|
|
4146
4149
|
var d;
|
|
4147
4150
|
let s = 0, n;
|
|
4148
|
-
const c = a.filter((
|
|
4149
|
-
var
|
|
4150
|
-
return ((g = (
|
|
4151
|
+
const c = a.filter((p) => {
|
|
4152
|
+
var h, g;
|
|
4153
|
+
return ((g = (h = p.properties) == null ? void 0 : h.category) == null ? void 0 : g.split("-")[0]) === o;
|
|
4151
4154
|
});
|
|
4152
|
-
(d = c.filter((
|
|
4153
|
-
var
|
|
4154
|
-
return ((
|
|
4155
|
-
})[0]) == null || d.properties.model, c.forEach((
|
|
4155
|
+
(d = c.filter((p) => {
|
|
4156
|
+
var h, g;
|
|
4157
|
+
return ((h = p.geometry) == null ? void 0 : h.type) === "LineString" && ((g = p.properties) == null ? void 0 : g.type) === "forecast";
|
|
4158
|
+
})[0]) == null || d.properties.model, c.forEach((p, h) => {
|
|
4156
4159
|
var g, u, y, f, m, v;
|
|
4157
|
-
((g =
|
|
4158
|
-
}), c.map((
|
|
4160
|
+
((g = p.geometry) == null ? void 0 : g.type) === "Point" && ((u = p.properties) == null ? void 0 : u.type) === "history" && (s = h, n = n === void 0 ? h : n), ((y = p.geometry) == null ? void 0 : y.type) === "Point" && ((f = p.properties) == null ? void 0 : f.type) === "forecast" && n === void 0 && (n = h), ((m = p.geometry) == null ? void 0 : m.type) === "LineString" && ((v = p.properties) == null || v.type);
|
|
4161
|
+
}), c.map((p, h) => {
|
|
4159
4162
|
var g, u, y, f, m, v, b;
|
|
4160
|
-
if (((g =
|
|
4161
|
-
|
|
4162
|
-
const _ = Z((b =
|
|
4163
|
-
|
|
4163
|
+
if (((g = p.geometry) == null ? void 0 : g.type) === "LineString" && ((u = p.properties) == null || u.type), ((y = p.geometry) == null ? void 0 : y.type) === "Point" && ((f = p.properties) == null ? void 0 : f.type) === "forecast" && (p.properties.name = o, p.properties.format = Z(p.properties.date).utcOffset(this.timeZone).format(`MMM-DD,HHmm [(utc ${this.computeTimezone})]`)), ((m = p.geometry) == null ? void 0 : m.type) === "Point" && ((v = p.properties) == null ? void 0 : v.type) === "history") {
|
|
4164
|
+
p.properties.format = Z(p.properties.date).utcOffset(this.timeZone).format(`MMM-DD,HHmm [(utc ${this.computeTimezone})]`);
|
|
4165
|
+
const _ = Z((b = p.properties) == null ? void 0 : b.date).utc().format("HHmm") === Z().utc().hour(Math.floor(e / 6) * 6).minute("00").format("HHmm");
|
|
4166
|
+
p.properties.showHistoryLabel = _ || h === s, p.properties.showNameLabel = h === s, p.properties.name = o;
|
|
4164
4167
|
}
|
|
4165
|
-
return
|
|
4168
|
+
return p;
|
|
4166
4169
|
});
|
|
4167
4170
|
}), this.handleInit();
|
|
4168
4171
|
},
|
|
@@ -4423,10 +4426,10 @@ const Ya = {
|
|
|
4423
4426
|
}), y = (/* @__PURE__ */ new Date()).valueOf() - (g + u), console.log("[tropical] add elapsed: ", y, ", total: ", u += y));
|
|
4424
4427
|
}
|
|
4425
4428
|
this.handleDrawCircle();
|
|
4426
|
-
const
|
|
4427
|
-
this.interpolateData = JSON.parse(JSON.stringify(
|
|
4428
|
-
const
|
|
4429
|
-
console.log(
|
|
4429
|
+
const p = Qe.interpolate(this.tropicals, 1);
|
|
4430
|
+
this.interpolateData = JSON.parse(JSON.stringify(p));
|
|
4431
|
+
const h = this.interpolateData.filter((g) => g.properties.name === "kristy" && g.properties.model === "ecmwf");
|
|
4432
|
+
console.log(h), this.handleDateChange();
|
|
4430
4433
|
}
|
|
4431
4434
|
},
|
|
4432
4435
|
handleClear() {
|
|
@@ -4434,14 +4437,14 @@ const Ya = {
|
|
|
4434
4437
|
this.map && (this.map.getLayer(this.historyLayer) && this.map.removeLayer(this.historyLayer), this.map.getLayer(this.forecastLayer) && this.map.removeLayer(this.forecastLayer), this.map.getLayer(this.forecastModelLayer) && this.map.removeLayer(this.forecastModelLayer), this.map.getLayer(this.forecastNameLayer) && this.map.removeLayer(this.forecastNameLayer), this.map.getLayer(this.pointCircleLayer) && this.map.removeLayer(this.pointCircleLayer), this.map.getLayer(this.pointCircleLayer + "-border") && this.map.removeLayer(this.pointCircleLayer + "-border"), this.map.getLayer(this.pointLabelLayer) && this.map.removeLayer(this.pointLabelLayer), this.map.getLayer(this.historyPointCircleLayer) && this.map.removeLayer(this.historyPointCircleLayer), this.map.getLayer(this.historyPointCircleLayer + "-border") && this.map.removeLayer(this.historyPointCircleLayer + "-border"), this.map.getLayer(this.historyPointCircleLayer + "-inner") && this.map.removeLayer(this.historyPointCircleLayer + "-inner"), this.map.getLayer(this.historyPointLabelLayer) && this.map.removeLayer(this.historyPointLabelLayer), this.map.getLayer(this.interpolateLineLayer) && this.map.removeLayer(this.interpolateLineLayer), (a = this.interpolateMarkers) == null || a.forEach((e) => e == null ? void 0 : e.remove()), this.map.getSource(this.source) && this.map.removeSource(this.source), this.map.getSource(this.clusterSource) && this.map.removeSource(this.clusterSource), this.map.getSource(this.interpolateSource) && this.map.removeSource(this.interpolateSource), this.map.getLayer(this.circleLayer) && this.map.removeLayer(this.circleLayer), this.map.getSource(this.circleSource) && this.map.removeSource(this.circleSource));
|
|
4435
4438
|
},
|
|
4436
4439
|
handleDateChange() {
|
|
4437
|
-
var a, e, t, r, i, o, s, n, c, d,
|
|
4440
|
+
var a, e, t, r, i, o, s, n, c, d, p, h, g, u, y, f, m, v, b, _, P, w, A, M, $, W, O, J, de, pe, me, ue, ye, fe, ge, ie;
|
|
4438
4441
|
if ((a = this.interpolateMarkers) == null || a.forEach((X) => X == null ? void 0 : X.remove()), this.circleSourceData.features = [], (e = this.interpolateData) != null && e.length && this.tropicals.active) {
|
|
4439
|
-
const X = Z(this.date).utc().set({ minute: 0, second: 0, millisecond: 0 }),
|
|
4442
|
+
const X = Z(this.date).utc().set({ minute: 0, second: 0, millisecond: 0 }), q = this.interpolateData.filter((I) => I.properties.date === X.format() && !I.properties.disabled), be = this.handleComputePolygons(q), Q = L.featureCollection([...q]);
|
|
4440
4443
|
be.forEach((I) => {
|
|
4441
|
-
|
|
4442
|
-
}), (t = this.map) != null && t.getSource(this.interpolateSource) ? (r = this.map) == null || r.getSource(this.interpolateSource).setData(
|
|
4444
|
+
Q.features.push(I);
|
|
4445
|
+
}), (t = this.map) != null && t.getSource(this.interpolateSource) ? (r = this.map) == null || r.getSource(this.interpolateSource).setData(Q) : ((i = this.map) == null || i.addSource(this.interpolateSource, {
|
|
4443
4446
|
type: "geojson",
|
|
4444
|
-
data:
|
|
4447
|
+
data: Q
|
|
4445
4448
|
}), (o = this.map) == null || o.addLayer({
|
|
4446
4449
|
id: this.interpolateLineLayer,
|
|
4447
4450
|
type: "line",
|
|
@@ -4453,10 +4456,10 @@ const Ya = {
|
|
|
4453
4456
|
"line-width": 1
|
|
4454
4457
|
}
|
|
4455
4458
|
})), this.interpolateMarkers = [];
|
|
4456
|
-
for (const I of
|
|
4459
|
+
for (const I of q)
|
|
4457
4460
|
if (!I.properties.disabled) {
|
|
4458
4461
|
let F = "#f44336";
|
|
4459
|
-
((n = (s = I.properties) == null ? void 0 : s.wind) == null ? void 0 : n.spd) < 17.2 || !((d = (c = I.properties) == null ? void 0 : c.wind) != null && d.spd) ? F = "#03f869" : ((
|
|
4462
|
+
((n = (s = I.properties) == null ? void 0 : s.wind) == null ? void 0 : n.spd) < 17.2 || !((d = (c = I.properties) == null ? void 0 : c.wind) != null && d.spd) ? F = "#03f869" : ((h = (p = I.properties) == null ? void 0 : p.wind) == null ? void 0 : h.spd) >= 17.2 && ((u = (g = I.properties) == null ? void 0 : g.wind) == null ? void 0 : u.spd) < 24.5 ? F = "#f2f202" : ((f = (y = I.properties) == null ? void 0 : y.wind) == null ? void 0 : f.spd) >= 24.5 && ((v = (m = I.properties) == null ? void 0 : m.wind) == null ? void 0 : v.spd) < 32.7 ? F = "#ff9100" : ((_ = (b = I.properties) == null ? void 0 : b.wind) == null ? void 0 : _.spd) >= 32.7 && ((w = (P = I.properties) == null ? void 0 : P.wind) == null ? void 0 : w.spd) < 41.5 ? F = "#f44336" : ((M = (A = I.properties) == null ? void 0 : A.wind) == null ? void 0 : M.spd) >= 41.5 && ((W = ($ = I.properties) == null ? void 0 : $.wind) == null ? void 0 : W.spd) < 51 ? F = "#f903d0" : ((J = (O = I.properties) == null ? void 0 : O.wind) == null ? void 0 : J.spd) >= 51 ? F = "#8702f9" : F = "#f44336";
|
|
4460
4463
|
const ve = `<svg t="1719918955501"
|
|
4461
4464
|
class="icon" viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg" p-id="18382"
|
|
4462
4465
|
xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200">
|
|
@@ -4471,9 +4474,9 @@ const Ya = {
|
|
|
4471
4474
|
<path
|
|
4472
4475
|
d="M420.66666667 959.17a16.08 16.08 0 0 1-15.91-13.49A15.89 15.89 0 0 1 415.50666667 928c1.49-0.55 38.88-14.76 72.79-65.52A354.55 354.55 0 0 1 162.66666667 509.17a450.14 450.14 0 0 1 450.5-450.5 16.07 16.07 0 0 1 15.91 13.48 15.88 15.88 0 0 1-10.75 17.66c-1.58 0.58-39.13 14.9-73.07 65.95A354.22 354.22 0 0 1 871.66666667 509.17a16 16 0 0 1-0.52 4.05A450.14 450.14 0 0 1 420.66666667 959.17zM554.80666667 94.72C351.57666667 123.2 194.66666667 298.21 194.66666667 509.17c0 177.08 144.06 321.74 321.13 322.48a16 16 0 0 1 14.07 23.49c-16.11 30.42-34.27 52.37-50.85 68C682.25666667 894.63 839.16666667 719.63 839.16666667 508.67a15.94 15.94 0 0 1 0.47-3.86C837.30666667 329.33 693.82666667 187 517.80666667 186.67A16 16 0 0 1 503.66666667 163.21c16.21-30.69 34.47-52.79 51.14-68.49z"
|
|
4473
4476
|
fill="#ffffff" p-id="18386"></path>
|
|
4474
|
-
</svg>`,
|
|
4475
|
-
|
|
4476
|
-
const we = new te.Marker(
|
|
4477
|
+
</svg>`, K = document.createElement("div");
|
|
4478
|
+
K.className = "hurricane-hourly-marker", K.innerHTML = `<div class="${I.geometry.coordinates[1] >= 0 ? "center north" : "center south"}">${ve}</div>`;
|
|
4479
|
+
const we = new te.Marker(K).setLngLat(I.geometry.coordinates).addTo(this.map);
|
|
4477
4480
|
if (this.interpolateMarkers.push(we), (de = I.properties) != null && de.showCircle) {
|
|
4478
4481
|
const re = { radius: 100, coordinates: I.geometry.coordinates }, oe = { radius: 200, coordinates: I.geometry.coordinates }, se = { radius: 500, coordinates: I.geometry.coordinates };
|
|
4479
4482
|
(pe = this.circleSourceData) == null || pe.features.push(
|
|
@@ -4490,7 +4493,7 @@ const Ya = {
|
|
|
4490
4493
|
(ge = this.map) != null && ge.getSource(this.interpolateSource) && ((ie = this.map) == null || ie.getSource(this.interpolateSource).setData(this.empty));
|
|
4491
4494
|
},
|
|
4492
4495
|
handleClick(a) {
|
|
4493
|
-
var o, s, n, c, d,
|
|
4496
|
+
var o, s, n, c, d, p, h, g;
|
|
4494
4497
|
const e = a.features[0], t = (s = (o = this.tropicals) == null ? void 0 : o.data) == null ? void 0 : s.features.filter(
|
|
4495
4498
|
(u) => {
|
|
4496
4499
|
var y;
|
|
@@ -4510,8 +4513,8 @@ const Ya = {
|
|
|
4510
4513
|
this.activeTropicals = {
|
|
4511
4514
|
name: (d = e == null ? void 0 : e.properties) == null ? void 0 : d.name,
|
|
4512
4515
|
forecasts: t.map((u) => u.properties),
|
|
4513
|
-
history: (
|
|
4514
|
-
showCircle: (g = (
|
|
4516
|
+
history: (p = r[0]) == null ? void 0 : p.properties,
|
|
4517
|
+
showCircle: (g = (h = t[0]) == null ? void 0 : h.properties) == null ? void 0 : g.showCircle
|
|
4515
4518
|
}, this.showTropicals = !0;
|
|
4516
4519
|
const i = document.getElementById("active-tropical");
|
|
4517
4520
|
this.activeTropicalsMarker ? this.activeTropicalsMarker.setLngLat([a.lngLat.lng, a.lngLat.lat]) : this.activeTropicalsMarker = new te.Marker(i).setLngLat([a.lngLat.lng, a.lngLat.lat]).setOffset([220, 0]).addTo(this.map);
|
|
@@ -4599,7 +4602,7 @@ const Ya = {
|
|
|
4599
4602
|
return L.lineToPolygon(i, { properties: t });
|
|
4600
4603
|
}
|
|
4601
4604
|
}
|
|
4602
|
-
}, Ue = (a) => (H("data-v-
|
|
4605
|
+
}, Ue = (a) => (H("data-v-f0e05b29"), a = a(), G(), a), qa = {
|
|
4603
4606
|
id: "active-tropical",
|
|
4604
4607
|
class: "active-tropical"
|
|
4605
4608
|
}, Qa = { class: "header-box" }, Ka = { class: "main" }, ei = { key: 0 }, ti = { class: "sub" }, ai = {
|
|
@@ -4614,9 +4617,9 @@ const Ya = {
|
|
|
4614
4617
|
}, li = /* @__PURE__ */ Ue(() => /* @__PURE__ */ l("label", null, "Pressure : ", -1)), ci = { class: "row" }, hi = {
|
|
4615
4618
|
class: "col col-24",
|
|
4616
4619
|
style: { "justify-content": "flex-start" }
|
|
4617
|
-
}, di = /* @__PURE__ */ Ue(() => /* @__PURE__ */ l("label", { style: { width: "max-content" } }, "Forecast Models : ", -1)), pi = { class: "forecast-models" }, mi = ["onClick"], ui = /* @__PURE__ */ rt('<div class="row" style="padding:0;height:1px;margin:10px 0;background:var(--idm-black-1);" data-v-
|
|
4620
|
+
}, di = /* @__PURE__ */ Ue(() => /* @__PURE__ */ l("label", { style: { width: "max-content" } }, "Forecast Models : ", -1)), pi = { class: "forecast-models" }, mi = ["onClick"], ui = /* @__PURE__ */ rt('<div class="row" style="padding:0;height:1px;margin:10px 0;background:var(--idm-black-1);" data-v-f0e05b29></div><div class="row" style="padding:2px 10px;" data-v-f0e05b29><div class="legend" data-v-f0e05b29><div class="icon td" data-v-f0e05b29></div><div class="label" data-v-f0e05b29>TD</div></div><div class="legend" data-v-f0e05b29><div class="icon ts" data-v-f0e05b29></div><div class="label" data-v-f0e05b29>TS</div></div><div class="legend" data-v-f0e05b29><div class="icon sts" data-v-f0e05b29></div><div class="label" data-v-f0e05b29>STS</div></div><div class="legend" data-v-f0e05b29><div class="icon ty" data-v-f0e05b29></div><div class="label" data-v-f0e05b29>TY</div></div><div class="legend" data-v-f0e05b29><div class="icon sty" data-v-f0e05b29></div><div class="label" data-v-f0e05b29>STY</div></div><div class="legend" data-v-f0e05b29><div class="icon supper-ty" data-v-f0e05b29></div><div class="label" data-v-f0e05b29>Super TY</div></div></div><div class="row" style="padding:2px 10px;" data-v-f0e05b29><div class="legend" data-v-f0e05b29><div class="icon history" data-v-f0e05b29></div><div class="label" data-v-f0e05b29>History</div></div><div class="legend" data-v-f0e05b29><div class="icon r7" data-v-f0e05b29></div><div class="label" data-v-f0e05b29>35kts Radii</div></div><div class="legend" data-v-f0e05b29><div class="icon r10" data-v-f0e05b29></div><div class="label" data-v-f0e05b29>50kts Radii</div></div></div>', 3), yi = { class: "more" };
|
|
4618
4621
|
function fi(a, e, t, r, i, o) {
|
|
4619
|
-
var s, n, c, d,
|
|
4622
|
+
var s, n, c, d, p, h, g, u, y, f, m, v, b, _, P;
|
|
4620
4623
|
return je((x(), C("div", qa, [
|
|
4621
4624
|
l("div", Qa, [
|
|
4622
4625
|
l("div", {
|
|
@@ -4624,10 +4627,10 @@ function fi(a, e, t, r, i, o) {
|
|
|
4624
4627
|
onClick: e[0] || (e[0] = (w) => i.showTropicals = !1)
|
|
4625
4628
|
}, ""),
|
|
4626
4629
|
l("div", Ka, [
|
|
4627
|
-
(n = (s = i.activeTropicals) == null ? void 0 : s.history) != null && n.level ? (x(), C("span", ei, S((d = (c = i.activeTropicals) == null ? void 0 : c.history) == null ? void 0 : d.level) + " , ", 1)) :
|
|
4628
|
-
Fe(S((
|
|
4630
|
+
(n = (s = i.activeTropicals) == null ? void 0 : s.history) != null && n.level ? (x(), C("span", ei, S((d = (c = i.activeTropicals) == null ? void 0 : c.history) == null ? void 0 : d.level) + " , ", 1)) : j("", !0),
|
|
4631
|
+
Fe(S((p = i.activeTropicals) == null ? void 0 : p.name), 1)
|
|
4629
4632
|
]),
|
|
4630
|
-
l("div", ti, " Last update: " + S(o.computeTime(((g = (
|
|
4633
|
+
l("div", ti, " Last update: " + S(o.computeTime(((g = (h = i.activeTropicals) == null ? void 0 : h.history) == null ? void 0 : g.updated) || ((f = (y = (u = i.activeTropicals) == null ? void 0 : u.forecasts) == null ? void 0 : y.filter((w) => !w.disabled)[0]) == null ? void 0 : f.date))), 1)
|
|
4631
4634
|
]),
|
|
4632
4635
|
l("div", ai, [
|
|
4633
4636
|
l("div", ii, [
|
|
@@ -4645,11 +4648,11 @@ function fi(a, e, t, r, i, o) {
|
|
|
4645
4648
|
l("div", hi, [
|
|
4646
4649
|
di,
|
|
4647
4650
|
l("div", pi, [
|
|
4648
|
-
(x(!0), C(Ae, null, $e((
|
|
4651
|
+
(x(!0), C(Ae, null, $e((P = i.activeTropicals) == null ? void 0 : P.forecasts, (w, A) => {
|
|
4649
4652
|
var M, $, W, O;
|
|
4650
4653
|
return x(), C("div", {
|
|
4651
4654
|
key: A,
|
|
4652
|
-
class:
|
|
4655
|
+
class: N([
|
|
4653
4656
|
"model",
|
|
4654
4657
|
w.disabled ? "" : "active",
|
|
4655
4658
|
A > 0 && A < (($ = (M = i.activeTropicals) == null ? void 0 : M.forecasts) == null ? void 0 : $.length) - 1 && ((O = (W = i.activeTropicals) == null ? void 0 : W.forecasts) == null ? void 0 : O.length) > 2 ? "center-child" : ""
|
|
@@ -4657,7 +4660,7 @@ function fi(a, e, t, r, i, o) {
|
|
|
4657
4660
|
onClick: (J) => o.handleForecastToggle(w)
|
|
4658
4661
|
}, [
|
|
4659
4662
|
l("span", {
|
|
4660
|
-
class:
|
|
4663
|
+
class: N(w.model)
|
|
4661
4664
|
}, S(w.model), 3)
|
|
4662
4665
|
], 10, mi);
|
|
4663
4666
|
}), 128))
|
|
@@ -4677,7 +4680,7 @@ function fi(a, e, t, r, i, o) {
|
|
|
4677
4680
|
[Ne, i.showTropicals && !a.$attrs.hideTropicalsLegend]
|
|
4678
4681
|
]);
|
|
4679
4682
|
}
|
|
4680
|
-
const Ke = /* @__PURE__ */ T(Ya, [["render", fi], ["__scopeId", "data-v-
|
|
4683
|
+
const Ke = /* @__PURE__ */ T(Ya, [["render", fi], ["__scopeId", "data-v-f0e05b29"]]);
|
|
4681
4684
|
const gi = {
|
|
4682
4685
|
name: "IdmPrecip3h",
|
|
4683
4686
|
props: {
|
|
@@ -4766,7 +4769,7 @@ const gi = {
|
|
|
4766
4769
|
[1, "rgba(197,5,58,0.8)"]
|
|
4767
4770
|
];
|
|
4768
4771
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
4769
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
4772
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.fragmentSchema);
|
|
4770
4773
|
this.program = e, this.aPositionBuffer = t;
|
|
4771
4774
|
}
|
|
4772
4775
|
},
|
|
@@ -4796,7 +4799,7 @@ function Pi(a, e, t, r, i, o) {
|
|
|
4796
4799
|
class: "legend-bars flex-center",
|
|
4797
4800
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
4798
4801
|
}, zi, 4)
|
|
4799
|
-
])) :
|
|
4802
|
+
])) : j("", !0);
|
|
4800
4803
|
}
|
|
4801
4804
|
const Ti = /* @__PURE__ */ T(gi, [["render", Pi], ["__scopeId", "data-v-9708a7a3"]]);
|
|
4802
4805
|
const Ii = {
|
|
@@ -4880,7 +4883,7 @@ const Ii = {
|
|
|
4880
4883
|
[1, "rgba(144,144,144,0)"]
|
|
4881
4884
|
];
|
|
4882
4885
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
4883
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
4886
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.fragmentSchema);
|
|
4884
4887
|
this.program = e, this.aPositionBuffer = t;
|
|
4885
4888
|
}
|
|
4886
4889
|
},
|
|
@@ -4908,7 +4911,7 @@ function Bi(a, e, t, r, i, o) {
|
|
|
4908
4911
|
class: "legend-bars flex-center",
|
|
4909
4912
|
style: U([{ position: "absolute" }, { right: a.right + "px", bottom: t.bottom }])
|
|
4910
4913
|
}, Ni, 4)
|
|
4911
|
-
])) :
|
|
4914
|
+
])) : j("", !0);
|
|
4912
4915
|
}
|
|
4913
4916
|
const Wi = /* @__PURE__ */ T(Ii, [["render", Bi], ["__scopeId", "data-v-f7b2fb08"]]);
|
|
4914
4917
|
const Oi = {
|
|
@@ -5000,7 +5003,7 @@ const Oi = {
|
|
|
5000
5003
|
//
|
|
5001
5004
|
];
|
|
5002
5005
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
5003
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
5006
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.fragmentSchema);
|
|
5004
5007
|
this.program = e, this.aPositionBuffer = t;
|
|
5005
5008
|
}
|
|
5006
5009
|
},
|
|
@@ -5028,7 +5031,7 @@ function Yi(a, e, t, r, i, o) {
|
|
|
5028
5031
|
class: "legend-bars flex-center",
|
|
5029
5032
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
5030
5033
|
}, Xi, 4)
|
|
5031
|
-
])) :
|
|
5034
|
+
])) : j("", !0);
|
|
5032
5035
|
}
|
|
5033
5036
|
const qi = /* @__PURE__ */ T(Oi, [["render", Yi], ["__scopeId", "data-v-7521f582"]]);
|
|
5034
5037
|
const Qi = {
|
|
@@ -5123,7 +5126,7 @@ const Qi = {
|
|
|
5123
5126
|
[1, "rgb(138, 43, 10)"]
|
|
5124
5127
|
];
|
|
5125
5128
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
5126
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
5129
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.fragmentSchema);
|
|
5127
5130
|
this.program = e, this.aPositionBuffer = t;
|
|
5128
5131
|
}
|
|
5129
5132
|
},
|
|
@@ -5153,7 +5156,7 @@ function cr(a, e, t, r, i, o) {
|
|
|
5153
5156
|
class: "legend-bars flex-center",
|
|
5154
5157
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
5155
5158
|
}, lr, 4)
|
|
5156
|
-
])) :
|
|
5159
|
+
])) : j("", !0);
|
|
5157
5160
|
}
|
|
5158
5161
|
const hr = /* @__PURE__ */ T(Qi, [["render", cr], ["__scopeId", "data-v-25daaa82"]]);
|
|
5159
5162
|
const dr = {
|
|
@@ -5239,7 +5242,7 @@ const dr = {
|
|
|
5239
5242
|
// 2m
|
|
5240
5243
|
];
|
|
5241
5244
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
5242
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
5245
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.fragmentSchema);
|
|
5243
5246
|
this.program = e, this.aPositionBuffer = t;
|
|
5244
5247
|
}
|
|
5245
5248
|
},
|
|
@@ -5267,7 +5270,7 @@ function wr(a, e, t, r, i, o) {
|
|
|
5267
5270
|
class: "legend-bars flex-center",
|
|
5268
5271
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
5269
5272
|
}, vr, 4)
|
|
5270
|
-
])) :
|
|
5273
|
+
])) : j("", !0);
|
|
5271
5274
|
}
|
|
5272
5275
|
const _r = /* @__PURE__ */ T(dr, [["render", wr], ["__scopeId", "data-v-5bb73794"]]);
|
|
5273
5276
|
const Lr = {
|
|
@@ -5357,12 +5360,12 @@ const Lr = {
|
|
|
5357
5360
|
}
|
|
5358
5361
|
}
|
|
5359
5362
|
}
|
|
5360
|
-
}, ae = (a) => (H("data-v-
|
|
5363
|
+
}, ae = (a) => (H("data-v-efcf572f"), a = a(), G(), a), xr = {
|
|
5361
5364
|
id: "point-meteo",
|
|
5362
5365
|
class: "point-meteo"
|
|
5363
5366
|
}, Cr = { class: "meteo-box" }, kr = { class: "header-box" }, Sr = { class: "main" }, zr = { class: "sub" }, Pr = { class: "main-box" }, Tr = { class: "flex-space" }, Ir = /* @__PURE__ */ ae(() => /* @__PURE__ */ l("label", null, "Wind", -1)), Er = { class: "flex-space" }, Rr = /* @__PURE__ */ ae(() => /* @__PURE__ */ l("label", null, "Wind.Wave", -1)), Ar = { class: "flex-space" }, Dr = /* @__PURE__ */ ae(() => /* @__PURE__ */ l("label", null, "Swell", -1)), Mr = { class: "flex-space" }, $r = /* @__PURE__ */ ae(() => /* @__PURE__ */ l("label", null, "Sig.Wave", -1)), jr = { class: "flex-space" }, Nr = /* @__PURE__ */ ae(() => /* @__PURE__ */ l("label", null, "Current", -1)), Br = { class: "flex-space" }, Wr = /* @__PURE__ */ ae(() => /* @__PURE__ */ l("label", null, "Precip", -1)), Or = { class: "flex-space" }, Fr = /* @__PURE__ */ ae(() => /* @__PURE__ */ l("label", null, "Visibility", -1)), Vr = { class: "flex-space" }, Ur = /* @__PURE__ */ ae(() => /* @__PURE__ */ l("label", null, "Temp", -1)), Zr = { class: "flex-space" }, Hr = /* @__PURE__ */ ae(() => /* @__PURE__ */ l("label", null, "Water Temp", -1));
|
|
5364
5367
|
function Gr(a, e, t, r, i, o) {
|
|
5365
|
-
var s, n, c, d,
|
|
5368
|
+
var s, n, c, d, p, h, g, u, y, f, m, v, b, _, P, w, A, M, $, W, O, J, de, pe, me, ue, ye, fe, ge, ie, X, q, be, Q, I, F, ve, K, we, re, oe, se, Pe, Te, Ie, Ee, Re;
|
|
5366
5369
|
return je((x(), C("div", xr, [
|
|
5367
5370
|
l("div", Cr, [
|
|
5368
5371
|
l("div", kr, [
|
|
@@ -5376,11 +5379,11 @@ function Gr(a, e, t, r, i, o) {
|
|
|
5376
5379
|
l("div", Pr, [
|
|
5377
5380
|
l("div", Tr, [
|
|
5378
5381
|
Ir,
|
|
5379
|
-
l("span", null, S(((
|
|
5382
|
+
l("span", null, S(((p = (d = t.meteo) == null ? void 0 : d.wind) == null ? void 0 : p.direction) || "-") + "/" + S(o.roundPrecision((g = (h = t.meteo) == null ? void 0 : h.wind) == null ? void 0 : g.kts, 1)) + "[kts]/" + S((y = (u = t.meteo) == null ? void 0 : u.wind) == null ? void 0 : y.scale) + "[BF]/" + S(o.roundPrecision((m = (f = t.meteo) == null ? void 0 : f.gusts) == null ? void 0 : m.kts, 1)) + "[kts]", 1)
|
|
5380
5383
|
]),
|
|
5381
5384
|
l("div", Er, [
|
|
5382
5385
|
Rr,
|
|
5383
|
-
l("span", null, S(((_ = (b = (v = t.meteo) == null ? void 0 : v.wave) == null ? void 0 : b.wd) == null ? void 0 : _.direction) || "-") + "/" + S(o.roundPrecision((A = (w = (
|
|
5386
|
+
l("span", null, S(((_ = (b = (v = t.meteo) == null ? void 0 : v.wave) == null ? void 0 : b.wd) == null ? void 0 : _.direction) || "-") + "/" + S(o.roundPrecision((A = (w = (P = t.meteo) == null ? void 0 : P.wave) == null ? void 0 : w.wd) == null ? void 0 : A.height, 1)) + "[m]/" + S(o.roundPrecision((W = ($ = (M = t.meteo) == null ? void 0 : M.wave) == null ? void 0 : $.wd) == null ? void 0 : W.period, 1)) + "[s]", 1)
|
|
5384
5387
|
]),
|
|
5385
5388
|
l("div", Ar, [
|
|
5386
5389
|
Dr,
|
|
@@ -5388,7 +5391,7 @@ function Gr(a, e, t, r, i, o) {
|
|
|
5388
5391
|
]),
|
|
5389
5392
|
l("div", Mr, [
|
|
5390
5393
|
$r,
|
|
5391
|
-
l("span", null, S(((
|
|
5394
|
+
l("span", null, S(((q = (X = (ie = t.meteo) == null ? void 0 : ie.wave) == null ? void 0 : X.sig) == null ? void 0 : q.direction) || "-") + "/" + S(o.roundPrecision((I = (Q = (be = t.meteo) == null ? void 0 : be.wave) == null ? void 0 : Q.sig) == null ? void 0 : I.height, 1)) + "[m]/" + S(o.roundPrecision((K = (ve = (F = t.meteo) == null ? void 0 : F.wave) == null ? void 0 : ve.sig) == null ? void 0 : K.period, 1)) + "[s]", 1)
|
|
5392
5395
|
]),
|
|
5393
5396
|
l("div", jr, [
|
|
5394
5397
|
Nr,
|
|
@@ -5411,13 +5414,13 @@ function Gr(a, e, t, r, i, o) {
|
|
|
5411
5414
|
l("span", null, S(o.roundPrecision((Re = t.meteo) == null ? void 0 : Re.waterTemp, 2)) + "[°C]", 1)
|
|
5412
5415
|
])
|
|
5413
5416
|
]),
|
|
5414
|
-
|
|
5417
|
+
j("", !0)
|
|
5415
5418
|
])
|
|
5416
5419
|
], 512)), [
|
|
5417
5420
|
[Ne, i.showMeteo]
|
|
5418
5421
|
]);
|
|
5419
5422
|
}
|
|
5420
|
-
const Jr = /* @__PURE__ */ T(Lr, [["render", Gr], ["__scopeId", "data-v-
|
|
5423
|
+
const Jr = /* @__PURE__ */ T(Lr, [["render", Gr], ["__scopeId", "data-v-efcf572f"]]), Xr = {
|
|
5421
5424
|
name: "IdmWarZone",
|
|
5422
5425
|
props: {
|
|
5423
5426
|
map: {
|
|
@@ -5812,7 +5815,7 @@ const ro = {
|
|
|
5812
5815
|
layout: {
|
|
5813
5816
|
"symbol-placement": "point",
|
|
5814
5817
|
"icon-image": "alert",
|
|
5815
|
-
"icon-size": 0.
|
|
5818
|
+
"icon-size": 0.08,
|
|
5816
5819
|
"icon-allow-overlap": !0,
|
|
5817
5820
|
"icon-rotation-alignment": "viewport"
|
|
5818
5821
|
},
|
|
@@ -5827,7 +5830,7 @@ const ro = {
|
|
|
5827
5830
|
layout: {
|
|
5828
5831
|
"symbol-placement": "line-center",
|
|
5829
5832
|
"icon-image": "alert",
|
|
5830
|
-
"icon-size": 0.
|
|
5833
|
+
"icon-size": 0.08,
|
|
5831
5834
|
"icon-allow-overlap": !0,
|
|
5832
5835
|
"icon-rotation-alignment": "viewport"
|
|
5833
5836
|
},
|
|
@@ -5842,7 +5845,7 @@ const ro = {
|
|
|
5842
5845
|
layout: {
|
|
5843
5846
|
"symbol-placement": "point",
|
|
5844
5847
|
"icon-image": "alert",
|
|
5845
|
-
"icon-size": 0.
|
|
5848
|
+
"icon-size": 0.08
|
|
5846
5849
|
},
|
|
5847
5850
|
paint: {
|
|
5848
5851
|
"icon-opacity": 0.8
|
|
@@ -5964,7 +5967,7 @@ const co = {
|
|
|
5964
5967
|
this.showPort = !1, this.map.getLayer(this.layer) && this.map.removeLayer(this.layer), this.map.getSource(this.source) && this.map.removeSource(this.source);
|
|
5965
5968
|
}
|
|
5966
5969
|
}
|
|
5967
|
-
}, Be = (a) => (H("data-v-
|
|
5970
|
+
}, Be = (a) => (H("data-v-c07e4c45"), a = a(), G(), a), ho = { id: "port-info" }, po = { class: "port-box" }, mo = { class: "flex-start" }, uo = /* @__PURE__ */ Be(() => /* @__PURE__ */ l("label", null, "Name : ", -1)), yo = { class: "flex-start" }, fo = /* @__PURE__ */ Be(() => /* @__PURE__ */ l("label", null, "Position : ", -1)), go = { class: "flex-start" }, bo = /* @__PURE__ */ Be(() => /* @__PURE__ */ l("label", null, "LoCode : ", -1)), vo = {
|
|
5968
5971
|
class: "flex-start",
|
|
5969
5972
|
style: { "align-items": "flex-start" }
|
|
5970
5973
|
}, wo = /* @__PURE__ */ Be(() => /* @__PURE__ */ l("label", null, "Region : ", -1));
|
|
@@ -5998,7 +6001,7 @@ function _o(a, e, t, r, i, o) {
|
|
|
5998
6001
|
[Ne, i.showPort]
|
|
5999
6002
|
]);
|
|
6000
6003
|
}
|
|
6001
|
-
const Lo = /* @__PURE__ */ T(co, [["render", _o], ["__scopeId", "data-v-
|
|
6004
|
+
const Lo = /* @__PURE__ */ T(co, [["render", _o], ["__scopeId", "data-v-c07e4c45"]]), xo = {
|
|
6002
6005
|
name: "IdmLoadLine",
|
|
6003
6006
|
props: {
|
|
6004
6007
|
map: {
|
|
@@ -6641,7 +6644,7 @@ function Oo(a, e, t, r, i, o) {
|
|
|
6641
6644
|
l("span", null, S(i.lngLat.lat.pretty), 1),
|
|
6642
6645
|
Wo,
|
|
6643
6646
|
l("span", null, S(i.lngLat.lng.pretty), 1)
|
|
6644
|
-
], 4)) :
|
|
6647
|
+
], 4)) : j("", !0);
|
|
6645
6648
|
}
|
|
6646
6649
|
const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7"]]), Fo = {
|
|
6647
6650
|
name: "IdmMeasure",
|
|
@@ -6689,8 +6692,8 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6689
6692
|
(a = this.map) == null || a.getCanvas().addEventListener("keydown", this.handleKeydown), (e = this.map) == null || e.on("mousemove", this.handleMove), (t = this.map) == null || t.on("dblclick", this.handleDblClick), (r = this.map) == null || r.on("click", this.handleClick), (i = this.map) == null || i.on("contextmenu", this.handleContextmenu), this.map && (this.map.getCanvas().style.cursor = "crosshair");
|
|
6690
6693
|
else {
|
|
6691
6694
|
(o = this.map) == null || o.getCanvas().removeEventListener("keydown", this.handleKeydown), (s = this.map) == null || s.off("mousemove", this.handleMove), (n = this.map) == null || n.off("dblclick", this.handleDblClick), (c = this.map) == null || c.off("click", this.handleClick), (d = this.map) == null || d.off("contextmenu", this.handleContextmenu);
|
|
6692
|
-
for (const
|
|
6693
|
-
this.handleClear(
|
|
6695
|
+
for (const p of this.geojson)
|
|
6696
|
+
this.handleClear(p, !0);
|
|
6694
6697
|
this.geojson = [], this.map && (this.map.getCanvas().style.cursor = "grab");
|
|
6695
6698
|
}
|
|
6696
6699
|
},
|
|
@@ -6702,7 +6705,7 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6702
6705
|
}
|
|
6703
6706
|
},
|
|
6704
6707
|
handleDrag(a) {
|
|
6705
|
-
var t, r, i, o, s, n, c, d,
|
|
6708
|
+
var t, r, i, o, s, n, c, d, p, h;
|
|
6706
6709
|
const e = (r = (t = a.target) == null ? void 0 : t._element) == null ? void 0 : r.id;
|
|
6707
6710
|
if ((e == null ? void 0 : e.split("-").length) === 2) {
|
|
6708
6711
|
const g = this.geojson.filter((m) => m.id === e.split("-")[0])[0];
|
|
@@ -6721,13 +6724,13 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6721
6724
|
this.handleTmpPointUpdate(
|
|
6722
6725
|
g,
|
|
6723
6726
|
f[y - 1],
|
|
6724
|
-
{ lng: (d = (c = a.target) == null ? void 0 : c._lngLat) == null ? void 0 : d.lng, lat: (
|
|
6727
|
+
{ lng: (d = (c = a.target) == null ? void 0 : c._lngLat) == null ? void 0 : d.lng, lat: (h = (p = a.target) == null ? void 0 : p._lngLat) == null ? void 0 : h.lat, properties: f[y].properties },
|
|
6725
6728
|
y === f.length - 1 ? void 0 : f[y + 1]
|
|
6726
6729
|
);
|
|
6727
6730
|
}
|
|
6728
6731
|
},
|
|
6729
6732
|
handleDragEnd(a) {
|
|
6730
|
-
var t, r, i, o, s, n, c, d,
|
|
6733
|
+
var t, r, i, o, s, n, c, d, p, h;
|
|
6731
6734
|
const e = (r = (t = a.target) == null ? void 0 : t._element) == null ? void 0 : r.id;
|
|
6732
6735
|
if ((e == null ? void 0 : e.split("-").length) === 2) {
|
|
6733
6736
|
const g = this.geojson.filter((f) => f.id === e.split("-")[0])[0];
|
|
@@ -6736,7 +6739,7 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6736
6739
|
return ((m = f._element) == null ? void 0 : m.id) === e;
|
|
6737
6740
|
})[0].setLngLat([(o = (i = a.target) == null ? void 0 : i._lngLat) == null ? void 0 : o.lng, (n = (s = a.target) == null ? void 0 : s._lngLat) == null ? void 0 : n.lat]);
|
|
6738
6741
|
const y = g.features.filter((f) => f.geometry.type === "Point" && f.properties.id == e.split("-")[1])[0];
|
|
6739
|
-
y.geometry.coordinates = [(d = (c = a.target) == null ? void 0 : c._lngLat) == null ? void 0 : d.lng, (
|
|
6742
|
+
y.geometry.coordinates = [(d = (c = a.target) == null ? void 0 : c._lngLat) == null ? void 0 : d.lng, (h = (p = a.target) == null ? void 0 : p._lngLat) == null ? void 0 : h.lat], g.features = g.features.filter((f) => f.geometry.type === "Point"), this.handlePointUpdate(g);
|
|
6740
6743
|
}
|
|
6741
6744
|
},
|
|
6742
6745
|
handleContextmenu(a) {
|
|
@@ -6783,12 +6786,12 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6783
6786
|
let t = 0;
|
|
6784
6787
|
const r = [];
|
|
6785
6788
|
for (let i = 1; i < e.length; i++) {
|
|
6786
|
-
const o = e[i - 1], s = e[i], n = o.properties, c = { lng: o.geometry.coordinates[0], lat: o.geometry.coordinates[1] }, d = { lng: s.geometry.coordinates[0], lat: s.geometry.coordinates[1] },
|
|
6787
|
-
t = D.roundPrecision(t +
|
|
6789
|
+
const o = e[i - 1], s = e[i], n = o.properties, c = { lng: o.geometry.coordinates[0], lat: o.geometry.coordinates[1] }, d = { lng: s.geometry.coordinates[0], lat: s.geometry.coordinates[1] }, p = ee.calculateDistance(c, d, n.mode === "RL", 2), h = ee.calculateBearing(c, d, n.mode === "RL", 2);
|
|
6790
|
+
t = D.roundPrecision(t + p, 2);
|
|
6788
6791
|
let g;
|
|
6789
6792
|
n.mode === "RL" ? g = D.convertToMonotonicLng([c, d]) : g = D.convertToMonotonicLng(ee.interpolateCoordinates(c, d, 200));
|
|
6790
6793
|
const u = L.lineString(g.map((y) => [y.lng, y.lat]));
|
|
6791
|
-
u.properties.dist =
|
|
6794
|
+
u.properties.dist = p, u.properties.bearing = h, u.properties.total = t, r.push(u);
|
|
6792
6795
|
}
|
|
6793
6796
|
e.push(...r), a.total = t;
|
|
6794
6797
|
}
|
|
@@ -6798,19 +6801,19 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6798
6801
|
const i = L.featureCollection([]);
|
|
6799
6802
|
let o, s;
|
|
6800
6803
|
if (e) {
|
|
6801
|
-
const c = e.properties, d = { lng: e.geometry.coordinates[0], lat: e.geometry.coordinates[1] },
|
|
6802
|
-
o = ee.calculateDistance(d,
|
|
6803
|
-
let
|
|
6804
|
-
c.mode === "RL" ?
|
|
6805
|
-
const g = L.lineString(
|
|
6804
|
+
const c = e.properties, d = { lng: e.geometry.coordinates[0], lat: e.geometry.coordinates[1] }, p = { lng: t.lng, lat: t.lat };
|
|
6805
|
+
o = ee.calculateDistance(d, p, c.mode === "RL", 2), s = ee.calculateBearing(d, p, c.mode === "RL", 2);
|
|
6806
|
+
let h;
|
|
6807
|
+
c.mode === "RL" ? h = D.convertToMonotonicLng([d, p]) : h = D.convertToMonotonicLng(ee.interpolateCoordinates(d, p, 200));
|
|
6808
|
+
const g = L.lineString(h.map((u) => [u.lng, u.lat]));
|
|
6806
6809
|
g.properties.dist = o, g.properties.bearing = s, i.features.push(g);
|
|
6807
6810
|
}
|
|
6808
6811
|
if (r) {
|
|
6809
|
-
const c = t.properties, d = t,
|
|
6810
|
-
o = ee.calculateDistance(d,
|
|
6811
|
-
let
|
|
6812
|
-
c.mode === "RL" ?
|
|
6813
|
-
const g = L.lineString(
|
|
6812
|
+
const c = t.properties, d = t, p = { lng: r.geometry.coordinates[0], lat: r.geometry.coordinates[1] };
|
|
6813
|
+
o = ee.calculateDistance(d, p, c.mode === "RL", 2), s = ee.calculateBearing(d, p, c.mode === "RL", 2);
|
|
6814
|
+
let h;
|
|
6815
|
+
c.mode === "RL" ? h = D.convertToMonotonicLng([d, p]) : h = D.convertToMonotonicLng(ee.interpolateCoordinates(d, p, 200));
|
|
6816
|
+
const g = L.lineString(h.map((u) => [u.lng, u.lat]));
|
|
6814
6817
|
g.properties.dist = o, g.properties.bearing = s, i.features.push(g);
|
|
6815
6818
|
}
|
|
6816
6819
|
this.map.getSource(this.tmpSource) ? this.map.getSource(this.tmpSource).setData(i) : this.map.addSource(this.tmpSource, {
|
|
@@ -6917,17 +6920,17 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6917
6920
|
c.on("drag", this.handleDrag), c.on("dragend", this.handleDragEnd), this.pointMarkers[a.id] ? this.pointMarkers[a.id].push(c) : this.pointMarkers[a.id] = [c];
|
|
6918
6921
|
}
|
|
6919
6922
|
if (a.closed) {
|
|
6920
|
-
const s = o.at(-1), c = a.features.filter((
|
|
6923
|
+
const s = o.at(-1), c = a.features.filter((p) => p.geometry.type === "LineString").at(-1), d = document.createElement("div");
|
|
6921
6924
|
d.className = "point-summary-marker", d.innerHTML = `<div id="${a.id}" class="marker-close">×</div><div class="marker-label">Tol: ${c.properties.total}nm</div>`, this.closeMarkers[a.id] = new te.Marker(d).setOffset([60, 0]).setLngLat(s.geometry.coordinates).addTo(this.map);
|
|
6922
6925
|
}
|
|
6923
6926
|
}
|
|
6924
6927
|
},
|
|
6925
6928
|
handleClear(a, e = !0) {
|
|
6926
|
-
var o, s, n, c, d,
|
|
6929
|
+
var o, s, n, c, d, p, h, g, u;
|
|
6927
6930
|
const t = `${a.id}-${this.source}`, r = `${a.id}-${this.layer}`, i = `${a.id}-${this.labelLayer}`;
|
|
6928
|
-
(o = this.map) != null && o.getLayer(r) && this.map.removeLayer(r), (s = this.map) != null && s.getLayer(i) && this.map.removeLayer(i), (n = this.map) != null && n.getLayer(this.tmpLayer) && this.map.removeLayer(this.tmpLayer), (c = this.map) != null && c.getLayer(this.tmpLabelLayer) && this.map.removeLayer(this.tmpLabelLayer), (d = this.closeMarkers[a.id]) == null || d.remove(), this.closeMarkers[a.id] = void 0, (
|
|
6931
|
+
(o = this.map) != null && o.getLayer(r) && this.map.removeLayer(r), (s = this.map) != null && s.getLayer(i) && this.map.removeLayer(i), (n = this.map) != null && n.getLayer(this.tmpLayer) && this.map.removeLayer(this.tmpLayer), (c = this.map) != null && c.getLayer(this.tmpLabelLayer) && this.map.removeLayer(this.tmpLabelLayer), (d = this.closeMarkers[a.id]) == null || d.remove(), this.closeMarkers[a.id] = void 0, (p = this.pointMarkers[a.id]) == null || p.forEach((y) => {
|
|
6929
6932
|
y == null || y.remove();
|
|
6930
|
-
}), this.pointMarkers[a.id] = [], (
|
|
6933
|
+
}), this.pointMarkers[a.id] = [], (h = this.tipMarker) == null || h.remove(), this.tipMarker = void 0, e && ((g = this.map) != null && g.getSource(t)) && this.map.removeSource(t), e && ((u = this.map) != null && u.getSource(this.tmpSource)) && this.map.removeSource(this.tmpSource);
|
|
6931
6934
|
}
|
|
6932
6935
|
}
|
|
6933
6936
|
};
|
|
@@ -6987,31 +6990,52 @@ const Zo = {
|
|
|
6987
6990
|
}
|
|
6988
6991
|
},
|
|
6989
6992
|
methods: {}
|
|
6990
|
-
}, tt = (a) => (H("data-v-
|
|
6993
|
+
}, tt = (a) => (H("data-v-8928221f"), a = a(), G(), a), Ho = { key: 0 }, Go = { class: "bar-item" }, Jo = /* @__PURE__ */ tt(() => /* @__PURE__ */ l("span", { class: "iconfont" }, "HI", -1)), Xo = [
|
|
6991
6994
|
Jo
|
|
6992
6995
|
], Yo = /* @__PURE__ */ tt(() => /* @__PURE__ */ l("span", { class: "iconfont" }, "I4", -1)), qo = [
|
|
6993
6996
|
Yo
|
|
6994
6997
|
];
|
|
6995
6998
|
function Qo(a, e, t, r, i, o) {
|
|
6999
|
+
const s = z("ElTooltip");
|
|
6996
7000
|
return t.enabled && t.permission & i.helper.LEVEL.Supper ? (x(), C("div", Ho, [
|
|
6997
7001
|
l("div", {
|
|
6998
7002
|
class: "menu-bar-box",
|
|
6999
7003
|
style: U({ position: "absolute", right: i.right + "px", bottom: t.bottom })
|
|
7000
7004
|
}, [
|
|
7001
7005
|
l("div", Go, [
|
|
7002
|
-
|
|
7003
|
-
|
|
7004
|
-
|
|
7005
|
-
|
|
7006
|
-
|
|
7007
|
-
|
|
7008
|
-
|
|
7009
|
-
|
|
7006
|
+
k(s, {
|
|
7007
|
+
placement: "left",
|
|
7008
|
+
effect: "light",
|
|
7009
|
+
content: "Hifleet",
|
|
7010
|
+
"show-after": 2e3
|
|
7011
|
+
}, {
|
|
7012
|
+
default: Y(() => [
|
|
7013
|
+
l("div", {
|
|
7014
|
+
class: N(i.vendor === "hi" ? "menu-icon active" : "menu-icon"),
|
|
7015
|
+
onClick: e[0] || (e[0] = (n) => i.vendor = "hi")
|
|
7016
|
+
}, Xo, 2)
|
|
7017
|
+
]),
|
|
7018
|
+
_: 1
|
|
7019
|
+
}),
|
|
7020
|
+
k(s, {
|
|
7021
|
+
placement: "left",
|
|
7022
|
+
effect: "light",
|
|
7023
|
+
content: "I4insight",
|
|
7024
|
+
"show-after": 2e3
|
|
7025
|
+
}, {
|
|
7026
|
+
default: Y(() => [
|
|
7027
|
+
l("div", {
|
|
7028
|
+
class: N(i.vendor === "i4" ? "menu-icon active" : "menu-icon"),
|
|
7029
|
+
onClick: e[1] || (e[1] = (n) => i.vendor = "i4")
|
|
7030
|
+
}, qo, 2)
|
|
7031
|
+
]),
|
|
7032
|
+
_: 1
|
|
7033
|
+
})
|
|
7010
7034
|
])
|
|
7011
7035
|
], 4)
|
|
7012
|
-
])) :
|
|
7036
|
+
])) : j("", !0);
|
|
7013
7037
|
}
|
|
7014
|
-
const Ko = /* @__PURE__ */ T(Zo, [["render", Qo], ["__scopeId", "data-v-
|
|
7038
|
+
const Ko = /* @__PURE__ */ T(Zo, [["render", Qo], ["__scopeId", "data-v-8928221f"]]);
|
|
7015
7039
|
const es = {
|
|
7016
7040
|
name: "IdmGLV2",
|
|
7017
7041
|
components: {
|
|
@@ -7117,10 +7141,10 @@ const es = {
|
|
|
7117
7141
|
},
|
|
7118
7142
|
activeWeatherLayers: {
|
|
7119
7143
|
handler() {
|
|
7120
|
-
var a, e, t, r, i, o, s, n, c, d,
|
|
7144
|
+
var a, e, t, r, i, o, s, n, c, d, p, h, g, u, y, f, m, v;
|
|
7121
7145
|
if (!this.map)
|
|
7122
7146
|
return !1;
|
|
7123
|
-
this.activeWeatherLayers.length > 0 ? ((e = (a = this.map) == null ? void 0 : a.getLayer(this.enc)) == null || e.setLayoutProperty("visibility", "none"), (r = (t = this.map) == null ? void 0 : t.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id)) == null || r.setLayoutProperty("visibility", "visible"), (o = this.map) != null && o.getLayer((i = this.viewport) == null ? void 0 : i.rampColorLayer) && ((s = this.map) != null && s.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id)) && this.mapProjection === "mercator" && ((c = this.map) == null || c.moveLayer((n = this.viewport) == null ? void 0 : n.rampColorLayer, this.helper.mapboxCustomer.layers.countryBoundary.id)), (
|
|
7147
|
+
this.activeWeatherLayers.length > 0 ? ((e = (a = this.map) == null ? void 0 : a.getLayer(this.enc)) == null || e.setLayoutProperty("visibility", "none"), (r = (t = this.map) == null ? void 0 : t.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id)) == null || r.setLayoutProperty("visibility", "visible"), (o = this.map) != null && o.getLayer((i = this.viewport) == null ? void 0 : i.rampColorLayer) && ((s = this.map) != null && s.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id)) && this.mapProjection === "mercator" && ((c = this.map) == null || c.moveLayer((n = this.viewport) == null ? void 0 : n.rampColorLayer, this.helper.mapboxCustomer.layers.countryBoundary.id)), (p = this.map) != null && p.getLayer((d = this.viewport) == null ? void 0 : d.particleLayer) && ((h = this.map) != null && h.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id)) && this.mapProjection === "mercator" && ((u = this.map) == null || u.moveLayer((g = this.viewport) == null ? void 0 : g.particleLayer, this.helper.mapboxCustomer.layers.countryBoundary.id))) : ((f = (y = this.map) == null ? void 0 : y.getLayer(this.enc)) == null || f.setLayoutProperty("visibility", "visible"), (v = (m = this.map) == null ? void 0 : m.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id)) == null || v.setLayoutProperty("visibility", "none"));
|
|
7124
7148
|
},
|
|
7125
7149
|
immediate: !0
|
|
7126
7150
|
}
|
|
@@ -7167,7 +7191,7 @@ const es = {
|
|
|
7167
7191
|
},
|
|
7168
7192
|
methods: {
|
|
7169
7193
|
async fetchWeatherLayers(a = { tropicals: !1 }) {
|
|
7170
|
-
var i, o, s, n, c, d,
|
|
7194
|
+
var i, o, s, n, c, d, p, h;
|
|
7171
7195
|
const e = (/* @__PURE__ */ new Date()).valueOf();
|
|
7172
7196
|
let t = 0, r = 0;
|
|
7173
7197
|
if (this.map) {
|
|
@@ -7201,8 +7225,8 @@ const es = {
|
|
|
7201
7225
|
console.log(`[${w}] fetch layer error: ${A}`);
|
|
7202
7226
|
})
|
|
7203
7227
|
);
|
|
7204
|
-
const
|
|
7205
|
-
this.weatherLayers = {},
|
|
7228
|
+
const P = await Promise.all(_);
|
|
7229
|
+
this.weatherLayers = {}, P.map((w) => {
|
|
7206
7230
|
var $, W, O, J;
|
|
7207
7231
|
const A = (($ = w == null ? void 0 : w.data) == null ? void 0 : $.data) || (w == null ? void 0 : w.data), M = (O = (W = w == null ? void 0 : w.config) == null ? void 0 : W.headers) == null ? void 0 : O.key;
|
|
7208
7232
|
M && A && (this.weatherLayers[M] = {
|
|
@@ -7238,7 +7262,7 @@ const es = {
|
|
|
7238
7262
|
};
|
|
7239
7263
|
}
|
|
7240
7264
|
if (this.weatherLayers["current-direction"] || this.weatherLayers["current-speed"]) {
|
|
7241
|
-
const b = (
|
|
7265
|
+
const b = (p = this.weatherLayers["current-direction"]) == null ? void 0 : p.raw, _ = (h = this.weatherLayers["current-speed"]) == null ? void 0 : h.raw;
|
|
7242
7266
|
delete this.weatherLayers["current-direction"], delete this.weatherLayers["current-speed"], this.weatherLayers.current = {
|
|
7243
7267
|
type: "json",
|
|
7244
7268
|
direction: b,
|
|
@@ -7268,19 +7292,19 @@ const es = {
|
|
|
7268
7292
|
});
|
|
7269
7293
|
if (((e = n == null ? void 0 : n.data) == null ? void 0 : e.code) === 0) {
|
|
7270
7294
|
const c = (t = n == null ? void 0 : n.data) == null ? void 0 : t.data, d = [];
|
|
7271
|
-
for (const
|
|
7295
|
+
for (const h in c)
|
|
7272
7296
|
d.push(
|
|
7273
|
-
ne.get(c[
|
|
7297
|
+
ne.get(c[h], {
|
|
7274
7298
|
headers: {
|
|
7275
7299
|
Authorization: this.token || this.defaultMeteoToken,
|
|
7276
|
-
key:
|
|
7300
|
+
key: h
|
|
7277
7301
|
}
|
|
7278
7302
|
})
|
|
7279
7303
|
);
|
|
7280
|
-
const
|
|
7281
|
-
this.otherLayers = { enc: s },
|
|
7304
|
+
const p = await Promise.all(d);
|
|
7305
|
+
this.otherLayers = { enc: s }, p.map((h) => {
|
|
7282
7306
|
var y, f, m;
|
|
7283
|
-
const g = ((y =
|
|
7307
|
+
const g = ((y = h == null ? void 0 : h.data) == null ? void 0 : y.data) || (h == null ? void 0 : h.data), u = (m = (f = h == null ? void 0 : h.config) == null ? void 0 : f.headers) == null ? void 0 : m.key;
|
|
7284
7308
|
this.otherLayers[u] = g;
|
|
7285
7309
|
});
|
|
7286
7310
|
}
|
|
@@ -7292,18 +7316,18 @@ const es = {
|
|
|
7292
7316
|
});
|
|
7293
7317
|
if (((r = n == null ? void 0 : n.data) == null ? void 0 : r.code) === 0) {
|
|
7294
7318
|
const c = (i = n == null ? void 0 : n.data) == null ? void 0 : i.data, d = [];
|
|
7295
|
-
for (const
|
|
7319
|
+
for (const h in c)
|
|
7296
7320
|
d.push(
|
|
7297
|
-
ne.get(c[
|
|
7321
|
+
ne.get(c[h], {
|
|
7298
7322
|
headers: {
|
|
7299
7323
|
Authorization: this.token || this.defaultMeteoToken,
|
|
7300
|
-
key:
|
|
7324
|
+
key: h
|
|
7301
7325
|
}
|
|
7302
7326
|
})
|
|
7303
7327
|
);
|
|
7304
|
-
(await Promise.all(d)).map((
|
|
7328
|
+
(await Promise.all(d)).map((h) => {
|
|
7305
7329
|
var y, f, m;
|
|
7306
|
-
const g = ((y =
|
|
7330
|
+
const g = ((y = h == null ? void 0 : h.data) == null ? void 0 : y.data) || (h == null ? void 0 : h.data), u = (m = (f = h == null ? void 0 : h.config) == null ? void 0 : f.headers) == null ? void 0 : m.key;
|
|
7307
7331
|
this.otherLayers[u] = g;
|
|
7308
7332
|
});
|
|
7309
7333
|
}
|
|
@@ -7325,7 +7349,7 @@ const es = {
|
|
|
7325
7349
|
this.activeWindLayer = !!this.activeWeatherLayers.find((e) => e.key === "wind"), this.$refs.layer && (this.$refs.layer.activeWeatherLayers = this.activeWeatherLayers);
|
|
7326
7350
|
},
|
|
7327
7351
|
handleRampColorInitial() {
|
|
7328
|
-
var a, e, t, r, i, o, s, n, c, d,
|
|
7352
|
+
var a, e, t, r, i, o, s, n, c, d, p, h;
|
|
7329
7353
|
this.viewport.map.getSource((a = this.viewport) == null ? void 0 : a.rampColorSource) || this.viewport.map.addSource((e = this.viewport) == null ? void 0 : e.rampColorSource, {
|
|
7330
7354
|
type: "canvas",
|
|
7331
7355
|
canvas: (t = this.viewport) == null ? void 0 : t.rampColorCanvas,
|
|
@@ -7349,8 +7373,8 @@ const es = {
|
|
|
7349
7373
|
}), this.viewport.map.getLayer((d = this.viewport) == null ? void 0 : d.particleLayer) || this.viewport.map.addLayer(
|
|
7350
7374
|
{
|
|
7351
7375
|
type: "raster",
|
|
7352
|
-
id: (
|
|
7353
|
-
source: (
|
|
7376
|
+
id: (p = this.viewport) == null ? void 0 : p.particleLayer,
|
|
7377
|
+
source: (h = this.viewport) == null ? void 0 : h.particleSource,
|
|
7354
7378
|
layout: {
|
|
7355
7379
|
visibility: "none"
|
|
7356
7380
|
}
|
|
@@ -7359,7 +7383,7 @@ const es = {
|
|
|
7359
7383
|
);
|
|
7360
7384
|
},
|
|
7361
7385
|
handleDragEndWithZoom4Json() {
|
|
7362
|
-
var d,
|
|
7386
|
+
var d, p, h, g;
|
|
7363
7387
|
const a = (/* @__PURE__ */ new Date()).valueOf();
|
|
7364
7388
|
let e = 0, t = 0;
|
|
7365
7389
|
const r = (d = this.map) == null ? void 0 : d.getBounds(), i = this.map.getZoom(), o = D.convertToStdLng(r._sw.lng), s = D.convertToStdLng(r._ne.lng), n = Math.floor(r._sw.lat), c = Math.ceil(r._ne.lat);
|
|
@@ -7368,25 +7392,25 @@ const es = {
|
|
|
7368
7392
|
this.weatherLayers[u].active = !1, this.weatherLayers[u].version = Math.random() + 1;
|
|
7369
7393
|
let y = [];
|
|
7370
7394
|
if (["swell", "current"].includes(u)) {
|
|
7371
|
-
const f = ((
|
|
7395
|
+
const f = ((p = this.weatherLayers[u]) == null ? void 0 : p.direction) || {};
|
|
7372
7396
|
for (const m in f)
|
|
7373
7397
|
if (m > n && m < c && (!(i <= this.zoom) || m % (i < this.zoom / 2 ? 5 : 3) === 0)) {
|
|
7374
7398
|
const v = f[m].lng;
|
|
7375
7399
|
o > s ? v.forEach((b, _) => {
|
|
7376
|
-
var
|
|
7400
|
+
var P;
|
|
7377
7401
|
if ((b >= o && b <= 180 || b >= -180 && b <= s) && (!(i <= this.zoom) || b % (i < this.zoom / 2 ? 5 : 3) === 0)) {
|
|
7378
7402
|
const w = L.point([b, m], {
|
|
7379
7403
|
val: f[m].val[_],
|
|
7380
|
-
spd: (
|
|
7404
|
+
spd: (P = f[m].spd) == null ? void 0 : P[_]
|
|
7381
7405
|
});
|
|
7382
7406
|
y.push(w);
|
|
7383
7407
|
}
|
|
7384
7408
|
}) : v.forEach((b, _) => {
|
|
7385
|
-
var
|
|
7409
|
+
var P;
|
|
7386
7410
|
if (b >= o && b <= s && (!(i <= this.zoom) || b % (i < this.zoom / 2 ? 5 : 3) === 0)) {
|
|
7387
7411
|
const w = L.point([b, m], {
|
|
7388
7412
|
val: f[m].val[_],
|
|
7389
|
-
spd: (
|
|
7413
|
+
spd: (P = f[m].spd) == null ? void 0 : P[_]
|
|
7390
7414
|
});
|
|
7391
7415
|
y.push(w);
|
|
7392
7416
|
}
|
|
@@ -7397,11 +7421,11 @@ const es = {
|
|
|
7397
7421
|
if (m) {
|
|
7398
7422
|
if (!m.data) {
|
|
7399
7423
|
const v = [];
|
|
7400
|
-
for (const b in (
|
|
7424
|
+
for (const b in (h = m.raw) == null ? void 0 : h.LineString) {
|
|
7401
7425
|
const _ = m.raw.LineString[b];
|
|
7402
|
-
for (const
|
|
7426
|
+
for (const P of _)
|
|
7403
7427
|
v.push(
|
|
7404
|
-
L.lineString(
|
|
7428
|
+
L.lineString(P, {
|
|
7405
7429
|
val: Number(b)
|
|
7406
7430
|
})
|
|
7407
7431
|
);
|
|
@@ -7421,8 +7445,8 @@ const es = {
|
|
|
7421
7445
|
if (!m.data) {
|
|
7422
7446
|
const b = [];
|
|
7423
7447
|
for (const _ in (g = m.raw) == null ? void 0 : g.Polygon) {
|
|
7424
|
-
const
|
|
7425
|
-
for (const w of
|
|
7448
|
+
const P = m.raw.Polygon[_];
|
|
7449
|
+
for (const w of P)
|
|
7426
7450
|
b.push(
|
|
7427
7451
|
L.polygon(w, {
|
|
7428
7452
|
val: Number(_)
|
|
@@ -7442,19 +7466,19 @@ const es = {
|
|
|
7442
7466
|
const v = f[m].lng;
|
|
7443
7467
|
o > s ? v.forEach((b, _) => {
|
|
7444
7468
|
if ((b >= o && b <= 180 || b >= -180 && b <= s) && (!(i <= this.zoom) || b % (i < this.zoom / 2 ? 5 : 3) === 0)) {
|
|
7445
|
-
const
|
|
7469
|
+
const P = L.point([b, m], {
|
|
7446
7470
|
val: f[m].val[_],
|
|
7447
7471
|
spd: f[m].spd[_]
|
|
7448
7472
|
});
|
|
7449
|
-
y.push(
|
|
7473
|
+
y.push(P);
|
|
7450
7474
|
}
|
|
7451
7475
|
}) : v.forEach((b, _) => {
|
|
7452
7476
|
if (b >= o && b <= s && (!(i <= this.zoom) || b % (i < this.zoom / 2 ? 5 : 3) === 0)) {
|
|
7453
|
-
const
|
|
7477
|
+
const P = L.point([b, m], {
|
|
7454
7478
|
val: f[m].val[_],
|
|
7455
7479
|
spd: f[m].spd[_]
|
|
7456
7480
|
});
|
|
7457
|
-
y.push(
|
|
7481
|
+
y.push(P);
|
|
7458
7482
|
}
|
|
7459
7483
|
});
|
|
7460
7484
|
}
|
|
@@ -7571,8 +7595,8 @@ const es = {
|
|
|
7571
7595
|
this.handleBeforeLayerToggle();
|
|
7572
7596
|
},
|
|
7573
7597
|
handleBeforeLayerToggle() {
|
|
7574
|
-
var a, e, t, r, i, o, s, n, c, d,
|
|
7575
|
-
(a = this.map) != null && a.getLayer(this.beforeLayer) && ((e = this.activeWeatherLayers) != null && e.length || (t = this.otherLayers) != null && t["war-zones"] || (r = this.otherLayers) != null && r["gmdss-areas"] || (i = this.otherLayers) != null && i["load-lines"] || (o = this.otherLayers) != null && o["high-risk-area"] || (s = this.otherLayers) != null && s["time-zones"] || (n = this.otherLayers) != null && n.pirates || (c = this.otherLayers) != null && c.ports || (d = this.otherLayers) != null && d.enc || (
|
|
7598
|
+
var a, e, t, r, i, o, s, n, c, d, p, h, g;
|
|
7599
|
+
(a = this.map) != null && a.getLayer(this.beforeLayer) && ((e = this.activeWeatherLayers) != null && e.length || (t = this.otherLayers) != null && t["war-zones"] || (r = this.otherLayers) != null && r["gmdss-areas"] || (i = this.otherLayers) != null && i["load-lines"] || (o = this.otherLayers) != null && o["high-risk-area"] || (s = this.otherLayers) != null && s["time-zones"] || (n = this.otherLayers) != null && n.pirates || (c = this.otherLayers) != null && c.ports || (d = this.otherLayers) != null && d.enc || (p = this.otherLayers) != null && p["voluntary-reporting-area"] || (h = this.otherLayers) != null && h["eca-zones"] || (g = this.otherLayers) != null && g["special-area"]) && this.map.setLayoutProperty(this.beforeLayer, "visibility", "visible");
|
|
7576
7600
|
},
|
|
7577
7601
|
handleDateChange(a = { tropicals: !1 }) {
|
|
7578
7602
|
this.fetchWeatherLayers(a), this.fetchOtherLayers({ dayNight: !0 });
|
|
@@ -7626,8 +7650,8 @@ const es = {
|
|
|
7626
7650
|
});
|
|
7627
7651
|
},
|
|
7628
7652
|
handle3dToggle(a) {
|
|
7629
|
-
var e, t, r, i, o, s, n, c, d,
|
|
7630
|
-
a ? (this.map.setProjection("globe"), this.mapProjection = "globe", (t = this.map) != null && t.getLayer((e = this.viewport) == null ? void 0 : e.rampColorLayer) && ((r = this.map) != null && r.getLayer(this.helper.mapboxCustomer.layers.water.id)) && ((o = this.map) == null || o.moveLayer((i = this.viewport) == null ? void 0 : i.rampColorLayer, this.helper.mapboxCustomer.layers.water.id)), (n = this.map) != null && n.getLayer((s = this.viewport) == null ? void 0 : s.particleLayer) && ((c = this.map) != null && c.getLayer(this.helper.mapboxCustomer.layers.water.id)) && ((
|
|
7653
|
+
var e, t, r, i, o, s, n, c, d, p, h, g, u, y, f, m, v, b, _, P;
|
|
7654
|
+
a ? (this.map.setProjection("globe"), this.mapProjection = "globe", (t = this.map) != null && t.getLayer((e = this.viewport) == null ? void 0 : e.rampColorLayer) && ((r = this.map) != null && r.getLayer(this.helper.mapboxCustomer.layers.water.id)) && ((o = this.map) == null || o.moveLayer((i = this.viewport) == null ? void 0 : i.rampColorLayer, this.helper.mapboxCustomer.layers.water.id)), (n = this.map) != null && n.getLayer((s = this.viewport) == null ? void 0 : s.particleLayer) && ((c = this.map) != null && c.getLayer(this.helper.mapboxCustomer.layers.water.id)) && ((p = this.map) == null || p.moveLayer((d = this.viewport) == null ? void 0 : d.particleLayer, this.helper.mapboxCustomer.layers.water.id)), this.map.off("zoomend", this.handleDragEndWithZoom4Json), this.map.off("dragend", this.handleDragEndWithZoom4Json), this.map.off("move", this.handleDragEndWithZoom4Image)) : (this.map.setProjection("mercator"), this.mapProjection = "mercator", this.map.on("zoomend", this.handleDragEndWithZoom4Json), this.map.on("dragend", this.handleDragEndWithZoom4Json), this.map.on("move", this.handleDragEndWithZoom4Image), this.handleDragEndWithZoom4Image(), this.handleDragEndWithZoom4Json(), (g = this.map) != null && g.getLayer((h = this.viewport) == null ? void 0 : h.rampColorLayer) && ((u = this.map) != null && u.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id)) && ((f = this.map) == null || f.moveLayer((y = this.viewport) == null ? void 0 : y.rampColorLayer, this.helper.mapboxCustomer.layers.countryBoundary.id)), (v = this.map) != null && v.getLayer((m = this.viewport) == null ? void 0 : m.particleLayer) && ((b = this.map) != null && b.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id)) && ((P = this.map) == null || P.moveLayer((_ = this.viewport) == null ? void 0 : _.particleLayer, this.helper.mapboxCustomer.layers.countryBoundary.id)));
|
|
7631
7655
|
},
|
|
7632
7656
|
handleParticle(a) {
|
|
7633
7657
|
this.particleFactor = a, this.weatherLayers[a.key] && (this.weatherLayers[a.key].particle = a.particle), this.activeWeatherLayers.forEach((r) => {
|
|
@@ -7648,8 +7672,8 @@ const es = {
|
|
|
7648
7672
|
className: "map-gl-home"
|
|
7649
7673
|
};
|
|
7650
7674
|
function as(a, e, t, r, i, o) {
|
|
7651
|
-
var ie, X,
|
|
7652
|
-
const s =
|
|
7675
|
+
var ie, X, q, be, Q, I, F, ve, K, we, re, oe, se, Pe, Te, Ie, Ee, Re, We, Ze, He, Ge, Je, Xe, Ye, qe;
|
|
7676
|
+
const s = z("IdmGlLayer"), n = z("IdmENC"), c = z("IdmSigWave"), d = z("IdmSwell"), p = z("IdmPrmsl"), h = z("IdmIceberg"), g = z("IdmTropicals"), u = z("IdmCurrents"), y = z("IdmCurrentParticle"), f = z("IdmWindBarb"), m = z("IdmWindParticle"), v = z("IdmPrecip3h"), b = z("IdmVisibility"), _ = z("IdmWaterTemp"), P = z("IdmTemp"), w = z("IdmArctic"), A = z("IdmWarZone"), M = z("IdmGmdssArea"), $ = z("IdmEcaZone"), W = z("IdmAlertZone"), O = z("IdmPort"), J = z("IdmLoadLine"), de = z("IdmTimezone"), pe = z("IdmVRA"), me = z("IdmSpecialArea"), ue = z("IdmTerminator"), ye = z("IdmLatLng"), fe = z("IdmMeasure"), ge = z("IdmPoint");
|
|
7653
7677
|
return t.map ? (x(), C("div", ts, [
|
|
7654
7678
|
k(s, E({
|
|
7655
7679
|
ref: "layer",
|
|
@@ -7680,18 +7704,18 @@ function as(a, e, t, r, i, o) {
|
|
|
7680
7704
|
}, a.$attrs), null, 16, ["map", "sig-wave", "before-layer"]),
|
|
7681
7705
|
k(d, E({
|
|
7682
7706
|
map: t.map,
|
|
7683
|
-
swell: (
|
|
7707
|
+
swell: (q = i.weatherLayers) == null ? void 0 : q.swell,
|
|
7684
7708
|
"before-layer": t.beforeLayer
|
|
7685
7709
|
}, a.$attrs), null, 16, ["map", "swell", "before-layer"]),
|
|
7686
|
-
k(
|
|
7710
|
+
k(p, E({
|
|
7687
7711
|
map: t.map,
|
|
7688
7712
|
prmsl: (be = i.weatherLayers) == null ? void 0 : be.prmsl,
|
|
7689
7713
|
"before-layer": t.beforeLayer,
|
|
7690
7714
|
"active-weather-layers": i.activeWeatherLayers
|
|
7691
7715
|
}, a.$attrs), null, 16, ["map", "prmsl", "before-layer", "active-weather-layers"]),
|
|
7692
|
-
k(
|
|
7716
|
+
k(h, E({
|
|
7693
7717
|
map: t.map,
|
|
7694
|
-
iceberg: (
|
|
7718
|
+
iceberg: (Q = i.weatherLayers) == null ? void 0 : Q.iceberg,
|
|
7695
7719
|
"before-layer": t.beforeLayer
|
|
7696
7720
|
}, a.$attrs), null, 16, ["map", "iceberg", "before-layer"]),
|
|
7697
7721
|
k(g, E({
|
|
@@ -7723,7 +7747,7 @@ function as(a, e, t, r, i, o) {
|
|
|
7723
7747
|
ref: "windBarb",
|
|
7724
7748
|
map: t.map,
|
|
7725
7749
|
"map-projection": i.mapProjection,
|
|
7726
|
-
wind: (
|
|
7750
|
+
wind: (K = i.weatherLayers) == null ? void 0 : K.wind,
|
|
7727
7751
|
current: (we = i.weatherLayers) == null ? void 0 : we.current,
|
|
7728
7752
|
"before-layer": t.beforeLayer,
|
|
7729
7753
|
"margin-bottom": i.showRampColor ? "56px" : "30px",
|
|
@@ -7757,7 +7781,7 @@ function as(a, e, t, r, i, o) {
|
|
|
7757
7781
|
"before-layer": t.beforeLayer,
|
|
7758
7782
|
"toggle-version": t.toggleVersion
|
|
7759
7783
|
}, a.$attrs), null, 16, ["viewport", "factor", "before-layer", "toggle-version"]),
|
|
7760
|
-
k(
|
|
7784
|
+
k(P, E({
|
|
7761
7785
|
viewport: i.viewport,
|
|
7762
7786
|
factor: (Te = i.weatherLayers) == null ? void 0 : Te.temp,
|
|
7763
7787
|
"before-layer": t.beforeLayer,
|
|
@@ -7832,7 +7856,7 @@ function as(a, e, t, r, i, o) {
|
|
|
7832
7856
|
show: i.showPoint,
|
|
7833
7857
|
meteo: i.meteo
|
|
7834
7858
|
}, a.$attrs, { onPoint: o.handlePointChange }), null, 16, ["map", "show", "meteo", "onPoint"])
|
|
7835
|
-
])) :
|
|
7859
|
+
])) : j("", !0);
|
|
7836
7860
|
}
|
|
7837
7861
|
const is = /* @__PURE__ */ T(es, [["render", as]]), ds = {
|
|
7838
7862
|
install(a) {
|
|
@@ -7848,5 +7872,5 @@ export {
|
|
|
7848
7872
|
Ke as TropicalGL,
|
|
7849
7873
|
Ve as Viewport,
|
|
7850
7874
|
Le as WebGL,
|
|
7851
|
-
|
|
7875
|
+
B as WebGLSchema
|
|
7852
7876
|
};
|