nxd-plugin 1.5.1 → 1.5.3

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.
Files changed (20) hide show
  1. package/dist/chunks/{component-HighWayFreeze-Bu_esAjA.mjs → component-HighWayFreeze-Ckh45dhq.mjs} +338 -302
  2. package/dist/chunks/{component-HighwayLiveAlarm-D5A8U6nr.mjs → component-HighwayLiveAlarm-BJQZsDZ2.mjs} +69 -69
  3. package/dist/chunks/{component-HighwayLiveAlarmNew-CxvMvtxs.mjs → component-HighwayLiveAlarmNew-C5_-1nLA.mjs} +103 -103
  4. package/dist/chunks/{component-HighwayStations-EkqsQMyT.mjs → component-HighwayStations-C0dO_r1R.mjs} +2 -2
  5. package/dist/chunks/{component-HighwayWeatherForecast-BevrRin0.mjs → component-HighwayWeatherForecast-shTrLuFz.mjs} +1 -1
  6. package/dist/chunks/{component-ImageGeneration-lgL5b_fS.mjs → component-ImageGeneration-BNWh-LrZ.mjs} +219 -219
  7. package/dist/chunks/{component-LithiumBatteryMiningArea-BGW8lyaE.mjs → component-LithiumBatteryMiningArea-CAWkyWzC.mjs} +2 -2
  8. package/dist/chunks/component-RadarShortTerm-Csx21bzr.mjs +1148 -0
  9. package/dist/chunks/{component-ServiceMaterialsBtn-BdGlr36l.mjs → component-ServiceMaterialsBtn-DAtuOkqp.mjs} +54 -54
  10. package/dist/chunks/{component-TimeBasedForecast-BWXd609e.mjs → component-TimeBasedForecast-XI_q_qXB.mjs} +4 -4
  11. package/dist/chunks/{component-WeatherForecast-BvNqw-L8.mjs → component-WeatherForecast-1gjqAkui.mjs} +2 -2
  12. package/dist/chunks/{component-YCHome-nB5SMh8D.mjs → component-YCHome-ClXcF7Y4.mjs} +435 -435
  13. package/dist/chunks/{component-YCLogin-Wj7pyIOq.mjs → component-YCLogin-cziiUlrT.mjs} +6 -6
  14. package/dist/chunks/{component-YCLoginNew-a9ZNeE3r.mjs → component-YCLoginNew-vzP6cN1o.mjs} +7 -7
  15. package/dist/nxd-plugin.mjs +16 -16
  16. package/dist/styles/component-RadarShortTerm.css +1 -1
  17. package/dist/styles/component-YCLogin.css +1 -1
  18. package/dist/styles/component-YCLoginNew.css +1 -1
  19. package/package.json +1 -1
  20. package/dist/chunks/component-RadarShortTerm-nye0qx9X.mjs +0 -267
