@tonconnect/sdk 0.0.15 → 0.0.16

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.
Files changed (2) hide show
  1. package/README.md +4 -30
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -33,9 +33,9 @@ connector.onStatusChange(
33
33
  TonConnect is build to support different wallets. You can fetch all supported wallets list and show a custom wallet selection dialog for user
34
34
 
35
35
  ```ts
36
- const { allWalletsList, injectedWalletsList, remoteConnectionWalletsList } = await connector.walletsList.getWalletsConfig();
36
+ const walletsList = await connector.getWallets();
37
37
 
38
- /* allWalletsList is
38
+ /* walletsList is
39
39
  {
40
40
  name: string;
41
41
  imageUrl: string;
@@ -44,38 +44,12 @@ const { allWalletsList, injectedWalletsList, remoteConnectionWalletsList } = awa
44
44
  universalLinkBase?: string;
45
45
  bridgeUrl?: string;
46
46
  jsBridgeKey?: string;
47
- }[]
48
-
49
- injectedWalletsList is (all injected to the page available wallets)
50
- {
51
- name: string;
52
- imageUrl: string;
53
- tondns?: string;
54
- aboutUrl: string;
55
- jsBridgeKey: string;
56
- }[]
57
-
58
- remoteConnectionWalletsList is (all wallets available via http bridge (QR code))
59
- {
60
- name: string;
61
- imageUrl: string;
62
- tondns?: string;
63
- aboutUrl: string;
64
- universalLinkBase: string;
65
- bridgeUrl: string;
47
+ injected?: boolean; // true if this wallet is injected to the webpage
48
+ embedded?: boolean; // true if dapp is opened inside this wallet's browser
66
49
  }[]
67
50
  */
68
51
  ```
69
52
 
70
- ### Check if your app is opened inside some wallet's browser
71
-
72
- If your app is opened inside some wallet's browser you shouldn't show a wallet selection dialog. Just connect dapp to the host-wallet when 'connect' button is clicked
73
-
74
- ```ts
75
- const walletConnectionSourceOrNull = await connector.inWhichWalletBrowser();
76
- ```
77
-
78
-
79
53
  ## Initialize a wallet connection when user clicks to 'connect' button in your app
80
54
  ### Initialize a remote wallet connection via universal link
81
55
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tonconnect/sdk",
3
- "version": "0.0.15",
3
+ "version": "0.0.16",
4
4
  "scripts": {
5
5
  "build": "npx rimraf lib && ttsc",
6
6
  "build:production": "npx rimraf lib && ttsc --sourceMap false"