gisviewer-vue3-arcgis 1.0.167 → 1.0.169
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/es/src/gis-map/gis-map.vue.d.ts +13 -2
- package/es/src/gis-map/gis-map.vue.mjs +138 -135
- package/es/src/gis-map/index.d.ts +13 -2
- package/es/src/gis-map/utils/holo-flow/index.mjs +37 -36
- package/es/src/gis-map/utils/holo-flow/signal-countdown-panel.vue.d.ts +8 -0
- package/es/src/gis-map/utils/holo-flow/signal-countdown-panel.vue.mjs +2 -2
- package/es/src/gis-map/utils/holo-flow/signal-countdown-panel.vue2.mjs +36 -35
- package/es/src/gis-map/utils/holo-flow/signal-holo-flow-lsr.d.ts +2 -0
- package/es/src/gis-map/utils/holo-flow/signal-holo-flow-lsr.mjs +100 -84
- package/es/src/gis-map/utils/holo-flow/signal-holo-flow.mjs +6 -5
- package/es/src/gis-map/utils/holo-flow/trace-renderer-external.d.ts +1 -1
- package/es/src/gis-map/utils/holo-flow/trace-renderer-external.mjs +10 -9
- package/es/src/gis-map/utils/holo-flow/trace-renderer-layer.mjs +6 -5
- package/es/src/gis-map/utils/signal-control-area-controller/index.d.ts +3 -1
- package/es/src/gis-map/utils/signal-control-area-controller/index.mjs +184 -79
- package/es/src/types/index.d.ts +1 -0
- package/es/style.css +1 -1
- package/lib/src/gis-map/gis-map.vue.d.ts +13 -2
- package/lib/src/gis-map/gis-map.vue.js +1 -1
- package/lib/src/gis-map/index.d.ts +13 -2
- package/lib/src/gis-map/utils/holo-flow/index.js +1 -1
- package/lib/src/gis-map/utils/holo-flow/signal-countdown-panel.vue.d.ts +8 -0
- package/lib/src/gis-map/utils/holo-flow/signal-countdown-panel.vue.js +1 -1
- package/lib/src/gis-map/utils/holo-flow/signal-countdown-panel.vue2.js +1 -1
- package/lib/src/gis-map/utils/holo-flow/signal-holo-flow-lsr.d.ts +2 -0
- package/lib/src/gis-map/utils/holo-flow/signal-holo-flow-lsr.js +1 -1
- package/lib/src/gis-map/utils/holo-flow/signal-holo-flow.js +1 -1
- package/lib/src/gis-map/utils/holo-flow/trace-renderer-external.d.ts +1 -1
- package/lib/src/gis-map/utils/holo-flow/trace-renderer-external.js +1 -1
- package/lib/src/gis-map/utils/holo-flow/trace-renderer-layer.js +1 -1
- package/lib/src/gis-map/utils/signal-control-area-controller/index.d.ts +3 -1
- package/lib/src/gis-map/utils/signal-control-area-controller/index.js +1 -1
- package/lib/src/types/index.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as g from "@arcgis/core/core/reactiveUtils.js";
|
|
2
2
|
import y from "@arcgis/core/Graphic";
|
|
3
3
|
import h from "@arcgis/core/layers/GraphicsLayer";
|
|
4
|
-
import
|
|
4
|
+
import u from "@turf/buffer";
|
|
5
5
|
import d from "@turf/convex";
|
|
6
|
-
import * as
|
|
7
|
-
import
|
|
8
|
-
import
|
|
6
|
+
import * as l from "@turf/helpers";
|
|
7
|
+
import b from "concaveman";
|
|
8
|
+
import f from "./district-controller.mjs";
|
|
9
9
|
class x {
|
|
10
10
|
constructor(e) {
|
|
11
11
|
this.crossScale = 5e3, this.view = e, this.districtControllerLayer = new h({
|
|
12
|
-
id: "districtControllerLayer"
|
|
13
|
-
maxScale: 144447,
|
|
14
|
-
minScale: 1155582
|
|
12
|
+
id: "districtControllerLayer"
|
|
15
13
|
}), this.subDistrictControllerLayer = new h({
|
|
16
14
|
id: "subDistrictControllerLayer",
|
|
17
|
-
|
|
18
|
-
|
|
15
|
+
visible: !1
|
|
16
|
+
// maxScale: 0,
|
|
17
|
+
// minScale: 144447
|
|
19
18
|
}), this.crossLayer = new h({
|
|
20
19
|
id: "crossLayer",
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
visible: !1
|
|
21
|
+
// maxScale: 0,
|
|
22
|
+
// minScale: 36112
|
|
23
23
|
}), this.highlightLayer = new h({
|
|
24
24
|
id: "highlightLayer"
|
|
25
25
|
}), this.view.map.addMany([
|
|
@@ -30,15 +30,15 @@ class x {
|
|
|
30
30
|
]);
|
|
31
31
|
}
|
|
32
32
|
showSignalControlArea(e) {
|
|
33
|
-
this.districtControllerLayer.removeAll(), this.subDistrictControllerLayer.removeAll(), this.crossLayer.removeAll(), this.highlightLayer.removeAll(), this.districtControllerLayer.visible = !0
|
|
33
|
+
this.districtControllerLayer.removeAll(), this.subDistrictControllerLayer.removeAll(), this.crossLayer.removeAll(), this.highlightLayer.removeAll(), this.districtControllerLayer.visible = !0;
|
|
34
34
|
for (const t of e) {
|
|
35
|
-
const
|
|
36
|
-
this.drawArea(
|
|
35
|
+
const i = new f(t);
|
|
36
|
+
this.drawArea(i, !0);
|
|
37
37
|
}
|
|
38
|
-
return this.watchHandle =
|
|
38
|
+
return this.watchHandle = g.watch(
|
|
39
39
|
() => this.view.scale,
|
|
40
|
-
(t,
|
|
41
|
-
t > this.crossScale &&
|
|
40
|
+
(t, i) => {
|
|
41
|
+
t > this.crossScale && i <= this.crossScale ? (this.crossLayer.graphics.forEach((s) => {
|
|
42
42
|
s.symbol = this.getCrossGraphicSymbol(
|
|
43
43
|
s.attributes,
|
|
44
44
|
"marker"
|
|
@@ -48,7 +48,7 @@ class x {
|
|
|
48
48
|
s.attributes,
|
|
49
49
|
"marker"
|
|
50
50
|
));
|
|
51
|
-
})) : t <= this.crossScale &&
|
|
51
|
+
})) : t <= this.crossScale && i > this.crossScale && (this.crossLayer.graphics.forEach((s) => {
|
|
52
52
|
s.symbol = this.getCrossGraphicSymbol(
|
|
53
53
|
s.attributes,
|
|
54
54
|
"picture"
|
|
@@ -73,30 +73,26 @@ class x {
|
|
|
73
73
|
scale: 1500
|
|
74
74
|
}) : await this.view.goTo(t.geometry), { status: 0, message: "ok" }) : { status: 1, message: "未找到" };
|
|
75
75
|
}
|
|
76
|
-
showPopup(e) {
|
|
77
|
-
const t = e.geometry.type === "point" ? e.geometry : e.geometry.centroid;
|
|
78
|
-
this.view.openPopup({
|
|
79
|
-
features: [e],
|
|
80
|
-
location: t
|
|
81
|
-
});
|
|
82
|
-
}
|
|
83
76
|
async highlightSignalControlArea(e) {
|
|
84
77
|
if (!e.id || e.id === "")
|
|
85
78
|
return { status: 1, message: "请输入id" };
|
|
86
|
-
this.highlightLayer.removeAll(), this.districtControllerLayer.visible = !1
|
|
87
|
-
const t = this.districtControllerLayer.graphics.filter((
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
79
|
+
this.highlightLayer.removeAll(), this.districtControllerLayer.visible = !1;
|
|
80
|
+
const t = this.districtControllerLayer.graphics.filter((r) => r.getAttribute("id") === e.id).toArray().map((r) => {
|
|
81
|
+
const a = r.clone();
|
|
82
|
+
return a.symbol.style = "none", a;
|
|
83
|
+
}), i = this.subDistrictControllerLayer.graphics.filter(
|
|
84
|
+
(r) => r.getAttribute("id") === e.id || r.getAttribute("parentId") === e.id
|
|
85
|
+
).toArray().map((r) => r.clone()), s = this.crossLayer.graphics.filter(
|
|
86
|
+
(r) => r.getAttribute("id") === e.id || r.getAttribute("districtId") === e.id || r.getAttribute("subDistrictId") === e.id
|
|
87
|
+
).toArray().map((r) => r.clone());
|
|
88
|
+
if (t.length > 0 && this.highlightLayer.addMany(t), i.length > 0 && this.highlightLayer.addMany(i), s.length > 0 && this.highlightLayer.addMany(s), this.highlightLayer.graphics.length === 0)
|
|
93
89
|
return { status: 1, message: "未找到" };
|
|
94
90
|
if (t.length > 0)
|
|
95
91
|
await this.view.goTo(t);
|
|
96
|
-
else if (
|
|
97
|
-
const
|
|
92
|
+
else if (i.length > 0) {
|
|
93
|
+
const r = i[0].geometry.centroid;
|
|
98
94
|
await this.view.goTo({
|
|
99
|
-
target:
|
|
95
|
+
target: r,
|
|
100
96
|
scale: this.crossScale - 500
|
|
101
97
|
});
|
|
102
98
|
} else
|
|
@@ -107,7 +103,28 @@ class x {
|
|
|
107
103
|
return { status: 0, message: "ok" };
|
|
108
104
|
}
|
|
109
105
|
resetHighlight() {
|
|
110
|
-
return this.highlightLayer.removeAll(), this.view.closePopup(), this.districtControllerLayer.visible = !0,
|
|
106
|
+
return this.highlightLayer.removeAll(), this.view.closePopup(), this.districtControllerLayer.visible = !0, { status: 0, message: "ok" };
|
|
107
|
+
}
|
|
108
|
+
showSubSignalControlArea(e) {
|
|
109
|
+
const t = e.children;
|
|
110
|
+
console.log(t);
|
|
111
|
+
const i = t.map((s) => new y({
|
|
112
|
+
geometry: {
|
|
113
|
+
type: "point",
|
|
114
|
+
x: s.longitude,
|
|
115
|
+
y: s.latitude
|
|
116
|
+
},
|
|
117
|
+
symbol: this.getCrossGraphicInSubDistrict(),
|
|
118
|
+
attributes: {
|
|
119
|
+
id: s.id,
|
|
120
|
+
name: s.name,
|
|
121
|
+
signalId: s.signalId
|
|
122
|
+
}
|
|
123
|
+
}));
|
|
124
|
+
return this.crossLayer.addMany(i), this.view.goTo(i), { status: 0, message: "ok" };
|
|
125
|
+
}
|
|
126
|
+
editSubSignalArea() {
|
|
127
|
+
return { status: 0, message: "ok" };
|
|
111
128
|
}
|
|
112
129
|
/**
|
|
113
130
|
* 在区控\子区\路口图层中查找对应的graphic
|
|
@@ -116,11 +133,11 @@ class x {
|
|
|
116
133
|
*/
|
|
117
134
|
findAreaGraphic(e) {
|
|
118
135
|
let t = this.districtControllerLayer.graphics.find(
|
|
119
|
-
(
|
|
136
|
+
(i) => i.attributes.id === e
|
|
120
137
|
);
|
|
121
138
|
return t || (t = this.subDistrictControllerLayer.graphics.find(
|
|
122
|
-
(
|
|
123
|
-
)), t || (t = this.crossLayer.graphics.find((
|
|
139
|
+
(i) => i.attributes.id === e
|
|
140
|
+
)), t || (t = this.crossLayer.graphics.find((i) => i.attributes.id === e)), t;
|
|
124
141
|
}
|
|
125
142
|
/**
|
|
126
143
|
* 绘制区控与子区
|
|
@@ -129,33 +146,33 @@ class x {
|
|
|
129
146
|
* @returns
|
|
130
147
|
*/
|
|
131
148
|
drawArea(e, t) {
|
|
132
|
-
const
|
|
133
|
-
if (
|
|
134
|
-
let
|
|
135
|
-
if (
|
|
136
|
-
|
|
149
|
+
const i = e.getAllCrossCoordinates();
|
|
150
|
+
if (i.length >= 2) {
|
|
151
|
+
let r = null;
|
|
152
|
+
if (i.length === 2)
|
|
153
|
+
r = l.lineString(i);
|
|
137
154
|
else {
|
|
138
155
|
if (t) {
|
|
139
|
-
const n =
|
|
140
|
-
|
|
156
|
+
const n = l.featureCollection(
|
|
157
|
+
i.map((p) => l.point(p))
|
|
141
158
|
);
|
|
142
|
-
|
|
159
|
+
r = d(n);
|
|
143
160
|
} else {
|
|
144
|
-
const n =
|
|
145
|
-
n.length >= 4 && (
|
|
161
|
+
const n = b(i, 0.5);
|
|
162
|
+
n.length >= 4 && (r = l.polygon([n]));
|
|
146
163
|
}
|
|
147
|
-
|
|
164
|
+
r || (r = l.lineString(i));
|
|
148
165
|
}
|
|
149
|
-
const
|
|
150
|
-
|
|
166
|
+
const a = u(
|
|
167
|
+
r.geometry,
|
|
151
168
|
// 区控面积更大,需要更大的缓冲半径
|
|
152
169
|
t ? 200 : 30,
|
|
153
170
|
{
|
|
154
171
|
units: "meters"
|
|
155
172
|
}
|
|
156
173
|
);
|
|
157
|
-
let
|
|
158
|
-
t ?
|
|
174
|
+
let o;
|
|
175
|
+
t ? o = [
|
|
159
176
|
{
|
|
160
177
|
fieldName: "id",
|
|
161
178
|
label: "区控编号"
|
|
@@ -168,7 +185,7 @@ class x {
|
|
|
168
185
|
fieldName: "subDistrictCount",
|
|
169
186
|
label: "子区数量"
|
|
170
187
|
}
|
|
171
|
-
] :
|
|
188
|
+
] : o = [
|
|
172
189
|
{
|
|
173
190
|
fieldName: "parentName",
|
|
174
191
|
label: "所属区控"
|
|
@@ -189,7 +206,7 @@ class x {
|
|
|
189
206
|
}, c = new y({
|
|
190
207
|
geometry: {
|
|
191
208
|
type: "polygon",
|
|
192
|
-
rings:
|
|
209
|
+
rings: a.geometry.coordinates
|
|
193
210
|
},
|
|
194
211
|
symbol: {
|
|
195
212
|
type: "simple-fill",
|
|
@@ -206,38 +223,38 @@ class x {
|
|
|
206
223
|
content: [
|
|
207
224
|
{
|
|
208
225
|
type: "fields",
|
|
209
|
-
fieldInfos:
|
|
226
|
+
fieldInfos: o
|
|
210
227
|
}
|
|
211
228
|
]
|
|
212
229
|
}
|
|
213
230
|
});
|
|
214
231
|
t ? this.districtControllerLayer.add(c) : this.subDistrictControllerLayer.add(c);
|
|
215
232
|
}
|
|
216
|
-
for (const
|
|
217
|
-
this.drawArea(
|
|
233
|
+
for (const r of e.subDistricts)
|
|
234
|
+
this.drawArea(r, !1);
|
|
218
235
|
const s = [];
|
|
219
|
-
e.crosses.forEach((
|
|
220
|
-
const
|
|
236
|
+
e.crosses.forEach((r) => {
|
|
237
|
+
const a = {
|
|
221
238
|
type: "cross",
|
|
222
|
-
id:
|
|
223
|
-
name:
|
|
239
|
+
id: r.id,
|
|
240
|
+
name: r.name,
|
|
224
241
|
color: e.areaColor,
|
|
225
|
-
signalId:
|
|
242
|
+
signalId: r.signalId,
|
|
226
243
|
districtId: t ? e.id : e.parentId,
|
|
227
244
|
districtName: t ? e.name : e.parentName,
|
|
228
245
|
subDistrictId: t ? "" : e.id,
|
|
229
246
|
subDistrictName: t ? "" : e.name,
|
|
230
|
-
isKey:
|
|
231
|
-
},
|
|
247
|
+
isKey: r.isKey
|
|
248
|
+
}, o = new y({
|
|
232
249
|
geometry: {
|
|
233
250
|
type: "point",
|
|
234
|
-
x:
|
|
235
|
-
y:
|
|
251
|
+
x: r.longitude,
|
|
252
|
+
y: r.latitude
|
|
236
253
|
},
|
|
237
|
-
symbol: this.getCrossGraphicSymbol(
|
|
238
|
-
attributes:
|
|
254
|
+
symbol: this.getCrossGraphicSymbol(a, "marker"),
|
|
255
|
+
attributes: a,
|
|
239
256
|
popupTemplate: {
|
|
240
|
-
title:
|
|
257
|
+
title: r.name,
|
|
241
258
|
content: [
|
|
242
259
|
{
|
|
243
260
|
type: "fields",
|
|
@@ -263,9 +280,97 @@ class x {
|
|
|
263
280
|
]
|
|
264
281
|
}
|
|
265
282
|
});
|
|
266
|
-
s.push(
|
|
283
|
+
s.push(o);
|
|
267
284
|
}), this.crossLayer.addMany(s);
|
|
268
285
|
}
|
|
286
|
+
getCrossGraphicInSubDistrict() {
|
|
287
|
+
return {
|
|
288
|
+
type: "cim",
|
|
289
|
+
data: {
|
|
290
|
+
type: "CIMSymbolReference",
|
|
291
|
+
primitiveOverrides: [
|
|
292
|
+
{
|
|
293
|
+
// 将textGraphic的TextString替换为graphic.attributes.name
|
|
294
|
+
type: "CIMPrimitiveOverride",
|
|
295
|
+
primitiveName: "textGraphic",
|
|
296
|
+
propertyName: "TextString",
|
|
297
|
+
valueExpressionInfo: {
|
|
298
|
+
type: "CIMExpressionInfo",
|
|
299
|
+
title: "Custom",
|
|
300
|
+
expression: 'Replace($feature.name, "与", "/") + " " + $feature.signalId',
|
|
301
|
+
returnType: "Default"
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
],
|
|
305
|
+
symbol: {
|
|
306
|
+
type: "CIMPointSymbol",
|
|
307
|
+
symbolLayers: [
|
|
308
|
+
// 路口名称
|
|
309
|
+
{
|
|
310
|
+
type: "CIMVectorMarker",
|
|
311
|
+
size: 32,
|
|
312
|
+
colorLocked: !0,
|
|
313
|
+
anchorPointUnits: "Relative",
|
|
314
|
+
frame: { xmin: -16, ymin: -16, xmax: 16, ymax: 16 },
|
|
315
|
+
markerGraphics: [
|
|
316
|
+
{
|
|
317
|
+
type: "CIMMarkerGraphic",
|
|
318
|
+
primitiveName: "textGraphic",
|
|
319
|
+
geometry: { x: 0, y: 0 },
|
|
320
|
+
symbol: {
|
|
321
|
+
type: "CIMTextSymbol",
|
|
322
|
+
height: 12,
|
|
323
|
+
horizontalAlignment: "Center",
|
|
324
|
+
offsetX: 0,
|
|
325
|
+
offsetY: 20,
|
|
326
|
+
haloSize: 1,
|
|
327
|
+
haloSymbol: {
|
|
328
|
+
type: "CIMPolygonSymbol",
|
|
329
|
+
symbolLayers: [
|
|
330
|
+
{
|
|
331
|
+
type: "CIMSolidFill",
|
|
332
|
+
enable: !0,
|
|
333
|
+
color: [255, 255, 255, 255]
|
|
334
|
+
}
|
|
335
|
+
]
|
|
336
|
+
},
|
|
337
|
+
symbol: {
|
|
338
|
+
type: "CIMPolygonSymbol",
|
|
339
|
+
symbolLayers: [
|
|
340
|
+
{
|
|
341
|
+
type: "CIMSolidFill",
|
|
342
|
+
enable: !0,
|
|
343
|
+
color: [0, 0, 0, 255]
|
|
344
|
+
}
|
|
345
|
+
]
|
|
346
|
+
},
|
|
347
|
+
verticalAlignment: "Center"
|
|
348
|
+
},
|
|
349
|
+
textString: ""
|
|
350
|
+
}
|
|
351
|
+
],
|
|
352
|
+
scaleSymbolsProportionally: !0,
|
|
353
|
+
respectFrame: !0
|
|
354
|
+
},
|
|
355
|
+
// 路口图标
|
|
356
|
+
{
|
|
357
|
+
type: "CIMPictureMarker",
|
|
358
|
+
enable: !0,
|
|
359
|
+
anchorPoint: {
|
|
360
|
+
x: 0,
|
|
361
|
+
y: 0
|
|
362
|
+
},
|
|
363
|
+
anchorPointUnits: "Relative",
|
|
364
|
+
size: 20,
|
|
365
|
+
rotateClockwise: !0,
|
|
366
|
+
textureFilter: "Picture",
|
|
367
|
+
url: "/GisViewerAssets/Images/gis_lkcz_xz.png"
|
|
368
|
+
}
|
|
369
|
+
]
|
|
370
|
+
}
|
|
371
|
+
}
|
|
372
|
+
};
|
|
373
|
+
}
|
|
269
374
|
/**
|
|
270
375
|
* 生成路口点符号。在不同比例尺下,使用不同的符号
|
|
271
376
|
* @param attributes
|
|
@@ -273,9 +378,9 @@ class x {
|
|
|
273
378
|
* @returns
|
|
274
379
|
*/
|
|
275
380
|
getCrossGraphicSymbol(e, t) {
|
|
276
|
-
const { isKey:
|
|
381
|
+
const { isKey: i, color: s } = e;
|
|
277
382
|
if (t === "marker")
|
|
278
|
-
return
|
|
383
|
+
return i ? {
|
|
279
384
|
type: "picture-marker",
|
|
280
385
|
url: "/GisViewerAssets/Images/icon_star.png",
|
|
281
386
|
width: "30px",
|
|
@@ -329,7 +434,7 @@ class x {
|
|
|
329
434
|
height: 12,
|
|
330
435
|
horizontalAlignment: "Center",
|
|
331
436
|
offsetX: 0,
|
|
332
|
-
offsetY:
|
|
437
|
+
offsetY: i ? 50 : 40,
|
|
333
438
|
haloSize: 1,
|
|
334
439
|
haloSymbol: {
|
|
335
440
|
type: "CIMPolygonSymbol",
|
|
@@ -368,11 +473,11 @@ class x {
|
|
|
368
473
|
y: 0
|
|
369
474
|
},
|
|
370
475
|
anchorPointUnits: "Relative",
|
|
371
|
-
size:
|
|
476
|
+
size: i ? 45 : 30,
|
|
372
477
|
rotateClockwise: !0,
|
|
373
478
|
textureFilter: "Picture",
|
|
374
|
-
url: `/GisViewerAssets/Images/xhj_${
|
|
375
|
-
offsetY:
|
|
479
|
+
url: `/GisViewerAssets/Images/xhj_${i ? 4 : 1}.png`,
|
|
480
|
+
offsetY: i ? 22 : 15
|
|
376
481
|
}
|
|
377
482
|
]
|
|
378
483
|
}
|
package/es/src/types/index.d.ts
CHANGED
package/es/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.gis-viewer{overflow:auto;scrollbar-width:none;-ms-overflow-style:none;&::-webkit-scrollbar{display:none}}.signal-countdown-panel[data-v-
|
|
1
|
+
.gis-viewer{overflow:auto;scrollbar-width:none;-ms-overflow-style:none;&::-webkit-scrollbar{display:none}}.signal-countdown-panel[data-v-f1172941]{position:absolute;display:flex;flex-direction:row;padding:0;margin:0}.signal-countdown-container[data-v-f1172941]{margin:0 1px;padding:0;background-color:#000c;border-style:solid;border-color:#40e0d0;border-width:2px;border-radius:5px;color:#fff;width:40px;height:70px;justify-content:center;align-items:center;display:flex;flex-direction:column}.signal-countdown-number[data-v-f1172941]{font:30px bold}
|
|
@@ -47,6 +47,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
47
47
|
top: number;
|
|
48
48
|
};
|
|
49
49
|
rotation: number;
|
|
50
|
+
scale: number;
|
|
50
51
|
lampStatus: {
|
|
51
52
|
uNumber?: number | undefined;
|
|
52
53
|
uColor?: string | undefined;
|
|
@@ -81,7 +82,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
81
82
|
calRoadIndicatorArea: () => Promise<void>;
|
|
82
83
|
connectCarFlow: (url: string, options?: any) => Promise<void>;
|
|
83
84
|
disconnectCarFlow: () => void;
|
|
84
|
-
handleHoloVehicleTraceData: (vehicleTrace: any) => void
|
|
85
|
+
handleHoloVehicleTraceData: (vehicleTrace: any) => Promise<void>;
|
|
85
86
|
clearHoloTrace: () => void;
|
|
86
87
|
setInterpolate: (enable: boolean) => void;
|
|
87
88
|
handleHoloSignalData: (signalData: any) => Promise<void>;
|
|
@@ -112,7 +113,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
112
113
|
status: number;
|
|
113
114
|
message: string;
|
|
114
115
|
}>;
|
|
115
|
-
showSignalControlArea: (params: any) =>
|
|
116
|
+
showSignalControlArea: (params: any) => import("../types").IResult;
|
|
116
117
|
clearSignalControlArea: () => void;
|
|
117
118
|
locateSignalControlArea: (params: {
|
|
118
119
|
id: string;
|
|
@@ -121,6 +122,8 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
121
122
|
id: string;
|
|
122
123
|
}) => Promise<import("../types").IResult>;
|
|
123
124
|
resetHighlightSignalControlArea: () => import("../types").IResult;
|
|
125
|
+
showSubSignalControlArea: (params: any) => import("../types").IResult;
|
|
126
|
+
editSubSignalControlArea: () => import("../types").IResult;
|
|
124
127
|
props: any;
|
|
125
128
|
emit: (event: "mapLoaded" | "markerClick" | "mapClick", ...args: any[]) => void;
|
|
126
129
|
SignalCountdownPanel: import("vue").DefineComponent<{
|
|
@@ -144,6 +147,10 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
144
147
|
type: ArrayConstructor;
|
|
145
148
|
required: true;
|
|
146
149
|
};
|
|
150
|
+
scale: {
|
|
151
|
+
type: NumberConstructor;
|
|
152
|
+
required: true;
|
|
153
|
+
};
|
|
147
154
|
position: {
|
|
148
155
|
type: ObjectConstructor;
|
|
149
156
|
required: true;
|
|
@@ -202,6 +209,10 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
202
209
|
type: ArrayConstructor;
|
|
203
210
|
required: true;
|
|
204
211
|
};
|
|
212
|
+
scale: {
|
|
213
|
+
type: NumberConstructor;
|
|
214
|
+
required: true;
|
|
215
|
+
};
|
|
205
216
|
position: {
|
|
206
217
|
type: ObjectConstructor;
|
|
207
218
|
required: true;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const n=require("vue"),Ie=require("pinia"),v=require("./stores/index.js");require("./style/index.css");const O=require("./utils/holo-flow/index.js"),Me=require("./utils/holo-flow/signal-countdown-panel.vue.js"),_e=require("./utils/map-initializer.js"),k=require("./utils/open-drive-renderer/index.js"),A=require("./utils/overlay.js"),xe=require("./utils/queue-length.js"),L=require("./utils/road-config-tool/index.js"),T=require("./utils/signal-control-area-controller/index.js"),Be=require("./utils/traffic-flow.js"),He={class:"gis-viewer"},Ve={style:{position:"absolute",bottom:"10px",left:"10px"}},Pe=n.defineComponent({__name:"gis-map",props:{config:{},assetsRoot:{}},emits:["mapLoaded","markerClick","mapClick"],setup(b,{expose:D,emit:q}){const p=n.ref(null);let i,u,l,o,a,r,g,t,s;const f=n.ref(!1);v.registerStore();const h=v.default.useAppDataStore,{countdownPanels:I}=Ie.storeToRefs(h);n.onMounted(async()=>{if(!p.value)return;document.addEventListener("keydown",m=>{m.ctrlKey&&m.key==="i"&&(f.value=!f.value)});const e=n.getCurrentInstance(),{$gisviewerAssetsRoot:d}=e.appContext.config.globalProperties,c=await(await fetch(C.config)).json();c.assetsRoot=C.assetsRoot||d,h.mapConfig=c,u=new _e.default,i=await u.initialize({container:p.value,mapConfig:c,markerClickCallback:(m,y,S,qe)=>{w("markerClick",m,y,S,qe)},mapClickCallback:(m,y,S)=>{w("mapClick",m,y,S)}}),a=new O.default(i),await a.init(),w("mapLoaded")}),n.onUnmounted(()=>{s==null||s.clearSignalControlArea(),t==null||t.clearOpenDrive(),a.clearHoloTrace(),a.clearHoloSignal(),o==null||o.disconnectTrafficFlow()});const M=n.computed(()=>i),_=()=>{const e=v.default.useAppDataStore;e.saveTrackLog=!0},x=()=>{a.downloadTrackLog()},B=async e=>await u.setMapCenter(e),H=async e=>await u.setMapCamera(e),V=async e=>await u.lookAt(e),P=e=>u.setLayerVisibility(e),N=(e,d)=>u.requestCoordinateTransform(e,d),E=e=>{u.cancelCoordinateTransform(e)},j=e=>{u.setMapZoomRange(e)},z=e=>(l||(l=new L.default(i)),l.showLaneNumber(e)),Q=()=>{l==null||l.clearLaneNumber()},Z=async e=>(l||(l=new L.default(i)),await l.initializeSearch(e)),K=async()=>l==null?void 0:l.calCrossIndicatorArea(),U=async()=>{},G=async(e,d)=>{o||(o=new Be.default(i)),o.connectTrafficFlow(e,d)},J=()=>{o==null||o.disconnectTrafficFlow()},W=async e=>{a||(a=new O.default(i),await a.init()),a.handleVehicleTraceData(e)},X=()=>{a.clearHoloTrace()},Y=e=>{a.setInterpolate(e)},F=async e=>{await a.handleSignalData(e)},R=()=>{a.clearHoloSignal()},$=e=>{o==null||o.toggleTrafficInfo(e),a==null||a.toggleTrafficInfo(e)},ee=e=>{a==null||a.togglePause(e)},te=e=>{o==null||o.toggleTrafficObject(e),a==null||a.toggleTrafficObject(e)},ae=e=>{a==null||a.updatePanelContent(e)},ne=async e=>(r||(r=new A.default(i)),r.addOverlays(e)),re=e=>(r||(r=new A.default(i)),r.addMask(e)),se=()=>{r==null||r.removeMask()},oe=e=>r==null?void 0:r.removeOverlaysByType(e),ie=e=>r==null?void 0:r.removeOverlaysById(e),ce=()=>r==null?void 0:r.removeAllOverlays(),le=()=>{r==null||r.showAllOverlays()},ue=e=>{g||(g=new xe.default(i)),g.updateQueueLength(e)},de=()=>{g==null||g.removeQueueLength()},me=async(e,d)=>(t||(t=new k.default(i)),await t.showOpenDriveFromServer(e,d)),ge=async e=>(t||(t=new k.default(i)),await t.clearOpenDrive(),await t.showOpenDriveFromFile(e)),pe=async()=>await(t==null?void 0:t.clearOpenDrive()),fe=async e=>t?await(t==null?void 0:t.findSumo(e)):{status:-1,message:"未加载OpenDrive地图"},we=async e=>t?t.selectSumo(e):{status:-1,message:"未加载OpenDrive地图"},ye=async e=>t?t.unselectSumo(e):{status:-1,message:"未加载OpenDrive地图"},Se=async e=>t?await t.geometrySearch(e):{status:-1,message:"未加载OpenDrive地图"},ve=async e=>t?await t.getSumoInfo(e):{status:-1,message:"未加载OpenDrive地图"},he=async e=>t?await(t==null?void 0:t.splitLane(e)):{status:-1,message:"未加载OpenDrive地图"},Ce=async()=>t?t==null?void 0:t.clearSplitLane():{status:-1,message:"未加载OpenDrive地图"},Oe=e=>(s||(s=new T.default(i)),s.showSignalControlArea(e)),ke=()=>{s==null||s.clearSignalControlArea()},Ae=async e=>s?await s.locateSignalControlArea(e):{status:-1,message:"未加载信号控制区"},Le=async e=>s?await s.highlightSignalControlArea(e):{status:-1,message:"未加载信号控制区"},Te=()=>s?s.resetHighlight():{status:-1,message:"未加载信号控制区"},be=e=>(s||(s=new T.default(i)),s.showSubSignalControlArea(e)),De=()=>s?s.editSubSignalArea():{status:-1,message:"未加载信号控制区"},C=b,w=q;return D({mapViewer:M,setLayerVisibility:P,setMapCenter:B,lookAt:V,setMapCamera:H,setMapZoomRange:j,requestCoordinateTransform:N,cancelCoordinateTransform:E,addOverlays:ne,addMask:re,removeMask:se,showAllOverlays:le,removeOverlaysByType:oe,removeOverlaysById:ie,removeAllOverlays:ce,showLaneNumber:z,clearLaneNumber:Q,initializeAreaTool:Z,calCrossIndicatorArea:K,calRoadIndicatorArea:U,connectCarFlow:G,disconnectCarFlow:J,handleHoloVehicleTraceData:W,clearHoloTrace:X,handleHoloSignalData:F,clearHoloSignal:R,setInterpolate:Y,toggleTrafficInfo:$,toggleTrafficObject:te,toggleVehicleInfo:ae,togglePause:ee,updateQueueLength:ue,removeQueueLength:de,showOpenDriveFromServer:me,showOpenDriveFromFile:ge,clearOpenDrive:pe,geometrySearchInOpenDrive:Se,findSumoInOpenDrive:fe,selectSumoInOpenDrive:we,unselectSumoInOpenDrive:ye,getSumoInfo:ve,splitOpenDriveLane:he,clearSplitOpenDriveLane:Ce,showSignalControlArea:Oe,clearSignalControlArea:ke,locateSignalControlArea:Ae,highlightSignalControlArea:Le,resetHighlightSignalControlArea:Te,showSubSignalControlArea:be,editSubSignalControlArea:De}),(e,d)=>(n.openBlock(),n.createElementBlock("div",He,[n.createElementVNode("div",{class:"gis-viewer-main",ref_key:"mapContainer",ref:p},[n.withDirectives(n.createElementVNode("div",Ve,[n.createElementVNode("button",{style:{"margin-right":"10px"},onClick:_}," 开始记录 "),n.createElementVNode("button",{onClick:x},"下载日志")],512),[[n.vShow,f.value]])],512),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(n.unref(I),(c,m)=>(n.openBlock(),n.createBlock(Me.default,{key:m,"display-mode":c.displayMode,"road-id":c.crossId,"cross-id":c.roadId,"map-point":c.mapPoint,"stop-line":c.stopLine,position:c.position,rotation:c.rotation,scale:c.scale,"lamp-status":c.lampStatus},null,8,["display-mode","road-id","cross-id","map-point","stop-line","position","rotation","scale","lamp-status"]))),128))]))}});exports.default=Pe;
|
|
@@ -36,6 +36,7 @@ export declare const GisMap: import("@easyest/utils/dist/lib/withinstall").SFCWi
|
|
|
36
36
|
top: number;
|
|
37
37
|
};
|
|
38
38
|
rotation: number;
|
|
39
|
+
scale: number;
|
|
39
40
|
lampStatus: {
|
|
40
41
|
uNumber?: number | undefined;
|
|
41
42
|
uColor?: string | undefined;
|
|
@@ -70,7 +71,7 @@ export declare const GisMap: import("@easyest/utils/dist/lib/withinstall").SFCWi
|
|
|
70
71
|
calRoadIndicatorArea: () => Promise<void>;
|
|
71
72
|
connectCarFlow: (url: string, options?: any) => Promise<void>;
|
|
72
73
|
disconnectCarFlow: () => void;
|
|
73
|
-
handleHoloVehicleTraceData: (vehicleTrace: any) => void
|
|
74
|
+
handleHoloVehicleTraceData: (vehicleTrace: any) => Promise<void>;
|
|
74
75
|
clearHoloTrace: () => void;
|
|
75
76
|
setInterpolate: (enable: boolean) => void;
|
|
76
77
|
handleHoloSignalData: (signalData: any) => Promise<void>;
|
|
@@ -101,7 +102,7 @@ export declare const GisMap: import("@easyest/utils/dist/lib/withinstall").SFCWi
|
|
|
101
102
|
status: number;
|
|
102
103
|
message: string;
|
|
103
104
|
}>;
|
|
104
|
-
showSignalControlArea: (params: any) =>
|
|
105
|
+
showSignalControlArea: (params: any) => import("../types").IResult;
|
|
105
106
|
clearSignalControlArea: () => void;
|
|
106
107
|
locateSignalControlArea: (params: {
|
|
107
108
|
id: string;
|
|
@@ -110,6 +111,8 @@ export declare const GisMap: import("@easyest/utils/dist/lib/withinstall").SFCWi
|
|
|
110
111
|
id: string;
|
|
111
112
|
}) => Promise<import("../types").IResult>;
|
|
112
113
|
resetHighlightSignalControlArea: () => import("../types").IResult;
|
|
114
|
+
showSubSignalControlArea: (params: any) => import("../types").IResult;
|
|
115
|
+
editSubSignalControlArea: () => import("../types").IResult;
|
|
113
116
|
props: any;
|
|
114
117
|
emit: (event: "mapLoaded" | "markerClick" | "mapClick", ...args: any[]) => void;
|
|
115
118
|
SignalCountdownPanel: import("vue").DefineComponent<{
|
|
@@ -133,6 +136,10 @@ export declare const GisMap: import("@easyest/utils/dist/lib/withinstall").SFCWi
|
|
|
133
136
|
type: ArrayConstructor;
|
|
134
137
|
required: true;
|
|
135
138
|
};
|
|
139
|
+
scale: {
|
|
140
|
+
type: NumberConstructor;
|
|
141
|
+
required: true;
|
|
142
|
+
};
|
|
136
143
|
position: {
|
|
137
144
|
type: ObjectConstructor;
|
|
138
145
|
required: true;
|
|
@@ -191,6 +198,10 @@ export declare const GisMap: import("@easyest/utils/dist/lib/withinstall").SFCWi
|
|
|
191
198
|
type: ArrayConstructor;
|
|
192
199
|
required: true;
|
|
193
200
|
};
|
|
201
|
+
scale: {
|
|
202
|
+
type: NumberConstructor;
|
|
203
|
+
required: true;
|
|
204
|
+
};
|
|
194
205
|
position: {
|
|
195
206
|
type: ObjectConstructor;
|
|
196
207
|
required: true;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("../../../types/index.js"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const i=require("vue"),t=require("../../../types/index.js"),s=require("../../stores/index.js"),n=require("./signal-holo-flow.js"),c=require("./signal-holo-flow-lsr.js"),r=require("./trace-holo-flow.js");class h{constructor(e){this.view=e}async init(){this.traceHoloFlow=new r.default(this.view),await this.traceHoloFlow.init()}handleVehicleTraceData(e){this.traceHoloFlow.handleVehicleTraceData(e)}toggleTrafficObject(e){switch(e.name.toLowerCase()){case"groundVehicle".toLowerCase():this.traceHoloFlow.toggleGroundVehicle(e.visible);break;case"elevatedVehicle".toLowerCase():this.traceHoloFlow.toggleElevatedVehicle(e.visible);break}}clearHoloTrace(){this.traceHoloFlow.clearTrace()}toggleTrafficInfo(e){this.traceHoloFlow.toggleTrafficInfo(e)}togglePause(e){this.traceHoloFlow.togglePause(e)}updatePanelContent(e){let o=t.EVehiclePlateState.None;switch(e){case"none":o=t.EVehiclePlateState.None;break;case"plateNumber":o=t.EVehiclePlateState.PlateNumber;break;case"vehicleId":o=t.EVehiclePlateState.Id;break;case"mix":o=t.EVehiclePlateState.Mix;break}this.traceHoloFlow.updatePanelContent(o)}async handleSignalData(e){var o,l;if(!this.signalHoloFlow){const a=s.default.useAppDataStore;((l=(o=i.toRaw(a.mapConfig).holoFlow)==null?void 0:o.signal)==null?void 0:l.style)==="LSR"?this.signalHoloFlow=new c.default(this.view):this.signalHoloFlow=new n.default(this.view),await this.signalHoloFlow.initializeLayer()}await this.signalHoloFlow.handleSignalData(e)}clearHoloSignal(){var e;(e=this.signalHoloFlow)==null||e.clearSignal()}setInterpolate(e){this.traceHoloFlow.setInterpolate(e)}downloadTrackLog(){this.traceHoloFlow.downloadLog()}}exports.default=h;
|
|
@@ -19,6 +19,10 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
19
19
|
type: ArrayConstructor;
|
|
20
20
|
required: true;
|
|
21
21
|
};
|
|
22
|
+
scale: {
|
|
23
|
+
type: NumberConstructor;
|
|
24
|
+
required: true;
|
|
25
|
+
};
|
|
22
26
|
position: {
|
|
23
27
|
type: ObjectConstructor;
|
|
24
28
|
required: true;
|
|
@@ -77,6 +81,10 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
77
81
|
type: ArrayConstructor;
|
|
78
82
|
required: true;
|
|
79
83
|
};
|
|
84
|
+
scale: {
|
|
85
|
+
type: NumberConstructor;
|
|
86
|
+
required: true;
|
|
87
|
+
};
|
|
80
88
|
position: {
|
|
81
89
|
type: ObjectConstructor;
|
|
82
90
|
required: true;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./signal-countdown-panel.vue2.js");require("./signal-countdown-panel.vue3.js");const t=require("../../../../_virtual/_plugin-vue_export-helper.js"),u=t.default(e.default,[["__scopeId","data-v-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./signal-countdown-panel.vue2.js");require("./signal-countdown-panel.vue3.js");const t=require("../../../../_virtual/_plugin-vue_export-helper.js"),u=t.default(e.default,[["__scopeId","data-v-f1172941"]]);exports.default=u;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),g={key:0,class:"signal-countdown-container"},S=["src"],v={key:1,class:"signal-countdown-container"},y=["src"],N={key:2,class:"signal-countdown-container"},h=["src"],w={key:3,class:"signal-countdown-container"},V=["src"],C=e.defineComponent({__name:"signal-countdown-panel",props:{displayMode:{},crossId:{},roadId:{},mapPoint:{},stopLine:{},position:{},rotation:{},lampStatus:{}},setup(n){const t=n,s=e.computed(()=>({top:`${t.position.top}px`,left:`${t.position.left}px`,"transform-origin":"bottom center",transform:`translateX(-50%) translateY(-100%) rotate(${t.rotation}deg)`})),a=e.computed(()=>`/GisViewerAssets/Images/SignalLamp/u-${t.lampStatus.uColor}.png`),r=e.computed(()=>({color:l(t.lampStatus.uColor)})),c=e.computed(()=>`/GisViewerAssets/Images/SignalLamp/l-${t.lampStatus.lColor}.png`),i=e.computed(()=>({color:l(t.lampStatus.lColor)})),m=e.computed(()=>`/GisViewerAssets/Images/SignalLamp/s-${t.lampStatus.sColor}.png`),u=e.computed(()=>({color:l(t.lampStatus.sColor)})),d=e.computed(()=>`/GisViewerAssets/Images/SignalLamp/r-${t.lampStatus.rColor}.png`),p=e.computed(()=>({color:l(t.lampStatus.rColor)})),l=o=>{switch(o){case"red":return"red";case"yellow":return"rgb(255, 192, 2)";case"green":return"lime";default:return"white"}};return(o,E)=>(e.openBlock(),e.createElementBlock("div",{class:"signal-countdown-panel",style:e.normalizeStyle(s.value)},[o.lampStatus.uColor?(e.openBlock(),e.createElementBlock("div",g,[e.createElementVNode("div",{class:"signal-countdown-number",style:e.normalizeStyle(r.value)},e.toDisplayString(o.lampStatus.uNumber),5),e.createElementVNode("div",null,[e.createElementVNode("img",{src:a.value,width:"20px",height:"20px"},null,8,S)])])):e.createCommentVNode("",!0),o.lampStatus.lColor?(e.openBlock(),e.createElementBlock("div",v,[e.createElementVNode("div",{class:"signal-countdown-number",style:e.normalizeStyle(i.value)},e.toDisplayString(o.lampStatus.lNumber),5),e.createElementVNode("div",null,[e.createElementVNode("img",{src:c.value,width:"20px",height:"20px"},null,8,y)])])):e.createCommentVNode("",!0),o.lampStatus.sColor?(e.openBlock(),e.createElementBlock("div",N,[e.createElementVNode("div",{class:"signal-countdown-number",style:e.normalizeStyle(u.value)},e.toDisplayString(o.lampStatus.sNumber),5),e.createElementVNode("div",null,[e.createElementVNode("img",{src:m.value,width:"20px",height:"20px"},null,8,h)])])):e.createCommentVNode("",!0),o.lampStatus.rColor!==void 0?(e.openBlock(),e.createElementBlock("div",w,[e.createElementVNode("div",{class:"signal-countdown-number",style:e.normalizeStyle(p.value)},e.toDisplayString(o.lampStatus.rNumber),5),e.createElementVNode("div",null,[e.createElementVNode("img",{src:d.value,width:"20px",height:"20px"},null,8,V)])])):e.createCommentVNode("",!0)],4))}});exports.default=C;
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),g={key:0,class:"signal-countdown-container"},S=["src"],v={key:1,class:"signal-countdown-container"},y=["src"],N={key:2,class:"signal-countdown-container"},h=["src"],w={key:3,class:"signal-countdown-container"},V=["src"],C=e.defineComponent({__name:"signal-countdown-panel",props:{displayMode:{},crossId:{},roadId:{},mapPoint:{},stopLine:{},scale:{},position:{},rotation:{},lampStatus:{}},setup(n){const t=n,s=e.computed(()=>({top:`${t.position.top}px`,left:`${t.position.left}px`,"transform-origin":"bottom center",transform:`translateX(-50%) translateY(-100%) rotate(${t.rotation}deg) scale(${t.scale})`})),a=e.computed(()=>`/GisViewerAssets/Images/SignalLamp/u-${t.lampStatus.uColor}.png`),r=e.computed(()=>({color:l(t.lampStatus.uColor)})),c=e.computed(()=>`/GisViewerAssets/Images/SignalLamp/l-${t.lampStatus.lColor}.png`),i=e.computed(()=>({color:l(t.lampStatus.lColor)})),m=e.computed(()=>`/GisViewerAssets/Images/SignalLamp/s-${t.lampStatus.sColor}.png`),u=e.computed(()=>({color:l(t.lampStatus.sColor)})),d=e.computed(()=>`/GisViewerAssets/Images/SignalLamp/r-${t.lampStatus.rColor}.png`),p=e.computed(()=>({color:l(t.lampStatus.rColor)})),l=o=>{switch(o){case"red":return"red";case"yellow":return"rgb(255, 192, 2)";case"green":return"lime";default:return"white"}};return(o,E)=>(e.openBlock(),e.createElementBlock("div",{class:"signal-countdown-panel",style:e.normalizeStyle(s.value)},[o.lampStatus.uColor?(e.openBlock(),e.createElementBlock("div",g,[e.createElementVNode("div",{class:"signal-countdown-number",style:e.normalizeStyle(r.value)},e.toDisplayString(o.lampStatus.uNumber),5),e.createElementVNode("div",null,[e.createElementVNode("img",{src:a.value,width:"20px",height:"20px"},null,8,S)])])):e.createCommentVNode("",!0),o.lampStatus.lColor?(e.openBlock(),e.createElementBlock("div",v,[e.createElementVNode("div",{class:"signal-countdown-number",style:e.normalizeStyle(i.value)},e.toDisplayString(o.lampStatus.lNumber),5),e.createElementVNode("div",null,[e.createElementVNode("img",{src:c.value,width:"20px",height:"20px"},null,8,y)])])):e.createCommentVNode("",!0),o.lampStatus.sColor?(e.openBlock(),e.createElementBlock("div",N,[e.createElementVNode("div",{class:"signal-countdown-number",style:e.normalizeStyle(u.value)},e.toDisplayString(o.lampStatus.sNumber),5),e.createElementVNode("div",null,[e.createElementVNode("img",{src:m.value,width:"20px",height:"20px"},null,8,h)])])):e.createCommentVNode("",!0),o.lampStatus.rColor!==void 0?(e.openBlock(),e.createElementBlock("div",w,[e.createElementVNode("div",{class:"signal-countdown-number",style:e.normalizeStyle(p.value)},e.toDisplayString(o.lampStatus.rNumber),5),e.createElementVNode("div",null,[e.createElementVNode("img",{src:d.value,width:"20px",height:"20px"},null,8,V)])])):e.createCommentVNode("",!0)],4))}});exports.default=C;
|
|
@@ -6,6 +6,8 @@ export default class LSRSignalHoloFlow extends SignalHoloFlow {
|
|
|
6
6
|
constructor(view: __esri.MapView | __esri.SceneView);
|
|
7
7
|
private stopLineMap;
|
|
8
8
|
initializeLayer(): Promise<void>;
|
|
9
|
+
private currentPanelScale;
|
|
10
|
+
private getPanelScale;
|
|
9
11
|
handleSignalData(data: any): Promise<void>;
|
|
10
12
|
clearSignal(): void;
|
|
11
13
|
/**
|