Compare commits
108 Commits
master
...
activityEn
Author | SHA1 | Date | |
---|---|---|---|
![]() |
7268190873 | ||
![]() |
91e59bff21 | ||
![]() |
c883736ea4 | ||
![]() |
624b83fc2d | ||
![]() |
aadf65466c | ||
![]() |
478a099803 | ||
![]() |
a322babef7 | ||
![]() |
b40eddf251 | ||
![]() |
172a9921ec | ||
![]() |
c69493e4ab | ||
![]() |
b05f1adfcc | ||
![]() |
52d11685bb | ||
![]() |
ed2f169f6a | ||
![]() |
bf5899833c | ||
![]() |
0f23b8ee6f | ||
![]() |
db5ef89f56 | ||
![]() |
68100ee167 | ||
![]() |
d4f136c1ac | ||
![]() |
780384d0d5 | ||
![]() |
e535319b32 | ||
![]() |
05f408f74d | ||
![]() |
ff61a47e39 | ||
![]() |
5cee1d8cde | ||
![]() |
22d253fc6a | ||
![]() |
193f6e5456 | ||
![]() |
e78bc9390f | ||
![]() |
30e1fb6b6a | ||
![]() |
f371007b8b | ||
![]() |
d4d0054289 | ||
![]() |
c5b322887d | ||
![]() |
538a60c0ff | ||
![]() |
ecba478f32 | ||
![]() |
aec6d87ddb | ||
![]() |
d634ba1260 | ||
![]() |
71b5fcb091 | ||
![]() |
7d64698e9c | ||
![]() |
89a3015749 | ||
![]() |
1c73b95f90 | ||
71573cefe4 | |||
![]() |
a7b09ffb8b | ||
![]() |
1558790f93 | ||
![]() |
98c4b0ef19 | ||
![]() |
4ec1f8e35b | ||
![]() |
d362520ed8 | ||
![]() |
04cacb6a7b | ||
![]() |
b21160d81e | ||
![]() |
967d8260b1 | ||
![]() |
69ed189cef | ||
1aaf074667 | |||
0c90819cfc | |||
967babba88 | |||
![]() |
f527671049 | ||
![]() |
e2648d912f | ||
55d8758ecc | |||
a894374fb5 | |||
![]() |
21cfb8daaa | ||
![]() |
dd84bf9d67 | ||
![]() |
4d74b0dac2 | ||
8bed0c5940 | |||
![]() |
c34d8d6da9 | ||
![]() |
80fb1e1a20 | ||
![]() |
25487b41c8 | ||
![]() |
89b1af7926 | ||
![]() |
ddc04eed65 | ||
![]() |
0524ae5df5 | ||
![]() |
e8f42fb4ae | ||
![]() |
0b9c650854 | ||
![]() |
834479325d | ||
![]() |
a82dfb603c | ||
![]() |
893c9dfae6 | ||
![]() |
97b8af0ead | ||
![]() |
bed6ac4211 | ||
![]() |
bce76af641 | ||
![]() |
74db65752d | ||
![]() |
417684178e | ||
![]() |
3d5cfc34ed | ||
![]() |
6fecc3aa04 | ||
![]() |
efa0f668d6 | ||
![]() |
1ea8a0dcc5 | ||
![]() |
8218871fd8 | ||
![]() |
dd5d3136d8 | ||
![]() |
044e476c9a | ||
![]() |
b73c078aca | ||
![]() |
dc1ceb506a | ||
![]() |
b2db3214ac | ||
![]() |
7f3002fd62 | ||
![]() |
b0e76587ff | ||
![]() |
a49cadd14f | ||
![]() |
5f0e7816e2 | ||
![]() |
8c8944dd2f | ||
![]() |
6c5e45f7c7 | ||
![]() |
87c1ee2c7f | ||
![]() |
d971c0e4b6 | ||
![]() |
81c6dc88ea | ||
![]() |
9f010d6bf4 | ||
![]() |
b46bede28f | ||
![]() |
468dc301da | ||
![]() |
cbc52879f5 | ||
![]() |
5e99c8bce0 | ||
![]() |
2b259dafb9 | ||
![]() |
c488a21a68 | ||
![]() |
af50b80479 | ||
![]() |
6faa71cba5 | ||
![]() |
7ed3911a9c | ||
![]() |
dc523994d4 | ||
![]() |
b78c513977 | ||
![]() |
47c5e4c782 | ||
![]() |
7e7bcb9973 |
@ -17,6 +17,8 @@ VUE_APP_CHAIN_ID = '5611'
|
||||
|
||||
VUE_APP_APP_NAME = 'CF UAW'
|
||||
|
||||
VUE_APP_MODE = 'development'
|
||||
|
||||
# 铭文的验证地址
|
||||
VUE_APP_SCRIPTION_ADDRESS='0xcd4bb3402f1a444a1af10f31946ed37dac0eac4d'
|
||||
# VUE_APP_SCRIPTION_ADDRESS='0x50A8e60041A206AcaA5F844a1104896224be6F39'
|
||||
|
@ -1,5 +1,5 @@
|
||||
# API
|
||||
VUE_APP_API_URL = 'https://oauth-svr.cebggame.com/task'
|
||||
VUE_APP_API_URL = 'https://taskapi.cebggame.com'
|
||||
VUE_APP_WL_URL = 'https://nftwl.counterfire.games/wl_test'
|
||||
VUE_APP_CONFIG_URL = 'https://sepolia.infura.io/v3/b6bf7d3508c941499b10025c0776eaf8'
|
||||
|
||||
@ -11,9 +11,11 @@ VUE_APP_NFT_URL = '0x59e751c2037B710090035B6ea928e0cce80aC03f'
|
||||
# BEB合约
|
||||
VUE_APP_BEB_URL = '0x1304E6AA241eE3C9ea44Db9e593e85Ae76eC41F1'
|
||||
|
||||
VUE_APP_CHAIN_ID = '5611'
|
||||
VUE_APP_CHAIN_ID = '204'
|
||||
|
||||
VUE_APP_APP_NAME = 'CF UAW'
|
||||
|
||||
VUE_APP_MODE = 'production'
|
||||
|
||||
VUE_APP_SCRIPTION_ADDRESS='0xcd4bb3402f1a444a1af10f31946ed37dac0eac4d'
|
||||
VUE_APP_CONTRACT='0x0Fd13D2CD0B6c679B6f92590E0b91C18DDe7BD3A'
|
||||
VUE_APP_CONTRACT='0x03B6f01EB419915B1F157e67C8263101ddd6E15e'
|
BIN
dist-prod.zip
Normal file
236
package-lock.json
generated
@ -1,13 +1,14 @@
|
||||
{
|
||||
"name": "uawgame",
|
||||
"version": "0.1.0",
|
||||
"version": "0.1.1",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "uawgame",
|
||||
"version": "0.1.0",
|
||||
"version": "0.1.1",
|
||||
"dependencies": {
|
||||
"@cloudcare/browser-rum": "^3.1.11",
|
||||
"@walletconnect/ethereum-provider": "^2.11.2",
|
||||
"@walletconnect/modal": "^2.6.2",
|
||||
"axios": "^1.6.8",
|
||||
@ -15,11 +16,15 @@
|
||||
"core-js": "^3.8.3",
|
||||
"crypto-js": "^4.2.0",
|
||||
"element-ui": "^2.15.14",
|
||||
"google-auth-library": "^9.9.0",
|
||||
"js-cookie": "^3.0.5",
|
||||
"moment": "^2.30.1",
|
||||
"postcss-px-to-viewport": "^1.1.1",
|
||||
"swiper": "^5.4.5",
|
||||
"vue": "^2.6.14",
|
||||
"vue-google-oauth2": "^1.5.10",
|
||||
"vue-google-signin-button-directive": "^1.0.3",
|
||||
"vue-gtag": "^1.16.1",
|
||||
"vue-loader": "^15.10.1",
|
||||
"vue-router": "^3.5.1",
|
||||
"vuex": "^3.6.2",
|
||||
@ -38,6 +43,7 @@
|
||||
"eslint-plugin-vue": "^8.0.3",
|
||||
"sass": "^1.32.7",
|
||||
"sass-loader": "^12.0.0",
|
||||
"source-map-loader": "^5.0.0",
|
||||
"vue-template-compiler": "^2.6.14"
|
||||
}
|
||||
},
|
||||
@ -1850,6 +1856,28 @@
|
||||
"node": ">=6.9.0"
|
||||
}
|
||||
},
|
||||
"node_modules/@cloudcare/browser-core": {
|
||||
"version": "3.1.11",
|
||||
"resolved": "https://registry.npmmirror.com/@cloudcare/browser-core/-/browser-core-3.1.11.tgz",
|
||||
"integrity": "sha512-GX5UIyvznSIO11N2DCaHL7NcniogMYAo7f7AQKDIgGKpFM9s6QspwY43XituUC8veSBvlSiPdE72MTCJF9ACxA=="
|
||||
},
|
||||
"node_modules/@cloudcare/browser-rum": {
|
||||
"version": "3.1.11",
|
||||
"resolved": "https://registry.npmmirror.com/@cloudcare/browser-rum/-/browser-rum-3.1.11.tgz",
|
||||
"integrity": "sha512-zVNV0TxpIhiC18ge3Gjqiuep5Z3VB8uJdFDtSSoKac/2nFUnILQGE7MMunIbA4yATOy2UzDqDIbcHH3a2DK1Kw==",
|
||||
"dependencies": {
|
||||
"@cloudcare/browser-core": "3.1.11",
|
||||
"@cloudcare/browser-worker": "3.1.11"
|
||||
}
|
||||
},
|
||||
"node_modules/@cloudcare/browser-worker": {
|
||||
"version": "3.1.11",
|
||||
"resolved": "https://registry.npmmirror.com/@cloudcare/browser-worker/-/browser-worker-3.1.11.tgz",
|
||||
"integrity": "sha512-Rs1Nvb/38DmSX12TRHTgr6GjeUEWwkNrJLFPSohiOjEZVhq5gVVk/r3vutRs3hCaKW1Fh++ouMECzh1vp2rywA==",
|
||||
"dependencies": {
|
||||
"@cloudcare/browser-core": "3.1.11"
|
||||
}
|
||||
},
|
||||
"node_modules/@discoveryjs/json-ext": {
|
||||
"version": "0.5.7",
|
||||
"resolved": "https://registry.npmmirror.com/@discoveryjs/json-ext/-/json-ext-0.5.7.tgz",
|
||||
@ -4494,6 +4522,17 @@
|
||||
"node": ">= 10.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/agent-base": {
|
||||
"version": "7.1.1",
|
||||
"resolved": "https://registry.npmmirror.com/agent-base/-/agent-base-7.1.1.tgz",
|
||||
"integrity": "sha512-H0TSyFNDMomMNJQBn8wFV5YC/2eJ+VXECwOadZJT554xP6cODZHPX3H9QMQECxvrgiSOP1pHjy1sMWQVYJOUOA==",
|
||||
"dependencies": {
|
||||
"debug": "^4.3.4"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 14"
|
||||
}
|
||||
},
|
||||
"node_modules/aggregate-error": {
|
||||
"version": "3.1.0",
|
||||
"resolved": "https://registry.npmmirror.com/aggregate-error/-/aggregate-error-3.1.0.tgz",
|
||||
@ -4940,8 +4979,7 @@
|
||||
"node_modules/base64-js": {
|
||||
"version": "1.5.1",
|
||||
"resolved": "https://registry.npmmirror.com/base64-js/-/base64-js-1.5.1.tgz",
|
||||
"integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==",
|
||||
"dev": true
|
||||
"integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA=="
|
||||
},
|
||||
"node_modules/batch": {
|
||||
"version": "0.6.1",
|
||||
@ -4957,6 +4995,14 @@
|
||||
"node": "*"
|
||||
}
|
||||
},
|
||||
"node_modules/bignumber.js": {
|
||||
"version": "9.1.2",
|
||||
"resolved": "https://registry.npmmirror.com/bignumber.js/-/bignumber.js-9.1.2.tgz",
|
||||
"integrity": "sha512-2/mKyZH9K85bzOEfhXDBFZTGd1CTs+5IHpeFQo9luiBG7hghdC851Pj2WAhb6E3R6b9tZj/XKhbg4fum+Kepug==",
|
||||
"engines": {
|
||||
"node": "*"
|
||||
}
|
||||
},
|
||||
"node_modules/binary-extensions": {
|
||||
"version": "2.3.0",
|
||||
"resolved": "https://registry.npmmirror.com/binary-extensions/-/binary-extensions-2.3.0.tgz",
|
||||
@ -5092,6 +5138,11 @@
|
||||
"ieee754": "^1.1.13"
|
||||
}
|
||||
},
|
||||
"node_modules/buffer-equal-constant-time": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmmirror.com/buffer-equal-constant-time/-/buffer-equal-constant-time-1.0.1.tgz",
|
||||
"integrity": "sha512-zRpUiDwd/xk6ADqPMATG8vc9VPrkck7T07OIx0gnjmJAnHnTVXNQG3vfvWNuiZIkwu9KrKdA1iJKfsfTVxE6NA=="
|
||||
},
|
||||
"node_modules/buffer-from": {
|
||||
"version": "1.1.2",
|
||||
"resolved": "https://registry.npmmirror.com/buffer-from/-/buffer-from-1.1.2.tgz",
|
||||
@ -6072,7 +6123,6 @@
|
||||
"version": "4.3.4",
|
||||
"resolved": "https://registry.npmmirror.com/debug/-/debug-4.3.4.tgz",
|
||||
"integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"ms": "2.1.2"
|
||||
},
|
||||
@ -6441,6 +6491,14 @@
|
||||
"node": ">=6.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/ecdsa-sig-formatter": {
|
||||
"version": "1.0.11",
|
||||
"resolved": "https://registry.npmmirror.com/ecdsa-sig-formatter/-/ecdsa-sig-formatter-1.0.11.tgz",
|
||||
"integrity": "sha512-nagl3RYrbNv6kQkeJIpt6NJZy8twLB/2vtz6yN9Z4vRKHN4/QZJIEbqohALSgwKdnksuY3k5Addp5lg8sVoVcQ==",
|
||||
"dependencies": {
|
||||
"safe-buffer": "^5.0.1"
|
||||
}
|
||||
},
|
||||
"node_modules/ee-first": {
|
||||
"version": "1.1.1",
|
||||
"resolved": "https://registry.npmmirror.com/ee-first/-/ee-first-1.1.1.tgz",
|
||||
@ -7252,6 +7310,11 @@
|
||||
"integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==",
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/extend": {
|
||||
"version": "3.0.2",
|
||||
"resolved": "https://registry.npmmirror.com/extend/-/extend-3.0.2.tgz",
|
||||
"integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g=="
|
||||
},
|
||||
"node_modules/fast-deep-equal": {
|
||||
"version": "3.1.3",
|
||||
"resolved": "https://registry.npmmirror.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz",
|
||||
@ -7563,6 +7626,49 @@
|
||||
"integrity": "sha512-dsKNQNdj6xA3T+QlADDA7mOSlX0qiMINjn0cgr+eGHGsbSHzTabcIogz2+p/iqP1Xs6EP/sS2SbqH+brGTbq0g==",
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/gaxios": {
|
||||
"version": "6.5.0",
|
||||
"resolved": "https://registry.npmmirror.com/gaxios/-/gaxios-6.5.0.tgz",
|
||||
"integrity": "sha512-R9QGdv8j4/dlNoQbX3hSaK/S0rkMijqjVvW3YM06CoBdbU/VdKd159j4hePpng0KuE6Lh6JJ7UdmVGJZFcAG1w==",
|
||||
"dependencies": {
|
||||
"extend": "^3.0.2",
|
||||
"https-proxy-agent": "^7.0.1",
|
||||
"is-stream": "^2.0.0",
|
||||
"node-fetch": "^2.6.9",
|
||||
"uuid": "^9.0.1"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=14"
|
||||
}
|
||||
},
|
||||
"node_modules/gaxios/node_modules/is-stream": {
|
||||
"version": "2.0.1",
|
||||
"resolved": "https://registry.npmmirror.com/is-stream/-/is-stream-2.0.1.tgz",
|
||||
"integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==",
|
||||
"engines": {
|
||||
"node": ">=8"
|
||||
}
|
||||
},
|
||||
"node_modules/gaxios/node_modules/uuid": {
|
||||
"version": "9.0.1",
|
||||
"resolved": "https://registry.npmmirror.com/uuid/-/uuid-9.0.1.tgz",
|
||||
"integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==",
|
||||
"bin": {
|
||||
"uuid": "dist/bin/uuid"
|
||||
}
|
||||
},
|
||||
"node_modules/gcp-metadata": {
|
||||
"version": "6.1.0",
|
||||
"resolved": "https://registry.npmmirror.com/gcp-metadata/-/gcp-metadata-6.1.0.tgz",
|
||||
"integrity": "sha512-Jh/AIwwgaxan+7ZUUmRLCjtchyDiqh4KjBJ5tW3plBZb5iL/BPcso8A5DlzeD9qlw0duCamnNdpFjxwaT0KyKg==",
|
||||
"dependencies": {
|
||||
"gaxios": "^6.0.0",
|
||||
"json-bigint": "^1.0.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=14"
|
||||
}
|
||||
},
|
||||
"node_modules/gensync": {
|
||||
"version": "1.0.0-beta.2",
|
||||
"resolved": "https://registry.npmmirror.com/gensync/-/gensync-1.0.0-beta.2.tgz",
|
||||
@ -7677,6 +7783,22 @@
|
||||
"node": ">= 4"
|
||||
}
|
||||
},
|
||||
"node_modules/google-auth-library": {
|
||||
"version": "9.9.0",
|
||||
"resolved": "https://registry.npmmirror.com/google-auth-library/-/google-auth-library-9.9.0.tgz",
|
||||
"integrity": "sha512-9l+zO07h1tDJdIHN74SpnWIlNR+OuOemXlWJlLP9pXy6vFtizgpEzMuwJa4lqY9UAdiAv5DVd5ql0Am916I+aA==",
|
||||
"dependencies": {
|
||||
"base64-js": "^1.3.0",
|
||||
"ecdsa-sig-formatter": "^1.0.11",
|
||||
"gaxios": "^6.1.1",
|
||||
"gcp-metadata": "^6.1.0",
|
||||
"gtoken": "^7.0.0",
|
||||
"jws": "^4.0.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=14"
|
||||
}
|
||||
},
|
||||
"node_modules/gopd": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmmirror.com/gopd/-/gopd-1.0.1.tgz",
|
||||
@ -7690,6 +7812,18 @@
|
||||
"resolved": "https://registry.npmmirror.com/graceful-fs/-/graceful-fs-4.2.11.tgz",
|
||||
"integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ=="
|
||||
},
|
||||
"node_modules/gtoken": {
|
||||
"version": "7.1.0",
|
||||
"resolved": "https://registry.npmmirror.com/gtoken/-/gtoken-7.1.0.tgz",
|
||||
"integrity": "sha512-pCcEwRi+TKpMlxAQObHDQ56KawURgyAf6jtIY046fJ5tIv3zDe/LEIubckAO8fj6JnAxLdmWkUfNyulQ2iKdEw==",
|
||||
"dependencies": {
|
||||
"gaxios": "^6.0.0",
|
||||
"jws": "^4.0.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=14.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/gzip-size": {
|
||||
"version": "6.0.0",
|
||||
"resolved": "https://registry.npmmirror.com/gzip-size/-/gzip-size-6.0.0.tgz",
|
||||
@ -8026,6 +8160,18 @@
|
||||
"node": ">= 0.12.0"
|
||||
}
|
||||
},
|
||||
"node_modules/https-proxy-agent": {
|
||||
"version": "7.0.4",
|
||||
"resolved": "https://registry.npmmirror.com/https-proxy-agent/-/https-proxy-agent-7.0.4.tgz",
|
||||
"integrity": "sha512-wlwpilI7YdjSkWaQ/7omYBMTliDcmCN8OLihO6I9B86g06lMyAoqgoDpV0XqoaPOKj+0DIdAvnsWfyAAhmimcg==",
|
||||
"dependencies": {
|
||||
"agent-base": "^7.0.2",
|
||||
"debug": "4"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 14"
|
||||
}
|
||||
},
|
||||
"node_modules/human-signals": {
|
||||
"version": "2.1.0",
|
||||
"resolved": "https://registry.npmmirror.com/human-signals/-/human-signals-2.1.0.tgz",
|
||||
@ -8518,6 +8664,14 @@
|
||||
"node": ">=4"
|
||||
}
|
||||
},
|
||||
"node_modules/json-bigint": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmmirror.com/json-bigint/-/json-bigint-1.0.0.tgz",
|
||||
"integrity": "sha512-SiPv/8VpZuWbvLSMtTDU8hEfrZWg/mH/nV/b4o0CYbSxu1UIQPLdwKOCIyLQX+VIPO5vrLX3i8qtqFyhdPSUSQ==",
|
||||
"dependencies": {
|
||||
"bignumber.js": "^9.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/json-buffer": {
|
||||
"version": "3.0.1",
|
||||
"resolved": "https://registry.npmmirror.com/json-buffer/-/json-buffer-3.0.1.tgz",
|
||||
@ -8574,6 +8728,25 @@
|
||||
"graceful-fs": "^4.1.6"
|
||||
}
|
||||
},
|
||||
"node_modules/jwa": {
|
||||
"version": "2.0.0",
|
||||
"resolved": "https://registry.npmmirror.com/jwa/-/jwa-2.0.0.tgz",
|
||||
"integrity": "sha512-jrZ2Qx916EA+fq9cEAeCROWPTfCwi1IVHqT2tapuqLEVVDKFDENFw1oL+MwrTvH6msKxsd1YTDVw6uKEcsrLEA==",
|
||||
"dependencies": {
|
||||
"buffer-equal-constant-time": "1.0.1",
|
||||
"ecdsa-sig-formatter": "1.0.11",
|
||||
"safe-buffer": "^5.0.1"
|
||||
}
|
||||
},
|
||||
"node_modules/jws": {
|
||||
"version": "4.0.0",
|
||||
"resolved": "https://registry.npmmirror.com/jws/-/jws-4.0.0.tgz",
|
||||
"integrity": "sha512-KDncfTmOZoOMTFG4mBlG0qUIOlc03fmzH+ru6RgYVZhPkyiy/92Owlt/8UEN+a4TXR1FQetfIpJE8ApdvdVxTg==",
|
||||
"dependencies": {
|
||||
"jwa": "^2.0.0",
|
||||
"safe-buffer": "^5.0.1"
|
||||
}
|
||||
},
|
||||
"node_modules/keyv": {
|
||||
"version": "4.5.4",
|
||||
"resolved": "https://registry.npmmirror.com/keyv/-/keyv-4.5.4.tgz",
|
||||
@ -9472,8 +9645,7 @@
|
||||
"node_modules/ms": {
|
||||
"version": "2.1.2",
|
||||
"resolved": "https://registry.npmmirror.com/ms/-/ms-2.1.2.tgz",
|
||||
"integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==",
|
||||
"dev": true
|
||||
"integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w=="
|
||||
},
|
||||
"node_modules/multicast-dns": {
|
||||
"version": "7.2.5",
|
||||
@ -11904,6 +12076,38 @@
|
||||
"node": ">=0.10.0"
|
||||
}
|
||||
},
|
||||
"node_modules/source-map-loader": {
|
||||
"version": "5.0.0",
|
||||
"resolved": "https://registry.npmjs.org/source-map-loader/-/source-map-loader-5.0.0.tgz",
|
||||
"integrity": "sha512-k2Dur7CbSLcAH73sBcIkV5xjPV4SzqO1NJ7+XaQl8if3VODDUj3FNchNGpqgJSKbvUfJuhVdv8K2Eu8/TNl2eA==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"iconv-lite": "^0.6.3",
|
||||
"source-map-js": "^1.0.2"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 18.12.0"
|
||||
},
|
||||
"funding": {
|
||||
"type": "opencollective",
|
||||
"url": "https://opencollective.com/webpack"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"webpack": "^5.72.1"
|
||||
}
|
||||
},
|
||||
"node_modules/source-map-loader/node_modules/iconv-lite": {
|
||||
"version": "0.6.3",
|
||||
"resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz",
|
||||
"integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"safer-buffer": ">= 2.1.2 < 3.0.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=0.10.0"
|
||||
}
|
||||
},
|
||||
"node_modules/source-map-support": {
|
||||
"version": "0.5.21",
|
||||
"resolved": "https://registry.npmmirror.com/source-map-support/-/source-map-support-0.5.21.tgz",
|
||||
@ -12992,6 +13196,24 @@
|
||||
"integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==",
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/vue-google-oauth2": {
|
||||
"version": "1.5.10",
|
||||
"resolved": "https://registry.npmmirror.com/vue-google-oauth2/-/vue-google-oauth2-1.5.10.tgz",
|
||||
"integrity": "sha512-0+ZGbauhkBhvTln2RPyeaSvRdrka194h+MeEQngy1H4UvGOC5hxRMB8QvUrVRP/w2Tt8/ByCqGDko6MuHpFpbQ=="
|
||||
},
|
||||
"node_modules/vue-google-signin-button-directive": {
|
||||
"version": "1.0.3",
|
||||
"resolved": "https://registry.npmmirror.com/vue-google-signin-button-directive/-/vue-google-signin-button-directive-1.0.3.tgz",
|
||||
"integrity": "sha512-S2gG+Zu+E+B/IoyXfbz/AixVrvZhnXU+G83bTtzhUAO9RaMg597G3XUpZOHHdgWBc/Szys/kHSbPXlONjR4wjQ=="
|
||||
},
|
||||
"node_modules/vue-gtag": {
|
||||
"version": "1.16.1",
|
||||
"resolved": "https://registry.npmmirror.com/vue-gtag/-/vue-gtag-1.16.1.tgz",
|
||||
"integrity": "sha512-5vs0pSGxdqrfXqN1Qwt0ZFXG0iTYjRMu/saddc7QIC5yp+DKgjWQRpGYVa7Pq+KbThxwzzMfo0sGi7ISa6NowA==",
|
||||
"peerDependencies": {
|
||||
"vue": "^2.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/vue-hot-reload-api": {
|
||||
"version": "2.3.4",
|
||||
"resolved": "https://registry.npmmirror.com/vue-hot-reload-api/-/vue-hot-reload-api-2.3.4.tgz",
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "uawgame",
|
||||
"version": "0.1.0",
|
||||
"version": "0.1.1",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"serve": "vue-cli-service serve",
|
||||
@ -10,6 +10,7 @@
|
||||
"lint": "vue-cli-service lint"
|
||||
},
|
||||
"dependencies": {
|
||||
"@cloudcare/browser-rum": "^3.1.11",
|
||||
"@walletconnect/ethereum-provider": "^2.11.2",
|
||||
"@walletconnect/modal": "^2.6.2",
|
||||
"axios": "^1.6.8",
|
||||
@ -22,6 +23,7 @@
|
||||
"postcss-px-to-viewport": "^1.1.1",
|
||||
"swiper": "^5.4.5",
|
||||
"vue": "^2.6.14",
|
||||
"vue-gtag": "^1.16.1",
|
||||
"vue-loader": "^15.10.1",
|
||||
"vue-router": "^3.5.1",
|
||||
"vuex": "^3.6.2",
|
||||
@ -40,6 +42,7 @@
|
||||
"eslint-plugin-vue": "^8.0.3",
|
||||
"sass": "^1.32.7",
|
||||
"sass-loader": "^12.0.0",
|
||||
"source-map-loader": "^5.0.0",
|
||||
"vue-template-compiler": "^2.6.14"
|
||||
}
|
||||
}
|
||||
|
@ -76,7 +76,7 @@ window.boot = function () {
|
||||
if (div) {
|
||||
div.style.backgroundImage = '';
|
||||
}
|
||||
console.log('Success to load scene: ' + launchScene);
|
||||
console.info('Success to load scene: ' + launchScene);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Before Width: | Height: | Size: 4.2 KiB After Width: | Height: | Size: 15 KiB |
@ -5,29 +5,56 @@
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width,initial-scale=1.0">
|
||||
<meta name="referrer" content="no-referrer">
|
||||
<link rel="icon" href="/logo.png">
|
||||
<title><%= htmlWebpackPlugin.options.title %></title>
|
||||
<link rel="icon" href="/favicon.ico">
|
||||
<title>Hill's Treasure Hunt</title>
|
||||
<link rel="apple-touch-icon" sizes="180x180" href="/src/img/apple-touch-icon.png">
|
||||
<link rel="icon" type="image/png" sizes="32x32" href="/src/img/favicon-32x32.png">
|
||||
<link rel="icon" type="image/png" sizes="16x16" href="/src/img/favicon-16x16.png">
|
||||
<link rel="manifest" href="/src/img/site.webmanifest">
|
||||
<link rel="mask-icon" href="/src/img/safari-pinned-tab.svg" color="#5bbad5">
|
||||
<meta name="msapplication-TileColor" content="#da532c">
|
||||
<meta name="theme-color" content="#ffffff">
|
||||
<meta
|
||||
name="description"
|
||||
content="Explore for chests; boost to unlock their full potential"
|
||||
/>
|
||||
<meta
|
||||
property="og:image"
|
||||
content="https://mint.counterfire.games/mint.png"
|
||||
/>
|
||||
<meta
|
||||
property="twitter:image"
|
||||
content="https://pbs.twimg.com/media/GLITHinbUAA1N8p?format=jpg&name=large"
|
||||
/>
|
||||
<script src="https://www.google.com/recaptcha/enterprise.js?render=explicit" async defer></script>
|
||||
</head>
|
||||
<body>
|
||||
<noscript>
|
||||
<strong>We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please enable it to continue.</strong>
|
||||
</noscript>
|
||||
<div id="app"></div>
|
||||
<script async src="https://www.googletagmanager.com/gtag/js?id=G-4KSHDJ3MGL"></script>
|
||||
<script>
|
||||
window.dataLayer = window.dataLayer || [];
|
||||
function gtag(){dataLayer.push(arguments);}
|
||||
gtag('js', new Date());
|
||||
|
||||
gtag('config', 'G-4KSHDJ3MGL');
|
||||
</script>
|
||||
<!-- built files will be auto injected -->
|
||||
<script src="https://www.google.com/recaptcha/api.js?render=6Ld3xoIpAAAAABW7f5ImgAC6GcWLeDCbt5HPXqe2"></script>
|
||||
<script th:inline="javascript">
|
||||
/**
|
||||
* 加载外部js
|
||||
*/
|
||||
var loadSingleScript = function (src, isModule) {
|
||||
return new Promise((resolve, reject) => {
|
||||
console.log(`>> begin load script: ${src}`);
|
||||
console.info(`>> begin load script: ${src}`);
|
||||
let s = document.createElement('script');
|
||||
s.async = true;
|
||||
if (isModule)s.type = 'module';
|
||||
s.src =src;
|
||||
s.addEventListener('load', function () {
|
||||
console.log(`<< finish load script: ${src}`);
|
||||
console.info(`<< finish load script: ${src}`);
|
||||
s.parentNode.removeChild(s);
|
||||
s.removeEventListener('load', arguments.callee, false);
|
||||
resolve && resolve();
|
||||
|
BIN
public/src/img/android-chrome-192x192.png
Normal file
After Width: | Height: | Size: 16 KiB |
BIN
public/src/img/android-chrome-512x512.png
Normal file
After Width: | Height: | Size: 49 KiB |
BIN
public/src/img/apple-touch-icon.png
Normal file
After Width: | Height: | Size: 15 KiB |
9
public/src/img/browserconfig.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<browserconfig>
|
||||
<msapplication>
|
||||
<tile>
|
||||
<square150x150logo src="/mstile-150x150.png"/>
|
||||
<TileColor>#da532c</TileColor>
|
||||
</tile>
|
||||
</msapplication>
|
||||
</browserconfig>
|
BIN
public/src/img/favicon-16x16.png
Normal file
After Width: | Height: | Size: 1021 B |
BIN
public/src/img/favicon-32x32.png
Normal file
After Width: | Height: | Size: 1.9 KiB |
BIN
public/src/img/favicon.ico
Normal file
After Width: | Height: | Size: 15 KiB |
BIN
public/src/img/mstile-150x150.png
Normal file
After Width: | Height: | Size: 11 KiB |
23
public/src/img/safari-pinned-tab.svg
Normal file
@ -0,0 +1,23 @@
|
||||
<?xml version="1.0" standalone="no"?>
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
|
||||
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
|
||||
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
|
||||
width="512.000000pt" height="512.000000pt" viewBox="0 0 512.000000 512.000000"
|
||||
preserveAspectRatio="xMidYMid meet">
|
||||
<metadata>
|
||||
Created by potrace 1.14, written by Peter Selinger 2001-2017
|
||||
</metadata>
|
||||
<g transform="translate(0.000000,512.000000) scale(0.100000,-0.100000)"
|
||||
fill="#000000" stroke="none">
|
||||
<path d="M2290 5110 c-30 -4 -80 -11 -110 -15 -30 -5 -64 -9 -75 -10 -11 -1
|
||||
-27 -5 -35 -7 -8 -3 -67 -17 -130 -33 -354 -86 -692 -252 -980 -481 -112 -89
|
||||
-328 -307 -411 -414 -223 -287 -394 -635 -475 -965 -55 -224 -67 -325 -70
|
||||
-590 -1 -137 2 -279 7 -315 5 -36 12 -83 15 -105 58 -426 274 -908 563 -1255
|
||||
55 -66 261 -274 317 -320 337 -277 697 -454 1105 -543 205 -45 279 -52 564
|
||||
-51 290 0 386 11 615 69 224 57 502 170 658 269 23 14 44 26 47 26 6 0 198
|
||||
131 205 140 3 3 21 17 40 30 19 14 42 32 51 40 8 8 46 42 84 75 96 85 185 178
|
||||
264 275 20 25 39 47 42 50 12 11 148 209 181 265 180 302 312 692 345 1025 15
|
||||
144 9 546 -10 665 -66 425 -225 807 -477 1150 -82 112 -124 160 -255 290 -345
|
||||
345 -749 570 -1220 680 -127 30 -182 39 -315 54 -88 11 -460 11 -540 1z"/>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 1.2 KiB |
19
public/src/img/site.webmanifest
Normal file
@ -0,0 +1,19 @@
|
||||
{
|
||||
"name": "",
|
||||
"short_name": "",
|
||||
"icons": [
|
||||
{
|
||||
"src": "./android-chrome-192x192.png",
|
||||
"sizes": "192x192",
|
||||
"type": "image/png"
|
||||
},
|
||||
{
|
||||
"src": "./android-chrome-512x512.png",
|
||||
"sizes": "512x512",
|
||||
"type": "image/png"
|
||||
}
|
||||
],
|
||||
"theme_color": "#ffffff",
|
||||
"background_color": "#ffffff",
|
||||
"display": "standalone"
|
||||
}
|
@ -18,6 +18,8 @@
|
||||
color: #2c3e50;
|
||||
background: url('@/assets/common/Bg.png') no-repeat;
|
||||
background-size: 100% 100%;
|
||||
word-break: keep-all;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
.grecaptcha-badge {
|
||||
display: none !important
|
||||
@ -114,5 +116,7 @@ video {
|
||||
|
||||
list-style: none;
|
||||
text-align: center;
|
||||
word-break: keep-all;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
</style>
|
||||
|
Before Width: | Height: | Size: 154 KiB After Width: | Height: | Size: 29 KiB |
Before Width: | Height: | Size: 178 KiB After Width: | Height: | Size: 30 KiB |
Before Width: | Height: | Size: 185 KiB After Width: | Height: | Size: 35 KiB |
Before Width: | Height: | Size: 269 KiB After Width: | Height: | Size: 39 KiB |
Before Width: | Height: | Size: 177 KiB After Width: | Height: | Size: 33 KiB |
Before Width: | Height: | Size: 198 KiB After Width: | Height: | Size: 35 KiB |
Before Width: | Height: | Size: 208 KiB After Width: | Height: | Size: 39 KiB |
Before Width: | Height: | Size: 291 KiB After Width: | Height: | Size: 42 KiB |
BIN
src/assets/common/Enter.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
BIN
src/assets/common/Event .png
Normal file
After Width: | Height: | Size: 2.1 KiB |
BIN
src/assets/common/Game .png
Normal file
After Width: | Height: | Size: 666 B |
BIN
src/assets/common/Google-icon.png
Normal file
After Width: | Height: | Size: 2.7 KiB |
BIN
src/assets/common/Historical Button.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
BIN
src/assets/common/Normal_GIF_1.gif
Normal file
After Width: | Height: | Size: 6.3 MiB |
BIN
src/assets/common/P6-up.png
Normal file
After Width: | Height: | Size: 3.0 KiB |
BIN
src/assets/common/P6.png
Normal file
After Width: | Height: | Size: 6.0 KiB |
BIN
src/assets/common/Point_icon_b.png
Normal file
After Width: | Height: | Size: 935 B |
BIN
src/assets/common/Reward.png
Normal file
After Width: | Height: | Size: 566 B |
BIN
src/assets/common/Turntable .png
Normal file
After Width: | Height: | Size: 726 B |
BIN
src/assets/common/Whitelist.png
Normal file
After Width: | Height: | Size: 952 B |
BIN
src/assets/common/andriod.png
Normal file
After Width: | Height: | Size: 4.9 KiB |
BIN
src/assets/common/app.png
Normal file
After Width: | Height: | Size: 4.9 KiB |
BIN
src/assets/common/appstore.png
Normal file
After Width: | Height: | Size: 20 KiB |
BIN
src/assets/common/check-input.png
Normal file
After Width: | Height: | Size: 2.6 KiB |
BIN
src/assets/common/close.png
Normal file
After Width: | Height: | Size: 2.2 KiB |
BIN
src/assets/common/common_icon_NFT.png
Normal file
After Width: | Height: | Size: 8.0 KiB |
BIN
src/assets/common/counterfire-apk.png
Normal file
After Width: | Height: | Size: 20 KiB |
BIN
src/assets/common/google.png
Normal file
After Width: | Height: | Size: 6.9 KiB |
BIN
src/assets/common/googleplay.png
Normal file
After Width: | Height: | Size: 22 KiB |
BIN
src/assets/common/holding01.png
Normal file
After Width: | Height: | Size: 6.2 KiB |
BIN
src/assets/common/holding02.png
Normal file
After Width: | Height: | Size: 7.7 KiB |
BIN
src/assets/common/holding03.png
Normal file
After Width: | Height: | Size: 7.4 KiB |
BIN
src/assets/common/invite02_box.png
Normal file
After Width: | Height: | Size: 4.0 KiB |
BIN
src/assets/common/logo-etherscan.png
Normal file
After Width: | Height: | Size: 4.6 KiB |
BIN
src/assets/common/quest Lock.png
Normal file
After Width: | Height: | Size: 746 B |
BIN
src/assets/common/step one.png
Normal file
After Width: | Height: | Size: 193 KiB |
BIN
src/assets/common/step tow.png
Normal file
After Width: | Height: | Size: 128 KiB |
BIN
src/assets/common/type0.png
Normal file
After Width: | Height: | Size: 4.5 KiB |
BIN
src/assets/common/type1.png
Normal file
After Width: | Height: | Size: 6.3 KiB |
BIN
src/assets/common/type2.png
Normal file
After Width: | Height: | Size: 39 KiB |
BIN
src/assets/home/Reissue.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 26 KiB After Width: | Height: | Size: 28 KiB |
Before Width: | Height: | Size: 6.7 KiB |
BIN
src/assets/turn/Background_shine.png
Normal file
After Width: | Height: | Size: 155 KiB |
BIN
src/assets/turn/GO .png
Normal file
After Width: | Height: | Size: 6.9 KiB |
BIN
src/assets/turn/Game.png
Normal file
After Width: | Height: | Size: 4.5 KiB |
BIN
src/assets/turn/Left_element_bg.png
Normal file
After Width: | Height: | Size: 117 KiB |
BIN
src/assets/turn/Lucky draw bg.png
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
src/assets/turn/P1.png
Normal file
After Width: | Height: | Size: 5.7 KiB |
BIN
src/assets/turn/Selected.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
src/assets/turn/Turntable.png
Normal file
After Width: | Height: | Size: 250 KiB |
BIN
src/assets/turn/Turntable02.png
Normal file
After Width: | Height: | Size: 152 KiB |
BIN
src/assets/turn/TurntableBG.png
Normal file
After Width: | Height: | Size: 134 KiB |
BIN
src/assets/turn/gobg.png
Normal file
After Width: | Height: | Size: 27 KiB |
BIN
src/assets/turn/leaderboard.png
Normal file
After Width: | Height: | Size: 585 KiB |
BIN
src/assets/turn/white .png
Normal file
After Width: | Height: | Size: 7.0 KiB |
BIN
src/assets/video/chest_bg_1.mp4
Normal file
BIN
src/assets/video/chest_bg_2.mp4
Normal file
BIN
src/assets/video/chest_bg_3.mp4
Normal file
BIN
src/assets/video/chest_bg_4.mp4
Normal file
BIN
src/assets/video/chest_bg_5.mp4
Normal file
@ -1,36 +1,59 @@
|
||||
<template>
|
||||
<el-button class="mybtn" :loading="timeLeft > 0" @click.stop="beginAction">{{ timeLeft > 0 ? timeLeft + 's' : title }}</el-button>
|
||||
<el-button
|
||||
class="mybtn"
|
||||
:loading="timeLeft > 0"
|
||||
@click.stop="beginAction"
|
||||
>{{ timeLeft > 0 ? timeLeft + 's' : title }}</el-button>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {
|
||||
apiCheckActivity,
|
||||
} from "@/utils/webapi.js";
|
||||
import { apiCheckActivity } from "@/utils/webapi.js";
|
||||
import { datafluxRum } from '@cloudcare/browser-rum'
|
||||
export default {
|
||||
props: {
|
||||
title: String,
|
||||
time: String,
|
||||
dataid: String
|
||||
itemData: Object,
|
||||
activityData: Object,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
timeLeft: 0,
|
||||
}
|
||||
timeLeft: 0
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
},
|
||||
methods: {
|
||||
async beginAction() {
|
||||
console.log(this.activityData,'----')
|
||||
return
|
||||
try {
|
||||
let { errcode, data } = await apiCheckActivity(this.dataid);
|
||||
let { errcode, errmsg, data } = await apiCheckActivity(
|
||||
this.itemData.id
|
||||
);
|
||||
datafluxRum.addRumGlobalContext('task_type',{
|
||||
name: this.itemData.task+'Verify'
|
||||
})
|
||||
if (errcode !== 0) {
|
||||
this.beginCountdown();
|
||||
if (errmsg == "twitter already binded") {
|
||||
this.$showErr("twitter already binded");
|
||||
this.$emit("reconnection", this.itemData)
|
||||
} else if (errmsg == "discord already binded to another account") {
|
||||
this.$showErr("discord already binded to another account");
|
||||
this.$emit("reconnection", this.itemData)
|
||||
} else if(errmsg == "google account already binded") {
|
||||
this.$showErr("google account already binded");
|
||||
this.$emit("reconnection", this.itemData)
|
||||
} else {
|
||||
this.beginCountdown();
|
||||
}
|
||||
return;
|
||||
}
|
||||
if (data.status === 2) {
|
||||
this.$emit('stateupdate', data.status);
|
||||
this.$emit("stateupdate", data.status);
|
||||
return;
|
||||
}
|
||||
this.beginCountdown();
|
||||
|
||||
} catch (err) {
|
||||
this.beginCountdown();
|
||||
}
|
||||
@ -40,41 +63,41 @@ export default {
|
||||
let timer = setInterval(() => {
|
||||
this.timeLeft--;
|
||||
if (this.timeLeft <= 0) {
|
||||
this.$showErr("Please try again");
|
||||
clearInterval(timer);
|
||||
}
|
||||
}, 1000);
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.mybtn{
|
||||
.mybtn {
|
||||
width: 90px;
|
||||
height: 30px;
|
||||
line-height: 0!important;
|
||||
line-height: 0 !important;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
transform: translate(-50% , -50%);
|
||||
transform: translate(-50%, -50%);
|
||||
background: #fec25d;
|
||||
background: url('@/assets/home/ButtonFollow.png') no-repeat;
|
||||
background: url("@/assets/home/ButtonFollow.png") no-repeat;
|
||||
background-size: 100% 100%;
|
||||
color: unset;
|
||||
border: none;
|
||||
}
|
||||
.mybtn:disabled{
|
||||
color:unset;
|
||||
.mybtn:disabled {
|
||||
color: unset;
|
||||
border: none;
|
||||
line-height: 0!important;
|
||||
line-height: 0 !important;
|
||||
}
|
||||
.mybtn.is-loading:before{
|
||||
.mybtn.is-loading:before {
|
||||
background-color: unset;
|
||||
}
|
||||
|
||||
</style>
|
||||
<style lang="scss">
|
||||
.mybtn .el-icon-loading{
|
||||
line-height: 0!important;
|
||||
.mybtn .el-icon-loading {
|
||||
line-height: 0 !important;
|
||||
}
|
||||
</style>
|
||||
|
514
src/components/emailDialog.vue
Normal file
@ -0,0 +1,514 @@
|
||||
<template>
|
||||
<div class>
|
||||
<el-dialog class="dialog-wallet" :visible.sync="emailDialogVisible" :modal="false" :before-close="handleClose">
|
||||
<div class="dialog-header">
|
||||
<div class="dialog-header-title">Connect Game Account</div>
|
||||
<div class="dialog-header-close" @click="handleClose">
|
||||
<img src="@/assets/common/close.png" alt />
|
||||
</div>
|
||||
</div>
|
||||
<div class="dialog-content">
|
||||
<div class="wallet-content">
|
||||
<li @click="getLinkGoogle()">
|
||||
<div>
|
||||
<img src="@/assets/common/Google-icon.png" alt />
|
||||
<span>Sign in with Google</span>
|
||||
</div>
|
||||
</li>
|
||||
</div>
|
||||
<div class="line"></div>
|
||||
</div>
|
||||
<div class="dialog-content">
|
||||
<div class="wallet-content">
|
||||
<div class="dialog-header-title title-color">Link with Code</div>
|
||||
<!-- <el-form :model="emailValidateForm" ref="emailValidateForm" :rules="rules">
|
||||
<el-form-item
|
||||
prop="email"
|
||||
:show-message="isShowMes"
|
||||
>
|
||||
<div>
|
||||
<span class="table-title">Email address</span>
|
||||
<el-input
|
||||
@focus="checkInput"
|
||||
@blur="blurInput"
|
||||
@input="checkInput"
|
||||
type="text"
|
||||
placeholder="Email address"
|
||||
class="ipt_css"
|
||||
v-model="emailValidateForm.email"
|
||||
/>
|
||||
</div>
|
||||
<div v-if="isEmail == '1'" class="email-no">Email address is required. Please enter your email to proceed.</div>
|
||||
<div v-if="isEmail == '2'" class="email-no">Please check the email format and try again.</div>
|
||||
</el-form-item>
|
||||
<el-form-item prop="emailCode">
|
||||
<div>
|
||||
<span class="table-title">Verification code</span>
|
||||
<el-input placeholder=""
|
||||
class="ipt_css"
|
||||
v-model="emailValidateForm.emailCode" />
|
||||
<div v-if="timeLeft <= 0" class="code-btn" @click="checkCode(emailValidateForm.email)">Send Code</div>
|
||||
<div v-else class="code-btn">{{ timeLeft }}</div>
|
||||
</div>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div class="check-validate" @click="resetForm('emailValidateForm')">Verify</div> -->
|
||||
|
||||
<el-form :model="codeValidateForm" ref="codeValidateForm" :rules="codeRules">
|
||||
<el-form-item prop="emailCode">
|
||||
<div>
|
||||
<span class="table-title">Code</span>
|
||||
<el-input placeholder=""
|
||||
class="ipt_css"
|
||||
v-model="codeValidateForm.emailCode" />
|
||||
</div>
|
||||
</el-form-item>
|
||||
<div class="code-btn" @click="checkEmailDialogVisible = true">How to Get Your Code</div>
|
||||
|
||||
</el-form>
|
||||
<div class="check-validate" @click="codeResetForm('codeValidateForm')">Verify</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-dialog>
|
||||
<el-dialog class="dialog-wallet dialog-code" :visible.sync="checkEmailDialogVisible" :modal="false" :before-close="checkHandleClose">
|
||||
<div class="dialog-header">
|
||||
<div class="dialog-header-title title-color"> How to Get Your Code</div>
|
||||
<div class="dialog-header-close" @click="checkHandleClose">
|
||||
<img src="@/assets/common/close.png" alt />
|
||||
</div>
|
||||
</div>
|
||||
<div class="dialog-content">
|
||||
<div class="wallet-content">
|
||||
<div class="get-code">
|
||||
<div class="get-code-left">
|
||||
<div class="get-code-left-top">
|
||||
Login to the game and find the 'Code' icon.
|
||||
</div>
|
||||
<div class="get-code-left-btm">
|
||||
<div>
|
||||
<img src="@/assets/common/step one.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="get-code-right">
|
||||
<div class="get-code-left-top">
|
||||
Copy your Code
|
||||
</div>
|
||||
<div class="get-code-left-btm">
|
||||
<div>
|
||||
<img src="@/assets/common/step tow.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { apiSendCode, apiVerifyEmail, apiVerifyClient } from '@/utils/webapi.js'
|
||||
|
||||
export default {
|
||||
props: {
|
||||
emailDialogVisible: Boolean,
|
||||
},
|
||||
|
||||
data() {
|
||||
let emailCodeVerifiers = /^\d{6}$/;
|
||||
let emailValidateCode = (rule, value, callback) => {
|
||||
if (value === "") {
|
||||
callback(new Error("Please enter the verification code we sent to your email."));
|
||||
} else {
|
||||
if (emailCodeVerifiers.test(value)) {
|
||||
callback();
|
||||
} else {
|
||||
callback(
|
||||
new Error(
|
||||
"Verification code is incorrect. Please verify and try again."
|
||||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
};
|
||||
let codeVerifiers = /^[23456789abcdefghjkmnpqrstuvwxy]{8}$/;
|
||||
let validateCode = (rule, value, callback) => {
|
||||
if (value === "") {
|
||||
callback(new Error("Please enter the verification code we sent to your email."));
|
||||
} else {
|
||||
if (codeVerifiers.test(value)) {
|
||||
callback();
|
||||
} else {
|
||||
callback(
|
||||
new Error(
|
||||
"Verification code is incorrect. Please verify and try again."
|
||||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
};
|
||||
return {
|
||||
isWalletList: [
|
||||
{
|
||||
name: "MetaMask",
|
||||
value: "google",
|
||||
imgUrl: require("@/assets/common/Google-icon.png")
|
||||
},
|
||||
{
|
||||
name: "OKXwallet",
|
||||
value: "email",
|
||||
imgUrl: require("@/assets/home/icon_OKXwallet.png")
|
||||
}
|
||||
],
|
||||
checkEmailDialogVisible: false,
|
||||
emailValidateForm: {
|
||||
email: '',
|
||||
emailCode: ''
|
||||
},
|
||||
rules: {
|
||||
email: [
|
||||
{
|
||||
required: true,
|
||||
message: 'Email address is required. Please enter your email to proceed.',
|
||||
trigger: 'blur',
|
||||
},
|
||||
{
|
||||
type: 'email',
|
||||
message: 'Please check the email format and try again.',
|
||||
trigger: ['blur', 'change'],
|
||||
},
|
||||
],
|
||||
emailCode: [
|
||||
{
|
||||
validator: emailValidateCode,
|
||||
trigger: ['blur', 'change'],
|
||||
},
|
||||
],
|
||||
},
|
||||
codeValidateForm: {
|
||||
emailCode: ''
|
||||
},
|
||||
codeRules: {
|
||||
emailCode: [
|
||||
{
|
||||
validator: validateCode,
|
||||
trigger: ['blur', 'change'],
|
||||
},
|
||||
],
|
||||
},
|
||||
isEmail: '0',
|
||||
timeLeft: 0,
|
||||
time: 60,
|
||||
isShowMes: true,
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
},
|
||||
methods: {
|
||||
// 绑定游戏账号
|
||||
async getLinkGoogle() {
|
||||
this.$emit('googleLogin')
|
||||
},
|
||||
|
||||
// 获取验证码
|
||||
async checkCode(email) {
|
||||
if(email) {
|
||||
if(this.isValidateEmail(email)) {
|
||||
let { errcode, errmsg, data } = await apiSendCode(email)
|
||||
if(!errcode) {
|
||||
this.beginCountdown()
|
||||
}
|
||||
}
|
||||
} else {
|
||||
this.isEmail = '1'
|
||||
this.isShowMes = false
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
checkInput() {
|
||||
this.isEmail = '0'
|
||||
this.isShowMes = true
|
||||
},
|
||||
blurInput() {
|
||||
this.isEmail = '0'
|
||||
},
|
||||
|
||||
// 验证邮箱
|
||||
resetForm(emailValidateForm) {
|
||||
this.$refs[emailValidateForm].validate(async (valid) => {
|
||||
if(valid) {
|
||||
let { errcode, errmsg, data } = await apiVerifyEmail(this.emailValidateForm.email, this.emailValidateForm.emailCode)
|
||||
if(!errcode) {
|
||||
this.$emit('bindEmail')
|
||||
} else if(errcode == 14) {
|
||||
this.$showErr(errmsg)
|
||||
} else if(errcode == 16) {
|
||||
this.$showErr(errmsg)
|
||||
}
|
||||
} else {
|
||||
return
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
// 客户端验证
|
||||
codeResetForm(codeValidateForm) {
|
||||
this.$refs[codeValidateForm].validate(async (valid) => {
|
||||
if(valid) {
|
||||
let { errcode, errmsg, data } = await apiVerifyClient(this.codeValidateForm.emailCode)
|
||||
if(!errcode) {
|
||||
this.$emit('bindEmail')
|
||||
} else if(errcode == 11) {
|
||||
this.$showErr(errmsg)
|
||||
} else if(errcode == 12) {
|
||||
this.$showErr(errmsg)
|
||||
} else if(errcode == 13) {
|
||||
this.$showErr(errmsg)
|
||||
} else if(errcode == 14) {
|
||||
this.$showErr(errmsg)
|
||||
} else if(errcode == 16) {
|
||||
this.$showErr(errmsg)
|
||||
}
|
||||
} else {
|
||||
return
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
// 邮箱验证
|
||||
isValidateEmail(email) {
|
||||
const reg = /^(\w-*\.*)+@(\w-?)+(\.\w{2,})+$/
|
||||
return reg.test(email)
|
||||
},
|
||||
|
||||
// 验证码验证
|
||||
isValiedCode(code){
|
||||
return /^\d{6}$/.test(code)
|
||||
},
|
||||
|
||||
// 倒计时
|
||||
beginCountdown() {
|
||||
this.timeLeft = parseInt(this.time);
|
||||
let timer = setInterval(() => {
|
||||
this.timeLeft--;
|
||||
if (this.timeLeft <= 0) {
|
||||
// this.$showErr("Please try again");
|
||||
this.time = 60
|
||||
clearInterval(timer);
|
||||
}
|
||||
}, 1000);
|
||||
},
|
||||
|
||||
// 关闭弹窗
|
||||
handleClose() {
|
||||
this.$emit("closeDialog");
|
||||
},
|
||||
|
||||
checkHandleClose() {
|
||||
this.checkEmailDialogVisible = false
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
div {
|
||||
.dialog-wallet {
|
||||
width: 50% !important;
|
||||
margin: auto;
|
||||
::v-deep .el-dialog {
|
||||
// border: 1px solid #924df2;
|
||||
background: #2d2738;
|
||||
border-radius: 30px;
|
||||
.el-dialog__header {
|
||||
// display: none;
|
||||
padding: 0;
|
||||
padding-top: 20px;
|
||||
button {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
.el-dialog__body {
|
||||
position: relative;
|
||||
padding: 0 30px;
|
||||
color: #fff;
|
||||
.dialog-header {
|
||||
margin-top: 20px;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
.dialog-header-title {
|
||||
text-align: left;
|
||||
font-weight: 700;
|
||||
font-size: 26px;
|
||||
color: #F1B85A;
|
||||
font-family: "Anton-Regular";
|
||||
}
|
||||
.title-color {
|
||||
color: #994FFD;
|
||||
}
|
||||
.dialog-header-close {
|
||||
width: 35px;
|
||||
height: 35px;
|
||||
cursor: pointer;
|
||||
img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.dialog-content {
|
||||
padding-bottom: 20px;
|
||||
p {
|
||||
text-align: left;
|
||||
padding: 20px 0;
|
||||
font-size: 16px;
|
||||
}
|
||||
.wallet-content {
|
||||
width: 95%;
|
||||
margin: 0 auto;
|
||||
text-align: left;
|
||||
li {
|
||||
height: 60px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin: 20px 0;
|
||||
padding-left: 50px;
|
||||
cursor: pointer;
|
||||
border-radius: 40px;
|
||||
text-align: left;
|
||||
box-sizing: border-box;
|
||||
border: 2px solid #a57a4a;
|
||||
div {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
img {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
}
|
||||
span {
|
||||
color: #FEC25D;
|
||||
margin-left: 20px;
|
||||
font-size: 24px;
|
||||
}
|
||||
}
|
||||
}
|
||||
li:nth-child(3) {
|
||||
padding-left: 0;
|
||||
background: url('@/assets/common/disconnect.png') no-repeat;
|
||||
background-size: 100% 100%;
|
||||
.disconnect {
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
// color: #000;
|
||||
}
|
||||
&:hover {
|
||||
background: url('@/assets/common/Please.png') no-repeat;
|
||||
background-size: 100% 100%;
|
||||
}
|
||||
}
|
||||
.dialog-header-title {
|
||||
text-align: left;
|
||||
font-weight: 700;
|
||||
font-size: 26px;
|
||||
color: #F1B85A;
|
||||
font-family: "Anton-Regular";
|
||||
}
|
||||
.title-color {
|
||||
color: #994FFD;
|
||||
}
|
||||
.el-form {
|
||||
.el-form-item {
|
||||
.el-form-item__content {
|
||||
div {
|
||||
text-align: left;
|
||||
.table-title {
|
||||
display: inline-block;
|
||||
font-size: 24px;
|
||||
}
|
||||
.el-input {
|
||||
// background: #fff;
|
||||
.el-input-group__append {
|
||||
cursor: pointer;
|
||||
color: #000;
|
||||
background: #ffc35b;
|
||||
border-radius: 20px;
|
||||
}
|
||||
input {
|
||||
background: #1e1b26;
|
||||
border-color: #1e1b26;
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.email-no {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
height: 10px;
|
||||
color: #F56C6C;
|
||||
font-size: 12px;
|
||||
}
|
||||
}
|
||||
}
|
||||
.code-btn {
|
||||
width: 140px;
|
||||
color: #9950fd;
|
||||
text-align: left;
|
||||
text-decoration: underline;
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
.get-code {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
margin-top: 30px;
|
||||
.get-code-left,
|
||||
.get-code-right {
|
||||
width: 48%;
|
||||
.get-code-left-top {
|
||||
font-size: 18px;
|
||||
padding-bottom: 10px;
|
||||
border-bottom: 2px solid #413c4c;
|
||||
}
|
||||
.get-code-left-btm {
|
||||
width: 100%;
|
||||
margin: 30px 0;
|
||||
div {
|
||||
width: 100%;
|
||||
img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.check-validate {
|
||||
width: 120px;
|
||||
height: 35px;
|
||||
line-height: 35px;
|
||||
background: #ffc35b;
|
||||
color: #000;
|
||||
margin: 20px auto;
|
||||
margin-top: 50px;
|
||||
border-radius: 20px;
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
.line {
|
||||
width: 100%;
|
||||
height: 0px;
|
||||
// background: #79787b,
|
||||
border: 1px dashed #79787b;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.dialog-code {
|
||||
width: 100% !important;
|
||||
}
|
||||
}
|
||||
</style>
|
@ -1,96 +0,0 @@
|
||||
<template>
|
||||
<el-dialog :visible="dialogVisible" :before-close="handleClose" :closable="false" :show-close="false">
|
||||
<div class="top">
|
||||
<div class="top-title"></div>
|
||||
<div class="top-close" @click="handleClose">
|
||||
<img src="@/assets/common/CloseButton.png" alt />
|
||||
</div>
|
||||
</div>
|
||||
<div class="content">
|
||||
<div>{{ errorText }}</div>
|
||||
<div>{{message}}</div>
|
||||
</div>
|
||||
<div class="btn" @click="handleClose">Confirm</div>
|
||||
<!-- <div class="confirm-box">
|
||||
<div class="confirm-title">
|
||||
<span>错误提示</span>
|
||||
</div>
|
||||
<div class="confirm-context"> {{message}}</div>
|
||||
</div>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<a-button @click="handleClose" type="primary">Confirm</a-button>
|
||||
</div>-->
|
||||
</el-dialog>
|
||||
</template>
|
||||
<script>
|
||||
|
||||
export default {
|
||||
name: "iErrorMessage",
|
||||
props: {
|
||||
dialogVisible: Boolean,
|
||||
errorText: String
|
||||
},
|
||||
data() {
|
||||
return {};
|
||||
},
|
||||
methods: {
|
||||
handleClose() {
|
||||
this.$emit('handleClose')
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
::v-deep .el-dialog {
|
||||
border: 1px solid #924df2;
|
||||
background: #1a1821;
|
||||
width: 600px;
|
||||
border-radius: 80px;
|
||||
padding: 0px 50px;
|
||||
.el-dialog__header {
|
||||
padding: 0;
|
||||
}
|
||||
.el-dialog__body {
|
||||
position: relative;
|
||||
color: #fff;
|
||||
.top {
|
||||
display: flex;
|
||||
height: 10px;
|
||||
.top-title {
|
||||
color: #fff;
|
||||
font-size: 28px;
|
||||
font-family: "Anton-Regular";
|
||||
}
|
||||
.top-close {
|
||||
position: absolute;
|
||||
top: -8%;
|
||||
right: -15%;
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
cursor: pointer;
|
||||
img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.content {
|
||||
margin: 20px 0;
|
||||
min-height: 100px;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
.btn {
|
||||
width: 200px;
|
||||
height: 50px;
|
||||
line-height: 50px;
|
||||
margin: 0 auto;
|
||||
color: #000;
|
||||
background: url("./../../assets/home/explore map button.png") no-repeat;
|
||||
background-size: 100% 100%;
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -13,7 +13,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="confirm-box">
|
||||
<div class="confirm-context">{{message}}</div>
|
||||
<div class="confirm-context" v-html="message">{{}}</div>
|
||||
</div>
|
||||
<div class="btn" @click="handleClose">Confirm</div>
|
||||
<!-- <div slot="footer" class="dialog-footer">
|
||||
@ -29,6 +29,7 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
handleClose() {
|
||||
this.nextAction && this.nextAction()
|
||||
this.dialogVisible = false;
|
||||
}
|
||||
}
|
||||
@ -72,7 +73,7 @@ export default {
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
color: #fff;
|
||||
font-size: 14px;
|
||||
font-size: 18px;
|
||||
padding-left: 21px;
|
||||
}
|
||||
.btn {
|
||||
|
@ -1,7 +1,7 @@
|
||||
import Vue from 'vue';
|
||||
import confirm from './errorDialog.vue';
|
||||
const iErrorMessage = Vue.extend(confirm);
|
||||
function showErrMsg(err) {
|
||||
function showErrMsg(err, action) {
|
||||
let errmsg = err
|
||||
// alert(err,'----')
|
||||
// let errmsg = err;
|
||||
@ -9,21 +9,97 @@ let errmsg = err
|
||||
errmsg = JSON.stringify(err);
|
||||
}
|
||||
if (errmsg.indexOf('insufficient tickets') > -1) {
|
||||
errmsg = 'Insufficient exploration attempts'
|
||||
errmsg = 'Not enough exploration attempts.'
|
||||
} else if(errmsg.indexOf('invalid opcode: opcode 0xd8 not defined') > -1) {
|
||||
errmsg = `Claim failed due to insufficient gas.`
|
||||
} else if(errmsg.indexOf('User rejected the request') > -1) {
|
||||
errmsg = `User refuses to switch networks`
|
||||
errmsg = `Please select the correct network to continue.`
|
||||
} else if(errmsg.indexOf('User denied transaction signature') > -1) {
|
||||
errmsg = `User refuses to sign`
|
||||
errmsg = `Signature required to proceed.`
|
||||
} else if(errmsg.indexOf('Internal JSON-RPC error') > -1) {
|
||||
errmsg = `Insufficient gas fees`
|
||||
errmsg = `Insufficient gas fees.`
|
||||
} else if(errmsg.indexOf('Hash: not available') > -1) {
|
||||
errmsg = `Operation timed out. Please retry`
|
||||
errmsg = `Operation timed out. Please retry.`
|
||||
} else if(errmsg.indexOf('chest already opened') > -1) {
|
||||
errmsg = 'chest already opened'
|
||||
// } else if(errmsg.indexOf('chest already opened') > -1) {
|
||||
// errmsg = 'Transaction failed please try again'
|
||||
errmsg = 'This chest has been opened already'
|
||||
} else if(errmsg.indexOf('check error: not found guild') > -1) {
|
||||
errmsg = 'Transaction failed please try again'
|
||||
} else if(errmsg.indexOf('execution reverted: TreasureHunt: paused') > -1) {
|
||||
errmsg = 'Event starting soon. Please check back later'
|
||||
} else if(errmsg.indexOf('waiting for chain confirm') > -1) {
|
||||
errmsg = 'waiting for chain confirm'
|
||||
} else if(errmsg.indexOf('voucher not found') > -1) {
|
||||
errmsg = 'Invalid Redemption Code'
|
||||
} else if(errmsg.indexOf('Can not be empty') > -1) {
|
||||
errmsg = 'Redemption Code is required'
|
||||
} else if(errmsg.indexOf('need connect discord first') > -1) {
|
||||
errmsg = `Discord account unlinked. Please ensure the 'Connect Your Discord' quest is complete.`
|
||||
} else if(errmsg.indexOf("You do not hold the required role in the") > -1) {
|
||||
errmsg = errmsg
|
||||
} else if(errmsg.indexOf('Invalid Voucher Code') > -1) {
|
||||
errmsg = 'Invalid Redemption Code'
|
||||
} else if(errmsg.indexOf('voucher already used') > -1) {
|
||||
errmsg = 'Redemption Code has already been used'
|
||||
} else if(errmsg.indexOf('already claimed') > -1) {
|
||||
errmsg = 'This reward chest has been claimed already'
|
||||
} else if(errmsg.indexOf('had no role') > -1) {
|
||||
errmsg = 'You do not hold the required role in the "Counter Fire" Discord server'
|
||||
} else if(errmsg.indexOf('have not join guild') > -1) {
|
||||
errmsg = 'You do not hold the required role in the "Counter Fire" Discord server'
|
||||
} else if(errmsg.indexOf('twitter already binded') > -1) {
|
||||
errmsg = 'This X account has already been linked'
|
||||
} else if(errmsg.indexOf('discord already binded to another account') > -1) {
|
||||
errmsg = 'This Discord account has already been linked'
|
||||
} else if(errmsg.indexOf('google account already binded') > -1) {
|
||||
errmsg = 'This Account is Already Connected to Another User. Try Using a Different Account.'
|
||||
} else if(errmsg.indexOf("Please complete the 'Connect Your X' quest first") > -1) {
|
||||
errmsg = "Please complete the 'Connect Your X' quest first"
|
||||
} else if(errmsg.indexOf("Please complete the 'Connect Your Google' quest first") > -1) {
|
||||
errmsg = "Please complete the 'Connect Your Google' quest first"
|
||||
} else if(errmsg.indexOf("Please complete the 'Connect Your Discord' quest first") > -1) {
|
||||
errmsg = "Please complete the 'Connect Your Discord' quest first"
|
||||
} else if(errmsg.indexOf("maintance now, please try later") > -1) {
|
||||
errmsg = "maintance now, please try later"
|
||||
} else if(errmsg.indexOf('Please try again') > -1) {
|
||||
errmsg = "Verification failed due to high traffic. Please attempt to verify again or try later"
|
||||
} else if(errmsg.indexOf('already claimed') > -1) {
|
||||
errmsg = "Already received"
|
||||
} else if(errmsg.indexOf('Complete CAPTCHA verification to verify you are not a robot') > -1) {
|
||||
errmsg = "Complete CAPTCHA verification to verify you are not a robot"
|
||||
} else if(errmsg.indexOf('Verification Successful') > -1) {
|
||||
errmsg = "Verification Successful"
|
||||
} else if(errmsg.indexOf('Verification Timeout') > -1) {
|
||||
errmsg = "Verification Timeout"
|
||||
} else if(errmsg.indexOf('Verification Error') > -1) {
|
||||
errmsg = "Verification Error"
|
||||
} else if(errmsg.indexOf('need connect game account first') > -1) {
|
||||
errmsg = `Game Account Not Connected`
|
||||
} else if(errmsg.indexOf('not match condition') > -1) {
|
||||
errmsg = `Quest Not Completed`
|
||||
} else if(errmsg.indexOf('no times') > -1) {
|
||||
errmsg = `You don't have enough Spins.`
|
||||
} else if(errmsg.indexOf('no ticket') > -1) {
|
||||
errmsg = `You don't have enough Spins.`
|
||||
} else if(errmsg.indexOf('Email address is required. Please enter your email to proceed.') > -1) {
|
||||
errmsg = `Email address is required. Please enter your email to proceed.`
|
||||
} else if(errmsg.indexOf('already bind game account') > -1) {
|
||||
errmsg = `This Account is Already Connected to Another User. Try Using a Different Account.`
|
||||
} else if(errmsg.indexOf('Email already binded to another account') > -1) {
|
||||
errmsg = `This Account is Already Connected to Another User. Try Using a Different Account.`
|
||||
} else if(errmsg.indexOf('code expired') > -1) {
|
||||
errmsg = `Your verification code has expired. Please request a new code.`
|
||||
} else if(errmsg.indexOf('code error') > -1) {
|
||||
errmsg = `Verification code is incorrect. Please verify and try again.`
|
||||
} else if(errmsg.indexOf('activity is end') > -1) {
|
||||
errmsg = `This event has now concluded. Thank you for participating!</br>
|
||||
Thank you for joining us! This event has officially ended.`
|
||||
} else if(errmsg.indexOf('You have already boosted the chest') > -1
|
||||
|| errmsg.indexOf('The chest’s boost count has reached the upper limit') > -1
|
||||
|| errmsg.indexOf('Today’s boost count has been exhausted') > -1) {
|
||||
// keep the errmsg
|
||||
} else {
|
||||
// 请重试
|
||||
errmsg = 'An unknown on-chain interaction error has occurred. Our technical team cannot resolve this issue directly. Please use a blockchain explorer to check your wallet address and determine if the transaction was recorded or if another issue exists.'
|
||||
}
|
||||
|
||||
const _confirm = new iErrorMessage({
|
||||
@ -31,6 +107,7 @@ let errmsg = err
|
||||
return {
|
||||
message: errmsg,
|
||||
dialogVisible: true,
|
||||
nextAction: action
|
||||
};
|
||||
},
|
||||
});
|
||||
|
516
src/components/header/index.vue
Normal file
@ -0,0 +1,516 @@
|
||||
<template>
|
||||
<div class="box-top">
|
||||
<div class="left">
|
||||
<div class="left-top">
|
||||
<div class="left-top-logo">
|
||||
<img src="./../../assets/home/mint_Logo1.png" alt />
|
||||
</div>
|
||||
<div class="left-top-points">
|
||||
<div class="left-top-points-left">
|
||||
<li>
|
||||
<div class="top">
|
||||
<span class="textCol4">{{ usesInviteCount }}</span>
|
||||
<div>
|
||||
<img src="./../../assets/common/Invites.png" alt />
|
||||
</div>
|
||||
</div>
|
||||
<div class="btm">Invites</div>
|
||||
<div class="hover-tips">Successful invitations</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="top">
|
||||
<span class="textCol3">{{ usesEnhanceCount }}</span>
|
||||
<div>
|
||||
<img src="./../../assets/common/Icon_Boosting.png" alt />
|
||||
</div>
|
||||
</div>
|
||||
<div class="btm">Boosts</div>
|
||||
<div class="hover-tips">Remaining Daily Boosts</div>
|
||||
</li>
|
||||
<li>
|
||||
<div class="top">
|
||||
<span class="textCol2">{{ todayStepTicket }}</span>
|
||||
<div>
|
||||
<img src="./../../assets/common/Icon_Explore.png" alt />
|
||||
</div>
|
||||
</div>
|
||||
<div class="btm">Exploration</div>
|
||||
<!-- <div class="hover-tips">Explorations Earned</div> -->
|
||||
</li>
|
||||
<li>
|
||||
<div class="top">
|
||||
<span class="textCol1">{{ usesPoints }}</span>
|
||||
<div>
|
||||
<img src="./../../assets/common/Icon_Points.png" alt />
|
||||
</div>
|
||||
</div>
|
||||
<div class="btm">Points</div>
|
||||
<!-- <div class="hover-tips">Explorations Earned</div> -->
|
||||
</li>
|
||||
<div class="touxiang">
|
||||
<UserImg :imgSrc="myTwitterAvatar" />
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="left-top-points-right">
|
||||
<img v-if="inWhiteList == 1" src="@/assets/common/wallet-yes.png" alt="">
|
||||
<img v-else src="@/assets/common/wallet-no.png" alt="">
|
||||
<div class="hover-tips">Partner NFT collection holders get extra rewards</div>
|
||||
</div>-->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="right">
|
||||
<div class="right-header">
|
||||
<div class="right-header-left"></div>
|
||||
<div class="right-header-right">
|
||||
<div class="link">
|
||||
<li v-for="(item, index) in linkList" :key="index">
|
||||
<a :href="item.hrefLink" target="_blank" rel="noopener noreferrer">
|
||||
<div>
|
||||
<img :src="item.imgSrc" alt />
|
||||
</div>
|
||||
</a>
|
||||
</li>
|
||||
</div>
|
||||
<div class="wallet" @click="walletLogin">
|
||||
<span v-if="!showAddress">Connect Wallet</span>
|
||||
<div class="wallet-address" v-else>{{ showAddress }}</div>
|
||||
<div class="wallet-btn">
|
||||
<img
|
||||
v-if="!showAddress"
|
||||
class="hover-show"
|
||||
src="./../../assets/home/Connect Menu1.png"
|
||||
alt
|
||||
/>
|
||||
<img v-else class="hover-none" src="@/assets/home/ICON03.png" alt />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="nav-btm">
|
||||
<div class="nav">
|
||||
<li
|
||||
:class="{active: navIndex == index}"
|
||||
v-for="(item, index) in navList"
|
||||
:key="index"
|
||||
@click="navBtn(index)"
|
||||
>
|
||||
<div class="nav-img">
|
||||
<img v-if="navIndex == index" :src="item.imgSrc1" alt />
|
||||
<img v-else :src="item.imgSrc" alt />
|
||||
</div>
|
||||
</li>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getToken } from "@/utils/cookies.js"
|
||||
import { formatShowAddress } from "@/utils/utils.js";
|
||||
import UserImg from "@/components/userImg.vue";
|
||||
export default {
|
||||
components: {
|
||||
UserImg
|
||||
},
|
||||
props: {
|
||||
todayStepTicket: Number,
|
||||
myTwitterAvatar: String,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
linkList: [
|
||||
{
|
||||
imgSrc: require("@/assets/common/Icon_Disc.png"),
|
||||
hrefLink: "https://discord.gg/counterfire"
|
||||
},
|
||||
{
|
||||
imgSrc: require("@/assets/common/Icon_X.png"),
|
||||
hrefLink: "https://twitter.com/playCounterFire"
|
||||
}
|
||||
],
|
||||
navList: [
|
||||
{
|
||||
id: 1,
|
||||
name: 1,
|
||||
imgSrc: require("./../../assets/common/P1-up.png"),
|
||||
imgSrc1: require("./../../assets/common/P1.png")
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
name: 2,
|
||||
imgSrc: require("./../../assets/common/P2-up.png"),
|
||||
imgSrc1: require("./../../assets/common/P2.png")
|
||||
},
|
||||
{
|
||||
id: 4,
|
||||
name: 4,
|
||||
imgSrc: require("./../../assets/common/P3-up.png"),
|
||||
imgSrc1: require("./../../assets/common/P3.png")
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
name: 3,
|
||||
imgSrc: require("./../../assets/common/P5-up.png"),
|
||||
imgSrc1: require("./../../assets/common/P5.png"),
|
||||
},
|
||||
{
|
||||
id: 5,
|
||||
name: 5,
|
||||
imgSrc: require("./../../assets/common/P4-up.png"),
|
||||
imgSrc1: require("./../../assets/common/P4.png")
|
||||
}
|
||||
],
|
||||
navIndex: 0,
|
||||
token: "",
|
||||
}
|
||||
},
|
||||
computed:{
|
||||
showAddress() {
|
||||
let address = this.$store.state.user.address;
|
||||
return formatShowAddress(address);
|
||||
},
|
||||
usesPoints() {
|
||||
return this.$store.state.user.userData?.scoreTotal || 0
|
||||
},
|
||||
usesEnhanceCount() {
|
||||
return this.$store.state.user.userData?.enhanceCount || 0
|
||||
},
|
||||
usesInviteCount() {
|
||||
return this.$store.state.user.userData?.inviteCount || 0
|
||||
},
|
||||
},
|
||||
mounted() {
|
||||
this.token = getToken()
|
||||
},
|
||||
methods: {
|
||||
// nav 导航
|
||||
navBtn(index) {
|
||||
this.navIndex = index;
|
||||
this.$emit('toNavBtn',index)
|
||||
},
|
||||
walletLogin() {
|
||||
this.$emit('onWalletLogin')
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.box-top {
|
||||
width: 100%;
|
||||
// height: 100%;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
.left {
|
||||
width: 70%;
|
||||
.left-top {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
padding: 20px 40px;
|
||||
position: inherit;
|
||||
z-index: 9;
|
||||
.left-top-logo {
|
||||
width: 200px;
|
||||
height: 100px;
|
||||
img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
.left-top-points {
|
||||
border-radius: 15px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
.left-top-points-left {
|
||||
display: flex;
|
||||
height: 50px;
|
||||
background: url('@/assets/common/User-bar.png') no-repeat;
|
||||
background-size: 100% 100%;
|
||||
position: relative;
|
||||
padding-right: 30px;
|
||||
margin-right: 30px;
|
||||
li {
|
||||
color: #fff;
|
||||
padding: 10px 20px 5px 40px;
|
||||
position: relative;
|
||||
.hover-tips {
|
||||
display: none;
|
||||
position: absolute;
|
||||
top: 35px;
|
||||
right: 0px;
|
||||
width: 240px;
|
||||
height: 100px;
|
||||
line-height: 90px;
|
||||
font-size: 14px;
|
||||
background: url('@/assets/common/WL .png') no-repeat;
|
||||
background-size: 100% 100%;
|
||||
z-index: 1;
|
||||
}
|
||||
.top {
|
||||
display: flex;
|
||||
justify-content: end;
|
||||
align-items: center;
|
||||
height: 16px;
|
||||
font-weight: 600;
|
||||
text-align: right;
|
||||
span {
|
||||
font-size: 16px;
|
||||
}
|
||||
.textCol1 {
|
||||
color: #9950fd;
|
||||
}
|
||||
.textCol2 {
|
||||
color: #fbc059;
|
||||
}
|
||||
.textCol3 {
|
||||
color: #0095ff;
|
||||
}
|
||||
div {
|
||||
width: 17px;
|
||||
height: 16px;
|
||||
margin-left: 5px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
// img {
|
||||
// width: 100%;
|
||||
// height: 100%;
|
||||
// }
|
||||
}
|
||||
}
|
||||
.btm {
|
||||
font-size: 16px;
|
||||
color: #A8A5AC;
|
||||
text-align: right;
|
||||
}
|
||||
}
|
||||
li:nth-child(1) {
|
||||
cursor: pointer;
|
||||
img {
|
||||
width: 17px;
|
||||
height: 11px;
|
||||
}
|
||||
&:hover {
|
||||
.hover-tips {
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
}
|
||||
li:nth-child(2) {
|
||||
cursor: pointer;
|
||||
img {
|
||||
width: 13px;
|
||||
height: 13px;
|
||||
}
|
||||
&:hover {
|
||||
.hover-tips {
|
||||
display: block;
|
||||
width: 300px;
|
||||
}
|
||||
}
|
||||
}
|
||||
li:nth-child(3) {
|
||||
.top {
|
||||
div {
|
||||
img {
|
||||
width: 15px;
|
||||
height: 15px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
li:nth-child(4) {
|
||||
img {
|
||||
width: 12px;
|
||||
height: 16px;
|
||||
}
|
||||
}
|
||||
.touxiang {
|
||||
width: 60px;
|
||||
height: 60px;
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
right: -20px;
|
||||
transform: translateY(-50%);
|
||||
div {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.left-top-points-right {
|
||||
margin-left: 40px;
|
||||
width: 60px;
|
||||
height: 60px;
|
||||
cursor: pointer;
|
||||
position: relative;
|
||||
img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
.hover-tips {
|
||||
display: none;
|
||||
position: absolute;
|
||||
top: 35px;
|
||||
right: -60px;
|
||||
width: 590px;
|
||||
height: 120px;
|
||||
line-height: 110px;
|
||||
font-size: 14px;
|
||||
background: url('@/assets/common/WL .png') no-repeat;
|
||||
background-size: 100% 100%;
|
||||
}
|
||||
&:hover {
|
||||
.hover-tips {
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.right {
|
||||
width: 28%;
|
||||
padding: 20px 30px;
|
||||
box-sizing: border-box;
|
||||
.right-header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
margin: 10px 50px 10px 0;
|
||||
.right-header-left {
|
||||
.right-header-nav {
|
||||
width: 160px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
li {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
color: #fff;
|
||||
background: #432967;
|
||||
border-radius: 50%;
|
||||
margin-right: 10px;
|
||||
box-sizing: content-box;
|
||||
cursor: pointer;
|
||||
.nav-img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
img {
|
||||
width: 100px;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.active {
|
||||
background: #9950fd;
|
||||
}
|
||||
}
|
||||
}
|
||||
.right-header-right {
|
||||
display: flex;
|
||||
cursor: pointer;
|
||||
.link {
|
||||
width: 100px;
|
||||
height: 40px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
background: #2d2738;
|
||||
border-radius: 20px;
|
||||
margin-right: 20px;
|
||||
li {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin: 0 10px;
|
||||
height: 40px;
|
||||
a {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
div {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
width: 16px;
|
||||
height: 15px;
|
||||
text-align: center;
|
||||
img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.wallet {
|
||||
width: 140px;
|
||||
height: 40px;
|
||||
border-radius: 26px;
|
||||
padding-left: 30px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
background: #2d2738;
|
||||
position: relative;
|
||||
span {
|
||||
color: #fff;
|
||||
margin-right: 10px;
|
||||
font-size: 16px;
|
||||
}
|
||||
.wallet-address {
|
||||
font-size: 16px;
|
||||
color: #fff;
|
||||
}
|
||||
.wallet-btn {
|
||||
z-index: 999;
|
||||
position: absolute;
|
||||
top: -22px;
|
||||
right: -40px;
|
||||
width: 85px;
|
||||
height: 85px;
|
||||
.hover-show {
|
||||
display: block;
|
||||
}
|
||||
.hover-none {
|
||||
// display: none;
|
||||
}
|
||||
img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.nav-btm {
|
||||
// width: 380px;
|
||||
margin: 10px auto;
|
||||
margin-bottom: 0px;
|
||||
.nav {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
li {
|
||||
width: 80px;
|
||||
height: 80px;
|
||||
line-height: 80px;
|
||||
color: #fff;
|
||||
border-radius: 50%;
|
||||
cursor: pointer;
|
||||
.nav-img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
.active {
|
||||
// background: #9950fd;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -1,14 +1,12 @@
|
||||
<template>
|
||||
<div>
|
||||
<el-dialog :visible="Loading" :show-close="false" :modal="false" class="RecentlyLoading">
|
||||
<div class="recentlyTit">
|
||||
<div>
|
||||
<img src="@/assets/common/loding .png" alt />
|
||||
</div>
|
||||
<p>Please wait. Data is currently loading </p>
|
||||
<p>Please wait. Data is loading</p>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
@ -14,18 +14,17 @@
|
||||
<script>
|
||||
export default {
|
||||
props:{
|
||||
currentPage: Number,
|
||||
total: Number,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
pageSize: 6,
|
||||
currentPage: 1,
|
||||
}
|
||||
},
|
||||
mounted() {},
|
||||
methods: {
|
||||
handleCurrentChange(val) {
|
||||
this.currentPage = val
|
||||
this.$emit("onChangePage", val);
|
||||
},
|
||||
},
|
||||
|
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div>
|
||||
<img v-if="imgSrc" :src="imgSrc" alt="">
|
||||
<img v-if="imgSrc" :src="imgSrc" alt="" :onerror="defalutUrl">
|
||||
<img v-else src="@/assets/common/head_default.jpg" alt="">
|
||||
</div>
|
||||
</template>
|
||||
@ -10,7 +10,11 @@ export default {
|
||||
props: {
|
||||
imgSrc: String,
|
||||
},
|
||||
|
||||
data() {
|
||||
return {
|
||||
defalutUrl: 'this.src="' + require('@/assets/common/head_default.jpg') + '"',
|
||||
}
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
|
@ -2,13 +2,13 @@
|
||||
<div class>
|
||||
<el-dialog class="dialog-wallet" :visible.sync="walletDialogVisible" :modal="false" :before-close="handleClose">
|
||||
<div class="dialog-header">
|
||||
<div class="dialog-header-title">Please connect your wallet</div>
|
||||
<div class="dialog-header-title">Connect Your Wallet</div>
|
||||
<div class="dialog-header-close" @click="handleClose">
|
||||
<img src="@/assets/common/CloseButton.png" alt />
|
||||
</div>
|
||||
</div>
|
||||
<div class="dialog-content">
|
||||
<p>Connect your wallet to start your Counter Fire journey</p>
|
||||
<p>Start your treasure hunt journey with Hill.</p>
|
||||
<div class="wallet-content">
|
||||
<li
|
||||
v-for="(item, index1) in isWalletList"
|
||||
@ -35,6 +35,8 @@
|
||||
// import { isWalletConnected, linkWallet, disconnectLink, loginWithEthereum } from './../../wallet/index.js';
|
||||
import { setToken, getToken } from './../../utils/cookies.js'
|
||||
import {Wallet} from '@/wallet/index.js'
|
||||
import { datafluxRum } from "@cloudcare/browser-rum";
|
||||
import marketVersion from '@/utils/version.js'
|
||||
|
||||
export default {
|
||||
props: {
|
||||
@ -52,11 +54,11 @@ export default {
|
||||
name: "OKXwallet",
|
||||
value: "okxwallet",
|
||||
imgUrl: require("./../../assets/home/icon_OKXwallet.png")
|
||||
},
|
||||
{
|
||||
name: "WalletConnect",
|
||||
value: "connect",
|
||||
imgUrl: require("./../../assets/home/icon_ConnectWallet.png")
|
||||
// },
|
||||
// {
|
||||
// name: "WalletConnect",
|
||||
// value: "connect",
|
||||
// imgUrl: require("./../../assets/home/icon_ConnectWallet.png")
|
||||
}
|
||||
],
|
||||
isWallet: !!localStorage.getItem('walletName'),
|
||||
@ -74,7 +76,7 @@ export default {
|
||||
localStorage.setItem('walletName',val)
|
||||
localStorage.setItem('myAddress',res)
|
||||
this.myAddress = res
|
||||
await this.getWalletConnected()
|
||||
await this.getWalletConnected(val)
|
||||
},
|
||||
async disconnect() {
|
||||
let walletName = localStorage.getItem('walletName')
|
||||
@ -85,9 +87,12 @@ export default {
|
||||
},
|
||||
|
||||
// 登录
|
||||
async getWalletConnected() {
|
||||
await this.$store.dispatch('user/login', this.activity)
|
||||
async getWalletConnected(val) {
|
||||
let require = {activity: this.activity, val}
|
||||
await this.$store.dispatch('user/login', require)
|
||||
await this.$store.dispatch('user/fetchUserState')
|
||||
this.eventGtag()
|
||||
localStorage.setItem('myToken',localStorage.getItem('token') )
|
||||
location.reload()
|
||||
},
|
||||
|
||||
@ -137,6 +142,16 @@ export default {
|
||||
localStorage.removeItem('walletName')
|
||||
// location.reload()
|
||||
},
|
||||
|
||||
// Google gtag打点
|
||||
eventGtag() {
|
||||
this.$gtag.event("login_info", {
|
||||
address_type: this.myAddress,
|
||||
})
|
||||
datafluxRum.addRumGlobalContext('login_info', {
|
||||
version: marketVersion,
|
||||
});
|
||||
},
|
||||
}
|
||||
};
|
||||
</script>
|
||||
@ -220,7 +235,7 @@ div {
|
||||
// border: 2px solid #d5befa;
|
||||
}
|
||||
}
|
||||
li:nth-child(4) {
|
||||
li:nth-child(3) {
|
||||
padding-left: 0;
|
||||
background: url('@/assets/common/disconnect.png') no-repeat;
|
||||
background-size: 100% 100%;
|
||||
|
25
src/main.js
@ -7,6 +7,7 @@ import ElementUI from 'element-ui'
|
||||
import 'element-ui/lib/theme-chalk/index.css'
|
||||
import moment from 'moment'
|
||||
import axios from 'axios'
|
||||
import VueGtag from "vue-gtag";
|
||||
import iErrorMsg from './components/errorDialog/index.js'
|
||||
Vue.prototype.$axios = axios
|
||||
|
||||
@ -17,11 +18,16 @@ Vue.use(iErrorMsg)
|
||||
|
||||
import {Message} from 'element-ui'
|
||||
Vue.prototype.$message = Message
|
||||
Vue.prototype.$moment = moment
|
||||
|
||||
Vue.filter('formatDate', function (value) {
|
||||
return moment(value).format('YYYY-MM-DD HH:mm:ss')
|
||||
})
|
||||
|
||||
Vue.use(VueGtag, {
|
||||
config: { id: "G-4KSHDJ3MGL" }
|
||||
}, router);
|
||||
|
||||
// Vue.config.errorHandler = function(err, vm, info){
|
||||
// //todo: show error message
|
||||
// console.error('[vue error handler|error]: ', err)
|
||||
@ -33,6 +39,25 @@ Vue.filter('formatDate', function (value) {
|
||||
// duration: 3 * 1000
|
||||
// })
|
||||
// }
|
||||
/*
|
||||
//引入观测云rum的sdk
|
||||
import { datafluxRum } from '@cloudcare/browser-rum'
|
||||
datafluxRum.init({
|
||||
applicationId: '20efe220_006a_11ef_941d_2d8bd5427e6e',
|
||||
site: 'https://ap1-rum-openway.guance.one',
|
||||
clientToken: '2OQwyC5Quls2McUi6QIUF7mzxD3ryhHDFwIMQHBBfUoiNCR_OQ',
|
||||
env: process.env.VUE_APP_MODE,
|
||||
version: '1.0.0',
|
||||
service: 'browser',
|
||||
sessionSampleRate: 100,
|
||||
sessionReplaySampleRate: 70,
|
||||
trackInteractions: true,
|
||||
traceType: 'ddtrace', // 非必填,默认为ddtrace,目前支持 ddtrace、zipkin、skywalking_v3、jaeger、zipkin_single_header、w3c_traceparent 6种类型
|
||||
allowedTracingOrigins: ['https://api.example.com',/https:\/\/.*\.my-api-domain\.com/], // 非必填,允许注入trace采集器所需header头部的所有请求列表。可以是请求的origin,也可以是是正则
|
||||
});
|
||||
**/
|
||||
|
||||
// datafluxRum.startSessionReplayRecording()
|
||||
|
||||
Vue.config.productionTip = false
|
||||
|
||||
|
@ -11,7 +11,7 @@ const routes = [
|
||||
component: HomeView
|
||||
},
|
||||
{
|
||||
path: '/home/:name/:box/:boxId',
|
||||
path: '/home/:code',
|
||||
name: 'home',
|
||||
component: HomeView
|
||||
},
|
||||
|
@ -24,8 +24,8 @@ const actions = {
|
||||
commit('updateToken', token)
|
||||
commit('updateLoginStatus', true)
|
||||
},
|
||||
async login({ state, commit}, activity) {
|
||||
let token = await new Wallet().loginWithEthereum(activity)
|
||||
async login({ state, commit}, activityList) {
|
||||
let token = await new Wallet().loginWithEthereum(activityList)
|
||||
commit('updateToken', token)
|
||||
},
|
||||
async fetchUserState({ state, commit }) {
|
||||
@ -40,7 +40,7 @@ const actions = {
|
||||
// mutations
|
||||
const mutations = {
|
||||
updateAddress(state, _address) {
|
||||
console.log('update address: ', _address)
|
||||
// console.info('update address: ', _address)
|
||||
state.address = _address
|
||||
},
|
||||
updateChain(state, _chainId) {
|
||||
@ -55,7 +55,7 @@ const mutations = {
|
||||
state.logined = _status
|
||||
},
|
||||
updateUserData(state, _data) {
|
||||
console.log(_data)
|
||||
// console.info(_data)
|
||||
state.userData = { ...state.userData, ..._data }
|
||||
}
|
||||
}
|
||||
|
@ -32,12 +32,12 @@ const actions = {
|
||||
// mutations
|
||||
const mutations = {
|
||||
updateAddress(state, _address) {
|
||||
console.log('update address: ', _address);
|
||||
console.info('update address: ', _address);
|
||||
state.address = _address;
|
||||
state.connected = true;
|
||||
},
|
||||
updateChain(state, _chainId) {
|
||||
console.log('update chain: ', _chainId);
|
||||
console.info('update chain: ', _chainId);
|
||||
state.chainId = _chainId;
|
||||
},
|
||||
updateWalletName(state, _walletName) {
|
||||
|
@ -50,29 +50,22 @@ export const sendToChain = async (type, address, val) => {
|
||||
if (!chainMethods[type]) {
|
||||
throw new Error('Invalid chain method')
|
||||
}
|
||||
const storeageKey = `${address}_${type}_${val || 'default'}`
|
||||
if (localStorage.getItem(storeageKey)) {
|
||||
return
|
||||
}
|
||||
|
||||
if (store.state.wallet.chainId+'' !== process.env.VUE_APP_CHAIN_ID){
|
||||
await new Wallet().changeChain()
|
||||
}
|
||||
|
||||
try {
|
||||
let chainRes = await new Wallet()[chainMethods[type]](address, val)
|
||||
if (!chainRes?.transactionHash) {
|
||||
throw new Error('Failed to claim task')
|
||||
}
|
||||
localStorage.setItem(storeageKey, chainRes.transactionHash)
|
||||
} catch (err) {
|
||||
if (JSON.stringify(err).indexOf('already') != -1) {
|
||||
localStorage.setItem(storeageKey, 'already')
|
||||
} else {
|
||||
if (JSON.stringify(err).indexOf('already') === -1 && err.message.indexOf('already') === -1) {
|
||||
throw err
|
||||
}
|
||||
}
|
||||
|
||||
return storeageKey
|
||||
return 'no_need'
|
||||
}
|
||||
|
||||
// 探索
|
||||
|
52
src/utils/debounce.js
Normal file
@ -0,0 +1,52 @@
|
||||
// 防抖
|
||||
export const debounce = (fn, delay) => {
|
||||
var time = null
|
||||
return function() {
|
||||
let context = this;//记录一下this指向
|
||||
let args = arguments;
|
||||
//清除定时任务
|
||||
if (time) clearTimeout(time);
|
||||
time = setTimeout(function() {
|
||||
time = null;
|
||||
fn.apply(context, args)
|
||||
}, delay)
|
||||
}
|
||||
}
|
||||
|
||||
export const throttle=(fn, delay) => {
|
||||
// 时间戳
|
||||
var timeTwo = 0 //new Date();
|
||||
// 定时器
|
||||
var timeThree = null;
|
||||
return function() {
|
||||
let context = this;
|
||||
let args = arguments;
|
||||
var now = new Date()
|
||||
|
||||
// !!!!时间戳实现【new Date()虽然获取结果不是时间戳但是计算结果会自动转化为时间戳】
|
||||
// if(now-timeTwo>=delay){
|
||||
// fn.apply(context,args);
|
||||
// timeTwo=new Date();
|
||||
// }
|
||||
|
||||
// !!!!定时器实现
|
||||
// if (!timeThree) {
|
||||
// timeThree = setTimeout(function () {
|
||||
// fn.apply(context, args);
|
||||
// timeThree=null;
|
||||
// }, delay)
|
||||
// }
|
||||
|
||||
// 结合 ps:最后一次触发在固定频率内会在延迟后触发
|
||||
var wait = delay - (now - timeTwo)
|
||||
clearTimeout(timeThree)
|
||||
if (wait <= 0) {
|
||||
fn.apply(context, args);
|
||||
timeTwo = new Date();
|
||||
} else {
|
||||
timeThree = setTimeout(function() {
|
||||
fn.apply(context, args);
|
||||
}, delay)
|
||||
}
|
||||
}
|
||||
}
|
2130
src/utils/fingerprint.js
Normal file
4
src/utils/version.js
Normal file
@ -0,0 +1,4 @@
|
||||
// const version = require('./package.json').version
|
||||
|
||||
const marketVersion = '1.0.10'
|
||||
export default marketVersion
|
@ -2,6 +2,7 @@ const API_BASE = process.env.VUE_APP_API_URL.replace('/api', '');
|
||||
import CryptoJS from 'crypto-js'
|
||||
import axios from 'axios'
|
||||
import store from '@/store'
|
||||
import fp from '@/utils/fingerprint.js'
|
||||
|
||||
const toJson = res => res.json();
|
||||
|
||||
@ -65,10 +66,13 @@ export const loginNonce = async (address) => {
|
||||
return nonce;
|
||||
}
|
||||
|
||||
export const loginWithSignature = async (message, signature, activity) => {
|
||||
export const loginWithSignature = async (message, signature, activity, wallet) => {
|
||||
let fps = await fp.load();
|
||||
let result = await fps.get()
|
||||
const clientId = result.clientId;
|
||||
return fetch(`${API_BASE}/api/wallet/login`, {
|
||||
method: "POST",
|
||||
body: JSON.stringify({ message, signature, activity }),
|
||||
body: JSON.stringify({ message, signature, activity,clientId, wallet }),
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
@ -197,6 +201,12 @@ export const apiCheckinClaim = async (days) => {
|
||||
return httpPost(url, { days })
|
||||
}
|
||||
|
||||
// 检查签到领取奖励
|
||||
export const apiCheckinClaimLeak = async (day) => {
|
||||
const url = `${API_BASE}/api/user/checkin`;
|
||||
return httpPost(url, { day })
|
||||
}
|
||||
|
||||
// 积分排行榜
|
||||
export const apiLeaderBoard = async (data) => {
|
||||
const url = `${API_BASE}/api/activity/leaderboard/${data.activity}/${data.page}`;
|
||||
@ -221,16 +231,16 @@ export const apiBoxOpen = async (chestId) => {
|
||||
|
||||
|
||||
export const checkReCaptcha = async(action) =>{
|
||||
const site_key = '6Ld3xoIpAAAAABW7f5ImgAC6GcWLeDCbt5HPXqe2'
|
||||
return new Promise((resolve,reject) => {
|
||||
window.grecaptcha.ready(function() {
|
||||
window.grecaptcha.execute(site_key, { action }).then(function(token) {
|
||||
resolve && resolve(token)
|
||||
}).catch(e => {
|
||||
reject && reject(e)
|
||||
})
|
||||
});
|
||||
})
|
||||
// const site_key = '6Ld3xoIpAAAAABW7f5ImgAC6GcWLeDCbt5HPXqe2'
|
||||
// return new Promise((resolve,reject) => {
|
||||
// window.grecaptcha.ready(function() {
|
||||
// window.grecaptcha.execute(site_key, { action }).then(function(token) {
|
||||
// resolve && resolve(token)
|
||||
// }).catch(e => {
|
||||
// reject && reject(e)
|
||||
// })
|
||||
// });
|
||||
// })
|
||||
}
|
||||
|
||||
// 转发推特
|
||||
@ -258,3 +268,85 @@ export const apiNftList = async () => {
|
||||
const url = `${API_BASE}/api/partner/nfts`;
|
||||
return httpPost(url, {})
|
||||
}
|
||||
|
||||
// 领取NFT holder 奖励
|
||||
export const apiClaimNft = async (contract) => {
|
||||
const url = `${API_BASE}/api/partner/claim`;
|
||||
return httpPost(url, {contract})
|
||||
}
|
||||
|
||||
// 宝箱激活码
|
||||
export const apiVoucherClaim = async (id) => {
|
||||
const url = `${API_BASE}/api/voucher/claim`;
|
||||
return httpPost(url, {id})
|
||||
}
|
||||
|
||||
// google 验证
|
||||
export const apiVerifyGoogle = async (code) => {
|
||||
const url = `${API_BASE}/api/user/verify_google`;
|
||||
return httpPost(url, {code})
|
||||
}
|
||||
|
||||
// google 验证
|
||||
export const apiMyNftList = async () => {
|
||||
const url = `${API_BASE}/api/ingame/nft_list`;
|
||||
return httpGet(url, {})
|
||||
}
|
||||
|
||||
// 游戏任务列表
|
||||
export const apiGameTasks = async () => {
|
||||
const url = `${API_BASE}/api/ingame/tasks`;
|
||||
return httpGet(url, {})
|
||||
}
|
||||
|
||||
// 领取游戏任务奖励
|
||||
export const apiGameClaim = async (task) => {
|
||||
const url = `${API_BASE}/api/ingame/claim`;
|
||||
return httpPost(url, {task})
|
||||
}
|
||||
|
||||
// 抽奖
|
||||
export const apiDrawCfg = async () => {
|
||||
const url = `${API_BASE}/api/ingame/draw_cfg`;
|
||||
return httpGet(url, {})
|
||||
}
|
||||
|
||||
// 抽奖
|
||||
export const apiDraw = async (step) => {
|
||||
const url = `${API_BASE}/api/ingame/draw`;
|
||||
return httpPost(url, {step})
|
||||
}
|
||||
|
||||
// 抽奖记录
|
||||
export const apiDrawHistory = async () => {
|
||||
const url = `${API_BASE}/api/ingame/draw_history`;
|
||||
return httpGet(url, {})
|
||||
}
|
||||
|
||||
// 发送邮件验证码
|
||||
export const apiSendCode = async (email) => {
|
||||
const url = `${API_BASE}/api/email/send_code`;
|
||||
return httpPost(url, {email})
|
||||
}
|
||||
|
||||
// 发送邮件验证码
|
||||
export const apiVerifyEmail = async (email, code) => {
|
||||
const url = `${API_BASE}/api/user/verify_email`;
|
||||
return httpPost(url, {email, code})
|
||||
}
|
||||
|
||||
// 发送客户端验证码
|
||||
export const apiVerifyClient = async (code) => {
|
||||
const url = `${API_BASE}/api/user/verify_client`;
|
||||
return httpPost(url, {code})
|
||||
}
|
||||
|
||||
// 活动时间结束
|
||||
export const endActivity = async (time) => {
|
||||
var now = new Date().getTime();
|
||||
if(time <= now) {
|
||||
return false
|
||||
} else {
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div>
|
||||
<!-- 成功获得奖品弹窗 -->
|
||||
<el-dialog class="Explore-dialog" :visible.sync="ExploreDialogVisible" :modal="false" :before-close="ExploreDialog">
|
||||
<el-dialog class="Explore-dialog" :visible.sync="ExploreDialogVisible" :modal="false" :before-close="ExploreDialog" @opened="openedDialog" @closed="closedDialog">
|
||||
<div v-if="eventName == 'explore_event'">
|
||||
<div class="top">
|
||||
<div class="top-title" v-if="awardData.chests.length != 0">{{ dialogTitle }}</div>
|
||||
@ -10,16 +10,16 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="content" v-if="awardData.chests.length != 0">
|
||||
<div class="content-points">
|
||||
<!-- <div class="content-points">
|
||||
<div>Points</div>
|
||||
<div>
|
||||
<span>X {{ awardData.score }}</span>
|
||||
<img src="./../../assets/common/Icon_Points.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
<div class="content-list">
|
||||
<li v-if="level1.length !=0">
|
||||
<div class="title">Normal Chest</div>
|
||||
<div class="title">Common Chest</div>
|
||||
<div class="box-img">
|
||||
<img :src="require(`./../../assets/box/box${level1[0].level}.png`)" alt="">
|
||||
</div>
|
||||
@ -29,7 +29,7 @@
|
||||
</div>
|
||||
</li>
|
||||
<li v-if="level2.length !=0">
|
||||
<div class="title">Advanced Chest</div>
|
||||
<div class="title">Rare Chest</div>
|
||||
<div class="box-img">
|
||||
<img :src="require(`./../../assets/box/box${level2[0].level}.png`)" alt="">
|
||||
</div>
|
||||
@ -39,7 +39,7 @@
|
||||
</div>
|
||||
</li>
|
||||
<li v-if="level3.length !=0">
|
||||
<div class="title">Epic Chest</div>
|
||||
<div class="title">Mythical Chest</div>
|
||||
<div class="box-img">
|
||||
<img :src="require(`./../../assets/box/box${level3[0].level}.png`)" alt="">
|
||||
</div>
|
||||
@ -72,7 +72,7 @@
|
||||
</div>
|
||||
<div class="btn" @click="ExploreDialog">Confirm</div>
|
||||
</div>
|
||||
<div v-else-if="eventName == 'help_event' || eventName == 'check_event'">
|
||||
<div v-else-if="eventName == 'help_event' || eventName == 'check_event' || eventName == 'game_event'">
|
||||
<div class="top">
|
||||
<div class="top-title"></div>
|
||||
<div class="top-close" @click="ExploreDialog">
|
||||
@ -82,23 +82,110 @@
|
||||
<div class="content">
|
||||
<div class="points-title">{{ dialogTitle }}</div>
|
||||
<div class="points-amount" v-if="awardData.score">
|
||||
<div v-if="eventName == 'game_event'">Gems</div>
|
||||
<div v-else>Points</div>
|
||||
<div>
|
||||
<span>X {{ awardData.score }}</span>
|
||||
<img v-if="eventName == 'game_event'" class="points-turn" src="./../../assets/common/type0.png" alt="">
|
||||
<img v-else src="./../../assets/common/Icon_Points.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
<div class="points-amount" v-if="awardData.ticket">
|
||||
<div v-if="eventName == 'game_event'">Spins</div>
|
||||
<div v-else>Explore</div>
|
||||
<div>
|
||||
<span>X {{ awardData.ticket }}</span>
|
||||
<img v-if="eventName == 'game_event'" class="points-turn" src="./../../assets/common/Turntable .png" alt="">
|
||||
<img v-else src="./../../assets/common/Icon_Explore9.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div>Complete tasks to get more rewards</div> -->
|
||||
</div>
|
||||
<div class="btn" v-if="awardData.isNewUser == 0" @click="toComplete">Done</div>
|
||||
<div class="btn" v-else @click="ExploreDialog">Confirm</div>
|
||||
</div>
|
||||
<div v-else-if="eventName == 'box_event'">
|
||||
<div class="top">
|
||||
<div class="top-title" v-if="awardData.items.length != 0">{{ dialogTitle }}</div>
|
||||
<div class="top-close" @click="ExploreDialog">
|
||||
<img src="./../../assets/common/CloseButton.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
<div class="content" v-if="awardData.items.length != 0">
|
||||
<div class="content-points">
|
||||
<div>Points</div>
|
||||
<div>
|
||||
<span>X {{ awardData.score }}</span>
|
||||
<img src="./../../assets/common/Icon_Points.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
<div class="points-amount" v-if="awardData.ticket">
|
||||
<div>Explore</div>
|
||||
<div class="content-list">
|
||||
<li v-for="(item, index) in awardData.items" :key="index">
|
||||
<div class="title">{{ item.name }}</div>
|
||||
<div v-if="item.name == 'NFT'" class="box-img nft">
|
||||
<img src="@/assets/common/Normal_GIF_1.gif" alt="">
|
||||
</div>
|
||||
<div v-else class="box-img">
|
||||
<img src="@/assets/common/whitelist01.png" alt="">
|
||||
</div>
|
||||
<!-- <div class="box-bg"></div> -->
|
||||
<div class="amount">
|
||||
</div>
|
||||
</li>
|
||||
</div>
|
||||
</div>
|
||||
<div class="content" v-else>
|
||||
<div class="points-title">{{ dialogTitle }}</div>
|
||||
<div class="points-amount">
|
||||
<div>Points</div>
|
||||
<div>
|
||||
<span>X {{ awardData.ticket }}</span>
|
||||
<img src="./../../assets/common/Icon_Explore9.png" alt="">
|
||||
<span>X {{ awardData.score }}</span>
|
||||
<img src="@/assets/common/Icon_Points.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
<div>Complete tasks to get more rewards</div>
|
||||
</div>
|
||||
<div class="btn" v-if="awardData.isNewUser == 0" @click="toComplete">To complete</div>
|
||||
<div class="btn" v-else @click="ExploreDialog">Confirm</div>
|
||||
<div class="btn" @click="ExploreDialog">Confirm</div>
|
||||
</div>
|
||||
<div v-if="eventName == 'turn_event'">
|
||||
<div class="top">
|
||||
<div class="top-title"></div>
|
||||
<div class="top-close" @click="ExploreDialog">
|
||||
<img src="./../../assets/common/CloseButton.png" alt="">
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="content">
|
||||
<div class="points-title">{{ dialogTitle }}</div>
|
||||
<div v-if="awardData.ticket" class="points-amount">
|
||||
<div>Spins</div>
|
||||
<div>
|
||||
<span>X {{ awardData.ticket }}</span>
|
||||
<img class="points-turn" src="@/assets/common/Turntable .png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="awardData.score" class="points-amount">
|
||||
<div>Gems</div>
|
||||
<div>
|
||||
<span>X {{ awardData.score }}</span>
|
||||
<img class="points-turn" src="@/assets/common/type0.png" alt="">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="awardData.items !== undefined && awardData.items.length > 0" class="content-list">
|
||||
<li v-for="(item, index) in awardData.items" :key="index">
|
||||
<div class="title">{{ item.name }}</div>
|
||||
<div v-if="item.name == 'NFT'" class="box-img nft">
|
||||
<img src="@/assets/common/Normal_GIF_1.gif" alt="">
|
||||
</div>
|
||||
<div v-else class="box-img">
|
||||
<img src="@/assets/common/whitelist01.png" alt="">
|
||||
</div>
|
||||
<!-- <div class="box-bg"></div> -->
|
||||
<div class="amount">
|
||||
</div>
|
||||
</li>
|
||||
</div>
|
||||
<div class="btn" @click="ExploreDialog">{{ timeLeft }}s Confirm</div>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
@ -115,13 +202,18 @@ export default {
|
||||
level3: Array,
|
||||
level4: Array,
|
||||
dialogTitle: String,
|
||||
// turnTime: Number
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
timeLeft: 0,
|
||||
turnTime: 2,
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
},
|
||||
watch: {
|
||||
},
|
||||
mounted() {
|
||||
},
|
||||
methods: {
|
||||
@ -130,7 +222,22 @@ export default {
|
||||
},
|
||||
toComplete() {
|
||||
this.$emit('toComplete', 0)
|
||||
}
|
||||
},
|
||||
beginCountdown() {
|
||||
this.timeLeft = parseInt(this.turnTime);
|
||||
let timer = setInterval(() => {
|
||||
this.timeLeft--;
|
||||
if (this.timeLeft <= 0) {
|
||||
clearInterval(timer);
|
||||
}
|
||||
}, 1000);
|
||||
},
|
||||
openedDialog() {
|
||||
this.beginCountdown()
|
||||
},
|
||||
closedDialog() {
|
||||
this.turnTime = 2
|
||||
},
|
||||
},
|
||||
}
|
||||
</script>
|
||||
@ -226,6 +333,10 @@ div {
|
||||
height: 100%;
|
||||
}
|
||||
}
|
||||
.nft {
|
||||
width: 160px;
|
||||
height: 200px;
|
||||
}
|
||||
.box-bg {
|
||||
width: 160px;
|
||||
height: 120px;
|
||||
@ -275,6 +386,13 @@ div {
|
||||
}
|
||||
}
|
||||
}
|
||||
.points-turn {
|
||||
|
||||
width: 15px !important;
|
||||
height: 14px !important;
|
||||
margin-left: 5px;
|
||||
|
||||
}
|
||||
}
|
||||
.btn {
|
||||
width: 200px;
|
||||
|