From ab37b6a7294db7f99c861402f6a70610bdc48ca5 Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Wed, 11 Jan 2023 10:36:35 -0700 Subject: [PATCH 1/5] Update new Ledger init options --- docs/src/routes/docs/[...4]wallets/ledger.md | 41 +++----------------- 1 file changed, 6 insertions(+), 35 deletions(-) diff --git a/docs/src/routes/docs/[...4]wallets/ledger.md b/docs/src/routes/docs/[...4]wallets/ledger.md index c509c8568..4ffd3214e 100644 --- a/docs/src/routes/docs/[...4]wallets/ledger.md +++ b/docs/src/routes/docs/[...4]wallets/ledger.md @@ -8,14 +8,14 @@ Wallet module for connecting Ledger hardware wallets to web3-onboard ```sh copy -yarn add @web3-onboard/ledger +yarn add @web3-onboard/core @web3-onboard/ledger ``` ```sh copy -npm install @web3-onboard/ledger +npm install @web3-onboard/core @web3-onboard/ledger ``` @@ -24,40 +24,11 @@ npm install @web3-onboard/ledger ## Options ```typescript -type LedgerOptions = { - customNetwork?: CustomNetwork -} - -interface CustomNetwork { - networkId: number - genesis: GenesisBlock - hardforks: Hardfork[] - bootstrapNodes: BootstrapNode[] -} - -interface GenesisBlock { - hash: string - timestamp: string | null - gasLimit: number - difficulty: number - nonce: string - extraData: string - stateRoot: string -} - -interface Hardfork { - name: string - block: number | null -} - -interface BootstrapNode { - ip: string - port: number | string - network?: string +interface LedgerOptions { chainId?: number - id: string - location: string - comment: string + bridge?: string + infuraId?: string + rpc?: { [chainId: number]: string } } ``` From f21215a2e44861712f4534317e3910be776236f7 Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Wed, 11 Jan 2023 10:40:16 -0700 Subject: [PATCH 2/5] Add Zeal wallet --- docs/yarn.lock | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/docs/yarn.lock b/docs/yarn.lock index 8fb2150dc..d0b5af0ae 100644 --- a/docs/yarn.lock +++ b/docs/yarn.lock @@ -3249,10 +3249,10 @@ tallyho-detect-provider "^1.0.0" tallyho-onboarding "^1.0.2" -"@web3-onboard/torus@^2.2.0-alpha.1": - version "2.2.0-alpha.1" - resolved "https://registry.yarnpkg.com/@web3-onboard/torus/-/torus-2.2.0-alpha.1.tgz#e86498bf9c9151968d33605134e5ac40149512ef" - integrity sha512-6A6gOtcsd+Bcx7pAx5enk7JNsEpq6hmMq40+zJgdmue4MT8BnyNeQM8V/8CWrJKxfQx0IExakiVpVDj303wBhA== +"@web3-onboard/torus@^2.2.0": + version "2.2.0" + resolved "https://registry.yarnpkg.com/@web3-onboard/torus/-/torus-2.2.0.tgz#6a844c99d783bbab2370f87b70f30a4cb8f36f07" + integrity sha512-0iaN3o13p5oCy//3FfEDdbRJnV1Y3QWXLWDTuaxJiYh/Qdj7tc7OORWxfAb3FB94vyaqIFV5jvLK8p7AYoQHmQ== dependencies: "@toruslabs/torus-embed" "1.38.2" "@web3-onboard/common" "^2.2.3" @@ -3272,10 +3272,10 @@ hdkey "^2.0.1" trezor-connect "^8.2.11" -"@web3-onboard/uauth@^2.0.1-alpha.1": - version "2.0.1-alpha.1" - resolved "https://registry.yarnpkg.com/@web3-onboard/uauth/-/uauth-2.0.1-alpha.1.tgz#7cc64fa99d8018688805e6bd7c482940afe3ab79" - integrity sha512-LCVgvF7UZ1VHYoHV8W/hadTXkQQVO+v0H9Ack7olBRuUBAJwcO+6cPe+bflmKhZXanunFwtVwBSeQkPyPqOMmA== +"@web3-onboard/uauth@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@web3-onboard/uauth/-/uauth-2.0.1.tgz#998eff50eb1b0a109d48748a122e7a277229a7fd" + integrity sha512-wSS9E8rpGubKzttDei2RgU+fdGr4u1/wuV36QjFQyf/ADWHbd4EiILs+iRdf0HxG7UBRVtqSDyv1r6uGeIixmg== dependencies: "@ethersproject/providers" "^5.5.0" "@uauth/js" "^2.4.0" @@ -3296,10 +3296,10 @@ "@web3-onboard/common" "^2.2.3" rxjs "^7.5.2" -"@web3-onboard/web3auth@^2.1.4-alpha.1": - version "2.1.4-alpha.1" - resolved "https://registry.yarnpkg.com/@web3-onboard/web3auth/-/web3auth-2.1.4-alpha.1.tgz#4fc916c245669ed298c48aae0797ad7e4197a1a2" - integrity sha512-ipIpXiwIB+trnCTjW/Z+gk8YraGb++QxuET4AP4dpwi/heivHGts64yiuddIxvSTXUipcoUwKjhTjp5GzPMDLw== +"@web3-onboard/web3auth@^2.1.4": + version "2.1.4" + resolved "https://registry.yarnpkg.com/@web3-onboard/web3auth/-/web3auth-2.1.4.tgz#2972914deec9b88ee5619822eebb651087735ff3" + integrity sha512-9G68PwvMhaN/F8pW2drxiGX/C5J/Vq6Vmb+u3XqLezkJjx2fZ15NzwBpnq538ChCQQIOOUE1yaKAZwIqNMDUbw== dependencies: "@web3-onboard/common" "^2.2.3" "@web3auth/base" "^3.3.0" From 687506ccd39a7f344b24330cd927af12903de576 Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Wed, 11 Jan 2023 10:41:31 -0700 Subject: [PATCH 3/5] Add Zeal docs --- docs/src/routes/docs/[...4]wallets/zeal.md | 49 ++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 docs/src/routes/docs/[...4]wallets/zeal.md diff --git a/docs/src/routes/docs/[...4]wallets/zeal.md b/docs/src/routes/docs/[...4]wallets/zeal.md new file mode 100644 index 000000000..5b5d6ac5a --- /dev/null +++ b/docs/src/routes/docs/[...4]wallets/zeal.md @@ -0,0 +1,49 @@ + +# Zeal + +## Wallet module for connecting Zeal to web3-onboard + +See [Zeal](https://www.zeal.app/) for details. + +For any questions or issues related to integration with Zeal wallet do not hesitate to contact our builders via [hi@zeal.app](mailto:hi@zeal.app) OR ping us on twitter [@withzeal](https://twitter.com/withzeal) + +## Install + + + + +```sh copy +yarn add @web3-onboard/core @web3-onboard/zeal +``` + + + + +```sh copy +npm install @web3-onboard/core @web3-onboard/zeal +``` + + + + + +## Usage + +```typescript +import Onboard from '@web3-onboard/core' +import zealWalletModule from '@web3-onboard/zeal' + +// initialize the module with options +const zealWalletSdk = zealWalletModule() + +const onboard = Onboard({ + // ... other Onboard options + wallets: [ + zealWalletModule() + //... other wallets + ] +}) + +const connectedWallets = await onboard.connectWallet() +console.log(connectedWallets) +``` From e549e6b2a116444f67ab422858eee76648e3f386 Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Wed, 11 Jan 2023 10:49:30 -0700 Subject: [PATCH 4/5] Add Phantom docs --- docs/src/routes/docs/[...4]wallets/phantom.md | 47 +++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 docs/src/routes/docs/[...4]wallets/phantom.md diff --git a/docs/src/routes/docs/[...4]wallets/phantom.md b/docs/src/routes/docs/[...4]wallets/phantom.md new file mode 100644 index 000000000..66f62a27d --- /dev/null +++ b/docs/src/routes/docs/[...4]wallets/phantom.md @@ -0,0 +1,47 @@ +# Phantom + +:::admonition type=warning +_Wallet module for connecting Phantom to web3-onboard is still in alpha testing and Phantom Eth mainnet coverage is not fully public yet but will be soon. Please visit the [Official Phantom Site](https://phantom.app/) for more details. +::: + +[Web3-Onboard](https://onboard.blocknative.com/) is an open-source, framework-agnostic JavaScript library to onboard users to web3 apps. This package can be used to integrate [Phantom Wallet](https://phantom.app/) support into Web3-Onboard's "Connect Wallet" modal. With this module the Phantom option will be shown even if the extension is not installed on the users browser or used within the Phantom app. If selected the user will be taken to a download screen and prompted to create a Phantom wallet. For more information on Phantom, please refer to the [Phantom developer docs](https://docs.phantom.app/). + +### Install + + + + +```sh copy +yarn add @web3-onboard/core @web3-onboard/phantom +``` + + + + +```sh copy +npm install @web3-onboard/core @web3-onboard/phantom +``` + + + + +## Usage + +```typescript +import Onboard from '@web3-onboard/core' +import phantomModule from '@web3-onboard/phantom' + +// initialize the module +const phantom = phantomModule() + +const onboard = Onboard({ + // ... other Onboard options + wallets: [ + phantom + //... other wallets + ] +}) + +const connectedWallets = await onboard.connectWallet() +console.log(connectedWallets) +``` From e43b682b8f9b7bad718e516acd2ada756adb8dd3 Mon Sep 17 00:00:00 2001 From: Adam Carpenter Date: Wed, 11 Jan 2023 11:12:40 -0700 Subject: [PATCH 5/5] Add link to appMetaData docs within Getting Started -> Installation - per gh issue --- .../src/routes/docs/[...2]getting-started/[...1]installation.md | 1 + docs/src/routes/docs/[...4]wallets/phantom.md | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/src/routes/docs/[...2]getting-started/[...1]installation.md b/docs/src/routes/docs/[...2]getting-started/[...1]installation.md index e98484ea7..c1e09bb56 100644 --- a/docs/src/routes/docs/[...2]getting-started/[...1]installation.md +++ b/docs/src/routes/docs/[...2]getting-started/[...1]installation.md @@ -69,6 +69,7 @@ const chains = [ #### App Metadata (Optional) You can add metadata about your dapp. +A full definition of `appMetaData` options can be found [here](/docs/modules/core#options) ```ts const appMetadata = { diff --git a/docs/src/routes/docs/[...4]wallets/phantom.md b/docs/src/routes/docs/[...4]wallets/phantom.md index 66f62a27d..79c73e7ab 100644 --- a/docs/src/routes/docs/[...4]wallets/phantom.md +++ b/docs/src/routes/docs/[...4]wallets/phantom.md @@ -1,7 +1,7 @@ # Phantom :::admonition type=warning -_Wallet module for connecting Phantom to web3-onboard is still in alpha testing and Phantom Eth mainnet coverage is not fully public yet but will be soon. Please visit the [Official Phantom Site](https://phantom.app/) for more details. +The module for connecting Phantom to web3-onboard is still in alpha testing and Phantom Eth mainnet coverage is not fully public yet but will be soon. Please visit the [Official Phantom Site](https://phantom.app/) for more details. ::: [Web3-Onboard](https://onboard.blocknative.com/) is an open-source, framework-agnostic JavaScript library to onboard users to web3 apps. This package can be used to integrate [Phantom Wallet](https://phantom.app/) support into Web3-Onboard's "Connect Wallet" modal. With this module the Phantom option will be shown even if the extension is not installed on the users browser or used within the Phantom app. If selected the user will be taken to a download screen and prompted to create a Phantom wallet. For more information on Phantom, please refer to the [Phantom developer docs](https://docs.phantom.app/).