@getpara/react-sdk 2.0.0-alpha.20 → 2.0.0-alpha.21

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 (88) hide show
  1. package/dist/index.d.ts +0 -1
  2. package/dist/index.js +0 -5
  3. package/dist/modal/ParaModal.js +15 -5
  4. package/dist/modal/components/Account/Account.js +14 -8
  5. package/dist/modal/components/Account/AccountProfile.d.ts +1 -0
  6. package/dist/modal/components/Account/AccountProfile.js +170 -0
  7. package/dist/modal/components/Account/AccountProfileLink.d.ts +1 -0
  8. package/dist/modal/components/Account/AccountProfileLink.js +205 -0
  9. package/dist/modal/components/Account/AccountProfileLinkOptions.d.ts +1 -0
  10. package/dist/modal/components/Account/AccountProfileLinkOptions.js +98 -0
  11. package/dist/modal/components/Account/AccountProfileUnlink.d.ts +1 -0
  12. package/dist/modal/components/Account/AccountProfileUnlink.js +47 -0
  13. package/dist/modal/components/AuthInput/AuthInput.d.ts +17 -3
  14. package/dist/modal/components/AuthInput/AuthInput.js +116 -101
  15. package/dist/modal/components/AuthMainStep/AuthMainStepContent.js +2 -2
  16. package/dist/modal/components/AuthOptions/AuthOptions.js +26 -1
  17. package/dist/modal/components/Body/Body.js +21 -2
  18. package/dist/modal/components/Controls/Selects.js +3 -19
  19. package/dist/modal/components/ExternalWalletStep/ExternalWalletStep.d.ts +7 -0
  20. package/dist/modal/components/ExternalWalletStep/ExternalWalletStep.js +70 -39
  21. package/dist/modal/components/Header/hooks/useStepTitle.js +7 -1
  22. package/dist/modal/components/OAuth/FarcasterOAuthStep.d.ts +1 -0
  23. package/dist/modal/components/OAuth/FarcasterOAuthStep.js +6 -2
  24. package/dist/modal/components/OAuth/OAuth.js +2 -2
  25. package/dist/modal/components/OAuth/TelegramOAuthStep.d.ts +7 -0
  26. package/dist/modal/components/OAuth/TelegramOAuthStep.js +36 -52
  27. package/dist/modal/components/VerificationCodeStep/VerificationCodeStep.d.ts +12 -1
  28. package/dist/modal/components/VerificationCodeStep/VerificationCodeStep.js +40 -23
  29. package/dist/modal/components/common.d.ts +18 -1
  30. package/dist/modal/components/common.js +86 -0
  31. package/dist/modal/constants/constants.d.ts +1 -1
  32. package/dist/modal/constants/constants.js +1 -1
  33. package/dist/modal/constants/oAuthLogos.d.ts +15 -6
  34. package/dist/modal/constants/oAuthLogos.js +148 -19
  35. package/dist/modal/hooks/useTelegramLogin.d.ts +12 -0
  36. package/dist/modal/hooks/useTelegramLogin.js +65 -0
  37. package/dist/modal/stores/modal/actions.js +6 -1
  38. package/dist/modal/stores/modal/useModalStore.d.ts +4 -3
  39. package/dist/modal/stores/modal/useModalStore.js +7 -2
  40. package/dist/modal/types/modalProps.d.ts +6 -1
  41. package/dist/modal/utils/authInputHelpers.d.ts +3 -5
  42. package/dist/modal/utils/authInputHelpers.js +23 -20
  43. package/dist/modal/utils/getWalletDisplayName.d.ts +5 -0
  44. package/dist/modal/utils/getWalletDisplayName.js +22 -0
  45. package/dist/modal/utils/steps.d.ts +10 -2
  46. package/dist/modal/utils/steps.js +18 -2
  47. package/dist/provider/ParaProvider.js +6 -5
  48. package/dist/provider/actions/index.d.ts +19 -0
  49. package/dist/provider/actions/index.js +47 -29
  50. package/dist/provider/actions/utils.d.ts +3 -2
  51. package/dist/provider/actions/utils.js +25 -6
  52. package/dist/provider/components/CosmosWalletWrapper.js +2 -2
  53. package/dist/provider/components/EvmWalletWrapper.js +2 -2
  54. package/dist/provider/components/ExternalWalletWrapper.js +2 -1
  55. package/dist/provider/components/SolanaWalletWrapper.js +2 -2
  56. package/dist/provider/external/stubs/CosmosExternalWalletContextStub.d.ts +0 -10
  57. package/dist/provider/external/stubs/CosmosExternalWalletContextStub.js +2 -12
  58. package/dist/provider/external/stubs/EvmExternalWalletContextStub.d.ts +0 -1
  59. package/dist/provider/external/stubs/EvmExternalWalletContextStub.js +2 -15
  60. package/dist/provider/external/stubs/SolanaExternalWalletContextStub.d.ts +0 -6
  61. package/dist/provider/external/stubs/SolanaExternalWalletContextStub.js +2 -8
  62. package/dist/provider/hooks/mutations/core.d.ts +27 -0
  63. package/dist/provider/hooks/mutations/core.js +66 -0
  64. package/dist/provider/hooks/mutations/index.d.ts +3 -28
  65. package/dist/provider/hooks/mutations/index.js +4 -60
  66. package/dist/provider/hooks/mutations/useLinkAccount.d.ts +9 -0
  67. package/dist/provider/hooks/mutations/useLinkAccount.js +18 -0
  68. package/dist/provider/hooks/mutations/utils.d.ts +11 -4
  69. package/dist/provider/hooks/mutations/utils.js +35 -4
  70. package/dist/provider/hooks/queries/core.d.ts +2 -0
  71. package/dist/provider/hooks/queries/core.js +13 -0
  72. package/dist/provider/hooks/queries/index.d.ts +1 -0
  73. package/dist/provider/hooks/queries/index.js +1 -0
  74. package/dist/provider/hooks/queries/utils.d.ts +4 -0
  75. package/dist/provider/hooks/queries/utils.js +24 -0
  76. package/dist/provider/hooks/utils/useModal.d.ts +4 -1
  77. package/dist/provider/hooks/utils/useModal.js +12 -2
  78. package/dist/provider/providers/AccountLinkProvider.d.ts +42 -0
  79. package/dist/provider/providers/AccountLinkProvider.js +443 -0
  80. package/dist/provider/providers/AuthProvider.d.ts +3 -1
  81. package/dist/provider/providers/AuthProvider.js +8 -5
  82. package/dist/provider/providers/ExternalWalletProvider.d.ts +18 -32
  83. package/dist/provider/providers/ExternalWalletProvider.js +167 -36
  84. package/dist/provider/stores/slices/modal.js +3 -1
  85. package/dist/provider/stores/types.d.ts +2 -1
  86. package/dist/provider/types/utils.d.ts +25 -6
  87. package/dist/provider/utils/renameMutations.d.ts +2 -2
  88. package/package.json +8 -8
