微信小程序个人中心列表控件如何编写实现代码?
- 内容介绍
- 文章标签
- 相关推荐
本文共计321个文字,预计阅读时间需要2分钟。
个人中心列表控件 + 首先来看效果图 + wxml + view class=list-item + image class=item-image src=.images/fuwu.png / + image + text class=item-text 我的收藏 / text + image class=image-jiantou src=.images/jiantou.png / + /view +
个人中心的列表控件
首先来看效果图
wxml
<view class="list-item"> <image class="item-image" src="../images/fuwu.png"></image> <text class="item-text">我的收藏</text> <image class="image-jiantou" src="../images/jiantou.png"></image> </view> <view class="line"></view>
wxss
.list-item { display: flex; flex-direction: row; align-items: center; width: 100%; height: 80rpx; margin-top: 10rpx; position: relative; /*父元素位置要设置为相对*/ } .item-image { width: 50rpx; height: 50rpx; margin: 20rpx; } .item-text { color: gray; font-size: 35rpx; margin-left: 20rpx; } .image-jiantou { width: 20rpx; height: 35rpx; position: absolute; /* 要约束所在位置的子元素的位置要设置成绝对 */ right: 0; /* 靠右调节 */ margin-right: 35rpx } .line { width: 100%; height: 3rpx; background: lightgray; margin-left: 90rpx; }
到此这篇关于微信小程序个人中心的列表控件实现代码的文章就介绍到这了,更多相关微信小程序个人中心内容请搜索易盾网络以前的文章或继续浏览下面的相关文章希望大家以后多多支持易盾网络!
本文共计321个文字,预计阅读时间需要2分钟。
个人中心列表控件 + 首先来看效果图 + wxml + view class=list-item + image class=item-image src=.images/fuwu.png / + image + text class=item-text 我的收藏 / text + image class=image-jiantou src=.images/jiantou.png / + /view +
个人中心的列表控件
首先来看效果图
wxml
<view class="list-item"> <image class="item-image" src="../images/fuwu.png"></image> <text class="item-text">我的收藏</text> <image class="image-jiantou" src="../images/jiantou.png"></image> </view> <view class="line"></view>
wxss
.list-item { display: flex; flex-direction: row; align-items: center; width: 100%; height: 80rpx; margin-top: 10rpx; position: relative; /*父元素位置要设置为相对*/ } .item-image { width: 50rpx; height: 50rpx; margin: 20rpx; } .item-text { color: gray; font-size: 35rpx; margin-left: 20rpx; } .image-jiantou { width: 20rpx; height: 35rpx; position: absolute; /* 要约束所在位置的子元素的位置要设置成绝对 */ right: 0; /* 靠右调节 */ margin-right: 35rpx } .line { width: 100%; height: 3rpx; background: lightgray; margin-left: 90rpx; }
到此这篇关于微信小程序个人中心的列表控件实现代码的文章就介绍到这了,更多相关微信小程序个人中心内容请搜索易盾网络以前的文章或继续浏览下面的相关文章希望大家以后多多支持易盾网络!

