lixuliang
2024-04-19 1fef6dcc04ffe09336e4983c2b05962ad901e545
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
<template>
  <div>
    <Popup
      ref="demo"
      :title="title"
      :left="left"
      :top="top"
      :maxHeight="maxHeight"
    >
      <div class="treeContainer">
        <div class="treeTitle">
          <el-button
            type="primary"
            size="mini"
            v-if="!isPlay && !playIndex"
            icon="el-icon-folder-opened"
            @click="start"
            >开始</el-button
          >
          <el-button
            type="primary"
            size="mini"
            v-if="isPlay"
            icon="el-icon-download"
            @click="pause"
            >暂停</el-button
          >
          <el-button
            type="primary"
            size="mini"
            v-if="!isPlay && playIndex"
            icon="el-icon-download"
            @click="pause"
            >继续</el-button
          >
          <el-button
            type="primary"
            v-if="isPlay"
            size="mini"
            icon="el-icon-download"
            @click="stop"
            >停止</el-button
          >
        </div>
 
        <el-tree
          ref="tree"
          :data="data"
          node-key="id"
          default-expand-all
          :expand-on-click-node="false"
          :render-content="renderContent"
        >
        </el-tree>
      </div>
    </Popup>
  </div>
</template>
 
<script>
import Bus from "@tools/Bus";
import Popup from "@tools/Popup";
 