@@ -30,7 +30,7 @@ export declare function getNetworkName(str: Network | string): string;
30
30
  export declare function getNetworkIcon(str: Network | string): IconType;
31
31
  export declare function getAssetCode(str: OnRampAsset | string): string;
32
32
  export declare function getAssetName(str: OnRampAsset | string): string;
33
- export declare function getAssetIcon(str: OnRampAsset | string): "key" | "phone" | "farcaster" | "telegram" | "discord" | "x" | "search" | "para" | "wallet" | "close" | "copy" | "cosmos" | "code" | "menu" | "alertCircle" | "alertTriangle" | "alignVerticalCenter" | "angelListBrand" | "angelList" | "appleBrand" | "apple" | "arbitrumBrand" | "arrowCircleBrokenDownLeft" | "arrowCircleDownFilled" | "arrowNarrow" | "arrow" | "asterisk" | "backupKit" | "bank" | "baseBrand" | "brush" | "celoBrand" | "checkCircleFilled" | "checkCircle" | "checkSquare" | "check" | "chevronDown" | "chevronRight" | "chevronSelectorVertical" | "chevronUp" | "clock" | "clubhouseBrand" | "clubhouse" | "copy07" | "creditCard02" | "creditCard" | "cube03" | "cubeOutline" | "cube" | "currencyDollar" | "decentBrand" | "decent" | "dell" | "discordBrand" | "dot" | "dots" | "downloadCloud" | "download" | "dribbbleBrand" | "dribbble" | "earth" | "edit02" | "emptyCircle" | "ethereum" | "eyeOff" | "eye" | "facebookBrand" | "facebook" | "farcasterBrand" | "figmaBrand" | "figma" | "file" | "folder" | "githubBrand" | "github" | "globe" | "googleBrand" | "google" | "gridDots" | "helpCircle" | "heroAlertCircle" | "heroCheckmarkCapsule" | "heroCheckmark" | "heroEmail" | "heroExternalConnection" | "heroLock" | "heroPasskey" | "heroPhone" | "heroPlusCircleCapsule" | "heroPlusCircle" | "heroWallet" | "home" | "hp" | "image" | "infoCircle" | "instagramBrand" | "instagram" | "laptop" | "lenovo" | "lg" | "lightning01" | "lightning" | "linkExternal" | "linkedinBrand" | "linkedin" | "lockKeyholeCircle" | "logOut" | "mail" | "monitor" | "moonpayBrand" | "moreLoginOptions" | "motorola" | "nobleBrand" | "optimismBrand" | "paraBlackBg" | "paraBrand" | "paraIconBrand" | "paraIconQr" | "paraIcon" | "paraLogo" | "paraRingsDark" | "paraRings" | "passcode" | "pintrestBrand" | "pintrest" | "plusCircle" | "plus" | "polygonBrand" | "polygon" | "puzzlePiece" | "qrCode02" | "qrCode" | "rampNetworkBrand" | "rampNetwork" | "redditBrand" | "reddit" | "refresh" | "samsung" | "send" | "settings" | "share" | "shield" | "signalBrand" | "signal" | "sliders" | "snapchatBrand" | "snapchat" | "solana" | "spacingHeight" | "star04Filled" | "star05" | "stars01Filled" | "stars02" | "stars" | "stopSquare" | "stripeBrand" | "telegramBrand" | "tetherBrand" | "tikTokBrand" | "tikTok" | "trash" | "tumblrBrand" | "tumblr" | "twitterBrand" | "twitter" | "usdcBrand" | "userCircle" | "user" | "youtubeBrand" | "youtube" | "AD" | "AE" | "AF" | "AG" | "AI" | "AL" | "AM" | "AO" | "AR" | "AS" | "AT" | "AU" | "AW" | "AX" | "AZ" | "BA" | "BB" | "BD" | "BE" | "BF" | "BG" | "BH" | "BI" | "BJ" | "BL" | "BM" | "BN" | "BO" | "BQ" | "BQ2" | "BQ3" | "BR" | "BS" | "BT" | "BW" | "BY" | "BZ" | "CA" | "CC" | "CD" | "CD2" | "CF" | "CH" | "CK" | "CL" | "CM" | "CN" | "CO" | "CR" | "CU" | "CW" | "CX" | "CY" | "CZ" | "DE" | "DJ" | "DK" | "DM" | "DO" | "DS" | "DZ" | "EC" | "EE" | "EG" | "EH" | "ER" | "ES" | "ET" | "FI" | "FJ" | "FK" | "FM" | "FO" | "FR" | "GA" | "GB2" | "GB" | "GD" | "GE" | "GG" | "GH" | "GI" | "GL" | "GM" | "GN" | "GQ" | "GR" | "GT" | "GU" | "GW" | "GY" | "HK" | "HN" | "HR" | "HT" | "HU" | "ID" | "IE" | "IL" | "IM" | "IN" | "IO" | "IQ" | "IR" | "IS" | "IT" | "JE" | "JM" | "JO" | "JP" | "KE" | "KG" | "KH" | "KI" | "KM" | "KN" | "KP" | "KR" | "KW" | "KY" | "KZ" | "LA" | "LB" | "LC" | "LI" | "LK" | "LR" | "LS" | "LT" | "LU" | "LV" | "LY" | "MA" | "MC" | "MD" | "ME" | "MG" | "MH" | "MK" | "ML" | "MM" | "MN" | "MO" | "MP" | "MQ" | "MR" | "MS" | "MT" | "MU" | "MV" | "MW" | "MX" | "MY" | "MZ" | "NA" | "NE" | "NF" | "NG" | "NI" | "NL" | "NO" | "NP" | "NR" | "NU" | "NZ" | "OM" | "PA" | "PE" | "PF" | "PG" | "PH" | "PK" | "PL" | "PN" | "PR" | "PS" | "PT" | "PW" | "PY" | "QA" | "RO" | "RS" | "RU" | "RW" | "SA" | "SB" | "SC" | "SE" | "SG" | "SI" | "SK" | "SL" | "SM" | "SN" | "SO" | "SR" | "SS" | "ST" | "SV" | "SX" | "SY" | "SZ" | "TC" | "TD" | "TG" | "TH" | "TJ" | "TK" | "TL" | "TM" | "TN" | "TO" | "TR" | "TT" | "TV" | "TW" | "TZ" | "UA" | "UG" | "US" | "UY" | "UZ" | "VC" | "VE" | "VG" | "VI" | "VN" | "VU" | "WS" | "YE" | "ZA" | "ZM" | "ZW";
33
+ export declare function getAssetIcon(str: OnRampAsset | string): "key" | "phone" | "farcaster" | "telegram" | "discord" | "x" | "search" | "para" | "walletConnect" | "wallet" | "close" | "copy" | "safe" | "cosmos" | "alertCircle" | "alertTriangle" | "alignVerticalCenter" | "angelListBrand" | "angelList" | "appleBrand" | "apple" | "arbitrumBrand" | "arrowCircleBrokenDownLeft" | "arrowCircleDownFilled" | "arrowNarrow" | "arrow" | "asterisk" | "backpack" | "backupKit" | "bank" | "baseBrand" | "brush" | "celoBrand" | "checkCircleFilled" | "checkCircle" | "checkSquare" | "check" | "chevronDown" | "chevronRight" | "chevronSelectorVertical" | "chevronUp" | "clock" | "clubhouseBrand" | "clubhouse" | "code" | "coinbase" | "copy07" | "cosmostation" | "creditCard02" | "creditCard" | "cube03" | "cubeOutline" | "cube" | "currencyDollar" | "decentBrand" | "decent" | "dell" | "discordBrand" | "dot" | "dots" | "downloadCloud" | "download" | "dribbbleBrand" | "dribbble" | "earth" | "edit02" | "emptyCircle" | "ethereum" | "eyeOff" | "eye" | "facebookBrand" | "facebook" | "farcasterBrand" | "figmaBrand" | "figma" | "file" | "folder" | "githubBrand" | "github" | "globe" | "glow" | "googleBrand" | "google" | "gridDots" | "haha" | "helpCircle" | "heroAlertCircle" | "heroCheckmarkCapsule" | "heroCheckmark" | "heroEmail" | "heroExternalConnection" | "heroLock" | "heroPasskey" | "heroPhone" | "heroPlusCircleCapsule" | "heroPlusCircle" | "heroWallet" | "home" | "hp" | "image" | "infoCircle" | "instagramBrand" | "instagram" | "keplr" | "laptop" | "leap" | "lenovo" | "lg" | "lightning01" | "lightning" | "linkExternal" | "linkedinBrand" | "linkedin" | "lockKeyholeCircle" | "logOut" | "mail" | "menu" | "metamask" | "monitor" | "moonpayBrand" | "moreLoginOptions" | "motorola" | "nobleBrand" | "okx" | "optimismBrand" | "paraBlackBg" | "paraBrand" | "paraIconBrand" | "paraIconQr" | "paraIcon" | "paraLogo" | "paraRingsDark" | "paraRings" | "passcode" | "phantom" | "pintrestBrand" | "pintrest" | "plusCircle" | "plus" | "polygonBrand" | "polygon" | "puzzlePiece" | "qrCode02" | "qrCode" | "rabby" | "rainbow" | "rampNetworkBrand" | "rampNetwork" | "redditBrand" | "reddit" | "refresh" | "samsung" | "send" | "settings" | "share" | "shield" | "signalBrand" | "signal" | "sliders" | "snapchatBrand" | "snapchat" | "solana" | "solflare" | "spacingHeight" | "star04Filled" | "star05" | "stars01Filled" | "stars02" | "stars" | "stopSquare" | "stripeBrand" | "telegramBrand" | "tetherBrand" | "tikTokBrand" | "tikTok" | "trash" | "tumblrBrand" | "tumblr" | "twitterBrand" | "twitter" | "usdcBrand" | "userCircle" | "userPlus" | "user" | "youtubeBrand" | "youtube" | "zerion" | "AD" | "AE" | "AF" | "AG" | "AI" | "AL" | "AM" | "AO" | "AR" | "AS" | "AT" | "AU" | "AW" | "AX" | "AZ" | "BA" | "BB" | "BD" | "BE" | "BF" | "BG" | "BH" | "BI" | "BJ" | "BL" | "BM" | "BN" | "BO" | "BQ" | "BQ2" | "BQ3" | "BR" | "BS" | "BT" | "BW" | "BY" | "BZ" | "CA" | "CC" | "CD" | "CD2" | "CF" | "CH" | "CK" | "CL" | "CM" | "CN" | "CO" | "CR" | "CU" | "CW" | "CX" | "CY" | "CZ" | "DE" | "DJ" | "DK" | "DM" | "DO" | "DS" | "DZ" | "EC" | "EE" | "EG" | "EH" | "ER" | "ES" | "ET" | "FI" | "FJ" | "FK" | "FM" | "FO" | "FR" | "GA" | "GB2" | "GB" | "GD" | "GE" | "GG" | "GH" | "GI" | "GL" | "GM" | "GN" | "GQ" | "GR" | "GT" | "GU" | "GW" | "GY" | "HK" | "HN" | "HR" | "HT" | "HU" | "ID" | "IE" | "IL" | "IM" | "IN" | "IO" | "IQ" | "IR" | "IS" | "IT" | "JE" | "JM" | "JO" | "JP" | "KE" | "KG" | "KH" | "KI" | "KM" | "KN" | "KP" | "KR" | "KW" | "KY" | "KZ" | "LA" | "LB" | "LC" | "LI" | "LK" | "LR" | "LS" | "LT" | "LU" | "LV" | "LY" | "MA" | "MC" | "MD" | "ME" | "MG" | "MH" | "MK" | "ML" | "MM" | "MN" | "MO" | "MP" | "MQ" | "MR" | "MS" | "MT" | "MU" | "MV" | "MW" | "MX" | "MY" | "MZ" | "NA" | "NE" | "NF" | "NG" | "NI" | "NL" | "NO" | "NP" | "NR" | "NU" | "NZ" | "OM" | "PA" | "PE" | "PF" | "PG" | "PH" | "PK" | "PL" | "PN" | "PR" | "PS" | "PT" | "PW" | "PY" | "QA" | "RO" | "RS" | "RU" | "RW" | "SA" | "SB" | "SC" | "SE" | "SG" | "SI" | "SK" | "SL" | "SM" | "SN" | "SO" | "SR" | "SS" | "ST" | "SV" | "SX" | "SY" | "SZ" | "TC" | "TD" | "TG" | "TH" | "TJ" | "TK" | "TL" | "TM" | "TN" | "TO" | "TR" | "TT" | "TV" | "TW" | "TZ" | "UA" | "UG" | "US" | "UY" | "UZ" | "VC" | "VE" | "VG" | "VI" | "VN" | "VU" | "WS" | "YE" | "ZA" | "ZM" | "ZW";
34
34
  export declare const MOBILE_SIZE = 480;
