@dynamic-labs/wallet-book 2.0.0-alpha.27 → 2.0.0-alpha.29

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/CHANGELOG.md CHANGED
@@ -1,4 +1,32 @@
1
1
 
2
+ ## [2.0.0-alpha.29](https://github.com/dynamic-labs/DynamicAuth/compare/v2.0.0-alpha.28...v2.0.0-alpha.29) (2024-04-10)
3
+
4
+
5
+ ### ⚠ BREAKING CHANGES
6
+
7
+ * replace sdk-api with sdk-api-core (#5280)
8
+
9
+ ### Features
10
+
11
+ * add dynamic client context ([#5250](https://github.com/dynamic-labs/DynamicAuth/issues/5250)) ([778ebe6](https://github.com/dynamic-labs/DynamicAuth/commit/778ebe6313e0bf3c9876feb6eff5bf152c15c55e))
12
+ * **webview-controller:** fetch manifest and render Dynamic SDK ([#5287](https://github.com/dynamic-labs/DynamicAuth/issues/5287)) ([00e84ac](https://github.com/dynamic-labs/DynamicAuth/commit/00e84acc4bdda92bad91108788f8d7882d0790d6))
13
+
14
+
15
+ ### Bug Fixes
16
+
17
+ * don't render modal header component if there's no content ([#5269](https://github.com/dynamic-labs/DynamicAuth/issues/5269)) ([f4d7266](https://github.com/dynamic-labs/DynamicAuth/commit/f4d72668a5243108649774c6581733655f385cab))
18
+ * don't show get extension button when there are no download links ([#5276](https://github.com/dynamic-labs/DynamicAuth/issues/5276)) ([e8cf660](https://github.com/dynamic-labs/DynamicAuth/commit/e8cf66076a9914881a8edda69feb2fb192ac63a3))
19
+
20
+
21
+ * replace sdk-api with sdk-api-core ([#5280](https://github.com/dynamic-labs/DynamicAuth/issues/5280)) ([da4b695](https://github.com/dynamic-labs/DynamicAuth/commit/da4b6955a81d6bfb5c994cd62e21e9ae11a4f454))
22
+
23
+ ## [2.0.0-alpha.28](https://github.com/dynamic-labs/DynamicAuth/compare/v2.0.0-alpha.27...v2.0.0-alpha.28) (2024-04-10)
24
+
25
+
26
+ ### Bug Fixes
27
+
28
+ * improve bridge connect experience on mobile ([#5283](https://github.com/dynamic-labs/DynamicAuth/issues/5283)) ([155e4a9](https://github.com/dynamic-labs/DynamicAuth/commit/155e4a99e2cf5f78a1a5e91e774acbf170d6b083))
29
+
2
30
  ## [2.0.0-alpha.27](https://github.com/dynamic-labs/DynamicAuth/compare/v2.0.0-alpha.26...v2.0.0-alpha.27) (2024-04-09)
3
31
 
4
32
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamic-labs/wallet-book",
3
- "version": "2.0.0-alpha.27",
3
+ "version": "2.0.0-alpha.29",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/dynamic-labs/DynamicAuth.git",
@@ -26,9 +26,9 @@
26
26
  },
27
27
  "dependencies": {
28
28
  "zod": "3.22.4",
29
- "@dynamic-labs/iconic": "2.0.0-alpha.27",
30
- "@dynamic-labs/logger": "2.0.0-alpha.27",
31
- "@dynamic-labs/utils": "2.0.0-alpha.27",
29
+ "@dynamic-labs/iconic": "2.0.0-alpha.29",
30
+ "@dynamic-labs/logger": "2.0.0-alpha.29",
31
+ "@dynamic-labs/utils": "2.0.0-alpha.29",
32
32
  "util": "0.12.5"
33
33
  },
34
34
  "peerDependencies": {
@@ -1,4 +1,12 @@
1
1
  export declare const walletConnectSourceData: Record<string, {
2
+ id: string;
3
+ metadata: {
4
+ shortName: string | null;
5
+ colors: {
6
+ primary: string | null;
7
+ secondary: string | null;
8
+ };
9
+ };
2
10
  name: string;
3
11
  chains: string[];
4
12
  desktop: {
@@ -28,7 +36,6 @@ export declare const walletConnectSourceData: Record<string, {
28
36
  category: string | null;
29
37
  description: string | null;
30
38
  homepage: string;
31
- id: string;
32
39
  image_id: string;
33
40
  image_url: {
34
41
  lg: string;
@@ -39,22 +46,15 @@ export declare const walletConnectSourceData: Record<string, {
39
46
  injected_id: string;
40
47
  namespace: string;
41
48
  }[] | null;
42
- metadata: {
43
- shortName: string | null;
44
- colors: {
45
- primary: string | null;
46
- secondary: string | null;
47
- };
48
- };
49
49
  slug: string;
50
50
  updatedAt: string;
51
51
  versions: string[];
52
52
  supported_standards?: {
53
53
  id: string;
54
- standard_id: number;
55
- standard_prefix: string;
56
54
  title: string;
57
55
  url: string;
56
+ standard_id: number;
57
+ standard_prefix: string;
58
58
  }[] | undefined;
59
59
  }>;
60
60
  export declare const walletConnectTransformedData: Promise<Record<string, {
@@ -2,13 +2,13 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const getWalletBookWallet = (walletBook, walletKey) => {
6
- var _a, _b;
5
+ const getWalletBookWallet = (walletBook, walletKey, walletFallback) => {
6
+ var _a, _b, _c;
7
7
  if (!walletKey)
8
8
  throw new Error('Wallet key is required. Please pass in a wallet key to getWalletBookWallet');
9
- const walletData = (_a = walletBook === null || walletBook === void 0 ? void 0 : walletBook.wallets) === null || _a === void 0 ? void 0 : _a[walletKey];
9
+ const walletData = (_b = (_a = walletBook === null || walletBook === void 0 ? void 0 : walletBook.wallets) === null || _a === void 0 ? void 0 : _a[walletKey]) !== null && _b !== void 0 ? _b : walletFallback;
10
10
  if (!walletData) {
11
- throw new Error(`Wallet ${walletKey} not found in wallet book (${Object.keys((_b = walletBook === null || walletBook === void 0 ? void 0 : walletBook.wallets) !== null && _b !== void 0 ? _b : {}).length} wallets found)`);
11
+ throw new Error(`Wallet ${walletKey} not found in wallet book (${Object.keys((_c = walletBook === null || walletBook === void 0 ? void 0 : walletBook.wallets) !== null && _c !== void 0 ? _c : {}).length} wallets found)`);
12
12
  }
13
13
  return walletData;
14
14
  };
@@ -1,2 +1,2 @@
1
1
  import { WalletBookSchema, WalletSchema } from '../schemas';
2
- export declare const getWalletBookWallet: (walletBook: WalletBookSchema, walletKey: string | undefined) => WalletSchema;
2
+ export declare const getWalletBookWallet: (walletBook: WalletBookSchema, walletKey: string | undefined, walletFallback?: WalletSchema) => WalletSchema;
@@ -1,10 +1,10 @@
1
- const getWalletBookWallet = (walletBook, walletKey) => {
2
- var _a, _b;
1
+ const getWalletBookWallet = (walletBook, walletKey, walletFallback) => {
2
+ var _a, _b, _c;
3
3
  if (!walletKey)
4
4
  throw new Error('Wallet key is required. Please pass in a wallet key to getWalletBookWallet');
5
- const walletData = (_a = walletBook === null || walletBook === void 0 ? void 0 : walletBook.wallets) === null || _a === void 0 ? void 0 : _a[walletKey];
5
+ const walletData = (_b = (_a = walletBook === null || walletBook === void 0 ? void 0 : walletBook.wallets) === null || _a === void 0 ? void 0 : _a[walletKey]) !== null && _b !== void 0 ? _b : walletFallback;
6
6
  if (!walletData) {
7
- throw new Error(`Wallet ${walletKey} not found in wallet book (${Object.keys((_b = walletBook === null || walletBook === void 0 ? void 0 : walletBook.wallets) !== null && _b !== void 0 ? _b : {}).length} wallets found)`);
7
+ throw new Error(`Wallet ${walletKey} not found in wallet book (${Object.keys((_c = walletBook === null || walletBook === void 0 ? void 0 : walletBook.wallets) !== null && _c !== void 0 ? _c : {}).length} wallets found)`);
8
8
  }
9
9
  return walletData;
10
10
  };
@@ -953,13 +953,6 @@ var wallets = {
953
953
  }
954
954
  ],
955
955
  name: "UniSat"
956
- },
957
- zerodev: {
958
- brand: {
959
- alt: "Smart Wallet",
960
- spriteId: "smartwallet"
961
- },
962
- name: "ZeroDev"
963
956
  }
964
957
  };
965
958
  var walletBookFallbacks = {
@@ -949,13 +949,6 @@ var wallets = {
949
949
  }
950
950
  ],
951
951
  name: "UniSat"
952
- },
953
- zerodev: {
954
- brand: {
955
- alt: "Smart Wallet",
956
- spriteId: "smartwallet"
957
- },
958
- name: "ZeroDev"
959
952
  }
960
953
  };
961
954
  var walletBookFallbacks = {