燕山石化溯源三维电子沙盘-【前端】-Web
1
WX
2023-09-08 5a4c6108b5c30d22d41d614c6212711607920c92
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
<template>
  <div class="">
    <div class="Switch_box">
      <div class="Switch">
        <span>粒子</span>
        <el-switch
          v-model="data.value1"
          active-text="显示"
          inactive-text="隐藏"
          inline-prompt
        />
      </div>
      <div class="Switch">
        <span>周边</span>
        <el-switch
          v-model="data.value1"
          active-text="显示"
          inactive-text="隐藏"
          inline-prompt
        />
      </div>
      <div class="Switch" style="margin-right: 0">
        <span>地形</span>
        <el-switch
          v-model="data.value1"
          active-text="显示"
          inactive-text="隐藏"
          inline-prompt
        />
      </div>
    </div>
    <div class="Slider_box slider-demo-block">
      <span class="demonstration">拉伸</span>
      <el-slider v-model="data.value2" />
    </div>
    <div class="Slider_box slider-demo-block">
      <span class="demonstration">高度</span>
      <el-slider v-model="data.value2" />
    </div>
    <div class="Slider_box slider-demo-block">
      <span class="demonstration">密度</span>
      <el-slider v-model="data.value2" />
    </div>
    <div class="Slider_box slider-demo-block">
      <span class="demonstration">大小</span>
      <el-slider v-model="data.value2" />
    </div>
    <div class="Slider_box slider-demo-block">
      <span class="demonstration">速度</span>
      <el-slider v-model="data.value2" />
    </div>
  </div>
</template>
 
<script>
import { reactive, onMounted, watch } from "vue";
export default {
  //import引入的组件需要注入到对象中才能使用
  components: {},
  props: [],
  setup(props) {
    let data = reactive({
      value1: true,
      value2: 1,
    });
    return { data };
  },
};
</script>
<style lang="less" scoped>
//@import url(); 引入公共css类
.Switch_box {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  .Switch {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-right: 60px;
 
    span {
      color: #fff;
      font-size: 20px;
      margin-right: 10px;
    }
  }
}
.Slider_box {
  background: rgba(0, 0, 0, 0.2);
  margin-bottom: 20px;
  border-radius: 10px;
  padding: 30px;
}
.slider-demo-block {
  display: flex;
  align-items: center;
}
.slider-demo-block .el-slider {
  margin-top: 0;
  margin-left: 12px;
}
.slider-demo-block .demonstration {
  font-size: 20px;
  color: #fff;
  //   line-height: 44px;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-bottom: 0;
}
.slider-demo-block .demonstration + .el-slider {
  flex: 0 0 70%;
}
</style>