diff --git a/.github/ISSUE_TEMPLATE/BUG.yml b/.github/ISSUE_TEMPLATE/BUG.yml index b3472c21e..24d8d7613 100644 --- a/.github/ISSUE_TEMPLATE/BUG.yml +++ b/.github/ISSUE_TEMPLATE/BUG.yml @@ -6,6 +6,7 @@ assignees: - taylorjdawson - aaronbarnardsound - Adamj1232 + - leightkt body: - type: markdown attributes: diff --git a/.github/ISSUE_TEMPLATE/FEATURE.yml b/.github/ISSUE_TEMPLATE/FEATURE.yml index 37672592f..2f9c99780 100644 --- a/.github/ISSUE_TEMPLATE/FEATURE.yml +++ b/.github/ISSUE_TEMPLATE/FEATURE.yml @@ -6,6 +6,7 @@ assignees: - taylorjdawson - aaronbarnardsound - Adamj1232 + - leightkt body: - type: markdown attributes: diff --git a/.github/workflows/issue-to-notion.yml b/.github/workflows/issue-to-notion.yml index e1ce264d4..a1ada2c06 100644 --- a/.github/workflows/issue-to-notion.yml +++ b/.github/workflows/issue-to-notion.yml @@ -21,12 +21,12 @@ jobs: STATE: ${{ github.event.issue.state }} ISSUE_URL: ${{ github.event.issue.html_url }} TITLE: ${{ github.event.issue.title }} - FLAG: Github + FLAG: Next Sprint DATABASE_NAME: Product STATUS: Backlog # Product Work Board DATABASE_ID: 69f0e513a59d445b87a1baed729c75c5 PROJECT_NAME: web3-onboard # User ids of who to assign the card to in notion: Taylor, Adam, Aaron - NOTION_USER_IDS: f6cbb362-4908-4138-9ef0-434003d9a9f8,8a3a2287-5d2c-4665-906d-02ae9a113340,3b407adf-6552-40de-b22f-5efa852c34a2 + NOTION_USER_IDS: f6cbb362-4908-4138-9ef0-434003d9a9f8,8a3a2287-5d2c-4665-906d-02ae9a113340,3b407adf-6552-40de-b22f-5efa852c34a2,436b76c5-fed3-42d2-b3ca-49bb882843f8 shell: bash diff --git a/assets/notify-custom-example.png b/assets/notify-custom-example.png new file mode 100644 index 000000000..73f4b0e80 Binary files /dev/null and b/assets/notify-custom-example.png differ diff --git a/assets/notify-example.png b/assets/notify-example.png new file mode 100644 index 000000000..ff6a08773 Binary files /dev/null and b/assets/notify-example.png differ diff --git a/assets/notify-preflight-example.png b/assets/notify-preflight-example.png new file mode 100644 index 000000000..8946a8fe8 Binary files /dev/null and b/assets/notify-preflight-example.png differ diff --git a/docs/package.json b/docs/package.json index 3af7f13fb..56d6cef26 100644 --- a/docs/package.json +++ b/docs/package.json @@ -55,7 +55,7 @@ "type": "module", "dependencies": { "@web3-onboard/coinbase": "^2.2.1", - "@web3-onboard/core": "^2.16.0", + "@web3-onboard/core": "^2.16.1", "@web3-onboard/dcent": "^2.2.4", "@web3-onboard/enkrypt": "^2.0.1", "@web3-onboard/fortmatic": "^2.0.16", @@ -76,7 +76,7 @@ "@web3-onboard/trezor": "^2.3.4", "@web3-onboard/trust": "^2.0.1", "@web3-onboard/uauth": "^2.0.2", - "@web3-onboard/walletconnect": "^2.3.3", + "@web3-onboard/walletconnect": "^2.3.4", "@web3-onboard/web3auth": "^2.2.0", "@web3-onboard/xdefi": "^2.0.1", "animejs": "^3.2.1", diff --git a/docs/src/app.html b/docs/src/app.html index b4594e03c..008b56e67 100644 --- a/docs/src/app.html +++ b/docs/src/app.html @@ -2,7 +2,7 @@ - + %sveltekit.head% diff --git a/docs/src/lib/assets/notify-custom-example.png b/docs/src/lib/assets/notify-custom-example.png new file mode 100644 index 000000000..73f4b0e80 Binary files /dev/null and b/docs/src/lib/assets/notify-custom-example.png differ diff --git a/docs/src/lib/assets/notify-example.png b/docs/src/lib/assets/notify-example.png new file mode 100644 index 000000000..ff6a08773 Binary files /dev/null and b/docs/src/lib/assets/notify-example.png differ diff --git a/docs/src/lib/assets/notify-preflight-example.png b/docs/src/lib/assets/notify-preflight-example.png new file mode 100644 index 000000000..8946a8fe8 Binary files /dev/null and b/docs/src/lib/assets/notify-preflight-example.png differ diff --git a/docs/src/routes/docs/[...1]overview/[...1]introduction.md b/docs/src/routes/docs/[...1]overview/[...1]introduction.md index 77d27856d..fcd44d7ef 100644 --- a/docs/src/routes/docs/[...1]overview/[...1]introduction.md +++ b/docs/src/routes/docs/[...1]overview/[...1]introduction.md @@ -33,7 +33,7 @@ Web3-Onboard is the quickest and easiest way to add multi-wallet and multi-chain ### Supported Networks -web3-onboard supports all EVM networks. Supporting a new network is simply a matter of adding its details in the Chains section upon initialization. For more information see [initialization options](https://onboard.blocknative.com/docs/modules/core#options). +web3-onboard supports all EVM networks. Supporting a new network is simply a matter of adding its details in the Chains section upon initialization. For more information see [initialization options](../../docs/modules/core.md#options). - Ethereum - Arbitrum @@ -141,35 +141,35 @@ if (wallets[0]) { Add other wallet modules such as Wallet Connect or Ledger to increase the support and functionality of your web3-onboard implementation. All modules are listed below and can be accessed through the subpages of web3-onboard docs on the left. -We recommend you add the [Core Repo](https://onboard.blocknative.com/docs/modules/core#install) and consider adding the [Injected Wallets](https://onboard.blocknative.com/docs/packages/injected#install) module to get connected with wallets like Metamask, Trust, Coinbase Wallet & more right away. +We recommend you add the [Core Repo](../../docs/modules/core.md#install) and consider adding the [Injected Wallets](../../docs/wallets/injected.md#install) module to get connected with wallets like Metamask, Trust, Coinbase Wallet & more right away. -[**Core Repo**](https://onboard.blocknative.com/docs/modules/core#install) +[**Core Repo**](../../docs/modules/core.md#install) -[**Injected Wallets**](https://onboard.blocknative.com/docs/packages/injected#install) +[**Injected Wallets**](../../docs/wallets/injected.md#install) **SDK Wallets** -- [Coinbase](https://onboard.blocknative.com/docs/packages/coinbase#install) -- [WalletConnect](https://onboard.blocknative.com/docs/packages/walletconnect#install) -- [Gnosis](https://onboard.blocknative.com/docs/packages/gnosis#install) -- [Magic](https://onboard.blocknative.com/docs/packages/magic#login-options) -- [Fortmatic](https://onboard.blocknative.com/docs/packages/formatic#install) -- [MEW](https://onboard.blocknative.com/docs/packages/mew#install) -- [Portis](https://onboard.blocknative.com/docs/packages/portis#install) -- [Web3Auth](https://onboard.blocknative.com/docs/packages/web3auth#install) +- [Coinbase](../../docs/wallets/coinbase.md#install) +- [WalletConnect](../../docs/wallets/walletconnect.md#install) +- [Gnosis](../../docs/wallets/gnosis.md#install) +- [Magic](../../docs/wallets/magic.md#login-options) +- [Fortmatic](../../docs/wallets/formatic.md#install) +- [MEW](../../docs/wallets/mewwallet.md#install) +- [Portis](../../docs/wallets/portis.md#install) +- [Web3Auth](../../docs/wallets/web3auth.md#install) **Hardware Wallets** -- [Ledger](https://onboard.blocknative.com/docs/packages/ledger#install) -- [Trezor](https://onboard.blocknative.com/docs/packages/trezor#install) -- [Keystone](https://onboard.blocknative.com/docs/packages/keystone#install) -- [KeepKey](https://onboard.blocknative.com/docs/packages/keepkey#install) -- [D'cent](https://onboard.blocknative.com/docs/packages/dcent#wallet-module-for-connecting-d-cent-hardware-wallets-to-web3-onboard) +- [Ledger](../../docs/wallets/ledger.md#install) +- [Trezor](../../docs/wallets/trezor.md#install) +- [Keystone](../../docs/wallets/keystone.md#install) +- [KeepKey](../../docs/wallets/keepkey.md#install) +- [D'cent](../../docs/wallets/dcent.md#install) **Frameworks** -- [React](https://onboard.blocknative.com/docs/modules/react#quickstart-with-injected-wallets-and-ethers-provider) -- [Vue](https://onboard.blocknative.com/docs/modules/vue#install) +- [React](../../docs/modules/react.md#quickstart-with-injected-wallets-and-ethers-provider) +- [Vue](../../docs/modules/vue.md#install) ## Test out the demo app diff --git a/docs/src/routes/docs/[...1]overview/[...2]contribution-guide.md b/docs/src/routes/docs/[...1]overview/[...2]contribution-guide.md index 6885e11c9..cbed1ed50 100644 --- a/docs/src/routes/docs/[...1]overview/[...2]contribution-guide.md +++ b/docs/src/routes/docs/[...1]overview/[...2]contribution-guide.md @@ -46,7 +46,7 @@ To add a new wallet to the official Web3 Onboard packages and repo, create a [pu Please also include updates to documentation in your PR. Refer to the [docs contributions section](#documentation-contributions-📄) and the PR template docs checklist. ### Adding Injected Wallets -If the wallet you are adding is an “injected” wallet (browser extension, mobile dapp browser wallet), add a wallet to the injected wallets module. [See here for an example of an injected wallets pull request.](https://github.com/blocknative/web3-onboard/pull/1177/files) You should also add the wallet to the [natively supported injected wallets list](http://localhost:3000/docs/wallets/injected#injected-wallets-supported-natively). +If the wallet you are adding is an “injected” wallet (browser extension, mobile dapp browser wallet), add a wallet to the injected wallets module. [See here for an example of an injected wallets pull request.](https://github.com/blocknative/web3-onboard/pull/1177/files) You should also add the wallet to the [natively supported injected wallets list](../../docs/wallets/injected.md#injected-wallets-supported-natively). ### Adding Wallet Modules Otherwise, if the wallet you are adding requires dependencies and initialization (SDK), then you will need to create a new package in the Web3 Onboard monorepo. [See here for an example of a pull request.](https://github.com/blocknative/web3-onboard/pull/1238/files) @@ -76,4 +76,4 @@ Jump in our [Discord](https://discord.com/invite/KZaBVME) and share your feedbac ## [Support 🤓](#support) -For general questions about how to use Web3 Onboard please first check out our [docs](https://onboard.blocknative.com/docs/overview/introduction#features), then head to our [Discord](https://discord.com/invite/KZaBVME) for support from the Blocknative team. +For general questions about how to use Web3 Onboard please first check out our [docs](../../docs/overview/introduction.md#features), then head to our [Discord](https://discord.com/invite/KZaBVME) for support from the Blocknative team. diff --git a/docs/src/routes/docs/[...3]modules/core.md b/docs/src/routes/docs/[...3]modules/core.md index 53c3e89a7..2852bbfd7 100644 --- a/docs/src/routes/docs/[...3]modules/core.md +++ b/docs/src/routes/docs/[...3]modules/core.md @@ -1,5 +1,8 @@ # Core @@ -219,6 +222,12 @@ type ConnectModalOptions = { * Defaults to `https://ethereum.org/en/wallets/find-wallet/#main-content` */ iDontHaveAWalletLink?: string + /** + * Customize the link for the `Where's My Wallet` info pop up shown on the + * select wallet modal. + * Defaults to `https://www.blocknative.com/blog/metamask-wont-connect-web3-wallet-troubleshooting` + */ + wheresMyWalletLink?: string /** * Define support for Unstoppable Domains resolutions * after a user connects. Similar to ens, uns can be used for users who @@ -266,11 +275,11 @@ Define a custom or predefined theme for Web3Onboard using either: For a complete walkthrough on customizing your theme checkout our [theming documentation](/docs/getting-started/theming) ```typescript -export type Theme = ThemingMap | BuiltInThemes | 'system' +type Theme = ThemingMap | BuiltInThemes | 'system' -export type BuiltInThemes = 'default' | 'dark' | 'light' +type BuiltInThemes = 'default' | 'dark' | 'light' -export type ThemingMap = { +type ThemingMap = { '--w3o-background-color'?: string '--w3o-font-family'?: string '--w3o-foreground-color'?: string @@ -307,7 +316,7 @@ type disableFontDownload = boolean // defaults to false An object that defines whether the account center UI (default and minimal) is enabled and its position on the screen. Currently the account center is enabled for both desktop and mobile devices. ```ts -export type AccountCenter = { +type AccountCenter = { enabled: boolean position?: AccountCenterPosition // default: 'topRight' expanded?: boolean // default: true @@ -320,7 +329,7 @@ export type AccountCenter = { containerElement?: string // defines the DOM container element for svelte to attach } -export type AccountCenterOptions = { +type AccountCenterOptions = { desktop: Omit mobile: Omit } @@ -359,24 +368,57 @@ type ContainerElements = { #### notify -Notify provides by default transaction notifications for all connected wallets on the current blockchain. When switching chains the previous chain listeners remain active for 60 seconds to allow capture and report of remaining transactions that may be in flight. -By default transaction notifications are captured if a DAppID is provided in the Onboard config along with the Account Center being enabled. -An object that defines whether transaction notifications will display (defaults to true if an API key is provided). This object contains an `enabled` flag prop and an optional `transactionHandler` which is a callback that can disable or allow customizations of notifications. -Currently notifications are positioned in the same location as the account center (either below, if the Account Center is positioned along the top, or above if positioned on the bottom of the view). -The `transactionHandler` can react off any property of the Ethereum TransactionData returned to the callback from the event (see console.log in example init). In turn, it can return a Custom `Notification` object to define the verbiage, styling, or add functionality: +Notify is a feature that provides transaction notifications for all connected wallets on the current blockchain. This document will provide you with an overview of Notify and guide you through the process of integrating it into your decentralized application (DApp). + +Transaction notifications image + +To enable transaction notifications and updates simply add your Blocknative `apiKey`([sign up for free](https://explorer.blocknative.com/account)) to the web3-onboard configurations as the value to the `apiKey` prop and thats it! +Transaction notifications will be shown for all transactions occurring on supported chains for all of the users connected wallets. +When switching chains, the previous chain listeners remain active for 60 seconds to allow the capture and report of any remaining transactions that may be in flight. + +Notifications are by default positioned in the same location as the Account Center (if enabled) or can be positioned separately using the `position` property. + +##### **Notify Configuration** + +| Property | Type | Description | +| -------------------- | --------------- | ------------------------------------------------------------- | +| `enabled` | boolean | Indicates whether transaction notifications will be displayed | +| `transactionHandler` | function | Optional callback for customizations of notifications | +| `position` | CommonPositions | Position of the notification on the screen | + +##### **Position Options** + +| Property | Type | Description | +| --------- | ------ | ---------------------------------------- | +| `desktop` | Notify | Configuration for desktop notifications. | +| `mobile` | Notify | Configuration for mobile notifications. | -- `Notification.message` - to completely customize the message shown -- `Notification.eventCode` - handle codes in your own way - see codes here under the notify prop [default en file here](https://github.com/blocknative/web3-onboard/blob/develop/packages/core/src/i18n/en.json) -- `Notification.type` - icon type displayed (see `NotificationType` below for options) -- `Notification.autoDismiss` - time (in ms) after which the notification will be dismissed. If set to `0` the notification will remain on screen until the user dismisses the notification, refreshes the page or navigates away from the site with the notifications -- `Notification.link` - add link to the transaction hash. For instance, a link to the transaction on etherscan -- `Notification.onClick()` - onClick handler for when user clicks the notification element +Both `desktop` and `mobile` configurations are of type `Notify`. -Notify can also be styled by using the CSS variables found below. These are setup to allow maximum customization with base styling variables setting the global theme (i.e. `--onboard-grey-600`) along with more precise component level styling variables available (`--notify-onboard-grey-600`) with the latter taking precedent if defined +###### **Transaction Handler** -If notifications are enabled the notifications can be handled through onboard app state as seen below. +The `transactionHandler` is a callback that receives an object of type `EthereumTransactionData`. Based on the data received, the handler can return a custom `Notification` object or a boolean value (false to disable the notification for the current event or undefined for a default notification). -```js +##### **Customizing Notification** + +| Property | Type | Description | +| ------------- | -------- | ----------------------------------------------------------- | +| `message` | string | Customizes the message shown | +| `eventCode` | string | Allows handling codes in a custom way | +| `type` | string | Represents the icon type displayed | +| `autoDismiss` | number | Time (in ms) after which the notification will be dismissed | +| `link` | string | Adds a link to the transaction hash | +| `onClick` | function | onClick handler for the notification element | + +##### **Styling Notify** + +Notify automatically will match the [`theme`](#theme) defined in the web3-onboard config. It can also be styled using the [exposed css variables provided below](#custom-styling). These variables allow for maximum customization with base styling variables setting the global theme (e.g., `--onboard-grey-600`) and more precise component-level styling variables available (`--notify-onboard-grey-600`). The latter takes precedence if defined. + +##### **Handling Notifications** + +If notifications are enabled, they can be fielded and handled through the onboard app state as seen in the example below - although this is not required for notifications to display: + +```javascript const wallets = onboard.state.select('notifications') const { unsubscribe } = wallets.subscribe((update) => console.log('transaction notifications: ', update) @@ -386,12 +428,15 @@ const { unsubscribe } = wallets.subscribe((update) => unsubscribe() ``` +##### **Notifications as Toast Messages** +The Notifications messages can also be used to send fully customized Dapp toast messages and updated. Check out the [customNotifications API docs for examples and code snippets](#customnotification) + ```ts -export type NotifyOptions = { +type NotifyOptions = { desktop: Notify mobile: Notify } -export type Notify = { +type Notify = { enabled: boolean // default: true /** * Callback that receives all transaction events @@ -403,40 +448,46 @@ export type Notify = { position: CommonPositions } -export type CommonPositions = 'topRight' | 'bottomRight' | 'bottomLeft' | 'topLeft' +type CommonPositions = 'topRight' | 'bottomRight' | 'bottomLeft' | 'topLeft' -export type TransactionHandlerReturn = CustomNotification | boolean | void +type TransactionHandlerReturn = CustomNotification | boolean | void -export type CustomNotification = Partial> +type CustomNotification = Partial> -export type Notification = { +type Notification = { id: string key: string - type: NotificationType network: Network startTime?: number - eventCode: string + /** + * to completely customize the message shown + */ message: string + /** + * handle codes in your own way - see codes here under the notify prop [default en file here](https://github.com/blocknative/web3-onboard/blob/develop/packages/core/src/i18n/en.json) + */ + eventCode: string + /** + * icon type displayed (see `NotificationType` below for options) + */ + type: NotificationType + /** + * time (in ms) after which the notification will be dismissed. If set to `0` the notification will remain on screen until the user dismisses the notification, refreshes the page or navigates away from the site with the notifications + */ autoDismiss: number + /** + * add link to the transaction hash. For instance, a link to the transaction on etherscan + */ link?: string + /** + * onClick handler for when user clicks the notification element + */ onClick?: (event: Event) => void } -export type NotificationType = 'pending' | 'success' | 'error' | 'hint' - -export declare type Network = - | 'main' - | 'testnet' - | 'ropsten' - | 'rinkeby' - | 'goerli' - | 'kovan' - | 'xdai' - | 'bsc-main' - | 'matic-main' - | 'fantom-main' - | 'matic-mumbai' - | 'local' +type NotificationType = 'pending' | 'success' | 'error' | 'hint' + +export declare type Network = 'main' | 'goerli' | 'matic-main' | 'matic-mumbai' | 'local' export interface UpdateNotification { (notificationObject: CustomNotification): { @@ -446,7 +497,9 @@ export interface UpdateNotification { } ``` -### Initialization Example +--- + +## Initialization Example Putting it all together, here is an example initialization with the injected wallet modules: @@ -457,6 +510,8 @@ import injectedModule from '@web3-onboard/injected-wallets' const injected = injectedModule() const onboard = Onboard({ + // head to https://explorer.blocknative.com/account to sign up for free + apiKey: 'xxx387fb-bxx1-4xxc-a0x3-9d37e426xxxx' wallets: [injected], chains: [ { @@ -518,7 +573,6 @@ const onboard = Onboard({ { name: 'Coinbase', url: 'https://wallet.coinbase.com/' } ] }, - apiKey: 'xxx387fb-bxx1-4xxc-a0x3-9d37e426xxxx' notify: { desktop: { enabled: true, @@ -585,6 +639,7 @@ const onboard = Onboard({ }) ``` +--- ## Connecting a Wallet To initiate a user to select and connect a wallet you can call the `connectWallet` function on an initialized Onboard instance. It will return a `Promise` that will resolve when the user either successfully connects a wallet, or when they dismiss the UI. The resolved value from the promise will be the latest state of the `wallets` array. The order of the wallets array is last to first, so the most recently selected wallet will be the first item in the array and can be thought of as the "primary wallet". If no wallet was selected, then the `wallets` array will have the same state as it had before calling `connectWallet`. @@ -884,35 +939,88 @@ onboard.state.actions.updateNotify({ #### **customNotification** +Custom notifications image + Notify can be used to deliver custom DApp notifications by passing a `CustomNotification` object to the `customNotification` action. This will return an `UpdateNotification` type. This `UpdateNotification` will return an `update` function that can be passed a new `CustomNotification` to update the existing notification. The `customNotification` method also returns a `dismiss` method that is called without any parameters to dismiss the notification. -```typescript copy -const { update, dismiss } = onboard.state.actions.customNotification({ - type: 'pending', - message: 'This is a custom DApp pending notification to use however you want', - autoDismiss: 0 -}) -setTimeout( - () => - update({ - eventCode: 'dbUpdateSuccess', - message: 'Updated status for custom notification', - type: 'success', - autoDismiss: 8000 - }), - 4000 -) +| Property | Type | Description | +| ------------- | -------- | ----------------------------------------------------------- | +| `message` | string | Customizes the message shown | +| `eventCode` | string | Allows handling codes in a custom way | +| `type` | string | Represents the icon type displayed | +| `autoDismiss` | number | Time (in ms) after which the notification will be dismissed | +| `link` | string | Adds a link to the transaction hash | +| `onClick` | function | onClick handler for the notification element | + +```javascript copy + + + + + ``` --- #### **preflightNotifications** -Notify can be used to deliver standard notifications along with preflight information by passing a `PreflightNotificationsOptions` object to the `preflightNotifications` action. This will return a promise that resolves to the transaction hash (if `sendTransaction` resolves the transaction hash and is successful), the internal notification id (if no `sendTransaction` function is provided) or return nothing if an error occurs or `sendTransaction` is not provided or doesn't resolve to a string. +Notify can be used to deliver standard notifications along with preflight updates by passing a `PreflightNotificationsOptions` object to the `preflightNotifications` API action. + +Preflight notifications image -Preflight event types include +Preflight event types include: - `txRequest` : Alert user there is a transaction request awaiting confirmation by their wallet - `txAwaitingApproval` : A previous transaction is awaiting confirmation @@ -922,21 +1030,9 @@ Preflight event types include - `txSendFail` : The user rejected the transaction (requires `sendTransaction`) - `txUnderpriced` : The gas price for the transaction is too low (requires `sendTransaction`) -```typescript -interface PreflightNotificationsOptions { - sendTransaction?: () => Promise - estimateGas?: () => Promise - gasPrice?: () => Promise - balance?: string | number - txDetails?: { - value: string | number - to?: string - from?: string - } - txApproveReminderTimeout?: number // defaults to 15 seconds if not specified -} -``` +This API call will return a promise that resolves to the transaction hash (if `sendTransaction` resolves the transaction hash and is successful), the internal notification id (if no `sendTransaction` function is provided) or return nothing if an error occurs or `sendTransaction` is not provided or doesn't resolve to a string. +Example: ```typescript copy const balanceValue = Object.values(balance)[0] // if using ethers v6 this is: @@ -968,6 +1064,21 @@ const transactionHash = await onboard.state.actions.preflightNotifications({ console.log(transactionHash) ``` +```typescript +interface PreflightNotificationsOptions { + sendTransaction?: () => Promise + estimateGas?: () => Promise + gasPrice?: () => Promise + balance?: string | number + txDetails?: { + value: string | number + to?: string + from?: string + } + txApproveReminderTimeout?: number // defaults to 15 seconds if not specified +} +``` + --- #### **updateAccountCenter** diff --git a/docs/src/routes/docs/[...4]wallets/injected.md b/docs/src/routes/docs/[...4]wallets/injected.md index 853152bd9..06a6bc498 100644 --- a/docs/src/routes/docs/[...4]wallets/injected.md +++ b/docs/src/routes/docs/[...4]wallets/injected.md @@ -1,6 +1,6 @@ # Injected Wallets -This module lets web3-onboard automatically detect Browser Injected Wallets such as Metamask or Coinbase Wallet. We recommend you install this module to get the most out of your w3o implementation. This module supports [EIP-1193](https://eips.ethereum.org/EIPS/eip-1193) and [recognizes many injected wallets natively](https://onboard.blocknative.com/docs/packages/injected#injected-wallets-supported-natively). +This module lets web3-onboard automatically detect Browser Injected Wallets such as Metamask or Coinbase Wallet. We recommend you install this module to get the most out of your w3o implementation. This module supports [EIP-1193](https://eips.ethereum.org/EIPS/eip-1193) and [recognizes many injected wallets natively](#injected-wallets-supported-natively). Note: Make sure to install the core module before installing other modules to w3o. diff --git a/docs/src/routes/docs/[...4]wallets/walletconnect.md b/docs/src/routes/docs/[...4]wallets/walletconnect.md index fee5c41c2..3ee0990f7 100644 --- a/docs/src/routes/docs/[...4]wallets/walletconnect.md +++ b/docs/src/routes/docs/[...4]wallets/walletconnect.md @@ -62,6 +62,10 @@ type WalletConnectOptions = { * optional chains for the WalletConnect module */ requiredChains?: number[] | undefined + /** + * `undefined` by default, see https://docs.walletconnect.com/2.0/web3modal/options + */ + qrModalOptions?: Web3ModalConfig } ) ``` diff --git a/docs/static/favicon.png b/docs/static/favicon.png deleted file mode 100644 index b4c800bd9..000000000 Binary files a/docs/static/favicon.png and /dev/null differ diff --git a/docs/yarn.lock b/docs/yarn.lock index 0b7ec5402..c19c94d2d 100644 --- a/docs/yarn.lock +++ b/docs/yarn.lock @@ -1751,11 +1751,6 @@ resolved "https://registry.yarnpkg.com/@hapi/hoek/-/hoek-11.0.2.tgz#cb3ea547daac7de5c9cf1d960c3f35c34f065427" integrity sha512-aKmlCO57XFZ26wso4rJsW4oTUnrgTFw2jh3io7CAtO9w4UltBNwRXvXIVzzyfkaaLRo3nluP/19msA8vDUUuKw== -"@hapi/hoek@^9.0.0": - version "9.3.0" - resolved "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz#8368869dcb735be2e7f5cb7647de78e167a251fb" - integrity sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ== - "@hapi/pinpoint@^2.0.1": version "2.0.1" resolved "https://registry.yarnpkg.com/@hapi/pinpoint/-/pinpoint-2.0.1.tgz#32077e715655fc00ab8df74b6b416114287d6513" @@ -1766,13 +1761,6 @@ resolved "https://registry.yarnpkg.com/@hapi/tlds/-/tlds-1.0.1.tgz#4bf9336918a3a254317eff246898f70600afb666" integrity sha512-OXs5OliWsLTmvzQKZtb3KhfEz30WuuaizwAn95GLfeK+JpGnBxR55lALv3kA4T1RRb3wlrNjnboBg6ur1Czvig== -"@hapi/topo@^5.0.0": - version "5.1.0" - resolved "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz#dc448e332c6c6e37a4dc02fd84ba8d44b9afb012" - integrity sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg== - dependencies: - "@hapi/hoek" "^9.0.0" - "@hapi/topo@^6.0.1": version "6.0.2" resolved "https://registry.yarnpkg.com/@hapi/topo/-/topo-6.0.2.tgz#f219c1c60da8430228af4c1f2e40c32a0d84bbb4" @@ -2363,23 +2351,6 @@ google-protobuf "^3.17.0" long "^4.0.0" -"@sideway/address@^4.1.3": - version "4.1.4" - resolved "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz#03dccebc6ea47fdc226f7d3d1ad512955d4783f0" - integrity sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw== - dependencies: - "@hapi/hoek" "^9.0.0" - -"@sideway/formula@^3.0.0": - version "3.0.1" - resolved "https://registry.yarnpkg.com/@sideway/formula/-/formula-3.0.1.tgz#80fcbcbaf7ce031e0ef2dd29b1bfc7c3f583611f" - integrity sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg== - -"@sideway/pinpoint@^2.0.0": - version "2.0.0" - resolved "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz#cff8ffadc372ad29fd3f78277aeb29e632cc70df" - integrity sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ== - "@socket.io/component-emitter@~3.1.0": version "3.1.0" resolved "https://registry.yarnpkg.com/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz#96116f2a912e0c02817345b3c10751069920d553" @@ -3227,13 +3198,13 @@ "@walletconnect/types" "^1.8.0" "@walletconnect/utils" "^1.8.0" -"@walletconnect/core@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-2.4.10.tgz#8975996b5c47d0d11a1187b3793215678c3ea3af" - integrity sha512-3ZVS07NS9+zG+Mw4MOxYhoJHwCSuIOrq+HuhaTLZZ+NswscZ+GwguF2fTsRNgk4jXkMJodaqUFxfPJeCVVcwHQ== +"@walletconnect/core@2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-2.5.2.tgz#999605a62a3b37867d2559e40b62778534eb787c" + integrity sha512-R0D9NKgHBpdun65q+1L49GOIGDLaIodnyb+Dq0tXGVzvXzy2lkXOlh2e9am61ixaVrUsHt7b96b318geqsuk4Q== dependencies: "@walletconnect/heartbeat" "1.2.0" - "@walletconnect/jsonrpc-provider" "1.0.9" + "@walletconnect/jsonrpc-provider" "1.0.10" "@walletconnect/jsonrpc-utils" "^1.0.4" "@walletconnect/jsonrpc-ws-connection" "1.0.10" "@walletconnect/keyvaluestorage" "^1.0.2" @@ -3242,8 +3213,8 @@ "@walletconnect/relay-auth" "^1.0.4" "@walletconnect/safe-json" "^1.0.1" "@walletconnect/time" "^1.0.2" - "@walletconnect/types" "2.4.10" - "@walletconnect/utils" "2.4.10" + "@walletconnect/types" "2.5.2" + "@walletconnect/utils" "2.5.2" events "^3.3.0" lodash.isequal "4.5.0" pino "7.11.0" @@ -3286,20 +3257,19 @@ dependencies: tslib "1.14.1" -"@walletconnect/ethereum-provider@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/ethereum-provider/-/ethereum-provider-2.4.10.tgz#450167cf3fbfb7813189076f13c0c61e324f8c25" - integrity sha512-anD3inbmuIZgWJ7Km5QP6L/hjI8sK/3Q4WA+g8OlyHS2cqO9sPjYdbPUVnzVgwhTDbNDJr2AUNXmvpm2R0hq5Q== +"@walletconnect/ethereum-provider@2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@walletconnect/ethereum-provider/-/ethereum-provider-2.5.2.tgz#b70c01fc281ae8b6c424fc063bc48b476ef3f83a" + integrity sha512-WEN85tsuHgvoiMK4KpsRsOgsKB0QLCctSwxTqyWDybBbXuJRJGWXkZ6Oma9VSmUR0MgPSjiGmOFgY4ybMlhEMA== dependencies: "@walletconnect/jsonrpc-http-connection" "^1.0.4" "@walletconnect/jsonrpc-provider" "^1.0.6" "@walletconnect/jsonrpc-types" "^1.0.2" "@walletconnect/jsonrpc-utils" "^1.0.4" - "@walletconnect/sign-client" "2.4.10" - "@walletconnect/types" "2.4.10" - "@walletconnect/universal-provider" "2.4.10" - "@walletconnect/utils" "2.4.10" - "@web3modal/standalone" "^2.2.0" + "@walletconnect/sign-client" "2.5.2" + "@walletconnect/types" "2.5.2" + "@walletconnect/universal-provider" "2.5.2" + "@walletconnect/utils" "2.5.2" events "^3.3.0" "@walletconnect/events@^1.0.1": @@ -3341,10 +3311,10 @@ cross-fetch "^3.1.4" tslib "1.14.1" -"@walletconnect/jsonrpc-provider@1.0.9": - version "1.0.9" - resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-provider/-/jsonrpc-provider-1.0.9.tgz#ce5ab64dce6a739110aef204ffeedd668ad343d8" - integrity sha512-8CwmiDW42F+F8Qct13lX2x4lJOsi0mNBtUln3VS6TpWioTaL1VfforC/8ULc3tHXv+SNWwAXn2lCZbDcYhdRcA== +"@walletconnect/jsonrpc-provider@1.0.10": + version "1.0.10" + resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-provider/-/jsonrpc-provider-1.0.10.tgz#8351a06b70faa8f8c0e77dc2c6d9b0190d17d407" + integrity sha512-g0ffPSpY3P6GqGjWGHsr3yqvQUhj7q2k6pAikoXv5XTXWaJRzFvrlbFkSgxziXsBrwrMZn0qvPufvpN4mMZ5FA== dependencies: "@walletconnect/jsonrpc-utils" "^1.0.6" "@walletconnect/safe-json" "^1.0.1" @@ -3478,19 +3448,19 @@ dependencies: tslib "1.14.1" -"@walletconnect/sign-client@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/sign-client/-/sign-client-2.4.10.tgz#727072fcbf0c1f84c5370155f0feb7e711733ca4" - integrity sha512-8yNpRUVvkoFY5sdj7QbW1+g6QWgP8VLy1xVAqWkjLIiPieMA6IQcOpaEih9Bbq55oTOxjeWO9+E+V8/0bNXVvQ== +"@walletconnect/sign-client@2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@walletconnect/sign-client/-/sign-client-2.5.2.tgz#d05df9dce271720fdb75741fb162dcc899e39029" + integrity sha512-eKUnGCVgYqN+6b4gm27ML/064m0c/2hTlTHy6tbUszYtEPTzb+q4fvpnWs6blaOjzc18l8NFwX3c1+MHxVdQUQ== dependencies: - "@walletconnect/core" "2.4.10" + "@walletconnect/core" "2.5.2" "@walletconnect/events" "^1.0.1" "@walletconnect/heartbeat" "1.2.0" "@walletconnect/jsonrpc-utils" "^1.0.4" "@walletconnect/logger" "^2.0.1" "@walletconnect/time" "^1.0.2" - "@walletconnect/types" "2.4.10" - "@walletconnect/utils" "2.4.10" + "@walletconnect/types" "2.5.2" + "@walletconnect/utils" "2.5.2" events "^3.3.0" pino "7.11.0" @@ -3510,18 +3480,6 @@ dependencies: tslib "1.14.1" -"@walletconnect/types@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.4.10.tgz#7f85a761b9d65e192d2f510ce858383f19a340f7" - integrity sha512-AvT3ynXXDXty94SadbjGrqqQA8vB1g9AchHZOakCY/Cfo5etpUFG3PfubWMC1FKe2FPk020nLkc2ghjNxHGGtw== - dependencies: - "@walletconnect/events" "^1.0.1" - "@walletconnect/heartbeat" "1.2.0" - "@walletconnect/jsonrpc-types" "^1.0.2" - "@walletconnect/keyvaluestorage" "^1.0.2" - "@walletconnect/logger" "^2.0.1" - events "^3.3.0" - "@walletconnect/types@2.5.2", "@walletconnect/types@^2.5.2": version "2.5.2" resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.5.2.tgz#b2ad73f9e6e19a90fe372babc9ed461fe27098fe" @@ -3539,27 +3497,27 @@ resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-1.8.0.tgz#3f5e85b2d6b149337f727ab8a71b8471d8d9a195" integrity sha512-Cn+3I0V0vT9ghMuzh1KzZvCkiAxTq+1TR2eSqw5E5AVWfmCtECFkVZBP6uUJZ8YjwLqXheI+rnjqPy7sVM4Fyg== -"@walletconnect/universal-provider@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/universal-provider/-/universal-provider-2.4.10.tgz#24696a2b9267d18a8a84008c5b42c8d5b917e4f0" - integrity sha512-KbRl3ivDGXtycp1qs/p8RvXz0f8VgG8k+NKpD6x9/ibnuuFLRt6UgriLHHCslJ9SSGuGHAeIaWs+kRRDKDNFXQ== +"@walletconnect/universal-provider@2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@walletconnect/universal-provider/-/universal-provider-2.5.2.tgz#f0ec21be16cde5c42f2dc87630add01d2e01acbb" + integrity sha512-R61VL02zvcljwSC+FJVzxGswbN21tokQLG0IQL1tVq30+KfkZOt0y/UxsDNvgHNGleGgfoQZzOWsfSLgp5pcBQ== dependencies: "@walletconnect/jsonrpc-http-connection" "^1.0.4" "@walletconnect/jsonrpc-provider" "^1.0.6" "@walletconnect/jsonrpc-types" "^1.0.2" "@walletconnect/jsonrpc-utils" "^1.0.4" "@walletconnect/logger" "^2.0.1" - "@walletconnect/sign-client" "2.4.10" - "@walletconnect/types" "2.4.10" - "@walletconnect/utils" "2.4.10" + "@walletconnect/sign-client" "2.5.2" + "@walletconnect/types" "2.5.2" + "@walletconnect/utils" "2.5.2" eip1193-provider "1.0.1" events "^3.3.0" pino "7.11.0" -"@walletconnect/utils@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-2.4.10.tgz#1fbae7973008c06209ccf79797f732e44e97ac1c" - integrity sha512-mg01uaGY+DoT5yMVb7eL9zXdXZLRfkz85b63URa6QyfWD0Jbstmviutc5NU2YzzbIuekT3miL4cwPvi0MRklWA== +"@walletconnect/utils@2.5.2", "@walletconnect/utils@^2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-2.5.2.tgz#2ee0a10ea646f3e33e192de4b087a846e03b839f" + integrity sha512-s5bpY5q/RaXMc6LgPp+E7qPbKhrff9TjrLRjN2m9COnt9cERowpQEFrPzWmh10FatRZ7dNrudJ5I/c36nFc+hw== dependencies: "@stablelib/chacha20poly1305" "1.0.1" "@stablelib/hkdf" "1.0.1" @@ -3570,7 +3528,7 @@ "@walletconnect/relay-api" "^1.0.9" "@walletconnect/safe-json" "^1.0.1" "@walletconnect/time" "^1.0.2" - "@walletconnect/types" "2.4.10" + "@walletconnect/types" "2.5.2" "@walletconnect/window-getters" "^1.0.1" "@walletconnect/window-metadata" "^1.0.1" detect-browser "5.3.0" @@ -3590,27 +3548,6 @@ js-sha3 "0.8.0" query-string "6.13.5" -"@walletconnect/utils@^2.5.2": - version "2.5.2" - resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-2.5.2.tgz#2ee0a10ea646f3e33e192de4b087a846e03b839f" - integrity sha512-s5bpY5q/RaXMc6LgPp+E7qPbKhrff9TjrLRjN2m9COnt9cERowpQEFrPzWmh10FatRZ7dNrudJ5I/c36nFc+hw== - dependencies: - "@stablelib/chacha20poly1305" "1.0.1" - "@stablelib/hkdf" "1.0.1" - "@stablelib/random" "^1.0.2" - "@stablelib/sha256" "1.0.1" - "@stablelib/x25519" "^1.0.3" - "@walletconnect/jsonrpc-utils" "^1.0.4" - "@walletconnect/relay-api" "^1.0.9" - "@walletconnect/safe-json" "^1.0.1" - "@walletconnect/time" "^1.0.2" - "@walletconnect/types" "2.5.2" - "@walletconnect/window-getters" "^1.0.1" - "@walletconnect/window-metadata" "^1.0.1" - detect-browser "5.3.0" - query-string "7.1.1" - uint8arrays "^3.1.0" - "@walletconnect/window-getters@1.0.0": version "1.0.0" resolved "https://registry.yarnpkg.com/@walletconnect/window-getters/-/window-getters-1.0.0.tgz#1053224f77e725dfd611c83931b5f6c98c32bfc8" @@ -3638,59 +3575,30 @@ "@walletconnect/window-getters" "^1.0.1" tslib "1.14.1" -"@web3-onboard/coinbase@^2.2.1-alpha.2": - version "2.2.1-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/coinbase/-/coinbase-2.2.1-alpha.2.tgz#0d027c47eb28215e450dced0569688ee87c691a8" - integrity sha512-VQ9WLvvwDAk0zx279LJDj8czU26ZDasef/5JGpXinT+sn9PWp2Wi1B3ITd4kvNaLCE8rnle+d8VFfXXYIsJwvA== +"@web3-onboard/coinbase@^2.2.1": + version "2.2.1" + resolved "https://registry.yarnpkg.com/@web3-onboard/coinbase/-/coinbase-2.2.1.tgz#019492fe4ad565602e0708967bd0a7364b616eed" + integrity sha512-6vlzSAavZ8Xqv6B6wKlgcj86TfrRtGgn5THb3BiFH47IcBrPbtqKpmyAl2jpwjv6mW85gBd7e8wSfP29kK192Q== dependencies: "@coinbase/wallet-sdk" "^3.6.0" - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" -"@web3-onboard/common@^2.2.4-alpha.1": - version "2.2.4-alpha.1" - resolved "https://registry.yarnpkg.com/@web3-onboard/common/-/common-2.2.4-alpha.1.tgz#3d48b9e49136d0f3dfb73916146fa216a5101274" - integrity sha512-qJBZ3SyAX4wFJdjXmpsdg/+sWxOUMa1hksSKVjQkt11LEotsLA2DGcdMbpEOYzsybX+6X2Z3CMY5SzeEQY5DSA== - dependencies: - bignumber.js "^9.1.0" - ethers "5.5.4" - joi "^17.6.1" - -"@web3-onboard/common@^2.3.0-alpha.1": - version "2.3.0-alpha.1" - resolved "https://registry.yarnpkg.com/@web3-onboard/common/-/common-2.3.0-alpha.1.tgz#f55a96d09af83a34b939d2420591e17eb2563c1f" - integrity sha512-9Q2F5kw9/EGapT8rnZPlWixsq88rmDV6Z+Oh/HAR7AnAS1voQc7yhIDOBVAeuIkq/TIYEG/Zv8O9+lGBFLPTlQ== +"@web3-onboard/common@^2.3.0": + version "2.3.0" + resolved "https://registry.yarnpkg.com/@web3-onboard/common/-/common-2.3.0.tgz#22a2314e9e6d58494629c4e6ca35d9ba37f3dac3" + integrity sha512-wFVJ1Sw2dRSRbAwJLmHs9eloRBTfC2N7V2IdKEf8dN1oRhsVgkSYeMYR3Vv27YzjXmzyZUdlEux7Fy2JJqbQCg== dependencies: bignumber.js "^9.1.0" ethers "5.5.4" joi "17.8.1" -"@web3-onboard/core@^2.15.6-alpha.4": - version "2.15.6-alpha.5" - resolved "https://registry.yarnpkg.com/@web3-onboard/core/-/core-2.15.6-alpha.5.tgz#590916721f3a4ea4e798fa8aadd1973045c070e8" - integrity sha512-IJKeCWCy7Vepgh81h2rB2ql3GZG+5AajNV/DDx0R9TzU+OXI5g7KZaNsU7tvmE9T46xg9LxOlipDbATyljdZ8g== +"@web3-onboard/core@^2.16.1-alpha.2": + version "2.16.1-alpha.2" + resolved "https://registry.yarnpkg.com/@web3-onboard/core/-/core-2.16.1-alpha.2.tgz#6679e9bb0bce303fb9649a0f8bb2e50ee182c0c2" + integrity sha512-ZeHYGFmSPctYcV0vP3t4p2L8LtTGUMWYxlBBmzpA5Xd+F7ZIPCJChTpEkrzw0UzV5qJ1MLybVv4oP4En9iew7Q== dependencies: "@unstoppabledomains/resolution" "^8.0" - "@web3-onboard/common" "^2.2.4-alpha.1" - bignumber.js "^9.0.0" - bnc-sdk "^4.6.7" - bowser "^2.11.0" - ethers "5.5.3" - eventemitter3 "^4.0.7" - joi "^17.6.1" - lodash.merge "^4.6.2" - lodash.partition "^4.6.0" - nanoid "^4.0.0" - rxjs "^7.5.5" - svelte "^3.49.0" - svelte-i18n "^3.3.13" - -"@web3-onboard/core@^2.16.0-alpha.1": - version "2.16.0-alpha.1" - resolved "https://registry.yarnpkg.com/@web3-onboard/core/-/core-2.16.0-alpha.1.tgz#62d10c6a3997d5fcaf0830a90eec1f4d8b16c77e" - integrity sha512-kSdrxYxLSwBqsFOs+NcD2IcqGA5teA52aVF0o9UdrViAV81UMvm8k01VU/djWgH8tXXRTz9K9yzCc8L7AnVy6w== - dependencies: - "@unstoppabledomains/resolution" "^8.0" - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" bignumber.js "^9.0.0" bnc-sdk "^4.6.7" bowser "^2.11.0" @@ -3704,255 +3612,240 @@ svelte "^3.49.0" svelte-i18n "^3.3.13" -"@web3-onboard/dcent@^2.2.4-alpha.2": - version "2.2.4-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/dcent/-/dcent-2.2.4-alpha.2.tgz#64a865a3c1dfe6b8ff7bcb798624c89c3f9bd339" - integrity sha512-RK49zSQgfyCUhoDuX2tJCdpY1fkDJjWJAPFf5OcPsKehBTYjHKewCTJ6l6Ja9vpwVVNfUJP9II7CO5RSs+0+BA== +"@web3-onboard/dcent@^2.2.4": + version "2.2.4" + resolved "https://registry.yarnpkg.com/@web3-onboard/dcent/-/dcent-2.2.4.tgz#9c8e2956f3051ea896fef7125af770e668234781" + integrity sha512-ZP9eqlS2LeL4q/Z4Cm3+DW1Gye/p3dGbx7skqhFja7sMmz0mXuBS+7lTpkSGqddgyiG03C7UM+nzHeK5vFnAvg== dependencies: "@ethereumjs/tx" "^3.4.0" "@ethersproject/providers" "^5.5.0" - "@web3-onboard/common" "^2.3.0-alpha.1" - "@web3-onboard/hw-common" "^2.2.0-alpha.1" + "@web3-onboard/common" "^2.3.0" + "@web3-onboard/hw-common" "^2.2.0" eth-dcent-keyring "^0.2.2" -"@web3-onboard/enkrypt@^2.0.1-alpha.2": - version "2.0.1-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/enkrypt/-/enkrypt-2.0.1-alpha.2.tgz#983b1c656f944e615d4812f00482bdfde93588ed" - integrity sha512-B/Rh6UgvviqDlXwa/2knpvCEQFmBAdJG6vRGNuoe0aFgNqzBMXokkBk0H/H9YGMrbR6ZWkVOctZqQhHeYOcW7w== +"@web3-onboard/enkrypt@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@web3-onboard/enkrypt/-/enkrypt-2.0.1.tgz#d3cc71aa81b56e1ffc770b25cdad4858e3d8d4bd" + integrity sha512-i3OK7+geZTbHspOqbyPstH39DiqE+Kd8hxB5CCk0yppcmuk3Nnr0rzDRBtBWuEDy6cm20bIQIgOluhRtQ7IcjQ== dependencies: - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" -"@web3-onboard/fortmatic@^2.0.16-alpha.2": - version "2.0.16-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/fortmatic/-/fortmatic-2.0.16-alpha.2.tgz#97394f67914fb8d92a1b3ba8d13ea7608ef656a5" - integrity sha512-eesDXVjNPtBPPcSBdul+i6Ah5WNGIF9R0UYdpnc8dN8yAil1u8hbiSu8WDOnX3VVF71BAcemM+fe+XM1df2OpA== +"@web3-onboard/fortmatic@^2.0.16": + version "2.0.16" + resolved "https://registry.yarnpkg.com/@web3-onboard/fortmatic/-/fortmatic-2.0.16.tgz#a445438cfb582ff27c69ef95ed80a55b3ebee920" + integrity sha512-dvJjqtDoyao8nMy9yxiFN30XXXRqrm+UeBQyBrpm8dlmrMv2NXgY/o4hOME52QkSz/BlzWFyFVEw1GoTkbpCsw== dependencies: - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" fortmatic "^2.2.1" -"@web3-onboard/gas@^2.1.5-alpha.2": - version "2.1.5-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/gas/-/gas-2.1.5-alpha.2.tgz#0701cb3618b94262a222d2777a81a22e35373ce5" - integrity sha512-gNgxOkOWSQ0zyT0+R5bUiZRr1lnb3Tb95vPa7B+1JYOy+Z1Vl3ha0mHG1G4vENNZqZSV8X+CK1xUFwhvraUC5w== +"@web3-onboard/gas@^2.1.5": + version "2.1.5" + resolved "https://registry.yarnpkg.com/@web3-onboard/gas/-/gas-2.1.5.tgz#bf7fa4cd5a168c78e36dfd39a6113dac5657aa1a" + integrity sha512-sB4a94eYUKr9fI4GmgtqGdAKgAGQqB4i6dDufBq4iBmhUmWfAd1xRK5dY4t2O0ccPbamjzHQM5WRz5Ez/WKzmA== dependencies: - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" joi "17.8.1" rxjs "^7.5.2" -"@web3-onboard/gnosis@^2.1.7-alpha.2": - version "2.1.7-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/gnosis/-/gnosis-2.1.7-alpha.2.tgz#90223293c0a166c0ecc59810df7dd1d634b9687c" - integrity sha512-pGY1DaGazcjz5f0g27+w7RA8qyVvkbohKIArQBEbMHVDYubcwmWzpDbV/ROUzG+PsvYluGCPP8wRyBGa0RpLcA== +"@web3-onboard/gnosis@^2.1.7": + version "2.1.7" + resolved "https://registry.yarnpkg.com/@web3-onboard/gnosis/-/gnosis-2.1.7.tgz#06fb01959afe6f366e0c7dff8012ac1584e97bf0" + integrity sha512-6VZtKA8BB3ce0eNP5hKWvaUSBohPTCtCmCG6c1BIhD4l2iHKPDRcuPlShljT52qwGS/Lt2vy8kPxsKwDuXonnA== dependencies: "@gnosis.pm/safe-apps-provider" "^0.9.2" "@gnosis.pm/safe-apps-sdk" "^6.1.1" - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" -"@web3-onboard/hw-common@^2.2.0-alpha.1": - version "2.2.0-alpha.1" - resolved "https://registry.yarnpkg.com/@web3-onboard/hw-common/-/hw-common-2.2.0-alpha.1.tgz#2b6f4aa85d6e041cc0a3842cf4078816eb17acad" - integrity sha512-pX6e2+aEHXFUCMviQcX2HCQJ6bpZ8SpwPf5gddUJI0L5qI52Pldoy13QGq8fseRCp7SKaq012HP1zYcL8NzloA== +"@web3-onboard/hw-common@^2.2.0": + version "2.2.0" + resolved "https://registry.yarnpkg.com/@web3-onboard/hw-common/-/hw-common-2.2.0.tgz#3e4b22c6b536c1964d44201781eb57a9aafa9cf2" + integrity sha512-sI6XfOSiej7j7eIuUnvTMGuIaAGDvPQ3oXDfrctB4dM+otAR0ceXISol1g+U1yhqgCIFnqyW2hpE7sF1VZ+99A== dependencies: "@ethereumjs/common" "2.6.2" - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" ethers "5.5.4" joi "17.8.1" rxjs "^7.5.2" -"@web3-onboard/infinity-wallet@^2.0.1-alpha.1": - version "2.0.1-alpha.1" - resolved "https://registry.yarnpkg.com/@web3-onboard/infinity-wallet/-/infinity-wallet-2.0.1-alpha.1.tgz#3653c56f62b479ed4705100014dd66f57221ed60" - integrity sha512-rs9z+y4Yk8k0+bweQCc0NgQDCbi9EP5h+7Jjqk5T/2wXzjs+rVt7F/k7+LXfD+6AE/wE6s0xpF6JlKKUDTtgoQ== +"@web3-onboard/infinity-wallet@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@web3-onboard/infinity-wallet/-/infinity-wallet-2.0.1.tgz#401b7847d1423d62f387e1cbaa0cef9a29897f1e" + integrity sha512-IALtHW3DB5SRdA4f3BaF9QzgpIPrG4h/8M2kCT8XdXY6ZJxjmq/mkJkfQzJ90dbXq28Dm8sIyEUKmwhQg1xMOw== dependencies: "@infinitywallet/infinity-connector" "^1.0.6" -"@web3-onboard/injected-wallets@^2.8.3-alpha.2": - version "2.8.3-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/injected-wallets/-/injected-wallets-2.8.3-alpha.2.tgz#bd6cf92a815d13c66a72dc8db1200905e636d795" - integrity sha512-H8dBC+bS6O8xDp7VAGVhnuYuw7WhOXyaUuxt1sy9kfK1U4ddyASLwo8ZK5y+8apDrPCrGF8BSJ5l+s+3vdyweg== +"@web3-onboard/injected-wallets@^2.8.3": + version "2.8.3" + resolved "https://registry.yarnpkg.com/@web3-onboard/injected-wallets/-/injected-wallets-2.8.3.tgz#6614fcebc1c128ccbfb4c4b6cee96ac654fbb402" + integrity sha512-0pi6b4TxKAjJ9edwAF56nl8Bz16c3FvVw2sElBs/lx8+yZIzoc2XMjPlOFFFOTkR8mWNg5vKzDqKN6Xu8lxWTQ== dependencies: - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" joi "17.8.1" lodash.uniqby "^4.7.0" -"@web3-onboard/keepkey@^2.3.4-alpha.2": - version "2.3.4-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/keepkey/-/keepkey-2.3.4-alpha.2.tgz#6280cfb4d7f3eb2bb6ee81e2ac8fc29b31b5a35d" - integrity sha512-/X4XsaNhiIhex6++ROm2FMqs/Ecc6I9ujoYKCzXMPPuYJaPBMr5a1R0E3XYXaNDdgfdvtka+FNJaTEJWr/SRUw== +"@web3-onboard/keepkey@^2.3.4": + version "2.3.4" + resolved "https://registry.yarnpkg.com/@web3-onboard/keepkey/-/keepkey-2.3.4.tgz#50a098159398ab886c15cdde3b6fc5defd21eaf3" + integrity sha512-JDPXUYupc/3US2VGXhSYwm8u+66/TF8gaDD72+KP03RmqHesdT5W07A3AXc0bIMs8pbtfx5w5VbB8i4dMfvfmg== dependencies: "@ethersproject/providers" "^5.5.0" "@shapeshiftoss/hdwallet-core" "^1.15.2" "@shapeshiftoss/hdwallet-keepkey-webusb" "^1.15.2" - "@web3-onboard/common" "^2.3.0-alpha.1" - "@web3-onboard/hw-common" "^2.2.0-alpha.1" + "@web3-onboard/common" "^2.3.0" + "@web3-onboard/hw-common" "^2.2.0" ethereumjs-util "^7.1.3" -"@web3-onboard/keystone@^2.3.4-alpha.2": - version "2.3.4-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/keystone/-/keystone-2.3.4-alpha.2.tgz#0bd8553d91edeb388b66567a9f867f0c5c633987" - integrity sha512-H5zTyypvxDo6wSqDVRSJD68vAMLRlM89LH1gIiq0aBUtxrNi/+7b4l7HcBkBZwkh9M4xLMl+WZhhnZlyzRn74g== +"@web3-onboard/keystone@^2.3.4": + version "2.3.4" + resolved "https://registry.yarnpkg.com/@web3-onboard/keystone/-/keystone-2.3.4.tgz#2436d1916d2134b04495967d8ad46fafd4f4f0fa" + integrity sha512-4wn1q343XJEwBnERHRRyLDlWQX+1dQ1cEKAcub7vR6pjcqyIEOxvHwUD23gUW+glO1YQt06zzhXEM2bE1lH52A== dependencies: "@ethereumjs/tx" "^3.4.0" "@ethersproject/providers" "^5.5.0" "@keystonehq/eth-keyring" "^0.14.00.3" - "@web3-onboard/common" "^2.3.0-alpha.1" - "@web3-onboard/hw-common" "^2.2.0-alpha.1" + "@web3-onboard/common" "^2.3.0" + "@web3-onboard/hw-common" "^2.2.0" -"@web3-onboard/ledger@^2.4.3-alpha.2": - version "2.4.3-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/ledger/-/ledger-2.4.3-alpha.2.tgz#623e7615c802cf84288388add391efc5ab35f24b" - integrity sha512-sLqVaU2KzidqlenI7+TDCSDDVvSFwWlTAlbcPv8IjNcQ3iG4U2gzNxH6npthtkGCHxjq7ZUywTS/yIOcBqlZbQ== +"@web3-onboard/ledger@^2.4.3": + version "2.4.3" + resolved "https://registry.yarnpkg.com/@web3-onboard/ledger/-/ledger-2.4.3.tgz#f76203731e10f74ef393a57a101a981b0579a295" + integrity sha512-rRMpggy1KvGOBe2ZczlQ0+3THiSnoE/voTK2nGiree+vyEGWF/oYI+tltlNgMbwot8kYCZqsI7CPgJ1vZg48/Q== dependencies: "@ethersproject/providers" "^5.5.0" "@ledgerhq/connect-kit-loader" "^1.0.2" "@walletconnect/client" "^1.7.1" - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" rxjs "^7.5.2" -"@web3-onboard/magic@^2.1.4-alpha.2": - version "2.1.4-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/magic/-/magic-2.1.4-alpha.2.tgz#31ef4635890861f15338d6e5be445c14d12aec67" - integrity sha512-xUU/DDRuJOOl55B6T8mvvakdpwr380RjTd2VQjtxxkkdHCU1BSV6DTrjAhN26XcPIVS566kEwFbNUR/ZB0bWdA== +"@web3-onboard/magic@^2.1.4": + version "2.1.4" + resolved "https://registry.yarnpkg.com/@web3-onboard/magic/-/magic-2.1.4.tgz#0e7bcce8252f32b490395f35678d7e9bb7b0e440" + integrity sha512-i6buxo8A5Ov5B0ZJi8+NpxfkRgmbuJnRvB9e+iXrR89RfCJU5Xjh5nxfuwsF479qwRShIDSRjP5JLW5dpmCzAA== dependencies: - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" joi "17.8.1" magic-sdk "^8.1.0" rxjs "^7.5.2" -"@web3-onboard/mew-wallet@^2.0.1-alpha.2": - version "2.0.1-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/mew-wallet/-/mew-wallet-2.0.1-alpha.2.tgz#0b231cd400c323a92fbf4eabaef9e8e60f92d4e1" - integrity sha512-bg6OmkZ0vvLlmPH1AjzADsg9vAcK3UNlX1IbccUKnmMTbaWhalMCvShO5x6Kds2doV5cq+RUwUfeVl+eZUssOg== +"@web3-onboard/mew-wallet@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@web3-onboard/mew-wallet/-/mew-wallet-2.0.1.tgz#9cfdde35ceec42c4acb06511d47cb05eadc9109d" + integrity sha512-SnpWEkCgYbuhHniJF6SqU5G/UySLZuZopLxRraC+WPnrdJKdZK2XgM/Z1DBk0AQPJcOdaZbsvv97eHDe0u32Ng== dependencies: - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" lodash.uniqby "^4.7.0" -"@web3-onboard/portis@^2.1.4-alpha.2": - version "2.1.4-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/portis/-/portis-2.1.4-alpha.2.tgz#625aae831686210a193135826783e6fd0860db40" - integrity sha512-y1wWpsz9vuwSIZ6TndTbetp55LCMybHuj9FyTLJLcCFIawEtjCIuPG5ao0LP9T/D/0we7VtpBGcOFF9X0VBH5A== +"@web3-onboard/portis@^2.1.4": + version "2.1.4" + resolved "https://registry.yarnpkg.com/@web3-onboard/portis/-/portis-2.1.4.tgz#1ce626c18e41430246229f504597af2b166e0d1e" + integrity sha512-IAB3B98RSgTOFR/fhhGBlJNlxR1xYXLE/sXfFuSKkSqAoORBfoKA8GIRWjuqxbD3hmrUa1PdHsYBt+vX4dDOQA== dependencies: "@portis/web3" "^4.0.6" - "@web3-onboard/common" "^2.3.0-alpha.1" - -"@web3-onboard/react@^2.7.0-alpha.1": - version "2.7.0-alpha.1" - resolved "https://registry.yarnpkg.com/@web3-onboard/react/-/react-2.7.0-alpha.1.tgz#ae0152b4bf97637aa96b813e5454dec785211a05" - integrity sha512-wGX1pOaVuUjkUJf9CPLBzhy711kTX9GonHYzM24M0Ik+NdaDFpd2AhqKisU2+EA/3xkfH4LVVgoecgD9bYMgLg== - dependencies: - "@web3-onboard/common" "^2.3.0-alpha.1" - "@web3-onboard/core" "^2.16.0-alpha.1" - use-sync-external-store "1.0.0" + "@web3-onboard/common" "^2.3.0" -"@web3-onboard/sequence@^2.0.5-alpha.2": - version "2.0.5-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/sequence/-/sequence-2.0.5-alpha.2.tgz#7dac9307c5916869c07323bc12b7d7393a1f0bbe" - integrity sha512-gBHel3lp6mqqh0YWHyuH6NHmXZNsV5QBWbfKP/fYB2LMadmOg4YPMtvjrpfXCTTiVXazpGY2zueICztBFeRp0g== +"@web3-onboard/sequence@^2.0.5": + version "2.0.5" + resolved "https://registry.yarnpkg.com/@web3-onboard/sequence/-/sequence-2.0.5.tgz#9cee995035e0f750206a2c402e11446df45243a7" + integrity sha512-F+KApsSZKJRMluGd0+v5uJuM2DoYN0aNY6Y5CbIft2j/nbbNs+JiKYTVl549EoAMb4oHCErV3yw1gI+Yhj9tpA== dependencies: "0xsequence" "^0.43.1" - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" -"@web3-onboard/taho@^2.0.1-alpha.2": - version "2.0.1-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/taho/-/taho-2.0.1-alpha.2.tgz#1d0b2c581ca4652a2dfecfb22c41244c4df7d56d" - integrity sha512-x07Cara9hGe0c4f38xNsHhacoab760rwmU+MTlWCRH+zeo7Ny5sJ8tWfi/czBVC7P8J3SYZhNWv271n7OUTJDQ== +"@web3-onboard/taho@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@web3-onboard/taho/-/taho-2.0.1.tgz#96d38e850d860e7800573155b226647e61c1bfce" + integrity sha512-rEetTMuwZ/XJJQnOo48ihlmDUcSUGNYMDxrRlwpPegy6pTALc1Zhf3pHSdG5t7dUGE5OhntKSg8nwIL1AqpHpQ== dependencies: - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" tallyho-detect-provider "^1.0.0" tallyho-onboarding "^1.0.2" -"@web3-onboard/torus@^2.2.2-alpha.2": - version "2.2.2-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/torus/-/torus-2.2.2-alpha.2.tgz#16d56853076500fd8abc6b9a3a996748adbc8297" - integrity sha512-T+6S+yOHObzRKSsTyZ6RbZyHDlWzVpY6PL6s/PirPgS2zXK8UwXBtwDbH8zitITbhU6rZcZUNXJSpwaJ0JKo3A== +"@web3-onboard/torus@^2.2.2": + version "2.2.2" + resolved "https://registry.yarnpkg.com/@web3-onboard/torus/-/torus-2.2.2.tgz#7e77b43ce2fc16d5ed5f561383d10bd2d826445d" + integrity sha512-WBrE73W6Jw+EqAAcM4r9hfqxiMQ1X+I5Cp67ikApY+ArpN5s0+93rocn9frcyR7ol39kmigGgXsRtKmPS2Q/rw== dependencies: "@toruslabs/torus-embed" "1.38.2" - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" -"@web3-onboard/transaction-preview@^2.0.5-alpha.1": - version "2.0.5-alpha.1" - resolved "https://registry.yarnpkg.com/@web3-onboard/transaction-preview/-/transaction-preview-2.0.5-alpha.1.tgz#ae34adc8d7dabe61097148076d37d03533da343d" - integrity sha512-cwZkwoAH8htL7E3licli7Q8HUEj3y6iN5/sO5KB+LCKsR3eXh+686C6xI1MTRJQgXGeGC70+C8g5rrXdDtf3tQ== +"@web3-onboard/transaction-preview@^2.0.5": + version "2.0.5" + resolved "https://registry.yarnpkg.com/@web3-onboard/transaction-preview/-/transaction-preview-2.0.5.tgz#12c7e0b813524a1f2b56a3ef6e1467cc3184a05e" + integrity sha512-pQkR5Afg0SuxGzznmb7A/NQ/cZqEGfhAmNrrqLTF/Iw8v97OLPzELUnjuTj93bpiSTjzxPY+b1LP083QCe6Byw== dependencies: - "@web3-onboard/common" "^2.2.4-alpha.1" + "@web3-onboard/common" "^2.3.0" bnc-sdk "^4.6.7" bowser "^2.11.0" - joi "^17.6.1" + joi "17.8.1" rxjs "^7.5.2" svelte "^3.49.0" svelte-i18n "^3.3.13" -"@web3-onboard/trezor@^2.3.4-alpha.2": - version "2.3.4-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/trezor/-/trezor-2.3.4-alpha.2.tgz#750bc40ee56e2245dab0112e7c6b10884683f993" - integrity sha512-+/uzRpCEUoHbh+/TlbReIKt39oFqdbnJ25z+sm1d1pZPAJfN+J/GLO5QTdADRWl++QI4LsYs4d5lbbKyAvnjWQ== +"@web3-onboard/trezor@^2.3.4": + version "2.3.4" + resolved "https://registry.yarnpkg.com/@web3-onboard/trezor/-/trezor-2.3.4.tgz#6495ed7444ebc30c6705aa2695a9f531a4af1039" + integrity sha512-MsQE+4jQ3rNDO+qYrkwR0AxDoNbRDLBssCuumrbFinfg/ZrzxmmtRwP9OZKKmV/7ggjBgh+N0TcVi/cbmcOqkw== dependencies: "@ethereumjs/tx" "^3.4.0" "@ethersproject/providers" "^5.5.0" - "@web3-onboard/common" "^2.3.0-alpha.1" - "@web3-onboard/hw-common" "^2.2.0-alpha.1" + "@web3-onboard/common" "^2.3.0" + "@web3-onboard/hw-common" "^2.2.0" buffer "^6.0.3" eth-crypto "^2.1.0" ethereumjs-util "^7.1.3" hdkey "^2.0.1" trezor-connect "^8.2.11" -"@web3-onboard/trust@^2.0.1-alpha.2": - version "2.0.1-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/trust/-/trust-2.0.1-alpha.2.tgz#e81cd8a50bcd84584e9798a524930c5018a81760" - integrity sha512-btwzB3pgL1idYqXvlYyA9D9g+czarD23pGVD8oUTNvMPzr+bsqyAZI4XTyrWp1WkxIFWQRD0vaLH2oC+Mpf+Xg== +"@web3-onboard/trust@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@web3-onboard/trust/-/trust-2.0.1.tgz#627d486b27a3bde2f0d732a3a1be046bbaf81ef7" + integrity sha512-kTnvg6mr1+H7OjddbFXmh+fyidne8+xUwo0zfEZ959xFL1l8L1vf5out/q8Lc8ohAc2A51x5im/JNj/EcCoP5w== dependencies: - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" -"@web3-onboard/uauth@^2.0.2-alpha.2": - version "2.0.2-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/uauth/-/uauth-2.0.2-alpha.2.tgz#1490f7354e18e035a82ab449cf97558715ae21e1" - integrity sha512-L55oIhQClQg/RAMe0vjQjEJ4nIpjF3gwX9MTXJECNlKXuQUsRGGNXNRFguhadIIKVvffeNsVq9CAlXrj40n0Gg== +"@web3-onboard/uauth@^2.0.2": + version "2.0.2" + resolved "https://registry.yarnpkg.com/@web3-onboard/uauth/-/uauth-2.0.2.tgz#955408a827b2ae09fc4b3b6591c870fb307c1d5c" + integrity sha512-h24CeCJSk/bZNzrs/xTTxd0lxZoZaa2gkVMlCCeq4R6DpYgdUpW4vVYV0toDXtbeiTUOMY5RvhZwsiYrXI2hZw== dependencies: "@ethersproject/providers" "^5.5.0" "@uauth/js" "^2.4.0" "@walletconnect/client" "^1.7.1" "@walletconnect/qrcode-modal" "^1.7.1" - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" joi "17.8.1" rxjs "^7.5.2" -"@web3-onboard/walletconnect@^2.3.3-alpha.2": - version "2.3.3-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/walletconnect/-/walletconnect-2.3.3-alpha.2.tgz#669b25ed8012be8b7e8f9a6aed9296b7b688d084" - integrity sha512-m2R7ub7IvS6k8EVqy5gxqaNOGh1VTcx+Y8zt3mvp0RyqPy+j27fTG2tlpRe47D5lxndier6wBR1MfB26AZhU2g== +"@web3-onboard/walletconnect@^2.3.4-alpha.1": + version "2.3.4-alpha.2" + resolved "https://registry.yarnpkg.com/@web3-onboard/walletconnect/-/walletconnect-2.3.4-alpha.2.tgz#ce9d6e106f2ed4d5faa43d44796e23e56abf7d3a" + integrity sha512-pz7scUS9275YJYk/maWGKHtF3Xib662WXa39qaziMNsiPjyAn6Ngl4wDG/LFg9UwC2+1xcAaAW/MZS1LeaDCCQ== dependencies: "@ethersproject/providers" "^5.5.0" "@walletconnect/client" "^1.8.0" - "@walletconnect/ethereum-provider" "2.4.10" + "@walletconnect/ethereum-provider" "2.5.2" "@walletconnect/qrcode-modal" "^1.8.0" - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" + "@web3modal/standalone" "^2.2.2" rxjs "^7.5.2" -"@web3-onboard/web3auth@^2.2.0-alpha.2": - version "2.2.0-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/web3auth/-/web3auth-2.2.0-alpha.2.tgz#16d6178098fab93a429369188fa3235ed51d8917" - integrity sha512-zVWSOc16RDNyM3DscC6pYTL3eW9h5z1Ji/NqsHGsZsVzKFp7xdDspgr5MFFSYFQsKRIishdcfAN8G9LcTp0Bgg== +"@web3-onboard/web3auth@^2.2.0": + version "2.2.0" + resolved "https://registry.yarnpkg.com/@web3-onboard/web3auth/-/web3auth-2.2.0.tgz#78f64fb99c1e1c0bea623c4a12751e69eea56332" + integrity sha512-m7YT3uGys9Z/KycAlZzaoPAxQVMcIdei93PknsmAxHYQHwmQdjF3j1LmYaXeMxv1putxSUY6SSZOmHFWY4mdJw== dependencies: "@solana/web3.js" "^1.73.0" - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" "@web3auth/base" "^5.0.1" "@web3auth/modal" "^5.0.1" react-dom "^18.2.0" -"@web3-onboard/xdefi@^2.0.1-alpha.1": - version "2.0.1-alpha.1" - resolved "https://registry.yarnpkg.com/@web3-onboard/xdefi/-/xdefi-2.0.1-alpha.1.tgz#410f36be1624501347fbb11a2a62379897489f3b" - integrity sha512-dknvthq387YHA75nw/KXQBRHVaw7WmyGQhgZsfT8LG+1V30hu9akdVAWGqXIZbtqb87dxbG6gZdjhsriAXAzJg== - dependencies: - "@web3-onboard/common" "^2.2.4-alpha.1" - -"@web3-onboard/zeal@^2.0.1-alpha.2": - version "2.0.1-alpha.2" - resolved "https://registry.yarnpkg.com/@web3-onboard/zeal/-/zeal-2.0.1-alpha.2.tgz#395fb8e3b554f23f138467463cd5535aa008daa4" - integrity sha512-h5iMLIC8cuuRGZ2RHHuYTR1xR2CcAR2Eeh7gEmdXUYkUXy8ikKnyePdaFHOW0JlnFfLI0SSAnnZ1h2Q5IRTOWg== +"@web3-onboard/xdefi@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@web3-onboard/xdefi/-/xdefi-2.0.1.tgz#1fc1e873c93f214c4f261ef9378645338abbdd07" + integrity sha512-C0z5sLu8rIids5euSZHDZCPNCbNuYzdXkm8NrECTmmCIbe8/2DuLBY9QjPDVr5fQHoZM1k6CthmjXfnnE0kA6g== dependencies: - "@web3-onboard/common" "^2.3.0-alpha.1" + "@web3-onboard/common" "^2.3.0" "@web3-react/abstract-connector@^6.0.7": version "6.0.7" @@ -4154,28 +4047,28 @@ "@web3auth/base-evm-adapter" "^5.1.0" "@web3auth/ethereum-provider" "^5.1.0" -"@web3modal/core@2.2.0": - version "2.2.0" - resolved "https://registry.yarnpkg.com/@web3modal/core/-/core-2.2.0.tgz#847459e1ab1766f312c39715270a7ca0fe831666" - integrity sha512-Kafg/KtK6S9x0Ofcaq9hj7dRK5/541nM+LnayPmHxx4fSrDgcM9YYhL12fI4BG1xGOJwkeZjgFOtS0qf123Cjw== +"@web3modal/core@2.2.2": + version "2.2.2" + resolved "https://registry.yarnpkg.com/@web3modal/core/-/core-2.2.2.tgz#1e282dc45bddb11c04f1c93abce570bac1b9a620" + integrity sha512-RKbYNIEVP5Hwiva68PWXExbkTFLUTasneyRpcjoQSM4BIh78qXp1YMt0nyTvFdHmHQEGxXEMCuRG5qoE97uMHA== dependencies: buffer "6.0.3" - valtio "1.9.0" + valtio "1.10.3" -"@web3modal/standalone@^2.2.0": - version "2.2.0" - resolved "https://registry.yarnpkg.com/@web3modal/standalone/-/standalone-2.2.0.tgz#9f81ed976dd16bd795f902503065f75c9160eab3" - integrity sha512-cLFW4VamSJ7L4sM5OGmr1SHK3FgyLUMEaacvHsCA3XSvUF0LxbMC+N4uBsONrW4c0JyIjTdeii1GqG4B3jwn7Q== +"@web3modal/standalone@^2.2.2": + version "2.2.2" + resolved "https://registry.yarnpkg.com/@web3modal/standalone/-/standalone-2.2.2.tgz#2d5ce74bbb7f112b31da32049620afa75c4a4686" + integrity sha512-c05kkTFNGZqnjJ3n2C8uo+wWL6ut1jexGYAyTvbweDengdsOr8LDo0VpK5V3XSKCV2fFcPh5JE9H1aA4jpnZPg== dependencies: - "@web3modal/core" "2.2.0" - "@web3modal/ui" "2.2.0" + "@web3modal/core" "2.2.2" + "@web3modal/ui" "2.2.2" -"@web3modal/ui@2.2.0": - version "2.2.0" - resolved "https://registry.yarnpkg.com/@web3modal/ui/-/ui-2.2.0.tgz#2837da46706f1a3fcdf2f2c22e7ed029e235a3ab" - integrity sha512-jcV5C9AuMdsFdf6Ljsr0v2lInu8FJJyXcZPaMHkgYNIczzgMEpDE+UOA7hLnyCTUxM9R0AgRcgfTyMWb9H8Ssw== +"@web3modal/ui@2.2.2": + version "2.2.2" + resolved "https://registry.yarnpkg.com/@web3modal/ui/-/ui-2.2.2.tgz#f1c1ac908230d4214c35891a5d922c118353eaf2" + integrity sha512-PAuMOuk4sZ4UGjucGMZKzu6Qu56XtFsgLaqOn8ZgP2RkZmYEBGSG9mUQVzJd3XzfzAy1T91Wmqp/3TI3m0pXuQ== dependencies: - "@web3modal/core" "2.2.0" + "@web3modal/core" "2.2.2" lit "2.6.1" motion "10.15.5" qrcode "1.5.1" @@ -7524,17 +7417,6 @@ joi@17.8.1: "@hapi/tlds" "^1.0.1" "@hapi/topo" "^6.0.1" -joi@^17.6.1: - version "17.6.3" - resolved "https://registry.yarnpkg.com/joi/-/joi-17.6.3.tgz#b8e9e143f0188884563e6de50f8b23ddcd3cb2f5" - integrity sha512-YlQsIaS9MHYekzf1Qe11LjTkNzx9qhYluK3172z38RxYoAUf82XMX1p1DG1H4Wtk2ED/vPdSn9OggqtDu+aTow== - dependencies: - "@hapi/hoek" "^9.0.0" - "@hapi/topo" "^5.0.0" - "@sideway/address" "^4.1.3" - "@sideway/formula" "^3.0.0" - "@sideway/pinpoint" "^2.0.0" - jose@^4.5.0: version "4.11.1" resolved "https://registry.yarnpkg.com/jose/-/jose-4.11.1.tgz#8f7443549befe5bddcf4bae664a9cbc1a62da4fa" @@ -8854,10 +8736,10 @@ protocol-buffers-schema@3.1.0: resolved "https://registry.yarnpkg.com/protocol-buffers-schema/-/protocol-buffers-schema-3.1.0.tgz#d8a819549ead3e6bd189ebe9e50e96636bbc5cc7" integrity sha512-1g9zFjLFhGN1Dc5UVO8D2loVslp6sVxk5sJqgD66CuWUITh2gOaTLRN/pIakGFfB6e0nNF6hImrYFDurEsA1UQ== -proxy-compare@2.4.0: - version "2.4.0" - resolved "https://registry.yarnpkg.com/proxy-compare/-/proxy-compare-2.4.0.tgz#90f6abffe734ef86d8e37428c5026268606a9c1b" - integrity sha512-FD8KmQUQD6Mfpd0hywCOzcon/dbkFP8XBd9F1ycbKtvVsfv6TsFUKJ2eC0Iz2y+KzlkdT1Z8SY6ZSgm07zOyqg== +proxy-compare@2.5.0: + version "2.5.0" + resolved "https://registry.yarnpkg.com/proxy-compare/-/proxy-compare-2.5.0.tgz#0387c5e4d283ba9b1c0353bb20def4449b06bbd2" + integrity sha512-f1us0OsVAJ3tdIMXGQx2lmseYS4YXe4W+sKF5g5ww/jV+5ogMadPt+sIZ+88Ga9kvMJsrRNWzCrKPpr6pMWYbA== prr@~1.0.1: version "1.0.1" @@ -10266,11 +10148,6 @@ url@^0.11.0: punycode "1.3.2" querystring "0.2.0" -use-sync-external-store@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/use-sync-external-store/-/use-sync-external-store-1.0.0.tgz#d98f4a9c2e73d0f958e7e2d2c2bfb5f618cbd8fd" - integrity sha512-AFVsxg5GkFg8GDcxnl+Z0lMAz9rE8DGJCc28qnBuQF7lac57B5smLcT37aXpXIIPz75rW4g3eXHPjhHwdGskOw== - use-sync-external-store@1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz#7dbefd6ef3fe4e767a0cf5d7287aacfb5846928a" @@ -10324,12 +10201,12 @@ v8-compile-cache@^2.0.3: resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz#2de19618c66dc247dcfb6f99338035d8245a2cee" integrity sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA== -valtio@1.9.0: - version "1.9.0" - resolved "https://registry.yarnpkg.com/valtio/-/valtio-1.9.0.tgz#d5d9f664319eaf18dd98f758d50495eca28eb0b8" - integrity sha512-mQLFsAlKbYascZygFQh6lXuDjU5WHLoeZ8He4HqMnWfasM96V6rDbeFkw1XeG54xycmDonr/Jb4xgviHtuySrA== +valtio@1.10.3: + version "1.10.3" + resolved "https://registry.yarnpkg.com/valtio/-/valtio-1.10.3.tgz#273eda9ba6459869798b4f58c84514e18fb80ed8" + integrity sha512-t3Ez/+baJ+Z5tIyeaI6nCAbW/hrmcq2jditwg/X++o5IvCdiGirQKTOv1kJq0glgUo13v5oABCVGcinggBfiKw== dependencies: - proxy-compare "2.4.0" + proxy-compare "2.5.0" use-sync-external-store "1.2.0" varint@5.0.0: @@ -10899,4 +10776,4 @@ yn@3.1.1: yocto-queue@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b" - integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q== + integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q== \ No newline at end of file diff --git a/examples/with-sveltekit/package.json b/examples/with-sveltekit/package.json index 13e69161b..635211de7 100644 --- a/examples/with-sveltekit/package.json +++ b/examples/with-sveltekit/package.json @@ -32,7 +32,7 @@ "type": "module", "dependencies": { "@fontsource/fira-mono": "^4.5.10", - "@web3-onboard/core": "^2.15.6-alpha.3", + "@web3-onboard/core": "^2.16.1-alpha.2", "@web3-onboard/injected-wallets": "^2.8.3-alpha.1", "@web3-onboard/walletconnect": "^2.3.3-alpha.1", "buffer": "^6.0.3" diff --git a/package.json b/package.json index 04b5bc9f7..4c66d6760 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "web3-onboard-monorepo", - "version": "2.21.0", + "version": "2.21.1", "private": true, "workspaces": { "packages": [ diff --git a/packages/core/README.md b/packages/core/README.md index cc8262048..a34d03d29 100644 --- a/packages/core/README.md +++ b/packages/core/README.md @@ -74,7 +74,8 @@ type InitOptions = { accountCenter?: AccountCenterOptions /** * Opt in to Blocknative value add services (transaction updates) by providing - * your Blocknative API key, head to https://explorer.blocknative.com/account + * your Blocknative API key, head to https://explorer.blocknative.com/account to sign + * up for free */ apiKey?: string /** @@ -198,6 +199,12 @@ type ConnectModalOptions = { * Defaults to `https://ethereum.org/en/wallets/find-wallet/#main-content` */ iDontHaveAWalletLink?: string + /** + * Customize the link for the `Where's My Wallet` info pop up shown on the + * select wallet modal. + * Defaults to `https://www.blocknative.com/blog/metamask-wont-connect-web3-wallet-troubleshooting` + */ + wheresMyWalletLink?: string /** * Define support for Unstoppable Domains resolutions * after a user connects. Similar to ens, uns can be used for users who @@ -219,9 +226,9 @@ Define a custom or predefined theme for Web3Onboard using either: Note: `system` will default to the theme set by the users system. ```typescript -export type Theme = ThemingMap | BuiltInThemes | 'system' -export type BuiltInThemes = 'default' | 'dark' | 'light' -export type ThemingMap = { +type Theme = ThemingMap | BuiltInThemes | 'system' +type BuiltInThemes = 'default' | 'dark' | 'light' +type ThemingMap = { '--w3o-background-color'?: string '--w3o-font-family'?: string '--w3o-foreground-color'?: string @@ -301,35 +308,60 @@ type AccountCenterPosition = ``` **`notify`** -Notify provides by default transaction notifications for all connected wallets on the current blockchain. When switching chains the previous chain listeners remain active for 60 seconds to allow capture and report of an remaining transactions that may be in flight. -By default transaction notifications are captured if a DAppID is provided in the Onboard config along with the Account Center being enabled. -An object that defines whether transaction notifications will display (defaults to true if an API key is provided). This object contains an `enabled` flag prop and an optional `transactionHandler` which is a callback that can disable or allow customizations of notifications. -Currently notifications are positioned in the same location as the account center (either below, if the Account Center is positioned along the top, or above if positioned on the bottom of the view). -The `transactionHandler` can react off any property of the Ethereum TransactionData returned to the callback from the event (see console.log in example init). In turn, it can return a Custom `Notification` object to define the verbiage, styling, or add functionality: -- `Notification.message` - to completely customize the message shown -- `Notification.eventCode` - handle codes in your own way - see codes here under the notify prop [default en file here](src/i18n/en.json) -- `Notification.type` - icon type displayed (see `NotificationType` below for options) -- `Notification.autoDismiss` - time (in ms) after which the notification will be dismissed. If set to `0` the notification will remain on screen until the user dismisses the notification, refreshes the page or navigates away from the site with the notifications -- `Notification.link` - add link to the transaction hash. For instance, a link to the transaction on etherscan -- `Notification.onClick()` - onClick handler for when user clicks the notification element +Notify is a feature that provides transaction notifications for all connected wallets on the current blockchain. This document will provide you with an overview of Notify and guide you through the process of integrating it into your decentralized application (DApp). + +Notify UI Components + +To enable transaction notifications and updates simply add your Blocknative `apiKey`([sign up for free](https://explorer.blocknative.com/account)) to the web3-onboard configurations as the value to the `apiKey` prop and thats it! +Transaction notifications will be shown for all transactions occurring on supported chains for all of the users connected wallets. +When switching chains, the previous chain listeners remain active for 60 seconds to allow the capture and report of any remaining transactions that may be in flight. + +Notifications are by default positioned in the same location as the Account Center (if enabled) or can be positioned separately using the `position` property. + +##### **Notify Configuration** + +| Property | Type | Description | +| -------------------- | --------------- | ------------------------------------------------------------- | +| `enabled` | boolean | Indicates whether transaction notifications will be displayed | +| `transactionHandler` | function | Optional callback for customizations of notifications | +| `position` | CommonPositions | Position of the notification on the screen | + +##### **Position Options** + +| Property | Type | Description | +| --------- | ------ | ---------------------------------------- | +| `desktop` | Notify | Configuration for desktop notifications. | +| `mobile` | Notify | Configuration for mobile notifications. | + +Both `desktop` and `mobile` configurations are of type `Notify`. + +###### **Transaction Handler** -Notify can also be styled by using the CSS variables found below. These are setup to allow maximum customization with base styling variables setting the global theme (i.e. `--onboard-grey-600`) along with more precise component level styling variables available (`--notify-onboard-grey-600`) with the latter taking precedent if defined. +The `transactionHandler` is a callback that receives an object of type `EthereumTransactionData`. Based on the data received, the handler can return a custom `Notification` object or a boolean value (false to disable the notification for the current event or undefined for a default notification). -Under the following conditions, when a transaction notification is hovered, a dropdown will appear, allowing the user to replace (speedup or cancel) their transaction: +##### **Customizing Notification** -- The [gas](../gas/) module has been passed in to the Web3 Onboard initialization -- The transaction was initiated on the networks that the gas module can get estimations for (currently Ethereum and Polygon mainnet) -- The transaction has a pending status (eventCode: 'txPool') -- The transaction was initiated by a hardware wallet (possibly other wallet types in future as they recognize the `nonce` field) +| Property | Type | Description | +| ------------- | -------- | ----------------------------------------------------------- | +| `message` | string | Customizes the message shown | +| `eventCode` | string | Allows handling codes in a custom way | +| `type` | string | Represents the icon type displayed | +| `autoDismiss` | number | Time (in ms) after which the notification will be dismissed | +| `link` | string | Adds a link to the transaction hash | +| `onClick` | function | onClick handler for the notification element | -The replacement gas values can be customized from the defaults by using the `replacement` parameter in the Notify options. +##### **Styling Notify** -If notifications are enabled the notifications can be handled through onboard app state as seen below. +Notify automatically will match the [`theme`](#theme) defined in the web3-onboard config. It can also be styled using the [exposed css variables provided below](#custom-styling). These variables allow for maximum customization with base styling variables setting the global theme (e.g., `--onboard-grey-600`) and more precise component-level styling variables available (`--notify-onboard-grey-600`). The latter takes precedence if defined. + +##### **Handling Notifications** + +If notifications are enabled, they can be fielded and handled through the onboard app state as seen in the example below - although this is not required for notifications to display: ```javascript const wallets = onboard.state.select('notifications') -const { unsubscribe } = wallets.subscribe(update => +const { unsubscribe } = wallets.subscribe((update) => console.log('transaction notifications: ', update) ) @@ -337,7 +369,21 @@ const { unsubscribe } = wallets.subscribe(update => unsubscribe() ``` -```typescript +##### **Notifications as Toast Messages** +The Notifications messages can also be used to send fully customized Dapp toast messages and updated. Check out the [customNotifications API docs for examples and code snippets](#customnotification) + + +```javascript +const wallets = onboard.state.select('notifications') +const { unsubscribe } = wallets.subscribe((update) => + console.log('transaction notifications: ', update) +) + +// unsubscribe when updates are no longer needed +unsubscribe() +``` + +```ts type NotifyOptions = { desktop: Notify mobile: Notify @@ -350,18 +396,8 @@ type Notify = { * Or return false to disable notification for this event * Or return undefined for a default notification */ - transactionHandler?: ( - event: EthereumTransactionData - ) => TransactionHandlerReturn + transactionHandler?: (event: EthereumTransactionData) => TransactionHandlerReturn position: CommonPositions - replacement?: { - gasPriceProbability?: { - // define the gas price used for speedup based on the probability of getting in to the next block. Default 80 - speedup?: number - // define the gas price used for cancel based on the probability of getting in to the next block. Default 95 - cancel?: number - } - } } type CommonPositions = 'topRight' | 'bottomRight' | 'bottomLeft' | 'topLeft' @@ -373,33 +409,44 @@ type CustomNotification = Partial> type Notification = { id: string key: string - type: NotificationType network: Network startTime?: number - eventCode: string + /** + * to completely customize the message shown + */ message: string + /** + * handle codes in your own way - see codes here under the notify prop [default en file here](https://github.com/blocknative/web3-onboard/blob/develop/packages/core/src/i18n/en.json) + */ + eventCode: string + /** + * icon type displayed (see `NotificationType` below for options) + */ + type: NotificationType + /** + * time (in ms) after which the notification will be dismissed. If set to `0` the notification will remain on screen until the user dismisses the notification, refreshes the page or navigates away from the site with the notifications + */ autoDismiss: number + /** + * add link to the transaction hash. For instance, a link to the transaction on etherscan + */ link?: string + /** + * onClick handler for when user clicks the notification element + */ onClick?: (event: Event) => void } type NotificationType = 'pending' | 'success' | 'error' | 'hint' -export declare type Network = +declare type Network = | 'main' - | 'testnet' - | 'ropsten' - | 'rinkeby' | 'goerli' - | 'kovan' - | 'xdai' - | 'bsc-main' | 'matic-main' - | 'fantom-main' | 'matic-mumbai' | 'local' -export interface UpdateNotification { +interface UpdateNotification { (notificationObject: CustomNotification): { dismiss: () => void update: UpdateNotification @@ -407,7 +454,9 @@ export interface UpdateNotification { } ``` -### Initialization Example +--- + +## Initialization Example Putting it all together, here is an example initialization with the injected wallet modules: @@ -422,6 +471,8 @@ const ETH_MAINNET_RPC = `https://mainnet.infura.io/v3/${INFURA_KEY}` || `https:/ const ETH_GOERLI_RPC = `https://goerli.infura.io/v3/${INFURA_ID}` || `https://eth-goerli.g.alchemy.com/v2/${ALCHEMY_KEY}` const onboard = Onboard({ + // head to https://explorer.blocknative.com/account to sign up for free + apiKey: 'xxx387fb-bxx1-4xxc-a0x3-9d37e426xxxx' wallets: [injected], chains: [ { @@ -471,7 +522,6 @@ const onboard = Onboard({ { name: 'Coinbase', url: 'https://wallet.coinbase.com/' } ] }, - apiKey: 'xxx387fb-bxx1-4xxc-a0x3-9d37e426xxxx' notify: { desktop: { enabled: true, @@ -537,6 +587,7 @@ const onboard = Onboard({ } }) ``` +--- ## Connecting a Wallet @@ -784,11 +835,11 @@ onboard.state.actions.updateTheme(customTheme) ``` ```typescript -export type Theme = ThemingMap | BuiltInThemes | 'system' +type Theme = ThemingMap | BuiltInThemes | 'system' -export type BuiltInThemes = 'default' | 'dark' | 'light' +type BuiltInThemes = 'default' | 'dark' | 'light' -export type ThemingMap = { +type ThemingMap = { '--w3o-background-color'?: string '--w3o-foreground-color'?: string '--w3o-text-color'?: string @@ -852,32 +903,30 @@ onboard.state.actions.updateNotify({ ``` **`customNotification`** + +Custom Notification UI Components + Notify can be used to deliver custom DApp notifications by passing a `CustomNotification` object to the `customNotification` action. This will return an `UpdateNotification` type. This `UpdateNotification` will return an `update` function that can be passed a new `CustomNotification` to update the existing notification. The `customNotification` method also returns a `dismiss` method that is called without any parameters to dismiss the notification. -```typescript -const { update, dismiss } = onboard.state.actions.customNotification({ - type: 'pending', - message: 'This is a custom DApp pending notification to use however you want', - autoDismiss: 0 -}) -setTimeout( - () => - update({ - eventCode: 'dbUpdateSuccess', - message: 'Updated status for custom notification', - type: 'success', - autoDismiss: 8000 - }), - 4000 -) -``` +| Property | Type | Description | +| ------------- | -------- | ----------------------------------------------------------- | +| `message` | string | Customizes the message shown | +| `eventCode` | string | Allows handling codes in a custom way | +| `type` | string | Represents the icon type displayed | +| `autoDismiss` | number | Time (in ms) after which the notification will be dismissed | +| `link` | string | Adds a link to the transaction hash | +| `onClick` | function | onClick handler for the notification element | + **`preflightNotifications`** -Notify can be used to deliver standard notifications along with preflight information by passing a `PreflightNotificationsOptions` object to the `preflightNotifications` action. This will return a a promise that resolves to the transaction hash (if `sendTransaction` resolves the transaction hash and is successful), the internal notification id (if no `sendTransaction` function is provided) or return nothing if an error occurs or `sendTransaction` is not provided or doesn't resolve to a string. -Preflight event types include +Notify can be used to deliver standard notifications along with preflight updates by passing a `PreflightNotificationsOptions` object to the `preflightNotifications` API action. + +Web3-Onboard UI Components + +Preflight event types include: - `txRequest` : Alert user there is a transaction request awaiting confirmation by their wallet - `txAwaitingApproval` : A previous transaction is awaiting confirmation @@ -887,26 +936,14 @@ Preflight event types include - `txSendFail` : The user rejected the transaction (requires `sendTransaction`) - `txUnderpriced` : The gas price for the transaction is too low (requires `sendTransaction`) -```typescript -interface PreflightNotificationsOptions { - sendTransaction?: () => Promise - estimateGas?: () => Promise - gasPrice?: () => Promise - balance?: string | number - txDetails?: { - value: string | number - to?: string - from?: string - } - txApproveReminderTimeout?: number // defaults to 15 seconds if not specified -} -``` +This API call will return a promise that resolves to the transaction hash (if `sendTransaction` resolves the transaction hash and is successful), the internal notification id (if no `sendTransaction` function is provided) or return nothing if an error occurs or `sendTransaction` is not provided or doesn't resolve to a string. -```typescript +Example: +```typescript copy const balanceValue = Object.values(balance)[0] -const ethersProvider = new ethers.providers.Web3Provider(provider, 'any') // if using ethers v6 this is: // ethersProvider = new ethers.BrowserProvider(wallet.provider, 'any') +const ethersProvider = new ethers.providers.Web3Provider(provider, 'any') const signer = ethersProvider.getSigner() const txDetails = { @@ -915,13 +952,13 @@ const txDetails = { } const sendTransaction = () => { - return signer.sendTransaction(txDetails).then(tx => tx.hash) + return signer.sendTransaction(txDetails).then((tx) => tx.hash) } -const gasPrice = () => ethersProvider.getGasPrice().then(res => res.toString()) +const gasPrice = () => ethersProvider.getGasPrice().then((res) => res.toString()) const estimateGas = () => { - return ethersProvider.estimateGas(txDetails).then(res => res.toString()) + return ethersProvider.estimateGas(txDetails).then((res) => res.toString()) } const transactionHash = await onboard.state.actions.preflightNotifications({ sendTransaction, @@ -933,6 +970,21 @@ const transactionHash = await onboard.state.actions.preflightNotifications({ console.log(transactionHash) ``` +```typescript +interface PreflightNotificationsOptions { + sendTransaction?: () => Promise + estimateGas?: () => Promise + gasPrice?: () => Promise + balance?: string | number + txDetails?: { + value: string | number + to?: string + from?: string + } + txApproveReminderTimeout?: number // defaults to 15 seconds if not specified +} +``` + **`updateAccountCenter`** If you need to update your Account Center configuration after initialization, you can call the `updateAccountCenter` function with the new configuration diff --git a/packages/core/package.json b/packages/core/package.json index a78a3041a..238ed4752 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/core", - "version": "2.16.0", + "version": "2.16.1", "description": "Web3-Onboard makes it simple to connect Ethereum hardware and software wallets to your dapp. Features standardized spec compliant web3 providers for all supported wallets, framework agnostic modern javascript UI with code splitting, CSS customization, multi-chain and multi-account support, reactive wallet state subscriptions and real-time transaction state change notifications.", "keywords": [ "Ethereum", diff --git a/packages/core/src/types.ts b/packages/core/src/types.ts index 55d309c6f..8d5408d7b 100644 --- a/packages/core/src/types.ts +++ b/packages/core/src/types.ts @@ -211,6 +211,13 @@ export type ConnectModalOptions = { * Defaults to `https://ethereum.org/en/wallets/find-wallet/#main-content` */ iDontHaveAWalletLink?: string + /** + * Customize the link for the `Where's My Wallet` info pop up shown on the + * select wallet modal. + * Defaults to `https://www.blocknative.com/blog/ + * metamask-wont-connect-web3-wallet-troubleshooting` + */ + wheresMyWalletLink?: string /** * Define support for Unstoppable Domains resolutions * after a user connects. Similar to ens, uns can be used for users who @@ -301,13 +308,36 @@ export type NotifyOptions = { export type Notification = { id: string key: string - type: NotificationType network: Network startTime?: number - eventCode: string + /** + * to completely customize the message shown + */ message: string + /** + * handle codes in your own way - see codes here under the notify + * prop default en file at ./packages/core/src/i18n/en.json + */ + eventCode: string + /** + * icon type displayed (see `NotificationType` below for options) + */ + type: NotificationType + /** + * time (in ms) after which the notification will be dismissed. If set + * to `0` the notification will remain on screen until the user dismisses the + * notification, refreshes the page or navigates away from the site + * with the notifications + */ autoDismiss: number + /** + * add link to the transaction hash. For instance, a link to the + * transaction on etherscan + */ link?: string + /** + * onClick handler for when user clicks the notification element + */ onClick?: (event: Event) => void } diff --git a/packages/core/src/validation.ts b/packages/core/src/validation.ts index 1b2304837..1716639f8 100644 --- a/packages/core/src/validation.ts +++ b/packages/core/src/validation.ts @@ -176,6 +176,7 @@ const connectModalOptions = Joi.object({ autoConnectLastWallet: Joi.boolean(), autoConnectAllPreviousWallet: Joi.boolean(), iDontHaveAWalletLink: Joi.string(), + wheresMyWalletLink: Joi.string(), disableUDResolution: Joi.boolean() }) diff --git a/packages/core/src/views/connect/SelectingWallet.svelte b/packages/core/src/views/connect/SelectingWallet.svelte index c4fe1e81b..2e6b976ae 100644 --- a/packages/core/src/views/connect/SelectingWallet.svelte +++ b/packages/core/src/views/connect/SelectingWallet.svelte @@ -11,11 +11,15 @@ export let connectingErrorMessage: string let windowWidth: number + const { connect } = state.get() function checkConnected(label: string) { const { wallets } = state.get() return !!wallets.find(wallet => wallet.label === label) } + + const wheresMyWalletDefault = + 'https://www.blocknative.com/blog/metamask-wont-connect-web3-wallet-troubleshooting' @@ -73,5 +86,16 @@ connectingWalletLabel !== wallet.label} /> {/each} +
+ +
Why don't I see my Wallet?
+ Click here to learn more +
+
diff --git a/packages/core/src/views/shared/Warning.svelte b/packages/core/src/views/shared/Warning.svelte index 6f216c5ef..d15a43767 100644 --- a/packages/core/src/views/shared/Warning.svelte +++ b/packages/core/src/views/shared/Warning.svelte @@ -5,13 +5,13 @@
-