35
35
  export declare const NETWORK_NOT_SUPPORTED_ERROR = "network not supported";
36
36
  export declare const EMAIL_REGEX: RegExp;
@@ -119,7 +119,7 @@ const BODY_MOTION_VARIANTS = {
119
119
  const BODY_TRANSITION = {
120
120
  duration: 0.2
121
121
  };
122
- const SDK_VERSION = "2.0.0-alpha.20";
122
+ const SDK_VERSION = "2.0.0-alpha.21";
123
123
  export {
124
124
  BODY_MOTION_VARIANTS,
125
125
  BODY_TRANSITION,
@@ -1,8 +1,17 @@
1
+ import { TExternalWallet } from '@getpara/web-sdk';
1
2
  import { IconType } from '@getpara/react-components';
2
- import { TOAuthMethod } from '@getpara/web-sdk';
3
- export declare const brandedOAuthLogos: {
4
- [key in TOAuthMethod]: IconType;
5
- };
6
- export declare const oAuthLogos: {
7
- [key in TOAuthMethod]: IconType;
3
+ import { TLinkedAccountType } from '@getpara/web-sdk';
4
+ export declare const ACCOUNT_TYPES: {
5
+ [key in TLinkedAccountType | TExternalWallet]: {
6
+ logo: IconType;
7
+ logoBranded?: IconType;
8
+ name: string;
9
+ isDark?: boolean;
10
+ inline?: string;
11
+ isExternalWallet?: boolean;
12
+ };
8
13
  };
14
+ export declare function getAccountTypeName(type: TLinkedAccountType | TExternalWallet | undefined, { inline }?: {
15
+ inline?: boolean;
16
+ }): string | undefined;
17
+ export declare function getAccountTypeLogo(type: TLinkedAccountType | undefined): IconType | undefined;
@@ -1,24 +1,153 @@
1
1
  "use client";
2
2
  import "../../chunk-MMUBH76A.js";
3
- const brandedOAuthLogos = {
4
- GOOGLE: "googleBrand",
5
- TWITTER: "twitter",
6
- APPLE: "apple",
7
- DISCORD: "discordBrand",
8
- FACEBOOK: "facebookBrand",
9
- FARCASTER: "farcasterBrand",
10
- TELEGRAM: "telegramBrand"
11
- };
12
- const oAuthLogos = {
13
- GOOGLE: "google",
14
- TWITTER: "twitter",
15
- APPLE: "apple",
16
- DISCORD: "discord",
17
- FACEBOOK: "facebook",
18
- FARCASTER: "farcaster",
19
- TELEGRAM: "telegram"
3
+ const ACCOUNT_TYPES = {
4
+ EMAIL: {
5
+ logo: "mail",
6
+ name: "Email",
7
+ inline: "email address",
8
+ isDark: true
9
+ },
10
+ PHONE: {
11
+ logo: "phone",
12
+ name: "Phone",
13
+ inline: "phone number",
14
+ isDark: true
15
+ },
16
+ EXTERNAL_WALLET: {
17
+ logo: "wallet",
18
+ name: "External Wallet",
19
+ inline: "external wallet",
20
+ isDark: true
21
+ },
22
+ GOOGLE: {
23
+ logo: "google",
24
+ logoBranded: "googleBrand",
25
+ name: "Google"
26
+ },
27
+ TWITTER: {
28
+ logo: "twitter",
29
+ logoBranded: "twitterBrand",
30
+ name: "X / Twitter",
31
+ inline: "X account",
32
+ isDark: true
33
+ },
34
+ APPLE: {
35
+ logo: "apple",
36
+ logoBranded: "appleBrand",
37
+ name: "Apple",
38
+ isDark: true
39
+ },
40
+ DISCORD: {
41
+ logo: "discord",
42
+ logoBranded: "discordBrand",
43
+ name: "Discord"
44
+ },
45
+ FACEBOOK: {
46
+ logo: "facebook",
47
+ logoBranded: "facebookBrand",
48
+ name: "Facebook"
49
+ },
50
+ FARCASTER: {
51
+ logo: "farcaster",
52
+ logoBranded: "farcasterBrand",
53
+ name: "Farcaster"
54
+ },
55
+ TELEGRAM: {
56
+ logo: "telegram",
57
+ logoBranded: "telegramBrand",
58
+ name: "Telegram"
59
+ },
60
+ METAMASK: {
61
+ logo: "metamask",
62
+ name: "MetaMask",
63
+ isExternalWallet: true
64
+ },
65
+ RAINBOW: {
66
+ logo: "rainbow",
67
+ name: "Rainbow",
68
+ isExternalWallet: true
69
+ },
70
+ COINBASE: {
71
+ logo: "coinbase",
72
+ name: "Coinbase Wallet",
73
+ isExternalWallet: true
74
+ },
75
+ WALLETCONNECT: {
76
+ logo: "walletConnect",
77
+ name: "WalletConnect",
78
+ isExternalWallet: true
79
+ },
80
+ ZERION: {
81
+ logo: "zerion",
82
+ name: "Zerion",
83
+ isExternalWallet: true
84
+ },
85
+ SAFE: {
86
+ logo: "safe",
87
+ name: "Safe",
88
+ isExternalWallet: true
89
+ },
90
+ RABBY: {
91
+ logo: "rabby",
92
+ name: "Rabby",
93
+ isExternalWallet: true
94
+ },
95
+ OKX: {
96
+ logo: "okx",
97
+ name: "OKX",
98
+ isExternalWallet: true
99
+ },
100
+ PHANTOM: {
101
+ logo: "phantom",
102
+ name: "Phantom",
103
+ isExternalWallet: true
104
+ },
105
+ GLOW: {
106
+ logo: "glow",
107
+ name: "Glow",
108
+ isExternalWallet: true
109
+ },
110
+ BACKPACK: {
111
+ logo: "backpack",
112
+ name: "Backpack",
113
+ isExternalWallet: true
114
+ },
115
+ KEPLR: {
116
+ logo: "keplr",
117
+ name: "Keplr",
118
+ isExternalWallet: true
119
+ },
120
+ LEAP: {
121
+ logo: "leap",
122
+ name: "Leap",
123
+ isExternalWallet: true
124
+ },
125
+ HAHA: {
126
+ logo: "haha",
127
+ name: "HaHa",
128
+ isExternalWallet: true
129
+ },
130
+ COSMOSTATION: {
131
+ logo: "cosmostation",
132
+ name: "Cosmostation",
133
+ isExternalWallet: true
134
+ },
135
+ SOLFLARE: {
136
+ logo: "solflare",
137
+ name: "Solflare",
138
+ isExternalWallet: true
139
+ }
20
140
  };
141
+ function getAccountTypeName(type, { inline = false } = {}) {
142
+ var _a;
143
+ const data = type ? ACCOUNT_TYPES[type] : void 0;
144
+ return data ? inline ? (_a = data.inline) != null ? _a : `${data.name} ${data.isExternalWallet ? "wallet" : "account"}` : data.name : void 0;
145
+ }
146
+ function getAccountTypeLogo(type) {
147
+ return type ? ACCOUNT_TYPES[type].logoBranded || ACCOUNT_TYPES[type].logo : void 0;
148
+ }
21
149
  export {
22
- brandedOAuthLogos,
23
- oAuthLogos
150
+ ACCOUNT_TYPES,
151
+ getAccountTypeLogo,
152
+ getAccountTypeName
24
153
  };
@@ -0,0 +1,12 @@
1
+ import { TelegramAuthResponse } from '@getpara/user-management-client';
2
+ import { MutationStatus } from '@tanstack/react-query';
3
+ export declare const useTelegramLogin: ({ isActive, onSubmit, status: propsStatus, }?: {
4
+ isActive?: boolean;
5
+ onSubmit?: (_: TelegramAuthResponse) => void;
6
+ status?: MutationStatus;
7
+ }) => {
8
+ url: string | undefined;
9
+ isLoaded: boolean;
10
+ setIsLoaded: import("react").Dispatch<import("react").SetStateAction<boolean>>;
11
+ status: MutationStatus | undefined;
12
+ };
@@ -0,0 +1,65 @@
1
+ "use client";
2
+ import {
3
+ __async
4
+ } from "../../chunk-MMUBH76A.js";
5
+ import { useEffect, useState } from "react";
6
+ import { useInternalClient } from "../../provider/hooks/utils/useInternalClient.js";
7
+ import { useModalStore } from "../stores/index.js";
8
+ const useTelegramLogin = ({
9
+ isActive = false,
10
+ onSubmit,
11
+ status: propsStatus
12
+ } = {}) => {
13
+ const para = useInternalClient();
14
+ const refs = useModalStore((state) => state.refs);
15
+ const [url, setUrl] = useState();
16
+ const [isLoaded, setIsLoaded] = useState(false);
17
+ const [msgStatus, setMsgStatus] = useState("idle");
18
+ const status = msgStatus === "success" ? propsStatus : msgStatus;
19
+ useEffect(() => {
20
+ if (isActive) {
21
+ if (!url) {
22
+ para.constructPortalUrl("telegramLogin").then(setUrl);
23
+ }
24
+ }
25
+ }, [isActive, url]);
26
+ useEffect(() => {
27
+ const updateState = (event) => __async(void 0, null, function* () {
28
+ var _a, _b;
29
+ switch (event.data.type) {
30
+ case "TELEGRAM_LOGIN":
31
+ setMsgStatus("pending");
32
+ break;
33
+ case "TELEGRAM_FAILED":
34
+ setMsgStatus("error");
35
+ break;
36
+ case "TELEGRAM_SUCCESS":
37
+ setMsgStatus("success");
38
+ if (!!event.data.payload) {
39
+ const authObject = event.data.payload;
40
+ try {
41
+ yield onSubmit == null ? void 0 : onSubmit(authObject);
42
+ } catch (e) {
43
+ (_b = (_a = refs.telegramIFrame.current) == null ? void 0 : _a.contentWindow) == null ? void 0 : _b.postMessage({ type: "TELEGRAM_RETRY" }, "*");
44
+ }
45
+ }
46
+ break;
47
+ }
48
+ });
49
+ if (isActive) {
50
+ window == null ? void 0 : window.addEventListener("message", updateState, false);
51
+ }
52
+ return () => {
53
+ window == null ? void 0 : window.removeEventListener("message", updateState, false);
54
+ };
55
+ }, [isActive, onSubmit]);
56
+ return {
57
+ url,
58
+ isLoaded,
59
+ setIsLoaded,
60
+ status
61
+ };
62
+ };
63
+ export {
64
+ useTelegramLogin
65
+ };
@@ -33,10 +33,14 @@ const getActions = (set, get) => ({
33
33
  return;
34
34
  }
35
35
  const onModalStepChange = get().onModalStepChange;
36
+ const accountLinkOptions = get().accountLinkOptions || [];
36
37
  const signupState = get().getSignupState();
37
38
  const iFrameUrl = get().iFrameUrl;
38
39
  const refs = get().refs;
39
40
  let prevStep = getPreviousStep(flow, currentStep);
41
+ if (currentStep === ModalStep.ACCOUNT_PROFILE_ADD && accountLinkOptions.length < 2) {
42
+ prevStep = ModalStep.ACCOUNT_PROFILE;
43
+ }
40
44
  if (currentStep === ModalStep.PASSWORD_CREATION && iFrameUrl && !(signupState == null ? void 0 : signupState.passkeyUrl)) {
41
45
  prevStep = ModalStep.AUTH_MAIN;
42
46
  }
@@ -123,7 +127,8 @@ const getActions = (set, get) => ({
123
127
  set({ authLayout: uniqueLayouts });
124
128
  },
125
129
  setAuthStepRoute: (authStepRoute) => set({ authStepRoute }),
126
- setIsPasskeySupported: (isPasskeySupported) => set({ isPasskeySupported })
130
+ setIsPasskeySupported: (isPasskeySupported) => set({ isPasskeySupported }),
131
+ setAccountLinkOptions: (accountLinkOptions) => set({ accountLinkOptions })
127
132
  });
128
133
  export {
129
134
  getActions
@@ -1,10 +1,8 @@
1
1
  import { ModalStep } from '../../utils/steps.js';
2
- import { OnRampConfig as OnRampConfigBase, OnRampPurchase, TWalletType } from '@getpara/web-sdk';
2
+ import { AuthStateLogin, AuthStateSignup, AuthState, AuthStateVerify, OnRampConfig as OnRampConfigBase, OnRampPurchase, TWalletType, Setup2faResponse, SupportedAccountLinks } from '@getpara/web-sdk';
3
3
  import { Tab as AddFundsTabType } from '../../components/AddFunds/AddFundsContext.js';
4
- import { AuthStateLogin, AuthStateSignup, AuthState, AuthStateVerify } from '@getpara/core-sdk';
5
4
  import { TAuthLayout } from '../../types/modalProps.js';
6
5
  import { MutableRefObject } from 'react';
7
- import { Setup2faResponse } from '@getpara/user-management-client';
8
6
  export type Flow = AuthStateSignup['stage'] | AuthStateLogin['stage'] | 'account' | 'guest';
9
7
  type ActiveWallet = [string | undefined, TWalletType | undefined];
10
8
  export declare enum OnRampStep {
@@ -50,8 +48,10 @@ interface ModalState {
50
48
  timeout: number;
51
49
  } | null>;
52
50
  currentStep: MutableRefObject<ModalStep | null>;
51
+ telegramIFrame: MutableRefObject<HTMLIFrameElement | null>;
53
52
  };
54
53
  isPasskeySupported: boolean;
54
+ accountLinkOptions: SupportedAccountLinks;
55
55
  }
56
56
  export interface ModalActions {
57
57
  resetState: () => void;
@@ -85,6 +85,7 @@ export interface ModalActions {
85
85
  setAuthLayout: (authLayout: TAuthLayout[]) => void;
86
86
  setAuthStepRoute: (_?: ModalStep) => void;
87
87
  setIsPasskeySupported: (_: boolean) => void;
88
+ setAccountLinkOptions: (_: SupportedAccountLinks) => void;
88
89
  }
89
90
  export type ModalStore = ModalState & ModalActions;
90
91
  export declare const DEFAULT_MODAL_STATE: Omit<ModalState, 'step' | 'onRampConfig'>;
@@ -6,6 +6,9 @@ import { create } from "zustand";
6
6
  import { persist, createJSONStorage } from "zustand/middleware";
7
7
  import { ModalStep } from "../../utils/steps.js";
8
8
  import { getActions } from "./actions.js";
9
+ import {
10
+ LINKED_ACCOUNT_TYPES
11
+ } from "@getpara/web-sdk";
9
12
  import { AuthLayout } from "../../types/modalProps.js";
10
13
  import { createRef } from "react";
11
14
  var OnRampStep = /* @__PURE__ */ ((OnRampStep2) => {
@@ -36,9 +39,11 @@ const DEFAULT_MODAL_STATE = {
36
39
  refs: {
37
40
  popupWindow: createRef(),
38
41
  poll: createRef(),
39
- currentStep: createRef()
42
+ currentStep: createRef(),
43
+ telegramIFrame: createRef()
40
44
  },
41
- isPasskeySupported: true
45
+ isPasskeySupported: true,
46
+ accountLinkOptions: [...LINKED_ACCOUNT_TYPES]
42
47
  };
43
48
  const useModalStore = create()(
44
49
  persist(
@@ -1,4 +1,4 @@
1
- import ParaWeb, { CurrentWalletIds, TOAuthMethod } from '@getpara/web-sdk';
1
+ import ParaWeb, { CurrentWalletIds, SupportedAccountLinks, TOAuthMethod } from '@getpara/web-sdk';
2
2
  import { Theme } from '@getpara/react-components';
3
3
  import { OnModalStepChangeValue } from '../stores/index.js';
4
4
  import { ModalStep, ModalStepProp } from '../utils/steps.js';
@@ -121,4 +121,9 @@ export interface ParaModalProps {
121
121
  recoverySecret?: string;
122
122
  walletIds: CurrentWalletIds;
123
123
  }>;
124
+ /**
125
+ * Which external accounts or wallets to allow your users to link to their accounts. The accounts will be displayed in this order in the modal account screen.
126
+ * If not provided, will default to your Developer Portal configuration or to all available account types.
127
+ */
128
+ supportedAccountLinks?: SupportedAccountLinks;
124
129
  }
@@ -1,7 +1,5 @@
1
+ import { Auth } from '@getpara/user-management-client';
1
2
  import countryCodes from './countryCodes.js';
2
3
  export declare function isCcMatch(countryCode: string, option: (typeof countryCodes)[number]): boolean;
3
- export declare function validateAuth(identifier: string, countryCode?: string, type?: 'email' | 'phone'): {
4
- email: string;
5
- } | {
6
- phone: import("@getpara/user-management-client").AuthIdentifier<"phone">;
7
- };
4
+ export declare function validateAuth(auth: Auth<'email' | 'phone'>): Auth<'email' | 'phone'>;
5
+ export declare function validateInput(identifier: string, countryCode?: string, type?: 'email' | 'phone'): Auth<"email" | "phone">;
@@ -5,34 +5,37 @@ import { formatPhoneNumber } from "@getpara/web-sdk";
5
5
  function isCcMatch(countryCode, option) {
6
6
  return countryCode === "+1" ? option.selectedLabel === "US" : option.value === countryCode;
7
7
  }
8
- function validateAuth(identifier, countryCode, type) {
9
- const isEmail = type === "email";
10
- const isPhone = type === "phone";
11
- let auth;
8
+ function validateAuth(auth) {
12
9
  switch (true) {
13
- case isEmail:
14
- if (!EMAIL_REGEX.test(identifier)) {
15
- throw new Error("Please enter a valid email!");
10
+ case "email" in auth:
11
+ if (!EMAIL_REGEX.test(auth.email)) {
12
+ throw new Error("Please enter a valid email address!");
16
13
  }
17
- auth = { email: identifier };
18
14
  break;
19
- case isPhone:
20
- if (countryCode === "+1" && identifier.slice(3, 6) === "555") {
21
- auth = { phone: `${countryCode}${identifier}` };
22
- break;
15
+ case "phone" in auth:
16
+ {
17
+ if (!/^\+1\d{3}555\d{4}$/.test(auth.phone)) {
18
+ const formatted = formatPhoneNumber(auth.phone);
19
+ if (!formatted) {
20
+ throw new Error("Please enter a valid phone number!");
21
+ }
22
+ }
23
23
  }
24
- const validatedPhone = formatPhoneNumber(identifier, countryCode);
25
- if (!validatedPhone) {
26
- throw new Error("Please enter a valid phone number!");
27
- }
28
- auth = { phone: validatedPhone };
29
24
  break;
30
- default:
31
- throw new Error("Please enter a valid email or phone number!");
32
25
  }
33
26
  return auth;
34
27
  }
28
+ function validateInput(identifier, countryCode, type) {
29
+ const isEmail = type === "email";
30
+ const isPhone = type === "phone";
31
+ const auth = isEmail ? { email: identifier } : isPhone ? { phone: `${countryCode}${identifier}` } : void 0;
32
+ if (!auth) {
33
+ throw new Error("Please enter a valid email or phone number!");
34
+ }
35
+ return validateAuth(auth);
36
+ }
35
37
  export {
36
38
  isCcMatch,
37
- validateAuth
39
+ validateAuth,
40
+ validateInput
38
41
  };
@@ -0,0 +1,5 @@
1
+ import ParaWeb from '@getpara/web-sdk';
2
+ export declare function getWalletDisplayName(para: ParaWeb, { type, isExternal, name, isMenu, hideWallets, }: Partial<Pick<(typeof para.availableWallets)[0], 'type' | 'isExternal' | 'name'> & {
3
+ isMenu?: boolean;
4
+ hideWallets?: boolean;
5
+ }>): string;
@@ -0,0 +1,22 @@
1
+ "use client";
2
+ import "../../chunk-MMUBH76A.js";
3
+ const WALLET_TYPES = {
4
+ EVM: "EVM",
5
+ SOLANA: "Solana",
6
+ COSMOS: "Cosmos"
7
+ };
8
+ function getWalletDisplayName(para, {
9
+ type,
10
+ isExternal,
11
+ name,
12
+ isMenu = false,
13
+ hideWallets = false
14
+ }) {
15
+ if (para.isMultiWallet) {
16
+ return name != null ? name : `${isExternal ? "External " : ""}${type ? WALLET_TYPES[type] : ""}${!hideWallets && (isMenu || isExternal) ? " Wallet" : ""}`;
17
+ }
18
+ return hideWallets ? "My Account" : name || "My Wallet";
19
+ }
20
+ export {
21
+ getWalletDisplayName
22
+ };
@@ -33,7 +33,11 @@ export declare enum ModalStep {
33
33
  ADD_FUNDS_SUCCESS = "ADD_FUNDS_SUCCESS",
34
34
  ADD_FUNDS_FAILURE = "ADD_FUNDS_FAILURE",
35
35
  ACCOUNT_MAIN = "ACCOUNT_MAIN",
36
- CHAIN_SWITCH = "CHAIN_SWITCH"
36
+ CHAIN_SWITCH = "CHAIN_SWITCH",
37
+ ACCOUNT_PROFILE = "ACCOUNT_PROFILE",
38
+ ACCOUNT_PROFILE_ADD = "ACCOUNT_PROFILE_ADD",
39
+ ACCOUNT_PROFILE_LIST = "ACCOUNT_PROFILE_LIST",
40
+ ACCOUNT_PROFILE_REMOVE = "ACCOUNT_PROFILE_REMOVE"
37
41
  }
38
42
  export type ModalStepPropU = keyof typeof ModalStep | ModalStep;
39
43
  export type ModalStepPropL = Lowercase<ModalStepPropU>;
@@ -47,7 +51,11 @@ declare enum AccountStep {
47
51
  ADD_FUNDS_AWAITING = "ADD_FUNDS_AWAITING",
48
52
  ADD_FUNDS_SUCCESS = "ADD_FUNDS_SUCCESS",
49
53
  ADD_FUNDS_FAILURE = "ADD_FUNDS_FAILURE",
50
- CHAIN_SWITCH = "CHAIN_SWITCH"
54
+ CHAIN_SWITCH = "CHAIN_SWITCH",
55
+ ACCOUNT_PROFILE = "ACCOUNT_PROFILE",
56
+ ACCOUNT_PROFILE_ADD = "ACCOUNT_PROFILE_ADD",
57
+ ACCOUNT_PROFILE_LIST = "ACCOUNT_PROFILE_LIST",
58
+ ACCOUNT_PROFILE_REMOVE = "ACCOUNT_PROFILE_REMOVE"
51
59
  }
52
60
  export declare const RESET_TO_AUTH_STEPS: ModalStep[];
53
61
  export declare const RESET_TO_ACCOUNT_STEPS: ModalStep[];
@@ -35,6 +35,10 @@ var ModalStep = /* @__PURE__ */ ((ModalStep2) => {
35
35
  ModalStep2["ADD_FUNDS_FAILURE"] = "ADD_FUNDS_FAILURE";
36
36
  ModalStep2["ACCOUNT_MAIN"] = "ACCOUNT_MAIN";
37
37
  ModalStep2["CHAIN_SWITCH"] = "CHAIN_SWITCH";
38
+ ModalStep2["ACCOUNT_PROFILE"] = "ACCOUNT_PROFILE";
39
+ ModalStep2["ACCOUNT_PROFILE_ADD"] = "ACCOUNT_PROFILE_ADD";
40
+ ModalStep2["ACCOUNT_PROFILE_LIST"] = "ACCOUNT_PROFILE_LIST";
41
+ ModalStep2["ACCOUNT_PROFILE_REMOVE"] = "ACCOUNT_PROFILE_REMOVE";
38
42
  return ModalStep2;
39
43
  })(ModalStep || {});
40
44
  var AccountStep = /* @__PURE__ */ ((AccountStep2) => {
@@ -47,6 +51,10 @@ var AccountStep = /* @__PURE__ */ ((AccountStep2) => {
47
51
  AccountStep2["ADD_FUNDS_SUCCESS"] = "ADD_FUNDS_SUCCESS";
48
52
  AccountStep2["ADD_FUNDS_FAILURE"] = "ADD_FUNDS_FAILURE";
49
53
  AccountStep2["CHAIN_SWITCH"] = "CHAIN_SWITCH";
54
+ AccountStep2["ACCOUNT_PROFILE"] = "ACCOUNT_PROFILE";
55
+ AccountStep2["ACCOUNT_PROFILE_ADD"] = "ACCOUNT_PROFILE_ADD";
56
+ AccountStep2["ACCOUNT_PROFILE_LIST"] = "ACCOUNT_PROFILE_LIST";
57
+ AccountStep2["ACCOUNT_PROFILE_REMOVE"] = "ACCOUNT_PROFILE_REMOVE";
50
58
  return AccountStep2;
51
59
  })(AccountStep || {});
52
60
  const RESET_TO_AUTH_STEPS = [
@@ -81,7 +89,11 @@ const RESET_TO_ACCOUNT_STEPS = [
81
89
  "ADD_FUNDS_AWAITING" /* ADD_FUNDS_AWAITING */,
82
90
  "ADD_FUNDS_SUCCESS" /* ADD_FUNDS_SUCCESS */,
83
91
  "ADD_FUNDS_FAILURE" /* ADD_FUNDS_FAILURE */,
84
- "CHAIN_SWITCH" /* CHAIN_SWITCH */
92
+ "CHAIN_SWITCH" /* CHAIN_SWITCH */,
93
+ "ACCOUNT_PROFILE" /* ACCOUNT_PROFILE */,
94
+ "ACCOUNT_PROFILE_ADD" /* ACCOUNT_PROFILE_ADD */,
95
+ "ACCOUNT_PROFILE_LIST" /* ACCOUNT_PROFILE_LIST */,
96
+ "ACCOUNT_PROFILE_REMOVE" /* ACCOUNT_PROFILE_REMOVE */
85
97
  ];
86
98
  const AccountPreviousStep = {
87
99
  ["ACCOUNT_MAIN" /* ACCOUNT_MAIN */]: void 0,
@@ -92,7 +104,11 @@ const AccountPreviousStep = {
92
104
  ["ADD_FUNDS_AWAITING" /* ADD_FUNDS_AWAITING */]: "ADD_FUNDS_BUY" /* ADD_FUNDS_BUY */,
93
105
  ["ADD_FUNDS_SUCCESS" /* ADD_FUNDS_SUCCESS */]: "ACCOUNT_MAIN" /* ACCOUNT_MAIN */,
94
106
  ["ADD_FUNDS_FAILURE" /* ADD_FUNDS_FAILURE */]: "ACCOUNT_MAIN" /* ACCOUNT_MAIN */,
95
- ["CHAIN_SWITCH" /* CHAIN_SWITCH */]: "ACCOUNT_MAIN" /* ACCOUNT_MAIN */
107
+ ["CHAIN_SWITCH" /* CHAIN_SWITCH */]: "ACCOUNT_MAIN" /* ACCOUNT_MAIN */,
108
+ ["ACCOUNT_PROFILE" /* ACCOUNT_PROFILE */]: "ACCOUNT_MAIN" /* ACCOUNT_MAIN */,
109
+ ["ACCOUNT_PROFILE_LIST" /* ACCOUNT_PROFILE_LIST */]: "ACCOUNT_PROFILE" /* ACCOUNT_PROFILE */,
110
+ ["ACCOUNT_PROFILE_ADD" /* ACCOUNT_PROFILE_ADD */]: "ACCOUNT_PROFILE_LIST" /* ACCOUNT_PROFILE_LIST */,
111
+ ["ACCOUNT_PROFILE_REMOVE" /* ACCOUNT_PROFILE_REMOVE */]: "ACCOUNT_PROFILE" /* ACCOUNT_PROFILE */
96
112
  };
97
113
  var SignUpModalStep = /* @__PURE__ */ ((SignUpModalStep2) => {
98
114
  SignUpModalStep2["AUTH_MAIN"] = "AUTH_MAIN";
@@ -12,8 +12,9 @@ import { ExternalWalletWrapper } from "./components/ExternalWalletWrapper.js";
12
12
  import { ParaModal } from "../modal/ParaModal.js";
13
13
  import { isConfigType, isParaWeb } from "./utils/paraConfigTypeGuards.js";
14
14
  import ParaWeb from "@getpara/web-sdk";
15
- import { ExternalWallet } from "@getpara/react-common";
15
+ import { EXTERNAL_WALLET_TYPES } from "@getpara/web-sdk";
16
16
  import { AuthProvider } from "./providers/AuthProvider.js";
17
+ import { AccountLinkProvider } from "./providers/AccountLinkProvider.js";
17
18
  const ParaProvider = forwardRef(({ children, paraClientConfig, callbacks, config, externalWalletConfig, paraModalConfig }, ref) => {
18
19
  useEventListeners(callbacks);
19
20
  useAutoSessionKeepAlive({ disabled: config.disableAutoSessionKeepAlive });
@@ -69,7 +70,7 @@ const ParaProvider = forwardRef(({ children, paraClientConfig, callbacks, config
69
70
  useEffect(() => {
70
71
  var _a;
71
72
  if (externalWallets !== (externalWalletConfig == null ? void 0 : externalWalletConfig.wallets)) {
72
- setExternalWallets((_a = externalWalletConfig == null ? void 0 : externalWalletConfig.wallets) != null ? _a : Object.values(ExternalWallet));
73
+ setExternalWallets((_a = externalWalletConfig == null ? void 0 : externalWalletConfig.wallets) != null ? _a : [...EXTERNAL_WALLET_TYPES]);
73
74
  }
74
75
  }, [externalWalletConfig == null ? void 0 : externalWalletConfig.wallets]);
75
76
  useEffect(() => {
@@ -80,7 +81,7 @@ const ParaProvider = forwardRef(({ children, paraClientConfig, callbacks, config
80
81
  setExternalWalletsWithFullAuth([]);
81
82
  } else {
82
83
  setExternalWalletsWithFullAuth(
83
- (externalWalletConfig == null ? void 0 : externalWalletConfig.createLinkedEmbeddedForExternalWallets) === "ALL" ? Object.values(ExternalWallet) : (_b = externalWalletConfig == null ? void 0 : externalWalletConfig.createLinkedEmbeddedForExternalWallets) != null ? _b : []
84
+ (externalWalletConfig == null ? void 0 : externalWalletConfig.createLinkedEmbeddedForExternalWallets) === "ALL" ? [...EXTERNAL_WALLET_TYPES] : (_b = externalWalletConfig == null ? void 0 : externalWalletConfig.createLinkedEmbeddedForExternalWallets) != null ? _b : []
84
85
  );
85
86
  }
86
87
  }
@@ -104,10 +105,10 @@ const ParaProvider = forwardRef(({ children, paraClientConfig, callbacks, config
104
105
  login: paraModalConfig == null ? void 0 : paraModalConfig.loginTransitionOverride,
105
106
  createWallets: paraModalConfig == null ? void 0 : paraModalConfig.createWalletOverride
106
107
  },
107
- children: /* @__PURE__ */ jsxs(ExternalWalletWrapper, { config: externalWalletConfig, children: [
108
+ children: /* @__PURE__ */ jsx(ExternalWalletWrapper, { config: externalWalletConfig, children: /* @__PURE__ */ jsxs(AccountLinkProvider, { children: [
108
109
  children,
109
110
  !config.disableEmbeddedModal && /* @__PURE__ */ jsx(ParaModal, { ref })
110
- ] })
111
+ ] }) })
111
112
  }
112
113
  );
113
114
  });