ソースを参照

最新和排行榜优化

pansl 1 年間 前
コミット
d164844040
2 ファイル変更22 行追加4 行削除
  1. 11 2
      pages/index/billboard/index.vue
  2. 11 2
      pages/index/new/index.vue

+ 11 - 2
pages/index/billboard/index.vue

@@ -8,9 +8,9 @@
 			</view>
 		</view>
 
-		<view class="flex space" style="display:flex; flex-wrap:wrap; padding: 30upx 30upx 0px 30upx;">
+		<view class="wrapper">
 			<block v-for="(value,key) in listData.data" :key="key">
-				<view class="box pb10 mb15" style="width:31%; border-radius:20rpx;" @click="detail(value)">
+				<view class="box pb10 mb15" style="width:30%; border-radius:20rpx;" @click="detail(value)">
 					<image class="integral-mall-goods" mode="aspectFill" :src="value.cover_image"></image>
 					<view class="mt8 plr10 ft14 ftw400 text-center text-over cl-main">{{value.name}}</view>
 				</view>
@@ -101,6 +101,15 @@
 </script>
 
 <style lang="scss" scoped>
+	.wrapper {
+		display: flex;
+		flex-wrap: wrap;
+
+		.box {
+			margin: 10rpx;
+		}
+	}
+
 	.top {
 		position: relative;
 

+ 11 - 2
pages/index/new/index.vue

@@ -1,8 +1,8 @@
 <template>
 	<view>
-		<view class="flex space" style="display:flex; flex-wrap:wrap; padding: 30upx 30upx 0px 30upx;">
+		<view class="wrapper" style="">
 			<block v-for="(value,key) in listData" :key="key">
-				<view class="box pb10 mb15" style="width:31%; border-radius:20rpx;" @click="detail(value)">
+				<view class="box pb10 mb15" style="width:30%; border-radius:20rpx;" @click="detail(value)">
 					<image class="integral-mall-goods" mode="aspectFill" :src="value.cover_image"></image>
 					<view class="mt8 plr10 ft14 ftw400 text-center text-over cl-main">{{value.name}}</view>
 				</view>
@@ -93,6 +93,15 @@
 </script>
 
 <style lang="scss" scoped>
+	.wrapper {
+		display: flex;
+		flex-wrap: wrap;
+
+		.box {
+			margin: 10rpx;
+		}
+	}
+
 	.integral-mall-goods {
 		width: 100%;
 		height: 280rpx;