123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458 |
- <template>
- <view class="index tn-safe-area-inset-bottom">
-
- <view class="">
- <uv-sticky bgColor="#ffffff">
- <uni-search-bar radius="15" placeholder="搜索" @confirm="search" v-model="searchValue" @blur="search"
- @cancel="cancel" @clear="clear" cancelButton="auto" clearButton="auto" :fontSize="(wxFontSize-2)"
- style="border-bottom: 1rpx solid #f1f1f1cc;">
- </uni-search-bar></uv-sticky>
- <!-- 图文信息 -->
- <block v-for="(item,index) in content" :key="item.id" >
- <view class="blogger__item">
- <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 }}
- </view>
- </view>
- </view>
- </view>
- </view>
- <view v-if="item.validDate"
- class="blogger__author__btn justify-content-item tn-flex-col-center tn-flex-row-center">
- <text class="" style="background: #3F51B542;font-size: 12px;word-break: keep-all;
- padding: 8px;
- color: #0000FF;
- border-radius: 24px;
- border-top-right-radius: 0;" :style="{fontSize:(wxFontSize-6)+'px'}" @click="showValid(item.validDate)">{{item.validDate}}</text>
- </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"
- >
- <!-- <view v-for="(label_item,label_index) in item.label" :key="label_index"
- class="blogger__desc__label tn-float-left tn-margin-right">
- <text class="blogger__desc__label--prefix tn-icon-topics-fill"></text>
- <text class="tn-text-df">{{ label_item }}</text>
- </view> -->
- <!-- 不用限制长度了,因为发布的时候限制长度了-->
- <text
- class="blogger__desc__content tn-flex-1 tn-text-justify tn-text-df" :style="{fontSize:(wxFontSize-2)+'px'}">{{ item.content }}</text>
- </view>
- <block v-if="item.imgList">
- <view v-if="[1,2,4].indexOf(item.imgList.length) != -1" class="tn-padding-top-xs"
- @click="tn('')">
- <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">
- <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" style="margin-bottom: 4px;" :key="file.id" v-if="!isImage(file.fileName)">
- <view>
- <text class="tn-icon-link" :style="{fontSize:(wxFontSize-4)+'px'}"></text>
- <view style="display: inline;margin-left:8px" :style="{fontSize:(wxFontSize-3)+'px'}" @click="clickLink(file.ftpUrl,file.fileName)">
- {{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" class="pop-dia" 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);"
- 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 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" 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>
- <view class='tn-tabbar-height' :style="{marginTop: vuex_custom_bar_height + 'px'}"></view>
-
- <!-- <view v-if="curItem.id" style="position: fixed;background-color: red;width: 100vw;height: 100%;top:0"><view>1234</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: 'Index',
- data() {
- return {
- loading: false,
- loadText: {
- loadmore: '下拉加载',
- loading: '快速加载中...',
- nomore: '恭喜你,已阅读完所有需求信息哦!'
- },
- showContact: false,
- curContact: {},
- totalSize: 0,
- curIndex: 1,
- showSheet: false,
- curItem: {},
- userNo: '',
- searchValue: '',
- collStatus: '',
- cardCur: 0,
- collId: '',
- isAndroid: true,
- content: [],
- showEmpty:false,
- wxFontSize:17,
- }
- },
- 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(); // 根据需要格式化日期
- },
- },
- created() {
- const appBaseInfo = wx.getAppBaseInfo();
- this.wxFontSize = uni.getStorageSync('fontSize')||appBaseInfo.fontSizeSetting||17;
-
- // const accountInfo = uni.getAccountInfoSync();
- // if(accountInfo&&accountInfo.miniProgram.envVersion&&accountInfo.miniProgram.version){
- //正式上线版本
- this.fetchData();
- // }
-
- },
- methods: {
- 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,
- // })
- },
- isImage(fileName) {
- const imageExtensions = ['jpg', 'jpeg', 'png', 'gif', 'bmp', 'webp', 'ico']
- const extension = fileName.split('.').pop().toLowerCase();
- return imageExtensions.includes(extension);
- },
- reFetchData() {
- this.loading = true;
- uni.showToast({
- title: '正在刷新...',
- icon: 'none'
- });
- this.fetchData();
- },
- fetchData(curIndex = 1) {
- let that = this;
- that.showEmpty = false;
- this.curIndex = curIndex;
- request.post('/slbResourceDemand/query', {
- index: curIndex,
- limit: 10,
- content: that.searchValue,
- }).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]);
- }
- }
- }
- if (curIndex == 1) {
- that.content = newList || [];
- } else {
- that.content = that.content.concat(newList || []);
- }
-
- }
- that.showEmpty = true;
- })
- },
- // 跳转
- tn(e) {
- uni.navigateTo({
- url: e,
- });
- },
- hideSheet(){
- this.curItem = {}
- this.showSheet = false;
- },
- showActionSheet(item) {
- let that = this;
- if(!this.curItem.id){
- this.curItem = item;
- }else{
- this.curItem = {}
- this.showSheet = false;
- return false;
- }
-
- this.curItem.isNeed = 1;
- 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: '1',
- 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'
- })
- }
- })
- },
- 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: '1',
- userNo: uni.getStorageSync('userNo'),
- });
-
- request.post('/slbCollect/add', params).then(res => {
- if (res.success) {
-
- that.curItem = {}
- that.showSheet = false;
-
- 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.curItem = {}
- that.showSheet = false;
-
-
- wx.showToast({
- title: '此需求信息将不会保存在我的收藏里',
- icon:'none',
- duration: 2000
- });
-
- } else {
- uni.showToast({
- title: res.msg,
- icon:'none'
- })
- }
- })
- },
- showImg(items, index) {
- let urls = [];
- for (let i = 0; i < items.length; i++) {
- urls.push(items[i].ftpUrl);
- }
- // 预览图片
- uni.previewImage({
- urls: urls,
- current: index,
- });
- },
- showValid(text){
- uni.showToast({
- title: '有效期:'+text,
- icon: 'none'
- })
- },
- addButton() {
- if (!uni.getStorageSync('userNo')) {
- uni.showToast({
- title: '请登录',
- icon:'none'
- })
- uni.navigateTo({
- url: '/pages/login/login'
- })
- return false;
- } else {
- uni.navigateTo({
- url: '/circlePages/circle'
- })
- }
- //未登录,去登录
- //已登录,去新增第一步
- },
- loadMore() {
- if (this.totalSize > this.content.length) {
- this.fetchData(this.curIndex + 1);
- }
- console.error('正在加载更多');
- },
- search() {
- this.fetchData();
- },
- cancel() {
- this.searchValue = '';
- this.fetchData();
- },
- clear() {
- this.searchValue = '';
- this.fetchData();
- },
- showTel(tel){
- uni.makePhoneCall({
- phoneNumber: tel,
- });
- },
- showDetail(item){
- uni.navigateTo({
- url: '/pages/index/detail/detail?id='+item.bisNo+'&isNeed=1'
- })
- }
- }
- }
- </script>
- <style lang="scss" scoped>
- .index {
- 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 */
- .card-swiper {
- height: 330rpx !important;
- }
- .card-swiper swiper-item {
- width: 750rpx !important;
- left: 0rpx;
- box-sizing: border-box;
- padding: 40rpx 30rpx 30rpx 30rpx;
- overflow: initial;
- }
- .card-swiper swiper-item .swiper-item {
- width: 100%;
- display: block;
- height: 100%;
- border-radius: 15rpx;
- 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-text {
- margin-top: -160rpx;
- text-align: center;
- width: 100%;
- display: block;
- height: 50%;
- border-radius: 10rpx;
- transform: translate(100rpx, -60rpx) scale(0.9, 0.9);
- transition: all 0.6s ease 0s;
- overflow: hidden;
- }
- .card-swiper swiper-item.cur .swiper-item-text {
- margin-top: -220rpx;
- width: 100%;
- transform: translate(0rpx, 0rpx) scale(0.9, 0.9);
- transition: all 0.6s ease 0s;
- }
- .image-banner {
- border: 1rpx solid #F8F7F8;
- display: flex;
- align-items: center;
- justify-content: center;
- }
- .image-banner image {
- width: 100%;
- height: 100%;
- }
- /* 轮播指示点 start*/
- .indication {
- z-index: 9999;
- width: 100%;
- height: 36rpx;
- position: absolute;
- display: flex;
- flex-direction: row;
- align-items: center;
- justify-content: center;
- }
- .spot {
- background-color: #FFFFFF;
- opacity: 0.6;
- width: 10rpx;
- height: 10rpx;
- border-radius: 20rpx;
- top: -70rpx;
- margin: 0 8rpx !important;
- position: relative;
- }
- .spot.active {
- opacity: 1;
- width: 30rpx;
- background-color: #FFFFFF;
- }
- /* 图标容器12 start */
- .tn-three {
- position: absolute;
- top: 50%;
- right: 50%;
- bottom: 50%;
- left: 50%;
- transform: translate(-38rpx, -20rpx) rotateX(20deg) rotateY(10deg) rotateZ(-20deg);
- text-shadow: -1rpx 2rpx 0 #f0f0f0, -2rpx 4rpx 0 #f0f0f0, -10rpx 20rpx 30rpx rgba(0, 0, 0, 0.2);
- }
- .icon12 {
- &__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: 100rpx;
- height: 100rpx;
- font-size: 60rpx;
- border-radius: 50%;
- margin-bottom: 18rpx;
- 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_bg6.png);
- }
- }
- }
- }
- /* 自定义导航栏内容 start */
- .custom-nav {
- height: 100%;
- &__back {
- margin: auto 5rpx;
- font-size: 40rpx;
- margin-right: 10rpx;
- margin-left: 30rpx;
- flex-basis: 5%;
- }
- &__search {
- flex-basis: 70%;
- 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: 65rpx;
- height: 65rpx;
- position: relative;
- border: 1rpx solid #F8F7F8;
- border-radius: 50%;
- }
- .logo-pic {
- background-size: cover;
- background-repeat: no-repeat;
- // background-attachment:fixed;
- background-position: top;
- border-radius: 50%;
- }
- /* 自定义导航栏内容 end */
- /* 热门图片 start*/
- .image-tuniao1 {
- padding: 165rpx 0rpx;
- font-size: 40rpx;
- font-weight: 300;
- position: relative;
- }
- .image-tuniao2 {
- padding: 75rpx 0rpx;
- font-size: 40rpx;
- font-weight: 300;
- position: relative;
- }
- .image-tuniao3 {
- padding: 90rpx 0rpx;
- 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;
- }
- /* 文章内容 start*/
- .tn-blogger-content {
- &__wrap {
- margin: 30rpx;
- }
- &__info {
- &__btn {
- margin-right: -12rpx;
- opacity: 0.5;
- }
- }
- &__label {
- &__item {
- color: #1D2541;
- background-color: #F3F2F7;
- border-radius: 10rpx;
- font-size: 22rpx;
- padding: 5rpx 15rpx;
- margin: 5rpx 0 0 18rpx;
- &--prefix {
- font-size: 24rpx;
- color: #1D2541;
- padding-right: 10rpx;
- }
- }
- &__desc {
- line-height: 55rpx;
- }
- }
- &__main-image {
- border: 1rpx solid #F8F7F8;
- border-radius: 16rpx;
- &--1 {
- max-width: 690rpx;
- min-width: 690rpx;
- max-height: 400rpx;
- min-height: 400rpx;
- }
- &--2 {
- max-width: 260rpx;
- max-height: 260rpx;
- }
- &--3 {
- height: 212rpx;
- width: 100%;
- }
- }
- &__count-icon {
- font-size: 40rpx;
- padding-right: 5rpx;
- }
- }
- .image-wallpaper {
- padding: 160rpx 0rpx;
- font-size: 40rpx;
- font-weight: 300;
- position: relative;
- }
- .image-pic {
- background-size: cover;
- background-repeat: no-repeat;
- // background-attachment:fixed;
- background-position: top;
- border-radius: 10rpx;
- }
- /* 文章内容 end*/
- .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/ .tn-toast {
- background-color: #000c !important;
- }
-
- .bg-content{
- color: #fff;
- background-image: url(./../../static/bg.png);
- background-size: cover;
- }
- </style>
|