1.配置H5 的样式展示

yj-dev
杨杰 4 years ago
parent 3e88aed859
commit e894ce24f6
  1. 37
      pages/goods/goods.vue
  2. 62
      pages/tabBar/user/user.vue

@ -13,7 +13,7 @@
<view class="swiper-box">
<swiper circular="true" autoplay="true" @change="swiperChange">
<swiper-item v-for="(swiper,index) in swiperList" :key="index">
<image mode="widthFix" :src="imageUrl+swiper" @click="perImage(swiper)"></image>
<image :src="imageUrl+swiper" @click="perImage(swiper)"></image>
</swiper-item>
</swiper>
<view class="indicator">{{currentSwiper+1}}/{{swiperList.length}}</view>
@ -742,13 +742,43 @@
}
}
// .swiper-box {
// position: relative;
// width: 100%;
// swiper {
// width: 100%;
// swiper-item {
// image {
// width: 100%;
// height: 100vw;
// }
// }
// }
// .indicator {
// display: flex;
// justify-content: center;
// align-items: center;
// padding: 0 25upx;
// height: 40upx;
// border-radius: 40upx;
// font-size: 22upx;
// position: absolute;
// bottom: 20upx;
// right: 20upx;
// color: #fff;
// background-color: rgba(0, 0, 0, 0.2);
// }
// }
.swiper-box {
position: relative;
width: 100%;
height: 100vw;
swiper {
width: 100%;
height: 100vw;
swiper-item {
image {
width: 100%;
@ -756,7 +786,6 @@
}
}
}
.indicator{
display: flex;
justify-content: center;

@ -1,11 +1,9 @@
<template>
<view>
<view v-if="showHeader" class="status" :style="{position:headerPosition,top:statusTop}"></view>
<view v-if="showHeader" class="header" :style="{position:headerPosition,top:headerTop}"></view>
<!-- 占位 -->
<!-- <view class="place">
<image @click="toScan"
src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAACACAYAAADDPmHLAAAHvUlEQVR4Xu2dv45XRRTHz9cHELQyFgqxsWMpTTSyJtawlXaADyDQ2QGVJcsTuBsbjSbuGwCFsQRiorFy6bRieQA95it3ZV1+986ZuTOz85t7JiFLMnNnzvmez5z5c+EuxMuiFcCivXfnxQFYOAQOgAOwcAUW7r5nAAdg4Qos3H3PAA7AwhVYuPueARyAhSuwcPc9AzgA5RVQ1TMiclFELogI/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knufkx2AAQIuCXwpwT+WY2KuYEW/Do0d2HAlG9tlqD0Dzwm1nSPlHx+sCABHlgSCwIxAEM6FPJ1ZT6G4Lha9eVRV+sQMUzrDPR6OzDslAn+odVEAjgZ0EI4XG9xA8So56h8uBOBg0ClUlXuFwRee1+lP9AuYEV9oO/8QLv5CySr/qKYaADNntz9eSAEHoJCw69KtA7AukSpkpwNQSNh16dYBWJdIFbLTASgk7Lp06wCsS6QK2ekAFBJ2Xbp1ANYlUoXsdAAKCbsu3ToA6xKpQnY6AIWEXZdu/wEz5iC9/YCh3gAAAABJRU5ErkJggg==">
</image>
</view> -->
<view v-if="showHeader" class="place"></view>
<view class="user">
<!-- 头像 -->
<view class="left">
@ -95,7 +93,7 @@
</view>
<!-- 占位 -->
<view class="place-bottom"></view>
<authorize></authorize>
<!-- <authorize></authorize> -->
</view>
</template>
<script>
@ -200,6 +198,14 @@
},
onLoad() {
this.statusHeight = 0;
// #ifdef APP-PLUS
this.showHeader = false;
this.statusHeight = plus.navigator.getStatusbarHeight();
// #endif
// #ifdef MP
this.showHeader = false;
this.statusHeight = plus.navigator.getStatusbarHeight();
// #endif
},
onReady() {
//,
@ -337,6 +343,50 @@
background-color: #fff;
}
.status {
width: 100%;
height: 0;
position: fixed;
z-index: 10;
background-color: #f06c7a;
top: 0;
/* #ifdef APP-PLUS */
height: var(--status-bar-height);//
/* #endif */
}
.header{
width: 92%;
padding: 0 4%;
height: 100upx;
display: flex;
justify-content: flex-end;
align-items: center;
position: fixed;
top: 0;
z-index: 10;
background-color: #f06c7a;
/* #ifdef APP-PLUS */
top: var(--status-bar-height);
/* #endif */
.icon-btn{
width: 120upx;
height: 60upx;
flex-shrink: 0;
display: flex;
.icon{
color: #fff;
width: 60upx;
height: 60upx;
display: flex;
justify-content: flex-end;
align-items: center;
font-size: 42upx;
}
}
}
button::after {
border: none
}

Loading…
Cancel
Save