提交 b48dad57 编写于 作者: 赵十四's avatar 赵十四

修改帖子显示图片的方式

上级 c76ed1b7
......@@ -30,12 +30,11 @@
<view class="img-conetent">
<!-- 多张图片 -->
<view v-if="item.pictureList.length!=1" class="one-img" v-for="img in item.pictureList">
<image :src="img" class="post-pic" @click.stop="showPic(img)"></image>
<view class="post-pic" @click.stop="showPic(img)" :style="'background: url('+img+') no-repeat center/cover #eeeeee;'"></view>
</view>
<!-- 单张图片 -->
<view v-if="item.pictureList.length == 1">
<image :src="item.pictureList[0]" class="single-pic"
@click.stop="showPic(item.pictureList[0])"></image>
<view v-if="item.pictureList.length == 1" class="single-pic" @click.stop="showPic(item.pictureList[0])"
:style="'background: url('+item.pictureList[0]+') no-repeat center/cover #eeeeee;'" >
</view>
</view>
</view>
......@@ -75,12 +74,11 @@
<view class="img-conetent">
<!-- 多张图片 -->
<view v-if="item.pictureList.length!=1" class="one-img" v-for="img in item.pictureList">
<image :src="img" class="post-pic" @click.stop="showPic(img)"></image>
<view class="post-pic" @click.stop="showPic(img)" :style="'background: url('+img+') no-repeat center/cover #eeeeee;'"></view>
</view>
<!-- 单张图片 -->
<view v-if="item.pictureList.length == 1">
<image :src="item.pictureList[0]" class="single-pic"
@click.stop="showPic(item.pictureList[0])"></image>
<view v-if="item.pictureList.length == 1" class="single-pic" @click.stop="showPic(item.pictureList[0])"
:style="'background: url('+item.pictureList[0]+') no-repeat center/cover #eeeeee;'" >
</view>
</view>
</view>
......@@ -397,6 +395,7 @@
width: 100%;
border-radius: 5px;
height: 250px;
background-size: 100% 100%;
}
.post-pic {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册