From 263f0a56df23df177257ba68c954a3a7d0e38d57 Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Tue, 28 Jun 2022 14:08:04 -0600 Subject: [PATCH 01/17] Release 2.2.0 - Develop (#1103) * Update react package version * Update version for release branch * Update versions, remove alpha tag for publish * Update to latest SDK for bugfix, modify to new API * Update package versions * Update .github/ISSUE_TEMPLATE/BUG.yml * Bump monorepo version to minor instead of patch --- .github/ISSUE_TEMPLATE/BUG.yml | 2 +- package.json | 2 +- packages/coinbase/package.json | 4 ++-- packages/common/package.json | 2 +- packages/core/package.json | 4 ++-- packages/dcent/package.json | 4 ++-- packages/demo/package.json | 30 ++++++++++++++--------------- packages/fortmatic/package.json | 4 ++-- packages/gnosis/package.json | 4 ++-- packages/injected/package.json | 4 ++-- packages/keepkey/package.json | 4 ++-- packages/keystone/package.json | 4 ++-- packages/ledger/package.json | 4 ++-- packages/magic/package.json | 4 ++-- packages/mew/package.json | 4 ++-- packages/portis/package.json | 4 ++-- packages/react/package.json | 6 +++--- packages/torus/package.json | 4 ++-- packages/trezor/package.json | 4 ++-- packages/vue/package.json | 6 +++--- packages/walletconnect/package.json | 4 ++-- packages/walletlink/package.json | 4 ++-- packages/web3auth/package.json | 4 ++-- 23 files changed, 58 insertions(+), 58 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/BUG.yml b/.github/ISSUE_TEMPLATE/BUG.yml index 80ad0afff..639ffb678 100644 --- a/.github/ISSUE_TEMPLATE/BUG.yml +++ b/.github/ISSUE_TEMPLATE/BUG.yml @@ -115,5 +115,5 @@ body: label: Sanity Check description: Sanity check to ensure that issue has been properly filled out to reduce friction for all involved parties. options: - - label: If this is a build issue, I have included my build config. If this is a runtime issues, I have included reproduction steps and/or a [Minimal, Reproducible Example](https://stackoverflow.com/help/minimal-reproducible-example). + - label: If this is a build issue, I have included my build config. If this is a runtime issue, I have included reproduction steps and/or a [Minimal, Reproducible Example](https://stackoverflow.com/help/minimal-reproducible-example). required: true diff --git a/package.json b/package.json index 824fad638..1ad8867b0 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "web3-onboard-monorepo", - "version": "2.1.0", + "version": "2.2.0", "private": true, "workspaces": [ "./packages/*" diff --git a/packages/coinbase/package.json b/packages/coinbase/package.json index 4171f0483..68c3138d1 100644 --- a/packages/coinbase/package.json +++ b/packages/coinbase/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/coinbase", - "version": "2.0.6-alpha.2", + "version": "2.0.6", "description": "Coinbase Wallet module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -21,6 +21,6 @@ }, "dependencies": { "@coinbase/wallet-sdk": "^3.0.5", - "@web3-onboard/common": "^2.1.3-alpha.2" + "@web3-onboard/common": "^2.1.3" } } diff --git a/packages/common/package.json b/packages/common/package.json index dae2bb704..525a1d8f0 100644 --- a/packages/common/package.json +++ b/packages/common/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/common", - "version": "2.1.3-alpha.2", + "version": "2.1.3", "scripts": { "build": "rollup -c", "dev": "rollup -c -w", diff --git a/packages/core/package.json b/packages/core/package.json index 813b33aba..5651b107a 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/core", - "version": "2.3.1-alpha.4", + "version": "2.3.1", "scripts": { "build": "rollup -c", "dev": "rollup -c -w", @@ -41,7 +41,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "bignumber.js": "^9.0.0", "bnc-sdk": "^4.4.1", "bowser": "^2.11.0", diff --git a/packages/dcent/package.json b/packages/dcent/package.json index 6d296f879..743361caf 100644 --- a/packages/dcent/package.json +++ b/packages/dcent/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/dcent", - "version": "2.0.3-alpha.2", + "version": "2.0.3", "description": "D'CENT module for web3-onboard", "module": "dist/index.js", "typings": "dist/index.d.ts", @@ -18,7 +18,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "@ethereumjs/common": "^2.6.1", "@ethereumjs/tx": "^3.4.0", "@ethersproject/providers": "^5.5.0", diff --git a/packages/demo/package.json b/packages/demo/package.json index e0212146c..9c80a9074 100644 --- a/packages/demo/package.json +++ b/packages/demo/package.json @@ -22,21 +22,21 @@ "webpack-dev-server": "4.7.4" }, "dependencies": { - "@web3-onboard/coinbase": "^2.0.6-alpha.1", - "@web3-onboard/core": "^2.3.1-alpha.3", - "@web3-onboard/dcent": "^2.0.3-alpha.1", - "@web3-onboard/fortmatic": "^2.0.5-alpha.1", - "@web3-onboard/gnosis": "^2.0.4-alpha.1", - "@web3-onboard/injected-wallets": "^2.0.11-alpha.1", - "@web3-onboard/keepkey": "^2.1.3-alpha.1", - "@web3-onboard/keystone": "^2.1.4-alpha.1", - "@web3-onboard/ledger": "^2.1.3-alpha.1", - "@web3-onboard/magic": "^2.0.6-alpha.1", - "@web3-onboard/portis": "^2.0.3-alpha.1", - "@web3-onboard/torus": "^2.0.4-alpha.1", - "@web3-onboard/trezor": "^2.1.3-alpha.1", - "@web3-onboard/walletconnect": "^2.0.4-alpha.2", - "@web3-onboard/web3auth": "^2.0.2-alpha.1", + "@web3-onboard/coinbase": "^2.0.6", + "@web3-onboard/core": "^2.3.1", + "@web3-onboard/dcent": "^2.0.3", + "@web3-onboard/fortmatic": "^2.0.5", + "@web3-onboard/gnosis": "^2.0.4", + "@web3-onboard/injected-wallets": "^2.0.11", + "@web3-onboard/keepkey": "^2.1.3", + "@web3-onboard/keystone": "^2.1.4", + "@web3-onboard/ledger": "^2.1.3", + "@web3-onboard/magic": "^2.0.6", + "@web3-onboard/portis": "^2.0.3", + "@web3-onboard/torus": "^2.0.4", + "@web3-onboard/trezor": "^2.1.3", + "@web3-onboard/walletconnect": "^2.0.4", + "@web3-onboard/web3auth": "^2.0.2", "vconsole": "^3.9.5" }, "license": "MIT", diff --git a/packages/fortmatic/package.json b/packages/fortmatic/package.json index 8b7cf1d5a..5af47bb59 100644 --- a/packages/fortmatic/package.json +++ b/packages/fortmatic/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/fortmatic", - "version": "2.0.5-alpha.2", + "version": "2.0.5", "description": "Fortmatic module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -20,7 +20,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "fortmatic": "^2.2.1" } } diff --git a/packages/gnosis/package.json b/packages/gnosis/package.json index 58f3b8e10..77f62a4f7 100644 --- a/packages/gnosis/package.json +++ b/packages/gnosis/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/gnosis", - "version": "2.0.4-alpha.2", + "version": "2.0.4", "description": "Gnosis module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -23,6 +23,6 @@ "dependencies": { "@gnosis.pm/safe-apps-provider": "^0.9.2", "@gnosis.pm/safe-apps-sdk": "^6.1.1", - "@web3-onboard/common": "^2.1.3-alpha.2" + "@web3-onboard/common": "^2.1.3" } } diff --git a/packages/injected/package.json b/packages/injected/package.json index 170e9f0ed..8ffc6dbef 100644 --- a/packages/injected/package.json +++ b/packages/injected/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/injected-wallets", - "version": "2.0.11-alpha.2", + "version": "2.0.11", "description": "Injected wallets module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -25,7 +25,7 @@ "window": "^4.2.7" }, "dependencies": { - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "joi": "^17.4.2", "lodash.uniqby": "^4.7.0" } diff --git a/packages/keepkey/package.json b/packages/keepkey/package.json index cc59bb966..41c931e1d 100644 --- a/packages/keepkey/package.json +++ b/packages/keepkey/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/keepkey", - "version": "2.1.3-alpha.2", + "version": "2.1.3", "description": "KeepKey module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -27,7 +27,7 @@ "@ethersproject/providers": "^5.5.0", "@shapeshiftoss/hdwallet-core": "^1.15.2", "@shapeshiftoss/hdwallet-keepkey-webusb": "^1.15.2", - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "ethereumjs-util": "^7.1.3" } } diff --git a/packages/keystone/package.json b/packages/keystone/package.json index 9f288d353..400e535f0 100644 --- a/packages/keystone/package.json +++ b/packages/keystone/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/keystone", - "version": "2.1.4-alpha.2", + "version": "2.1.4", "description": "Keystone module for web3-onboard", "module": "dist/index.js", "typings": "dist/index.d.ts", @@ -21,6 +21,6 @@ "@ethereumjs/tx": "^3.4.0", "@ethersproject/providers": "^5.5.0", "@keystonehq/eth-keyring": "^0.14.0-alpha.10.3", - "@web3-onboard/common": "^2.1.3-alpha.2" + "@web3-onboard/common": "^2.1.3" } } diff --git a/packages/ledger/package.json b/packages/ledger/package.json index fc38cb020..43a0e391f 100644 --- a/packages/ledger/package.json +++ b/packages/ledger/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/ledger", - "version": "2.1.3-alpha.2", + "version": "2.1.3", "description": "Ledger module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -27,7 +27,7 @@ "@ledgerhq/hw-transport-u2f": "^5.36.0-deprecated", "@ledgerhq/hw-transport-webusb": "^6.19.0", "@metamask/eth-sig-util": "^4.0.0", - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "buffer": "^6.0.3", "ethereumjs-util": "^7.1.3" } diff --git a/packages/magic/package.json b/packages/magic/package.json index 466dfb797..04013b4bf 100644 --- a/packages/magic/package.json +++ b/packages/magic/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/magic", - "version": "2.0.6-alpha.2", + "version": "2.0.6", "description": "Magic module for Onboard.js", "scripts": { "build": "rollup -c", @@ -42,7 +42,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "joi": "^17.4.2", "magic-sdk": "^8.1.0", "rxjs": "^7.5.2" diff --git a/packages/mew/package.json b/packages/mew/package.json index 3052d7402..1a361327e 100644 --- a/packages/mew/package.json +++ b/packages/mew/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/mew", - "version": "2.0.3-alpha.2", + "version": "2.0.3", "description": "MEW module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -23,7 +23,7 @@ "@myetherwallet/mewconnect-web-client": "^2.2.0-beta.14" }, "dependencies": { - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "rxjs": "^7.5.2" } } diff --git a/packages/portis/package.json b/packages/portis/package.json index 1777d50bb..743a9a026 100644 --- a/packages/portis/package.json +++ b/packages/portis/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/portis", - "version": "2.0.3-alpha.2", + "version": "2.0.3", "description": "Portis module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -21,6 +21,6 @@ }, "dependencies": { "@portis/web3": "^4.0.6", - "@web3-onboard/common": "^2.1.3-alpha.2" + "@web3-onboard/common": "^2.1.3" } } diff --git a/packages/react/package.json b/packages/react/package.json index 51f2c94e8..af3b37a8e 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/react", - "version": "2.2.1-alpha.4", + "version": "2.2.1", "description": "Collection of React Hooks for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -23,8 +23,8 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/core": "^2.3.1-alpha.4", - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/core": "^2.3.1", + "@web3-onboard/common": "^2.1.3", "use-sync-external-store": "1.0.0" }, "peerDependencies": { diff --git a/packages/torus/package.json b/packages/torus/package.json index c33fa335f..e560a9b83 100644 --- a/packages/torus/package.json +++ b/packages/torus/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/torus", - "version": "2.0.4-alpha.2", + "version": "2.0.4", "description": "Torus module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -21,6 +21,6 @@ }, "dependencies": { "@toruslabs/torus-embed": "^1.18.3", - "@web3-onboard/common": "^2.1.3-alpha.2" + "@web3-onboard/common": "^2.1.3" } } diff --git a/packages/trezor/package.json b/packages/trezor/package.json index 1a17c1a4d..26a7dc084 100644 --- a/packages/trezor/package.json +++ b/packages/trezor/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/trezor", - "version": "2.1.3-alpha.2", + "version": "2.1.3", "description": "Trezor module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -22,7 +22,7 @@ "dependencies": { "@ethereumjs/tx": "^3.4.0", "@ethersproject/providers": "^5.5.0", - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "buffer": "^6.0.3", "eth-crypto": "^2.1.0", "ethereumjs-util": "^7.1.3", diff --git a/packages/vue/package.json b/packages/vue/package.json index a9468bd63..401103274 100644 --- a/packages/vue/package.json +++ b/packages/vue/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/vue", - "version": "2.1.1-alpha.3", + "version": "2.1.1", "description": "Vue Composable for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -23,8 +23,8 @@ "dependencies": { "@vueuse/core": "^8.4.2", "@vueuse/rxjs": "^8.2.0", - "@web3-onboard/common": "^2.1.3-alpha.2", - "@web3-onboard/core": "^2.3.1-alpha.4", + "@web3-onboard/common": "^2.1.3", + "@web3-onboard/core": "^2.3.1", "vue-demi": "^0.12.4" }, "peerDependencies": { diff --git a/packages/walletconnect/package.json b/packages/walletconnect/package.json index b9d018d25..e9fc63938 100644 --- a/packages/walletconnect/package.json +++ b/packages/walletconnect/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/walletconnect", - "version": "2.0.4-alpha.2", + "version": "2.0.4", "description": "WalletConnect module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -23,7 +23,7 @@ "@ethersproject/providers": "^5.5.0", "@walletconnect/client": "^1.7.1", "@walletconnect/qrcode-modal": "^1.7.1", - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "rxjs": "^7.5.2" } } diff --git a/packages/walletlink/package.json b/packages/walletlink/package.json index 35c492188..78bb252e1 100644 --- a/packages/walletlink/package.json +++ b/packages/walletlink/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/walletlink", - "version": "2.0.3-alpha.2", + "version": "2.0.3", "description": "WalletLink module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -20,7 +20,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "walletlink": "^2.5.0" } } diff --git a/packages/web3auth/package.json b/packages/web3auth/package.json index b90ae344b..005e11422 100644 --- a/packages/web3auth/package.json +++ b/packages/web3auth/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/web3auth", - "version": "2.0.2-alpha.2", + "version": "2.0.2", "description": "Web3Auth module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -20,7 +20,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3-alpha.2", + "@web3-onboard/common": "^2.1.3", "@web3auth/web3auth": "^1.0.0" } } From 79ee71af9a33665b6f11de68045c2b2d7a331aef Mon Sep 17 00:00:00 2001 From: vvvvvv1vvvvvv <86296331+vvvvvv1vvvvvv@users.noreply.github.com> Date: Wed, 29 Jun 2022 22:38:57 +0800 Subject: [PATCH 02/17] feat: intergration of Rabby wallet (#1069) * feat: intergration rabby wallet --- packages/injected/package.json | 2 +- packages/injected/src/icons/rabby.ts | 24 ++++++++++++++++++++++++ packages/injected/src/types.ts | 6 ++++-- packages/injected/src/wallets.ts | 15 ++++++++++++++- 4 files changed, 43 insertions(+), 4 deletions(-) create mode 100644 packages/injected/src/icons/rabby.ts diff --git a/packages/injected/package.json b/packages/injected/package.json index 8ffc6dbef..466bc3d60 100644 --- a/packages/injected/package.json +++ b/packages/injected/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/injected-wallets", - "version": "2.0.11", + "version": "2.0.12-alpha.1", "description": "Injected wallets module for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", diff --git a/packages/injected/src/icons/rabby.ts b/packages/injected/src/icons/rabby.ts new file mode 100644 index 000000000..4ee8a89f4 --- /dev/null +++ b/packages/injected/src/icons/rabby.ts @@ -0,0 +1,24 @@ +export default ` + + + + + + + + + + + + + + + + + + + + + + +` diff --git a/packages/injected/src/types.ts b/packages/injected/src/types.ts index ede008038..b4a5b904a 100644 --- a/packages/injected/src/types.ts +++ b/packages/injected/src/types.ts @@ -40,7 +40,8 @@ export enum ProviderIdentityFlag { OneInch = 'isOneInchIOSWallet', Tokenary = 'isTokenary', Tally = 'isTally', - BraveWallet = 'isBraveWallet' + BraveWallet = 'isBraveWallet', + Rabby = 'isRabby' } export enum ProviderLabel { @@ -72,7 +73,8 @@ export enum ProviderLabel { XDEFI = 'XDEFI Wallet', OneInch = '1inch Wallet', Tokenary = 'Tokenary Wallet', - Tally = 'Tally Wallet' + Tally = 'Tally Wallet', + Rabby = 'Rabby' } export interface MeetOneProvider extends ExternalProvider { diff --git a/packages/injected/src/wallets.ts b/packages/injected/src/wallets.ts index da4f25a89..b1cb30053 100644 --- a/packages/injected/src/wallets.ts +++ b/packages/injected/src/wallets.ts @@ -473,6 +473,18 @@ const tally: InjectedWalletModule = { platforms: ['desktop'] } +const rabby: InjectedWalletModule = { + label: ProviderLabel.Rabby, + injectedNamespace: InjectedNameSpace.Ethereum, + checkProviderIdentity: ({ provider }) => + !!provider && !!provider[ProviderIdentityFlag.Rabby], + getIcon: async () => (await import('./icons/rabby.js')).default, + getInterface: async () => ({ + provider: createEIP1193Provider(window.ethereum) + }), + platforms: ['desktop'] +} + const wallets = [ exodus, metamask, @@ -500,7 +512,8 @@ const wallets = [ xdefi, oneInch, tokenary, - tally + tally, + rabby ] export default wallets From a9e267f73e9a17afeffdd04435de0fbc7d622c8f Mon Sep 17 00:00:00 2001 From: Benjamin Reid Date: Wed, 29 Jun 2022 15:42:26 +0100 Subject: [PATCH 03/17] Fix typeof check for notify in core (#1106) * Fix typeof check for notify in core * Bump version * Update packages/core/package.json Co-authored-by: Adam Carpenter Co-authored-by: Adam Carpenter --- packages/core/package.json | 2 +- packages/core/src/index.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/core/package.json b/packages/core/package.json index 5651b107a..eef264b9c 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/core", - "version": "2.3.1", + "version": "2.3.2-alpha.1", "scripts": { "build": "rollup -c", "dev": "rollup -c -w", diff --git a/packages/core/src/index.ts b/packages/core/src/index.ts index cbd7a22ff..ede76737c 100644 --- a/packages/core/src/index.ts +++ b/packages/core/src/index.ts @@ -103,7 +103,7 @@ function init(options: InitOptions): OnboardAPI { } // update notify - if (typeof notify !== undefined) { + if (typeof notify !== 'undefined') { if ('desktop' in notify || 'mobile' in notify) { const error = validateNotifyOptions(notify) From 7c4902c0948f686662e162a0752c5082d0ad196d Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Wed, 29 Jun 2022 09:08:46 -0600 Subject: [PATCH 04/17] [react-v2.2.2-alpha.1, vue-v2.1.2-alpha.1] : Update - Version bump core in React and Vue (#1108) * Update react package version * Bump core version in react, vue and demo --- packages/demo/package.json | 2 +- packages/react/package.json | 4 ++-- packages/vue/package.json | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/demo/package.json b/packages/demo/package.json index 9c80a9074..f19b5f5d5 100644 --- a/packages/demo/package.json +++ b/packages/demo/package.json @@ -23,7 +23,7 @@ }, "dependencies": { "@web3-onboard/coinbase": "^2.0.6", - "@web3-onboard/core": "^2.3.1", + "@web3-onboard/core": "^2.3.2-alpha.1", "@web3-onboard/dcent": "^2.0.3", "@web3-onboard/fortmatic": "^2.0.5", "@web3-onboard/gnosis": "^2.0.4", diff --git a/packages/react/package.json b/packages/react/package.json index af3b37a8e..31dc503ea 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/react", - "version": "2.2.1", + "version": "2.2.2-alpha.1", "description": "Collection of React Hooks for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -23,7 +23,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/core": "^2.3.1", + "@web3-onboard/core": "^2.3.2-alpha.1", "@web3-onboard/common": "^2.1.3", "use-sync-external-store": "1.0.0" }, diff --git a/packages/vue/package.json b/packages/vue/package.json index 401103274..7cf8b6d0b 100644 --- a/packages/vue/package.json +++ b/packages/vue/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/vue", - "version": "2.1.1", + "version": "2.1.2-alpha.1", "description": "Vue Composable for web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", @@ -24,7 +24,7 @@ "@vueuse/core": "^8.4.2", "@vueuse/rxjs": "^8.2.0", "@web3-onboard/common": "^2.1.3", - "@web3-onboard/core": "^2.3.1", + "@web3-onboard/core": "^2.3.2-alpha.1", "vue-demi": "^0.12.4" }, "peerDependencies": { From 5397eb2eca635c856c583e10e608a4d35633fcbb Mon Sep 17 00:00:00 2001 From: Taylor Dawson Date: Wed, 29 Jun 2022 10:19:16 -0500 Subject: [PATCH 05/17] Adds repository field (#1109) * Adds repository field * Version bumpies --- packages/coinbase/package.json | 5 +++-- packages/common/package.json | 3 ++- packages/core/package.json | 5 +++-- packages/dcent/package.json | 5 +++-- packages/demo/package.json | 2 +- packages/fortmatic/package.json | 5 +++-- packages/gnosis/package.json | 5 +++-- packages/injected/package.json | 5 +++-- packages/keepkey/package.json | 5 +++-- packages/keystone/package.json | 5 +++-- packages/ledger/package.json | 5 +++-- packages/magic/package.json | 5 +++-- packages/mew/package.json | 5 +++-- packages/portis/package.json | 5 +++-- packages/react/package.json | 5 +++-- packages/torus/package.json | 5 +++-- packages/trezor/package.json | 5 +++-- packages/vue/package.json | 5 +++-- packages/walletconnect/package.json | 5 +++-- packages/walletlink/package.json | 5 +++-- packages/web3auth/package.json | 5 +++-- 21 files changed, 60 insertions(+), 40 deletions(-) diff --git a/packages/coinbase/package.json b/packages/coinbase/package.json index 68c3138d1..21e814772 100644 --- a/packages/coinbase/package.json +++ b/packages/coinbase/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/coinbase", - "version": "2.0.6", + "version": "2.0.7-alpha.1", "description": "Coinbase Wallet module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -21,6 +22,6 @@ }, "dependencies": { "@coinbase/wallet-sdk": "^3.0.5", - "@web3-onboard/common": "^2.1.3" + "@web3-onboard/common": "^2.1.4-alpha.1" } } diff --git a/packages/common/package.json b/packages/common/package.json index 525a1d8f0..61776ef72 100644 --- a/packages/common/package.json +++ b/packages/common/package.json @@ -1,6 +1,7 @@ { "name": "@web3-onboard/common", - "version": "2.1.3", + "version": "2.1.4-alpha.1", + "repository": "blocknative/web3-onboard", "scripts": { "build": "rollup -c", "dev": "rollup -c -w", diff --git a/packages/core/package.json b/packages/core/package.json index eef264b9c..bf773ec72 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,7 @@ { "name": "@web3-onboard/core", - "version": "2.3.2-alpha.1", + "version": "2.3.2-alpha.2", + "repository": "blocknative/web3-onboard", "scripts": { "build": "rollup -c", "dev": "rollup -c -w", @@ -41,7 +42,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "bignumber.js": "^9.0.0", "bnc-sdk": "^4.4.1", "bowser": "^2.11.0", diff --git a/packages/dcent/package.json b/packages/dcent/package.json index 743361caf..20479d9a2 100644 --- a/packages/dcent/package.json +++ b/packages/dcent/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/dcent", - "version": "2.0.3", + "version": "2.0.4-alpha.1", "description": "D'CENT module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "typings": "dist/index.d.ts", "files": [ @@ -18,7 +19,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "@ethereumjs/common": "^2.6.1", "@ethereumjs/tx": "^3.4.0", "@ethersproject/providers": "^5.5.0", diff --git a/packages/demo/package.json b/packages/demo/package.json index f19b5f5d5..2aa06c281 100644 --- a/packages/demo/package.json +++ b/packages/demo/package.json @@ -23,7 +23,7 @@ }, "dependencies": { "@web3-onboard/coinbase": "^2.0.6", - "@web3-onboard/core": "^2.3.2-alpha.1", + "@web3-onboard/core": "^2.3.2-alpha.2", "@web3-onboard/dcent": "^2.0.3", "@web3-onboard/fortmatic": "^2.0.5", "@web3-onboard/gnosis": "^2.0.4", diff --git a/packages/fortmatic/package.json b/packages/fortmatic/package.json index 5af47bb59..f854305d6 100644 --- a/packages/fortmatic/package.json +++ b/packages/fortmatic/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/fortmatic", - "version": "2.0.5", + "version": "2.0.6-alpha.1", "description": "Fortmatic module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -20,7 +21,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "fortmatic": "^2.2.1" } } diff --git a/packages/gnosis/package.json b/packages/gnosis/package.json index 77f62a4f7..a3bc4cf39 100644 --- a/packages/gnosis/package.json +++ b/packages/gnosis/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/gnosis", - "version": "2.0.4", + "version": "2.0.5-alpha.1", "description": "Gnosis module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -23,6 +24,6 @@ "dependencies": { "@gnosis.pm/safe-apps-provider": "^0.9.2", "@gnosis.pm/safe-apps-sdk": "^6.1.1", - "@web3-onboard/common": "^2.1.3" + "@web3-onboard/common": "^2.1.4-alpha.1" } } diff --git a/packages/injected/package.json b/packages/injected/package.json index 466bc3d60..7075ad48a 100644 --- a/packages/injected/package.json +++ b/packages/injected/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/injected-wallets", - "version": "2.0.12-alpha.1", + "version": "2.0.12-alpha.2", "description": "Injected wallets module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -25,7 +26,7 @@ "window": "^4.2.7" }, "dependencies": { - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "joi": "^17.4.2", "lodash.uniqby": "^4.7.0" } diff --git a/packages/keepkey/package.json b/packages/keepkey/package.json index 41c931e1d..0a405a802 100644 --- a/packages/keepkey/package.json +++ b/packages/keepkey/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/keepkey", - "version": "2.1.3", + "version": "2.1.4-alpha.1", "description": "KeepKey module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -27,7 +28,7 @@ "@ethersproject/providers": "^5.5.0", "@shapeshiftoss/hdwallet-core": "^1.15.2", "@shapeshiftoss/hdwallet-keepkey-webusb": "^1.15.2", - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "ethereumjs-util": "^7.1.3" } } diff --git a/packages/keystone/package.json b/packages/keystone/package.json index 400e535f0..51ad173e9 100644 --- a/packages/keystone/package.json +++ b/packages/keystone/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/keystone", - "version": "2.1.4", + "version": "2.1.5-alpha.1", "description": "Keystone module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "typings": "dist/index.d.ts", "files": [ @@ -21,6 +22,6 @@ "@ethereumjs/tx": "^3.4.0", "@ethersproject/providers": "^5.5.0", "@keystonehq/eth-keyring": "^0.14.0-alpha.10.3", - "@web3-onboard/common": "^2.1.3" + "@web3-onboard/common": "^2.1.4-alpha.1" } } diff --git a/packages/ledger/package.json b/packages/ledger/package.json index 43a0e391f..b9ee2066b 100644 --- a/packages/ledger/package.json +++ b/packages/ledger/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/ledger", - "version": "2.1.3", + "version": "2.1.4-alpha.1", "description": "Ledger module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -27,7 +28,7 @@ "@ledgerhq/hw-transport-u2f": "^5.36.0-deprecated", "@ledgerhq/hw-transport-webusb": "^6.19.0", "@metamask/eth-sig-util": "^4.0.0", - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "buffer": "^6.0.3", "ethereumjs-util": "^7.1.3" } diff --git a/packages/magic/package.json b/packages/magic/package.json index 04013b4bf..77c404393 100644 --- a/packages/magic/package.json +++ b/packages/magic/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/magic", - "version": "2.0.6", + "version": "2.0.7-alpha.1", "description": "Magic module for Onboard.js", + "repository": "blocknative/web3-onboard", "scripts": { "build": "rollup -c", "dev": "rollup -c -w", @@ -42,7 +43,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "joi": "^17.4.2", "magic-sdk": "^8.1.0", "rxjs": "^7.5.2" diff --git a/packages/mew/package.json b/packages/mew/package.json index 1a361327e..f05744743 100644 --- a/packages/mew/package.json +++ b/packages/mew/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/mew", - "version": "2.0.3", + "version": "2.0.4-alpha.1", "description": "MEW module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -23,7 +24,7 @@ "@myetherwallet/mewconnect-web-client": "^2.2.0-beta.14" }, "dependencies": { - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "rxjs": "^7.5.2" } } diff --git a/packages/portis/package.json b/packages/portis/package.json index 743a9a026..1ec2d002b 100644 --- a/packages/portis/package.json +++ b/packages/portis/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/portis", - "version": "2.0.3", + "version": "2.0.4-alpha.1", "description": "Portis module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -21,6 +22,6 @@ }, "dependencies": { "@portis/web3": "^4.0.6", - "@web3-onboard/common": "^2.1.3" + "@web3-onboard/common": "^2.1.4-alpha.1" } } diff --git a/packages/react/package.json b/packages/react/package.json index 31dc503ea..8c2c06dfb 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -2,6 +2,7 @@ "name": "@web3-onboard/react", "version": "2.2.2-alpha.1", "description": "Collection of React Hooks for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -23,8 +24,8 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/core": "^2.3.2-alpha.1", - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/core": "^2.3.2-alpha.2", + "@web3-onboard/common": "^2.1.4-alpha.1", "use-sync-external-store": "1.0.0" }, "peerDependencies": { diff --git a/packages/torus/package.json b/packages/torus/package.json index e560a9b83..37f177c26 100644 --- a/packages/torus/package.json +++ b/packages/torus/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/torus", - "version": "2.0.4", + "version": "2.0.5-alpha.1", "description": "Torus module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -21,6 +22,6 @@ }, "dependencies": { "@toruslabs/torus-embed": "^1.18.3", - "@web3-onboard/common": "^2.1.3" + "@web3-onboard/common": "^2.1.4-alpha.1" } } diff --git a/packages/trezor/package.json b/packages/trezor/package.json index 26a7dc084..410928e03 100644 --- a/packages/trezor/package.json +++ b/packages/trezor/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/trezor", - "version": "2.1.3", + "version": "2.1.4-alpha.1", "description": "Trezor module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -22,7 +23,7 @@ "dependencies": { "@ethereumjs/tx": "^3.4.0", "@ethersproject/providers": "^5.5.0", - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "buffer": "^6.0.3", "eth-crypto": "^2.1.0", "ethereumjs-util": "^7.1.3", diff --git a/packages/vue/package.json b/packages/vue/package.json index 7cf8b6d0b..80aa7e606 100644 --- a/packages/vue/package.json +++ b/packages/vue/package.json @@ -2,6 +2,7 @@ "name": "@web3-onboard/vue", "version": "2.1.2-alpha.1", "description": "Vue Composable for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -23,8 +24,8 @@ "dependencies": { "@vueuse/core": "^8.4.2", "@vueuse/rxjs": "^8.2.0", - "@web3-onboard/common": "^2.1.3", - "@web3-onboard/core": "^2.3.2-alpha.1", + "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/core": "^2.3.2-alpha.2", "vue-demi": "^0.12.4" }, "peerDependencies": { diff --git a/packages/walletconnect/package.json b/packages/walletconnect/package.json index e9fc63938..5a4aabdf4 100644 --- a/packages/walletconnect/package.json +++ b/packages/walletconnect/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/walletconnect", - "version": "2.0.4", + "version": "2.0.5-alpha.1", "description": "WalletConnect module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -23,7 +24,7 @@ "@ethersproject/providers": "^5.5.0", "@walletconnect/client": "^1.7.1", "@walletconnect/qrcode-modal": "^1.7.1", - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "rxjs": "^7.5.2" } } diff --git a/packages/walletlink/package.json b/packages/walletlink/package.json index 78bb252e1..892b55aa9 100644 --- a/packages/walletlink/package.json +++ b/packages/walletlink/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/walletlink", - "version": "2.0.3", + "version": "2.0.4-alpha.1", "description": "WalletLink module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -20,7 +21,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "walletlink": "^2.5.0" } } diff --git a/packages/web3auth/package.json b/packages/web3auth/package.json index 005e11422..805d61dd6 100644 --- a/packages/web3auth/package.json +++ b/packages/web3auth/package.json @@ -1,7 +1,8 @@ { "name": "@web3-onboard/web3auth", - "version": "2.0.2", + "version": "2.0.3-alpha.1", "description": "Web3Auth module for web3-onboard", + "repository": "blocknative/web3-onboard", "module": "dist/index.js", "browser": "dist/index.js", "main": "dist/index.js", @@ -20,7 +21,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.3", + "@web3-onboard/common": "^2.1.4-alpha.1", "@web3auth/web3auth": "^1.0.0" } } From 230e22417a61394763b6dd0d664eb075e79fbc87 Mon Sep 17 00:00:00 2001 From: Taylor Dawson Date: Wed, 29 Jun 2022 11:04:32 -0500 Subject: [PATCH 06/17] Yaml discriminates against @ characters (#1110) --- .github/ISSUE_TEMPLATE/BUG.yml | 40 +++++++++++++++++----------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/BUG.yml b/.github/ISSUE_TEMPLATE/BUG.yml index 639ffb678..a3548ebec 100644 --- a/.github/ISSUE_TEMPLATE/BUG.yml +++ b/.github/ISSUE_TEMPLATE/BUG.yml @@ -41,26 +41,26 @@ body: attributes: label: What package is effected by this issue? options: - - @web3-onboard/core - - @web3-onboard/common - - @web3-onboard/coinbase - - @web3-onboard/decent - - @web3-onboard/formatic - - @web3-onboard/gnosis - - @web3-onboard/injected - - @web3-onboard/keepkey - - @web3-onboard/keystone - - @web3-onboard/ledger - - @web3-onboard/magic - - @web3-onboard/mew - - @web3-onboard/portis - - @web3-onboard/react - - @web3-onboard/torus - - @web3-onboard/trezor - - @web3-onboard/vue - - @web3-onboard/walletconnect - - @web3-onboard/walletlink - - @web3-onboard/web3auth + - "@web3-onboard/core" + - "@web3-onboard/common" + - "@web3-onboard/coinbase" + - "@web3-onboard/decent" + - "@web3-onboard/formatic" + - "@web3-onboard/gnosis" + - "@web3-onboard/injected" + - "@web3-onboard/keepkey" + - "@web3-onboard/keystone" + - "@web3-onboard/ledger" + - "@web3-onboard/magic" + - "@web3-onboard/mew" + - "@web3-onboard/portis" + - "@web3-onboard/react" + - "@web3-onboard/torus" + - "@web3-onboard/trezor" + - "@web3-onboard/vue" + - "@web3-onboard/walletconnect" + - "@web3-onboard/walletlink" + - "@web3-onboard/web3auth" - bnc-onboard (v1) validations: required: true From 631d34d21f56bb324af752c50a0f74c293c4ffd4 Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Wed, 29 Jun 2022 16:06:44 -0600 Subject: [PATCH 07/17] [core-v2.3.2-alpha.3 , react-v2.2.2-alpha.2, vue-v2.1.2-alpha.2] : Fix - Conditional rendering Notify and Account Center (#1113) * Moved notification stream up a level, positioning working as expected * working but needs cleanup * Handle placement and abstract logic into variables * Bump versions * Refine naming --- packages/core/package.json | 2 +- packages/core/src/views/Index.svelte | 77 ++++++++++++++++++--- packages/core/src/views/notify/Index.svelte | 8 +-- packages/react/package.json | 4 +- packages/vue/package.json | 4 +- 5 files changed, 78 insertions(+), 17 deletions(-) diff --git a/packages/core/package.json b/packages/core/package.json index bf773ec72..3f9c2bdb7 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/core", - "version": "2.3.2-alpha.2", + "version": "2.3.2-alpha.3", "repository": "blocknative/web3-onboard", "scripts": { "build": "rollup -c", diff --git a/packages/core/src/views/Index.svelte b/packages/core/src/views/Index.svelte index adcb618dc..dcdca9865 100644 --- a/packages/core/src/views/Index.svelte +++ b/packages/core/src/views/Index.svelte @@ -17,12 +17,61 @@ const notify$ = state .select('notify') .pipe(startWith(state.get().notify), shareReplay(1)) + + const notifications$ = $notify$.enabled + ? state.select('notifications').pipe(startWith(state.get().notifications)) + : null + const positioningDefaults = { topLeft: 'top: 0; left: 0;', topRight: 'top: 0; right: 0;', bottomRight: 'bottom: 0; right: 0;', bottomLeft: 'bottom: 0; left: 0;' } + + $: sharedContainer = + $accountCenter$.enabled && + $notify$.enabled && + $notify$.position === $accountCenter$.position + + $: samePositionMobile = + device.type === 'mobile' || $accountCenter$.position === $notify$.position + + $: sharedMobileContainerCheck = + device.type === 'mobile' && + (($notify$.position.includes('bottom') && + $accountCenter$.position.includes('bottom')) || + ($notify$.position.includes('top') && + $accountCenter$.position.includes('top'))) + + $: separateMobileContainerCheck = + device.type === 'mobile' && + (($notify$.position.includes('top') && + $accountCenter$.position.includes('bottom')) || + ($notify$.position.includes('bottom') && + $accountCenter$.position.includes('top'))) + + $: displayNotifySeparate = + $notify$.enabled && + (!$accountCenter$.enabled || + ($notify$.position !== $accountCenter$.position && + device.type !== 'mobile') || + separateMobileContainerCheck) && + $wallets$.length + + $: displayAccountCenterSeparate = + $accountCenter$.enabled && + (!$notify$.enabled || + ($notify$.position !== $accountCenter$.position && + device.type !== 'mobile') || + separateMobileContainerCheck) && + $wallets$.length + + $: displayAccountCenterNotifySameContainer = + $notify$.enabled && + $accountCenter$.enabled && + $wallets$.length && + (sharedContainer || sharedMobileContainerCheck) -{#if $notifications$.length} +{#if notifications.length}
    - {#each $notifications$ as notification (notification.key)} + {#each notifications as notification (notification.key)}
  • Date: Thu, 30 Jun 2022 10:07:44 +1000 Subject: [PATCH 08/17] 2.0.3-alpha.2: [fix] - MEW Set Chain (#1102) * Disable switch chain methods * Increment version --- packages/mew/package.json | 2 +- packages/mew/src/index.ts | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/mew/package.json b/packages/mew/package.json index f05744743..0e6990200 100644 --- a/packages/mew/package.json +++ b/packages/mew/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/mew", - "version": "2.0.4-alpha.1", + "version": "2.0.3-alpha.2", "description": "MEW module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", diff --git a/packages/mew/src/index.ts b/packages/mew/src/index.ts index 15313dd6c..abc930e9b 100644 --- a/packages/mew/src/index.ts +++ b/packages/mew/src/index.ts @@ -46,7 +46,9 @@ function mew(): WalletInit { firstValueFrom(closed$) ]) }, - eth_selectAccounts: null + eth_selectAccounts: null, + wallet_addEthereumChain: null, + wallet_switchEthereumChain: null }) const events = new EventEmitter() From 63052616a9d586faccf564c0a45ca3173b3f42d8 Mon Sep 17 00:00:00 2001 From: Aaron Barnard Date: Thu, 30 Jun 2022 11:44:06 +1000 Subject: [PATCH 09/17] [core: 2.3.2-alpha.4]: [fix] - Recommended Injected Wallets (#1115) * Fixes recommended injected wallets * Remove unecessary check --- packages/core/package.json | 2 +- packages/core/src/views/connect/Index.svelte | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/core/package.json b/packages/core/package.json index 3f9c2bdb7..2e7046f29 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/core", - "version": "2.3.2-alpha.3", + "version": "2.3.2-alpha.4", "repository": "blocknative/web3-onboard", "scripts": { "build": "rollup -c", diff --git a/packages/core/src/views/connect/Index.svelte b/packages/core/src/views/connect/Index.svelte index 764b259dd..958667450 100644 --- a/packages/core/src/views/connect/Index.svelte +++ b/packages/core/src/views/connect/Index.svelte @@ -52,7 +52,7 @@ let scrollContainer: HTMLElement let walletToAutoSelect = - autoSelect && + autoSelect.label && walletModules.find( ({ label }) => label.toLowerCase() === autoSelect.label.toLowerCase() ) @@ -209,7 +209,7 @@ // user rejected account access if (code === ProviderRpcErrorCode.ACCOUNT_ACCESS_REJECTED) { connectionRejected = true - if (autoSelect) { + if (walletToAutoSelect) { walletToAutoSelect = null if (autoSelect.disableModals) { @@ -360,7 +360,7 @@ -{#if !autoSelect || (autoSelect && !autoSelect.disableModals)} +{#if !autoSelect.disableModals}
    {#if windowWidth >= 809} @@ -396,7 +396,7 @@ {connectingErrorMessage} />
    - {:else if !autoSelect} + {:else} {/if} {/if} From b8db3890dd91144f7c8e85961f2c7569acafa235 Mon Sep 17 00:00:00 2001 From: Murat Akdeniz Date: Thu, 30 Jun 2022 10:57:49 -0700 Subject: [PATCH 10/17] added tagline (#1114) --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 0b467ca0c..b79787cdd 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,5 @@ # Web3-Onboard +**easy way to connect users to dapps** ## Features From 62a1dcfc26aa99c60288b54d030e33674430dcd8 Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Thu, 30 Jun 2022 12:18:31 -0600 Subject: [PATCH 11/17] Bump versions for release --- package.json | 2 +- packages/coinbase/package.json | 4 ++-- packages/common/package.json | 2 +- packages/core/package.json | 4 ++-- packages/dcent/package.json | 4 ++-- packages/demo/package.json | 2 +- packages/fortmatic/package.json | 4 ++-- packages/gnosis/package.json | 4 ++-- packages/injected/package.json | 4 ++-- packages/keepkey/package.json | 4 ++-- packages/keystone/package.json | 4 ++-- packages/ledger/package.json | 4 ++-- packages/magic/package.json | 4 ++-- packages/mew/package.json | 4 ++-- packages/portis/package.json | 4 ++-- packages/react/package.json | 6 +++--- packages/torus/package.json | 4 ++-- packages/trezor/package.json | 4 ++-- packages/vue/package.json | 6 +++--- packages/walletconnect/package.json | 4 ++-- packages/walletlink/package.json | 4 ++-- packages/web3auth/package.json | 4 ++-- 22 files changed, 43 insertions(+), 43 deletions(-) diff --git a/package.json b/package.json index 1ad8867b0..57c1bbdbd 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "web3-onboard-monorepo", - "version": "2.2.0", + "version": "2.3.0", "private": true, "workspaces": [ "./packages/*" diff --git a/packages/coinbase/package.json b/packages/coinbase/package.json index 21e814772..3028dac62 100644 --- a/packages/coinbase/package.json +++ b/packages/coinbase/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/coinbase", - "version": "2.0.7-alpha.1", + "version": "2.0.7", "description": "Coinbase Wallet module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -22,6 +22,6 @@ }, "dependencies": { "@coinbase/wallet-sdk": "^3.0.5", - "@web3-onboard/common": "^2.1.4-alpha.1" + "@web3-onboard/common": "^2.1.4" } } diff --git a/packages/common/package.json b/packages/common/package.json index 61776ef72..ac0346e99 100644 --- a/packages/common/package.json +++ b/packages/common/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/common", - "version": "2.1.4-alpha.1", + "version": "2.1.4", "repository": "blocknative/web3-onboard", "scripts": { "build": "rollup -c", diff --git a/packages/core/package.json b/packages/core/package.json index 2e7046f29..18bc413c2 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/core", - "version": "2.3.2-alpha.4", + "version": "2.3.2", "repository": "blocknative/web3-onboard", "scripts": { "build": "rollup -c", @@ -42,7 +42,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "bignumber.js": "^9.0.0", "bnc-sdk": "^4.4.1", "bowser": "^2.11.0", diff --git a/packages/dcent/package.json b/packages/dcent/package.json index 20479d9a2..1e5264e25 100644 --- a/packages/dcent/package.json +++ b/packages/dcent/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/dcent", - "version": "2.0.4-alpha.1", + "version": "2.0.4", "description": "D'CENT module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -19,7 +19,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "@ethereumjs/common": "^2.6.1", "@ethereumjs/tx": "^3.4.0", "@ethersproject/providers": "^5.5.0", diff --git a/packages/demo/package.json b/packages/demo/package.json index 2aa06c281..4ee32d42b 100644 --- a/packages/demo/package.json +++ b/packages/demo/package.json @@ -23,7 +23,7 @@ }, "dependencies": { "@web3-onboard/coinbase": "^2.0.6", - "@web3-onboard/core": "^2.3.2-alpha.2", + "@web3-onboard/core": "^2.3.2", "@web3-onboard/dcent": "^2.0.3", "@web3-onboard/fortmatic": "^2.0.5", "@web3-onboard/gnosis": "^2.0.4", diff --git a/packages/fortmatic/package.json b/packages/fortmatic/package.json index f854305d6..a4a482d1c 100644 --- a/packages/fortmatic/package.json +++ b/packages/fortmatic/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/fortmatic", - "version": "2.0.6-alpha.1", + "version": "2.0.6", "description": "Fortmatic module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -21,7 +21,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "fortmatic": "^2.2.1" } } diff --git a/packages/gnosis/package.json b/packages/gnosis/package.json index a3bc4cf39..7dcd7f5d4 100644 --- a/packages/gnosis/package.json +++ b/packages/gnosis/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/gnosis", - "version": "2.0.5-alpha.1", + "version": "2.0.5", "description": "Gnosis module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -24,6 +24,6 @@ "dependencies": { "@gnosis.pm/safe-apps-provider": "^0.9.2", "@gnosis.pm/safe-apps-sdk": "^6.1.1", - "@web3-onboard/common": "^2.1.4-alpha.1" + "@web3-onboard/common": "^2.1.4" } } diff --git a/packages/injected/package.json b/packages/injected/package.json index 7075ad48a..c07474b84 100644 --- a/packages/injected/package.json +++ b/packages/injected/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/injected-wallets", - "version": "2.0.12-alpha.2", + "version": "2.0.12", "description": "Injected wallets module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -26,7 +26,7 @@ "window": "^4.2.7" }, "dependencies": { - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "joi": "^17.4.2", "lodash.uniqby": "^4.7.0" } diff --git a/packages/keepkey/package.json b/packages/keepkey/package.json index 0a405a802..12acda501 100644 --- a/packages/keepkey/package.json +++ b/packages/keepkey/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/keepkey", - "version": "2.1.4-alpha.1", + "version": "2.1.4", "description": "KeepKey module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -28,7 +28,7 @@ "@ethersproject/providers": "^5.5.0", "@shapeshiftoss/hdwallet-core": "^1.15.2", "@shapeshiftoss/hdwallet-keepkey-webusb": "^1.15.2", - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "ethereumjs-util": "^7.1.3" } } diff --git a/packages/keystone/package.json b/packages/keystone/package.json index 51ad173e9..ea6144e24 100644 --- a/packages/keystone/package.json +++ b/packages/keystone/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/keystone", - "version": "2.1.5-alpha.1", + "version": "2.1.5", "description": "Keystone module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -22,6 +22,6 @@ "@ethereumjs/tx": "^3.4.0", "@ethersproject/providers": "^5.5.0", "@keystonehq/eth-keyring": "^0.14.0-alpha.10.3", - "@web3-onboard/common": "^2.1.4-alpha.1" + "@web3-onboard/common": "^2.1.4" } } diff --git a/packages/ledger/package.json b/packages/ledger/package.json index b9ee2066b..05235e616 100644 --- a/packages/ledger/package.json +++ b/packages/ledger/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/ledger", - "version": "2.1.4-alpha.1", + "version": "2.1.4", "description": "Ledger module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -28,7 +28,7 @@ "@ledgerhq/hw-transport-u2f": "^5.36.0-deprecated", "@ledgerhq/hw-transport-webusb": "^6.19.0", "@metamask/eth-sig-util": "^4.0.0", - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "buffer": "^6.0.3", "ethereumjs-util": "^7.1.3" } diff --git a/packages/magic/package.json b/packages/magic/package.json index 77c404393..ce2010766 100644 --- a/packages/magic/package.json +++ b/packages/magic/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/magic", - "version": "2.0.7-alpha.1", + "version": "2.0.7", "description": "Magic module for Onboard.js", "repository": "blocknative/web3-onboard", "scripts": { @@ -43,7 +43,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "joi": "^17.4.2", "magic-sdk": "^8.1.0", "rxjs": "^7.5.2" diff --git a/packages/mew/package.json b/packages/mew/package.json index 0e6990200..ac24511ae 100644 --- a/packages/mew/package.json +++ b/packages/mew/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/mew", - "version": "2.0.3-alpha.2", + "version": "2.0.3", "description": "MEW module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -24,7 +24,7 @@ "@myetherwallet/mewconnect-web-client": "^2.2.0-beta.14" }, "dependencies": { - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "rxjs": "^7.5.2" } } diff --git a/packages/portis/package.json b/packages/portis/package.json index 1ec2d002b..5cff6e448 100644 --- a/packages/portis/package.json +++ b/packages/portis/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/portis", - "version": "2.0.4-alpha.1", + "version": "2.0.4", "description": "Portis module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -22,6 +22,6 @@ }, "dependencies": { "@portis/web3": "^4.0.6", - "@web3-onboard/common": "^2.1.4-alpha.1" + "@web3-onboard/common": "^2.1.4" } } diff --git a/packages/react/package.json b/packages/react/package.json index 382f9b7de..57cd12bd7 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/react", - "version": "2.2.2-alpha.2", + "version": "2.2.2", "description": "Collection of React Hooks for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -24,8 +24,8 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/core": "^2.3.2-alpha.3", - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/core": "^2.3.2", + "@web3-onboard/common": "^2.1.4", "use-sync-external-store": "1.0.0" }, "peerDependencies": { diff --git a/packages/torus/package.json b/packages/torus/package.json index 37f177c26..52deded3c 100644 --- a/packages/torus/package.json +++ b/packages/torus/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/torus", - "version": "2.0.5-alpha.1", + "version": "2.0.5", "description": "Torus module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -22,6 +22,6 @@ }, "dependencies": { "@toruslabs/torus-embed": "^1.18.3", - "@web3-onboard/common": "^2.1.4-alpha.1" + "@web3-onboard/common": "^2.1.4" } } diff --git a/packages/trezor/package.json b/packages/trezor/package.json index 410928e03..f02f2c602 100644 --- a/packages/trezor/package.json +++ b/packages/trezor/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/trezor", - "version": "2.1.4-alpha.1", + "version": "2.1.4", "description": "Trezor module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -23,7 +23,7 @@ "dependencies": { "@ethereumjs/tx": "^3.4.0", "@ethersproject/providers": "^5.5.0", - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "buffer": "^6.0.3", "eth-crypto": "^2.1.0", "ethereumjs-util": "^7.1.3", diff --git a/packages/vue/package.json b/packages/vue/package.json index 9c330fffb..d77b24f17 100644 --- a/packages/vue/package.json +++ b/packages/vue/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/vue", - "version": "2.1.2-alpha.2", + "version": "2.1.2", "description": "Vue Composable for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -24,8 +24,8 @@ "dependencies": { "@vueuse/core": "^8.4.2", "@vueuse/rxjs": "^8.2.0", - "@web3-onboard/common": "^2.1.4-alpha.1", - "@web3-onboard/core": "^2.3.2-alpha.3", + "@web3-onboard/common": "^2.1.4", + "@web3-onboard/core": "^2.3.2", "vue-demi": "^0.12.4" }, "peerDependencies": { diff --git a/packages/walletconnect/package.json b/packages/walletconnect/package.json index 5a4aabdf4..0230c975b 100644 --- a/packages/walletconnect/package.json +++ b/packages/walletconnect/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/walletconnect", - "version": "2.0.5-alpha.1", + "version": "2.0.5", "description": "WalletConnect module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -24,7 +24,7 @@ "@ethersproject/providers": "^5.5.0", "@walletconnect/client": "^1.7.1", "@walletconnect/qrcode-modal": "^1.7.1", - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "rxjs": "^7.5.2" } } diff --git a/packages/walletlink/package.json b/packages/walletlink/package.json index 892b55aa9..7659e362c 100644 --- a/packages/walletlink/package.json +++ b/packages/walletlink/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/walletlink", - "version": "2.0.4-alpha.1", + "version": "2.0.4", "description": "WalletLink module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -21,7 +21,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "walletlink": "^2.5.0" } } diff --git a/packages/web3auth/package.json b/packages/web3auth/package.json index 805d61dd6..a68b79b2f 100644 --- a/packages/web3auth/package.json +++ b/packages/web3auth/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/web3auth", - "version": "2.0.3-alpha.1", + "version": "2.0.3", "description": "Web3Auth module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", @@ -21,7 +21,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/common": "^2.1.4-alpha.1", + "@web3-onboard/common": "^2.1.4", "@web3auth/web3auth": "^1.0.0" } } From 77167dca0ac73b17bab09aa4cc6a5b79ec558b99 Mon Sep 17 00:00:00 2001 From: Mahmud <104795334+mahmud-bn@users.noreply.github.com> Date: Thu, 30 Jun 2022 14:28:59 -0600 Subject: [PATCH 12/17] [react-v2.2.2-alpha.3]: Fix - Next.js SSR support (#1118) * next js SSR support * package bump --- packages/react/package.json | 2 +- packages/react/src/index.ts | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/react/package.json b/packages/react/package.json index 382f9b7de..bcfcbb033 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/react", - "version": "2.2.2-alpha.2", + "version": "2.2.2-alpha.3", "description": "Collection of React Hooks for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", diff --git a/packages/react/src/index.ts b/packages/react/src/index.ts index ea2a80e86..8de00de28 100644 --- a/packages/react/src/index.ts +++ b/packages/react/src/index.ts @@ -51,7 +51,8 @@ const useAppState: { return stateKey ? snapshot[stateKey] : snapshot }, [stateKey]) - return useSyncExternalStore(subscribe, getSnapshot) + const getServerSnapshot = () => get() || getSnapshot; + return useSyncExternalStore(subscribe, getSnapshot, getServerSnapshot); } export const useConnectWallet = (): [ From 7b0015bbefbaa49c02bf422d8fb62658220a5510 Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Thu, 30 Jun 2022 14:41:37 -0600 Subject: [PATCH 13/17] Bumpm demo versions --- packages/demo/package.json | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/packages/demo/package.json b/packages/demo/package.json index 4ee32d42b..cec2a2c0f 100644 --- a/packages/demo/package.json +++ b/packages/demo/package.json @@ -22,21 +22,21 @@ "webpack-dev-server": "4.7.4" }, "dependencies": { - "@web3-onboard/coinbase": "^2.0.6", + "@web3-onboard/coinbase": "^2.0.7", "@web3-onboard/core": "^2.3.2", - "@web3-onboard/dcent": "^2.0.3", - "@web3-onboard/fortmatic": "^2.0.5", - "@web3-onboard/gnosis": "^2.0.4", - "@web3-onboard/injected-wallets": "^2.0.11", - "@web3-onboard/keepkey": "^2.1.3", - "@web3-onboard/keystone": "^2.1.4", - "@web3-onboard/ledger": "^2.1.3", - "@web3-onboard/magic": "^2.0.6", - "@web3-onboard/portis": "^2.0.3", - "@web3-onboard/torus": "^2.0.4", - "@web3-onboard/trezor": "^2.1.3", - "@web3-onboard/walletconnect": "^2.0.4", - "@web3-onboard/web3auth": "^2.0.2", + "@web3-onboard/dcent": "^2.0.6", + "@web3-onboard/fortmatic": "^2.0.6", + "@web3-onboard/gnosis": "^2.0.5", + "@web3-onboard/injected-wallets": "^2.0.12", + "@web3-onboard/keepkey": "^2.1.4", + "@web3-onboard/keystone": "^2.1.5", + "@web3-onboard/ledger": "^2.1.4", + "@web3-onboard/magic": "^2.0.7", + "@web3-onboard/portis": "^2.0.4", + "@web3-onboard/torus": "^2.0.5", + "@web3-onboard/trezor": "^2.1.4", + "@web3-onboard/walletconnect": "^2.0.5", + "@web3-onboard/web3auth": "^2.0.3", "vconsole": "^3.9.5" }, "license": "MIT", From 93b41806ff59f4a2f99c732f387de1e120ed5bb7 Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Thu, 30 Jun 2022 14:45:32 -0600 Subject: [PATCH 14/17] bump mew version --- packages/mew/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/mew/package.json b/packages/mew/package.json index ac24511ae..aeed67174 100644 --- a/packages/mew/package.json +++ b/packages/mew/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/mew", - "version": "2.0.3", + "version": "2.0.4", "description": "MEW module for web3-onboard", "repository": "blocknative/web3-onboard", "module": "dist/index.js", From e86904138ecaddb815af2bd22a08b74120ee13dc Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Fri, 1 Jul 2022 08:35:08 -0600 Subject: [PATCH 15/17] Update naming --- packages/core/src/views/Index.svelte | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/core/src/views/Index.svelte b/packages/core/src/views/Index.svelte index dcdca9865..580269ded 100644 --- a/packages/core/src/views/Index.svelte +++ b/packages/core/src/views/Index.svelte @@ -34,7 +34,7 @@ $notify$.enabled && $notify$.position === $accountCenter$.position - $: samePositionMobile = + $: samePositionOrMobile = device.type === 'mobile' || $accountCenter$.position === $notify$.position $: sharedMobileContainerCheck = @@ -339,7 +339,7 @@ ? 'padding-top:0;' : ''} " > - {#if $notify$.position.includes('bottom') && $accountCenter$.position.includes('bottom') && samePositionMobile} + {#if $notify$.position.includes('bottom') && $accountCenter$.position.includes('bottom') && samePositionOrMobile} - {#if $notify$.position.includes('top') && $accountCenter$.position.includes('top') && samePositionMobile} + {#if $notify$.position.includes('top') && $accountCenter$.position.includes('top') && samePositionOrMobile} Date: Fri, 1 Jul 2022 09:02:41 -0600 Subject: [PATCH 16/17] cleanup notify disabled logic --- packages/core/src/index.ts | 34 ++++++++++++++++++++++++---- packages/core/src/views/Index.svelte | 7 +++--- 2 files changed, 33 insertions(+), 8 deletions(-) diff --git a/packages/core/src/index.ts b/packages/core/src/index.ts index ede76737c..e29442eff 100644 --- a/packages/core/src/index.ts +++ b/packages/core/src/index.ts @@ -4,7 +4,11 @@ import disconnectWallet from './disconnect' import setChain from './chain' import { state } from './store' import { reset$ } from './streams' -import { validateInitOptions, validateNotify, validateNotifyOptions } from './validation' +import { + validateInitOptions, + validateNotify, + validateNotifyOptions +} from './validation' import initI18N from './i18n' import App from './views/Index.svelte' import type { InitOptions, OnboardAPI, Notify } from './types' @@ -106,11 +110,11 @@ function init(options: InitOptions): OnboardAPI { if (typeof notify !== 'undefined') { if ('desktop' in notify || 'mobile' in notify) { const error = validateNotifyOptions(notify) - + if (error) { throw error } - + if ( (!notify.desktop || (notify.desktop && !notify.desktop.position)) && accountCenter && @@ -128,6 +132,7 @@ function init(options: InitOptions): OnboardAPI { notify.mobile.position = accountCenter.mobile.position } let notifyUpdate: Partial + if (device.type === 'mobile' && notify.mobile) { notifyUpdate = { ...APP_INITIAL_STATE.notify, @@ -139,15 +144,34 @@ function init(options: InitOptions): OnboardAPI { ...notify.desktop } } + if (!apiKey || !notifyUpdate.enabled) { + notifyUpdate.enabled = false + } updateNotify(notifyUpdate) } else { const error = validateNotify(notify as Notify) - + if (error) { throw error } - updateNotify(notify as Notify) + const notifyUpdate: Partial = { + ...APP_INITIAL_STATE.notify, + ...notify + } + + if (!apiKey || !notifyUpdate.enabled) { + notifyUpdate.enabled = false + } + console.log(notifyUpdate) + updateNotify(notifyUpdate) + } + } else { + const notifyUpdate: Partial = APP_INITIAL_STATE.notify + + if (!apiKey) { + notifyUpdate.enabled = false } + updateNotify(notifyUpdate) } if (svelteInstance) { diff --git a/packages/core/src/views/Index.svelte b/packages/core/src/views/Index.svelte index 580269ded..2b1dedbdb 100644 --- a/packages/core/src/views/Index.svelte +++ b/packages/core/src/views/Index.svelte @@ -8,6 +8,9 @@ import AccountCenter from './account-center/Index.svelte' import Notify from './notify/Index.svelte' import { configuration } from '../configuration' +import type { Observable } from 'rxjs'; +import type { Notification } from '../types' + const { device } = configuration const accountCenter$ = state @@ -18,9 +21,7 @@ .select('notify') .pipe(startWith(state.get().notify), shareReplay(1)) - const notifications$ = $notify$.enabled - ? state.select('notifications').pipe(startWith(state.get().notifications)) - : null + const notifications$: Observable = state.select('notifications').pipe(startWith(state.get().notifications)) const positioningDefaults = { topLeft: 'top: 0; left: 0;', From 5c29be690d43d3387eba1af12b9ad6520c7588f6 Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Fri, 1 Jul 2022 09:04:12 -0600 Subject: [PATCH 17/17] Prettier formatting --- packages/core/src/views/Index.svelte | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/packages/core/src/views/Index.svelte b/packages/core/src/views/Index.svelte index 2b1dedbdb..709873e48 100644 --- a/packages/core/src/views/Index.svelte +++ b/packages/core/src/views/Index.svelte @@ -8,9 +8,8 @@ import AccountCenter from './account-center/Index.svelte' import Notify from './notify/Index.svelte' import { configuration } from '../configuration' -import type { Observable } from 'rxjs'; -import type { Notification } from '../types' - + import type { Observable } from 'rxjs' + import type { Notification } from '../types' const { device } = configuration const accountCenter$ = state @@ -21,7 +20,9 @@ import type { Notification } from '../types' .select('notify') .pipe(startWith(state.get().notify), shareReplay(1)) - const notifications$: Observable = state.select('notifications').pipe(startWith(state.get().notifications)) + const notifications$: Observable = state + .select('notifications') + .pipe(startWith(state.get().notifications)) const positioningDefaults = { topLeft: 'top: 0; left: 0;',