123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333 |
- <template>
- <view class="content">
- <view class="top-content">
- <view class="search-box">
- <view class="inner">
- <image src="../../static/images/icon_search.png" mode=""></image>
- <input type="text" placeholder="输入关键字搜索" placeholder-class="placeholder">
- </view>
- </view>
- <view class="tag-box">
- <scroll-view scroll-x="true" >
- <view class="tag-scroll">
- <view v-for="(item,index) in 2" :key="index" class="tag">体重管理</view>
- </view>
- </scroll-view>
- </view>
- </view>
- <!-- 数据列表 -->
- <view class="prom-list">
- <view class="item" v-for="(item,index) in 5" :key="index">
- <view class="info-box">
- <view class="info-text">
- <view class="title">维生素B2几块钱一百片,却能调理改善4类健康问题</view>
- <view class="time">2022-11-04</view>
- </view>
- <image class="img" src="../../static/images/detault_head.jpg" mode="aspectFill"></image>
- </view>
- <view class="hand-box">
- <view class="left">
- <view class="head-box">
- <view v-for="(img,j) in 3" :key="j" class="head-item">
- <image class="img" src="../../static/images/detault_head.jpg" mode="aspectFill"></image>
- </view>
- </view>
- <view class="hand-item">
- <image class="eyes" src="../../static/images/icon_eyes.png" mode=""></image>
- <text class="text">218</text>
- </view>
- <view class="hand-item">
- <image class="share" src="../../static/images/icon_share_gray.png" mode=""></image>
- <text class="text">16</text>
- </view>
- </view>
- <view class="share-btn" @click="handShare">立即分享</view>
- </view>
- </view>
- </view>
- <!-- 分享弹窗 -->
- <uni-popup ref="sharePopup" type="bottom" :mask-click="false">
- <view class="share-content">
- <view class="share-inner">
- <view class="share-item">
- <image src="../../static/images/icon_wx.png" mode=""></image>
- <text class="text">微信</text>
- </view>
- <view class="share-item">
- <image src="../../static/images/icon_pyq.png" mode=""></image>
- <text class="text">朋友圈</text>
- </view>
- <view class="share-item">
- <image src="../../static/images/icon_xcxhb.png" mode=""></image>
- <text class="text">小程序海报</text>
- </view>
- <view class="share-item">
- <image src="../../static/images/icon_xccard.png" mode=""></image>
- <text class="text">小程序卡片</text>
- </view>
- <view class="share-item">
- <image src="../../static/images/icon_code.png" mode=""></image>
- <text class="text">二维码</text>
- </view>
- <view class="share-item">
- <image src="../../static/images/icon_copy_link.png" mode=""></image>
- <text class="text">复制链接</text>
- </view>
- </view>
- <view class="cancel-btn" @click="cancelShare">取消</view>
- </view>
- </uni-popup>
- </view>
- </template>
- <script>
- export default {
- data() {
- return {
-
- }
- },
- methods: {
- // 分享
- handShare() {
- this.$refs.sharePopup.open('bottom')
- },
- // 取消分享
- cancelShare() {
- this.$refs.sharePopup.close()
- }
- }
- }
- </script>
- <style lang="scss">
- page{
- background-color: #F7F7F7;
- }
- </style>
- <style scoped lang="scss">
-
- .top-content{
- width: 100%;
- position: fixed;
- top: 0;
- left: 0;
- z-index: 11;
- background: #FFFFFF;
- .search-box{
- height: 104upx;
- padding: 0 30upx;
- display: flex;
- align-items: center;
- .inner{
- box-sizing: border-box;
- width: 100%;
- height: 72upx;
- background: #F7F7F7;
- border-radius: 36upx;
- display: flex;
- align-items: center;
- padding: 0 30upx;
- image{
- width: 28upx;
- height: 28upx;
- margin-right: 20upx;
- }
- input{
- font-size: 28upx;
- font-family: PingFang SC;
- font-weight: 500;
- flex: 1;
- }
- .placeholder{
- font-size: 28upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #BBBBBB;
- }
- }
- }
- .tag-box{
- height: 106upx;
- padding: 0 30upx;
- .tag-scroll{
- height: 106upx;
- display: flex;
- align-items: center;
- .tag{
- flex-shrink: 0;
- height: 58upx;
- line-height: 56upx;
- padding: 0 24upx;
- background: #F5FFFE;
- border: 2upx solid #8AD5CE;
- border-radius: 14upx;
- font-size: 28upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #FF5C03;
- margin-right: 20upx;
- &:last-child{
- margin-right: 0;
- }
- }
- }
- }
- }
- .prom-list{
- padding: 230upx 20upx 20upx;
- .item{
- background: #FFFFFF;
- border-radius: 16upx;
- margin-bottom: 20upx;
- padding: 40upx 30upx;
- &:last-child{
- margin-bottom: 0;
- }
- .info-box{
- display: flex;
- align-items: center;
- justify-content: space-between;
- .info-text{
- width: calc(100% - 254upx);
- height: 170upx;
- display: flex;
- flex-direction: column;
- justify-content: space-between;
- .title{
- font-size: 32upx;
- font-family: PingFang SC;
- font-weight: bold;
- color: #111111;
- line-height: 50upx;
- overflow: hidden;
- text-overflow: ellipsis;
- display: -webkit-box;
- -webkit-line-clamp: 2;
- -webkit-box-orient: vertical;
- }
- .time{
- font-size: 24upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #999999;
- line-height: 1;
- }
- }
- .img{
- width: 224upx;
- height: 171upx;
- background: #E0E0E0;
- border-radius: 16upx;
- overflow: hidden;
- }
- }
- .hand-box{
- margin-top: 50upx;
- display: flex;
- align-items: center;
- justify-content: space-between;
- .left{
- display: flex;
- align-items: center;
- .head-box{
- display: flex;
- margin-right: 26upx;
- .head-item{
- width: 48upx;
- height: 48upx;
- background: #F6F7FB;
- border: 2upx solid #FFFFFF;
- border-radius: 50%;
- overflow: hidden;
- margin-left: -10upx;
- &:first-child{
- margin-left: 0;
- }
- .img{
- width: 100%;
- height: 100%;
- }
- }
- }
- .hand-item{
- display: flex;
- align-items: center;
- margin-right: 40upx;
- &:last-child{
- margin-right: 0;
- }
- .eyes{
- width: 27upx;
- height: 22upx;
- margin-right: 18upx;
- }
- .share{
- width: 24upx;
- height: 24upx;
- margin-right: 12upx;
- }
- .text{
- font-size: 24upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #999999;
- line-height: 1;
- }
- }
- }
- .share-btn{
- padding: 0 25upx;
- height: 60upx;
- line-height: 60upx;
- background: #FF5C03;
- border-radius: 12upx;
- font-size: 26upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #FFFFFF;
- }
- }
- }
- }
- .share-content{
- background-color: #F2F5F4;
- border-radius: 40upx 40upx 0px 0px;
- .share-inner{
- padding: 70upx 0 0 0;
- display: flex;
- flex-wrap: wrap;
- .share-item{
- width: 25%;
- display: flex;
- flex-direction: column;
- align-items: center;
- justify-content: center;
- margin-bottom: 66upx;
- image{
- width: 80upx;
- height: 80upx;
- margin-bottom: 20upx;
- }
- .text{
- font-size: 28upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #111111;
- line-height: 1;
- }
- }
- }
- .cancel-btn{
- height: 96upx;
- line-height: 96upx;
- text-align: center;
- font-size: 32upx;
- font-family: PingFang SC;
- font-weight: 500;
- color: #111111;
- border-top: 2upx solid #E8E8E8;
- background: #F2F5F4;
- }
- }
- </style>
|