luckdraw.vue 35 KB

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