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
| <template>
| <!-- v-show="isOpenDrawALine" -->
| <div
| :class="['mobileCloseRouter', isOpenDrawALine ? 'mobileCloseActive' : '']"
| @click="mobileRouterClose"
| >
| 退出导航
| </div>
| </template>
|
| <script>
| import { mapGetters } from "vuex";
| export default {
| name: "mobileCloseRouter",
| computed: {
| ...mapGetters(["isOpenDrawALine"]),
| },
| watch: {
| isOpenDrawALine() {
| if (this.isOpenDrawALine) {
| } else {
| }
| },
| },
| methods: {
| mobileRouterClose() {
| this.$store.commit("removePolyline");
| },
| },
| };
| </script>
|
| <style lang="scss" scoped>
| .mobileCloseRouter {
| position: fixed;
| width: 80px;
| height: 32px;
| background-color: #409eff;
| z-index: 600;
| right: -100px;
| opacity: 0;
| bottom: 320px;
| font-size: 14px;
| display: flex;
| align-items: center;
| justify-content: center;
| border-radius: 8px 0 0 8px;
| color: #fff;
| transition: all 0.5s;
| }
| .mobileCloseActive {
| right: 0px;
| opacity: 1;
| }
| </style>
|
|