index.vue 25 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213
  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="currencyIconPath" alt />
  41. <span class="money-txt">{{ receiveAmount }}</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 }} / {{
  49. detail.postBizData.amountValue || ''
  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.currencyIconPath" alt />
  62. <div class="luck-money-txt">{{ item.amountValue || 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 }} / {{
  126. detail.postBizData.amountValue || ''
  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.currencyIconPath" alt />
  139. <div class="luck-money-txt">{{ item.amountValue || 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. currencyIconPath: '',
  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. }
  246. },
  247. methods: {
  248. isMobile() {
  249. 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);
  250. return flag;
  251. },
  252. installExtension() {
  253. let url = 'https://d3d9wvhy948gxx.cloudfront.net/extensions/chrome/denet.zip'
  254. location.href = url;
  255. this.$router.push({
  256. path: '/install'
  257. })
  258. },
  259. formatTime(time, _type = 'MM-DD HH:mm:ss') {
  260. return moment(time).format(_type)
  261. },
  262. guid() {
  263. return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
  264. var r = Math.random() * 16 | 0, v = c == 'x' ? r : (r & 0x3 | 0x8);
  265. return v.toString(16);
  266. });
  267. },
  268. handleScroll(e) {
  269. e = e.target
  270. if (this.luck_list_end) {
  271. return
  272. }
  273. if ((e.clientHeight + e.scrollTop) / e.scrollHeight > .8) {
  274. this.luck_list_end = false
  275. this.page_index++
  276. this.getReceivedList()
  277. }
  278. },
  279. setCookieMid() {
  280. let _cookie_mid_arr = Cookies.get('mid') || []
  281. if (_cookie_mid_arr.length > 0) {
  282. this.mid = JSON.parse(_cookie_mid_arr)[0].mid
  283. } else {
  284. this.mid = this.guid()
  285. Cookies.set('mid', JSON.stringify([{ mid: this.mid }]), { expires: 1000 })
  286. }
  287. },
  288. async getRedPacket() {
  289. this.currencyIconPath = this.detail.postBizData.currencyIconPath
  290. let { data } = await axios.post(`${baseURL}/denet/post/luckdrop/receiveLuckdrop`, {
  291. baseInfo: {
  292. appVersionCode: this.appVersionCode,
  293. mid: this.mid
  294. },
  295. params: {
  296. postId: this.detail.postId || ''
  297. }
  298. })
  299. this.show_home = true
  300. switch (data.code.toString()) {
  301. case '0':
  302. if (data.data.newReceived) {
  303. this.status = 'not-open'
  304. setTimeout(() => {
  305. this.status = 'open'
  306. }, 3000)
  307. this.receiveAmount = data.data.receiveAmount
  308. } else {
  309. this.status = 'opened'
  310. }
  311. this.getValidity(data.data.endTimestamp)
  312. this.receiveAmount = data.data.receiveAmount
  313. break;
  314. case '2003':
  315. this.status = 'expire'
  316. break
  317. // 红包被领完了
  318. case '2008':
  319. this.status = 'nothing'
  320. break
  321. case '2029':
  322. // 推文未发布
  323. this.status = 'error'
  324. break
  325. default:
  326. console.log('getRedPacket', data)
  327. this.show_home = false
  328. break;
  329. }
  330. // 领取列表分页
  331. this.getReceivedList()
  332. },
  333. async getReceivedList() {
  334. let { data } = await axios.post(`${baseURL}/denet/post/luckdrop/getReceivedList`, {
  335. baseInfo: {
  336. appVersionCode: this.appVersionCode,
  337. mid: this.mid
  338. },
  339. params: {
  340. pageNum: this.page_index,
  341. pageSize: this.page_size,
  342. postId: this.detail.postId || ''
  343. }
  344. })
  345. if (data.code == 0) {
  346. if (data.data.length > 0) {
  347. this.luck_list = this.luck_list.concat(data.data)
  348. this.luck_list_end = false
  349. } else {
  350. this.luck_list_end = true
  351. }
  352. } else {
  353. console.log('getReceivedList', data)
  354. }
  355. },
  356. getValidity(end_time) {
  357. let _d1, _d2, _d3, _h, _m, _s
  358. let timer = setInterval(() => {
  359. let _time = new Date().getTime()
  360. _d3 = end_time - _time
  361. if (_d3 > 0) {
  362. _d1 = moment(end_time)
  363. _d2 = moment(_time)
  364. _h = moment.duration(_d1.diff(_d2)).hours()
  365. _m = moment.duration(_d1.diff(_d2)).minutes()
  366. _s = moment.duration(_d1.diff(_d2)).seconds()
  367. if (_h < 10) {
  368. _h = '0' + _h
  369. }
  370. if (_m < 10) {
  371. _m = '0' + _m
  372. }
  373. if (_s < 10) {
  374. _s = '0' + _s
  375. }
  376. this.validity = `${_h}:${_m}:${_s}`
  377. } else {
  378. clearInterval(timer)
  379. }
  380. }, 1000)
  381. },
  382. setPickupInfo() {
  383. let pickupInfo = {
  384. srcContentId: this.detail.srcContentId,
  385. postNickName: this.detail.postBizData.postUserInfo.nickName
  386. };
  387. Cookies.set('pickup_info', JSON.stringify(pickupInfo), { expires: 100 });
  388. }
  389. },
  390. async asyncData(params) {
  391. let { route } = params;
  392. let { data } = await axios.post(`${baseURL}/denet/post/getDetail`, {
  393. baseInfo: {
  394. mid: function () {
  395. return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
  396. var r = Math.random() * 16 | 0, v = c == 'x' ? r : (r & 0x3 | 0x8);
  397. return v.toString(16);
  398. });
  399. }()
  400. },
  401. params: {
  402. postId: route.params.id || ''
  403. }
  404. })
  405. if (data.code == 0) {
  406. if (data.data && data.data.postBizData && typeof data.data.postBizData == 'string') {
  407. data.data.postBizData = JSON.parse(data.data.postBizData)
  408. }
  409. return {
  410. detail: data.data,
  411. }
  412. }
  413. },
  414. mounted() {
  415. if (!this.detail.postId) {
  416. return
  417. }
  418. //改变font-size
  419. // (function (doc, win) {
  420. // var docEI = doc.documentElement,
  421. // resizeEvt = 'orientationchange' in window ? 'orientataionchange' : 'resize',
  422. // recalc = function () {
  423. // var clientWidth = docEI.clientWidth;
  424. // if (!clientWidth) return;
  425. // //100是字体大小,1510是开发时浏览器窗口的宽度,等比计算
  426. // docEI.style.fontSize = 10 * (clientWidth / 1510) + 'px';
  427. // }
  428. // if (!doc.addEventListener) return;
  429. // win.addEventListener(resizeEvt, recalc, false);
  430. // doc.addEventListener('DOMContentLoaded', recalc, false);
  431. // })(document, window);
  432. document.documentElement.style.fontSize = '62.5%'
  433. if (this.isMobile()) {
  434. this.show_moblie = true
  435. this.cp_link = window.location.href
  436. // 复制链接
  437. var clipboard = new ClipboardJS('.btn');
  438. clipboard.on('success', function (e) {
  439. console.info('Action:', e.action);
  440. console.info('Text:', e.text);
  441. console.info('Trigger:', e.trigger);
  442. e.clearSelection();
  443. });
  444. clipboard.on('error', function (e) {
  445. this.layer_show = true
  446. console.error('Action:', e.action);
  447. console.error('Trigger:', e.trigger);
  448. });
  449. // 领取列表分页
  450. this.getReceivedList()
  451. } else if (isBrowser() == 'chrome') {
  452. // 领取任务红包
  453. this.setCookieMid()
  454. this.getRedPacket()
  455. this.setPickupInfo()
  456. } else {
  457. this.show_home = true
  458. this.status = 'no-chrome'
  459. }
  460. }
  461. }
  462. </script>
  463. <style lang="scss" >
  464. html,
  465. body,
  466. #__nuxt,
  467. #__layout {
  468. width: 100%;
  469. height: 100%;
  470. padding: 0;
  471. margin: 0;
  472. }
  473. .moblie {
  474. display: flex;
  475. flex-wrap: wrap;
  476. height: 100%;
  477. align-content: flex-start;
  478. flex-direction: column;
  479. .layer {
  480. position: fixed;
  481. width: 100%;
  482. height: 100%;
  483. top: 0;
  484. left: 0;
  485. background: rgba(0, 0, 0, .5);
  486. .layer-box {
  487. width: 30rem;
  488. height: 17rem;
  489. background: #FFFFFF;
  490. border-radius: 11px;
  491. opacity: 1;
  492. position: absolute;
  493. top: 25rem;
  494. left: 50%;
  495. margin-left: -15rem;
  496. .layer-txt {
  497. margin: 3rem 0;
  498. width: 100%;
  499. padding: 0 2.7rem;
  500. font-weight: 600;
  501. font-size: 1.8rem;
  502. text-align: center;
  503. }
  504. .layer-btn {
  505. width: 19rem;
  506. height: 4rem;
  507. background: #389AFF;
  508. border-radius: 100px;
  509. margin: 0 auto;
  510. text-align: center;
  511. line-height: 4rem;
  512. color: #fff;
  513. font-weight: 600;
  514. font-size: 1.8rem;
  515. }
  516. }
  517. }
  518. .head-area {
  519. width: 100%;
  520. height: 8rem;
  521. text-align: center;
  522. letter-spacing: 0.3px;
  523. font-size: 2rem;
  524. text-align: center;
  525. color: #fff;
  526. background: #389AFF;
  527. border-radius: 0 586px 586px/0 0 104px 104px;
  528. display: flex;
  529. align-items: center;
  530. .txt {
  531. width: 100%;
  532. text-align: center;
  533. }
  534. }
  535. .luck-list-title {
  536. /* margin-top: 47px;*/
  537. margin: 0 16px;
  538. padding: 14px 0 11px 0;
  539. background: #fff;
  540. display: flex;
  541. justify-content: space-between;
  542. color: #B0B0B0;
  543. border-bottom: 1px solid #D1D1D1;
  544. }
  545. .luck-list {
  546. flex: 1;
  547. width: 100%;
  548. background: #fff;
  549. overflow: auto;
  550. .luck-item {
  551. display: flex;
  552. padding: 12px 0;
  553. margin: 0 16px;
  554. border-bottom: 1px solid #d1d1d1;
  555. justify-content: space-between;
  556. position: relative;
  557. img:first-child {
  558. border-radius: 50%;
  559. }
  560. .luck-king {
  561. position: absolute;
  562. top: 36px;
  563. right: 0px;
  564. display: flex;
  565. align-items: center;
  566. img {
  567. width: 22px;
  568. height: 19px;
  569. margin: 0;
  570. }
  571. span {
  572. font-weight: 500;
  573. font-size: 12px;
  574. line-height: 14px;
  575. letter-spacing: 0.3px;
  576. color: #f5b945;
  577. }
  578. }
  579. img {
  580. width: 42px;
  581. height: 42px;
  582. margin-right: 12px;
  583. }
  584. .luck-content {
  585. flex: auto;
  586. .luck-title {
  587. font-weight: 500;
  588. font-size: 16px;
  589. letter-spacing: 0.3px;
  590. color: #444444;
  591. }
  592. .luck-time {
  593. font-weight: 400;
  594. font-size: 12px;
  595. line-height: 14px;
  596. color: #9b9b9b;
  597. }
  598. }
  599. .luck-money {
  600. display: flex;
  601. height: 17px;
  602. align-items: center;
  603. img {
  604. width: 14px;
  605. height: 14px;
  606. margin-right: 6px;
  607. }
  608. .luck-money-txt {
  609. font-weight: 500;
  610. font-size: 14px;
  611. /* identical to box height */
  612. text-align: right;
  613. letter-spacing: 0.3px;
  614. color: #444444;
  615. }
  616. }
  617. }
  618. .luck-item:last-child {
  619. border: 0;
  620. }
  621. }
  622. .area-cp-link {
  623. background: #fff;
  624. display: flex;
  625. width: 100%;
  626. flex-wrap: wrap;
  627. position: fixed;
  628. bottom: 0;
  629. height: 20rem;
  630. box-shadow: 0px -4px 10px rgba(0, 0, 0, 0.1);
  631. border-top-left-radius: 2rem;
  632. border-top-right-radius: 2rem;
  633. .area-title {
  634. display: flex;
  635. img {
  636. width: 6.4rem;
  637. height: 6.4rem;
  638. margin: 1.5rem;
  639. }
  640. .right {
  641. flex: 1;
  642. letter-spacing: 0.3px;
  643. .right-title {
  644. font-size: 1.7rem;
  645. color: #000000;
  646. margin-top: 1.7rem;
  647. }
  648. .right-content {
  649. font-size: 1.2rem;
  650. color: #989898;
  651. }
  652. }
  653. }
  654. .area-content {
  655. background: #F4F4F4;
  656. height: 4.6rem;
  657. padding: 0 1rem;
  658. width: 100%;
  659. font-size: 1.3rem;
  660. word-break: break-all;
  661. }
  662. .area-btn {
  663. flex: 1;
  664. display: flex;
  665. justify-content: center;
  666. .btn {
  667. width: 34.3rem;
  668. height: 4rem;
  669. background: #389AFF;
  670. border-radius: 100px;
  671. font-size: 1.8rem;
  672. color: #FFFFFF;
  673. }
  674. }
  675. }
  676. }
  677. .content {
  678. width: 100%;
  679. height: 100%;
  680. background-size: 100%;
  681. background-repeat: no-repeat;
  682. position: relative;
  683. font-family: "SF Pro Display";
  684. font-style: normal;
  685. font-weight: 600;
  686. .not-open {
  687. display: flex;
  688. align-items: center;
  689. justify-content: center;
  690. width: 100%;
  691. height: 100%;
  692. img {
  693. width: 20rem;
  694. height: 20rem;
  695. }
  696. }
  697. .logo {
  698. position: absolute;
  699. left: 4rem;
  700. top: 1.5rem;
  701. img {
  702. width: 10.7rem;
  703. height: 4rem;
  704. }
  705. }
  706. .key_packet {
  707. animation: key_packet 3s;
  708. animation-delay: 0s;
  709. animation-fill-mode: forwards;
  710. }
  711. .redPacket {
  712. display: flex;
  713. justify-content: flex-start;
  714. flex-direction: column;
  715. position: absolute;
  716. top: 9rem;
  717. left: 50%;
  718. width: 37.5rem;
  719. margin-left: -18rem;
  720. height: 65rem;
  721. border-radius: 2rem;
  722. // background: red;
  723. overflow: hidden;
  724. box-shadow: 0 0 5px #888888;
  725. background: #fff;
  726. .top {
  727. top: 0;
  728. position: absolute;
  729. width: 100%;
  730. z-index: 12;
  731. }
  732. .down {
  733. bottom: 0;
  734. position: absolute;
  735. height: 32.3rem;
  736. z-index: 11;
  737. }
  738. .head {
  739. position: relative;
  740. .head-title {
  741. position: absolute;
  742. top: 0;
  743. width: 100%;
  744. display: flex;
  745. align-items: center;
  746. justify-content: center;
  747. height: 3.6rem;
  748. background: rgba(255, 255, 255, .1);
  749. img {
  750. width: 1.8rem;
  751. height: 1.8rem;
  752. border-radius: 50%;
  753. border: 1px solid #fff;
  754. }
  755. span {
  756. margin-left: .8rem;
  757. font-size: 1.2rem;
  758. color: #fff;
  759. }
  760. }
  761. .head-txt {
  762. margin-top: 4.7rem;
  763. font-size: 2rem;
  764. text-align: center;
  765. color: #fff;
  766. }
  767. .head-area {
  768. height: 19rem;
  769. text-align: center;
  770. letter-spacing: 0.3px;
  771. font-size: 2rem;
  772. text-align: center;
  773. color: #fff;
  774. background: #389AFF;
  775. border-radius: 0 586px 586px/0 0 104px 104px;
  776. .txt {
  777. padding-top: 8.5rem;
  778. }
  779. }
  780. .head-money {
  781. .txt {
  782. padding-top: 6.8rem;
  783. font-weight: 800;
  784. font-size: 1.5rem;
  785. text-align: center;
  786. letter-spacing: 0.3px;
  787. }
  788. .head-money-area {
  789. display: flex;
  790. width: 100%;
  791. justify-content: center;
  792. align-items: center;
  793. img {
  794. width: 4rem;
  795. height: 4rem;
  796. border: 2px solid #FFFFFF;
  797. border-radius: 100px;
  798. }
  799. span {
  800. margin-left: 1.3rem;
  801. font-size: 4.6rem;
  802. }
  803. }
  804. }
  805. }
  806. .luck-list-title {
  807. /* margin-top: 47px;*/
  808. margin: 0 16px;
  809. padding: 14px 0 11px 0;
  810. background: #fff;
  811. display: flex;
  812. justify-content: space-between;
  813. color: #B0B0B0;
  814. border-bottom: 1px solid #D1D1D1;
  815. }
  816. .luck-list {
  817. background: #fff;
  818. overflow: auto;
  819. .luck-item {
  820. display: flex;
  821. padding: 12px 0;
  822. margin: 0 16px;
  823. border-bottom: 1px solid #d1d1d1;
  824. justify-content: space-between;
  825. position: relative;
  826. img:first-child {
  827. border-radius: 50%;
  828. }
  829. .luck-king {
  830. position: absolute;
  831. top: 36px;
  832. right: 0px;
  833. display: flex;
  834. align-items: center;
  835. img {
  836. width: 22px;
  837. height: 19px;
  838. margin: 0;
  839. }
  840. span {
  841. font-weight: 500;
  842. font-size: 12px;
  843. line-height: 14px;
  844. letter-spacing: 0.3px;
  845. color: #f5b945;
  846. }
  847. }
  848. img {
  849. width: 42px;
  850. height: 42px;
  851. margin-right: 12px;
  852. }
  853. .luck-content {
  854. flex: auto;
  855. .luck-title {
  856. font-weight: 500;
  857. font-size: 16px;
  858. letter-spacing: 0.3px;
  859. color: #444444;
  860. }
  861. .luck-time {
  862. font-weight: 400;
  863. font-size: 12px;
  864. line-height: 14px;
  865. color: #9b9b9b;
  866. }
  867. }
  868. .luck-money {
  869. display: flex;
  870. height: 17px;
  871. align-items: center;
  872. img {
  873. width: 14px;
  874. height: 14px;
  875. margin-right: 6px;
  876. }
  877. .luck-money-txt {
  878. font-weight: 500;
  879. font-size: 14px;
  880. /* identical to box height */
  881. text-align: right;
  882. letter-spacing: 0.3px;
  883. color: #444444;
  884. }
  885. }
  886. }
  887. .luck-item:last-child {
  888. border: 0;
  889. }
  890. }
  891. .area {
  892. position: absolute;
  893. z-index: 112;
  894. width: 100%;
  895. .title {
  896. z-index: 11;
  897. margin-top: 8.5rem;
  898. text-align: center;
  899. img {
  900. width: 3.6rem;
  901. height: 3.6rem;
  902. border: 2px solid #fff4db;
  903. border-radius: 50%;
  904. }
  905. span {
  906. letter-spacing: 0.3px;
  907. font-size: 1.6rem;
  908. color: #fff2d3;
  909. }
  910. }
  911. .txt {
  912. font-size: 4rem;
  913. text-align: center;
  914. letter-spacing: 0.03rem;
  915. color: #fff2d3;
  916. }
  917. }
  918. .key_area {
  919. animation: key_area 1s;
  920. animation-delay: 1s;
  921. animation-fill-mode: forwards;
  922. }
  923. }
  924. .redPacket2 {
  925. left: 30.6rem;
  926. margin-left: -18rem;
  927. }
  928. .key_install {
  929. opacity: 0;
  930. animation: key_install 2s;
  931. animation-delay: 0s;
  932. animation-fill-mode: forwards;
  933. }
  934. .install {
  935. position: absolute;
  936. top: 20rem;
  937. left: 78.5rem;
  938. .title {
  939. font-size: 4.8rem;
  940. color: #000000;
  941. letter-spacing: 0.3px;
  942. }
  943. .validity {
  944. margin-top: 1rem;
  945. color: #FF0000;
  946. width: 40rem;
  947. height: 3.3rem;
  948. line-height: 3.3rem;
  949. span {
  950. font-size: 1.4rem;
  951. }
  952. }
  953. .flow {
  954. position: absolute;
  955. margin-top: 4rem;
  956. .line {
  957. position: absolute;
  958. height: 16rem;
  959. border: 1px solid #e0e0e0;
  960. top: 3rem;
  961. left: 1.2rem;
  962. }
  963. .area_num {
  964. display: flex;
  965. align-items: center;
  966. .num {
  967. width: 2.4rem;
  968. height: 2.4rem;
  969. background-color: rgba(56, 154, 255, 1);
  970. border-radius: 50%;
  971. color: #fff;
  972. text-align: center;
  973. line-height: 2.4rem;
  974. font-size: 1.4rem;
  975. }
  976. span {
  977. margin-left: 1.5rem;
  978. color: #000000;
  979. font-size: 1.8rem;
  980. }
  981. }
  982. .tip {
  983. margin-left: 4rem;
  984. margin-top: 0.7rem;
  985. font-size: 1.4rem;
  986. color: #a4a4a4;
  987. }
  988. .install_btn {
  989. cursor: pointer;
  990. margin-left: 4rem;
  991. margin-top: 2rem;
  992. margin-bottom: 6.7rem;
  993. width: 23rem;
  994. height: 5.8rem;
  995. background: #389aff;
  996. border-radius: 10rem;
  997. color: #fff;
  998. line-height: 5.8rem;
  999. text-align: center;
  1000. font-size: 2rem;
  1001. }
  1002. }
  1003. .tip {
  1004. margin-top: 0.7rem;
  1005. font-size: 1.4rem;
  1006. color: #a4a4a4;
  1007. }
  1008. .install_btn {
  1009. cursor: pointer;
  1010. margin-top: 2rem;
  1011. margin-bottom: 6.7rem;
  1012. width: 23rem;
  1013. height: 5.8rem;
  1014. background: #389aff;
  1015. border-radius: 10rem;
  1016. color: #fff;
  1017. line-height: 5.8rem;
  1018. text-align: center;
  1019. font-size: 2rem;
  1020. }
  1021. }
  1022. .install-error {
  1023. left: 78.5rem;
  1024. .install_chrome {
  1025. cursor: pointer;
  1026. width: 24.3rem;
  1027. height: 5.8rem;
  1028. font-size: 2rem;
  1029. font-weight: 500;
  1030. letter-spacing: 0.3px;
  1031. display: flex;
  1032. align-items: center;
  1033. background: #FFFFFF;
  1034. border: 1px solid #e8e8e8;
  1035. border-radius: 10rem;
  1036. margin-top: 3.3rem;
  1037. img {
  1038. width: 3.2rem;
  1039. height: 3.2rem;
  1040. margin-left: 3.3rem;
  1041. }
  1042. span {
  1043. margin-left: 1.2rem;
  1044. }
  1045. }
  1046. }
  1047. }
  1048. @keyframes key_area {
  1049. 0% {
  1050. opacity: 1;
  1051. }
  1052. 100% {
  1053. opacity: 0;
  1054. }
  1055. }
  1056. @keyframes key_install {
  1057. 0% {
  1058. opacity: 0;
  1059. }
  1060. 100% {
  1061. opacity: 1;
  1062. }
  1063. }
  1064. @keyframes key_packet {
  1065. 0% {}
  1066. 100% {
  1067. left: 30.6rem;
  1068. margin-left: -18rem;
  1069. }
  1070. }
  1071. </style>