index.vue 25 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210
  1. <template>
  2. <div style="width: 100%; height: 100%;">
  3. <div class="content" :style="{ 'background': `#F5FAFF` }" v-show="show_home" v-if="detail">
  4. <div class="logo">
  5. <img src="/svg/icon-logo.svg" alt />
  6. </div>
  7. <!-- 未开始 -->
  8. <div class="not-open" v-show="status == 'not-open'">
  9. <img src="/subject/001.gif">
  10. </div>
  11. <!-- 红包打开 -->
  12. <div class="redPacket" v-show="status != 'not-open'"
  13. :class="{ redPacket2: status != 'open', key_packet: status == 'open' }">
  14. <!-- 内容 -->
  15. <div class="head">
  16. <div class="head-title">
  17. <img :src="detail.postBizData.postUserInfo.avatarUrl" alt />
  18. <span>{{ detail.postBizData.postUserInfo.nickName }}</span>
  19. </div>
  20. <!-- <div class="head-txt" v-if="status == 'open' || status == 'opened'">Awesome! You Will Get</div> -->
  21. <!-- <div class="head-area" v-else-if="status == 'opened'">opened!</div> -->
  22. <!-- 红包被领完了 -->
  23. <div class="head-area" v-if="status == 'nothing'">
  24. <div class="txt">Better luck next time!</div>
  25. </div>
  26. <!-- 过期 -->
  27. <div class="head-area expire" v-if="status == 'expire'">
  28. <div class="txt">This Giveaways</div>
  29. <div class="titme">expired on {{ formatTime(detail.postBizData.endTimestamp, 'MM-DD') }}</div>
  30. </div>
  31. <!-- 非chrome浏览器 -->
  32. <div class="head-area expire" v-if="status == 'no-chrome'">
  33. <div class="txt">Get Giveaways</div>
  34. <div class="titme">with chrome</div>
  35. </div>
  36. <!-- 领取成功 -->
  37. <div class="head-area head-money" v-if="status == 'open' || status == 'opened'">
  38. <div class="txt">AWESOME! YOU Will GET</div>
  39. <div class="head-money-area">
  40. <img :src="currencyIconUrl" alt />
  41. <span class="money-txt">{{ receiveAmount / 100 }}</span>
  42. </div>
  43. </div>
  44. </div>
  45. <!-- 领取列表 -->
  46. <div class="luck-list-title">
  47. <div>{{ detail.postBizData.receiveCount || 0 }}/{{ detail.postBizData.totalCount || 0 }} Got</div>
  48. <div> {{ detail.postBizData.receiveAmountValue / 100 }} / {{
  49. detail.postBizData.amountValue / 100 || ''
  50. }} {{ detail.postBizData.amountCurrencyCode || '' }}</div>
  51. </div>
  52. <div class="luck-list" @scroll="handleScroll($event)">
  53. <div class="luck-item" v-for="item, i in luck_list" v-bind:key="i">
  54. <img v-if="item.simpleUserInfoVO.avatarUrl" :src="item.simpleUserInfoVO.avatarUrl" alt />
  55. <img v-else src="/svg/icon-twitter.svg" alt />
  56. <div class="luck-content">
  57. <div class="luck-title">{{ item.simpleUserInfoVO.nickName || 'Twitter User' }}</div>
  58. <div class="luck-time">{{ formatTime(item.receiveTimestamp) }}</div>
  59. </div>
  60. <div class="luck-money">
  61. <img :src="item.currencyIconUrl" alt />
  62. <div class="luck-money-txt">{{ item.amountValue / 100 || 0 }}</div>
  63. </div>
  64. <div class="luck-king" v-if="item.maxAmount">
  65. <img src="/svg/icon-king-hat.svg" alt />
  66. <span>Luckiest Draw</span>
  67. </div>
  68. </div>
  69. </div>
  70. </div>
  71. <!-- 安装 -->
  72. <div class="install" v-if="status == 'open' || status == 'opened'"
  73. :class="{ key_install: status == 'open' }">
  74. <div class="title">Withdraw to Wallet</div>
  75. <div class="validity">
  76. <template v-if="validity_state">
  77. <span>Validity</span>
  78. <span style="color: red;">{{ validity }}</span>
  79. </template>
  80. <template v-else>
  81. <span style="color: red;">Giveaways Validity</span>
  82. </template>
  83. </div>
  84. <div class="flow">
  85. <div class="line"></div>
  86. <div class="area_num">
  87. <div class="num">1</div>
  88. <span>Install DeNet</span>
  89. </div>
  90. <div class="tip">Used for Task Verification and Giveaways Withdrawal</div>
  91. <div class="install_btn" @click="installExtension">Install</div>
  92. <div class="area_num">
  93. <div class="num">2</div>
  94. <span>Complete Tasks by {{ detail.postBizData.postUserInfo.nickName }}</span>
  95. </div>
  96. <div class="tip">Follow、Like tweet、Retweet (Just 1-3 minutes)</div>
  97. </div>
  98. </div>
  99. <!-- 过期 -->
  100. <div class="install install-error" v-if="status == 'nothing' || status == 'expire'">
  101. <div class="title">Install DeNet</div>
  102. <div class="title">Don't miss the next Giveaway</div>
  103. <div class="tip">Used for Task Verification and Giveaways Withdrawal</div>
  104. <div class="install_btn" @click="installExtension">Install</div>
  105. </div>
  106. <!-- 非chrome 浏览器状态 -->
  107. <div class="install install-error" v-if="status == 'no-chrome'">
  108. <div class="title">Open Giveaways</div>
  109. <div class="title">with chrome</div>
  110. <div class="tip">Only supports getting Giveaways through chrome</div>
  111. <div class="install_chrome">
  112. <img src="/svg/icon-chrome.svg" alt />
  113. Install Chrome
  114. </div>
  115. </div>
  116. <div v-if="status == 'error'"></div>
  117. </div>
  118. <div v-if="show_moblie" class="moblie">
  119. <div class="head-area">
  120. <div class="txt">GET GIVEAWAY</div>
  121. </div>
  122. <!-- 领取列表 -->
  123. <div class="luck-list-title">
  124. <div>{{ detail.postBizData.receiveCount || 0 }}/{{ detail.postBizData.totalCount || 0 }} Got</div>
  125. <div> {{ detail.postBizData.receiveAmountValue / 100 }} / {{
  126. detail.postBizData.amountValue / 100 || ''
  127. }} {{ detail.postBizData.amountCurrencyCode || '' }}</div>
  128. </div>
  129. <div class="luck-list" @scroll="handleScroll($event)">
  130. <div class="luck-item" v-for="item, i in luck_list" v-bind:key="i">
  131. <img v-if="item.simpleUserInfoVO.avatarUrl" :src="item.simpleUserInfoVO.avatarUrl" alt />
  132. <img v-else src="/svg/icon-twitter.svg" alt />
  133. <div class="luck-content">
  134. <div class="luck-title">{{ item.simpleUserInfoVO.nickName || 'Twitter User' }}</div>
  135. <div class="luck-time">{{ formatTime(item.receiveTimestamp) }}</div>
  136. </div>
  137. <div class="luck-money">
  138. <img :src="item.currencyIconUrl" alt />
  139. <div class="luck-money-txt">{{ item.amountValue / 100 || 0 }}</div>
  140. </div>
  141. <div class="luck-king" v-if="item.maxAmount">
  142. <img src="/svg/icon-king-hat.svg" alt />
  143. <span>Luckiest Draw</span>
  144. </div>
  145. </div>
  146. </div>
  147. <div class="area-cp-link">
  148. <div class="area-title">
  149. <img src="/svg/icon-mobile.svg" alt="">
  150. <div class="right">
  151. <div class="right-title">Get Giveaway on PC</div>
  152. <div class="right-content">You need to use a computer to complete tasks, and Get Giveaways (Just
  153. 2-3 minutes)</div>
  154. </div>
  155. </div>
  156. <div class="area-content">
  157. {{ cp_link }}
  158. </div>
  159. <div class="area-btn">
  160. <div class="btn" :data-clipboard-text="cp_link">Copy Link</div>
  161. </div>
  162. </div>
  163. <div class="layer" v-show="layer_show">
  164. <div class="layer-box">
  165. <div class="layer-txt">Unable to copy, please enter the link manually</div>
  166. <div class="layer-btn" @click="layer_show = false">Done</div>
  167. </div>
  168. </div>
  169. </div>
  170. </div>
  171. </template>
  172. <script>
  173. import axios from 'axios';
  174. import Cookies from 'js-cookie'
  175. import { isBrowser } from '../utils/help.js'
  176. var moment = require('moment');
  177. var ClipboardJS = require('clipboard')
  178. const api = {
  179. prod: 'https://api.denetme.net',
  180. pre: 'https://preapi.denetme.net',
  181. test: 'https://testapi.denetme.net'
  182. }
  183. const page = {
  184. prod: "https://h5.denetme.net",
  185. pre: "https://preh5.denetme.net",
  186. test: 'https://testh5.denetme.net'
  187. }
  188. const jumpUrl = page[process.env.NUXT_ENV.MODE] + '/'
  189. const baseURL = api[process.env.NUXT_ENV.MODE]
  190. export default {
  191. name: "index",
  192. data() {
  193. return {
  194. cp_link: '',
  195. appVersionCode: 1,
  196. mid: '',
  197. show_moblie: false,
  198. show_home: false,
  199. layer_show: false,
  200. validity: '',
  201. receiveAmount: 0,
  202. validity_state: true,
  203. detail: {
  204. postId: '',
  205. postBizData: {
  206. imagePath: '',
  207. postUserInfo: {
  208. }
  209. }
  210. },
  211. currencyIconUrl: '',
  212. title: '',
  213. twitterTitle: 'deNet',
  214. jumpUrl: jumpUrl,
  215. status: '',
  216. page_index: 1,
  217. page_size: 20,
  218. luck_list: [],
  219. luck_list_end: false
  220. }
  221. },
  222. head() {
  223. return {
  224. type: '',
  225. title: this.title,
  226. appVersionCode: 1,
  227. meta: [
  228. {
  229. name: 'twitter:card',
  230. content: 'summary_large_image'
  231. },
  232. {
  233. name: 'twitter:url',
  234. content: this.jumpUrl + this.detail.postId
  235. },
  236. {
  237. name: 'twitter:title',
  238. content: this.twitterTitle
  239. },
  240. {
  241. name: 'twitter:image',
  242. content: this.detail.postBizData.imagePath || ''
  243. },
  244. {
  245. name: 'twitter:image:width',
  246. content: '1280'
  247. },
  248. {
  249. name: 'twitter:image:height',
  250. content: '720'
  251. },
  252. ]
  253. }
  254. },
  255. methods: {
  256. isMobile() {
  257. let flag = navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i);
  258. return flag;
  259. },
  260. installExtension() {
  261. let url = 'https://d3d9wvhy948gxx.cloudfront.net/extensions/chrome/denet.zip'
  262. location.href = url;
  263. this.$router.push({
  264. path: '/install'
  265. })
  266. },
  267. formatTime(time, _type = 'MM-DD HH:mm:ss') {
  268. return moment(time).format(_type)
  269. },
  270. guid() {
  271. return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
  272. var r = Math.random() * 16 | 0, v = c == 'x' ? r : (r & 0x3 | 0x8);
  273. return v.toString(16);
  274. });
  275. },
  276. handleScroll(e) {
  277. e = e.target
  278. if (this.luck_list_end) {
  279. return
  280. }
  281. if ((e.clientHeight + e.scrollTop) / e.scrollHeight > .8) {
  282. this.luck_list_end = false
  283. this.page_index++
  284. this.getReceivedList()
  285. }
  286. },
  287. setCookieMid() {
  288. let _cookie_mid_arr = Cookies.get('mid') || []
  289. if (_cookie_mid_arr.length > 0) {
  290. this.mid = JSON.parse(_cookie_mid_arr)[0].mid
  291. } else {
  292. this.mid = this.guid()
  293. Cookies.set('mid', JSON.stringify([{ mid: this.mid }]), { expires: 1000 })
  294. }
  295. },
  296. async getRedPacket() {
  297. let { data } = await axios.post(`${baseURL}/denet/post/luckdrop/receiveLuckdrop`, {
  298. baseInfo: {
  299. appVersionCode: this.appVersionCode,
  300. mid: this.mid
  301. },
  302. params: {
  303. postId: this.detail.postId || ''
  304. }
  305. })
  306. this.show_home = true
  307. switch (data.code.toString()) {
  308. case '0':
  309. if (data.data.newReceived) {
  310. this.status = 'not-open'
  311. setTimeout(() => {
  312. this.status = 'open'
  313. }, 3000)
  314. this.receiveAmount = data.data.receiveAmount
  315. } else {
  316. this.status = 'opened'
  317. }
  318. this.getValidity(data.data.endTimestamp)
  319. this.receiveAmount = data.data.receiveAmount
  320. break;
  321. case '2003':
  322. this.status = 'expire'
  323. break
  324. // 红包被领完了
  325. case '2008':
  326. this.status = 'nothing'
  327. break
  328. case '2029':
  329. // 推文未发布
  330. this.status = 'error'
  331. break
  332. default:
  333. console.log('getRedPacket', data)
  334. this.show_home = false
  335. break;
  336. }
  337. // 领取列表分页
  338. this.getReceivedList()
  339. },
  340. async getReceivedList() {
  341. let { data } = await axios.post(`${baseURL}/denet/post/luckdrop/getReceivedList`, {
  342. baseInfo: {
  343. appVersionCode: this.appVersionCode,
  344. mid: this.mid
  345. },
  346. params: {
  347. pageNum: this.page_index,
  348. pageSize: this.page_size,
  349. postId: this.detail.postId || ''
  350. }
  351. })
  352. if (data.code == 0) {
  353. if (data.data.length > 0) {
  354. this.luck_list = this.luck_list.concat(data.data)
  355. this.luck_list_end = false
  356. } else {
  357. this.luck_list_end = true
  358. }
  359. } else {
  360. console.log('getReceivedList', data)
  361. }
  362. },
  363. getValidity(end_time) {
  364. let _d1, _d2, _d3, _h, _m, _s
  365. let timer = setInterval(() => {
  366. let _time = new Date().getTime()
  367. _d3 = end_time - _time
  368. if (_d3 > 0) {
  369. _d1 = moment(end_time)
  370. _d2 = moment(_time)
  371. _h = moment.duration(_d1.diff(_d2)).hours()
  372. _m = moment.duration(_d1.diff(_d2)).minutes()
  373. _s = moment.duration(_d1.diff(_d2)).seconds()
  374. this.validity = `${_h}:${_m}:${_s}`
  375. } else {
  376. clearInterval(timer)
  377. }
  378. }, 1000)
  379. },
  380. setPickupInfo() {
  381. let pickupInfo = {
  382. srcContentId: this.detail.srcContentId,
  383. postNickName: this.detail.postBizData.postUserInfo.nickName
  384. };
  385. Cookies.set('pickup_info', JSON.stringify(pickupInfo), { expires: 100 });
  386. }
  387. },
  388. async asyncData(params) {
  389. let { route } = params;
  390. let { data } = await axios.post(`${baseURL}/denet/post/getDetail`, {
  391. baseInfo: {
  392. mid: function () {
  393. return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
  394. var r = Math.random() * 16 | 0, v = c == 'x' ? r : (r & 0x3 | 0x8);
  395. return v.toString(16);
  396. });
  397. }()
  398. },
  399. params: {
  400. postId: route.params.id || ''
  401. }
  402. })
  403. if (data.code == 0) {
  404. if (data.data && data.data.postBizData && typeof data.data.postBizData == 'string') {
  405. data.data.postBizData = JSON.parse(data.data.postBizData)
  406. }
  407. return {
  408. detail: data.data,
  409. }
  410. }
  411. },
  412. mounted() {
  413. if (!this.detail.postId) {
  414. return
  415. }
  416. //改变font-size
  417. // (function (doc, win) {
  418. // var docEI = doc.documentElement,
  419. // resizeEvt = 'orientationchange' in window ? 'orientataionchange' : 'resize',
  420. // recalc = function () {
  421. // var clientWidth = docEI.clientWidth;
  422. // if (!clientWidth) return;
  423. // //100是字体大小,1510是开发时浏览器窗口的宽度,等比计算
  424. // docEI.style.fontSize = 10 * (clientWidth / 1510) + 'px';
  425. // }
  426. // if (!doc.addEventListener) return;
  427. // win.addEventListener(resizeEvt, recalc, false);
  428. // doc.addEventListener('DOMContentLoaded', recalc, false);
  429. // })(document, window);
  430. document.documentElement.style.fontSize = '62.5%'
  431. if (this.isMobile()) {
  432. this.show_moblie = true
  433. this.cp_link = window.location.href
  434. // 复制链接
  435. var clipboard = new ClipboardJS('.btn');
  436. clipboard.on('success', function (e) {
  437. console.info('Action:', e.action);
  438. console.info('Text:', e.text);
  439. console.info('Trigger:', e.trigger);
  440. e.clearSelection();
  441. });
  442. clipboard.on('error', function (e) {
  443. this.layer_show = true
  444. console.error('Action:', e.action);
  445. console.error('Trigger:', e.trigger);
  446. });
  447. // 领取列表分页
  448. this.getReceivedList()
  449. } else if (isBrowser() == 'chrome') {
  450. // 领取任务红包
  451. this.setCookieMid()
  452. this.getRedPacket()
  453. this.setPickupInfo()
  454. } else {
  455. this.show_home = true
  456. this.status = 'no-chrome'
  457. }
  458. }
  459. }
  460. </script>
  461. <style lang="scss" >
  462. html,
  463. body,
  464. #__nuxt,
  465. #__layout {
  466. width: 100%;
  467. height: 100%;
  468. padding: 0;
  469. margin: 0;
  470. }
  471. .moblie {
  472. display: flex;
  473. flex-wrap: wrap;
  474. height: 100%;
  475. align-content: flex-start;
  476. flex-direction: column;
  477. .layer {
  478. position: fixed;
  479. width: 100%;
  480. height: 100%;
  481. top: 0;
  482. left: 0;
  483. background: rgba(0, 0, 0, .5);
  484. .layer-box {
  485. width: 30rem;
  486. height: 17rem;
  487. background: #FFFFFF;
  488. border-radius: 11px;
  489. opacity: 1;
  490. position: absolute;
  491. top: 25rem;
  492. left: 50%;
  493. margin-left: -15rem;
  494. .layer-txt {
  495. margin: 3rem 0;
  496. width: 100%;
  497. padding: 0 2.7rem;
  498. font-weight: 600;
  499. font-size: 1.8rem;
  500. text-align: center;
  501. }
  502. .layer-btn {
  503. width: 19rem;
  504. height: 4rem;
  505. background: #389AFF;
  506. border-radius: 100px;
  507. margin: 0 auto;
  508. text-align: center;
  509. line-height: 4rem;
  510. color: #fff;
  511. font-weight: 600;
  512. font-size: 1.8rem;
  513. }
  514. }
  515. }
  516. .head-area {
  517. width: 100%;
  518. height: 8rem;
  519. text-align: center;
  520. letter-spacing: 0.3px;
  521. font-size: 2rem;
  522. text-align: center;
  523. color: #fff;
  524. background: #389AFF;
  525. border-radius: 0 586px 586px/0 0 104px 104px;
  526. display: flex;
  527. align-items: center;
  528. .txt {
  529. width: 100%;
  530. text-align: center;
  531. }
  532. }
  533. .luck-list-title {
  534. /* margin-top: 47px;*/
  535. margin: 0 16px;
  536. padding: 14px 0 11px 0;
  537. background: #fff;
  538. display: flex;
  539. justify-content: space-between;
  540. color: #B0B0B0;
  541. border-bottom: 1px solid #D1D1D1;
  542. }
  543. .luck-list {
  544. flex: 1;
  545. width: 100%;
  546. background: #fff;
  547. overflow: auto;
  548. .luck-item {
  549. display: flex;
  550. padding: 12px 0;
  551. margin: 0 16px;
  552. border-bottom: 1px solid #d1d1d1;
  553. justify-content: space-between;
  554. position: relative;
  555. img:first-child {
  556. border-radius: 50%;
  557. }
  558. .luck-king {
  559. position: absolute;
  560. top: 36px;
  561. right: 0px;
  562. display: flex;
  563. align-items: center;
  564. img {
  565. width: 22px;
  566. height: 19px;
  567. margin: 0;
  568. }
  569. span {
  570. font-weight: 500;
  571. font-size: 12px;
  572. line-height: 14px;
  573. letter-spacing: 0.3px;
  574. color: #f5b945;
  575. }
  576. }
  577. img {
  578. width: 42px;
  579. height: 42px;
  580. margin-right: 12px;
  581. }
  582. .luck-content {
  583. flex: auto;
  584. .luck-title {
  585. font-weight: 500;
  586. font-size: 16px;
  587. letter-spacing: 0.3px;
  588. color: #444444;
  589. }
  590. .luck-time {
  591. font-weight: 400;
  592. font-size: 12px;
  593. line-height: 14px;
  594. color: #9b9b9b;
  595. }
  596. }
  597. .luck-money {
  598. display: flex;
  599. height: 17px;
  600. align-items: center;
  601. img {
  602. width: 14px;
  603. height: 14px;
  604. margin-right: 6px;
  605. }
  606. .luck-money-txt {
  607. font-weight: 500;
  608. font-size: 14px;
  609. /* identical to box height */
  610. text-align: right;
  611. letter-spacing: 0.3px;
  612. color: #444444;
  613. }
  614. }
  615. }
  616. .luck-item:last-child {
  617. border: 0;
  618. }
  619. }
  620. .area-cp-link {
  621. background: #fff;
  622. display: flex;
  623. width: 100%;
  624. flex-wrap: wrap;
  625. position: fixed;
  626. bottom: 0;
  627. height: 20rem;
  628. box-shadow: 0px -4px 10px rgba(0, 0, 0, 0.1);
  629. border-top-left-radius: 2rem;
  630. border-top-right-radius: 2rem;
  631. .area-title {
  632. display: flex;
  633. img {
  634. width: 6.4rem;
  635. height: 6.4rem;
  636. margin: 1.5rem;
  637. }
  638. .right {
  639. flex: 1;
  640. letter-spacing: 0.3px;
  641. .right-title {
  642. font-size: 1.7rem;
  643. color: #000000;
  644. margin-top: 1.7rem;
  645. }
  646. .right-content {
  647. font-size: 1.2rem;
  648. color: #989898;
  649. }
  650. }
  651. }
  652. .area-content {
  653. background: #F4F4F4;
  654. height: 4.6rem;
  655. padding: 0 1rem;
  656. width: 100%;
  657. font-size: 1.3rem;
  658. word-break: break-all;
  659. }
  660. .area-btn {
  661. flex: 1;
  662. display: flex;
  663. justify-content: center;
  664. .btn {
  665. width: 34.3rem;
  666. height: 4rem;
  667. background: #389AFF;
  668. border-radius: 100px;
  669. font-size: 1.8rem;
  670. color: #FFFFFF;
  671. }
  672. }
  673. }
  674. }
  675. .content {
  676. width: 100%;
  677. height: 100%;
  678. background-size: 100%;
  679. background-repeat: no-repeat;
  680. position: relative;
  681. font-family: "SF Pro Display";
  682. font-style: normal;
  683. font-weight: 600;
  684. .not-open {
  685. display: flex;
  686. align-items: center;
  687. justify-content: center;
  688. width: 100%;
  689. height: 100%;
  690. img {
  691. width: 20rem;
  692. height: 20rem;
  693. }
  694. }
  695. .logo {
  696. position: absolute;
  697. left: 4rem;
  698. top: 1.5rem;
  699. img {
  700. width: 10.7rem;
  701. height: 4rem;
  702. }
  703. }
  704. .key_packet {
  705. animation: key_packet 3s;
  706. animation-delay: 0s;
  707. animation-fill-mode: forwards;
  708. }
  709. .redPacket {
  710. display: flex;
  711. justify-content: flex-start;
  712. flex-direction: column;
  713. position: absolute;
  714. top: 9rem;
  715. left: 50%;
  716. width: 37.5rem;
  717. margin-left: -18rem;
  718. height: 65rem;
  719. border-radius: 2rem;
  720. // background: red;
  721. overflow: hidden;
  722. box-shadow: 0 0 5px #888888;
  723. background: #fff;
  724. .top {
  725. top: 0;
  726. position: absolute;
  727. width: 100%;
  728. z-index: 12;
  729. }
  730. .down {
  731. bottom: 0;
  732. position: absolute;
  733. height: 32.3rem;
  734. z-index: 11;
  735. }
  736. .head {
  737. position: relative;
  738. .head-title {
  739. position: absolute;
  740. top: 0;
  741. width: 100%;
  742. display: flex;
  743. align-items: center;
  744. justify-content: center;
  745. height: 3.6rem;
  746. background: rgba(255, 255, 255, .1);
  747. img {
  748. width: 1.8rem;
  749. height: 1.8rem;
  750. border-radius: 50%;
  751. border: 1px solid #fff;
  752. }
  753. span {
  754. margin-left: .8rem;
  755. font-size: 1.2rem;
  756. color: #fff;
  757. }
  758. }
  759. .head-txt {
  760. margin-top: 4.7rem;
  761. font-size: 2rem;
  762. text-align: center;
  763. color: #fff;
  764. }
  765. .head-area {
  766. height: 19rem;
  767. text-align: center;
  768. letter-spacing: 0.3px;
  769. font-size: 2rem;
  770. text-align: center;
  771. color: #fff;
  772. background: #389AFF;
  773. border-radius: 0 586px 586px/0 0 104px 104px;
  774. .txt {
  775. padding-top: 8.5rem;
  776. }
  777. }
  778. .head-money {
  779. .txt {
  780. padding-top: 6.8rem;
  781. font-weight: 800;
  782. font-size: 1.5rem;
  783. text-align: center;
  784. letter-spacing: 0.3px;
  785. }
  786. .head-money-area {
  787. display: flex;
  788. width: 100%;
  789. justify-content: center;
  790. align-items: center;
  791. img {
  792. width: 4rem;
  793. height: 4rem;
  794. border: 2px solid #FFFFFF;
  795. border-radius: 100px;
  796. }
  797. span {
  798. margin-left: 1.3rem;
  799. font-size: 4.6rem;
  800. }
  801. }
  802. }
  803. }
  804. .luck-list-title {
  805. /* margin-top: 47px;*/
  806. margin: 0 16px;
  807. padding: 14px 0 11px 0;
  808. background: #fff;
  809. display: flex;
  810. justify-content: space-between;
  811. color: #B0B0B0;
  812. border-bottom: 1px solid #D1D1D1;
  813. }
  814. .luck-list {
  815. background: #fff;
  816. overflow: auto;
  817. .luck-item {
  818. display: flex;
  819. padding: 12px 0;
  820. margin: 0 16px;
  821. border-bottom: 1px solid #d1d1d1;
  822. justify-content: space-between;
  823. position: relative;
  824. img:first-child {
  825. border-radius: 50%;
  826. }
  827. .luck-king {
  828. position: absolute;
  829. top: 36px;
  830. right: 0px;
  831. display: flex;
  832. align-items: center;
  833. img {
  834. width: 22px;
  835. height: 19px;
  836. margin: 0;
  837. }
  838. span {
  839. font-weight: 500;
  840. font-size: 12px;
  841. line-height: 14px;
  842. letter-spacing: 0.3px;
  843. color: #f5b945;
  844. }
  845. }
  846. img {
  847. width: 42px;
  848. height: 42px;
  849. margin-right: 12px;
  850. }
  851. .luck-content {
  852. flex: auto;
  853. .luck-title {
  854. font-weight: 500;
  855. font-size: 16px;
  856. letter-spacing: 0.3px;
  857. color: #444444;
  858. }
  859. .luck-time {
  860. font-weight: 400;
  861. font-size: 12px;
  862. line-height: 14px;
  863. color: #9b9b9b;
  864. }
  865. }
  866. .luck-money {
  867. display: flex;
  868. height: 17px;
  869. align-items: center;
  870. img {
  871. width: 14px;
  872. height: 14px;
  873. margin-right: 6px;
  874. }
  875. .luck-money-txt {
  876. font-weight: 500;
  877. font-size: 14px;
  878. /* identical to box height */
  879. text-align: right;
  880. letter-spacing: 0.3px;
  881. color: #444444;
  882. }
  883. }
  884. }
  885. .luck-item:last-child {
  886. border: 0;
  887. }
  888. }
  889. .area {
  890. position: absolute;
  891. z-index: 112;
  892. width: 100%;
  893. .title {
  894. z-index: 11;
  895. margin-top: 8.5rem;
  896. text-align: center;
  897. img {
  898. width: 3.6rem;
  899. height: 3.6rem;
  900. border: 2px solid #fff4db;
  901. border-radius: 50%;
  902. }
  903. span {
  904. letter-spacing: 0.3px;
  905. font-size: 1.6rem;
  906. color: #fff2d3;
  907. }
  908. }
  909. .txt {
  910. font-size: 4rem;
  911. text-align: center;
  912. letter-spacing: 0.03rem;
  913. color: #fff2d3;
  914. }
  915. }
  916. .key_area {
  917. animation: key_area 1s;
  918. animation-delay: 1s;
  919. animation-fill-mode: forwards;
  920. }
  921. }
  922. .redPacket2 {
  923. left: 30.6rem;
  924. margin-left: -18rem;
  925. }
  926. .key_install {
  927. opacity: 0;
  928. animation: key_install 2s;
  929. animation-delay: 0s;
  930. animation-fill-mode: forwards;
  931. }
  932. .install {
  933. position: absolute;
  934. top: 20rem;
  935. left: 78.5rem;
  936. .title {
  937. font-size: 4.8rem;
  938. color: #000000;
  939. letter-spacing: 0.3px;
  940. }
  941. .validity {
  942. margin-top: 1rem;
  943. color: #FF0000;
  944. width: 40rem;
  945. height: 3.3rem;
  946. line-height: 3.3rem;
  947. span {
  948. font-size: 1.4rem;
  949. }
  950. }
  951. .flow {
  952. position: absolute;
  953. margin-top: 4rem;
  954. .line {
  955. position: absolute;
  956. height: 16rem;
  957. border: 1px solid #e0e0e0;
  958. top: 3rem;
  959. left: 1.2rem;
  960. }
  961. .area_num {
  962. display: flex;
  963. align-items: center;
  964. .num {
  965. width: 2.4rem;
  966. height: 2.4rem;
  967. background-color: rgba(56, 154, 255, 1);
  968. border-radius: 50%;
  969. color: #fff;
  970. text-align: center;
  971. line-height: 2.4rem;
  972. font-size: 1.4rem;
  973. }
  974. span {
  975. margin-left: 1.5rem;
  976. color: #000000;
  977. font-size: 1.8rem;
  978. }
  979. }
  980. .tip {
  981. margin-left: 4rem;
  982. margin-top: 0.7rem;
  983. font-size: 1.4rem;
  984. color: #a4a4a4;
  985. }
  986. .install_btn {
  987. cursor: pointer;
  988. margin-left: 4rem;
  989. margin-top: 2rem;
  990. margin-bottom: 6.7rem;
  991. width: 23rem;
  992. height: 5.8rem;
  993. background: #389aff;
  994. border-radius: 10rem;
  995. color: #fff;
  996. line-height: 5.8rem;
  997. text-align: center;
  998. font-size: 2rem;
  999. }
  1000. }
  1001. .tip {
  1002. margin-top: 0.7rem;
  1003. font-size: 1.4rem;
  1004. color: #a4a4a4;
  1005. }
  1006. .install_btn {
  1007. cursor: pointer;
  1008. margin-top: 2rem;
  1009. margin-bottom: 6.7rem;
  1010. width: 23rem;
  1011. height: 5.8rem;
  1012. background: #389aff;
  1013. border-radius: 10rem;
  1014. color: #fff;
  1015. line-height: 5.8rem;
  1016. text-align: center;
  1017. font-size: 2rem;
  1018. }
  1019. }
  1020. .install-error {
  1021. left: 78.5rem;
  1022. .install_chrome {
  1023. cursor: pointer;
  1024. width: 24.3rem;
  1025. height: 5.8rem;
  1026. font-size: 2rem;
  1027. font-weight: 500;
  1028. letter-spacing: 0.3px;
  1029. display: flex;
  1030. align-items: center;
  1031. background: #FFFFFF;
  1032. border: 1px solid #e8e8e8;
  1033. border-radius: 10rem;
  1034. margin-top: 3.3rem;
  1035. img {
  1036. width: 3.2rem;
  1037. height: 3.2rem;
  1038. margin-left: 3.3rem;
  1039. }
  1040. span {
  1041. margin-left: 1.2rem;
  1042. }
  1043. }
  1044. }
  1045. }
  1046. @keyframes key_area {
  1047. 0% {
  1048. opacity: 1;
  1049. }
  1050. 100% {
  1051. opacity: 0;
  1052. }
  1053. }
  1054. @keyframes key_install {
  1055. 0% {
  1056. opacity: 0;
  1057. }
  1058. 100% {
  1059. opacity: 1;
  1060. }
  1061. }
  1062. @keyframes key_packet {
  1063. 0% {}
  1064. 100% {
  1065. left: 30.6rem;
  1066. margin-left: -18rem;
  1067. }
  1068. }
  1069. </style>