@idmwx/idmui-gl3 4.4.4 → 4.4.6
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 +251 -223
- 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
|
]),
|
|
@@ -676,11 +678,12 @@ function Ut(a, e, t, r, i, o) {
|
|
|
676
678
|
k(s, {
|
|
677
679
|
placement: "left",
|
|
678
680
|
effect: "light",
|
|
679
|
-
content: "Measure"
|
|
681
|
+
content: "Measure",
|
|
682
|
+
"show-after": 2e3
|
|
680
683
|
}, {
|
|
681
|
-
default:
|
|
684
|
+
default: Y(() => [
|
|
682
685
|
l("div", {
|
|
683
|
-
class:
|
|
686
|
+
class: N(i.showMeasure ? "menu-icon active" : "menu-icon"),
|
|
684
687
|
onClick: e[1] || (e[1] = (...h) => o.handleMeasureToggle && o.handleMeasureToggle(...h))
|
|
685
688
|
}, yt, 2)
|
|
686
689
|
]),
|
|
@@ -689,11 +692,12 @@ function Ut(a, e, t, r, i, o) {
|
|
|
689
692
|
k(s, {
|
|
690
693
|
placement: "left",
|
|
691
694
|
effect: "light",
|
|
692
|
-
content: "Point Meteo"
|
|
695
|
+
content: "Point Meteo",
|
|
696
|
+
"show-after": 2e3
|
|
693
697
|
}, {
|
|
694
|
-
default:
|
|
698
|
+
default: Y(() => [
|
|
695
699
|
l("div", {
|
|
696
|
-
class:
|
|
700
|
+
class: N(i.showPoint ? "menu-icon active" : "menu-icon"),
|
|
697
701
|
onClick: e[2] || (e[2] = (...h) => o.handlePointToggle && o.handlePointToggle(...h))
|
|
698
702
|
}, gt, 2)
|
|
699
703
|
]),
|
|
@@ -702,11 +706,12 @@ function Ut(a, e, t, r, i, o) {
|
|
|
702
706
|
k(s, {
|
|
703
707
|
placement: "left",
|
|
704
708
|
effect: "light",
|
|
705
|
-
content: "Grid"
|
|
709
|
+
content: "Grid",
|
|
710
|
+
"show-after": 2e3
|
|
706
711
|
}, {
|
|
707
|
-
default:
|
|
712
|
+
default: Y(() => [
|
|
708
713
|
l("div", {
|
|
709
|
-
class:
|
|
714
|
+
class: N(i.showCoord ? "menu-icon active" : "menu-icon"),
|
|
710
715
|
onClick: e[3] || (e[3] = (...h) => o.handleCoordToggle && o.handleCoordToggle(...h))
|
|
711
716
|
}, vt, 2)
|
|
712
717
|
]),
|
|
@@ -715,11 +720,12 @@ function Ut(a, e, t, r, i, o) {
|
|
|
715
720
|
k(s, {
|
|
716
721
|
placement: "left",
|
|
717
722
|
effect: "light",
|
|
718
|
-
content: "3D"
|
|
723
|
+
content: "3D",
|
|
724
|
+
"show-after": 2e3
|
|
719
725
|
}, {
|
|
720
|
-
default:
|
|
726
|
+
default: Y(() => [
|
|
721
727
|
l("div", {
|
|
722
|
-
class:
|
|
728
|
+
class: N(i.show3d ? "menu-icon active" : "menu-icon"),
|
|
723
729
|
onClick: e[4] || (e[4] = (...h) => o.handle3DToggle && o.handle3DToggle(...h))
|
|
724
730
|
}, _t, 2)
|
|
725
731
|
]),
|
|
@@ -727,25 +733,26 @@ function Ut(a, e, t, r, i, o) {
|
|
|
727
733
|
})
|
|
728
734
|
])
|
|
729
735
|
], 4),
|
|
730
|
-
|
|
736
|
+
((p = i.layers.weather.filter((h) => h.collected)) == null ? void 0 : p.length) > 0 ? (x(), C("div", {
|
|
737
|
+
key: 0,
|
|
731
738
|
class: "active-layers",
|
|
732
739
|
style: U({ right: i.right + "px", bottom: "100px" })
|
|
733
740
|
}, [
|
|
734
741
|
(x(!0), C(Ae, null, $e(i.layers.weather.filter((h) => h.collected), (h) => (x(), C("div", {
|
|
735
742
|
key: h.key,
|
|
736
|
-
class:
|
|
737
|
-
onClick: (
|
|
743
|
+
class: N(o.computeLayerClass(h, i.activeWeatherLayers)),
|
|
744
|
+
onClick: (g) => o.handleActiveWeatherLayerPick(h)
|
|
738
745
|
}, [
|
|
739
746
|
xt,
|
|
740
747
|
l("span", null, S(h.name), 1)
|
|
741
748
|
], 10, Lt))), 128))
|
|
742
|
-
], 4),
|
|
749
|
+
], 4)) : j("", !0),
|
|
743
750
|
l("div", {
|
|
744
751
|
class: "available-layers flex-center",
|
|
745
752
|
style: U({ top: t.top + "px", right: t.layerToggle ? "0px" : "-240px" })
|
|
746
753
|
}, [
|
|
747
754
|
l("div", {
|
|
748
|
-
class:
|
|
755
|
+
class: N(["list-box", t.layerToggle ? "right-bar" : ""])
|
|
749
756
|
}, [
|
|
750
757
|
l("div", Ct, [
|
|
751
758
|
kt,
|
|
@@ -755,26 +762,26 @@ function Ut(a, e, t, r, i, o) {
|
|
|
755
762
|
}, "")
|
|
756
763
|
]),
|
|
757
764
|
k(d, { style: { flex: "1" } }, {
|
|
758
|
-
default:
|
|
765
|
+
default: Y(() => [
|
|
759
766
|
l("div", St, [
|
|
760
767
|
zt,
|
|
761
768
|
l("div", Pt, [
|
|
762
769
|
(x(!0), C(Ae, null, $e(i.layers.weather, (h) => (x(), C(Ae, {
|
|
763
770
|
key: h.key
|
|
764
771
|
}, [
|
|
765
|
-
h.hide ?
|
|
772
|
+
h.hide ? j("", !0) : (x(), C("div", {
|
|
766
773
|
key: 0,
|
|
767
|
-
class:
|
|
774
|
+
class: N(o.computeLayerClass(h, i.weatherLayers))
|
|
768
775
|
}, [
|
|
769
776
|
l("div", {
|
|
770
777
|
class: "flex-start",
|
|
771
|
-
onClick: (
|
|
778
|
+
onClick: (g) => o.handleWeatherLayerPick(h)
|
|
772
779
|
}, [
|
|
773
780
|
It,
|
|
774
781
|
l("span", null, S(h.name), 1)
|
|
775
782
|
], 8, Tt),
|
|
776
783
|
l("div", {
|
|
777
|
-
onClick: (
|
|
784
|
+
onClick: (g) => o.handleWeatherLayerCollect(h)
|
|
778
785
|
}, [
|
|
779
786
|
h.collected ? (x(), C("i", Rt, "")) : (x(), C("i", At, ""))
|
|
780
787
|
], 8, Et)
|
|
@@ -788,8 +795,8 @@ function Ut(a, e, t, r, i, o) {
|
|
|
788
795
|
l("div", jt, [
|
|
789
796
|
(x(!0), C(Ae, null, $e(i.layers.other, (h) => (x(), C("div", {
|
|
790
797
|
key: h.key,
|
|
791
|
-
class:
|
|
792
|
-
onClick: (
|
|
798
|
+
class: N(o.computeLayerClass(h, i.otherLayers)),
|
|
799
|
+
onClick: (g) => o.handleOtherLayerPick(h)
|
|
793
800
|
}, [
|
|
794
801
|
l("div", Bt, [
|
|
795
802
|
Wt,
|
|
@@ -806,15 +813,15 @@ function Ut(a, e, t, r, i, o) {
|
|
|
806
813
|
"onUpdate:modelValue": e[6] || (e[6] = (h) => i.source = h),
|
|
807
814
|
class: "layer-radio flex-col-center-start"
|
|
808
815
|
}, {
|
|
809
|
-
default:
|
|
816
|
+
default: Y(() => [
|
|
810
817
|
k(n, { value: "GFS" }, {
|
|
811
|
-
default:
|
|
818
|
+
default: Y(() => [
|
|
812
819
|
Fe("GFS")
|
|
813
820
|
]),
|
|
814
821
|
_: 1
|
|
815
822
|
}),
|
|
816
823
|
k(n, { value: "CMEMS" }, {
|
|
817
|
-
default:
|
|
824
|
+
default: Y(() => [
|
|
818
825
|
Fe("CMEMS")
|
|
819
826
|
]),
|
|
820
827
|
_: 1
|
|
@@ -893,7 +900,7 @@ const Ht = {
|
|
|
893
900
|
toggleVersion: {
|
|
894
901
|
handler() {
|
|
895
902
|
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) +
|
|
903
|
+
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
904
|
},
|
|
898
905
|
immediate: !0
|
|
899
906
|
}
|
|
@@ -916,22 +923,22 @@ const Ht = {
|
|
|
916
923
|
else {
|
|
917
924
|
this.map.addSource(this.source, { type: "geojson", data: n });
|
|
918
925
|
for (let c = 0; c < (this.barbs ?? []).length - 1; c++) {
|
|
919
|
-
const d = (this.barbs ?? [])[c] || 0,
|
|
926
|
+
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
927
|
this.map.addLayer(
|
|
921
928
|
{
|
|
922
|
-
id:
|
|
929
|
+
id: h,
|
|
923
930
|
type: "symbol",
|
|
924
931
|
filter: [
|
|
925
932
|
"all",
|
|
926
933
|
// @ts-ignore
|
|
927
934
|
[">=", "spd", d],
|
|
928
935
|
// @ts-ignore
|
|
929
|
-
["<", "spd",
|
|
936
|
+
["<", "spd", p]
|
|
930
937
|
],
|
|
931
938
|
source: this.source,
|
|
932
939
|
layout: {
|
|
933
940
|
"symbol-placement": "point",
|
|
934
|
-
"icon-image":
|
|
941
|
+
"icon-image": h,
|
|
935
942
|
// mapbox sprite
|
|
936
943
|
"icon-size": 0.14,
|
|
937
944
|
"icon-offset": [0, -20],
|
|
@@ -990,15 +997,15 @@ function ea(a, e, t, r, i, o) {
|
|
|
990
997
|
}, [
|
|
991
998
|
t.mapProjection === "mercator" ? (x(), C("div", {
|
|
992
999
|
key: 0,
|
|
993
|
-
class:
|
|
1000
|
+
class: N(["item-bar flex-start", t.showParticle ? "active" : "inactive"]),
|
|
994
1001
|
onClick: e[0] || (e[0] = (...n) => o.handleParticle && o.handleParticle(...n))
|
|
995
|
-
}, Yt, 2)) :
|
|
1002
|
+
}, Yt, 2)) : j("", !0),
|
|
996
1003
|
l("div", {
|
|
997
|
-
class:
|
|
1004
|
+
class: N(["item-bar flex-start", i.showFeather ? "active" : "inactive"]),
|
|
998
1005
|
onClick: e[1] || (e[1] = (n) => i.showFeather = !i.showFeather)
|
|
999
1006
|
}, Kt, 2)
|
|
1000
1007
|
], 4)
|
|
1001
|
-
])) :
|
|
1008
|
+
])) : j("", !0);
|
|
1002
1009
|
}
|
|
1003
1010
|
const ta = /* @__PURE__ */ T(Ht, [["render", ea]]);
|
|
1004
1011
|
class Ve {
|
|
@@ -1046,8 +1053,8 @@ class Ve {
|
|
|
1046
1053
|
* @param [lb.x, lb.y, rt.x, rt.y]
|
|
1047
1054
|
*/
|
|
1048
1055
|
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 [
|
|
1056
|
+
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));
|
|
1057
|
+
return [h, g, d + u, p];
|
|
1051
1058
|
}
|
|
1052
1059
|
/**
|
|
1053
1060
|
* [视窗边界像素宽度]
|
|
@@ -1062,13 +1069,13 @@ class Ve {
|
|
|
1062
1069
|
* @param zoom
|
|
1063
1070
|
*/
|
|
1064
1071
|
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 [
|
|
1072
|
+
const r = 2 ** t, [i, o, s, n] = e.map((p) => ~~(p / (r * 256))), c = [];
|
|
1073
|
+
for (let p = n; p <= o; p++)
|
|
1074
|
+
for (let h = i; h <= s; h++)
|
|
1075
|
+
c.push([h, p]);
|
|
1076
|
+
return c.map((p) => {
|
|
1077
|
+
const h = 2 ** t * 256;
|
|
1078
|
+
return [p[0] * h, p[1] * h, h];
|
|
1072
1079
|
});
|
|
1073
1080
|
}
|
|
1074
1081
|
resize() {
|
|
@@ -1171,8 +1178,8 @@ class Le {
|
|
|
1171
1178
|
const n = s.getContext("2d");
|
|
1172
1179
|
if (n && e) {
|
|
1173
1180
|
const c = n == null ? void 0 : n.createLinearGradient(0, 0, 256, 0);
|
|
1174
|
-
return t.forEach(([d,
|
|
1175
|
-
c.addColorStop(d,
|
|
1181
|
+
return t.forEach(([d, p]) => {
|
|
1182
|
+
c.addColorStop(d, p);
|
|
1176
1183
|
}), n.fillStyle = c, n.fillRect(0, 0, 256, 1), {
|
|
1177
1184
|
canvas: s,
|
|
1178
1185
|
texture: this.createTexture(
|
|
@@ -1189,11 +1196,11 @@ class Le {
|
|
|
1189
1196
|
}
|
|
1190
1197
|
setupParticle(e, t = 1e3) {
|
|
1191
1198
|
const r = Math.ceil(Math.sqrt(t)), i = r * r, o = new Uint8Array(i * 4);
|
|
1192
|
-
for (let
|
|
1193
|
-
o[
|
|
1199
|
+
for (let p = 0; p < o.length; p++)
|
|
1200
|
+
o[p] = Math.floor(Math.random() * 256);
|
|
1194
1201
|
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[
|
|
1202
|
+
for (let p = 0; p < i; p++)
|
|
1203
|
+
c[p] = p;
|
|
1197
1204
|
const d = this.createDataBuffer(e, "array", c);
|
|
1198
1205
|
return { resolution: r, total: i, texture0: s, texture1: n, indexBuffer: d };
|
|
1199
1206
|
}
|
|
@@ -1210,26 +1217,26 @@ class Le {
|
|
|
1210
1217
|
return {};
|
|
1211
1218
|
}
|
|
1212
1219
|
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:
|
|
1220
|
+
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();
|
|
1221
|
+
return { particle: n, screen: c, update: d, quadBuffer: p, frameBuffer: h };
|
|
1215
1222
|
}
|
|
1216
1223
|
draw(e, t, r, i, o, s, n) {
|
|
1217
1224
|
var c, d;
|
|
1218
1225
|
if (t && r) {
|
|
1219
1226
|
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
1227
|
try {
|
|
1221
|
-
const
|
|
1222
|
-
if (t.useProgram(r), t.uniform2f(
|
|
1228
|
+
const p = t.getUniformLocation(r, "u_resolution"), h = t.getUniformLocation(r, "u_image"), g = t.getUniformLocation(r, "u_color");
|
|
1229
|
+
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
1230
|
const m = t.getUniformLocation(r, "u_range_u_v"), v = t.getUniformLocation(r, "u_range_s");
|
|
1224
1231
|
t.uniform2f(m, n.uvRange[0], n.uvRange[1]), t.uniform2f(v, n.sRange[0], n.sRange[1]);
|
|
1225
1232
|
}
|
|
1226
1233
|
const u = e.getBoundPixel(), y = e.map.getZoom() + 1, f = e.getWorldCopy(u, y);
|
|
1227
1234
|
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, [
|
|
1235
|
+
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
1236
|
t.bindBuffer(t.ARRAY_BUFFER, s), t.bufferData(t.ARRAY_BUFFER, $, t.STATIC_DRAW), t.drawArrays(t.TRIANGLES, 0, 6);
|
|
1230
1237
|
}
|
|
1231
|
-
} catch (
|
|
1232
|
-
console.log(`render failed...${
|
|
1238
|
+
} catch (p) {
|
|
1239
|
+
console.log(`render failed...${p}`);
|
|
1233
1240
|
}
|
|
1234
1241
|
}
|
|
1235
1242
|
}
|
|
@@ -1274,10 +1281,10 @@ class Le {
|
|
|
1274
1281
|
});
|
|
1275
1282
|
}
|
|
1276
1283
|
}
|
|
1277
|
-
class
|
|
1284
|
+
class B {
|
|
1278
1285
|
}
|
|
1279
1286
|
// 顶点渲染
|
|
1280
|
-
R(
|
|
1287
|
+
R(B, "vertexSchema", `
|
|
1281
1288
|
//canvas 坐标系上的坐标 (x, y)
|
|
1282
1289
|
attribute vec2 a_position; //像素坐标
|
|
1283
1290
|
attribute vec2 a_texCoord; //纹理坐标
|
|
@@ -1292,7 +1299,7 @@ R(N, "vertexSchema", `
|
|
|
1292
1299
|
gl_Position = vec4(position * vec2(1, -1), 0.0, 1.0);
|
|
1293
1300
|
v_texCoord = a_texCoord;
|
|
1294
1301
|
}`), // 类如风、流等u v双变量片元渲染
|
|
1295
|
-
R(
|
|
1302
|
+
R(B, "uvFragmentSchema", `
|
|
1296
1303
|
precision mediump float;
|
|
1297
1304
|
uniform sampler2D u_image;
|
|
1298
1305
|
uniform vec2 u_range_u_v;
|
|
@@ -1311,7 +1318,7 @@ R(N, "uvFragmentSchema", `
|
|
|
1311
1318
|
|
|
1312
1319
|
gl_FragColor = color;
|
|
1313
1320
|
}`), // 类如浪、气压等单变量片元渲染
|
|
1314
|
-
R(
|
|
1321
|
+
R(B, "fragmentSchema", `
|
|
1315
1322
|
precision mediump float;
|
|
1316
1323
|
uniform sampler2D u_image; // 灰度
|
|
1317
1324
|
uniform sampler2D u_color; // 色值映射
|
|
@@ -3189,7 +3196,7 @@ const ia = {
|
|
|
3189
3196
|
[1, "rgb(91, 136, 161)"]
|
|
3190
3197
|
];
|
|
3191
3198
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
3192
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
3199
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.uvFragmentSchema);
|
|
3193
3200
|
this.program = e, this.aPositionBuffer = t;
|
|
3194
3201
|
}
|
|
3195
3202
|
this.handleParticleSetup();
|
|
@@ -3254,7 +3261,7 @@ function ua(a, e, t, r, i, o) {
|
|
|
3254
3261
|
class: "legend-bars flex-center",
|
|
3255
3262
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
3256
3263
|
}, ma, 4)
|
|
3257
|
-
])) :
|
|
3264
|
+
])) : j("", !0);
|
|
3258
3265
|
}
|
|
3259
3266
|
const ya = /* @__PURE__ */ T(ia, [["render", ua], ["__scopeId", "data-v-64887571"]]);
|
|
3260
3267
|
const fa = {
|
|
@@ -3320,7 +3327,7 @@ const fa = {
|
|
|
3320
3327
|
toggleVersion: {
|
|
3321
3328
|
handler() {
|
|
3322
3329
|
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) +
|
|
3330
|
+
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
3331
|
},
|
|
3325
3332
|
immediate: !0
|
|
3326
3333
|
}
|
|
@@ -3423,15 +3430,15 @@ function Ca(a, e, t, r, i, o) {
|
|
|
3423
3430
|
}, [
|
|
3424
3431
|
t.mapProjection === "mercator" ? (x(), C("div", {
|
|
3425
3432
|
key: 0,
|
|
3426
|
-
class:
|
|
3433
|
+
class: N(["flex-start item-bar", t.showParticle ? "active" : "inactive"]),
|
|
3427
3434
|
onClick: e[0] || (e[0] = (n) => o.handleParticle(!t.showParticle))
|
|
3428
|
-
}, wa, 2)) :
|
|
3435
|
+
}, wa, 2)) : j("", !0),
|
|
3429
3436
|
l("div", {
|
|
3430
|
-
class:
|
|
3437
|
+
class: N(["flex-start item-bar", i.showJson ? "active" : "inactive"]),
|
|
3431
3438
|
onClick: e[1] || (e[1] = (n) => i.showJson = !i.showJson)
|
|
3432
3439
|
}, xa, 2)
|
|
3433
3440
|
], 4)
|
|
3434
|
-
])) :
|
|
3441
|
+
])) : j("", !0);
|
|
3435
3442
|
}
|
|
3436
3443
|
const ka = /* @__PURE__ */ T(fa, [["render", Ca]]);
|
|
3437
3444
|
const Sa = {
|
|
@@ -3539,7 +3546,7 @@ const Sa = {
|
|
|
3539
3546
|
[1, "rgb(195,194,194)"]
|
|
3540
3547
|
];
|
|
3541
3548
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
3542
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
3549
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.uvFragmentSchema);
|
|
3543
3550
|
this.program = e, this.aPositionBuffer = t;
|
|
3544
3551
|
}
|
|
3545
3552
|
this.handleParticleSetup();
|
|
@@ -3607,7 +3614,7 @@ function $a(a, e, t, r, i, o) {
|
|
|
3607
3614
|
class: "legend-bars flex-center",
|
|
3608
3615
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
3609
3616
|
}, Ma, 4)
|
|
3610
|
-
])) :
|
|
3617
|
+
])) : j("", !0);
|
|
3611
3618
|
}
|
|
3612
3619
|
const ja = /* @__PURE__ */ T(Sa, [["render", $a], ["__scopeId", "data-v-6d4fd206"]]), Na = {
|
|
3613
3620
|
name: "IdmSigWave",
|
|
@@ -4145,24 +4152,24 @@ const Ya = {
|
|
|
4145
4152
|
}), t.forEach((o) => {
|
|
4146
4153
|
var d;
|
|
4147
4154
|
let s = 0, n;
|
|
4148
|
-
const c = a.filter((
|
|
4149
|
-
var
|
|
4150
|
-
return ((g = (
|
|
4155
|
+
const c = a.filter((p) => {
|
|
4156
|
+
var h, g;
|
|
4157
|
+
return ((g = (h = p.properties) == null ? void 0 : h.category) == null ? void 0 : g.split("-")[0]) === o;
|
|
4151
4158
|
});
|
|
4152
|
-
(d = c.filter((
|
|
4153
|
-
var
|
|
4154
|
-
return ((
|
|
4155
|
-
})[0]) == null || d.properties.model, c.forEach((
|
|
4159
|
+
(d = c.filter((p) => {
|
|
4160
|
+
var h, g;
|
|
4161
|
+
return ((h = p.geometry) == null ? void 0 : h.type) === "LineString" && ((g = p.properties) == null ? void 0 : g.type) === "forecast";
|
|
4162
|
+
})[0]) == null || d.properties.model, c.forEach((p, h) => {
|
|
4156
4163
|
var g, u, y, f, m, v;
|
|
4157
|
-
((g =
|
|
4158
|
-
}), c.map((
|
|
4164
|
+
((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);
|
|
4165
|
+
}), c.map((p, h) => {
|
|
4159
4166
|
var g, u, y, f, m, v, b;
|
|
4160
|
-
if (((g =
|
|
4161
|
-
|
|
4162
|
-
const _ = Z((b =
|
|
4163
|
-
|
|
4167
|
+
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") {
|
|
4168
|
+
p.properties.format = Z(p.properties.date).utcOffset(this.timeZone).format(`MMM-DD,HHmm [(utc ${this.computeTimezone})]`);
|
|
4169
|
+
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");
|
|
4170
|
+
p.properties.showHistoryLabel = _ || h === s, p.properties.showNameLabel = h === s, p.properties.name = o;
|
|
4164
4171
|
}
|
|
4165
|
-
return
|
|
4172
|
+
return p;
|
|
4166
4173
|
});
|
|
4167
4174
|
}), this.handleInit();
|
|
4168
4175
|
},
|
|
@@ -4423,10 +4430,10 @@ const Ya = {
|
|
|
4423
4430
|
}), y = (/* @__PURE__ */ new Date()).valueOf() - (g + u), console.log("[tropical] add elapsed: ", y, ", total: ", u += y));
|
|
4424
4431
|
}
|
|
4425
4432
|
this.handleDrawCircle();
|
|
4426
|
-
const
|
|
4427
|
-
this.interpolateData = JSON.parse(JSON.stringify(
|
|
4428
|
-
const
|
|
4429
|
-
console.log(
|
|
4433
|
+
const p = Qe.interpolate(this.tropicals, 1);
|
|
4434
|
+
this.interpolateData = JSON.parse(JSON.stringify(p));
|
|
4435
|
+
const h = this.interpolateData.filter((g) => g.properties.name === "kristy" && g.properties.model === "ecmwf");
|
|
4436
|
+
console.log(h), this.handleDateChange();
|
|
4430
4437
|
}
|
|
4431
4438
|
},
|
|
4432
4439
|
handleClear() {
|
|
@@ -4434,14 +4441,14 @@ const Ya = {
|
|
|
4434
4441
|
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
4442
|
},
|
|
4436
4443
|
handleDateChange() {
|
|
4437
|
-
var a, e, t, r, i, o, s, n, c, d,
|
|
4444
|
+
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
4445
|
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 }),
|
|
4446
|
+
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
4447
|
be.forEach((I) => {
|
|
4441
|
-
|
|
4442
|
-
}), (t = this.map) != null && t.getSource(this.interpolateSource) ? (r = this.map) == null || r.getSource(this.interpolateSource).setData(
|
|
4448
|
+
Q.features.push(I);
|
|
4449
|
+
}), (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
4450
|
type: "geojson",
|
|
4444
|
-
data:
|
|
4451
|
+
data: Q
|
|
4445
4452
|
}), (o = this.map) == null || o.addLayer({
|
|
4446
4453
|
id: this.interpolateLineLayer,
|
|
4447
4454
|
type: "line",
|
|
@@ -4453,10 +4460,10 @@ const Ya = {
|
|
|
4453
4460
|
"line-width": 1
|
|
4454
4461
|
}
|
|
4455
4462
|
})), this.interpolateMarkers = [];
|
|
4456
|
-
for (const I of
|
|
4463
|
+
for (const I of q)
|
|
4457
4464
|
if (!I.properties.disabled) {
|
|
4458
4465
|
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" : ((
|
|
4466
|
+
((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
4467
|
const ve = `<svg t="1719918955501"
|
|
4461
4468
|
class="icon" viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg" p-id="18382"
|
|
4462
4469
|
xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200">
|
|
@@ -4471,9 +4478,9 @@ const Ya = {
|
|
|
4471
4478
|
<path
|
|
4472
4479
|
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
4480
|
fill="#ffffff" p-id="18386"></path>
|
|
4474
|
-
</svg>`,
|
|
4475
|
-
|
|
4476
|
-
const we = new te.Marker(
|
|
4481
|
+
</svg>`, K = document.createElement("div");
|
|
4482
|
+
K.className = "hurricane-hourly-marker", K.innerHTML = `<div class="${I.geometry.coordinates[1] >= 0 ? "center north" : "center south"}">${ve}</div>`;
|
|
4483
|
+
const we = new te.Marker(K).setLngLat(I.geometry.coordinates).addTo(this.map);
|
|
4477
4484
|
if (this.interpolateMarkers.push(we), (de = I.properties) != null && de.showCircle) {
|
|
4478
4485
|
const re = { radius: 100, coordinates: I.geometry.coordinates }, oe = { radius: 200, coordinates: I.geometry.coordinates }, se = { radius: 500, coordinates: I.geometry.coordinates };
|
|
4479
4486
|
(pe = this.circleSourceData) == null || pe.features.push(
|
|
@@ -4490,7 +4497,7 @@ const Ya = {
|
|
|
4490
4497
|
(ge = this.map) != null && ge.getSource(this.interpolateSource) && ((ie = this.map) == null || ie.getSource(this.interpolateSource).setData(this.empty));
|
|
4491
4498
|
},
|
|
4492
4499
|
handleClick(a) {
|
|
4493
|
-
var o, s, n, c, d,
|
|
4500
|
+
var o, s, n, c, d, p, h, g;
|
|
4494
4501
|
const e = a.features[0], t = (s = (o = this.tropicals) == null ? void 0 : o.data) == null ? void 0 : s.features.filter(
|
|
4495
4502
|
(u) => {
|
|
4496
4503
|
var y;
|
|
@@ -4510,8 +4517,8 @@ const Ya = {
|
|
|
4510
4517
|
this.activeTropicals = {
|
|
4511
4518
|
name: (d = e == null ? void 0 : e.properties) == null ? void 0 : d.name,
|
|
4512
4519
|
forecasts: t.map((u) => u.properties),
|
|
4513
|
-
history: (
|
|
4514
|
-
showCircle: (g = (
|
|
4520
|
+
history: (p = r[0]) == null ? void 0 : p.properties,
|
|
4521
|
+
showCircle: (g = (h = t[0]) == null ? void 0 : h.properties) == null ? void 0 : g.showCircle
|
|
4515
4522
|
}, this.showTropicals = !0;
|
|
4516
4523
|
const i = document.getElementById("active-tropical");
|
|
4517
4524
|
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 +4606,7 @@ const Ya = {
|
|
|
4599
4606
|
return L.lineToPolygon(i, { properties: t });
|
|
4600
4607
|
}
|
|
4601
4608
|
}
|
|
4602
|
-
}, Ue = (a) => (H("data-v-
|
|
4609
|
+
}, Ue = (a) => (H("data-v-f0e05b29"), a = a(), G(), a), qa = {
|
|
4603
4610
|
id: "active-tropical",
|
|
4604
4611
|
class: "active-tropical"
|
|
4605
4612
|
}, Qa = { class: "header-box" }, Ka = { class: "main" }, ei = { key: 0 }, ti = { class: "sub" }, ai = {
|
|
@@ -4614,9 +4621,9 @@ const Ya = {
|
|
|
4614
4621
|
}, li = /* @__PURE__ */ Ue(() => /* @__PURE__ */ l("label", null, "Pressure : ", -1)), ci = { class: "row" }, hi = {
|
|
4615
4622
|
class: "col col-24",
|
|
4616
4623
|
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-
|
|
4624
|
+
}, 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
4625
|
function fi(a, e, t, r, i, o) {
|
|
4619
|
-
var s, n, c, d,
|
|
4626
|
+
var s, n, c, d, p, h, g, u, y, f, m, v, b, _, P;
|
|
4620
4627
|
return je((x(), C("div", qa, [
|
|
4621
4628
|
l("div", Qa, [
|
|
4622
4629
|
l("div", {
|
|
@@ -4624,10 +4631,10 @@ function fi(a, e, t, r, i, o) {
|
|
|
4624
4631
|
onClick: e[0] || (e[0] = (w) => i.showTropicals = !1)
|
|
4625
4632
|
}, ""),
|
|
4626
4633
|
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((
|
|
4634
|
+
(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),
|
|
4635
|
+
Fe(S((p = i.activeTropicals) == null ? void 0 : p.name), 1)
|
|
4629
4636
|
]),
|
|
4630
|
-
l("div", ti, " Last update: " + S(o.computeTime(((g = (
|
|
4637
|
+
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
4638
|
]),
|
|
4632
4639
|
l("div", ai, [
|
|
4633
4640
|
l("div", ii, [
|
|
@@ -4645,11 +4652,11 @@ function fi(a, e, t, r, i, o) {
|
|
|
4645
4652
|
l("div", hi, [
|
|
4646
4653
|
di,
|
|
4647
4654
|
l("div", pi, [
|
|
4648
|
-
(x(!0), C(Ae, null, $e((
|
|
4655
|
+
(x(!0), C(Ae, null, $e((P = i.activeTropicals) == null ? void 0 : P.forecasts, (w, A) => {
|
|
4649
4656
|
var M, $, W, O;
|
|
4650
4657
|
return x(), C("div", {
|
|
4651
4658
|
key: A,
|
|
4652
|
-
class:
|
|
4659
|
+
class: N([
|
|
4653
4660
|
"model",
|
|
4654
4661
|
w.disabled ? "" : "active",
|
|
4655
4662
|
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 +4664,7 @@ function fi(a, e, t, r, i, o) {
|
|
|
4657
4664
|
onClick: (J) => o.handleForecastToggle(w)
|
|
4658
4665
|
}, [
|
|
4659
4666
|
l("span", {
|
|
4660
|
-
class:
|
|
4667
|
+
class: N(w.model)
|
|
4661
4668
|
}, S(w.model), 3)
|
|
4662
4669
|
], 10, mi);
|
|
4663
4670
|
}), 128))
|
|
@@ -4677,7 +4684,7 @@ function fi(a, e, t, r, i, o) {
|
|
|
4677
4684
|
[Ne, i.showTropicals && !a.$attrs.hideTropicalsLegend]
|
|
4678
4685
|
]);
|
|
4679
4686
|
}
|
|
4680
|
-
const Ke = /* @__PURE__ */ T(Ya, [["render", fi], ["__scopeId", "data-v-
|
|
4687
|
+
const Ke = /* @__PURE__ */ T(Ya, [["render", fi], ["__scopeId", "data-v-f0e05b29"]]);
|
|
4681
4688
|
const gi = {
|
|
4682
4689
|
name: "IdmPrecip3h",
|
|
4683
4690
|
props: {
|
|
@@ -4766,7 +4773,7 @@ const gi = {
|
|
|
4766
4773
|
[1, "rgba(197,5,58,0.8)"]
|
|
4767
4774
|
];
|
|
4768
4775
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
4769
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
4776
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.fragmentSchema);
|
|
4770
4777
|
this.program = e, this.aPositionBuffer = t;
|
|
4771
4778
|
}
|
|
4772
4779
|
},
|
|
@@ -4796,7 +4803,7 @@ function Pi(a, e, t, r, i, o) {
|
|
|
4796
4803
|
class: "legend-bars flex-center",
|
|
4797
4804
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
4798
4805
|
}, zi, 4)
|
|
4799
|
-
])) :
|
|
4806
|
+
])) : j("", !0);
|
|
4800
4807
|
}
|
|
4801
4808
|
const Ti = /* @__PURE__ */ T(gi, [["render", Pi], ["__scopeId", "data-v-9708a7a3"]]);
|
|
4802
4809
|
const Ii = {
|
|
@@ -4880,7 +4887,7 @@ const Ii = {
|
|
|
4880
4887
|
[1, "rgba(144,144,144,0)"]
|
|
4881
4888
|
];
|
|
4882
4889
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
4883
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
4890
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.fragmentSchema);
|
|
4884
4891
|
this.program = e, this.aPositionBuffer = t;
|
|
4885
4892
|
}
|
|
4886
4893
|
},
|
|
@@ -4908,7 +4915,7 @@ function Bi(a, e, t, r, i, o) {
|
|
|
4908
4915
|
class: "legend-bars flex-center",
|
|
4909
4916
|
style: U([{ position: "absolute" }, { right: a.right + "px", bottom: t.bottom }])
|
|
4910
4917
|
}, Ni, 4)
|
|
4911
|
-
])) :
|
|
4918
|
+
])) : j("", !0);
|
|
4912
4919
|
}
|
|
4913
4920
|
const Wi = /* @__PURE__ */ T(Ii, [["render", Bi], ["__scopeId", "data-v-f7b2fb08"]]);
|
|
4914
4921
|
const Oi = {
|
|
@@ -5000,7 +5007,7 @@ const Oi = {
|
|
|
5000
5007
|
//
|
|
5001
5008
|
];
|
|
5002
5009
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
5003
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
5010
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.fragmentSchema);
|
|
5004
5011
|
this.program = e, this.aPositionBuffer = t;
|
|
5005
5012
|
}
|
|
5006
5013
|
},
|
|
@@ -5028,7 +5035,7 @@ function Yi(a, e, t, r, i, o) {
|
|
|
5028
5035
|
class: "legend-bars flex-center",
|
|
5029
5036
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
5030
5037
|
}, Xi, 4)
|
|
5031
|
-
])) :
|
|
5038
|
+
])) : j("", !0);
|
|
5032
5039
|
}
|
|
5033
5040
|
const qi = /* @__PURE__ */ T(Oi, [["render", Yi], ["__scopeId", "data-v-7521f582"]]);
|
|
5034
5041
|
const Qi = {
|
|
@@ -5123,7 +5130,7 @@ const Qi = {
|
|
|
5123
5130
|
[1, "rgb(138, 43, 10)"]
|
|
5124
5131
|
];
|
|
5125
5132
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
5126
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
5133
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.fragmentSchema);
|
|
5127
5134
|
this.program = e, this.aPositionBuffer = t;
|
|
5128
5135
|
}
|
|
5129
5136
|
},
|
|
@@ -5153,7 +5160,7 @@ function cr(a, e, t, r, i, o) {
|
|
|
5153
5160
|
class: "legend-bars flex-center",
|
|
5154
5161
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
5155
5162
|
}, lr, 4)
|
|
5156
|
-
])) :
|
|
5163
|
+
])) : j("", !0);
|
|
5157
5164
|
}
|
|
5158
5165
|
const hr = /* @__PURE__ */ T(Qi, [["render", cr], ["__scopeId", "data-v-25daaa82"]]);
|
|
5159
5166
|
const dr = {
|
|
@@ -5239,7 +5246,7 @@ const dr = {
|
|
|
5239
5246
|
// 2m
|
|
5240
5247
|
];
|
|
5241
5248
|
this.rampColor = this.webgl.setup(this.context, a);
|
|
5242
|
-
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context,
|
|
5249
|
+
const { program: e, aPositionBuffer: t } = this.webgl.bind(this.context, B.vertexSchema, B.fragmentSchema);
|
|
5243
5250
|
this.program = e, this.aPositionBuffer = t;
|
|
5244
5251
|
}
|
|
5245
5252
|
},
|
|
@@ -5267,7 +5274,7 @@ function wr(a, e, t, r, i, o) {
|
|
|
5267
5274
|
class: "legend-bars flex-center",
|
|
5268
5275
|
style: U([{ position: "absolute" }, { right: i.right + "px", bottom: t.bottom }])
|
|
5269
5276
|
}, vr, 4)
|
|
5270
|
-
])) :
|
|
5277
|
+
])) : j("", !0);
|
|
5271
5278
|
}
|
|
5272
5279
|
const _r = /* @__PURE__ */ T(dr, [["render", wr], ["__scopeId", "data-v-5bb73794"]]);
|
|
5273
5280
|
const Lr = {
|
|
@@ -5357,12 +5364,12 @@ const Lr = {
|
|
|
5357
5364
|
}
|
|
5358
5365
|
}
|
|
5359
5366
|
}
|
|
5360
|
-
}, ae = (a) => (H("data-v-
|
|
5367
|
+
}, ae = (a) => (H("data-v-efcf572f"), a = a(), G(), a), xr = {
|
|
5361
5368
|
id: "point-meteo",
|
|
5362
5369
|
class: "point-meteo"
|
|
5363
5370
|
}, 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
5371
|
function Gr(a, e, t, r, i, o) {
|
|
5365
|
-
var s, n, c, d,
|
|
5372
|
+
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
5373
|
return je((x(), C("div", xr, [
|
|
5367
5374
|
l("div", Cr, [
|
|
5368
5375
|
l("div", kr, [
|
|
@@ -5376,11 +5383,11 @@ function Gr(a, e, t, r, i, o) {
|
|
|
5376
5383
|
l("div", Pr, [
|
|
5377
5384
|
l("div", Tr, [
|
|
5378
5385
|
Ir,
|
|
5379
|
-
l("span", null, S(((
|
|
5386
|
+
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
5387
|
]),
|
|
5381
5388
|
l("div", Er, [
|
|
5382
5389
|
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 = (
|
|
5390
|
+
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
5391
|
]),
|
|
5385
5392
|
l("div", Ar, [
|
|
5386
5393
|
Dr,
|
|
@@ -5388,7 +5395,7 @@ function Gr(a, e, t, r, i, o) {
|
|
|
5388
5395
|
]),
|
|
5389
5396
|
l("div", Mr, [
|
|
5390
5397
|
$r,
|
|
5391
|
-
l("span", null, S(((
|
|
5398
|
+
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
5399
|
]),
|
|
5393
5400
|
l("div", jr, [
|
|
5394
5401
|
Nr,
|
|
@@ -5411,13 +5418,13 @@ function Gr(a, e, t, r, i, o) {
|
|
|
5411
5418
|
l("span", null, S(o.roundPrecision((Re = t.meteo) == null ? void 0 : Re.waterTemp, 2)) + "[°C]", 1)
|
|
5412
5419
|
])
|
|
5413
5420
|
]),
|
|
5414
|
-
|
|
5421
|
+
j("", !0)
|
|
5415
5422
|
])
|
|
5416
5423
|
], 512)), [
|
|
5417
5424
|
[Ne, i.showMeteo]
|
|
5418
5425
|
]);
|
|
5419
5426
|
}
|
|
5420
|
-
const Jr = /* @__PURE__ */ T(Lr, [["render", Gr], ["__scopeId", "data-v-
|
|
5427
|
+
const Jr = /* @__PURE__ */ T(Lr, [["render", Gr], ["__scopeId", "data-v-efcf572f"]]), Xr = {
|
|
5421
5428
|
name: "IdmWarZone",
|
|
5422
5429
|
props: {
|
|
5423
5430
|
map: {
|
|
@@ -5812,7 +5819,7 @@ const ro = {
|
|
|
5812
5819
|
layout: {
|
|
5813
5820
|
"symbol-placement": "point",
|
|
5814
5821
|
"icon-image": "alert",
|
|
5815
|
-
"icon-size": 0.
|
|
5822
|
+
"icon-size": 0.08,
|
|
5816
5823
|
"icon-allow-overlap": !0,
|
|
5817
5824
|
"icon-rotation-alignment": "viewport"
|
|
5818
5825
|
},
|
|
@@ -5827,7 +5834,7 @@ const ro = {
|
|
|
5827
5834
|
layout: {
|
|
5828
5835
|
"symbol-placement": "line-center",
|
|
5829
5836
|
"icon-image": "alert",
|
|
5830
|
-
"icon-size": 0.
|
|
5837
|
+
"icon-size": 0.08,
|
|
5831
5838
|
"icon-allow-overlap": !0,
|
|
5832
5839
|
"icon-rotation-alignment": "viewport"
|
|
5833
5840
|
},
|
|
@@ -5842,7 +5849,7 @@ const ro = {
|
|
|
5842
5849
|
layout: {
|
|
5843
5850
|
"symbol-placement": "point",
|
|
5844
5851
|
"icon-image": "alert",
|
|
5845
|
-
"icon-size": 0.
|
|
5852
|
+
"icon-size": 0.08
|
|
5846
5853
|
},
|
|
5847
5854
|
paint: {
|
|
5848
5855
|
"icon-opacity": 0.8
|
|
@@ -5964,7 +5971,7 @@ const co = {
|
|
|
5964
5971
|
this.showPort = !1, this.map.getLayer(this.layer) && this.map.removeLayer(this.layer), this.map.getSource(this.source) && this.map.removeSource(this.source);
|
|
5965
5972
|
}
|
|
5966
5973
|
}
|
|
5967
|
-
}, Be = (a) => (H("data-v-
|
|
5974
|
+
}, 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
5975
|
class: "flex-start",
|
|
5969
5976
|
style: { "align-items": "flex-start" }
|
|
5970
5977
|
}, wo = /* @__PURE__ */ Be(() => /* @__PURE__ */ l("label", null, "Region : ", -1));
|
|
@@ -5998,7 +6005,7 @@ function _o(a, e, t, r, i, o) {
|
|
|
5998
6005
|
[Ne, i.showPort]
|
|
5999
6006
|
]);
|
|
6000
6007
|
}
|
|
6001
|
-
const Lo = /* @__PURE__ */ T(co, [["render", _o], ["__scopeId", "data-v-
|
|
6008
|
+
const Lo = /* @__PURE__ */ T(co, [["render", _o], ["__scopeId", "data-v-c07e4c45"]]), xo = {
|
|
6002
6009
|
name: "IdmLoadLine",
|
|
6003
6010
|
props: {
|
|
6004
6011
|
map: {
|
|
@@ -6641,7 +6648,7 @@ function Oo(a, e, t, r, i, o) {
|
|
|
6641
6648
|
l("span", null, S(i.lngLat.lat.pretty), 1),
|
|
6642
6649
|
Wo,
|
|
6643
6650
|
l("span", null, S(i.lngLat.lng.pretty), 1)
|
|
6644
|
-
], 4)) :
|
|
6651
|
+
], 4)) : j("", !0);
|
|
6645
6652
|
}
|
|
6646
6653
|
const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7"]]), Fo = {
|
|
6647
6654
|
name: "IdmMeasure",
|
|
@@ -6689,8 +6696,8 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6689
6696
|
(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
6697
|
else {
|
|
6691
6698
|
(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(
|
|
6699
|
+
for (const p of this.geojson)
|
|
6700
|
+
this.handleClear(p, !0);
|
|
6694
6701
|
this.geojson = [], this.map && (this.map.getCanvas().style.cursor = "grab");
|
|
6695
6702
|
}
|
|
6696
6703
|
},
|
|
@@ -6702,7 +6709,7 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6702
6709
|
}
|
|
6703
6710
|
},
|
|
6704
6711
|
handleDrag(a) {
|
|
6705
|
-
var t, r, i, o, s, n, c, d,
|
|
6712
|
+
var t, r, i, o, s, n, c, d, p, h;
|
|
6706
6713
|
const e = (r = (t = a.target) == null ? void 0 : t._element) == null ? void 0 : r.id;
|
|
6707
6714
|
if ((e == null ? void 0 : e.split("-").length) === 2) {
|
|
6708
6715
|
const g = this.geojson.filter((m) => m.id === e.split("-")[0])[0];
|
|
@@ -6721,13 +6728,13 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6721
6728
|
this.handleTmpPointUpdate(
|
|
6722
6729
|
g,
|
|
6723
6730
|
f[y - 1],
|
|
6724
|
-
{ lng: (d = (c = a.target) == null ? void 0 : c._lngLat) == null ? void 0 : d.lng, lat: (
|
|
6731
|
+
{ 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
6732
|
y === f.length - 1 ? void 0 : f[y + 1]
|
|
6726
6733
|
);
|
|
6727
6734
|
}
|
|
6728
6735
|
},
|
|
6729
6736
|
handleDragEnd(a) {
|
|
6730
|
-
var t, r, i, o, s, n, c, d,
|
|
6737
|
+
var t, r, i, o, s, n, c, d, p, h;
|
|
6731
6738
|
const e = (r = (t = a.target) == null ? void 0 : t._element) == null ? void 0 : r.id;
|
|
6732
6739
|
if ((e == null ? void 0 : e.split("-").length) === 2) {
|
|
6733
6740
|
const g = this.geojson.filter((f) => f.id === e.split("-")[0])[0];
|
|
@@ -6736,7 +6743,7 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6736
6743
|
return ((m = f._element) == null ? void 0 : m.id) === e;
|
|
6737
6744
|
})[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
6745
|
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, (
|
|
6746
|
+
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
6747
|
}
|
|
6741
6748
|
},
|
|
6742
6749
|
handleContextmenu(a) {
|
|
@@ -6783,12 +6790,12 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6783
6790
|
let t = 0;
|
|
6784
6791
|
const r = [];
|
|
6785
6792
|
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 +
|
|
6793
|
+
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);
|
|
6794
|
+
t = D.roundPrecision(t + p, 2);
|
|
6788
6795
|
let g;
|
|
6789
6796
|
n.mode === "RL" ? g = D.convertToMonotonicLng([c, d]) : g = D.convertToMonotonicLng(ee.interpolateCoordinates(c, d, 200));
|
|
6790
6797
|
const u = L.lineString(g.map((y) => [y.lng, y.lat]));
|
|
6791
|
-
u.properties.dist =
|
|
6798
|
+
u.properties.dist = p, u.properties.bearing = h, u.properties.total = t, r.push(u);
|
|
6792
6799
|
}
|
|
6793
6800
|
e.push(...r), a.total = t;
|
|
6794
6801
|
}
|
|
@@ -6798,19 +6805,19 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6798
6805
|
const i = L.featureCollection([]);
|
|
6799
6806
|
let o, s;
|
|
6800
6807
|
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(
|
|
6808
|
+
const c = e.properties, d = { lng: e.geometry.coordinates[0], lat: e.geometry.coordinates[1] }, p = { lng: t.lng, lat: t.lat };
|
|
6809
|
+
o = ee.calculateDistance(d, p, c.mode === "RL", 2), s = ee.calculateBearing(d, p, c.mode === "RL", 2);
|
|
6810
|
+
let h;
|
|
6811
|
+
c.mode === "RL" ? h = D.convertToMonotonicLng([d, p]) : h = D.convertToMonotonicLng(ee.interpolateCoordinates(d, p, 200));
|
|
6812
|
+
const g = L.lineString(h.map((u) => [u.lng, u.lat]));
|
|
6806
6813
|
g.properties.dist = o, g.properties.bearing = s, i.features.push(g);
|
|
6807
6814
|
}
|
|
6808
6815
|
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(
|
|
6816
|
+
const c = t.properties, d = t, p = { lng: r.geometry.coordinates[0], lat: r.geometry.coordinates[1] };
|
|
6817
|
+
o = ee.calculateDistance(d, p, c.mode === "RL", 2), s = ee.calculateBearing(d, p, c.mode === "RL", 2);
|
|
6818
|
+
let h;
|
|
6819
|
+
c.mode === "RL" ? h = D.convertToMonotonicLng([d, p]) : h = D.convertToMonotonicLng(ee.interpolateCoordinates(d, p, 200));
|
|
6820
|
+
const g = L.lineString(h.map((u) => [u.lng, u.lat]));
|
|
6814
6821
|
g.properties.dist = o, g.properties.bearing = s, i.features.push(g);
|
|
6815
6822
|
}
|
|
6816
6823
|
this.map.getSource(this.tmpSource) ? this.map.getSource(this.tmpSource).setData(i) : this.map.addSource(this.tmpSource, {
|
|
@@ -6917,17 +6924,17 @@ const et = /* @__PURE__ */ T(No, [["render", Oo], ["__scopeId", "data-v-73241fe7
|
|
|
6917
6924
|
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
6925
|
}
|
|
6919
6926
|
if (a.closed) {
|
|
6920
|
-
const s = o.at(-1), c = a.features.filter((
|
|
6927
|
+
const s = o.at(-1), c = a.features.filter((p) => p.geometry.type === "LineString").at(-1), d = document.createElement("div");
|
|
6921
6928
|
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
6929
|
}
|
|
6923
6930
|
}
|
|
6924
6931
|
},
|
|
6925
6932
|
handleClear(a, e = !0) {
|
|
6926
|
-
var o, s, n, c, d,
|
|
6933
|
+
var o, s, n, c, d, p, h, g, u;
|
|
6927
6934
|
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, (
|
|
6935
|
+
(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
6936
|
y == null || y.remove();
|
|
6930
|
-
}), this.pointMarkers[a.id] = [], (
|
|
6937
|
+
}), 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
6938
|
}
|
|
6932
6939
|
}
|
|
6933
6940
|
};
|
|
@@ -6987,31 +6994,52 @@ const Zo = {
|
|
|
6987
6994
|
}
|
|
6988
6995
|
},
|
|
6989
6996
|
methods: {}
|
|
6990
|
-
}, tt = (a) => (H("data-v-
|
|
6997
|
+
}, 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
6998
|
Jo
|
|
6992
6999
|
], Yo = /* @__PURE__ */ tt(() => /* @__PURE__ */ l("span", { class: "iconfont" }, "I4", -1)), qo = [
|
|
6993
7000
|
Yo
|
|
6994
7001
|
];
|
|
6995
7002
|
function Qo(a, e, t, r, i, o) {
|
|
7003
|
+
const s = z("ElTooltip");
|
|
6996
7004
|
return t.enabled && t.permission & i.helper.LEVEL.Supper ? (x(), C("div", Ho, [
|
|
6997
7005
|
l("div", {
|
|
6998
7006
|
class: "menu-bar-box",
|
|
6999
7007
|
style: U({ position: "absolute", right: i.right + "px", bottom: t.bottom })
|
|
7000
7008
|
}, [
|
|
7001
7009
|
l("div", Go, [
|
|
7002
|
-
|
|
7003
|
-
|
|
7004
|
-
|
|
7005
|
-
|
|
7006
|
-
|
|
7007
|
-
|
|
7008
|
-
|
|
7009
|
-
|
|
7010
|
+
k(s, {
|
|
7011
|
+
placement: "left",
|
|
7012
|
+
effect: "light",
|
|
7013
|
+
content: "Hifleet",
|
|
7014
|
+
"show-after": 2e3
|
|
7015
|
+
}, {
|
|
7016
|
+
default: Y(() => [
|
|
7017
|
+
l("div", {
|
|
7018
|
+
class: N(i.vendor === "hi" ? "menu-icon active" : "menu-icon"),
|
|
7019
|
+
onClick: e[0] || (e[0] = (n) => i.vendor = "hi")
|
|
7020
|
+
}, Xo, 2)
|
|
7021
|
+
]),
|
|
7022
|
+
_: 1
|
|
7023
|
+
}),
|
|
7024
|
+
k(s, {
|
|
7025
|
+
placement: "left",
|
|
7026
|
+
effect: "light",
|
|
7027
|
+
content: "I4insight",
|
|
7028
|
+
"show-after": 2e3
|
|
7029
|
+
}, {
|
|
7030
|
+
default: Y(() => [
|
|
7031
|
+
l("div", {
|
|
7032
|
+
class: N(i.vendor === "i4" ? "menu-icon active" : "menu-icon"),
|
|
7033
|
+
onClick: e[1] || (e[1] = (n) => i.vendor = "i4")
|
|
7034
|
+
}, qo, 2)
|
|
7035
|
+
]),
|
|
7036
|
+
_: 1
|
|
7037
|
+
})
|
|
7010
7038
|
])
|
|
7011
7039
|
], 4)
|
|
7012
|
-
])) :
|
|
7040
|
+
])) : j("", !0);
|
|
7013
7041
|
}
|
|
7014
|
-
const Ko = /* @__PURE__ */ T(Zo, [["render", Qo], ["__scopeId", "data-v-
|
|
7042
|
+
const Ko = /* @__PURE__ */ T(Zo, [["render", Qo], ["__scopeId", "data-v-8928221f"]]);
|
|
7015
7043
|
const es = {
|
|
7016
7044
|
name: "IdmGLV2",
|
|
7017
7045
|
components: {
|
|
@@ -7117,10 +7145,10 @@ const es = {
|
|
|
7117
7145
|
},
|
|
7118
7146
|
activeWeatherLayers: {
|
|
7119
7147
|
handler() {
|
|
7120
|
-
var a, e, t, r, i, o, s, n, c, d,
|
|
7148
|
+
var a, e, t, r, i, o, s, n, c, d, p, h, g, u, y, f, m, v;
|
|
7121
7149
|
if (!this.map)
|
|
7122
7150
|
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)), (
|
|
7151
|
+
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
7152
|
},
|
|
7125
7153
|
immediate: !0
|
|
7126
7154
|
}
|
|
@@ -7167,7 +7195,7 @@ const es = {
|
|
|
7167
7195
|
},
|
|
7168
7196
|
methods: {
|
|
7169
7197
|
async fetchWeatherLayers(a = { tropicals: !1 }) {
|
|
7170
|
-
var i, o, s, n, c, d,
|
|
7198
|
+
var i, o, s, n, c, d, p, h;
|
|
7171
7199
|
const e = (/* @__PURE__ */ new Date()).valueOf();
|
|
7172
7200
|
let t = 0, r = 0;
|
|
7173
7201
|
if (this.map) {
|
|
@@ -7201,8 +7229,8 @@ const es = {
|
|
|
7201
7229
|
console.log(`[${w}] fetch layer error: ${A}`);
|
|
7202
7230
|
})
|
|
7203
7231
|
);
|
|
7204
|
-
const
|
|
7205
|
-
this.weatherLayers = {},
|
|
7232
|
+
const P = await Promise.all(_);
|
|
7233
|
+
this.weatherLayers = {}, P.map((w) => {
|
|
7206
7234
|
var $, W, O, J;
|
|
7207
7235
|
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
7236
|
M && A && (this.weatherLayers[M] = {
|
|
@@ -7238,7 +7266,7 @@ const es = {
|
|
|
7238
7266
|
};
|
|
7239
7267
|
}
|
|
7240
7268
|
if (this.weatherLayers["current-direction"] || this.weatherLayers["current-speed"]) {
|
|
7241
|
-
const b = (
|
|
7269
|
+
const b = (p = this.weatherLayers["current-direction"]) == null ? void 0 : p.raw, _ = (h = this.weatherLayers["current-speed"]) == null ? void 0 : h.raw;
|
|
7242
7270
|
delete this.weatherLayers["current-direction"], delete this.weatherLayers["current-speed"], this.weatherLayers.current = {
|
|
7243
7271
|
type: "json",
|
|
7244
7272
|
direction: b,
|
|
@@ -7268,19 +7296,19 @@ const es = {
|
|
|
7268
7296
|
});
|
|
7269
7297
|
if (((e = n == null ? void 0 : n.data) == null ? void 0 : e.code) === 0) {
|
|
7270
7298
|
const c = (t = n == null ? void 0 : n.data) == null ? void 0 : t.data, d = [];
|
|
7271
|
-
for (const
|
|
7299
|
+
for (const h in c)
|
|
7272
7300
|
d.push(
|
|
7273
|
-
ne.get(c[
|
|
7301
|
+
ne.get(c[h], {
|
|
7274
7302
|
headers: {
|
|
7275
7303
|
Authorization: this.token || this.defaultMeteoToken,
|
|
7276
|
-
key:
|
|
7304
|
+
key: h
|
|
7277
7305
|
}
|
|
7278
7306
|
})
|
|
7279
7307
|
);
|
|
7280
|
-
const
|
|
7281
|
-
this.otherLayers = { enc: s },
|
|
7308
|
+
const p = await Promise.all(d);
|
|
7309
|
+
this.otherLayers = { enc: s }, p.map((h) => {
|
|
7282
7310
|
var y, f, m;
|
|
7283
|
-
const g = ((y =
|
|
7311
|
+
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
7312
|
this.otherLayers[u] = g;
|
|
7285
7313
|
});
|
|
7286
7314
|
}
|
|
@@ -7292,18 +7320,18 @@ const es = {
|
|
|
7292
7320
|
});
|
|
7293
7321
|
if (((r = n == null ? void 0 : n.data) == null ? void 0 : r.code) === 0) {
|
|
7294
7322
|
const c = (i = n == null ? void 0 : n.data) == null ? void 0 : i.data, d = [];
|
|
7295
|
-
for (const
|
|
7323
|
+
for (const h in c)
|
|
7296
7324
|
d.push(
|
|
7297
|
-
ne.get(c[
|
|
7325
|
+
ne.get(c[h], {
|
|
7298
7326
|
headers: {
|
|
7299
7327
|
Authorization: this.token || this.defaultMeteoToken,
|
|
7300
|
-
key:
|
|
7328
|
+
key: h
|
|
7301
7329
|
}
|
|
7302
7330
|
})
|
|
7303
7331
|
);
|
|
7304
|
-
(await Promise.all(d)).map((
|
|
7332
|
+
(await Promise.all(d)).map((h) => {
|
|
7305
7333
|
var y, f, m;
|
|
7306
|
-
const g = ((y =
|
|
7334
|
+
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
7335
|
this.otherLayers[u] = g;
|
|
7308
7336
|
});
|
|
7309
7337
|
}
|
|
@@ -7325,7 +7353,7 @@ const es = {
|
|
|
7325
7353
|
this.activeWindLayer = !!this.activeWeatherLayers.find((e) => e.key === "wind"), this.$refs.layer && (this.$refs.layer.activeWeatherLayers = this.activeWeatherLayers);
|
|
7326
7354
|
},
|
|
7327
7355
|
handleRampColorInitial() {
|
|
7328
|
-
var a, e, t, r, i, o, s, n, c, d,
|
|
7356
|
+
var a, e, t, r, i, o, s, n, c, d, p, h;
|
|
7329
7357
|
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
7358
|
type: "canvas",
|
|
7331
7359
|
canvas: (t = this.viewport) == null ? void 0 : t.rampColorCanvas,
|
|
@@ -7349,8 +7377,8 @@ const es = {
|
|
|
7349
7377
|
}), this.viewport.map.getLayer((d = this.viewport) == null ? void 0 : d.particleLayer) || this.viewport.map.addLayer(
|
|
7350
7378
|
{
|
|
7351
7379
|
type: "raster",
|
|
7352
|
-
id: (
|
|
7353
|
-
source: (
|
|
7380
|
+
id: (p = this.viewport) == null ? void 0 : p.particleLayer,
|
|
7381
|
+
source: (h = this.viewport) == null ? void 0 : h.particleSource,
|
|
7354
7382
|
layout: {
|
|
7355
7383
|
visibility: "none"
|
|
7356
7384
|
}
|
|
@@ -7359,7 +7387,7 @@ const es = {
|
|
|
7359
7387
|
);
|
|
7360
7388
|
},
|
|
7361
7389
|
handleDragEndWithZoom4Json() {
|
|
7362
|
-
var d,
|
|
7390
|
+
var d, p, h, g;
|
|
7363
7391
|
const a = (/* @__PURE__ */ new Date()).valueOf();
|
|
7364
7392
|
let e = 0, t = 0;
|
|
7365
7393
|
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 +7396,25 @@ const es = {
|
|
|
7368
7396
|
this.weatherLayers[u].active = !1, this.weatherLayers[u].version = Math.random() + 1;
|
|
7369
7397
|
let y = [];
|
|
7370
7398
|
if (["swell", "current"].includes(u)) {
|
|
7371
|
-
const f = ((
|
|
7399
|
+
const f = ((p = this.weatherLayers[u]) == null ? void 0 : p.direction) || {};
|
|
7372
7400
|
for (const m in f)
|
|
7373
7401
|
if (m > n && m < c && (!(i <= this.zoom) || m % (i < this.zoom / 2 ? 5 : 3) === 0)) {
|
|
7374
7402
|
const v = f[m].lng;
|
|
7375
7403
|
o > s ? v.forEach((b, _) => {
|
|
7376
|
-
var
|
|
7404
|
+
var P;
|
|
7377
7405
|
if ((b >= o && b <= 180 || b >= -180 && b <= s) && (!(i <= this.zoom) || b % (i < this.zoom / 2 ? 5 : 3) === 0)) {
|
|
7378
7406
|
const w = L.point([b, m], {
|
|
7379
7407
|
val: f[m].val[_],
|
|
7380
|
-
spd: (
|
|
7408
|
+
spd: (P = f[m].spd) == null ? void 0 : P[_]
|
|
7381
7409
|
});
|
|
7382
7410
|
y.push(w);
|
|
7383
7411
|
}
|
|
7384
7412
|
}) : v.forEach((b, _) => {
|
|
7385
|
-
var
|
|
7413
|
+
var P;
|
|
7386
7414
|
if (b >= o && b <= s && (!(i <= this.zoom) || b % (i < this.zoom / 2 ? 5 : 3) === 0)) {
|
|
7387
7415
|
const w = L.point([b, m], {
|
|
7388
7416
|
val: f[m].val[_],
|
|
7389
|
-
spd: (
|
|
7417
|
+
spd: (P = f[m].spd) == null ? void 0 : P[_]
|
|
7390
7418
|
});
|
|
7391
7419
|
y.push(w);
|
|
7392
7420
|
}
|
|
@@ -7397,11 +7425,11 @@ const es = {
|
|
|
7397
7425
|
if (m) {
|
|
7398
7426
|
if (!m.data) {
|
|
7399
7427
|
const v = [];
|
|
7400
|
-
for (const b in (
|
|
7428
|
+
for (const b in (h = m.raw) == null ? void 0 : h.LineString) {
|
|
7401
7429
|
const _ = m.raw.LineString[b];
|
|
7402
|
-
for (const
|
|
7430
|
+
for (const P of _)
|
|
7403
7431
|
v.push(
|
|
7404
|
-
L.lineString(
|
|
7432
|
+
L.lineString(P, {
|
|
7405
7433
|
val: Number(b)
|
|
7406
7434
|
})
|
|
7407
7435
|
);
|
|
@@ -7421,8 +7449,8 @@ const es = {
|
|
|
7421
7449
|
if (!m.data) {
|
|
7422
7450
|
const b = [];
|
|
7423
7451
|
for (const _ in (g = m.raw) == null ? void 0 : g.Polygon) {
|
|
7424
|
-
const
|
|
7425
|
-
for (const w of
|
|
7452
|
+
const P = m.raw.Polygon[_];
|
|
7453
|
+
for (const w of P)
|
|
7426
7454
|
b.push(
|
|
7427
7455
|
L.polygon(w, {
|
|
7428
7456
|
val: Number(_)
|
|
@@ -7442,19 +7470,19 @@ const es = {
|
|
|
7442
7470
|
const v = f[m].lng;
|
|
7443
7471
|
o > s ? v.forEach((b, _) => {
|
|
7444
7472
|
if ((b >= o && b <= 180 || b >= -180 && b <= s) && (!(i <= this.zoom) || b % (i < this.zoom / 2 ? 5 : 3) === 0)) {
|
|
7445
|
-
const
|
|
7473
|
+
const P = L.point([b, m], {
|
|
7446
7474
|
val: f[m].val[_],
|
|
7447
7475
|
spd: f[m].spd[_]
|
|
7448
7476
|
});
|
|
7449
|
-
y.push(
|
|
7477
|
+
y.push(P);
|
|
7450
7478
|
}
|
|
7451
7479
|
}) : v.forEach((b, _) => {
|
|
7452
7480
|
if (b >= o && b <= s && (!(i <= this.zoom) || b % (i < this.zoom / 2 ? 5 : 3) === 0)) {
|
|
7453
|
-
const
|
|
7481
|
+
const P = L.point([b, m], {
|
|
7454
7482
|
val: f[m].val[_],
|
|
7455
7483
|
spd: f[m].spd[_]
|
|
7456
7484
|
});
|
|
7457
|
-
y.push(
|
|
7485
|
+
y.push(P);
|
|
7458
7486
|
}
|
|
7459
7487
|
});
|
|
7460
7488
|
}
|
|
@@ -7571,8 +7599,8 @@ const es = {
|
|
|
7571
7599
|
this.handleBeforeLayerToggle();
|
|
7572
7600
|
},
|
|
7573
7601
|
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 || (
|
|
7602
|
+
var a, e, t, r, i, o, s, n, c, d, p, h, g;
|
|
7603
|
+
(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
7604
|
},
|
|
7577
7605
|
handleDateChange(a = { tropicals: !1 }) {
|
|
7578
7606
|
this.fetchWeatherLayers(a), this.fetchOtherLayers({ dayNight: !0 });
|
|
@@ -7626,8 +7654,8 @@ const es = {
|
|
|
7626
7654
|
});
|
|
7627
7655
|
},
|
|
7628
7656
|
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)) && ((
|
|
7657
|
+
var e, t, r, i, o, s, n, c, d, p, h, g, u, y, f, m, v, b, _, P;
|
|
7658
|
+
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
7659
|
},
|
|
7632
7660
|
handleParticle(a) {
|
|
7633
7661
|
this.particleFactor = a, this.weatherLayers[a.key] && (this.weatherLayers[a.key].particle = a.particle), this.activeWeatherLayers.forEach((r) => {
|
|
@@ -7648,8 +7676,8 @@ const es = {
|
|
|
7648
7676
|
className: "map-gl-home"
|
|
7649
7677
|
};
|
|
7650
7678
|
function as(a, e, t, r, i, o) {
|
|
7651
|
-
var ie, X,
|
|
7652
|
-
const s =
|
|
7679
|
+
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;
|
|
7680
|
+
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
7681
|
return t.map ? (x(), C("div", ts, [
|
|
7654
7682
|
k(s, E({
|
|
7655
7683
|
ref: "layer",
|
|
@@ -7680,18 +7708,18 @@ function as(a, e, t, r, i, o) {
|
|
|
7680
7708
|
}, a.$attrs), null, 16, ["map", "sig-wave", "before-layer"]),
|
|
7681
7709
|
k(d, E({
|
|
7682
7710
|
map: t.map,
|
|
7683
|
-
swell: (
|
|
7711
|
+
swell: (q = i.weatherLayers) == null ? void 0 : q.swell,
|
|
7684
7712
|
"before-layer": t.beforeLayer
|
|
7685
7713
|
}, a.$attrs), null, 16, ["map", "swell", "before-layer"]),
|
|
7686
|
-
k(
|
|
7714
|
+
k(p, E({
|
|
7687
7715
|
map: t.map,
|
|
7688
7716
|
prmsl: (be = i.weatherLayers) == null ? void 0 : be.prmsl,
|
|
7689
7717
|
"before-layer": t.beforeLayer,
|
|
7690
7718
|
"active-weather-layers": i.activeWeatherLayers
|
|
7691
7719
|
}, a.$attrs), null, 16, ["map", "prmsl", "before-layer", "active-weather-layers"]),
|
|
7692
|
-
k(
|
|
7720
|
+
k(h, E({
|
|
7693
7721
|
map: t.map,
|
|
7694
|
-
iceberg: (
|
|
7722
|
+
iceberg: (Q = i.weatherLayers) == null ? void 0 : Q.iceberg,
|
|
7695
7723
|
"before-layer": t.beforeLayer
|
|
7696
7724
|
}, a.$attrs), null, 16, ["map", "iceberg", "before-layer"]),
|
|
7697
7725
|
k(g, E({
|
|
@@ -7723,7 +7751,7 @@ function as(a, e, t, r, i, o) {
|
|
|
7723
7751
|
ref: "windBarb",
|
|
7724
7752
|
map: t.map,
|
|
7725
7753
|
"map-projection": i.mapProjection,
|
|
7726
|
-
wind: (
|
|
7754
|
+
wind: (K = i.weatherLayers) == null ? void 0 : K.wind,
|
|
7727
7755
|
current: (we = i.weatherLayers) == null ? void 0 : we.current,
|
|
7728
7756
|
"before-layer": t.beforeLayer,
|
|
7729
7757
|
"margin-bottom": i.showRampColor ? "56px" : "30px",
|
|
@@ -7757,7 +7785,7 @@ function as(a, e, t, r, i, o) {
|
|
|
7757
7785
|
"before-layer": t.beforeLayer,
|
|
7758
7786
|
"toggle-version": t.toggleVersion
|
|
7759
7787
|
}, a.$attrs), null, 16, ["viewport", "factor", "before-layer", "toggle-version"]),
|
|
7760
|
-
k(
|
|
7788
|
+
k(P, E({
|
|
7761
7789
|
viewport: i.viewport,
|
|
7762
7790
|
factor: (Te = i.weatherLayers) == null ? void 0 : Te.temp,
|
|
7763
7791
|
"before-layer": t.beforeLayer,
|
|
@@ -7832,7 +7860,7 @@ function as(a, e, t, r, i, o) {
|
|
|
7832
7860
|
show: i.showPoint,
|
|
7833
7861
|
meteo: i.meteo
|
|
7834
7862
|
}, a.$attrs, { onPoint: o.handlePointChange }), null, 16, ["map", "show", "meteo", "onPoint"])
|
|
7835
|
-
])) :
|
|
7863
|
+
])) : j("", !0);
|
|
7836
7864
|
}
|
|
7837
7865
|
const is = /* @__PURE__ */ T(es, [["render", as]]), ds = {
|
|
7838
7866
|
install(a) {
|
|
@@ -7848,5 +7876,5 @@ export {
|
|
|
7848
7876
|
Ke as TropicalGL,
|
|
7849
7877
|
Ve as Viewport,
|
|
7850
7878
|
Le as WebGL,
|
|
7851
|
-
|
|
7879
|
+
B as WebGLSchema
|
|
7852
7880
|
};
|