feat:完善首页样式
This commit is contained in:
@@ -6,14 +6,11 @@
|
||||
</template>
|
||||
</Title1>
|
||||
<div class="flex pt-20">
|
||||
<div
|
||||
class="item"
|
||||
:class="{ core: index == 0, queue: index == 1, congestion: index == 2 }"
|
||||
v-for="(item, index) in homeData?.scenicSpot"
|
||||
:key="index"
|
||||
>
|
||||
<span class="label">{{ item.name }}</span>
|
||||
<div class="flex align-end">
|
||||
<!-- :class="{ core: index == 0, queue: index == 1, congestion: index == 2 }" -->
|
||||
<div class="item" v-for="(item, index) in homeData?.scenicSpot" :key="index">
|
||||
<img class="item-icon" src="@/assets/images/core.png" alt="" />
|
||||
<span class="item-label">{{ item.name }}</span>
|
||||
<div class="item-value flex align-end rela">
|
||||
<countup :end-val="item.value" /><span class="unit">个</span>
|
||||
</div>
|
||||
</div>
|
||||
@@ -241,24 +238,35 @@
|
||||
}
|
||||
.item {
|
||||
position: relative;
|
||||
flex: 1;
|
||||
padding-left: vw(70);
|
||||
height: vh(52);
|
||||
margin: 0 vh(10);
|
||||
flex: 1;
|
||||
z-index: 1;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
background-size: 100% 100%;
|
||||
.label {
|
||||
&-icon {
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
height: auto;
|
||||
z-index: -1;
|
||||
}
|
||||
&-label {
|
||||
position: absolute;
|
||||
left: vw(80);
|
||||
top: vh(-10);
|
||||
font-weight: 400;
|
||||
font-size: vw(14);
|
||||
color: rgba(255, 255, 255, 0.7);
|
||||
}
|
||||
.countup-wrap {
|
||||
color: #02f9fa;
|
||||
font-size: vw(28);
|
||||
font-weight: bold;
|
||||
&-value {
|
||||
position: absolute;
|
||||
left: vw(80);
|
||||
.countup-wrap {
|
||||
color: #02f9fa;
|
||||
font-size: vw(28);
|
||||
font-weight: bold;
|
||||
}
|
||||
}
|
||||
}
|
||||
.unit {
|
||||
|
||||
Reference in New Issue
Block a user