popup.vue 32 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975
  1. <template>
  2. <div class="page-wrapper" ref="pageWrapperDom" @scroll="pageScroll">
  3. <template v-if="isLogin && homeVisibility">
  4. <v-head :show_more="true" :show_state="'home'" :user_info="userInfo"></v-head>
  5. <div class="content">
  6. <div class="balance">
  7. <div class="wallet">
  8. <img :src="require('@/assets/svg/icon-home-wallet.svg')" />
  9. <font>Balance Valuation</font>
  10. </div>
  11. <div class="bill" @click="showTransactions">
  12. <red-dot class="red-dot" v-if="unReadCountWallet > 0"></red-dot>
  13. <img :src="require('@/assets/svg/icon-home-bill.svg')" />
  14. </div>
  15. </div>
  16. <div class="amount">${{ canWithdrawBalance }}</div>
  17. <div class="area-btn">
  18. <div class="withdraw-btn" @click="clickWithdraw">Withdraw</div>
  19. <div class="top-up-btn" @click="clickTopUp">Deposit</div>
  20. </div>
  21. </div>
  22. <div class="tab-bar">
  23. <div class="tab-item"
  24. :class="{ active: currentTabIndex == index }"
  25. v-for="(item, index) in tabList"
  26. :key="index"
  27. @click="clickTab(item, index)">
  28. <img :src="item.icon" class="icon" />
  29. {{ item.label }}
  30. </div>
  31. </div>
  32. <div class="list-wrapper" ref="pageGiveListDom">
  33. <div class="give-list" v-if="currentTabIndex == 0">
  34. <template v-if="giveList.length">
  35. <div class="cell"
  36. :class="{'cell-center': item.type == 1}"
  37. v-for="(item, index) in giveList"
  38. :key="index"
  39. @click="clickListItem(item, index)">
  40. <red-dot class="red-dots"
  41. v-if="item.unReadMsgCount > 0"></red-dot>
  42. <div class="img-wrapper">
  43. <!-- 收到红包 -->
  44. <template v-if="item.type == 1">
  45. <img class="icon-avatar" :src="item.userInfo.avatarUrl" />
  46. <img class="icon-give" :src="
  47. require('@/assets/svg/icon-giveaways.svg')
  48. " />
  49. </template>
  50. <!-- 发出去红包 -->
  51. <template v-else-if="2">
  52. <img
  53. class="icon-big-give"
  54. :src="
  55. require('@/assets/svg/icon-list-big-give.svg')
  56. " />
  57. </template>
  58. </div>
  59. <div class="info-wrapper"
  60. :class="{'info-center': item.type == 1}">
  61. <div class="left">
  62. <div class="nickname">
  63. {{
  64. item.type == 1
  65. ? item.userInfo.nickName
  66. : "Giveaways"
  67. }}
  68. </div>
  69. <div class="time">
  70. {{
  71. moment(item.timestamp).format(
  72. "MM-DD HH:mm:ss"
  73. )
  74. }}
  75. </div>
  76. </div>
  77. <div class="right">
  78. <div class="msg">
  79. <div class="bold">
  80. <!-- 收到的 -->
  81. <template v-if="item.type == 1">
  82. <!-- 进行中-->
  83. <template v-if="item.status == 0">
  84. in progress
  85. </template>
  86. <!-- 已完成 -->
  87. <template v-else-if="item.status == 1">
  88. <span class="blance">{{ item.amount }}</span>
  89. <span class="coin-type">{{ item.currencySymbol || '' }}</span>
  90. <img :src="item.currencyIconPath" alt="">
  91. </template>
  92. <!-- 已过期 -->
  93. <template v-else-if="item.status == 2">
  94. Timeout
  95. </template>
  96. </template>
  97. <!-- 发出去的 -->
  98. <template v-else-if="item.type == 2">
  99. <span class="blance">-{{ item.amount }}</span>
  100. <span class="coin-type">{{ item.currencySymbol || '' }}</span>
  101. <img :src="item.currencyIconPath" alt="">
  102. </template>
  103. </div>
  104. <!-- 发出的红包显示 -->
  105. <div class="desc" v-if="item.type == 2">
  106. <!-- 未发送-->
  107. <template v-if="item.postTaskLuckdrop.reSendAvailable">
  108. Unpublished
  109. </template>
  110. <!-- 进行中 -->
  111. <template v-else-if="item.status == 1">
  112. {{item.postTaskLuckdrop.receivedCount}}/{{item.postTaskLuckdrop.totalCount}}
  113. </template>
  114. <!-- 2:已结束; 3:提前终止-->
  115. <template v-else-if="item.status == 2 || item.status == 3">
  116. ({{item.status == 2 ? 'Time expired' : 'Termination'}})
  117. {{
  118. item.postTaskLuckdrop
  119. .receivedCount
  120. }}/{{
  121. item.postTaskLuckdrop
  122. .totalCount
  123. }}
  124. </template>
  125. <!-- 红包提前终止/退款(进行中)显示-->
  126. <template v-if="item.status == 4">
  127. Terminating
  128. </template>
  129. <!-- 进行中或者未发送成功时显示
  130. v-if="item.status == 1 || item.postTaskLuckdrop.reSendAvailable"-->
  131. <div class="desc-bottom-bar">
  132. <!-- 没有终止红包时显示 -->
  133. <div v-if="item.postTaskLuckdrop.terminatedAvailable"
  134. class="btn"
  135. @click.stop="terminaHandler(item, index)">
  136. Termination
  137. </div>
  138. <!-- 红包未发出显示 -->
  139. <div class="btn send-btn"
  140. v-if="item.postTaskLuckdrop.reSendAvailable"
  141. @click.stop="sendTwitter(item)">
  142. Send
  143. </div>
  144. <div v-else-if="item.srcContentId"
  145. class="btn detail-btn"
  146. @click.stop="clickListItem(item, index)">details</div>
  147. </div>
  148. </div>
  149. </div>
  150. <!-- 发红包—— 未发出、进行中 隐藏 -->
  151. <img v-if="item.type != 2"
  152. class="icon"
  153. :src="require('@/assets/svg/icon-cell-arrow-right.svg')" />
  154. </div>
  155. </div>
  156. </div>
  157. </template>
  158. <template v-else>
  159. <img class="icon-empty" :src="require('@/assets/svg/icon-empty-list.svg')" />
  160. </template>
  161. </div>
  162. <div class="more-list" v-else>
  163. <div class="cell"
  164. v-for="(item, index) in moreTabList"
  165. :key="index"
  166. @click="moreItemHandle(item)">
  167. <img class="icon" :src="item.icon" />
  168. <div class="info-wrapper">
  169. <div class="left">
  170. {{ item.label }}
  171. </div>
  172. <div class="right">
  173. <img class="icon" :src="
  174. require('@/assets/svg/icon-cell-arrow-right.svg')
  175. " />
  176. </div>
  177. </div>
  178. </div>
  179. </div>
  180. </div>
  181. </template>
  182. <!-- login -->
  183. <popup-login v-if="!isLogin" @loginAction="loginAction" />
  184. <template v-if="isLogin && !homeVisibility">
  185. <!-- 交易列表 -->
  186. <popup-transactions v-if="transactionsVisibility" @back="transactionsBack" />
  187. <!-- 提现页 -->
  188. <popup-withdraw :amountValue="canWithdrawBalance" :walletWithdrawConfig="walletWithdrawConfig"
  189. v-if="withdrawVisibility" @back="withdrawBack" />
  190. </template>
  191. <modal :visible="modalVisible"
  192. title="Early termination of Giveaway?"
  193. content="This operation will close the red envelope and refund the remaining amount within 2 days"
  194. cancelText="Termination"
  195. confirmText="Cancel"
  196. @cancel="modalCancel"
  197. @confirm="modalConfirm" />
  198. </div>
  199. </template>
  200. <script setup>
  201. import { ref, onMounted, inject, onBeforeUnmount } from "vue";
  202. import popupLogin from "@/view/popup/components/login.vue";
  203. import popupTransactions from "@/view/components/popup-transactions";
  204. import popupWithdraw from "@/view/components/popup-withdraw.vue";
  205. import redDot from "@/view/components/red-dot.vue";
  206. import modal from "@/view/popup/components/modal.vue";
  207. import {
  208. getChromeStorage,
  209. } from "@/uilts/chromeExtension";
  210. import { getBalance, getMineLuckdropRecords } from "@/http/account";
  211. import { readAllMsgByType, getAllMessageInfo } from "@/http/messageApi"
  212. import { terminatedLuckdrop } from "@/http/redPacket";
  213. import { setBadgeInfo, hideBadge } from "@/logic/background/twitter";
  214. import Report from "@/log-center/log";
  215. import router from "@/router/popup.js";
  216. import VHead from '@/view/popup/components/head.vue'
  217. let withdraw_info = inject('withdraw_info')
  218. withdraw_info.paypal = {}
  219. var moment = require("moment");
  220. let pageWrapperDom = ref(null);
  221. let pageGiveListDom = ref(null);
  222. let isLogin = ref(false);
  223. let homeVisibility = ref(false);
  224. let transactionsVisibility = ref(false);
  225. let withdrawVisibility = ref(false);
  226. let modalVisible = ref(false);
  227. let terminaTask = {};
  228. let userInfo = ref({});
  229. let canWithdrawBalance = ref(0);
  230. withdraw_info.paypal.amount_value = canWithdrawBalance
  231. withdraw_info.balance = 0
  232. let isRequestWithdrawBalance = ref(false);
  233. let currentTabIndex = ref(0);
  234. let giveList = ref([]);
  235. // 钱包未读数
  236. let unReadCountWallet = ref(0);
  237. let giveReqParams = {
  238. params: {
  239. pageNum: 1,
  240. pageSize: 10,
  241. },
  242. loadMore: false,
  243. };
  244. let walletWithdrawConfig = ref({
  245. withdrawUSDPaypalFee: 0,
  246. withdrawUSDPreMinAmount: 100,
  247. withdrawUSDSwitch: "",
  248. withdrawUSDPaypalFeeDesc: ''
  249. });
  250. withdraw_info.paypal.wallet_withdraw_config = walletWithdrawConfig
  251. let moreTabList = ref([
  252. {
  253. icon: require("@/assets/svg/icon-twitter.svg"),
  254. label: "Twitter",
  255. href: 'https://twitter.com/denet2022'
  256. }
  257. // , {
  258. // icon: require("@/assets/svg/icon-discord.svg"),
  259. // label: "Discord",
  260. // href: 'https://discord.gg/wZSz9p8ddG'
  261. // }, {
  262. // icon: require("@/assets/svg/icon-telegram.svg"),
  263. // label: "Telegram",
  264. // href: 'https://t.me/denetpro'
  265. // }
  266. ]);
  267. let tabList = ref([
  268. {
  269. icon: require("@/assets/svg/icon-giveaways.svg"),
  270. label: "Giveaways",
  271. },
  272. {
  273. icon: require("@/assets/svg/icon-more.svg"),
  274. label: "More",
  275. },
  276. ]);
  277. onMounted(() => {
  278. checkLoginState(() => {
  279. if (isLogin.value) {
  280. getAccountBalance();
  281. getLuckdropRecordsList();
  282. chrome.runtime.connect({ name: "popup" });
  283. Report.reportLog({
  284. pageSource: Report.pageSource.denetHomePage,
  285. businessType: Report.businessType.pageView,
  286. },{
  287. type: window.location.href.indexOf('home.html') > -1 ? 'web' : 'extensions'
  288. });
  289. } else {
  290. Report.reportLog({
  291. pageSource: Report.pageSource.denetLogin,
  292. businessType: Report.businessType.pageView,
  293. });
  294. }
  295. });
  296. setMessageCount();
  297. setTimeout(() => {
  298. setMessageCount();
  299. }, 1600)
  300. });
  301. onBeforeUnmount(() => {
  302. readAllMsgByType({
  303. params: {
  304. msgType: 1
  305. }
  306. }).then(res => {
  307. setMessageCount();
  308. })
  309. });
  310. const setMessageCount = () => {
  311. getAllMessageInfo({params: {
  312. }}).then(res => {
  313. if(res.code == 0) {
  314. let {unReadCountTotal = 0, unReadCountWalletDetail = 0, unReadCountTaskLuckdrop = 0} = res.data;
  315. unReadCountWallet.value = unReadCountWalletDetail;
  316. if(unReadCountTotal > 0) {
  317. let text = unReadCountTotal > 99 ? '99+' : unReadCountTotal+'';
  318. setBadgeInfo({data: {text}});
  319. } else {
  320. hideBadge();
  321. }
  322. }
  323. });
  324. }
  325. const moreItemHandle = (params) => {
  326. window.open(params.href);
  327. }
  328. /**
  329. * 获取账户余额
  330. */
  331. const getAccountBalance = () => {
  332. isRequestWithdrawBalance.value = false;
  333. getBalance({}).then((res) => {
  334. isRequestWithdrawBalance.value = true;
  335. if (res.code == 0) {
  336. if (res.data) {
  337. canWithdrawBalance.value = res.data.allAssetValuationUSD;
  338. withdraw_info.balance = res.data.allAssetValuationUSD || 0
  339. }
  340. }
  341. });
  342. };
  343. const getUserInfo = (cb) => {
  344. getChromeStorage("userInfo", (res) => {
  345. cb && cb(res);
  346. });
  347. };
  348. /**
  349. * 检查登录状态
  350. */
  351. const checkLoginState = (cb) => {
  352. getUserInfo((res) => {
  353. if (res && res.accessToken) {
  354. userInfo.value = res;
  355. isLogin.value = true;
  356. homeVisibility.value = true;
  357. } else {
  358. userInfo.value = {};
  359. isLogin.value = false;
  360. }
  361. cb && cb();
  362. });
  363. };
  364. const pageScroll = (e) => {
  365. let wrapperHeight = pageWrapperDom.value.offsetHeight;
  366. let pageGiveListHeight = pageGiveListDom.value.offsetHeight;
  367. let scrollTop = e.target.scrollTop || 0;
  368. if (currentTabIndex.value != 0) {
  369. return;
  370. }
  371. if (
  372. giveReqParams.loadMore === false &&
  373. wrapperHeight + scrollTop >= pageGiveListHeight
  374. ) {
  375. giveReqParams.loadMore = true;
  376. giveReqParams.params.pageNum++;
  377. getLuckdropRecordsList();
  378. }
  379. };
  380. /**
  381. * 获取红包列表
  382. */
  383. const getLuckdropRecordsList = () => {
  384. getMineLuckdropRecords({
  385. params: giveReqParams.params,
  386. }).then((res) => {
  387. if (res.data && res.data.length) {
  388. if (giveReqParams.params.pageNum < 2) {
  389. giveList.value = res.data;
  390. } else {
  391. let data = giveList.value;
  392. data = data.concat(res.data);
  393. giveList.value = data;
  394. }
  395. giveReqParams.loadMore = false;
  396. }
  397. });
  398. };
  399. const clickTab = (params, index) => {
  400. currentTabIndex.value = index;
  401. console.log(params, index);
  402. };
  403. /**
  404. * 点击列表跳转到推文
  405. */
  406. const clickListItem = (params) => {
  407. if (!params.srcContentId) {
  408. return;
  409. }
  410. let twitterUrl = "https://twitter.com/";
  411. let nickName = "";
  412. if (params.type == 1) {
  413. nickName = params.userInfo.nickName;
  414. } else if (params.type == 2) {
  415. nickName = userInfo.value.nickName;
  416. }
  417. let url = twitterUrl + nickName + "/status/" + params.srcContentId;
  418. chrome.tabs.create({
  419. url,
  420. });
  421. };
  422. /**
  423. * 交易列表返回
  424. */
  425. const transactionsBack = () => {
  426. if (!homeVisibility.value) {
  427. if (transactionsVisibility.value) {
  428. transactionsVisibility.value = false;
  429. }
  430. homeVisibility.value = true;
  431. }
  432. };
  433. /**
  434. * 提现返回
  435. */
  436. const withdrawBack = () => {
  437. if (!homeVisibility.value) {
  438. if (withdrawVisibility.value) {
  439. withdrawVisibility.value = false;
  440. }
  441. homeVisibility.value = true;
  442. getAccountBalance();
  443. giveReqParams.params.pageNum = 1;
  444. getLuckdropRecordsList();
  445. }
  446. };
  447. const showTransactions = () => {
  448. // // homeVisibility.value = false;
  449. // // transactionsVisibility.value = true;
  450. router.push('/transactions')
  451. };
  452. // const clickWithdraw = () => {
  453. // if (isRequestWithdrawBalance.value) {
  454. // homeVisibility.value = false;
  455. // withdrawVisibility.value = true;
  456. // }
  457. // };
  458. const loginAction = () => {
  459. Report.reportLog({
  460. pageSource: Report.pageSource.denetLogin,
  461. businessType: Report.businessType.buttonClick,
  462. objectType: Report.objectType.loginButton
  463. });
  464. login();
  465. };
  466. const login = () => {
  467. callEventPageMethod("POPUP_LOGIN", "", function (response) {
  468. console.log("res", response);
  469. });
  470. };
  471. /**
  472. * sendMessage
  473. */
  474. const callEventPageMethod = (actionType, data, callback) => {
  475. chrome.runtime.sendMessage(
  476. {
  477. actionType: actionType,
  478. data: data
  479. },
  480. function (response) {
  481. if (typeof callback === "function") callback(response);
  482. }
  483. );
  484. };
  485. /**
  486. * 点击发送,去发推
  487. */
  488. const sendTwitter = (params) => {
  489. console.log(params)
  490. callEventPageMethod(
  491. "POPUP_PUBLISH_TWITTER_RED_PACK",
  492. {
  493. srcContent: params.postTaskLuckdrop.srcContent,
  494. postId: params.postTaskLuckdrop.postId
  495. },
  496. function (response) {
  497. console.log("res", response);
  498. }
  499. );
  500. };
  501. // 点击提现
  502. const clickWithdraw = () => {
  503. Report.reportLog({
  504. pageSource: Report.pageSource.denetHomePage,
  505. businessType: Report.businessType.buttonClick,
  506. objectType: Report.objectType.withdrawButton
  507. });
  508. router.push('/withdraw/home');
  509. }
  510. const clickTopUp = () => {
  511. Report.reportLog({
  512. pageSource: Report.pageSource.denetHomePage,
  513. businessType: Report.businessType.buttonClick,
  514. objectType: Report.objectType.topupButton
  515. });
  516. router.push('/top-up/home');
  517. }
  518. const terminaHandler = (params, index) => {
  519. terminaTask = params;
  520. terminaTask.index = index;
  521. modalVisible.value = true;
  522. }
  523. const modalCancel = () => {
  524. //请求终止接口 id terminaTask.id 、 刷新当前列表、 关闭
  525. modalVisible.value = false;
  526. let index = terminaTask.index;
  527. terminatedLuckdrop({
  528. params: {
  529. luckdropId: terminaTask.id
  530. }
  531. }).then(res => {
  532. if(res.code == 0) {
  533. giveList.value[index]['status'] = res.data.status;
  534. giveList.value[index]['postTaskLuckdrop']['reSendAvailable'] = false;
  535. giveList.value[index]['postTaskLuckdrop']['terminatedAvailable'] = false;
  536. }
  537. });
  538. terminaTask = {};
  539. }
  540. const modalConfirm = () => {
  541. modalVisible.value = false;
  542. terminaTask = {};
  543. }
  544. </script>
  545. <style lang="scss">
  546. html,
  547. body {
  548. padding: 0 !important;
  549. margin: 0 !important;
  550. }
  551. .page-wrapper {
  552. width: 375px;
  553. height: 600px;
  554. box-sizing: border-box;
  555. overflow-y: scroll;
  556. .nav-bar {
  557. padding: 14px;
  558. box-sizing: border-box;
  559. display: flex;
  560. align-items: center;
  561. justify-content: space-between;
  562. .item {
  563. display: flex;
  564. align-items: center;
  565. font-size: 13px;
  566. cursor: pointer;
  567. img {
  568. width: 16px;
  569. height: 16px;
  570. margin-right: 4px;
  571. }
  572. }
  573. .left {
  574. font-weight: 500;
  575. }
  576. .right {
  577. color: #b6b6b6;
  578. }
  579. }
  580. .content {
  581. padding: 20px;
  582. background-color: #F0F8FE;
  583. .icon-money {
  584. width: 70px;
  585. height: 70px;
  586. }
  587. .balance {
  588. display: flex;
  589. justify-content: space-between;
  590. .wallet {
  591. img {
  592. width: 24px;
  593. height: 24px;
  594. margin-right: 6px;
  595. vertical-align: middle;
  596. }
  597. font {
  598. color: #000;
  599. font-size: 14px;
  600. font-weight: bold;
  601. }
  602. }
  603. .bill {
  604. position: relative;
  605. img {
  606. width: 24px;
  607. height: 24px;
  608. cursor: pointer;
  609. }
  610. .red-dot {
  611. position: absolute;
  612. right: 0px;
  613. top: -1px;
  614. }
  615. }
  616. }
  617. .amount {
  618. margin-top: 20px;
  619. margin-bottom: 20px;
  620. font-weight: 700;
  621. font-size: 36px;
  622. line-height: 43px;
  623. }
  624. .area-btn {
  625. display: flex;
  626. justify-content: space-between;
  627. font-weight: 600;
  628. font-size: 15px;
  629. .top-up-btn {
  630. cursor: pointer;
  631. border: 1px solid #1D9BF0;
  632. color: #fff;
  633. background: #1D9BF0;
  634. border-radius: 100px;
  635. width: 165px;
  636. height: 38px;
  637. text-align: center;
  638. margin-left: 8px;
  639. line-height: 36px;
  640. }
  641. .withdraw-btn {
  642. background: rgba(56, 154, 255, 0.01);
  643. border: 1px solid #1D9BF0;
  644. box-sizing: border-box;
  645. width: 165px;
  646. font-size: 15px;
  647. height: 38px;
  648. text-align: center;
  649. line-height: 36px;
  650. border-radius: 100px;
  651. color: #1D9BF0;
  652. display: inline-block;
  653. cursor: pointer;
  654. }
  655. }
  656. .msg {
  657. margin-top: 10px;
  658. font-size: 13px;
  659. color: #b6b6b6;
  660. }
  661. }
  662. .tab-bar {
  663. display: flex;
  664. align-items: center;
  665. position: sticky;
  666. position: -webkit-sticky;
  667. top: 0px;
  668. z-index: 1000;
  669. background-color: #fff;
  670. .tab-item {
  671. flex: 1;
  672. display: flex;
  673. align-items: center;
  674. justify-content: center;
  675. padding: 17px 0;
  676. box-sizing: border-box;
  677. border-bottom: 1px solid #ECECEC;
  678. cursor: pointer;
  679. .icon {
  680. width: 16px;
  681. height: 16px;
  682. margin-right: 5px;
  683. font-weight: 500;
  684. font-size: 16px;
  685. }
  686. }
  687. .active {
  688. border-bottom: 2px solid #000;
  689. }
  690. }
  691. .list-wrapper {
  692. min-height: 202px;
  693. .give-list {
  694. min-height: 202px;
  695. position: relative;
  696. .cell {
  697. display: flex;
  698. justify-content: space-between;
  699. min-height: 66px;
  700. box-sizing: border-box;
  701. padding-left: 14px;
  702. position: relative;
  703. cursor: pointer;
  704. .red-dots {
  705. position: absolute;
  706. right: 4px;
  707. top: 4px;
  708. }
  709. .img-wrapper {
  710. position: relative;
  711. margin-right: 16px;
  712. box-sizing: border-box;
  713. .icon-avatar {
  714. width: 34px;
  715. height: 34px;
  716. border-radius: 50%;
  717. }
  718. .icon-give {
  719. position: absolute;
  720. right: -4px;
  721. bottom: 2px;
  722. }
  723. .icon-big-give {
  724. margin-top: 14px;
  725. }
  726. }
  727. .info-wrapper {
  728. flex: 1;
  729. height: 100%;
  730. display: flex;
  731. justify-content: space-between;
  732. border-bottom: 1px solid #d1d1d1;
  733. box-sizing: border-box;
  734. padding: 10px 14px 10px 0;
  735. .left {
  736. .nickname {
  737. font-weight: 500;
  738. font-size: 14px;
  739. margin-bottom: 5px;
  740. }
  741. .time {
  742. font-size: 12px;
  743. color: #b6b6b6;
  744. }
  745. }
  746. .right {
  747. display: flex;
  748. align-items: center;
  749. cursor: pointer;
  750. .msg {
  751. .bold {
  752. font-weight: 500;
  753. font-size: 14px;
  754. text-align: right;
  755. display: flex;
  756. justify-content: flex-end;
  757. align-items: center;
  758. .blance {
  759. margin-left: 3px;
  760. display: inline-block;
  761. max-width: 68px;
  762. word-break: break-all;
  763. line-height: 18px;
  764. color: #E29A2E;
  765. }
  766. .coin-type {
  767. margin-left: 3px;
  768. }
  769. img {
  770. margin-left: 4px;
  771. width: 14px;
  772. height: 14px;
  773. }
  774. }
  775. .desc {
  776. font-size: 12px;
  777. color: #b6b6b6;
  778. margin-top: 5px;
  779. text-align: right;
  780. .desc-bottom-bar {
  781. display: flex;
  782. align-items: center;
  783. justify-content: end;
  784. margin-top: 10px;
  785. .btn {
  786. min-width: 80px;
  787. height: 29px;
  788. padding: 0 8px;
  789. box-sizing: border-box;
  790. font-weight: 400;
  791. font-size: 14px;
  792. cursor: pointer;
  793. text-align: center;
  794. border-radius: 100px;
  795. color: #5E5E5E;
  796. border: 1px solid #DFDFDF;
  797. display: flex;
  798. align-items: center;
  799. justify-content: center;
  800. }
  801. .send-btn {
  802. border: 1px solid #1D9BF0;
  803. color: #1D9BF0;
  804. }
  805. .detail-btn, .send-btn {
  806. margin-left: 8px;
  807. }
  808. }
  809. }
  810. }
  811. .icon {
  812. width: 18px;
  813. height: 24px;
  814. margin-left: 4px;
  815. margin-right: -5px;
  816. }
  817. }
  818. }
  819. .info-center {
  820. align-items: center;
  821. }
  822. }
  823. .cell-center {
  824. align-items: center;
  825. }
  826. .icon-empty {
  827. position: absolute;
  828. left: 50%;
  829. top: 50%;
  830. transform: translate(-50%, -50%);
  831. }
  832. }
  833. .more-list {
  834. .cell {
  835. cursor: pointer;
  836. display: flex;
  837. justify-content: space-between;
  838. align-items: center;
  839. height: 66px;
  840. box-sizing: border-box;
  841. padding-left: 20px;
  842. .icon {
  843. width: 42px;
  844. height: 42px;
  845. border-radius: 50%;
  846. }
  847. .info-wrapper {
  848. flex: 1;
  849. height: 100%;
  850. display: flex;
  851. justify-content: space-between;
  852. align-items: center;
  853. border-bottom: 1px solid #ECECEC;
  854. box-sizing: border-box;
  855. padding-right: 16px;
  856. .left {
  857. font-weight: 500;
  858. font-size: 16px;
  859. }
  860. .right {
  861. display: flex;
  862. align-items: center;
  863. cursor: pointer;
  864. .icon {
  865. width: 18px;
  866. height: 24px;
  867. }
  868. }
  869. }
  870. }
  871. }
  872. }
  873. }
  874. .page-wrapper::-webkit-scrollbar {
  875. display: none;
  876. }
  877. </style>