diff --git a/env.json b/env.json index f094177e9..c56a87b0a 100644 --- a/env.json +++ b/env.json @@ -8,6 +8,7 @@ "FEATURE_FLAGS": { "moonpay": true }, + "SUBQUERY_ENDPOINT": "https://api.subquery.network/sq/sora-xor/sora", "DEFAULT_NETWORKS": [ { "chain": "SORA", @@ -26,8 +27,8 @@ }, { "chain": "SORA", - "name": "SORA Community (Lux8)", - "address": "wss://sora.lux8.net" + "name": "OnFinality", + "address": "wss://sora.api.onfinality.io/public-ws" } ], "NETWORK_TYPE": "Prod", diff --git a/package.json b/package.json index fee6e255a..5239c9bde 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "polkaswap-exchange-web", - "version": "1.7.0", + "version": "1.8.0", "license": "Apache-2.0", "private": true, "author": "jihoon@tutanota.de ", @@ -20,9 +20,10 @@ }, "dependencies": { "@metamask/detect-provider": "^1.2.0", - "@soramitsu/soraneo-wallet-web": "^1.7.31", + "@soramitsu/soraneo-wallet-web": "1.8.23", "@walletconnect/web3-provider": "^1.6.6", "core-js": "^3.6.4", + "direct-vuex": "^0.12.1", "ethers": "^5.5.4", "lodash": "^4.17.21", "vue": "^2.6.14", @@ -30,8 +31,7 @@ "vue-i18n": "^8.11.2", "vue-property-decorator": "^9.1.2", "vue-router": "^3.5.3", - "vuex": "^3.1.3", - "vuex-class": "^0.3.2" + "vuex": "^3.1.3" }, "devDependencies": { "@babel/runtime": "^7.12.5", @@ -74,6 +74,7 @@ "ts-jest": "^27.0.5", "typescript": "~4.4.4", "vue-cli-plugin-electron-builder": "^3.0.0-alpha.3", + "vue-svg-loader": "^0.16.0", "vue-template-compiler": "^2.6.14" }, "gitHooks": { diff --git a/public/env.json b/public/env.json index 49a34a2f3..820dc7c22 100644 --- a/public/env.json +++ b/public/env.json @@ -9,6 +9,7 @@ "moonpay": true }, "FAUCET_URL": "https://faucet.dev.sora2.tachi.soramitsu.co.jp/", + "SUBQUERY_ENDPOINT": "https://api.subquery.network/sq/sora-xor/sora-dev", "DEFAULT_NETWORKS": [ { "chain": "SORA-dev Testnet", diff --git a/public/index.html b/public/index.html index 1488f4f51..68c90fa7e 100644 --- a/public/index.html +++ b/public/index.html @@ -27,8 +27,7 @@ - - + @@ -36,8 +35,8 @@ - - + + diff --git a/src/App.vue b/src/App.vue index de83b8b20..b752b7bf5 100644 --- a/src/App.vue +++ b/src/App.vue @@ -6,9 +6,10 @@ :visible="menuVisibility" :on-select="goTo" :is-about-page-opened="isAboutPage" + @open-download-dialog="openDownloadDialog" @click.native="handleAppMenuClick" > - +
@@ -35,27 +36,31 @@
+ + diff --git a/src/components/Bridge/TransferNotification.vue b/src/components/Bridge/TransferNotification.vue new file mode 100644 index 000000000..095c15b71 --- /dev/null +++ b/src/components/Bridge/TransferNotification.vue @@ -0,0 +1,124 @@ + + + + + + + diff --git a/src/components/ConfirmBridgeTransactionDialog.vue b/src/components/ConfirmBridgeTransactionDialog.vue index 314c5ddcb..dc9d34fe4 100644 --- a/src/components/ConfirmBridgeTransactionDialog.vue +++ b/src/components/ConfirmBridgeTransactionDialog.vue @@ -53,7 +53,7 @@ + + + + diff --git a/src/components/Moonpay/Moonpay.vue b/src/components/Moonpay/Moonpay.vue index 30afb6269..897597066 100644 --- a/src/components/Moonpay/Moonpay.vue +++ b/src/components/Moonpay/Moonpay.vue @@ -9,7 +9,6 @@ - - diff --git a/src/components/PairTokenLogo.vue b/src/components/PairTokenLogo.vue index 6a1887c5a..0aca9f838 100644 --- a/src/components/PairTokenLogo.vue +++ b/src/components/PairTokenLogo.vue @@ -1,7 +1,7 @@ @@ -10,12 +10,13 @@ import { Component, Mixins, Prop } from 'vue-property-decorator'; import type { AccountAsset, Asset } from '@sora-substrate/util/build/assets/types'; import TranslationMixin from '@/components/mixins/TranslationMixin'; -import { LogoSize, Components, ObjectInit } from '@/consts'; -import { lazyComponent } from '@/router'; +import { LogoSize, ObjectInit } from '@/consts'; + +import { components } from '@soramitsu/soraneo-wallet-web'; @Component({ components: { - TokenLogo: lazyComponent(Components.TokenLogo), + TokenLogo: components.TokenLogo, }, }) export default class PairTokenLogo extends Mixins(TranslationMixin) { diff --git a/src/components/Referrals/ConfirmBonding.vue b/src/components/Referrals/ConfirmBonding.vue index f39bfe639..225e7049e 100644 --- a/src/components/Referrals/ConfirmBonding.vue +++ b/src/components/Referrals/ConfirmBonding.vue @@ -1,5 +1,4 @@
- +
import { Component, Mixins } from 'vue-property-decorator'; -import { Action, Getter } from 'vuex-class'; import { FPNumber } from '@sora-substrate/util'; import { components, mixins } from '@soramitsu/soraneo-wallet-web'; import TranslationMixin from '@/components/mixins/TranslationMixin'; import { lazyComponent } from '@/router'; import { Components } from '@/consts'; +import { state, mutation } from '@/store/decorators'; +import type { TabItem } from '@/types/tabs'; @Component({ components: { @@ -53,8 +54,8 @@ import { Components } from '@/consts'; }) export default class SlippageTolerance extends Mixins(mixins.NumberFormatterMixin, TranslationMixin) { readonly delimiters = FPNumber.DELIMITERS_CONFIG; - readonly SlippageToleranceTabs: Array = ['0.1', '0.5', '1'].map((name) => ({ - name: String(name), + readonly SlippageToleranceTabs: Array = ['0.1', '0.5', '1'].map((name) => ({ + name: name, label: `${this.formatStringValue(name)}%`, })); @@ -66,11 +67,11 @@ export default class SlippageTolerance extends Mixins(mixins.NumberFormatterMixi slippageToleranceFocused = false; slippageToleranceOpened = true; - @Getter slippageTolerance!: string; - @Getter transactionDeadline!: number; - @Getter nodeAddress!: { ip: string; port: number }; - @Action setSlippageTolerance!: (value: string) => Promise; - @Action setTransactionDeadline!: any; + @state.settings.slippageTolerance slippageTolerance!: string; + @state.settings.transactionDeadline transactionDeadline!: number; + + @mutation.settings.setSlippageTolerance private setSlippageTolerance!: (value: string) => void; + @mutation.settings.setTransactionDeadline private setTransactionDeadline!: (value: number) => void; get customSlippageTolerance(): string { const suffix = this.slippageToleranceFocused ? '' : '%'; diff --git a/src/components/SimpleNotification.vue b/src/components/SimpleNotification.vue new file mode 100644 index 000000000..2ff522569 --- /dev/null +++ b/src/components/SimpleNotification.vue @@ -0,0 +1,73 @@ + + + + + diff --git a/src/components/TokenLogo.vue b/src/components/TokenLogo.vue deleted file mode 100644 index 096590c63..000000000 --- a/src/components/TokenLogo.vue +++ /dev/null @@ -1,158 +0,0 @@ - - - - - diff --git a/src/components/TransactionDetails/AddLiquidityTransactionDetails.vue b/src/components/TransactionDetails/AddLiquidityTransactionDetails.vue index 843b42b16..79029d340 100644 --- a/src/components/TransactionDetails/AddLiquidityTransactionDetails.vue +++ b/src/components/TransactionDetails/AddLiquidityTransactionDetails.vue @@ -15,11 +15,11 @@

{{ t('createPair.pricePool') }}

@@ -38,14 +38,14 @@ @@ -56,18 +56,18 @@ diff --git a/src/components/TransactionDetails/SwapTransactionDetails.vue b/src/components/TransactionDetails/SwapTransactionDetails.vue index df022c407..dfaf31573 100644 --- a/src/components/TransactionDetails/SwapTransactionDetails.vue +++ b/src/components/TransactionDetails/SwapTransactionDetails.vue @@ -44,7 +44,6 @@ diff --git a/src/views/BridgeTransactionsHistory.vue b/src/views/BridgeTransactionsHistory.vue index 433b285ba..ffcb0688a 100644 --- a/src/views/BridgeTransactionsHistory.vue +++ b/src/views/BridgeTransactionsHistory.vue @@ -3,24 +3,15 @@ - - - - - + +