let AnimationData = [];
let pointFly;
export default {
  name: "Layer",
  components: {
    Popup,
  },
  data() {
    return {
      title: "演示动画",
      left: "calc(100% - 330px)",
      top: "10px",
      maxHeight: "400px",
      isPlay: false,
      playIndex: 0,
      data: [
        {
          id: 0,
          type: "message",
          class: "error",
          name: "某地忽然发生火灾",
          time: 2,
        },
        {
          id: 1,
          type: "location",
          name: "火灾位置",
          position: [113.10963, 28.22072, 393.39, 299.9, -38.0],
        },
        {
          id: 2,
          type: "flame",
          name: "火灾",
          position: [113.10561, 28.22262, 62.82],
          time: 2,
        },
        {
          id: 3,
          type: "message",
          class: "error",
          name: "消防指挥中心接到报警电话",
          time: 2,
        },
        {
          id: 4,
          type: "location",
          name: "消防指挥中心位置",
          position: [113.12459, 28.22435, 1155.88, 304.6, -52.1],
        },
        {
          id: 5,
          type: "label",
          name: "消防指挥中心",
          position: [113.11665, 28.22942, 31.68],
          fillColor: "#f00",
          outlineColor: "#fff",
          font: "bold 28px 微软雅黑",
          outlineWidth: 2,
          time: 2,
        },
        {
          id: 6,
          type: "message",
          class: "error",
          name: "查看火灾区域周围情况",
          time: 2,
        },
        {
          id: 7,
          type: "location",
          name: "火灾周围位置",
          position: [113.12053, 28.21231, 1037.29, 309.2, -30.7],
        },
        {
          id: 8,
          type: "label",
          name: "火灾发生地点",
          position: [113.10561, 28.22262, 120],
          fillColor: "#f00",
          outlineColor: "#fff",
          font: "bold 28px 微软雅黑",
          outlineWidth: 2,
          time: 1,
        },
        {
          id: 9,
          type: "pointFly",
          name: "查看火灾周围",
          position: [113.10561, 28.22262, 62.82],
          time: 25,
        },
        {
          id: 10,
          type: "message",
          class: "error",
          name: "分析周边资源",
          time: 2,
        },
        {
          id: 11,
          type: "label",
          name: "周边资源分析中...",
          position: [113.10719, 28.22184, 24.09],
          fillColor: "#f00",
          outlineColor: "#fff",
          font: "28px 微软雅黑",
          outlineWidth: 2,
          deleteTime: 15,
        },
        {
          id: 12,
          type: "circle",
          name: "一级区域",
          position: [113.10561, 28.22262, 1.0],
          color: "rgba(0,0,255,0.1)",
          radius: 400,
          heightReference: 0,
          height: 6,
          outline: true,
          deleteTime: 15,
          time: 3,
        },
        {
          id: 13,
          type: "circle",
          name: "二级区域",
          position: [113.10561, 28.22262, 1.0],
          color: "rgba(0,0,255,0.1)",
          radius: 800,
          heightReference: 0,
          height: 5,
          outline: true,
          deleteTime: 9,
          time: 3,
        },
        {
          id: 14,
          type: "circle",
          name: "三级区域",
          position: [113.10561, 28.22262, 1.0],
          color: "rgba(0,0,255,0.2)",
          radius: 1200,
          heightReference: 0,
          height: 4,
          outline: true,
          deleteTime: 3,
          time: 9,
        },
        {
          id: 15,
          type: "label",
          name: "消防中队",
          position: [113.10047, 28.22026, 12.86],
          fillColor: "#f00",
          outlineColor: "#fff",
          font: "28px 微软雅黑",
          outlineWidth: 2,
        },
        {
          id: 16,
          type: "label",
          name: "应急专家",
          position: [113.09807, 28.22219, 9.87],
          fillColor: "#ff0",
          outlineColor: "#fff",
          font: "28px 微软雅黑",
          outlineWidth: 2,
        },
        {
          id: 17,
          type: "message",
          class: "error",
          name: "呼叫周边消防队和应急专家",
          time: 2,
        },
        {
          id: 18,
          type: "location",
          name: "消防队和应急专家位置详情",
          position: [113.10189, 28.22137, 1639.63, 0, -90],
        },
        {
          id: 19,
          type: "message",
          class: "error",
          name: "规划最短路径",
          time: 2,
        },
        {
          id: 20,
          type: "TrailLine",
          name: "消防队路线详情",
          color: "#f00",
          position: [
            113.10025, 28.22042, 113.10028, 28.22126, 113.10599, 28.22122,
            113.10587, 28.22261,
          ],
          deleteTime: 6,
        },
        {
          id: 21,
          type: "TrailLine",
          name: "专家路线详情",
          color: "#ff0",
          position: [
            113.09756, 28.22186, 113.09761, 28.22127, 113.10028, 28.22126,
            113.10599, 28.22122, 113.10587, 28.22261,
          ],
          deleteTime: 6,
          time: 5,
        },
        {
          id: 22,
          type: "message",
          class: "error",
          name: "消防队和应急专家赶往现场",
          time: 2,
        },
        {
          id: 23,
          type: "czml",
          name: "消防队前往现场",
          model:
            "http://183.162.245.49:8099/ModelLibrary/车辆/xiaofangche.gltf",
          position: [
            0, 113.10025, 28.22042, 1, 2, 113.10028, 28.22126, 1, 6, 113.10599,
            28.22122, 1, 10, 113.10587, 28.22261, 1,
          ],
        },
        {
          id: 24,
          type: "czml",
          name: "应急专家前往现场",
          position: [
            0, 113.09757, 28.22223, 1, 2, 113.09761, 28.22127, 1, 4, 113.10028,
            28.22126, 1, 8, 113.10599, 28.22122, 1, 12, 113.10593, 28.22225, 1,
          ],
          time: 12,
        },
        {
          id: 25,
          type: "location",
          name: "火灾位置",
          position: [113.11057, 28.21997, 393.16, 299.9, -38.0],
        },
        {
          id: 26,
          type: "fountain",
          name: "灭火",
          position: [113.10587, 28.22261, 1],
          emissionRate: 150, // 粒子数量
          minimumSpeed: 16, // 最小速度
          maximumSpeed: 26, // 最大速度
          heading: 10,
          pitch: 15,
          time: 2,
        },
        {
          id: 27,
          type: "message",
          class: "error",
          name: "分析火灾威胁范围",
          time: 2,
        },
        {
          id: 28,
          type: "label",
          name: "严重威胁",
          position: [113.10521, 28.22255, 12.86],
          fillColor: "#f00",
          outlineColor: "#fff",
          font: "20px 微软雅黑",
          outlineWidth: 2,
          deleteTime: 18,
        },
        {
          id: 29,
          type: "circle",
          name: "严重威胁",
          position: [113.10561, 28.22262, 1.0],
          color: "rgba(255,0,0,0.5)",
          radius: 50,
          heightReference: 0,
          height: 6,
          outline: true,
          deleteTime: 18,
          time: 3,
        },
        {
          id: 30,
          type: "label",
          name: "一般威胁",
          position: [113.10555, 28.22189, 12.86],
          fillColor: "#f00",
          outlineColor: "#fff",
          font: "20px 微软雅黑",
          outlineWidth: 2,
          deleteTime: 9,
        },
        {
          id: 31,
          type: "circle",
          name: "一般威胁",
          position: [113.10561, 28.22262, 1.0],
          color: "rgba(255,0,0,0.2)",
          radius: 100,
          heightReference: 0,
          height: 5,
          outline: true,
          deleteTime: 9,
          time: 3,
        },
        {
          id: 32,
          type: "label",
          name: "轻度威胁",
          position: [113.10622, 28.22157, 12.86],
          fillColor: "#ff0",
          outlineColor: "#fff",
          font: "20px 微软雅黑",
          outlineWidth: 2,
          deleteTime: 3,
        },
        {
          id: 33,
          type: "circle",
          name: "轻度威胁",
          position: [113.10561, 28.22262, 1.0],
          color: "rgba(255,255,0,0.4)",
          radius: 150,
          heightReference: 0,
          height: 4,
          outline: true,
          deleteTime: 3,
          time: 9,
        },
        {
          id: 34,
          type: "label",
          name: "某某学校",
          position: [113.11, 28.22246, 19.51],
          fillColor: "#0f0",
          outlineColor: "#fff",
          font: "28px 微软雅黑",
          outlineWidth: 2,
          deleteTime: 10,
        },
        {
          id: 35,
          type: "location",
          name: "查看逃生路线",
          position: [113.11574, 28.22257, 898.21, 268.9, -51.7],
        },
        {
          id: 36,
          type: "TrailLine",
          name: "逃生路线",
          color: "#0000ff",
          width: 10,
          position: [
            113.10587, 28.22261, 113.10599, 28.22122, 113.11007, 28.22127,
            113.11003, 28.22183,
          ],
          deleteTime: 6,
          time: 2,
        },
        {
          id: 37,
          type: "message",
          class: "error",
          name: "警方组织人员疏散",
          time: 4,
        },
        {
          id: 38,
          type: "message",
          class: "success",
          name: "经过两小时的救援,火情得到控制",
          time: 3,
        },
        {
          id: 39,
          type: "removeEffect",
          name: "灭火结束",
          time: 2,
        },
        {
          id: 40,
          type: "message",
          class: "success",
          name: "确认人员伤亡情况",
          time: 2,
        },
        {
          id: 41,
          type: "polygon",
          name: "安全区域",
          position: [
            113.11042, 28.22178, 113.11038, 28.22335, 113.10932, 28.22335,
            113.10943, 28.22181,
          ],
          clampToGround: true,
          deleteTime: 8,
        },
        {
          id: 42,
          type: "label",
          name: "安全区",
          position: [113.10953, 28.22256, 12.86],
          fillColor: "#ff0",
          outlineColor: "#fff",
          font: "20px 微软雅黑",
          outlineWidth: 2,
          deleteTime: 8,
        },
        {
          id: 43,
          type: "model",
          name: "人员1",
          position: [113.10989, 28.22233, 0],
          url: "http://183.162.245.49:8099/ModelLibrary/人/gongren.glb",
          deleteTime: 8,
        },
        {
          id: 44,
          type: "model",
          name: "人员2",
          position: [113.10986, 28.22233, 0],
          url: "http://183.162.245.49:8099/ModelLibrary/人/walk.gltf",
          deleteTime: 8,
        },
        {
          id: 45,
          type: "model",
          name: "人员3",
          position: [113.10982, 28.22246, 0],
          url: "http://183.162.245.49:8099/ModelLibrary/人/walk.gltf",
          deleteTime: 8,
        },
        {
          id: 46,
          type: "model",
          name: "消防员",
          position: [113.10982, 28.2224, 0],
          url: "http://183.162.245.49:8099/ModelLibrary/人/xiaofangyuan.glb",
          deleteTime: 8,
        },
        {
          id: 47,
          type: "location",
          name: "查看安全区",
          position: [113.11061, 28.22249, 82.63, 270.9, -48.0],
        },
        {
          id: 48,
          type: "message",
          class: "success",
          name: "查看避难所内所有人员,确认无伤亡情况",
          time: 2,
        },
        {
          id: 49,
          type: "location",
          name: "俯瞰全局",
          position: [113.12103, 28.2227, 1949.69, 268.9, -51.7],
        },
        {
          id: 50,
          type: "message",
          class: "success",
          name: "火灾救援任务完成,各部门陆续撤离现场",
          time: 3,
        },
      ],
    };
  },
  mounted() {},
  destroyed() {},
  methods: {
    open() {
      this.$refs.demo.open();
    },
    // 渲染
    renderContent(h, { node, data }) {
      return (
        <span class="custom-tree-node" on-click={() => this.play(data)}>
          <span>
            <i class={data.children ? "el-icon-folder" : "el-icon-star-on"}></i>
            {data.name}
          </span>
        </span>
      );
    },
    message(item) {
      this.$message({
        customClass: "noIconMessage",
        center: true,
        message: item.name,
        type: item.class,
        duration: item.time * 1000,
        offset: 140,
      });
    },
    timeOut(callback, time) {
      clearTimeout(this.time);
      this.time = setTimeout(callback, time * 1000);
    },
    start() {
      this.playIndex = 0;
      this.isPlay = true;
      this.play();
    },
    play(data) {
      if (data) {
        this.stop();
        this.playIndex = data.id;
        this.isPlay = true;
      }
      if (this.playIndex > this.data.length - 1) {
        this.stop();
        return;
      } else if (!this.isPlay) {
        return;
      }
      let thisPlay = this.data[this.playIndex];
 
      if (thisPlay.type === "location") {
        let position = thisPlay.position;
        if (!thisPlay.time) {
          thisPlay.time = 3;
        }
        sgworld.Navigate.flyToPointsInterest({
          destination: Cesium.Cartesian3.fromDegrees(
            position[0],
            position[1],
            position[2]
          ),
          orientation: {
            heading: Cesium.Math.toRadians(position[3]),
            pitch: Cesium.Math.toRadians(position[4]),
            roll: 0,
          },
        });
      } else if (thisPlay.type === "message") {
        this.message(thisPlay);
      } else if (thisPlay.type === "flame" || thisPlay.type === "fountain") {
        this.addParticleEffect(thisPlay);
      } else if (thisPlay.type === "removeEffect") {
        let type = ["fireworks", "fountain", "flame", "smog"];
        type.forEach((item) => {
          sgworld.Analysis.removeParticleEffect(item);
        });
      } else if (thisPlay.type === "label") {
        let position = thisPlay.position;
        let label = sgworld.Creator.addSimpleGraphic("label", {
          ...thisPlay,
          text: thisPlay.name,
          heightReference: 0,
          removeEdit: true,
          position: Cesium.Cartesian3.fromDegrees(
            position[0],
            position[1],
            position[2]
          ),
        });
        AnimationData.push(label);
        if (thisPlay.deleteTime) {
          setTimeout(() => {
            Viewer.entities.remove(label);
          }, thisPlay.deleteTime * 1000);
        }
      } else if (thisPlay.type === "model") {
        let position = thisPlay.position;
        let model = sgworld.Creator.addSimpleGraphic("model", {
          ...thisPlay,
          removeEdit: true,
          position: Cesium.Cartesian3.fromDegrees(
            position[0],
            position[1],
            position[2]
          ),
        });
        AnimationData.push(model);
        if (thisPlay.deleteTime) {
          setTimeout(() => {
            Viewer.entities.remove(model);
          }, thisPlay.deleteTime * 1000);
        }
      } else if (thisPlay.type === "polygon") {
        let polygon = sgworld.Creator.addSimpleGraphic("polygon", {
          ...thisPlay,
          removeEdit: true,
          positions: Cesium.Cartesian3.fromDegreesArray(thisPlay.position),
        });
        AnimationData.push(polygon);
        if (thisPlay.deleteTime) {
          setTimeout(() => {
            Viewer.entities.remove(polygon);
          }, thisPlay.deleteTime * 1000);
        }
      } else if (thisPlay.type === "circle") {
        let position = thisPlay.position;
        let label = sgworld.Creator.addSimpleGraphic("circle", {
          ...thisPlay,
          removeEdit: true,
          position: Cesium.Cartesian3.fromDegrees(
            position[0],
            position[1],
            position[2]
          ),
        });
        AnimationData.push(label);
        if (thisPlay.deleteTime) {
          setTimeout(() => {
            Viewer.entities.remove(label);
          }, thisPlay.deleteTime * 1000);
        }
      } else if (thisPlay.type === "pointFly") {
        let position = thisPlay.position;
        pointFly = sgworld.Analysis.setPointFly({
          position: Cesium.Cartesian3.fromDegrees(
            position[0],
            position[1],
            position[2]
          ),
          time: thisPlay.time,
          hideImage: true,
        });
      } else if (thisPlay.type === "TrailLine") {
        let position = thisPlay.position;
        let TrailLine = sgworld.Creator.createTrailLine(
          Cesium.Cartesian3.fromDegreesArray(position),
          {
            //time: 3000,    //时间(可选)
            width: thisPlay.width || 5, //线宽(可选)
            color: thisPlay.color || "#0000ff", //线颜色(可选)
            clampToGround: true, //是否贴地(可选)
          }
        );
        AnimationData.push(TrailLine);
        if (thisPlay.deleteTime) {
          setTimeout(() => {
            TrailLine.deleteObject();
          }, thisPlay.deleteTime * 1000);
        }
      } else if (thisPlay.type === "czml") {
        let czml = this.initCZML(thisPlay);
        AnimationData.push(czml);
        if (thisPlay.deleteTime) {
          setTimeout(() => {
            czml.deleteObject();
          }, thisPlay.deleteTime * 1000);
        }
      }
      if (thisPlay.time) {
        this.timeOut(() => {
          pointFly && pointFly.end();
          pointFly = undefined;
          this.playIndex++;
          this.play();
        }, thisPlay.time);
      } else {
        this.playIndex++;
        this.play();
      }
    },
    stop() {
      clearTimeout(this.time);
      sgworld.Navigate.Stop(); //取消飞行状态
 
      this.playIndex = 0;
      this.isPlay = false;
      AnimationData.forEach((item) => {
        item.deleteObject && item.deleteObject();
        Viewer.scene.primitives.remove(item);
        Viewer.entities.remove(item);
      });
      AnimationData = [];
      pointFly && pointFly.end();
      pointFly = undefined;
    },
    pause() {
      this.isPlay = !this.isPlay;
    },
    addParticleEffect(data) {
      let position = data.position;
      sgworld.Analysis.createParticleEffect(
        data.type,
        {
          x: position[0],
          y: position[1],
          z: position[2],
        },
        {
          translation: Cesium.Cartesian3.fromElements(
            data.x || 0,
            data.y || 0,
            data.z || 0
          ), //平移
          rotation: Cesium.HeadingPitchRoll.fromDegrees(
            data.heading || 0,
            data.pitch || 0,
            data.roll || 0.0
          ), // 旋转
          ...data,
        },
        (effects) => {
          let Effect = effects[effects.length - 1];
          AnimationData.push(Effect);
          if (data.deleteTime) {
            setTimeout(() => {
              Viewer.scene.primitives.remove(Effect);
            }, data.deleteTime * 1000);
          }
        }
      );
    },
    initCZML(data) {
      let lon = data.position[data.position.length - 3];
      let lat = data.position[data.position.length - 2];
      let h = data.position[data.position.length - 1];
      data.position.push(600, lon, lat, h);
      let czml = [
        {
          id: "document",
          name: "daodan1",
          version: "1.0",
          clock: {
            interval: "2020-05-01T16:00:00Z/2020-05-01T16:10:00Z",
            currentTime: "2019-06-01T16:00:00Z",
            multiplier: 1,
          },
        },
        {
          id: data.id + "czml",
          position: {
            interpolationAlgorithm: "LINEAR",
            interpolationDegree: 1,
            epoch: "2020-05-01T16:00:00Z",
            cartographicDegrees: data.position,
          },
          orientation: {
            velocityReference: "#position",
          },
          model: {
            scale: 1.5,
            gltf:
              data.model ||
              "http://183.162.245.49:82/05sdkdemo-pro/static/SmartEarthSDK/Workers/Model/xiaoche.glb",
          },
        },
      ];
 
      return sgworld.Creator.CZML(czml, {});
    },
  },
};
</script>
 
<style scoped lang="less" scoped>
.treeContainer {
  width: 100%;
  height: 100%;
 
  .treeTitle {
    text-align: center;
    margin: 10px 0;
  }
 
  .el-tree {
    background: transparent;
    color: #fff;
  }
 
  /deep/ .el-tree-node__content:hover {
    background-color: rgba(245, 247, 250, 0.2);
  }
 
  /deep/ .el-tree-node:focus > .el-tree-node__content {
    background-color: rgba(245, 247, 250, 0.2);
  }
 
  /deep/ .custom-tree-node {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 14px;
    padding-right: 10px;
 
    i {
      margin-right: 5px;
    }
  }
}
</style>