From b2854433ec7b816cf700d13c4bd3fac600c7266d Mon Sep 17 00:00:00 2001
From: Wenty Li <105278450+wenty22@users.noreply.github.com>
Date: Fri, 1 Dec 2023 15:22:19 +0800
Subject: [PATCH 1/4] docs: Update CONTRIBUTING.md
---
CONTRIBUTING.md | 36 ++++++++++++++++++++++++++++++------
1 file changed, 30 insertions(+), 6 deletions(-)
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 632a16a3..6b195e7a 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -55,11 +55,11 @@ Before adding a new wallet, you need to collect some information:
| item | description | e.g. | required |
| ------------------ | --------------------------------------------------------------------------------------------------- | ----------------------------------- | -------- |
-| wallet name | - | Trust Wallet | yes |
+| wallet name | - | Trust Wallet | ✔️ |
| short name | If display space is insufficient, the short name will be displayed. | Trust | optional |
-| wallet logo | logo in svg format. | - | yes |
-| download url | - | https://trustwallet.com/download | yes |
-| deeplink | After clicking deeplink in the system browser, we can directly open dapp in the app's dapp browser. | trust://open_url?coin_id=60&url=xxx | yes |
+| wallet logo | logo in svg format. | - | ✔️ |
+| download url | - | https://trustwallet.com/download | ✔️ |
+| deeplink | After clicking deeplink in the system browser, we can directly open dapp in the app's dapp browser. | trust://open_url?coin_id=60&url=xxx | ✔️ |
| WalletConnect link | If your app supports WalletConnect, please provides the WalletConnect uri. | trust://wc?uri=xxx | optional |
Then you can add it to project by following steps:
@@ -117,7 +117,7 @@ export function trustWallet(props: TrustWalletProps = {}): WalletProps {
default: 'https://trustwallet.com/',
},
spinnerColor: '#1098FC',
- installed: isTrustWallet(),
+ isInstalled: isTrustWallet,
createConnector: (chains: Chain[]) => {
return new TrustWalletConnector({
chains,
@@ -163,7 +163,7 @@ export interface WalletProps {
};
spinnerColor?: string;
showQRCode?: boolean;
- installed: boolean | undefined;
+ isInstalled: () => boolean | undefined;
createConnector: (chains: Chain[]) => Connector;
getDeepLink: () => string | undefined;
getQRCodeUri?: (uri: string) => string;
@@ -205,6 +205,30 @@ const config = createConfig(
);
```
+## Notice!!! Test cases for adding a new wallet
+
+Before merging the PR to main branch, we hope you complete the following tests, and fill the test results into the PR template, otherwise the PR may
+not be approved.
+
+In general, wallet is available at several different platforms, such as PC browser extension,
+Android, iOS and WalletConnect. If your wallet supports the corresponding platform, please make sure
+your wallet is worked, can it be connected, can it switch networks, and can it support testnet?
+
+
+
+|test case|steps|support?|connected?|switch networks?|support testnet?|
+|-|-|-|-|-|-|
+|PC, browser extension|
Open dapp in PC browser Select your wallet, check the functions |✔️|✔️|✔️|✔️|
+|Android, in system browser|Open dapp in Android system browser, select your wallet The wallet app will be evoked, and the dapp will be open in the wallet dapp browser Select your wallet, check the functions |✔️|✔️|❌|✔️|
+|Android, in wallet dapp browser|Open dapp in the wallet dapp browser Select your wallet, check the functions |✔️|✔️|✔️|✔️|
+|iOS, in system browser|Open dapp in iOS system browser, select your wallet The wallet app will be evoked, and the dapp will be open in the wallet dapp browser Select your wallet, check the functions |✔️|✔️|✔️|❌|
+|iOS, in wallet dapp browser|Open dapp in the wallet dapp browser Select your wallet, check the functions |✔️|✔️|✔️|❌|
+|WalletConnect, PC|Scan the QR code of WalletConnect using your wallet app You will see a popup on the wallet app that asks you to connect WalletConnect Check the functions |✔️|✔️|✔️|✔️|
+|WalletConnect, Android, in system browser|Open dapp in Android system browser, select WalletConnect, choose your wallet in WalletConnect wallet list The wallet app will be evoked, a popup for applying to connect WalletConnect will be displayed. Check the functions |✔️|✔️|✔️|✔️|
+|WalletConnect, Android, in wallet dapp browser|Open dapp in the wallet dapp browser Select WalletConnect, choose your wallet in WalletConnect wallet list A popup for applying to connect WalletConnect will be displayed Check the functions |✔️|✔️|✔️|✔️|
+|WalletConnect, iOS, in system browser|Open dapp in iOS system browser, select WalletConnect, choose your wallet in WalletConnect wallet list The wallet app will be evoked, a popup for applying to connect WalletConnect will be displayed. Check the functions |✔️|✔️|✔️|✔️|
+|WalletConnect, iOS, in wallet dapp browser|Open dapp in the wallet dapp browser Select WalletConnect, choose your wallet in WalletConnect wallet list A popup for applying to connect WalletConnect will be displayed Check the functions |✔️|✔️|✔️|✔️|
+
## Release notes
A complete development workflow like following:
From d18aedbbebe3a7d8975a54af80639f64417a2a0b Mon Sep 17 00:00:00 2001
From: Wenty Li <105278450+wenty22@users.noreply.github.com>
Date: Fri, 1 Dec 2023 15:28:33 +0800
Subject: [PATCH 2/4] docs: Add test result table
---
.github/PULL_REQUEST_TEMPLATE.md | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md
index 68e6da91..15fd1e6f 100644
--- a/.github/PULL_REQUEST_TEMPLATE.md
+++ b/.github/PULL_REQUEST_TEMPLATE.md
@@ -30,3 +30,22 @@
- [ ] I have read the **CONTRIBUTING** document.
- [ ] I have added tests to cover my changes.
- [ ] All new and existing tests passed.
+
+## For adding a new wallet
+
+For more detail, please click [here](../CONTRIBUTING.md#notice-test-cases-for-adding-a-new-wallet)
+
+
+|test case|support?|connected?|switch networks?|support testnet?|
+|-|-|-|-|-|
+|PC, browser extension| ✔️ | ✔️ | ❌ | ❌ |
+|Android, in system browser| | | | |
+|Android, in wallet dapp browser| | | | |
+|iOS, in system browser| | | | |
+|iOS, in wallet dapp browser| | | | |
+|WalletConnect, PC| | | | |
+|WalletConnect, Android, in system browser| | | | |
+|WalletConnect, Android, in wallet dapp browser| | | | |
+|WalletConnect, iOS, in system browser| | | | |
+|WalletConnect, iOS, in wallet dapp browser| | | | |
+
From 084a397a261093f64e80c5b5fbd700e2cfe7a3ec Mon Sep 17 00:00:00 2001
From: Wenty Li <105278450+wenty22@users.noreply.github.com>
Date: Wed, 13 Dec 2023 10:11:10 +0800
Subject: [PATCH 3/4] build: release 1.0.7 (#60)
* chore: Update bug_report template (#26)
* feat: Add test example
* feat: Update examples
* feat: Add disclaimer & download url
* docs: Update example
* docs: Update docs
* docs: Update docs
* docs: Update gitignore
* docs: Update docs
* feat: Add zIndices theme config
* feat: Update examples
* feat: Refactor switch network modal
* refactor: Clean code
* feat: Update examples
* refactor: Update dependencies
* feat: Update version
* docs: Update docs
* chore: Add changeset
* test: Test changeset version
* docs: Create LICENSE
* docs: Update packages info
* chore: Add husky & lint-staged
* abc: test commit lint
* chore: Update husky
* chore: Update husky
* test: test husky
* chore: Add issue & pr template
* fix: Update OpenSwitchNetworkOptions type
* feat: Add options to control modal close
* feat: Add default wallets to walletConnect
* docs: Update useModal document
* refactor: Add className to base components
* chore: Add release github acton
* chore: Add publish ci script
* chore: Fix github action
* chore: Update github action
* test: Test github action
* chore: Add .pnpm-store to gitignore
* chore: Update github action
* chore: Copy readme to walletkit package when publish
* chore: Update issue_template
* chore: Update pr & issue template
* Update bug_report.yml
* Create config.yml
* Delete .github/ISSUE_TEMPLATE/config.yml
* Update bug_report.yml
* Update bug_report.yml
* chore: Update bug_report.yml
* style: Add chains type declaration for dev example
* style: Add chains type declaration for dev example
* chore: test docs release workflow
* chore: Test docs release workflow
* chore: test docs release workflow
* chore: test docs release workflow
* style: Add chains type declaration for dev example
* chore: test docs release workflow
* chore: Test docs release workflow
* chore: test docs release workflow
* chore: test docs release workflow
* test: test alpha release
* chore: update versions (alpha) (#39)
Co-authored-by: github-actions[bot]
* docs: Update docs
* fix: fix theme `auto` mode issue & fix walletConnect chains error
* fix: fixed `WalletConnect` automatic connection issue
* chore: Update dependencies versions
* chore: update versions (alpha) (#41)
Co-authored-by: github-actions[bot]
* chore: prettier & eslint ignore changeset's md files
* fix: No need refresh when open WalletConnect Modal in QRCode page
* chore: Add vconsole for dev demo
* fix: fixed trustwallet losing status after refreshing
* chore: update release info
* fix: Fixed trustwallet losing account status after refreshing (#44)
* chore: prettier & eslint ignore changeset's md files
* fix: No need refresh when open WalletConnect Modal in QRCode page
* chore: Add vconsole for dev demo
* fix: fixed trustwallet losing status after refreshing
* chore: update release info
* chore: update versions (alpha) (#45)
Co-authored-by: github-actions[bot]
* style: Update log output styles
* style: Add switchNetwork log
* refactor: update the `installed` field that detect whether wallet is installed to a function
* fix: fixed conflict issue between trustwallet and metaMask
* docs: update release docs
* Dev (#47)
* chore: prettier & eslint ignore changeset's md files
* fix: No need refresh when open WalletConnect Modal in QRCode page
* chore: Add vconsole for dev demo
* fix: fixed trustwallet losing status after refreshing
* chore: update release info
* style: Update log output styles
* style: Add switchNetwork log
* refactor: update the `installed` field that detect whether wallet is installed to a function
* fix: fixed conflict issue between trustwallet and metaMask
* docs: update release docs
* chore: update versions (alpha) (#48)
Co-authored-by: github-actions[bot]
* docs: Add tests for adding new wallet
* Dev (#49)
* chore: prettier & eslint ignore changeset's md files
* fix: No need refresh when open WalletConnect Modal in QRCode page
* chore: Add vconsole for dev demo
* fix: fixed trustwallet losing status after refreshing
* chore: update release info
* style: Update log output styles
* style: Add switchNetwork log
* refactor: update the `installed` field that detect whether wallet is installed to a function
* fix: fixed conflict issue between trustwallet and metaMask
* docs: update release docs
* docs: Add tests for adding new wallet
* docs: Update contributing
* docs: Add test result table to PULL_REQUEST_TEMPLATE
* fix: fixed multiple wallet conflicts resulting in undetectable issues
* chore: Add changeset log
* fix: Fixed multiple wallets conficts resulting in undetectable issues. (#51)
* docs: Add test result table to PULL_REQUEST_TEMPLATE
* fix: fixed multiple wallet conflicts resulting in undetectable issues
* chore: Add changeset log
* chore: update versions (alpha) (#52)
Co-authored-by: github-actions[bot]
* fix: Fixed TrustWallet will automatically reconnect after reloading the page. (#53)
* docs: Add test result table to PULL_REQUEST_TEMPLATE
* fix: fixed multiple wallet conflicts resulting in undetectable issues
* chore: Add changeset log
* chore: update versions (alpha) (#54)
Co-authored-by: github-actions[bot]
* feat: add `action` prop to WalletKitButton & WalletKitButton.Custom to support the case of adding network.
* Add `action` prop to WalletKitButton & WalletKitButton.Custom to support the case of adding network. (#56)
* docs: Add test result table to PULL_REQUEST_TEMPLATE
* fix: fixed multiple wallet conflicts resulting in undetectable issues
* chore: Add changeset log
* feat: add `action` prop to WalletKitButton & WalletKitButton.Custom to support the case of adding network.
* chore: update versions (alpha) (#57)
Co-authored-by: github-actions[bot]
* fix: fix theme configuration naming error issue
* docs: Add changeset docs
* build: release
---------
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot]
---
.changeset/afraid-crabs-pump.md | 5 +
.changeset/famous-drinks-behave.md | 5 +
.changeset/happy-hounds-complain.md | 5 +
.changeset/honest-numbers-hug.md | 5 +
.changeset/late-birds-compare.md | 5 +
.changeset/lovely-months-argue.md | 5 +
.changeset/modern-comics-smell.md | 5 +
.changeset/pre.json | 19 +
.changeset/pretty-flowers-rhyme.md | 5 +
.eslintignore | 3 +-
.github/actions/setup/action.yaml | 25 +
.github/workflows/docs.yaml | 38 ++
.github/workflows/release.yaml | 30 +-
.prettierignore | 2 +-
CONTRIBUTING.md | 8 +-
README.md | 6 +-
examples/nextjs/package.json | 4 +-
examples/nextjs/pages/_app.tsx | 2 +-
examples/nextjs/pages/_document.tsx | 2 +
examples/vite/package.json | 4 +-
examples/vite/src/App.tsx | 2 +-
package.json | 13 +-
packages/walletkit/CHANGELOG.md | 76 ++-
packages/walletkit/README.md | 6 +-
packages/walletkit/dev/App.tsx | 3 +
packages/walletkit/dev/index.html | 27 +
packages/walletkit/dev/vite.config.ts | 7 +-
packages/walletkit/package.json | 7 +-
.../src/chains/icons/EthereumIcon.tsx | 14 +
packages/walletkit/src/chains/index.tsx | 28 +-
.../src/components/EthereumScript/index.tsx | 30 ++
.../src/components/ModalProvider/context.ts | 7 +-
.../src/components/ModalProvider/index.tsx | 10 +-
.../src/components/ThemeProvider/index.tsx | 4 +-
.../WalletKitButton/ConnectButton/index.tsx | 15 +-
.../ConnectButtonRenderer/index.tsx | 15 +-
.../components/WalletKitProvider/context.ts | 6 +-
.../components/WalletKitProvider/index.tsx | 10 +-
.../src/defaultConfig/getDefaultConfig.ts | 53 +-
packages/walletkit/src/globalData/index.ts | 20 +-
.../walletkit/src/hooks/useClickWallet.ts | 13 +-
packages/walletkit/src/hooks/useConnector.ts | 6 -
packages/walletkit/src/hooks/useQRCodeUri.ts | 24 +-
.../src/hooks/useWalletConnectModal.ts | 16 +-
.../src/hooks/useWalletKitConnect.ts | 8 +-
.../src/hooks/useWalletKitSwitchNetwork.ts | 10 +-
packages/walletkit/src/index.ts | 1 +
.../src/pages/ConnectWithQRCode/index.tsx | 6 -
.../walletkit/src/pages/Connecting/index.tsx | 26 +-
.../src/pages/Connectors/GridLayout/index.tsx | 10 +-
.../pages/Connectors/GridLayout/styles.css.ts | 4 +-
.../src/pages/Connectors/ListLayout/index.tsx | 10 +-
.../walletkit/src/pages/Connectors/index.tsx | 9 +-
.../src/pages/SwitchNetwork/index.tsx | 6 +-
packages/walletkit/src/themes/base.ts | 8 +-
packages/walletkit/src/typings.d.ts | 1 -
packages/walletkit/src/utils/common.ts | 8 +
.../src/wallets/binanceWeb3Wallet/index.tsx | 6 +-
.../src/wallets/coinbaseWallet/icon.tsx | 15 +-
.../src/wallets/coinbaseWallet/index.tsx | 7 +-
.../walletkit/src/wallets/injected/index.tsx | 2 +-
.../src/wallets/mathWallet/index.tsx | 2 +-
.../walletkit/src/wallets/metaMask/icon.tsx | 15 +-
.../walletkit/src/wallets/metaMask/index.tsx | 16 +-
.../walletkit/src/wallets/okxWallet/index.tsx | 4 +-
packages/walletkit/src/wallets/safe/index.tsx | 2 +-
.../src/wallets/tokenPocket/icon.tsx | 2 +-
.../src/wallets/tokenPocket/index.tsx | 10 +-
.../src/wallets/trustWallet/connector.ts | 8 +
.../src/wallets/trustWallet/index.tsx | 8 +-
packages/walletkit/src/wallets/types.ts | 2 +-
.../src/wallets/walletConnect/index.tsx | 11 +-
pnpm-lock.yaml | 466 +++++++++---------
website/package.json | 5 +-
website/src/App.tsx | 8 +-
website/src/components/Layout/index.tsx | 6 +-
website/src/components/WalletKit/index.tsx | 2 +-
website/src/pages/index.mdx | 9 +-
78 files changed, 798 insertions(+), 510 deletions(-)
create mode 100644 .changeset/afraid-crabs-pump.md
create mode 100644 .changeset/famous-drinks-behave.md
create mode 100644 .changeset/happy-hounds-complain.md
create mode 100644 .changeset/honest-numbers-hug.md
create mode 100644 .changeset/late-birds-compare.md
create mode 100644 .changeset/lovely-months-argue.md
create mode 100644 .changeset/modern-comics-smell.md
create mode 100644 .changeset/pre.json
create mode 100644 .changeset/pretty-flowers-rhyme.md
create mode 100644 .github/actions/setup/action.yaml
create mode 100644 .github/workflows/docs.yaml
create mode 100644 packages/walletkit/src/chains/icons/EthereumIcon.tsx
create mode 100644 packages/walletkit/src/components/EthereumScript/index.tsx
delete mode 100644 packages/walletkit/src/hooks/useConnector.ts
diff --git a/.changeset/afraid-crabs-pump.md b/.changeset/afraid-crabs-pump.md
new file mode 100644
index 00000000..c9bc7057
--- /dev/null
+++ b/.changeset/afraid-crabs-pump.md
@@ -0,0 +1,5 @@
+---
+'@totejs/walletkit': patch
+---
+
+Fixed theme configuration naming error issue
diff --git a/.changeset/famous-drinks-behave.md b/.changeset/famous-drinks-behave.md
new file mode 100644
index 00000000..d53113e8
--- /dev/null
+++ b/.changeset/famous-drinks-behave.md
@@ -0,0 +1,5 @@
+---
+'@totejs/walletkit': patch
+---
+
+Fixed TrustWallet will automatically reconnect after reloading the page.
diff --git a/.changeset/happy-hounds-complain.md b/.changeset/happy-hounds-complain.md
new file mode 100644
index 00000000..17ddadad
--- /dev/null
+++ b/.changeset/happy-hounds-complain.md
@@ -0,0 +1,5 @@
+---
+'@totejs/walletkit': patch
+---
+
+refactor: update the `installed` field that detect whether wallet is installed to a function
diff --git a/.changeset/honest-numbers-hug.md b/.changeset/honest-numbers-hug.md
new file mode 100644
index 00000000..12669d36
--- /dev/null
+++ b/.changeset/honest-numbers-hug.md
@@ -0,0 +1,5 @@
+---
+'@totejs/walletkit': patch
+---
+
+Fixed multiple wallets conficts resulting in undetectable issues.
diff --git a/.changeset/late-birds-compare.md b/.changeset/late-birds-compare.md
new file mode 100644
index 00000000..2471f4e7
--- /dev/null
+++ b/.changeset/late-birds-compare.md
@@ -0,0 +1,5 @@
+---
+'@totejs/walletkit': patch
+---
+
+Fixed `WalletConnect` automatic connection issue in the follow scenario: connect the WalletConnect -> close browser -> reopen browser -> disconnect -> select WalletConnect, will automatically connect.
diff --git a/.changeset/lovely-months-argue.md b/.changeset/lovely-months-argue.md
new file mode 100644
index 00000000..8674cc05
--- /dev/null
+++ b/.changeset/lovely-months-argue.md
@@ -0,0 +1,5 @@
+---
+'@totejs/walletkit': patch
+---
+
+Fixed trustwallet losing account status after refreshing
diff --git a/.changeset/modern-comics-smell.md b/.changeset/modern-comics-smell.md
new file mode 100644
index 00000000..55dfc42c
--- /dev/null
+++ b/.changeset/modern-comics-smell.md
@@ -0,0 +1,5 @@
+---
+'@totejs/walletkit': patch
+---
+
+Fixed conflict issue between trustwallet and metaMask.
diff --git a/.changeset/pre.json b/.changeset/pre.json
new file mode 100644
index 00000000..06ad5de3
--- /dev/null
+++ b/.changeset/pre.json
@@ -0,0 +1,19 @@
+{
+ "mode": "exit",
+ "tag": "alpha",
+ "initialVersions": {
+ "example-nextjs": "0.0.1",
+ "example-vite": "0.0.1",
+ "@totejs/walletkit": "1.0.7-alpha.2",
+ "website": "0.0.1"
+ },
+ "changesets": [
+ "famous-drinks-behave",
+ "happy-hounds-complain",
+ "honest-numbers-hug",
+ "late-birds-compare",
+ "lovely-months-argue",
+ "modern-comics-smell",
+ "pretty-flowers-rhyme"
+ ]
+}
diff --git a/.changeset/pretty-flowers-rhyme.md b/.changeset/pretty-flowers-rhyme.md
new file mode 100644
index 00000000..261fa305
--- /dev/null
+++ b/.changeset/pretty-flowers-rhyme.md
@@ -0,0 +1,5 @@
+---
+'@totejs/walletkit': patch
+---
+
+Add `action` prop to WalletKitButton & WalletKitButton.Custom to support the case of adding network.
diff --git a/.eslintignore b/.eslintignore
index 3859ffd8..2ff8f9da 100644
--- a/.eslintignore
+++ b/.eslintignore
@@ -1,4 +1,3 @@
.next
dist
-CHANGELOG.md
-build.cjs
\ No newline at end of file
+**/*.md
\ No newline at end of file
diff --git a/.github/actions/setup/action.yaml b/.github/actions/setup/action.yaml
new file mode 100644
index 00000000..7b3a6999
--- /dev/null
+++ b/.github/actions/setup/action.yaml
@@ -0,0 +1,25 @@
+name: 'setup'
+description: Prepare the environment
+
+runs:
+ using: composite
+ steps:
+ - name: Setup node.js
+ uses: actions/setup-node@v3
+ with:
+ node-version: 16
+
+ - name: Setup pnpm
+ uses: pnpm/action-setup@v2
+ id: pnpm-install
+ with:
+ version: 8
+ run_install: false
+
+ - name: Setup pnpm config
+ shell: bash
+ run: pnpm config set store-dir .pnpm-store
+
+ - name: Install dependencies
+ shell: bash
+ run: pnpm install
diff --git a/.github/workflows/docs.yaml b/.github/workflows/docs.yaml
new file mode 100644
index 00000000..989ab81d
--- /dev/null
+++ b/.github/workflows/docs.yaml
@@ -0,0 +1,38 @@
+name: Deploy docs
+on:
+ push:
+ branches:
+ - main
+ - alpha
+
+jobs:
+ release:
+ name: deploy docs
+ if: github.repository == 'node-real/walletkit'
+ timeout-minutes: 10
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout code repository
+ uses: actions/checkout@v3
+ with:
+ fetch-depth: 0
+
+ - uses: ./.github/actions/setup
+
+ - name: Build docs
+ run: pnpm build:docs
+
+ - name: Redirect
+ run: |
+ mkdir -p ./website/dist/website/dist
+ cat << EOF > "./website/dist/website/dist/index.html"
+
+ EOF
+
+ - name: Deploy docs
+ uses: JamesIves/github-pages-deploy-action@v4
+ with:
+ folder: ./website/dist
+ branch: 'docs'
+ clean: true
+ force: true
diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml
index 391aa96e..7815ae84 100644
--- a/.github/workflows/release.yaml
+++ b/.github/workflows/release.yaml
@@ -3,17 +3,15 @@ on:
push:
branches:
- main
+ - alpha
- 0.x
-
-env:
- CI: true
- PNPM_CACHE_FOLDER: .pnpm-store
+ - 0.x-alpha
jobs:
release:
name: release
if: github.repository == 'node-real/walletkit'
- timeout-minutes: 15
+ timeout-minutes: 10
runs-on: ubuntu-latest
steps:
- name: Checkout code repository
@@ -21,17 +19,10 @@ jobs:
with:
fetch-depth: 0
- - name: Setup node.js
- uses: actions/setup-node@v3
- with:
- node-version: 16
+ - uses: ./.github/actions/setup
- - name: Setup pnpm
- uses: pnpm/action-setup@v2
- id: pnpm-install
- with:
- version: 8
- run_install: false
+ - name: Build packages
+ run: pnpm build
- name: Creating .npmrc
run: |
@@ -41,15 +32,6 @@ jobs:
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- - name: Setup pnpm config
- run: pnpm config set store-dir $PNPM_CACHE_FOLDER
-
- - name: Install dependencies
- run: pnpm install
-
- - name: Build packages
- run: pnpm --filter "@totejs/**" build
-
- name: Create and publish versions
uses: changesets/action@v1
with:
diff --git a/.prettierignore b/.prettierignore
index 9262527b..2ff8f9da 100644
--- a/.prettierignore
+++ b/.prettierignore
@@ -1,3 +1,3 @@
.next
dist
-CHANGELOG.md
\ No newline at end of file
+**/*.md
\ No newline at end of file
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 6b195e7a..87fba8a3 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -207,13 +207,9 @@ const config = createConfig(
## Notice!!! Test cases for adding a new wallet
-Before merging the PR to main branch, we hope you complete the following tests, and fill the test results into the PR template, otherwise the PR may
-not be approved.
-
-In general, wallet is available at several different platforms, such as PC browser extension,
-Android, iOS and WalletConnect. If your wallet supports the corresponding platform, please make sure
-your wallet is worked, can it be connected, can it switch networks, and can it support testnet?
+Before merging the PR to main branch, we hope you complete the following tests, and fill the test results into the PR template, otherwise the PR may not be approved.
+In general, wallet is available at several different platforms, such as PC browser extension, Android, iOS and WalletConnect. If your wallet supports the corresponding platform, please make sure your wallet is worked, can it be connected, can it switch networks, and can it support testnet?
|test case|steps|support?|connected?|switch networks?|support testnet?|
diff --git a/README.md b/README.md
index b0e3b47f..78461d3d 100644
--- a/README.md
+++ b/README.md
@@ -10,14 +10,14 @@ WalletKit is a React component library for easily connecting a wallet to your dA
## Documentation
-For full documentation, visit [here](https://node-real.github.io/walletkit/website/dist/#/index).
+For full documentation, visit [here](https://node-real.github.io/walletkit).
## Examples
The following examples are provided in the [examples](./examples/) folder of this repo.
-- [nextjs](https://github.com/node-real/walletkit/tree/main/examples/nextjs)
-- [vite](https://github.com/node-real/walletkit/tree/main/examples/vite)
+- [nextjs](./examples/nextjs/)
+- [vite](./examples/vite/)
## Installation
diff --git a/examples/nextjs/package.json b/examples/nextjs/package.json
index 8ae42fd4..c486f2ed 100644
--- a/examples/nextjs/package.json
+++ b/examples/nextjs/package.json
@@ -14,12 +14,12 @@
"next": "^13.5.6",
"react": "^18.2.0",
"react-dom": "^18.2.0",
- "viem": "^1.19.8",
+ "viem": "^1.19.9",
"wagmi": "^1.4.7"
},
"devDependencies": {
"@types/node": "^20.10.0",
- "@types/react": "^18.2.38",
+ "@types/react": "^18.2.39",
"@types/react-dom": "^18.2.17",
"typescript": "^5.3.2"
}
diff --git a/examples/nextjs/pages/_app.tsx b/examples/nextjs/pages/_app.tsx
index b4a8eb0e..d9387ed6 100644
--- a/examples/nextjs/pages/_app.tsx
+++ b/examples/nextjs/pages/_app.tsx
@@ -27,7 +27,7 @@ const config = createConfig(
);
const options: WalletKitOptions = {
- initialChainId: 56,
+ initialChainId: 1,
};
export default function App({ Component, pageProps }: AppProps) {
diff --git a/examples/nextjs/pages/_document.tsx b/examples/nextjs/pages/_document.tsx
index 86b57f74..b4c55d0a 100644
--- a/examples/nextjs/pages/_document.tsx
+++ b/examples/nextjs/pages/_document.tsx
@@ -1,10 +1,12 @@
import { Html, Head, Main, NextScript } from 'next/document';
+import { EthereumScript } from '@totejs/walletkit';
export default function Document() {
return (
WalletKit Next.js Example
+
diff --git a/examples/vite/package.json b/examples/vite/package.json
index 6a62c762..a19cc36f 100644
--- a/examples/vite/package.json
+++ b/examples/vite/package.json
@@ -13,11 +13,11 @@
"@totejs/walletkit": "workspace:*",
"react": "^18.2.0",
"react-dom": "^18.2.0",
- "viem": "^1.19.8",
+ "viem": "^1.19.9",
"wagmi": "^1.4.7"
},
"devDependencies": {
- "@types/react": "^18.2.38",
+ "@types/react": "^18.2.39",
"@types/react-dom": "^18.2.17",
"@vitejs/plugin-react": "^4.2.0",
"typescript": "^5.3.2",
diff --git a/examples/vite/src/App.tsx b/examples/vite/src/App.tsx
index 455a875c..38459e33 100644
--- a/examples/vite/src/App.tsx
+++ b/examples/vite/src/App.tsx
@@ -25,7 +25,7 @@ const config = createConfig(
);
const options: WalletKitOptions = {
- initialChainId: 56,
+ initialChainId: 1,
};
export default function App() {
diff --git a/package.json b/package.json
index eb808576..e8c2cac6 100644
--- a/package.json
+++ b/package.json
@@ -9,12 +9,17 @@
"scripts": {
"prepare": "husky install",
"lint": "pnpm eslint .",
- "dev": "pnpm --filter @totejs/walletkit dev",
- "ci:version": "pnpm changeset version && pnpm install && cp README.md packages/walletkit/README.md",
- "ci:publish": "pnpm publish -r"
+ "dev": "pnpm --F @totejs/walletkit dev",
+ "build": "pnpm --F @totejs/walletkit build",
+ "dev:docs": "pnpm --F @totejs/walletkit build:watch & pnpm --F website dev",
+ "build:docs": "pnpm --F @totejs/walletkit build && pnpm --F website build",
+ "pre:enter": "pnpm changeset pre enter alpha",
+ "pre:exit": "pnpm changeset pre exit",
+ "ci:version": "pnpm changeset version && cp README.md packages/walletkit/README.md",
+ "ci:publish": "pnpm changeset publish"
},
"devDependencies": {
- "@changesets/cli": "^2.26.2",
+ "@changesets/cli": "^2.27.1",
"@commitlint/cli": "^18.4.3",
"@commitlint/config-conventional": "^18.4.3",
"@typescript-eslint/eslint-plugin": "^5.62.0",
diff --git a/packages/walletkit/CHANGELOG.md b/packages/walletkit/CHANGELOG.md
index ae2a8fc6..06268094 100644
--- a/packages/walletkit/CHANGELOG.md
+++ b/packages/walletkit/CHANGELOG.md
@@ -1,35 +1,79 @@
# @totejs/walletkit
+## 1.0.7-alpha.6
+
+### Patch Changes
+
+- c431545: Add `action` prop to WalletKitButton & WalletKitButton.Custom to support the case of
+ adding network.
+
+## 1.0.7-alpha.5
+
+### Patch Changes
+
+- f851750: Fixed TrustWallet will automatically reconnect after reloading the page.
+
+## 1.0.7-alpha.4
+
+### Patch Changes
+
+- 78c9fc8: Fixed multiple wallets conficts resulting in undetectable issues.
+
+## 1.0.7-alpha.3
+
+### Patch Changes
+
+- e418a56: Update the `installed` field that detect whether wallet is installed to a function
+- e418a56: Fixed conflict issue between trustwallet and metaMask.
+
+## 1.0.7-alpha.2
+
+### Patch Changes
+
+- 52e9976: Fixed trustwallet losing account status after refreshing
+
+## 1.0.7-alpha.1
+
+### Patch Changes
+
+- 3dd2578: Fixed `WalletConnect` automatic connection issue in the follow scenario: connect the
+ WalletConnect -> close browser -> reopen browser -> disconnect -> select WalletConnect, will
+ automatically connect.
+
## 1.0.6
### Patch Changes
-- 9fd73b8: Add chains type declaration for dev example
-- 9fd73b8: Fixed typescript declaration files export path error, remove `dev` in tsconfig.json
- includes field
+- 9fd73b8:
+ - Add chains type declaration for `dev example`
+- 9fd73b8:
+ - Fixed typescript declaration files export path error, remove `dev` from tsconfig.json includes
+ field
## 1.0.5
### Patch Changes
-- d3aaaf9: Add chains type declaration for dev example
-- 12ebee8: Add Binance Web3 Wallet & Coinbase Wallet & OKX Wallet & MathWallet support.
+- 12ebee8:
+
+ - Add Binance Web3 Wallet & Coinbase Wallet & OKX Wallet & MathWallet support.
- Add showQRCode & getQRCodeUri configuration items to support display a QR code when a wallet is
- not installed.
+ - Add showQRCode & getQRCodeUri configuration items to support display a QR code when a wallet is
+ not installed.
- UI adapted to mobile end and multiple wallets.
+ - UI adapted to mobile end and multiple wallets.
- Fixed the hover effect did not disappear after clicking button on the mobile end.
+ - Fixed the hover effect did not disappear after clicking button on the mobile end.
- Fixed walletConnect popup and QR code display being very slow issue.
+ - Fixed walletConnect popup and QR code display being very slow issue.
- Disabled page scrolling when opening walletkit modal.
+ - Disabled page scrolling when opening walletkit modal.
- For a smoother development experience, remove `examples/test` and create a dev demo in
- `packages/walletkit`.
+ - For a smoother development experience, remove `examples/test` and create a dev demo in
+ `packages/walletkit`.
- Update walletConnect `relayUrl` to `wss://relay.walletconnect.org`.
+ - Update walletConnect `relayUrl` to `wss://relay.walletconnect.org`.
-- 4a88b07: Remove default `initialChainId` to support the case only connecting a wallet and not
- switching a network.
+- 4a88b07:
+ - Remove default `initialChainId` to support the case only connecting a wallet and not switching a
+ network.
diff --git a/packages/walletkit/README.md b/packages/walletkit/README.md
index b0e3b47f..78461d3d 100644
--- a/packages/walletkit/README.md
+++ b/packages/walletkit/README.md
@@ -10,14 +10,14 @@ WalletKit is a React component library for easily connecting a wallet to your dA
## Documentation
-For full documentation, visit [here](https://node-real.github.io/walletkit/website/dist/#/index).
+For full documentation, visit [here](https://node-real.github.io/walletkit).
## Examples
The following examples are provided in the [examples](./examples/) folder of this repo.
-- [nextjs](https://github.com/node-real/walletkit/tree/main/examples/nextjs)
-- [vite](https://github.com/node-real/walletkit/tree/main/examples/vite)
+- [nextjs](./examples/nextjs/)
+- [vite](./examples/vite/)
## Installation
diff --git a/packages/walletkit/dev/App.tsx b/packages/walletkit/dev/App.tsx
index df07e60e..b712b404 100644
--- a/packages/walletkit/dev/App.tsx
+++ b/packages/walletkit/dev/App.tsx
@@ -1,5 +1,6 @@
import { chains } from './chains';
import { WagmiConfig, createConfig } from 'wagmi';
+import VConsole from 'vconsole';
import {
SwitchNetworkModal,
ThemeMode,
@@ -23,6 +24,8 @@ import {
} from '../src/wallets';
import React from 'react';
+new VConsole();
+
const config = createConfig(
getDefaultConfig({
autoConnect: true,
diff --git a/packages/walletkit/dev/index.html b/packages/walletkit/dev/index.html
index f5e32244..07e23793 100644
--- a/packages/walletkit/dev/index.html
+++ b/packages/walletkit/dev/index.html
@@ -5,6 +5,33 @@
WalletKit Test Demo
+
diff --git a/packages/walletkit/dev/vite.config.ts b/packages/walletkit/dev/vite.config.ts
index 6334f25c..4843eec6 100644
--- a/packages/walletkit/dev/vite.config.ts
+++ b/packages/walletkit/dev/vite.config.ts
@@ -6,7 +6,12 @@ import { vanillaExtractPlugin } from '@vanilla-extract/vite-plugin';
export default defineConfig({
root: './dev',
- plugins: [react(), vanillaExtractPlugin()],
+ plugins: [
+ react(),
+ vanillaExtractPlugin({
+ identifiers: ({ hash }) => `wk_${hash}`,
+ }),
+ ],
resolve: {
alias: {
'@': path.resolve(__dirname, '../src'),
diff --git a/packages/walletkit/package.json b/packages/walletkit/package.json
index 0b4b0f1b..f4852f70 100644
--- a/packages/walletkit/package.json
+++ b/packages/walletkit/package.json
@@ -1,6 +1,6 @@
{
"name": "@totejs/walletkit",
- "version": "1.0.6",
+ "version": "1.0.7-alpha.6",
"author": "node-real",
"private": false,
"description": "WalletKit is a React component library for easily connecting a wallet to your dApp.",
@@ -43,7 +43,7 @@
"devDependencies": {
"@rollup/plugin-node-resolve": "^15.2.3",
"@types/qrcode": "^1.5.5",
- "@types/react": "^18.2.38",
+ "@types/react": "^18.2.39",
"@types/react-dom": "^18.2.17",
"@vanilla-extract/css": "^1.14.0",
"@vanilla-extract/vite-plugin": "^3.9.2",
@@ -52,7 +52,8 @@
"react-dom": "^18.2.0",
"rollup-plugin-peer-deps-external": "^2.2.4",
"typescript": "^5.3.2",
- "viem": "^1.19.8",
+ "vconsole": "^3.15.1",
+ "viem": "^1.19.9",
"vite": "^4.5.0",
"vite-plugin-dts": "^3.6.3",
"wagmi": "^1.4.7"
diff --git a/packages/walletkit/src/chains/icons/EthereumIcon.tsx b/packages/walletkit/src/chains/icons/EthereumIcon.tsx
new file mode 100644
index 00000000..4cc13998
--- /dev/null
+++ b/packages/walletkit/src/chains/icons/EthereumIcon.tsx
@@ -0,0 +1,14 @@
+import { SVGIconProps } from '@/types';
+
+export function EthereumIcon(props: SVGIconProps) {
+ return (
+
+
+
+
+
+
+
+
+ );
+}
diff --git a/packages/walletkit/src/chains/index.tsx b/packages/walletkit/src/chains/index.tsx
index 2235f9fc..5441e11a 100644
--- a/packages/walletkit/src/chains/index.tsx
+++ b/packages/walletkit/src/chains/index.tsx
@@ -1,7 +1,13 @@
import { BscIcon } from './icons/BscIcon';
import { ComboIcon } from './icons/ComboIcon';
+import { EthereumIcon } from './icons/EthereumIcon';
const chainsConfig = [
+ {
+ id: 1,
+ name: 'Ethereum',
+ logo: ,
+ },
{
id: 56,
name: 'BSC',
@@ -15,7 +21,27 @@ const chainsConfig = [
{
id: 91715,
name: 'Combo Testnet',
- logo: ,
+ logo: ,
+ },
+ {
+ id: 204,
+ name: 'opBNB',
+ logo: ,
+ },
+ {
+ id: 1017,
+ name: 'BNB Greenfield',
+ logo: ,
+ },
+ {
+ id: 5600,
+ name: 'BNB Greenfield Testnet',
+ logo: ,
+ },
+ {
+ id: 9000,
+ name: 'BNB Greenfield Devnet',
+ logo: ,
},
];
diff --git a/packages/walletkit/src/components/EthereumScript/index.tsx b/packages/walletkit/src/components/EthereumScript/index.tsx
new file mode 100644
index 00000000..1fb856d3
--- /dev/null
+++ b/packages/walletkit/src/components/EthereumScript/index.tsx
@@ -0,0 +1,30 @@
+export function EthereumScript() {
+ const scriptHtml = `
+ (function() {
+ try {
+ const isMobile =
+ /android|iPhone|iPad|iPod/i.test(navigator.userAgent) ||
+ (navigator.platform === 'MacIntel' && navigator.maxTouchPoints > 1);
+
+ if (!isMobile && window.ethereum && window.ethereum.isMetaMask && window.trustwallet) {
+ const originalEthereum = window.ethereum;
+
+ Object.defineProperty(window, 'ethereum', {
+ enumerable: true,
+ configurable: true,
+ set(v) {
+ if (v.isTrust || v.isTrustWallet) return;
+ this.value = v;
+ },
+ get() {
+ return this.value ?? originalEthereum;
+ },
+ });
+ }
+ } catch (err) {
+ console.error('[ethereum script]', err);
+ }
+ })()
+ `;
+ return ;
+}
diff --git a/packages/walletkit/src/components/ModalProvider/context.ts b/packages/walletkit/src/components/ModalProvider/context.ts
index 3fc56aa4..23f27519 100644
--- a/packages/walletkit/src/components/ModalProvider/context.ts
+++ b/packages/walletkit/src/components/ModalProvider/context.ts
@@ -1,16 +1,21 @@
import React, { useContext } from 'react';
+import { Action } from '../WalletKitProvider/context';
export interface OpenSwitchNetworkOptions {
isClosable?: boolean;
}
+export interface OpenOptions {
+ action?: Action;
+}
+
export interface ModalContextProps {
isClosable: boolean;
closeOnEsc?: boolean;
closeOnOverlayClick?: boolean;
isOpen: boolean;
onClose: () => void;
- onOpen: () => void;
+ onOpen: (options?: OpenOptions) => void;
onOpenProfile: () => void;
onOpenSwitchNetwork: (options?: OpenSwitchNetworkOptions) => void;
}
diff --git a/packages/walletkit/src/components/ModalProvider/index.tsx b/packages/walletkit/src/components/ModalProvider/index.tsx
index ebc1d758..762a7bc7 100644
--- a/packages/walletkit/src/components/ModalProvider/index.tsx
+++ b/packages/walletkit/src/components/ModalProvider/index.tsx
@@ -1,11 +1,11 @@
import { toast } from '@/base/components/toast';
import { useDisclosure } from '@/base/hooks/useDisclosure';
import { useEffect, useMemo, useState } from 'react';
-import { useAccount, useNetwork, useConnect } from 'wagmi';
+import { useAccount, useNetwork } from 'wagmi';
import { routes } from '../RouteProvider';
import { useRouter } from '../RouteProvider/context';
import { useWalletKitContext } from '../WalletKitProvider/context';
-import { OpenSwitchNetworkOptions, ModalContext } from './context';
+import { OpenSwitchNetworkOptions, ModalContext, OpenOptions } from './context';
export interface ModalProviderProps {
children: React.ReactNode;
@@ -21,7 +21,7 @@ export function ModalProvider(props: ModalProviderProps) {
const { chain } = useNetwork();
const router = useRouter();
- const { options } = useWalletKitContext();
+ const { options, setAction } = useWalletKitContext();
const { closeModalAfterConnected, closeModalOnEsc, closeModalOnOverlayClick } = options;
useEffect(() => {
@@ -43,7 +43,8 @@ export function ModalProvider(props: ModalProviderProps) {
router.reset();
}, 300);
},
- onOpen() {
+ onOpen(options?: OpenOptions) {
+ setAction(options?.action);
router.push(routes.CONNECTORS);
onOpen();
},
@@ -80,6 +81,7 @@ export function ModalProvider(props: ModalProviderProps) {
onClose,
onOpen,
router,
+ setAction,
]);
useEffect(() => {
diff --git a/packages/walletkit/src/components/ThemeProvider/index.tsx b/packages/walletkit/src/components/ThemeProvider/index.tsx
index c2c940eb..11775624 100644
--- a/packages/walletkit/src/components/ThemeProvider/index.tsx
+++ b/packages/walletkit/src/components/ThemeProvider/index.tsx
@@ -83,12 +83,14 @@ export function ThemeProvider(props: ThemeProviderProps) {
useEffect(() => {
if (mode === 'auto') {
+ const matchMedia = window.matchMedia('(prefers-color-scheme: dark)');
+
const onChange = () => {
const cm = matchMedia.matches ? 'dark' : 'light';
setColorMode(cm);
};
+ onChange();
- const matchMedia = window.matchMedia('(prefers-color-scheme: dark)');
matchMedia.addEventListener('change', onChange);
return () => {
matchMedia.removeEventListener('change', onChange);
diff --git a/packages/walletkit/src/components/WalletKitButton/ConnectButton/index.tsx b/packages/walletkit/src/components/WalletKitButton/ConnectButton/index.tsx
index e3581c44..2d860a9d 100644
--- a/packages/walletkit/src/components/WalletKitButton/ConnectButton/index.tsx
+++ b/packages/walletkit/src/components/WalletKitButton/ConnectButton/index.tsx
@@ -1,31 +1,30 @@
import { ButtonProps, Button } from '@/base/components/Button';
import { useIsMounted } from '@/base/hooks/useIsMounted';
-import { ConnectRole, useWalletKitContext, useModal, cx } from '@/index';
+import { useModal, cx, Action } from '@/index';
import React, { useCallback } from 'react';
import { useAccount } from 'wagmi';
import { ConnectedInfo } from './ConnectedInfo';
import { clsWalletkitButton } from './styles.css';
export interface ConnectButtonProps extends ButtonProps {
- role?: ConnectRole;
+ action?: Action;
}
export const ConnectButton = React.forwardRef((props: ConnectButtonProps, ref: any) => {
- const { className, role = 'default', onClick, ...restProps } = props;
+ const { className, action, onClick, ...restProps } = props;
- const { setConnectRole } = useWalletKitContext();
const { onOpen } = useModal();
const { isConnected } = useAccount();
const isMounted = useIsMounted();
const onClickButton = useCallback(
(e: React.MouseEvent) => {
- setConnectRole(role);
-
- onOpen();
+ onOpen({
+ action,
+ });
onClick?.(e);
},
- [role, onClick, onOpen, setConnectRole],
+ [action, onClick, onOpen],
);
if (!isMounted) return null;
diff --git a/packages/walletkit/src/components/WalletKitButton/ConnectButtonRenderer/index.tsx b/packages/walletkit/src/components/WalletKitButton/ConnectButtonRenderer/index.tsx
index 842c9256..7809ffca 100644
--- a/packages/walletkit/src/components/WalletKitButton/ConnectButtonRenderer/index.tsx
+++ b/packages/walletkit/src/components/WalletKitButton/ConnectButtonRenderer/index.tsx
@@ -1,12 +1,12 @@
import { routes } from '@/components/RouteProvider';
import { useRouter } from '@/components/RouteProvider/context';
-import { ConnectRole, useWalletKitContext, useModal } from '@/index';
+import { Action, useModal } from '@/index';
import { truncateAddress } from '@/utils/account';
import { useCallback } from 'react';
import { Chain, useAccount, useEnsName, useNetwork } from 'wagmi';
export interface ConnectButtonRendererProps {
- role?: ConnectRole;
+ action?: Action;
children?: (renderProps: {
show: () => void;
@@ -24,9 +24,7 @@ export interface ConnectButtonRendererProps {
}
export function ConnectButtonRenderer(props: ConnectButtonRendererProps) {
- const { role = 'default', children } = props;
-
- const { setConnectRole } = useWalletKitContext();
+ const { action, children } = props;
const { isOpen, onOpen, onClose, onOpenProfile } = useModal();
const router = useRouter();
@@ -39,9 +37,10 @@ export function ConnectButtonRenderer(props: ConnectButtonRendererProps) {
});
const onOpenModal = useCallback(() => {
- setConnectRole(role);
- onOpen();
- }, [setConnectRole, role, onOpen]);
+ onOpen({
+ action,
+ });
+ }, [action, onOpen]);
if (!children) return null;
diff --git a/packages/walletkit/src/components/WalletKitProvider/context.ts b/packages/walletkit/src/components/WalletKitProvider/context.ts
index ffde24bf..fa7cf50b 100644
--- a/packages/walletkit/src/components/WalletKitProvider/context.ts
+++ b/packages/walletkit/src/components/WalletKitProvider/context.ts
@@ -2,7 +2,7 @@ import { ChainProps } from '@/chains/types';
import { ReactNode, createContext, useContext } from 'react';
import { Connector } from 'wagmi';
-export type ConnectRole = 'add-network' | 'default';
+export type Action = 'add-network' | undefined;
export type WalletErrorProps = {
description?: string;
@@ -30,8 +30,8 @@ export interface WalletKitContextProps {
options: WalletKitOptions;
supportedChains: ChainProps[];
- connectRole: ConnectRole;
- setConnectRole: (role: ConnectRole) => void;
+ action: Action;
+ setAction: (action: Action) => void;
selectedConnector: Connector;
setSelectedConnector: (connector: Connector) => void;
diff --git a/packages/walletkit/src/components/WalletKitProvider/index.tsx b/packages/walletkit/src/components/WalletKitProvider/index.tsx
index f34dc867..f357fec8 100644
--- a/packages/walletkit/src/components/WalletKitProvider/index.tsx
+++ b/packages/walletkit/src/components/WalletKitProvider/index.tsx
@@ -9,7 +9,7 @@ import { ModalProvider } from '../ModalProvider';
import { RouteProvider } from '../RouteProvider';
import { ThemeVariant, ThemeMode, ThemeProvider } from '../ThemeProvider';
import { WalletKitModal } from '../WalletKitModal';
-import { WalletKitOptions, ConnectRole, WalletKitContextProps, WalletKitContext } from './context';
+import { WalletKitOptions, WalletKitContextProps, WalletKitContext, Action } from './context';
export interface WalletKitProviderProps {
options: WalletKitOptions;
@@ -30,7 +30,7 @@ export const WalletKitProvider = (props: WalletKitProviderProps) => {
customTheme,
} = props;
- const [connectRole, setConnectRole] = useState('default');
+ const [action, setAction] = useState();
const [selectedConnector, setSelectedConnector] = useState({} as Connector);
const chains = useChains();
@@ -44,13 +44,13 @@ export const WalletKitProvider = (props: WalletKitProviderProps) => {
log: debugMode ? console.log : () => {},
options: finalOptions,
supportedChains: finalChains,
- connectRole,
- setConnectRole,
+ action,
+ setAction,
selectedConnector,
setSelectedConnector,
};
return finalValue;
- }, [options, chains, connectRole, selectedConnector, debugMode]);
+ }, [options, chains, debugMode, action, selectedConnector]);
return (
diff --git a/packages/walletkit/src/defaultConfig/getDefaultConfig.ts b/packages/walletkit/src/defaultConfig/getDefaultConfig.ts
index 9616d859..a413f3db 100644
--- a/packages/walletkit/src/defaultConfig/getDefaultConfig.ts
+++ b/packages/walletkit/src/defaultConfig/getDefaultConfig.ts
@@ -14,7 +14,7 @@ import { WalletProps } from '../wallets/types';
import { WALLET_CONNECT_PROJECT_ID } from '../constants/common';
import { setGlobalData } from '../globalData';
import { getDefaultWallets } from './getDefaultWallets';
-import { WALLET_CONNECT_ID, walletConnect } from '@/wallets';
+import { isWalletConnectConnector, walletConnect } from '@/wallets';
export interface DefaultConfigProps {
appName: string;
@@ -68,13 +68,11 @@ export const getDefaultConfig = (props: DefaultConfigProps) => {
} = props;
setGlobalData({
- walletConnectDefaultOptions: {
- walletConnectProjectId,
- appName,
- appIcon,
- appDescription,
- appUrl,
- },
+ appName,
+ walletConnectProjectId,
+ appIcon,
+ appDescription,
+ appUrl,
});
const providers: ChainProviderFn[] = [];
@@ -105,7 +103,7 @@ export const getDefaultConfig = (props: DefaultConfigProps) => {
const wallets = customizedWallets ?? getDefaultWallets();
const configuredConnectors = createConnectors(wallets, configuredChains);
- createGlobalWalletConnect(configuredConnectors);
+ createGlobalWalletConnect(configuredConnectors, configuredChains);
return {
autoConnect,
@@ -126,33 +124,18 @@ function createConnectors(wallets: WalletProps[], chains: Chain[]) {
return connectors;
}
-// !!!hack
-// If creating WalletConnect connector after wagmi initialization,
-// the speed of creating qr code and displaying WalletConnect modal will be very slow.
-function createGlobalWalletConnect(connectors: Connector[]) {
- const wc = connectors.find((c) => c.id === WALLET_CONNECT_ID);
-
- const { createConnector, ...restWalletProps } = wc?._wallet ?? walletConnect();
- const options = wc?.options;
-
- const qrCodeWalletConnectConnector = walletConnect({
- ...restWalletProps,
- connectorOptions: {
- ...options,
- showQrModal: false,
- },
- }).createConnector(wc?.chains ?? []);
-
- const modalWalletConnectConnector = walletConnect({
- ...restWalletProps,
- connectorOptions: {
- ...options,
- showQrModal: true,
- },
- }).createConnector(wc?.chains ?? []);
+// !!! notice
+// Try to keep only one walletConnect connector in a project
+// or multiple walletConnect connectors may lead some competition issues.
+function createGlobalWalletConnect(connectors: Connector[], chains: Chain[]) {
+ let wc = connectors.find((c) => isWalletConnectConnector(c));
+ if (!wc) {
+ // for hiding in the wallet list, there is no need to mount the `_wallet`
+ wc = walletConnect().createConnector(chains);
+ connectors.push(wc);
+ }
setGlobalData({
- qrCodeWalletConnectConnector,
- modalWalletConnectConnector,
+ walletConnectConnector: wc,
});
}
diff --git a/packages/walletkit/src/globalData/index.ts b/packages/walletkit/src/globalData/index.ts
index d6976c76..84b12cdc 100644
--- a/packages/walletkit/src/globalData/index.ts
+++ b/packages/walletkit/src/globalData/index.ts
@@ -1,21 +1,17 @@
import { Connector } from 'wagmi/connectors';
export interface GlobalDataType {
- qrCodeWalletConnectConnector?: Connector;
- modalWalletConnectConnector?: Connector;
- walletConnectDefaultOptions: {
- walletConnectProjectId?: string;
- appName: string;
- appIcon?: string;
- appDescription?: string;
- appUrl?: string;
- };
+ appName: string;
+ appIcon?: string;
+ appDescription?: string;
+ appUrl?: string;
+ walletConnectProjectId?: string;
+ walletConnectConnector?: Connector;
+ walletConnectModalIsOpen?: boolean;
}
let globalData: GlobalDataType = {
- walletConnectDefaultOptions: {
- appName: 'Connect Wallet',
- },
+ appName: 'Connect Wallet',
};
export const setGlobalData = (value: Partial) => {
diff --git a/packages/walletkit/src/hooks/useClickWallet.ts b/packages/walletkit/src/hooks/useClickWallet.ts
index fc0f9ec3..e70d2f74 100644
--- a/packages/walletkit/src/hooks/useClickWallet.ts
+++ b/packages/walletkit/src/hooks/useClickWallet.ts
@@ -21,8 +21,9 @@ export function useClickWallet() {
const pass = options.onClickWallet?.(connector, e);
if (pass === false) return;
- log('[click wallet] connector', connector);
- log('[click wallet] ethereum', window.ethereum);
+ log('[click wallet]', `connector:`, connector);
+ log('[click wallet]', `ethereum:`, window.ethereum);
+ log('[click wallet]', `installed:`, connector._wallet.isInstalled());
const gotoQRcodePage = () => {
setSelectedConnector(connector);
@@ -39,12 +40,12 @@ export function useClickWallet() {
clearTimeout(timerRef.current);
timerRef.current = setTimeout(() => {
if (isWalletConnectConnector(connector)) {
- if (connector.options.showQrModal) {
- onOpenWcModal();
- } else {
+ if (connector._wallet.showQRCode) {
gotoQRcodePage();
+ } else {
+ onOpenWcModal();
}
- } else if (!connector._wallet.installed) {
+ } else if (!connector._wallet.isInstalled()) {
if (mobile) {
const deepLink = connector._wallet.getDeepLink?.();
if (deepLink) {
diff --git a/packages/walletkit/src/hooks/useConnector.ts b/packages/walletkit/src/hooks/useConnector.ts
deleted file mode 100644
index d3a2c982..00000000
--- a/packages/walletkit/src/hooks/useConnector.ts
+++ /dev/null
@@ -1,6 +0,0 @@
-import { useConnect, Connector } from 'wagmi';
-
-export function useConnector(id: string) {
- const { connectors } = useConnect();
- return connectors.find((c) => c.id === id) as Connector | undefined;
-}
diff --git a/packages/walletkit/src/hooks/useQRCodeUri.ts b/packages/walletkit/src/hooks/useQRCodeUri.ts
index b7911b63..10c78a9c 100644
--- a/packages/walletkit/src/hooks/useQRCodeUri.ts
+++ b/packages/walletkit/src/hooks/useQRCodeUri.ts
@@ -4,7 +4,6 @@ import { commonErrorHandler } from '@/utils/common';
import { useState, useEffect } from 'react';
import { useAccount, useConnect } from 'wagmi';
-let lastWcUri: string;
let timer: any;
export function useQRCodeUri() {
@@ -15,29 +14,34 @@ export function useQRCodeUri() {
const [wcUri, setWcUri] = useState('');
useEffect(() => {
- const { qrCodeWalletConnectConnector: connector } = getGlobalData();
+ const connector = getGlobalData().walletConnectConnector;
if (isConnected || !connector) return;
const onUpdateWcUri = ({ type, data }: any) => {
- if (type === 'display_uri') {
- lastWcUri = data;
+ if (type === 'display_uri' && !getGlobalData().walletConnectModalIsOpen) {
setWcUri(data);
}
};
const connectWallet = async () => {
try {
+ log('[qrcode uri]', 'connecting');
+ const provider = await connector?.getProvider();
+ provider.rpc.showQrModal = false;
+
await connectAsync({ connector });
} catch (error: any) {
clearTimeout(timer);
timer = setTimeout(() => {
- commonErrorHandler({
- log,
- error,
- handler: options.onError,
- });
- connectWallet(); // refresh qr code
+ if (error?.code === 4001) {
+ commonErrorHandler({
+ log,
+ error,
+ handler: options.onError,
+ });
+ connectWallet(); // refresh qr code
+ }
}, 100);
}
};
diff --git a/packages/walletkit/src/hooks/useWalletConnectModal.ts b/packages/walletkit/src/hooks/useWalletConnectModal.ts
index 4a83237d..1470acb6 100644
--- a/packages/walletkit/src/hooks/useWalletConnectModal.ts
+++ b/packages/walletkit/src/hooks/useWalletConnectModal.ts
@@ -2,7 +2,7 @@ import { MODAL_AUTO_CLOSE_DELAY } from '@/constants/common';
import { useEffect, useState } from 'react';
import { useModal, useWalletKitContext } from '..';
import { useWalletKitConnect } from './useWalletKitConnect';
-import { getGlobalData } from '@/globalData';
+import { getGlobalData, setGlobalData } from '@/globalData';
export function useWalletConnectModal() {
const { connectAsync } = useWalletKitConnect();
@@ -21,17 +21,20 @@ export function useWalletConnectModal() {
clearTimeout(timer);
};
}
+
+ setGlobalData({
+ walletConnectModalIsOpen: isOpen,
+ });
}, [isOpen, onClose]);
return {
isOpenWcModal: isOpen,
onOpenWcModal: async () => {
- const w3mcss = document.createElement('style');
- w3mcss.innerHTML = `#walletconnect-wrapper{z-index:2147483647;}`;
- document.head.appendChild(w3mcss);
document.body.style.setProperty('--wcm-z-index', '2147483647');
- const { modalWalletConnectConnector: connector } = getGlobalData();
+ const connector = getGlobalData().walletConnectConnector;
+ const provider = await connector?.getProvider();
+ provider.rpc.showQrModal = true;
if (connector) {
setIsOpen(true);
@@ -39,11 +42,10 @@ export function useWalletConnectModal() {
try {
await connectAsync({ connector });
} catch (err) {
- log('WalletConnect', err);
+ log('[open walletconnect modal]', err);
}
setIsOpen(false);
- document.head.removeChild(w3mcss);
}
},
};
diff --git a/packages/walletkit/src/hooks/useWalletKitConnect.ts b/packages/walletkit/src/hooks/useWalletKitConnect.ts
index 5cc84509..d74583cd 100644
--- a/packages/walletkit/src/hooks/useWalletKitConnect.ts
+++ b/packages/walletkit/src/hooks/useWalletKitConnect.ts
@@ -2,7 +2,9 @@ import { commonErrorHandler } from '@/utils/common';
import { useConnect } from 'wagmi';
import { useWalletKitContext } from '..';
-export function useWalletKitConnect({ ...props }: any = {}): ReturnType {
+export type UseWalletKitConnectProps = Parameters[0];
+
+export function useWalletKitConnect(props?: UseWalletKitConnectProps) {
const { log, options } = useWalletKitContext();
const connectProps = {
@@ -11,13 +13,13 @@ export function useWalletKitConnect({ ...props }: any = {}): ReturnType {
+export type UseWalletKitSwitchNetworkProps = Parameters[0];
+
+export function useWalletKitSwitchNetwork(props?: UseWalletKitSwitchNetworkProps) {
const { log, options } = useWalletKitContext();
const result = useSwitchNetwork({
...props,
- onError(error: any) {
+ onError(error: Error, ...params) {
commonErrorHandler({
log,
handler: options.onError,
error,
});
- props?.onError?.(error);
+ props?.onError?.(error, ...params);
},
});
diff --git a/packages/walletkit/src/index.ts b/packages/walletkit/src/index.ts
index 0d830aa9..5b118be9 100644
--- a/packages/walletkit/src/index.ts
+++ b/packages/walletkit/src/index.ts
@@ -6,6 +6,7 @@ export * from './components/WalletKitButton';
export * from './components/WalletKitProvider';
export * from './components/WalletKitProvider/context';
export * from './components/SwitchNetworkModal';
+export * from './components/EthereumScript';
export { useModal } from './components/ModalProvider/context';
export { type ThemeMode, type ThemeVariant } from './components/ThemeProvider';
diff --git a/packages/walletkit/src/pages/ConnectWithQRCode/index.tsx b/packages/walletkit/src/pages/ConnectWithQRCode/index.tsx
index 4e2fac5c..1182de1f 100644
--- a/packages/walletkit/src/pages/ConnectWithQRCode/index.tsx
+++ b/packages/walletkit/src/pages/ConnectWithQRCode/index.tsx
@@ -12,7 +12,6 @@ import { useWalletKitContext, cx } from '@/index';
import { clsContainer, clsOfficialButton } from './styles.css';
import { isWalletConnectConnector } from '@/wallets';
import { useQRCodeUri } from '@/hooks/useQRCodeUri';
-import { useEffect, useRef } from 'react';
export function ConnectWithQRCodePage() {
const { selectedConnector, options } = useWalletKitContext();
@@ -25,11 +24,6 @@ export function ConnectWithQRCodePage() {
const isWalletConnect = isWalletConnectConnector(selectedConnector);
const qrCodeUri = wcUri && (wallet.getQRCodeUri?.(wcUri) ?? wcUri);
- const startRef = useRef(wcUri ? 0 : Date.now());
- useEffect(() => {
- console.log(Date.now() - startRef.current, '==');
- }, [wcUri]);
-
return (
<>
diff --git a/packages/walletkit/src/pages/Connecting/index.tsx b/packages/walletkit/src/pages/Connecting/index.tsx
index 4e88342e..e5ab361c 100644
--- a/packages/walletkit/src/pages/Connecting/index.tsx
+++ b/packages/walletkit/src/pages/Connecting/index.tsx
@@ -8,7 +8,7 @@ import { useWalletConfig } from '@/hooks/useWalletConfig';
import { useWalletDownloadUrl } from '@/hooks/useWalletDownloadUrl';
import { useWalletKitConnect } from '@/hooks/useWalletKitConnect';
import { useWalletLogos } from '@/hooks/useWalletLogos';
-import { useWalletKitContext } from '@/index';
+import { cx, useWalletKitContext } from '@/index';
import { useState, useCallback, useEffect } from 'react';
import { ConnectSpinner } from './ConnectSpinner';
import { Content } from './Content';
@@ -28,13 +28,15 @@ export const states = {
};
export function ConnectingPage() {
- const { selectedConnector, options, connectRole, log } = useWalletKitContext();
+ const { selectedConnector, options, action, log } = useWalletKitContext();
const wallet = useWalletConfig(selectedConnector);
const logos = useWalletLogos(wallet.logos);
const downloadUrl = useWalletDownloadUrl(wallet.downloadUrls);
- const [status, setStatus] = useState(!wallet.installed ? states.UNAVAILABLE : states.CONNECTING);
+ const [status, setStatus] = useState(
+ wallet.isInstalled() ? states.CONNECTING : states.UNAVAILABLE,
+ );
const { connect } = useWalletKitConnect({
onMutate: (connector?: any) => {
@@ -76,7 +78,7 @@ export function ConnectingPage() {
if (
options.initialChainId &&
data.chain.id === options.initialChainId &&
- connectRole === 'add-network'
+ action === 'add-network'
) {
options.onChainAlreadyAdded?.(selectedConnector, options.initialChainId);
}
@@ -85,14 +87,14 @@ export function ConnectingPage() {
});
const runConnect = useCallback(() => {
- if (!wallet.installed) return;
+ if (!wallet.isInstalled()) return;
if (selectedConnector) {
connect({ connector: selectedConnector });
} else {
setStatus(states.UNAVAILABLE);
}
- }, [connect, selectedConnector, wallet.installed]);
+ }, [connect, selectedConnector, wallet]);
useEffect(() => {
if (status === states.UNAVAILABLE) return;
@@ -104,7 +106,7 @@ export function ConnectingPage() {
// eslint-disable-next-line react-hooks/exhaustive-deps
}, []);
- log('[Connect]', status, selectedConnector?.name);
+ log('[connecting page]', `name: ${selectedConnector?.name}, status: ${status}`);
const isError = [states.FAILED, states.NOTCONNECTED, states.REJECTED].includes(status);
const isLoading = status === states.CONNECTING;
@@ -167,7 +169,7 @@ export function ConnectingPage() {
{(status === states.FAILED || status === states.REJECTED) && (
-
+
Try Again
@@ -175,7 +177,13 @@ export function ConnectingPage() {
{status === states.UNAVAILABLE && (
-
+
Install the Extension
diff --git a/packages/walletkit/src/pages/Connectors/GridLayout/index.tsx b/packages/walletkit/src/pages/Connectors/GridLayout/index.tsx
index b6ff3ca9..bf0cd7cf 100644
--- a/packages/walletkit/src/pages/Connectors/GridLayout/index.tsx
+++ b/packages/walletkit/src/pages/Connectors/GridLayout/index.tsx
@@ -2,13 +2,17 @@ import { ModalBody } from '@/base/components/Modal/ModalBody';
import { ModalFooter } from '@/base/components/Modal/ModalFooter';
import { WalletIcon } from '@/base/icons/WalletIcon';
import { useWalletKitContext, cx } from '@/index';
-import { useConnect } from 'wagmi';
+import { Connector } from 'wagmi';
import { clsNoWalletButton, clsWallets } from './styles.css';
import { WalletOption } from './WalletOption';
import { Button } from '@/base/components/Button';
-export function GridLayout() {
- const { connectors } = useConnect();
+export interface GridLayoutProps {
+ connectors: Connector[];
+}
+
+export function GridLayout(props: GridLayoutProps) {
+ const { connectors } = props;
const { options } = useWalletKitContext();
return (
diff --git a/packages/walletkit/src/pages/Connectors/GridLayout/styles.css.ts b/packages/walletkit/src/pages/Connectors/GridLayout/styles.css.ts
index 5d5d5684..3a428a9d 100644
--- a/packages/walletkit/src/pages/Connectors/GridLayout/styles.css.ts
+++ b/packages/walletkit/src/pages/Connectors/GridLayout/styles.css.ts
@@ -21,10 +21,10 @@ export const clsNoWalletButton = style({
borderRadius: cssVar('noWalletButton', 'radii'),
background: cssVar('noWalletButtonBackground'),
borderColor: cssVar('noWalletButtonBorder'),
- color: cssVar('noWalletButtonBackgroundText'),
+ color: cssVar('noWalletButtonText'),
'@media': hover({
background: cssVar('noWalletButtonBackgroundHover'),
- color: cssVar('noWalletButtonBackgroundTextHover'),
+ color: cssVar('noWalletButtonTextHover'),
borderColor: cssVar('noWalletButtonBorderHover'),
}),
});
diff --git a/packages/walletkit/src/pages/Connectors/ListLayout/index.tsx b/packages/walletkit/src/pages/Connectors/ListLayout/index.tsx
index f7c11db0..4046aebf 100644
--- a/packages/walletkit/src/pages/Connectors/ListLayout/index.tsx
+++ b/packages/walletkit/src/pages/Connectors/ListLayout/index.tsx
@@ -3,13 +3,17 @@ import { ModalBody } from '@/base/components/Modal/ModalBody';
import { ModalFooter } from '@/base/components/Modal/ModalFooter';
import { WalletIcon } from '@/base/icons/WalletIcon';
import { useWalletKitContext, cx } from '@/index';
-import { useConnect } from 'wagmi';
import { WalletOption } from './WalletOption';
import { clsWallets, clsNoWalletLink } from './styles.css';
+import { Connector } from 'wagmi/connectors';
-export function ListLayout() {
- const { connectors } = useConnect();
+export interface ListLayoutProps {
+ connectors: Connector[];
+}
+
+export function ListLayout(props: ListLayoutProps) {
+ const { connectors } = props;
const { options } = useWalletKitContext();
return (
diff --git a/packages/walletkit/src/pages/Connectors/index.tsx b/packages/walletkit/src/pages/Connectors/index.tsx
index e6b3a74a..81eac6c4 100644
--- a/packages/walletkit/src/pages/Connectors/index.tsx
+++ b/packages/walletkit/src/pages/Connectors/index.tsx
@@ -14,7 +14,8 @@ export function ConnectorsPage() {
const { options } = useWalletKitContext();
const { isMobileLayout } = useResponsive();
- const useGridLayout = connectors.length > LIST_LAYOUT_THRESHOLD || isMobileLayout;
+ const visibleConnectors = connectors.filter((c) => !!c._wallet);
+ const useGridLayout = visibleConnectors.length > LIST_LAYOUT_THRESHOLD || isMobileLayout;
return (
<>
@@ -25,7 +26,11 @@ export function ConnectorsPage() {
{options.disclaimer}
)}
- {useGridLayout ? : }
+ {useGridLayout ? (
+
+ ) : (
+
+ )}
>
);
}
diff --git a/packages/walletkit/src/pages/SwitchNetwork/index.tsx b/packages/walletkit/src/pages/SwitchNetwork/index.tsx
index 2d25d362..3d0ad419 100644
--- a/packages/walletkit/src/pages/SwitchNetwork/index.tsx
+++ b/packages/walletkit/src/pages/SwitchNetwork/index.tsx
@@ -18,12 +18,14 @@ import {
import { ModalFooter } from '@/base/components/Modal/ModalFooter';
export function SwitchNetworkPage() {
- const { supportedChains } = useWalletKitContext();
+ const { supportedChains, log } = useWalletKitContext();
const { isLoading, switchNetwork, pendingChainId } = useWalletKitSwitchNetwork();
const { chain } = useNetwork();
const { isClosable } = useModal();
const onSwitchNetwork = (chainId: number) => {
+ log('[switch network page]', 'switchNetwork:', switchNetwork, ', isLoading:', isLoading);
+
if (switchNetwork && !isLoading) {
switchNetwork(chainId);
}
@@ -54,7 +56,7 @@ export function SwitchNetworkPage() {
);
})}
- or
+ or
diff --git a/packages/walletkit/src/themes/base.ts b/packages/walletkit/src/themes/base.ts
index 677b1544..9f13eaeb 100644
--- a/packages/walletkit/src/themes/base.ts
+++ b/packages/walletkit/src/themes/base.ts
@@ -69,8 +69,8 @@ export const base = {
qrCodeDot: 'var(--wk-colors-text)',
qrCodeBorder: 'var(--wk-colors-border)',
- noWalletButtonBackgroundText: 'var(--wk-colors-text)',
- noWalletButtonBackgroundTextHover: 'var(--wk-colors-text)',
+ noWalletButtonText: 'var(--wk-colors-text)',
+ noWalletButtonTextHover: 'var(--wk-colors-text)',
noWalletButtonBackground: 'transparent',
noWalletButtonBackgroundHover: 'var(--wk-colors-border)',
noWalletButtonBorder: 'var(--wk-colors-border)',
@@ -136,8 +136,8 @@ export const base = {
qrCodeDot: 'var(--wk-colors-text)',
qrCodeBorder: 'var(--wk-colors-border)',
- noWalletButtonBackgroundText: 'var(--wk-colors-text)',
- noWalletButtonBackgroundTextHover: 'var(--wk-colors-text)',
+ noWalletButtonText: 'var(--wk-colors-text)',
+ noWalletButtonTextHover: 'var(--wk-colors-text)',
noWalletButtonBackground: 'transparent',
noWalletButtonBackgroundHover: 'var(--wk-colors-border)',
noWalletButtonBorder: 'var(--wk-colors-border)',
diff --git a/packages/walletkit/src/typings.d.ts b/packages/walletkit/src/typings.d.ts
index 79e81685..f39334c8 100644
--- a/packages/walletkit/src/typings.d.ts
+++ b/packages/walletkit/src/typings.d.ts
@@ -1,5 +1,4 @@
import { Connector as WagmiConnector } from 'wagmi';
-import type { WindowProvider } from 'wagmi/window';
import { WalletProps } from './wallets/types';
diff --git a/packages/walletkit/src/utils/common.ts b/packages/walletkit/src/utils/common.ts
index 18541857..420d4acc 100644
--- a/packages/walletkit/src/utils/common.ts
+++ b/packages/walletkit/src/utils/common.ts
@@ -47,3 +47,11 @@ export function commonErrorHandler(props: { log: any; handler: any; error: any }
handler?.(error, description);
}
}
+
+export async function sleep(duration = 1000) {
+ return new Promise((resolve) => {
+ setTimeout(() => {
+ resolve(null);
+ }, duration);
+ });
+}
diff --git a/packages/walletkit/src/wallets/binanceWeb3Wallet/index.tsx b/packages/walletkit/src/wallets/binanceWeb3Wallet/index.tsx
index 2dcaf977..35a65094 100644
--- a/packages/walletkit/src/wallets/binanceWeb3Wallet/index.tsx
+++ b/packages/walletkit/src/wallets/binanceWeb3Wallet/index.tsx
@@ -21,7 +21,7 @@ export function binanceWeb3Wallet(props: PartialCustomProps = {}): WalletProps {
},
spinnerColor: undefined,
showQRCode: true,
- installed: isBinanceWeb3Wallet(),
+ isInstalled: isBinanceWeb3Wallet,
createConnector: (chains: Chain[]) => {
return new CustomConnector({
id: BINANCE_WEB3_WALLET_ID,
@@ -53,9 +53,5 @@ export function binanceWeb3Wallet(props: PartialCustomProps = {}): WalletProps {
export function isBinanceWeb3Wallet() {
if (typeof window === 'undefined') return false;
- if (isMobile()) {
- return !!window.ethereum;
- }
-
return false;
}
diff --git a/packages/walletkit/src/wallets/coinbaseWallet/icon.tsx b/packages/walletkit/src/wallets/coinbaseWallet/icon.tsx
index 513d4b51..62c443a2 100644
--- a/packages/walletkit/src/wallets/coinbaseWallet/icon.tsx
+++ b/packages/walletkit/src/wallets/coinbaseWallet/icon.tsx
@@ -19,9 +19,20 @@ export const CoinbaseWalletIcon = (props: SVGIconProps) => {
d="M0 18.1333C0 8.11857 8.11857 0 18.1333 0H49.8667C59.8814 0 68 8.11857 68 18.1333V49.8667C68 59.8814 59.8814 68 49.8667 68H18.1333C8.11857 68 0 59.8814 0 49.8667V18.1333Z"
fill="#0051FE"
/>
-
+
-
+
{
- const { walletConnectDefaultOptions } = getGlobalData();
- const { appName } = walletConnectDefaultOptions;
+ const { appName } = getGlobalData();
return new CoinbaseWalletConnector({
chains,
@@ -57,5 +56,5 @@ export function coinbaseWallet(props: CoinbaseWalletProps = {}): WalletProps {
export function isCoinbaseWallet() {
if (typeof window === 'undefined') return false;
- return hasInjectedProvider('isCoinbaseWallet');
+ return hasInjectedProvider('isCoinbaseWallet') || !!window.coinbaseWalletExtension;
}
diff --git a/packages/walletkit/src/wallets/injected/index.tsx b/packages/walletkit/src/wallets/injected/index.tsx
index 846c70e0..419f906e 100644
--- a/packages/walletkit/src/wallets/injected/index.tsx
+++ b/packages/walletkit/src/wallets/injected/index.tsx
@@ -26,7 +26,7 @@ export function injected(props: InjectedProps = {}): WalletProps {
default: undefined,
},
showQRCode: false,
- installed: isInjected(),
+ isInstalled: isInjected,
createConnector: (chains: Chain[]) => {
return new InjectedConnector({
chains,
diff --git a/packages/walletkit/src/wallets/mathWallet/index.tsx b/packages/walletkit/src/wallets/mathWallet/index.tsx
index 3fbbdcf3..65d796d1 100644
--- a/packages/walletkit/src/wallets/mathWallet/index.tsx
+++ b/packages/walletkit/src/wallets/mathWallet/index.tsx
@@ -21,7 +21,7 @@ export function mathWallet(props: PartialCustomProps = {}): WalletProps {
},
showQRCode: false,
spinnerColor: undefined,
- installed: isMathWallet(),
+ isInstalled: isMathWallet,
createConnector: (chains: Chain[]) => {
return new CustomConnector({
id: MATH_WALLET_ID,
diff --git a/packages/walletkit/src/wallets/metaMask/icon.tsx b/packages/walletkit/src/wallets/metaMask/icon.tsx
index 5d6327d9..9487e113 100644
--- a/packages/walletkit/src/wallets/metaMask/icon.tsx
+++ b/packages/walletkit/src/wallets/metaMask/icon.tsx
@@ -134,10 +134,21 @@ export function MetaMaskIcon(props: SVGIconProps) {
>
-
+
-
+
{
return new MetaMaskConnector({
chains,
options: {
shimDisconnect: true,
UNSTABLE_shimOnConnectSelectAccount: false,
+ getProvider() {
+ return getInjectedProvider('isMetaMask');
+ },
...connectorOptions,
- },
+ } as any,
});
},
getDeepLink: () => {
@@ -51,11 +55,7 @@ export function metaMask(props: MetaMaskProps = {}): WalletProps {
}
export function isMetaMask() {
- if (typeof window === 'undefined') return false;
-
- if (isTokenPocket()) return false;
-
- return window?.ethereum?.isMetaMask;
+ return hasInjectedProvider('isMetaMask');
}
export function isMetaMaskConnector(connector?: Connector) {
diff --git a/packages/walletkit/src/wallets/okxWallet/index.tsx b/packages/walletkit/src/wallets/okxWallet/index.tsx
index 2b2edb14..05cc6297 100644
--- a/packages/walletkit/src/wallets/okxWallet/index.tsx
+++ b/packages/walletkit/src/wallets/okxWallet/index.tsx
@@ -22,7 +22,7 @@ export function okxWallet(props: PartialCustomProps = {}): WalletProps {
},
spinnerColor: undefined,
showQRCode: false,
- installed: isOkxWallet(),
+ isInstalled: isOkxWallet,
createConnector: (chains: Chain[]) => {
return new CustomConnector({
id: OKX_WALLET_ID,
@@ -60,5 +60,5 @@ export function isOkxWallet() {
return !!(window.ethereum || window.okexchain);
}
- return !!(hasInjectedProvider('isOkxWallet') || window.okexchain?.isOkxWallet);
+ return hasInjectedProvider('isOkxWallet') || window.okexchain?.isOkxWallet;
}
diff --git a/packages/walletkit/src/wallets/safe/index.tsx b/packages/walletkit/src/wallets/safe/index.tsx
index 46ec2c27..a6b54379 100644
--- a/packages/walletkit/src/wallets/safe/index.tsx
+++ b/packages/walletkit/src/wallets/safe/index.tsx
@@ -28,7 +28,7 @@ export function safe(props: SafeProps = {}): WalletProps {
default: undefined,
},
showQRCode: false,
- installed: isSafe(),
+ isInstalled: isSafe,
createConnector: (chains: Chain[]) => {
return new SafeConnector({
chains,
diff --git a/packages/walletkit/src/wallets/tokenPocket/icon.tsx b/packages/walletkit/src/wallets/tokenPocket/icon.tsx
index 6ec4a6b9..c2eb302c 100644
--- a/packages/walletkit/src/wallets/tokenPocket/icon.tsx
+++ b/packages/walletkit/src/wallets/tokenPocket/icon.tsx
@@ -74,7 +74,7 @@ export const TokenPocketIcon = (props: SVGIconProps) => {
-
+
{
return new CustomConnector({
id: TOKEN_POCKET_ID,
@@ -32,7 +32,11 @@ export function tokenPocket(props: PartialCustomProps = {}): WalletProps {
getProvider() {
if (typeof window === 'undefined') return;
- const provider = getInjectedProvider('isTokenPocket') ?? window.tokenpocket;
+ const provider =
+ getInjectedProvider('isTokenPocket') ??
+ window.tokenpocket?.ethereum ??
+ window.tokenpocket;
+
return provider;
},
...connectorOptions,
@@ -55,5 +59,5 @@ export function tokenPocket(props: PartialCustomProps = {}): WalletProps {
export function isTokenPocket() {
if (typeof window === 'undefined') return false;
- return !!(hasInjectedProvider('isTokenPocket') || window.tokenpocket);
+ return hasInjectedProvider('isTokenPocket') || window.tokenpocket?.ethereum || window.tokenpocket;
}
diff --git a/packages/walletkit/src/wallets/trustWallet/connector.ts b/packages/walletkit/src/wallets/trustWallet/connector.ts
index 902d4599..daa59e25 100644
--- a/packages/walletkit/src/wallets/trustWallet/connector.ts
+++ b/packages/walletkit/src/wallets/trustWallet/connector.ts
@@ -2,6 +2,7 @@ import { Chain } from 'wagmi';
import { MetaMaskConnector } from 'wagmi/connectors/metaMask';
import { TRUST_WALLET_ID } from '.';
import { getInjectedProvider } from '../utils';
+import { sleep } from '@/utils/common';
export type TrustWalletConnectorOptions = {
shimDisconnect?: boolean;
@@ -30,6 +31,13 @@ export class TrustWalletConnector extends MetaMaskConnector {
options,
});
}
+
+ public async getProvider() {
+ if (typeof window !== 'undefined' && !window.trustwallet?.request) {
+ await sleep();
+ }
+ return this.options.getProvider();
+ }
}
function getProvider() {
diff --git a/packages/walletkit/src/wallets/trustWallet/index.tsx b/packages/walletkit/src/wallets/trustWallet/index.tsx
index 3d183ba9..ac23907c 100644
--- a/packages/walletkit/src/wallets/trustWallet/index.tsx
+++ b/packages/walletkit/src/wallets/trustWallet/index.tsx
@@ -40,7 +40,7 @@ export function trustWallet(props: TrustWalletProps = {}): WalletProps {
},
spinnerColor: '#1098FC',
showQRCode: false,
- installed: isTrustWallet(),
+ isInstalled: isTrustWallet,
createConnector: (chains: Chain[]) => {
return new TrustWalletConnector({
chains,
@@ -66,9 +66,7 @@ export function trustWallet(props: TrustWalletProps = {}): WalletProps {
export function isTrustWallet() {
if (typeof window === 'undefined') return false;
- return !!(
- hasInjectedProvider('isTrust') ||
- window?.trustwallet?.isTrust ||
- window?.trustWallet?.isTrust
+ return (
+ hasInjectedProvider('isTrust') || window?.trustwallet?.isTrust || window?.trustWallet?.isTrust
);
}
diff --git a/packages/walletkit/src/wallets/types.ts b/packages/walletkit/src/wallets/types.ts
index 139435aa..d41a6e9b 100644
--- a/packages/walletkit/src/wallets/types.ts
+++ b/packages/walletkit/src/wallets/types.ts
@@ -14,7 +14,7 @@ export interface WalletProps {
};
spinnerColor?: string;
showQRCode?: boolean;
- installed: boolean | undefined;
+ isInstalled: () => boolean | undefined;
createConnector: (chains: Chain[]) => Connector;
getDeepLink: () => string | undefined;
getQRCodeUri?: (uri: string) => string;
diff --git a/packages/walletkit/src/wallets/walletConnect/index.tsx b/packages/walletkit/src/wallets/walletConnect/index.tsx
index ea32b810..881126ba 100644
--- a/packages/walletkit/src/wallets/walletConnect/index.tsx
+++ b/packages/walletkit/src/wallets/walletConnect/index.tsx
@@ -28,11 +28,10 @@ export function walletConnect(props: WalletConnectProps = {}): WalletProps {
downloadUrls: {
default: undefined,
},
- installed: undefined,
+ showQRCode: isMobile() ? false : !connectorOptions?.showQrModal,
+ isInstalled: () => false,
createConnector: (chains: Chain[]) => {
- const { walletConnectDefaultOptions } = getGlobalData();
- const { walletConnectProjectId, appName, appIcon, appDescription, appUrl } =
- walletConnectDefaultOptions;
+ const { walletConnectProjectId, appName, appIcon, appDescription, appUrl } = getGlobalData();
const hasAllAppData = appName && appIcon && appDescription && appUrl;
@@ -44,8 +43,7 @@ export function walletConnect(props: WalletConnectProps = {}): WalletProps {
chains,
options: {
// https://github.com/WalletConnect/walletconnect-monorepo/issues/2830
- relayUrl: 'wss://relay.walletconnect.org',
- showQrModal: isMobile() ? true : false,
+ // relayUrl: 'wss://relay.walletconnect.org',
projectId: walletConnectProjectId,
metadata: hasAllAppData
? {
@@ -63,6 +61,7 @@ export function walletConnect(props: WalletConnectProps = {}): WalletProps {
],
},
...connectorOptions,
+ showQrModal: true,
},
});
},
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 57ac11ba..4606b13b 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -9,8 +9,8 @@ importers:
.:
devDependencies:
'@changesets/cli':
- specifier: ^2.26.2
- version: 2.26.2
+ specifier: ^2.27.1
+ version: 2.27.1
'@commitlint/cli':
specifier: ^18.4.3
version: 18.4.3(typescript@5.3.2)
@@ -57,18 +57,18 @@ importers:
specifier: ^18.2.0
version: 18.2.0(react@18.2.0)
viem:
- specifier: ^1.19.8
- version: 1.19.8(typescript@5.3.2)
+ specifier: ^1.19.9
+ version: 1.19.9(typescript@5.3.2)
wagmi:
specifier: ^1.4.7
- version: 1.4.7(@types/react@18.2.38)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.2)(viem@1.19.8)
+ version: 1.4.7(@types/react@18.2.39)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.2)(viem@1.19.9)
devDependencies:
'@types/node':
specifier: ^20.10.0
version: 20.10.0
'@types/react':
- specifier: ^18.2.38
- version: 18.2.38
+ specifier: ^18.2.39
+ version: 18.2.39
'@types/react-dom':
specifier: ^18.2.17
version: 18.2.17
@@ -88,15 +88,15 @@ importers:
specifier: ^18.2.0
version: 18.2.0(react@18.2.0)
viem:
- specifier: ^1.19.8
- version: 1.19.8(typescript@5.3.2)
+ specifier: ^1.19.9
+ version: 1.19.9(typescript@5.3.2)
wagmi:
specifier: ^1.4.7
- version: 1.4.7(@types/react@18.2.38)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.2)(viem@1.19.8)
+ version: 1.4.7(@types/react@18.2.39)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.2)(viem@1.19.9)
devDependencies:
'@types/react':
- specifier: ^18.2.38
- version: 18.2.38
+ specifier: ^18.2.39
+ version: 18.2.39
'@types/react-dom':
specifier: ^18.2.17
version: 18.2.17
@@ -121,13 +121,13 @@ importers:
devDependencies:
'@rollup/plugin-node-resolve':
specifier: ^15.2.3
- version: 15.2.3(rollup@4.5.2)
+ version: 15.2.3(rollup@4.6.0)
'@types/qrcode':
specifier: ^1.5.5
version: 1.5.5
'@types/react':
- specifier: ^18.2.38
- version: 18.2.38
+ specifier: ^18.2.39
+ version: 18.2.39
'@types/react-dom':
specifier: ^18.2.17
version: 18.2.17
@@ -148,31 +148,34 @@ importers:
version: 18.2.0(react@18.2.0)
rollup-plugin-peer-deps-external:
specifier: ^2.2.4
- version: 2.2.4(rollup@4.5.2)
+ version: 2.2.4(rollup@4.6.0)
typescript:
specifier: ^5.3.2
version: 5.3.2
+ vconsole:
+ specifier: ^3.15.1
+ version: 3.15.1
viem:
- specifier: ^1.19.8
- version: 1.19.8(typescript@5.3.2)
+ specifier: ^1.19.9
+ version: 1.19.9(typescript@5.3.2)
vite:
specifier: ^4.5.0
version: 4.5.0(@types/node@18.18.13)
vite-plugin-dts:
specifier: ^3.6.3
- version: 3.6.3(@types/node@18.18.13)(rollup@4.5.2)(typescript@5.3.2)(vite@4.5.0)
+ version: 3.6.3(@types/node@18.18.13)(rollup@4.6.0)(typescript@5.3.2)(vite@4.5.0)
wagmi:
specifier: ^1.4.7
- version: 1.4.7(@types/react@18.2.38)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.2)(viem@1.19.8)
+ version: 1.4.7(@types/react@18.2.39)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.2)(viem@1.19.9)
website:
dependencies:
'@emotion/react':
specifier: ^11.11.1
- version: 11.11.1(@types/react@18.2.38)(react@18.2.0)
+ version: 11.11.1(@types/react@18.2.39)(react@18.2.0)
'@emotion/styled':
specifier: ^11.11.0
- version: 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.38)(react@18.2.0)
+ version: 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.39)(react@18.2.0)
'@mdx-js/mdx':
specifier: ~2.1.5
version: 2.1.5
@@ -213,15 +216,15 @@ importers:
specifier: ^3.15.1
version: 3.15.1
viem:
- specifier: ^1.19.8
- version: 1.19.8(typescript@5.3.2)
+ specifier: ^1.19.9
+ version: 1.19.9(typescript@5.3.2)
wagmi:
specifier: ^1.4.7
- version: 1.4.7(@types/react@18.2.38)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.2)(viem@1.19.8)
+ version: 1.4.7(@types/react@18.2.39)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.2)(viem@1.19.9)
devDependencies:
'@mdx-js/rollup':
specifier: ~2.2.1
- version: 2.2.1(rollup@4.5.2)
+ version: 2.2.1(rollup@4.6.0)
'@types/mdx':
specifier: ~2.0.10
version: 2.0.10
@@ -229,8 +232,8 @@ importers:
specifier: ~18.6.5
version: 18.6.5
'@types/react':
- specifier: ^18.2.38
- version: 18.2.38
+ specifier: ^18.2.39
+ version: 18.2.39
'@types/react-dom':
specifier: ^18.2.17
version: 18.2.17
@@ -533,14 +536,14 @@ packages:
to-fast-properties: 2.0.0
dev: true
- /@changesets/apply-release-plan@6.1.4:
- resolution: {integrity: sha512-FMpKF1fRlJyCZVYHr3CbinpZZ+6MwvOtWUuO8uo+svcATEoc1zRDcj23pAurJ2TZ/uVz1wFHH6K3NlACy0PLew==}
+ /@changesets/apply-release-plan@7.0.0:
+ resolution: {integrity: sha512-vfi69JR416qC9hWmFGSxj7N6wA5J222XNBmezSVATPWDVPIF7gkd4d8CpbEbXmRWbVrkoli3oerGS6dcL/BGsQ==}
dependencies:
'@babel/runtime': 7.23.4
- '@changesets/config': 2.3.1
- '@changesets/get-version-range-type': 0.3.2
- '@changesets/git': 2.0.0
- '@changesets/types': 5.2.1
+ '@changesets/config': 3.0.0
+ '@changesets/get-version-range-type': 0.4.0
+ '@changesets/git': 3.0.0
+ '@changesets/types': 6.0.0
'@manypkg/get-packages': 1.1.3
detect-indent: 6.1.0
fs-extra: 7.0.1
@@ -551,51 +554,50 @@ packages:
semver: 7.5.4
dev: true
- /@changesets/assemble-release-plan@5.2.4:
- resolution: {integrity: sha512-xJkWX+1/CUaOUWTguXEbCDTyWJFECEhmdtbkjhn5GVBGxdP/JwaHBIU9sW3FR6gD07UwZ7ovpiPclQZs+j+mvg==}
+ /@changesets/assemble-release-plan@6.0.0:
+ resolution: {integrity: sha512-4QG7NuisAjisbW4hkLCmGW2lRYdPrKzro+fCtZaILX+3zdUELSvYjpL4GTv0E4aM9Mef3PuIQp89VmHJ4y2bfw==}
dependencies:
'@babel/runtime': 7.23.4
- '@changesets/errors': 0.1.4
- '@changesets/get-dependents-graph': 1.3.6
- '@changesets/types': 5.2.1
+ '@changesets/errors': 0.2.0
+ '@changesets/get-dependents-graph': 2.0.0
+ '@changesets/types': 6.0.0
'@manypkg/get-packages': 1.1.3
semver: 7.5.4
dev: true
- /@changesets/changelog-git@0.1.14:
- resolution: {integrity: sha512-+vRfnKtXVWsDDxGctOfzJsPhaCdXRYoe+KyWYoq5X/GqoISREiat0l3L8B0a453B2B4dfHGcZaGyowHbp9BSaA==}
+ /@changesets/changelog-git@0.2.0:
+ resolution: {integrity: sha512-bHOx97iFI4OClIT35Lok3sJAwM31VbUM++gnMBV16fdbtBhgYu4dxsphBF/0AZZsyAHMrnM0yFcj5gZM1py6uQ==}
dependencies:
- '@changesets/types': 5.2.1
+ '@changesets/types': 6.0.0
dev: true
- /@changesets/cli@2.26.2:
- resolution: {integrity: sha512-dnWrJTmRR8bCHikJHl9b9HW3gXACCehz4OasrXpMp7sx97ECuBGGNjJhjPhdZNCvMy9mn4BWdplI323IbqsRig==}
+ /@changesets/cli@2.27.1:
+ resolution: {integrity: sha512-iJ91xlvRnnrJnELTp4eJJEOPjgpF3NOh4qeQehM6Ugiz9gJPRZ2t+TsXun6E3AMN4hScZKjqVXl0TX+C7AB3ZQ==}
hasBin: true
dependencies:
'@babel/runtime': 7.23.4
- '@changesets/apply-release-plan': 6.1.4
- '@changesets/assemble-release-plan': 5.2.4
- '@changesets/changelog-git': 0.1.14
- '@changesets/config': 2.3.1
- '@changesets/errors': 0.1.4
- '@changesets/get-dependents-graph': 1.3.6
- '@changesets/get-release-plan': 3.0.17
- '@changesets/git': 2.0.0
- '@changesets/logger': 0.0.5
- '@changesets/pre': 1.0.14
- '@changesets/read': 0.5.9
- '@changesets/types': 5.2.1
- '@changesets/write': 0.2.3
+ '@changesets/apply-release-plan': 7.0.0
+ '@changesets/assemble-release-plan': 6.0.0
+ '@changesets/changelog-git': 0.2.0
+ '@changesets/config': 3.0.0
+ '@changesets/errors': 0.2.0
+ '@changesets/get-dependents-graph': 2.0.0
+ '@changesets/get-release-plan': 4.0.0
+ '@changesets/git': 3.0.0
+ '@changesets/logger': 0.1.0
+ '@changesets/pre': 2.0.0
+ '@changesets/read': 0.6.0
+ '@changesets/types': 6.0.0
+ '@changesets/write': 0.3.0
'@manypkg/get-packages': 1.1.3
- '@types/is-ci': 3.0.4
'@types/semver': 7.5.6
ansi-colors: 4.1.3
chalk: 2.4.2
+ ci-info: 3.9.0
enquirer: 2.4.1
external-editor: 3.1.0
fs-extra: 7.0.1
human-id: 1.0.2
- is-ci: 3.0.1
meow: 6.1.1
outdent: 0.5.0
p-limit: 2.3.0
@@ -607,93 +609,93 @@ packages:
tty-table: 4.2.3
dev: true
- /@changesets/config@2.3.1:
- resolution: {integrity: sha512-PQXaJl82CfIXddUOppj4zWu+987GCw2M+eQcOepxN5s+kvnsZOwjEJO3DH9eVy+OP6Pg/KFEWdsECFEYTtbg6w==}
+ /@changesets/config@3.0.0:
+ resolution: {integrity: sha512-o/rwLNnAo/+j9Yvw9mkBQOZySDYyOr/q+wptRLcAVGlU6djOeP9v1nlalbL9MFsobuBVQbZCTp+dIzdq+CLQUA==}
dependencies:
- '@changesets/errors': 0.1.4
- '@changesets/get-dependents-graph': 1.3.6
- '@changesets/logger': 0.0.5
- '@changesets/types': 5.2.1
+ '@changesets/errors': 0.2.0
+ '@changesets/get-dependents-graph': 2.0.0
+ '@changesets/logger': 0.1.0
+ '@changesets/types': 6.0.0
'@manypkg/get-packages': 1.1.3
fs-extra: 7.0.1
micromatch: 4.0.5
dev: true
- /@changesets/errors@0.1.4:
- resolution: {integrity: sha512-HAcqPF7snsUJ/QzkWoKfRfXushHTu+K5KZLJWPb34s4eCZShIf8BFO3fwq6KU8+G7L5KdtN2BzQAXOSXEyiY9Q==}
+ /@changesets/errors@0.2.0:
+ resolution: {integrity: sha512-6BLOQUscTpZeGljvyQXlWOItQyU71kCdGz7Pi8H8zdw6BI0g3m43iL4xKUVPWtG+qrrL9DTjpdn8eYuCQSRpow==}
dependencies:
extendable-error: 0.1.7
dev: true
- /@changesets/get-dependents-graph@1.3.6:
- resolution: {integrity: sha512-Q/sLgBANmkvUm09GgRsAvEtY3p1/5OCzgBE5vX3vgb5CvW0j7CEljocx5oPXeQSNph6FXulJlXV3Re/v3K3P3Q==}
+ /@changesets/get-dependents-graph@2.0.0:
+ resolution: {integrity: sha512-cafUXponivK4vBgZ3yLu944mTvam06XEn2IZGjjKc0antpenkYANXiiE6GExV/yKdsCnE8dXVZ25yGqLYZmScA==}
dependencies:
- '@changesets/types': 5.2.1
+ '@changesets/types': 6.0.0
'@manypkg/get-packages': 1.1.3
chalk: 2.4.2
fs-extra: 7.0.1
semver: 7.5.4
dev: true
- /@changesets/get-release-plan@3.0.17:
- resolution: {integrity: sha512-6IwKTubNEgoOZwDontYc2x2cWXfr6IKxP3IhKeK+WjyD6y3M4Gl/jdQvBw+m/5zWILSOCAaGLu2ZF6Q+WiPniw==}
+ /@changesets/get-release-plan@4.0.0:
+ resolution: {integrity: sha512-9L9xCUeD/Tb6L/oKmpm8nyzsOzhdNBBbt/ZNcjynbHC07WW4E1eX8NMGC5g5SbM5z/V+MOrYsJ4lRW41GCbg3w==}
dependencies:
'@babel/runtime': 7.23.4
- '@changesets/assemble-release-plan': 5.2.4
- '@changesets/config': 2.3.1
- '@changesets/pre': 1.0.14
- '@changesets/read': 0.5.9
- '@changesets/types': 5.2.1
+ '@changesets/assemble-release-plan': 6.0.0
+ '@changesets/config': 3.0.0
+ '@changesets/pre': 2.0.0
+ '@changesets/read': 0.6.0
+ '@changesets/types': 6.0.0
'@manypkg/get-packages': 1.1.3
dev: true
- /@changesets/get-version-range-type@0.3.2:
- resolution: {integrity: sha512-SVqwYs5pULYjYT4op21F2pVbcrca4qA/bAA3FmFXKMN7Y+HcO8sbZUTx3TAy2VXulP2FACd1aC7f2nTuqSPbqg==}
+ /@changesets/get-version-range-type@0.4.0:
+ resolution: {integrity: sha512-hwawtob9DryoGTpixy1D3ZXbGgJu1Rhr+ySH2PvTLHvkZuQ7sRT4oQwMh0hbqZH1weAooedEjRsbrWcGLCeyVQ==}
dev: true
- /@changesets/git@2.0.0:
- resolution: {integrity: sha512-enUVEWbiqUTxqSnmesyJGWfzd51PY4H7mH9yUw0hPVpZBJ6tQZFMU3F3mT/t9OJ/GjyiM4770i+sehAn6ymx6A==}
+ /@changesets/git@3.0.0:
+ resolution: {integrity: sha512-vvhnZDHe2eiBNRFHEgMiGd2CT+164dfYyrJDhwwxTVD/OW0FUD6G7+4DIx1dNwkwjHyzisxGAU96q0sVNBns0w==}
dependencies:
'@babel/runtime': 7.23.4
- '@changesets/errors': 0.1.4
- '@changesets/types': 5.2.1
+ '@changesets/errors': 0.2.0
+ '@changesets/types': 6.0.0
'@manypkg/get-packages': 1.1.3
is-subdir: 1.2.0
micromatch: 4.0.5
spawndamnit: 2.0.0
dev: true
- /@changesets/logger@0.0.5:
- resolution: {integrity: sha512-gJyZHomu8nASHpaANzc6bkQMO9gU/ib20lqew1rVx753FOxffnCrJlGIeQVxNWCqM+o6OOleCo/ivL8UAO5iFw==}
+ /@changesets/logger@0.1.0:
+ resolution: {integrity: sha512-pBrJm4CQm9VqFVwWnSqKEfsS2ESnwqwH+xR7jETxIErZcfd1u2zBSqrHbRHR7xjhSgep9x2PSKFKY//FAshA3g==}
dependencies:
chalk: 2.4.2
dev: true
- /@changesets/parse@0.3.16:
- resolution: {integrity: sha512-127JKNd167ayAuBjUggZBkmDS5fIKsthnr9jr6bdnuUljroiERW7FBTDNnNVyJ4l69PzR57pk6mXQdtJyBCJKg==}
+ /@changesets/parse@0.4.0:
+ resolution: {integrity: sha512-TS/9KG2CdGXS27S+QxbZXgr8uPsP4yNJYb4BC2/NeFUj80Rni3TeD2qwWmabymxmrLo7JEsytXH1FbpKTbvivw==}
dependencies:
- '@changesets/types': 5.2.1
+ '@changesets/types': 6.0.0
js-yaml: 3.14.1
dev: true
- /@changesets/pre@1.0.14:
- resolution: {integrity: sha512-dTsHmxQWEQekHYHbg+M1mDVYFvegDh9j/kySNuDKdylwfMEevTeDouR7IfHNyVodxZXu17sXoJuf2D0vi55FHQ==}
+ /@changesets/pre@2.0.0:
+ resolution: {integrity: sha512-HLTNYX/A4jZxc+Sq8D1AMBsv+1qD6rmmJtjsCJa/9MSRybdxh0mjbTvE6JYZQ/ZiQ0mMlDOlGPXTm9KLTU3jyw==}
dependencies:
'@babel/runtime': 7.23.4
- '@changesets/errors': 0.1.4
- '@changesets/types': 5.2.1
+ '@changesets/errors': 0.2.0
+ '@changesets/types': 6.0.0
'@manypkg/get-packages': 1.1.3
fs-extra: 7.0.1
dev: true
- /@changesets/read@0.5.9:
- resolution: {integrity: sha512-T8BJ6JS6j1gfO1HFq50kU3qawYxa4NTbI/ASNVVCBTsKquy2HYwM9r7ZnzkiMe8IEObAJtUVGSrePCOxAK2haQ==}
+ /@changesets/read@0.6.0:
+ resolution: {integrity: sha512-ZypqX8+/im1Fm98K4YcZtmLKgjs1kDQ5zHpc2U1qdtNBmZZfo/IBiG162RoP0CUF05tvp2y4IspH11PLnPxuuw==}
dependencies:
'@babel/runtime': 7.23.4
- '@changesets/git': 2.0.0
- '@changesets/logger': 0.0.5
- '@changesets/parse': 0.3.16
- '@changesets/types': 5.2.1
+ '@changesets/git': 3.0.0
+ '@changesets/logger': 0.1.0
+ '@changesets/parse': 0.4.0
+ '@changesets/types': 6.0.0
chalk: 2.4.2
fs-extra: 7.0.1
p-filter: 2.1.0
@@ -703,15 +705,15 @@ packages:
resolution: {integrity: sha512-LDQvVDv5Kb50ny2s25Fhm3d9QSZimsoUGBsUioj6MC3qbMUCuC8GPIvk/M6IvXx3lYhAs0lwWUQLb+VIEUCECw==}
dev: true
- /@changesets/types@5.2.1:
- resolution: {integrity: sha512-myLfHbVOqaq9UtUKqR/nZA/OY7xFjQMdfgfqeZIBK4d0hA6pgxArvdv8M+6NUzzBsjWLOtvApv8YHr4qM+Kpfg==}
+ /@changesets/types@6.0.0:
+ resolution: {integrity: sha512-b1UkfNulgKoWfqyHtzKS5fOZYSJO+77adgL7DLRDr+/7jhChN+QcHnbjiQVOz/U+Ts3PGNySq7diAItzDgugfQ==}
dev: true
- /@changesets/write@0.2.3:
- resolution: {integrity: sha512-Dbamr7AIMvslKnNYsLFafaVORx4H0pvCA2MHqgtNCySMe1blImEyAEOzDmcgKAkgz4+uwoLz7demIrX+JBr/Xw==}
+ /@changesets/write@0.3.0:
+ resolution: {integrity: sha512-slGLb21fxZVUYbyea+94uFiD6ntQW0M2hIKNznFizDhZPDgn2c/fv1UzzlW43RVzh1BEDuIqW6hzlJ1OflNmcw==}
dependencies:
'@babel/runtime': 7.23.4
- '@changesets/types': 5.2.1
+ '@changesets/types': 6.0.0
fs-extra: 7.0.1
human-id: 1.0.2
prettier: 2.8.8
@@ -722,7 +724,7 @@ packages:
engines: {node: '>= 10.0.0'}
dependencies:
'@metamask/safe-event-emitter': 2.0.0
- '@solana/web3.js': 1.87.5
+ '@solana/web3.js': 1.87.6
bind-decorator: 1.0.11
bn.js: 5.2.1
buffer: 6.0.3
@@ -732,7 +734,7 @@ packages:
eth-rpc-errors: 4.0.2
json-rpc-engine: 6.1.0
keccak: 3.0.4
- preact: 10.18.2
+ preact: 10.19.2
qs: 6.11.2
rxjs: 6.6.7
sha.js: 2.4.11
@@ -861,7 +863,7 @@ packages:
dependencies:
'@commitlint/top-level': 18.4.3
'@commitlint/types': 18.4.3
- fs-extra: 11.1.1
+ fs-extra: 11.2.0
git-raw-commits: 2.0.11
minimist: 1.2.8
dev: true
@@ -954,7 +956,7 @@ packages:
resolution: {integrity: sha512-W2P2c/VRW1/1tLox0mVUalvnWXxavmv/Oum2aPsRcoDJuob75FC3Y8FbpfLwUegRcxINtGUMPq0tFCvYNTBXNA==}
dev: false
- /@emotion/react@11.11.1(@types/react@18.2.38)(react@18.2.0):
+ /@emotion/react@11.11.1(@types/react@18.2.39)(react@18.2.0):
resolution: {integrity: sha512-5mlW1DquU5HaxjLkfkGN1GA/fvVGdyHURRiX/0FHl2cfIfRxSOfmxEH5YS43edp0OldZrZ+dkBKbngxcNCdZvA==}
peerDependencies:
'@types/react': '*'
@@ -970,7 +972,7 @@ packages:
'@emotion/use-insertion-effect-with-fallbacks': 1.0.1(react@18.2.0)
'@emotion/utils': 1.2.1
'@emotion/weak-memoize': 0.3.1
- '@types/react': 18.2.38
+ '@types/react': 18.2.39
hoist-non-react-statics: 3.3.2
react: 18.2.0
dev: false
@@ -989,7 +991,7 @@ packages:
resolution: {integrity: sha512-0QBtGvaqtWi+nx6doRwDdBIzhNdZrXUppvTM4dtZZWEGTXL/XE/yJxLMGlDT1Gt+UHH5IX1n+jkXyytE/av7OA==}
dev: false
- /@emotion/styled@11.11.0(@emotion/react@11.11.1)(@types/react@18.2.38)(react@18.2.0):
+ /@emotion/styled@11.11.0(@emotion/react@11.11.1)(@types/react@18.2.39)(react@18.2.0):
resolution: {integrity: sha512-hM5Nnvu9P3midq5aaXj4I+lnSfNi7Pmd4EWk1fOZ3pxookaQTNew6bp4JaCBYM4HVFZF9g7UjJmsUmC2JlxOng==}
peerDependencies:
'@emotion/react': ^11.0.0-rc.0
@@ -1002,11 +1004,11 @@ packages:
'@babel/runtime': 7.23.4
'@emotion/babel-plugin': 11.11.0
'@emotion/is-prop-valid': 1.2.1
- '@emotion/react': 11.11.1(@types/react@18.2.38)(react@18.2.0)
+ '@emotion/react': 11.11.1(@types/react@18.2.39)(react@18.2.0)
'@emotion/serialize': 1.1.2
'@emotion/use-insertion-effect-with-fallbacks': 1.0.1(react@18.2.0)
'@emotion/utils': 1.2.1
- '@types/react': 18.2.38
+ '@types/react': 18.2.39
react: 18.2.0
dev: false
@@ -1580,18 +1582,18 @@ packages:
react: '>=16'
dependencies:
'@types/mdx': 2.0.10
- '@types/react': 18.2.38
+ '@types/react': 18.2.39
react: 18.2.0
dev: false
- /@mdx-js/rollup@2.2.1(rollup@4.5.2):
+ /@mdx-js/rollup@2.2.1(rollup@4.6.0):
resolution: {integrity: sha512-wpGeK9iO7gPEIyC/ZTiggLY/MkEWDj5IWSsjlpkefgjb5RbmUukXU6/D2rHA+VAopxigS3NlaIL2ctpYBi4fmg==}
peerDependencies:
rollup: '>=2'
dependencies:
'@mdx-js/mdx': 2.1.5
- '@rollup/pluginutils': 5.0.5(rollup@4.5.2)
- rollup: 4.5.2
+ '@rollup/pluginutils': 5.1.0(rollup@4.6.0)
+ rollup: 4.6.0
source-map: 0.7.4
vfile: 5.3.7
transitivePeerDependencies:
@@ -1622,8 +1624,8 @@ packages:
- '@types/node'
dev: true
- /@microsoft/api-extractor@7.38.2(@types/node@18.18.13):
- resolution: {integrity: sha512-JOARuhTwOcOMIU0O2czscoJy3ddVzIRhSA9/7T1ALuZSNphgWsPk+Bv4E7AnBDmTV4pP4lBNLtCxEHjjpWaytQ==}
+ /@microsoft/api-extractor@7.38.3(@types/node@18.18.13):
+ resolution: {integrity: sha512-xt9iYyC5f39281j77JTA9C3ISJpW1XWkCcnw+2vM78CPnro6KhPfwQdPDfwS5JCPNuq0grm8cMdPUOPvrchDWw==}
hasBin: true
dependencies:
'@microsoft/api-extractor-model': 7.28.2(@types/node@18.18.13)
@@ -1832,7 +1834,7 @@ packages:
engines: {node: '>=14'}
dev: false
- /@rollup/plugin-node-resolve@15.2.3(rollup@4.5.2):
+ /@rollup/plugin-node-resolve@15.2.3(rollup@4.6.0):
resolution: {integrity: sha512-j/lym8nf5E21LwBT4Df1VD6hRO2L2iwUeUmP7litikRsVp1H6NWx20NEp0Y7su+7XGc476GnXXc4kFeZNGmaSQ==}
engines: {node: '>=14.0.0'}
peerDependencies:
@@ -1841,17 +1843,17 @@ packages:
rollup:
optional: true
dependencies:
- '@rollup/pluginutils': 5.0.5(rollup@4.5.2)
+ '@rollup/pluginutils': 5.1.0(rollup@4.6.0)
'@types/resolve': 1.20.2
deepmerge: 4.3.1
is-builtin-module: 3.2.1
is-module: 1.0.0
resolve: 1.22.8
- rollup: 4.5.2
+ rollup: 4.6.0
dev: true
- /@rollup/pluginutils@5.0.5(rollup@4.5.2):
- resolution: {integrity: sha512-6aEYR910NyP73oHiJglti74iRyOwgFU4x3meH/H8OJx6Ry0j6cOVZ5X/wTvub7G7Ao6qaHBEaNsV3GLJkSsF+Q==}
+ /@rollup/pluginutils@5.1.0(rollup@4.6.0):
+ resolution: {integrity: sha512-XTIWOPPcpvyKI6L1NHo0lFlCyznUEyPmPY1mc3KpPVDYulHSTvyeLNVW00QTLIAFNhR3kYnJTQHeGqU4M3n09g==}
engines: {node: '>=14.0.0'}
peerDependencies:
rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0
@@ -1862,99 +1864,99 @@ packages:
'@types/estree': 1.0.5
estree-walker: 2.0.2
picomatch: 2.3.1
- rollup: 4.5.2
+ rollup: 4.6.0
dev: true
- /@rollup/rollup-android-arm-eabi@4.5.2:
- resolution: {integrity: sha512-ee7BudTwwrglFYSc3UnqInDDjCLWHKrFmGNi4aK7jlEyg4CyPa1DCMrZfsN1O13YT76UFEqXz2CoN7BCGpUlJw==}
+ /@rollup/rollup-android-arm-eabi@4.6.0:
+ resolution: {integrity: sha512-keHkkWAe7OtdALGoutLY3utvthkGF+Y17ws9LYT8pxMBYXaCoH/8dXS2uzo6e8+sEhY7y/zi5RFo22Dy2lFpDw==}
cpu: [arm]
os: [android]
requiresBuild: true
dev: true
optional: true
- /@rollup/rollup-android-arm64@4.5.2:
- resolution: {integrity: sha512-xOuhj9HHtn8128ir8veoQsBbAUBasDbHIBniYTEx02pAmu9EXL+ZjJqngnNEy6ZgZ4h1JwL33GMNu3yJL5Mzow==}
+ /@rollup/rollup-android-arm64@4.6.0:
+ resolution: {integrity: sha512-y3Kt+34smKQNWilicPbBz/MXEY7QwDzMFNgwEWeYiOhUt9MTWKjHqe3EVkXwT2fR7izOvHpDWZ0o2IyD9SWX7A==}
cpu: [arm64]
os: [android]
requiresBuild: true
dev: true
optional: true
- /@rollup/rollup-darwin-arm64@4.5.2:
- resolution: {integrity: sha512-NTGJWoL8bKyqyWFn9/RzSv4hQ4wTbaAv0lHHRwf4OnpiiP4P8W0jiXbm8Nc5BCXKmWAwuvJY82mcIU2TayC20g==}
+ /@rollup/rollup-darwin-arm64@4.6.0:
+ resolution: {integrity: sha512-oLzzxcUIHltHxOCmaXl+pkIlU+uhSxef5HfntW7RsLh1eHm+vJzjD9Oo4oUKso4YuP4PpbFJNlZjJuOrxo8dPg==}
cpu: [arm64]
os: [darwin]
requiresBuild: true
dev: true
optional: true
- /@rollup/rollup-darwin-x64@4.5.2:
- resolution: {integrity: sha512-hlKqj7bpPvU15sZo4za14u185lpMzdwWLMc9raMqPK4wywt0wR23y1CaVQ4oAFXat3b5/gmRntyfpwWTKl+vvA==}
+ /@rollup/rollup-darwin-x64@4.6.0:
+ resolution: {integrity: sha512-+ANnmjkcOBaV25n0+M0Bere3roeVAnwlKW65qagtuAfIxXF9YxUneRyAn/RDcIdRa7QrjRNJL3jR7T43ObGe8Q==}
cpu: [x64]
os: [darwin]
requiresBuild: true
dev: true
optional: true
- /@rollup/rollup-linux-arm-gnueabihf@4.5.2:
- resolution: {integrity: sha512-7ZIZx8c3u+pfI0ohQsft/GywrXez0uR6dUP0JhBuCK3sFO5TfdLn/YApnVkvPxuTv3+YKPIZend9Mt7Cz6sS3Q==}
+ /@rollup/rollup-linux-arm-gnueabihf@4.6.0:
+ resolution: {integrity: sha512-tBTSIkjSVUyrekddpkAqKOosnj1Fc0ZY0rJL2bIEWPKqlEQk0paORL9pUIlt7lcGJi3LzMIlUGXvtNi1Z6MOCQ==}
cpu: [arm]
os: [linux]
requiresBuild: true
dev: true
optional: true
- /@rollup/rollup-linux-arm64-gnu@4.5.2:
- resolution: {integrity: sha512-7Pk/5mO11JW/cH+a8lL/i0ZxmRGrbpYqN0VwO2DHhU+SJWWOH2zE1RAcPaj8KqiwC8DCDIJOSxjV9+9lLb6aeA==}
+ /@rollup/rollup-linux-arm64-gnu@4.6.0:
+ resolution: {integrity: sha512-Ed8uJI3kM11de9S0j67wAV07JUNhbAqIrDYhQBrQW42jGopgheyk/cdcshgGO4fW5Wjq97COCY/BHogdGvKVNQ==}
cpu: [arm64]
os: [linux]
requiresBuild: true
dev: true
optional: true
- /@rollup/rollup-linux-arm64-musl@4.5.2:
- resolution: {integrity: sha512-KrRnuG5phJx756e62wxvWH2e+TK84MP2IVuPwfge+GBvWqIUfVzFRn09TKruuQBXzZp52Vyma7FjMDkwlA9xpg==}
+ /@rollup/rollup-linux-arm64-musl@4.6.0:
+ resolution: {integrity: sha512-mZoNQ/qK4D7SSY8v6kEsAAyDgznzLLuSFCA3aBHZTmf3HP/dW4tNLTtWh9+LfyO0Z1aUn+ecpT7IQ3WtIg3ViQ==}
cpu: [arm64]
os: [linux]
requiresBuild: true
dev: true
optional: true
- /@rollup/rollup-linux-x64-gnu@4.5.2:
- resolution: {integrity: sha512-My+53GasPa2D2tU5dXiyHYwrELAUouSfkNlZ3bUKpI7btaztO5vpALEs3mvFjM7aKTvEbc7GQckuXeXIDKQ0fg==}
+ /@rollup/rollup-linux-x64-gnu@4.6.0:
+ resolution: {integrity: sha512-rouezFHpwCqdEXsqAfNsTgSWO0FoZ5hKv5p+TGO5KFhyN/dvYXNMqMolOb8BkyKcPqjYRBeT+Z6V3aM26rPaYg==}
cpu: [x64]
os: [linux]
requiresBuild: true
dev: true
optional: true
- /@rollup/rollup-linux-x64-musl@4.5.2:
- resolution: {integrity: sha512-/f0Q6Sc+Vw54Ws6N8fxaEe4R7at3b8pFyv+O/F2VaQ4hODUJcRUcCBJh6zuqtgQQt7w845VTkGLFgWZkP3tUoQ==}
+ /@rollup/rollup-linux-x64-musl@4.6.0:
+ resolution: {integrity: sha512-Bbm+fyn3S6u51urfj3YnqBXg5vI2jQPncRRELaucmhBVyZkbWClQ1fEsRmdnCPpQOQfkpg9gZArvtMVkOMsh1w==}
cpu: [x64]
os: [linux]
requiresBuild: true
dev: true
optional: true
- /@rollup/rollup-win32-arm64-msvc@4.5.2:
- resolution: {integrity: sha512-NCKuuZWLht6zj7s6EIFef4BxCRX1GMr83S2W4HPCA0RnJ4iHE4FS1695q6Ewoa6A9nFjJe1//yUu0kgBU07Edw==}
+ /@rollup/rollup-win32-arm64-msvc@4.6.0:
+ resolution: {integrity: sha512-+MRMcyx9L2kTrTUzYmR61+XVsliMG4odFb5UmqtiT8xOfEicfYAGEuF/D1Pww1+uZkYhBqAHpvju7VN+GnC3ng==}
cpu: [arm64]
os: [win32]
requiresBuild: true
dev: true
optional: true
- /@rollup/rollup-win32-ia32-msvc@4.5.2:
- resolution: {integrity: sha512-J5zL3riR4AOyU/J3M/i4k/zZ8eP1yT+nTmAKztCXJtnI36jYH0eepvob22mAQ/kLwfsK2TB6dbyVY1F8c/0H5A==}
+ /@rollup/rollup-win32-ia32-msvc@4.6.0:
+ resolution: {integrity: sha512-rxfeE6K6s/Xl2HGeK6cO8SiQq3k/3BYpw7cfhW5Bk2euXNEpuzi2cc7llxx1si1QgwfjNtdRNTGqdBzGlFZGFw==}
cpu: [ia32]
os: [win32]
requiresBuild: true
dev: true
optional: true
- /@rollup/rollup-win32-x64-msvc@4.5.2:
- resolution: {integrity: sha512-pL0RXRHuuGLhvs7ayX/SAHph1hrDPXOM5anyYUQXWJEENxw3nfHkzv8FfVlEVcLyKPAEgDRkd6RKZq2SMqS/yg==}
+ /@rollup/rollup-win32-x64-msvc@4.6.0:
+ resolution: {integrity: sha512-QqmCsydHS172Y0Kc13bkMXvipbJSvzeglBncJG3LsYJSiPlxYACz7MmJBs4A8l1oU+jfhYEIC/+AUSlvjmiX/g==}
cpu: [x64]
os: [win32]
requiresBuild: true
@@ -2010,7 +2012,7 @@ packages:
resolution: {integrity: sha512-gYw0ki/EAuV1oSyMxpqandHjnthZjYYy+YWpTAzf8BqfXM3ItcZLpjxfg+3+mXW8HIO+3jw6T9iiqEXsqHaMMw==}
dependencies:
'@safe-global/safe-gateway-typescript-sdk': 3.13.2
- viem: 1.19.8(typescript@5.3.2)
+ viem: 1.19.9(typescript@5.3.2)
transitivePeerDependencies:
- bufferutil
- typescript
@@ -2021,7 +2023,7 @@ packages:
resolution: {integrity: sha512-XJbEPuaVc7b9n23MqlF6c+ToYIS3f7P2Sel8f3cSBQ9WORE4xrSuvhMpK9fDSFqJ7by/brc+rmJR/5HViRr0/w==}
dependencies:
'@safe-global/safe-gateway-typescript-sdk': 3.13.2
- viem: 1.19.8(typescript@5.3.2)
+ viem: 1.19.9(typescript@5.3.2)
transitivePeerDependencies:
- bufferutil
- typescript
@@ -2054,8 +2056,8 @@ packages:
dependencies:
buffer: 6.0.3
- /@solana/web3.js@1.87.5:
- resolution: {integrity: sha512-hy5RVGVw8eXq//g41mIFhk5Jx4QH1CwbkPiQn/3MmHp6VD2HBRVMMZUSGUhYZxbK7NoIjQUsiv4MOlnl3VaUag==}
+ /@solana/web3.js@1.87.6:
+ resolution: {integrity: sha512-LkqsEBgTZztFiccZZXnawWa8qNCATEqE97/d0vIwjTclmVlc8pBpD1DmjfVHtZ1HS5fZorFlVhXfpwnCNDZfyg==}
dependencies:
'@babel/runtime': 7.23.4
'@noble/curves': 1.2.0
@@ -2070,7 +2072,7 @@ packages:
fast-stable-stringify: 1.0.0
jayson: 4.1.0
node-fetch: 2.7.0
- rpc-websockets: 7.6.2
+ rpc-websockets: 7.8.0
superstruct: 0.14.2
transitivePeerDependencies:
- bufferutil
@@ -2227,8 +2229,8 @@ packages:
react: '>=16.9.0'
react-dom: '>=16.9.0'
dependencies:
- '@emotion/react': 11.11.1(@types/react@18.2.38)(react@18.2.0)
- '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.38)(react@18.2.0)
+ '@emotion/react': 11.11.1(@types/react@18.2.39)(react@18.2.0)
+ '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.39)(react@18.2.0)
'@totejs/styled-system': 2.14.0(react-dom@18.2.0)(react@18.2.0)
react: 18.2.0
react-dom: 18.2.0(react@18.2.0)
@@ -2242,8 +2244,8 @@ packages:
react: '>=16.9.0'
react-dom: '>=16.9.0'
dependencies:
- '@emotion/react': 11.11.1(@types/react@18.2.38)(react@18.2.0)
- '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.38)(react@18.2.0)
+ '@emotion/react': 11.11.1(@types/react@18.2.39)(react@18.2.0)
+ '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.39)(react@18.2.0)
'@totejs/styled-system': 2.14.0(react-dom@18.2.0)(react@18.2.0)
react: 18.2.0
react-dom: 18.2.0(react@18.2.0)
@@ -2267,8 +2269,8 @@ packages:
react: '>=16.9.0'
react-dom: '>=16.9.0'
dependencies:
- '@emotion/react': 11.11.1(@types/react@18.2.38)(react@18.2.0)
- '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.38)(react@18.2.0)
+ '@emotion/react': 11.11.1(@types/react@18.2.39)(react@18.2.0)
+ '@emotion/styled': 11.11.0(@emotion/react@11.11.1)(@types/react@18.2.39)(react@18.2.0)
'@popperjs/core': 2.11.8
'@totejs/icons': 2.18.0(@emotion/react@11.11.1)(@emotion/styled@11.11.0)(react-dom@18.2.0)(react@18.2.0)
'@totejs/styled-system': 2.14.0(react-dom@18.2.0)(react@18.2.0)
@@ -2366,12 +2368,6 @@ packages:
dependencies:
'@types/unist': 2.0.10
- /@types/is-ci@3.0.4:
- resolution: {integrity: sha512-AkCYCmwlXeuH89DagDCzvCAyltI2v9lh3U3DqSg/GrBYoReAaWwxfXCqMx9UV5MajLZ4ZFwZzV4cABGIxk2XRw==}
- dependencies:
- ci-info: 3.9.0
- dev: true
-
/@types/json-schema@7.0.15:
resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==}
dev: true
@@ -2429,11 +2425,11 @@ packages:
/@types/react-dom@18.2.17:
resolution: {integrity: sha512-rvrT/M7Df5eykWFxn6MYt5Pem/Dbyc1N8Y0S9Mrkw2WFCRiqUgw9P7ul2NpwsXCSM1DVdENzdG9J5SreqfAIWg==}
dependencies:
- '@types/react': 18.2.38
+ '@types/react': 18.2.39
dev: true
- /@types/react@18.2.38:
- resolution: {integrity: sha512-cBBXHzuPtQK6wNthuVMV6IjHAFkdl/FOPFIlkd81/Cd1+IqkHu/A+w4g43kaQQoYHik/ruaQBDL72HyCy1vuMw==}
+ /@types/react@18.2.39:
+ resolution: {integrity: sha512-Oiw+ppED6IremMInLV4HXGbfbG6GyziY3kqAwJYOR0PNbkYDmLWQA3a95EhdSmamsvbkJN96ZNN+YD+fGjzSBA==}
dependencies:
'@types/prop-types': 15.7.11
'@types/scheduler': 0.16.8
@@ -2723,20 +2719,20 @@ packages:
path-browserify: 1.0.1
dev: true
- /@vue/compiler-core@3.3.8:
- resolution: {integrity: sha512-hN/NNBUECw8SusQvDSqqcVv6gWq8L6iAktUR0UF3vGu2OhzRqcOiAno0FmBJWwxhYEXRlQJT5XnoKsVq1WZx4g==}
+ /@vue/compiler-core@3.3.9:
+ resolution: {integrity: sha512-+/Lf68Vr/nFBA6ol4xOtJrW+BQWv3QWKfRwGSm70jtXwfhZNF4R/eRgyVJYoxFRhdCTk/F6g99BP0ffPgZihfQ==}
dependencies:
- '@babel/parser': 7.23.0
- '@vue/shared': 3.3.8
+ '@babel/parser': 7.23.4
+ '@vue/shared': 3.3.9
estree-walker: 2.0.2
source-map-js: 1.0.2
dev: true
- /@vue/compiler-dom@3.3.8:
- resolution: {integrity: sha512-+PPtv+p/nWDd0AvJu3w8HS0RIm/C6VGBIRe24b9hSyNWOAPEUosFZ5diwawwP8ip5sJ8n0Pe87TNNNHnvjs0FQ==}
+ /@vue/compiler-dom@3.3.9:
+ resolution: {integrity: sha512-nfWubTtLXuT4iBeDSZ5J3m218MjOy42Vp2pmKVuBKo2/BLcrFUX8nCSr/bKRFiJ32R8qbdnnnBgRn9AdU5v0Sg==}
dependencies:
- '@vue/compiler-core': 3.3.8
- '@vue/shared': 3.3.8
+ '@vue/compiler-core': 3.3.9
+ '@vue/shared': 3.3.9
dev: true
/@vue/language-core@1.8.22(typescript@5.3.2):
@@ -2749,8 +2745,8 @@ packages:
dependencies:
'@volar/language-core': 1.10.10
'@volar/source-map': 1.10.10
- '@vue/compiler-dom': 3.3.8
- '@vue/shared': 3.3.8
+ '@vue/compiler-dom': 3.3.9
+ '@vue/shared': 3.3.9
computeds: 0.0.1
minimatch: 9.0.3
muggle-string: 0.3.1
@@ -2758,11 +2754,11 @@ packages:
vue-template-compiler: 2.7.15
dev: true
- /@vue/shared@3.3.8:
- resolution: {integrity: sha512-8PGwybFwM4x8pcfgqEQFy70NaQxASvOC5DJwLQfpArw1UDfUXrJkdxD3BhVTMS+0Lef/TU7YO0Jvr0jJY8T+mw==}
+ /@vue/shared@3.3.9:
+ resolution: {integrity: sha512-ZE0VTIR0LmYgeyhurPTpy4KzKsuDyQbMSdM49eKkMnT5X4VfFBLysMzjIZhLEFQYjjOVVfbvUDHckwjDFiO2eA==}
dev: true
- /@wagmi/connectors@3.1.5(@types/react@18.2.38)(react@18.2.0)(typescript@5.3.2)(viem@1.19.8):
+ /@wagmi/connectors@3.1.5(@types/react@18.2.39)(react@18.2.0)(typescript@5.3.2)(viem@1.19.9):
resolution: {integrity: sha512-aE4rWZbivqWa9HqjiLDPtwROH2b1Az+lBVMeZ3o/aFxGNGNEkdrSAMOUG15/UFy3VnN6HqGOtTobOBZ10JhfNQ==}
peerDependencies:
typescript: '>=5.0.4'
@@ -2777,12 +2773,12 @@ packages:
'@safe-global/safe-apps-sdk': 8.1.0(typescript@5.3.2)
'@walletconnect/ethereum-provider': 2.10.2(@walletconnect/modal@2.6.2)
'@walletconnect/legacy-provider': 2.0.0
- '@walletconnect/modal': 2.6.2(@types/react@18.2.38)(react@18.2.0)
+ '@walletconnect/modal': 2.6.2(@types/react@18.2.39)(react@18.2.0)
'@walletconnect/utils': 2.10.2
abitype: 0.8.7(typescript@5.3.2)
eventemitter3: 4.0.7
typescript: 5.3.2
- viem: 1.19.8(typescript@5.3.2)
+ viem: 1.19.9(typescript@5.3.2)
transitivePeerDependencies:
- '@react-native-async-storage/async-storage'
- '@types/react'
@@ -2794,7 +2790,7 @@ packages:
- utf-8-validate
- zod
- /@wagmi/core@1.4.7(@types/react@18.2.38)(react@18.2.0)(typescript@5.3.2)(viem@1.19.8):
+ /@wagmi/core@1.4.7(@types/react@18.2.39)(react@18.2.0)(typescript@5.3.2)(viem@1.19.9):
resolution: {integrity: sha512-PiOIGni8ArQoPmuDylHX38zMt2nPnTYRIluIqiduKyGCM61X/tf10a0rafUMOOphDPudZu1TacNDhCSeoh/LEA==}
peerDependencies:
typescript: '>=5.0.4'
@@ -2803,12 +2799,12 @@ packages:
typescript:
optional: true
dependencies:
- '@wagmi/connectors': 3.1.5(@types/react@18.2.38)(react@18.2.0)(typescript@5.3.2)(viem@1.19.8)
+ '@wagmi/connectors': 3.1.5(@types/react@18.2.39)(react@18.2.0)(typescript@5.3.2)(viem@1.19.9)
abitype: 0.8.7(typescript@5.3.2)
eventemitter3: 4.0.7
typescript: 5.3.2
- viem: 1.19.8(typescript@5.3.2)
- zustand: 4.4.6(@types/react@18.2.38)(react@18.2.0)
+ viem: 1.19.9(typescript@5.3.2)
+ zustand: 4.4.7(@types/react@18.2.39)(react@18.2.0)
transitivePeerDependencies:
- '@react-native-async-storage/async-storage'
- '@types/react'
@@ -2880,7 +2876,7 @@ packages:
'@walletconnect/jsonrpc-provider': 1.0.13
'@walletconnect/jsonrpc-types': 1.0.3
'@walletconnect/jsonrpc-utils': 1.0.8
- '@walletconnect/modal': 2.6.2(@types/react@18.2.38)(react@18.2.0)
+ '@walletconnect/modal': 2.6.2(@types/react@18.2.39)(react@18.2.0)
'@walletconnect/sign-client': 2.10.2
'@walletconnect/types': 2.10.2
'@walletconnect/universal-provider': 2.10.2
@@ -3020,18 +3016,18 @@ packages:
pino: 7.11.0
tslib: 1.14.1
- /@walletconnect/modal-core@2.6.2(@types/react@18.2.38)(react@18.2.0):
+ /@walletconnect/modal-core@2.6.2(@types/react@18.2.39)(react@18.2.0):
resolution: {integrity: sha512-cv8ibvdOJQv2B+nyxP9IIFdxvQznMz8OOr/oR/AaUZym4hjXNL/l1a2UlSQBXrVjo3xxbouMxLb3kBsHoYP2CA==}
dependencies:
- valtio: 1.11.2(@types/react@18.2.38)(react@18.2.0)
+ valtio: 1.11.2(@types/react@18.2.39)(react@18.2.0)
transitivePeerDependencies:
- '@types/react'
- react
- /@walletconnect/modal-ui@2.6.2(@types/react@18.2.38)(react@18.2.0):
+ /@walletconnect/modal-ui@2.6.2(@types/react@18.2.39)(react@18.2.0):
resolution: {integrity: sha512-rbdstM1HPGvr7jprQkyPggX7rP4XiCG85ZA+zWBEX0dVQg8PpAgRUqpeub4xQKDgY7pY/xLRXSiCVdWGqvG2HA==}
dependencies:
- '@walletconnect/modal-core': 2.6.2(@types/react@18.2.38)(react@18.2.0)
+ '@walletconnect/modal-core': 2.6.2(@types/react@18.2.39)(react@18.2.0)
lit: 2.8.0
motion: 10.16.2
qrcode: 1.5.3
@@ -3039,11 +3035,11 @@ packages:
- '@types/react'
- react
- /@walletconnect/modal@2.6.2(@types/react@18.2.38)(react@18.2.0):
+ /@walletconnect/modal@2.6.2(@types/react@18.2.39)(react@18.2.0):
resolution: {integrity: sha512-eFopgKi8AjKf/0U4SemvcYw9zlLpx9njVN8sf6DAkowC2Md0gPU/UNEbH1Wwj407pEKnEds98pKWib1NN1ACoA==}
dependencies:
- '@walletconnect/modal-core': 2.6.2(@types/react@18.2.38)(react@18.2.0)
- '@walletconnect/modal-ui': 2.6.2(@types/react@18.2.38)(react@18.2.0)
+ '@walletconnect/modal-core': 2.6.2(@types/react@18.2.39)(react@18.2.0)
+ '@walletconnect/modal-ui': 2.6.2(@types/react@18.2.39)(react@18.2.0)
transitivePeerDependencies:
- '@types/react'
- react
@@ -3528,8 +3524,8 @@ packages:
resolution: {integrity: sha512-NTt0DNoKe958Q0BE0j0c1V9jbUzhBxHIEJy7asmGrpE0yG63KTV7PLHPnK2E1O9RsQrQ081I3NLuXGS6zht3cw==}
dev: true
- /caniuse-lite@1.0.30001564:
- resolution: {integrity: sha512-DqAOf+rhof+6GVx1y+xzbFPeOumfQnhYzVnZD6LAXijR77yPtm9mfOcqOnT3mpnJiZVT+kwLAFnRlZcIz+c6bg==}
+ /caniuse-lite@1.0.30001565:
+ resolution: {integrity: sha512-xrE//a3O7TP0vaJ8ikzkD2c2NgcVUvsEe2IvFTntV4Yd1Z9FVzh+gW+enX96L0psrbaFMcVcH2l90xNuGDWc8w==}
dev: false
/ccount@2.0.1:
@@ -4549,8 +4545,8 @@ packages:
dependencies:
is-callable: 1.2.7
- /fs-extra@11.1.1:
- resolution: {integrity: sha512-MGIE4HOvQCeUCzmlHs0vXpih4ysz4wg9qiSAu6cd42lVwPbTM1TjV7RusoyQqMmk/95gdQZX72u+YW+c3eEpFQ==}
+ /fs-extra@11.2.0:
+ resolution: {integrity: sha512-PmDi3uwK5nFuXh7XDTlVnS17xJS7vW36is2+w3xcv8SVxiB4NyATf4ctkVY5bkSjX0Y4nbvZCq1/EjtEyr9ktw==}
engines: {node: '>=14.14'}
dependencies:
graceful-fs: 4.2.11
@@ -4977,13 +4973,6 @@ packages:
resolution: {integrity: sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==}
engines: {node: '>= 0.4'}
- /is-ci@3.0.1:
- resolution: {integrity: sha512-ZYvCgrefwqoQ6yTyYUbQu64HsITZ3NfKX1lzaEYdkTDcfKzzCI/wthRRYKkdjHKFVgNiXKAKm65Zo1pk2as/QQ==}
- hasBin: true
- dependencies:
- ci-info: 3.9.0
- dev: true
-
/is-core-module@2.13.1:
resolution: {integrity: sha512-hHrIjvZsftOsvKSn2TRYl63zvxsgE0K+0mYMoH6gD4omR5IWB2KynivBQczo3+wF1cCkjzvptnI9Q0sPU66ilw==}
dependencies:
@@ -6205,7 +6194,7 @@ packages:
'@next/env': 13.5.6
'@swc/helpers': 0.5.2
busboy: 1.6.0
- caniuse-lite: 1.0.30001564
+ caniuse-lite: 1.0.30001565
postcss: 8.4.31
react: 18.2.0
react-dom: 18.2.0(react@18.2.0)
@@ -6565,6 +6554,9 @@ packages:
/preact@10.18.2:
resolution: {integrity: sha512-X/K43vocUHDg0XhWVmTTMbec4LT/iBMh+csCEqJk+pJqegaXsvjdqN80ZZ3L+93azWCnWCZ+WGwYb8SplxeNjA==}
+ /preact@10.19.2:
+ resolution: {integrity: sha512-UA9DX/OJwv6YwP9Vn7Ti/vF80XL+YA5H2l7BpCtUr3ya8LWHFzpiO5R+N7dN16ujpIxhekRFuOOF82bXX7K/lg==}
+
/preferred-pm@3.1.2:
resolution: {integrity: sha512-nk7dKrcW8hfCZ4H6klWcdRknBOXWzNQByJ0oJyX97BOupsYD+FzLS4hflgEu/uPUEHZCuRfMxzCBsuWd7OzT8Q==}
engines: {node: '>=10'}
@@ -6959,12 +6951,12 @@ packages:
glob: 7.2.3
dev: true
- /rollup-plugin-peer-deps-external@2.2.4(rollup@4.5.2):
+ /rollup-plugin-peer-deps-external@2.2.4(rollup@4.6.0):
resolution: {integrity: sha512-AWdukIM1+k5JDdAqV/Cxd+nejvno2FVLVeZ74NKggm3Q5s9cbbcOgUPGdbxPi4BXu7xGaZ8HG12F+thImYu/0g==}
peerDependencies:
rollup: '*'
dependencies:
- rollup: 4.5.2
+ rollup: 4.6.0
dev: true
/rollup@3.29.4:
@@ -6975,28 +6967,28 @@ packages:
fsevents: 2.3.3
dev: true
- /rollup@4.5.2:
- resolution: {integrity: sha512-CRK1uoROBfkcqrZKyaFcqCcZWNsvJ6yVYZkqTlRocZhO2s5yER6Z3f/QaYtO8RGyloPnmhwgzuPQpNGeK210xQ==}
+ /rollup@4.6.0:
+ resolution: {integrity: sha512-R8i5Her4oO1LiMQ3jKf7MUglYV/mhQ5g5OKeld5CnkmPdIGo79FDDQYqPhq/PCVuTQVuxsWgIbDy9F+zdHn80w==}
engines: {node: '>=18.0.0', npm: '>=8.0.0'}
hasBin: true
optionalDependencies:
- '@rollup/rollup-android-arm-eabi': 4.5.2
- '@rollup/rollup-android-arm64': 4.5.2
- '@rollup/rollup-darwin-arm64': 4.5.2
- '@rollup/rollup-darwin-x64': 4.5.2
- '@rollup/rollup-linux-arm-gnueabihf': 4.5.2
- '@rollup/rollup-linux-arm64-gnu': 4.5.2
- '@rollup/rollup-linux-arm64-musl': 4.5.2
- '@rollup/rollup-linux-x64-gnu': 4.5.2
- '@rollup/rollup-linux-x64-musl': 4.5.2
- '@rollup/rollup-win32-arm64-msvc': 4.5.2
- '@rollup/rollup-win32-ia32-msvc': 4.5.2
- '@rollup/rollup-win32-x64-msvc': 4.5.2
+ '@rollup/rollup-android-arm-eabi': 4.6.0
+ '@rollup/rollup-android-arm64': 4.6.0
+ '@rollup/rollup-darwin-arm64': 4.6.0
+ '@rollup/rollup-darwin-x64': 4.6.0
+ '@rollup/rollup-linux-arm-gnueabihf': 4.6.0
+ '@rollup/rollup-linux-arm64-gnu': 4.6.0
+ '@rollup/rollup-linux-arm64-musl': 4.6.0
+ '@rollup/rollup-linux-x64-gnu': 4.6.0
+ '@rollup/rollup-linux-x64-musl': 4.6.0
+ '@rollup/rollup-win32-arm64-msvc': 4.6.0
+ '@rollup/rollup-win32-ia32-msvc': 4.6.0
+ '@rollup/rollup-win32-x64-msvc': 4.6.0
fsevents: 2.3.3
dev: true
- /rpc-websockets@7.6.2:
- resolution: {integrity: sha512-+M1fOYMPxvOQDHbSItkD/an4fRwPZ1Nft1zv48G84S0TyChG2A1GXmjWkbs3o2NxW+q36H9nM2uLo5yojTrPaA==}
+ /rpc-websockets@7.8.0:
+ resolution: {integrity: sha512-AStkq6KDvSAmA4WiwlK1pDvj/33BWmExTATUokC0v+NhWekXSTNzXS5OGXeYwq501/pj6lBZMofg/h4dx4/tCg==}
dependencies:
'@babel/runtime': 7.23.4
eventemitter3: 4.0.7
@@ -7835,7 +7827,7 @@ packages:
engines: {node: '>= 0.10'}
dev: true
- /valtio@1.11.2(@types/react@18.2.38)(react@18.2.0):
+ /valtio@1.11.2(@types/react@18.2.39)(react@18.2.0):
resolution: {integrity: sha512-1XfIxnUXzyswPAPXo1P3Pdx2mq/pIqZICkWN60Hby0d9Iqb+MEIpqgYVlbflvHdrp2YR/q3jyKWRPJJ100yxaw==}
engines: {node: '>=12.20.0'}
peerDependencies:
@@ -7847,7 +7839,7 @@ packages:
react:
optional: true
dependencies:
- '@types/react': 18.2.38
+ '@types/react': 18.2.39
proxy-compare: 2.5.1
react: 18.2.0
use-sync-external-store: 1.2.0(react@18.2.0)
@@ -7874,8 +7866,8 @@ packages:
unist-util-stringify-position: 3.0.3
vfile-message: 3.1.4
- /viem@1.19.8(typescript@5.3.2):
- resolution: {integrity: sha512-AgoZcLej7u4Zw/ojDsDWfonPSoz07EirrvXVndAMG78ikHf7VnRbxkFACAFg2SgNbCXmr5+ePHpgd53dMVIZ4Q==}
+ /viem@1.19.9(typescript@5.3.2):
+ resolution: {integrity: sha512-Sf9U2x4jU0S/FALqYypcspWOGene0NZyD470oUripNhE0Ta6uOE/OgE4toTDVfRxov8qw0JFinr/wPGxYE3+HQ==}
peerDependencies:
typescript: '>=5.0.4'
peerDependenciesMeta:
@@ -7920,7 +7912,7 @@ packages:
- terser
dev: true
- /vite-plugin-dts@3.6.3(@types/node@18.18.13)(rollup@4.5.2)(typescript@5.3.2)(vite@4.5.0):
+ /vite-plugin-dts@3.6.3(@types/node@18.18.13)(rollup@4.6.0)(typescript@5.3.2)(vite@4.5.0):
resolution: {integrity: sha512-NyRvgobl15rYj65coi/gH7UAEH+CpSjh539DbGb40DfOTZSvDLNYTzc8CK4460W+LqXuMK7+U3JAxRB3ksrNPw==}
engines: {node: ^14.18.0 || >=16.0.0}
peerDependencies:
@@ -7930,8 +7922,8 @@ packages:
vite:
optional: true
dependencies:
- '@microsoft/api-extractor': 7.38.2(@types/node@18.18.13)
- '@rollup/pluginutils': 5.0.5(rollup@4.5.2)
+ '@microsoft/api-extractor': 7.38.3(@types/node@18.18.13)
+ '@rollup/pluginutils': 5.1.0(rollup@4.6.0)
'@vue/language-core': 1.8.22(typescript@5.3.2)
debug: 4.3.4
kolorist: 1.8.0
@@ -8039,7 +8031,7 @@ packages:
typescript: 5.3.2
dev: true
- /wagmi@1.4.7(@types/react@18.2.38)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.2)(viem@1.19.8):
+ /wagmi@1.4.7(@types/react@18.2.39)(react-dom@18.2.0)(react@18.2.0)(typescript@5.3.2)(viem@1.19.9):
resolution: {integrity: sha512-/k8gA9S6RnwU6Qroxs630jAFvRIx+DSKpCP1owgAEGWc7D2bAJHljwRSCRTGENz48HyJ4V3R7KYV1yImxPvM3A==}
peerDependencies:
react: '>=17.0.0'
@@ -8052,12 +8044,12 @@ packages:
'@tanstack/query-sync-storage-persister': 4.36.1
'@tanstack/react-query': 4.36.1(react-dom@18.2.0)(react@18.2.0)
'@tanstack/react-query-persist-client': 4.36.1(@tanstack/react-query@4.36.1)
- '@wagmi/core': 1.4.7(@types/react@18.2.38)(react@18.2.0)(typescript@5.3.2)(viem@1.19.8)
+ '@wagmi/core': 1.4.7(@types/react@18.2.39)(react@18.2.0)(typescript@5.3.2)(viem@1.19.9)
abitype: 0.8.7(typescript@5.3.2)
react: 18.2.0
typescript: 5.3.2
use-sync-external-store: 1.2.0(react@18.2.0)
- viem: 1.19.8(typescript@5.3.2)
+ viem: 1.19.9(typescript@5.3.2)
transitivePeerDependencies:
- '@react-native-async-storage/async-storage'
- '@types/react'
@@ -8309,8 +8301,8 @@ packages:
commander: 9.5.0
dev: true
- /zustand@4.4.6(@types/react@18.2.38)(react@18.2.0):
- resolution: {integrity: sha512-Rb16eW55gqL4W2XZpJh0fnrATxYEG3Apl2gfHTyDSE965x/zxslTikpNch0JgNjJA9zK6gEFW8Fl6d1rTZaqgg==}
+ /zustand@4.4.7(@types/react@18.2.39)(react@18.2.0):
+ resolution: {integrity: sha512-QFJWJMdlETcI69paJwhSMJz7PPWjVP8Sjhclxmxmxv/RYI7ZOvR5BHX+ktH0we9gTWQMxcne8q1OY8xxz604gw==}
engines: {node: '>=12.7.0'}
peerDependencies:
'@types/react': '>=16.8'
@@ -8324,7 +8316,7 @@ packages:
react:
optional: true
dependencies:
- '@types/react': 18.2.38
+ '@types/react': 18.2.39
react: 18.2.0
use-sync-external-store: 1.2.0(react@18.2.0)
diff --git a/website/package.json b/website/package.json
index 910fc279..c5b2e33a 100644
--- a/website/package.json
+++ b/website/package.json
@@ -4,6 +4,7 @@
"author": "node-real",
"private": true,
"type": "module",
+ "homepage": "https://node-real.github.io/walletkit",
"scripts": {
"dev": "vite --host 0.0.0.0",
"build": "tsc && vite build"
@@ -24,14 +25,14 @@
"unified": "~10.1.2",
"unist-util-visit": "~4.1.2",
"vconsole": "^3.15.1",
- "viem": "^1.19.8",
+ "viem": "^1.19.9",
"wagmi": "^1.4.7"
},
"devDependencies": {
"@mdx-js/rollup": "~2.2.1",
"@types/mdx": "~2.0.10",
"@types/node": "~18.6.5",
- "@types/react": "^18.2.38",
+ "@types/react": "^18.2.39",
"@types/react-dom": "^18.2.17",
"@vitejs/plugin-react": "~4.1.1",
"remark-gfm": "~3.0.1",
diff --git a/website/src/App.tsx b/website/src/App.tsx
index 21d836e7..8f6ab823 100644
--- a/website/src/App.tsx
+++ b/website/src/App.tsx
@@ -13,11 +13,11 @@ new VConsole();
export default function App() {
return (
-
- }>
+
+
} />
-
-
+
+
);
}
diff --git a/website/src/components/Layout/index.tsx b/website/src/components/Layout/index.tsx
index 76471468..9b0ea216 100644
--- a/website/src/components/Layout/index.tsx
+++ b/website/src/components/Layout/index.tsx
@@ -1,15 +1,13 @@
import { Box, Flex } from '@totejs/uikit';
-import { Outlet } from 'react-router-dom';
-
import { Header } from './Header';
-export function Layout() {
+export function Layout(props: React.PropsWithChildren) {
return (
-
+ {props.children}
diff --git a/website/src/components/WalletKit/index.tsx b/website/src/components/WalletKit/index.tsx
index f76e8013..ad9829fe 100644
--- a/website/src/components/WalletKit/index.tsx
+++ b/website/src/components/WalletKit/index.tsx
@@ -41,7 +41,7 @@ const config = createConfig(
);
const options: WalletKitOptions = {
- initialChainId: 56, // Once connected to the wallet, which chain you want to use
+ initialChainId: 1, // Once connected to the wallet, which chain you want to use
};
export default function App() {
diff --git a/website/src/pages/index.mdx b/website/src/pages/index.mdx
index e408522a..ce819bfe 100644
--- a/website/src/pages/index.mdx
+++ b/website/src/pages/index.mdx
@@ -170,7 +170,8 @@ const config = createConfig(
## Customizing ConnectButton
-`WalletKitButton.Custom`
+Note that `show()` will open the `connected page` instead of the `connectors page` once the wallet
+is connected.
```tsx live=false
@@ -342,8 +343,8 @@ const customTheme = {
qrCodeDot: 'var(--wk-colors-text)',
qrCodeBorder: 'var(--wk-colors-border)',
- noWalletButtonBackgroundText: 'var(--wk-colors-text)',
- noWalletButtonBackgroundTextHover: 'var(--wk-colors-text)',
+ noWalletButtonText: 'var(--wk-colors-text)',
+ noWalletButtonTextHover: 'var(--wk-colors-text)',
noWalletButtonBackground: 'transparent',
noWalletButtonBackgroundHover: 'var(--wk-colors-border)',
noWalletButtonBorder: 'var(--wk-colors-border)',
@@ -419,7 +420,7 @@ interface WalletKitOptions {
onClickWallet?: (connector: Connector, e?: React.MouseEvent) => undefined | boolean;
// !!! Notice
- // This callback takes effect only if WalletKitButton's connectRole='add-network'
+ // This callback takes effect only if WalletKitButton's action='add-network'
// will be called if network has already added to the wallet
onChainAlreadyAdded?: (connector: Connector, chainId: number) => void;
From 82e3521800480c668b960f6489bbedc451012c1e Mon Sep 17 00:00:00 2001
From: "github-actions[bot]"
<41898282+github-actions[bot]@users.noreply.github.com>
Date: Wed, 13 Dec 2023 10:12:33 +0800
Subject: [PATCH 4/4] chore: update versions (#61)
Co-authored-by: github-actions[bot]
---
.changeset/afraid-crabs-pump.md | 5 -----
.changeset/famous-drinks-behave.md | 5 -----
.changeset/happy-hounds-complain.md | 5 -----
.changeset/honest-numbers-hug.md | 5 -----
.changeset/late-birds-compare.md | 5 -----
.changeset/lovely-months-argue.md | 5 -----
.changeset/modern-comics-smell.md | 5 -----
.changeset/pre.json | 19 -------------------
.changeset/pretty-flowers-rhyme.md | 5 -----
packages/walletkit/CHANGELOG.md | 17 +++++++++++++++++
packages/walletkit/package.json | 2 +-
11 files changed, 18 insertions(+), 60 deletions(-)
delete mode 100644 .changeset/afraid-crabs-pump.md
delete mode 100644 .changeset/famous-drinks-behave.md
delete mode 100644 .changeset/happy-hounds-complain.md
delete mode 100644 .changeset/honest-numbers-hug.md
delete mode 100644 .changeset/late-birds-compare.md
delete mode 100644 .changeset/lovely-months-argue.md
delete mode 100644 .changeset/modern-comics-smell.md
delete mode 100644 .changeset/pre.json
delete mode 100644 .changeset/pretty-flowers-rhyme.md
diff --git a/.changeset/afraid-crabs-pump.md b/.changeset/afraid-crabs-pump.md
deleted file mode 100644
index c9bc7057..00000000
--- a/.changeset/afraid-crabs-pump.md
+++ /dev/null
@@ -1,5 +0,0 @@
----
-'@totejs/walletkit': patch
----
-
-Fixed theme configuration naming error issue
diff --git a/.changeset/famous-drinks-behave.md b/.changeset/famous-drinks-behave.md
deleted file mode 100644
index d53113e8..00000000
--- a/.changeset/famous-drinks-behave.md
+++ /dev/null
@@ -1,5 +0,0 @@
----
-'@totejs/walletkit': patch
----
-
-Fixed TrustWallet will automatically reconnect after reloading the page.
diff --git a/.changeset/happy-hounds-complain.md b/.changeset/happy-hounds-complain.md
deleted file mode 100644
index 17ddadad..00000000
--- a/.changeset/happy-hounds-complain.md
+++ /dev/null
@@ -1,5 +0,0 @@
----
-'@totejs/walletkit': patch
----
-
-refactor: update the `installed` field that detect whether wallet is installed to a function
diff --git a/.changeset/honest-numbers-hug.md b/.changeset/honest-numbers-hug.md
deleted file mode 100644
index 12669d36..00000000
--- a/.changeset/honest-numbers-hug.md
+++ /dev/null
@@ -1,5 +0,0 @@
----
-'@totejs/walletkit': patch
----
-
-Fixed multiple wallets conficts resulting in undetectable issues.
diff --git a/.changeset/late-birds-compare.md b/.changeset/late-birds-compare.md
deleted file mode 100644
index 2471f4e7..00000000
--- a/.changeset/late-birds-compare.md
+++ /dev/null
@@ -1,5 +0,0 @@
----
-'@totejs/walletkit': patch
----
-
-Fixed `WalletConnect` automatic connection issue in the follow scenario: connect the WalletConnect -> close browser -> reopen browser -> disconnect -> select WalletConnect, will automatically connect.
diff --git a/.changeset/lovely-months-argue.md b/.changeset/lovely-months-argue.md
deleted file mode 100644
index 8674cc05..00000000
--- a/.changeset/lovely-months-argue.md
+++ /dev/null
@@ -1,5 +0,0 @@
----
-'@totejs/walletkit': patch
----
-
-Fixed trustwallet losing account status after refreshing
diff --git a/.changeset/modern-comics-smell.md b/.changeset/modern-comics-smell.md
deleted file mode 100644
index 55dfc42c..00000000
--- a/.changeset/modern-comics-smell.md
+++ /dev/null
@@ -1,5 +0,0 @@
----
-'@totejs/walletkit': patch
----
-
-Fixed conflict issue between trustwallet and metaMask.
diff --git a/.changeset/pre.json b/.changeset/pre.json
deleted file mode 100644
index 06ad5de3..00000000
--- a/.changeset/pre.json
+++ /dev/null
@@ -1,19 +0,0 @@
-{
- "mode": "exit",
- "tag": "alpha",
- "initialVersions": {
- "example-nextjs": "0.0.1",
- "example-vite": "0.0.1",
- "@totejs/walletkit": "1.0.7-alpha.2",
- "website": "0.0.1"
- },
- "changesets": [
- "famous-drinks-behave",
- "happy-hounds-complain",
- "honest-numbers-hug",
- "late-birds-compare",
- "lovely-months-argue",
- "modern-comics-smell",
- "pretty-flowers-rhyme"
- ]
-}
diff --git a/.changeset/pretty-flowers-rhyme.md b/.changeset/pretty-flowers-rhyme.md
deleted file mode 100644
index 261fa305..00000000
--- a/.changeset/pretty-flowers-rhyme.md
+++ /dev/null
@@ -1,5 +0,0 @@
----
-'@totejs/walletkit': patch
----
-
-Add `action` prop to WalletKitButton & WalletKitButton.Custom to support the case of adding network.
diff --git a/packages/walletkit/CHANGELOG.md b/packages/walletkit/CHANGELOG.md
index 06268094..f0b7c728 100644
--- a/packages/walletkit/CHANGELOG.md
+++ b/packages/walletkit/CHANGELOG.md
@@ -1,5 +1,22 @@
# @totejs/walletkit
+## 1.0.7
+
+### Patch Changes
+
+- 084a397: Fixed theme configuration naming error issue
+- 084a397: Fixed TrustWallet will automatically reconnect after reloading the page.
+- 084a397: refactor: update the `installed` field that detect whether wallet is installed to a
+ function
+- 084a397: Fixed multiple wallets conficts resulting in undetectable issues.
+- 084a397: Fixed `WalletConnect` automatic connection issue in the follow scenario: connect the
+ WalletConnect -> close browser -> reopen browser -> disconnect -> select WalletConnect, will
+ automatically connect.
+- 084a397: Fixed trustwallet losing account status after refreshing
+- 084a397: Fixed conflict issue between trustwallet and metaMask.
+- 084a397: Add `action` prop to WalletKitButton & WalletKitButton.Custom to support the case of
+ adding network.
+
## 1.0.7-alpha.6
### Patch Changes
diff --git a/packages/walletkit/package.json b/packages/walletkit/package.json
index f4852f70..9d9d1b73 100644
--- a/packages/walletkit/package.json
+++ b/packages/walletkit/package.json
@@ -1,6 +1,6 @@
{
"name": "@totejs/walletkit",
- "version": "1.0.7-alpha.6",
+ "version": "1.0.7",
"author": "node-real",
"private": false,
"description": "WalletKit is a React component library for easily connecting a wallet to your dApp.",