@dynamic-labs/sdk-react-core 1.0.5 → 1.0.7
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 +22 -0
- package/package.cjs +3 -3
- package/package.js +3 -3
- package/package.json +12 -12
- package/src/index.cjs +11 -9
- package/src/index.js +6 -5
- package/src/lib/Main.cjs +25 -10
- package/src/lib/Main.js +25 -10
- package/src/lib/components/IconWithSpinner/IconWithSpinner.cjs +1 -1
- package/src/lib/components/IconWithSpinner/IconWithSpinner.js +1 -1
- package/src/lib/components/IconWithSpinner/Spinner/Spinner.cjs +1 -1
- package/src/lib/components/IconWithSpinner/Spinner/Spinner.js +1 -1
- package/src/lib/components/IconWithStatus/IconWithStatus.cjs +1 -1
- package/src/lib/components/IconWithStatus/IconWithStatus.js +1 -1
- package/src/lib/components/MenuList/Dropdown/Dropdown.cjs +1 -1
- package/src/lib/components/MenuList/Dropdown/Dropdown.js +1 -1
- package/src/lib/components/NetworkPicker/components/EvmNetworkControl/EvmNetworkControl.cjs +4 -1
- package/src/lib/components/NetworkPicker/components/EvmNetworkControl/EvmNetworkControl.js +4 -1
- package/src/lib/components/SendBalanceForm/SendBalanceForm.cjs +1 -1
- package/src/lib/components/SendBalanceForm/SendBalanceForm.js +1 -1
- package/src/lib/components/SyncPasskeyFlow/SyncPasskeyFlow.cjs +2 -2
- package/src/lib/components/SyncPasskeyFlow/SyncPasskeyFlow.js +2 -2
- package/src/lib/components/UserProfileForm/UserProfileForm.cjs +1 -1
- package/src/lib/components/UserProfileForm/UserProfileForm.js +1 -1
- package/src/lib/context/DynamicContext/DynamicContext.cjs +4 -2
- package/src/lib/context/DynamicContext/DynamicContext.js +4 -2
- package/src/lib/context/DynamicContext/hooks/useEmailLoginState/useEmailLoginState.cjs +1 -1
- package/src/lib/context/DynamicContext/hooks/useEmailLoginState/useEmailLoginState.js +1 -1
- package/src/lib/data/api.cjs +2 -2
- package/src/lib/data/api.d.ts +1 -0
- package/src/lib/data/api.js +2 -2
- package/src/lib/shared/utils/hooks/index.d.ts +5 -4
- package/src/lib/shared/utils/hooks/useThrottle/index.d.ts +1 -0
- package/src/lib/shared/utils/hooks/useThrottle/useThrottle.cjs +29 -0
- package/src/lib/shared/utils/hooks/useThrottle/useThrottle.d.ts +8 -0
- package/src/lib/shared/utils/hooks/useThrottle/useThrottle.js +25 -0
- package/src/lib/utils/functions/getWalletIdentifier/getWalletIdentifier.cjs +7 -0
- package/src/lib/utils/functions/getWalletIdentifier/getWalletIdentifier.d.ts +2 -0
- package/src/lib/utils/functions/getWalletIdentifier/getWalletIdentifier.js +3 -0
- package/src/lib/utils/functions/getWalletIdentifier/index.d.ts +1 -0
- package/src/lib/utils/functions/index.d.ts +5 -3
- package/src/lib/utils/hooks/multiWallet/useSyncPrimaryWallet/useSyncPrimaryWallet.cjs +13 -2
- package/src/lib/utils/hooks/multiWallet/useSyncPrimaryWallet/useSyncPrimaryWallet.js +13 -2
- package/src/lib/utils/hooks/useColorSchemePreference/useColorSchemePreference.cjs +1 -1
- package/src/lib/utils/hooks/useColorSchemePreference/useColorSchemePreference.js +1 -1
- package/src/lib/utils/hooks/useConnectedWalletsNetworkValidation/useConnectedWalletsNetworkValidation.cjs +1 -1
- package/src/lib/utils/hooks/useConnectedWalletsNetworkValidation/useConnectedWalletsNetworkValidation.js +1 -1
- package/src/lib/utils/hooks/useEmailProvider/useEmailProvider.cjs +1 -1
- package/src/lib/utils/hooks/useEmailProvider/useEmailProvider.js +1 -1
- package/src/lib/utils/hooks/useEmbeddedWallet/useEmbeddedWallet.cjs +14 -6
- package/src/lib/utils/hooks/useEmbeddedWallet/useEmbeddedWallet.js +14 -6
- package/src/lib/utils/hooks/useFetchProjectSettings/useFetchProjectSettings.cjs +15 -1
- package/src/lib/utils/hooks/useFetchProjectSettings/useFetchProjectSettings.js +16 -2
- package/src/lib/utils/hooks/useHandleUnlinkWallet/useHandleUnlinkWallet.cjs +7 -1
- package/src/lib/utils/hooks/useHandleUnlinkWallet/useHandleUnlinkWallet.d.ts +4 -2
- package/src/lib/utils/hooks/useHandleUnlinkWallet/useHandleUnlinkWallet.js +7 -1
- package/src/lib/utils/hooks/useKYCFlag/useKYCFlag.cjs +1 -1
- package/src/lib/utils/hooks/useKYCFlag/useKYCFlag.js +1 -1
- package/src/lib/utils/hooks/usePasskeyRecovery/usePasskeyRecovery.cjs +1 -1
- package/src/lib/utils/hooks/usePasskeyRecovery/usePasskeyRecovery.js +1 -1
- package/src/lib/utils/hooks/useSocialAccounts/useSocialAccounts.cjs +1 -1
- package/src/lib/utils/hooks/useSocialAccounts/useSocialAccounts.js +1 -1
- package/src/lib/utils/hooks/useSocialAuth/useSocialAuth.cjs +1 -1
- package/src/lib/utils/hooks/useSocialAuth/useSocialAuth.js +1 -1
- package/src/lib/utils/hooks/useVerifyWallet/useVerifyWallet.cjs +2 -1
- package/src/lib/utils/hooks/useVerifyWallet/useVerifyWallet.js +2 -1
- package/src/lib/utils/hooks/useWalletConnectorOptions/utils/verifyMagicIsSetup/verifyMagicIsSetup.cjs +1 -1
- package/src/lib/utils/hooks/useWalletConnectorOptions/utils/verifyMagicIsSetup/verifyMagicIsSetup.js +1 -1
- package/src/lib/utils/hooks/useWalletConnectorOptions/utils/verifyZeroDevIsSetup/verifyZeroDevIsSetup.cjs +1 -1
- package/src/lib/utils/hooks/useWalletConnectorOptions/utils/verifyZeroDevIsSetup/verifyZeroDevIsSetup.js +1 -1
- package/src/lib/utils/hooks/useWalletConnectors/useWalletConnectors.cjs +8 -4
- package/src/lib/utils/hooks/useWalletConnectors/useWalletConnectors.js +8 -4
- package/src/lib/utils/hooks/useWalletEventListeners/useWalletEventListeners.cjs +4 -3
- package/src/lib/utils/hooks/useWalletEventListeners/useWalletEventListeners.js +4 -3
- package/src/lib/utils/hooks/useWalletItemActions/useWalletItemActions.cjs +1 -1
- package/src/lib/utils/hooks/useWalletItemActions/useWalletItemActions.js +1 -1
- package/src/lib/utils/hooks/useWalletsConnectionState/useWalletsConnectionState.cjs +67 -43
- package/src/lib/utils/hooks/useWalletsConnectionState/useWalletsConnectionState.d.ts +5 -7
- package/src/lib/utils/hooks/useWalletsConnectionState/useWalletsConnectionState.js +68 -44
- package/src/lib/views/LoginView/sections/SocialSignInSection/SocialSignInSection.cjs +1 -1
- package/src/lib/views/LoginView/sections/SocialSignInSection/SocialSignInSection.js +1 -1
- package/src/lib/views/LoginView/useLoginView.cjs +1 -1
- package/src/lib/views/LoginView/useLoginView.js +1 -1
- package/src/lib/views/Passkey/PasskeyIntroView/PasskeyIntroView.cjs +1 -1
- package/src/lib/views/Passkey/PasskeyIntroView/PasskeyIntroView.js +1 -1
- package/src/lib/views/Passkey/PasskeyRecovery/BundleValidation/PasskeyBundleRecovery.cjs +1 -1
- package/src/lib/views/Passkey/PasskeyRecovery/BundleValidation/PasskeyBundleRecovery.js +1 -1
- package/src/lib/views/Passkey/PasskeyRecovery/CompleteRecovery/PasskeyCompleteRecovery.cjs +2 -2
- package/src/lib/views/Passkey/PasskeyRecovery/CompleteRecovery/PasskeyCompleteRecovery.js +2 -2
- package/src/lib/views/Passkey/PasskeyRecovery/InitRecovery/PasskeyInitRecovery.cjs +1 -1
- package/src/lib/views/Passkey/PasskeyRecovery/InitRecovery/PasskeyInitRecovery.js +1 -1
- package/src/lib/views/QrCodeView/QrCodeView.cjs +1 -1
- package/src/lib/views/QrCodeView/QrCodeView.js +1 -1
- package/src/lib/widgets/DynamicWidget/components/ActiveWalletInformation/ActiveWalletInformation.cjs +2 -2
- package/src/lib/widgets/DynamicWidget/components/ActiveWalletInformation/ActiveWalletInformation.js +2 -2
- package/src/lib/widgets/DynamicWidget/components/WalletIconWithStatus/WalletIconWithStatus.cjs +1 -1
- package/src/lib/widgets/DynamicWidget/components/WalletIconWithStatus/WalletIconWithStatus.js +1 -1
- package/src/lib/widgets/DynamicWidget/prompts/UnlinkWalletPopUp/UnlinkWalletPopUp.cjs +1 -6
- package/src/lib/widgets/DynamicWidget/prompts/UnlinkWalletPopUp/UnlinkWalletPopUp.js +1 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,26 @@
|
|
|
1
1
|
|
|
2
|
+
### [1.0.7](https://github.com/dynamic-labs/DynamicAuth/compare/v1.0.6...v1.0.7) (2024-01-25)
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### Bug Fixes
|
|
6
|
+
|
|
7
|
+
* add support for newest backpack extension ([66786ce](https://github.com/dynamic-labs/DynamicAuth/commit/66786ceb7927046c1cdb439888271f3070ca93a4))
|
|
8
|
+
* broken help icon in create passkey view ([2e38ea5](https://github.com/dynamic-labs/DynamicAuth/commit/2e38ea580e55f3349a2d3040d7b07bb2923631f7))
|
|
9
|
+
* connect to wallet with wallet connect even if network is not supported ([#4465](https://github.com/dynamic-labs/DynamicAuth/issues/4465)) ([#4472](https://github.com/dynamic-labs/DynamicAuth/issues/4472)) ([8270b94](https://github.com/dynamic-labs/DynamicAuth/commit/8270b9468c289e7c49cd2ef104fb73dfaaa9f41c))
|
|
10
|
+
* infinite loop when connecting with trust wallet ([#4448](https://github.com/dynamic-labs/DynamicAuth/issues/4448)) ([#4450](https://github.com/dynamic-labs/DynamicAuth/issues/4450)) ([c5ffee6](https://github.com/dynamic-labs/DynamicAuth/commit/c5ffee67a6a95ee62e779da69ce311c90575388f))
|
|
11
|
+
* logging in with an email linked to a third party wallet gets stu… ([#4422](https://github.com/dynamic-labs/DynamicAuth/issues/4422)) ([995889b](https://github.com/dynamic-labs/DynamicAuth/commit/995889b5d03bcbafecd6959c52a88db8d9db940e))
|
|
12
|
+
* switching wallet in extension caused connected flag to be false ([#4464](https://github.com/dynamic-labs/DynamicAuth/issues/4464)) ([a53dc1a](https://github.com/dynamic-labs/DynamicAuth/commit/a53dc1a9869a270c98753041cfbd587855629af4)), closes [#4454](https://github.com/dynamic-labs/DynamicAuth/issues/4454)
|
|
13
|
+
|
|
14
|
+
### [1.0.6](https://github.com/dynamic-labs/DynamicAuth/compare/v1.0.5...v1.0.6) (2024-01-18)
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
### Bug Fixes
|
|
18
|
+
|
|
19
|
+
* call onUnlinkSuccess in headless mode ([#4417](https://github.com/dynamic-labs/DynamicAuth/issues/4417)) ([d00e644](https://github.com/dynamic-labs/DynamicAuth/commit/d00e644f3452ab9081af4cad0e98aa055ebe3722))
|
|
20
|
+
* correctly map keplr chain ids from project settings ([#4418](https://github.com/dynamic-labs/DynamicAuth/issues/4418)) ([#4420](https://github.com/dynamic-labs/DynamicAuth/issues/4420)) ([1f75a5f](https://github.com/dynamic-labs/DynamicAuth/commit/1f75a5f6138513634d59a4aec389b0271176d72e))
|
|
21
|
+
* correctly update wallets connected flag after wallet switch ([#4397](https://github.com/dynamic-labs/DynamicAuth/issues/4397)) ([#4405](https://github.com/dynamic-labs/DynamicAuth/issues/4405)) ([ca9ae8a](https://github.com/dynamic-labs/DynamicAuth/commit/ca9ae8a92e717cb3d5dd66d4bbdb9a7f8834d22a))
|
|
22
|
+
* fix ui issues on react 17 ([#4373](https://github.com/dynamic-labs/DynamicAuth/issues/4373)) ([#4376](https://github.com/dynamic-labs/DynamicAuth/issues/4376)) ([a3719cf](https://github.com/dynamic-labs/DynamicAuth/commit/a3719cf23517c82cc7a5574013e14807c99811bb))
|
|
23
|
+
|
|
2
24
|
### [1.0.5](https://github.com/dynamic-labs/DynamicAuth/compare/v1.0.4...v1.0.5) (2024-01-10)
|
|
3
25
|
|
|
4
26
|
|
package/package.cjs
CHANGED
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var version = "1.0.
|
|
5
|
+
var version = "1.0.7";
|
|
6
6
|
var dependencies = {
|
|
7
|
-
"@dynamic-labs/iconic": "0.1.
|
|
8
|
-
"@dynamic-labs/sdk-api": "0.0.
|
|
7
|
+
"@dynamic-labs/iconic": "0.1.48",
|
|
8
|
+
"@dynamic-labs/sdk-api": "0.0.347",
|
|
9
9
|
"@hcaptcha/react-hcaptcha": "1.4.4",
|
|
10
10
|
"country-list": "2.3.0",
|
|
11
11
|
formik: "2.2.9",
|
package/package.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
var version = "1.0.
|
|
1
|
+
var version = "1.0.7";
|
|
2
2
|
var dependencies = {
|
|
3
|
-
"@dynamic-labs/iconic": "0.1.
|
|
4
|
-
"@dynamic-labs/sdk-api": "0.0.
|
|
3
|
+
"@dynamic-labs/iconic": "0.1.48",
|
|
4
|
+
"@dynamic-labs/sdk-api": "0.0.347",
|
|
5
5
|
"@hcaptcha/react-hcaptcha": "1.4.4",
|
|
6
6
|
"country-list": "2.3.0",
|
|
7
7
|
formik: "2.2.9",
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/sdk-react-core",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.7",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "https://github.com/dynamic-labs/DynamicAuth.git",
|
|
7
7
|
"directory": "packages/sdk-react-core"
|
|
8
8
|
},
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@dynamic-labs/iconic": "0.1.
|
|
11
|
-
"@dynamic-labs/sdk-api": "0.0.
|
|
10
|
+
"@dynamic-labs/iconic": "0.1.48",
|
|
11
|
+
"@dynamic-labs/sdk-api": "0.0.347",
|
|
12
12
|
"@hcaptcha/react-hcaptcha": "1.4.4",
|
|
13
13
|
"country-list": "2.3.0",
|
|
14
14
|
"formik": "2.2.9",
|
|
@@ -17,15 +17,15 @@
|
|
|
17
17
|
"react-focus-lock": "2.9.2",
|
|
18
18
|
"react-i18next": "^13.2.0",
|
|
19
19
|
"yup": "0.32.11",
|
|
20
|
-
"@dynamic-labs/ethereum": "1.0.
|
|
21
|
-
"@dynamic-labs/logger": "1.0.
|
|
22
|
-
"@dynamic-labs/multi-wallet": "1.0.
|
|
23
|
-
"@dynamic-labs/rpc-providers": "1.0.
|
|
24
|
-
"@dynamic-labs/types": "1.0.
|
|
25
|
-
"@dynamic-labs/utils": "1.0.
|
|
26
|
-
"@dynamic-labs/viem-utils": "1.0.
|
|
27
|
-
"@dynamic-labs/wallet-book": "1.0.
|
|
28
|
-
"@dynamic-labs/wallet-connector-core": "1.0.
|
|
20
|
+
"@dynamic-labs/ethereum": "1.0.7",
|
|
21
|
+
"@dynamic-labs/logger": "1.0.7",
|
|
22
|
+
"@dynamic-labs/multi-wallet": "1.0.7",
|
|
23
|
+
"@dynamic-labs/rpc-providers": "1.0.7",
|
|
24
|
+
"@dynamic-labs/types": "1.0.7",
|
|
25
|
+
"@dynamic-labs/utils": "1.0.7",
|
|
26
|
+
"@dynamic-labs/viem-utils": "1.0.7",
|
|
27
|
+
"@dynamic-labs/wallet-book": "1.0.7",
|
|
28
|
+
"@dynamic-labs/wallet-connector-core": "1.0.7",
|
|
29
29
|
"eventemitter3": "5.0.1"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
package/src/index.cjs
CHANGED
|
@@ -38,13 +38,14 @@ var getWalletListItemLabel = require('./lib/shared/utils/functions/getWalletList
|
|
|
38
38
|
var formatBigNumber = require('./lib/shared/utils/functions/formatBigNumber/formatBigNumber.cjs');
|
|
39
39
|
var trimEnd = require('./lib/shared/utils/functions/trimEnd/trimEnd.cjs');
|
|
40
40
|
var ceil = require('./lib/shared/utils/functions/ceil/ceil.cjs');
|
|
41
|
+
var useEffectOnce = require('./lib/shared/utils/hooks/useEffectOnce/useEffectOnce.cjs');
|
|
42
|
+
var useForwardedRef = require('./lib/shared/utils/hooks/useForwardedRef/useForwardedRef.cjs');
|
|
43
|
+
var useGlobalLoading = require('./lib/shared/utils/hooks/useGlobalLoading/useGlobalLoading.cjs');
|
|
41
44
|
var useLocalStorage = require('./lib/shared/utils/hooks/useLocalStorage/useLocalStorage.cjs');
|
|
45
|
+
var useMediaQuery = require('./lib/shared/utils/hooks/useMediaQuery/useMediaQuery.cjs');
|
|
42
46
|
var index$1 = require('./lib/shared/utils/hooks/useOnClickOutside/index.cjs');
|
|
43
47
|
var usePreventPageScroll = require('./lib/shared/utils/hooks/usePreventPageScroll/usePreventPageScroll.cjs');
|
|
44
|
-
var
|
|
45
|
-
var useMediaQuery = require('./lib/shared/utils/hooks/useMediaQuery/useMediaQuery.cjs');
|
|
46
|
-
var useEffectOnce = require('./lib/shared/utils/hooks/useEffectOnce/useEffectOnce.cjs');
|
|
47
|
-
var useForwardedRef = require('./lib/shared/utils/hooks/useForwardedRef/useForwardedRef.cjs');
|
|
48
|
+
var useThrottle = require('./lib/shared/utils/hooks/useThrottle/useThrottle.cjs');
|
|
48
49
|
var localStorage = require('./lib/shared/utils/classes/storage/localStorage.cjs');
|
|
49
50
|
var PhantomLedgerIcon = require('./lib/shared/assets/wallets/PhantomLedgerIcon/PhantomLedgerIcon.cjs');
|
|
50
51
|
var addWallet = require('./lib/shared/assets/add-wallet.cjs');
|
|
@@ -113,8 +114,8 @@ require('react-dom');
|
|
|
113
114
|
require('@dynamic-labs/utils');
|
|
114
115
|
var sdkApi = require('@dynamic-labs/sdk-api');
|
|
115
116
|
require('./lib/config/ApiEndpoint.cjs');
|
|
116
|
-
require('@dynamic-labs/multi-wallet');
|
|
117
117
|
var walletConnectorCore = require('@dynamic-labs/wallet-connector-core');
|
|
118
|
+
require('@dynamic-labs/multi-wallet');
|
|
118
119
|
require('./lib/utils/constants/colors.cjs');
|
|
119
120
|
var isSameWalletName = require('./lib/utils/functions/isSameWalletName/isSameWalletName.cjs');
|
|
120
121
|
require('./lib/context/ViewContext/ViewContext.cjs');
|
|
@@ -217,13 +218,14 @@ exports.getWalletListItemLabel = getWalletListItemLabel.getWalletListItemLabel;
|
|
|
217
218
|
exports.formatBigNumber = formatBigNumber.formatBigNumber;
|
|
218
219
|
exports.trimEnd = trimEnd.trimEnd;
|
|
219
220
|
exports.ceil = ceil.ceil;
|
|
221
|
+
exports.useEffectOnce = useEffectOnce.useEffectOnce;
|
|
222
|
+
exports.useForwardedRef = useForwardedRef.useForwardedRef;
|
|
223
|
+
exports.useGlobalLoading = useGlobalLoading.useGlobalLoading;
|
|
220
224
|
exports.useLocalStorage = useLocalStorage.useLocalStorage;
|
|
225
|
+
exports.useMediaQuery = useMediaQuery.useMediaQuery;
|
|
221
226
|
exports.useOnClickOutside = index$1.useOnClickOutside;
|
|
222
227
|
exports.usePreventPageScroll = usePreventPageScroll.usePreventPageScroll;
|
|
223
|
-
exports.
|
|
224
|
-
exports.useMediaQuery = useMediaQuery.useMediaQuery;
|
|
225
|
-
exports.useEffectOnce = useEffectOnce.useEffectOnce;
|
|
226
|
-
exports.useForwardedRef = useForwardedRef.useForwardedRef;
|
|
228
|
+
exports.useThrottle = useThrottle.useThrottle;
|
|
227
229
|
exports.LocalStorage = localStorage.LocalStorage;
|
|
228
230
|
exports.PhantomLedgerIcon = PhantomLedgerIcon.PhantomLedgerIcon;
|
|
229
231
|
exports.AddWalletIcon = addWallet.ReactComponent;
|
package/src/index.js
CHANGED
|
@@ -34,13 +34,14 @@ export { getWalletListItemLabel } from './lib/shared/utils/functions/getWalletLi
|
|
|
34
34
|
export { formatBigNumber } from './lib/shared/utils/functions/formatBigNumber/formatBigNumber.js';
|
|
35
35
|
export { trimEnd } from './lib/shared/utils/functions/trimEnd/trimEnd.js';
|
|
36
36
|
export { ceil } from './lib/shared/utils/functions/ceil/ceil.js';
|
|
37
|
+
export { useEffectOnce } from './lib/shared/utils/hooks/useEffectOnce/useEffectOnce.js';
|
|
38
|
+
export { useForwardedRef } from './lib/shared/utils/hooks/useForwardedRef/useForwardedRef.js';
|
|
39
|
+
export { useGlobalLoading } from './lib/shared/utils/hooks/useGlobalLoading/useGlobalLoading.js';
|
|
37
40
|
export { useLocalStorage } from './lib/shared/utils/hooks/useLocalStorage/useLocalStorage.js';
|
|
41
|
+
export { useMediaQuery } from './lib/shared/utils/hooks/useMediaQuery/useMediaQuery.js';
|
|
38
42
|
export { useOnClickOutside } from './lib/shared/utils/hooks/useOnClickOutside/index.js';
|
|
39
43
|
export { usePreventPageScroll } from './lib/shared/utils/hooks/usePreventPageScroll/usePreventPageScroll.js';
|
|
40
|
-
export {
|
|
41
|
-
export { useMediaQuery } from './lib/shared/utils/hooks/useMediaQuery/useMediaQuery.js';
|
|
42
|
-
export { useEffectOnce } from './lib/shared/utils/hooks/useEffectOnce/useEffectOnce.js';
|
|
43
|
-
export { useForwardedRef } from './lib/shared/utils/hooks/useForwardedRef/useForwardedRef.js';
|
|
44
|
+
export { useThrottle } from './lib/shared/utils/hooks/useThrottle/useThrottle.js';
|
|
44
45
|
export { LocalStorage } from './lib/shared/utils/classes/storage/localStorage.js';
|
|
45
46
|
export { PhantomLedgerIcon } from './lib/shared/assets/wallets/PhantomLedgerIcon/PhantomLedgerIcon.js';
|
|
46
47
|
export { ReactComponent as AddWalletIcon } from './lib/shared/assets/add-wallet.js';
|
|
@@ -109,8 +110,8 @@ import 'react-dom';
|
|
|
109
110
|
import '@dynamic-labs/utils';
|
|
110
111
|
export { DynamicJwtFromJSON } from '@dynamic-labs/sdk-api';
|
|
111
112
|
import './lib/config/ApiEndpoint.js';
|
|
112
|
-
import '@dynamic-labs/multi-wallet';
|
|
113
113
|
export { normalizeWalletName } from '@dynamic-labs/wallet-connector-core';
|
|
114
|
+
import '@dynamic-labs/multi-wallet';
|
|
114
115
|
import './lib/utils/constants/colors.js';
|
|
115
116
|
export { isSameWalletName } from './lib/utils/functions/isSameWalletName/isSameWalletName.js';
|
|
116
117
|
import './lib/context/ViewContext/ViewContext.js';
|
package/src/lib/Main.cjs
CHANGED
|
@@ -6,14 +6,14 @@ var _tslib = require('../../_virtual/_tslib.cjs');
|
|
|
6
6
|
var jsxRuntime = require('react/jsx-runtime');
|
|
7
7
|
var React = require('react');
|
|
8
8
|
var utils = require('@dynamic-labs/utils');
|
|
9
|
-
|
|
9
|
+
require('../polyfills.cjs');
|
|
10
|
+
require('@dynamic-labs/multi-wallet');
|
|
10
11
|
require('@dynamic-labs/wallet-connector-core');
|
|
11
|
-
require('
|
|
12
|
-
require('./context/ErrorContext/ErrorContext.cjs');
|
|
13
|
-
var ViewContext = require('./context/ViewContext/ViewContext.cjs');
|
|
12
|
+
require('@dynamic-labs/rpc-providers');
|
|
14
13
|
require('@dynamic-labs/sdk-api');
|
|
15
14
|
require('./shared/logger.cjs');
|
|
16
15
|
require('@dynamic-labs/iconic');
|
|
16
|
+
var ViewContext = require('./context/ViewContext/ViewContext.cjs');
|
|
17
17
|
require('@dynamic-labs/wallet-book');
|
|
18
18
|
var localStorage$1 = require('./utils/constants/localStorage.cjs');
|
|
19
19
|
require('./utils/constants/colors.cjs');
|
|
@@ -21,7 +21,11 @@ var localStorage = require('./shared/utils/classes/storage/localStorage.cjs');
|
|
|
21
21
|
require('viem');
|
|
22
22
|
var usePreventPageScroll = require('./shared/utils/hooks/usePreventPageScroll/usePreventPageScroll.cjs');
|
|
23
23
|
var index$1 = require('./shared/consts/index.cjs');
|
|
24
|
-
require('
|
|
24
|
+
require('./context/DynamicContext/DynamicContext.cjs');
|
|
25
|
+
var useInternalDynamicContext = require('./context/DynamicContext/useInternalDynamicContext.cjs');
|
|
26
|
+
var UserWalletsContext = require('./context/UserWalletsContext/UserWalletsContext.cjs');
|
|
27
|
+
require('./context/CaptchaContext/CaptchaContext.cjs');
|
|
28
|
+
require('./context/ErrorContext/ErrorContext.cjs');
|
|
25
29
|
var isSupportedNetwork = require('./utils/functions/isSupportedNetwork/isSupportedNetwork.cjs');
|
|
26
30
|
var AccessDeniedContext = require('./context/AccessDeniedContext/AccessDeniedContext.cjs');
|
|
27
31
|
var AccountExistsContext = require('./context/AccountExistsContext/AccountExistsContext.cjs');
|
|
@@ -37,8 +41,6 @@ require('react-i18next');
|
|
|
37
41
|
require('./context/MockContext/MockContext.cjs');
|
|
38
42
|
require('./utils/hooks/useUserUpdateRequest/useUpdateUser/useUpdateUser.cjs');
|
|
39
43
|
require('./context/UserFieldEditorContext/UserFieldEditorContext.cjs');
|
|
40
|
-
require('@dynamic-labs/rpc-providers');
|
|
41
|
-
require('./context/UserWalletsContext/UserWalletsContext.cjs');
|
|
42
44
|
var useWalletItemActions = require('./utils/hooks/useWalletItemActions/useWalletItemActions.cjs');
|
|
43
45
|
var DynamicAuthModal = require('./modals/DynamicAuthModal/DynamicAuthModal.cjs');
|
|
44
46
|
require('./components/IconButton/IconButton.cjs');
|
|
@@ -56,12 +58,25 @@ var PopperContext = require('./components/Popper/PopperContext/PopperContext.cjs
|
|
|
56
58
|
var Portal = require('./components/Portal/Portal.cjs');
|
|
57
59
|
require('i18next');
|
|
58
60
|
require('./components/OverlayCard/OverlayCard.context.cjs');
|
|
61
|
+
require('./widgets/DynamicBridgeWidget/context/DynamicBridgeWidgetContext/DynamicBridgeWidgetContext.cjs');
|
|
62
|
+
require('./widgets/DynamicWidget/context/DynamicWidgetContext.cjs');
|
|
63
|
+
require('./widgets/DynamicWidget/components/DynamicWidgetCard/DynamicWidgetCard.cjs');
|
|
64
|
+
require('./components/UserProfile/parts/UserProfileField/components/VerifiedEmailIcon/VerifiedEmailIcon.cjs');
|
|
59
65
|
var index = require('./context/FooterAnimationContext/index.cjs');
|
|
60
66
|
var SocialRedirectContext = require('./context/SocialRedirectContext/SocialRedirectContext.cjs');
|
|
61
|
-
|
|
62
|
-
|
|
67
|
+
require('./context/QrCodeContext/QrCodeContext.cjs');
|
|
68
|
+
require('./context/WalletGroupContext/WalletGroupContext.cjs');
|
|
69
|
+
require('./widgets/DynamicWidget/components/DynamicWidgetHeader/DynamicWidgetHeader.cjs');
|
|
70
|
+
require('qrcode');
|
|
71
|
+
require('./context/LoadingContext/LoadingContext.cjs');
|
|
72
|
+
require('./widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.cjs');
|
|
73
|
+
require('./views/WalletList/WalletList.cjs');
|
|
63
74
|
var viewToComponentMap = require('./views/viewToComponentMap.cjs');
|
|
75
|
+
require('./context/FundingContext/FundingContext.cjs');
|
|
76
|
+
require('./context/SendBalanceContext/SendBalanceContext.cjs');
|
|
64
77
|
require('./main.global.cjs');
|
|
78
|
+
var isSelectedWalletAlreadyConnected = require('./utils/functions/isSelectedWalletAlreadyConnected/isSelectedWalletAlreadyConnected.cjs');
|
|
79
|
+
var useVerifyOnAwaitingSignature = require('./utils/hooks/multiWallet/useVerifyOnAwaitingSignature/useVerifyOnAwaitingSignature.cjs');
|
|
65
80
|
|
|
66
81
|
const viewsToDisableCloseOnOverlayClick = [
|
|
67
82
|
'email-wallet-otp-verification-view',
|
|
@@ -74,7 +89,7 @@ const Main = () => {
|
|
|
74
89
|
const { setDeniedAddress, setDeniedOauthProvider } = AccessDeniedContext.useAccessDeniedContext();
|
|
75
90
|
const { setExistentAccountData } = AccountExistsContext.useAccountExistsContext();
|
|
76
91
|
usePreventPageScroll.usePreventPageScroll(showAuthFlow);
|
|
77
|
-
const userWallets =
|
|
92
|
+
const userWallets = UserWalletsContext.useUserWallets();
|
|
78
93
|
const handleClose = () => _tslib.__awaiter(void 0, void 0, void 0, function* () {
|
|
79
94
|
if (viewsToDisableCloseOnOverlayClick.includes(view))
|
|
80
95
|
return;
|
package/src/lib/Main.js
CHANGED
|
@@ -2,14 +2,14 @@ import { __awaiter } from '../../_virtual/_tslib.js';
|
|
|
2
2
|
import { jsx } from 'react/jsx-runtime';
|
|
3
3
|
import { useCallback, useEffect } from 'react';
|
|
4
4
|
import { isMobile } from '@dynamic-labs/utils';
|
|
5
|
-
import
|
|
5
|
+
import '../polyfills.js';
|
|
6
|
+
import '@dynamic-labs/multi-wallet';
|
|
6
7
|
import '@dynamic-labs/wallet-connector-core';
|
|
7
|
-
import '
|
|
8
|
-
import './context/ErrorContext/ErrorContext.js';
|
|
9
|
-
import { useViewContext } from './context/ViewContext/ViewContext.js';
|
|
8
|
+
import '@dynamic-labs/rpc-providers';
|
|
10
9
|
import '@dynamic-labs/sdk-api';
|
|
11
10
|
import './shared/logger.js';
|
|
12
11
|
import '@dynamic-labs/iconic';
|
|
12
|
+
import { useViewContext } from './context/ViewContext/ViewContext.js';
|
|
13
13
|
import '@dynamic-labs/wallet-book';
|
|
14
14
|
import { NEWTOWEB3_WALLET_EXTENSION_FLAG_KEY } from './utils/constants/localStorage.js';
|
|
15
15
|
import './utils/constants/colors.js';
|
|
@@ -17,7 +17,11 @@ import { LocalStorage } from './shared/utils/classes/storage/localStorage.js';
|
|
|
17
17
|
import 'viem';
|
|
18
18
|
import { usePreventPageScroll } from './shared/utils/hooks/usePreventPageScroll/usePreventPageScroll.js';
|
|
19
19
|
import { authModalZIndex } from './shared/consts/index.js';
|
|
20
|
-
import '
|
|
20
|
+
import './context/DynamicContext/DynamicContext.js';
|
|
21
|
+
import { useInternalDynamicContext } from './context/DynamicContext/useInternalDynamicContext.js';
|
|
22
|
+
import { useUserWallets } from './context/UserWalletsContext/UserWalletsContext.js';
|
|
23
|
+
import './context/CaptchaContext/CaptchaContext.js';
|
|
24
|
+
import './context/ErrorContext/ErrorContext.js';
|
|
21
25
|
import { isSupportedNetwork } from './utils/functions/isSupportedNetwork/isSupportedNetwork.js';
|
|
22
26
|
import { useAccessDeniedContext } from './context/AccessDeniedContext/AccessDeniedContext.js';
|
|
23
27
|
import { useAccountExistsContext } from './context/AccountExistsContext/AccountExistsContext.js';
|
|
@@ -33,8 +37,6 @@ import 'react-i18next';
|
|
|
33
37
|
import './context/MockContext/MockContext.js';
|
|
34
38
|
import './utils/hooks/useUserUpdateRequest/useUpdateUser/useUpdateUser.js';
|
|
35
39
|
import './context/UserFieldEditorContext/UserFieldEditorContext.js';
|
|
36
|
-
import '@dynamic-labs/rpc-providers';
|
|
37
|
-
import './context/UserWalletsContext/UserWalletsContext.js';
|
|
38
40
|
import { useWalletItemActions } from './utils/hooks/useWalletItemActions/useWalletItemActions.js';
|
|
39
41
|
import { DynamicAuthModal } from './modals/DynamicAuthModal/DynamicAuthModal.js';
|
|
40
42
|
import './components/IconButton/IconButton.js';
|
|
@@ -52,12 +54,25 @@ import { PopperProvider } from './components/Popper/PopperContext/PopperContext.
|
|
|
52
54
|
import { Portal } from './components/Portal/Portal.js';
|
|
53
55
|
import 'i18next';
|
|
54
56
|
import './components/OverlayCard/OverlayCard.context.js';
|
|
57
|
+
import './widgets/DynamicBridgeWidget/context/DynamicBridgeWidgetContext/DynamicBridgeWidgetContext.js';
|
|
58
|
+
import './widgets/DynamicWidget/context/DynamicWidgetContext.js';
|
|
59
|
+
import './widgets/DynamicWidget/components/DynamicWidgetCard/DynamicWidgetCard.js';
|
|
60
|
+
import './components/UserProfile/parts/UserProfileField/components/VerifiedEmailIcon/VerifiedEmailIcon.js';
|
|
55
61
|
import { FooterAnimationContextProvider } from './context/FooterAnimationContext/index.js';
|
|
56
62
|
import { SocialRedirectContextProvider } from './context/SocialRedirectContext/SocialRedirectContext.js';
|
|
57
|
-
import
|
|
58
|
-
import
|
|
63
|
+
import './context/QrCodeContext/QrCodeContext.js';
|
|
64
|
+
import './context/WalletGroupContext/WalletGroupContext.js';
|
|
65
|
+
import './widgets/DynamicWidget/components/DynamicWidgetHeader/DynamicWidgetHeader.js';
|
|
66
|
+
import 'qrcode';
|
|
67
|
+
import './context/LoadingContext/LoadingContext.js';
|
|
68
|
+
import './widgets/DynamicWidget/views/ManagePasskeysWidgetView/PasskeyCard/PasskeyCard.js';
|
|
69
|
+
import './views/WalletList/WalletList.js';
|
|
59
70
|
import { viewToComponentMap } from './views/viewToComponentMap.js';
|
|
71
|
+
import './context/FundingContext/FundingContext.js';
|
|
72
|
+
import './context/SendBalanceContext/SendBalanceContext.js';
|
|
60
73
|
import './main.global.js';
|
|
74
|
+
import { isSelectedWalletAlreadyConnected } from './utils/functions/isSelectedWalletAlreadyConnected/isSelectedWalletAlreadyConnected.js';
|
|
75
|
+
import { useVerifyOnAwaitingSignature } from './utils/hooks/multiWallet/useVerifyOnAwaitingSignature/useVerifyOnAwaitingSignature.js';
|
|
61
76
|
|
|
62
77
|
const viewsToDisableCloseOnOverlayClick = [
|
|
63
78
|
'email-wallet-otp-verification-view',
|
|
@@ -70,7 +85,7 @@ const Main = () => {
|
|
|
70
85
|
const { setDeniedAddress, setDeniedOauthProvider } = useAccessDeniedContext();
|
|
71
86
|
const { setExistentAccountData } = useAccountExistsContext();
|
|
72
87
|
usePreventPageScroll(showAuthFlow);
|
|
73
|
-
const userWallets =
|
|
88
|
+
const userWallets = useUserWallets();
|
|
74
89
|
const handleClose = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
75
90
|
if (viewsToDisableCloseOnOverlayClick.includes(view))
|
|
76
91
|
return;
|
|
@@ -6,10 +6,10 @@ var jsxRuntime = require('react/jsx-runtime');
|
|
|
6
6
|
var React = require('react');
|
|
7
7
|
var utils = require('@dynamic-labs/utils');
|
|
8
8
|
var classNames = require('../../utils/functions/classNames/classNames.cjs');
|
|
9
|
+
require('@dynamic-labs/wallet-connector-core');
|
|
9
10
|
require('@dynamic-labs/sdk-api');
|
|
10
11
|
require('../../shared/logger.cjs');
|
|
11
12
|
require('@dynamic-labs/iconic');
|
|
12
|
-
require('@dynamic-labs/wallet-connector-core');
|
|
13
13
|
require('../../context/ViewContext/ViewContext.cjs');
|
|
14
14
|
require('@dynamic-labs/wallet-book');
|
|
15
15
|
require('../../utils/constants/colors.cjs');
|
|
@@ -2,10 +2,10 @@ import { jsxs, jsx } from 'react/jsx-runtime';
|
|
|
2
2
|
import { useState, useEffect } from 'react';
|
|
3
3
|
import { isLegacySafari } from '@dynamic-labs/utils';
|
|
4
4
|
import { classNames } from '../../utils/functions/classNames/classNames.js';
|
|
5
|
+
import '@dynamic-labs/wallet-connector-core';
|
|
5
6
|
import '@dynamic-labs/sdk-api';
|
|
6
7
|
import '../../shared/logger.js';
|
|
7
8
|
import '@dynamic-labs/iconic';
|
|
8
|
-
import '@dynamic-labs/wallet-connector-core';
|
|
9
9
|
import '../../context/ViewContext/ViewContext.js';
|
|
10
10
|
import '@dynamic-labs/wallet-book';
|
|
11
11
|
import '../../utils/constants/colors.js';
|
|
@@ -4,10 +4,10 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var jsxRuntime = require('react/jsx-runtime');
|
|
6
6
|
var ThemeContext = require('../../../context/ThemeContext/ThemeContext.cjs');
|
|
7
|
+
require('@dynamic-labs/wallet-connector-core');
|
|
7
8
|
require('@dynamic-labs/sdk-api');
|
|
8
9
|
require('../../../shared/logger.cjs');
|
|
9
10
|
require('@dynamic-labs/iconic');
|
|
10
|
-
require('@dynamic-labs/wallet-connector-core');
|
|
11
11
|
require('../../../context/ViewContext/ViewContext.cjs');
|
|
12
12
|
require('react');
|
|
13
13
|
require('@dynamic-labs/wallet-book');
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { useThemeContext } from '../../../context/ThemeContext/ThemeContext.js';
|
|
3
|
+
import '@dynamic-labs/wallet-connector-core';
|
|
3
4
|
import '@dynamic-labs/sdk-api';
|
|
4
5
|
import '../../../shared/logger.js';
|
|
5
6
|
import '@dynamic-labs/iconic';
|
|
6
|
-
import '@dynamic-labs/wallet-connector-core';
|
|
7
7
|
import '../../../context/ViewContext/ViewContext.js';
|
|
8
8
|
import 'react';
|
|
9
9
|
import '@dynamic-labs/wallet-book';
|
|
@@ -4,10 +4,10 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var jsxRuntime = require('react/jsx-runtime');
|
|
6
6
|
var walletBook = require('@dynamic-labs/wallet-book');
|
|
7
|
+
require('@dynamic-labs/wallet-connector-core');
|
|
7
8
|
require('@dynamic-labs/sdk-api');
|
|
8
9
|
require('../../shared/logger.cjs');
|
|
9
10
|
require('@dynamic-labs/iconic');
|
|
10
|
-
require('@dynamic-labs/wallet-connector-core');
|
|
11
11
|
require('../../context/ViewContext/ViewContext.cjs');
|
|
12
12
|
require('react');
|
|
13
13
|
require('../../utils/constants/colors.cjs');
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
2
2
|
import { WalletIcon } from '@dynamic-labs/wallet-book';
|
|
3
|
+
import '@dynamic-labs/wallet-connector-core';
|
|
3
4
|
import '@dynamic-labs/sdk-api';
|
|
4
5
|
import '../../shared/logger.js';
|
|
5
6
|
import '@dynamic-labs/iconic';
|
|
6
|
-
import '@dynamic-labs/wallet-connector-core';
|
|
7
7
|
import '../../context/ViewContext/ViewContext.js';
|
|
8
8
|
import 'react';
|
|
9
9
|
import '../../utils/constants/colors.js';
|
|
@@ -9,11 +9,11 @@ var classNames = require('../../../utils/functions/classNames/classNames.cjs');
|
|
|
9
9
|
var Popper = require('../../Popper/Popper/Popper.cjs');
|
|
10
10
|
var PopperContext = require('../../Popper/PopperContext/PopperContext.cjs');
|
|
11
11
|
var watchToScrollInHierarchy = require('../utils/watchToScrollInHierarchy/watchToScrollInHierarchy.cjs');
|
|
12
|
+
var useForwardedRef = require('../../../shared/utils/hooks/useForwardedRef/useForwardedRef.cjs');
|
|
12
13
|
require('../../../shared/logger.cjs');
|
|
13
14
|
require('../../../shared/utils/classes/storage/localStorage.cjs');
|
|
14
15
|
var index = require('../../../shared/utils/hooks/useOnClickOutside/index.cjs');
|
|
15
16
|
require('@dynamic-labs/utils');
|
|
16
|
-
var useForwardedRef = require('../../../shared/utils/hooks/useForwardedRef/useForwardedRef.cjs');
|
|
17
17
|
require('@dynamic-labs/sdk-api');
|
|
18
18
|
require('@dynamic-labs/iconic');
|
|
19
19
|
require('@dynamic-labs/wallet-connector-core');
|
|
@@ -5,11 +5,11 @@ import { classNames } from '../../../utils/functions/classNames/classNames.js';
|
|
|
5
5
|
import { Popper } from '../../Popper/Popper/Popper.js';
|
|
6
6
|
import { usePopper } from '../../Popper/PopperContext/PopperContext.js';
|
|
7
7
|
import { watchToScrollInHierarchy } from '../utils/watchToScrollInHierarchy/watchToScrollInHierarchy.js';
|
|
8
|
+
import { useForwardedRef } from '../../../shared/utils/hooks/useForwardedRef/useForwardedRef.js';
|
|
8
9
|
import '../../../shared/logger.js';
|
|
9
10
|
import '../../../shared/utils/classes/storage/localStorage.js';
|
|
10
11
|
import { useOnClickOutside } from '../../../shared/utils/hooks/useOnClickOutside/index.js';
|
|
11
12
|
import '@dynamic-labs/utils';
|
|
12
|
-
import { useForwardedRef } from '../../../shared/utils/hooks/useForwardedRef/useForwardedRef.js';
|
|
13
13
|
import '@dynamic-labs/sdk-api';
|
|
14
14
|
import '@dynamic-labs/iconic';
|
|
15
15
|
import '@dynamic-labs/wallet-connector-core';
|
|
@@ -87,7 +87,10 @@ const EvmNetworkControl = ({ evmNetworks, className = '', activeClassName = '',
|
|
|
87
87
|
[activeClassName]: isOpen,
|
|
88
88
|
}, className), children: currentEvmNetwork.name && ((_a = currentEvmNetwork.iconUrls) === null || _a === void 0 ? void 0 : _a[0]) ? (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(Icon.Icon, { size: 'small', children: jsxRuntime.jsx("img", { src: currentEvmNetwork.iconUrls[0], alt: `${currentEvmNetwork.name} icon` }) }), showNetworkName && (jsxRuntime.jsx(Typography.Typography, { className: 'evm-network-control__network-name', as: 'span', variant: 'body_small', children: currentEvmNetwork.vanityName || currentEvmNetwork.name }))] })) : (jsxRuntime.jsx(UnsupportedNetwork.UnsupportedNetwork, { showMsg: showNetworkName })) }));
|
|
89
89
|
}
|
|
90
|
-
return (jsxRuntime.jsxs("button", { "data-testid": 'EvmNetworkControl', type: 'button', onClick: () =>
|
|
90
|
+
return (jsxRuntime.jsxs("button", { "data-testid": 'EvmNetworkControl', type: 'button', onClick: (e) => {
|
|
91
|
+
e.stopPropagation();
|
|
92
|
+
network && setIsOpen(!isOpen);
|
|
93
|
+
}, className: classNames.classNames(className, {
|
|
91
94
|
[activeClassName]: isOpen,
|
|
92
95
|
'evm-network-control__container': Boolean(walletConnector === null || walletConnector === void 0 ? void 0 : walletConnector.supportsNetworkSwitching()),
|
|
93
96
|
'evm-network-control__container--error': !(currentEvmNetwork === null || currentEvmNetwork === void 0 ? void 0 : currentEvmNetwork.name),
|
|
@@ -83,7 +83,10 @@ const EvmNetworkControl = ({ evmNetworks, className = '', activeClassName = '',
|
|
|
83
83
|
[activeClassName]: isOpen,
|
|
84
84
|
}, className), children: currentEvmNetwork.name && ((_a = currentEvmNetwork.iconUrls) === null || _a === void 0 ? void 0 : _a[0]) ? (jsxs(Fragment, { children: [jsx(Icon, { size: 'small', children: jsx("img", { src: currentEvmNetwork.iconUrls[0], alt: `${currentEvmNetwork.name} icon` }) }), showNetworkName && (jsx(Typography, { className: 'evm-network-control__network-name', as: 'span', variant: 'body_small', children: currentEvmNetwork.vanityName || currentEvmNetwork.name }))] })) : (jsx(UnsupportedNetwork, { showMsg: showNetworkName })) }));
|
|
85
85
|
}
|
|
86
|
-
return (jsxs("button", { "data-testid": 'EvmNetworkControl', type: 'button', onClick: () =>
|
|
86
|
+
return (jsxs("button", { "data-testid": 'EvmNetworkControl', type: 'button', onClick: (e) => {
|
|
87
|
+
e.stopPropagation();
|
|
88
|
+
network && setIsOpen(!isOpen);
|
|
89
|
+
}, className: classNames(className, {
|
|
87
90
|
[activeClassName]: isOpen,
|
|
88
91
|
'evm-network-control__container': Boolean(walletConnector === null || walletConnector === void 0 ? void 0 : walletConnector.supportsNetworkSwitching()),
|
|
89
92
|
'evm-network-control__container--error': !(currentEvmNetwork === null || currentEvmNetwork === void 0 ? void 0 : currentEvmNetwork.name),
|
|
@@ -9,10 +9,10 @@ var formik = require('formik');
|
|
|
9
9
|
var yup = require('yup');
|
|
10
10
|
var Input = require('../Input/Input.cjs');
|
|
11
11
|
var Button = require('../Button/Button.cjs');
|
|
12
|
+
require('@dynamic-labs/wallet-connector-core');
|
|
12
13
|
require('@dynamic-labs/sdk-api');
|
|
13
14
|
require('../../shared/logger.cjs');
|
|
14
15
|
require('@dynamic-labs/iconic');
|
|
15
|
-
require('@dynamic-labs/wallet-connector-core');
|
|
16
16
|
require('../../context/ViewContext/ViewContext.cjs');
|
|
17
17
|
require('@dynamic-labs/wallet-book');
|
|
18
18
|
require('../../utils/constants/colors.cjs');
|
|
@@ -5,10 +5,10 @@ import { Formik, Form, Field } from 'formik';
|
|
|
5
5
|
import { object, string } from 'yup';
|
|
6
6
|
import { Input } from '../Input/Input.js';
|
|
7
7
|
import { Button } from '../Button/Button.js';
|
|
8
|
+
import '@dynamic-labs/wallet-connector-core';
|
|
8
9
|
import '@dynamic-labs/sdk-api';
|
|
9
10
|
import '../../shared/logger.js';
|
|
10
11
|
import '@dynamic-labs/iconic';
|
|
11
|
-
import '@dynamic-labs/wallet-connector-core';
|
|
12
12
|
import '../../context/ViewContext/ViewContext.js';
|
|
13
13
|
import '@dynamic-labs/wallet-book';
|
|
14
14
|
import '../../utils/constants/colors.js';
|
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var _tslib = require('../../../../_virtual/_tslib.cjs');
|
|
6
|
-
var jsxRuntime = require('react/jsx-runtime');
|
|
7
6
|
var React = require('react');
|
|
8
7
|
var useInternalDynamicContext = require('../../context/DynamicContext/useInternalDynamicContext.cjs');
|
|
9
8
|
require('@dynamic-labs/sdk-api');
|
|
10
9
|
require('../../shared/logger.cjs');
|
|
11
10
|
require('@dynamic-labs/iconic');
|
|
12
11
|
require('@dynamic-labs/wallet-connector-core');
|
|
12
|
+
require('react/jsx-runtime');
|
|
13
13
|
require('../../context/ViewContext/ViewContext.cjs');
|
|
14
14
|
require('@dynamic-labs/wallet-book');
|
|
15
15
|
var localStorage$1 = require('../../utils/constants/localStorage.cjs');
|
|
@@ -102,7 +102,7 @@ const SyncPasskeyFlow = () => {
|
|
|
102
102
|
user,
|
|
103
103
|
createEmbeddedWallet,
|
|
104
104
|
]);
|
|
105
|
-
return
|
|
105
|
+
return null;
|
|
106
106
|
};
|
|
107
107
|
|
|
108
108
|
exports.SyncPasskeyFlow = SyncPasskeyFlow;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { __awaiter } from '../../../../_virtual/_tslib.js';
|
|
2
|
-
import { jsx, Fragment } from 'react/jsx-runtime';
|
|
3
2
|
import { useEffect } from 'react';
|
|
4
3
|
import { useInternalDynamicContext } from '../../context/DynamicContext/useInternalDynamicContext.js';
|
|
5
4
|
import '@dynamic-labs/sdk-api';
|
|
6
5
|
import '../../shared/logger.js';
|
|
7
6
|
import '@dynamic-labs/iconic';
|
|
8
7
|
import '@dynamic-labs/wallet-connector-core';
|
|
8
|
+
import 'react/jsx-runtime';
|
|
9
9
|
import '../../context/ViewContext/ViewContext.js';
|
|
10
10
|
import '@dynamic-labs/wallet-book';
|
|
11
11
|
import { LAST_USED_WALLET } from '../../utils/constants/localStorage.js';
|
|
@@ -98,7 +98,7 @@ const SyncPasskeyFlow = () => {
|
|
|
98
98
|
user,
|
|
99
99
|
createEmbeddedWallet,
|
|
100
100
|
]);
|
|
101
|
-
return
|
|
101
|
+
return null;
|
|
102
102
|
};
|
|
103
103
|
|
|
104
104
|
export { SyncPasskeyFlow };
|
|
@@ -6,10 +6,10 @@ var jsxRuntime = require('react/jsx-runtime');
|
|
|
6
6
|
var React = require('react');
|
|
7
7
|
var formik = require('formik');
|
|
8
8
|
var useUserDataForm = require('../../utils/hooks/useUserDataForm/useUserDataForm.cjs');
|
|
9
|
+
require('@dynamic-labs/wallet-connector-core');
|
|
9
10
|
require('@dynamic-labs/sdk-api');
|
|
10
11
|
require('../../shared/logger.cjs');
|
|
11
12
|
require('@dynamic-labs/iconic');
|
|
12
|
-
require('@dynamic-labs/wallet-connector-core');
|
|
13
13
|
require('../../context/ViewContext/ViewContext.cjs');
|
|
14
14
|
var check = require('../../shared/assets/check.cjs');
|
|
15
15
|
require('@dynamic-labs/wallet-book');
|
|
@@ -2,10 +2,10 @@ import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
|
2
2
|
import { useMemo } from 'react';
|
|
3
3
|
import { Formik, Form } from 'formik';
|
|
4
4
|
import { useUserDataForm } from '../../utils/hooks/useUserDataForm/useUserDataForm.js';
|
|
5
|
+
import '@dynamic-labs/wallet-connector-core';
|
|
5
6
|
import '@dynamic-labs/sdk-api';
|
|
6
7
|
import '../../shared/logger.js';
|
|
7
8
|
import '@dynamic-labs/iconic';
|
|
8
|
-
import '@dynamic-labs/wallet-connector-core';
|
|
9
9
|
import '../../context/ViewContext/ViewContext.js';
|
|
10
10
|
import { ReactComponent as SvgCheck } from '../../shared/assets/check.js';
|
|
11
11
|
import '@dynamic-labs/wallet-book';
|
|
@@ -21,8 +21,8 @@ require('../../utils/constants/colors.cjs');
|
|
|
21
21
|
var values = require('../../utils/constants/values.cjs');
|
|
22
22
|
var localStorage = require('../../shared/utils/classes/storage/localStorage.cjs');
|
|
23
23
|
require('viem');
|
|
24
|
-
var useLocalStorage = require('../../shared/utils/hooks/useLocalStorage/useLocalStorage.cjs');
|
|
25
24
|
var useGlobalLoading = require('../../shared/utils/hooks/useGlobalLoading/useGlobalLoading.cjs');
|
|
25
|
+
var useLocalStorage = require('../../shared/utils/hooks/useLocalStorage/useLocalStorage.cjs');
|
|
26
26
|
require('../../shared/consts/index.cjs');
|
|
27
27
|
require('@dynamic-labs/multi-wallet');
|
|
28
28
|
var getAuthToken = require('../../utils/functions/getAuthToken/getAuthToken.cjs');
|
|
@@ -118,7 +118,7 @@ const DynamicContext = React.createContext(undefined);
|
|
|
118
118
|
/** The context provider itself we only use internally */
|
|
119
119
|
const InnerDynamicContextProvider = ({ children, theme, settings, locale: locale$1, }) => {
|
|
120
120
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
121
|
-
const { accessDeniedMessagePrimary, accessDeniedMessageSecondary, accessDeniedButton, apiBaseUrl, enableForcedNetworkValidation: enableForcedNetworkValidationProp = false, deepLinkPreference = 'native', bridgeChains, cssOverrides, defaultNumberOfWalletsToShow = values.DEFAULT_NUMBER_OF_WALLETS_TO_SHOW, flowNetwork, initialAuthenticationMode = 'connect-and-sign', debugError = false, displaySiweStatement = true, newToWeb3WalletChainMap, enableVisitTrackingOnConnectOnly = true, environmentId, localStorageSuffix, eventsCallbacks, evmNetworks, walletsFilter, logLevel = 'WARN', notInTheListImageUrl, onboardingImageUrl, policiesConsentInnerComponent, customPrivacyPolicy, privacyPolicyUrl, signWithEmailWalletName, socialMediaLinkText, socialMediaIconUrl, socialMediaUrl, customTermsOfServices, termsOfServiceUrl, toolkitEnabled, siweStatement, shadowDOMEnabled = true, walletConnectors: walletConnectorsProp, socialProvidersFilter, showLockedWalletView =
|
|
121
|
+
const { accessDeniedMessagePrimary, accessDeniedMessageSecondary, accessDeniedButton, apiBaseUrl, enableForcedNetworkValidation: enableForcedNetworkValidationProp = false, deepLinkPreference = 'native', bridgeChains, cssOverrides, defaultNumberOfWalletsToShow = values.DEFAULT_NUMBER_OF_WALLETS_TO_SHOW, flowNetwork, initialAuthenticationMode = 'connect-and-sign', debugError = false, displaySiweStatement = true, newToWeb3WalletChainMap, enableVisitTrackingOnConnectOnly = true, environmentId, localStorageSuffix, eventsCallbacks, evmNetworks, walletsFilter, logLevel = 'WARN', notInTheListImageUrl, onboardingImageUrl, policiesConsentInnerComponent, customPrivacyPolicy, privacyPolicyUrl, signWithEmailWalletName, socialMediaLinkText, socialMediaIconUrl, socialMediaUrl, customTermsOfServices, termsOfServiceUrl, toolkitEnabled, siweStatement, shadowDOMEnabled = true, walletConnectors: walletConnectorsProp, socialProvidersFilter, showLockedWalletView = false, walletConnectPreferredChains, walletConnectorExtensions, } = settings;
|
|
122
122
|
let enableForcedNetworkValidation = enableForcedNetworkValidationProp;
|
|
123
123
|
if (bridgeChains) {
|
|
124
124
|
enableForcedNetworkValidation = true;
|
|
@@ -370,9 +370,11 @@ const InnerDynamicContextProvider = ({ children, theme, settings, locale: locale
|
|
|
370
370
|
});
|
|
371
371
|
const handleUnlinkWallet = useHandleUnlinkWallet.useHandleUnlinkWallet({
|
|
372
372
|
environmentId,
|
|
373
|
+
eventsCallbacks,
|
|
373
374
|
primaryWalletId,
|
|
374
375
|
secondaryWallets,
|
|
375
376
|
setUser,
|
|
377
|
+
user,
|
|
376
378
|
verifiedCredentials: (user === null || user === void 0 ? void 0 : user.verifiedCredentials) || [],
|
|
377
379
|
});
|
|
378
380
|
const { loadingNetwork, network, setNetwork } = useWalletEventListeners.useWalletEventListeners({
|