tree.vue 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782
  1. <template>
  2. <view class="page-container">
  3. <view class="base-container">
  4. <member-level :treeData="treeData">
  5. <view class="toogle" @click="handleShow">切换 {{name}}<up-icon class="icon" name="arrow-down" color="#fff"
  6. size="12"></up-icon></view>
  7. </member-level>
  8. <view class="tree-cont">
  9. <!-- 弹幕组件 -->
  10. <view class="danmaku-wrapper">
  11. <danmakuManager
  12. ref="danmakuRef"
  13. :danmakuList="danmakuList"
  14. :height="100"
  15. :infinite="true"
  16. :speed="80"
  17. @danmakuComplete="onDanmakuComplete"
  18. ></danmakuManager>
  19. </view>
  20. <view class="dialogue-tips">
  21. <view class="tips-name">
  22. <image class="tip-img" :src="`${config.BASIC_IMG}img/treePage/sun-icon.png`"></image>
  23. <text>亲爱的主人!</text>
  24. </view>
  25. <view class="tips-cont">今天是我开花的日子,我很开心!</view>
  26. </view>
  27. <view class="tree-name">
  28. <view>{{treeName}}</view>
  29. <image v-if="userInfo.tel" @click="handleEditName" class="edit-icon" :src="`${config.BASIC_IMG}img/edit-icon.png`">
  30. </image>
  31. </view>
  32. <image class="drone-icon" :src="`${config.BASIC_IMG}img/treePage/drone-icon.png`"></image>
  33. <view class="tool-wrap">
  34. <view class="tool-left">
  35. <view :class="['tool-item',item.className]" v-for="(item,index) in toolLeftList" :key="index"
  36. @click="handleToolItem(item)">
  37. <image class="icon" :src="`${config.BASIC_IMG}img/treePage/l-tree-icon-${index+1}.png`">
  38. </image>
  39. <view class="name">{{item.name}}</view>
  40. </view>
  41. </view>
  42. <view class="tool-right">
  43. <view :class="['tool-item',item.className]" v-for="(item,index) in toolRightList" :key="index"
  44. @click="handleToolItem(item)">
  45. <image class="icon" :src="`${config.BASIC_IMG}img/treePage/r-tree-icon-${index+1}.png`">
  46. </image>
  47. <view class="name">{{item.name}}</view>
  48. </view>
  49. </view>
  50. </view>
  51. </view>
  52. <view class="tree-footer">
  53. <template v-if="userInfo.tel">
  54. <view class="footer-item" v-for="(item,index) in footerList" :key="index" @click="handleItem(index)">
  55. <view @click="requestSubscribe">
  56. <button class="share-btn" open-type="share" v-if="index === 2">
  57. <image class="icon" :src="`${config.BASIC_IMG}img/treePage/b-tree-icon-${index+1}.png`">
  58. </image>
  59. </button>
  60. <image v-else class="icon" :class="{small:index === 0}" :src="`${config.BASIC_IMG}img/treePage/b-tree-icon-${index+1}.png`">
  61. </image>
  62. <view class="name">{{item}}</view>
  63. </view>
  64. </view>
  65. </template>
  66. <view v-else class="button" @click="handlePage">开启我的守护</view>
  67. </view>
  68. </view>
  69. <!-- 引导弹窗 -->
  70. <view class="guide-bg" v-if="showMask" @click="handleClose">
  71. <image class="guide-icon" :src="`${config.BASIC_IMG}img/treePage/guide-1.png`"></image>
  72. </view>
  73. <!-- 切换 -->
  74. <up-picker :show="showPicker" :columns="columns" :defaultIndex="[0]" @cancel="handleCancel"
  75. @confirm="handleConfirm" keyName="name" valueName="speciesId"></up-picker>
  76. <!-- 签到打卡 -->
  77. <checkinPopup v-if="showCheckin" @closedCheckPopup="closedCheckPopup"></checkinPopup>
  78. <!-- 编辑树名称 -->
  79. <editNamePopup ref="editNameRef" @editEnd="getBySampleId"></editNamePopup>
  80. <!-- 海报弹窗 -->
  81. <posterPopup
  82. :showPoster="showPoster"
  83. :farmBuyId="farmBuyId"
  84. :treeName="treeName"
  85. :sampleId="sampleId"
  86. @download-poster="handleDownloadPoster"
  87. ></posterPopup>
  88. <!-- 果树成功弹窗 -->
  89. <guardSuccessPopup :show="showGuardSuccess" :treeData="treeData" @closedGuardSuccessPopup="featchIsLookedGuide"></guardSuccessPopup>
  90. <!-- 果树相册弹窗 -->
  91. <tree-album-popup :show="showAlbum" :farmBuyId="farmBuyId" :sampleId="sampleId"></tree-album-popup>
  92. <!-- 等级升级成功弹窗 -->
  93. <levelSuccessPopup :show="showUpgradePopup" @closeLevel="closeLevel"></levelSuccessPopup>
  94. <!-- 祝福弹窗 -->
  95. <blessingsPopup :show="showBlessingsPopup" :showSuccess="showSuccess" :farmBuyId="farmBuyId"
  96. :clockinType="clockinType" @clockinCallback="getBySampleId" @closeBlessings="closeBlessings"></blessingsPopup>
  97. <!-- canvas生成图片 - 隐藏的canvas元素 -->
  98. <canvas id="posterCanvas" canvas-id="posterCanvas" style="width: 1380rpx;height: 2280rpx;position: fixed;left: 750rpx;top: 2000rpx;z-index: 9999;"></canvas>
  99. </view>
  100. </template>
  101. <script setup>
  102. import config from "@/api/config.js"
  103. import {
  104. onLoad,
  105. onShareAppMessage,
  106. onShow,
  107. onHide,
  108. onUnload
  109. } from '@dcloudio/uni-app'
  110. import memberLevel from "./components/memberLevel.vue"
  111. import treeAlbumPopup from "./components/treeAlbumPopup.vue"
  112. import blessingsPopup from "./components/blessingsPopup.vue"
  113. import checkinPopup from "@/components/checkinPopup/checkinPopup.vue"
  114. import editNamePopup from "@/components/editNamePopup/editNamePopup.vue"
  115. import guardSuccessPopup from "@/components/guardSuccessPopup/guardSuccessPopup.vue"
  116. import levelSuccessPopup from "@/components/levelSuccessPopup/levelSuccessPopup.vue"
  117. import danmakuManager from "@/components/danmakuManager/danmakuManager.vue"
  118. import posterPopup from "@/components/posterPopup/posterPopup.vue"
  119. import TREE from '@/api/tree.js'
  120. import USER from '@/api/user.js'
  121. import { CanvasUtils } from '@/utils/canvasUtils.js'
  122. import {
  123. onMounted,
  124. ref
  125. } from 'vue';
  126. const name = ref('荔枝')
  127. const showPicker = ref(false)
  128. const columns = ref([[{name:'荔枝',speciesId:'1'}]]);
  129. const speciesId = ref('')
  130. const handleShow = () => {
  131. showPicker.value = true
  132. }
  133. const handleCancel = () => {
  134. showPicker.value = false
  135. }
  136. const handleConfirm = (e) => {
  137. name.value = e.value[0].name
  138. speciesId.value = e.value[0].speciesId
  139. handleCancel()
  140. }
  141. const toolLeftList = [{
  142. name: "相册",
  143. clickName: 'album'
  144. },
  145. {
  146. name: "日记",
  147. path: 'diary'
  148. },
  149. {
  150. name: "海报",
  151. className: 'blue',
  152. clickName: 'poster'
  153. },
  154. {
  155. name: "礼物",
  156. className: 'gift',
  157. path: 'gift'
  158. }
  159. ]
  160. const toolRightList = [{
  161. name: "好友",
  162. className: 'friend',
  163. path: 'rank'
  164. },
  165. {
  166. name: "认养",
  167. },
  168. {
  169. name: "果园",
  170. },
  171. {
  172. name: "动态",
  173. className: 'dynamic',
  174. path: 'dynamic',
  175. params: 'farmBuyId'
  176. }
  177. ]
  178. const showGuardSuccess = ref(false)
  179. const showCheckin = ref(false)
  180. const editNameRef = ref(null)
  181. const formatDate = (dateStr) => {
  182. return dateStr.split(" ")[0].replace(/-/g, ".");
  183. };
  184. const handleEditName = () => {
  185. editNameRef.value.showPopup({
  186. id: farmBuyId.value,
  187. treeName: treeName.value,
  188. nickname: treeData.value.buyList[0].nickname,
  189. showName: treeData.value.buyList[0].showName,
  190. createDate: formatDate(treeData.value.buyList[0].createDate),
  191. })
  192. }
  193. const userInfo = ref({})
  194. // onLoad(() => {
  195. // featchCategoryList()
  196. // })
  197. onShow(async ()=>{
  198. userInfo.value = uni.getStorageSync('userInfo')
  199. await featchLightTree(() => {
  200. handleUpgrade()
  201. })
  202. featchSessionStore()
  203. })
  204. onHide(() => {
  205. // 页面隐藏时停止弹幕
  206. stopDanmaku()
  207. })
  208. onUnload(() => {
  209. // 页面卸载时停止弹幕
  210. stopDanmaku()
  211. })
  212. onMounted(() => {
  213. featchIsLookedGuide()
  214. })
  215. async function handleUpgrade() {
  216. // 是否有200积分弹窗
  217. await TREE.fetchLevelAwardInfo({buyId: farmBuyId.value}).then(({data}) => {
  218. if (data?.hasAward) {
  219. clockinType.value = 4
  220. levelAwardId.value = data?.levelAward?.id
  221. showSuccess.value = !showSuccess.value
  222. } else {
  223. showCheckin.value = true
  224. }
  225. })
  226. }
  227. //品类查询所有
  228. const featchCategoryList = () =>{
  229. TREE.categoryList().then(({
  230. data
  231. }) => {
  232. columns.value[0] = data || []
  233. speciesId.value = data[0].speciesId
  234. featchLightTree()
  235. })
  236. }
  237. const showMask = ref(false)
  238. const featchIsLookedGuide = () => {
  239. USER.isLookedGuide({
  240. type: 1
  241. }).then(({
  242. data
  243. }) => {
  244. if (data == false) {
  245. showMask.value = true
  246. }
  247. })
  248. }
  249. const handleClose = async () =>{
  250. const {code} = await USER.lookedGuide({type:1})
  251. if(code === 0){
  252. showMask.value = false
  253. }
  254. }
  255. const featchSessionStore = () => {
  256. USER.getSessionStore({
  257. key: 'successTree',
  258. miniUserId: userInfo.value.id
  259. }).then((({data}) => {
  260. if(data?.text === 'orderSuccess'){
  261. // clockinType.value = 4
  262. // showSuccess.value = !showSuccess.value
  263. // treeSetSessionStore()
  264. }else{
  265. if (data?.val == 0) {
  266. showGuardSuccess.value = !showGuardSuccess.value
  267. treeSetSessionStore()
  268. }else{
  269. featchIsLookedGuide()
  270. }
  271. }
  272. }))
  273. }
  274. const treeSetSessionStore = () =>{
  275. USER.setSessionStore({
  276. key: 'successTree',
  277. miniUserId: userInfo.value.id,
  278. val:1,
  279. text:'1'
  280. })
  281. }
  282. const levelAwardId = ref('1')
  283. // 得到200分弹窗关闭
  284. function closeBlessings() {
  285. // 设为已读
  286. TREE.fetchUserAsRead({type: 3, buyId: farmBuyId.value})
  287. TREE.fetchClaimAward({buyId: farmBuyId.value, levelAwardId: levelAwardId.value}).then(({data}) => {
  288. showUpgradePopup.value = true
  289. })
  290. }
  291. // 升级弹窗关闭方法
  292. function closeLevel() {
  293. showCheckin.value = true
  294. }
  295. const closedCheckPopup = () =>{
  296. showPoster.value = !showPoster.value
  297. }
  298. const sampleId = ref('')
  299. //通过品类查询当前树
  300. const featchLightTree = (callback) =>{
  301. TREE.getLightTreeList().then((res =>{
  302. sampleId.value = res.data[0].sampleId
  303. getBySampleId(callback)
  304. }))
  305. }
  306. const treeData = ref({})
  307. const farmBuyId = ref('')
  308. const treeName = ref('')
  309. const getBySampleId = (callback) => {
  310. TREE.getBySampleId({
  311. sampleId: sampleId.value
  312. }).then(({
  313. data
  314. }) => {
  315. treeData.value = data || {}
  316. if (userInfo.value.tel) {
  317. treeName.value = data.buyList[0].treeName || (data.buyList[0].nickname.length ? data.buyList[0]
  318. .nickname.slice(0, 3) + "荔" : data.buyList[0].owner.slice(0, 3) + "荔")
  319. } else {
  320. treeName.value = '飞鸟守护'
  321. }
  322. farmBuyId.value = data.buyList[0].id
  323. callback && callback()
  324. featchSessionStore()
  325. // 获取能量记录
  326. featchEnergyRecords()
  327. })
  328. }
  329. const handlePage = () =>{
  330. uni.navigateTo({
  331. url: `/pages/login/index`
  332. });
  333. }
  334. const showPoster = ref(false)
  335. const showAlbum = ref(false)
  336. const handleToolItem = ({
  337. path,
  338. clickName,
  339. params
  340. }) => {
  341. if (clickName === 'album') {
  342. showAlbum.value = !showAlbum.value
  343. } else if (clickName === 'poster') {
  344. showPoster.value = !showPoster.value
  345. } else {
  346. uni.navigateTo({
  347. url: `/pages/tabBar/tree/subPages/${path}?farmBuyId=${farmBuyId.value}&sampleId=${sampleId.value}`
  348. });
  349. }
  350. }
  351. const footerList = ["每日阳光", "送ta祝福", "分享转发", "水果订购"]
  352. const showBlessingsPopup = ref(false)
  353. const showSuccess = ref(false)
  354. const showUpgradePopup = ref(false)
  355. const clockinType = ref('1')
  356. // 弹幕相关数据
  357. const danmakuList = ref([])
  358. const featchEnergyRecords = () => {
  359. TREE.getEnergyRecords({
  360. page: 1,
  361. limit: 9999,
  362. onlyOther:1,
  363. farmBuyId: farmBuyId.value
  364. }).then(({
  365. data
  366. }) => {
  367. // 将接口返回的数据转换为弹幕组件期望的格式
  368. const formattedData = (data || []).map(item => ({
  369. msg: item.desc || item.text || item.content || '守护果树,收获美好', // 使用desc字段作为消息内容
  370. icon: item.icon || `${config.BASIC_IMG}img/treePage/drone-icon.png` // 使用icon字段作为头像
  371. }))
  372. danmakuList.value = formattedData
  373. if(formattedData.length > 0){
  374. // 页面显示时启动弹幕
  375. setTimeout(() => {
  376. startDanmaku()
  377. }, 1000)
  378. }
  379. }).catch(error => {
  380. console.error('获取能量记录失败:', error)
  381. })
  382. }
  383. // 弹幕组件引用
  384. const danmakuRef = ref(null)
  385. // 弹幕完成回调
  386. const onDanmakuComplete = (id) => {
  387. // 弹幕播放完成处理
  388. }
  389. // 启动弹幕
  390. const startDanmaku = () => {
  391. if (danmakuRef.value) {
  392. danmakuRef.value.startDanmakuAnimation()
  393. }
  394. }
  395. // 停止弹幕
  396. const stopDanmaku = () => {
  397. if (danmakuRef.value) {
  398. danmakuRef.value.stopDanmakuAnimation()
  399. }
  400. }
  401. // 创建canvas工具类实例
  402. const canvasUtils = new CanvasUtils('posterCanvas')
  403. // 处理海报下载
  404. const handleDownloadPoster = async (data) => {
  405. // 检查数据完整性
  406. if (!data || !data.treeObj) {
  407. uni.showToast({
  408. title: '数据不完整,无法生成海报',
  409. icon: 'none'
  410. });
  411. return;
  412. }
  413. try {
  414. uni.showLoading({
  415. title: '正在生成海报...',
  416. mask: true
  417. });
  418. const success = await canvasUtils.generateAndSave(data);
  419. uni.hideLoading();
  420. } catch (error) {
  421. uni.hideLoading();
  422. console.error('海报处理出错:', error);
  423. uni.showToast({
  424. title: '海报生成失败: ' + error.message,
  425. icon: 'none'
  426. });
  427. }
  428. }
  429. const handleItem = (index) => {
  430. if (index === 0) {
  431. clockinType.value = 1
  432. if (treeData.value.buyList[0].level.clockinMap['1']) {
  433. uni.showToast({
  434. title: '今日已守护',
  435. icon: 'none',
  436. duration: 2000
  437. });
  438. } else {
  439. showSuccess.value = !showSuccess.value
  440. }
  441. } else if (index === 1) {
  442. clockinType.value = 3
  443. if (treeData.value.buyList[0].level.clockinMap['3']) {
  444. uni.showToast({
  445. title: '今日已送过祝福',
  446. icon: 'none',
  447. duration: 2000
  448. });
  449. } else {
  450. showBlessingsPopup.value = !showBlessingsPopup.value
  451. }
  452. } else if (index === 2) {
  453. clockinType.value = 2
  454. if (!treeData.value.buyList[0].level.clockinMap['2']) {
  455. showSuccess.value = !showSuccess.value
  456. }
  457. } else {
  458. uni.navigateTo({
  459. url: `/pages/tabBar/home/subPages/gardenItem`
  460. });
  461. }
  462. }
  463. function requestSubscribe() {
  464. // #ifdef MP-WEIXIN
  465. //订阅模板
  466. TREE.getSubscribeTemplate({
  467. id: 1
  468. }).then(({
  469. data
  470. }) => {
  471. uni.requestSubscribeMessage({
  472. tmplIds: [data.templateId], // 模板ID
  473. success(res) {
  474. if (res[data.templateId] === 'accept') {
  475. TREE.addSubscribe({
  476. templateId: 1
  477. })
  478. } else if (res[data.templateId] === 'reject') {
  479. console.log('用户拒绝订阅模板');
  480. }
  481. },
  482. fail(err) {
  483. uni.openSetting({
  484. withSubscriptions: true, // 显示订阅消息开关
  485. });
  486. },
  487. });
  488. })
  489. // #endif
  490. }
  491. onShareAppMessage((res) => {
  492. return {
  493. title: '我分享了我的果树,快来查看吧~',
  494. path: `/pages/tabBar/tree/subPages/friendTree?sampleId=${sampleId.value}`, // 分享的小程序页面路径
  495. imageUrl: `http://birdseye-api.feiniaotech.sysuimars.cn/mini/z_farm_buy/genImage/${farmBuyId.value}?key=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9&x1=25&y1=220&fontSize1=40&x2=55&y2=250&fontSize2=16&timestamp=${Date.now()}`,
  496. }
  497. })
  498. </script>
  499. <style lang="scss" scoped>
  500. @import "@/static/style/mixin.scss";
  501. .guide-bg{
  502. position: fixed;
  503. top: 0;
  504. width: 100%;
  505. height: 107vh;
  506. @include ossBg("treePage/guide-bg.png");
  507. z-index: 999;
  508. display: flex;
  509. align-items: center;
  510. justify-content: center;
  511. .guide-icon{
  512. width: 360rpx;
  513. height: 236rpx
  514. }
  515. }
  516. /* #ifdef H5 */
  517. .guide-bg{
  518. height: 102vh;
  519. }
  520. /* #endif */
  521. .base-container {
  522. @include ossBg("tree-bg.png");
  523. // background-position: top left;
  524. padding: 22rpx 0;
  525. position: relative;
  526. .danmaku-wrapper {
  527. position: absolute;
  528. top: 21%;
  529. left: 0;
  530. right: 0;
  531. z-index: 100;
  532. pointer-events: none;
  533. }
  534. .toogle {
  535. position: absolute;
  536. right: 0;
  537. top: calc(50% - 32rpx);
  538. font-size: 24rpx;
  539. color: #fff;
  540. border-radius: 50rpx 0 0 50rpx;
  541. background: rgba(0, 0, 0, 0.2);
  542. padding: 12rpx 20rpx;
  543. display: flex;
  544. .icon {
  545. margin-left: 10rpx;
  546. }
  547. }
  548. .tree-cont {
  549. width: 100%;
  550. margin-top: 10rpx;
  551. .dialogue-tips{
  552. position: absolute;
  553. top: 31.5%;
  554. right: 80rpx;
  555. font-size: 24rpx;
  556. @include ossBg("treePage/tips-bg.png");
  557. padding: 10rpx 10rpx 30rpx 20rpx;
  558. .tips-name{
  559. font-size: 28rpx;
  560. font-weight: 500;
  561. margin-bottom: 6rpx;
  562. display: flex;
  563. align-items: center;
  564. .tip-img{
  565. width: 40rpx;
  566. height: 40rpx;
  567. margin-right: 4rpx;
  568. }
  569. }
  570. }
  571. .tree-name {
  572. position: absolute;
  573. top: 60.45%;
  574. left: calc(50% - 32rpx);
  575. z-index: 2;
  576. font-size: 22rpx;
  577. font-family: 'SweiSpringCJKtc';
  578. text-align: center;
  579. width: 88rpx;
  580. .edit-icon {
  581. width: 44rpx;
  582. height: 44rpx;
  583. margin-top: 14rpx;
  584. }
  585. }
  586. .drone-icon {
  587. width: 376rpx;
  588. height: 384rpx;
  589. margin-left: 26rpx;
  590. }
  591. .tool-wrap {
  592. width: 100%;
  593. padding: 14rpx;
  594. box-sizing: border-box;
  595. position: absolute;
  596. bottom: calc(50% - 350rpx);
  597. display: flex;
  598. justify-content: space-between;
  599. .tool-left,
  600. .tool-right {
  601. .tool-item {
  602. color: #fff;
  603. font-size: 24rpx;
  604. font-weight: 500;
  605. text-align: center;
  606. width: 100rpx;
  607. margin-bottom: 16rpx;
  608. text-shadow:
  609. 0 0 3rpx #D7660A,
  610. 0 0 3rpx #D7660A,
  611. 0 0 3rpx #D7660A,
  612. 0 0 3rpx #D7660A;
  613. &.blue {
  614. text-shadow:
  615. 0 0 3rpx #2199F8,
  616. 0 0 3rpx #2199F8,
  617. 0 0 3rpx #2199F8,
  618. 0 0 3rpx #2199F8;
  619. }
  620. .icon {
  621. width: 100%;
  622. height: 82rpx;
  623. position: relative;
  624. }
  625. .name {
  626. margin-top: -24rpx;
  627. position: relative;
  628. z-index: 2;
  629. }
  630. &.gift {
  631. .icon {
  632. height: 114rpx;
  633. margin-top: -5rpx;
  634. }
  635. .name {
  636. margin-top: -44rpx;
  637. }
  638. }
  639. &.friend {
  640. .icon {
  641. height: 90rpx;
  642. }
  643. .name {
  644. margin-top: -35rpx;
  645. }
  646. }
  647. &.dynamic {
  648. .icon {
  649. height: 96rpx;
  650. }
  651. .name {
  652. margin-top: -32rpx;
  653. }
  654. }
  655. }
  656. }
  657. }
  658. }
  659. .tree-footer {
  660. position: absolute;
  661. left: 0;
  662. bottom: 76rpx;
  663. width: 100%;
  664. display: flex;
  665. justify-content: center;
  666. .button {
  667. padding: 26rpx 80rpx;
  668. border-radius: 50rpx;
  669. border: 2rpx solid #fff;
  670. background-image: linear-gradient(120deg, #FFD887, #ED9E1E);
  671. margin-top: 20rpx;
  672. color: #fff;
  673. }
  674. .footer-item {
  675. width: 18%;
  676. text-align: center;
  677. .icon {
  678. width: 96rpx;
  679. height: 96rpx;
  680. }
  681. .share-btn {
  682. background: transparent;
  683. display: inline-flex;
  684. .icon {
  685. width: 90rpx;
  686. height: 90rpx;
  687. margin-top: 6rpx;
  688. }
  689. &::after {
  690. border: none;
  691. }
  692. }
  693. .small{
  694. width: 90rpx;
  695. height: 90rpx;
  696. margin-top: 6rpx;
  697. }
  698. .name {
  699. font-size: 24rpx;
  700. font-weight: 500;
  701. padding: 2rpx 16rpx;
  702. background-image: linear-gradient(0deg, #FFFFFF, #FFE079);
  703. border-radius: 50rpx;
  704. border: 2rpx solid #fff;
  705. }
  706. }
  707. .footer-item+.footer-item {
  708. margin-left: 30rpx;
  709. }
  710. }
  711. }
  712. </style>