@@ -0,0 +1,1148 @@
1
+ import "./rolldown-runtime-Dd0fQ6-X.mjs";
2
+ import { B as e, C as t, G as n, J as r, L as i, N as a, P as o, Q as s, S as c, Y as l, at as u, b as d, c as f, d as p, i as m, it as h, j as ee, k as g, l as _, m as v, ot as y, st as b, u as x } from "./component-HighWayFreeze-Ckh45dhq.mjs";
3
+ import { D as S, F as C, L as w, Nt as T, O as E, Pt as te, T as D, Ut as O, _ as ne, g as k, i as A, n as j, p as M, r as N, tn as P, w as F, z as I } from "./component-HighWayEarlyWarningRed-C4eUxLai.mjs";
4
+ import { i as re, o as ie } from "./component-ImageGeneration-BNWh-LrZ.mjs";
5
+ import { n as ae } from "./component-HighwayLiveAlarmNew-C5_-1nLA.mjs";
6
+ import { Fragment as L, computed as R, createBlock as z, createCommentVNode as B, createElementBlock as V, createElementVNode as H, createSlots as oe, createTextVNode as U, createVNode as W, defineComponent as G, h as K, inject as se, nextTick as q, normalizeClass as J, normalizeStyle as ce, onBeforeUnmount as le, onMounted as ue, onUpdated as de, openBlock as Y, provide as fe, reactive as pe, ref as X, renderList as me, renderSlot as he, shallowRef as ge, toDisplayString as Z, toRefs as _e, unref as Q, vShow as ve, watch as ye, watchEffect as be, withCtx as $, withDirectives as xe, withKeys as Se, withModifiers as Ce } from "vue";
7
+ var we = "_RepeatClick", Te = {
8
+ beforeMount(e, t) {
9
+ let n = t.value, { interval: r = 100, delay: i = 600 } = te(n) ? {} : n, a, o, s = () => te(n) ? n() : n.handler(), c = () => {
10
+ o &&= (clearTimeout(o), void 0), a &&= (clearInterval(a), void 0);
11
+ }, l = (e) => {
12
+ e.button === 0 && (c(), s(), document.addEventListener("mouseup", c, { once: !0 }), o = setTimeout(() => {
13
+ a = setInterval(() => {
14
+ s();
15
+ }, r);
16
+ }, i));
17
+ };
18
+ e[we] = {
19
+ start: l,
20
+ clear: c
21
+ }, e.addEventListener("mousedown", l);
22
+ },
23
+ unmounted(e) {
24
+ if (!e[we]) return;
25
+ let { start: t, clear: n } = e[we];
26
+ t && e.removeEventListener("mousedown", t), n && (n(), document.removeEventListener("mouseup", n)), e[we] = null;
27
+ }
28
+ }, Ee = S({
29
+ id: {
30
+ type: String,
31
+ default: void 0
32
+ },
33
+ step: {
34
+ type: Number,
35
+ default: 1
36
+ },
37
+ stepStrictly: Boolean,
38
+ max: {
39
+ type: Number,
40
+ default: 2 ** 53 - 1
41
+ },
42
+ min: {
43
+ type: Number,
44
+ default: -(2 ** 53 - 1)
45
+ },
46
+ modelValue: { type: [Number, null] },
47
+ readonly: Boolean,
48
+ disabled: {
49
+ type: Boolean,
50
+ default: void 0
51
+ },
52
+ size: M,
53
+ controls: {
54
+ type: Boolean,
55
+ default: !0
56
+ },
57
+ controlsPosition: {
58
+ type: String,
59
+ default: "",
60
+ values: ["", "right"]
61
+ },
62
+ valueOnClear: {
63
+ type: E([
64
+ String,
65
+ Number,
66
+ null
67
+ ]),
68
+ validator: (e) => e === null || C(e) || ["min", "max"].includes(e),
69
+ default: null
70
+ },
71
+ name: String,
72
+ placeholder: String,
73
+ precision: {
74
+ type: Number,
75
+ validator: (e) => e >= 0 && e === Number.parseInt(`${e}`, 10)
76
+ },
77
+ validateEvent: {
78
+ type: Boolean,
79
+ default: !0
80
+ },
81
+ ...e(["ariaLabel"]),
82
+ inputmode: {
83
+ type: E(String),
84
+ default: void 0
85
+ },
86
+ align: {
87
+ type: E(String),
88
+ default: "center"
89
+ },
90
+ disabledScientific: Boolean
91
+ }), De = {
92
+ [h]: (e, t) => t !== e,
93
+ blur: (e) => e instanceof FocusEvent,
94
+ focus: (e) => e instanceof FocusEvent,
95
+ [u]: (e) => C(e) || I(e),
96
+ [y]: (e) => C(e) || I(e)
97
+ }, Oe = ["aria-label"], ke = ["aria-label"], Ae = i(/* @__PURE__ */ G({
98
+ name: "ElInputNumber",
99
+ __name: "input-number",
100
+ props: Ee,
101
+ emits: De,
102
+ setup(e, { expose: n, emit: i }) {
103
+ let a = e, o = i, { t: s } = ne(), c = k("input-number"), m = X(), _ = pe({
104
+ currentValue: a.modelValue,
105
+ userInput: null
106
+ }), { formItem: S } = f(), T = R(() => C(a.modelValue) && a.modelValue <= a.min), E = R(() => C(a.modelValue) && a.modelValue >= a.max), te = R(() => {
107
+ let e = ie(a.step);
108
+ return w(a.precision) ? Math.max(ie(a.modelValue), e) : (e > a.precision && F("InputNumber", "precision should not be less than the decimal places of step"), a.precision);
109
+ }), A = R(() => a.controls && a.controlsPosition === "right"), j = p(), M = x(), N = R(() => {
110
+ if (_.userInput !== null) return _.userInput;
111
+ let e = _.currentValue;
112
+ if (I(e)) return "";
113
+ if (C(e)) {
114
+ if (Number.isNaN(e)) return "";
115
+ w(a.precision) || (e = e.toFixed(a.precision));
116
+ }
117
+ return e;
118
+ }), P = (e, t) => {
119
+ if (w(t) && (t = te.value), t === 0) return Math.round(e);
120
+ let n = String(e), r = n.indexOf(".");
121
+ if (r === -1 || !n.replace(".", "").split("")[r + t]) return e;
122
+ let i = n.length;
123
+ return n.charAt(i - 1) === "5" && (n = `${n.slice(0, Math.max(0, i - 1))}6`), Number.parseFloat(Number(n).toFixed(t));
124
+ }, ie = (e) => {
125
+ if (I(e)) return 0;
126
+ let t = e.toString(), n = t.indexOf("."), r = 0;
127
+ return n !== -1 && (r = t.length - n - 1), r;
128
+ }, ae = (e, t = 1) => C(e) ? e >= 2 ** 53 - 1 && t === 1 ? (F("InputNumber", "The value has reached the maximum safe integer limit."), e) : e <= -(2 ** 53 - 1) && t === -1 ? (F("InputNumber", "The value has reached the minimum safe integer limit."), e) : P(e + a.step * t) : _.currentValue, L = (e) => {
129
+ let t = r(e), n = l(e);
130
+ if (a.disabledScientific && ["e", "E"].includes(n)) {
131
+ e.preventDefault();
132
+ return;
133
+ }
134
+ switch (t) {
135
+ case b.up:
136
+ e.preventDefault(), H();
137
+ break;
138
+ case b.down:
139
+ e.preventDefault(), U();
140
+ break;
141
+ }
142
+ }, H = () => {
143
+ a.readonly || M.value || E.value || (K(ae(Number(N.value) || 0)), o(u, _.currentValue), ge());
144
+ }, U = () => {
145
+ a.readonly || M.value || T.value || (K(ae(Number(N.value) || 0, -1)), o(u, _.currentValue), ge());
146
+ }, G = (e, t) => {
147
+ let { max: n, min: r, step: i, precision: s, stepStrictly: c, valueOnClear: l } = a;
148
+ n < r && D("InputNumber", "min should not be greater than max.");
149
+ let u = Number(e);
150
+ if (I(e) || Number.isNaN(u)) return null;
151
+ if (e === "") {
152
+ if (l === null) return null;
153
+ u = O(l) ? {
154
+ min: r,
155
+ max: n
156
+ }[l] : l;
157
+ }
158
+ return c && (u = P(Math.round(P(u / i)) * i, s), u !== e && t && o("update:modelValue", u)), w(s) || (u = P(u, s)), (u > n || u < r) && (u = u > n ? n : r, t && o("update:modelValue", u)), u;
159
+ }, K = (e, t = !0) => {
160
+ let n = _.currentValue, r = G(e);
161
+ if (!t) {
162
+ o(y, r);
163
+ return;
164
+ }
165
+ _.userInput = null, !(n === r && e) && (o(y, r), n !== r && o(h, r, n), a.validateEvent && S?.validate?.("change").catch((e) => F(e)), _.currentValue = r);
166
+ }, se = (e) => {
167
+ _.userInput = e;
168
+ let t = e === "" ? null : Number(e);
169
+ o(u, t), K(t, !1);
170
+ }, q = (e) => {
171
+ let t = e === "" ? "" : Number(e);
172
+ (C(t) && !Number.isNaN(t) || e === "") && K(t), ge(), _.userInput = null;
173
+ }, ce = () => {
174
+ m.value?.focus?.();
175
+ }, le = () => {
176
+ m.value?.blur?.();
177
+ }, fe = (e) => {
178
+ o("focus", e);
179
+ }, me = (e) => {
180
+ _.userInput = null, _.currentValue === null && m.value?.input && (m.value.input.value = ""), o("blur", e), a.validateEvent && S?.validate?.("blur").catch((e) => F(e));
181
+ }, ge = () => {
182
+ _.currentValue !== a.modelValue && (_.currentValue = a.modelValue);
183
+ }, Z = (e) => {
184
+ document.activeElement === e.target && e.preventDefault();
185
+ };
186
+ return ye(() => a.modelValue, (e, t) => {
187
+ let n = G(e, !0);
188
+ _.userInput === null && n !== t && (_.currentValue = n);
189
+ }, { immediate: !0 }), ye(() => a.precision, () => {
190
+ _.currentValue = G(a.modelValue);
191
+ }), ue(() => {
192
+ let { min: e, max: t, modelValue: n } = a, r = m.value?.input;
193
+ if (r.setAttribute("role", "spinbutton"), Number.isFinite(t) ? r.setAttribute("aria-valuemax", String(t)) : r.removeAttribute("aria-valuemax"), Number.isFinite(e) ? r.setAttribute("aria-valuemin", String(e)) : r.removeAttribute("aria-valuemin"), r.setAttribute("aria-valuenow", _.currentValue || _.currentValue === 0 ? String(_.currentValue) : ""), r.setAttribute("aria-disabled", String(M.value)), !C(n) && n != null) {
194
+ let e = Number(n);
195
+ Number.isNaN(e) && (e = null), o(y, e);
196
+ }
197
+ r.addEventListener("wheel", Z, { passive: !1 });
198
+ }), de(() => {
199
+ (m.value?.input)?.setAttribute("aria-valuenow", `${_.currentValue ?? ""}`);
200
+ }), n({
201
+ focus: ce,
202
+ blur: le
203
+ }), (n, r) => (Y(), V("div", {
204
+ class: J([
205
+ Q(c).b(),
206
+ Q(c).m(Q(j)),
207
+ Q(c).is("disabled", Q(M)),
208
+ Q(c).is("without-controls", !e.controls),
209
+ Q(c).is("controls-right", A.value),
210
+ Q(c).is(e.align, !!e.align)
211
+ ]),
212
+ onDragstart: r[0] ||= Ce(() => {}, ["prevent"])
213
+ }, [
214
+ e.controls ? xe((Y(), V("span", {
215
+ key: 0,
216
+ role: "button",
217
+ "aria-label": Q(s)("el.inputNumber.decrease"),
218
+ class: J([Q(c).e("decrease"), Q(c).is("disabled", T.value)]),
219
+ onKeydown: Se(U, ["enter"])
220
+ }, [he(n.$slots, "decrease-icon", {}, () => [W(Q(v), null, {
221
+ default: $(() => [A.value ? (Y(), z(Q(d), { key: 0 })) : (Y(), z(Q(g), { key: 1 }))]),
222
+ _: 1
223
+ })])], 42, Oe)), [[Q(Te), U]]) : B("v-if", !0),
224
+ e.controls ? xe((Y(), V("span", {
225
+ key: 1,
226
+ role: "button",
227
+ "aria-label": Q(s)("el.inputNumber.increase"),
228
+ class: J([Q(c).e("increase"), Q(c).is("disabled", E.value)]),
229
+ onKeydown: Se(H, ["enter"])
230
+ }, [he(n.$slots, "increase-icon", {}, () => [W(Q(v), null, {
231
+ default: $(() => [A.value ? (Y(), z(Q(t), { key: 0 })) : (Y(), z(Q(ee), { key: 1 }))]),
232
+ _: 1
233
+ })])], 42, ke)), [[Q(Te), H]]) : B("v-if", !0),
234
+ W(Q(re), {
235
+ id: e.id,
236
+ ref_key: "input",
237
+ ref: m,
238
+ type: "number",
239
+ step: e.step,
240
+ "model-value": N.value,
241
+ placeholder: e.placeholder,
242
+ readonly: e.readonly,
243
+ disabled: Q(M),
244
+ size: Q(j),
245
+ max: e.max,
246
+ min: e.min,
247
+ name: e.name,
248
+ "aria-label": e.ariaLabel,
249
+ "validate-event": !1,
250
+ inputmode: e.inputmode,
251
+ onKeydown: L,
252
+ onBlur: me,
253
+ onFocus: fe,
254
+ onInput: se,
255
+ onChange: q
256
+ }, oe({ _: 2 }, [n.$slots.prefix ? {
257
+ name: "prefix",
258
+ fn: $(() => [he(n.$slots, "prefix")]),
259
+ key: "0"
260
+ } : void 0, n.$slots.suffix ? {
261
+ name: "suffix",
262
+ fn: $(() => [he(n.$slots, "suffix")]),
263
+ key: "1"
264
+ } : void 0]), 1032, [
265
+ "id",
266
+ "step",
267
+ "model-value",
268
+ "placeholder",
269
+ "readonly",
270
+ "disabled",
271
+ "size",
272
+ "max",
273
+ "min",
274
+ "name",
275
+ "aria-label",
276
+ "inputmode"
277
+ ])
278
+ ], 34));
279
+ }
280
+ })), je = Symbol("sliderContextKey"), Me = S({
281
+ modelValue: {
282
+ type: E([Number, Array]),
283
+ default: 0
284
+ },
285
+ id: {
286
+ type: String,
287
+ default: void 0
288
+ },
289
+ min: {
290
+ type: Number,
291
+ default: 0
292
+ },
293
+ max: {
294
+ type: Number,
295
+ default: 100
296
+ },
297
+ step: {
298
+ type: E([Number, String]),
299
+ default: 1
300
+ },
301
+ showInput: Boolean,
302
+ showInputControls: {
303
+ type: Boolean,
304
+ default: !0
305
+ },
306
+ size: M,
307
+ inputSize: M,
308
+ showStops: Boolean,
309
+ showTooltip: {
310
+ type: Boolean,
311
+ default: !0
312
+ },
313
+ formatTooltip: {
314
+ type: E(Function),
315
+ default: void 0
316
+ },
317
+ disabled: {
318
+ type: Boolean,
319
+ default: void 0
320
+ },
321
+ range: Boolean,
322
+ vertical: Boolean,
323
+ height: String,
324
+ rangeStartLabel: {
325
+ type: String,
326
+ default: void 0
327
+ },
328
+ rangeEndLabel: {
329
+ type: String,
330
+ default: void 0
331
+ },
332
+ formatValueText: {
333
+ type: E(Function),
334
+ default: void 0
335
+ },
336
+ tooltipClass: {
337
+ type: String,
338
+ default: void 0
339
+ },
340
+ placement: {
341
+ type: String,
342
+ values: n,
343
+ default: "top"
344
+ },
345
+ marks: { type: E(Object) },
346
+ validateEvent: {
347
+ type: Boolean,
348
+ default: !0
349
+ },
350
+ persistent: {
351
+ type: Boolean,
352
+ default: !0
353
+ },
354
+ ...e(["ariaLabel"])
355
+ }), Ne = (e) => C(e) || T(e) && e.every(C), Pe = {
356
+ [y]: Ne,
357
+ [u]: Ne,
358
+ [h]: Ne
359
+ }, Fe = (e, t, n) => {
360
+ let r = X();
361
+ return ue(async () => {
362
+ e.range ? (T(e.modelValue) ? (t.firstValue = Math.max(e.min, e.modelValue[0]), t.secondValue = Math.min(e.max, e.modelValue[1])) : (t.firstValue = e.min, t.secondValue = e.max), t.oldValue = [t.firstValue, t.secondValue]) : (!C(e.modelValue) || Number.isNaN(e.modelValue) ? t.firstValue = e.min : t.firstValue = Math.min(e.max, Math.max(e.min, e.modelValue)), t.oldValue = t.firstValue), P(window, "resize", n), await q(), n();
363
+ }), { sliderWrapper: r };
364
+ }, Ie = (e) => {
365
+ let t = R(() => e.marks ? Object.keys(e.marks).map(Number.parseFloat).sort((e, t) => e - t).filter((t) => t <= e.max && t >= e.min).map((t) => ({
366
+ point: t,
367
+ position: (t - e.min) * 100 / (e.max - e.min),
368
+ mark: e.marks[t]
369
+ })) : []);
370
+ return be(() => {
371
+ if (e.step === "mark" && !e.marks && F("ElSlider", "marks prop must be provided when step is mark"), e.marks) {
372
+ let n = Object.keys(e.marks), r = t.value.map((e) => e.point), i = n.filter((e) => {
373
+ let t = Number.parseFloat(e);
374
+ return Number.isNaN(t) || !r.includes(t);
375
+ });
376
+ i.length > 0 && F("ElSlider", `Some marks keys are invalid (not a number or out of [min, max]): [${i.map((e) => `'${e}'`).join(", ")}] and will be ignored.`);
377
+ }
378
+ }), t;
379
+ }, Le = (e, t, n) => {
380
+ let { formItem: r } = f(), i = ge(), a = X(), o = X(), s = {
381
+ firstButton: a,
382
+ secondButton: o
383
+ }, c = x(), l = R(() => Math.min(t.firstValue, t.secondValue)), d = R(() => Math.max(t.firstValue, t.secondValue)), p = R(() => e.range ? `${100 * (d.value - l.value) / (e.max - e.min)}%` : `${100 * (t.firstValue - e.min) / (e.max - e.min)}%`), m = R(() => e.range ? `${100 * (l.value - e.min) / (e.max - e.min)}%` : "0%"), ee = R(() => e.vertical ? { height: e.height } : {}), g = R(() => e.vertical ? {
384
+ height: p.value,
385
+ bottom: m.value
386
+ } : {
387
+ width: p.value,
388
+ left: m.value
389
+ }), _ = () => {
390
+ i.value && (t.sliderSize = i.value.getBoundingClientRect()[e.vertical ? "height" : "width"]);
391
+ }, v = (n) => {
392
+ let r = e.min + n * (e.max - e.min) / 100;
393
+ if (!e.range) return a;
394
+ let i;
395
+ return i = Math.abs(l.value - r) < Math.abs(d.value - r) ? t.firstValue < t.secondValue ? "firstButton" : "secondButton" : t.firstValue > t.secondValue ? "firstButton" : "secondButton", s[i];
396
+ }, b = (e) => {
397
+ let t = v(e);
398
+ return t.value.setPosition(e), t;
399
+ }, S = (n) => {
400
+ t.firstValue = n ?? e.min, w(e.range ? [l.value, d.value] : n ?? e.min);
401
+ }, C = (n) => {
402
+ t.secondValue = n, e.range && w([l.value, d.value]);
403
+ }, w = (e) => {
404
+ n(y, e), n(u, e);
405
+ }, T = async () => {
406
+ await q(), n(h, e.range ? [l.value, d.value] : e.modelValue);
407
+ }, E = (n) => {
408
+ if (c.value || t.dragging) return;
409
+ _();
410
+ let r = 0;
411
+ if (e.vertical) {
412
+ let e = n.touches?.item(0)?.clientY ?? n.clientY;
413
+ r = (i.value.getBoundingClientRect().bottom - e) / t.sliderSize * 100;
414
+ } else r = ((n.touches?.item(0)?.clientX ?? n.clientX) - i.value.getBoundingClientRect().left) / t.sliderSize * 100;
415
+ if (!(r < 0 || r > 100)) return b(r);
416
+ };
417
+ return {
418
+ elFormItem: r,
419
+ slider: i,
420
+ firstButton: a,
421
+ secondButton: o,
422
+ sliderDisabled: c,
423
+ minValue: l,
424
+ maxValue: d,
425
+ runwayStyle: ee,
426
+ barStyle: g,
427
+ resetSize: _,
428
+ setPosition: b,
429
+ emitChange: T,
430
+ onSliderWrapperPrevent: (e) => {
431
+ (s.firstButton.value?.dragging || s.secondButton.value?.dragging) && e.preventDefault();
432
+ },
433
+ onSliderClick: (e) => {
434
+ E(e) && T();
435
+ },
436
+ onSliderDown: async (e) => {
437
+ let t = E(e);
438
+ t && (await q(), t.value.onButtonDown(e));
439
+ },
440
+ onSliderMarkerDown: (e) => {
441
+ c.value || t.dragging || b(e) && T();
442
+ },
443
+ setFirstValue: S,
444
+ setSecondValue: C
445
+ };
446
+ }, Re = (e, t, n, r) => ({
447
+ stops: R(() => {
448
+ if (!e.showStops || e.min > e.max) return [];
449
+ if (e.step === "mark" || e.step === 0) return e.step === 0 && F("ElSlider", "step should not be 0."), [];
450
+ let i = Math.ceil((e.max - e.min) / e.step), a = 100 * e.step / (e.max - e.min), o = Array.from({ length: i - 1 }).map((e, t) => (t + 1) * a);
451
+ return e.range ? o.filter((t) => t < 100 * (n.value - e.min) / (e.max - e.min) || t > 100 * (r.value - e.min) / (e.max - e.min)) : o.filter((n) => n > 100 * (t.firstValue - e.min) / (e.max - e.min));
452
+ }),
453
+ getStopStyle: (t) => e.vertical ? { bottom: `${t}%` } : { left: `${t}%` }
454
+ }), ze = (e, t, n, r, i, a) => {
455
+ let o = (e) => {
456
+ i(y, e), i(u, e);
457
+ }, s = () => e.range ? ![n.value, r.value].every((e, n) => e === t.oldValue[n]) : e.modelValue !== t.oldValue, c = () => {
458
+ e.min > e.max && D("Slider", "min should not be greater than max.");
459
+ let n = e.modelValue;
460
+ e.range && T(n) ? n[1] < e.min ? o([e.min, e.min]) : n[0] > e.max ? o([e.max, e.max]) : n[0] < e.min ? o([e.min, n[1]]) : n[1] > e.max ? o([n[0], e.max]) : (t.firstValue = n[0], t.secondValue = n[1], s() && (e.validateEvent && a?.validate?.("change").catch((e) => F(e)), t.oldValue = n.slice())) : !e.range && C(n) && !Number.isNaN(n) && (n < e.min ? o(e.min) : n > e.max ? o(e.max) : (t.firstValue = n, s() && (e.validateEvent && a?.validate?.("change").catch((e) => F(e)), t.oldValue = n)));
461
+ };
462
+ c(), ye(() => t.dragging, (e) => {
463
+ e || c();
464
+ }), ye(() => e.modelValue, (e, n) => {
465
+ t.dragging || T(e) && T(n) && e.every((e, t) => e === n[t]) && t.firstValue === e[0] && t.secondValue === e[1] || c();
466
+ }, { deep: !0 }), ye(() => [e.min, e.max], () => {
467
+ c();
468
+ });
469
+ }, Be = (e, t, n) => {
470
+ let r = X(), i = X(!1), a = R(() => t.value instanceof Function);
471
+ return {
472
+ tooltip: r,
473
+ tooltipVisible: i,
474
+ formatValue: R(() => a.value && t.value(e.modelValue) || e.modelValue),
475
+ displayTooltip: ie(() => {
476
+ n.value && (i.value = !0);
477
+ }, 50),
478
+ hideTooltip: ie(() => {
479
+ n.value && (i.value = !1);
480
+ }, 50)
481
+ };
482
+ }, Ve = (e, t, n) => {
483
+ let { disabled: i, min: a, max: o, step: c, showTooltip: l, persistent: u, precision: d, sliderSize: f, formatTooltip: p, emitChange: m, resetSize: h, updateDragging: ee, markList: g } = se(je), { tooltip: _, tooltipVisible: v, formatValue: x, displayTooltip: S, hideTooltip: w } = Be(e, p, l), T = X(), E = R(() => `${(e.modelValue - a.value) / (o.value - a.value) * 100}%`), te = R(() => e.vertical ? { bottom: E.value } : { left: E.value }), D = R(() => c.value === "mark" && g.value.length > 0), O = () => {
484
+ t.hovering = !0, S();
485
+ }, ne = () => {
486
+ t.hovering = !1, t.dragging || w();
487
+ }, k = (e) => {
488
+ i.value || (e.preventDefault(), z(e), window.addEventListener("mousemove", B), window.addEventListener("touchmove", B), window.addEventListener("mouseup", V), window.addEventListener("touchend", V), window.addEventListener("contextmenu", V), T.value.focus());
489
+ }, A = (e) => {
490
+ i.value || (t.newPosition = Number.parseFloat(E.value) + e / (o.value - a.value) * 100, H(t.newPosition), m());
491
+ }, j = (t) => {
492
+ if (i.value || !g.value.length) return;
493
+ let n = e.modelValue, r = 2 ** -52, s = Math.abs(t), c;
494
+ if (t > 0) {
495
+ let e = g.value.findIndex((e) => e.point > n + r);
496
+ if (e !== -1) {
497
+ let t = Math.min(e + s - 1, g.value.length - 1);
498
+ c = g.value[t].point;
499
+ }
500
+ } else {
501
+ let e = -1;
502
+ for (let t = g.value.length - 1; t >= 0; t--) if (g.value[t].point < n - r) {
503
+ e = t;
504
+ break;
505
+ }
506
+ if (e !== -1) {
507
+ let t = Math.max(e - (s - 1), 0);
508
+ c = g.value[t].point;
509
+ }
510
+ }
511
+ c !== void 0 && c !== n && (H((c - a.value) / (o.value - a.value) * 100), m());
512
+ }, M = () => {
513
+ D.value ? j(-1) : C(c.value) && A(-c.value);
514
+ }, N = () => {
515
+ D.value ? j(1) : C(c.value) && A(c.value);
516
+ }, F = () => {
517
+ D.value ? j(-4) : C(c.value) && A(-c.value * 4);
518
+ }, I = () => {
519
+ D.value ? j(4) : C(c.value) && A(c.value * 4);
520
+ }, re = () => {
521
+ i.value || (H(0), m());
522
+ }, ie = () => {
523
+ i.value || (H(100), m());
524
+ }, ae = (e) => {
525
+ let t = r(e), n = !0;
526
+ switch (t) {
527
+ case b.left:
528
+ case b.down:
529
+ M();
530
+ break;
531
+ case b.right:
532
+ case b.up:
533
+ N();
534
+ break;
535
+ case b.home:
536
+ re();
537
+ break;
538
+ case b.end:
539
+ ie();
540
+ break;
541
+ case b.pageDown:
542
+ F();
543
+ break;
544
+ case b.pageUp:
545
+ I();
546
+ break;
547
+ default:
548
+ n = !1;
549
+ break;
550
+ }
551
+ n && e.preventDefault();
552
+ }, L = (e) => {
553
+ let t, n;
554
+ return e.type.startsWith("touch") ? (n = e.touches[0].clientY, t = e.touches[0].clientX) : (n = e.clientY, t = e.clientX), {
555
+ clientX: t,
556
+ clientY: n
557
+ };
558
+ }, z = (n) => {
559
+ t.dragging = !0, t.isClick = !0;
560
+ let { clientX: r, clientY: i } = L(n);
561
+ e.vertical ? t.startY = i : t.startX = r, t.startPosition = Number.parseFloat(E.value), t.newPosition = t.startPosition;
562
+ }, B = (n) => {
563
+ if (t.dragging) {
564
+ t.isClick = !1, S(), h();
565
+ let r, { clientX: i, clientY: a } = L(n);
566
+ e.vertical ? (t.currentY = a, r = (t.startY - t.currentY) / f.value * 100) : (t.currentX = i, r = (t.currentX - t.startX) / f.value * 100), t.newPosition = t.startPosition + r, H(t.newPosition);
567
+ }
568
+ }, V = () => {
569
+ t.dragging && (setTimeout(() => {
570
+ t.dragging = !1, t.hovering || w(), t.isClick || H(t.newPosition), m();
571
+ }, 0), window.removeEventListener("mousemove", B), window.removeEventListener("touchmove", B), window.removeEventListener("mouseup", V), window.removeEventListener("touchend", V), window.removeEventListener("contextmenu", V));
572
+ }, H = async (r) => {
573
+ if (r === null || Number.isNaN(+r)) return;
574
+ r = s(r, 0, 100);
575
+ let i;
576
+ if (c.value === "mark") i = g.value.length === 0 ? r <= 50 ? a.value : o.value : g.value.reduce((e, t) => Math.abs(t.position - r) < Math.abs(e.position - r) ? t : e).point;
577
+ else {
578
+ let e = Math.floor((o.value - a.value) / c.value), t = e * c.value / (o.value - a.value) * 100, n = t + (100 - t) / 2;
579
+ if (r < t) {
580
+ let n = t / e, o = Math.round(r / n);
581
+ i = a.value + o * c.value;
582
+ } else i = r < n ? a.value + e * c.value : o.value;
583
+ i = Number.parseFloat(i.toFixed(d.value));
584
+ }
585
+ i !== e.modelValue && n(y, i), !t.dragging && e.modelValue !== t.oldValue && (t.oldValue = e.modelValue), await q(), t.dragging && S(), _.value.updatePopper();
586
+ };
587
+ return ye(() => t.dragging, (e) => {
588
+ ee(e);
589
+ }), P(T, "touchstart", k, { passive: !1 }), {
590
+ disabled: i,
591
+ button: T,
592
+ tooltip: _,
593
+ tooltipVisible: v,
594
+ showTooltip: l,
595
+ persistent: u,
596
+ wrapperStyle: te,
597
+ formatValue: x,
598
+ handleMouseEnter: O,
599
+ handleMouseLeave: ne,
600
+ onButtonDown: k,
601
+ onKeyDown: ae,
602
+ setPosition: H
603
+ };
604
+ }, He = S({
605
+ modelValue: {
606
+ type: Number,
607
+ default: 0
608
+ },
609
+ vertical: Boolean,
610
+ tooltipClass: String,
611
+ placement: {
612
+ type: String,
613
+ values: n,
614
+ default: "top"
615
+ }
616
+ }), Ue = { [y]: (e) => C(e) }, We = ["tabindex"], Ge = /* @__PURE__ */ G({
617
+ name: "ElSliderButton",
618
+ __name: "button",
619
+ props: He,
620
+ emits: Ue,
621
+ setup(e, { expose: t, emit: n }) {
622
+ let r = e, i = n, a = k("slider"), o = pe({
623
+ hovering: !1,
624
+ dragging: !1,
625
+ isClick: !1,
626
+ startX: 0,
627
+ currentX: 0,
628
+ startY: 0,
629
+ currentY: 0,
630
+ startPosition: 0,
631
+ newPosition: 0,
632
+ oldValue: r.modelValue
633
+ }), s = R(() => d.value ? f.value : !1), { disabled: c, button: l, tooltip: u, showTooltip: d, persistent: f, tooltipVisible: p, wrapperStyle: h, formatValue: ee, handleMouseEnter: g, handleMouseLeave: _, onButtonDown: v, onKeyDown: y, setPosition: b } = Ve(r, o, i), { hovering: x, dragging: S } = _e(o);
634
+ return t({
635
+ onButtonDown: v,
636
+ onKeyDown: y,
637
+ setPosition: b,
638
+ hovering: x,
639
+ dragging: S
640
+ }), (e, t) => (Y(), V("div", {
641
+ ref_key: "button",
642
+ ref: l,
643
+ class: J([Q(a).e("button-wrapper"), {
644
+ hover: Q(x),
645
+ dragging: Q(S)
646
+ }]),
647
+ style: ce(Q(h)),
648
+ tabindex: Q(c) ? void 0 : 0,
649
+ onMouseenter: t[0] ||= (...e) => Q(g) && Q(g)(...e),
650
+ onMouseleave: t[1] ||= (...e) => Q(_) && Q(_)(...e),
651
+ onMousedown: t[2] ||= (...e) => Q(v) && Q(v)(...e),
652
+ onFocus: t[3] ||= (...e) => Q(g) && Q(g)(...e),
653
+ onBlur: t[4] ||= (...e) => Q(_) && Q(_)(...e),
654
+ onKeydown: t[5] ||= (...e) => Q(y) && Q(y)(...e)
655
+ }, [W(Q(m), {
656
+ ref_key: "tooltip",
657
+ ref: u,
658
+ visible: Q(p),
659
+ placement: e.placement,
660
+ "fallback-placements": [
661
+ "top",
662
+ "bottom",
663
+ "right",
664
+ "left"
665
+ ],
666
+ "stop-popper-mouse-event": !1,
667
+ "popper-class": e.tooltipClass,
668
+ disabled: !Q(d),
669
+ persistent: s.value
670
+ }, {
671
+ content: $(() => [H("span", null, Z(Q(ee)), 1)]),
672
+ default: $(() => [H("div", { class: J([Q(a).e("button"), {
673
+ hover: Q(x),
674
+ dragging: Q(S)
675
+ }]) }, null, 2)]),
676
+ _: 1
677
+ }, 8, [
678
+ "visible",
679
+ "placement",
680
+ "popper-class",
681
+ "disabled",
682
+ "persistent"
683
+ ])], 46, We));
684
+ }
685
+ }), Ke = G({
686
+ name: "ElSliderMarker",
687
+ props: S({ mark: {
688
+ type: E([String, Object]),
689
+ default: void 0
690
+ } }),
691
+ setup(e) {
692
+ let t = k("slider"), n = R(() => O(e.mark) ? e.mark : e.mark.label), r = R(() => O(e.mark) ? void 0 : e.mark.style);
693
+ return () => K("div", {
694
+ class: t.e("marks-text"),
695
+ style: r.value
696
+ }, n.value);
697
+ }
698
+ }), qe = [
699
+ "id",
700
+ "role",
701
+ "aria-label",
702
+ "aria-labelledby"
703
+ ], Je = { key: 1 }, Ye = i(/* @__PURE__ */ G({
704
+ name: "ElSlider",
705
+ __name: "slider",
706
+ props: Me,
707
+ emits: Pe,
708
+ setup(e, { expose: t, emit: n }) {
709
+ let r = e, i = n, a = k("slider"), { t: o } = ne(), s = pe({
710
+ firstValue: 0,
711
+ secondValue: 0,
712
+ oldValue: 0,
713
+ dragging: !1,
714
+ sliderSize: 1
715
+ }), { elFormItem: c, slider: l, firstButton: u, secondButton: d, sliderDisabled: f, minValue: m, maxValue: h, runwayStyle: ee, barStyle: g, resetSize: v, emitChange: y, onSliderWrapperPrevent: b, onSliderClick: x, onSliderDown: S, onSliderMarkerDown: w, setFirstValue: T, setSecondValue: E } = Le(r, s, i), { stops: te, getStopStyle: D } = Re(r, s, m, h), { inputId: O, isLabeledByFormItem: A } = _(r, { formItemContext: c }), j = p(), M = R(() => r.inputSize || j.value), N = R(() => r.showInput && !r.range && r.step !== "mark"), F = R(() => r.ariaLabel || o("el.slider.defaultLabel", {
716
+ min: r.min,
717
+ max: r.max
718
+ })), I = R(() => r.range ? r.rangeStartLabel || o("el.slider.defaultRangeStartLabel") : F.value), re = R(() => r.formatValueText ? r.formatValueText(q.value) : `${q.value}`), ie = R(() => r.rangeEndLabel || o("el.slider.defaultRangeEndLabel")), ae = R(() => r.formatValueText ? r.formatValueText(le.value) : `${le.value}`), oe = R(() => [
719
+ a.b(),
720
+ a.m(j.value),
721
+ a.is("vertical", r.vertical),
722
+ { [a.m("with-input")]: N.value }
723
+ ]), U = Ie(r);
724
+ ze(r, s, m, h, i, c);
725
+ let G = R(() => C(r.step) ? r.step : 1), K = R(() => {
726
+ let e = C(r.step) ? r.step : 1, t = [
727
+ r.min,
728
+ r.max,
729
+ e
730
+ ].map((e) => {
731
+ let t = `${e}`.split(".")[1];
732
+ return t ? t.length : 0;
733
+ });
734
+ return Math.max.apply(null, t);
735
+ }), { sliderWrapper: se } = Fe(r, s, v), { firstValue: q, secondValue: le, sliderSize: ue } = _e(s), de = (e) => {
736
+ s.dragging = e;
737
+ };
738
+ return P(se, "touchstart", b, { passive: !1 }), P(se, "touchmove", b, { passive: !1 }), fe(je, {
739
+ ..._e(r),
740
+ sliderSize: ue,
741
+ disabled: f,
742
+ precision: K,
743
+ markList: U,
744
+ emitChange: y,
745
+ resetSize: v,
746
+ updateDragging: de
747
+ }), t({ onSliderClick: x }), (e, t) => (Y(), V("div", {
748
+ id: e.range ? Q(O) : void 0,
749
+ ref_key: "sliderWrapper",
750
+ ref: se,
751
+ class: J(oe.value),
752
+ role: e.range ? "group" : void 0,
753
+ "aria-label": e.range && !Q(A) ? F.value : void 0,
754
+ "aria-labelledby": e.range && Q(A) ? Q(c)?.labelId : void 0
755
+ }, [H("div", {
756
+ ref_key: "slider",
757
+ ref: l,
758
+ class: J([
759
+ Q(a).e("runway"),
760
+ { "show-input": N.value },
761
+ Q(a).is("disabled", Q(f))
762
+ ]),
763
+ style: ce(Q(ee)),
764
+ onMousedown: t[0] ||= (...e) => Q(S) && Q(S)(...e),
765
+ onTouchstartPassive: t[1] ||= (...e) => Q(S) && Q(S)(...e)
766
+ }, [
767
+ H("div", {
768
+ class: J(Q(a).e("bar")),
769
+ style: ce(Q(g))
770
+ }, null, 6),
771
+ W(Ge, {
772
+ id: e.range ? void 0 : Q(O),
773
+ ref_key: "firstButton",
774
+ ref: u,
775
+ "model-value": Q(q),
776
+ vertical: e.vertical,
777
+ "tooltip-class": e.tooltipClass,
778
+ placement: e.placement,
779
+ role: "slider",
780
+ "aria-label": e.range || !Q(A) ? I.value : void 0,
781
+ "aria-labelledby": !e.range && Q(A) ? Q(c)?.labelId : void 0,
782
+ "aria-valuemin": e.min,
783
+ "aria-valuemax": e.range ? Q(le) : e.max,
784
+ "aria-valuenow": Q(q),
785
+ "aria-valuetext": re.value,
786
+ "aria-orientation": e.vertical ? "vertical" : "horizontal",
787
+ "aria-disabled": Q(f),
788
+ "onUpdate:modelValue": Q(T)
789
+ }, null, 8, [
790
+ "id",
791
+ "model-value",
792
+ "vertical",
793
+ "tooltip-class",
794
+ "placement",
795
+ "aria-label",
796
+ "aria-labelledby",
797
+ "aria-valuemin",
798
+ "aria-valuemax",
799
+ "aria-valuenow",
800
+ "aria-valuetext",
801
+ "aria-orientation",
802
+ "aria-disabled",
803
+ "onUpdate:modelValue"
804
+ ]),
805
+ e.range ? (Y(), z(Ge, {
806
+ key: 0,
807
+ ref_key: "secondButton",
808
+ ref: d,
809
+ "model-value": Q(le),
810
+ vertical: e.vertical,
811
+ "tooltip-class": e.tooltipClass,
812
+ placement: e.placement,
813
+ role: "slider",
814
+ "aria-label": ie.value,
815
+ "aria-valuemin": Q(q),
816
+ "aria-valuemax": e.max,
817
+ "aria-valuenow": Q(le),
818
+ "aria-valuetext": ae.value,
819
+ "aria-orientation": e.vertical ? "vertical" : "horizontal",
820
+ "aria-disabled": Q(f),
821
+ "onUpdate:modelValue": Q(E)
822
+ }, null, 8, [
823
+ "model-value",
824
+ "vertical",
825
+ "tooltip-class",
826
+ "placement",
827
+ "aria-label",
828
+ "aria-valuemin",
829
+ "aria-valuemax",
830
+ "aria-valuenow",
831
+ "aria-valuetext",
832
+ "aria-orientation",
833
+ "aria-disabled",
834
+ "onUpdate:modelValue"
835
+ ])) : B("v-if", !0),
836
+ e.showStops ? (Y(), V("div", Je, [(Y(!0), V(L, null, me(Q(te), (e, t) => (Y(), V("div", {
837
+ key: t,
838
+ class: J(Q(a).e("stop")),
839
+ style: ce(Q(D)(e))
840
+ }, null, 6))), 128))])) : B("v-if", !0),
841
+ Q(U).length > 0 ? (Y(), V(L, { key: 2 }, [H("div", null, [(Y(!0), V(L, null, me(Q(U), (e, t) => (Y(), V("div", {
842
+ key: t,
843
+ style: ce(Q(D)(e.position)),
844
+ class: J([Q(a).e("stop"), Q(a).e("marks-stop")])
845
+ }, null, 6))), 128))]), H("div", { class: J(Q(a).e("marks")) }, [(Y(!0), V(L, null, me(Q(U), (e, t) => (Y(), z(Q(Ke), {
846
+ key: t,
847
+ mark: e.mark,
848
+ style: ce(Q(D)(e.position)),
849
+ onMousedown: Ce((t) => Q(w)(e.position), ["stop"])
850
+ }, null, 8, [
851
+ "mark",
852
+ "style",
853
+ "onMousedown"
854
+ ]))), 128))], 2)], 64)) : B("v-if", !0)
855
+ ], 38), N.value ? (Y(), z(Q(Ae), {
856
+ key: 0,
857
+ ref: "input",
858
+ "model-value": Q(q),
859
+ class: J(Q(a).e("input")),
860
+ step: G.value,
861
+ disabled: Q(f),
862
+ controls: e.showInputControls,
863
+ min: e.min,
864
+ max: e.max,
865
+ precision: K.value,
866
+ size: M.value,
867
+ "onUpdate:modelValue": Q(T),
868
+ onChange: Q(y)
869
+ }, null, 8, [
870
+ "model-value",
871
+ "class",
872
+ "step",
873
+ "disabled",
874
+ "controls",
875
+ "min",
876
+ "max",
877
+ "precision",
878
+ "size",
879
+ "onUpdate:modelValue",
880
+ "onChange"
881
+ ])) : B("v-if", !0)], 10, qe));
882
+ }
883
+ })), Xe = { class: "RadarShortTerm" }, Ze = { class: "RadarShortTerm-setting-panel" }, Qe = { class: "display-setting" }, $e = { class: "setting-row setting-row-pile" }, et = { class: "setting-pile-options" }, tt = { class: "RadarShortTerm-table" }, nt = { class: "table-body" }, rt = ["onClick"], it = { class: "name" }, at = ["onClick"], ot = {
884
+ key: 0,
885
+ style: { color: "red" }
886
+ }, st = { class: "pile-panel" }, ct = {
887
+ key: 0,
888
+ class: "pile-body"
889
+ }, lt = {
890
+ key: 1,
891
+ class: "pile-empty"
892
+ }, ut = { class: "RadarShortTerm-timeline" }, dt = ["title"], ft = { class: "timeline-slider-wrap" }, pt = { class: "timeline-time-label" }, mt = /* @__PURE__ */ N(/* @__PURE__ */ G({
893
+ __name: "RadarShortTerm",
894
+ props: {
895
+ appKey: {
896
+ type: String,
897
+ default: ""
898
+ },
899
+ appSalt: {
900
+ type: String,
901
+ default: ""
902
+ },
903
+ baseHttp: {
904
+ type: String,
905
+ default: ""
906
+ },
907
+ ids: {
908
+ type: Object,
909
+ default: () => ({})
910
+ }
911
+ },
912
+ emits: [
913
+ "close",
914
+ "addImage",
915
+ "clearImg",
916
+ "addDataTitle",
917
+ "removeDataTitle",
918
+ "showRadarLegend"
919
+ ],
920
+ setup(e, { emit: t }) {
921
+ let n = e, r = t, i = X(!0), s = X(!1), l = X(0), u = X(null), d = X([]), f = X({}), p = X({}), m = X({}), h = X("");
922
+ ue(() => {
923
+ ee();
924
+ }), le(() => {
925
+ P();
926
+ });
927
+ let ee = async () => {
928
+ let e = await g(), t = await A({
929
+ appKey: n.appKey,
930
+ appSalt: n.appSalt,
931
+ id: n.ids.radar.id,
932
+ variables: {},
933
+ baseHttp: n.baseHttp,
934
+ reqType: n.ids.radar.reqType,
935
+ isFormData: n.ids.radar.isFormData
936
+ });
937
+ console.log("雷达", t.data.result), m.value = y(t.data.result), l.value = 0, d.value = e.map((e) => {
938
+ let t = T(e), n = te(e.zhflds || []);
939
+ return {
940
+ name: e.name,
941
+ tags: D(t),
942
+ piles: n
943
+ };
944
+ }), w();
945
+ }, g = async () => {
946
+ let e = await A({
947
+ appKey: n.appKey,
948
+ appSalt: n.appSalt,
949
+ id: n.ids.shortTerm.id,
950
+ variables: {},
951
+ baseHttp: n.baseHttp,
952
+ reqType: n.ids.shortTerm.reqType,
953
+ isFormData: n.ids.shortTerm.isFormData
954
+ });
955
+ return console.log("短时预报", e.data.result.ds), e.data.result.ds || [];
956
+ }, _ = (e) => {
957
+ let t = String(e || "").split(",").map((e) => Number(e.trim()));
958
+ return {
959
+ lngStart: t[0],
960
+ lngEnd: t[1],
961
+ latStart: t[2],
962
+ latEnd: t[3]
963
+ };
964
+ }, y = (e) => {
965
+ let t = Array.isArray(e?.ds) ? e : e?.ds, n = Array.isArray(t?.ds) ? t.ds : [];
966
+ n = [...n].reverse();
967
+ let r = _(n[0]?.extendstr || "");
968
+ return n.length ? {
969
+ ds: n,
970
+ httpurl: t?.httpUrl || t?.httpurl || "",
971
+ ...r
972
+ } : {
973
+ ds: [],
974
+ httpurl: "",
975
+ lngStart: null,
976
+ lngEnd: null,
977
+ latStart: null,
978
+ latEnd: null
979
+ };
980
+ }, b = R(() => ne(d.value, (e) => O(e.tags))), x = R(() => m.value?.ds || []), S = R(() => x.value.map((e) => {
981
+ let t = new Date(e.focarcast_time);
982
+ return `${String(t.getHours()).padStart(2, "0")}:${String(t.getMinutes()).padStart(2, "0")}`;
983
+ })), C = R(() => ({
984
+ httpurl: m.value?.httpurl || "",
985
+ lngStart: m.value?.lngStart,
986
+ latStart: m.value?.latStart,
987
+ lngEnd: m.value?.lngEnd,
988
+ latEnd: m.value?.latEnd
989
+ })), w = () => {
990
+ let e = b.value.find((e) => O(e.tags)), t = {}, n = {};
991
+ e && (t[e.name] = !0, n[e.name] = !0), f.value = t, p.value = n;
992
+ }, T = (e) => {
993
+ let t = e.zhflds || [];
994
+ return {
995
+ iswarnpre1h: t.some((e) => e?.iswarnpre1h === 1) ? 1 : 0,
996
+ iswarnpre2h: t.some((e) => e?.iswarnpre2h === 1) ? 1 : 0,
997
+ iswarnpre3h: t.some((e) => e?.iswarnpre3h === 1) ? 1 : 0
998
+ };
999
+ }, E = (e) => {
1000
+ let t = [];
1001
+ return e?.iswarnpre1h === 1 && t.push(`未来R1h:${e.rain_1h}`), e?.iswarnpre2h === 1 && t.push(`未来R2h:${e.rain_2h}`), e?.iswarnpre3h === 1 && t.push(`未来R3h:${e.rain_3h}`), t.length ? t.join(",") : "无";
1002
+ }, te = (e) => ne((e || []).map((e) => ({
1003
+ pileNo: `${e.type || ""}${e.Name || ""}`,
1004
+ isWarn: e?.iswarnpre1h === 1 || e?.iswarnpre2h === 1 || e?.iswarnpre3h === 1,
1005
+ warnValue: E(e)
1006
+ })), (e) => e.isWarn), D = (e) => [
1007
+ {
1008
+ label: "未来R1h",
1009
+ warn: e.iswarnpre1h === 1
1010
+ },
1011
+ {
1012
+ label: "未来R2h",
1013
+ warn: e.iswarnpre2h === 1
1014
+ },
1015
+ {
1016
+ label: "未来R3h",
1017
+ warn: e.iswarnpre3h === 1
1018
+ }
1019
+ ], O = (e) => e.some((e) => e.warn), ne = (e, t) => [...e].sort((e, n) => Number(t(n)) - Number(t(e))), k = (e) => e.filter((e) => e.isWarn).length, M = (e) => e ? {
1020
+ alt: "",
1021
+ imgUrl: `${C.value.httpurl}${e.file_name}`,
1022
+ lngStart: C.value.lngStart,
1023
+ latStart: C.value.latStart,
1024
+ lngEnd: C.value.lngEnd,
1025
+ latEnd: C.value.latEnd,
1026
+ opacity: 1,
1027
+ otherData: { imgId: "radar_RadarShortTerm" }
1028
+ } : null, N = (e) => {
1029
+ let t = x.value[e], n = { imgArr: [M(t)] };
1030
+ console.log(n), r("addImage", {
1031
+ removeImg: "radar_RadarShortTerm",
1032
+ data: n
1033
+ }), h.value && r("removeDataTitle", h.value), h.value = "雷达观测时间:" + j(t.focarcast_time).format("YYYY-MM-DD HH:mm "), console.log(h.value), r("addDataTitle", h.value), r("showRadarLegend", !0);
1034
+ }, P = () => {
1035
+ u.value &&= (clearInterval(u.value), null);
1036
+ }, F = () => {
1037
+ s.value = !1, P();
1038
+ }, I = () => {
1039
+ S.value.length <= 1 || (s.value = !0, P(), u.value = setInterval(() => {
1040
+ l.value = (l.value + 1) % S.value.length;
1041
+ }, 1e3));
1042
+ }, re = () => {
1043
+ if (s.value) {
1044
+ F();
1045
+ return;
1046
+ }
1047
+ I();
1048
+ };
1049
+ ye(l, (e) => {
1050
+ N(e);
1051
+ });
1052
+ let ie = () => {
1053
+ F();
1054
+ }, oe = () => {
1055
+ if (!i.value) {
1056
+ r("clearImg", "radar_RadarShortTerm"), r("removeDataTitle", h.value), r("showRadarLegend", !1), F();
1057
+ return;
1058
+ }
1059
+ N(l.value);
1060
+ }, G = (e) => {
1061
+ let t = !!f.value[e];
1062
+ f.value[e] = !t, t || (p.value[e] = !0);
1063
+ }, K = (e) => {
1064
+ p.value[e] = !p.value[e];
1065
+ }, se = () => {
1066
+ r("close", "RadarShortTerm");
1067
+ };
1068
+ return (e, t) => {
1069
+ let n = ae, r = v, u = Ye;
1070
+ return Y(), V("div", Xe, [
1071
+ H("div", { class: "RadarShortTerm-head" }, [H("div", { class: "RadarShortTerm-head-top" }, [t[2] ||= H("div", null, "雷达短临预报", -1), H("div", { class: "head-actions" }, [H("div", {
1072
+ class: "closeBtn",
1073
+ onClick: se,
1074
+ title: "关闭"
1075
+ })])]), t[3] ||= H("img", {
1076
+ class: "RadarShortTerm-head-line",
1077
+ src: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAbsAAAASBAMAAAAwI22/AAAABGdBTUEAALGPC/xhBQAAAAFzUkdCAK7OHOkAAAAwUExURQAAAAem/wem/wem/wem/wem/wem/wem/wem/wem/wem/wem/wem/wem/wem/wem/5bu5GYAAAAPdFJOUwAFwAwc2M8ULQYDn/hGXGnV2UoAAAGZSURBVEjH7ZM/S8NAGId/JYGmmeLspptThurk0CHWRXGo0Nk/S50y6CYSHMRF7Efo4uQXEIpbwUnM6OhnEIeChXjv5ZLLXdLtLCX68vDCe0eGJ7/3AJN1VcL+UImB/SruVJwYTqSAW5V3LLyaPR1c+IIdH12OPZiLcyTAjccZEdccZ0Nn4bXpC3KpCuFu5tkdziX3FJxBSBZZdFk9HempCduMk4xSitJTpOgJSSIPrx10YAUB0tYOwrQ1g12k7ZyODIYXZmQpppLV26rtbDFOXVhua2Fn7WTWwUEyAe5Zc2hiLWTTC3jjk8Hw+jrSM9/Z8raKOAtZVmyr9jbpee4lU9hvSUStw6YvOpqwiXlK9d8IL0Oq5tuqvc3KLMs7q9uyCC0y22aKvDVp4u2SjnJ1c+Wecg7h9gV4CFV8NHpEaw7yF2wVGcIa6OBx/Ax3PI6pRWx6Am98alBbpSODNVTxgAbQUpF3KeVv0s80xMUow8N//YVaqWEV9BJDdby2PBUZ1/te0uU0YzeLa623jjrrvaLOep/+str9ACyAtv25BhHcAAAAAElFTkSuQmCC",
1078
+ alt: ""
1079
+ }, null, -1)]),
1080
+ H("div", Ze, [H("div", Qe, [H("div", $e, [t[5] ||= H("span", { class: "setting-label" }, "雷达展示:", -1), H("div", et, [W(n, {
1081
+ modelValue: i.value,
1082
+ "onUpdate:modelValue": t[0] ||= (e) => i.value = e,
1083
+ class: "pile-checkbox",
1084
+ onChange: oe
1085
+ }, {
1086
+ default: $(() => [...t[4] ||= [U(" 显示 ", -1)]]),
1087
+ _: 1
1088
+ }, 8, ["modelValue"])])])])]),
1089
+ H("div", tt, [t[8] ||= H("div", { class: "table-head" }, [
1090
+ H("span", null, "高速名称"),
1091
+ H("span", null, "状态要素"),
1092
+ H("span", { class: "head-arrow" })
1093
+ ], -1), H("div", nt, [(Y(!0), V(L, null, me(b.value, (e) => (Y(), V("div", {
1094
+ class: "table-row",
1095
+ key: e.name
1096
+ }, [
1097
+ H("div", {
1098
+ class: "table-row-main",
1099
+ onClick: (t) => G(e.name)
1100
+ }, [
1101
+ H("span", it, Z(e.name), 1),
1102
+ H("div", { class: J(["status-tags", { "has-warn": O(e.tags) }]) }, [(Y(!0), V(L, null, me(e.tags, (t) => (Y(), V("span", {
1103
+ class: J(["status-tag", { warn: t.warn }]),
1104
+ key: `${e.name}-${t.label}`
1105
+ }, [H("span", null, Z(t.label), 1)], 2))), 128))], 2),
1106
+ H("span", {
1107
+ class: J(["expand-arrow", { expanded: f.value[e.name] }]),
1108
+ "aria-hidden": "true"
1109
+ }, [W(r, null, {
1110
+ default: $(() => [W(Q(c))]),
1111
+ _: 1
1112
+ })], 2)
1113
+ ], 8, rt),
1114
+ xe(H("div", {
1115
+ class: "pile-title",
1116
+ onClick: (t) => K(e.name)
1117
+ }, [H("span", null, [t[6] ||= U(" 桩号数据 ", -1), k(e.piles) > 0 ? (Y(), V("span", ot, " (报警数量:" + Z(k(e.piles)) + "个)", 1)) : B("", !0)]), H("span", { class: J(["panel-arrow", { expanded: p.value[e.name] }]) }, [W(r, null, {
1118
+ default: $(() => [W(Q(c))]),
1119
+ _: 1
1120
+ })], 2)], 8, at), [[ve, f.value[e.name]]]),
1121
+ xe(H("div", st, [t[7] ||= H("div", { class: "pile-head" }, [H("span", null, "桩号"), H("span", null, "报警值")], -1), e.piles.length ? (Y(), V("div", ct, [(Y(!0), V(L, null, me(e.piles, (e) => (Y(), V("div", {
1122
+ class: J(["pile-row", { "is-warn": e.isWarn }]),
1123
+ key: e.pileNo
1124
+ }, [H("span", null, Z(e.pileNo), 1), H("span", null, Z(e.warnValue), 1)], 2))), 128))])) : (Y(), V("div", lt, "暂无数据"))], 512), [[ve, f.value[e.name] && p.value[e.name]]])
1125
+ ]))), 128))])]),
1126
+ xe(H("div", ut, [H("button", {
1127
+ type: "button",
1128
+ class: "timeline-play-btn",
1129
+ title: s.value ? "暂停" : "播放",
1130
+ onClick: re
1131
+ }, [W(r, null, {
1132
+ default: $(() => [s.value ? (Y(), z(Q(a), { key: 0 })) : (Y(), z(Q(o), { key: 1 }))]),
1133
+ _: 1
1134
+ })], 8, dt), H("div", ft, [H("span", pt, Z(S.value[l.value] || ""), 1), W(u, {
1135
+ modelValue: l.value,
1136
+ "onUpdate:modelValue": t[1] ||= (e) => l.value = e,
1137
+ min: 0,
1138
+ max: Math.max(0, S.value.length - 1),
1139
+ step: 1,
1140
+ "show-tooltip": !1,
1141
+ onChange: ie
1142
+ }, null, 8, ["modelValue", "max"])])], 512), [[ve, i.value]])
1143
+ ]);
1144
+ };
1145
+ }
1146
+ }), [["__scopeId", "data-v-f283c9b3"]]);
1147
+ //#endregion
1148
+ export { mt as t };