@walletconnect/ethereum-provider 2.5.0 → 2.5.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -16,19 +16,19 @@ import { EthereumProvider } from "@walletconnect/ethereum-provider";
16
16
  const provider = await EthereumProvider.init({
17
17
  projectId, // REQUIRED your projectId
18
18
  chains, // REQUIRED chain ids
19
+ showQrModal, // REQUIRED set to "true" to use @web3modal/standalone,
19
20
  methods, // OPTIONAL ethereum methods
20
21
  events, // OPTIONAL ethereum events
21
22
  rpcMap, // OPTIONAL rpc urls for each chain
22
23
  metadata, // OPTIONAL metadata of your app
23
- showQrModal, // OPTIONAL - `true` by default,
24
- qrModalOptions, // OPTIONAL - `undefined` by default, see https://docs.walletconnect.com/2.0/web3modal/theming
24
+ qrModalOptions, // OPTIONAL - `undefined` by default, see https://docs.walletconnect.com/2.0/web3modal/options
25
25
  });
26
26
  ```
27
27
 
28
28
  ## Display Web3Modal with QR code / Handle connection URI
29
29
 
30
30
  ```typescript
31
- // Web3Modal is enabled by default and will display a QR code modal
31
+ // Web3Modal is disabled by default, enable it during init() to display a QR code modal
32
32
  await provider.connect({
33
33
  chains, // OPTIONAL chain ids
34
34
  rpcMap, // OPTIONAL rpc urls
@@ -39,7 +39,7 @@ await provider.enable();
39
39
  ```
40
40
 
41
41
  ```typescript
42
- // If you wish to disable the built-in modal via `showQrModal`,
42
+ // If you are not using Web3Modal,
43
43
  // you can subscribe to the `display_uri` event and handle the URI yourself.
44
44
  provider.on("display_uri", (uri: string) => {
45
45
  // ... custom logic
@@ -76,3 +76,18 @@ provider.on("display_uri", handler);
76
76
  // session disconnect
77
77
  provider.on("disconnect", handler);
78
78
  ```
79
+
80
+ ## Supported Web3Modal options (qrModalOptions)
81
+
82
+ - [themeMode](https://docs.walletconnect.com/2.0/web3modal/options#thememode-optional)
83
+ - [themeVariables](https://docs.walletconnect.com/2.0/web3modal/options#themevariables-optional)
84
+ - [chainImages](https://docs.walletconnect.com/2.0/web3modal/options#chainimages-optional)
85
+ - [tokenImages](https://docs.walletconnect.com/2.0/web3modal/options#tokenimages-optional)
86
+ - [walletImages](https://docs.walletconnect.com/2.0/web3modal/options#walletimages-optional)
87
+ - [desktopWallets](https://docs.walletconnect.com/2.0/web3modal/options#desktopwallets-optional)
88
+ - [mobileWallets](https://docs.walletconnect.com/2.0/web3modal/options#mobilewallets-optional)
89
+ - [enableExplorer](https://docs.walletconnect.com/2.0/web3modal/options#enableexplorer-optional)
90
+ - [explorerAllowList](https://docs.walletconnect.com/2.0/web3modal/options#explorerallowlist-optional)
91
+ - [explorerDenyList](https://docs.walletconnect.com/2.0/web3modal/options#explorerdenylist-optional)
92
+ - [privacyPolicyUrl](https://docs.walletconnect.com/2.0/web3modal/options#privacypolicyurl-optional)
93
+ - [termsOfServiceUrl](https://docs.walletconnect.com/2.0/web3modal/options#privacypolicyurl-optional)