<template> <view class="circle tn-safe-area-inset-bottom"> <!-- 发现 --> <view class="" v-if="current==0" > <uv-sticky bgColor="#ffffff"> <view style="width: 100%;" v-if="currentTab==0"> <view style="display: flex; padding: 10px 12px;"> <view style="flex:1;background-color: #f8f8f8;border-radius: 18px;color: #bbb;line-height: 35px;" @click="showSearch"> <view> <uni-icons type="search" color="#bbbbbb" :size="wxFontSize+1" style="margin: 8px;"></uni-icons> <text :style="{fontSize:(wxFontSize-2)+'px'}" v-if="!searchProdValue">产品名称/品牌/产品型号</text> <text :style="{fontSize:(wxFontSize-2)+'px'}" v-if="searchProdValue">{{searchProdValue}}</text> </view> </view> <view v-if="searchProdValue" @click="clearProd" style="line-height: 36px;margin-left: 10px;" :style="{fontSize:(wxFontSize-2)+'px'}">取消 </view> </view> </view> <view style="width: 100%;" v-if="currentTab==1"> <view style="display: flex; padding: 10px 12px;"> <view style="flex:1;background-color: #f8f8f8;border-radius: 18px;color: #bbb;line-height: 35px;" @click="showSearch2"> <view> <uni-icons type="search" color="#bbbbbb" :size="wxFontSize+1" style="margin: 8px;"></uni-icons> <text v-if="!searchProdValue2" :style="{fontSize:(wxFontSize-2)+'px'}">品牌/服务内容</text> <text v-if="searchProdValue2" :style="{fontSize:(wxFontSize-2)+'px'}">{{searchProdValue2}}</text> </view> </view> <view v-if="searchProdValue2" @click="clearProd2" style="line-height: 36px;margin-left: 10px;" :style="{fontSize:(wxFontSize-2)+'px'}">取消 </view> </view> </view> <!-- <uni-search-bar radius="15" placeholder="搜索" v-if="currentTab==1" @confirm="search" v-model="searchValue" @blur="search" @cancel="cancel" @clear="clear" cancelButton="auto" clearButton="auto"> </uni-search-bar> --> <tn-tabs-swiper :list="tabList" :isScroll="false" :fontSize="(wxFontSize+12)" :barWidth="wxFontSize+50" :current="currentTab" name="tab-name" @change="changeTab" style="border-bottom: 1rpx solid #f1f1f1cc;"> </tn-tabs-swiper> </uv-sticky> <view class="tn-flex tn-flex-direction-column tn-margin-top-sm "> <!-- 图文信息 --> <block v-for="(item,index) in content" :key="item.id"> <view class="blogger__item" :key="index"> <view class="blogger__author tn-flex tn-flex-row-between tn-flex-col-center"> <view class="justify__author__info" @click="tn('')"> <view class="tn-flex tn-flex-row-center"> <view class="tn-flex tn-flex-row-center tn-flex-col-center"> <!-- <view class=""> <tn-avatar class="" shape="circle" :src="item.userAvatar" size="lg"> </tn-avatar> </view> --> <view class="tn-padding-right"> <view class="tn-padding-right tn-color-grey tn-text-lg" :style="{fontSize:(wxFontSize)+'px'}"> {{ item.company||(item.contactNickName||item.contactPerson) }} </view> <!-- <view class="tn-padding-right tn-padding-left-sm tn-padding-top-xs tn-color-gray">{{ item.date }}</view> --> </view> </view> </view> </view> </view> <view class="blogger__desc tn-margin-top-sm tn-margin-bottom-sm tn-text-justify tn-flex-col-center tn-flex-row-left" > <!-- 不用限制长度了,因为发布的时候限制长度了--> <tn-tag margin="-4px 4px 0 0" backgroundColor="#3a96d733" v-if="item.brand" fontColor="#3a96d7" shape="circle" :fontSize="wxFontSize+11" @click="showBrand('品牌:'+item.brand)">{{ item.brand }}</tn-tag> <tn-tag margin="-4px 4px 0 0" backgroundColor="#3a96d733" v-if="!item.company" fontColor="#3a96d7" shape="circle" :fontSize="wxFontSize+11" @click="showBrand('个人发布')">个人</tn-tag> <text v-if="item.content" class="blogger__desc__content tn-flex-1 tn-text-justify tn-text-df" :style="{fontSize:(wxFontSize-2)+'px'}">{{ item.content }}</text> </view> <!-- 内容太多疲劳了--> <view v-if="item.shareExt&&item.shareExt.length>0" class="blogger__content" :id="`blogger__content--${index}`"> <basic-table header-row-class-name="basic-table-header" :columns="columns" :border="true" :fontSize="(wxFontSize-3)" :stripe="true" :data="item.shareExt"> <template #item="{column,scope,index}"> <view v-if="column.fieldName==='prodDesc'"> <tn-read-more openText="查看全部" :closeBtn="true" closeText="收起" :showHeight="125"> <text :style="{fontSize:(scope.fontSize-3)+'px'}">{{scope.prodDesc||''}}</text> </tn-read-more> </view> </template> </basic-table> </view> <block v-if="item.imgList"> <view v-if="[1,2,4].indexOf(item.imgList.length) != -1" class="tn-padding-top-xs" > <image v-for="(image_item,image_index) in item.imgList" :key="image_index" class="blogger__main-image" :class="{ 'blogger__main-image--1 tn-margin-bottom-sm': item.imgList.length === 1, 'blogger__main-image--2 tn-margin-right-sm tn-margin-bottom-sm': item.imgList.length === 2 || item.imgList.length === 4 }" :src="image_item.ftpUrl" mode="aspectFill" @click="showImg(item.imgList,image_index)"></image> </view> <view v-else class="tn-padding-top-xs" @click="tn('')"> <tn-grid hoverClass="none" :col="3"> <block v-for="(image_item,image_index) in item.imgList" :key="image_index"> <!-- #ifndef MP-WEIXIN --> <tn-grid-item style="width: 30%;margin: 10rpx;"> <image class="blogger__main-image blogger__main-image--3" :src="image_item.ftpUrl" mode="aspectFill" @click="showImg(item.imgList,image_index)"></image> </tn-grid-item> <!-- #endif--> <!-- #ifdef MP-WEIXIN --> <tn-grid-item style="width: 30%;margin: 10rpx;"> <image class="blogger__main-image blogger__main-image--3" :src="image_item.ftpUrl" mode="aspectFill" @click="showImg(item.imgList,image_index)"></image> </tn-grid-item> <!-- #endif--> </block> </tn-grid> </view> </block> <view v-for="file in item.fileDetailList" :key="file.id" v-if="!isImage(file.fileName)"> <view style="margin-top:10px"> <text class="tn-icon-link" :style="{fontSize:(wxFontSize-4)+'px'}"></text> <view style="display: inline;margin-left:8px;" @click="clickLink(file.ftpUrl,file.fileName)" :style="{fontSize:(wxFontSize-3)+'px'}"> {{file.fileName}}</view> </view> </view> <view class="tn-flex tn-flex-row-between tn-flex-col-center tn-margin-top-xs"> <view class="justify-content-item tn-color-gray tn-text-center"> <view class="tn-padding-right tn-padding-top-xs tn-color-gray" :style="{fontSize:(wxFontSize-3)+'px'}"> {{ item.createTime|formatDate }} </view> </view> <view class="justify-content-item tn-flex tn-flex-col-center" style="position: relative"> <text class="tn-icon-more-vertical tn-color-gray tn-text-bold tn-text-xxl" @click="showActionSheet(item)"></text> <view v-if="curItem.id==item.id&&showSheet" style="position: absolute; background: #ddd; display: block; right: 10px; top: 24px;border-radius: 16px;z-index: 900;border-top-right-radius: 0"> <text class="tn-icon-close" style="float: right;padding:8px;color:#333" @click="hideSheet()"></text> <view class="content" style="padding: 24px 36px;font-size: 16px;line-height: 24px; width: calc(100vw - 52px); border-radius: 16px; border-top-right-radius: 0;" v-if="!showContact"> <button @click="linkTel()" style="border-radius:30px;color:#fff;background-color: #1d60b1;"><text class="tn-icon-service" style="margin-right: 12px;"></text> 联系供方</button> <!-- <view>联系我们帮助对接</view> --> <button v-if="!collStatus" @click="addColl" style="margin-top:10px;border-radius:30px;" type="default" plain="true"><text class="tn-icon-star" style="margin-right: 12px;"></text> 收 藏</button> <button v-if="collStatus" @click="delColl" style="margin-top:10px;border-radius:30px;" type="default" plain="true"><text class="tn-icon-star-fill" style="margin-right: 12px;"></text> 取消收藏</button> <button open-type="share" style="margin-top:10px;border-radius:30px;" type="default" plain="true" :data-coupon="curItem"><text class="tn-icon-send" style="margin-right: 12px;"></text> 转 发</button> </view> <view class="content bg-content" style="padding: 50px 36px;padding-bottom: 32px;font-size: 16px;width: calc(100vw - 52px);line-height: 24px; border-radius: 16px;border-top-right-radius: 0;" v-if="showContact"> <view><text style="font-size: 20px;font-weight: bold;" v-if="curContact.company">{{curContact.company}}</text></view> <view style="margin-top:20px; font-weight: bold; font-size: 20px;"><text class="tn-icon-my-formal"></text><text style="margin-left: 6px;">{{curContact.contactPerson}}</text> </view> <view style="margin-top:20px;font-size: 20px;font-weight: bold;" @click="showTel(curContact.contactMethod)"><text class="tn-icon-tel"></text> <text style="margin-left: 4px;">{{curContact.contactMethod}}</text> </view> </view> </view> </view> </view> </view> <!-- 边距间隔 --> <view class="tn-strip-bottom" v-if="index != content.length - 1"></view> </block> <!-- 边距间隔 --> <!-- <view class="tn-strip-bottom"></view> --> <view v-if="showEmpty&&content.length==0" style="margin-top: 32vh;"> <tn-empty mode="list"></tn-empty> </view> <!-- 广告 --> <!-- 结尾 --> <view v-if="content.length==totalSize&&totalSize!=0&¤tTab==0" style="background-color: #f1f1f1cc;padding: 16px 0;" :style="{paddingTop:showSheet?'216px':'16px'}"> <tn-load-more status="nomore" :loadText="loadText" :fontSize="(wxFontSize+11)"></tn-load-more> </view> <view v-if="content.length==totalSize&&totalSize!=0&¤tTab==1" style="background-color: #f1f1f1cc;padding: 16px 0;" :style="{paddingTop:showSheet?'216px':'16px'}"> <tn-load-more status="nomore" :loadText="loadText2" :fontSize="(wxFontSize+11)"></tn-load-more> </view> </view> <view class='tn-tabbar-height' :style="{marginTop: vuex_custom_bar_height + 'px'}"></view> </view> <tn-popup v-model="showSheet2" mode="center" closeBtn="true" borderRadius="16"> <view class="content" style="padding: 24px 36px;font-size: 16px;line-height: 24px; width: 320px;" v-if="!showContact"> <button @click="linkTel()" style="border-radius:30px;color:#fff;background-color: #1d60b1;"><text class="tn-icon-service" style="margin-right: 12px;"></text> 联系供方</button> <!-- <view>联系我们帮助对接</view> --> <button v-if="!collStatus" @click="addColl" style="margin-top:10px;border-radius:30px;" type="default" plain="true"><text class="tn-icon-star" style="margin-right: 12px;"></text> 收 藏</button> <button v-if="collStatus" @click="delColl" style="margin-top:10px;border-radius:30px;" type="default" plain="true"><text class="tn-icon-star-fill" style="margin-right: 12px;"></text> 取消收藏</button> <button open-type="share" style="margin-top:10px;border-radius:30px;" type="default" plain="true" :data-coupon="curItem"><text class="tn-icon-send" style="margin-right: 12px;"></text> 转 发</button> </view> <view class="content bg-content" style="padding: 50px 36px;padding-bottom: 32px;font-size: 16px;width:320px;line-height: 24px;" v-if="showContact"> <view><text style="font-size: 20px;font-weight: bold;" v-if="curContact.company">{{curContact.company}}</text></view> <view style="margin-top:20px; font-weight: bold; font-size: 20px;"><text class="tn-icon-my-formal"></text><text style="margin-left: 6px;">{{curContact.contactPerson}}</text> </view> <view style="margin-top:20px;font-size: 20px;font-weight: bold;" @click="showTel(curContact.contactMethod)"><text class="tn-icon-tel"></text> <text style="margin-left: 4px;">{{curContact.contactMethod}}</text> </view> </view> </tn-popup> <tn-toast ref="toast"></tn-toast> </view> </template> <script> import request from '../../utils/request' export default { name: 'Circle', data() { return { loading: false, searchProdValue: '', searchProdValue2:'', tabList: [{ 'tab-name': '产品' }, { 'tab-name': '服务' }], loadText: { loadmore: '下拉加载', loading: '快速加载中...', nomore: '恭喜你,已阅读完所有供应信息哦!' }, loadText2: { loadmore: '下拉加载', loading: '快速加载中...', nomore: '恭喜你,已阅读完所有供应信息哦!' }, currentTab: 0, showEmpty: false, columns: [{ fieldName: 'prodName', fieldDesc: '产品名称', }, { fieldName: 'prodSpec', fieldDesc: '产品型号', }, { fieldName: 'prodDesc', fieldDesc: '产品介绍', fieldType:'slot' }], showSheet: false, curItem: {}, collId: '', showContact: false, curContact: {}, current: 0, collStatus: '', searchValue: '', content: [], totalSize: 0, curIndex: 1, wxFontSize:17 } }, onReady() { const appBaseInfo = wx.getAppBaseInfo(); this.wxFontSize = uni.getStorageSync('fontSize')||appBaseInfo.fontSizeSetting||17; this.$nextTick(() => { this.fetchData() }) }, onShow() { this.fetchData() }, onHide() { this.adAutoplay = false }, filters: { formatDate(value) { if (!value) return ''; const date = new Date(value); const today = new Date(); const yesterday = new Date(today); // 昨天的日期 yesterday.setDate(yesterday.getDate() - 1); // 将昨天的日期设置为前一天 if (date.getFullYear() == today.getFullYear() && date.getMonth() == today.getMonth() && date.getDate() == today.getDate()) { return '今天 ' + (date.getHours() > 9 ? '' : '0') + date.getHours() + ':' + (date .getMinutes() > 9 ? '' : '0') + date.getMinutes(); // 根据需要格式化日期 } if (date.getFullYear() == yesterday.getFullYear() && date.getMonth() == yesterday.getMonth() && date .getDate() == yesterday.getDate()) { return '昨天 ' + (date.getHours() > 9 ? '' : '0') + date.getHours() + ':' + (date .getMinutes() > 9 ? '' : '0') + date.getMinutes(); // 根据需要格式化日期 } return date.toLocaleDateString() + ' ' + (date.getHours() > 9 ? '' : '0') + date.getHours() + ':' + (date .getMinutes() > 9 ? '' : '0') + date.getMinutes(); // 根据需要格式化日期 }, }, methods: { showSearch(item) { // 或者可以直接设置body的tabindex属性为-1,然后移除焦点 // 注意:这种方式可能会导致一些浏览器的兼容性问题 uni.navigateTo({ url: '/pages/comm/search' }) }, showDetail(item){ uni.navigateTo({ url: '/pages/index/detail/detail?id='+item.bisNo+'&isNeed=0' }) }, showSearch2(item) { // 或者可以直接设置body的tabindex属性为-1,然后移除焦点 // 注意:这种方式可能会导致一些浏览器的兼容性问题 uni.navigateTo({ url: '/pages/comm/search2' }) }, isImage(fileName) { const imageExtensions = ['jpg', 'jpeg', 'png', 'gif', 'bmp', 'webp', 'ico'] const extension = fileName.split('.').pop().toLowerCase(); return imageExtensions.includes(extension); }, addButton() { if (!uni.getStorageSync('userNo')) { uni.showToast({ title: '请登录', icon:'none' }) uni.navigateTo({ url: '/pages/login/login' }) return false; } else { uni.navigateTo({ url: '/circlePages/addShare' }) } }, showImg(items, index) { let urls = []; for (let i = 0; i < items.length; i++) { urls.push(items[i].ftpUrl); } // wx.chooseMessageFile({ // count: 3, //默认100 // type:'file', // extension:['.pdf','.doc'], // success: function (res) { // console.error(JSON.stringify(res)); // } // }); // 预览图片 uni.previewImage({ urls: urls, current: index, }); }, clickLink(url,fileName) { // uni.navigateTo({ // url:'/pages/webview/web-view?url='+encodeURIComponent('https://slb-m.lx-device.com/webview?title='+fileName+'&url='+ url), // }) uni.downloadFile({ url: url, filePath: wx.env.USER_DATA_PATH + "/" + fileName, success: function (res) { const filePath = res.filePath uni.openDocument({ filePath: filePath, showMenu: true, success: function (res) { console.log('打开文档成功') }, fail: function(){ uni.navigateTo({ url:'/pages/webview/web-view?url='+encodeURIComponent('https://slb-m.lx-device.com/webview?title='+fileName+'&url='+ url), }) } }) } }) // uni.navigateTo({ // url: '/pages/webview/web-view?url=' + url, // }) }, // tab选项卡切换 tabChange(index) { this.current = index }, // 跳转 tn(e) { uni.navigateTo({ url: e, }); }, // 震动跳转 navEdit(e) { wx.vibrateLong(); uni.navigateTo({ url: '/circlePages/edit' }) }, // 震动跳转 navCreate(e) { wx.vibrateLong(); uni.navigateTo({ url: '/circlePages/create' }) }, // 震动跳转 navBuild(e) { wx.vibrateLong(); uni.navigateTo({ url: '/circlePages/build' }) }, reFetchData() { this.loading = true; uni.showToast({ title: '正在刷新...', icon: 'none' }); this.fetchData(); }, hideSheet(){ this.curItem = {}; this.showSheet = false; }, loadMore() { if (this.totalSize > this.content.length) { this.fetchData(this.curIndex + 1); } console.error('正在加载更多'); }, changeTab(index) { this.currentTab = index; this.content = []; this.fetchData(); }, // 获取内容容器的信息 fetchData(curIndex = 1) { let that = this; that.showEmpty = false; this.curIndex = curIndex; if (uni.getStorageSync('searchProdValue')) { that.searchProdValue = uni.getStorageSync('searchProdValue'); }else{ that.searchProdValue = '' } if (uni.getStorageSync('searchProdValue2')) { that.searchProdValue2 = uni.getStorageSync('searchProdValue2'); }else{ that.searchProdValue2 = '' } request.post('/slbResourceShare/query', { type: that.currentTab == 1 ? '2' : '1', index: curIndex, content: that.currentTab == 1 ? (that.searchProdValue2 ? that.searchProdValue2.split('/')[1]:'') : undefined, prodSpec: that.currentTab == 0 ? (that.searchProdValue ? that.searchProdValue.split('/')[2] : '') : undefined, prodName: that.currentTab == 0 ? (that.searchProdValue ? that.searchProdValue.split('/')[0] : '') : undefined, brand: that.currentTab == 0 ? (that.searchProdValue ? that.searchProdValue.split('/')[1] : '') : that.currentTab == 1 ?(that.searchProdValue2 ? that.searchProdValue2.split('/')[0]:''): undefined, }).then(res => { that.loading = false; if (res && res.success) { that.totalSize = res.total || 0; let newList = res.list || []; for (let i = 0; i < newList.length; i++) { newList[i].imgList = []; for (let j = 0; j < newList[i].fileDetailList.length; j++) { if (that.isImage(newList[i].fileDetailList[j].fileName)) { newList[i].imgList.push(newList[i].fileDetailList[j]); } } for(let k = 0;newList[i].shareExt&&k<newList[i].shareExt.length;k++){ newList[i].shareExt[k].fontSize= this.wxFontSize; } } if (curIndex == 1) { that.content = newList || []; } else { that.content = that.content.concat(newList || []); } } that.showEmpty = true; console.warn(res); }) }, showActionSheet(item) { let that = this; if(!this.curItem.id){ this.curItem = item; }else{ this.curItem = {} this.showSheet = false; return false; } this.collStatus = false; this.showSheet = true; that.showContact = false; if (uni.getStorageSync('userNo')) { let params = {}; params = { fkBisNo: that.curItem.bisNo, userNo: uni.getStorageSync('userNo'), }; request.post('/slbCollect/query', params).then(res => { if (res.success) { if (res.list && res.list.length > 0) { that.collStatus = true; that.collId = res.list[0].id; } } }) } }, linkTel() { if (!uni.getStorageSync('userNo')) { uni.showToast({ title: '请登录', icon:'none' }) uni.navigateTo({ url: '/pages/login/login' }) return false; } let that = this; let params = {}; params.slbBisContact = JSON.stringify({ fkBisNo: that.curItem.bisNo, bisType: '2', type: '1', company: that.curItem.company, companyNo: that.curItem.companyNo, userNo: uni.getStorageSync('userNo'), }); request.post('/slbBisContact/add', params).then(res => { if (res.success) { that.showContact = true; that.curContact.company = that.curItem.company; that.curContact.contactMethod = res.resultMap.contactMethod; that.curContact.contactPerson = res.resultMap.contactPerson; } else { that.showContact = false; uni.showToast({ title: res.msg, icon: 'none' }) } }) }, showBrand(text){ uni.showToast({ title: text, icon: 'none' }) }, addColl() { if (!uni.getStorageSync('userNo')) { uni.showToast({ title: '请登录', icon:'none' }) uni.navigateTo({ url: '/pages/login/login' }) return false; } let that = this; let params = {}; params.slbCollect = JSON.stringify({ fkBisNo: that.curItem.bisNo, bisType: '2', userNo: uni.getStorageSync('userNo'), }); request.post('/slbCollect/add', params).then(res => { if (res.success) { that.showSheet = false; that.curItem = {}; uni.showToast({ title: '信息已收藏,请在我的收藏里查看阅读', icon: 'none', duration: 2000 }) } else { uni.showToast({ title: res.msg, icon:'none' }) } }) }, delColl() { let that = this; request.post('/slbCollect/del', { id: that.collId }).then(res => { if (res.success) { that.showSheet = false; that.curItem = {}; uni.showToast({ title: '此供应信息将不会保存在我的收藏里', icon: 'none', duration: 2000 }) } else { uni.showToast({ title: res.msg, icon:'none' }) } }) }, search() { this.fetchData(); }, searchProd() { this.searchProdValue = ''; this.fetchData(); }, cancel() { this.searchValue = ''; this.fetchData(); }, clear() { this.searchValue = ''; this.fetchData(); }, clearProd() { this.searchProdValue = ''; uni.removeStorageSync('searchProdValue'); this.fetchData(); }, clearProd2() { this.searchProdValue2 = ''; uni.removeStorageSync('searchProdValue2'); this.fetchData(); }, showTel(tel){ uni.makePhoneCall({ phoneNumber: tel, }); }, } } </script> <style lang="scss" scoped> .circle { max-height: 100vh; } /* 底部安全边距 start*/ .tn-tabbar-height { min-height: 120rpx; height: calc(140rpx + env(safe-area-inset-bottom) / 2); height: calc(140rpx + constant(safe-area-inset-bottom)); } /* 自定义导航栏内容 start */ .custom-nav { height: 100%; &__back { margin: auto 5rpx; font-size: 40rpx; margin-right: 10rpx; margin-left: 30rpx; flex-basis: 5%; } &__search { flex-basis: 60%; width: 100%; height: 100%; &__box { width: 100%; height: 70%; padding: 10rpx 0; margin: 0 30rpx; border-radius: 60rpx 60rpx 0 60rpx; font-size: 24rpx; } &__icon { padding-right: 10rpx; margin-left: 20rpx; font-size: 30rpx; } &__text { color: #AAAAAA; } } } .logo-image { width: 60rpx; height: 60rpx; position: relative; margin-top: -15rpx; } .logo-pic { background-size: cover; background-repeat: no-repeat; // background-attachment:fixed; background-position: top; border-radius: 50%; } /* 自定义导航栏内容 end */ /* 博主头像 start*/ .image-circle { // padding: 95rpx; width: 190rpx; height: 190rpx; font-size: 40rpx; font-weight: 300; position: relative; } .image-pic { border: 1rpx solid #F8F7F8; background-size: cover; background-repeat: no-repeat; // background-attachment:fixed; background-position: top; border-radius: 10rpx; } .tn-color-cat { color: #1D2541; } .tn-bg-cat { background-color: #1D2541; } /* 文章内容 start*/ .blogger { &__item { padding: 30rpx; } &__author { &__btn { margin-right: -12rpx; opacity: 0.5; } } &__desc { line-height: 30rpx; &__label { color: #1D2541; background-color: #F3F2F7; border-radius: 10rpx; font-size: 22rpx; padding: 5rpx 15rpx; margin: 5rpx 18rpx 0 0; &--prefix { font-size: 24rpx; color: #1D2541; padding-right: 10rpx; } } &__content { line-height: 50rpx; } } &__content { margin-top: 18rpx; padding-right: 18rpx; &__data { line-height: 46rpx; text-align: justify; overflow: hidden; transition: all 0.25s ease-in-out; } &__status { margin-top: 10rpx; font-size: 26rpx; color: #82B2FF; } } &__main-image { border: 1rpx solid #F8F7F8; border-radius: 16rpx; &--1 { max-width: 80%; max-height: 300rpx; } &--2 { max-width: 260rpx; max-height: 260rpx; } &--3 { height: 212rpx; width: 100%; } } &__count-icon { font-size: 40rpx; padding-right: 5rpx; } &__ad { width: 100%; height: 500rpx; transform: translate3d(0px, 0px, 0px) !important; ::v-deep .uni-swiper-slide-frame { transform: translate3d(0px, 0px, 0px) !important; } .uni-swiper-slide-frame { transform: translate3d(0px, 0px, 0px) !important; } &__item { position: absolute; width: 100%; height: 100%; transform-origin: left center; transform: translate3d(100%, 0px, 0px) scale(1) !important; transition: transform 0.25s ease-in-out; z-index: 1; &--0 { transform: translate3d(0%, 0px, 0px) scale(1) !important; z-index: 4; } &--1 { transform: translate3d(13%, 0px, 0px) scale(0.9) !important; z-index: 3; } &--2 { transform: translate3d(26%, 0px, 0px) scale(0.8) !important; z-index: 2; } } &__content { border-radius: 40rpx; width: 640rpx; height: 500rpx; overflow: hidden; } &__image { width: 100%; height: 100%; } } } /* 文章内容 end*/ /* 间隔线 start*/ .tn-strip-bottom { width: 100%; border-bottom: 20rpx solid rgba(241, 241, 241, 0.8); } /* 间隔线 end*/ /* 广告内容 start */ .ad-image { width: 80rpx; height: 80rpx; position: relative; } .ad-pic { background-size: cover; background-repeat: no-repeat; // background-attachment:fixed; background-position: top; border-radius: 20%; } /* 自定义导航栏内容 end */ /* 全屏轮播 start*/ .card-swiper { height: 100vh !important; } .card-swiper swiper-item { width: 750rpx !important; left: 0rpx; box-sizing: border-box; overflow: initial; } .card-swiper swiper-item .swiper-item { width: 100%; display: block; height: 100vh; border-radius: 0rpx; transform: scale(1); transition: all 0.2s ease-in 0s; overflow: hidden; } .card-swiper swiper-item.cur .swiper-item { transform: none; transition: all 0.2s ease-in 0s; } .card-swiper swiper-item .swiper-item-png { margin-top: -50vh; width: 100%; display: block; border-radius: 0rpx; transform: translate(1040rpx, 20rpx) scale(0.5, 0.5); transition: all 0.6s ease 0s; // overflow: hidden; } .card-swiper swiper-item.cur .swiper-item-png { margin-top: -100vh; width: 900rpx; transform: translate(-80rpx, 0rpx) scale(1, 1); transition: all 0.6s ease 0s; } .image-banner { display: flex; align-items: center; justify-content: center; } .image-banner image { width: 100%; } /* 轮播指示点 start*/ .indication { z-index: 9999; width: 100%; height: 36rpx; position: fixed; // display:flex; display: block; flex-direction: row; align-items: center; justify-content: center; } .spot { background-color: #000; opacity: 0.3; width: 10rpx; height: 10rpx; border-radius: 20rpx; margin: 20rpx 0 !important; left: 95vw; top: -60vh; position: relative; } .spot.active { opacity: 0.6; height: 30rpx; background-color: #000; } /* 资讯主图 start*/ .image-article { border-radius: 8rpx; border: 1rpx solid #F8F7F8; width: 200rpx; height: 200rpx; position: relative; } .image-pic { background-size: cover; background-repeat: no-repeat; // background-attachment:fixed; background-position: top; border-radius: 10rpx; } .article-shadow { border-radius: 15rpx; box-shadow: 0rpx 0rpx 50rpx 0rpx rgba(0, 0, 0, 0.07); } /* 文字截取*/ .clamp-text-1 { -webkit-line-clamp: 1; display: -webkit-box; -webkit-box-orient: vertical; text-overflow: ellipsis; overflow: hidden; } .clamp-text-2 { -webkit-line-clamp: 2; display: -webkit-box; -webkit-box-orient: vertical; text-overflow: ellipsis; overflow: hidden; } /* 标签内容 start*/ .tn-tag-content { &__item { display: inline-block; line-height: 35rpx; color: #1D2541; background-color: #F3F2F7; border-radius: 10rpx; font-size: 22rpx; padding: 5rpx 15rpx; &--prefix { padding-right: 10rpx; } } } /* 图标容器9 start */ .icon9 { &__item { width: 30%; background-color: #FFFFFF; border-radius: 10rpx; padding: 30rpx; margin: 20rpx 10rpx; transform: scale(1); transition: transform 0.3s linear; transform-origin: center center; &--icon { width: 110rpx; height: 110rpx; font-size: 65rpx; border-radius: 50%; margin: 20rpx 40rpx; position: relative; z-index: 1; &::after { content: " "; position: absolute; z-index: -1; width: 100%; height: 100%; left: 0; bottom: 0; border-radius: inherit; opacity: 1; transform: scale(1, 1); background-size: 100% 100%; background-image: url(https://resource.tuniaokj.com/images/cool_bg_image/icon_bg5.png); } } } } /* 悬浮 */ .tnxuanfu { animation: suspension 3s ease-in-out infinite; } @keyframes suspension { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-0.8rem); } } /* 悬浮按钮 */ .button-shop { width: 90rpx; height: 90rpx; display: flex; flex-direction: row; position: fixed; /* bottom:200rpx; right: 20rpx; */ left: 5rpx; top: 5rpx; z-index: 1001; border-radius: 100px; opacity: 0.9; } /* 按钮 */ .edit { bottom: 300rpx; right: 75rpx; position: fixed; z-index: 9999; } .pa, .pa0 { position: absolute } .pa0 { left: 0; top: 0 } .bg0 { width: 100rpx; height: 100rpx; top: 50%; left: 50%; transform: translate(-50%, -50%); } .bg1 { width: 100%; height: 100%; } .hx-box { top: 50%; left: 50%; width: 100rpx; height: 100rpx; transform-style: preserve-3d; transform: translate(-50%, -50%) rotateY(75deg) rotateZ(10deg); } .hx-box .pr { width: 100rpx; height: 100rpx; transform-style: preserve-3d; animation: hxz 20s linear infinite; } @keyframes hxz { 0% { transform: rotateX(0deg); } 100% { transform: rotateX(-360deg); } } .hx-box .pr .pa0 { width: 100rpx; height: 100rpx; /* border: 4px solid #5ec0ff; */ border-radius: 1000px; } .hx-box .pr .pa0 .span { display: block; width: 100%; height: 100%; background: url(https://resource.tuniaokj.com/images/cool_bg_image/arc4.png) no-repeat center center; background-size: 100% 100%; animation: hx 4s linear infinite; } @keyframes hx { to { transform: rotate(360deg); } } .hx-k1 { transform: rotateX(-60deg) rotateZ(-60deg) } .hx-k2 { transform: rotateX(-30deg) rotateZ(-30deg) } .hx-k3 { transform: rotateX(0deg) rotateZ(0deg) } .hx-k4 { transform: rotateX(30deg) rotateZ(30deg) } .hx-k5 { transform: rotateX(60deg) rotateZ(60deg) } .hx-k6 { transform: rotateX(90deg) rotateZ(90deg) } /deep/ .basic-table-header { background-color: #edeeee; } .bg-content{ color: #fff; background-image: url(./../../static/bg.png); background-size: cover; } </style>