@idmwx/idmui-gl3 4.0.6 → 4.0.8
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 +53 -45
- package/dist/index.umd.cjs +1 -1
- package/dist/mapbox/src/components/other/point.vue.d.ts +8 -2
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -451,10 +451,10 @@ const Wt = {
|
|
|
451
451
|
}, Ft = {
|
|
452
452
|
key: 1,
|
|
453
453
|
class: "iconfont"
|
|
454
|
-
},
|
|
454
|
+
}, Ut = {
|
|
455
455
|
key: 0,
|
|
456
456
|
class: "iconfont active"
|
|
457
|
-
},
|
|
457
|
+
}, Vt = {
|
|
458
458
|
key: 1,
|
|
459
459
|
class: "iconfont"
|
|
460
460
|
};
|
|
@@ -481,7 +481,7 @@ function Zt(a, e, t, r, i, o) {
|
|
|
481
481
|
style: { "margin-left": "16px" },
|
|
482
482
|
onClick: e[1] || (e[1] = (s) => i.showFeather = !i.showFeather)
|
|
483
483
|
}, [
|
|
484
|
-
i.showFeather ? (L(), x("i",
|
|
484
|
+
i.showFeather ? (L(), x("i", Ut, "")) : (L(), x("i", Vt, "")),
|
|
485
485
|
l("span", {
|
|
486
486
|
class: M(i.showFeather ? "active" : "")
|
|
487
487
|
}, "Wind Feather", 2)
|
|
@@ -811,9 +811,9 @@ R(N, "fragmentSchema", `
|
|
|
811
811
|
vec4 color = texture2D(u_color, vec2(rgba.r, 0));
|
|
812
812
|
gl_FragColor = color;
|
|
813
813
|
}`);
|
|
814
|
-
class
|
|
814
|
+
class V {
|
|
815
815
|
}
|
|
816
|
-
R(
|
|
816
|
+
R(V, "vertexSchema", `
|
|
817
817
|
precision mediump float;
|
|
818
818
|
|
|
819
819
|
attribute float a_index; // 索引
|
|
@@ -837,7 +837,7 @@ R(U, "vertexSchema", `
|
|
|
837
837
|
gl_PointSize = 1.0;
|
|
838
838
|
// gl_PointSize = u_point;
|
|
839
839
|
gl_Position = vec4(2.0 * v_particle_pos.x - 1.0, 1.0 - 2.0 * v_particle_pos.y, 0, 1);
|
|
840
|
-
}`), R(
|
|
840
|
+
}`), R(V, "fragmentSchema", `
|
|
841
841
|
precision mediump float;
|
|
842
842
|
|
|
843
843
|
uniform sampler2D u_factor;
|
|
@@ -859,7 +859,7 @@ R(U, "vertexSchema", `
|
|
|
859
859
|
|
|
860
860
|
float f = 1.0 - uv.b;
|
|
861
861
|
gl_FragColor = texture2D(u_color_ramp, ramp_pos) * f;
|
|
862
|
-
}`), R(
|
|
862
|
+
}`), R(V, "quadVertSchema", `
|
|
863
863
|
precision mediump float;
|
|
864
864
|
|
|
865
865
|
attribute vec2 a_pos;
|
|
@@ -869,7 +869,7 @@ R(U, "vertexSchema", `
|
|
|
869
869
|
void main() {
|
|
870
870
|
v_tex_pos = a_pos;
|
|
871
871
|
gl_Position = vec4(1.0 - 2.0 * a_pos, 0, 1);
|
|
872
|
-
}`), R(
|
|
872
|
+
}`), R(V, "screenFragmentSchema", `
|
|
873
873
|
precision mediump float;
|
|
874
874
|
|
|
875
875
|
uniform sampler2D u_screen;
|
|
@@ -881,7 +881,7 @@ R(U, "vertexSchema", `
|
|
|
881
881
|
vec4 color = texture2D(u_screen, 1.0 - v_tex_pos);
|
|
882
882
|
// a hack to guarantee opacity fade out even with a value close to 1.0
|
|
883
883
|
gl_FragColor = vec4(floor(255.0 * color * u_opacity) / 255.0);
|
|
884
|
-
}`), R(
|
|
884
|
+
}`), R(V, "updateFragmentSchema", `
|
|
885
885
|
precision mediump float;
|
|
886
886
|
|
|
887
887
|
uniform sampler2D u_particles;
|
|
@@ -2692,11 +2692,11 @@ const Jt = {
|
|
|
2692
2692
|
];
|
|
2693
2693
|
this.wrapper = this.webgl.bindParticle(
|
|
2694
2694
|
this.particleContext,
|
|
2695
|
-
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
2695
|
+
V.vertexSchema,
|
|
2696
|
+
V.fragmentSchema,
|
|
2697
|
+
V.quadVertSchema,
|
|
2698
|
+
V.screenFragmentSchema,
|
|
2699
|
+
V.updateFragmentSchema
|
|
2700
2700
|
), this.wrapper.color = this.webgl.setup(this.particleContext, a, !0, 16, 16), this.wrapper = { ...this.wrapper, ...this.webgl.setupParticle(this.particleContext, 9e3), ...this.webgl.resize(this.viewport, this.particleContext) }, this.viewport.map.on("resize", this.handleResize), this.viewport.map.on("movestart", this.handlePause), this.viewport.map.on("moveend", this.handlePlay);
|
|
2701
2701
|
}
|
|
2702
2702
|
},
|
|
@@ -3070,11 +3070,11 @@ const ya = {
|
|
|
3070
3070
|
];
|
|
3071
3071
|
this.wrapper = this.webgl.bindParticle(
|
|
3072
3072
|
this.particleContext,
|
|
3073
|
-
|
|
3074
|
-
|
|
3075
|
-
|
|
3076
|
-
|
|
3077
|
-
|
|
3073
|
+
V.vertexSchema,
|
|
3074
|
+
V.fragmentSchema,
|
|
3075
|
+
V.quadVertSchema,
|
|
3076
|
+
V.screenFragmentSchema,
|
|
3077
|
+
V.updateFragmentSchema
|
|
3078
3078
|
), this.wrapper.color = this.webgl.setup(this.particleContext, a, !0, 16, 16), this.wrapper = {
|
|
3079
3079
|
...this.wrapper,
|
|
3080
3080
|
...this.webgl.setupParticle(this.particleContext, 12e3),
|
|
@@ -3970,15 +3970,15 @@ const Wa = {
|
|
|
3970
3970
|
})), this.interpolateMarkers = [];
|
|
3971
3971
|
for (const E of Y)
|
|
3972
3972
|
if (!E.properties.disabled) {
|
|
3973
|
-
let
|
|
3974
|
-
((s = (n = E.properties) == null ? void 0 : n.wind) == null ? void 0 : s.spd) < 17.2 || !((h = (c = E.properties) == null ? void 0 : c.wind) != null && h.spd) ?
|
|
3973
|
+
let U = "#f44336";
|
|
3974
|
+
((s = (n = E.properties) == null ? void 0 : n.wind) == null ? void 0 : s.spd) < 17.2 || !((h = (c = E.properties) == null ? void 0 : c.wind) != null && h.spd) ? U = "#03f869" : ((p = (d = E.properties) == null ? void 0 : d.wind) == null ? void 0 : p.spd) >= 17.2 && ((m = (f = E.properties) == null ? void 0 : f.wind) == null ? void 0 : m.spd) < 24.5 ? U = "#f2f202" : ((y = (b = E.properties) == null ? void 0 : b.wind) == null ? void 0 : y.spd) >= 24.5 && ((v = (u = E.properties) == null ? void 0 : u.wind) == null ? void 0 : v.spd) < 32.7 ? U = "#ff9100" : ((w = (g = E.properties) == null ? void 0 : g.wind) == null ? void 0 : w.spd) >= 32.7 && ((_ = (k = E.properties) == null ? void 0 : k.wind) == null ? void 0 : _.spd) < 41.5 ? U = "#f44336" : ((A = (D = E.properties) == null ? void 0 : D.wind) == null ? void 0 : A.spd) >= 41.5 && ((W = (B = E.properties) == null ? void 0 : B.wind) == null ? void 0 : W.spd) < 51 ? U = "#f903d0" : ((J = (O = E.properties) == null ? void 0 : O.wind) == null ? void 0 : J.spd) >= 51 ? U = "#8702f9" : U = "#f44336";
|
|
3975
3975
|
const ve = `<svg t="1719918955501"
|
|
3976
3976
|
class="icon" viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg" p-id="18382"
|
|
3977
3977
|
xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200">
|
|
3978
3978
|
<path
|
|
3979
3979
|
d="M515.17000001 169.34666667c41-77.73 95.33-96 95.33-96-240 0-434.5 194.53-434.5 434.5 0 186.47 150.78 337.7 337.06 338.48C472.11000001 923.66666667 418.00000001 941.83666667 418.00000001 941.83666667c240 0 434.5-194.54 434.5-434.5l0.5 0.5C853.00000001 321.10666667 701.81000001 169.66666667 515.17000001 169.34666667z m-0.67 468A129.5 129.5 0 1 1 644.00000001 507.83666667a129.5 129.5 0 0 1-129.5 129.5z"
|
|
3980
|
-
fill="${
|
|
3981
|
-
<path d="M514.50000001 507.83666667m-129.5 0a129.5 129.5 0 1 0 259 0 129.5 129.5 0 1 0-259 0Z" fill="${
|
|
3980
|
+
fill="${U}" p-id="18383"></path>
|
|
3981
|
+
<path d="M514.50000001 507.83666667m-129.5 0a129.5 129.5 0 1 0 259 0 129.5 129.5 0 1 0-259 0Z" fill="${U}"
|
|
3982
3982
|
p-id="18384"></path>
|
|
3983
3983
|
<path
|
|
3984
3984
|
d="M517.16666667 654.67c-80.23 0-145.5-65.27-145.5-145.5s65.27-145.5 145.5-145.5S662.66666667 428.94 662.66666667 509.17s-65.27 145.5-145.5 145.5z m0-259A113.5 113.5 0 1 0 630.66666667 509.17a113.63 113.63 0 0 0-113.5-113.5z"
|
|
@@ -4117,7 +4117,7 @@ const Wa = {
|
|
|
4117
4117
|
}, je = (a) => (H("data-v-08ecb5a5"), a = a(), G(), a), Oa = {
|
|
4118
4118
|
id: "active-tropical",
|
|
4119
4119
|
class: "active-tropical"
|
|
4120
|
-
}, ja = { class: "header-box" }, Fa = { class: "main" },
|
|
4120
|
+
}, ja = { class: "header-box" }, Fa = { class: "main" }, Ua = { key: 0 }, Va = { class: "sub" }, Za = {
|
|
4121
4121
|
id: "meteoBox",
|
|
4122
4122
|
class: "main-box"
|
|
4123
4123
|
}, Ha = { class: "content" }, Ga = { class: "row" }, Ja = {
|
|
@@ -4139,10 +4139,10 @@ function oi(a, e, t, r, i, o) {
|
|
|
4139
4139
|
onClick: e[0] || (e[0] = (_) => i.showTropicals = !1)
|
|
4140
4140
|
}, ""),
|
|
4141
4141
|
l("div", Fa, [
|
|
4142
|
-
(s = (n = i.activeTropicals) == null ? void 0 : n.history) != null && s.level ? (L(), x("span",
|
|
4142
|
+
(s = (n = i.activeTropicals) == null ? void 0 : n.history) != null && s.level ? (L(), x("span", Ua, S((h = (c = i.activeTropicals) == null ? void 0 : c.history) == null ? void 0 : h.level) + " , ", 1)) : $("", !0),
|
|
4143
4143
|
Xe(S((d = i.activeTropicals) == null ? void 0 : d.name), 1)
|
|
4144
4144
|
]),
|
|
4145
|
-
l("div",
|
|
4145
|
+
l("div", Va, " Last update: " + S(o.computeTime(((f = (p = i.activeTropicals) == null ? void 0 : p.history) == null ? void 0 : f.updated) || ((y = (b = (m = i.activeTropicals) == null ? void 0 : m.forecasts) == null ? void 0 : b.filter((_) => !_.disabled)[0]) == null ? void 0 : y.date))), 1)
|
|
4146
4146
|
]),
|
|
4147
4147
|
l("div", Za, [
|
|
4148
4148
|
l("div", Ha, [
|
|
@@ -4651,9 +4651,9 @@ const ji = {
|
|
|
4651
4651
|
this.webgl.draw(this.viewport, this.context, this.program, this.texture, this.rampColor.texture, this.aPositionBuffer), this.viewport.toggle(!0);
|
|
4652
4652
|
}
|
|
4653
4653
|
}
|
|
4654
|
-
}, he = (a) => (H("data-v-389ea886"), a = a(), G(), a), Fi = { key: 0 },
|
|
4655
|
-
Vi,
|
|
4654
|
+
}, he = (a) => (H("data-v-389ea886"), a = a(), G(), a), Fi = { key: 0 }, Ui = /* @__PURE__ */ he(() => /* @__PURE__ */ l("span", null, "°C", -1)), Vi = /* @__PURE__ */ he(() => /* @__PURE__ */ l("span", null, "-20", -1)), Zi = /* @__PURE__ */ he(() => /* @__PURE__ */ l("span", null, "-10", -1)), Hi = /* @__PURE__ */ he(() => /* @__PURE__ */ l("span", null, "0", -1)), Gi = /* @__PURE__ */ he(() => /* @__PURE__ */ l("span", null, "10", -1)), Ji = /* @__PURE__ */ he(() => /* @__PURE__ */ l("span", null, "20", -1)), Xi = /* @__PURE__ */ he(() => /* @__PURE__ */ l("span", null, "30", -1)), qi = /* @__PURE__ */ he(() => /* @__PURE__ */ l("span", null, "40", -1)), Yi = [
|
|
4656
4655
|
Ui,
|
|
4656
|
+
Vi,
|
|
4657
4657
|
Zi,
|
|
4658
4658
|
Hi,
|
|
4659
4659
|
Gi,
|
|
@@ -4795,6 +4795,10 @@ const dr = {
|
|
|
4795
4795
|
show: {
|
|
4796
4796
|
type: Boolean
|
|
4797
4797
|
},
|
|
4798
|
+
timeZone: {
|
|
4799
|
+
type: Number,
|
|
4800
|
+
default: 0
|
|
4801
|
+
},
|
|
4798
4802
|
meteo: {
|
|
4799
4803
|
type: Object
|
|
4800
4804
|
}
|
|
@@ -4827,7 +4831,11 @@ const dr = {
|
|
|
4827
4831
|
computed: {
|
|
4828
4832
|
computeTime() {
|
|
4829
4833
|
return function(a) {
|
|
4830
|
-
|
|
4834
|
+
if (a) {
|
|
4835
|
+
const e = Z(a).utc().utcOffset(this.timeZone), t = this.timeZone < 0 ? this.timeZone : "+" + this.timeZone;
|
|
4836
|
+
return `${e.format("MMM-DD,HHmm")} ( UTC ${t} )`;
|
|
4837
|
+
}
|
|
4838
|
+
return "-";
|
|
4831
4839
|
};
|
|
4832
4840
|
},
|
|
4833
4841
|
computeLat() {
|
|
@@ -4864,7 +4872,7 @@ const dr = {
|
|
|
4864
4872
|
}
|
|
4865
4873
|
}
|
|
4866
4874
|
}
|
|
4867
|
-
}, q = (a) => (H("data-v-
|
|
4875
|
+
}, q = (a) => (H("data-v-97102c3b"), a = a(), G(), a), pr = {
|
|
4868
4876
|
id: "point-meteo",
|
|
4869
4877
|
class: "point-meteo"
|
|
4870
4878
|
}, mr = { class: "meteo-box" }, ur = { class: "header-box" }, yr = { class: "main" }, fr = { class: "sub" }, gr = { class: "main-box" }, br = { class: "flex-space" }, vr = /* @__PURE__ */ q(() => /* @__PURE__ */ l("label", null, "Wind", -1)), _r = { class: "flex-space" }, wr = /* @__PURE__ */ q(() => /* @__PURE__ */ l("label", null, "Wind.Wave", -1)), Lr = { class: "flex-space" }, xr = /* @__PURE__ */ q(() => /* @__PURE__ */ l("label", null, "Swell", -1)), Cr = { class: "flex-space" }, Sr = /* @__PURE__ */ q(() => /* @__PURE__ */ l("label", null, "Sig.Wave", -1)), kr = { class: "flex-space" }, zr = /* @__PURE__ */ q(() => /* @__PURE__ */ l("label", null, "Current", -1)), Pr = { class: "flex-space" }, Tr = /* @__PURE__ */ q(() => /* @__PURE__ */ l("label", null, "Precip", -1)), Er = { class: "flex-space" }, Ir = /* @__PURE__ */ q(() => /* @__PURE__ */ l("label", null, "Visibility", -1)), Rr = { class: "flex-space" }, Dr = /* @__PURE__ */ q(() => /* @__PURE__ */ l("label", null, "Temp", -1)), Ar = { class: "flex-space" }, Mr = /* @__PURE__ */ q(() => /* @__PURE__ */ l("label", null, "Water Temp", -1)), $r = {
|
|
@@ -4875,7 +4883,7 @@ const dr = {
|
|
|
4875
4883
|
Br
|
|
4876
4884
|
];
|
|
4877
4885
|
function Wr(a, e, t, r, i, o) {
|
|
4878
|
-
var n, s, c, h, d, p, f, m, b, y, u, v, g, w, k, _, D, A, B, W, O, J, de, pe, me, ue, ye, fe, ge, ae, X, Y, be, Q, E,
|
|
4886
|
+
var n, s, c, h, d, p, f, m, b, y, u, v, g, w, k, _, D, A, B, W, O, J, de, pe, me, ue, ye, fe, ge, ae, X, Y, be, Q, E, U, ve, K, _e, ie, re, oe, ke, ze, Pe, Te, Ee;
|
|
4879
4887
|
return Me((L(), x("div", pr, [
|
|
4880
4888
|
l("div", mr, [
|
|
4881
4889
|
l("div", ur, [
|
|
@@ -4901,7 +4909,7 @@ function Wr(a, e, t, r, i, o) {
|
|
|
4901
4909
|
]),
|
|
4902
4910
|
l("div", Cr, [
|
|
4903
4911
|
Sr,
|
|
4904
|
-
l("span", null, S(((Y = (X = (ae = t.meteo) == null ? void 0 : ae.wave) == null ? void 0 : X.sig) == null ? void 0 : Y.direction) || "-") + "/" + S(o.roundPrecision((E = (Q = (be = t.meteo) == null ? void 0 : be.wave) == null ? void 0 : Q.sig) == null ? void 0 : E.height, 1)) + "[m]/" + S(o.roundPrecision((K = (ve = (
|
|
4912
|
+
l("span", null, S(((Y = (X = (ae = t.meteo) == null ? void 0 : ae.wave) == null ? void 0 : X.sig) == null ? void 0 : Y.direction) || "-") + "/" + S(o.roundPrecision((E = (Q = (be = t.meteo) == null ? void 0 : be.wave) == null ? void 0 : Q.sig) == null ? void 0 : E.height, 1)) + "[m]/" + S(o.roundPrecision((K = (ve = (U = t.meteo) == null ? void 0 : U.wave) == null ? void 0 : ve.sig) == null ? void 0 : K.period, 1)) + "[s]", 1)
|
|
4905
4913
|
]),
|
|
4906
4914
|
l("div", kr, [
|
|
4907
4915
|
zr,
|
|
@@ -4930,7 +4938,7 @@ function Wr(a, e, t, r, i, o) {
|
|
|
4930
4938
|
[$e, i.showMeteo]
|
|
4931
4939
|
]);
|
|
4932
4940
|
}
|
|
4933
|
-
const Or = /* @__PURE__ */ T(dr, [["render", Wr], ["__scopeId", "data-v-
|
|
4941
|
+
const Or = /* @__PURE__ */ T(dr, [["render", Wr], ["__scopeId", "data-v-97102c3b"]]), jr = {
|
|
4934
4942
|
name: "IdmWarZone",
|
|
4935
4943
|
props: {
|
|
4936
4944
|
map: {
|
|
@@ -5023,7 +5031,7 @@ const Or = /* @__PURE__ */ T(dr, [["render", Wr], ["__scopeId", "data-v-ef7fa87d
|
|
|
5023
5031
|
function Fr(a, e, t, r, i, o) {
|
|
5024
5032
|
return L(), x("div");
|
|
5025
5033
|
}
|
|
5026
|
-
const
|
|
5034
|
+
const Ur = /* @__PURE__ */ T(jr, [["render", Fr]]), Vr = {
|
|
5027
5035
|
name: "IdmGmdssArea",
|
|
5028
5036
|
props: {
|
|
5029
5037
|
map: {
|
|
@@ -5146,7 +5154,7 @@ const Vr = /* @__PURE__ */ T(jr, [["render", Fr]]), Ur = {
|
|
|
5146
5154
|
function Zr(a, e, t, r, i, o) {
|
|
5147
5155
|
return L(), x("div");
|
|
5148
5156
|
}
|
|
5149
|
-
const Hr = /* @__PURE__ */ T(
|
|
5157
|
+
const Hr = /* @__PURE__ */ T(Vr, [["render", Zr]]), Gr = {
|
|
5150
5158
|
name: "IdmEcaZone",
|
|
5151
5159
|
props: {
|
|
5152
5160
|
map: {
|
|
@@ -6498,10 +6506,10 @@ const Bo = {
|
|
|
6498
6506
|
methods: {}
|
|
6499
6507
|
}, Ke = (a) => (H("data-v-ab627b83"), a = a(), G(), a), No = { key: 0 }, Wo = { class: "bar-item" }, Oo = /* @__PURE__ */ Ke(() => /* @__PURE__ */ l("span", { class: "iconfont" }, "HI", -1)), jo = [
|
|
6500
6508
|
Oo
|
|
6501
|
-
], Fo = /* @__PURE__ */ Ke(() => /* @__PURE__ */ l("span", { class: "iconfont" }, "I4", -1)),
|
|
6509
|
+
], Fo = /* @__PURE__ */ Ke(() => /* @__PURE__ */ l("span", { class: "iconfont" }, "I4", -1)), Uo = [
|
|
6502
6510
|
Fo
|
|
6503
6511
|
];
|
|
6504
|
-
function
|
|
6512
|
+
function Vo(a, e, t, r, i, o) {
|
|
6505
6513
|
return t.enabled && t.permission & i.helper.LEVEL.Supper ? (L(), x("div", No, [
|
|
6506
6514
|
l("div", {
|
|
6507
6515
|
class: "menu-bar-box",
|
|
@@ -6515,12 +6523,12 @@ function Uo(a, e, t, r, i, o) {
|
|
|
6515
6523
|
l("div", {
|
|
6516
6524
|
class: M(i.vendor === "i4" ? "menu-icon active" : "menu-icon"),
|
|
6517
6525
|
onClick: e[1] || (e[1] = (n) => i.vendor = "i4")
|
|
6518
|
-
},
|
|
6526
|
+
}, Uo, 2)
|
|
6519
6527
|
])
|
|
6520
6528
|
], 4)
|
|
6521
6529
|
])) : $("", !0);
|
|
6522
6530
|
}
|
|
6523
|
-
const Zo = /* @__PURE__ */ T(Bo, [["render",
|
|
6531
|
+
const Zo = /* @__PURE__ */ T(Bo, [["render", Vo], ["__scopeId", "data-v-ab627b83"]]);
|
|
6524
6532
|
const Ho = {
|
|
6525
6533
|
name: "IdmGLV2",
|
|
6526
6534
|
components: {
|
|
@@ -6540,7 +6548,7 @@ const Ho = {
|
|
|
6540
6548
|
IdmWaterTemp: Oi,
|
|
6541
6549
|
IdmTemp: Ki,
|
|
6542
6550
|
IdmArctic: hr,
|
|
6543
|
-
IdmWarZone:
|
|
6551
|
+
IdmWarZone: Ur,
|
|
6544
6552
|
IdmGmdssArea: Hr,
|
|
6545
6553
|
IdmEcaZone: Xr,
|
|
6546
6554
|
IdmAlertZone: eo,
|
|
@@ -7137,7 +7145,7 @@ const Ho = {
|
|
|
7137
7145
|
className: "map-gl-home"
|
|
7138
7146
|
};
|
|
7139
7147
|
function Jo(a, e, t, r, i, o) {
|
|
7140
|
-
var ae, X, Y, be, Q, E,
|
|
7148
|
+
var ae, X, Y, be, Q, E, U, ve, K, _e, ie, re, oe, ke, ze, Pe, Te, Ee, Ne, Fe, Ue, Ve, Ze, He, Ge, Je;
|
|
7141
7149
|
const n = z("IdmGlLayer"), s = z("IdmENC"), c = z("IdmSigWave"), h = z("IdmSwell"), d = z("IdmPrmsl"), p = z("IdmIceberg"), f = z("IdmTropicals"), m = z("IdmCurrents"), b = z("IdmCurrentParticle"), y = z("IdmWindBarb"), u = z("IdmWindParticle"), v = z("IdmPrecip3h"), g = z("IdmVisibility"), w = z("IdmWaterTemp"), k = z("IdmTemp"), _ = z("IdmArctic"), D = z("IdmWarZone"), A = z("IdmGmdssArea"), B = 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");
|
|
7142
7150
|
return t.map ? (L(), x("div", Go, [
|
|
7143
7151
|
P(n, I({
|
|
@@ -7192,7 +7200,7 @@ function Jo(a, e, t, r, i, o) {
|
|
|
7192
7200
|
P(m, I({
|
|
7193
7201
|
map: t.map,
|
|
7194
7202
|
"map-projection": i.mapProjection,
|
|
7195
|
-
current: (
|
|
7203
|
+
current: (U = i.weatherLayers) == null ? void 0 : U.current,
|
|
7196
7204
|
"before-layer": t.beforeLayer,
|
|
7197
7205
|
"show-particle": i.showCurrentParticle,
|
|
7198
7206
|
"margin-bottom": i.activeWindLayer ? i.showRampColor ? "84px" : "56px" : i.showRampColor ? "56px" : "30px",
|
|
@@ -7277,12 +7285,12 @@ function Jo(a, e, t, r, i, o) {
|
|
|
7277
7285
|
}, a.$attrs), null, 16, ["map", "zone", "before-layer"]),
|
|
7278
7286
|
P(O, I({
|
|
7279
7287
|
map: t.map,
|
|
7280
|
-
port: (
|
|
7288
|
+
port: (Ue = i.otherLayers) == null ? void 0 : Ue.ports,
|
|
7281
7289
|
"before-layer": t.beforeLayer
|
|
7282
7290
|
}, a.$attrs), null, 16, ["map", "port", "before-layer"]),
|
|
7283
7291
|
P(J, I({
|
|
7284
7292
|
map: t.map,
|
|
7285
|
-
line: (
|
|
7293
|
+
line: (Ve = i.otherLayers) == null ? void 0 : Ve["load-lines"],
|
|
7286
7294
|
"before-layer": t.beforeLayer
|
|
7287
7295
|
}, a.$attrs), null, 16, ["map", "line", "before-layer"]),
|
|
7288
7296
|
P(de, I({
|
|
@@ -7330,7 +7338,7 @@ export {
|
|
|
7330
7338
|
Xo as MapboxGL,
|
|
7331
7339
|
rs as MapboxGLPlugin,
|
|
7332
7340
|
Gt as MapboxHelper,
|
|
7333
|
-
|
|
7341
|
+
V as ParticleSchema,
|
|
7334
7342
|
Ye as TropicalGL,
|
|
7335
7343
|
Oe as Viewport,
|
|
7336
7344
|
we as WebGL,
|
package/dist/index.umd.cjs
CHANGED
|
@@ -201,4 +201,4 @@
|
|
|
201
201
|
<path
|
|
202
202
|
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"
|
|
203
203
|
fill="#ffffff" p-id="18386"></path>
|
|
204
|
-
</svg>`,H=document.createElement("div");H.className="hurricane-hourly-marker",H.innerHTML=`<div class="${S.geometry.coordinates[1]>=0?"center north":"center south"}">${de}</div>`;const pe=new Z.Marker(H).setLngLat(S.geometry.coordinates).addTo(this.map);if(this.interpolateMarkers.push(pe),(ie=S.properties)!=null&&ie.showCircle){const K={radius:100,coordinates:S.geometry.coordinates},ee={radius:200,coordinates:S.geometry.coordinates},te={radius:500,coordinates:S.geometry.coordinates};(oe=this.circleSourceData)==null||oe.features.push(x.circle(K.coordinates,K.radius,{steps:100,units:"kilometers",properties:{type:"tropicalCircle"}})),(re=this.circleSourceData)==null||re.features.push(x.circle(ee.coordinates,ee.radius,{steps:100,units:"kilometers",properties:{type:"tropicalCircle"}})),(se=this.circleSourceData)==null||se.features.push(x.circle(te.coordinates,te.radius,{steps:100,units:"kilometers",properties:{type:"tropicalCircle"}}))}(le=(ne=this.map)==null?void 0:ne.getSource(this.circleSource))==null||le.setData(this.circleSourceData)}}else(ce=this.map)!=null&&ce.getSource(this.interpolateSource)&&((Q=this.map)==null||Q.getSource(this.interpolateSource).setData(this.empty))},handleClick(a){var s,l,n,c,h,d,p,u;const e=a.features[0],t=(l=(s=this.tropicals)==null?void 0:s.data)==null?void 0:l.features.filter(m=>{var b;return m.geometry.type==="LineString"&&m.properties.type==="forecast"&&m.properties.name===((b=e==null?void 0:e.properties)==null?void 0:b.name)});t.sort((m,b)=>{var f,y,_,g;return((f=m.properties)==null?void 0:f.model)==="cma"?-1:((y=m.properties)==null?void 0:y.model)==="jma"?((_=b.properties)==null?void 0:_.model)==="cma"?1:-1:m.properties.model==="ecmwf"?["jma","cma"].includes((g=b.properties)==null?void 0:g.model)?1:-1:0});const r=(c=(n=this.tropicals)==null?void 0:n.data)==null?void 0:c.features.filter(m=>{var b;return m.geometry.type==="LineString"&&m.properties.type==="history"&&m.properties.name===((b=e==null?void 0:e.properties)==null?void 0:b.name)});this.activeTropicals={name:(h=e==null?void 0:e.properties)==null?void 0:h.name,forecasts:t.map(m=>m.properties),history:(d=r[0])==null?void 0:d.properties,showCircle:(u=(p=t[0])==null?void 0:p.properties)==null?void 0:u.showCircle},this.showTropicals=!0;const o=document.getElementById("active-tropical");this.activeTropicalsMarker?this.activeTropicalsMarker.setLngLat([a.lngLat.lng,a.lngLat.lat]):this.activeTropicalsMarker=new Z.Marker(o).setLngLat([a.lngLat.lng,a.lngLat.lat]).setOffset([220,0]).addTo(this.map)},handleForecastToggle(a){var r,o,s,l,n,c;a.disabled=!a.disabled;const e=`${a.name}-${a.model}`,t=(o=(r=this.map)==null?void 0:r.getSource(this.source)._data)==null?void 0:o.features;t.forEach(h=>{h.properties.category===e&&(h.properties.disabled=a.disabled)}),this.interpolateData.forEach(h=>{h.properties.category===e&&(h.properties.disabled=a.disabled)}),(l=(s=this.map)==null?void 0:s.getSource(this.source))==null||l.setData(x.featureCollection(t)),(c=(n=this.map)==null?void 0:n.getSource(this.clusterSource))==null||c.setData(x.featureCollection(t)),this.handleDateChange()},handleStrikeProbability(a){this.$emit("tropicalProbability",a)},handleToggleCircles(a){var e,t;a.showCircle=!a.showCircle,(t=(e=this.tropicals.data)==null?void 0:e.features)==null||t.forEach(r=>{r.properties.name===a.name&&(r.properties.showCircle=a.showCircle)}),this.handleRender()},handleDrawCircle(){var a,e;(a=this.map)!=null&&a.getSource(this.circleSource)?(e=this.map)==null||e.getSource(this.circleSource).setData(this.circleSourceData):(this.map.addSource(this.circleSource,{type:"geojson",data:this.circleSourceData}),this.map.addLayer({id:this.circleLayer,type:"line",source:this.circleSource,filter:["all",["==","$type","Polygon"],["==","type","tropicalCircle"]],paint:{"line-color":"#fff","line-width":2,"line-opacity":1,"line-dasharray":[1,1]}}))},handleComputePolygons(a){const e=[];for(const t of a){const r=t.properties.wind,o={ne:r.r7ne>=0?r.r7ne:void 0,se:r.r7se>=0?r.r7se:void 0,sw:r.r7sw>=0?r.r7sw:void 0,nw:r.r7nw>=0?r.r7nw:void 0},s=this.handleComputeArc(t.geometry.coordinates,o,{...t.properties,level:7});e.push(s);const l={ne:r.r10ne>=0?r.r10ne:void 0,se:r.r10se>=0?r.r10se:void 0,sw:r.r10sw>=0?r.r10sw:void 0,nw:r.r10nw>=0?r.r10nw:void 0},n=this.handleComputeArc(t.geometry.coordinates,l,{...t.properties,level:10});e.push(n)}return e},handleComputeArc(a,e,t){var s;const r=[];for(const l in e){const n=e[l]??0;let c;switch(l){case"ne":c=x.lineArc(a,n*1.852,0,90,{steps:n>0?64:1});break;case"se":c=x.lineArc(a,n*1.852,90,180,{steps:n>0?64:1});break;case"sw":c=x.lineArc(a,n*1.852,180,270,{steps:n>0?64:1});break;case"nw":c=x.lineArc(a,n*1.852,270,360,{steps:n>0?64:1});break}r.push(...(s=c==null?void 0:c.geometry)==null?void 0:s.coordinates)}const o=x.lineString(r);return x.lineToPolygon(o,{properties:t})}}},ve=a=>(i.pushScopeId("data-v-08ecb5a5"),a=a(),i.popScopeId(),a),Kt={id:"active-tropical",class:"active-tropical"},ea={class:"header-box"},ta={class:"main"},aa={key:0},ia={class:"sub"},oa={id:"meteoBox",class:"main-box"},ra={class:"content"},sa={class:"row"},na={class:"col col-left",style:{"justify-content":"flex-start"}},la=ve(()=>i.createElementVNode("label",null,"Wind speed : ",-1)),ca={class:"col col-right",style:{"justify-content":"flex-start"}},ha=ve(()=>i.createElementVNode("label",null,"Pressure : ",-1)),da={class:"row"},pa={class:"col col-24",style:{"justify-content":"flex-start"}},ma=ve(()=>i.createElementVNode("label",{style:{width:"max-content"}},"Forecast Models : ",-1)),ya={class:"forecast-models"},fa=["onClick"],ua=i.createStaticVNode('<div class="row" style="padding:0;height:1px;margin:10px 0;background:var(--idm-black-1);" data-v-08ecb5a5></div><div class="row" style="padding:2px 10px;" data-v-08ecb5a5><div class="legend" data-v-08ecb5a5><div class="icon td" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>TD</div></div><div class="legend" data-v-08ecb5a5><div class="icon ts" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>TS</div></div><div class="legend" data-v-08ecb5a5><div class="icon sts" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>STS</div></div><div class="legend" data-v-08ecb5a5><div class="icon ty" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>TY</div></div><div class="legend" data-v-08ecb5a5><div class="icon sty" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>STY</div></div><div class="legend" data-v-08ecb5a5><div class="icon supper-ty" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>Super TY</div></div></div><div class="row" style="padding:2px 10px;" data-v-08ecb5a5><div class="legend" data-v-08ecb5a5><div class="icon history" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>History</div></div><div class="legend" data-v-08ecb5a5><div class="icon r7" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>35kts Radii</div></div><div class="legend" data-v-08ecb5a5><div class="icon r10" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>50kts Radii</div></div></div>',3),ga={class:"more"};function ba(a,e,t,r,o,s){var l,n,c,h,d,p,u,m,b,f,y,_,g,w,v;return i.withDirectives((i.openBlock(),i.createElementBlock("div",Kt,[i.createElementVNode("div",ea,[i.createElementVNode("div",{class:"iconfont close-btn",onClick:e[0]||(e[0]=L=>o.showTropicals=!1)},""),i.createElementVNode("div",ta,[(n=(l=o.activeTropicals)==null?void 0:l.history)!=null&&n.level?(i.openBlock(),i.createElementBlock("span",aa,i.toDisplayString((h=(c=o.activeTropicals)==null?void 0:c.history)==null?void 0:h.level)+" , ",1)):i.createCommentVNode("",!0),i.createTextVNode(i.toDisplayString((d=o.activeTropicals)==null?void 0:d.name),1)]),i.createElementVNode("div",ia," Last update: "+i.toDisplayString(s.computeTime(((u=(p=o.activeTropicals)==null?void 0:p.history)==null?void 0:u.updated)||((f=(b=(m=o.activeTropicals)==null?void 0:m.forecasts)==null?void 0:b.filter(L=>!L.disabled)[0])==null?void 0:f.date))),1)]),i.createElementVNode("div",oa,[i.createElementVNode("div",ra,[i.createElementVNode("div",sa,[i.createElementVNode("div",na,[la,i.createElementVNode("span",null,i.toDisplayString(((_=(y=o.activeTropicals)==null?void 0:y.history)==null?void 0:_.kts)||"-")+"[kts]",1)]),i.createElementVNode("div",ca,[ha,i.createElementVNode("span",null,i.toDisplayString(((w=(g=o.activeTropicals)==null?void 0:g.history)==null?void 0:w.pressure)||"-")+"[hPa]",1)])]),i.createElementVNode("div",da,[i.createElementVNode("div",pa,[ma,i.createElementVNode("div",ya,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList((v=o.activeTropicals)==null?void 0:v.forecasts,(L,N)=>{var T,D,R,B;return i.openBlock(),i.createElementBlock("div",{key:N,class:i.normalizeClass(["model",L.disabled?"":"active",N>0&&N<((D=(T=o.activeTropicals)==null?void 0:T.forecasts)==null?void 0:D.length)-1&&((B=(R=o.activeTropicals)==null?void 0:R.forecasts)==null?void 0:B.length)>2?"center-child":""]),onClick:M=>s.handleForecastToggle(L)},[i.createElementVNode("span",{class:i.normalizeClass(L.model)},i.toDisplayString(L.model),3)],10,fa)}),128))])])]),ua]),i.createElementVNode("div",ga,[i.createElementVNode("div",{class:"button",onClick:e[1]||(e[1]=L=>s.handleStrikeProbability(o.activeTropicals))},"Strike Probability >>")])])],512)),[[i.vShow,o.showTropicals&&!a.$attrs.hideTropicalsLegend]])}const Ce=C(Qt,[["render",ba],["__scopeId","data-v-08ecb5a5"]]),tr="",_a={name:"IdmPrecip3h",props:{factor:{type:Object},viewport:{type:Object},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{program:void 0,context:void 0,texture:void 0,rampColor:void 0,aPositionBuffer:void 0,webgl:new J,etime:void 0,right:10}},watch:{"factor.version":{handler(){var a;(a=this.factor)!=null&&a.active?this.handleRender():this.handleClear()},deep:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{handleRender(){if(!this.viewport)setTimeout(()=>{this.handleRender()},500);else if(this.factor){const a=new Date().valueOf();let e=0,t=0;this.handleDraw(),t=new Date().valueOf()-(a+e),console.log("[precip3h] add elapsed: ",t,", total: ",e+=t)}},handleClear(){this.context=void 0,this.etime=void 0,this.viewport.toggle(!1)},handleSetup(){if(!this.context){this.context=this.viewport.rampColorCanvas.getContext("webgl");const a=[[0,"rgba(59, 126, 162, 0)"],[14/255,"rgba(84,170,230, 0)"],[15/255,"rgba(172, 210, 255, 0.8)"],[20/255,"rgba(51,202,248,0.8)"],[30/255,"rgba(3,248,103,0.8)"],[49/255,"rgba(14,201,3,0.8)"],[57/255,"rgba(190,226,2,0.8)"],[73/255,"rgba(248,1,1,0.8)"],[82/255,"rgba(197,5,58,0.8)"],[1,"rgba(197,5,58,0.8)"]];this.rampColor=this.webgl.setup(this.context,a);const{program:e,aPositionBuffer:t}=this.webgl.bind(this.context,I.vertexSchema,I.fragmentSchema);this.program=e,this.aPositionBuffer=t}},async handleDraw(){if(this.handleSetup(),this.etime!==this.factor.etime){this.etime=this.factor.etime;const a=await this.webgl.loadImg(this.factor.raw);this.texture=this.webgl.createTexture(this.context,this.context.NEAREST,this.context.LINEAR,this.context.CLAMP_TO_EDGE,a)}this.webgl.draw(this.viewport,this.context,this.program,this.texture,this.rampColor.texture,this.aPositionBuffer),this.viewport.toggle(!0)}}},q=a=>(i.pushScopeId("data-v-dec867b8"),a=a(),i.popScopeId(),a),La={key:0},wa=[q(()=>i.createElementVNode("span",null,"mm",-1)),q(()=>i.createElementVNode("span",null,"1.5",-1)),q(()=>i.createElementVNode("span",null,"2",-1)),q(()=>i.createElementVNode("span",null,"3",-1)),q(()=>i.createElementVNode("span",null,"7",-1)),q(()=>i.createElementVNode("span",null,"10",-1)),q(()=>i.createElementVNode("span",null,"20",-1)),q(()=>i.createElementVNode("span",null,"30",-1))];function xa(a,e,t,r,o,s){var l;return(l=t.factor)!=null&&l.active?(i.openBlock(),i.createElementBlock("div",La,[i.createElementVNode("div",{class:"legend-bars flex-center",style:i.normalizeStyle([{position:"absolute"},{right:o.right+"px",bottom:t.bottom}])},wa,4)])):i.createCommentVNode("",!0)}const va=C(_a,[["render",xa],["__scopeId","data-v-dec867b8"]]),hr="",Ca={name:"IdmVisibility",props:{factor:{type:Object},viewport:{type:Object},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{program:void 0,context:void 0,texture:void 0,rampColor:void 0,aPositionBuffer:void 0,webgl:new J,etime:void 0}},watch:{"factor.version":{handler(){var a;(a=this.factor)!=null&&a.active?this.handleRender():this.handleClear()},deep:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{handleRender(){if(!this.viewport)setTimeout(()=>{this.handleRender()},500);else if(this.factor){const a=new Date().valueOf();let e=0,t=0;this.handleDraw(),t=new Date().valueOf()-(a+e),console.log("[visibility] add elapsed: ",t,", total: ",e+=t)}},handleClear(){this.context=void 0,this.etime=void 0,this.viewport.toggle(!1)},handleSetup(){if(!this.context){this.context=this.viewport.rampColorCanvas.getContext("webgl");const a=[[0,"rgba(189,50,160,0.8)"],[8/255,"rgba(208,56,56,0.8)"],[27/255,"rgba(190,226,2,0.8)"],[60/255,"rgba(3,236,118,0.8)"],[160/255,"rgba(172, 210,255,0.8)"],[161/255,"rgba(172, 210,255,0)"],[1,"rgba(144,144,144,0)"]];this.rampColor=this.webgl.setup(this.context,a);const{program:e,aPositionBuffer:t}=this.webgl.bind(this.context,I.vertexSchema,I.fragmentSchema);this.program=e,this.aPositionBuffer=t}},async handleDraw(){if(this.handleSetup(),this.etime!==this.factor.etime){this.etime=this.factor.etime;const a=await this.webgl.loadImg(this.factor.raw);this.texture=this.webgl.createTexture(this.context,this.context.NEAREST,this.context.LINEAR,this.context.CLAMP_TO_EDGE,a)}this.webgl.draw(this.viewport,this.context,this.program,this.texture,this.rampColor.texture,this.aPositionBuffer),this.viewport.toggle(!0)}}},me=a=>(i.pushScopeId("data-v-952dee5c"),a=a(),i.popScopeId(),a),Sa={key:0},ka=[me(()=>i.createElementVNode("span",null,"nm",-1)),me(()=>i.createElementVNode("span",null,"0",-1)),me(()=>i.createElementVNode("span",null,"0.5",-1)),me(()=>i.createElementVNode("span",null,"1.5",-1)),me(()=>i.createElementVNode("span",null,"3",-1)),me(()=>i.createElementVNode("span",null,"9",-1))];function Ea(a,e,t,r,o,s){var l;return(l=t.factor)!=null&&l.active?(i.openBlock(),i.createElementBlock("div",Sa,[i.createElementVNode("div",{class:"legend-bars flex-center",style:i.normalizeStyle([{position:"absolute"},{right:a.right+"px",bottom:t.bottom}])},ka,4)])):i.createCommentVNode("",!0)}const za=C(Ca,[["render",Ea],["__scopeId","data-v-952dee5c"]]),gr="",Pa={name:"IdmWaterTemp",props:{factor:{type:Object},viewport:{type:Object},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{program:void 0,context:void 0,texture:void 0,rampColor:void 0,aPositionBuffer:void 0,webgl:new J,etime:void 0,right:10}},watch:{"factor.version":{handler(){var a;(a=this.factor)!=null&&a.active?this.handleRender():this.handleClear()},deep:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{handleRender(){if(!this.viewport)setTimeout(()=>{this.handleRender()},500);else if(this.factor){const a=new Date().valueOf();let e=0,t=0;this.handleDraw(),t=new Date().valueOf()-(a+e),console.log("[water-temp] add elapsed: ",t,", total: ",e+=t)}},handleClear(){this.context=void 0,this.etime=void 0,this.viewport.toggle(!1)},handleSetup(){if(!this.context){this.context=this.viewport.rampColorCanvas.getContext("webgl");const a=[[0,"rgba(95, 143, 197)"],[46/255,"rgba(95, 143, 197)"],[69/255,"rgb(80, 140, 62)"],[92/255,"rgb(121, 146, 28)"],[115/255,"rgb(171, 161, 14)"],[138/255,"rgb(223, 177, 69)"],[161/255,"rgb(243, 150, 6)"],[184/255,"rgb(236, 95, 21)"],[207/255,"rgb(190, 65, 18)"],[230/255,"rgb(138, 43, 10)"],[1,"rgb(138, 43, 10)"]];this.rampColor=this.webgl.setup(this.context,a);const{program:e,aPositionBuffer:t}=this.webgl.bind(this.context,I.vertexSchema,I.fragmentSchema);this.program=e,this.aPositionBuffer=t}},async handleDraw(){if(this.handleSetup(),this.etime!==this.factor.etime){this.etime=this.factor.etime;const a=await this.webgl.loadImg(this.factor.raw);this.texture=this.webgl.createTexture(this.context,this.context.NEAREST,this.context.LINEAR,this.context.CLAMP_TO_EDGE,a)}this.webgl.draw(this.viewport,this.context,this.program,this.texture,this.rampColor.texture,this.aPositionBuffer),this.viewport.toggle(!0)}}},ye=a=>(i.pushScopeId("data-v-67e5094b"),a=a(),i.popScopeId(),a),Na={key:0},Ta=[ye(()=>i.createElementVNode("span",null,"°C",-1)),ye(()=>i.createElementVNode("span",null,"0",-1)),ye(()=>i.createElementVNode("span",null,"10",-1)),ye(()=>i.createElementVNode("span",null,"20",-1)),ye(()=>i.createElementVNode("span",null,"30",-1)),ye(()=>i.createElementVNode("span",null,"40",-1))];function Ia(a,e,t,r,o,s){var l;return(l=t.factor)!=null&&l.active?(i.openBlock(),i.createElementBlock("div",Na,[i.createElementVNode("div",{class:"legend-bars flex-center",style:i.normalizeStyle([{position:"absolute"},{right:o.right+"px",bottom:t.bottom}])},Ta,4)])):i.createCommentVNode("",!0)}const Da=C(Pa,[["render",Ia],["__scopeId","data-v-67e5094b"]]),Cr="",Va={name:"IdmTemp",props:{factor:{type:Object},viewport:{type:Object},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{program:void 0,context:void 0,texture:void 0,rampColor:void 0,aPositionBuffer:void 0,webgl:new J,etime:void 0,right:10}},watch:{"factor.version":{handler(){var a;(a=this.factor)!=null&&a.active?this.handleRender():this.handleClear()},deep:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{handleRender(){if(!this.viewport)setTimeout(()=>{this.handleRender()},500);else if(this.factor){const a=new Date().valueOf();let e=0,t=0;this.handleDraw(),t=new Date().valueOf()-(a+e),console.log("[water-temp] add elapsed: ",t,", total: ",e+=t)}},handleClear(){this.context=void 0,this.etime=void 0,this.viewport.toggle(!1)},handleSetup(){if(!this.context){this.context=this.viewport.rampColorCanvas.getContext("webgl");const a=[[0,"rgb(149, 137, 211)"],[100/255,"rgb(149, 137, 211)"],[110/255,"rgb(150, 209, 216)"],[120/255,"rgb(129, 204, 197)"],[130/255,"rgb(103, 180, 186)"],[140/255,"rgb(95, 143, 197)"],[150/255,"rgb(80, 140, 62)"],[160/255,"rgb(121, 146, 28)"],[170/255,"rgb(171, 161, 14)"],[180/255,"rgb(223, 177, 6)"],[190/255,"rgb(243, 150, 6)"],[200/255,"rgb(236, 95, 21)"],[210/255,"rgb(190, 65, 18)"],[220/255,"rgb(138, 43, 10)"],[1,"rgb(138, 43, 10)"]];this.rampColor=this.webgl.setup(this.context,a);const{program:e,aPositionBuffer:t}=this.webgl.bind(this.context,I.vertexSchema,I.fragmentSchema);this.program=e,this.aPositionBuffer=t}},async handleDraw(){if(this.handleSetup(),this.etime!==this.factor.etime){this.etime=this.factor.etime;const a=await this.webgl.loadImg(this.factor.raw);this.texture=this.webgl.createTexture(this.context,this.context.NEAREST,this.context.LINEAR,this.context.CLAMP_TO_EDGE,a)}this.webgl.draw(this.viewport,this.context,this.program,this.texture,this.rampColor.texture,this.aPositionBuffer),this.viewport.toggle(!0)}}},Y=a=>(i.pushScopeId("data-v-389ea886"),a=a(),i.popScopeId(),a),Ra={key:0},Ba=[Y(()=>i.createElementVNode("span",null,"°C",-1)),Y(()=>i.createElementVNode("span",null,"-20",-1)),Y(()=>i.createElementVNode("span",null,"-10",-1)),Y(()=>i.createElementVNode("span",null,"0",-1)),Y(()=>i.createElementVNode("span",null,"10",-1)),Y(()=>i.createElementVNode("span",null,"20",-1)),Y(()=>i.createElementVNode("span",null,"30",-1)),Y(()=>i.createElementVNode("span",null,"40",-1))];function $a(a,e,t,r,o,s){var l;return(l=t.factor)!=null&&l.active?(i.openBlock(),i.createElementBlock("div",Ra,[i.createElementVNode("div",{class:"legend-bars flex-center",style:i.normalizeStyle([{position:"absolute"},{right:o.right+"px",bottom:t.bottom}])},Ba,4)])):i.createCommentVNode("",!0)}const Aa=C(Va,[["render",$a],["__scopeId","data-v-389ea886"]]),Dr="",Ma={name:"IdmArctic",props:{factor:{type:Object},viewport:{type:Object},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{program:void 0,context:void 0,texture:void 0,rampColor:void 0,aPositionBuffer:void 0,webgl:new J,etime:void 0,right:10}},watch:{"factor.version":{handler(){var a;(a=this.factor)!=null&&a.active?this.handleRender():this.handleClear()},deep:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{handleRender(){if(!this.viewport)setTimeout(()=>{this.handleRender()},500);else if(this.factor){const a=new Date().valueOf();let e=0,t=0;this.handleDraw(),t=new Date().valueOf()-(a+e),console.log("[water-temp] add elapsed: ",t,", total: ",e+=t)}},handleClear(){this.context=void 0,this.etime=void 0,this.viewport.toggle(!1)},handleSetup(){if(!this.context){this.context=this.viewport.rampColorCanvas.getContext("webgl");const a=[[0,"rgba(76, 165, 228, 0)"],[50/255,"rgba(76, 165, 228, 0)"],[51/255,"rgb(76, 165, 228)"],[102/255,"rgb(129, 204, 197)"],[153/255,"rgb(150, 209, 216)"],[204/255,"rgb(180, 209, 216)"],[1,"rgb(180, 209, 216)"]];this.rampColor=this.webgl.setup(this.context,a);const{program:e,aPositionBuffer:t}=this.webgl.bind(this.context,I.vertexSchema,I.fragmentSchema);this.program=e,this.aPositionBuffer=t}},async handleDraw(){if(this.handleSetup(),this.etime!==this.factor.etime){this.etime=this.factor.etime;const a=await this.webgl.loadImg(this.factor.raw);this.texture=this.webgl.createTexture(this.context,this.context.NEAREST,this.context.LINEAR,this.context.CLAMP_TO_EDGE,a)}this.webgl.draw(this.viewport,this.context,this.program,this.texture,this.rampColor.texture,this.aPositionBuffer),this.viewport.toggle(!0)}}},fe=a=>(i.pushScopeId("data-v-db805141"),a=a(),i.popScopeId(),a),Wa={key:0},Oa=[fe(()=>i.createElementVNode("span",null,"m",-1)),fe(()=>i.createElementVNode("span",null,"0",-1)),fe(()=>i.createElementVNode("span",null,"0.5",-1)),fe(()=>i.createElementVNode("span",null,"1",-1)),fe(()=>i.createElementVNode("span",null,"1.5",-1)),fe(()=>i.createElementVNode("span",null,"2",-1))];function ja(a,e,t,r,o,s){var l;return(l=t.factor)!=null&&l.active?(i.openBlock(),i.createElementBlock("div",Wa,[i.createElementVNode("div",{class:"legend-bars flex-center",style:i.normalizeStyle([{position:"absolute"},{right:o.right+"px",bottom:t.bottom}])},Oa,4)])):i.createCommentVNode("",!0)}const Fa=C(Ma,[["render",ja],["__scopeId","data-v-db805141"]]),Wr="",Ha={name:"IdmPoint",emits:["point","more"],props:{map:{type:Object},show:{type:Boolean},meteo:{type:Object}},data(){return{showMeteo:!1,meteoMarker:void 0,helper:z.CompanyHelper}},watch:{show:{handler(){this.handleBind()},immediate:!0},map:{handler(){this.map&&this.show&&this.handleBind()}},meteo:{handler(){this.meteo?(this.showMeteo=!0,this.handleRender()):this.showMeteo=!1}}},computed:{computeTime(){return function(a){return a?`${A(a).utc().format("MMM-DD,HHmm[Z]")}`:"-"}},computeLat(){return function(a,e=4){return E.LngLatHelper.lat2pretty(a,e).pretty}},computeLng(){return function(a,e=4){return E.LngLatHelper.lng2pretty(a,e).pretty}},roundPrecision(){return function(a,e=4){return isNaN(a)?"-":E.LngLatHelper.roundPrecision(a,e)}}},methods:{handleBind(){var a,e;this.show?(a=this.map)==null||a.on("click",this.handleClick):((e=this.map)==null||e.off("click",this.handleClick),this.showMeteo=!1)},handleClick(a){a.originalEvent.stopPropagation();const e=a.originalEvent.target.className;e.indexOf("close")>-1?this.showMeteo=!1:e==="more"?this.$emit("more",this.meteo):this.$emit("point",a.lngLat)},handleRender(){var a;if(this.meteo){const e=document.getElementById("point-meteo");this.meteoMarker?(a=this.meteoMarker)==null||a.setLngLat([this.meteo.lng,this.meteo.lat]):this.meteoMarker=new Z.Marker(e).setLngLat([this.meteo.lng,this.meteo.lat]).addTo(this.map)}}}},O=a=>(i.pushScopeId("data-v-ef7fa87d"),a=a(),i.popScopeId(),a),Ua={id:"point-meteo",class:"point-meteo"},Za={class:"meteo-box"},Ga={class:"header-box"},Ja={class:"main"},Xa={class:"sub"},qa={class:"main-box"},Ya={class:"flex-space"},Qa=O(()=>i.createElementVNode("label",null,"Wind",-1)),Ka={class:"flex-space"},ei=O(()=>i.createElementVNode("label",null,"Wind.Wave",-1)),ti={class:"flex-space"},ai=O(()=>i.createElementVNode("label",null,"Swell",-1)),ii={class:"flex-space"},oi=O(()=>i.createElementVNode("label",null,"Sig.Wave",-1)),ri={class:"flex-space"},si=O(()=>i.createElementVNode("label",null,"Current",-1)),ni={class:"flex-space"},li=O(()=>i.createElementVNode("label",null,"Precip",-1)),ci={class:"flex-space"},hi=O(()=>i.createElementVNode("label",null,"Visibility",-1)),di={class:"flex-space"},pi=O(()=>i.createElementVNode("label",null,"Temp",-1)),mi={class:"flex-space"},yi=O(()=>i.createElementVNode("label",null,"Water Temp",-1)),fi={key:0,class:"flex-space",style:{"justify-content":"flex-end"}},ui=[O(()=>i.createElementVNode("span",{class:"more"},"More >>",-1))];function gi(a,e,t,r,o,s){var l,n,c,h,d,p,u,m,b,f,y,_,g,w,v,L,N,T,D,R,B,M,ie,oe,re,se,ne,le,ce,Q,W,j,he,F,S,$,de,H,pe,K,ee,te,ue,ge,be,_e,Le;return i.withDirectives((i.openBlock(),i.createElementBlock("div",Ua,[i.createElementVNode("div",Za,[i.createElementVNode("div",Ga,[i.createElementVNode("div",{class:"iconfont close",onClick:e[0]||(e[0]=ke=>o.showMeteo=!1)},""),i.createElementVNode("div",Ja,i.toDisplayString(s.computeLat((l=t.meteo)==null?void 0:l.lat))+","+i.toDisplayString(s.computeLng((n=t.meteo)==null?void 0:n.lng)),1),i.createElementVNode("div",Xa,i.toDisplayString(s.computeTime((c=t.meteo)==null?void 0:c.utc)),1)]),i.createElementVNode("div",qa,[i.createElementVNode("div",Ya,[Qa,i.createElementVNode("span",null,i.toDisplayString(((d=(h=t.meteo)==null?void 0:h.wind)==null?void 0:d.direction)||"-")+"/"+i.toDisplayString(s.roundPrecision((u=(p=t.meteo)==null?void 0:p.wind)==null?void 0:u.kts,1))+"[kts]/"+i.toDisplayString((b=(m=t.meteo)==null?void 0:m.wind)==null?void 0:b.scale)+"[BF]/"+i.toDisplayString(s.roundPrecision((y=(f=t.meteo)==null?void 0:f.gusts)==null?void 0:y.kts,1))+"[kts]",1)]),i.createElementVNode("div",Ka,[ei,i.createElementVNode("span",null,i.toDisplayString(((w=(g=(_=t.meteo)==null?void 0:_.wave)==null?void 0:g.wd)==null?void 0:w.direction)||"-")+"/"+i.toDisplayString(s.roundPrecision((N=(L=(v=t.meteo)==null?void 0:v.wave)==null?void 0:L.wd)==null?void 0:N.height,1))+"[m]/"+i.toDisplayString(s.roundPrecision((R=(D=(T=t.meteo)==null?void 0:T.wave)==null?void 0:D.wd)==null?void 0:R.period,1))+"[s]",1)]),i.createElementVNode("div",ti,[ai,i.createElementVNode("span",null,i.toDisplayString(((ie=(M=(B=t.meteo)==null?void 0:B.wave)==null?void 0:M.swell)==null?void 0:ie.direction)||"-")+"/"+i.toDisplayString(s.roundPrecision((se=(re=(oe=t.meteo)==null?void 0:oe.wave)==null?void 0:re.swell)==null?void 0:se.height,1))+"[m]/"+i.toDisplayString(s.roundPrecision((ce=(le=(ne=t.meteo)==null?void 0:ne.wave)==null?void 0:le.swell)==null?void 0:ce.period,1))+"[s]",1)]),i.createElementVNode("div",ii,[oi,i.createElementVNode("span",null,i.toDisplayString(((j=(W=(Q=t.meteo)==null?void 0:Q.wave)==null?void 0:W.sig)==null?void 0:j.direction)||"-")+"/"+i.toDisplayString(s.roundPrecision((S=(F=(he=t.meteo)==null?void 0:he.wave)==null?void 0:F.sig)==null?void 0:S.height,1))+"[m]/"+i.toDisplayString(s.roundPrecision((H=(de=($=t.meteo)==null?void 0:$.wave)==null?void 0:de.sig)==null?void 0:H.period,1))+"[s]",1)]),i.createElementVNode("div",ri,[si,i.createElementVNode("span",null,i.toDisplayString(((K=(pe=t.meteo)==null?void 0:pe.current)==null?void 0:K.direction)||"-")+"/"+i.toDisplayString(s.roundPrecision((te=(ee=t.meteo)==null?void 0:ee.current)==null?void 0:te.kts,2))+"[kts]",1)]),i.createElementVNode("div",ni,[li,i.createElementVNode("span",null,i.toDisplayString(s.roundPrecision((ge=(ue=t.meteo)==null?void 0:ue.precip)==null?void 0:ge.inter6h,2))+"[mm]",1)]),i.createElementVNode("div",ci,[hi,i.createElementVNode("span",null,i.toDisplayString(s.roundPrecision(((be=t.meteo)==null?void 0:be.visibility)/1852,0))+"[nm]",1)]),i.createElementVNode("div",di,[pi,i.createElementVNode("span",null,i.toDisplayString(s.roundPrecision((_e=t.meteo)==null?void 0:_e.temp,0))+"[°C]",1)]),i.createElementVNode("div",mi,[yi,i.createElementVNode("span",null,i.toDisplayString(s.roundPrecision((Le=t.meteo)==null?void 0:Le.waterTemp,2))+"[°C]",1)])]),a.$attrs.permission&o.helper.LEVEL.Prime?(i.openBlock(),i.createElementBlock("div",fi,ui)):i.createCommentVNode("",!0)])],512)),[[i.vShow,o.showMeteo]])}const bi=C(Ha,[["render",gi],["__scopeId","data-v-ef7fa87d"]]),_i={name:"IdmWarZone",props:{map:{type:Object},zone:{type:Object},beforeLayer:{type:String}},data(){return{source:"war-zone-source",zoneLayer:"war-zone-layer",zoneLabelLayer:"war-zone-label-layer"}},watch:{zone:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.zone&&(this.map.addSource(this.source,{type:"geojson",data:this.zone}),this.map.addLayer({id:this.zoneLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-color":"#f44336","fill-opacity":.4}},this.beforeLayer),this.map.addLayer({id:this.zoneLayer+"-border",type:"line",source:this.source,filter:["==","$type","Polygon"],paint:{"line-width":1,"line-opacity":1,"line-color":"#f44336"}},this.beforeLayer),this.map.addLayer({id:this.zoneLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"identify","text-anchor":"top","text-field":"{lbl}","text-rotation-alignment":"viewport","text-size":10,"text-offset":[0,-1]},paint:{"icon-opacity":.8,"text-color":"#000","text-halo-color":"#fff","text-halo-width":1}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.zoneLayer)&&this.map.removeLayer(this.zoneLayer),this.map.getLayer(this.zoneLayer+"-border")&&this.map.removeLayer(this.zoneLayer+"-border"),this.map.getLayer(this.zoneLabelLayer)&&this.map.removeLayer(this.zoneLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function Li(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const wi=C(_i,[["render",Li]]),xi={name:"IdmGmdssArea",props:{map:{type:Object},area:{type:Object},beforeLayer:{type:String}},data(){return{source:"gmdss-area-source",areaLayer:"gmdss-area-layer",areaLabelLayer:"gmdss-area-label-layer"}},watch:{area:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.area&&(this.map.addSource(this.source,{type:"geojson",data:this.area}),this.map.addLayer({id:this.areaLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.5,"fill-color":["match",["get","val"],"AreaI","#EB8996","AreaII","#6F448B","AreaIII","#3E8BD3","AreaIV","#5EBCC4","AreaV","#00AAE7","AreaVI","#9CCE6D","AreaVII","#F4AE00","AreaVIII","#EF9A85","AreaIX","#00AAA7","AreaX","#7AC49F","AreaXI","#DFDFDF","AreaXII","#FFF974","AreaXIII","#EF9A85","AreaXIV","#86A2D1","AreaXV","#EC8972","AreaXVI","#EAC2DA","AreaXVII","#B9C8E7","AreaXVIII","#BBA1C8","AreaXIX","#FAE0BD","AreaXX","#DBECC8","AreaXXI","#D496AF","#ffffff"]}},this.beforeLayer),this.map.addLayer({id:this.areaLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"identify","text-anchor":"top","text-field":"{lbl}","text-rotation-alignment":"viewport","text-size":12,"text-offset":[0,-3.5]},paint:{"icon-opacity":.8,"text-opacity":.8,"text-color":"#000"}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.areaLayer)&&this.map.removeLayer(this.areaLayer),this.map.getLayer(this.areaLabelLayer)&&this.map.removeLayer(this.areaLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function vi(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const Ci=C(xi,[["render",vi]]),Si={name:"IdmEcaZone",props:{map:{type:Object},zone:{type:Object},beforeLayer:{type:String}},data(){return{source:"eca-zone-source",zoneLayer:"eca-zone-layer",zoneLabelLayer:"eca-zone-label-layer"}},watch:{zone:{handler(){this.zone?this.handleRender():this.handleClear()}}},methods:{handleRender(){var a;this.map?(this.handleClear(),this.zone&&(this.map.getSource(this.source)?(a=this.map)==null||a.getSource(this.source).setData(this.zone):(this.map.addSource(this.source,{type:"geojson",data:this.zone}),this.map.addLayer({id:this.zoneLayer,type:"fill",source:this.source,filter:["all",["==","$type","Polygon"],["!=","disabled",!0]],paint:{"fill-outline-color":"silver","fill-opacity":.4,"fill-color":"#05f324"}}),this.map.addLayer({id:this.zoneLayer+"-border",type:"line",source:this.source,filter:["all",["==","$type","Polygon"],["!=","disabled",!0]],paint:{"line-color":"#04c021","line-width":1,"line-opacity":1}},this.beforeLayer),this.map.addLayer({id:this.zoneLabelLayer,type:"symbol",source:this.source,filter:["all",["==","$type","Point"],["!=","disabled",!0]],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"identify","text-max-width":16,"text-justify":"left","text-anchor":"top","text-field":"{lbl}","text-rotation-alignment":"viewport","text-size":10,"text-offset":[0,-3.5]},paint:{"icon-opacity":.8,"text-color":"#000","text-halo-color":"#fff","text-halo-width":1}})))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.zoneLayer)&&this.map.removeLayer(this.zoneLayer),this.map.getLayer(this.zoneLayer+"-border")&&this.map.removeLayer(this.zoneLayer+"-border"),this.map.getLayer(this.zoneLabelLayer)&&this.map.removeLayer(this.zoneLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function ki(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const Ei=C(Si,[["render",ki]]),jr="",zi={name:"IdmAlertZone",props:{map:{type:Object},zone:{type:Object},beforeLayer:{type:String}},data(){return{source:"alert-zone-source",polygonLayer:"alert-zone-polygon-layer",polygonLabelLayer:"alert-zone-polygon-label-layer",lineLayer:"alert-zone-line-layer",lineLabelLayer:"alert-zone-line-label-layer",pointLayer:"alert-zone-point-layer",showZone:!1,form:{}}},watch:{zone:{handler(){var a,e;this.zone?(this.handleRender(),(a=this.map)==null||a.on("click",[this.polygonLabelLayer,this.lineLabelLayer,this.pointLayer],this.handleClick)):(this.handleClear(),(e=this.map)==null||e.off("click",[this.polygonLabelLayer,this.lineLabelLayer,this.pointLayer],this.handleClick))}}},methods:{handleClick(a){var r;const e=a.features[0],t=(r=this.zone)==null?void 0:r.features.filter(o=>{var s;return o.properties.id===((s=e==null?void 0:e.properties)==null?void 0:s.id)})[0];t&&(this.showZone=!0,this.form={...t.properties})},handleRender(){var a;this.map?(this.handleClear(),this.zone&&(this.map.getSource(this.source)?(a=this.map)==null||a.getSource(this.source).setData(this.zone):(this.map.addSource(this.source,{type:"geojson",data:this.zone}),this.map.addLayer({id:this.polygonLayer,type:"fill",source:this.source,filter:["all",["==","$type","Polygon"],["!=","disabled",!0]],paint:{"fill-outline-color":"#d57d02","fill-opacity":.4,"fill-color":"#d57d02"}}),this.map.addLayer({id:this.polygonLayer+"-border",type:"line",source:this.source,filter:["all",["==","$type","Polygon"],["!=","disabled",!0]],paint:{"line-width":1,"line-color":"#d57d02"}}),this.map.addLayer({id:this.lineLayer,type:"line",source:this.source,filter:["all",["==","$type","LineString"],["!=","disabled",!0]],paint:{"line-color":"#d57d02","line-width":2}}),this.map.addLayer({id:this.polygonLabelLayer,type:"symbol",source:this.source,filter:["all",["==","$type","Polygon"],["!=","disabled",!0]],layout:{"symbol-placement":"point","icon-image":"alert","icon-size":.1,"icon-allow-overlap":!0,"icon-rotation-alignment":"viewport"},paint:{"icon-opacity":.8}}),this.map.addLayer({id:this.lineLabelLayer,type:"symbol",source:this.source,filter:["all",["==","$type","LineString"],["!=","disabled",!0]],layout:{"symbol-placement":"line-center","icon-image":"alert","icon-size":.1,"icon-allow-overlap":!0,"icon-rotation-alignment":"viewport"},paint:{"icon-opacity":.8}}),this.map.addLayer({id:this.pointLayer,type:"symbol",source:this.source,filter:["all",["==","$type","Point"],["!=","disabled",!0]],layout:{"symbol-placement":"point","icon-image":"alert","icon-size":.1},paint:{"icon-opacity":.8}})))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.polygonLayer)&&this.map.removeLayer(this.polygonLayer),this.map.getLayer(this.polygonLayer+"-border")&&this.map.removeLayer(this.polygonLayer+"-border"),this.map.getLayer(this.polygonLabelLayer)&&this.map.removeLayer(this.polygonLabelLayer),this.map.getLayer(this.lineLayer)&&this.map.removeLayer(this.lineLayer),this.map.getLayer(this.lineLabelLayer)&&this.map.removeLayer(this.lineLabelLayer),this.map.getLayer(this.pointLayer)&&this.map.removeLayer(this.pointLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}},Pi={id:"zone-info"},Ni=["innerHTML"];function Ti(a,e,t,r,o,s){var l;return i.withDirectives((i.openBlock(),i.createElementBlock("div",Pi,[i.createElementVNode("div",{class:"iconfont close",onClick:e[0]||(e[0]=n=>o.showZone=!1)},""),i.createElementVNode("div",{class:"rich-context",innerHTML:(l=o.form)==null?void 0:l.name},null,8,Ni)],512)),[[i.vShow,o.showZone]])}const Ii=C(zi,[["render",Ti],["__scopeId","data-v-c0864afc"]]),Fr="",Di={name:"IdmPort",props:{map:{type:Object},port:{type:Object},beforeLayer:{type:String}},emits:["port"],data(){return{source:"port-source",layer:"port-layer",showPort:!1,form:{},marker:void 0}},computed:{computeLat(){return function(a){return E.LngLatHelper.lat2pretty(a,4).pretty}},computeLng(){return function(a){return E.LngLatHelper.lng2pretty(a,4).pretty}}},watch:{port:{handler(){var a,e;this.port?(this.handleRender(),(a=this.map)==null||a.on("click",[this.layer],this.handleClick)):(this.handleClear(),(e=this.map)==null||e.off("click",[this.layer],this.handleClick))}}},methods:{handleClick(a){var r;const e=a.features[0],t=(r=this.port)==null?void 0:r.features.filter(o=>{var s;return o.properties.id===((s=e==null?void 0:e.properties)==null?void 0:s.id)})[0];if(t){this.showPort=!0,this.form={...t.properties},this.form.lng=t.geometry.coordinates[0],this.form.lat=t.geometry.coordinates[1];const o=document.getElementById("port-info");this.marker?this.marker.setLngLat([a.lngLat.lng,a.lngLat.lat]):this.marker=new Z.Marker(o).setLngLat([a.lngLat.lng,a.lngLat.lat]).setOffset([0,-85]).addTo(this.map)}},handleEmit(){this.$emit("port",this.form)},handleRender(){var a;this.map?this.port&&(this.map.getSource(this.source)?(a=this.map)==null||a.getSource(this.source).setData(this.port):(this.map.addSource(this.source,{type:"geojson",data:this.port}),this.map.addLayer({id:this.layer,type:"symbol",source:this.source,filter:["all",["==","$type","Point"],["!=","disabled",!0]],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"port","text-anchor":"left","text-field":"{name}","text-rotation-alignment":"viewport","text-size":10,"text-offset":[1,0]},paint:{"text-color":"rgba(0, 0, 0, 0.8)","text-halo-color":"#fff","text-halo-width":1}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.showPort=!1,this.map.getLayer(this.layer)&&this.map.removeLayer(this.layer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}},xe=a=>(i.pushScopeId("data-v-4ab013cc"),a=a(),i.popScopeId(),a),Vi={id:"port-info"},Ri={class:"port-box"},Bi={class:"flex-start"},$i=xe(()=>i.createElementVNode("label",null,"Name : ",-1)),Ai={class:"flex-start"},Mi=xe(()=>i.createElementVNode("label",null,"Position : ",-1)),Wi={class:"flex-start"},Oi=xe(()=>i.createElementVNode("label",null,"LoCode : ",-1)),ji={class:"flex-start",style:{"align-items":"flex-start"}},Fi=xe(()=>i.createElementVNode("label",null,"Region : ",-1));function Hi(a,e,t,r,o,s){return i.withDirectives((i.openBlock(),i.createElementBlock("div",Vi,[i.createElementVNode("div",{class:"close iconfont",onClick:e[0]||(e[0]=l=>o.showPort=!1)},""),i.createElementVNode("div",Ri,[i.createElementVNode("div",Bi,[$i,i.createElementVNode("span",{onClick:e[1]||(e[1]=(...l)=>s.handleEmit&&s.handleEmit(...l))},i.toDisplayString(o.form.name),1)]),i.createElementVNode("div",Ai,[Mi,i.createElementVNode("span",null,i.toDisplayString(s.computeLat(o.form.lat))+", "+i.toDisplayString(s.computeLng(o.form.lng)),1)]),i.createElementVNode("div",Wi,[Oi,i.createElementVNode("span",null,i.toDisplayString(o.form.loCode||"-"),1)]),i.createElementVNode("div",ji,[Fi,i.createElementVNode("span",null,i.toDisplayString(o.form.city||"-")+", "+i.toDisplayString(o.form.country||"-"),1)])])],512)),[[i.vShow,o.showPort]])}const Ui=C(Di,[["render",Hi],["__scopeId","data-v-4ab013cc"]]),Zi={name:"IdmLoadLine",props:{map:{type:Object},line:{type:Object},beforeLayer:{type:String}},data(){return{source:"load-line-source",lineLayer:"load-line-layer",lineLabelLayer:"load-line-label-layer"}},watch:{line:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.line&&(this.map.addSource(this.source,{type:"geojson",data:this.line}),this.map.addLayer({id:this.lineLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.75,"fill-color":["match",["get","val"],"LLGreen","#A0C0C0","LLRed","#F5A39D","LLBlue","#6B94E4","#ffffff"]}},this.beforeLayer),this.map.addLayer({id:this.lineLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","text-field":"{lbl} (Length < {shipLength}, {start} - {end})","text-rotation-alignment":"viewport","text-offset":[0,1],"text-size":10,"text-allow-overlap":!0},paint:{"text-opacity":.8}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.lineLayer)&&this.map.removeLayer(this.lineLayer),this.map.getLayer(this.lineLabelLayer)&&this.map.removeLayer(this.lineLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function Gi(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const Ji=C(Zi,[["render",Gi]]),Xi={name:"IdmTimezone",props:{map:{type:Object},zone:{type:Object},beforeLayer:{type:String}},data(){return{source:"time-zone-source",zoneLayer:"time-zone-layer",zoneLabelLayer:"time-zone-label-layer"}},watch:{zone:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.zone&&(this.map.addSource(this.source,{type:"geojson",data:this.zone}),this.map.addLayer({id:this.zoneLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.5,"fill-color":["match",["get","offSet"],"-11.5","rgba(255,0,0,0.4)","-11","rgba(0,255,0,0.3)","-10.5","rgba(0,255,0,0.3)","-10","rgba(0,0,255,0.3)","-9.5","rgba(0,0,255,0.3)","-9","rgba(255,0,0,0.4)","-8.5","rgba(255,0,0,0.4)","-8","rgba(0,255,0,0.3)","-7.5","rgba(0,255,0,0.3)","-7","rgba(0,0,255,0.3)","-6.5","rgba(0,0,255,0.3)","-6","rgba(255,0,0,0.4)","-5.5","rgba(255,0,0,0.4)","-5","rgba(0,255,0,0.3)","-4.5","rgba(0,255,0,0.3)","-4","rgba(0,0,255,0.3)","-3.5","rgba(0,0,255,0.3)","-3","rgba(255,0,0,0.4)","-2.5","rgba(255,0,0,0.4)","-2","rgba(0,255,0,0.3)","-1.5","rgba(0,255,0,0.3)","-1","rgba(0,0,255,0.3)","-0.5","rgba(0,0,255,0.3)","+0","rgba(255,0,0,0.4)","+0.5","rgba(255,0,0,0.4)","+1","rgba(0,255,0,0.3)","+1.5","rgba(0,255,0,0.3)","+2","rgba(0,0,255,0.3)","+2.5","rgba(0,0,255,0.3)","+3","rgba(255,0,0,0.4)","+3.5","rgba(255,0,0,0.4)","+4","rgba(0,255,0,0.3)","+4.5","rgba(0,255,0,0.3)","+5","rgba(0,0,255,0.3)","+5.5","rgba(0,0,255,0.3)","+6","rgba(255,0,0,0.4)","+6.5","rgba(255,0,0,0.4)","+7","rgba(0,255,0,0.3)","+7.5","rgba(0,255,0,0.3)","+8","rgba(0,0,255,0.3)","+8.5","rgba(0,0,255,0.3)","+9","rgba(255,0,0,0.4)","+9.5","rgba(255,0,0,0.4)","+10","rgba(0,255,0,0.3)","+10.5","rgba(0,255,0,0.3)","+11","rgba(0,0,255,0.3)","+11.5","rgba(0,0,255,0.3)","rgba(255,0,0,0.4)"]}}),this.map.addLayer({id:this.zoneLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","text-field":"{offSet}","text-rotation-alignment":"viewport","text-size":12,"text-offset":[0,1]},paint:{"text-opacity":.8,"text-color":"#fff"}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.zoneLayer)&&this.map.removeLayer(this.zoneLayer),this.map.getLayer(this.zoneLabelLayer)&&this.map.removeLayer(this.zoneLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function qi(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const Yi=C(Xi,[["render",qi]]),Qi={name:"IdmVoluntaryReportingArea",props:{map:{type:Object},area:{type:Object},beforeLayer:{type:String}},data(){return{source:"vra-source",areaLayer:"vra-layer",areaLabelLayer:"vra-label-layer"}},watch:{area:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.area&&(this.map.addSource(this.source,{type:"geojson",data:this.area}),this.map.addLayer({id:this.areaLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.4,"fill-color":"#9f30f9"}},this.beforeLayer),this.map.addLayer({id:this.areaLayer+"-border",type:"line",source:this.source,filter:["==","$type","Polygon"],paint:{"line-width":1,"line-opacity":1,"line-color":"#9f30f9"}},this.beforeLayer),this.map.addLayer({id:this.areaLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"identify","text-anchor":"top","text-field":"{lbl}","text-rotation-alignment":"viewport","text-size":10,"text-offset":[0,-3.5]},paint:{"icon-opacity":.8,"text-color":"#000","text-halo-color":"#fff","text-halo-width":1}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.areaLayer)&&this.map.removeLayer(this.areaLayer),this.map.getLayer(this.areaLayer+"-border")&&this.map.removeLayer(this.areaLayer+"-border"),this.map.getLayer(this.areaLabelLayer)&&this.map.removeLayer(this.areaLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function Ki(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const eo=C(Qi,[["render",Ki]]),to={name:"IdmSpecialArea",props:{map:{type:Object},area:{type:Object},beforeLayer:{type:String}},data(){return{source:"special-area-source",areaLayer:"special-area-layer",areaLabelLayer:"special-area-label-layer"}},watch:{area:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.area&&(this.area.features.forEach(a=>{a.geometry.type==="Polygon"&&a.geometry.coordinates.forEach(e=>E.LngLatHelper.convertToMonotonicLng2(e))}),this.map.addSource(this.source,{type:"geojson",data:this.area}),this.map.addLayer({id:this.areaLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.4,"fill-color":["match",["get","val"],"DefaultStyle","rgb(0,0,0)","JWCriskArea","rgb(0,0,0)","rgb(0,0,0)"]}},this.beforeLayer),this.map.addLayer({id:this.areaLayer+"-border",type:"line",source:this.source,filter:["==","$type","Polygon"],paint:{"line-width":1,"line-opacity":.4,"line-color":"rgb(0,0,0)"}},this.beforeLayer),this.map.addLayer({id:this.areaLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"identify","text-anchor":"top","text-field":"{lbl}","text-rotation-alignment":"viewport","text-size":10,"text-offset":[0,-3.5]},paint:{"icon-opacity":.8,"text-color":"#000","text-halo-color":"#fff","text-halo-width":1}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.areaLayer)&&this.map.removeLayer(this.areaLayer),this.map.getLayer(this.areaLayer+"-border")&&this.map.removeLayer(this.areaLayer+"-border"),this.map.getLayer(this.areaLabelLayer)&&this.map.removeLayer(this.areaLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function ao(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const io=C(to,[["render",ao]]),oo={name:"IdmTerminator",props:{map:{type:Object},area:{type:Object}},data(){return{source:"terminator-source",layer:"terminator-layer"}},watch:{area:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.area&&(this.map.addSource(this.source,{type:"geojson",data:this.area}),this.map.addLayer({id:this.layer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.5,"fill-color":"rgba(0, 0, 0, 0.4)"}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.layer)&&this.map.removeLayer(this.layer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function ro(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const so=C(oo,[["render",ro]]),Hr="",no={name:"IdmLatLng",props:{map:{type:Object},show:{type:Boolean},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{lngLat:void 0,source:"idm-lat-lng-source",layer:"idm-lat-lng-layer",labelLayer:"idm-lat-lng-label-layer",right:10}},watch:{show:{handler(){this.handleBind()},immediate:!0},map:{handler(){var a;this.map&&((a=this.map)==null||a.on("mousemove",this.handleMouseMove))},immediate:!0},toggleVersion:{handler(){var a,e,t;this.right=(((a=document.getElementsByClassName("legend-bars")[0])==null?void 0:a.clientWidth)||-10)+(((e=document.getElementsByClassName("available-layers-show")[0])==null?void 0:e.clientWidth)||0)+(((t=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:t.clientWidth)||0)+20},immediate:!0}},methods:{handleBind(){var a,e;this.show?((a=this.map)==null||a.on("zoomend",this.handleZoomEnd),this.handleRender()):(this.handleClear(),(e=this.map)==null||e.off("zoomend",this.handleZoomEnd))},handleMouseMove(a){const e=a.lngLat,t=E.LngLatHelper.lng2pretty(e.lng,2),r=E.LngLatHelper.lat2pretty(e.lat,2);this.lngLat={lng:t,lat:r}},handleComputeLatLngs(){var r;const a=(r=this.map)==null?void 0:r.getZoom();console.log(a);let e=30;a>4?e=10:a>3&&(e=15);const t=[];for(let o=-60;o<90;o+=e)t.push({type:"Feature",geometry:{type:"LineString",coordinates:[[-180,o],[180,o]]}});for(let o=-180;o<180;o+=e)t.push({type:"Feature",geometry:{type:"LineString",coordinates:[[o,-90],[o,90]]}});for(let o=180;o>-180;o-=e)for(let s=-60;s<90;s+=e)t.push({type:"Feature",geometry:{type:"Point",coordinates:[o,s]},properties:{val:`${s>0?s+" N":s===0?s:s*-1+" S"}, ${o>0?o+" E":o*-1+" W"}`}});return t},handleZoomEnd(){var e;const a=this.handleComputeLatLngs();(e=this.map)==null||e.getSource(this.source).setData(x.featureCollection(a))},handleRender(){if(this.map){const a=this.handleComputeLatLngs();this.map.addSource(this.source,{type:"geojson",data:{type:"FeatureCollection",features:a}}),this.map.addLayer({id:this.layer,type:"line",source:this.source,filter:["==","$type","LineString"],layout:{"line-join":"round","line-cap":"round"},paint:{"line-color":"rgba(0, 0, 0, 0.3)","line-width":1}}),this.map.addLayer({id:this.labelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","text-field":"{val}","text-rotation-alignment":"viewport","text-offset":[0,1],"text-size":10,"text-allow-overlap":!0},paint:{"text-opacity":.8}})}},handleClear(){var a,e,t,r,o,s;(a=this.map)!=null&&a.getLayer(this.layer)&&((e=this.map)==null||e.removeLayer(this.layer)),(t=this.map)!=null&&t.getLayer(this.labelLayer)&&((r=this.map)==null||r.removeLayer(this.labelLayer)),(o=this.map)!=null&&o.getSource(this.source)&&((s=this.map)==null||s.removeSource(this.source))}}},lo=(a=>(i.pushScopeId("data-v-7367f59b"),a=a(),i.popScopeId(),a))(()=>i.createElementVNode("span",null,", ",-1));function co(a,e,t,r,o,s){return o.lngLat?(i.openBlock(),i.createElementBlock("div",{key:0,class:"lat-lng-tip",style:i.normalizeStyle({right:o.right+"px",bottom:t.bottom})},[i.createElementVNode("span",null,i.toDisplayString(o.lngLat.lat.pretty),1),lo,i.createElementVNode("span",null,i.toDisplayString(o.lngLat.lng.pretty),1)],4)):i.createCommentVNode("",!0)}const Se=C(no,[["render",co],["__scopeId","data-v-7367f59b"]]),ho={name:"IdmMeasure",props:{map:{type:Object},show:{type:Boolean}},data(){return{geojson:[],source:"measure-source",layer:"measure-layer",labelLayer:"measure-label-layer",tmpSource:"measure-tmp-source",tmpLayer:"measure-tmp-layer",tmpLabelLayer:"measure-tmp-label-layer",closeMarkers:{},pointMarkers:{},tipMarker:void 0,contextmenu:void 0,navigation:"RL"}},watch:{show:{handler(){this.handleBind()},immediate:!0},map:{handler(){this.map&&this.handleBind()}}},methods:{handleBind(){var a,e,t,r,o,s,l,n,c,h;if(this.show)(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),(o=this.map)==null||o.on("contextmenu",this.handleContextmenu),this.map&&(this.map.getCanvas().style.cursor="crosshair");else{(s=this.map)==null||s.getCanvas().removeEventListener("keydown",this.handleKeydown),(l=this.map)==null||l.off("mousemove",this.handleMove),(n=this.map)==null||n.off("dblclick",this.handleDblClick),(c=this.map)==null||c.off("click",this.handleClick),(h=this.map)==null||h.off("contextmenu",this.handleContextmenu);for(const d of this.geojson)this.handleClear(d,!0);this.geojson=[],this.map&&(this.map.getCanvas().style.cursor="grab")}},handleKeydown(a){if(a.key==="Shift"){this.navigation=this.navigation==="RL"?"GC":"RL";const t=this.geojson.at(-1).features.filter(r=>r.geometry.type==="Point");t.length&&(t.at(-1).properties.mode=this.navigation)}},handleDrag(a){var t,r,o,s,l,n,c,h,d,p;const e=(r=(t=a.target)==null?void 0:t._element)==null?void 0:r.id;if((e==null?void 0:e.split("-").length)===2){const u=this.geojson.filter(y=>y.id===e.split("-")[0])[0];this.pointMarkers[u.id].filter(y=>{var _;return((_=y._element)==null?void 0:_.id)===e})[0].setLngLat([(s=(o=a.target)==null?void 0:o._lngLat)==null?void 0:s.lng,(n=(l=a.target)==null?void 0:l._lngLat)==null?void 0:n.lat]);let b;u.features.forEach((y,_)=>{if(y.geometry.type==="Point"&&y.properties.id==e.split("-")[1]){b=_;return}});const f=u.features.filter(y=>y.geometry.type==="Point");this.handleTmpPointUpdate(u,f[b-1],{lng:(h=(c=a.target)==null?void 0:c._lngLat)==null?void 0:h.lng,lat:(p=(d=a.target)==null?void 0:d._lngLat)==null?void 0:p.lat,properties:f[b].properties},b===f.length-1?void 0:f[b+1])}},handleDragEnd(a){var t,r,o,s,l,n,c,h,d,p;const e=(r=(t=a.target)==null?void 0:t._element)==null?void 0:r.id;if((e==null?void 0:e.split("-").length)===2){const u=this.geojson.filter(f=>f.id===e.split("-")[0])[0];this.pointMarkers[u.id].filter(f=>{var y;return((y=f._element)==null?void 0:y.id)===e})[0].setLngLat([(s=(o=a.target)==null?void 0:o._lngLat)==null?void 0:s.lng,(n=(l=a.target)==null?void 0:l._lngLat)==null?void 0:n.lat]);const b=u.features.filter(f=>f.geometry.type==="Point"&&f.properties.id==e.split("-")[1])[0];b.geometry.coordinates=[(h=(c=a.target)==null?void 0:c._lngLat)==null?void 0:h.lng,(p=(d=a.target)==null?void 0:d._lngLat)==null?void 0:p.lat],u.features=u.features.filter(f=>f.geometry.type==="Point"),this.handlePointUpdate(u)}},handleContextmenu(a){var t,r,o,s;a.preventDefault(),(t=this.contextmenu)==null||t.remove();const e=(s=(o=(r=a.originalEvent)==null?void 0:r.target)==null?void 0:o.parentElement)==null?void 0:s.id;if((e==null?void 0:e.split("-").length)===2){const n=this.geojson.filter(c=>c.id===e.split("-")[0])[0].features.filter(c=>c.geometry.type==="Point");if(n.length>2&&n.filter(h=>h.properties.id===(e==null?void 0:e.split("-")[1]))[0]){const h=document.createElement("div");h.className="point-contextmenu-marker",h.innerHTML=`<span id="del-${e}" class="del-point">Del</span>`,this.contextmenu=new Z.Marker(h).setOffset([24,0]).setLngLat([a.lngLat.lng,a.lngLat.lat]).addTo(this.map)}}},handleClick(a){var t,r,o,s,l;(t=this.contextmenu)==null||t.remove();const e=a.originalEvent.target.className;if(e==="marker-close"){const n=(o=(r=a.originalEvent)==null?void 0:r.srcElement)==null?void 0:o.id,c=this.geojson.filter(h=>h.id===n)[0];c&&this.handleClear(c,!0),this.geojson=this.geojson.filter(h=>h.id!==n)}else if(e==="del-point"){const n=(l=(s=a.originalEvent.target.id)==null?void 0:s.replace("del-",""))==null?void 0:l.split("-"),c=this.geojson.filter(h=>h.id===n[0])[0];c.features=c.features.filter(h=>h.geometry.type==="Point"&&h.properties.id!==n[1]),this.handlePointUpdate(c)}else if(e!=="marker-label"){let n=this.geojson.at(-1);n||(n=x.featureCollection([],{id:new Date().getTime().toString()}),this.geojson.push(n)),n.features=n.features.filter(h=>h.geometry.type==="Point");const c=x.feature({type:"Point",coordinates:[a.lngLat.lng,a.lngLat.lat]},{id:new Date().getTime().toString(),mode:this.navigation});n.features.push(c),this.handlePointUpdate(n)}},handlePointUpdate(a){const e=a.features;if(e.length>1){let t=0;const r=[];for(let o=1;o<e.length;o++){const s=e[o-1],l=e[o],n=s.properties,c={lng:s.geometry.coordinates[0],lat:s.geometry.coordinates[1]},h={lng:l.geometry.coordinates[0],lat:l.geometry.coordinates[1]},d=E.LaneHelper.calculateDistance(c,h,n.mode==="RL",2),p=E.LaneHelper.calculateBearing(c,h,n.mode==="RL",2);t=E.LngLatHelper.roundPrecision(t+d,2);let u;n.mode==="RL"?u=E.LngLatHelper.convertToMonotonicLng([c,h]):u=E.LngLatHelper.convertToMonotonicLng(E.LaneHelper.interpolateCoordinates(c,h,200));const m=x.lineString(u.map(b=>[b.lng,b.lat]));m.properties.dist=d,m.properties.bearing=p,m.properties.total=t,r.push(m)}e.push(...r),a.total=t}return this.handleRender(a),a},handleTmpPointUpdate(a,e,t,r){const o=x.featureCollection([]);let s,l;if(e){const c=e.properties,h={lng:e.geometry.coordinates[0],lat:e.geometry.coordinates[1]},d={lng:t.lng,lat:t.lat};s=E.LaneHelper.calculateDistance(h,d,c.mode==="RL",2),l=E.LaneHelper.calculateBearing(h,d,c.mode==="RL",2);let p;c.mode==="RL"?p=E.LngLatHelper.convertToMonotonicLng([h,d]):p=E.LngLatHelper.convertToMonotonicLng(E.LaneHelper.interpolateCoordinates(h,d,200));const u=x.lineString(p.map(m=>[m.lng,m.lat]));u.properties.dist=s,u.properties.bearing=l,o.features.push(u)}if(r){const c=t.properties,h=t,d={lng:r.geometry.coordinates[0],lat:r.geometry.coordinates[1]};s=E.LaneHelper.calculateDistance(h,d,c.mode==="RL",2),l=E.LaneHelper.calculateBearing(h,d,c.mode==="RL",2);let p;c.mode==="RL"?p=E.LngLatHelper.convertToMonotonicLng([h,d]):p=E.LngLatHelper.convertToMonotonicLng(E.LaneHelper.interpolateCoordinates(h,d,200));const u=x.lineString(p.map(m=>[m.lng,m.lat]));u.properties.dist=s,u.properties.bearing=l,o.features.push(u)}this.map.getSource(this.tmpSource)?this.map.getSource(this.tmpSource).setData(o):this.map.addSource(this.tmpSource,{type:"geojson",data:o}),this.map.getLayer(this.tmpLayer)||this.map.addLayer({id:this.tmpLayer,type:"line",source:this.tmpSource,filter:["==","$type","LineString"],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#F44336","line-width":2,"line-opacity":1,"line-dasharray":[3,2]}}),this.map.getLayer(this.tmpLabelLayer)||this.map.addLayer({id:this.tmpLabelLayer,type:"symbol",source:this.tmpSource,filter:["==","$type","LineString"],layout:{"symbol-placement":"line-center","text-field":"{dist} nm","text-rotation-alignment":"map","text-size":12},paint:{"text-opacity":1,"text-color":"#fff","text-halo-color":"#F44336","text-halo-width":4,"text-halo-blur":0}});let n;if(r?n='<div class="marker-label">Drag and drop</div>':n=`<div class="marker-label">Tol distance: <b>${E.LngLatHelper.roundPrecision((a.total??0)+s,2)}</b>nm, bearing: <b>${l}</b>°</div><div class="marker-label">${this.navigation==="RL"?"RL":"GC"} mode, using 'Shift' to switch</div><div class="marker-label">Double click to end</div>`,this.tipMarker)this.tipMarker._element.innerHTML=n,this.tipMarker.setLngLat([t.lng,t.lat]);else{const c=document.createElement("div");c.className="tip-marker",c.innerHTML=n,this.tipMarker=new Z.Marker(c).setOffset([140,0]).setLngLat([t.lng,t.lat]).addTo(this.map)}},handleMove(a){this.map.getCanvas().style.cursor="crosshair";let e=this.geojson.at(-1);e||(e=x.featureCollection([],{id:new Date().getTime().toString()}),this.geojson.push(e));const t=e.features.filter(r=>r.geometry.type==="Point");t!=null&&t.length&&this.handleTmpPointUpdate(e,t.at(-1),{lng:a.lngLat.lng,lat:a.lngLat.lat})},handleDblClick(a){a.preventDefault();let e=this.geojson.at(-1);e.closed=!0,this.handleRender(e),e=x.featureCollection([],{id:new Date().getTime().toString()}),this.geojson.push(e)},handleRender(a){var e;if((e=a==null?void 0:a.features)!=null&&e.length){const t=`${a.id}-${this.source}`,r=`${a.id}-${this.layer}`,o=`${a.id}-${this.labelLayer}`;this.map.getSource(t)?this.map.getSource(t).setData(a):this.map.addSource(t,{type:"geojson",data:a}),this.handleClear(a,!1),this.map.addLayer({id:r,type:"line",source:t,filter:["==","$type","LineString"],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#F44336","line-width":2}}),this.map.addLayer({id:o,type:"symbol",source:t,filter:["==","$type","LineString"],layout:{"symbol-placement":"line-center","text-field":"{dist}nm,{bearing}°","text-rotation-alignment":"map","text-size":12},paint:{"text-opacity":1,"text-color":"#fff","text-halo-color":"#F44336","text-halo-width":4,"text-halo-blur":0}});const s=a.features.filter(l=>l.geometry.type==="Point");for(const l of s){const n=document.createElement("div");n.id=`${a.id}-${l.properties.id}`,n.className=`${a.closed?"point-marker closed":"point-marker"}`,n.innerHTML='<div class="marker-circle"></div>';const c=new Z.Marker({element:n,draggable:!0,contextmenu:!0}).setLngLat(l.geometry.coordinates).addTo(this.map);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]}if(a.closed){const l=s.at(-1),c=a.features.filter(d=>d.geometry.type==="LineString").at(-1),h=document.createElement("div");h.className="point-summary-marker",h.innerHTML=`<div id="${a.id}" class="marker-close">×</div><div class="marker-label">Tol: ${c.properties.total}nm</div>`,this.closeMarkers[a.id]=new Z.Marker(h).setOffset([60,0]).setLngLat(l.geometry.coordinates).addTo(this.map)}}},handleClear(a,e=!0){var s,l,n,c,h,d,p,u,m;const t=`${a.id}-${this.source}`,r=`${a.id}-${this.layer}`,o=`${a.id}-${this.labelLayer}`;(s=this.map)!=null&&s.getLayer(r)&&this.map.removeLayer(r),(l=this.map)!=null&&l.getLayer(o)&&this.map.removeLayer(o),(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),(h=this.closeMarkers[a.id])==null||h.remove(),this.closeMarkers[a.id]=void 0,(d=this.pointMarkers[a.id])==null||d.forEach(b=>{b==null||b.remove()}),this.pointMarkers[a.id]=[],(p=this.tipMarker)==null||p.remove(),this.tipMarker=void 0,e&&((u=this.map)!=null&&u.getSource(t))&&this.map.removeSource(t),e&&((m=this.map)!=null&&m.getSource(this.tmpSource))&&this.map.removeSource(this.tmpSource)}}};function po(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const mo=C(ho,[["render",po]]),Zr="",yo={name:"IdmENC",props:{map:{type:Object},enabled:{type:Boolean},beforeLayer:{type:String,default:"grayland"},bottom:{type:String,default:"260px"},token:{type:String,default:""},toggleVersion:{type:Number},permission:{type:Number}},emits:["enc"],data(){return{helper:z.CompanyHelper,vendor:this.$attrs.permission&z.CompanyHelper.LEVEL.Supper?"hi":"i4",right:10}},watch:{vendor:{handler(){this.$emit("enc",this.vendor)},immediate:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{}},ze=a=>(i.pushScopeId("data-v-ab627b83"),a=a(),i.popScopeId(),a),fo={key:0},uo={class:"bar-item"},go=[ze(()=>i.createElementVNode("span",{class:"iconfont"},"HI",-1))],bo=[ze(()=>i.createElementVNode("span",{class:"iconfont"},"I4",-1))];function _o(a,e,t,r,o,s){return t.enabled&&t.permission&o.helper.LEVEL.Supper?(i.openBlock(),i.createElementBlock("div",fo,[i.createElementVNode("div",{class:"menu-bar-box",style:i.normalizeStyle({position:"absolute",right:o.right+"px",bottom:t.bottom})},[i.createElementVNode("div",uo,[i.createElementVNode("div",{class:i.normalizeClass(o.vendor==="hi"?"menu-icon active":"menu-icon"),onClick:e[0]||(e[0]=l=>o.vendor="hi")},go,2),i.createElementVNode("div",{class:i.normalizeClass(o.vendor==="i4"?"menu-icon active":"menu-icon"),onClick:e[1]||(e[1]=l=>o.vendor="i4")},bo,2)])],4)])):i.createCommentVNode("",!0)}const Lo=C(yo,[["render",_o],["__scopeId","data-v-ab627b83"]]),Xr="",wo={name:"IdmGLV2",components:{IdmGlLayer:mt,IdmWindBarb:wt,IdmWindParticle:kt,IdmCurrents:Vt,IdmCurrentParticle:Mt,IdmSigWave:jt,IdmSwell:Ut,IdmPrmsl:Jt,IdmIceberg:Yt,IdmTropicals:Ce,IdmPrecip3h:va,IdmVisibility:za,IdmWaterTemp:Da,IdmTemp:Aa,IdmArctic:Fa,IdmWarZone:wi,IdmGmdssArea:Ci,IdmEcaZone:Ei,IdmAlertZone:Ii,IdmPort:Ui,IdmLoadLine:Ji,IdmTimezone:Yi,IdmVRA:eo,IdmSpecialArea:io,IdmTerminator:so,IdmLatLng:Se,IdmMeasure:mo,IdmPoint:bi,IdmENC:Lo},props:{map:{type:Object,default:void 0},token:{type:String},ts:{type:String},beforeLayer:{type:String,default:""}},data(){return{weatherLayers:{},activeWeatherLayers:[],weatherWeight:0,otherLayers:{},otherWeight:0,showCoord:!1,showMeasure:!1,showPoint:!1,show3d:!1,meteo:void 0,source:"",gateway:"https://cbe.idmwx.com",mapProjection:"mercator",zoom:6,viewport:void 0,particleFactor:void 0,showRampColor:!1,activeWindLayer:!1,showWindParticle:!1,showCurrentParticle:!1,toggleVersion:0,enc:"",defaultMeteoToken:"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6ImNseTVudHJzYzAwNWUwbHBsZHkyaDRqczMiLCJyb2xlIjoxLCJuYW1lIjoiZmFrZUBvcm13eC5jb20iLCJwbGF0SWQiOiJnZDBtdDFkIiwiY29tcGFueSI6eyJpZCI6bnVsbCwiY2hpbGRyZW4iOltdfSwiaWF0IjoxNzIzMDI0MDI0LCJleHAiOjM5MzA1NDQwMjR9.RrKcdcMnq-FxBLJQ-i6lx2FscDE46y8EvHIemPW4HTg",helper:new Ee}},watch:{ts:{handler(a,e){a&&e&&A(a).utc().format("yyyy-MM-DD HH")!==A(e).utc().format("yyyy-MM-DD HH")&&this.$nextTick(()=>{this.handleDateChange({tropicals:!1})})},immediate:!0},map:{handler(){this.map&&(this.map.on("zoomend",this.handleDragEndWithZoom4Json),this.map.on("dragend",this.handleDragEndWithZoom4Json),this.map.on("move",this.handleDragEndWithZoom4Image),this.viewport=new we(this.map),this.handleRampColorInitial())},immediate:!0},enc:{handler(a,e){var t,r,o,s,l,n,c,h;a?((r=(t=this.map)==null?void 0:t.getLayer(a))==null||r.setLayoutProperty("visibility","visible"),(s=(o=this.map)==null?void 0:o.getLayer(e))==null||s.setLayoutProperty("visibility","none")):((n=(l=this.map)==null?void 0:l.getLayer("i4"))==null||n.setLayoutProperty("visibility","none"),(h=(c=this.map)==null?void 0:c.getLayer("hi"))==null||h.setLayoutProperty("visibility","none"))}},activeWeatherLayers:{handler(){var a,e,t,r,o,s,l,n,c,h,d,p,u,m,b,f,y,_;if(!this.map)return!1;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"),(s=this.map)!=null&&s.getLayer((o=this.viewport)==null?void 0:o.rampColorLayer)&&((l=this.map)!=null&&l.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)),(d=this.map)!=null&&d.getLayer((h=this.viewport)==null?void 0:h.particleLayer)&&((p=this.map)!=null&&p.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id))&&this.mapProjection==="mercator"&&((m=this.map)==null||m.moveLayer((u=this.viewport)==null?void 0:u.particleLayer,this.helper.mapboxCustomer.layers.countryBoundary.id))):((f=(b=this.map)==null?void 0:b.getLayer(this.enc))==null||f.setLayoutProperty("visibility","visible"),(_=(y=this.map)==null?void 0:y.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id))==null||_.setLayoutProperty("visibility","none"))},immediate:!0}},methods:{async fetchWeatherLayers(a={tropicals:!1}){var o,s,l,n,c,h,d,p;const e=new Date().valueOf();let t=0,r=0;if(this.map){const u=((o=this.map)==null?void 0:o.getZoom())+1,m=(s=this.map)==null?void 0:s.getBounds(),b=`${m._sw.lng},${m._sw.lat},${m._ne.lng},${m._ne.lat}`;if(this.handleRampColorState(),this.particleFactor){const f=z.LayerHelper.WEATHER_LAYERS.find(y=>{var _;return((_=y.peer)==null?void 0:_.weight)===this.particleFactor.weight});this.particleFactor.particle?this.weatherWeight=this.weatherWeight&f.weight?this.weatherWeight:this.weatherWeight+f.weight:this.weatherWeight=this.weatherWeight&f.weight?this.weatherWeight-f.weight:this.weatherWeight}if(this.weatherWeight>0){let f=this.weatherWeight,y;if(a.tropicals||this.weatherWeight&256&&(y=this.weatherLayers.tropicals,y&&(f-=256,y.version=Math.random()+1)),f>0){const _=await G.get(`${this.gateway}/api/arc/weather/layers/links?l=${f}&v=${this.source}&z=${u}&bbox=${b}&t=${this.ts}`,{headers:{Authorization:this.token||this.defaultMeteoToken}});if(r=new Date().valueOf()-(e+t),console.log("weather links elapsed: ",r,", total: ",t+=r),((l=_==null?void 0:_.data)==null?void 0:l.code)===0){const g=(n=_==null?void 0:_.data)==null?void 0:n.data,w=[];for(const L in g)L==="ice-edge"&&(g[L]="https://idm-hz.oss-cn-hangzhou.aliyuncs.com/test/sea_ice_contours.geojson"),L!=="tropicals"&&w.push(G.get(g[L],{headers:{Authorization:this.token||this.defaultMeteoToken,key:L},responseType:/\.(jpg|png)$/.test(g[L])?"blob":"json"}).catch(N=>{console.log(`[${L}] fetch layer error: ${N}`)}));const v=await Promise.all(w);this.weatherLayers={},v.map(L=>{var D,R,B,M;const N=((D=L==null?void 0:L.data)==null?void 0:D.data)||(L==null?void 0:L.data),T=(B=(R=L==null?void 0:L.config)==null?void 0:R.headers)==null?void 0:B.key;T&&N&&(this.weatherLayers[T]={raw:N,type:((M=L==null?void 0:L.config)==null?void 0:M.responseType)==="blob"?"image":"json",etime:this.ts})}),g.tropicals&&G.get(g.tropicals,{headers:{Authorization:this.token||this.defaultMeteoToken,key:"tropicals"}}).then(L=>{var D,R,B;const N=E.TropicalHelper.convert2Geojson(((D=L==null?void 0:L.data)==null?void 0:D.data)||(L==null?void 0:L.data)),T=(B=(R=L==null?void 0:L.config)==null?void 0:R.headers)==null?void 0:B.key;this.weatherLayers[T]={data:N,active:!0,cached:!1,type:"json",etime:this.ts,version:Math.random()+1}})}if(r=new Date().valueOf()-(e+t),console.log("weather layers elapsed: ",r,", total: ",t+=r),this.weatherLayers["swell-direction"]||this.weatherLayers["swell-height"]){const g=(c=this.weatherLayers["swell-direction"])==null?void 0:c.raw,w=(h=this.weatherLayers["swell-height"])==null?void 0:h.raw;delete this.weatherLayers["swell-direction"],delete this.weatherLayers["swell-height"],this.weatherLayers.swell={type:"json",direction:g,height:{raw:w},etime:this.ts}}if(this.weatherLayers["current-direction"]||this.weatherLayers["current-speed"]){const g=(d=this.weatherLayers["current-direction"])==null?void 0:d.raw,w=(p=this.weatherLayers["current-speed"])==null?void 0:p.raw;delete this.weatherLayers["current-direction"],delete this.weatherLayers["current-speed"],this.weatherLayers.current={type:"json",direction:g,speed:{raw:w},etime:this.ts}}}y&&(y.etime=this.ts,y.cached=!0,this.weatherLayers.tropicals=y)}this.handleWeatherLayerToggle(),this.handleDragEndWithZoom4Json()}this.toggleVersion=Math.random()},async fetchOtherLayers(a={all:!1,dayNight:!1,enc:!1}){var e,t,r,o;if(this.map){let s=this.otherWeight;if(s){let l=!1;if(this.otherWeight&2048&&(s=this.otherWeight-2048,l=!0),s){if(a.all){const n=await G.get(`${this.gateway}/api/arc/other/layers/links?l=${s}&t=${this.ts}`,{headers:{Authorization:this.token||this.defaultMeteoToken}});if(((e=n==null?void 0:n.data)==null?void 0:e.code)===0){const c=(t=n==null?void 0:n.data)==null?void 0:t.data,h=[];for(const p in c)h.push(G.get(c[p],{headers:{Authorization:this.token||this.defaultMeteoToken,key:p}}));const d=await Promise.all(h);this.otherLayers={enc:l},d.map(p=>{var b,f,y;const u=((b=p==null?void 0:p.data)==null?void 0:b.data)||(p==null?void 0:p.data),m=(y=(f=p==null?void 0:p.config)==null?void 0:f.headers)==null?void 0:y.key;this.otherLayers[m]=u})}}else if(a.dayNight&&s&1024){const n=await G.get(`${this.gateway}/api/arc/other/layers/links?l=1024&t=${this.ts}`,{headers:{Authorization:this.token||this.defaultMeteoToken}});if(((r=n==null?void 0:n.data)==null?void 0:r.code)===0){const c=(o=n==null?void 0:n.data)==null?void 0:o.data,h=[];for(const p in c)h.push(G.get(c[p],{headers:{Authorization:this.token||this.defaultMeteoToken,key:p}}));(await Promise.all(h)).map(p=>{var b,f,y;const u=((b=p==null?void 0:p.data)==null?void 0:b.data)||(p==null?void 0:p.data),m=(y=(f=p==null?void 0:p.config)==null?void 0:f.headers)==null?void 0:y.key;this.otherLayers[m]=u})}}}else this.otherLayers={enc:l}}else this.otherLayers={};this.handleBeforeLayerToggle()}},handleRampColorState(){var a;if(this.showRampColor=!1,this.showWindParticle=!1,this.showCurrentParticle=!1,(a=this.particleFactor)!=null&&a.particle)this.showRampColor=!0,this.showWindParticle=this.particleFactor.key==="wind",this.showCurrentParticle=this.particleFactor.key==="current",this.activeWeatherLayers=this.activeWeatherLayers.filter(e=>e.type==="json");else for(const e of this.activeWeatherLayers)["png","jpg"].includes(e.type)&&(this.showRampColor=!0);this.activeWindLayer=!!this.activeWeatherLayers.find(e=>e.key==="wind"),this.$refs.layer&&(this.$refs.layer.activeWeatherLayers=this.activeWeatherLayers)},handleRampColorInitial(){var a,e,t,r,o,s,l,n,c,h,d,p;this.viewport.map.getSource((a=this.viewport)==null?void 0:a.rampColorSource)||this.viewport.map.addSource((e=this.viewport)==null?void 0:e.rampColorSource,{type:"canvas",canvas:(t=this.viewport)==null?void 0:t.rampColorCanvas,animate:!0,coordinates:this.viewport.getBoundLngLat()}),this.viewport.map.getLayer((r=this.viewport)==null?void 0:r.rampColorLayer)||this.viewport.map.addLayer({type:"raster",id:(o=this.viewport)==null?void 0:o.rampColorLayer,source:(s=this.viewport)==null?void 0:s.rampColorSource,layout:{visibility:"none"}},this.beforeLayer),this.viewport.map.getSource((l=this.viewport)==null?void 0:l.particleSource)||this.viewport.map.addSource((n=this.viewport)==null?void 0:n.particleSource,{type:"canvas",canvas:(c=this.viewport)==null?void 0:c.particleCanvas,animate:!0,coordinates:this.viewport.getBoundLngLat()}),this.viewport.map.getLayer((h=this.viewport)==null?void 0:h.particleLayer)||this.viewport.map.addLayer({type:"raster",id:(d=this.viewport)==null?void 0:d.particleLayer,source:(p=this.viewport)==null?void 0:p.particleSource,layout:{visibility:"none"}},this.beforeLayer)},handleDragEndWithZoom4Json(){var h,d,p,u;const a=new Date().valueOf();let e=0,t=0;const r=(h=this.map)==null?void 0:h.getBounds(),o=this.map.getZoom(),s=z.convertToStandardLng(r._sw.lng),l=z.convertToStandardLng(r._ne.lng),n=Math.floor(r._sw.lat),c=Math.ceil(r._ne.lat);for(const m in this.weatherLayers)if(this.weatherLayers[m].active&&this.weatherLayers[m].type==="json"){this.weatherLayers[m].active=!1,this.weatherLayers[m].version=Math.random()+1;let b=[];if(["swell","current"].includes(m)){const f=((d=this.weatherLayers[m])==null?void 0:d.direction)||{};for(const y in f)if(y>n&&y<c&&(!(o<=this.zoom)||y%(o<this.zoom/2?5:3)===0)){const _=f[y].lng;s>l?_.forEach((g,w)=>{var v;if((g>=s&&g<=180||g>=-180&&g<=l)&&(!(o<=this.zoom)||g%(o<this.zoom/2?5:3)===0)){const L=x.point([g,y],{val:f[y].val[w],spd:(v=f[y].spd)==null?void 0:v[w]});b.push(L)}}):_.forEach((g,w)=>{var v;if(g>=s&&g<=l&&(!(o<=this.zoom)||g%(o<this.zoom/2?5:3)===0)){const L=x.point([g,y],{val:f[y].val[w],spd:(v=f[y].spd)==null?void 0:v[w]});b.push(L)}})}if(t=new Date().valueOf()-(a+e),console.log("direction elapsed: ",t,", total: ",e+=t),m==="swell"){const y=this.weatherLayers[m].height;if(y){if(!y.data){const _=[];for(const g in(p=y.raw)==null?void 0:p.LineString){const w=y.raw.LineString[g];for(const v of w)_.push(x.lineString(v,{val:Number(g)}));y.data=x.featureCollection(_)}}if(y.data){const _=this.handleBboxClip(y.data,r);b=b.concat(_)}t=new Date().valueOf()-(a+e),console.log("height elapsed: ",t,", total: ",e+=t)}}if(m==="current"){const y=this.weatherLayers[m].speed;if(y){if(!y.data){const g=[];for(const w in(u=y.raw)==null?void 0:u.Polygon){const v=y.raw.Polygon[w];for(const L of v)g.push(x.polygon(L,{val:Number(w)}))}y.data=x.featureCollection(g)}const _=o<this.zoom?y.data.features.filter(g=>g.properties.val>.5):y.data.features;b=b.concat(_),t=new Date().valueOf()-(a+e),console.log("speed elapsed: ",t,", total: ",e+=t)}}}else if(m==="wind"){const f=this.weatherLayers.wind.raw;for(const y in f)if(y>n&&y<c&&(!(o<=this.zoom)||y%(o<this.zoom/2?5:3)===0)){const _=f[y].lng;s>l?_.forEach((g,w)=>{if((g>=s&&g<=180||g>=-180&&g<=l)&&(!(o<=this.zoom)||g%(o<this.zoom/2?5:3)===0)){const v=x.point([g,y],{val:f[y].val[w],spd:f[y].spd[w]});b.push(v)}}):_.forEach((g,w)=>{if(g>=s&&g<=l&&(!(o<=this.zoom)||g%(o<this.zoom/2?5:3)===0)){const v=x.point([g,y],{val:f[y].val[w],spd:f[y].spd[w]});b.push(v)}})}t=new Date().valueOf()-(a+e),console.log("wind barb elapsed: ",t,", total: ",e+=t)}else if(m==="sig-wave-height"){if(this.weatherLayers[m].data)b=this.weatherLayers[m].data;else{const f=this.weatherLayers[m].raw;if(f){const y=[];for(const _ in f.Polygon){const g=f.Polygon[_];for(const w of g)y.push(x.polygon(w,{val:Number(_)}))}for(const _ in f.Point){const g=f.Point[_];for(const w of g)y.push(...x.points(w,{val:Number(_)}).features)}b=b.concat(y)}}t=new Date().valueOf()-(a+e),console.log("sigWave elapsed: ",t,", total: ",e+=t)}else if(m==="prmsl"){if(this.weatherLayers[m].data)b=this.weatherLayers[m].data;else{const f=this.weatherLayers[m].raw;if(f){const y=[];for(const _ in f.LineString){const g=f.LineString[_];for(const w of g)y.push(x.lineString(w,{val:Number(_)}))}for(const _ in f.Point)f.Point[_].lng.forEach((g,w)=>{g=z.convertToStandardLng(g),y.push(x.point([g,_],{val:f.Point[_].val[w],type:f.Point[_].type[w]}))});b=b.concat(y)}}t=new Date().valueOf()-(a+e),console.log("prmsl elapsed: ",t,", total: ",e+=t)}else if(m==="arctic"||m==="iceberg"){if(this.weatherLayers[m].data)b=this.weatherLayers[m].data;else{const f=this.weatherLayers[m].raw;if(f){const y=[];for(const _ in f.LineString){const g=f.LineString[_];for(const w of g)y.push(x.lineString(w,{val:Number(_)}))}b=b.concat(y)}}t=new Date().valueOf()-(a+e)}console.log(m," elapsed: ",t,", total: ",e+=t),b.length&&(this.weatherLayers[m].data=x.featureCollection(b)),this.weatherLayers[m].active=!0,this.weatherLayers[m].version=Math.random()+1}},handleDragEndWithZoom4Image(){for(const a in this.weatherLayers)this.weatherLayers[a].active&&this.weatherLayers[a].type==="image"&&(this.weatherLayers[a].active=!0,this.weatherLayers[a].version=Math.random()+1)},handleBboxClip(a,e){const t=[],r=z.convertToStandardLng(e._sw.lng),o=z.convertToStandardLng(e._ne.lng);return a.features.forEach(s=>{if(s.geometry.type!=="Point")if(r>o){let l=[r,e._sw.lat,180,e._ne.lat],n=x.bboxClip(s,l);n.geometry.coordinates.length&&t.push(n),l=[-180,e._sw.lat,o,e._ne.lat],n=x.bboxClip(s,l),n.geometry.coordinates.length&&t.push(n)}else{const l=[r,e._sw.lat,o,e._ne.lat],n=x.bboxClip(s,l);n.geometry.coordinates.length&&t.push(n)}else t.push(s)}),t},handleWeatherLayerToggle(){var a;for(const e in this.weatherLayers)this.weatherLayers[e].active=!1,this.weatherLayers[e].version=Math.random()+1;for(const e of this.activeWeatherLayers){let t=e.key;t.indexOf("swell")>-1?t="swell":t.indexOf("current")>-1&&(t="current"),this.weatherLayers[t]&&(this.weatherLayers[t].active=!0,this.weatherLayers[t].version=Math.random()+1,((a=this.particleFactor)==null?void 0:a.key)===t&&this.weatherLayers[`${t}-particle`]&&(this.weatherLayers[`${t}-particle`].active=this.particleFactor.particle))}this.handleBeforeLayerToggle()},handleBeforeLayerToggle(){var a,e,t,r,o,s,l,n,c,h,d,p,u;(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"]||(o=this.otherLayers)!=null&&o["load-lines"]||(s=this.otherLayers)!=null&&s["high-risk-area"]||(l=this.otherLayers)!=null&&l["time-zones"]||(n=this.otherLayers)!=null&&n.pirates||(c=this.otherLayers)!=null&&c.ports||(h=this.otherLayers)!=null&&h.enc||(d=this.otherLayers)!=null&&d["voluntary-reporting-area"]||(p=this.otherLayers)!=null&&p["eca-zones"]||(u=this.otherLayers)!=null&&u["special-area"])&&this.map.setLayoutProperty(this.beforeLayer,"visibility","visible")},handleDateChange(a={tropicals:!1}){this.fetchWeatherLayers(a),this.fetchOtherLayers({dayNight:!0})},handleWeatherLayerChange(a,e,t){if(!this.map)setTimeout(()=>{this.handleWeatherLayerChange(a,e,t)},500);else{this.activeWeatherLayers=e;const r=this.activeWeatherLayers.some(l=>["wind","current"].includes(l.key)),o=this.activeWeatherLayers.some(l=>["png","jpg"].includes(l.type));r&&!o?(this.particleFactor=this.activeWeatherLayers.find(l=>["wind","current"].includes(l.key)),this.particleFactor.particle=!0):o&&this.particleFactor&&(this.particleFactor.particle=!1);const s=e==null?void 0:e.reduce((l,n)=>l+(l&(n==null?void 0:n.weight)?0:n==null?void 0:n.weight),0);this.weatherWeight!==s||this.source!==t?(this.source=t,this.weatherWeight=s,this.fetchWeatherLayers({tropicals:!1})):this.handleWeatherLayerToggle()}},handleOtherLayerChange(a){if(!this.map)setTimeout(()=>{this.handleOtherLayerChange(a)},500);else{const e=a==null?void 0:a.reduce((t,r)=>t+(r==null?void 0:r.weight),0);a.find(t=>t.key==="enc")?this.enc="i4":this.enc="",this.otherWeight!=e&&(this.otherWeight=e,this.fetchOtherLayers({all:!0}))}},async handlePointChange(a){const e=this.ts?A(this.ts):A(),t={lat:a.lat,lng:a.lng,ts:e.utc().format(),wt:!0,src:this.source},r=await G.get(`${this.gateway}/api/arc/meteo/query`,{params:t,headers:{Authorization:this.token||this.defaultMeteoToken}});(r==null?void 0:r.status)===200&&(this.meteo={...r==null?void 0:r.data,...a})},handle3dToggle(a){var e,t,r,o,s,l,n,c,h,d,p,u,m,b,f,y,_,g,w,v;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))&&((s=this.map)==null||s.moveLayer((o=this.viewport)==null?void 0:o.rampColorLayer,this.helper.mapboxCustomer.layers.water.id)),(n=this.map)!=null&&n.getLayer((l=this.viewport)==null?void 0:l.particleLayer)&&((c=this.map)!=null&&c.getLayer(this.helper.mapboxCustomer.layers.water.id))&&((d=this.map)==null||d.moveLayer((h=this.viewport)==null?void 0:h.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(),(u=this.map)!=null&&u.getLayer((p=this.viewport)==null?void 0:p.rampColorLayer)&&((m=this.map)!=null&&m.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id))&&((f=this.map)==null||f.moveLayer((b=this.viewport)==null?void 0:b.rampColorLayer,this.helper.mapboxCustomer.layers.countryBoundary.id)),(_=this.map)!=null&&_.getLayer((y=this.viewport)==null?void 0:y.particleLayer)&&((g=this.map)!=null&&g.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id))&&((v=this.map)==null||v.moveLayer((w=this.viewport)==null?void 0:w.particleLayer,this.helper.mapboxCustomer.layers.countryBoundary.id)))},handleParticle(a){this.particleFactor=a,this.fetchWeatherLayers({tropicals:!1})}}},xo={key:0,className:"map-gl-home"};function vo(a,e,t,r,o,s){var Q,W,j,he,F,S,$,de,H,pe,K,ee,te,ue,ge,be,_e,Le,ke,Ne,Te,Ie,De,Ve,Re,Be;const l=i.resolveComponent("IdmGlLayer"),n=i.resolveComponent("IdmENC"),c=i.resolveComponent("IdmSigWave"),h=i.resolveComponent("IdmSwell"),d=i.resolveComponent("IdmPrmsl"),p=i.resolveComponent("IdmIceberg"),u=i.resolveComponent("IdmTropicals"),m=i.resolveComponent("IdmCurrents"),b=i.resolveComponent("IdmCurrentParticle"),f=i.resolveComponent("IdmWindBarb"),y=i.resolveComponent("IdmWindParticle"),_=i.resolveComponent("IdmPrecip3h"),g=i.resolveComponent("IdmVisibility"),w=i.resolveComponent("IdmWaterTemp"),v=i.resolveComponent("IdmTemp"),L=i.resolveComponent("IdmArctic"),N=i.resolveComponent("IdmWarZone"),T=i.resolveComponent("IdmGmdssArea"),D=i.resolveComponent("IdmEcaZone"),R=i.resolveComponent("IdmAlertZone"),B=i.resolveComponent("IdmPort"),M=i.resolveComponent("IdmLoadLine"),ie=i.resolveComponent("IdmTimezone"),oe=i.resolveComponent("IdmVRA"),re=i.resolveComponent("IdmSpecialArea"),se=i.resolveComponent("IdmTerminator"),ne=i.resolveComponent("IdmLatLng"),le=i.resolveComponent("IdmMeasure"),ce=i.resolveComponent("IdmPoint");return t.map?(i.openBlock(),i.createElementBlock("div",xo,[i.createVNode(l,i.mergeProps({ref:"layer",map:t.map,"toggle-version":o.toggleVersion,"map-projection":o.mapProjection},a.$attrs,{onWeather:s.handleWeatherLayerChange,onOther:s.handleOtherLayerChange,onCoordinate:e[0]||(e[0]=U=>o.showCoord=U),onMeasure:e[1]||(e[1]=U=>o.showMeasure=U),onPoint:e[2]||(e[2]=U=>o.showPoint=U),on3d:s.handle3dToggle,onToggleVersion:e[3]||(e[3]=U=>o.toggleVersion=U)}),null,16,["map","toggle-version","map-projection","onWeather","onOther","on3d"]),i.createVNode(n,i.mergeProps({map:t.map,token:t.token,enabled:(Q=o.otherLayers)==null?void 0:Q.enc,"toggle-version":o.toggleVersion},a.$attrs,{onEnc:e[4]||(e[4]=U=>o.enc=U)}),null,16,["map","token","enabled","toggle-version"]),i.createVNode(c,i.mergeProps({map:t.map,"sig-wave":(W=o.weatherLayers)==null?void 0:W["sig-wave-height"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","sig-wave","before-layer"]),i.createVNode(h,i.mergeProps({map:t.map,swell:(j=o.weatherLayers)==null?void 0:j.swell,"before-layer":t.beforeLayer},a.$attrs),null,16,["map","swell","before-layer"]),i.createVNode(d,i.mergeProps({map:t.map,prmsl:(he=o.weatherLayers)==null?void 0:he.prmsl,"before-layer":t.beforeLayer,"active-weather-layers":o.activeWeatherLayers},a.$attrs),null,16,["map","prmsl","before-layer","active-weather-layers"]),i.createVNode(p,i.mergeProps({map:t.map,iceberg:(F=o.weatherLayers)==null?void 0:F.iceberg,"before-layer":t.beforeLayer},a.$attrs),null,16,["map","iceberg","before-layer"]),i.createVNode(u,i.mergeProps({map:t.map,date:t.ts,tropicals:(S=o.weatherLayers)==null?void 0:S.tropicals,"before-layer":t.beforeLayer},a.$attrs),null,16,["map","date","tropicals","before-layer"]),i.createVNode(m,i.mergeProps({map:t.map,"map-projection":o.mapProjection,current:($=o.weatherLayers)==null?void 0:$.current,"before-layer":t.beforeLayer,"show-particle":o.showCurrentParticle,"margin-bottom":o.activeWindLayer?o.showRampColor?"84px":"56px":o.showRampColor?"56px":"30px","toggle-version":o.toggleVersion,"weather-layers":o.weatherLayers},a.$attrs,{onParticle:s.handleParticle}),null,16,["map","map-projection","current","before-layer","show-particle","margin-bottom","toggle-version","weather-layers","onParticle"]),i.createVNode(b,i.mergeProps({viewport:o.viewport,factor:(de=o.weatherLayers)==null?void 0:de["current-particle"],"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(f,i.mergeProps({ref:"windBarb",map:t.map,"map-projection":o.mapProjection,wind:(H=o.weatherLayers)==null?void 0:H.wind,current:(pe=o.weatherLayers)==null?void 0:pe.current,"before-layer":t.beforeLayer,"margin-bottom":o.showRampColor?"56px":"30px","show-particle":o.showWindParticle},a.$attrs,{"toggle-version":o.toggleVersion,"weather-layers":o.weatherLayers,onParticle:s.handleParticle}),null,16,["map","map-projection","wind","current","before-layer","margin-bottom","show-particle","toggle-version","weather-layers","onParticle"]),i.createVNode(y,i.mergeProps({viewport:o.viewport,factor:(K=o.weatherLayers)==null?void 0:K["wind-particle"],"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(_,i.mergeProps({viewport:o.viewport,factor:(ee=o.weatherLayers)==null?void 0:ee.precip3h,"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(g,i.mergeProps({viewport:o.viewport,factor:(te=o.weatherLayers)==null?void 0:te.visibility,"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(w,i.mergeProps({viewport:o.viewport,factor:(ue=o.weatherLayers)==null?void 0:ue["water-temp"],"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(v,i.mergeProps({viewport:o.viewport,factor:(ge=o.weatherLayers)==null?void 0:ge.temp,"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(L,i.mergeProps({viewport:o.viewport,factor:(be=o.weatherLayers)==null?void 0:be.arctic,"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(N,i.mergeProps({map:t.map,zone:(_e=o.otherLayers)==null?void 0:_e["war-zones"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","zone","before-layer"]),i.createVNode(T,i.mergeProps({map:t.map,area:(Le=o.otherLayers)==null?void 0:Le["gmdss-areas"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","area","before-layer"]),i.createVNode(D,i.mergeProps({map:t.map,zone:(ke=o.otherLayers)==null?void 0:ke["eca-zones"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","zone","before-layer"]),i.createVNode(R,i.mergeProps({map:t.map,zone:(Ne=o.otherLayers)==null?void 0:Ne["alert-zones"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","zone","before-layer"]),i.createVNode(B,i.mergeProps({map:t.map,port:(Te=o.otherLayers)==null?void 0:Te.ports,"before-layer":t.beforeLayer},a.$attrs),null,16,["map","port","before-layer"]),i.createVNode(M,i.mergeProps({map:t.map,line:(Ie=o.otherLayers)==null?void 0:Ie["load-lines"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","line","before-layer"]),i.createVNode(ie,i.mergeProps({map:t.map,zone:(De=o.otherLayers)==null?void 0:De["time-zones"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","zone","before-layer"]),i.createVNode(oe,i.mergeProps({map:t.map,area:(Ve=o.otherLayers)==null?void 0:Ve["voluntary-reporting-area"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","area","before-layer"]),i.createVNode(re,i.mergeProps({map:t.map,area:(Re=o.otherLayers)==null?void 0:Re["special-area"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","area","before-layer"]),i.createVNode(se,i.mergeProps({map:t.map,area:(Be=o.otherLayers)==null?void 0:Be["day-night"]},a.$attrs),null,16,["map","area"]),i.createVNode(ne,i.mergeProps({map:t.map,show:o.showCoord,"toggle-version":o.toggleVersion},a.$attrs),null,16,["map","show","toggle-version"]),i.createVNode(le,i.mergeProps({map:t.map,show:o.showMeasure},a.$attrs),null,16,["map","show"]),i.createVNode(ce,i.mergeProps({map:t.map,show:o.showPoint,meteo:o.meteo},a.$attrs,{onPoint:s.handlePointChange}),null,16,["map","show","meteo","onPoint"])])):i.createCommentVNode("",!0)}const Pe=C(wo,[["render",vo]]),Co={install(a){a.component("MapboxGL",Pe),a.component("TropicalGL",Ce),a.component("LatLngGL",Se)}};k.LatLngGL=Se,k.MapboxGL=Pe,k.MapboxGLPlugin=Co,k.MapboxHelper=Ee,k.ParticleSchema=V,k.TropicalGL=Ce,k.Viewport=we,k.WebGL=J,k.WebGLSchema=I,Object.defineProperty(k,Symbol.toStringTag,{value:"Module"})});
|
|
204
|
+
</svg>`,H=document.createElement("div");H.className="hurricane-hourly-marker",H.innerHTML=`<div class="${S.geometry.coordinates[1]>=0?"center north":"center south"}">${de}</div>`;const pe=new Z.Marker(H).setLngLat(S.geometry.coordinates).addTo(this.map);if(this.interpolateMarkers.push(pe),(ie=S.properties)!=null&&ie.showCircle){const K={radius:100,coordinates:S.geometry.coordinates},ee={radius:200,coordinates:S.geometry.coordinates},te={radius:500,coordinates:S.geometry.coordinates};(oe=this.circleSourceData)==null||oe.features.push(x.circle(K.coordinates,K.radius,{steps:100,units:"kilometers",properties:{type:"tropicalCircle"}})),(re=this.circleSourceData)==null||re.features.push(x.circle(ee.coordinates,ee.radius,{steps:100,units:"kilometers",properties:{type:"tropicalCircle"}})),(se=this.circleSourceData)==null||se.features.push(x.circle(te.coordinates,te.radius,{steps:100,units:"kilometers",properties:{type:"tropicalCircle"}}))}(le=(ne=this.map)==null?void 0:ne.getSource(this.circleSource))==null||le.setData(this.circleSourceData)}}else(ce=this.map)!=null&&ce.getSource(this.interpolateSource)&&((Q=this.map)==null||Q.getSource(this.interpolateSource).setData(this.empty))},handleClick(a){var s,l,n,c,h,d,p,u;const e=a.features[0],t=(l=(s=this.tropicals)==null?void 0:s.data)==null?void 0:l.features.filter(m=>{var b;return m.geometry.type==="LineString"&&m.properties.type==="forecast"&&m.properties.name===((b=e==null?void 0:e.properties)==null?void 0:b.name)});t.sort((m,b)=>{var f,y,_,g;return((f=m.properties)==null?void 0:f.model)==="cma"?-1:((y=m.properties)==null?void 0:y.model)==="jma"?((_=b.properties)==null?void 0:_.model)==="cma"?1:-1:m.properties.model==="ecmwf"?["jma","cma"].includes((g=b.properties)==null?void 0:g.model)?1:-1:0});const r=(c=(n=this.tropicals)==null?void 0:n.data)==null?void 0:c.features.filter(m=>{var b;return m.geometry.type==="LineString"&&m.properties.type==="history"&&m.properties.name===((b=e==null?void 0:e.properties)==null?void 0:b.name)});this.activeTropicals={name:(h=e==null?void 0:e.properties)==null?void 0:h.name,forecasts:t.map(m=>m.properties),history:(d=r[0])==null?void 0:d.properties,showCircle:(u=(p=t[0])==null?void 0:p.properties)==null?void 0:u.showCircle},this.showTropicals=!0;const o=document.getElementById("active-tropical");this.activeTropicalsMarker?this.activeTropicalsMarker.setLngLat([a.lngLat.lng,a.lngLat.lat]):this.activeTropicalsMarker=new Z.Marker(o).setLngLat([a.lngLat.lng,a.lngLat.lat]).setOffset([220,0]).addTo(this.map)},handleForecastToggle(a){var r,o,s,l,n,c;a.disabled=!a.disabled;const e=`${a.name}-${a.model}`,t=(o=(r=this.map)==null?void 0:r.getSource(this.source)._data)==null?void 0:o.features;t.forEach(h=>{h.properties.category===e&&(h.properties.disabled=a.disabled)}),this.interpolateData.forEach(h=>{h.properties.category===e&&(h.properties.disabled=a.disabled)}),(l=(s=this.map)==null?void 0:s.getSource(this.source))==null||l.setData(x.featureCollection(t)),(c=(n=this.map)==null?void 0:n.getSource(this.clusterSource))==null||c.setData(x.featureCollection(t)),this.handleDateChange()},handleStrikeProbability(a){this.$emit("tropicalProbability",a)},handleToggleCircles(a){var e,t;a.showCircle=!a.showCircle,(t=(e=this.tropicals.data)==null?void 0:e.features)==null||t.forEach(r=>{r.properties.name===a.name&&(r.properties.showCircle=a.showCircle)}),this.handleRender()},handleDrawCircle(){var a,e;(a=this.map)!=null&&a.getSource(this.circleSource)?(e=this.map)==null||e.getSource(this.circleSource).setData(this.circleSourceData):(this.map.addSource(this.circleSource,{type:"geojson",data:this.circleSourceData}),this.map.addLayer({id:this.circleLayer,type:"line",source:this.circleSource,filter:["all",["==","$type","Polygon"],["==","type","tropicalCircle"]],paint:{"line-color":"#fff","line-width":2,"line-opacity":1,"line-dasharray":[1,1]}}))},handleComputePolygons(a){const e=[];for(const t of a){const r=t.properties.wind,o={ne:r.r7ne>=0?r.r7ne:void 0,se:r.r7se>=0?r.r7se:void 0,sw:r.r7sw>=0?r.r7sw:void 0,nw:r.r7nw>=0?r.r7nw:void 0},s=this.handleComputeArc(t.geometry.coordinates,o,{...t.properties,level:7});e.push(s);const l={ne:r.r10ne>=0?r.r10ne:void 0,se:r.r10se>=0?r.r10se:void 0,sw:r.r10sw>=0?r.r10sw:void 0,nw:r.r10nw>=0?r.r10nw:void 0},n=this.handleComputeArc(t.geometry.coordinates,l,{...t.properties,level:10});e.push(n)}return e},handleComputeArc(a,e,t){var s;const r=[];for(const l in e){const n=e[l]??0;let c;switch(l){case"ne":c=x.lineArc(a,n*1.852,0,90,{steps:n>0?64:1});break;case"se":c=x.lineArc(a,n*1.852,90,180,{steps:n>0?64:1});break;case"sw":c=x.lineArc(a,n*1.852,180,270,{steps:n>0?64:1});break;case"nw":c=x.lineArc(a,n*1.852,270,360,{steps:n>0?64:1});break}r.push(...(s=c==null?void 0:c.geometry)==null?void 0:s.coordinates)}const o=x.lineString(r);return x.lineToPolygon(o,{properties:t})}}},ve=a=>(i.pushScopeId("data-v-08ecb5a5"),a=a(),i.popScopeId(),a),Kt={id:"active-tropical",class:"active-tropical"},ea={class:"header-box"},ta={class:"main"},aa={key:0},ia={class:"sub"},oa={id:"meteoBox",class:"main-box"},ra={class:"content"},sa={class:"row"},na={class:"col col-left",style:{"justify-content":"flex-start"}},la=ve(()=>i.createElementVNode("label",null,"Wind speed : ",-1)),ca={class:"col col-right",style:{"justify-content":"flex-start"}},ha=ve(()=>i.createElementVNode("label",null,"Pressure : ",-1)),da={class:"row"},pa={class:"col col-24",style:{"justify-content":"flex-start"}},ma=ve(()=>i.createElementVNode("label",{style:{width:"max-content"}},"Forecast Models : ",-1)),ya={class:"forecast-models"},fa=["onClick"],ua=i.createStaticVNode('<div class="row" style="padding:0;height:1px;margin:10px 0;background:var(--idm-black-1);" data-v-08ecb5a5></div><div class="row" style="padding:2px 10px;" data-v-08ecb5a5><div class="legend" data-v-08ecb5a5><div class="icon td" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>TD</div></div><div class="legend" data-v-08ecb5a5><div class="icon ts" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>TS</div></div><div class="legend" data-v-08ecb5a5><div class="icon sts" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>STS</div></div><div class="legend" data-v-08ecb5a5><div class="icon ty" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>TY</div></div><div class="legend" data-v-08ecb5a5><div class="icon sty" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>STY</div></div><div class="legend" data-v-08ecb5a5><div class="icon supper-ty" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>Super TY</div></div></div><div class="row" style="padding:2px 10px;" data-v-08ecb5a5><div class="legend" data-v-08ecb5a5><div class="icon history" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>History</div></div><div class="legend" data-v-08ecb5a5><div class="icon r7" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>35kts Radii</div></div><div class="legend" data-v-08ecb5a5><div class="icon r10" data-v-08ecb5a5></div><div class="label" data-v-08ecb5a5>50kts Radii</div></div></div>',3),ga={class:"more"};function ba(a,e,t,r,o,s){var l,n,c,h,d,p,u,m,b,f,y,_,g,w,v;return i.withDirectives((i.openBlock(),i.createElementBlock("div",Kt,[i.createElementVNode("div",ea,[i.createElementVNode("div",{class:"iconfont close-btn",onClick:e[0]||(e[0]=L=>o.showTropicals=!1)},""),i.createElementVNode("div",ta,[(n=(l=o.activeTropicals)==null?void 0:l.history)!=null&&n.level?(i.openBlock(),i.createElementBlock("span",aa,i.toDisplayString((h=(c=o.activeTropicals)==null?void 0:c.history)==null?void 0:h.level)+" , ",1)):i.createCommentVNode("",!0),i.createTextVNode(i.toDisplayString((d=o.activeTropicals)==null?void 0:d.name),1)]),i.createElementVNode("div",ia," Last update: "+i.toDisplayString(s.computeTime(((u=(p=o.activeTropicals)==null?void 0:p.history)==null?void 0:u.updated)||((f=(b=(m=o.activeTropicals)==null?void 0:m.forecasts)==null?void 0:b.filter(L=>!L.disabled)[0])==null?void 0:f.date))),1)]),i.createElementVNode("div",oa,[i.createElementVNode("div",ra,[i.createElementVNode("div",sa,[i.createElementVNode("div",na,[la,i.createElementVNode("span",null,i.toDisplayString(((_=(y=o.activeTropicals)==null?void 0:y.history)==null?void 0:_.kts)||"-")+"[kts]",1)]),i.createElementVNode("div",ca,[ha,i.createElementVNode("span",null,i.toDisplayString(((w=(g=o.activeTropicals)==null?void 0:g.history)==null?void 0:w.pressure)||"-")+"[hPa]",1)])]),i.createElementVNode("div",da,[i.createElementVNode("div",pa,[ma,i.createElementVNode("div",ya,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList((v=o.activeTropicals)==null?void 0:v.forecasts,(L,N)=>{var T,D,R,B;return i.openBlock(),i.createElementBlock("div",{key:N,class:i.normalizeClass(["model",L.disabled?"":"active",N>0&&N<((D=(T=o.activeTropicals)==null?void 0:T.forecasts)==null?void 0:D.length)-1&&((B=(R=o.activeTropicals)==null?void 0:R.forecasts)==null?void 0:B.length)>2?"center-child":""]),onClick:M=>s.handleForecastToggle(L)},[i.createElementVNode("span",{class:i.normalizeClass(L.model)},i.toDisplayString(L.model),3)],10,fa)}),128))])])]),ua]),i.createElementVNode("div",ga,[i.createElementVNode("div",{class:"button",onClick:e[1]||(e[1]=L=>s.handleStrikeProbability(o.activeTropicals))},"Strike Probability >>")])])],512)),[[i.vShow,o.showTropicals&&!a.$attrs.hideTropicalsLegend]])}const Ce=C(Qt,[["render",ba],["__scopeId","data-v-08ecb5a5"]]),tr="",_a={name:"IdmPrecip3h",props:{factor:{type:Object},viewport:{type:Object},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{program:void 0,context:void 0,texture:void 0,rampColor:void 0,aPositionBuffer:void 0,webgl:new J,etime:void 0,right:10}},watch:{"factor.version":{handler(){var a;(a=this.factor)!=null&&a.active?this.handleRender():this.handleClear()},deep:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{handleRender(){if(!this.viewport)setTimeout(()=>{this.handleRender()},500);else if(this.factor){const a=new Date().valueOf();let e=0,t=0;this.handleDraw(),t=new Date().valueOf()-(a+e),console.log("[precip3h] add elapsed: ",t,", total: ",e+=t)}},handleClear(){this.context=void 0,this.etime=void 0,this.viewport.toggle(!1)},handleSetup(){if(!this.context){this.context=this.viewport.rampColorCanvas.getContext("webgl");const a=[[0,"rgba(59, 126, 162, 0)"],[14/255,"rgba(84,170,230, 0)"],[15/255,"rgba(172, 210, 255, 0.8)"],[20/255,"rgba(51,202,248,0.8)"],[30/255,"rgba(3,248,103,0.8)"],[49/255,"rgba(14,201,3,0.8)"],[57/255,"rgba(190,226,2,0.8)"],[73/255,"rgba(248,1,1,0.8)"],[82/255,"rgba(197,5,58,0.8)"],[1,"rgba(197,5,58,0.8)"]];this.rampColor=this.webgl.setup(this.context,a);const{program:e,aPositionBuffer:t}=this.webgl.bind(this.context,I.vertexSchema,I.fragmentSchema);this.program=e,this.aPositionBuffer=t}},async handleDraw(){if(this.handleSetup(),this.etime!==this.factor.etime){this.etime=this.factor.etime;const a=await this.webgl.loadImg(this.factor.raw);this.texture=this.webgl.createTexture(this.context,this.context.NEAREST,this.context.LINEAR,this.context.CLAMP_TO_EDGE,a)}this.webgl.draw(this.viewport,this.context,this.program,this.texture,this.rampColor.texture,this.aPositionBuffer),this.viewport.toggle(!0)}}},q=a=>(i.pushScopeId("data-v-dec867b8"),a=a(),i.popScopeId(),a),La={key:0},wa=[q(()=>i.createElementVNode("span",null,"mm",-1)),q(()=>i.createElementVNode("span",null,"1.5",-1)),q(()=>i.createElementVNode("span",null,"2",-1)),q(()=>i.createElementVNode("span",null,"3",-1)),q(()=>i.createElementVNode("span",null,"7",-1)),q(()=>i.createElementVNode("span",null,"10",-1)),q(()=>i.createElementVNode("span",null,"20",-1)),q(()=>i.createElementVNode("span",null,"30",-1))];function xa(a,e,t,r,o,s){var l;return(l=t.factor)!=null&&l.active?(i.openBlock(),i.createElementBlock("div",La,[i.createElementVNode("div",{class:"legend-bars flex-center",style:i.normalizeStyle([{position:"absolute"},{right:o.right+"px",bottom:t.bottom}])},wa,4)])):i.createCommentVNode("",!0)}const va=C(_a,[["render",xa],["__scopeId","data-v-dec867b8"]]),hr="",Ca={name:"IdmVisibility",props:{factor:{type:Object},viewport:{type:Object},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{program:void 0,context:void 0,texture:void 0,rampColor:void 0,aPositionBuffer:void 0,webgl:new J,etime:void 0}},watch:{"factor.version":{handler(){var a;(a=this.factor)!=null&&a.active?this.handleRender():this.handleClear()},deep:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{handleRender(){if(!this.viewport)setTimeout(()=>{this.handleRender()},500);else if(this.factor){const a=new Date().valueOf();let e=0,t=0;this.handleDraw(),t=new Date().valueOf()-(a+e),console.log("[visibility] add elapsed: ",t,", total: ",e+=t)}},handleClear(){this.context=void 0,this.etime=void 0,this.viewport.toggle(!1)},handleSetup(){if(!this.context){this.context=this.viewport.rampColorCanvas.getContext("webgl");const a=[[0,"rgba(189,50,160,0.8)"],[8/255,"rgba(208,56,56,0.8)"],[27/255,"rgba(190,226,2,0.8)"],[60/255,"rgba(3,236,118,0.8)"],[160/255,"rgba(172, 210,255,0.8)"],[161/255,"rgba(172, 210,255,0)"],[1,"rgba(144,144,144,0)"]];this.rampColor=this.webgl.setup(this.context,a);const{program:e,aPositionBuffer:t}=this.webgl.bind(this.context,I.vertexSchema,I.fragmentSchema);this.program=e,this.aPositionBuffer=t}},async handleDraw(){if(this.handleSetup(),this.etime!==this.factor.etime){this.etime=this.factor.etime;const a=await this.webgl.loadImg(this.factor.raw);this.texture=this.webgl.createTexture(this.context,this.context.NEAREST,this.context.LINEAR,this.context.CLAMP_TO_EDGE,a)}this.webgl.draw(this.viewport,this.context,this.program,this.texture,this.rampColor.texture,this.aPositionBuffer),this.viewport.toggle(!0)}}},me=a=>(i.pushScopeId("data-v-952dee5c"),a=a(),i.popScopeId(),a),Sa={key:0},ka=[me(()=>i.createElementVNode("span",null,"nm",-1)),me(()=>i.createElementVNode("span",null,"0",-1)),me(()=>i.createElementVNode("span",null,"0.5",-1)),me(()=>i.createElementVNode("span",null,"1.5",-1)),me(()=>i.createElementVNode("span",null,"3",-1)),me(()=>i.createElementVNode("span",null,"9",-1))];function Ea(a,e,t,r,o,s){var l;return(l=t.factor)!=null&&l.active?(i.openBlock(),i.createElementBlock("div",Sa,[i.createElementVNode("div",{class:"legend-bars flex-center",style:i.normalizeStyle([{position:"absolute"},{right:a.right+"px",bottom:t.bottom}])},ka,4)])):i.createCommentVNode("",!0)}const za=C(Ca,[["render",Ea],["__scopeId","data-v-952dee5c"]]),gr="",Pa={name:"IdmWaterTemp",props:{factor:{type:Object},viewport:{type:Object},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{program:void 0,context:void 0,texture:void 0,rampColor:void 0,aPositionBuffer:void 0,webgl:new J,etime:void 0,right:10}},watch:{"factor.version":{handler(){var a;(a=this.factor)!=null&&a.active?this.handleRender():this.handleClear()},deep:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{handleRender(){if(!this.viewport)setTimeout(()=>{this.handleRender()},500);else if(this.factor){const a=new Date().valueOf();let e=0,t=0;this.handleDraw(),t=new Date().valueOf()-(a+e),console.log("[water-temp] add elapsed: ",t,", total: ",e+=t)}},handleClear(){this.context=void 0,this.etime=void 0,this.viewport.toggle(!1)},handleSetup(){if(!this.context){this.context=this.viewport.rampColorCanvas.getContext("webgl");const a=[[0,"rgba(95, 143, 197)"],[46/255,"rgba(95, 143, 197)"],[69/255,"rgb(80, 140, 62)"],[92/255,"rgb(121, 146, 28)"],[115/255,"rgb(171, 161, 14)"],[138/255,"rgb(223, 177, 69)"],[161/255,"rgb(243, 150, 6)"],[184/255,"rgb(236, 95, 21)"],[207/255,"rgb(190, 65, 18)"],[230/255,"rgb(138, 43, 10)"],[1,"rgb(138, 43, 10)"]];this.rampColor=this.webgl.setup(this.context,a);const{program:e,aPositionBuffer:t}=this.webgl.bind(this.context,I.vertexSchema,I.fragmentSchema);this.program=e,this.aPositionBuffer=t}},async handleDraw(){if(this.handleSetup(),this.etime!==this.factor.etime){this.etime=this.factor.etime;const a=await this.webgl.loadImg(this.factor.raw);this.texture=this.webgl.createTexture(this.context,this.context.NEAREST,this.context.LINEAR,this.context.CLAMP_TO_EDGE,a)}this.webgl.draw(this.viewport,this.context,this.program,this.texture,this.rampColor.texture,this.aPositionBuffer),this.viewport.toggle(!0)}}},ye=a=>(i.pushScopeId("data-v-67e5094b"),a=a(),i.popScopeId(),a),Na={key:0},Ta=[ye(()=>i.createElementVNode("span",null,"°C",-1)),ye(()=>i.createElementVNode("span",null,"0",-1)),ye(()=>i.createElementVNode("span",null,"10",-1)),ye(()=>i.createElementVNode("span",null,"20",-1)),ye(()=>i.createElementVNode("span",null,"30",-1)),ye(()=>i.createElementVNode("span",null,"40",-1))];function Ia(a,e,t,r,o,s){var l;return(l=t.factor)!=null&&l.active?(i.openBlock(),i.createElementBlock("div",Na,[i.createElementVNode("div",{class:"legend-bars flex-center",style:i.normalizeStyle([{position:"absolute"},{right:o.right+"px",bottom:t.bottom}])},Ta,4)])):i.createCommentVNode("",!0)}const Da=C(Pa,[["render",Ia],["__scopeId","data-v-67e5094b"]]),Cr="",Va={name:"IdmTemp",props:{factor:{type:Object},viewport:{type:Object},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{program:void 0,context:void 0,texture:void 0,rampColor:void 0,aPositionBuffer:void 0,webgl:new J,etime:void 0,right:10}},watch:{"factor.version":{handler(){var a;(a=this.factor)!=null&&a.active?this.handleRender():this.handleClear()},deep:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{handleRender(){if(!this.viewport)setTimeout(()=>{this.handleRender()},500);else if(this.factor){const a=new Date().valueOf();let e=0,t=0;this.handleDraw(),t=new Date().valueOf()-(a+e),console.log("[water-temp] add elapsed: ",t,", total: ",e+=t)}},handleClear(){this.context=void 0,this.etime=void 0,this.viewport.toggle(!1)},handleSetup(){if(!this.context){this.context=this.viewport.rampColorCanvas.getContext("webgl");const a=[[0,"rgb(149, 137, 211)"],[100/255,"rgb(149, 137, 211)"],[110/255,"rgb(150, 209, 216)"],[120/255,"rgb(129, 204, 197)"],[130/255,"rgb(103, 180, 186)"],[140/255,"rgb(95, 143, 197)"],[150/255,"rgb(80, 140, 62)"],[160/255,"rgb(121, 146, 28)"],[170/255,"rgb(171, 161, 14)"],[180/255,"rgb(223, 177, 6)"],[190/255,"rgb(243, 150, 6)"],[200/255,"rgb(236, 95, 21)"],[210/255,"rgb(190, 65, 18)"],[220/255,"rgb(138, 43, 10)"],[1,"rgb(138, 43, 10)"]];this.rampColor=this.webgl.setup(this.context,a);const{program:e,aPositionBuffer:t}=this.webgl.bind(this.context,I.vertexSchema,I.fragmentSchema);this.program=e,this.aPositionBuffer=t}},async handleDraw(){if(this.handleSetup(),this.etime!==this.factor.etime){this.etime=this.factor.etime;const a=await this.webgl.loadImg(this.factor.raw);this.texture=this.webgl.createTexture(this.context,this.context.NEAREST,this.context.LINEAR,this.context.CLAMP_TO_EDGE,a)}this.webgl.draw(this.viewport,this.context,this.program,this.texture,this.rampColor.texture,this.aPositionBuffer),this.viewport.toggle(!0)}}},Y=a=>(i.pushScopeId("data-v-389ea886"),a=a(),i.popScopeId(),a),Ra={key:0},Ba=[Y(()=>i.createElementVNode("span",null,"°C",-1)),Y(()=>i.createElementVNode("span",null,"-20",-1)),Y(()=>i.createElementVNode("span",null,"-10",-1)),Y(()=>i.createElementVNode("span",null,"0",-1)),Y(()=>i.createElementVNode("span",null,"10",-1)),Y(()=>i.createElementVNode("span",null,"20",-1)),Y(()=>i.createElementVNode("span",null,"30",-1)),Y(()=>i.createElementVNode("span",null,"40",-1))];function $a(a,e,t,r,o,s){var l;return(l=t.factor)!=null&&l.active?(i.openBlock(),i.createElementBlock("div",Ra,[i.createElementVNode("div",{class:"legend-bars flex-center",style:i.normalizeStyle([{position:"absolute"},{right:o.right+"px",bottom:t.bottom}])},Ba,4)])):i.createCommentVNode("",!0)}const Aa=C(Va,[["render",$a],["__scopeId","data-v-389ea886"]]),Dr="",Ma={name:"IdmArctic",props:{factor:{type:Object},viewport:{type:Object},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{program:void 0,context:void 0,texture:void 0,rampColor:void 0,aPositionBuffer:void 0,webgl:new J,etime:void 0,right:10}},watch:{"factor.version":{handler(){var a;(a=this.factor)!=null&&a.active?this.handleRender():this.handleClear()},deep:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{handleRender(){if(!this.viewport)setTimeout(()=>{this.handleRender()},500);else if(this.factor){const a=new Date().valueOf();let e=0,t=0;this.handleDraw(),t=new Date().valueOf()-(a+e),console.log("[water-temp] add elapsed: ",t,", total: ",e+=t)}},handleClear(){this.context=void 0,this.etime=void 0,this.viewport.toggle(!1)},handleSetup(){if(!this.context){this.context=this.viewport.rampColorCanvas.getContext("webgl");const a=[[0,"rgba(76, 165, 228, 0)"],[50/255,"rgba(76, 165, 228, 0)"],[51/255,"rgb(76, 165, 228)"],[102/255,"rgb(129, 204, 197)"],[153/255,"rgb(150, 209, 216)"],[204/255,"rgb(180, 209, 216)"],[1,"rgb(180, 209, 216)"]];this.rampColor=this.webgl.setup(this.context,a);const{program:e,aPositionBuffer:t}=this.webgl.bind(this.context,I.vertexSchema,I.fragmentSchema);this.program=e,this.aPositionBuffer=t}},async handleDraw(){if(this.handleSetup(),this.etime!==this.factor.etime){this.etime=this.factor.etime;const a=await this.webgl.loadImg(this.factor.raw);this.texture=this.webgl.createTexture(this.context,this.context.NEAREST,this.context.LINEAR,this.context.CLAMP_TO_EDGE,a)}this.webgl.draw(this.viewport,this.context,this.program,this.texture,this.rampColor.texture,this.aPositionBuffer),this.viewport.toggle(!0)}}},fe=a=>(i.pushScopeId("data-v-db805141"),a=a(),i.popScopeId(),a),Wa={key:0},Oa=[fe(()=>i.createElementVNode("span",null,"m",-1)),fe(()=>i.createElementVNode("span",null,"0",-1)),fe(()=>i.createElementVNode("span",null,"0.5",-1)),fe(()=>i.createElementVNode("span",null,"1",-1)),fe(()=>i.createElementVNode("span",null,"1.5",-1)),fe(()=>i.createElementVNode("span",null,"2",-1))];function ja(a,e,t,r,o,s){var l;return(l=t.factor)!=null&&l.active?(i.openBlock(),i.createElementBlock("div",Wa,[i.createElementVNode("div",{class:"legend-bars flex-center",style:i.normalizeStyle([{position:"absolute"},{right:o.right+"px",bottom:t.bottom}])},Oa,4)])):i.createCommentVNode("",!0)}const Fa=C(Ma,[["render",ja],["__scopeId","data-v-db805141"]]),Wr="",Ha={name:"IdmPoint",emits:["point","more"],props:{map:{type:Object},show:{type:Boolean},timeZone:{type:Number,default:0},meteo:{type:Object}},data(){return{showMeteo:!1,meteoMarker:void 0,helper:z.CompanyHelper}},watch:{show:{handler(){this.handleBind()},immediate:!0},map:{handler(){this.map&&this.show&&this.handleBind()}},meteo:{handler(){this.meteo?(this.showMeteo=!0,this.handleRender()):this.showMeteo=!1}}},computed:{computeTime(){return function(a){if(a){const e=A(a).utc().utcOffset(this.timeZone),t=this.timeZone<0?this.timeZone:"+"+this.timeZone;return`${e.format("MMM-DD,HHmm")} ( UTC ${t} )`}return"-"}},computeLat(){return function(a,e=4){return E.LngLatHelper.lat2pretty(a,e).pretty}},computeLng(){return function(a,e=4){return E.LngLatHelper.lng2pretty(a,e).pretty}},roundPrecision(){return function(a,e=4){return isNaN(a)?"-":E.LngLatHelper.roundPrecision(a,e)}}},methods:{handleBind(){var a,e;this.show?(a=this.map)==null||a.on("click",this.handleClick):((e=this.map)==null||e.off("click",this.handleClick),this.showMeteo=!1)},handleClick(a){a.originalEvent.stopPropagation();const e=a.originalEvent.target.className;e.indexOf("close")>-1?this.showMeteo=!1:e==="more"?this.$emit("more",this.meteo):this.$emit("point",a.lngLat)},handleRender(){var a;if(this.meteo){const e=document.getElementById("point-meteo");this.meteoMarker?(a=this.meteoMarker)==null||a.setLngLat([this.meteo.lng,this.meteo.lat]):this.meteoMarker=new Z.Marker(e).setLngLat([this.meteo.lng,this.meteo.lat]).addTo(this.map)}}}},O=a=>(i.pushScopeId("data-v-97102c3b"),a=a(),i.popScopeId(),a),Ua={id:"point-meteo",class:"point-meteo"},Za={class:"meteo-box"},Ga={class:"header-box"},Ja={class:"main"},Xa={class:"sub"},qa={class:"main-box"},Ya={class:"flex-space"},Qa=O(()=>i.createElementVNode("label",null,"Wind",-1)),Ka={class:"flex-space"},ei=O(()=>i.createElementVNode("label",null,"Wind.Wave",-1)),ti={class:"flex-space"},ai=O(()=>i.createElementVNode("label",null,"Swell",-1)),ii={class:"flex-space"},oi=O(()=>i.createElementVNode("label",null,"Sig.Wave",-1)),ri={class:"flex-space"},si=O(()=>i.createElementVNode("label",null,"Current",-1)),ni={class:"flex-space"},li=O(()=>i.createElementVNode("label",null,"Precip",-1)),ci={class:"flex-space"},hi=O(()=>i.createElementVNode("label",null,"Visibility",-1)),di={class:"flex-space"},pi=O(()=>i.createElementVNode("label",null,"Temp",-1)),mi={class:"flex-space"},yi=O(()=>i.createElementVNode("label",null,"Water Temp",-1)),fi={key:0,class:"flex-space",style:{"justify-content":"flex-end"}},ui=[O(()=>i.createElementVNode("span",{class:"more"},"More >>",-1))];function gi(a,e,t,r,o,s){var l,n,c,h,d,p,u,m,b,f,y,_,g,w,v,L,N,T,D,R,B,M,ie,oe,re,se,ne,le,ce,Q,W,j,he,F,S,$,de,H,pe,K,ee,te,ue,ge,be,_e,Le;return i.withDirectives((i.openBlock(),i.createElementBlock("div",Ua,[i.createElementVNode("div",Za,[i.createElementVNode("div",Ga,[i.createElementVNode("div",{class:"iconfont close",onClick:e[0]||(e[0]=ke=>o.showMeteo=!1)},""),i.createElementVNode("div",Ja,i.toDisplayString(s.computeLat((l=t.meteo)==null?void 0:l.lat))+","+i.toDisplayString(s.computeLng((n=t.meteo)==null?void 0:n.lng)),1),i.createElementVNode("div",Xa,i.toDisplayString(s.computeTime((c=t.meteo)==null?void 0:c.utc)),1)]),i.createElementVNode("div",qa,[i.createElementVNode("div",Ya,[Qa,i.createElementVNode("span",null,i.toDisplayString(((d=(h=t.meteo)==null?void 0:h.wind)==null?void 0:d.direction)||"-")+"/"+i.toDisplayString(s.roundPrecision((u=(p=t.meteo)==null?void 0:p.wind)==null?void 0:u.kts,1))+"[kts]/"+i.toDisplayString((b=(m=t.meteo)==null?void 0:m.wind)==null?void 0:b.scale)+"[BF]/"+i.toDisplayString(s.roundPrecision((y=(f=t.meteo)==null?void 0:f.gusts)==null?void 0:y.kts,1))+"[kts]",1)]),i.createElementVNode("div",Ka,[ei,i.createElementVNode("span",null,i.toDisplayString(((w=(g=(_=t.meteo)==null?void 0:_.wave)==null?void 0:g.wd)==null?void 0:w.direction)||"-")+"/"+i.toDisplayString(s.roundPrecision((N=(L=(v=t.meteo)==null?void 0:v.wave)==null?void 0:L.wd)==null?void 0:N.height,1))+"[m]/"+i.toDisplayString(s.roundPrecision((R=(D=(T=t.meteo)==null?void 0:T.wave)==null?void 0:D.wd)==null?void 0:R.period,1))+"[s]",1)]),i.createElementVNode("div",ti,[ai,i.createElementVNode("span",null,i.toDisplayString(((ie=(M=(B=t.meteo)==null?void 0:B.wave)==null?void 0:M.swell)==null?void 0:ie.direction)||"-")+"/"+i.toDisplayString(s.roundPrecision((se=(re=(oe=t.meteo)==null?void 0:oe.wave)==null?void 0:re.swell)==null?void 0:se.height,1))+"[m]/"+i.toDisplayString(s.roundPrecision((ce=(le=(ne=t.meteo)==null?void 0:ne.wave)==null?void 0:le.swell)==null?void 0:ce.period,1))+"[s]",1)]),i.createElementVNode("div",ii,[oi,i.createElementVNode("span",null,i.toDisplayString(((j=(W=(Q=t.meteo)==null?void 0:Q.wave)==null?void 0:W.sig)==null?void 0:j.direction)||"-")+"/"+i.toDisplayString(s.roundPrecision((S=(F=(he=t.meteo)==null?void 0:he.wave)==null?void 0:F.sig)==null?void 0:S.height,1))+"[m]/"+i.toDisplayString(s.roundPrecision((H=(de=($=t.meteo)==null?void 0:$.wave)==null?void 0:de.sig)==null?void 0:H.period,1))+"[s]",1)]),i.createElementVNode("div",ri,[si,i.createElementVNode("span",null,i.toDisplayString(((K=(pe=t.meteo)==null?void 0:pe.current)==null?void 0:K.direction)||"-")+"/"+i.toDisplayString(s.roundPrecision((te=(ee=t.meteo)==null?void 0:ee.current)==null?void 0:te.kts,2))+"[kts]",1)]),i.createElementVNode("div",ni,[li,i.createElementVNode("span",null,i.toDisplayString(s.roundPrecision((ge=(ue=t.meteo)==null?void 0:ue.precip)==null?void 0:ge.inter6h,2))+"[mm]",1)]),i.createElementVNode("div",ci,[hi,i.createElementVNode("span",null,i.toDisplayString(s.roundPrecision(((be=t.meteo)==null?void 0:be.visibility)/1852,0))+"[nm]",1)]),i.createElementVNode("div",di,[pi,i.createElementVNode("span",null,i.toDisplayString(s.roundPrecision((_e=t.meteo)==null?void 0:_e.temp,0))+"[°C]",1)]),i.createElementVNode("div",mi,[yi,i.createElementVNode("span",null,i.toDisplayString(s.roundPrecision((Le=t.meteo)==null?void 0:Le.waterTemp,2))+"[°C]",1)])]),a.$attrs.permission&o.helper.LEVEL.Prime?(i.openBlock(),i.createElementBlock("div",fi,ui)):i.createCommentVNode("",!0)])],512)),[[i.vShow,o.showMeteo]])}const bi=C(Ha,[["render",gi],["__scopeId","data-v-97102c3b"]]),_i={name:"IdmWarZone",props:{map:{type:Object},zone:{type:Object},beforeLayer:{type:String}},data(){return{source:"war-zone-source",zoneLayer:"war-zone-layer",zoneLabelLayer:"war-zone-label-layer"}},watch:{zone:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.zone&&(this.map.addSource(this.source,{type:"geojson",data:this.zone}),this.map.addLayer({id:this.zoneLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-color":"#f44336","fill-opacity":.4}},this.beforeLayer),this.map.addLayer({id:this.zoneLayer+"-border",type:"line",source:this.source,filter:["==","$type","Polygon"],paint:{"line-width":1,"line-opacity":1,"line-color":"#f44336"}},this.beforeLayer),this.map.addLayer({id:this.zoneLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"identify","text-anchor":"top","text-field":"{lbl}","text-rotation-alignment":"viewport","text-size":10,"text-offset":[0,-1]},paint:{"icon-opacity":.8,"text-color":"#000","text-halo-color":"#fff","text-halo-width":1}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.zoneLayer)&&this.map.removeLayer(this.zoneLayer),this.map.getLayer(this.zoneLayer+"-border")&&this.map.removeLayer(this.zoneLayer+"-border"),this.map.getLayer(this.zoneLabelLayer)&&this.map.removeLayer(this.zoneLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function Li(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const wi=C(_i,[["render",Li]]),xi={name:"IdmGmdssArea",props:{map:{type:Object},area:{type:Object},beforeLayer:{type:String}},data(){return{source:"gmdss-area-source",areaLayer:"gmdss-area-layer",areaLabelLayer:"gmdss-area-label-layer"}},watch:{area:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.area&&(this.map.addSource(this.source,{type:"geojson",data:this.area}),this.map.addLayer({id:this.areaLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.5,"fill-color":["match",["get","val"],"AreaI","#EB8996","AreaII","#6F448B","AreaIII","#3E8BD3","AreaIV","#5EBCC4","AreaV","#00AAE7","AreaVI","#9CCE6D","AreaVII","#F4AE00","AreaVIII","#EF9A85","AreaIX","#00AAA7","AreaX","#7AC49F","AreaXI","#DFDFDF","AreaXII","#FFF974","AreaXIII","#EF9A85","AreaXIV","#86A2D1","AreaXV","#EC8972","AreaXVI","#EAC2DA","AreaXVII","#B9C8E7","AreaXVIII","#BBA1C8","AreaXIX","#FAE0BD","AreaXX","#DBECC8","AreaXXI","#D496AF","#ffffff"]}},this.beforeLayer),this.map.addLayer({id:this.areaLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"identify","text-anchor":"top","text-field":"{lbl}","text-rotation-alignment":"viewport","text-size":12,"text-offset":[0,-3.5]},paint:{"icon-opacity":.8,"text-opacity":.8,"text-color":"#000"}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.areaLayer)&&this.map.removeLayer(this.areaLayer),this.map.getLayer(this.areaLabelLayer)&&this.map.removeLayer(this.areaLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function vi(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const Ci=C(xi,[["render",vi]]),Si={name:"IdmEcaZone",props:{map:{type:Object},zone:{type:Object},beforeLayer:{type:String}},data(){return{source:"eca-zone-source",zoneLayer:"eca-zone-layer",zoneLabelLayer:"eca-zone-label-layer"}},watch:{zone:{handler(){this.zone?this.handleRender():this.handleClear()}}},methods:{handleRender(){var a;this.map?(this.handleClear(),this.zone&&(this.map.getSource(this.source)?(a=this.map)==null||a.getSource(this.source).setData(this.zone):(this.map.addSource(this.source,{type:"geojson",data:this.zone}),this.map.addLayer({id:this.zoneLayer,type:"fill",source:this.source,filter:["all",["==","$type","Polygon"],["!=","disabled",!0]],paint:{"fill-outline-color":"silver","fill-opacity":.4,"fill-color":"#05f324"}}),this.map.addLayer({id:this.zoneLayer+"-border",type:"line",source:this.source,filter:["all",["==","$type","Polygon"],["!=","disabled",!0]],paint:{"line-color":"#04c021","line-width":1,"line-opacity":1}},this.beforeLayer),this.map.addLayer({id:this.zoneLabelLayer,type:"symbol",source:this.source,filter:["all",["==","$type","Point"],["!=","disabled",!0]],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"identify","text-max-width":16,"text-justify":"left","text-anchor":"top","text-field":"{lbl}","text-rotation-alignment":"viewport","text-size":10,"text-offset":[0,-3.5]},paint:{"icon-opacity":.8,"text-color":"#000","text-halo-color":"#fff","text-halo-width":1}})))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.zoneLayer)&&this.map.removeLayer(this.zoneLayer),this.map.getLayer(this.zoneLayer+"-border")&&this.map.removeLayer(this.zoneLayer+"-border"),this.map.getLayer(this.zoneLabelLayer)&&this.map.removeLayer(this.zoneLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function ki(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const Ei=C(Si,[["render",ki]]),jr="",zi={name:"IdmAlertZone",props:{map:{type:Object},zone:{type:Object},beforeLayer:{type:String}},data(){return{source:"alert-zone-source",polygonLayer:"alert-zone-polygon-layer",polygonLabelLayer:"alert-zone-polygon-label-layer",lineLayer:"alert-zone-line-layer",lineLabelLayer:"alert-zone-line-label-layer",pointLayer:"alert-zone-point-layer",showZone:!1,form:{}}},watch:{zone:{handler(){var a,e;this.zone?(this.handleRender(),(a=this.map)==null||a.on("click",[this.polygonLabelLayer,this.lineLabelLayer,this.pointLayer],this.handleClick)):(this.handleClear(),(e=this.map)==null||e.off("click",[this.polygonLabelLayer,this.lineLabelLayer,this.pointLayer],this.handleClick))}}},methods:{handleClick(a){var r;const e=a.features[0],t=(r=this.zone)==null?void 0:r.features.filter(o=>{var s;return o.properties.id===((s=e==null?void 0:e.properties)==null?void 0:s.id)})[0];t&&(this.showZone=!0,this.form={...t.properties})},handleRender(){var a;this.map?(this.handleClear(),this.zone&&(this.map.getSource(this.source)?(a=this.map)==null||a.getSource(this.source).setData(this.zone):(this.map.addSource(this.source,{type:"geojson",data:this.zone}),this.map.addLayer({id:this.polygonLayer,type:"fill",source:this.source,filter:["all",["==","$type","Polygon"],["!=","disabled",!0]],paint:{"fill-outline-color":"#d57d02","fill-opacity":.4,"fill-color":"#d57d02"}}),this.map.addLayer({id:this.polygonLayer+"-border",type:"line",source:this.source,filter:["all",["==","$type","Polygon"],["!=","disabled",!0]],paint:{"line-width":1,"line-color":"#d57d02"}}),this.map.addLayer({id:this.lineLayer,type:"line",source:this.source,filter:["all",["==","$type","LineString"],["!=","disabled",!0]],paint:{"line-color":"#d57d02","line-width":2}}),this.map.addLayer({id:this.polygonLabelLayer,type:"symbol",source:this.source,filter:["all",["==","$type","Polygon"],["!=","disabled",!0]],layout:{"symbol-placement":"point","icon-image":"alert","icon-size":.1,"icon-allow-overlap":!0,"icon-rotation-alignment":"viewport"},paint:{"icon-opacity":.8}}),this.map.addLayer({id:this.lineLabelLayer,type:"symbol",source:this.source,filter:["all",["==","$type","LineString"],["!=","disabled",!0]],layout:{"symbol-placement":"line-center","icon-image":"alert","icon-size":.1,"icon-allow-overlap":!0,"icon-rotation-alignment":"viewport"},paint:{"icon-opacity":.8}}),this.map.addLayer({id:this.pointLayer,type:"symbol",source:this.source,filter:["all",["==","$type","Point"],["!=","disabled",!0]],layout:{"symbol-placement":"point","icon-image":"alert","icon-size":.1},paint:{"icon-opacity":.8}})))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.polygonLayer)&&this.map.removeLayer(this.polygonLayer),this.map.getLayer(this.polygonLayer+"-border")&&this.map.removeLayer(this.polygonLayer+"-border"),this.map.getLayer(this.polygonLabelLayer)&&this.map.removeLayer(this.polygonLabelLayer),this.map.getLayer(this.lineLayer)&&this.map.removeLayer(this.lineLayer),this.map.getLayer(this.lineLabelLayer)&&this.map.removeLayer(this.lineLabelLayer),this.map.getLayer(this.pointLayer)&&this.map.removeLayer(this.pointLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}},Pi={id:"zone-info"},Ni=["innerHTML"];function Ti(a,e,t,r,o,s){var l;return i.withDirectives((i.openBlock(),i.createElementBlock("div",Pi,[i.createElementVNode("div",{class:"iconfont close",onClick:e[0]||(e[0]=n=>o.showZone=!1)},""),i.createElementVNode("div",{class:"rich-context",innerHTML:(l=o.form)==null?void 0:l.name},null,8,Ni)],512)),[[i.vShow,o.showZone]])}const Ii=C(zi,[["render",Ti],["__scopeId","data-v-c0864afc"]]),Fr="",Di={name:"IdmPort",props:{map:{type:Object},port:{type:Object},beforeLayer:{type:String}},emits:["port"],data(){return{source:"port-source",layer:"port-layer",showPort:!1,form:{},marker:void 0}},computed:{computeLat(){return function(a){return E.LngLatHelper.lat2pretty(a,4).pretty}},computeLng(){return function(a){return E.LngLatHelper.lng2pretty(a,4).pretty}}},watch:{port:{handler(){var a,e;this.port?(this.handleRender(),(a=this.map)==null||a.on("click",[this.layer],this.handleClick)):(this.handleClear(),(e=this.map)==null||e.off("click",[this.layer],this.handleClick))}}},methods:{handleClick(a){var r;const e=a.features[0],t=(r=this.port)==null?void 0:r.features.filter(o=>{var s;return o.properties.id===((s=e==null?void 0:e.properties)==null?void 0:s.id)})[0];if(t){this.showPort=!0,this.form={...t.properties},this.form.lng=t.geometry.coordinates[0],this.form.lat=t.geometry.coordinates[1];const o=document.getElementById("port-info");this.marker?this.marker.setLngLat([a.lngLat.lng,a.lngLat.lat]):this.marker=new Z.Marker(o).setLngLat([a.lngLat.lng,a.lngLat.lat]).setOffset([0,-85]).addTo(this.map)}},handleEmit(){this.$emit("port",this.form)},handleRender(){var a;this.map?this.port&&(this.map.getSource(this.source)?(a=this.map)==null||a.getSource(this.source).setData(this.port):(this.map.addSource(this.source,{type:"geojson",data:this.port}),this.map.addLayer({id:this.layer,type:"symbol",source:this.source,filter:["all",["==","$type","Point"],["!=","disabled",!0]],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"port","text-anchor":"left","text-field":"{name}","text-rotation-alignment":"viewport","text-size":10,"text-offset":[1,0]},paint:{"text-color":"rgba(0, 0, 0, 0.8)","text-halo-color":"#fff","text-halo-width":1}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.showPort=!1,this.map.getLayer(this.layer)&&this.map.removeLayer(this.layer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}},xe=a=>(i.pushScopeId("data-v-4ab013cc"),a=a(),i.popScopeId(),a),Vi={id:"port-info"},Ri={class:"port-box"},Bi={class:"flex-start"},$i=xe(()=>i.createElementVNode("label",null,"Name : ",-1)),Ai={class:"flex-start"},Mi=xe(()=>i.createElementVNode("label",null,"Position : ",-1)),Wi={class:"flex-start"},Oi=xe(()=>i.createElementVNode("label",null,"LoCode : ",-1)),ji={class:"flex-start",style:{"align-items":"flex-start"}},Fi=xe(()=>i.createElementVNode("label",null,"Region : ",-1));function Hi(a,e,t,r,o,s){return i.withDirectives((i.openBlock(),i.createElementBlock("div",Vi,[i.createElementVNode("div",{class:"close iconfont",onClick:e[0]||(e[0]=l=>o.showPort=!1)},""),i.createElementVNode("div",Ri,[i.createElementVNode("div",Bi,[$i,i.createElementVNode("span",{onClick:e[1]||(e[1]=(...l)=>s.handleEmit&&s.handleEmit(...l))},i.toDisplayString(o.form.name),1)]),i.createElementVNode("div",Ai,[Mi,i.createElementVNode("span",null,i.toDisplayString(s.computeLat(o.form.lat))+", "+i.toDisplayString(s.computeLng(o.form.lng)),1)]),i.createElementVNode("div",Wi,[Oi,i.createElementVNode("span",null,i.toDisplayString(o.form.loCode||"-"),1)]),i.createElementVNode("div",ji,[Fi,i.createElementVNode("span",null,i.toDisplayString(o.form.city||"-")+", "+i.toDisplayString(o.form.country||"-"),1)])])],512)),[[i.vShow,o.showPort]])}const Ui=C(Di,[["render",Hi],["__scopeId","data-v-4ab013cc"]]),Zi={name:"IdmLoadLine",props:{map:{type:Object},line:{type:Object},beforeLayer:{type:String}},data(){return{source:"load-line-source",lineLayer:"load-line-layer",lineLabelLayer:"load-line-label-layer"}},watch:{line:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.line&&(this.map.addSource(this.source,{type:"geojson",data:this.line}),this.map.addLayer({id:this.lineLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.75,"fill-color":["match",["get","val"],"LLGreen","#A0C0C0","LLRed","#F5A39D","LLBlue","#6B94E4","#ffffff"]}},this.beforeLayer),this.map.addLayer({id:this.lineLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","text-field":"{lbl} (Length < {shipLength}, {start} - {end})","text-rotation-alignment":"viewport","text-offset":[0,1],"text-size":10,"text-allow-overlap":!0},paint:{"text-opacity":.8}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.lineLayer)&&this.map.removeLayer(this.lineLayer),this.map.getLayer(this.lineLabelLayer)&&this.map.removeLayer(this.lineLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function Gi(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const Ji=C(Zi,[["render",Gi]]),Xi={name:"IdmTimezone",props:{map:{type:Object},zone:{type:Object},beforeLayer:{type:String}},data(){return{source:"time-zone-source",zoneLayer:"time-zone-layer",zoneLabelLayer:"time-zone-label-layer"}},watch:{zone:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.zone&&(this.map.addSource(this.source,{type:"geojson",data:this.zone}),this.map.addLayer({id:this.zoneLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.5,"fill-color":["match",["get","offSet"],"-11.5","rgba(255,0,0,0.4)","-11","rgba(0,255,0,0.3)","-10.5","rgba(0,255,0,0.3)","-10","rgba(0,0,255,0.3)","-9.5","rgba(0,0,255,0.3)","-9","rgba(255,0,0,0.4)","-8.5","rgba(255,0,0,0.4)","-8","rgba(0,255,0,0.3)","-7.5","rgba(0,255,0,0.3)","-7","rgba(0,0,255,0.3)","-6.5","rgba(0,0,255,0.3)","-6","rgba(255,0,0,0.4)","-5.5","rgba(255,0,0,0.4)","-5","rgba(0,255,0,0.3)","-4.5","rgba(0,255,0,0.3)","-4","rgba(0,0,255,0.3)","-3.5","rgba(0,0,255,0.3)","-3","rgba(255,0,0,0.4)","-2.5","rgba(255,0,0,0.4)","-2","rgba(0,255,0,0.3)","-1.5","rgba(0,255,0,0.3)","-1","rgba(0,0,255,0.3)","-0.5","rgba(0,0,255,0.3)","+0","rgba(255,0,0,0.4)","+0.5","rgba(255,0,0,0.4)","+1","rgba(0,255,0,0.3)","+1.5","rgba(0,255,0,0.3)","+2","rgba(0,0,255,0.3)","+2.5","rgba(0,0,255,0.3)","+3","rgba(255,0,0,0.4)","+3.5","rgba(255,0,0,0.4)","+4","rgba(0,255,0,0.3)","+4.5","rgba(0,255,0,0.3)","+5","rgba(0,0,255,0.3)","+5.5","rgba(0,0,255,0.3)","+6","rgba(255,0,0,0.4)","+6.5","rgba(255,0,0,0.4)","+7","rgba(0,255,0,0.3)","+7.5","rgba(0,255,0,0.3)","+8","rgba(0,0,255,0.3)","+8.5","rgba(0,0,255,0.3)","+9","rgba(255,0,0,0.4)","+9.5","rgba(255,0,0,0.4)","+10","rgba(0,255,0,0.3)","+10.5","rgba(0,255,0,0.3)","+11","rgba(0,0,255,0.3)","+11.5","rgba(0,0,255,0.3)","rgba(255,0,0,0.4)"]}}),this.map.addLayer({id:this.zoneLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","text-field":"{offSet}","text-rotation-alignment":"viewport","text-size":12,"text-offset":[0,1]},paint:{"text-opacity":.8,"text-color":"#fff"}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.zoneLayer)&&this.map.removeLayer(this.zoneLayer),this.map.getLayer(this.zoneLabelLayer)&&this.map.removeLayer(this.zoneLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function qi(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const Yi=C(Xi,[["render",qi]]),Qi={name:"IdmVoluntaryReportingArea",props:{map:{type:Object},area:{type:Object},beforeLayer:{type:String}},data(){return{source:"vra-source",areaLayer:"vra-layer",areaLabelLayer:"vra-label-layer"}},watch:{area:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.area&&(this.map.addSource(this.source,{type:"geojson",data:this.area}),this.map.addLayer({id:this.areaLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.4,"fill-color":"#9f30f9"}},this.beforeLayer),this.map.addLayer({id:this.areaLayer+"-border",type:"line",source:this.source,filter:["==","$type","Polygon"],paint:{"line-width":1,"line-opacity":1,"line-color":"#9f30f9"}},this.beforeLayer),this.map.addLayer({id:this.areaLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"identify","text-anchor":"top","text-field":"{lbl}","text-rotation-alignment":"viewport","text-size":10,"text-offset":[0,-3.5]},paint:{"icon-opacity":.8,"text-color":"#000","text-halo-color":"#fff","text-halo-width":1}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.areaLayer)&&this.map.removeLayer(this.areaLayer),this.map.getLayer(this.areaLayer+"-border")&&this.map.removeLayer(this.areaLayer+"-border"),this.map.getLayer(this.areaLabelLayer)&&this.map.removeLayer(this.areaLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function Ki(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const eo=C(Qi,[["render",Ki]]),to={name:"IdmSpecialArea",props:{map:{type:Object},area:{type:Object},beforeLayer:{type:String}},data(){return{source:"special-area-source",areaLayer:"special-area-layer",areaLabelLayer:"special-area-label-layer"}},watch:{area:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.area&&(this.area.features.forEach(a=>{a.geometry.type==="Polygon"&&a.geometry.coordinates.forEach(e=>E.LngLatHelper.convertToMonotonicLng2(e))}),this.map.addSource(this.source,{type:"geojson",data:this.area}),this.map.addLayer({id:this.areaLayer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.4,"fill-color":["match",["get","val"],"DefaultStyle","rgb(0,0,0)","JWCriskArea","rgb(0,0,0)","rgb(0,0,0)"]}},this.beforeLayer),this.map.addLayer({id:this.areaLayer+"-border",type:"line",source:this.source,filter:["==","$type","Polygon"],paint:{"line-width":1,"line-opacity":.4,"line-color":"rgb(0,0,0)"}},this.beforeLayer),this.map.addLayer({id:this.areaLabelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","icon-size":.1,"icon-image":"identify","text-anchor":"top","text-field":"{lbl}","text-rotation-alignment":"viewport","text-size":10,"text-offset":[0,-3.5]},paint:{"icon-opacity":.8,"text-color":"#000","text-halo-color":"#fff","text-halo-width":1}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.areaLayer)&&this.map.removeLayer(this.areaLayer),this.map.getLayer(this.areaLayer+"-border")&&this.map.removeLayer(this.areaLayer+"-border"),this.map.getLayer(this.areaLabelLayer)&&this.map.removeLayer(this.areaLabelLayer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function ao(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const io=C(to,[["render",ao]]),oo={name:"IdmTerminator",props:{map:{type:Object},area:{type:Object}},data(){return{source:"terminator-source",layer:"terminator-layer"}},watch:{area:{handler(){this.handleRender()}}},methods:{handleRender(){this.map?(this.handleClear(),this.area&&(this.map.addSource(this.source,{type:"geojson",data:this.area}),this.map.addLayer({id:this.layer,type:"fill",source:this.source,filter:["==","$type","Polygon"],paint:{"fill-outline-color":"silver","fill-opacity":.5,"fill-color":"rgba(0, 0, 0, 0.4)"}}))):setTimeout(()=>{this.handleRender()},500)},handleClear(){this.map.getLayer(this.layer)&&this.map.removeLayer(this.layer),this.map.getSource(this.source)&&this.map.removeSource(this.source)}}};function ro(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const so=C(oo,[["render",ro]]),Hr="",no={name:"IdmLatLng",props:{map:{type:Object},show:{type:Boolean},bottom:{type:String,default:"70px"},toggleVersion:{type:Number}},data(){return{lngLat:void 0,source:"idm-lat-lng-source",layer:"idm-lat-lng-layer",labelLayer:"idm-lat-lng-label-layer",right:10}},watch:{show:{handler(){this.handleBind()},immediate:!0},map:{handler(){var a;this.map&&((a=this.map)==null||a.on("mousemove",this.handleMouseMove))},immediate:!0},toggleVersion:{handler(){var a,e,t;this.right=(((a=document.getElementsByClassName("legend-bars")[0])==null?void 0:a.clientWidth)||-10)+(((e=document.getElementsByClassName("available-layers-show")[0])==null?void 0:e.clientWidth)||0)+(((t=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:t.clientWidth)||0)+20},immediate:!0}},methods:{handleBind(){var a,e;this.show?((a=this.map)==null||a.on("zoomend",this.handleZoomEnd),this.handleRender()):(this.handleClear(),(e=this.map)==null||e.off("zoomend",this.handleZoomEnd))},handleMouseMove(a){const e=a.lngLat,t=E.LngLatHelper.lng2pretty(e.lng,2),r=E.LngLatHelper.lat2pretty(e.lat,2);this.lngLat={lng:t,lat:r}},handleComputeLatLngs(){var r;const a=(r=this.map)==null?void 0:r.getZoom();console.log(a);let e=30;a>4?e=10:a>3&&(e=15);const t=[];for(let o=-60;o<90;o+=e)t.push({type:"Feature",geometry:{type:"LineString",coordinates:[[-180,o],[180,o]]}});for(let o=-180;o<180;o+=e)t.push({type:"Feature",geometry:{type:"LineString",coordinates:[[o,-90],[o,90]]}});for(let o=180;o>-180;o-=e)for(let s=-60;s<90;s+=e)t.push({type:"Feature",geometry:{type:"Point",coordinates:[o,s]},properties:{val:`${s>0?s+" N":s===0?s:s*-1+" S"}, ${o>0?o+" E":o*-1+" W"}`}});return t},handleZoomEnd(){var e;const a=this.handleComputeLatLngs();(e=this.map)==null||e.getSource(this.source).setData(x.featureCollection(a))},handleRender(){if(this.map){const a=this.handleComputeLatLngs();this.map.addSource(this.source,{type:"geojson",data:{type:"FeatureCollection",features:a}}),this.map.addLayer({id:this.layer,type:"line",source:this.source,filter:["==","$type","LineString"],layout:{"line-join":"round","line-cap":"round"},paint:{"line-color":"rgba(0, 0, 0, 0.3)","line-width":1}}),this.map.addLayer({id:this.labelLayer,type:"symbol",source:this.source,filter:["==","$type","Point"],layout:{"symbol-placement":"point","text-field":"{val}","text-rotation-alignment":"viewport","text-offset":[0,1],"text-size":10,"text-allow-overlap":!0},paint:{"text-opacity":.8}})}},handleClear(){var a,e,t,r,o,s;(a=this.map)!=null&&a.getLayer(this.layer)&&((e=this.map)==null||e.removeLayer(this.layer)),(t=this.map)!=null&&t.getLayer(this.labelLayer)&&((r=this.map)==null||r.removeLayer(this.labelLayer)),(o=this.map)!=null&&o.getSource(this.source)&&((s=this.map)==null||s.removeSource(this.source))}}},lo=(a=>(i.pushScopeId("data-v-7367f59b"),a=a(),i.popScopeId(),a))(()=>i.createElementVNode("span",null,", ",-1));function co(a,e,t,r,o,s){return o.lngLat?(i.openBlock(),i.createElementBlock("div",{key:0,class:"lat-lng-tip",style:i.normalizeStyle({right:o.right+"px",bottom:t.bottom})},[i.createElementVNode("span",null,i.toDisplayString(o.lngLat.lat.pretty),1),lo,i.createElementVNode("span",null,i.toDisplayString(o.lngLat.lng.pretty),1)],4)):i.createCommentVNode("",!0)}const Se=C(no,[["render",co],["__scopeId","data-v-7367f59b"]]),ho={name:"IdmMeasure",props:{map:{type:Object},show:{type:Boolean}},data(){return{geojson:[],source:"measure-source",layer:"measure-layer",labelLayer:"measure-label-layer",tmpSource:"measure-tmp-source",tmpLayer:"measure-tmp-layer",tmpLabelLayer:"measure-tmp-label-layer",closeMarkers:{},pointMarkers:{},tipMarker:void 0,contextmenu:void 0,navigation:"RL"}},watch:{show:{handler(){this.handleBind()},immediate:!0},map:{handler(){this.map&&this.handleBind()}}},methods:{handleBind(){var a,e,t,r,o,s,l,n,c,h;if(this.show)(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),(o=this.map)==null||o.on("contextmenu",this.handleContextmenu),this.map&&(this.map.getCanvas().style.cursor="crosshair");else{(s=this.map)==null||s.getCanvas().removeEventListener("keydown",this.handleKeydown),(l=this.map)==null||l.off("mousemove",this.handleMove),(n=this.map)==null||n.off("dblclick",this.handleDblClick),(c=this.map)==null||c.off("click",this.handleClick),(h=this.map)==null||h.off("contextmenu",this.handleContextmenu);for(const d of this.geojson)this.handleClear(d,!0);this.geojson=[],this.map&&(this.map.getCanvas().style.cursor="grab")}},handleKeydown(a){if(a.key==="Shift"){this.navigation=this.navigation==="RL"?"GC":"RL";const t=this.geojson.at(-1).features.filter(r=>r.geometry.type==="Point");t.length&&(t.at(-1).properties.mode=this.navigation)}},handleDrag(a){var t,r,o,s,l,n,c,h,d,p;const e=(r=(t=a.target)==null?void 0:t._element)==null?void 0:r.id;if((e==null?void 0:e.split("-").length)===2){const u=this.geojson.filter(y=>y.id===e.split("-")[0])[0];this.pointMarkers[u.id].filter(y=>{var _;return((_=y._element)==null?void 0:_.id)===e})[0].setLngLat([(s=(o=a.target)==null?void 0:o._lngLat)==null?void 0:s.lng,(n=(l=a.target)==null?void 0:l._lngLat)==null?void 0:n.lat]);let b;u.features.forEach((y,_)=>{if(y.geometry.type==="Point"&&y.properties.id==e.split("-")[1]){b=_;return}});const f=u.features.filter(y=>y.geometry.type==="Point");this.handleTmpPointUpdate(u,f[b-1],{lng:(h=(c=a.target)==null?void 0:c._lngLat)==null?void 0:h.lng,lat:(p=(d=a.target)==null?void 0:d._lngLat)==null?void 0:p.lat,properties:f[b].properties},b===f.length-1?void 0:f[b+1])}},handleDragEnd(a){var t,r,o,s,l,n,c,h,d,p;const e=(r=(t=a.target)==null?void 0:t._element)==null?void 0:r.id;if((e==null?void 0:e.split("-").length)===2){const u=this.geojson.filter(f=>f.id===e.split("-")[0])[0];this.pointMarkers[u.id].filter(f=>{var y;return((y=f._element)==null?void 0:y.id)===e})[0].setLngLat([(s=(o=a.target)==null?void 0:o._lngLat)==null?void 0:s.lng,(n=(l=a.target)==null?void 0:l._lngLat)==null?void 0:n.lat]);const b=u.features.filter(f=>f.geometry.type==="Point"&&f.properties.id==e.split("-")[1])[0];b.geometry.coordinates=[(h=(c=a.target)==null?void 0:c._lngLat)==null?void 0:h.lng,(p=(d=a.target)==null?void 0:d._lngLat)==null?void 0:p.lat],u.features=u.features.filter(f=>f.geometry.type==="Point"),this.handlePointUpdate(u)}},handleContextmenu(a){var t,r,o,s;a.preventDefault(),(t=this.contextmenu)==null||t.remove();const e=(s=(o=(r=a.originalEvent)==null?void 0:r.target)==null?void 0:o.parentElement)==null?void 0:s.id;if((e==null?void 0:e.split("-").length)===2){const n=this.geojson.filter(c=>c.id===e.split("-")[0])[0].features.filter(c=>c.geometry.type==="Point");if(n.length>2&&n.filter(h=>h.properties.id===(e==null?void 0:e.split("-")[1]))[0]){const h=document.createElement("div");h.className="point-contextmenu-marker",h.innerHTML=`<span id="del-${e}" class="del-point">Del</span>`,this.contextmenu=new Z.Marker(h).setOffset([24,0]).setLngLat([a.lngLat.lng,a.lngLat.lat]).addTo(this.map)}}},handleClick(a){var t,r,o,s,l;(t=this.contextmenu)==null||t.remove();const e=a.originalEvent.target.className;if(e==="marker-close"){const n=(o=(r=a.originalEvent)==null?void 0:r.srcElement)==null?void 0:o.id,c=this.geojson.filter(h=>h.id===n)[0];c&&this.handleClear(c,!0),this.geojson=this.geojson.filter(h=>h.id!==n)}else if(e==="del-point"){const n=(l=(s=a.originalEvent.target.id)==null?void 0:s.replace("del-",""))==null?void 0:l.split("-"),c=this.geojson.filter(h=>h.id===n[0])[0];c.features=c.features.filter(h=>h.geometry.type==="Point"&&h.properties.id!==n[1]),this.handlePointUpdate(c)}else if(e!=="marker-label"){let n=this.geojson.at(-1);n||(n=x.featureCollection([],{id:new Date().getTime().toString()}),this.geojson.push(n)),n.features=n.features.filter(h=>h.geometry.type==="Point");const c=x.feature({type:"Point",coordinates:[a.lngLat.lng,a.lngLat.lat]},{id:new Date().getTime().toString(),mode:this.navigation});n.features.push(c),this.handlePointUpdate(n)}},handlePointUpdate(a){const e=a.features;if(e.length>1){let t=0;const r=[];for(let o=1;o<e.length;o++){const s=e[o-1],l=e[o],n=s.properties,c={lng:s.geometry.coordinates[0],lat:s.geometry.coordinates[1]},h={lng:l.geometry.coordinates[0],lat:l.geometry.coordinates[1]},d=E.LaneHelper.calculateDistance(c,h,n.mode==="RL",2),p=E.LaneHelper.calculateBearing(c,h,n.mode==="RL",2);t=E.LngLatHelper.roundPrecision(t+d,2);let u;n.mode==="RL"?u=E.LngLatHelper.convertToMonotonicLng([c,h]):u=E.LngLatHelper.convertToMonotonicLng(E.LaneHelper.interpolateCoordinates(c,h,200));const m=x.lineString(u.map(b=>[b.lng,b.lat]));m.properties.dist=d,m.properties.bearing=p,m.properties.total=t,r.push(m)}e.push(...r),a.total=t}return this.handleRender(a),a},handleTmpPointUpdate(a,e,t,r){const o=x.featureCollection([]);let s,l;if(e){const c=e.properties,h={lng:e.geometry.coordinates[0],lat:e.geometry.coordinates[1]},d={lng:t.lng,lat:t.lat};s=E.LaneHelper.calculateDistance(h,d,c.mode==="RL",2),l=E.LaneHelper.calculateBearing(h,d,c.mode==="RL",2);let p;c.mode==="RL"?p=E.LngLatHelper.convertToMonotonicLng([h,d]):p=E.LngLatHelper.convertToMonotonicLng(E.LaneHelper.interpolateCoordinates(h,d,200));const u=x.lineString(p.map(m=>[m.lng,m.lat]));u.properties.dist=s,u.properties.bearing=l,o.features.push(u)}if(r){const c=t.properties,h=t,d={lng:r.geometry.coordinates[0],lat:r.geometry.coordinates[1]};s=E.LaneHelper.calculateDistance(h,d,c.mode==="RL",2),l=E.LaneHelper.calculateBearing(h,d,c.mode==="RL",2);let p;c.mode==="RL"?p=E.LngLatHelper.convertToMonotonicLng([h,d]):p=E.LngLatHelper.convertToMonotonicLng(E.LaneHelper.interpolateCoordinates(h,d,200));const u=x.lineString(p.map(m=>[m.lng,m.lat]));u.properties.dist=s,u.properties.bearing=l,o.features.push(u)}this.map.getSource(this.tmpSource)?this.map.getSource(this.tmpSource).setData(o):this.map.addSource(this.tmpSource,{type:"geojson",data:o}),this.map.getLayer(this.tmpLayer)||this.map.addLayer({id:this.tmpLayer,type:"line",source:this.tmpSource,filter:["==","$type","LineString"],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#F44336","line-width":2,"line-opacity":1,"line-dasharray":[3,2]}}),this.map.getLayer(this.tmpLabelLayer)||this.map.addLayer({id:this.tmpLabelLayer,type:"symbol",source:this.tmpSource,filter:["==","$type","LineString"],layout:{"symbol-placement":"line-center","text-field":"{dist} nm","text-rotation-alignment":"map","text-size":12},paint:{"text-opacity":1,"text-color":"#fff","text-halo-color":"#F44336","text-halo-width":4,"text-halo-blur":0}});let n;if(r?n='<div class="marker-label">Drag and drop</div>':n=`<div class="marker-label">Tol distance: <b>${E.LngLatHelper.roundPrecision((a.total??0)+s,2)}</b>nm, bearing: <b>${l}</b>°</div><div class="marker-label">${this.navigation==="RL"?"RL":"GC"} mode, using 'Shift' to switch</div><div class="marker-label">Double click to end</div>`,this.tipMarker)this.tipMarker._element.innerHTML=n,this.tipMarker.setLngLat([t.lng,t.lat]);else{const c=document.createElement("div");c.className="tip-marker",c.innerHTML=n,this.tipMarker=new Z.Marker(c).setOffset([140,0]).setLngLat([t.lng,t.lat]).addTo(this.map)}},handleMove(a){this.map.getCanvas().style.cursor="crosshair";let e=this.geojson.at(-1);e||(e=x.featureCollection([],{id:new Date().getTime().toString()}),this.geojson.push(e));const t=e.features.filter(r=>r.geometry.type==="Point");t!=null&&t.length&&this.handleTmpPointUpdate(e,t.at(-1),{lng:a.lngLat.lng,lat:a.lngLat.lat})},handleDblClick(a){a.preventDefault();let e=this.geojson.at(-1);e.closed=!0,this.handleRender(e),e=x.featureCollection([],{id:new Date().getTime().toString()}),this.geojson.push(e)},handleRender(a){var e;if((e=a==null?void 0:a.features)!=null&&e.length){const t=`${a.id}-${this.source}`,r=`${a.id}-${this.layer}`,o=`${a.id}-${this.labelLayer}`;this.map.getSource(t)?this.map.getSource(t).setData(a):this.map.addSource(t,{type:"geojson",data:a}),this.handleClear(a,!1),this.map.addLayer({id:r,type:"line",source:t,filter:["==","$type","LineString"],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#F44336","line-width":2}}),this.map.addLayer({id:o,type:"symbol",source:t,filter:["==","$type","LineString"],layout:{"symbol-placement":"line-center","text-field":"{dist}nm,{bearing}°","text-rotation-alignment":"map","text-size":12},paint:{"text-opacity":1,"text-color":"#fff","text-halo-color":"#F44336","text-halo-width":4,"text-halo-blur":0}});const s=a.features.filter(l=>l.geometry.type==="Point");for(const l of s){const n=document.createElement("div");n.id=`${a.id}-${l.properties.id}`,n.className=`${a.closed?"point-marker closed":"point-marker"}`,n.innerHTML='<div class="marker-circle"></div>';const c=new Z.Marker({element:n,draggable:!0,contextmenu:!0}).setLngLat(l.geometry.coordinates).addTo(this.map);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]}if(a.closed){const l=s.at(-1),c=a.features.filter(d=>d.geometry.type==="LineString").at(-1),h=document.createElement("div");h.className="point-summary-marker",h.innerHTML=`<div id="${a.id}" class="marker-close">×</div><div class="marker-label">Tol: ${c.properties.total}nm</div>`,this.closeMarkers[a.id]=new Z.Marker(h).setOffset([60,0]).setLngLat(l.geometry.coordinates).addTo(this.map)}}},handleClear(a,e=!0){var s,l,n,c,h,d,p,u,m;const t=`${a.id}-${this.source}`,r=`${a.id}-${this.layer}`,o=`${a.id}-${this.labelLayer}`;(s=this.map)!=null&&s.getLayer(r)&&this.map.removeLayer(r),(l=this.map)!=null&&l.getLayer(o)&&this.map.removeLayer(o),(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),(h=this.closeMarkers[a.id])==null||h.remove(),this.closeMarkers[a.id]=void 0,(d=this.pointMarkers[a.id])==null||d.forEach(b=>{b==null||b.remove()}),this.pointMarkers[a.id]=[],(p=this.tipMarker)==null||p.remove(),this.tipMarker=void 0,e&&((u=this.map)!=null&&u.getSource(t))&&this.map.removeSource(t),e&&((m=this.map)!=null&&m.getSource(this.tmpSource))&&this.map.removeSource(this.tmpSource)}}};function po(a,e,t,r,o,s){return i.openBlock(),i.createElementBlock("div")}const mo=C(ho,[["render",po]]),Zr="",yo={name:"IdmENC",props:{map:{type:Object},enabled:{type:Boolean},beforeLayer:{type:String,default:"grayland"},bottom:{type:String,default:"260px"},token:{type:String,default:""},toggleVersion:{type:Number},permission:{type:Number}},emits:["enc"],data(){return{helper:z.CompanyHelper,vendor:this.$attrs.permission&z.CompanyHelper.LEVEL.Supper?"hi":"i4",right:10}},watch:{vendor:{handler(){this.$emit("enc",this.vendor)},immediate:!0},toggleVersion:{handler(){var a,e;this.right=(((a=document.getElementsByClassName("available-layers-show")[0])==null?void 0:a.clientWidth)||0)+(((e=document.getElementsByClassName("fleet-list-container")[0])==null?void 0:e.clientWidth)||0)+10},immediate:!0}},methods:{}},ze=a=>(i.pushScopeId("data-v-ab627b83"),a=a(),i.popScopeId(),a),fo={key:0},uo={class:"bar-item"},go=[ze(()=>i.createElementVNode("span",{class:"iconfont"},"HI",-1))],bo=[ze(()=>i.createElementVNode("span",{class:"iconfont"},"I4",-1))];function _o(a,e,t,r,o,s){return t.enabled&&t.permission&o.helper.LEVEL.Supper?(i.openBlock(),i.createElementBlock("div",fo,[i.createElementVNode("div",{class:"menu-bar-box",style:i.normalizeStyle({position:"absolute",right:o.right+"px",bottom:t.bottom})},[i.createElementVNode("div",uo,[i.createElementVNode("div",{class:i.normalizeClass(o.vendor==="hi"?"menu-icon active":"menu-icon"),onClick:e[0]||(e[0]=l=>o.vendor="hi")},go,2),i.createElementVNode("div",{class:i.normalizeClass(o.vendor==="i4"?"menu-icon active":"menu-icon"),onClick:e[1]||(e[1]=l=>o.vendor="i4")},bo,2)])],4)])):i.createCommentVNode("",!0)}const Lo=C(yo,[["render",_o],["__scopeId","data-v-ab627b83"]]),Xr="",wo={name:"IdmGLV2",components:{IdmGlLayer:mt,IdmWindBarb:wt,IdmWindParticle:kt,IdmCurrents:Vt,IdmCurrentParticle:Mt,IdmSigWave:jt,IdmSwell:Ut,IdmPrmsl:Jt,IdmIceberg:Yt,IdmTropicals:Ce,IdmPrecip3h:va,IdmVisibility:za,IdmWaterTemp:Da,IdmTemp:Aa,IdmArctic:Fa,IdmWarZone:wi,IdmGmdssArea:Ci,IdmEcaZone:Ei,IdmAlertZone:Ii,IdmPort:Ui,IdmLoadLine:Ji,IdmTimezone:Yi,IdmVRA:eo,IdmSpecialArea:io,IdmTerminator:so,IdmLatLng:Se,IdmMeasure:mo,IdmPoint:bi,IdmENC:Lo},props:{map:{type:Object,default:void 0},token:{type:String},ts:{type:String},beforeLayer:{type:String,default:""}},data(){return{weatherLayers:{},activeWeatherLayers:[],weatherWeight:0,otherLayers:{},otherWeight:0,showCoord:!1,showMeasure:!1,showPoint:!1,show3d:!1,meteo:void 0,source:"",gateway:"https://cbe.idmwx.com",mapProjection:"mercator",zoom:6,viewport:void 0,particleFactor:void 0,showRampColor:!1,activeWindLayer:!1,showWindParticle:!1,showCurrentParticle:!1,toggleVersion:0,enc:"",defaultMeteoToken:"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6ImNseTVudHJzYzAwNWUwbHBsZHkyaDRqczMiLCJyb2xlIjoxLCJuYW1lIjoiZmFrZUBvcm13eC5jb20iLCJwbGF0SWQiOiJnZDBtdDFkIiwiY29tcGFueSI6eyJpZCI6bnVsbCwiY2hpbGRyZW4iOltdfSwiaWF0IjoxNzIzMDI0MDI0LCJleHAiOjM5MzA1NDQwMjR9.RrKcdcMnq-FxBLJQ-i6lx2FscDE46y8EvHIemPW4HTg",helper:new Ee}},watch:{ts:{handler(a,e){a&&e&&A(a).utc().format("yyyy-MM-DD HH")!==A(e).utc().format("yyyy-MM-DD HH")&&this.$nextTick(()=>{this.handleDateChange({tropicals:!1})})},immediate:!0},map:{handler(){this.map&&(this.map.on("zoomend",this.handleDragEndWithZoom4Json),this.map.on("dragend",this.handleDragEndWithZoom4Json),this.map.on("move",this.handleDragEndWithZoom4Image),this.viewport=new we(this.map),this.handleRampColorInitial())},immediate:!0},enc:{handler(a,e){var t,r,o,s,l,n,c,h;a?((r=(t=this.map)==null?void 0:t.getLayer(a))==null||r.setLayoutProperty("visibility","visible"),(s=(o=this.map)==null?void 0:o.getLayer(e))==null||s.setLayoutProperty("visibility","none")):((n=(l=this.map)==null?void 0:l.getLayer("i4"))==null||n.setLayoutProperty("visibility","none"),(h=(c=this.map)==null?void 0:c.getLayer("hi"))==null||h.setLayoutProperty("visibility","none"))}},activeWeatherLayers:{handler(){var a,e,t,r,o,s,l,n,c,h,d,p,u,m,b,f,y,_;if(!this.map)return!1;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"),(s=this.map)!=null&&s.getLayer((o=this.viewport)==null?void 0:o.rampColorLayer)&&((l=this.map)!=null&&l.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)),(d=this.map)!=null&&d.getLayer((h=this.viewport)==null?void 0:h.particleLayer)&&((p=this.map)!=null&&p.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id))&&this.mapProjection==="mercator"&&((m=this.map)==null||m.moveLayer((u=this.viewport)==null?void 0:u.particleLayer,this.helper.mapboxCustomer.layers.countryBoundary.id))):((f=(b=this.map)==null?void 0:b.getLayer(this.enc))==null||f.setLayoutProperty("visibility","visible"),(_=(y=this.map)==null?void 0:y.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id))==null||_.setLayoutProperty("visibility","none"))},immediate:!0}},methods:{async fetchWeatherLayers(a={tropicals:!1}){var o,s,l,n,c,h,d,p;const e=new Date().valueOf();let t=0,r=0;if(this.map){const u=((o=this.map)==null?void 0:o.getZoom())+1,m=(s=this.map)==null?void 0:s.getBounds(),b=`${m._sw.lng},${m._sw.lat},${m._ne.lng},${m._ne.lat}`;if(this.handleRampColorState(),this.particleFactor){const f=z.LayerHelper.WEATHER_LAYERS.find(y=>{var _;return((_=y.peer)==null?void 0:_.weight)===this.particleFactor.weight});this.particleFactor.particle?this.weatherWeight=this.weatherWeight&f.weight?this.weatherWeight:this.weatherWeight+f.weight:this.weatherWeight=this.weatherWeight&f.weight?this.weatherWeight-f.weight:this.weatherWeight}if(this.weatherWeight>0){let f=this.weatherWeight,y;if(a.tropicals||this.weatherWeight&256&&(y=this.weatherLayers.tropicals,y&&(f-=256,y.version=Math.random()+1)),f>0){const _=await G.get(`${this.gateway}/api/arc/weather/layers/links?l=${f}&v=${this.source}&z=${u}&bbox=${b}&t=${this.ts}`,{headers:{Authorization:this.token||this.defaultMeteoToken}});if(r=new Date().valueOf()-(e+t),console.log("weather links elapsed: ",r,", total: ",t+=r),((l=_==null?void 0:_.data)==null?void 0:l.code)===0){const g=(n=_==null?void 0:_.data)==null?void 0:n.data,w=[];for(const L in g)L==="ice-edge"&&(g[L]="https://idm-hz.oss-cn-hangzhou.aliyuncs.com/test/sea_ice_contours.geojson"),L!=="tropicals"&&w.push(G.get(g[L],{headers:{Authorization:this.token||this.defaultMeteoToken,key:L},responseType:/\.(jpg|png)$/.test(g[L])?"blob":"json"}).catch(N=>{console.log(`[${L}] fetch layer error: ${N}`)}));const v=await Promise.all(w);this.weatherLayers={},v.map(L=>{var D,R,B,M;const N=((D=L==null?void 0:L.data)==null?void 0:D.data)||(L==null?void 0:L.data),T=(B=(R=L==null?void 0:L.config)==null?void 0:R.headers)==null?void 0:B.key;T&&N&&(this.weatherLayers[T]={raw:N,type:((M=L==null?void 0:L.config)==null?void 0:M.responseType)==="blob"?"image":"json",etime:this.ts})}),g.tropicals&&G.get(g.tropicals,{headers:{Authorization:this.token||this.defaultMeteoToken,key:"tropicals"}}).then(L=>{var D,R,B;const N=E.TropicalHelper.convert2Geojson(((D=L==null?void 0:L.data)==null?void 0:D.data)||(L==null?void 0:L.data)),T=(B=(R=L==null?void 0:L.config)==null?void 0:R.headers)==null?void 0:B.key;this.weatherLayers[T]={data:N,active:!0,cached:!1,type:"json",etime:this.ts,version:Math.random()+1}})}if(r=new Date().valueOf()-(e+t),console.log("weather layers elapsed: ",r,", total: ",t+=r),this.weatherLayers["swell-direction"]||this.weatherLayers["swell-height"]){const g=(c=this.weatherLayers["swell-direction"])==null?void 0:c.raw,w=(h=this.weatherLayers["swell-height"])==null?void 0:h.raw;delete this.weatherLayers["swell-direction"],delete this.weatherLayers["swell-height"],this.weatherLayers.swell={type:"json",direction:g,height:{raw:w},etime:this.ts}}if(this.weatherLayers["current-direction"]||this.weatherLayers["current-speed"]){const g=(d=this.weatherLayers["current-direction"])==null?void 0:d.raw,w=(p=this.weatherLayers["current-speed"])==null?void 0:p.raw;delete this.weatherLayers["current-direction"],delete this.weatherLayers["current-speed"],this.weatherLayers.current={type:"json",direction:g,speed:{raw:w},etime:this.ts}}}y&&(y.etime=this.ts,y.cached=!0,this.weatherLayers.tropicals=y)}this.handleWeatherLayerToggle(),this.handleDragEndWithZoom4Json()}this.toggleVersion=Math.random()},async fetchOtherLayers(a={all:!1,dayNight:!1,enc:!1}){var e,t,r,o;if(this.map){let s=this.otherWeight;if(s){let l=!1;if(this.otherWeight&2048&&(s=this.otherWeight-2048,l=!0),s){if(a.all){const n=await G.get(`${this.gateway}/api/arc/other/layers/links?l=${s}&t=${this.ts}`,{headers:{Authorization:this.token||this.defaultMeteoToken}});if(((e=n==null?void 0:n.data)==null?void 0:e.code)===0){const c=(t=n==null?void 0:n.data)==null?void 0:t.data,h=[];for(const p in c)h.push(G.get(c[p],{headers:{Authorization:this.token||this.defaultMeteoToken,key:p}}));const d=await Promise.all(h);this.otherLayers={enc:l},d.map(p=>{var b,f,y;const u=((b=p==null?void 0:p.data)==null?void 0:b.data)||(p==null?void 0:p.data),m=(y=(f=p==null?void 0:p.config)==null?void 0:f.headers)==null?void 0:y.key;this.otherLayers[m]=u})}}else if(a.dayNight&&s&1024){const n=await G.get(`${this.gateway}/api/arc/other/layers/links?l=1024&t=${this.ts}`,{headers:{Authorization:this.token||this.defaultMeteoToken}});if(((r=n==null?void 0:n.data)==null?void 0:r.code)===0){const c=(o=n==null?void 0:n.data)==null?void 0:o.data,h=[];for(const p in c)h.push(G.get(c[p],{headers:{Authorization:this.token||this.defaultMeteoToken,key:p}}));(await Promise.all(h)).map(p=>{var b,f,y;const u=((b=p==null?void 0:p.data)==null?void 0:b.data)||(p==null?void 0:p.data),m=(y=(f=p==null?void 0:p.config)==null?void 0:f.headers)==null?void 0:y.key;this.otherLayers[m]=u})}}}else this.otherLayers={enc:l}}else this.otherLayers={};this.handleBeforeLayerToggle()}},handleRampColorState(){var a;if(this.showRampColor=!1,this.showWindParticle=!1,this.showCurrentParticle=!1,(a=this.particleFactor)!=null&&a.particle)this.showRampColor=!0,this.showWindParticle=this.particleFactor.key==="wind",this.showCurrentParticle=this.particleFactor.key==="current",this.activeWeatherLayers=this.activeWeatherLayers.filter(e=>e.type==="json");else for(const e of this.activeWeatherLayers)["png","jpg"].includes(e.type)&&(this.showRampColor=!0);this.activeWindLayer=!!this.activeWeatherLayers.find(e=>e.key==="wind"),this.$refs.layer&&(this.$refs.layer.activeWeatherLayers=this.activeWeatherLayers)},handleRampColorInitial(){var a,e,t,r,o,s,l,n,c,h,d,p;this.viewport.map.getSource((a=this.viewport)==null?void 0:a.rampColorSource)||this.viewport.map.addSource((e=this.viewport)==null?void 0:e.rampColorSource,{type:"canvas",canvas:(t=this.viewport)==null?void 0:t.rampColorCanvas,animate:!0,coordinates:this.viewport.getBoundLngLat()}),this.viewport.map.getLayer((r=this.viewport)==null?void 0:r.rampColorLayer)||this.viewport.map.addLayer({type:"raster",id:(o=this.viewport)==null?void 0:o.rampColorLayer,source:(s=this.viewport)==null?void 0:s.rampColorSource,layout:{visibility:"none"}},this.beforeLayer),this.viewport.map.getSource((l=this.viewport)==null?void 0:l.particleSource)||this.viewport.map.addSource((n=this.viewport)==null?void 0:n.particleSource,{type:"canvas",canvas:(c=this.viewport)==null?void 0:c.particleCanvas,animate:!0,coordinates:this.viewport.getBoundLngLat()}),this.viewport.map.getLayer((h=this.viewport)==null?void 0:h.particleLayer)||this.viewport.map.addLayer({type:"raster",id:(d=this.viewport)==null?void 0:d.particleLayer,source:(p=this.viewport)==null?void 0:p.particleSource,layout:{visibility:"none"}},this.beforeLayer)},handleDragEndWithZoom4Json(){var h,d,p,u;const a=new Date().valueOf();let e=0,t=0;const r=(h=this.map)==null?void 0:h.getBounds(),o=this.map.getZoom(),s=z.convertToStandardLng(r._sw.lng),l=z.convertToStandardLng(r._ne.lng),n=Math.floor(r._sw.lat),c=Math.ceil(r._ne.lat);for(const m in this.weatherLayers)if(this.weatherLayers[m].active&&this.weatherLayers[m].type==="json"){this.weatherLayers[m].active=!1,this.weatherLayers[m].version=Math.random()+1;let b=[];if(["swell","current"].includes(m)){const f=((d=this.weatherLayers[m])==null?void 0:d.direction)||{};for(const y in f)if(y>n&&y<c&&(!(o<=this.zoom)||y%(o<this.zoom/2?5:3)===0)){const _=f[y].lng;s>l?_.forEach((g,w)=>{var v;if((g>=s&&g<=180||g>=-180&&g<=l)&&(!(o<=this.zoom)||g%(o<this.zoom/2?5:3)===0)){const L=x.point([g,y],{val:f[y].val[w],spd:(v=f[y].spd)==null?void 0:v[w]});b.push(L)}}):_.forEach((g,w)=>{var v;if(g>=s&&g<=l&&(!(o<=this.zoom)||g%(o<this.zoom/2?5:3)===0)){const L=x.point([g,y],{val:f[y].val[w],spd:(v=f[y].spd)==null?void 0:v[w]});b.push(L)}})}if(t=new Date().valueOf()-(a+e),console.log("direction elapsed: ",t,", total: ",e+=t),m==="swell"){const y=this.weatherLayers[m].height;if(y){if(!y.data){const _=[];for(const g in(p=y.raw)==null?void 0:p.LineString){const w=y.raw.LineString[g];for(const v of w)_.push(x.lineString(v,{val:Number(g)}));y.data=x.featureCollection(_)}}if(y.data){const _=this.handleBboxClip(y.data,r);b=b.concat(_)}t=new Date().valueOf()-(a+e),console.log("height elapsed: ",t,", total: ",e+=t)}}if(m==="current"){const y=this.weatherLayers[m].speed;if(y){if(!y.data){const g=[];for(const w in(u=y.raw)==null?void 0:u.Polygon){const v=y.raw.Polygon[w];for(const L of v)g.push(x.polygon(L,{val:Number(w)}))}y.data=x.featureCollection(g)}const _=o<this.zoom?y.data.features.filter(g=>g.properties.val>.5):y.data.features;b=b.concat(_),t=new Date().valueOf()-(a+e),console.log("speed elapsed: ",t,", total: ",e+=t)}}}else if(m==="wind"){const f=this.weatherLayers.wind.raw;for(const y in f)if(y>n&&y<c&&(!(o<=this.zoom)||y%(o<this.zoom/2?5:3)===0)){const _=f[y].lng;s>l?_.forEach((g,w)=>{if((g>=s&&g<=180||g>=-180&&g<=l)&&(!(o<=this.zoom)||g%(o<this.zoom/2?5:3)===0)){const v=x.point([g,y],{val:f[y].val[w],spd:f[y].spd[w]});b.push(v)}}):_.forEach((g,w)=>{if(g>=s&&g<=l&&(!(o<=this.zoom)||g%(o<this.zoom/2?5:3)===0)){const v=x.point([g,y],{val:f[y].val[w],spd:f[y].spd[w]});b.push(v)}})}t=new Date().valueOf()-(a+e),console.log("wind barb elapsed: ",t,", total: ",e+=t)}else if(m==="sig-wave-height"){if(this.weatherLayers[m].data)b=this.weatherLayers[m].data;else{const f=this.weatherLayers[m].raw;if(f){const y=[];for(const _ in f.Polygon){const g=f.Polygon[_];for(const w of g)y.push(x.polygon(w,{val:Number(_)}))}for(const _ in f.Point){const g=f.Point[_];for(const w of g)y.push(...x.points(w,{val:Number(_)}).features)}b=b.concat(y)}}t=new Date().valueOf()-(a+e),console.log("sigWave elapsed: ",t,", total: ",e+=t)}else if(m==="prmsl"){if(this.weatherLayers[m].data)b=this.weatherLayers[m].data;else{const f=this.weatherLayers[m].raw;if(f){const y=[];for(const _ in f.LineString){const g=f.LineString[_];for(const w of g)y.push(x.lineString(w,{val:Number(_)}))}for(const _ in f.Point)f.Point[_].lng.forEach((g,w)=>{g=z.convertToStandardLng(g),y.push(x.point([g,_],{val:f.Point[_].val[w],type:f.Point[_].type[w]}))});b=b.concat(y)}}t=new Date().valueOf()-(a+e),console.log("prmsl elapsed: ",t,", total: ",e+=t)}else if(m==="arctic"||m==="iceberg"){if(this.weatherLayers[m].data)b=this.weatherLayers[m].data;else{const f=this.weatherLayers[m].raw;if(f){const y=[];for(const _ in f.LineString){const g=f.LineString[_];for(const w of g)y.push(x.lineString(w,{val:Number(_)}))}b=b.concat(y)}}t=new Date().valueOf()-(a+e)}console.log(m," elapsed: ",t,", total: ",e+=t),b.length&&(this.weatherLayers[m].data=x.featureCollection(b)),this.weatherLayers[m].active=!0,this.weatherLayers[m].version=Math.random()+1}},handleDragEndWithZoom4Image(){for(const a in this.weatherLayers)this.weatherLayers[a].active&&this.weatherLayers[a].type==="image"&&(this.weatherLayers[a].active=!0,this.weatherLayers[a].version=Math.random()+1)},handleBboxClip(a,e){const t=[],r=z.convertToStandardLng(e._sw.lng),o=z.convertToStandardLng(e._ne.lng);return a.features.forEach(s=>{if(s.geometry.type!=="Point")if(r>o){let l=[r,e._sw.lat,180,e._ne.lat],n=x.bboxClip(s,l);n.geometry.coordinates.length&&t.push(n),l=[-180,e._sw.lat,o,e._ne.lat],n=x.bboxClip(s,l),n.geometry.coordinates.length&&t.push(n)}else{const l=[r,e._sw.lat,o,e._ne.lat],n=x.bboxClip(s,l);n.geometry.coordinates.length&&t.push(n)}else t.push(s)}),t},handleWeatherLayerToggle(){var a;for(const e in this.weatherLayers)this.weatherLayers[e].active=!1,this.weatherLayers[e].version=Math.random()+1;for(const e of this.activeWeatherLayers){let t=e.key;t.indexOf("swell")>-1?t="swell":t.indexOf("current")>-1&&(t="current"),this.weatherLayers[t]&&(this.weatherLayers[t].active=!0,this.weatherLayers[t].version=Math.random()+1,((a=this.particleFactor)==null?void 0:a.key)===t&&this.weatherLayers[`${t}-particle`]&&(this.weatherLayers[`${t}-particle`].active=this.particleFactor.particle))}this.handleBeforeLayerToggle()},handleBeforeLayerToggle(){var a,e,t,r,o,s,l,n,c,h,d,p,u;(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"]||(o=this.otherLayers)!=null&&o["load-lines"]||(s=this.otherLayers)!=null&&s["high-risk-area"]||(l=this.otherLayers)!=null&&l["time-zones"]||(n=this.otherLayers)!=null&&n.pirates||(c=this.otherLayers)!=null&&c.ports||(h=this.otherLayers)!=null&&h.enc||(d=this.otherLayers)!=null&&d["voluntary-reporting-area"]||(p=this.otherLayers)!=null&&p["eca-zones"]||(u=this.otherLayers)!=null&&u["special-area"])&&this.map.setLayoutProperty(this.beforeLayer,"visibility","visible")},handleDateChange(a={tropicals:!1}){this.fetchWeatherLayers(a),this.fetchOtherLayers({dayNight:!0})},handleWeatherLayerChange(a,e,t){if(!this.map)setTimeout(()=>{this.handleWeatherLayerChange(a,e,t)},500);else{this.activeWeatherLayers=e;const r=this.activeWeatherLayers.some(l=>["wind","current"].includes(l.key)),o=this.activeWeatherLayers.some(l=>["png","jpg"].includes(l.type));r&&!o?(this.particleFactor=this.activeWeatherLayers.find(l=>["wind","current"].includes(l.key)),this.particleFactor.particle=!0):o&&this.particleFactor&&(this.particleFactor.particle=!1);const s=e==null?void 0:e.reduce((l,n)=>l+(l&(n==null?void 0:n.weight)?0:n==null?void 0:n.weight),0);this.weatherWeight!==s||this.source!==t?(this.source=t,this.weatherWeight=s,this.fetchWeatherLayers({tropicals:!1})):this.handleWeatherLayerToggle()}},handleOtherLayerChange(a){if(!this.map)setTimeout(()=>{this.handleOtherLayerChange(a)},500);else{const e=a==null?void 0:a.reduce((t,r)=>t+(r==null?void 0:r.weight),0);a.find(t=>t.key==="enc")?this.enc="i4":this.enc="",this.otherWeight!=e&&(this.otherWeight=e,this.fetchOtherLayers({all:!0}))}},async handlePointChange(a){const e=this.ts?A(this.ts):A(),t={lat:a.lat,lng:a.lng,ts:e.utc().format(),wt:!0,src:this.source},r=await G.get(`${this.gateway}/api/arc/meteo/query`,{params:t,headers:{Authorization:this.token||this.defaultMeteoToken}});(r==null?void 0:r.status)===200&&(this.meteo={...r==null?void 0:r.data,...a})},handle3dToggle(a){var e,t,r,o,s,l,n,c,h,d,p,u,m,b,f,y,_,g,w,v;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))&&((s=this.map)==null||s.moveLayer((o=this.viewport)==null?void 0:o.rampColorLayer,this.helper.mapboxCustomer.layers.water.id)),(n=this.map)!=null&&n.getLayer((l=this.viewport)==null?void 0:l.particleLayer)&&((c=this.map)!=null&&c.getLayer(this.helper.mapboxCustomer.layers.water.id))&&((d=this.map)==null||d.moveLayer((h=this.viewport)==null?void 0:h.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(),(u=this.map)!=null&&u.getLayer((p=this.viewport)==null?void 0:p.rampColorLayer)&&((m=this.map)!=null&&m.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id))&&((f=this.map)==null||f.moveLayer((b=this.viewport)==null?void 0:b.rampColorLayer,this.helper.mapboxCustomer.layers.countryBoundary.id)),(_=this.map)!=null&&_.getLayer((y=this.viewport)==null?void 0:y.particleLayer)&&((g=this.map)!=null&&g.getLayer(this.helper.mapboxCustomer.layers.countryBoundary.id))&&((v=this.map)==null||v.moveLayer((w=this.viewport)==null?void 0:w.particleLayer,this.helper.mapboxCustomer.layers.countryBoundary.id)))},handleParticle(a){this.particleFactor=a,this.fetchWeatherLayers({tropicals:!1})}}},xo={key:0,className:"map-gl-home"};function vo(a,e,t,r,o,s){var Q,W,j,he,F,S,$,de,H,pe,K,ee,te,ue,ge,be,_e,Le,ke,Ne,Te,Ie,De,Ve,Re,Be;const l=i.resolveComponent("IdmGlLayer"),n=i.resolveComponent("IdmENC"),c=i.resolveComponent("IdmSigWave"),h=i.resolveComponent("IdmSwell"),d=i.resolveComponent("IdmPrmsl"),p=i.resolveComponent("IdmIceberg"),u=i.resolveComponent("IdmTropicals"),m=i.resolveComponent("IdmCurrents"),b=i.resolveComponent("IdmCurrentParticle"),f=i.resolveComponent("IdmWindBarb"),y=i.resolveComponent("IdmWindParticle"),_=i.resolveComponent("IdmPrecip3h"),g=i.resolveComponent("IdmVisibility"),w=i.resolveComponent("IdmWaterTemp"),v=i.resolveComponent("IdmTemp"),L=i.resolveComponent("IdmArctic"),N=i.resolveComponent("IdmWarZone"),T=i.resolveComponent("IdmGmdssArea"),D=i.resolveComponent("IdmEcaZone"),R=i.resolveComponent("IdmAlertZone"),B=i.resolveComponent("IdmPort"),M=i.resolveComponent("IdmLoadLine"),ie=i.resolveComponent("IdmTimezone"),oe=i.resolveComponent("IdmVRA"),re=i.resolveComponent("IdmSpecialArea"),se=i.resolveComponent("IdmTerminator"),ne=i.resolveComponent("IdmLatLng"),le=i.resolveComponent("IdmMeasure"),ce=i.resolveComponent("IdmPoint");return t.map?(i.openBlock(),i.createElementBlock("div",xo,[i.createVNode(l,i.mergeProps({ref:"layer",map:t.map,"toggle-version":o.toggleVersion,"map-projection":o.mapProjection},a.$attrs,{onWeather:s.handleWeatherLayerChange,onOther:s.handleOtherLayerChange,onCoordinate:e[0]||(e[0]=U=>o.showCoord=U),onMeasure:e[1]||(e[1]=U=>o.showMeasure=U),onPoint:e[2]||(e[2]=U=>o.showPoint=U),on3d:s.handle3dToggle,onToggleVersion:e[3]||(e[3]=U=>o.toggleVersion=U)}),null,16,["map","toggle-version","map-projection","onWeather","onOther","on3d"]),i.createVNode(n,i.mergeProps({map:t.map,token:t.token,enabled:(Q=o.otherLayers)==null?void 0:Q.enc,"toggle-version":o.toggleVersion},a.$attrs,{onEnc:e[4]||(e[4]=U=>o.enc=U)}),null,16,["map","token","enabled","toggle-version"]),i.createVNode(c,i.mergeProps({map:t.map,"sig-wave":(W=o.weatherLayers)==null?void 0:W["sig-wave-height"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","sig-wave","before-layer"]),i.createVNode(h,i.mergeProps({map:t.map,swell:(j=o.weatherLayers)==null?void 0:j.swell,"before-layer":t.beforeLayer},a.$attrs),null,16,["map","swell","before-layer"]),i.createVNode(d,i.mergeProps({map:t.map,prmsl:(he=o.weatherLayers)==null?void 0:he.prmsl,"before-layer":t.beforeLayer,"active-weather-layers":o.activeWeatherLayers},a.$attrs),null,16,["map","prmsl","before-layer","active-weather-layers"]),i.createVNode(p,i.mergeProps({map:t.map,iceberg:(F=o.weatherLayers)==null?void 0:F.iceberg,"before-layer":t.beforeLayer},a.$attrs),null,16,["map","iceberg","before-layer"]),i.createVNode(u,i.mergeProps({map:t.map,date:t.ts,tropicals:(S=o.weatherLayers)==null?void 0:S.tropicals,"before-layer":t.beforeLayer},a.$attrs),null,16,["map","date","tropicals","before-layer"]),i.createVNode(m,i.mergeProps({map:t.map,"map-projection":o.mapProjection,current:($=o.weatherLayers)==null?void 0:$.current,"before-layer":t.beforeLayer,"show-particle":o.showCurrentParticle,"margin-bottom":o.activeWindLayer?o.showRampColor?"84px":"56px":o.showRampColor?"56px":"30px","toggle-version":o.toggleVersion,"weather-layers":o.weatherLayers},a.$attrs,{onParticle:s.handleParticle}),null,16,["map","map-projection","current","before-layer","show-particle","margin-bottom","toggle-version","weather-layers","onParticle"]),i.createVNode(b,i.mergeProps({viewport:o.viewport,factor:(de=o.weatherLayers)==null?void 0:de["current-particle"],"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(f,i.mergeProps({ref:"windBarb",map:t.map,"map-projection":o.mapProjection,wind:(H=o.weatherLayers)==null?void 0:H.wind,current:(pe=o.weatherLayers)==null?void 0:pe.current,"before-layer":t.beforeLayer,"margin-bottom":o.showRampColor?"56px":"30px","show-particle":o.showWindParticle},a.$attrs,{"toggle-version":o.toggleVersion,"weather-layers":o.weatherLayers,onParticle:s.handleParticle}),null,16,["map","map-projection","wind","current","before-layer","margin-bottom","show-particle","toggle-version","weather-layers","onParticle"]),i.createVNode(y,i.mergeProps({viewport:o.viewport,factor:(K=o.weatherLayers)==null?void 0:K["wind-particle"],"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(_,i.mergeProps({viewport:o.viewport,factor:(ee=o.weatherLayers)==null?void 0:ee.precip3h,"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(g,i.mergeProps({viewport:o.viewport,factor:(te=o.weatherLayers)==null?void 0:te.visibility,"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(w,i.mergeProps({viewport:o.viewport,factor:(ue=o.weatherLayers)==null?void 0:ue["water-temp"],"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(v,i.mergeProps({viewport:o.viewport,factor:(ge=o.weatherLayers)==null?void 0:ge.temp,"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(L,i.mergeProps({viewport:o.viewport,factor:(be=o.weatherLayers)==null?void 0:be.arctic,"before-layer":t.beforeLayer,"toggle-version":o.toggleVersion},a.$attrs),null,16,["viewport","factor","before-layer","toggle-version"]),i.createVNode(N,i.mergeProps({map:t.map,zone:(_e=o.otherLayers)==null?void 0:_e["war-zones"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","zone","before-layer"]),i.createVNode(T,i.mergeProps({map:t.map,area:(Le=o.otherLayers)==null?void 0:Le["gmdss-areas"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","area","before-layer"]),i.createVNode(D,i.mergeProps({map:t.map,zone:(ke=o.otherLayers)==null?void 0:ke["eca-zones"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","zone","before-layer"]),i.createVNode(R,i.mergeProps({map:t.map,zone:(Ne=o.otherLayers)==null?void 0:Ne["alert-zones"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","zone","before-layer"]),i.createVNode(B,i.mergeProps({map:t.map,port:(Te=o.otherLayers)==null?void 0:Te.ports,"before-layer":t.beforeLayer},a.$attrs),null,16,["map","port","before-layer"]),i.createVNode(M,i.mergeProps({map:t.map,line:(Ie=o.otherLayers)==null?void 0:Ie["load-lines"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","line","before-layer"]),i.createVNode(ie,i.mergeProps({map:t.map,zone:(De=o.otherLayers)==null?void 0:De["time-zones"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","zone","before-layer"]),i.createVNode(oe,i.mergeProps({map:t.map,area:(Ve=o.otherLayers)==null?void 0:Ve["voluntary-reporting-area"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","area","before-layer"]),i.createVNode(re,i.mergeProps({map:t.map,area:(Re=o.otherLayers)==null?void 0:Re["special-area"],"before-layer":t.beforeLayer},a.$attrs),null,16,["map","area","before-layer"]),i.createVNode(se,i.mergeProps({map:t.map,area:(Be=o.otherLayers)==null?void 0:Be["day-night"]},a.$attrs),null,16,["map","area"]),i.createVNode(ne,i.mergeProps({map:t.map,show:o.showCoord,"toggle-version":o.toggleVersion},a.$attrs),null,16,["map","show","toggle-version"]),i.createVNode(le,i.mergeProps({map:t.map,show:o.showMeasure},a.$attrs),null,16,["map","show"]),i.createVNode(ce,i.mergeProps({map:t.map,show:o.showPoint,meteo:o.meteo},a.$attrs,{onPoint:s.handlePointChange}),null,16,["map","show","meteo","onPoint"])])):i.createCommentVNode("",!0)}const Pe=C(wo,[["render",vo]]),Co={install(a){a.component("MapboxGL",Pe),a.component("TropicalGL",Ce),a.component("LatLngGL",Se)}};k.LatLngGL=Se,k.MapboxGL=Pe,k.MapboxGLPlugin=Co,k.MapboxHelper=Ee,k.ParticleSchema=V,k.TropicalGL=Ce,k.Viewport=we,k.WebGL=J,k.WebGLSchema=I,Object.defineProperty(k,Symbol.toStringTag,{value:"Module"})});
|
|
@@ -10,9 +10,15 @@ declare namespace _sfc_main {
|
|
|
10
10
|
const type_1: BooleanConstructor;
|
|
11
11
|
export { type_1 as type };
|
|
12
12
|
}
|
|
13
|
-
namespace
|
|
14
|
-
const type_2:
|
|
13
|
+
namespace timeZone {
|
|
14
|
+
const type_2: NumberConstructor;
|
|
15
15
|
export { type_2 as type };
|
|
16
|
+
const _default: number;
|
|
17
|
+
export { _default as default };
|
|
18
|
+
}
|
|
19
|
+
namespace meteo {
|
|
20
|
+
const type_3: ObjectConstructor;
|
|
21
|
+
export { type_3 as type };
|
|
16
22
|
}
|
|
17
23
|
}
|
|
18
24
|
function data(): {
|
package/dist/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@charset "UTF-8";:root{--idm-white: rgba(255, 255, 255, 1);--idm-white-9: rgba(255, 255, 255, .9);--idm-white-8: rgba(255, 255, 255, .8);--idm-white-7: rgba(255, 255, 255, .7);--idm-white-6: rgba(255, 255, 255, .6);--idm-white-5: rgba(255, 255, 255, .5);--idm-white-4: rgba(255, 255, 255, .4);--idm-white-3: rgba(255, 255, 255, .3);--idm-white-2: rgba(255, 255, 255, .2);--idm-white-1: rgba(255, 255, 255, .1);--idm-black: rgba(0, 0, 0, 1);--idm-black-9: rgba(0, 0, 0, .9);--idm-black-8: rgba(0, 0, 0, .8);--idm-black-7: rgba(0, 0, 0, .7);--idm-black-6: rgba(0, 0, 0, .6);--idm-black-5: rgba(0, 0, 0, .5);--idm-black-4: rgba(0, 0, 0, .4);--idm-black-3: rgba(0, 0, 0, .3);--idm-black-2: rgba(0, 0, 0, .2);--idm-black-1: rgba(0, 0, 0, .1);--idm-gray-light: rgba(239, 239, 239, 1);--idm-primary-color: rgba(42, 87, 183, 1);--idm-primary-color-light: #6c8ad9;--idm-primary-color-light2: #a7c4ff;--idm-primary-color-dark: #053a7e;--idm-primary-color-dark2: #002e6b;--idm-primary-color-9: rgba(42, 87, 183, .9);--idm-primary-color-8: rgba(42, 87, 183, .8);--idm-primary-color-7: rgba(42, 87, 183, .7);--idm-primary-color-6: rgba(42, 87, 183, .6);--idm-primary-color-5: rgba(42, 87, 183, .5);--idm-primary-color-4: rgba(42, 87, 183, .4);--idm-primary-color-3: rgba(42, 87, 183, .3);--idm-primary-color-2: rgba(42, 87, 183, .2);--idm-primary-color-1: rgba(42, 87, 183, .1);--idm-success-color: #0ddd9f;--idm-success-color-light: #92f7d9;--idm-success-color-dark: #06a074;--idm-success-color-dark2: #06694c;--idm-warning-color: #ff9500;--idm-warning-color-light: #ffcc00;--idm-warning-color-dark: #c77402;--idm-danger-color: #f44336;--idm-danger-color-light: #fb796e;--idm-danger-color-dark: #ad251b;--idm-info-color: #6e6e6e;--idm-info-color-light: #969696;--idm-info-color-light2: #c0c0c0;--idm-info-color-light3: #e2e2e2;--idm-info-color-dark: #494949;--idm-dangerous: #f44336;--idm-severe: #ff9500;--idm-heavy: #ffff00;--idm-vessel-cargo-color: lightgreen;--idm-vessel-tanker-color: red;--idm-vessel-passenger-color: blue;--idm-vessel-other-color: lightgrey;--idm-perf-cii-a: var(--idm-success-color);--idm-perf-cii-b: var(--idm-success-color-light);--idm-perf-cii-c: var(--idm-warning-color);--idm-perf-cii-d: var(--idm-danger-color-light);--idm-perf-cii-e: var(--idm-danger-color);--idm-tropicals-td: #03f869;--idm-tropicals-ts: #f2f202;--idm-tropicals-sts: #ff9100;--idm-tropicals-ty: #f44336;--idm-tropicals-sty: #f903d0;--idm-tropicals-super-ty: #8702f9;--idm-tropicals-r7: #ff9100;--idm-tropicals-r10: #f44336;--idm-text-shadow: 0px 0px 4px rgba(0, 0, 0, 1);--idm-dashed-border: 1px dashed var(--idm-white-5);--idm-solid-border: 1px solid var(--idm-white-4);--idm-background-color: var(--idm-primary-color-9);--idm-background-color-dark: var(--idm-primary-color-dark);--idm-background-color-light: var(--idm-primary-color-light);--idm-background-color-light2: #f3f5f8;--idm-active-background-light: linear-gradient(130deg, rgba(142, 163, 255, .93) 20%, rgb(90 67 193 / 93%) 100%);--idm-active-text-shadow-light: 0 0 7px rgb(194, 255, 247), 0 0 21px rgb(194, 255, 247), 0 0 30px rgba(182, 211, 207, .4), 0 0 12px rgba(15, 115, 223, .6), 0 0 22px rgba(15, 115, 223, .8), 0 0 38px rgba(15, 115, 223, .9), 0 0 60px rgba(15, 115, 223, 1);--idm-background-opaque-linear-gradient-top: linear-gradient(to top, rgba(41, 32, 165) 0%, rgba(44, 93, 184) 80%, rgba(32, 90, 165) 100%);--idm-background-linear-gradient-top: linear-gradient(to top, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-bottom: linear-gradient(to bottom, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-right: linear-gradient(to right, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-left: linear-gradient(to left, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-blink-animation: blink .8s ease-out infinite alternate}:root[colorTheme=black]{--idm-background-opaque-linear-gradient-top: linear-gradient(to top, rgba(0, 0, 0, .8) 0%, rgba(0, 0, 0, .8) 80%, rgb(0, 0, 0, .8) 100%);--idm-background-linear-gradient-top: linear-gradient(to top, rgba(0, 0, 0, .6) 0%, rgba(0, 0, 0, .7) 70%, rgb(0, 0, 0, .7) 100%);--idm-background-linear-gradient-bottom: linear-gradient(to top, rgba(0, 0, 0, .6) 0%, rgba(0, 0, 0, .7) 70%, rgb(0, 0, 0, .7) 100%);--idm-background-linear-gradient-right: linear-gradient(to top, rgba(0, 0, 0, .6) 0%, rgba(0, 0, 0, .7) 70%, rgb(0, 0, 0, .7) 100%);--idm-background-linear-gradient-left: linear-gradient(to top, rgba(0, 0, 0, .6) 0%, rgba(0, 0, 0, .7) 70%, rgb(0, 0, 0, .7) 100%);--idm-active-background-light: linear-gradient(130deg, rgba(117, 117, 117, .93) 30%, rgba(200, 200, 200, .93) 100%);--idm-active-text-shadow-light: 0 0 7px rgb(253, 253, 253), 0 0 21px rgb(226, 226, 226), 0 0 30px rgba(185, 185, 185, .4), 0 0 12px rgba(67, 67, 67, .6), 0 0 22px rgba(27, 27, 27, .8), 0 0 38px rgba(15, 115, 223, .9), 0 0 60px rgba(15, 115, 223, 1);--idm-primary-color: rgba(0, 0, 0, .7);--idm-primary-color-light: #757575;--idm-primary-color-light2: #a5a5a5;--idm-primary-color-dark: rgba(0, 0, 0, .8);--idm-primary-color-dark2: rgba(0, 0, 0, 1);--idm-primary-color-9: rgba(0, 0, 0, .9);--idm-primary-color-7: rgba(0, 0, 0, .7);--idm-primary-color-5: rgba(0, 0, 0, .5);--idm-primary-color-3: rgba(0, 0, 0, .3);--idm-primary-color-1: rgba(0, 0, 0, .1)}:root[colorTheme=blue]{--idm-background-opaque-linear-gradient-top: linear-gradient(to top, rgba(41, 32, 165) 0%, rgba(44, 93, 184) 80%, rgba(32, 90, 165) 100%);--idm-background-linear-gradient-top: linear-gradient(to top, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-bottom: linear-gradient(to bottom, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-right: linear-gradient(to right, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-left: linear-gradient(to left, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-active-background-light: linear-gradient(130deg, rgba(142, 163, 255, .93) 20%, rgb(90 67 193 / 93%) 100%);--idm-active-text-shadow-light: 0 0 7px rgb(194, 255, 247), 0 0 21px rgb(194, 255, 247), 0 0 30px rgba(182, 211, 207, .4), 0 0 12px rgba(15, 115, 223, .6), 0 0 22px rgba(15, 115, 223, .8), 0 0 38px rgba(15, 115, 223, .9), 0 0 60px rgba(15, 115, 223, 1);--idm-primary-color: rgba(42, 87, 183, 1);--idm-primary-color-light: #6c8ad9;--idm-primary-color-light2: #a7c4ff;--idm-primary-color-dark: #053a7e;--idm-primary-color-dark2: #002e6b;--idm-primary-color-9: rgba(42, 87, 183, .9);--idm-primary-color-8: rgba(42, 87, 183, .8);--idm-primary-color-7: rgba(42, 87, 183, .7);--idm-primary-color-6: rgba(42, 87, 183, .6);--idm-primary-color-5: rgba(42, 87, 183, .5);--idm-primary-color-4: rgba(42, 87, 183, .4);--idm-primary-color-3: rgba(42, 87, 183, .3);--idm-primary-color-2: rgba(42, 87, 183, .2);--idm-primary-color-1: rgba(42, 87, 183, .1)}:root[colorTheme=dark-blue]{--idm-background-opaque-linear-gradient-top: linear-gradient(to top, rgba(16, 22, 79, .85) 0%, rgba(15, 41, 89, .85) 80%, rgba(19, 47, 108, .85) 100%);--idm-background-linear-gradient-top: linear-gradient(to top, rgba(16, 22, 79, .85) 0%, rgba(15, 41, 89, .85) 80%, rgba(19, 47, 108, .85) 100%);--idm-background-linear-gradient-bottom: linear-gradient(to bottom, rgba(16, 22, 79, .85) 0%, rgba(15, 41, 89, .85) 80%, rgba(19, 47, 108, .85) 100%);--idm-background-linear-gradient-right: linear-gradient(to right, rgba(16, 22, 79, .85) 0%, rgba(15, 41, 89, .85) 80%, rgba(19, 47, 108, .85) 100%);--idm-background-linear-gradient-left: linear-gradient(to left, rgba(16, 22, 79, .85) 0%, rgba(15, 41, 89, .85) 80%, rgba(19, 47, 108, .85) 100%);--idm-active-background-light: linear-gradient(130deg, rgba(104, 104, 226, .93) 20%, rgba(22, 49, 182, .93) 100%);--idm-active-text-shadow-light: 0 0 7px rgb(194, 255, 247), 0 0 21px rgb(194, 255, 247), 0 0 30px rgba(182, 211, 207, .4), 0 0 12px rgba(15, 115, 223, .6), 0 0 22px rgba(15, 115, 223, .8), 0 0 38px rgba(15, 115, 223, .9), 0 0 60px rgba(15, 115, 223, 1);--idm-primary-color: rgba(42, 87, 183, 1);--idm-primary-color-light: #6266e0;--idm-primary-color-light2: #89b0ff;--idm-primary-color-dark: #00224e;--idm-primary-color-dark2: #021a39;--idm-primary-color-9: rgba(19, 47, 108, .9);--idm-primary-color-7: rgba(19, 47, 108, .7);--idm-primary-color-5: rgba(19, 47, 108, .5);--idm-primary-color-3: rgba(19, 47, 108, .3);--idm-primary-color-1: rgba(19, 47, 108, .1)}@font-face{font-family:iconfont;src:url(https://iconfont.idmwx.com/iconfont.woff2) format("woff2"),url(https://iconfont.idmwx.com/iconfont.woff) format("woff"),url(https://iconfont.idmwx.com/iconfont.ttf) format("truetype"),url(https://iconfont.idmwx.com/iconfont.svg?#iconfont) format("svg")}.iconfont{font-family:iconfont!important;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}*,*:before,*:after{box-sizing:border-box;margin:0}.text-ellipsis{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.flex-start{display:flex;align-items:center;justify-content:flex-start}.flex-end{display:flex;align-items:center;justify-content:flex-end}.flex-center{display:flex;align-items:center;justify-content:center}.flex-between,.flex-space{display:flex;align-items:center;justify-content:space-between}.flex-around{display:flex;align-items:center;justify-content:space-around}.flex-evenly{display:flex;align-items:center;justify-content:space-evenly}.flex-col-center-center{display:flex;flex-direction:column;justify-content:center;align-items:center}.flex-col-start-center{display:flex;flex-direction:column;justify-content:flex-start;align-items:center}.flex-col-end-center{display:flex;flex-direction:column;justify-content:flex-end;align-items:center}.flex-col-between-center{display:flex;flex-direction:column;justify-content:space-between;align-items:center}.flex-col-around-center{display:flex;flex-direction:column;justify-content:space-around;align-items:center}.flex-col-center-start{display:flex;flex-direction:column;justify-content:center;align-items:flex-start}.flex-col-center-end{display:flex;flex-direction:column;justify-content:center;align-items:flex-end}.flex{flex:1}.dropdown{position:relative;display:inline-block!important}.dropdown .dropdown-content{display:none;position:absolute;z-index:1}.dropdown:hover .dropdown-content{display:block}.loading{position:fixed;top:0;left:0;right:0;bottom:0;background:var(--idm-black-5);z-index:1000;display:flex;justify-content:center;align-items:center;flex-direction:column}.loading i{font-size:30px;color:var(--idm-white);margin-bottom:16px;animation:rotate 2s linear infinite}.loading div{color:var(--idm-white);font-size:16px}@keyframes blink{0%{box-shadow:0 0 20px var(--idm-warning-color-dark) inset}to{box-shadow:0 0 20px var(--idm-success-color) inset}}@keyframes rotate{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.idm-gl3-layer .fade-enter-active,.idm-gl3-layer .fade-leave-active{transition:opacity .4s}.idm-gl3-layer .fade-enter,.idm-gl3-layer .fade-leave-to{opacity:0}.idm-gl3-layer .menu-bar-box{position:absolute;overflow-y:hidden;box-sizing:border-box;display:flex;flex-direction:column;align-items:flex-end;justify-content:flex-start;transition:all .4s ease-in-out;z-index:2;border-radius:5px;box-shadow:0 2px 12px #0003}.idm-gl3-layer .menu-bar-box .bar-item{position:relative;border-radius:5px;background:var(--idm-white);cursor:pointer}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon{padding:8px;display:flex}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon:first-child{border-top-left-radius:5px;border-top-right-radius:5px}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon:last-child{border-bottom-left-radius:5px;border-bottom-right-radius:5px}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon span{font-size:20px;font-weight:600;color:var(--idm-black-8)}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon.active{background:var(--idm-primary-color)}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon.active span{color:var(--idm-white)}.idm-gl3-layer .layer{cursor:pointer;display:inline-flex;align-items:center;padding:5px 0}.idm-gl3-layer .layer.disabled{cursor:not-allowed}.idm-gl3-layer .layer.disabled span{color:var(--idm-black-4)}.idm-gl3-layer .layer.disabled .checkbox{border:1px solid var(--idm-black-2)}.idm-gl3-layer .layer.active .checkbox{border:var(--idm-primary-color);background:var(--idm-primary-color)}.idm-gl3-layer .layer.active .checkbox:after{content:"✔";color:var(--idm-white);font-size:12px;display:flex;align-items:center;justify-content:center}.idm-gl3-layer .layer.active span{color:var(--idm-primary-color)}.idm-gl3-layer .layer .checkbox{width:16px;height:16px;margin-right:4px;border:1px solid var(--idm-black-8)}.idm-gl3-layer .layer span{color:var(--idm-black-8);font-size:14px;width:max-content}.idm-gl3-layer .other-bars{position:absolute;top:36px;border-radius:5px;background:var(--idm-background-linear-gradient-top);box-shadow:0 2px 12px #0003}.idm-gl3-layer .active-layers{position:absolute;max-width:250px;min-width:200px;display:flex;flex-wrap:wrap;align-items:center;background:var(--idm-white);border-radius:5px;box-shadow:0 2px 12px #0003;transition:all .4s ease-in-out}.idm-gl3-layer .active-layers .layer{width:auto;padding:5px}.idm-gl3-layer .available-layers{position:absolute;height:calc(100vh - 120px);box-sizing:border-box;transition:all .4s ease-in-out}.idm-gl3-layer .available-layers .side-bar{margin:0 10px;box-sizing:border-box}.idm-gl3-layer .available-layers .side-bar i{padding:15px 1px;background:var(--idm-white-7);border-radius:5px;cursor:pointer;font-size:18px;font-weight:600;color:var(--idm-black);box-shadow:0 2px 12px #0003}.idm-gl3-layer .available-layers .list-box{height:inherit;width:200px;padding:10px 0;overflow-y:auto;color:var(--idm-black-8);background:var(--idm-white);display:flex;flex-direction:column;box-shadow:0 2px 12px #0003;z-index:1}.idm-gl3-layer .available-layers .list-box .layers-title{font-size:16px;font-weight:600;padding:0 10px 10px;color:var(--idm-black-8);border-bottom:var(--idm-dashed-border)}.idm-gl3-layer .available-layers .list-box .layers-body{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-start;padding:0 10px;font-size:14px}.idm-gl3-layer .available-layers .list-box .layers-body .layer{width:140px}.idm-gl3-layer .available-layers .list-box .model-box{display:flex;align-items:center;justify-content:flex-start;margin:10px 0;cursor:pointer}.idm-gl3-layer .available-layers .list-box .model-box span{padding:3px 10px;border:1px solid #cecece}.idm-gl3-layer .available-layers .list-box .model-box span.active{color:var(--idm-white);border:1px solid var(--idm-primary-color);background:var(--idm-primary-color)}.idm-gl3-layer .available-layers .list-box .model-box span:first-child{border-top-left-radius:5px;border-bottom-left-radius:5px}.idm-gl3-layer .available-layers .list-box .model-box span:last-child{border-top-right-radius:5px;border-bottom-right-radius:5px;border-left:none}.tool-bars[data-v-b6fb74d9]{transition:all .4s ease-in-out}.tool-bars i[data-v-b6fb74d9]{cursor:pointer;font-size:30px;color:var(--idm-white-8);text-shadow:var(--idm-text-shadow)}.tool-bars i.active[data-v-b6fb74d9]{color:var(--idm-white)}.tool-bars span[data-v-b6fb74d9]{cursor:pointer;font-size:12px;color:var(--idm-black-8);margin-left:4px;background:var(--idm-white-8);padding:2px 4px;border-radius:5px;box-shadow:0 2px 12px #0003}.tool-bars span.active[data-v-b6fb74d9]{color:var(--idm-white);background:var(--idm-primary-color)}.legend-bars[data-v-41a686d0]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(98,113,184),rgb(98,113,184),rgb(98,113,184),rgb(98,113,184),rgb(61,110,163),rgb(74,148,170),rgb(74,146,148),rgb(77,142,124),rgb(76,164,76),rgb(103,164,54),rgb(162,135,64),rgb(162,109,92),rgb(141,63,92),rgb(151,75,145),rgb(95,100,160),rgb(91,136,161),rgb(91,136,161));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-41a686d0]{font-size:12px;text-align:center;color:var(--idm-white-8);width:32px}.tool-bars[data-v-ae630f43]{transition:all .4s ease-in-out}.tool-bars i[data-v-ae630f43]{cursor:pointer;font-size:30px;color:var(--idm-white-8);text-shadow:var(--idm-text-shadow)}.tool-bars i.active[data-v-ae630f43]{color:var(--idm-white)}.tool-bars span[data-v-ae630f43]{cursor:pointer;font-size:12px;color:var(--idm-black-8);margin-left:4px;background:var(--idm-white-8);padding:2px 4px;border-radius:5px;box-shadow:0 2px 12px #0003}.tool-bars span.active[data-v-ae630f43]{color:var(--idm-white);background:var(--idm-primary-color)}.legend-bars[data-v-9115889b]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(84,170,230),rgb(84,170,230),rgb(84,170,230),rgb(84,170,230),rgb(64,127,115),rgb(58,164,58),rgb(191,182,67),rgb(197,154,68),rgb(160,70,94),rgb(138,84,166),rgb(82,113,165),rgb(84,142,152),rgb(150,181,184),rgb(195,194,194),rgb(195,194,194));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-9115889b]{font-size:12px;text-align:center;color:var(--idm-white);width:36px}.active-tropical[data-v-08ecb5a5]{bottom:unset;background:var(--idm-white-9);padding:10px;border-radius:5px;box-shadow:0 2px 12px #0003;z-index:5}.active-tropical .header-box[data-v-08ecb5a5]{min-width:360px;margin-bottom:10px;box-sizing:border-box;color:var(--idm-black-8)}.active-tropical .header-box .close-btn[data-v-08ecb5a5]{position:relative;height:0px;text-align:right;font-size:22px;color:var(--idm-primary-color)}.active-tropical .header-box .main[data-v-08ecb5a5]{font-size:16px}.active-tropical .header-box .sub[data-v-08ecb5a5]{margin:3px 0;font-size:12px;color:var(--idm-info-color)}.active-tropical .main-box[data-v-08ecb5a5]{min-width:360px;color:var(--idm-black-8);overflow-y:auto;box-sizing:border-box;font-size:12px;z-index:4}.active-tropical .main-box .content[data-v-08ecb5a5]{padding:5px 0;border-radius:5px;background:var(--idm-gray-light)}.active-tropical .main-box .row[data-v-08ecb5a5]{width:100%;padding:4px 10px;box-sizing:border-box;display:flex;align-items:center;justify-content:space-between}.active-tropical .main-box .row .col[data-v-08ecb5a5]{display:flex;align-items:center;justify-content:space-between}.active-tropical .main-box .row .col label[data-v-08ecb5a5]{width:82px;margin-right:4px;color:var(--idm-info-color)}.active-tropical .main-box .row .col.col-24[data-v-08ecb5a5]{width:100%}.active-tropical .main-box .row .col.col-left[data-v-08ecb5a5]{width:55%}.active-tropical .main-box .row .col.col-right[data-v-08ecb5a5]{width:40%}.active-tropical .main-box .row .col .icon[data-v-08ecb5a5]{font-size:30px;color:var(--idm-black-4)}.active-tropical .main-box .row .col .icon.active[data-v-08ecb5a5]{color:var(--idm-primary-color)}.forecast-models[data-v-08ecb5a5]{display:flex;justify-content:flex-end;flex:1;margin-left:5px;flex-wrap:wrap}.forecast-models .model[data-v-08ecb5a5]{font-size:12px;padding:0 6px 4px;display:flex;border:1px solid var(--idm-primary-color)}.forecast-models .model span[data-v-08ecb5a5]{border-bottom:2px dashed var(--idm-white)}.forecast-models .model span.cma[data-v-08ecb5a5]{border-color:#e2ea03cc}.forecast-models .model span.jma[data-v-08ecb5a5]{border-color:#01d2b7cc}.forecast-models .model span.ecmwf[data-v-08ecb5a5]{border-color:#f582f2cc}.forecast-models .model span.ukm[data-v-08ecb5a5]{border-color:#f5bb47cc}.forecast-models .model span.noaa-at[data-v-08ecb5a5],.forecast-models .model span.noaa-ep[data-v-08ecb5a5]{border-color:#9758fbcc}.forecast-models .model.active[data-v-08ecb5a5]{border:1px solid var(--idm-primary-color);background-color:var(--idm-primary-color);color:var(--idm-white)}.forecast-models .model[data-v-08ecb5a5]:first-child{border-top-left-radius:4px;border-bottom-left-radius:4px}.forecast-models .model.center-child[data-v-08ecb5a5]{border-left:1px solid var(--idm-primary-color);border-right:1px solid var(--idm-primary-color)}.forecast-models .model[data-v-08ecb5a5]:last-child{border-top-right-radius:4px;border-bottom-right-radius:4px}.legend[data-v-08ecb5a5]{display:flex;align-items:center;color:var(--idm-info-color)}.legend .icon[data-v-08ecb5a5]{height:14px;width:14px;border-radius:50%;border:3px solid #fff;margin-right:3px}.legend .icon.td[data-v-08ecb5a5]{background-color:var(--idm-tropicals-td)}.legend .icon.ts[data-v-08ecb5a5]{background-color:var(--idm-tropicals-ts)}.legend .icon.sts[data-v-08ecb5a5]{background-color:var(--idm-tropicals-sts)}.legend .icon.ty[data-v-08ecb5a5]{background-color:var(--idm-tropicals-ty)}.legend .icon.sty[data-v-08ecb5a5]{background-color:var(--idm-tropicals-sty)}.legend .icon.supper-ty[data-v-08ecb5a5]{background-color:var(--idm-tropicals-super-ty)}.legend .icon.r7[data-v-08ecb5a5]{border:1.5px solid var(--idm-tropicals-r7)}.legend .icon.r10[data-v-08ecb5a5]{border:1.5px solid var(--idm-tropicals-r10)}.legend .icon.history[data-v-08ecb5a5]{border:none;border-radius:0;height:4px;background:var(--idm-black-5)}.legend .button[data-v-08ecb5a5]{cursor:pointer;padding:0 4px;border-radius:4px;border:1px solid var(--idm-primary-color);color:var(--idm-primary-color)}.more[data-v-08ecb5a5]{display:flex;align-items:center;justify-content:flex-end;color:var(--idm-primary-color);font-weight:700;margin-top:5px}.legend-bars[data-v-dec867b8]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgba(59,126,162,0),rgb(172,210,255),rgb(172,210,255),rgb(3,248,103),rgb(14,201,3),rgb(190,226,2),rgb(248,1,1),rgb(197,5,58),rgb(197,5,58));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-dec867b8]{font-size:12px;text-align:center;color:var(--idm-white);width:35px}.legend-bars[data-v-952dee5c]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(189,50,160),rgb(189,50,160),rgb(189,50,160),rgb(189,50,160),rgb(208,56,56),rgb(208,56,56),rgb(190,226,2),rgb(190,226,2),rgb(4,210,64),rgb(4,210,64),rgb(172,210,255),rgb(172,210,255));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-952dee5c]{font-size:12px;text-align:center;color:var(--idm-white);width:40px}.legend-bars[data-v-67e5094b]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(95,143,197),rgb(95,143,197),rgb(95,143,197),rgb(95,143,197),rgb(80,140,62),rgb(121,146,28),rgb(171,161,14),rgb(223,177,6),rgb(243,150,6),rgb(236,95,21),rgb(190,65,18),rgb(138,43,10),rgb(138,43,10));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-67e5094b]{font-size:12px;text-align:center;color:var(--idm-white);width:32px}.legend-bars[data-v-389ea886]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(149,137,211),rgb(149,137,211),rgb(149,137,211),rgb(149,137,211),rgb(150,209,216),rgb(129,204,197),rgb(103,180,186),rgb(95,143,197),rgb(80,140,62),rgb(121,146,28),rgb(171,161,14),rgb(223,177,6),rgb(243,150,6),rgb(236,95,21),rgb(190,65,18),rgb(138,43,10),rgb(138,43,10));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-389ea886]{font-size:12px;text-align:center;color:var(--idm-white);width:32px}.legend-bars[data-v-db805141]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(76,165,228),rgb(76,165,228),rgb(76,165,228),rgb(76,165,228),rgb(103,180,186),rgb(129,204,197),rgb(150,209,216),rgb(180,209,216));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-db805141]{font-size:12px;text-align:center;color:var(--idm-white);width:40px}.point-meteo[data-v-ef7fa87d]{bottom:unset}.point-meteo .meteo-box[data-v-ef7fa87d]{position:absolute;color:var(--idm-black-8);top:0;left:5px;padding:10px;background-color:var(--idm-white-9);-webkit-backdrop-filter:blur(3px);backdrop-filter:blur(3px);width:260px;border-top-right-radius:5px;border-bottom-right-radius:5px;box-shadow:0 2px 12px #0003;z-index:2}.point-meteo .meteo-box .header-box[data-v-ef7fa87d]{margin-bottom:10px;box-sizing:border-box;color:var(--idm-black-8)}.point-meteo .meteo-box .header-box .close[data-v-ef7fa87d]{position:relative;height:0px;text-align:right;font-size:22px;color:var(--idm-primary-color)}.point-meteo .meteo-box .header-box .main[data-v-ef7fa87d]{font-size:16px}.point-meteo .meteo-box .header-box .sub[data-v-ef7fa87d]{margin:3px 0;font-size:12px;color:var(--idm-info-color)}.point-meteo .meteo-box .main-box[data-v-ef7fa87d]{padding:0 5px;border-radius:5px;background:var(--idm-gray-light)}.point-meteo .meteo-box .main-box .flex-space[data-v-ef7fa87d]{padding:3px 0;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--idm-white);box-sizing:border-box}.point-meteo .meteo-box .main-box .flex-space label[data-v-ef7fa87d]{color:var(--idm-black-8)}.point-meteo .meteo-box .main-box .flex-space label[data-v-ef7fa87d]:after{content:":"}.point-meteo .meteo-box .main-box .flex-space[data-v-ef7fa87d]:last-child{border-bottom:none}.point-meteo .meteo-box .more[data-v-ef7fa87d]{margin-top:5px;color:var(--idm-primary-color);font-weight:700;cursor:pointer}.point-meteo[data-v-ef7fa87d]:after{display:block;width:8px;height:8px;border-radius:50%;content:"";background-color:var(--idm-white-9);margin-bottom:360px}.point-meteo[data-v-ef7fa87d]:before{display:block;content:"";width:2px;height:360px;margin-left:3px;border-left:2px solid var(--idm-white-9)}#zone-info[data-v-c0864afc]{position:absolute;background:var(--idm-white);color:var(--idm-black-8);z-index:10}#zone-info .rich-context[data-v-c0864afc]{width:100vw;height:100vh;padding:10px;font-size:14px;font-weight:400;color:var(--idm-black-8)!important;overflow-y:auto}#zone-info .close[data-v-c0864afc]{position:relative;color:var(--idm-info-color-light2);font-size:24px;height:0;text-align:right;margin:5px 5px 0 0}#port-info[data-v-4ab013cc]{position:absolute;background:var(--idm-white);color:var(--idm-black-8);padding:10px;border-radius:6px;cursor:default;z-index:1000;height:fit-content}#port-info .port-box[data-v-4ab013cc]{margin-top:10px;max-width:240px}#port-info .port-box .flex-start[data-v-4ab013cc]{line-height:2}#port-info .port-box .flex-start label[data-v-4ab013cc]{color:var(--idm-info-color);margin-right:10px;width:50px}#port-info .port-box .flex-start span[data-v-4ab013cc]{flex:1;flex-wrap:wrap;text-align:justify-all;color:var(--idm-black-8)}#port-info .port-box .flex-start span.link[data-v-4ab013cc]{cursor:pointer;text-decoration:underline}#port-info .port-box .flex-start span.link[data-v-4ab013cc]:hover{font-weight:600}#port-info .close[data-v-4ab013cc]{position:relative;text-align:right;height:0px;color:var(--idm-info-color-light2);font-size:24px}.lat-lng-tip[data-v-7367f59b]{position:absolute;padding:2px 10px;border-radius:5px;color:var(--idm-primary-color);font-size:12px;top:unset;background:var(--idm-white);box-shadow:0 2px 12px #0003;transition:all .4s ease-in-out}.menu-bar-box[data-v-ab627b83]{display:flex;flex-direction:column;align-items:flex-end;justify-content:flex-start;transition:all .4s ease-in-out}.menu-bar-box .bar-item[data-v-ab627b83]{position:relative;margin-bottom:15px;border-radius:5px;background:var(--idm-white);cursor:pointer;box-shadow:0 2px 12px #0003}.menu-bar-box .bar-item .menu-icon[data-v-ab627b83]{padding:8px;display:flex}.menu-bar-box .bar-item .menu-icon[data-v-ab627b83]:first-child{border-top-left-radius:5px;border-top-right-radius:5px}.menu-bar-box .bar-item .menu-icon[data-v-ab627b83]:last-child{border-bottom-left-radius:5px;border-bottom-right-radius:5px}.menu-bar-box .bar-item .menu-icon span[data-v-ab627b83]{font-size:18px;font-weight:500;color:var(--idm-black-8)}.menu-bar-box .bar-item .menu-icon.active[data-v-ab627b83]{background:var(--idm-primary-color)}.menu-bar-box .bar-item .menu-icon.active span[data-v-ab627b83]{color:var(--idm-white)}:root{--idm-gl-box-shadow-color: rgba(0, 0, 0, .5);--idm-gl-box-shadow: 0px 12px 32px 4px rgba(0, 0, 0, .04), 0px 8px 20px rgba(0, 0, 0, .08);--idm-gl-box-shadow-light: 0px 0px 12px rgba(0, 0, 0, .12);--idm-gl-box-shadow-lighter: 0px 0px 6px rgba(0, 0, 0, .12);--idm-gl-box-shadow-dark: 0px 16px 48px 16px rgba(0, 0, 0, .08), 0px 12px 32px rgba(0, 0, 0, .12), 0px 8px 16px -8px rgba(0, 0, 0, .16)}.point-marker{pointer-events:none!important}.point-marker .marker-circle{pointer-events:inherit;width:12px;height:12px;border-radius:50%;border:2px solid var(--idm-white);background:var(--idm-danger-color)}.point-marker .marker-circle:hover{cursor:pointer}.point-marker.closed{pointer-events:auto!important}.point-summary-marker,.point-contextmenu-marker{color:var(--idm-white);font-size:12px;background:var(--idm-danger-color);border:2px solid var(--idm-white);padding:2px 5px;border-radius:5px;cursor:pointer}.point-summary-marker .marker-close,.point-contextmenu-marker .marker-close{pointer-events:auto;position:absolute;background:var(--idm-danger-color);border:1px dashed var(--idm-white);display:flex;align-items:center;justify-content:center;width:20px;height:20px;right:-17px;top:-17px;cursor:pointer;font-size:20px}.tip-marker{color:var(--idm-white);font-size:12px;text-shadow:var(--idm-text-shadow);background-color:var(--idm-black-6);padding:2px 5px;border-radius:5px;cursor:pointer}.tip-marker .marker-label{border-bottom:var(--idm-dashed-border)}.tip-marker .marker-label:last-child{border-bottom:none}.tip-marker .marker-label b{font-weight:600;color:var(--idm-danger-color)}.hurricane-hourly-marker .iconfont{font-size:34px!important;color:var(--idm-danger-color)}.hurricane-hourly-marker svg{height:34px;width:34px}.hurricane-hourly-marker .center{box-sizing:border-box;display:flex;align-items:center;justify-content:center}.hurricane-hourly-marker .center.north{animation:anticlockwise 2s linear infinite}.hurricane-hourly-marker .center.south{animation:clockwise 2s linear infinite}@keyframes clockwise{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes anticlockwise{0%{transform:rotate(0)}to{transform:rotate(-360deg)}}
|
|
1
|
+
@charset "UTF-8";:root{--idm-white: rgba(255, 255, 255, 1);--idm-white-9: rgba(255, 255, 255, .9);--idm-white-8: rgba(255, 255, 255, .8);--idm-white-7: rgba(255, 255, 255, .7);--idm-white-6: rgba(255, 255, 255, .6);--idm-white-5: rgba(255, 255, 255, .5);--idm-white-4: rgba(255, 255, 255, .4);--idm-white-3: rgba(255, 255, 255, .3);--idm-white-2: rgba(255, 255, 255, .2);--idm-white-1: rgba(255, 255, 255, .1);--idm-black: rgba(0, 0, 0, 1);--idm-black-9: rgba(0, 0, 0, .9);--idm-black-8: rgba(0, 0, 0, .8);--idm-black-7: rgba(0, 0, 0, .7);--idm-black-6: rgba(0, 0, 0, .6);--idm-black-5: rgba(0, 0, 0, .5);--idm-black-4: rgba(0, 0, 0, .4);--idm-black-3: rgba(0, 0, 0, .3);--idm-black-2: rgba(0, 0, 0, .2);--idm-black-1: rgba(0, 0, 0, .1);--idm-gray-light: rgba(239, 239, 239, 1);--idm-primary-color: rgba(42, 87, 183, 1);--idm-primary-color-light: #6c8ad9;--idm-primary-color-light2: #a7c4ff;--idm-primary-color-dark: #053a7e;--idm-primary-color-dark2: #002e6b;--idm-primary-color-9: rgba(42, 87, 183, .9);--idm-primary-color-8: rgba(42, 87, 183, .8);--idm-primary-color-7: rgba(42, 87, 183, .7);--idm-primary-color-6: rgba(42, 87, 183, .6);--idm-primary-color-5: rgba(42, 87, 183, .5);--idm-primary-color-4: rgba(42, 87, 183, .4);--idm-primary-color-3: rgba(42, 87, 183, .3);--idm-primary-color-2: rgba(42, 87, 183, .2);--idm-primary-color-1: rgba(42, 87, 183, .1);--idm-success-color: #0ddd9f;--idm-success-color-light: #92f7d9;--idm-success-color-dark: #06a074;--idm-success-color-dark2: #06694c;--idm-warning-color: #ff9500;--idm-warning-color-light: #ffcc00;--idm-warning-color-dark: #c77402;--idm-danger-color: #f44336;--idm-danger-color-light: #fb796e;--idm-danger-color-dark: #ad251b;--idm-info-color: #6e6e6e;--idm-info-color-light: #969696;--idm-info-color-light2: #c0c0c0;--idm-info-color-light3: #e2e2e2;--idm-info-color-dark: #494949;--idm-dangerous: #f44336;--idm-severe: #ff9500;--idm-heavy: #ffff00;--idm-vessel-cargo-color: lightgreen;--idm-vessel-tanker-color: red;--idm-vessel-passenger-color: blue;--idm-vessel-other-color: lightgrey;--idm-perf-cii-a: var(--idm-success-color);--idm-perf-cii-b: var(--idm-success-color-light);--idm-perf-cii-c: var(--idm-warning-color);--idm-perf-cii-d: var(--idm-danger-color-light);--idm-perf-cii-e: var(--idm-danger-color);--idm-tropicals-td: #03f869;--idm-tropicals-ts: #f2f202;--idm-tropicals-sts: #ff9100;--idm-tropicals-ty: #f44336;--idm-tropicals-sty: #f903d0;--idm-tropicals-super-ty: #8702f9;--idm-tropicals-r7: #ff9100;--idm-tropicals-r10: #f44336;--idm-text-shadow: 0px 0px 4px rgba(0, 0, 0, 1);--idm-dashed-border: 1px dashed var(--idm-white-5);--idm-solid-border: 1px solid var(--idm-white-4);--idm-background-color: var(--idm-primary-color-9);--idm-background-color-dark: var(--idm-primary-color-dark);--idm-background-color-light: var(--idm-primary-color-light);--idm-background-color-light2: #f3f5f8;--idm-active-background-light: linear-gradient(130deg, rgba(142, 163, 255, .93) 20%, rgb(90 67 193 / 93%) 100%);--idm-active-text-shadow-light: 0 0 7px rgb(194, 255, 247), 0 0 21px rgb(194, 255, 247), 0 0 30px rgba(182, 211, 207, .4), 0 0 12px rgba(15, 115, 223, .6), 0 0 22px rgba(15, 115, 223, .8), 0 0 38px rgba(15, 115, 223, .9), 0 0 60px rgba(15, 115, 223, 1);--idm-background-opaque-linear-gradient-top: linear-gradient(to top, rgba(41, 32, 165) 0%, rgba(44, 93, 184) 80%, rgba(32, 90, 165) 100%);--idm-background-linear-gradient-top: linear-gradient(to top, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-bottom: linear-gradient(to bottom, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-right: linear-gradient(to right, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-left: linear-gradient(to left, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-blink-animation: blink .8s ease-out infinite alternate}:root[colorTheme=black]{--idm-background-opaque-linear-gradient-top: linear-gradient(to top, rgba(0, 0, 0, .8) 0%, rgba(0, 0, 0, .8) 80%, rgb(0, 0, 0, .8) 100%);--idm-background-linear-gradient-top: linear-gradient(to top, rgba(0, 0, 0, .6) 0%, rgba(0, 0, 0, .7) 70%, rgb(0, 0, 0, .7) 100%);--idm-background-linear-gradient-bottom: linear-gradient(to top, rgba(0, 0, 0, .6) 0%, rgba(0, 0, 0, .7) 70%, rgb(0, 0, 0, .7) 100%);--idm-background-linear-gradient-right: linear-gradient(to top, rgba(0, 0, 0, .6) 0%, rgba(0, 0, 0, .7) 70%, rgb(0, 0, 0, .7) 100%);--idm-background-linear-gradient-left: linear-gradient(to top, rgba(0, 0, 0, .6) 0%, rgba(0, 0, 0, .7) 70%, rgb(0, 0, 0, .7) 100%);--idm-active-background-light: linear-gradient(130deg, rgba(117, 117, 117, .93) 30%, rgba(200, 200, 200, .93) 100%);--idm-active-text-shadow-light: 0 0 7px rgb(253, 253, 253), 0 0 21px rgb(226, 226, 226), 0 0 30px rgba(185, 185, 185, .4), 0 0 12px rgba(67, 67, 67, .6), 0 0 22px rgba(27, 27, 27, .8), 0 0 38px rgba(15, 115, 223, .9), 0 0 60px rgba(15, 115, 223, 1);--idm-primary-color: rgba(0, 0, 0, .7);--idm-primary-color-light: #757575;--idm-primary-color-light2: #a5a5a5;--idm-primary-color-dark: rgba(0, 0, 0, .8);--idm-primary-color-dark2: rgba(0, 0, 0, 1);--idm-primary-color-9: rgba(0, 0, 0, .9);--idm-primary-color-7: rgba(0, 0, 0, .7);--idm-primary-color-5: rgba(0, 0, 0, .5);--idm-primary-color-3: rgba(0, 0, 0, .3);--idm-primary-color-1: rgba(0, 0, 0, .1)}:root[colorTheme=blue]{--idm-background-opaque-linear-gradient-top: linear-gradient(to top, rgba(41, 32, 165) 0%, rgba(44, 93, 184) 80%, rgba(32, 90, 165) 100%);--idm-background-linear-gradient-top: linear-gradient(to top, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-bottom: linear-gradient(to bottom, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-right: linear-gradient(to right, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-background-linear-gradient-left: linear-gradient(to left, rgba(19, 23, 152, .85) 0%, rgba(44, 93, 184, .85) 80%, rgba(64, 110, 196, .85) 100%);--idm-active-background-light: linear-gradient(130deg, rgba(142, 163, 255, .93) 20%, rgb(90 67 193 / 93%) 100%);--idm-active-text-shadow-light: 0 0 7px rgb(194, 255, 247), 0 0 21px rgb(194, 255, 247), 0 0 30px rgba(182, 211, 207, .4), 0 0 12px rgba(15, 115, 223, .6), 0 0 22px rgba(15, 115, 223, .8), 0 0 38px rgba(15, 115, 223, .9), 0 0 60px rgba(15, 115, 223, 1);--idm-primary-color: rgba(42, 87, 183, 1);--idm-primary-color-light: #6c8ad9;--idm-primary-color-light2: #a7c4ff;--idm-primary-color-dark: #053a7e;--idm-primary-color-dark2: #002e6b;--idm-primary-color-9: rgba(42, 87, 183, .9);--idm-primary-color-8: rgba(42, 87, 183, .8);--idm-primary-color-7: rgba(42, 87, 183, .7);--idm-primary-color-6: rgba(42, 87, 183, .6);--idm-primary-color-5: rgba(42, 87, 183, .5);--idm-primary-color-4: rgba(42, 87, 183, .4);--idm-primary-color-3: rgba(42, 87, 183, .3);--idm-primary-color-2: rgba(42, 87, 183, .2);--idm-primary-color-1: rgba(42, 87, 183, .1)}:root[colorTheme=dark-blue]{--idm-background-opaque-linear-gradient-top: linear-gradient(to top, rgba(16, 22, 79, .85) 0%, rgba(15, 41, 89, .85) 80%, rgba(19, 47, 108, .85) 100%);--idm-background-linear-gradient-top: linear-gradient(to top, rgba(16, 22, 79, .85) 0%, rgba(15, 41, 89, .85) 80%, rgba(19, 47, 108, .85) 100%);--idm-background-linear-gradient-bottom: linear-gradient(to bottom, rgba(16, 22, 79, .85) 0%, rgba(15, 41, 89, .85) 80%, rgba(19, 47, 108, .85) 100%);--idm-background-linear-gradient-right: linear-gradient(to right, rgba(16, 22, 79, .85) 0%, rgba(15, 41, 89, .85) 80%, rgba(19, 47, 108, .85) 100%);--idm-background-linear-gradient-left: linear-gradient(to left, rgba(16, 22, 79, .85) 0%, rgba(15, 41, 89, .85) 80%, rgba(19, 47, 108, .85) 100%);--idm-active-background-light: linear-gradient(130deg, rgba(104, 104, 226, .93) 20%, rgba(22, 49, 182, .93) 100%);--idm-active-text-shadow-light: 0 0 7px rgb(194, 255, 247), 0 0 21px rgb(194, 255, 247), 0 0 30px rgba(182, 211, 207, .4), 0 0 12px rgba(15, 115, 223, .6), 0 0 22px rgba(15, 115, 223, .8), 0 0 38px rgba(15, 115, 223, .9), 0 0 60px rgba(15, 115, 223, 1);--idm-primary-color: rgba(42, 87, 183, 1);--idm-primary-color-light: #6266e0;--idm-primary-color-light2: #89b0ff;--idm-primary-color-dark: #00224e;--idm-primary-color-dark2: #021a39;--idm-primary-color-9: rgba(19, 47, 108, .9);--idm-primary-color-7: rgba(19, 47, 108, .7);--idm-primary-color-5: rgba(19, 47, 108, .5);--idm-primary-color-3: rgba(19, 47, 108, .3);--idm-primary-color-1: rgba(19, 47, 108, .1)}@font-face{font-family:iconfont;src:url(https://iconfont.idmwx.com/iconfont.woff2) format("woff2"),url(https://iconfont.idmwx.com/iconfont.woff) format("woff"),url(https://iconfont.idmwx.com/iconfont.ttf) format("truetype"),url(https://iconfont.idmwx.com/iconfont.svg?#iconfont) format("svg")}.iconfont{font-family:iconfont!important;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}*,*:before,*:after{box-sizing:border-box;margin:0}.text-ellipsis{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.flex-start{display:flex;align-items:center;justify-content:flex-start}.flex-end{display:flex;align-items:center;justify-content:flex-end}.flex-center{display:flex;align-items:center;justify-content:center}.flex-between,.flex-space{display:flex;align-items:center;justify-content:space-between}.flex-around{display:flex;align-items:center;justify-content:space-around}.flex-evenly{display:flex;align-items:center;justify-content:space-evenly}.flex-col-center-center{display:flex;flex-direction:column;justify-content:center;align-items:center}.flex-col-start-center{display:flex;flex-direction:column;justify-content:flex-start;align-items:center}.flex-col-end-center{display:flex;flex-direction:column;justify-content:flex-end;align-items:center}.flex-col-between-center{display:flex;flex-direction:column;justify-content:space-between;align-items:center}.flex-col-around-center{display:flex;flex-direction:column;justify-content:space-around;align-items:center}.flex-col-center-start{display:flex;flex-direction:column;justify-content:center;align-items:flex-start}.flex-col-center-end{display:flex;flex-direction:column;justify-content:center;align-items:flex-end}.flex{flex:1}.dropdown{position:relative;display:inline-block!important}.dropdown .dropdown-content{display:none;position:absolute;z-index:1}.dropdown:hover .dropdown-content{display:block}.loading{position:fixed;top:0;left:0;right:0;bottom:0;background:var(--idm-black-5);z-index:1000;display:flex;justify-content:center;align-items:center;flex-direction:column}.loading i{font-size:30px;color:var(--idm-white);margin-bottom:16px;animation:rotate 2s linear infinite}.loading div{color:var(--idm-white);font-size:16px}@keyframes blink{0%{box-shadow:0 0 20px var(--idm-warning-color-dark) inset}to{box-shadow:0 0 20px var(--idm-success-color) inset}}@keyframes rotate{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.idm-gl3-layer .fade-enter-active,.idm-gl3-layer .fade-leave-active{transition:opacity .4s}.idm-gl3-layer .fade-enter,.idm-gl3-layer .fade-leave-to{opacity:0}.idm-gl3-layer .menu-bar-box{position:absolute;overflow-y:hidden;box-sizing:border-box;display:flex;flex-direction:column;align-items:flex-end;justify-content:flex-start;transition:all .4s ease-in-out;z-index:2;border-radius:5px;box-shadow:0 2px 12px #0003}.idm-gl3-layer .menu-bar-box .bar-item{position:relative;border-radius:5px;background:var(--idm-white);cursor:pointer}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon{padding:8px;display:flex}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon:first-child{border-top-left-radius:5px;border-top-right-radius:5px}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon:last-child{border-bottom-left-radius:5px;border-bottom-right-radius:5px}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon span{font-size:20px;font-weight:600;color:var(--idm-black-8)}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon.active{background:var(--idm-primary-color)}.idm-gl3-layer .menu-bar-box .bar-item .menu-icon.active span{color:var(--idm-white)}.idm-gl3-layer .layer{cursor:pointer;display:inline-flex;align-items:center;padding:5px 0}.idm-gl3-layer .layer.disabled{cursor:not-allowed}.idm-gl3-layer .layer.disabled span{color:var(--idm-black-4)}.idm-gl3-layer .layer.disabled .checkbox{border:1px solid var(--idm-black-2)}.idm-gl3-layer .layer.active .checkbox{border:var(--idm-primary-color);background:var(--idm-primary-color)}.idm-gl3-layer .layer.active .checkbox:after{content:"✔";color:var(--idm-white);font-size:12px;display:flex;align-items:center;justify-content:center}.idm-gl3-layer .layer.active span{color:var(--idm-primary-color)}.idm-gl3-layer .layer .checkbox{width:16px;height:16px;margin-right:4px;border:1px solid var(--idm-black-8)}.idm-gl3-layer .layer span{color:var(--idm-black-8);font-size:14px;width:max-content}.idm-gl3-layer .other-bars{position:absolute;top:36px;border-radius:5px;background:var(--idm-background-linear-gradient-top);box-shadow:0 2px 12px #0003}.idm-gl3-layer .active-layers{position:absolute;max-width:250px;min-width:200px;display:flex;flex-wrap:wrap;align-items:center;background:var(--idm-white);border-radius:5px;box-shadow:0 2px 12px #0003;transition:all .4s ease-in-out}.idm-gl3-layer .active-layers .layer{width:auto;padding:5px}.idm-gl3-layer .available-layers{position:absolute;height:calc(100vh - 120px);box-sizing:border-box;transition:all .4s ease-in-out}.idm-gl3-layer .available-layers .side-bar{margin:0 10px;box-sizing:border-box}.idm-gl3-layer .available-layers .side-bar i{padding:15px 1px;background:var(--idm-white-7);border-radius:5px;cursor:pointer;font-size:18px;font-weight:600;color:var(--idm-black);box-shadow:0 2px 12px #0003}.idm-gl3-layer .available-layers .list-box{height:inherit;width:200px;padding:10px 0;overflow-y:auto;color:var(--idm-black-8);background:var(--idm-white);display:flex;flex-direction:column;box-shadow:0 2px 12px #0003;z-index:1}.idm-gl3-layer .available-layers .list-box .layers-title{font-size:16px;font-weight:600;padding:0 10px 10px;color:var(--idm-black-8);border-bottom:var(--idm-dashed-border)}.idm-gl3-layer .available-layers .list-box .layers-body{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-start;padding:0 10px;font-size:14px}.idm-gl3-layer .available-layers .list-box .layers-body .layer{width:140px}.idm-gl3-layer .available-layers .list-box .model-box{display:flex;align-items:center;justify-content:flex-start;margin:10px 0;cursor:pointer}.idm-gl3-layer .available-layers .list-box .model-box span{padding:3px 10px;border:1px solid #cecece}.idm-gl3-layer .available-layers .list-box .model-box span.active{color:var(--idm-white);border:1px solid var(--idm-primary-color);background:var(--idm-primary-color)}.idm-gl3-layer .available-layers .list-box .model-box span:first-child{border-top-left-radius:5px;border-bottom-left-radius:5px}.idm-gl3-layer .available-layers .list-box .model-box span:last-child{border-top-right-radius:5px;border-bottom-right-radius:5px;border-left:none}.tool-bars[data-v-b6fb74d9]{transition:all .4s ease-in-out}.tool-bars i[data-v-b6fb74d9]{cursor:pointer;font-size:30px;color:var(--idm-white-8);text-shadow:var(--idm-text-shadow)}.tool-bars i.active[data-v-b6fb74d9]{color:var(--idm-white)}.tool-bars span[data-v-b6fb74d9]{cursor:pointer;font-size:12px;color:var(--idm-black-8);margin-left:4px;background:var(--idm-white-8);padding:2px 4px;border-radius:5px;box-shadow:0 2px 12px #0003}.tool-bars span.active[data-v-b6fb74d9]{color:var(--idm-white);background:var(--idm-primary-color)}.legend-bars[data-v-41a686d0]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(98,113,184),rgb(98,113,184),rgb(98,113,184),rgb(98,113,184),rgb(61,110,163),rgb(74,148,170),rgb(74,146,148),rgb(77,142,124),rgb(76,164,76),rgb(103,164,54),rgb(162,135,64),rgb(162,109,92),rgb(141,63,92),rgb(151,75,145),rgb(95,100,160),rgb(91,136,161),rgb(91,136,161));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-41a686d0]{font-size:12px;text-align:center;color:var(--idm-white-8);width:32px}.tool-bars[data-v-ae630f43]{transition:all .4s ease-in-out}.tool-bars i[data-v-ae630f43]{cursor:pointer;font-size:30px;color:var(--idm-white-8);text-shadow:var(--idm-text-shadow)}.tool-bars i.active[data-v-ae630f43]{color:var(--idm-white)}.tool-bars span[data-v-ae630f43]{cursor:pointer;font-size:12px;color:var(--idm-black-8);margin-left:4px;background:var(--idm-white-8);padding:2px 4px;border-radius:5px;box-shadow:0 2px 12px #0003}.tool-bars span.active[data-v-ae630f43]{color:var(--idm-white);background:var(--idm-primary-color)}.legend-bars[data-v-9115889b]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(84,170,230),rgb(84,170,230),rgb(84,170,230),rgb(84,170,230),rgb(64,127,115),rgb(58,164,58),rgb(191,182,67),rgb(197,154,68),rgb(160,70,94),rgb(138,84,166),rgb(82,113,165),rgb(84,142,152),rgb(150,181,184),rgb(195,194,194),rgb(195,194,194));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-9115889b]{font-size:12px;text-align:center;color:var(--idm-white);width:36px}.active-tropical[data-v-08ecb5a5]{bottom:unset;background:var(--idm-white-9);padding:10px;border-radius:5px;box-shadow:0 2px 12px #0003;z-index:5}.active-tropical .header-box[data-v-08ecb5a5]{min-width:360px;margin-bottom:10px;box-sizing:border-box;color:var(--idm-black-8)}.active-tropical .header-box .close-btn[data-v-08ecb5a5]{position:relative;height:0px;text-align:right;font-size:22px;color:var(--idm-primary-color)}.active-tropical .header-box .main[data-v-08ecb5a5]{font-size:16px}.active-tropical .header-box .sub[data-v-08ecb5a5]{margin:3px 0;font-size:12px;color:var(--idm-info-color)}.active-tropical .main-box[data-v-08ecb5a5]{min-width:360px;color:var(--idm-black-8);overflow-y:auto;box-sizing:border-box;font-size:12px;z-index:4}.active-tropical .main-box .content[data-v-08ecb5a5]{padding:5px 0;border-radius:5px;background:var(--idm-gray-light)}.active-tropical .main-box .row[data-v-08ecb5a5]{width:100%;padding:4px 10px;box-sizing:border-box;display:flex;align-items:center;justify-content:space-between}.active-tropical .main-box .row .col[data-v-08ecb5a5]{display:flex;align-items:center;justify-content:space-between}.active-tropical .main-box .row .col label[data-v-08ecb5a5]{width:82px;margin-right:4px;color:var(--idm-info-color)}.active-tropical .main-box .row .col.col-24[data-v-08ecb5a5]{width:100%}.active-tropical .main-box .row .col.col-left[data-v-08ecb5a5]{width:55%}.active-tropical .main-box .row .col.col-right[data-v-08ecb5a5]{width:40%}.active-tropical .main-box .row .col .icon[data-v-08ecb5a5]{font-size:30px;color:var(--idm-black-4)}.active-tropical .main-box .row .col .icon.active[data-v-08ecb5a5]{color:var(--idm-primary-color)}.forecast-models[data-v-08ecb5a5]{display:flex;justify-content:flex-end;flex:1;margin-left:5px;flex-wrap:wrap}.forecast-models .model[data-v-08ecb5a5]{font-size:12px;padding:0 6px 4px;display:flex;border:1px solid var(--idm-primary-color)}.forecast-models .model span[data-v-08ecb5a5]{border-bottom:2px dashed var(--idm-white)}.forecast-models .model span.cma[data-v-08ecb5a5]{border-color:#e2ea03cc}.forecast-models .model span.jma[data-v-08ecb5a5]{border-color:#01d2b7cc}.forecast-models .model span.ecmwf[data-v-08ecb5a5]{border-color:#f582f2cc}.forecast-models .model span.ukm[data-v-08ecb5a5]{border-color:#f5bb47cc}.forecast-models .model span.noaa-at[data-v-08ecb5a5],.forecast-models .model span.noaa-ep[data-v-08ecb5a5]{border-color:#9758fbcc}.forecast-models .model.active[data-v-08ecb5a5]{border:1px solid var(--idm-primary-color);background-color:var(--idm-primary-color);color:var(--idm-white)}.forecast-models .model[data-v-08ecb5a5]:first-child{border-top-left-radius:4px;border-bottom-left-radius:4px}.forecast-models .model.center-child[data-v-08ecb5a5]{border-left:1px solid var(--idm-primary-color);border-right:1px solid var(--idm-primary-color)}.forecast-models .model[data-v-08ecb5a5]:last-child{border-top-right-radius:4px;border-bottom-right-radius:4px}.legend[data-v-08ecb5a5]{display:flex;align-items:center;color:var(--idm-info-color)}.legend .icon[data-v-08ecb5a5]{height:14px;width:14px;border-radius:50%;border:3px solid #fff;margin-right:3px}.legend .icon.td[data-v-08ecb5a5]{background-color:var(--idm-tropicals-td)}.legend .icon.ts[data-v-08ecb5a5]{background-color:var(--idm-tropicals-ts)}.legend .icon.sts[data-v-08ecb5a5]{background-color:var(--idm-tropicals-sts)}.legend .icon.ty[data-v-08ecb5a5]{background-color:var(--idm-tropicals-ty)}.legend .icon.sty[data-v-08ecb5a5]{background-color:var(--idm-tropicals-sty)}.legend .icon.supper-ty[data-v-08ecb5a5]{background-color:var(--idm-tropicals-super-ty)}.legend .icon.r7[data-v-08ecb5a5]{border:1.5px solid var(--idm-tropicals-r7)}.legend .icon.r10[data-v-08ecb5a5]{border:1.5px solid var(--idm-tropicals-r10)}.legend .icon.history[data-v-08ecb5a5]{border:none;border-radius:0;height:4px;background:var(--idm-black-5)}.legend .button[data-v-08ecb5a5]{cursor:pointer;padding:0 4px;border-radius:4px;border:1px solid var(--idm-primary-color);color:var(--idm-primary-color)}.more[data-v-08ecb5a5]{display:flex;align-items:center;justify-content:flex-end;color:var(--idm-primary-color);font-weight:700;margin-top:5px}.legend-bars[data-v-dec867b8]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgba(59,126,162,0),rgb(172,210,255),rgb(172,210,255),rgb(3,248,103),rgb(14,201,3),rgb(190,226,2),rgb(248,1,1),rgb(197,5,58),rgb(197,5,58));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-dec867b8]{font-size:12px;text-align:center;color:var(--idm-white);width:35px}.legend-bars[data-v-952dee5c]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(189,50,160),rgb(189,50,160),rgb(189,50,160),rgb(189,50,160),rgb(208,56,56),rgb(208,56,56),rgb(190,226,2),rgb(190,226,2),rgb(4,210,64),rgb(4,210,64),rgb(172,210,255),rgb(172,210,255));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-952dee5c]{font-size:12px;text-align:center;color:var(--idm-white);width:40px}.legend-bars[data-v-67e5094b]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(95,143,197),rgb(95,143,197),rgb(95,143,197),rgb(95,143,197),rgb(80,140,62),rgb(121,146,28),rgb(171,161,14),rgb(223,177,6),rgb(243,150,6),rgb(236,95,21),rgb(190,65,18),rgb(138,43,10),rgb(138,43,10));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-67e5094b]{font-size:12px;text-align:center;color:var(--idm-white);width:32px}.legend-bars[data-v-389ea886]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(149,137,211),rgb(149,137,211),rgb(149,137,211),rgb(149,137,211),rgb(150,209,216),rgb(129,204,197),rgb(103,180,186),rgb(95,143,197),rgb(80,140,62),rgb(121,146,28),rgb(171,161,14),rgb(223,177,6),rgb(243,150,6),rgb(236,95,21),rgb(190,65,18),rgb(138,43,10),rgb(138,43,10));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-389ea886]{font-size:12px;text-align:center;color:var(--idm-white);width:32px}.legend-bars[data-v-db805141]{transition:all .4s ease-in-out;background:linear-gradient(to right,rgb(76,165,228),rgb(76,165,228),rgb(76,165,228),rgb(76,165,228),rgb(103,180,186),rgb(129,204,197),rgb(150,209,216),rgb(180,209,216));padding:2px 0;border-radius:10px;box-shadow:var(--idm-gl-box-shadow)}.legend-bars span[data-v-db805141]{font-size:12px;text-align:center;color:var(--idm-white);width:40px}.point-meteo[data-v-97102c3b]{bottom:unset}.point-meteo .meteo-box[data-v-97102c3b]{position:absolute;color:var(--idm-black-8);top:0;left:5px;padding:10px;background-color:var(--idm-white-9);-webkit-backdrop-filter:blur(3px);backdrop-filter:blur(3px);width:260px;border-top-right-radius:5px;border-bottom-right-radius:5px;box-shadow:0 2px 12px #0003;z-index:2}.point-meteo .meteo-box .header-box[data-v-97102c3b]{margin-bottom:10px;box-sizing:border-box;color:var(--idm-black-8)}.point-meteo .meteo-box .header-box .close[data-v-97102c3b]{position:relative;height:0px;text-align:right;font-size:22px;color:var(--idm-primary-color)}.point-meteo .meteo-box .header-box .main[data-v-97102c3b]{font-size:16px}.point-meteo .meteo-box .header-box .sub[data-v-97102c3b]{margin:3px 0;font-size:12px;color:var(--idm-info-color)}.point-meteo .meteo-box .main-box[data-v-97102c3b]{padding:0 5px;border-radius:5px;background:var(--idm-gray-light)}.point-meteo .meteo-box .main-box .flex-space[data-v-97102c3b]{padding:3px 0;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--idm-white);box-sizing:border-box}.point-meteo .meteo-box .main-box .flex-space label[data-v-97102c3b]{color:var(--idm-black-8)}.point-meteo .meteo-box .main-box .flex-space label[data-v-97102c3b]:after{content:":"}.point-meteo .meteo-box .main-box .flex-space[data-v-97102c3b]:last-child{border-bottom:none}.point-meteo .meteo-box .more[data-v-97102c3b]{margin-top:5px;color:var(--idm-primary-color);font-weight:700;cursor:pointer}.point-meteo[data-v-97102c3b]:after{display:block;width:8px;height:8px;border-radius:50%;content:"";background-color:var(--idm-white-9);margin-bottom:360px}.point-meteo[data-v-97102c3b]:before{display:block;content:"";width:2px;height:360px;margin-left:3px;border-left:2px solid var(--idm-white-9)}#zone-info[data-v-c0864afc]{position:absolute;background:var(--idm-white);color:var(--idm-black-8);z-index:10}#zone-info .rich-context[data-v-c0864afc]{width:100vw;height:100vh;padding:10px;font-size:14px;font-weight:400;color:var(--idm-black-8)!important;overflow-y:auto}#zone-info .close[data-v-c0864afc]{position:relative;color:var(--idm-info-color-light2);font-size:24px;height:0;text-align:right;margin:5px 5px 0 0}#port-info[data-v-4ab013cc]{position:absolute;background:var(--idm-white);color:var(--idm-black-8);padding:10px;border-radius:6px;cursor:default;z-index:1000;height:fit-content}#port-info .port-box[data-v-4ab013cc]{margin-top:10px;max-width:240px}#port-info .port-box .flex-start[data-v-4ab013cc]{line-height:2}#port-info .port-box .flex-start label[data-v-4ab013cc]{color:var(--idm-info-color);margin-right:10px;width:50px}#port-info .port-box .flex-start span[data-v-4ab013cc]{flex:1;flex-wrap:wrap;text-align:justify-all;color:var(--idm-black-8)}#port-info .port-box .flex-start span.link[data-v-4ab013cc]{cursor:pointer;text-decoration:underline}#port-info .port-box .flex-start span.link[data-v-4ab013cc]:hover{font-weight:600}#port-info .close[data-v-4ab013cc]{position:relative;text-align:right;height:0px;color:var(--idm-info-color-light2);font-size:24px}.lat-lng-tip[data-v-7367f59b]{position:absolute;padding:2px 10px;border-radius:5px;color:var(--idm-primary-color);font-size:12px;top:unset;background:var(--idm-white);box-shadow:0 2px 12px #0003;transition:all .4s ease-in-out}.menu-bar-box[data-v-ab627b83]{display:flex;flex-direction:column;align-items:flex-end;justify-content:flex-start;transition:all .4s ease-in-out}.menu-bar-box .bar-item[data-v-ab627b83]{position:relative;margin-bottom:15px;border-radius:5px;background:var(--idm-white);cursor:pointer;box-shadow:0 2px 12px #0003}.menu-bar-box .bar-item .menu-icon[data-v-ab627b83]{padding:8px;display:flex}.menu-bar-box .bar-item .menu-icon[data-v-ab627b83]:first-child{border-top-left-radius:5px;border-top-right-radius:5px}.menu-bar-box .bar-item .menu-icon[data-v-ab627b83]:last-child{border-bottom-left-radius:5px;border-bottom-right-radius:5px}.menu-bar-box .bar-item .menu-icon span[data-v-ab627b83]{font-size:18px;font-weight:500;color:var(--idm-black-8)}.menu-bar-box .bar-item .menu-icon.active[data-v-ab627b83]{background:var(--idm-primary-color)}.menu-bar-box .bar-item .menu-icon.active span[data-v-ab627b83]{color:var(--idm-white)}:root{--idm-gl-box-shadow-color: rgba(0, 0, 0, .5);--idm-gl-box-shadow: 0px 12px 32px 4px rgba(0, 0, 0, .04), 0px 8px 20px rgba(0, 0, 0, .08);--idm-gl-box-shadow-light: 0px 0px 12px rgba(0, 0, 0, .12);--idm-gl-box-shadow-lighter: 0px 0px 6px rgba(0, 0, 0, .12);--idm-gl-box-shadow-dark: 0px 16px 48px 16px rgba(0, 0, 0, .08), 0px 12px 32px rgba(0, 0, 0, .12), 0px 8px 16px -8px rgba(0, 0, 0, .16)}.point-marker{pointer-events:none!important}.point-marker .marker-circle{pointer-events:inherit;width:12px;height:12px;border-radius:50%;border:2px solid var(--idm-white);background:var(--idm-danger-color)}.point-marker .marker-circle:hover{cursor:pointer}.point-marker.closed{pointer-events:auto!important}.point-summary-marker,.point-contextmenu-marker{color:var(--idm-white);font-size:12px;background:var(--idm-danger-color);border:2px solid var(--idm-white);padding:2px 5px;border-radius:5px;cursor:pointer}.point-summary-marker .marker-close,.point-contextmenu-marker .marker-close{pointer-events:auto;position:absolute;background:var(--idm-danger-color);border:1px dashed var(--idm-white);display:flex;align-items:center;justify-content:center;width:20px;height:20px;right:-17px;top:-17px;cursor:pointer;font-size:20px}.tip-marker{color:var(--idm-white);font-size:12px;text-shadow:var(--idm-text-shadow);background-color:var(--idm-black-6);padding:2px 5px;border-radius:5px;cursor:pointer}.tip-marker .marker-label{border-bottom:var(--idm-dashed-border)}.tip-marker .marker-label:last-child{border-bottom:none}.tip-marker .marker-label b{font-weight:600;color:var(--idm-danger-color)}.hurricane-hourly-marker .iconfont{font-size:34px!important;color:var(--idm-danger-color)}.hurricane-hourly-marker svg{height:34px;width:34px}.hurricane-hourly-marker .center{box-sizing:border-box;display:flex;align-items:center;justify-content:center}.hurricane-hourly-marker .center.north{animation:anticlockwise 2s linear infinite}.hurricane-hourly-marker .center.south{animation:clockwise 2s linear infinite}@keyframes clockwise{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes anticlockwise{0%{transform:rotate(0)}to{transform:rotate(-360deg)}}
|