+

-

+
{@html infoIcon} diff --git a/packages/demo/package.json b/packages/demo/package.json index 21eb730b0..4288391e9 100644 --- a/packages/demo/package.json +++ b/packages/demo/package.json @@ -23,7 +23,7 @@ "webpack-dev-server": "4.7.4" }, "dependencies": { - "@web3-onboard/core": "^2.16.0", + "@web3-onboard/core": "^2.16.1", "@web3-onboard/coinbase": "^2.2.1", "@web3-onboard/transaction-preview": "^2.0.5", "@web3-onboard/dcent": "^2.2.4", @@ -45,7 +45,7 @@ "@web3-onboard/torus": "^2.2.2", "@web3-onboard/taho": "^2.0.1", "@web3-onboard/web3auth": "^2.2.0", - "@web3-onboard/walletconnect": "^2.3.3", + "@web3-onboard/walletconnect": "^2.3.4", "@web3-onboard/enkrypt": "^2.0.1", "@web3-onboard/mew-wallet": "^2.0.0", "@web3-onboard/xdefi": "^2.0.1", diff --git a/packages/demo/src/App.svelte b/packages/demo/src/App.svelte index 38cc989f8..1b14b79bb 100644 --- a/packages/demo/src/App.svelte +++ b/packages/demo/src/App.svelte @@ -105,7 +105,7 @@ const walletConnect = walletConnectModule({ connectFirstChainId: true, version: 2, - handleUri: (uri) => console.log(uri), + handleUri: uri => console.log(uri), projectId: 'f6bd6e2911b56f5ac3bc8b2d0e2d7ad5', qrcodeModalOptions: { mobileLinks: ['rainbow', 'metamask', 'argent', 'trust', 'imtoken', 'pillar'] @@ -329,10 +329,8 @@ provider => provider.label === 'Unstoppable' ) if (unstoppableUser) console.log(unstoppableUser.instance.user) - const wc = wallet.find( - provider => provider.label === 'WalletConnect' - ) - if(wc) console.log(wc) + const wc = wallet.find(provider => provider.label === 'WalletConnect') + if (wc) console.log(wc) }) const signTransactionMessage = async provider => { diff --git a/packages/react/package.json b/packages/react/package.json index a6e39610e..ccfd9e859 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/react", - "version": "2.7.0", + "version": "2.7.1", "description": "A collection of React hooks for integrating Web3-Onboard in to React and Next.js projects. Web3-Onboard makes it simple to connect Ethereum hardware and software wallets to your dapp. Features standardised spec compliant web3 providers for all supported wallets, modern javascript UI with code splitting, CSS customization, multi-chain and multi-account support, reactive wallet state subscriptions and real-time transaction state change notifications.", "keywords": [ "Ethereum", @@ -62,7 +62,7 @@ "typescript": "^4.5.5" }, "dependencies": { - "@web3-onboard/core": "^2.16.0", + "@web3-onboard/core": "^2.16.1", "@web3-onboard/common": "^2.3.0", "use-sync-external-store": "1.0.0" }, diff --git a/packages/vue/package.json b/packages/vue/package.json index eebbaf42d..e7995863f 100644 --- a/packages/vue/package.json +++ b/packages/vue/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/vue", - "version": "2.6.0", + "version": "2.6.1", "description": "A collection of Vue Composables for integrating Web3-Onboard in to a Vue or Nuxt project. Web3-Onboard makes it simple to connect Ethereum hardware and software wallets to your dapp. Features standardized spec compliant web3 providers for all supported wallets, modern javascript UI with code splitting, CSS customization, multi-chain and multi-account support, reactive wallet state subscriptions and real-time transaction state change notifications.", "keywords": [ "Ethereum", @@ -63,7 +63,7 @@ "@vueuse/core": "^8.4.2", "@vueuse/rxjs": "^8.2.0", "@web3-onboard/common": "^2.3.0", - "@web3-onboard/core": "^2.16.0", + "@web3-onboard/core": "^2.16.1", "vue-demi": "^0.12.4" }, "peerDependencies": { diff --git a/packages/walletconnect/README.md b/packages/walletconnect/README.md index 0a9cb0f03..dd5af1541 100644 --- a/packages/walletconnect/README.md +++ b/packages/walletconnect/README.md @@ -47,6 +47,10 @@ type WalletConnectOptions = { * optional chains for the WalletConnect module */ requiredChains?: number[] | undefined + /** + * `undefined` by default, see https://docs.walletconnect.com/2.0/web3modal/options + */ + qrModalOptions?: Web3ModalConfig } ) ``` diff --git a/packages/walletconnect/package.json b/packages/walletconnect/package.json index 7f1c0e2ac..057ac3623 100644 --- a/packages/walletconnect/package.json +++ b/packages/walletconnect/package.json @@ -1,6 +1,6 @@ { "name": "@web3-onboard/walletconnect", - "version": "2.3.3", + "version": "2.3.4", "description": "WalletConnect SDK module for connecting to Web3-Onboard. Web3-Onboard makes it simple to connect Ethereum hardware and software wallets to your dapp. Features standardised spec compliant web3 providers for all supported wallets, framework agnostic modern javascript UI with code splitting, CSS customization, multi-chain and multi-account support, reactive wallet state subscriptions and real-time transaction state change notifications.", "keywords": [ "Ethereum", @@ -56,13 +56,15 @@ "license": "MIT", "devDependencies": { "typescript": "^4.5.5", - "@walletconnect/types": "^2.3.3" + "@walletconnect/types": "^2.5.2", + "@web3modal/standalone": "^2.2.2" }, "dependencies": { "@ethersproject/providers": "^5.5.0", - "@walletconnect/ethereum-provider": "2.4.10", + "@walletconnect/ethereum-provider": "2.5.2", "@walletconnect/client": "^1.8.0", "@walletconnect/qrcode-modal": "^1.8.0", + "@web3modal/standalone":"^2.2.2", "@web3-onboard/common": "^2.3.0", "rxjs": "^7.5.2" } diff --git a/packages/walletconnect/src/index.ts b/packages/walletconnect/src/index.ts index 56066ef9c..3a225721f 100644 --- a/packages/walletconnect/src/index.ts +++ b/packages/walletconnect/src/index.ts @@ -1,4 +1,5 @@ import type { WalletInit } from '@web3-onboard/common' +import type { Web3ModalConfig } from '@web3modal/standalone' import v1 from './v1.js' import v2 from './v2.js' @@ -11,8 +12,7 @@ export type WalletConnectOptions = { bridge?: string qrcodeModalOptions?: { mobileLinks: string[] - }, - + } } & ( | { /** @@ -36,6 +36,10 @@ export type WalletConnectOptions = { * optional chains for the WalletConnect module */ requiredChains?: number[] | undefined + /** + * `undefined` by default, see https://docs.walletconnect.com/2.0/web3modal/options + */ + qrModalOptions?: Web3ModalConfig } ) @@ -48,7 +52,7 @@ export const isHexString = (value: string | number) => { } function walletConnect(options?: WalletConnectOptions): WalletInit { - const version = options && options.version || 1 + const version = (options && options.version) || 1 return version === 1 ? v1(options) : v2(options) } diff --git a/packages/walletconnect/src/v2.ts b/packages/walletconnect/src/v2.ts index 6fe602539..bffcab7b6 100644 --- a/packages/walletconnect/src/v2.ts +++ b/packages/walletconnect/src/v2.ts @@ -1,4 +1,5 @@ import type { CoreTypes } from '@walletconnect/types' +import type { EthereumProvider } from '@walletconnect/ethereum-provider' import type { Chain, ProviderAccounts, @@ -19,13 +20,12 @@ const methods = [ ] function walletConnect(options?: WalletConnectOptions): WalletInit { - const projectId = - options && options.version === 2 ? options.projectId : undefined - if (!projectId) { + if (!options || options.version !== 2) { throw new Error( 'WalletConnect requires a projectId. Please visit https://cloud.walletconnect.com to get one.' ) } + const { projectId, handleUri, requiredChains, qrModalOptions } = options return () => { return { @@ -65,21 +65,20 @@ function walletConnect(options?: WalletConnectOptions): WalletInit { } // default to mainnet - const requiredChains = - options && - options.version === 2 && - Array.isArray(options.requiredChains) && - options.requiredChains.length && - options.requiredChains.every(num => !isNaN(num) ) - // @ts-ignore + const requiredChainsParsed = + Array.isArray(requiredChains) && + requiredChains.length && + requiredChains.every(num => !isNaN(num)) + ? // @ts-ignore // Required as WC package does not support hex numbers - ? options.requiredChains.map(chainID => parseInt(chainID)) + requiredChains.map(chainID => parseInt(chainID)) : [1] const connector = await EthereumProvider.init({ projectId, + chains: requiredChainsParsed, // default to mainnet metadata: getMetaData(), - chains: requiredChains, // default to mainnet + showQrModal: true, optionalChains: chains.map(({ id }) => parseInt(id, 16)), optionalMethods: methods, rpcMap: chains @@ -87,7 +86,8 @@ function walletConnect(options?: WalletConnectOptions): WalletInit { .reduce((rpcMap: Record, { id, rpcUrl }) => { rpcMap[parseInt(id, 16)] = rpcUrl || '' return rpcMap - }, {}) + }, {}), + qrModalOptions: qrModalOptions }) const emitter = new EventEmitter() @@ -163,7 +163,7 @@ function walletConnect(options?: WalletConnectOptions): WalletInit { if (this.connector.session) this.connector.disconnect() } - if (options && options.handleUri) { + if (options && handleUri) { // listen for uri event fromEvent( this.connector as JQueryStyleEventEmitter, @@ -173,20 +173,21 @@ function walletConnect(options?: WalletConnectOptions): WalletInit { .pipe(takeUntil(this.disconnected$)) .subscribe(async uri => { try { - options.handleUri && (await options.handleUri(uri)) + handleUri && (await handleUri(uri)) } catch (error) { throw `An error occurred when handling the URI. Error: ${error}` } }) } - ;(() => { + const checkForSession = () => { const session = this.connector.session if (session) { this.emit('accountsChanged', this.connector.accounts) this.emit('chainChanged', this.connector.chainId) } - })() + } + checkForSession() this.request = async ({ method, params }) => { if (method === 'eth_chainId') { @@ -196,50 +197,52 @@ function walletConnect(options?: WalletConnectOptions): WalletInit { } if (method === 'eth_requestAccounts') { - return new Promise((resolve, reject) => { - // Check if connection is already established - if (!this.connector.session) { - // create new session - this.connector.connect().catch(err => { - console.error('err: ', err) - reject( - new ProviderRpcError({ - code: 4001, - message: 'User rejected the request.' - }) - ) - }) - } else { - // update ethereum provider to load accounts & chainId - const accounts = this.connector.accounts - const chainId = this.connector.chainId - const hexChainId = `0x${chainId.toString(16)}` - this.emit('chainChanged', hexChainId) - return resolve(accounts) + return new Promise( + async (resolve, reject) => { + // Subscribe to connection events + fromEvent( + this.connector as JQueryStyleEventEmitter< + any, + { chainId: number } + >, + 'connect', + (payload: { chainId: number | string }) => payload + ) + .pipe(take(1)) + .subscribe({ + next: ({ chainId }) => { + this.emit('accountsChanged', this.connector.accounts) + const hexChainId = isHexString(chainId) + ? chainId + : `0x${chainId.toString(16)}` + this.emit('chainChanged', hexChainId) + resolve(this.connector.accounts) + }, + error: reject + }) + + // Check if connection is already established + if (!this.connector.session) { + // create new session + await this.connector.connect().catch(err => { + console.error('err creating new session: ', err) + reject( + new ProviderRpcError({ + code: 4001, + message: 'User rejected the request.' + }) + ) + }) + } else { + // update ethereum provider to load accounts & chainId + const accounts = this.connector.accounts + const chainId = this.connector.chainId + const hexChainId = `0x${chainId.toString(16)}` + this.emit('chainChanged', hexChainId) + return resolve(accounts) + } } - // Subscribe to connection events - fromEvent( - this.connector as JQueryStyleEventEmitter< - any, - { accounts: string[]; chainId: number } - >, - 'connect', - (payload: { accounts: string[]; chainId: number }) => - payload - ) - .pipe(take(1)) - .subscribe({ - next: ({ accounts, chainId }) => { - this.emit('accountsChanged', accounts) - const hexChainId = isHexString(chainId) - ? chainId - : `0x${chainId.toString(16)}` - this.emit('chainChanged', hexChainId) - resolve(accounts) - }, - error: reject - }) - }) + ) } if (method === 'eth_selectAccounts') { diff --git a/yarn.lock b/yarn.lock index 7d4136230..a0012765b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1417,10 +1417,10 @@ resolved "https://registry.yarnpkg.com/@ledgerhq/connect-kit-loader/-/connect-kit-loader-1.0.2.tgz#8554e16943f86cc2a5f6348a14dfe6e5bd0c572a" integrity sha512-TQ21IjcZOw/scqypaVFY3jHVqI7X7Hta3qN/us6FvTol3AY06UmrhhXGww0E9xHmAbdX241ddwXEiMBSQZFr9g== -"@lit-labs/ssr-dom-shim@^1.0.0": - version "1.0.0" - resolved "https://registry.yarnpkg.com/@lit-labs/ssr-dom-shim/-/ssr-dom-shim-1.0.0.tgz#427e19a2765681fd83411cd72c55ba80a01e0523" - integrity sha512-ic93MBXfApIFTrup4a70M/+ddD8xdt2zxxj9sRwHQzhS9ag/syqkD8JPdTXsc1gUy2K8TTirhlCqyTEM/sifNw== +"@lit-labs/ssr-dom-shim@^1.0.0", "@lit-labs/ssr-dom-shim@^1.1.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@lit-labs/ssr-dom-shim/-/ssr-dom-shim-1.1.0.tgz#3361d6b8c4cb2ac426d5794ac7cd9776cd2f0814" + integrity sha512-92uQ5ARf7UXYrzaFcAX3T2rTvaS9Z1//ukV+DqjACM4c8s0ZBQd7ayJU5Dh2AFLD/Ayuyz4uMmxQec8q3U4Ong== "@lit/reactive-element@^1.3.0", "@lit/reactive-element@^1.6.0": version "1.6.1" @@ -2628,9 +2628,9 @@ "@types/node" "*" "@types/trusted-types@^2.0.2": - version "2.0.2" - resolved "https://registry.yarnpkg.com/@types/trusted-types/-/trusted-types-2.0.2.tgz#fc25ad9943bcac11cceb8168db4f275e0e72e756" - integrity sha512-F5DIZ36YVLE+PN+Zwws4kJogq47hNgX3Nx6WyDJ3kcplxyke3XIzB8uK5n/Lpm1HBsbGzd6nmGehL8cPekP+Tg== + version "2.0.3" + resolved "https://registry.yarnpkg.com/@types/trusted-types/-/trusted-types-2.0.3.tgz#a136f83b0758698df454e328759dbd3d44555311" + integrity sha512-NfQ4gyz38SL8sDNrSixxU2Os1a5xcdFxipAFxYEuLUlvU2uDwS4NUpsImcf1//SlWItCVMMLiylsxbmNMToV/g== "@types/use-sync-external-store@^0.0.3": version "0.0.3" @@ -2927,13 +2927,13 @@ "@walletconnect/types" "^1.8.0" "@walletconnect/utils" "^1.8.0" -"@walletconnect/core@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-2.4.10.tgz#8975996b5c47d0d11a1187b3793215678c3ea3af" - integrity sha512-3ZVS07NS9+zG+Mw4MOxYhoJHwCSuIOrq+HuhaTLZZ+NswscZ+GwguF2fTsRNgk4jXkMJodaqUFxfPJeCVVcwHQ== +"@walletconnect/core@2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-2.5.2.tgz#999605a62a3b37867d2559e40b62778534eb787c" + integrity sha512-R0D9NKgHBpdun65q+1L49GOIGDLaIodnyb+Dq0tXGVzvXzy2lkXOlh2e9am61ixaVrUsHt7b96b318geqsuk4Q== dependencies: "@walletconnect/heartbeat" "1.2.0" - "@walletconnect/jsonrpc-provider" "1.0.9" + "@walletconnect/jsonrpc-provider" "1.0.10" "@walletconnect/jsonrpc-utils" "^1.0.4" "@walletconnect/jsonrpc-ws-connection" "1.0.10" "@walletconnect/keyvaluestorage" "^1.0.2" @@ -2942,8 +2942,8 @@ "@walletconnect/relay-auth" "^1.0.4" "@walletconnect/safe-json" "^1.0.1" "@walletconnect/time" "^1.0.2" - "@walletconnect/types" "2.4.10" - "@walletconnect/utils" "2.4.10" + "@walletconnect/types" "2.5.2" + "@walletconnect/utils" "2.5.2" events "^3.3.0" lodash.isequal "4.5.0" pino "7.11.0" @@ -3017,20 +3017,19 @@ dependencies: tslib "1.14.1" -"@walletconnect/ethereum-provider@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/ethereum-provider/-/ethereum-provider-2.4.10.tgz#450167cf3fbfb7813189076f13c0c61e324f8c25" - integrity sha512-anD3inbmuIZgWJ7Km5QP6L/hjI8sK/3Q4WA+g8OlyHS2cqO9sPjYdbPUVnzVgwhTDbNDJr2AUNXmvpm2R0hq5Q== +"@walletconnect/ethereum-provider@2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@walletconnect/ethereum-provider/-/ethereum-provider-2.5.2.tgz#b70c01fc281ae8b6c424fc063bc48b476ef3f83a" + integrity sha512-WEN85tsuHgvoiMK4KpsRsOgsKB0QLCctSwxTqyWDybBbXuJRJGWXkZ6Oma9VSmUR0MgPSjiGmOFgY4ybMlhEMA== dependencies: "@walletconnect/jsonrpc-http-connection" "^1.0.4" "@walletconnect/jsonrpc-provider" "^1.0.6" "@walletconnect/jsonrpc-types" "^1.0.2" "@walletconnect/jsonrpc-utils" "^1.0.4" - "@walletconnect/sign-client" "2.4.10" - "@walletconnect/types" "2.4.10" - "@walletconnect/universal-provider" "2.4.10" - "@walletconnect/utils" "2.4.10" - "@web3modal/standalone" "^2.2.0" + "@walletconnect/sign-client" "2.5.2" + "@walletconnect/types" "2.5.2" + "@walletconnect/universal-provider" "2.5.2" + "@walletconnect/utils" "2.5.2" events "^3.3.0" "@walletconnect/events@^1.0.1": @@ -3081,10 +3080,10 @@ cross-fetch "^3.1.4" tslib "1.14.1" -"@walletconnect/jsonrpc-provider@1.0.9": - version "1.0.9" - resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-provider/-/jsonrpc-provider-1.0.9.tgz#ce5ab64dce6a739110aef204ffeedd668ad343d8" - integrity sha512-8CwmiDW42F+F8Qct13lX2x4lJOsi0mNBtUln3VS6TpWioTaL1VfforC/8ULc3tHXv+SNWwAXn2lCZbDcYhdRcA== +"@walletconnect/jsonrpc-provider@1.0.10": + version "1.0.10" + resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-provider/-/jsonrpc-provider-1.0.10.tgz#8351a06b70faa8f8c0e77dc2c6d9b0190d17d407" + integrity sha512-g0ffPSpY3P6GqGjWGHsr3yqvQUhj7q2k6pAikoXv5XTXWaJRzFvrlbFkSgxziXsBrwrMZn0qvPufvpN4mMZ5FA== dependencies: "@walletconnect/jsonrpc-utils" "^1.0.6" "@walletconnect/safe-json" "^1.0.1" @@ -3253,19 +3252,19 @@ dependencies: tslib "1.14.1" -"@walletconnect/sign-client@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/sign-client/-/sign-client-2.4.10.tgz#727072fcbf0c1f84c5370155f0feb7e711733ca4" - integrity sha512-8yNpRUVvkoFY5sdj7QbW1+g6QWgP8VLy1xVAqWkjLIiPieMA6IQcOpaEih9Bbq55oTOxjeWO9+E+V8/0bNXVvQ== +"@walletconnect/sign-client@2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@walletconnect/sign-client/-/sign-client-2.5.2.tgz#d05df9dce271720fdb75741fb162dcc899e39029" + integrity sha512-eKUnGCVgYqN+6b4gm27ML/064m0c/2hTlTHy6tbUszYtEPTzb+q4fvpnWs6blaOjzc18l8NFwX3c1+MHxVdQUQ== dependencies: - "@walletconnect/core" "2.4.10" + "@walletconnect/core" "2.5.2" "@walletconnect/events" "^1.0.1" "@walletconnect/heartbeat" "1.2.0" "@walletconnect/jsonrpc-utils" "^1.0.4" "@walletconnect/logger" "^2.0.1" "@walletconnect/time" "^1.0.2" - "@walletconnect/types" "2.4.10" - "@walletconnect/utils" "2.4.10" + "@walletconnect/types" "2.5.2" + "@walletconnect/utils" "2.5.2" events "^3.3.0" pino "7.11.0" @@ -3294,10 +3293,10 @@ dependencies: tslib "1.14.1" -"@walletconnect/types@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.4.10.tgz#7f85a761b9d65e192d2f510ce858383f19a340f7" - integrity sha512-AvT3ynXXDXty94SadbjGrqqQA8vB1g9AchHZOakCY/Cfo5etpUFG3PfubWMC1FKe2FPk020nLkc2ghjNxHGGtw== +"@walletconnect/types@2.5.1", "@walletconnect/types@^2.4.10": + version "2.5.1" + resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.5.1.tgz#1bb7d51a6cf04233a70c38efea0aa414db5768f9" + integrity sha512-PctuQw1Kt0tJ8mYU8p1JOXYxv8PhvNoXXtLaGkGZ/9knn1dJaQRlMDEN0iHG6qXlSAo0tW8Q3PtK5tetf5dJ0g== dependencies: "@walletconnect/events" "^1.0.1" "@walletconnect/heartbeat" "1.2.0" @@ -3306,10 +3305,10 @@ "@walletconnect/logger" "^2.0.1" events "^3.3.0" -"@walletconnect/types@2.5.1", "@walletconnect/types@^2.4.10": - version "2.5.1" - resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.5.1.tgz#1bb7d51a6cf04233a70c38efea0aa414db5768f9" - integrity sha512-PctuQw1Kt0tJ8mYU8p1JOXYxv8PhvNoXXtLaGkGZ/9knn1dJaQRlMDEN0iHG6qXlSAo0tW8Q3PtK5tetf5dJ0g== +"@walletconnect/types@2.5.2", "@walletconnect/types@^2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.5.2.tgz#b2ad73f9e6e19a90fe372babc9ed461fe27098fe" + integrity sha512-VnV43qs4f2hwv6wGQ9ZSE+smP0z2oVy2XaVO5Szd2fmOx9bB+ov+sQzh9xeoQ+DhjNrbJhUaecW/peE6CPPSag== dependencies: "@walletconnect/events" "^1.0.1" "@walletconnect/heartbeat" "1.2.0" @@ -3328,39 +3327,27 @@ resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-1.8.0.tgz#3f5e85b2d6b149337f727ab8a71b8471d8d9a195" integrity sha512-Cn+3I0V0vT9ghMuzh1KzZvCkiAxTq+1TR2eSqw5E5AVWfmCtECFkVZBP6uUJZ8YjwLqXheI+rnjqPy7sVM4Fyg== -"@walletconnect/types@^2.3.3": - version "2.4.0" - resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.4.0.tgz#fc4f9a315104558669b9345f1411b338aa99e6d6" - integrity sha512-hUdvwte7jnycq+B4Wa9czWraH3fDilbzr2/uziQTs61hiafoP7BkS+OrMymeb4HGmo+I2YOgVlc8ngVtdAxOSQ== - dependencies: - "@walletconnect/events" "^1.0.1" - "@walletconnect/heartbeat" "1.2.0" - "@walletconnect/jsonrpc-types" "^1.0.2" - "@walletconnect/keyvaluestorage" "^1.0.2" - "@walletconnect/logger" "^2.0.1" - events "^3.3.0" - -"@walletconnect/universal-provider@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/universal-provider/-/universal-provider-2.4.10.tgz#24696a2b9267d18a8a84008c5b42c8d5b917e4f0" - integrity sha512-KbRl3ivDGXtycp1qs/p8RvXz0f8VgG8k+NKpD6x9/ibnuuFLRt6UgriLHHCslJ9SSGuGHAeIaWs+kRRDKDNFXQ== +"@walletconnect/universal-provider@2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@walletconnect/universal-provider/-/universal-provider-2.5.2.tgz#f0ec21be16cde5c42f2dc87630add01d2e01acbb" + integrity sha512-R61VL02zvcljwSC+FJVzxGswbN21tokQLG0IQL1tVq30+KfkZOt0y/UxsDNvgHNGleGgfoQZzOWsfSLgp5pcBQ== dependencies: "@walletconnect/jsonrpc-http-connection" "^1.0.4" "@walletconnect/jsonrpc-provider" "^1.0.6" "@walletconnect/jsonrpc-types" "^1.0.2" "@walletconnect/jsonrpc-utils" "^1.0.4" "@walletconnect/logger" "^2.0.1" - "@walletconnect/sign-client" "2.4.10" - "@walletconnect/types" "2.4.10" - "@walletconnect/utils" "2.4.10" + "@walletconnect/sign-client" "2.5.2" + "@walletconnect/types" "2.5.2" + "@walletconnect/utils" "2.5.2" eip1193-provider "1.0.1" events "^3.3.0" pino "7.11.0" -"@walletconnect/utils@2.4.10": - version "2.4.10" - resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-2.4.10.tgz#1fbae7973008c06209ccf79797f732e44e97ac1c" - integrity sha512-mg01uaGY+DoT5yMVb7eL9zXdXZLRfkz85b63URa6QyfWD0Jbstmviutc5NU2YzzbIuekT3miL4cwPvi0MRklWA== +"@walletconnect/utils@2.5.2": + version "2.5.2" + resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-2.5.2.tgz#2ee0a10ea646f3e33e192de4b087a846e03b839f" + integrity sha512-s5bpY5q/RaXMc6LgPp+E7qPbKhrff9TjrLRjN2m9COnt9cERowpQEFrPzWmh10FatRZ7dNrudJ5I/c36nFc+hw== dependencies: "@stablelib/chacha20poly1305" "1.0.1" "@stablelib/hkdf" "1.0.1" @@ -3371,7 +3358,7 @@ "@walletconnect/relay-api" "^1.0.9" "@walletconnect/safe-json" "^1.0.1" "@walletconnect/time" "^1.0.2" - "@walletconnect/types" "2.4.10" + "@walletconnect/types" "2.5.2" "@walletconnect/window-getters" "^1.0.1" "@walletconnect/window-metadata" "^1.0.1" detect-browser "5.3.0" @@ -3652,28 +3639,28 @@ "@web3auth/base-evm-adapter" "^5.0.1" "@web3auth/ethereum-provider" "^5.0.1" -"@web3modal/core@2.2.0": - version "2.2.0" - resolved "https://registry.yarnpkg.com/@web3modal/core/-/core-2.2.0.tgz#847459e1ab1766f312c39715270a7ca0fe831666" - integrity sha512-Kafg/KtK6S9x0Ofcaq9hj7dRK5/541nM+LnayPmHxx4fSrDgcM9YYhL12fI4BG1xGOJwkeZjgFOtS0qf123Cjw== +"@web3modal/core@2.2.2": + version "2.2.2" + resolved "https://registry.yarnpkg.com/@web3modal/core/-/core-2.2.2.tgz#1e282dc45bddb11c04f1c93abce570bac1b9a620" + integrity sha512-RKbYNIEVP5Hwiva68PWXExbkTFLUTasneyRpcjoQSM4BIh78qXp1YMt0nyTvFdHmHQEGxXEMCuRG5qoE97uMHA== dependencies: buffer "6.0.3" - valtio "1.9.0" + valtio "1.10.3" -"@web3modal/standalone@^2.2.0": - version "2.2.0" - resolved "https://registry.yarnpkg.com/@web3modal/standalone/-/standalone-2.2.0.tgz#9f81ed976dd16bd795f902503065f75c9160eab3" - integrity sha512-cLFW4VamSJ7L4sM5OGmr1SHK3FgyLUMEaacvHsCA3XSvUF0LxbMC+N4uBsONrW4c0JyIjTdeii1GqG4B3jwn7Q== +"@web3modal/standalone@^2.2.2": + version "2.2.2" + resolved "https://registry.yarnpkg.com/@web3modal/standalone/-/standalone-2.2.2.tgz#2d5ce74bbb7f112b31da32049620afa75c4a4686" + integrity sha512-c05kkTFNGZqnjJ3n2C8uo+wWL6ut1jexGYAyTvbweDengdsOr8LDo0VpK5V3XSKCV2fFcPh5JE9H1aA4jpnZPg== dependencies: - "@web3modal/core" "2.2.0" - "@web3modal/ui" "2.2.0" + "@web3modal/core" "2.2.2" + "@web3modal/ui" "2.2.2" -"@web3modal/ui@2.2.0": - version "2.2.0" - resolved "https://registry.yarnpkg.com/@web3modal/ui/-/ui-2.2.0.tgz#2837da46706f1a3fcdf2f2c22e7ed029e235a3ab" - integrity sha512-jcV5C9AuMdsFdf6Ljsr0v2lInu8FJJyXcZPaMHkgYNIczzgMEpDE+UOA7hLnyCTUxM9R0AgRcgfTyMWb9H8Ssw== +"@web3modal/ui@2.2.2": + version "2.2.2" + resolved "https://registry.yarnpkg.com/@web3modal/ui/-/ui-2.2.2.tgz#f1c1ac908230d4214c35891a5d922c118353eaf2" + integrity sha512-PAuMOuk4sZ4UGjucGMZKzu6Qu56XtFsgLaqOn8ZgP2RkZmYEBGSG9mUQVzJd3XzfzAy1T91Wmqp/3TI3m0pXuQ== dependencies: - "@web3modal/core" "2.2.0" + "@web3modal/core" "2.2.2" lit "2.6.1" motion "10.15.5" qrcode "1.5.1" @@ -8223,17 +8210,18 @@ lie@3.1.1: immediate "~3.0.5" lit-element@^3.2.0: - version "3.2.2" - resolved "https://registry.yarnpkg.com/lit-element/-/lit-element-3.2.2.tgz#d148ab6bf4c53a33f707a5168e087725499e5f2b" - integrity sha512-6ZgxBR9KNroqKb6+htkyBwD90XGRiqKDHVrW/Eh0EZ+l+iC+u+v+w3/BA5NGi4nizAVHGYvQBHUDuSmLjPp7NQ== + version "3.3.0" + resolved "https://registry.yarnpkg.com/lit-element/-/lit-element-3.3.0.tgz#a8e0b9ca5239faf721d9af4460f106cf7f03533b" + integrity sha512-M3OIoblNS7LZdRxOIk8g0wyLEA/lRw/UGJ1TX+767OpkuDsRdSoxBIvewpWqCo7sMd9xt1XedUNZIr9jUO1X3g== dependencies: + "@lit-labs/ssr-dom-shim" "^1.1.0" "@lit/reactive-element" "^1.3.0" - lit-html "^2.2.0" + lit-html "^2.7.0" -lit-html@^2.2.0, lit-html@^2.6.0: - version "2.6.1" - resolved "https://registry.yarnpkg.com/lit-html/-/lit-html-2.6.1.tgz#eb29f0b0c2ab54ea77379db11fc011b0c71f1cda" - integrity sha512-Z3iw+E+3KKFn9t2YKNjsXNEu/LRLI98mtH/C6lnFg7kvaqPIzPn124Yd4eT/43lyqrejpc5Wb6BHq3fdv4S8Rw== +lit-html@^2.6.0, lit-html@^2.7.0: + version "2.7.0" + resolved "https://registry.yarnpkg.com/lit-html/-/lit-html-2.7.0.tgz#b244457d0f8c4782a50e83b2c6f3611347ef775d" + integrity sha512-/zPOl8EfeB3HHpTzINSpnWgvgQ8N07g/j272EOAIyB0Ys2RzBqTVT23i+JZuUlNbB2WHHeSsTCFi92NtWrtpqQ== dependencies: "@types/trusted-types" "^2.0.2" @@ -9595,10 +9583,10 @@ proxy-addr@~2.0.7: forwarded "0.2.0" ipaddr.js "1.9.1" -proxy-compare@2.4.0: - version "2.4.0" - resolved "https://registry.yarnpkg.com/proxy-compare/-/proxy-compare-2.4.0.tgz#90f6abffe734ef86d8e37428c5026268606a9c1b" - integrity sha512-FD8KmQUQD6Mfpd0hywCOzcon/dbkFP8XBd9F1ycbKtvVsfv6TsFUKJ2eC0Iz2y+KzlkdT1Z8SY6ZSgm07zOyqg== +proxy-compare@2.5.0: + version "2.5.0" + resolved "https://registry.yarnpkg.com/proxy-compare/-/proxy-compare-2.5.0.tgz#0387c5e4d283ba9b1c0353bb20def4449b06bbd2" + integrity sha512-f1us0OsVAJ3tdIMXGQx2lmseYS4YXe4W+sKF5g5ww/jV+5ogMadPt+sIZ+88Ga9kvMJsrRNWzCrKPpr6pMWYbA== prr@~1.0.1: version "1.0.1" @@ -11603,12 +11591,12 @@ v8-compile-cache@^2.0.3: resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz#2de19618c66dc247dcfb6f99338035d8245a2cee" integrity sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA== -valtio@1.9.0: - version "1.9.0" - resolved "https://registry.yarnpkg.com/valtio/-/valtio-1.9.0.tgz#d5d9f664319eaf18dd98f758d50495eca28eb0b8" - integrity sha512-mQLFsAlKbYascZygFQh6lXuDjU5WHLoeZ8He4HqMnWfasM96V6rDbeFkw1XeG54xycmDonr/Jb4xgviHtuySrA== +valtio@1.10.3: + version "1.10.3" + resolved "https://registry.yarnpkg.com/valtio/-/valtio-1.10.3.tgz#273eda9ba6459869798b4f58c84514e18fb80ed8" + integrity sha512-t3Ez/+baJ+Z5tIyeaI6nCAbW/hrmcq2jditwg/X++o5IvCdiGirQKTOv1kJq0glgUo13v5oABCVGcinggBfiKw== dependencies: - proxy-compare "2.4.0" + proxy-compare "2.5.0" use-sync-external-store "1.2.0" varint@5.0.0: