@dynamic-labs/sdk-react-core 0.18.100-viem.3 → 0.18.100-viem.31

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 (165) hide show
  1. package/CHANGELOG.md +240 -0
  2. package/package.cjs +3 -3
  3. package/package.js +3 -3
  4. package/package.json +10 -10
  5. package/src/index.cjs +1 -2
  6. package/src/index.d.ts +1 -1
  7. package/src/index.js +1 -1
  8. package/src/lib/components/MenuList/Dropdown/Dropdown.cjs +1 -1
  9. package/src/lib/components/MenuList/Dropdown/Dropdown.js +1 -1
  10. package/src/lib/components/ModalHeaderBanner/ModalHeaderBanner.cjs +6 -2
  11. package/src/lib/components/ModalHeaderBanner/ModalHeaderBanner.d.ts +2 -1
  12. package/src/lib/components/ModalHeaderBanner/ModalHeaderBanner.js +6 -2
  13. package/src/lib/components/OTPVerificationView/OTPVerificationView.cjs +2 -2
  14. package/src/lib/components/OTPVerificationView/OTPVerificationView.d.ts +1 -0
  15. package/src/lib/components/OTPVerificationView/OTPVerificationView.js +2 -2
  16. package/src/lib/components/SignMessagePreview/SignMessagePreview.cjs +27 -0
  17. package/src/lib/components/SignMessagePreview/SignMessagePreview.d.ts +6 -0
  18. package/src/lib/components/SignMessagePreview/SignMessagePreview.js +23 -0
  19. package/src/lib/components/SignMessagePreview/SignMessagePreview.types.d.ts +8 -0
  20. package/src/lib/components/SignMessagePreview/components/SignTypedDataPreview/SignTypedDataPreview.cjs +44 -0
  21. package/src/lib/components/SignMessagePreview/components/SignTypedDataPreview/SignTypedDataPreview.d.ts +8 -0
  22. package/src/lib/components/SignMessagePreview/components/SignTypedDataPreview/SignTypedDataPreview.js +40 -0
  23. package/src/lib/components/SignMessagePreview/components/SignTypedDataPreview/index.d.ts +1 -0
  24. package/src/lib/components/SignMessagePreview/components/index.d.ts +1 -0
  25. package/src/lib/components/SignMessagePreview/index.d.ts +1 -0
  26. package/src/lib/components/SignMessagePreview/utils/index.d.ts +1 -0
  27. package/src/lib/components/SignMessagePreview/utils/isSignTypedData/index.d.ts +1 -0
  28. package/src/lib/components/SignMessagePreview/utils/isSignTypedData/isSignTypedData.cjs +17 -0
  29. package/src/lib/components/SignMessagePreview/utils/isSignTypedData/isSignTypedData.d.ts +2 -0
  30. package/src/lib/components/SignMessagePreview/utils/isSignTypedData/isSignTypedData.js +13 -0
  31. package/src/lib/components/Typography/Typography.cjs +1 -0
  32. package/src/lib/components/Typography/Typography.js +1 -0
  33. package/src/lib/components/Typography/Typography.types.d.ts +1 -1
  34. package/src/lib/components/UserProfile/UserProfile.cjs +1 -1
  35. package/src/lib/components/UserProfile/UserProfile.js +1 -1
  36. package/src/lib/components/UserProfile/parts/UserProfileSocialAccount/UserProfileSocialAccount.cjs +1 -1
  37. package/src/lib/components/UserProfile/parts/UserProfileSocialAccount/UserProfileSocialAccount.js +1 -1
  38. package/src/lib/components/index.d.ts +1 -0
  39. package/src/lib/context/DynamicContext/DynamicContext.cjs +20 -6
  40. package/src/lib/context/DynamicContext/DynamicContext.d.ts +11 -1
  41. package/src/lib/context/DynamicContext/DynamicContext.js +21 -7
  42. package/src/lib/context/DynamicContext/helpers.cjs +42 -3
  43. package/src/lib/context/DynamicContext/helpers.d.ts +7 -1
  44. package/src/lib/context/DynamicContext/helpers.js +38 -4
  45. package/src/lib/context/DynamicContext/hooks/useSetShowAuthFlowWithInit/useSetShowAuthFlowWithInit.cjs +5 -2
  46. package/src/lib/context/DynamicContext/hooks/useSetShowAuthFlowWithInit/useSetShowAuthFlowWithInit.d.ts +4 -2
  47. package/src/lib/context/DynamicContext/hooks/useSetShowAuthFlowWithInit/useSetShowAuthFlowWithInit.js +5 -2
  48. package/src/lib/context/DynamicContext/internalEvents/index.d.ts +2 -0
  49. package/src/lib/context/DynamicContext/internalEvents/internalEvents.cjs +14 -0
  50. package/src/lib/context/DynamicContext/internalEvents/internalEvents.d.ts +8 -0
  51. package/src/lib/context/DynamicContext/internalEvents/internalEvents.js +6 -0
  52. package/src/lib/context/DynamicContext/types/index.d.ts +7 -1
  53. package/src/lib/context/DynamicContext/useDynamicContext.cjs +2 -1
  54. package/src/lib/context/DynamicContext/useDynamicContext.d.ts +1 -1
  55. package/src/lib/context/DynamicContext/useDynamicContext.js +2 -1
  56. package/src/lib/context/ErrorContext/ErrorContext.cjs +1 -0
  57. package/src/lib/context/ErrorContext/ErrorContext.js +1 -0
  58. package/src/lib/context/SocialRedirectContext/SocialRedirectContext.cjs +33 -7
  59. package/src/lib/context/SocialRedirectContext/SocialRedirectContext.js +33 -7
  60. package/src/lib/context/ViewContext/ViewContext.d.ts +1 -1
  61. package/src/lib/context/WalletContext/WalletContext.cjs +2 -16
  62. package/src/lib/context/WalletContext/WalletContext.js +2 -16
  63. package/src/lib/data/api.cjs +20 -12
  64. package/src/lib/data/api.d.ts +3 -2
  65. package/src/lib/data/api.js +20 -12
  66. package/src/lib/main.global.cjs +1 -1
  67. package/src/lib/main.global.js +1 -1
  68. package/src/lib/modals/SignMessageConfirmationModal/SignMessageConfirmationModal.cjs +2 -1
  69. package/src/lib/modals/SignMessageConfirmationModal/SignMessageConfirmationModal.js +2 -1
  70. package/src/lib/modals/TransactionConfirmationModal/TransactionConfirmationModal.cjs +2 -1
  71. package/src/lib/modals/TransactionConfirmationModal/TransactionConfirmationModal.js +2 -1
  72. package/src/lib/shared/types/index.d.ts +4 -0
  73. package/src/lib/shared/utils/hooks/usePreventPageScroll/usePreventPageScroll.cjs +28 -2
  74. package/src/lib/shared/utils/hooks/usePreventPageScroll/usePreventPageScroll.js +28 -2
  75. package/src/lib/styles/index.shadow.cjs +1 -1
  76. package/src/lib/styles/index.shadow.js +1 -1
  77. package/src/lib/utils/constants/localStorage.cjs +4 -0
  78. package/src/lib/utils/constants/localStorage.d.ts +2 -0
  79. package/src/lib/utils/constants/localStorage.js +3 -1
  80. package/src/lib/utils/functions/createUserProfile/createUserProfile.cjs +1 -1
  81. package/src/lib/utils/functions/createUserProfile/createUserProfile.js +1 -1
  82. package/src/lib/utils/functions/getDynamicLayoutData/getDynamicLayoutData.cjs +6 -1
  83. package/src/lib/utils/functions/getDynamicLayoutData/getDynamicLayoutData.js +6 -1
  84. package/src/lib/utils/functions/getProviderByType/getProviderByType.cjs +7 -0
  85. package/src/lib/utils/functions/getProviderByType/getProviderByType.d.ts +2 -0
  86. package/src/lib/utils/functions/getProviderByType/getProviderByType.js +3 -0
  87. package/src/lib/utils/functions/getProviderByType/index.d.ts +1 -0
  88. package/src/lib/utils/functions/index.d.ts +2 -0
  89. package/src/lib/utils/functions/sendTransactionWithAutoNonce/index.d.ts +1 -0
  90. package/src/lib/utils/functions/sendTransactionWithAutoNonce/sendTransactionWithAutoNonce.cjs +48 -0
  91. package/src/lib/utils/functions/sendTransactionWithAutoNonce/sendTransactionWithAutoNonce.d.ts +18 -0
  92. package/src/lib/utils/functions/sendTransactionWithAutoNonce/sendTransactionWithAutoNonce.js +43 -0
  93. package/src/lib/utils/hooks/authenticationHooks/useConnectAndSign/useConnectAndSign.cjs +10 -5
  94. package/src/lib/utils/hooks/authenticationHooks/useConnectAndSign/useConnectAndSign.js +10 -5
  95. package/src/lib/utils/hooks/authenticationHooks/useSignConnectOnlyUser/useSignConnectOnlyUser.cjs +6 -2
  96. package/src/lib/utils/hooks/authenticationHooks/useSignConnectOnlyUser/useSignConnectOnlyUser.js +6 -2
  97. package/src/lib/utils/hooks/multiWallet/useSyncPrimaryWallet/useSyncPrimaryWallet.cjs +13 -4
  98. package/src/lib/utils/hooks/multiWallet/useSyncPrimaryWallet/useSyncPrimaryWallet.d.ts +1 -19
  99. package/src/lib/utils/hooks/multiWallet/useSyncPrimaryWallet/useSyncPrimaryWallet.js +13 -4
  100. package/src/lib/utils/hooks/useConnectWallet/useConnectWallet.cjs +22 -32
  101. package/src/lib/utils/hooks/useConnectWallet/useConnectWallet.d.ts +1 -2
  102. package/src/lib/utils/hooks/useConnectWallet/useConnectWallet.js +23 -33
  103. package/src/lib/utils/hooks/useConnectedWalletsNetworkValidation/useConnectedWalletsNetworkValidation.cjs +7 -6
  104. package/src/lib/utils/hooks/useConnectedWalletsNetworkValidation/useConnectedWalletsNetworkValidation.js +7 -6
  105. package/src/lib/utils/hooks/useFetchProjectSettings/useFetchProjectSettings.cjs +10 -1
  106. package/src/lib/utils/hooks/useFetchProjectSettings/useFetchProjectSettings.js +10 -1
  107. package/src/lib/utils/hooks/useHandleWalletsToConnect/useHandleWalletsToConnect.cjs +15 -1
  108. package/src/lib/utils/hooks/useHandleWalletsToConnect/useHandleWalletsToConnect.js +15 -1
  109. package/src/lib/utils/hooks/usePrimaryWalletId/usePrimaryWalletId.cjs +6 -2
  110. package/src/lib/utils/hooks/usePrimaryWalletId/usePrimaryWalletId.d.ts +2 -1
  111. package/src/lib/utils/hooks/usePrimaryWalletId/usePrimaryWalletId.js +6 -2
  112. package/src/lib/utils/hooks/useSocialAccounts/useSocialAccounts.cjs +94 -16
  113. package/src/lib/utils/hooks/useSocialAccounts/useSocialAccounts.d.ts +5 -1
  114. package/src/lib/utils/hooks/useSocialAccounts/useSocialAccounts.js +94 -16
  115. package/src/lib/utils/hooks/useUserUpdateRequest/useUserUpdateRequest.cjs +5 -1
  116. package/src/lib/utils/hooks/useUserUpdateRequest/useUserUpdateRequest.js +5 -1
  117. package/src/lib/utils/hooks/useVerifyWallet/useVerifyWallet.cjs +13 -3
  118. package/src/lib/utils/hooks/useVerifyWallet/useVerifyWallet.js +13 -3
  119. package/src/lib/utils/hooks/useWallets/useWallets.cjs +20 -26
  120. package/src/lib/utils/hooks/useWallets/useWallets.d.ts +3 -2
  121. package/src/lib/utils/hooks/useWallets/useWallets.js +21 -27
  122. package/src/lib/views/CollectUserDataView/OnboardingUserDataForm/OnboardingUserDataForm.cjs +3 -3
  123. package/src/lib/views/CollectUserDataView/OnboardingUserDataForm/OnboardingUserDataForm.js +3 -3
  124. package/src/lib/views/EmailWalletOTPVerificationView/EmailWalletOTPVerificationView.cjs +1 -1
  125. package/src/lib/views/EmailWalletOTPVerificationView/EmailWalletOTPVerificationView.js +1 -1
  126. package/src/lib/views/LoginWithEmailView/components/SocialSignIn/SocialSignIn.cjs +1 -1
  127. package/src/lib/views/LoginWithEmailView/components/SocialSignIn/SocialSignIn.js +1 -1
  128. package/src/lib/views/NetworkNotSupported/NetworkNotSupported.cjs +3 -2
  129. package/src/lib/views/NetworkNotSupported/NetworkNotSupported.js +3 -2
  130. package/src/lib/views/NetworkNotSupportedSwitchManual/NetworkNotSupportedSwitchManual.cjs +3 -2
  131. package/src/lib/views/NetworkNotSupportedSwitchManual/NetworkNotSupportedSwitchManual.js +3 -2
  132. package/src/lib/views/SendBalanceView/SendBalanceView.cjs +19 -3
  133. package/src/lib/views/SendBalanceView/SendBalanceView.js +19 -3
  134. package/src/lib/views/SendBalanceView/components/TransactionStage/TransactionStage.cjs +4 -16
  135. package/src/lib/views/SendBalanceView/components/TransactionStage/TransactionStage.d.ts +2 -0
  136. package/src/lib/views/SendBalanceView/components/TransactionStage/TransactionStage.js +5 -17
  137. package/src/lib/views/WalletGroupView/components/WalletGroupItem/WalletGroupItem.cjs +1 -0
  138. package/src/lib/views/WalletGroupView/components/WalletGroupItem/WalletGroupItem.js +1 -0
  139. package/src/lib/views/WalletList/WalletListItem/WalletListItem.cjs +1 -1
  140. package/src/lib/views/WalletList/WalletListItem/WalletListItem.js +1 -1
  141. package/src/lib/views/WalletList/data.cjs +2 -14
  142. package/src/lib/views/WalletList/data.d.ts +4 -2
  143. package/src/lib/views/WalletList/data.js +2 -13
  144. package/src/lib/views/viewToComponentMap.cjs +1 -0
  145. package/src/lib/views/viewToComponentMap.js +1 -0
  146. package/src/lib/widgets/DynamicBridgeWidget/views/EditProfileView/EditProfileView.cjs +3 -3
  147. package/src/lib/widgets/DynamicBridgeWidget/views/EditProfileView/EditProfileView.js +3 -3
  148. package/src/lib/widgets/DynamicWidget/DynamicWidget.cjs +2 -2
  149. package/src/lib/widgets/DynamicWidget/DynamicWidget.js +3 -3
  150. package/src/lib/widgets/DynamicWidget/components/DynamicNav/DynamicNav.cjs +36 -1
  151. package/src/lib/widgets/DynamicWidget/components/DynamicNav/DynamicNav.js +36 -1
  152. package/src/lib/widgets/DynamicWidget/components/DynamicUserProfile/DynamicUserProfile.cjs +2 -2
  153. package/src/lib/widgets/DynamicWidget/components/DynamicUserProfile/DynamicUserProfile.js +2 -2
  154. package/src/lib/widgets/DynamicWidget/context/DynamicWidgetContext.cjs +7 -10
  155. package/src/lib/widgets/DynamicWidget/context/DynamicWidgetContext.d.ts +1 -0
  156. package/src/lib/widgets/DynamicWidget/context/DynamicWidgetContext.js +8 -11
  157. package/src/lib/widgets/DynamicWidget/hooks/index.d.ts +1 -0
  158. package/src/lib/widgets/DynamicWidget/hooks/useViewController/index.d.ts +1 -0
  159. package/src/lib/widgets/DynamicWidget/hooks/useViewController/useViewController.cjs +17 -0
  160. package/src/lib/widgets/DynamicWidget/hooks/useViewController/useViewController.d.ts +6 -0
  161. package/src/lib/widgets/DynamicWidget/hooks/useViewController/useViewController.js +13 -0
  162. package/src/lib/widgets/DynamicWidget/views/EditProfileView/EditProfileView.cjs +3 -3
  163. package/src/lib/widgets/DynamicWidget/views/EditProfileView/EditProfileView.js +3 -3
  164. package/src/lib/widgets/DynamicWidget/views/SendBalanceWidgetView/SendBalanceWidgetView.cjs +2 -3
  165. package/src/lib/widgets/DynamicWidget/views/SendBalanceWidgetView/SendBalanceWidgetView.js +2 -3
