diff --git a/Dockerfile b/Dockerfile index 94bfb4365..18f8b4c8e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM node:20-bullseye +FROM node:20-bookworm RUN apt update RUN apt install build-essential zip -y ENV HOME /home diff --git a/package.json b/package.json index 757c7ce4c..6a9e4295f 100644 --- a/package.json +++ b/package.json @@ -31,12 +31,12 @@ "devDependencies": { "@commitlint/cli": "^17.8.1", "@commitlint/config-conventional": "^17.8.1", - "@swc/core": "^1.3.104", + "@swc/core": "^1.4.4", "concurrently": "^8.2.2", "devmoji": "^2.3.0", "husky": "^8.0.3", "node-notifier": "^10.0.1", - "nodemon": "^3.0.3", + "nodemon": "^3.1.0", "ultra-runner": "^3.10.5" }, "resolutions": { diff --git a/packages/extension-bridge/package.json b/packages/extension-bridge/package.json index 78be5c8b5..69a2e0b6f 100644 --- a/packages/extension-bridge/package.json +++ b/packages/extension-bridge/package.json @@ -39,14 +39,14 @@ "webextension-polyfill": "^0.10.0" }, "devDependencies": { - "@types/chai": "^4.3.11", + "@types/chai": "^4.3.12", "@types/mocha": "^10.0.6", - "@types/node": "^20.11.5", + "@types/node": "^20.11.24", "@types/webextension-polyfill": "^0.10.7", "@typescript-eslint/eslint-plugin": "^5.62.0", "@typescript-eslint/parser": "^5.62.0", - "bumpp": "^9.3.0", - "eslint": "^8.56.0", + "bumpp": "^9.4.0", + "eslint": "^8.57.0", "eslint-config-airbnb-base": "^15.0.0", "eslint-config-prettier": "^8.10.0", "eslint-import-resolver-alias": "^1.1.2", diff --git a/packages/extension/configs/browser-build.js b/packages/extension/configs/browser-build.js index 5e58648dd..1aad7c06f 100644 --- a/packages/extension/configs/browser-build.js +++ b/packages/extension/configs/browser-build.js @@ -62,6 +62,9 @@ const setConfig = (config) => { }); config.plugin("copy-manifest").use(copyManifest); config.plugin("define").tap((args) => { + Object.assign(args[0], { + __VUE_PROD_HYDRATION_MISMATCH_DETAILS__: "false", + }); const _base = args[0]["process.env"]; args[0]["process.env"] = { ..._base, diff --git a/packages/extension/package.json b/packages/extension/package.json index e449dabcb..ebba978ec 100644 --- a/packages/extension/package.json +++ b/packages/extension/package.json @@ -1,6 +1,6 @@ { "name": "@enkryptcom/extension", - "version": "1.34.0", + "version": "1.35.0", "private": true, "scripts": { "zip": "cd dist; zip -r release.zip *;", @@ -30,10 +30,10 @@ "@enkryptcom/utils": "workspace:^", "@ethereumjs/common": "^3.2.0", "@ethereumjs/tx": "^4.2.0", - "@ledgerhq/hw-transport-webusb": "^6.28.1", + "@ledgerhq/hw-transport-webusb": "^6.28.4", "@metamask/eth-sig-util": "^7.0.1", "@rollup/plugin-replace": "^5.0.5", - "@types/chrome": "^0.0.258", + "@types/chrome": "^0.0.262", "@types/events": "^3.0.3", "@types/less": "^3.0.6", "@types/lodash": "^4.14.202", @@ -45,8 +45,8 @@ "bitcoinjs-lib": "^6.1.5", "chai": "^4.4.1", "concurrently": "^8.2.2", - "core-js": "^3.35.0", - "echarts": "^5.4.3", + "core-js": "^3.36.0", + "echarts": "^5.5.0", "ethereumjs-abi": "^0.6.8", "ethereumjs-util": "^7.1.5", "ethereumjs-wallet": "^1.0.2", @@ -60,25 +60,25 @@ "switch-ts": "^1.1.1", "url-parse": "^1.5.10", "uuid": "^9.0.1", - "vue": "^3.4.15", - "vue-echarts": "6.6.8", - "vue-router": "4.2.5", + "vue": "^3.4.21", + "vue-echarts": "6.6.9", + "vue-router": "4.3.0", "vue3-lottie": "^2.7.4", "vuedraggable": "^4.1.0", - "web3-eth": "^1.10.3", - "web3-utils": "^1.10.3", + "web3-eth": "^1.10.4", + "web3-utils": "^1.10.4", "yarn": "^1.22.21", "zxcvbn": "^4.4.2" }, "devDependencies": { "@babel/plugin-transform-class-static-block": "^7.23.4", - "@polkadot/api": "^10.11.2", - "@polkadot/extension-inject": "^0.46.6", + "@polkadot/api": "^10.12.1", + "@polkadot/extension-inject": "^0.46.7", "@polkadot/keyring": "^12.6.2", - "@polkadot/rpc-provider": "^10.11.2", - "@polkadot/types": "^10.11.2", - "@polkadot/types-known": "^10.11.2", - "@polkadot/ui-shared": "^3.6.4", + "@polkadot/rpc-provider": "^10.12.1", + "@polkadot/types": "^10.12.1", + "@polkadot/types-known": "^10.12.1", + "@polkadot/ui-shared": "^3.6.5", "@polkadot/util": "^12.6.2", "@polkadot/wasm-crypto": "^7.3.2", "@rollup/plugin-commonjs": "^25.0.7", @@ -88,7 +88,7 @@ "@types/ethereumjs-abi": "^0.6.5", "@types/mocha": "^10.0.6", "@types/url-parse": "^1.4.11", - "@types/uuid": "^9.0.7", + "@types/uuid": "^9.0.8", "@types/wif": "^2.0.5", "@types/zxcvbn": "^4.4.4", "@typescript-eslint/eslint-plugin": "^5.62.0", @@ -101,23 +101,23 @@ "buffer": "^6.0.3", "cross-env": "^7.0.3", "crypto-browserify": "^3.12.0", - "eslint": "^8.56.0", + "eslint": "^8.57.0", "eslint-config-prettier": "^8.10.0", "eslint-plugin-prettier": "^4.2.1", "eslint-plugin-vue": "^8.7.1", "https-browserify": "^1.0.0", "less": "^4.2.0", "less-loader": "^11.1.4", - "mocha": "^10.2.0", + "mocha": "^10.3.0", "path-browserify": "^1.0.1", "prettier": "^2.8.8", "rimraf": "^5.0.5", "rollup": "^3.29.4", "rollup-plugin-uglify": "^6.0.4", - "semver": "^7.5.4", + "semver": "^7.6.0", "stream-browserify": "^3.0.0", "stream-http": "^3.2.0", - "systeminformation": "^5.21.22", + "systeminformation": "^5.22.0", "ts-mocha": "^10.0.0", "tsconfig-paths": "^4.2.0", "typescript": "^4.9.5", diff --git a/packages/extension/src/providers/bitcoin/ui/send-transaction/index.vue b/packages/extension/src/providers/bitcoin/ui/send-transaction/index.vue index 3d9715151..4f15be7c9 100644 --- a/packages/extension/src/providers/bitcoin/ui/send-transaction/index.vue +++ b/packages/extension/src/providers/bitcoin/ui/send-transaction/index.vue @@ -282,7 +282,13 @@ const isInputsValid = computed(() => { !isAddress(addressTo.value, (props.network as BitcoinNetwork).networkInfo) ) return false; - if (!isValidDecimals(sendAmount.value, selectedAsset.value.decimals!)) { + if ( + isSendToken.value && + !isValidDecimals(sendAmount.value, selectedAsset.value.decimals!) + ) { + return false; + } + if (!isSendToken.value && !selectedNft.value.id) { return false; } if ( diff --git a/packages/extension/src/providers/ethereum/libs/activity-handlers/providers/etherscan/configs.ts b/packages/extension/src/providers/ethereum/libs/activity-handlers/providers/etherscan/configs.ts index 1acf4296a..ef4490c5b 100644 --- a/packages/extension/src/providers/ethereum/libs/activity-handlers/providers/etherscan/configs.ts +++ b/packages/extension/src/providers/ethereum/libs/activity-handlers/providers/etherscan/configs.ts @@ -34,8 +34,9 @@ const NetworkEndpoints: Record = { "https://parallel-stormy-spica.explorer.mainnet.skalenodes.com/", [NetworkNames.SkaleChaos]: "https://staging-fast-active-bellatrix.explorer.staging-v3.skalenodes.com/", - [NetworkNames.ZkSyncGoerli]: "https://zksync2-testnet.zkscan.io/", - [NetworkNames.ZkSync]: "https://zksync2-mainnet.zkscan.io/", + [NetworkNames.ZkSyncGoerli]: + "https://block-explorer-api.testnets.zksync.dev/", + [NetworkNames.ZkSync]: "https://block-explorer-api.mainnet.zksync.io/", [NetworkNames.Arbitrum]: "https://api.arbiscan.io/", [NetworkNames.Gnosis]: "https://api.gnosisscan.io/", [NetworkNames.Avalanche]: "https://api.snowtrace.io/", @@ -46,7 +47,6 @@ const NetworkEndpoints: Record = { [NetworkNames.MaticZK]: "https://api-zkevm.polygonscan.com/", [NetworkNames.Base]: "https://api.basescan.org/", [NetworkNames.Celo]: "https://explorer.celo.org/mainnet/", - [NetworkNames.Arthera]: "https://explorer-test.arthera.net/", [NetworkNames.FormTestnet]: "https://testnet-explorer.form.network/", [NetworkNames.ArtheraTest]: "https://explorer-test.arthera.net/", [NetworkNames.Arthera]: "https://explorer.arthera.net/", diff --git a/packages/extension/src/providers/ethereum/methods/enkrypt_getPublicKey.ts b/packages/extension/src/providers/ethereum/methods/enkrypt_getPublicKey.ts index 3a6ce5fe5..49e989047 100644 --- a/packages/extension/src/providers/ethereum/methods/enkrypt_getPublicKey.ts +++ b/packages/extension/src/providers/ethereum/methods/enkrypt_getPublicKey.ts @@ -15,7 +15,7 @@ const method: MiddlewareFunction = async function ( ): Promise { if (payload.method !== "enkrypt_getPublicKey") return next(); else { - const whitelistDomains = ["localhost", "raffle.enkrypt.com"]; + const whitelistDomains = ["localhost", "giveaway.enkrypt.com"]; if (!whitelistDomains.includes(payload.options?.domain || "".toLowerCase())) return res(getCustomError("Cannot call this method from this domain")); const isInitialized = await this.KeyRing.isInitialized(); diff --git a/packages/extension/src/providers/ethereum/networks/zksync.ts b/packages/extension/src/providers/ethereum/networks/zksync.ts index 5dbb4005c..a1925cc9e 100644 --- a/packages/extension/src/providers/ethereum/networks/zksync.ts +++ b/packages/extension/src/providers/ethereum/networks/zksync.ts @@ -21,7 +21,6 @@ const zkSyncOptions: EvmNetworkOptions = { coingeckoPlatform: CoingeckoPlatform.Zksync, NFTHandler: shNFTHandler, assetsInfoHandler, - activityHandler: wrapActivityHandler(EtherscanActivity), }; diff --git a/packages/extension/src/providers/ethereum/ui/send-transaction/index.vue b/packages/extension/src/providers/ethereum/ui/send-transaction/index.vue index 9d0eae8cd..d27d0153e 100644 --- a/packages/extension/src/providers/ethereum/ui/send-transaction/index.vue +++ b/packages/extension/src/providers/ethereum/ui/send-transaction/index.vue @@ -474,7 +474,13 @@ const isValidSend = computed(() => { const isInputsValid = computed(() => { if (!props.network.isAddress(addressTo.value)) return false; - if (!isValidDecimals(sendAmount.value, selectedAsset.value.decimals!)) { + if ( + isSendToken.value && + !isValidDecimals(sendAmount.value, selectedAsset.value.decimals!) + ) { + return false; + } + if (!isSendToken.value && !selectedNft.value.id) { return false; } if (new BigNumber(sendAmount.value).gt(assetMaxValue.value)) return false; diff --git a/packages/extension/src/ui/action/views/send-transaction/index.vue b/packages/extension/src/ui/action/views/send-transaction/index.vue index 4c9032abf..d22c2bdeb 100644 --- a/packages/extension/src/ui/action/views/send-transaction/index.vue +++ b/packages/extension/src/ui/action/views/send-transaction/index.vue @@ -1,5 +1,9 @@