forked from drone/command-center-dashboard

chenyao
2025-03-27 4b6bb2df2ea7edde4912b0ca1ccc95710ce3bdb8
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
<template>
  <div class="home">
    <div id="cesium"></div>
    <div class="page-index">
      <Header/>
      <router-view></router-view>
    </div>
  </div>
</template>
 
<script setup>
import { onMounted } from 'vue';
import cesiumOperation from '@/utils/cesium-tsa';
import Header from './Header.vue';
 
const { _init } = cesiumOperation();
 
onMounted(() => {
  _init('cesium');
});
</script>
 
<style scoped lang="scss">
.home {
  position: relative;
  height: 100%;
  width: 100%;
  overflow: hidden;
 
  #cesium {
    height: 100%;
    width: 100%;
 
    :deep() {
      .cesium-viewer {
        width: 100%;
        height: 100%;
 
        .cesium-viewer-cesiumWidgetContainer {
          width: 100%;
          height: 100%;
 
          .cesium-widget {
            width: 100%;
            height: 100%;
 
            canvas {
              width: 100%;
              height: 100%;
            }
          }
        }
      }
    }
  }
 
  .page-index {
    left: 0;
    top: 0;
    position: absolute;
    z-index: 999;
    height: 100%;
    width: 100%;
    background-image: url('../assets/images/bg-new.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    pointer-events: none;
    
    > * {
      pointer-events: auto;
    }
  }
}
</style>