package/CHANGELOG.md CHANGED
@@ -1,4 +1,244 @@
1
1
 
2
+ ### [0.18.100-viem.31](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.30...v0.18.100-viem.31) (2023-12-14)
3
+
4
+
5
+ ### Bug Fixes
6
+
7
+ * update wagmi to v1.4.12 to fix ledger security issue ([#4181](https://github.com/dynamic-labs/DynamicAuth/issues/4181)) ([05e120e](https://github.com/dynamic-labs/DynamicAuth/commit/05e120eb3d636927094ed47abe63a077924ba91b))
8
+
9
+ ### [0.18.100-viem.30](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.29...v0.18.100-viem.30) (2023-11-27)
10
+
11
+
12
+ ### Bug Fixes
13
+
14
+ * handle origin_check message from authWindow ([#3993](https://github.com/dynamic-labs/DynamicAuth/issues/3993)) ([9b5a030](https://github.com/dynamic-labs/DynamicAuth/commit/9b5a030a52cbc45ed35353bf3e478c489184c864))
15
+
16
+ ### [0.18.100-viem.29](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.28...v0.18.100-viem.29) (2023-11-22)
17
+
18
+
19
+ ### Bug Fixes
20
+
21
+ * allow metadata to be updated in updateUser hook ([#3947](https://github.com/dynamic-labs/DynamicAuth/issues/3947)) ([d6a3591](https://github.com/dynamic-labs/DynamicAuth/commit/d6a35918327b095d1a715942bc84cd9763e6864d))
22
+ * null safe check to window object ([#3919](https://github.com/dynamic-labs/DynamicAuth/issues/3919)) ([e466964](https://github.com/dynamic-labs/DynamicAuth/commit/e4669644c451139d443e534df238602d18fcda07))
23
+ * only process oauth message coming from the expected origin ([#3812](https://github.com/dynamic-labs/DynamicAuth/issues/3812)) ([ff98948](https://github.com/dynamic-labs/DynamicAuth/commit/ff98948b5415967ad3769887bb95d9c6d353a0c6))
24
+
25
+ ### [0.18.100-viem.28](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.27...v0.18.100-viem.28) (2023-10-30)
26
+
27
+
28
+ ### Bug Fixes
29
+
30
+ * better handling of Coinbase wallet disconnect + upgrade to 3.7.2 ([#3691](https://github.com/dynamic-labs/DynamicAuth/issues/3691)) ([2385af8](https://github.com/dynamic-labs/DynamicAuth/commit/2385af8e960c3c3a23d2ce3379c50668a88b0478))
31
+ * Fix send balance in multiple chains ([#3767](https://github.com/dynamic-labs/DynamicAuth/issues/3767)) ([724d650](https://github.com/dynamic-labs/DynamicAuth/commit/724d650965a4e8cc864a1eeb787646399fce3814))
32
+ * safely render message to sign ([#3655](https://github.com/dynamic-labs/DynamicAuth/issues/3655)) ([#3661](https://github.com/dynamic-labs/DynamicAuth/issues/3661)) ([8ddc30a](https://github.com/dynamic-labs/DynamicAuth/commit/8ddc30a9b43e5ef47fedcaa58e9b20a9528b8cc6))
33
+
34
+ ### [0.18.100-viem.27](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.26...v0.18.100-viem.27) (2023-10-19)
35
+
36
+
37
+ ### Bug Fixes
38
+
39
+ * fix: don't show user profile when reconnecting a primary social wallet ([#3619](https://github.com/dynamic-labs/DynamicAuth/issues/3619)) ([88a9667](https://github.com/dynamic-labs/DynamicAuth/commit/88a9667c7d51a9792bfbffc13c1dca4eedb6f5eb)), closes [#3614](https://github.com/dynamic-labs/DynamicAuth/issues/3614)
40
+
41
+ ### [0.18.100-viem.26](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.25...v0.18.100-viem.26) (2023-10-14)
42
+
43
+
44
+ ### Bug Fixes
45
+
46
+ * support argentX in-browser wallet ([#3601](https://github.com/dynamic-labs/DynamicAuth/issues/3601)) ([b7bd4a8](https://github.com/dynamic-labs/DynamicAuth/commit/b7bd4a80f8c0928e9515151b570cdf88a6731109))
47
+
48
+ ### [0.18.100-viem.25](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.24...v0.18.100-viem.25) (2023-10-12)
49
+
50
+
51
+ ### Bug Fixes
52
+
53
+ * **wagmi-connector:** use wallets list to sync wagmi client ([#3563](https://github.com/dynamic-labs/DynamicAuth/issues/3563)) ([#3581](https://github.com/dynamic-labs/DynamicAuth/issues/3581)) ([c15cd2c](https://github.com/dynamic-labs/DynamicAuth/commit/c15cd2cbc4dfb68c4eb407401020fc0680701a33))
54
+
55
+ ### [0.18.100-viem.24](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.23...v0.18.100-viem.24) (2023-10-03)
56
+
57
+
58
+ ### Bug Fixes
59
+
60
+ * fix PopperProvider error when using DynamicNav ([#3486](https://github.com/dynamic-labs/DynamicAuth/issues/3486)) ([8a7dd27](https://github.com/dynamic-labs/DynamicAuth/commit/8a7dd27e0e29cd811e95b7c48d241d6ea1adce4e))
61
+
62
+ ### [0.18.100-viem.23](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.22...v0.18.100-viem.23) (2023-09-30)
63
+
64
+
65
+ ### Bug Fixes
66
+
67
+ * css variables for the ConnectButton are being ignored ([#2856](https://github.com/dynamic-labs/DynamicAuth/issues/2856)) ([#3480](https://github.com/dynamic-labs/DynamicAuth/issues/3480)) ([3885c73](https://github.com/dynamic-labs/DynamicAuth/commit/3885c7390cc5b2ef94ecf67478c55459fad7374e))
68
+
69
+ ### [0.18.100-viem.22](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.21...v0.18.100-viem.22) (2023-09-28)
70
+
71
+ ### [0.18.100-viem.21](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.20...v0.18.100-viem.21) (2023-09-28)
72
+
73
+
74
+ ### Bug Fixes
75
+
76
+ * better handling for starknet account changed event ([#3441](https://github.com/dynamic-labs/DynamicAuth/issues/3441)) ([#3453](https://github.com/dynamic-labs/DynamicAuth/issues/3453)) ([0d1fd05](https://github.com/dynamic-labs/DynamicAuth/commit/0d1fd05e365bd060dbf4d5a30dcfad1fff5b31ca))
77
+ * wait for networks to fetch wallets ([#3430](https://github.com/dynamic-labs/DynamicAuth/issues/3430)) ([69cac51](https://github.com/dynamic-labs/DynamicAuth/commit/69cac51479c7c8789bab7f8311c7c34dd5cf67fc))
78
+
79
+ ### [0.18.100-viem.20](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.19...v0.18.100-viem.20) (2023-09-25)
80
+
81
+
82
+ ### Bug Fixes
83
+
84
+ * signing messages with backpack ([#3400](https://github.com/dynamic-labs/DynamicAuth/issues/3400)) ([f3231d8](https://github.com/dynamic-labs/DynamicAuth/commit/f3231d82c739ccd40ac9de6a33a0a1dd116145bf))
85
+
86
+ ### [0.18.100-viem.19](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.18...v0.18.100-viem.19) (2023-09-22)
87
+
88
+
89
+ ### Bug Fixes
90
+
91
+ * pass the network param on wallet transfers ([#3307](https://github.com/dynamic-labs/DynamicAuth/issues/3307)) ([#3385](https://github.com/dynamic-labs/DynamicAuth/issues/3385)) ([d003423](https://github.com/dynamic-labs/DynamicAuth/commit/d00342377fe1cd9605f37e54edb647378edd45d5))
92
+
93
+ ### [0.18.100-viem.18](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.17...v0.18.100-viem.18) (2023-09-20)
94
+
95
+
96
+ ### Bug Fixes
97
+
98
+ * show default wallet icon when no image is available ([#3291](https://github.com/dynamic-labs/DynamicAuth/issues/3291)) ([b541d00](https://github.com/dynamic-labs/DynamicAuth/commit/b541d002a0f6ff2e409034341e6e2191d6d3ac7f))
99
+ * display user profile when closing send balance ([#3333](https://github.com/dynamic-labs/DynamicAuth/issues/3333)) ([#3337](https://github.com/dynamic-labs/DynamicAuth/issues/3337)) ([5b3e665](https://github.com/dynamic-labs/DynamicAuth/commit/5b3e665a6ebfc0b46b84c787634d2e27bc4a9270))
100
+ * display sign typed data message for confirmation ([#3328](https://github.com/dynamic-labs/DynamicAuth/issues/3328)) ([2b93473](https://github.com/dynamic-labs/DynamicAuth/commit/2b93473024e277072be32a17c5513168b85d13f9))
101
+ * remove async from getWeb3Provider method in Magic connector ([#3281](https://github.com/dynamic-labs/DynamicAuth/issues/3281)) ([1d949c1](https://github.com/dynamic-labs/DynamicAuth/commit/1d949c18df8d5453f057f61b0c54ac16de1fbb76))
102
+ * fixes unlinking oauth account from multi wallet panel ([#3344](https://github.com/dynamic-labs/DynamicAuth/issues/3344)) ([87d08d6](https://github.com/dynamic-labs/DynamicAuth/commit/87d08d667f7bb82fcbadcf651a99c08acfdabf1e))
103
+ * prevent wallet connect v2 from redirect user to last known wallet after logout ([#3354](https://github.com/dynamic-labs/DynamicAuth/issues/3354)) ([dd39b13](https://github.com/dynamic-labs/DynamicAuth/commit/dd39b136af95667d1bf81586034eee5dc9c385db))
104
+
105
+ ### [0.18.100-viem.17](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.16...v0.18.100-viem.17) (2023-09-11)
106
+
107
+
108
+ ### Bug Fixes
109
+
110
+ * remove react component props from sending to sdk api v18-viem ([#3287](https://github.com/dynamic-labs/DynamicAuth/issues/3287)) ([18e7617](https://github.com/dynamic-labs/DynamicAuth/commit/18e76179b3287cc9ca60efc2771e072bb87667ba)), closes [#3282](https://github.com/dynamic-labs/DynamicAuth/issues/3282)
111
+
112
+ ### [0.18.100-viem.16](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.15...v0.18.100-viem.16) (2023-09-11)
113
+
114
+
115
+ ### Bug Fixes
116
+
117
+ * catch error sending sdkSettings and log warning v18-viem ([#3277](https://github.com/dynamic-labs/DynamicAuth/issues/3277)) ([af86753](https://github.com/dynamic-labs/DynamicAuth/commit/af86753f4b73c0ec4ba981c9ffd47af21fac9d8d)), closes [#3274](https://github.com/dynamic-labs/DynamicAuth/issues/3274)
118
+ * issue where unexpected token would occur when bundlers defined process.env ([#3283](https://github.com/dynamic-labs/DynamicAuth/issues/3283)) ([16110f9](https://github.com/dynamic-labs/DynamicAuth/commit/16110f90f02841104b053365b17343ed80a72018))
119
+ * seprate ls checks for dynamiccontext and wagmi settings v18-viem ([#3279](https://github.com/dynamic-labs/DynamicAuth/issues/3279)) ([e31d85e](https://github.com/dynamic-labs/DynamicAuth/commit/e31d85e576d0fba31616d6aa408316c261f42373)), closes [#3275](https://github.com/dynamic-labs/DynamicAuth/issues/3275)
120
+
121
+ ### [0.18.100-viem.15](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.14...v0.18.100-viem.15) (2023-09-11)
122
+
123
+
124
+ ### Bug Fixes
125
+ * sdkSettings should call once per session ([#3189](https://github.com/dynamic-labs/DynamicAuth/issues/3189)) ([#3265](https://github.com/dynamic-labs/DynamicAuth/issues/3265)) ([f46a692](https://github.com/dynamic-labs/DynamicAuth/commit/f46a6927684caf5962e5b60a9927030a5f7720e2))
126
+ * wallet transition in the bridge ([#3268](https://github.com/dynamic-labs/DynamicAuth/issues/3268)) ([#3271](https://github.com/dynamic-labs/DynamicAuth/issues/3271)) ([95e6d5f](https://github.com/dynamic-labs/DynamicAuth/commit/95e6d5f6ff003ff428795bdd73e2d88da366ed56)), closes [#3243](https://github.com/dynamic-labs/DynamicAuth/issues/3243)
127
+
128
+ ### [0.18.100-viem.14](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.13...v0.18.100-viem.14) (2023-09-05)
129
+
130
+
131
+ ### Features
132
+
133
+ * add onSignedMessage callback ([#3214](https://github.com/dynamic-labs/DynamicAuth/issues/3214)) ([92fd070](https://github.com/dynamic-labs/DynamicAuth/commit/92fd070c8edabce5ed991cfd92b3745c7afb0b43))
134
+
135
+
136
+ ### Bug Fixes
137
+
138
+ * prefer mainnet chain id when connecting with WCv2 ([#3220](https://github.com/dynamic-labs/DynamicAuth/issues/3220)) ([55eb097](https://github.com/dynamic-labs/DynamicAuth/commit/55eb09739f4c8912a9de2198f69cd925923270c4))
139
+
140
+ ### [0.18.100-viem.13](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.12...v0.18.100-viem.13) (2023-09-01)
141
+
142
+
143
+ ### Features
144
+
145
+ * add option to disable the locked wallet view ([#3187](https://github.com/dynamic-labs/DynamicAuth/issues/3187)) ([aa70fb5](https://github.com/dynamic-labs/DynamicAuth/commit/aa70fb52bb185e27fdb311b0e0dd10166a83d60a))
146
+ * migrate starknet version to v5 ([#3198](https://github.com/dynamic-labs/DynamicAuth/issues/3198)) ([e5b24ea](https://github.com/dynamic-labs/DynamicAuth/commit/e5b24ea86ce58f83a539d8ef8adc6fb0c77bd51a))
147
+
148
+
149
+ ### Bug Fixes
150
+
151
+ * show the multi wallet list when opening the auth flow to authenticated users ([#3165](https://github.com/dynamic-labs/DynamicAuth/issues/3165)) ([b7a7110](https://github.com/dynamic-labs/DynamicAuth/commit/b7a71106a730925dc44abbd0e3aedf5ce3f5ca39)), closes [#3134](https://github.com/dynamic-labs/DynamicAuth/issues/3134) [#3152](https://github.com/dynamic-labs/DynamicAuth/issues/3152) [#3168](https://github.com/dynamic-labs/DynamicAuth/issues/3168)
152
+ * sign message for embedded wallet when auth mode is connect only ([#3195](https://github.com/dynamic-labs/DynamicAuth/issues/3195)) ([6cdee66](https://github.com/dynamic-labs/DynamicAuth/commit/6cdee661d45877c3d78744d115a675d114d62091))
153
+ * verify email OTP when email is updated ([#3168](https://github.com/dynamic-labs/DynamicAuth/issues/3168)) ([641eeb6](https://github.com/dynamic-labs/DynamicAuth/commit/641eeb685b0c9d77cc72912f29b137c699c192f0))
154
+
155
+ ### [0.18.100-viem.12](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.11...v0.18.100-viem.12) (2023-08-30)
156
+
157
+
158
+ ### Features
159
+
160
+ * add deepLinkPreference prop ([#3174](https://github.com/dynamic-labs/DynamicAuth/issues/3174)) ([#3177](https://github.com/dynamic-labs/DynamicAuth/issues/3177)) ([d5a4052](https://github.com/dynamic-labs/DynamicAuth/commit/d5a4052ce6547289fff08ba57728af227d334dfa))
161
+
162
+
163
+ ### Bug Fixes
164
+
165
+ * end connector session when unlinking from bridge ([#3120](https://github.com/dynamic-labs/DynamicAuth/issues/3120)) ([#3179](https://github.com/dynamic-labs/DynamicAuth/issues/3179)) ([d1f9898](https://github.com/dynamic-labs/DynamicAuth/commit/d1f9898fd678c9b342afe0dc1ea9ab21914c610f))
166
+ * **bridge:** update address when switching networks ([#3171](https://github.com/dynamic-labs/DynamicAuth/issues/3171)) ([#3181](https://github.com/dynamic-labs/DynamicAuth/issues/3181)) ([0e138e0](https://github.com/dynamic-labs/DynamicAuth/commit/0e138e0f824cda7e67f6ffce3057deb0a92ee7ae))
167
+
168
+ ### [0.18.100-viem.11](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.10...v0.18.100-viem.11) (2023-08-29)
169
+
170
+
171
+ ### Bug Fixes
172
+
173
+ * **bridge:** connect L2 wallet after updating network ([#3164](https://github.com/dynamic-labs/DynamicAuth/issues/3164)) ([b775408](https://github.com/dynamic-labs/DynamicAuth/commit/b775408f98c1436383ae781dffb4a832f86a7d0d))
174
+ * resend magic OTP on back click ([#3123](https://github.com/dynamic-labs/DynamicAuth/issues/3123)) ([#3151](https://github.com/dynamic-labs/DynamicAuth/issues/3151)) ([eee2b0c](https://github.com/dynamic-labs/DynamicAuth/commit/eee2b0c0db0d9538b39c8e6ee76baf36c3479af5))
175
+ * **WagmiConnector:** sync wagmi with wallet connector events ([#3160](https://github.com/dynamic-labs/DynamicAuth/issues/3160)) ([5618903](https://github.com/dynamic-labs/DynamicAuth/commit/561890334f4ae28ffaf40f02d793da75865a0885)), closes [#3149](https://github.com/dynamic-labs/DynamicAuth/issues/3149)
176
+
177
+ ### [0.18.100-viem.10](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.9...v0.18.100-viem.10) (2023-08-25)
178
+
179
+
180
+ ### Bug Fixes
181
+
182
+ * stop calling handleLogOut prematurely ([#3137](https://github.com/dynamic-labs/DynamicAuth/issues/3137)) ([3d029ba](https://github.com/dynamic-labs/DynamicAuth/commit/3d029ba3e34e3cb8a2b976dc5d3fb9ee1356d76c)), closes [#3135](https://github.com/dynamic-labs/DynamicAuth/issues/3135)
183
+
184
+ ### [0.18.100-viem.9](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.8...v0.18.100-viem.9) (2023-08-25)
185
+
186
+
187
+ ### Features
188
+
189
+ * register connection of second wallet in bridge ([3e12cde](https://github.com/dynamic-labs/DynamicAuth/commit/3e12cdece4abd717280aeed442999aef4653e059)), closes [#3113](https://github.com/dynamic-labs/DynamicAuth/issues/3113)
190
+
191
+
192
+ ### Bug Fixes
193
+
194
+ * fix github social linking icon on dark mode ([#3130](https://github.com/dynamic-labs/DynamicAuth/issues/3130)) ([8db8aa7](https://github.com/dynamic-labs/DynamicAuth/commit/8db8aa7b9892f93f6fb6aa7772f99b747fe8f86b)), closes [#3126](https://github.com/dynamic-labs/DynamicAuth/issues/3126)
195
+ * fix issue with detecting oauth window closed before finishing linking ([#3128](https://github.com/dynamic-labs/DynamicAuth/issues/3128)) ([b108bf9](https://github.com/dynamic-labs/DynamicAuth/commit/b108bf9d9b3ca47202ca4a1993f155639fd032a8)), closes [#3124](https://github.com/dynamic-labs/DynamicAuth/issues/3124)
196
+
197
+ ### [0.18.100-viem.8](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.7...v0.18.100-viem.8) (2023-08-24)
198
+
199
+
200
+ ### Bug Fixes
201
+
202
+ * allow overriding contracts on wagmi chains ([#3105](https://github.com/dynamic-labs/DynamicAuth/issues/3105)) ([acee314](https://github.com/dynamic-labs/DynamicAuth/commit/acee3147156c30957bdb690c56cfd10af13dc57f))
203
+ * send wagmi settings only once when DynamicWagmiConnector loads (v18-viem) ([#3109](https://github.com/dynamic-labs/DynamicAuth/issues/3109)) ([a6e2675](https://github.com/dynamic-labs/DynamicAuth/commit/a6e2675c49eab3c40dc9365b20ac2dd9eaf8e4ae)), closes [#3103](https://github.com/dynamic-labs/DynamicAuth/issues/3103)
204
+
205
+ ### [0.18.100-viem.7](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.6...v0.18.100-viem.7) (2023-08-23)
206
+
207
+
208
+ ### Bug Fixes
209
+
210
+ * fix jumping when entering OTP code on IOS ([#3036](https://github.com/dynamic-labs/DynamicAuth/issues/3036)) ([#3094](https://github.com/dynamic-labs/DynamicAuth/issues/3094)) ([093ab9a](https://github.com/dynamic-labs/DynamicAuth/commit/093ab9aae2f8bba99622e1146d1dc54c077ae3cb))
211
+ * log user out when magic session expires ([#3085](https://github.com/dynamic-labs/DynamicAuth/issues/3085)) ([#3088](https://github.com/dynamic-labs/DynamicAuth/issues/3088)) ([d7d125c](https://github.com/dynamic-labs/DynamicAuth/commit/d7d125c93a652f26deeedce534f1e0472ad3377c))
212
+ * improvements to network switching in bridge flow ([#3080](https://github.com/dynamic-labs/DynamicAuth/issues/3080)) ([4137c05](https://github.com/dynamic-labs/DynamicAuth/commit/4137c0599a760d2ec8a6b9a6a5de7cce9987033b))
213
+ * fix could not replace transaction error ([#3058](https://github.com/dynamic-labs/DynamicAuth/issues/3058)) ([b36184e](https://github.com/dynamic-labs/DynamicAuth/commit/b36184e17a268d49bed100e81477df9f5e4b3731)), closes [#3049](https://github.com/dynamic-labs/DynamicAuth/issues/3049)
214
+ * update embedded wallet notice design ([529f90f](https://github.com/dynamic-labs/DynamicAuth/commit/529f90f323f712240dfd964d908b6ea59cacbd19)), closes [#2987](https://github.com/dynamic-labs/DynamicAuth/issues/2987) [#3082](https://github.com/dynamic-labs/DynamicAuth/issues/3082)
215
+
216
+ ### [0.18.100-viem.6](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.5...v0.18.100-viem.6) (2023-08-21)
217
+
218
+
219
+ ### Bug Fixes
220
+
221
+ * detect when user closes oauth window when linking social account ([#3066](https://github.com/dynamic-labs/DynamicAuth/issues/3066)) ([428e9e8](https://github.com/dynamic-labs/DynamicAuth/commit/428e9e81d5473b2de03560f118c61baf3ee9e692))
222
+ * sync connected wallets with wagmi client ([#3073](https://github.com/dynamic-labs/DynamicAuth/issues/3073)) ([bce960d](https://github.com/dynamic-labs/DynamicAuth/commit/bce960d341ff55d3d660a8c34121c4348ca2908b))
223
+
224
+ ### [0.18.100-viem.5](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.4...v0.18.100-viem.5) (2023-08-19)
225
+
226
+
227
+ ### Bug Fixes
228
+
229
+ * ensure social sign in embedded wallets sync correctly with wagmi ([5fdf11d](https://github.com/dynamic-labs/DynamicAuth/commit/5fdf11df19759b6e32b461802c0a32686365d890))
230
+
231
+ ### [0.18.100-viem.4](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.3...v0.18.100-viem.4) (2023-08-17)
232
+
233
+
234
+ ### Bug Fixes
235
+
236
+ * always enable magic connectors when enabled ([#3014](https://github.com/dynamic-labs/DynamicAuth/issues/3014)) ([#3039](https://github.com/dynamic-labs/DynamicAuth/issues/3039)) ([6d4c473](https://github.com/dynamic-labs/DynamicAuth/commit/6d4c4738b92b40c903488c435fdd1bf69dc6c96e))
237
+ * guard against null or undefined provider value when logging in w… ([#3028](https://github.com/dynamic-labs/DynamicAuth/issues/3028)) ([050b62c](https://github.com/dynamic-labs/DynamicAuth/commit/050b62c7c91b6430eb350f7b49fa57260a08a756)), closes [#3021](https://github.com/dynamic-labs/DynamicAuth/issues/3021)
238
+ * issue where walletconnectors are instantiated without walletbook ([#3020](https://github.com/dynamic-labs/DynamicAuth/issues/3020)) ([#3033](https://github.com/dynamic-labs/DynamicAuth/issues/3033)) ([92394aa](https://github.com/dynamic-labs/DynamicAuth/commit/92394aa83cad497d805ac4d4ce8eb35d2b10690c))
239
+ * only use the production api environment of magicLink ([#3024](https://github.com/dynamic-labs/DynamicAuth/issues/3024)) ([25eea74](https://github.com/dynamic-labs/DynamicAuth/commit/25eea7438b0c2cb0279fb70d0be3c16f73b24573))
240
+ * switching network in connected state should update wallets to connect list ([#3038](https://github.com/dynamic-labs/DynamicAuth/issues/3038)) ([22837cb](https://github.com/dynamic-labs/DynamicAuth/commit/22837cb0af3a2dbdd7345b5cf92c23455bdd3cc4))
241
+
2
242
  ### [0.18.100-viem.3](https://github.com/dynamic-labs/DynamicAuth/compare/v0.18.100-viem.2...v0.18.100-viem.3) (2023-08-16)
3
243
 
4
244
 
package/package.cjs CHANGED
@@ -2,11 +2,11 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var version = "0.18.100-viem.3";
5
+ var version = "0.18.100-viem.31";
6
6
  var dependencies = {
7
7
  "react-focus-lock": "2.9.2",
8
- "@dynamic-labs/iconic": "0.1.23",
9
- "@dynamic-labs/sdk-api": "0.0.260",
8
+ "@dynamic-labs/iconic": "0.1.32",
9
+ "@dynamic-labs/sdk-api": "0.0.270",
10
10
  "@hcaptcha/react-hcaptcha": "1.4.4",
11
11
  "country-list": "2.3.0",
12
12
  yup: "0.32.11",
package/package.js CHANGED
@@ -1,8 +1,8 @@
1
- var version = "0.18.100-viem.3";
1
+ var version = "0.18.100-viem.31";
2
2
  var dependencies = {
3
3
  "react-focus-lock": "2.9.2",
4
- "@dynamic-labs/iconic": "0.1.23",
5
- "@dynamic-labs/sdk-api": "0.0.260",
4
+ "@dynamic-labs/iconic": "0.1.32",
5
+ "@dynamic-labs/sdk-api": "0.0.270",
6
6
  "@hcaptcha/react-hcaptcha": "1.4.4",
7
7
  "country-list": "2.3.0",
8
8
  yup: "0.32.11",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamic-labs/sdk-react-core",
3
- "version": "0.18.100-viem.3",
3
+ "version": "0.18.100-viem.31",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/dynamic-labs/DynamicAuth.git",
@@ -8,20 +8,20 @@
8
8
  },
9
9
  "dependencies": {
10
10
  "react-focus-lock": "2.9.2",
11
- "@dynamic-labs/iconic": "0.1.23",
12
- "@dynamic-labs/sdk-api": "0.0.260",
11
+ "@dynamic-labs/iconic": "0.1.32",
12
+ "@dynamic-labs/sdk-api": "0.0.270",
13
13
  "@hcaptcha/react-hcaptcha": "1.4.4",
14
14
  "country-list": "2.3.0",
15
15
  "yup": "0.32.11",
16
16
  "formik": "2.2.9",
17
17
  "qrcode": "1.5.1",
18
- "@dynamic-labs/logger": "0.18.100-viem.3",
19
- "@dynamic-labs/multi-wallet": "0.18.100-viem.3",
20
- "@dynamic-labs/rpc-providers": "0.18.100-viem.3",
21
- "@dynamic-labs/types": "0.18.100-viem.3",
22
- "@dynamic-labs/utils": "0.18.100-viem.3",
23
- "@dynamic-labs/wallet-book": "0.18.100-viem.3",
24
- "@dynamic-labs/wallet-connector-core": "0.18.100-viem.3",
18
+ "@dynamic-labs/logger": "0.18.100-viem.31",
19
+ "@dynamic-labs/multi-wallet": "0.18.100-viem.31",
20
+ "@dynamic-labs/rpc-providers": "0.18.100-viem.31",
21
+ "@dynamic-labs/types": "0.18.100-viem.31",
22
+ "@dynamic-labs/utils": "0.18.100-viem.31",
23
+ "@dynamic-labs/wallet-book": "0.18.100-viem.31",
24
+ "@dynamic-labs/wallet-connector-core": "0.18.100-viem.31",
25
25
  "eventemitter3": "5.0.1"
26
26
  },
27
27
  "devDependencies": {
package/src/index.cjs CHANGED
@@ -136,8 +136,7 @@ var SendBalanceContext = require('./lib/context/SendBalanceContext/SendBalanceCo
136
136
 
137
137
 
138
138
  exports.VERSION = version.VERSION;
139
- exports.getInstalledWallets = data.getInstalledWallets;
140
- exports.getNotInstalledWallets = data.getNotInstalledWallets;
139
+ exports.getWallets = data.getWallets;
141
140
  exports.getAuthToken = getAuthToken.getAuthToken;
142
141
  exports.DynamicContext = DynamicContext.DynamicContext;
143
142
  exports.DynamicContextProvider = DynamicContext.DynamicContextProvider;
package/src/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import './polyfills';
2
2
  export { VERSION } from './version';
3
- export { getInstalledWallets, getNotInstalledWallets, } from './lib/views/WalletList/data';
3
+ export { getWallets } from './lib/views/WalletList/data';
4
4
  export { getAuthToken } from './lib/utils/functions/getAuthToken';
5
5
  export { DynamicContextProvider, DynamicContext, } from './lib/context/DynamicContext';
6
6
  export type { DynamicContextProps } from './lib/context/DynamicContext';
package/src/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import './polyfills.js';
2
2
  export { VERSION } from './version.js';
3
- export { getInstalledWallets, getNotInstalledWallets } from './lib/views/WalletList/data.js';
3
+ export { getWallets } from './lib/views/WalletList/data.js';
4
4
  export { getAuthToken } from './lib/utils/functions/getAuthToken/getAuthToken.js';
5
5
  export { DynamicContext, DynamicContextProvider } from './lib/context/DynamicContext/DynamicContext.js';
6
6
  export { useDynamicContext } from './lib/context/DynamicContext/useDynamicContext.js';
@@ -12,13 +12,13 @@ var watchToScrollInHierarchy = require('../utils/watchToScrollInHierarchy/watchT
12
12
  require('../../../shared/logger.cjs');
13
13
  require('../../../shared/utils/classes/storage/localStorage.cjs');
14
14
  var index = require('../../../shared/utils/hooks/useOnClickOutside/index.cjs');
15
+ require('@dynamic-labs/utils');
15
16
  var useForwardedRef = require('../../../shared/utils/hooks/useForwardedRef/useForwardedRef.cjs');
16
17
  require('@dynamic-labs/sdk-api');
17
18
  require('@dynamic-labs/iconic');
18
19
  require('@dynamic-labs/wallet-connector-core');
19
20
  require('../../../context/ViewContext/ViewContext.cjs');
20
21
  require('@dynamic-labs/wallet-book');
21
- require('@dynamic-labs/utils');
22
22
  require('../../../utils/constants/colors.cjs');
23
23
  require('viem');
24
24
  require('../../../shared/consts/index.cjs');
@@ -8,13 +8,13 @@ import { watchToScrollInHierarchy } from '../utils/watchToScrollInHierarchy/watc
8
8
  import '../../../shared/logger.js';
9
9
  import '../../../shared/utils/classes/storage/localStorage.js';
10
10
  import { useOnClickOutside } from '../../../shared/utils/hooks/useOnClickOutside/index.js';
11
+ import '@dynamic-labs/utils';
11
12
  import { useForwardedRef } from '../../../shared/utils/hooks/useForwardedRef/useForwardedRef.js';
12
13
  import '@dynamic-labs/sdk-api';
13
14
  import '@dynamic-labs/iconic';
14
15
  import '@dynamic-labs/wallet-connector-core';
15
16
  import '../../../context/ViewContext/ViewContext.js';
16
17
  import '@dynamic-labs/wallet-book';
17
- import '@dynamic-labs/utils';
18
18
  import '../../../utils/constants/colors.js';
19
19
  import 'viem';
20
20
  import '../../../shared/consts/index.js';
@@ -13,9 +13,13 @@ var VerticalDrawerTransition = require('../Transition/VerticalDrawerTransition/V
13
13
 
14
14
  const typographyColor = {
15
15
  error: 'error-1',
16
+ notice: 'brand-primary',
17
+ success: 'green-1',
16
18
  };
17
- const ModalHeaderBanner = ({ message, type = 'error', }) => (jsxRuntime.jsx(AnimatePresence.AnimatePresence, { animationComponent: jsxRuntime.jsx(VerticalDrawerTransition.VerticalDrawerTransition, { style: { width: '100%' } }), children: Boolean(message) && (jsxRuntime.jsx("div", { className: classNames.classNames('modal-header-banner', {
19
+ const ModalHeaderBanner = ({ message, type = 'error', disableTruncate = false, }) => (jsxRuntime.jsx(AnimatePresence.AnimatePresence, { animationComponent: jsxRuntime.jsx(VerticalDrawerTransition.VerticalDrawerTransition, { style: { width: '100%' } }), children: Boolean(message) && (jsxRuntime.jsx("div", { className: classNames.classNames('modal-header-banner', {
18
20
  'modal-header-banner__error': type === 'error',
19
- }), children: jsxRuntime.jsx(Typography.Typography, { variant: 'body_small', color: typographyColor[type], truncate: true, children: message }) })) }));
21
+ 'modal-header-banner__notice': type === 'notice',
22
+ 'modal-header-banner__success': type === 'success',
23
+ }), children: jsxRuntime.jsx(Typography.Typography, { variant: 'body_small', color: typographyColor[type], truncate: disableTruncate === false, children: message }) })) }));
20
24
 
21
25
  exports.ModalHeaderBanner = ModalHeaderBanner;
@@ -1,8 +1,9 @@
1
1
  import { FC } from 'react';
2
- type ModalHeaderBannerType = 'error';
2
+ type ModalHeaderBannerType = 'error' | 'success' | 'notice';
3
3
  export type ModalHeaderBannerProps = {
4
4
  message?: string;
5
5
  type?: ModalHeaderBannerType;
6
+ disableTruncate?: boolean;
6
7
  };
7
8
  export declare const ModalHeaderBanner: FC<ModalHeaderBannerProps>;
8
9
  export {};
@@ -9,9 +9,13 @@ import { VerticalDrawerTransition } from '../Transition/VerticalDrawerTransition
9
9
 
10
10
  const typographyColor = {
11
11
  error: 'error-1',
12
+ notice: 'brand-primary',
13
+ success: 'green-1',
12
14
  };
13
- const ModalHeaderBanner = ({ message, type = 'error', }) => (jsx(AnimatePresence, { animationComponent: jsx(VerticalDrawerTransition, { style: { width: '100%' } }), children: Boolean(message) && (jsx("div", { className: classNames('modal-header-banner', {
15
+ const ModalHeaderBanner = ({ message, type = 'error', disableTruncate = false, }) => (jsx(AnimatePresence, { animationComponent: jsx(VerticalDrawerTransition, { style: { width: '100%' } }), children: Boolean(message) && (jsx("div", { className: classNames('modal-header-banner', {
14
16
  'modal-header-banner__error': type === 'error',
15
- }), children: jsx(Typography, { variant: 'body_small', color: typographyColor[type], truncate: true, children: message }) })) }));
17
+ 'modal-header-banner__notice': type === 'notice',
18
+ 'modal-header-banner__success': type === 'success',
19
+ }), children: jsx(Typography, { variant: 'body_small', color: typographyColor[type], truncate: disableTruncate === false, children: message }) })) }));
16
20
 
17
21
  export { ModalHeaderBanner };
@@ -55,10 +55,10 @@ require('yup');
55
55
  require('../InlineWidget/InlineWidget.cjs');
56
56
  require('../MenuList/Dropdown/Dropdown.cjs');
57
57
 
58
- const OTPVerificationView = ({ onClickBack, onClickEditEmail, isLoading, email, onPinComplete, isValid, error, onPinChange, onClickClose, displayPoweredByDynamic = false, }) => {
58
+ const OTPVerificationView = ({ onClickBack, onClickEditEmail, isLoading, email, onPinComplete, isValid, error, onPinChange, onClickClose, displayPoweredByDynamic = false, successBannerText, }) => {
59
59
  const backButton = onClickBack && (jsxRuntime.jsx(IconButton.IconButton, { type: 'button', onClick: onClickBack, "data-testid": 'back-button', children: jsxRuntime.jsx(chevronLeft.ReactComponent, {}) }));
60
60
  const closeButton = (jsxRuntime.jsx(IconButton.IconButton, { onClick: onClickClose, type: 'button', "data-testid": 'close-button', children: jsxRuntime.jsx(close.ReactComponent, {}) }));
61
- return (jsxRuntime.jsxs("div", { className: 'otp-verification-view', children: [jsxRuntime.jsx(ModalHeaderBanner.ModalHeaderBanner, { type: 'error', message: error === null || error === void 0 ? void 0 : error.message }), jsxRuntime.jsx(ModalHeader.ModalHeader, { alignContent: 'bottom', leading: onClickBack && backButton, trailing: onClickClose && closeButton, children: jsxRuntime.jsxs("div", { className: 'otp-verification-view__status-header', children: [isValid && (jsxRuntime.jsx(IconWithStatus.IconWithStatus, { Icon: iconic.SignInWithEmailIcon, iconSize: 50, InnerIcon: check.ReactComponent })), !isValid && (jsxRuntime.jsx(IconWithSpinner.IconWithSpinner, { Icon: iconic.SignInWithEmailIcon, iconSize: 80, isSpinning: isLoading }))] }) }), jsxRuntime.jsx(Typography.Typography, { weight: 'medium', variant: 'title', color: 'primary', className: 'otp-verification-view__title', children: isValid ? 'Verification code confirmed' : 'Confirm verification code' }), jsxRuntime.jsxs("div", { className: 'otp-verification-view__body', children: [isValid && (jsxRuntime.jsx(Typography.Typography, { variant: 'body_normal', weight: 'regular', color: 'secondary', children: "Hang tight while we get things ready for you" })), !isValid && (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(Typography.Typography, { variant: 'body_normal', weight: 'regular', color: 'secondary', children: "We\u2019ve sent a verification code to" }), jsxRuntime.jsxs("div", { className: 'otp-verification-view__email-container', children: [jsxRuntime.jsx(Typography.Typography, { variant: 'body_normal', weight: 'bold', color: 'secondary', children: shortenEmail.shortenEmail(email) }), onClickEditEmail && (jsxRuntime.jsx(IconButton.IconButton, { onClick: onClickEditEmail, "data-testid": 'otp-verification-view__edit-button', children: jsxRuntime.jsx(Icon.Icon, { color: 'text-tertiary', children: jsxRuntime.jsx(pencilAltIcon.ReactComponent, {}) }) }))] })] }))] }), jsxRuntime.jsx(PinField.PinField, { initialValue: Array(6).join('.').split('.'), isLoading: isLoading, handleComplete: onPinComplete, isValidated: isValid, inputMode: 'numeric', pattern: '[0-9]*', hasError: Boolean(error), onChange: onPinChange }), jsxRuntime.jsx("div", { className: 'otp-verification-view__footer', children: displayPoweredByDynamic && jsxRuntime.jsx(PoweredByDynamic.PoweredByDynamic, {}) })] }));
61
+ return (jsxRuntime.jsxs("div", { className: 'otp-verification-view', children: [successBannerText && (jsxRuntime.jsx(ModalHeaderBanner.ModalHeaderBanner, { type: 'notice', message: successBannerText, disableTruncate: true })), jsxRuntime.jsx(ModalHeaderBanner.ModalHeaderBanner, { type: 'error', message: error === null || error === void 0 ? void 0 : error.message }), jsxRuntime.jsx(ModalHeader.ModalHeader, { alignContent: 'bottom', leading: onClickBack && backButton, trailing: onClickClose && closeButton, children: jsxRuntime.jsxs("div", { className: 'otp-verification-view__status-header', children: [isValid && (jsxRuntime.jsx(IconWithStatus.IconWithStatus, { Icon: iconic.SignInWithEmailIcon, iconSize: 50, InnerIcon: check.ReactComponent })), !isValid && (jsxRuntime.jsx(IconWithSpinner.IconWithSpinner, { Icon: iconic.SignInWithEmailIcon, iconSize: 80, isSpinning: isLoading }))] }) }), jsxRuntime.jsx(Typography.Typography, { weight: 'medium', variant: 'title', color: 'primary', className: 'otp-verification-view__title', children: isValid ? 'Verification code confirmed' : 'Confirm verification code' }), jsxRuntime.jsxs("div", { className: 'otp-verification-view__body', children: [isValid && (jsxRuntime.jsx(Typography.Typography, { variant: 'body_normal', weight: 'regular', color: 'secondary', children: "Hang tight while we get things ready for you" })), !isValid && (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(Typography.Typography, { variant: 'body_normal', weight: 'regular', color: 'secondary', children: "We\u2019ve sent a verification code to" }), jsxRuntime.jsxs("div", { className: 'otp-verification-view__email-container', children: [jsxRuntime.jsx(Typography.Typography, { variant: 'body_normal', weight: 'bold', color: 'secondary', children: shortenEmail.shortenEmail(email) }), onClickEditEmail && (jsxRuntime.jsx(IconButton.IconButton, { onClick: onClickEditEmail, "data-testid": 'otp-verification-view__edit-button', children: jsxRuntime.jsx(Icon.Icon, { color: 'text-tertiary', children: jsxRuntime.jsx(pencilAltIcon.ReactComponent, {}) }) }))] })] }))] }), jsxRuntime.jsx(PinField.PinField, { initialValue: Array(6).join('.').split('.'), isLoading: isLoading, handleComplete: onPinComplete, isValidated: isValid, inputMode: 'numeric', pattern: '[0-9]*', hasError: Boolean(error), onChange: onPinChange }), jsxRuntime.jsx("div", { className: 'otp-verification-view__footer', children: displayPoweredByDynamic && jsxRuntime.jsx(PoweredByDynamic.PoweredByDynamic, {}) })] }));
62
62
  };
63
63
 
64
64
  exports.OTPVerificationView = OTPVerificationView;
@@ -10,6 +10,7 @@ type OtpVerificationLayoutProps = {
10
10
  onClickEditEmail?: MouseEventHandler<HTMLButtonElement>;
11
11
  onPinChange?: (value: string) => void;
12
12
  onPinComplete: (value: string) => void;
13
+ successBannerText?: string;
13
14
  };
14
15
  export declare const OTPVerificationView: FC<OtpVerificationLayoutProps>;
15
16
  export {};
@@ -51,10 +51,10 @@ import 'yup';
51
51
  import '../InlineWidget/InlineWidget.js';
52
52
  import '../MenuList/Dropdown/Dropdown.js';
53
53
 
54
- const OTPVerificationView = ({ onClickBack, onClickEditEmail, isLoading, email, onPinComplete, isValid, error, onPinChange, onClickClose, displayPoweredByDynamic = false, }) => {
54
+ const OTPVerificationView = ({ onClickBack, onClickEditEmail, isLoading, email, onPinComplete, isValid, error, onPinChange, onClickClose, displayPoweredByDynamic = false, successBannerText, }) => {
55
55
  const backButton = onClickBack && (jsx(IconButton, { type: 'button', onClick: onClickBack, "data-testid": 'back-button', children: jsx(SvgChevronLeft, {}) }));
56
56
  const closeButton = (jsx(IconButton, { onClick: onClickClose, type: 'button', "data-testid": 'close-button', children: jsx(SvgClose, {}) }));
57
- return (jsxs("div", { className: 'otp-verification-view', children: [jsx(ModalHeaderBanner, { type: 'error', message: error === null || error === void 0 ? void 0 : error.message }), jsx(ModalHeader, { alignContent: 'bottom', leading: onClickBack && backButton, trailing: onClickClose && closeButton, children: jsxs("div", { className: 'otp-verification-view__status-header', children: [isValid && (jsx(IconWithStatus, { Icon: SignInWithEmailIcon, iconSize: 50, InnerIcon: SvgCheck })), !isValid && (jsx(IconWithSpinner, { Icon: SignInWithEmailIcon, iconSize: 80, isSpinning: isLoading }))] }) }), jsx(Typography, { weight: 'medium', variant: 'title', color: 'primary', className: 'otp-verification-view__title', children: isValid ? 'Verification code confirmed' : 'Confirm verification code' }), jsxs("div", { className: 'otp-verification-view__body', children: [isValid && (jsx(Typography, { variant: 'body_normal', weight: 'regular', color: 'secondary', children: "Hang tight while we get things ready for you" })), !isValid && (jsxs(Fragment, { children: [jsx(Typography, { variant: 'body_normal', weight: 'regular', color: 'secondary', children: "We\u2019ve sent a verification code to" }), jsxs("div", { className: 'otp-verification-view__email-container', children: [jsx(Typography, { variant: 'body_normal', weight: 'bold', color: 'secondary', children: shortenEmail(email) }), onClickEditEmail && (jsx(IconButton, { onClick: onClickEditEmail, "data-testid": 'otp-verification-view__edit-button', children: jsx(Icon, { color: 'text-tertiary', children: jsx(SvgPencilAltIcon, {}) }) }))] })] }))] }), jsx(PinField, { initialValue: Array(6).join('.').split('.'), isLoading: isLoading, handleComplete: onPinComplete, isValidated: isValid, inputMode: 'numeric', pattern: '[0-9]*', hasError: Boolean(error), onChange: onPinChange }), jsx("div", { className: 'otp-verification-view__footer', children: displayPoweredByDynamic && jsx(PoweredByDynamic, {}) })] }));
57
+ return (jsxs("div", { className: 'otp-verification-view', children: [successBannerText && (jsx(ModalHeaderBanner, { type: 'notice', message: successBannerText, disableTruncate: true })), jsx(ModalHeaderBanner, { type: 'error', message: error === null || error === void 0 ? void 0 : error.message }), jsx(ModalHeader, { alignContent: 'bottom', leading: onClickBack && backButton, trailing: onClickClose && closeButton, children: jsxs("div", { className: 'otp-verification-view__status-header', children: [isValid && (jsx(IconWithStatus, { Icon: SignInWithEmailIcon, iconSize: 50, InnerIcon: SvgCheck })), !isValid && (jsx(IconWithSpinner, { Icon: SignInWithEmailIcon, iconSize: 80, isSpinning: isLoading }))] }) }), jsx(Typography, { weight: 'medium', variant: 'title', color: 'primary', className: 'otp-verification-view__title', children: isValid ? 'Verification code confirmed' : 'Confirm verification code' }), jsxs("div", { className: 'otp-verification-view__body', children: [isValid && (jsx(Typography, { variant: 'body_normal', weight: 'regular', color: 'secondary', children: "Hang tight while we get things ready for you" })), !isValid && (jsxs(Fragment, { children: [jsx(Typography, { variant: 'body_normal', weight: 'regular', color: 'secondary', children: "We\u2019ve sent a verification code to" }), jsxs("div", { className: 'otp-verification-view__email-container', children: [jsx(Typography, { variant: 'body_normal', weight: 'bold', color: 'secondary', children: shortenEmail(email) }), onClickEditEmail && (jsx(IconButton, { onClick: onClickEditEmail, "data-testid": 'otp-verification-view__edit-button', children: jsx(Icon, { color: 'text-tertiary', children: jsx(SvgPencilAltIcon, {}) }) }))] })] }))] }), jsx(PinField, { initialValue: Array(6).join('.').split('.'), isLoading: isLoading, handleComplete: onPinComplete, isValidated: isValid, inputMode: 'numeric', pattern: '[0-9]*', hasError: Boolean(error), onChange: onPinChange }), jsx("div", { className: 'otp-verification-view__footer', children: displayPoweredByDynamic && jsx(PoweredByDynamic, {}) })] }));
58
58
  };
59
59
 
60
60
  export { OTPVerificationView };
@@ -0,0 +1,27 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var jsxRuntime = require('react/jsx-runtime');
6
+ var React = require('react');
7
+ var Typography = require('../Typography/Typography.cjs');
8
+ var isSignTypedData = require('./utils/isSignTypedData/isSignTypedData.cjs');
9
+ var SignTypedDataPreview = require('./components/SignTypedDataPreview/SignTypedDataPreview.cjs');
10
+
11
+ const SignMessagePreview = ({ message, }) => {
12
+ const signTypedData = React.useMemo(() => {
13
+ try {
14
+ const json = JSON.parse(message);
15
+ return isSignTypedData.isSignTypedData(json) ? json : undefined;
16
+ }
17
+ catch (e) {
18
+ return undefined;
19
+ }
20
+ }, [message]);
21
+ if (signTypedData) {
22
+ return (jsxRuntime.jsx(SignTypedDataPreview.SignTypedDataPreview, { currentType: signTypedData.primaryType, types: signTypedData.types, showTypeName: true, data: signTypedData.message }));
23
+ }
24
+ return (jsxRuntime.jsx(Typography.Typography, { color: 'primary', variant: 'body_normal', children: jsxRuntime.jsx("span", { style: { whiteSpace: 'pre-line' }, children: message }) }));
25
+ };
26
+
27
+ exports.SignMessagePreview = SignMessagePreview;
@@ -0,0 +1,6 @@
1
+ import { FC } from 'react';
2
+ type SignMessagePreviewProps = {
3
+ message: string;
4
+ };
5
+ export declare const SignMessagePreview: FC<SignMessagePreviewProps>;
6
+ export {};
@@ -0,0 +1,23 @@
1
+ import { jsx } from 'react/jsx-runtime';
2
+ import { useMemo } from 'react';
3
+ import { Typography } from '../Typography/Typography.js';
4
+ import { isSignTypedData } from './utils/isSignTypedData/isSignTypedData.js';
5
+ import { SignTypedDataPreview } from './components/SignTypedDataPreview/SignTypedDataPreview.js';
6
+
7
+ const SignMessagePreview = ({ message, }) => {
8
+ const signTypedData = useMemo(() => {
9
+ try {
10
+ const json = JSON.parse(message);
11
+ return isSignTypedData(json) ? json : undefined;
12
+ }
13
+ catch (e) {
14
+ return undefined;
15
+ }
16
+ }, [message]);
17
+ if (signTypedData) {
18
+ return (jsx(SignTypedDataPreview, { currentType: signTypedData.primaryType, types: signTypedData.types, showTypeName: true, data: signTypedData.message }));
19
+ }
20
+ return (jsx(Typography, { color: 'primary', variant: 'body_normal', children: jsx("span", { style: { whiteSpace: 'pre-line' }, children: message }) }));
21
+ };
22
+
23
+ export { SignMessagePreview };
@@ -0,0 +1,8 @@
1
+ type Types = Record<string, any>;
2
+ type Message = Record<string, any>;
3
+ export type SignTypedData = {
4
+ types: Types;
5
+ message: Message;
6
+ primaryType: string;
7
+ };
8
+ export {};
@@ -0,0 +1,44 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var jsxRuntime = require('react/jsx-runtime');
6
+ var Typography = require('../../../Typography/Typography.cjs');
7
+ var capitalize = require('../../../../shared/utils/functions/capitalize/capitalize.cjs');
8
+ require('@dynamic-labs/sdk-api');
9
+ require('../../../../shared/logger.cjs');
10
+ require('@dynamic-labs/iconic');
11
+ require('@dynamic-labs/wallet-connector-core');
12
+ require('../../../../context/ViewContext/ViewContext.cjs');
13
+ require('react');
14
+ require('@dynamic-labs/wallet-book');
15
+ var shortenWalletAddress = require('../../../../shared/utils/functions/shortenWalletAddress/shortenWalletAddress.cjs');
16
+ require('@dynamic-labs/utils');
17
+ require('../../../../utils/constants/colors.cjs');
18
+ require('../../../../shared/utils/classes/storage/localStorage.cjs');
19
+ require('viem');
20
+ require('../../../../shared/consts/index.cjs');
21
+
22
+ const TypeTitle = ({ children }) => (jsxRuntime.jsx(Typography.Typography, { color: 'secondary', weight: 'medium', children: children }));
23
+ const AttributeName = TypeTitle;
24
+ const AttributeValue = ({ children, title, }) => (jsxRuntime.jsx(Typography.Typography, { as: 'span', weight: 'regular', color: 'primary', title: title, children: children }));
25
+ const SignTypedDataPreview = ({ currentType, types, showTypeName = false, data }) => {
26
+ const fields = types[currentType].map((field) => {
27
+ const { type } = field;
28
+ const isKnownType = type in types;
29
+ if (isKnownType) {
30
+ return (jsxRuntime.jsxs("div", { children: [jsxRuntime.jsx(TypeTitle, { children: capitalize.capitalize(field.name) }), jsxRuntime.jsx("div", { className: 'sign-typed-data-preview--type-container', children: jsxRuntime.jsx(SignTypedDataPreview, { currentType: type, types: types, data: data === null || data === void 0 ? void 0 : data[field.name] }) })] }, field.name));
31
+ }
32
+ const fieldData = data === null || data === void 0 ? void 0 : data[field.name];
33
+ const fieldType = field.type;
34
+ return (jsxRuntime.jsxs("div", { className: 'sign-typed-data-preview--attribute-row', children: [jsxRuntime.jsxs(AttributeName, { children: [capitalize.capitalize(field.name), ": "] }), jsxRuntime.jsx(AttributeValue, { title: fieldData, children: fieldType === 'address'
35
+ ? shortenWalletAddress.shortenWalletAddress(fieldData, 4, 4)
36
+ : fieldData })] }, field.name));
37
+ });
38
+ if (showTypeName) {
39
+ return (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(TypeTitle, { children: currentType }), jsxRuntime.jsx("div", { className: 'sign-typed-data-preview--type-container', children: fields })] }));
40
+ }
41
+ return jsxRuntime.jsx("div", { className: 'sign-typed-data-preview--fields-list', children: fields });
42
+ };
43
+
44
+ exports.SignTypedDataPreview = SignTypedDataPreview;
@@ -0,0 +1,8 @@
1
+ import { FC } from 'react';
2
+ import { SignTypedData } from '../../SignMessagePreview.types';
3
+ export declare const SignTypedDataPreview: FC<{
4
+ types: SignTypedData['types'];
5
+ currentType: string;
6
+ data: SignTypedData['message'];
7
+ showTypeName?: boolean;
8
+ }>;