@dynamic-labs/sdk-react-core 3.4.5 → 3.5.0

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 (23) hide show
  1. package/CHANGELOG.md +26 -0
  2. package/package.cjs +1 -1
  3. package/package.js +1 -1
  4. package/package.json +11 -11
  5. package/src/lib/components/AuthProviderIcon/AuthProviderIcon.cjs +5 -2
  6. package/src/lib/components/AuthProviderIcon/AuthProviderIcon.js +6 -3
  7. package/src/lib/context/DynamicContext/DynamicContext.cjs +3 -2
  8. package/src/lib/context/DynamicContext/DynamicContext.js +3 -2
  9. package/src/lib/shared/assets/index.d.ts +1 -0
  10. package/src/lib/shared/assets/smart-wallet.cjs +59 -0
  11. package/src/lib/shared/assets/smart-wallet.js +35 -0
  12. package/src/lib/utils/hooks/useNetworkConfigurationsFromProjectSettings/useNetworkConfigurationsFromProjectSettings.cjs +1 -0
  13. package/src/lib/utils/hooks/useNetworkConfigurationsFromProjectSettings/useNetworkConfigurationsFromProjectSettings.js +1 -0
  14. package/src/lib/utils/hooks/useSocialAuth/useSocialAuth.cjs +1 -0
  15. package/src/lib/utils/hooks/useSocialAuth/useSocialAuth.js +1 -0
  16. package/src/lib/utils/hooks/useWalletConnectors/useWalletConnectors.cjs +8 -2
  17. package/src/lib/utils/hooks/useWalletConnectors/useWalletConnectors.d.ts +2 -1
  18. package/src/lib/utils/hooks/useWalletConnectors/useWalletConnectors.js +8 -2
  19. package/src/lib/utils/hooks/useWalletConnectors/utils/createLinkedWalletsFromWalletOptions/createLinkedWalletsFromWalletOptions.cjs +3 -2
  20. package/src/lib/utils/hooks/useWalletConnectors/utils/createLinkedWalletsFromWalletOptions/createLinkedWalletsFromWalletOptions.d.ts +2 -1
  21. package/src/lib/utils/hooks/useWalletConnectors/utils/createLinkedWalletsFromWalletOptions/createLinkedWalletsFromWalletOptions.js +3 -2
  22. package/src/lib/utils/hooks/useWalletOptions/useWalletOptions.cjs +1 -1
  23. package/src/lib/utils/hooks/useWalletOptions/useWalletOptions.js +1 -1
package/CHANGELOG.md CHANGED
@@ -1,4 +1,30 @@
1
1
 
2
+ ## [3.5.0](https://github.com/dynamic-labs/DynamicAuth/compare/v3.4.6...v3.5.0) (2024-11-05)
3
+
4
+
5
+ ### Features
6
+
7
+ * add support for line social ([61b23fd](https://github.com/dynamic-labs/dynamic-auth/commit/61b23fde9f4b0bc56c1cdc2f7456784931bdb878))
8
+
9
+
10
+ ### Bug Fixes
11
+
12
+ * global connectivity transaction failures and confirmation modal ([#7355](https://github.com/dynamic-labs/DynamicAuth/issues/7355)) ([eb1c5d7](https://github.com/dynamic-labs/DynamicAuth/commit/eb1c5d794df972dfb2f84fdcaa6c581ba68285c0)), closes [#7347](https://github.com/dynamic-labs/DynamicAuth/issues/7347)
13
+
14
+ ### [3.4.6](https://github.com/dynamic-labs/DynamicAuth/compare/v3.4.5...v3.4.6) (2024-10-31)
15
+
16
+
17
+ ### Features
18
+
19
+ * add support for compass and leap wallets ([ab170c9](https://github.com/dynamic-labs/DynamicAuth/commit/ab170c962099ed6356d2f31c947b122f1aa7ec73))
20
+
21
+
22
+ ### Bug Fixes
23
+
24
+ * prevent use-wallet-options from reading empty wallet-book ([#7320](https://github.com/dynamic-labs/DynamicAuth/issues/7320)) ([24c6cb1](https://github.com/dynamic-labs/DynamicAuth/commit/24c6cb14ce324925b120d363e029e29b72560895))
25
+ * sats-connect wallets not prompting correctly to sync account when making a transaction ([#7311](https://github.com/dynamic-labs/DynamicAuth/issues/7311)) ([#7312](https://github.com/dynamic-labs/DynamicAuth/issues/7312)) ([2026be4](https://github.com/dynamic-labs/DynamicAuth/commit/2026be412edcbb7e98341a5a5b2a3bd75ffdb83f))
26
+ * update check for wallet provider event listeners support ([#7303](https://github.com/dynamic-labs/DynamicAuth/issues/7303)) ([#7304](https://github.com/dynamic-labs/DynamicAuth/issues/7304)) ([1e91c76](https://github.com/dynamic-labs/DynamicAuth/commit/1e91c767ebe078f63c27884e4a8e7729d49b2114))
27
+
2
28
  ### [3.4.5](https://github.com/dynamic-labs/DynamicAuth/compare/v3.4.4...v3.4.5) (2024-10-30)
3
29
 
4
30
 
package/package.cjs CHANGED
@@ -3,7 +3,7 @@
3
3
 
4
4
  Object.defineProperty(exports, '__esModule', { value: true });
5
5
 
6
- var version = "3.4.5";
6
+ var version = "3.5.0";
7
7
  var dependencies = {
8
8
  "@dynamic-labs/sdk-api-core": "0.0.559",
9
9
  "@hcaptcha/react-hcaptcha": "1.4.4",
package/package.js CHANGED
@@ -1,5 +1,5 @@
1
1
  'use client'
2
- var version = "3.4.5";
2
+ var version = "3.5.0";
3
3
  var dependencies = {
4
4
  "@dynamic-labs/sdk-api-core": "0.0.559",
5
5
  "@hcaptcha/react-hcaptcha": "1.4.4",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamic-labs/sdk-react-core",
3
- "version": "3.4.5",
3
+ "version": "3.5.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/dynamic-labs/dynamic-auth.git",
@@ -17,16 +17,16 @@
17
17
  "react-i18next": "13.5.0",
18
18
  "yup": "0.32.11",
19
19
  "react-international-phone": "4.2.5",
20
- "@dynamic-labs/assert-package-version": "3.4.5",
21
- "@dynamic-labs/iconic": "3.4.5",
22
- "@dynamic-labs/logger": "3.4.5",
23
- "@dynamic-labs/multi-wallet": "3.4.5",
24
- "@dynamic-labs/rpc-providers": "3.4.5",
25
- "@dynamic-labs/store": "3.4.5",
26
- "@dynamic-labs/types": "3.4.5",
27
- "@dynamic-labs/utils": "3.4.5",
28
- "@dynamic-labs/wallet-book": "3.4.5",
29
- "@dynamic-labs/wallet-connector-core": "3.4.5",
20
+ "@dynamic-labs/assert-package-version": "3.5.0",
21
+ "@dynamic-labs/iconic": "3.5.0",
22
+ "@dynamic-labs/logger": "3.5.0",
23
+ "@dynamic-labs/multi-wallet": "3.5.0",
24
+ "@dynamic-labs/rpc-providers": "3.5.0",
25
+ "@dynamic-labs/store": "3.5.0",
26
+ "@dynamic-labs/types": "3.5.0",
27
+ "@dynamic-labs/utils": "3.5.0",
28
+ "@dynamic-labs/wallet-book": "3.5.0",
29
+ "@dynamic-labs/wallet-connector-core": "3.5.0",
30
30
  "eventemitter3": "5.0.1"
31
31
  },
32
32
  "devDependencies": {
@@ -14,6 +14,7 @@ require('@dynamic-labs/sdk-api-core');
14
14
  var logger = require('../../shared/logger.cjs');
15
15
  require('../../context/ViewContext/ViewContext.cjs');
16
16
  var embeddedWalletIcon = require('../../shared/assets/embedded-wallet-icon.cjs');
17
+ var smartWallet = require('../../shared/assets/smart-wallet.cjs');
17
18
  require('@dynamic-labs/utils');
18
19
  require('../../utils/constants/colors.cjs');
19
20
  require('../../utils/constants/values.cjs');
@@ -105,8 +106,10 @@ const getWalletIcon = ({ findSocialIcon, wallet, user, }) => {
105
106
  logger.logger.error(err);
106
107
  }
107
108
  }
108
- if (walletConnectorCore.isEmbeddedConnector(wallet.connector) ||
109
- walletConnectorCore.isAccountAbstractionConnector(wallet.connector)) {
109
+ if (walletConnectorCore.isAccountAbstractionConnector(wallet.connector)) {
110
+ return smartWallet.ReactComponent;
111
+ }
112
+ if (walletConnectorCore.isEmbeddedConnector(wallet.connector)) {
110
113
  return embeddedWalletIcon.ReactComponent;
111
114
  }
112
115
  return null;
@@ -2,7 +2,7 @@
2
2
  import { jsx } from 'react/jsx-runtime';
3
3
  import { SignInWithEmailIcon } from '@dynamic-labs/iconic';
4
4
  import { WalletIcon } from '@dynamic-labs/wallet-book';
5
- import { isEmailOTPWalletConnector, isSocialWalletConnector, isEmbeddedConnector, isAccountAbstractionConnector } from '@dynamic-labs/wallet-connector-core';
5
+ import { isEmailOTPWalletConnector, isSocialWalletConnector, isAccountAbstractionConnector, isEmbeddedConnector } from '@dynamic-labs/wallet-connector-core';
6
6
  import { useAccessDeniedContext } from '../../context/AccessDeniedContext/AccessDeniedContext.js';
7
7
  import 'react';
8
8
  import '../../context/DynamicContext/DynamicContext.js';
@@ -10,6 +10,7 @@ import '@dynamic-labs/sdk-api-core';
10
10
  import { logger } from '../../shared/logger.js';
11
11
  import '../../context/ViewContext/ViewContext.js';
12
12
  import { ReactComponent as SvgEmbeddedWalletIcon } from '../../shared/assets/embedded-wallet-icon.js';
13
+ import { ReactComponent as SvgSmartWallet } from '../../shared/assets/smart-wallet.js';
13
14
  import '@dynamic-labs/utils';
14
15
  import '../../utils/constants/colors.js';
15
16
  import '../../utils/constants/values.js';
@@ -101,8 +102,10 @@ const getWalletIcon = ({ findSocialIcon, wallet, user, }) => {
101
102
  logger.error(err);
102
103
  }
103
104
  }
104
- if (isEmbeddedConnector(wallet.connector) ||
105
- isAccountAbstractionConnector(wallet.connector)) {
105
+ if (isAccountAbstractionConnector(wallet.connector)) {
106
+ return SvgSmartWallet;
107
+ }
108
+ if (isEmbeddedConnector(wallet.connector)) {
106
109
  return SvgEmbeddedWalletIcon;
107
110
  }
108
111
  return null;
@@ -146,7 +146,7 @@ const PUBLIC_PROJECT_LIVE_ENVIRONMENT_ID = '2762a57b-faa4-41ce-9f16-abff9300e2c9
146
146
  const DynamicContext = React.createContext(undefined);
147
147
  /** The context provider itself we only use internally */
148
148
  const InnerDynamicContextProvider = ({ children, theme, settings: settings$1, locale: locale$1, enableInstrumentation = false, }) => {
149
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
149
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
150
150
  const { accessDeniedMessagePrimary, accessDeniedMessageSecondary, accessDeniedButton, defaultPhoneInputIso2, apiBaseUrl, coinbaseWalletPreference, detectNewWalletsForLinking = false, enableConnectOnlyFallback = false, deepLinkPreference: deepLinkPreferenceProp = 'native', bridgeChains, cssOverrides, defaultNumberOfWalletsToShow = values.DEFAULT_NUMBER_OF_WALLETS_TO_SHOW, flowNetwork, initialAuthenticationMode = 'connect-and-sign', debugError = false, displaySiweStatement = true, newToWeb3WalletChainMap, enableVisitTrackingOnConnectOnly = true, environmentId, walletsFilter, logLevel = 'WARN', mobileExperience, notInTheListImageUrl, onboardingImageUrl, policiesConsentInnerComponent, customPrivacyPolicy, privacyPolicyUrl, socialMediaLinkText, socialMediaIconUrl, socialMediaUrl, customTermsOfServices, termsOfServiceUrl, toolkitEnabled, siweStatement, shadowDOMEnabled = true, walletConnectors: walletConnectorsProp, socialProvidersFilter, showLockedWalletView = false, walletConnectPreferredChains, walletConnectorExtensions, recommendedWallets, handlers, } = settings$1;
151
151
  /**
152
152
  * initialize Storage
@@ -299,6 +299,7 @@ const InnerDynamicContextProvider = ({ children, theme, settings: settings$1, lo
299
299
  canHaveMultipleWalletsConnected: multiWallet,
300
300
  connectedWallets,
301
301
  primaryWalletId,
302
+ separateSmartWalletAndSigner: (_q = (_p = projectSettings$1 === null || projectSettings$1 === void 0 ? void 0 : projectSettings$1.sdk) === null || _p === void 0 ? void 0 : _p.accountAbstraction) === null || _q === void 0 ? void 0 : _q.separateSmartWalletAndSigner,
302
303
  setMultiWalletWidgetState,
303
304
  setPrimaryWalletId,
304
305
  user: user$1 || userWithMissingInfo,
@@ -712,7 +713,7 @@ const InnerDynamicContextProvider = ({ children, theme, settings: settings$1, lo
712
713
  }
713
714
  // eslint-disable-next-line react-hooks/exhaustive-deps
714
715
  }, [multiWallet, multiWalletWidgetState, showDynamicUserProfile]);
715
- return (jsxRuntime.jsx(reactI18next.I18nextProvider, { i18n: i18nSDKInstance, children: jsxRuntime.jsx(DynamicContext.Provider, { value: value, children: jsxRuntime.jsx(walletBook.WalletBookContextProvider, { walletBook: walletBook$1, children: jsxRuntime.jsx(ThemeContext.ThemeContextProvider, { customerTheme: parseTheme.parseTheme(theme, ((_p = projectSettings$1 === null || projectSettings$1 === void 0 ? void 0 : projectSettings$1.design) === null || _p === void 0 ? void 0 : _p.modal) || undefined), designSettings: projectSettings$1 === null || projectSettings$1 === void 0 ? void 0 : projectSettings$1.design, children: jsxRuntime.jsx(LoadingContext.LoadingContextProvider, { children: jsxRuntime.jsxs(ViewContext.ViewContextProvider, { initialView: helpers.getInitialView({
716
+ return (jsxRuntime.jsx(reactI18next.I18nextProvider, { i18n: i18nSDKInstance, children: jsxRuntime.jsx(DynamicContext.Provider, { value: value, children: jsxRuntime.jsx(walletBook.WalletBookContextProvider, { walletBook: walletBook$1, children: jsxRuntime.jsx(ThemeContext.ThemeContextProvider, { customerTheme: parseTheme.parseTheme(theme, ((_r = projectSettings$1 === null || projectSettings$1 === void 0 ? void 0 : projectSettings$1.design) === null || _r === void 0 ? void 0 : _r.modal) || undefined), designSettings: projectSettings$1 === null || projectSettings$1 === void 0 ? void 0 : projectSettings$1.design, children: jsxRuntime.jsx(LoadingContext.LoadingContextProvider, { children: jsxRuntime.jsxs(ViewContext.ViewContextProvider, { initialView: helpers.getInitialView({
716
717
  bridgeOnboardingCompleted,
717
718
  connectedWallets,
718
719
  isAuthenticated: isAuthenticated || Boolean(primaryWallet),
@@ -142,7 +142,7 @@ const PUBLIC_PROJECT_LIVE_ENVIRONMENT_ID = '2762a57b-faa4-41ce-9f16-abff9300e2c9
142
142
  const DynamicContext = createContext(undefined);
143
143
  /** The context provider itself we only use internally */
144
144
  const InnerDynamicContextProvider = ({ children, theme, settings, locale, enableInstrumentation = false, }) => {
145
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
145
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
146
146
  const { accessDeniedMessagePrimary, accessDeniedMessageSecondary, accessDeniedButton, defaultPhoneInputIso2, apiBaseUrl, coinbaseWalletPreference, detectNewWalletsForLinking = false, enableConnectOnlyFallback = false, deepLinkPreference: deepLinkPreferenceProp = 'native', bridgeChains, cssOverrides, defaultNumberOfWalletsToShow = DEFAULT_NUMBER_OF_WALLETS_TO_SHOW, flowNetwork, initialAuthenticationMode = 'connect-and-sign', debugError = false, displaySiweStatement = true, newToWeb3WalletChainMap, enableVisitTrackingOnConnectOnly = true, environmentId, walletsFilter, logLevel = 'WARN', mobileExperience, notInTheListImageUrl, onboardingImageUrl, policiesConsentInnerComponent, customPrivacyPolicy, privacyPolicyUrl, socialMediaLinkText, socialMediaIconUrl, socialMediaUrl, customTermsOfServices, termsOfServiceUrl, toolkitEnabled, siweStatement, shadowDOMEnabled = true, walletConnectors: walletConnectorsProp, socialProvidersFilter, showLockedWalletView = false, walletConnectPreferredChains, walletConnectorExtensions, recommendedWallets, handlers, } = settings;
147
147
  /**
148
148
  * initialize Storage
@@ -295,6 +295,7 @@ const InnerDynamicContextProvider = ({ children, theme, settings, locale, enable
295
295
  canHaveMultipleWalletsConnected: multiWallet,
296
296
  connectedWallets,
297
297
  primaryWalletId,
298
+ separateSmartWalletAndSigner: (_q = (_p = projectSettings === null || projectSettings === void 0 ? void 0 : projectSettings.sdk) === null || _p === void 0 ? void 0 : _p.accountAbstraction) === null || _q === void 0 ? void 0 : _q.separateSmartWalletAndSigner,
298
299
  setMultiWalletWidgetState,
299
300
  setPrimaryWalletId,
300
301
  user: user || userWithMissingInfo,
@@ -708,7 +709,7 @@ const InnerDynamicContextProvider = ({ children, theme, settings, locale, enable
708
709
  }
709
710
  // eslint-disable-next-line react-hooks/exhaustive-deps
710
711
  }, [multiWallet, multiWalletWidgetState, showDynamicUserProfile]);
711
- return (jsx(I18nextProvider, { i18n: i18nSDKInstance, children: jsx(DynamicContext.Provider, { value: value, children: jsx(WalletBookContextProvider, { walletBook: walletBook, children: jsx(ThemeContextProvider, { customerTheme: parseTheme(theme, ((_p = projectSettings === null || projectSettings === void 0 ? void 0 : projectSettings.design) === null || _p === void 0 ? void 0 : _p.modal) || undefined), designSettings: projectSettings === null || projectSettings === void 0 ? void 0 : projectSettings.design, children: jsx(LoadingContextProvider, { children: jsxs(ViewContextProvider, { initialView: getInitialView({
712
+ return (jsx(I18nextProvider, { i18n: i18nSDKInstance, children: jsx(DynamicContext.Provider, { value: value, children: jsx(WalletBookContextProvider, { walletBook: walletBook, children: jsx(ThemeContextProvider, { customerTheme: parseTheme(theme, ((_r = projectSettings === null || projectSettings === void 0 ? void 0 : projectSettings.design) === null || _r === void 0 ? void 0 : _r.modal) || undefined), designSettings: projectSettings === null || projectSettings === void 0 ? void 0 : projectSettings.design, children: jsx(LoadingContextProvider, { children: jsxs(ViewContextProvider, { initialView: getInitialView({
712
713
  bridgeOnboardingCompleted,
713
714
  connectedWallets,
714
715
  isAuthenticated: isAuthenticated || Boolean(primaryWallet),
@@ -103,3 +103,4 @@ export { ReactComponent as CurrencyIcon } from './currency.svg';
103
103
  export { ReactComponent as AuthenticatorIcon } from './authenticator.svg';
104
104
  export { ReactComponent as ShieldIcon } from './shield.svg';
105
105
  export { ReactComponent as SecureActionIcon } from './secure-action.svg';
106
+ export { ReactComponent as SmartWalletIcon } from './smart-wallet.svg';
@@ -0,0 +1,59 @@
1
+ 'use client'
2
+ 'use strict';
3
+
4
+ Object.defineProperty(exports, '__esModule', { value: true });
5
+
6
+ var React = require('react');
7
+
8
+ function _interopNamespace(e) {
9
+ if (e && e.__esModule) return e;
10
+ var n = Object.create(null);
11
+ if (e) {
12
+ Object.keys(e).forEach(function (k) {
13
+ if (k !== 'default') {
14
+ var d = Object.getOwnPropertyDescriptor(e, k);
15
+ Object.defineProperty(n, k, d.get ? d : {
16
+ enumerable: true,
17
+ get: function () { return e[k]; }
18
+ });
19
+ }
20
+ });
21
+ }
22
+ n["default"] = e;
23
+ return Object.freeze(n);
24
+ }
25
+
26
+ var React__namespace = /*#__PURE__*/_interopNamespace(React);
27
+
28
+ var _path, _path2;
29
+ var _excluded = ["title", "titleId"];
30
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
31
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
32
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
33
+ var SvgSmartWallet = function SvgSmartWallet(_ref) {
34
+ var title = _ref.title,
35
+ titleId = _ref.titleId,
36
+ props = _objectWithoutProperties(_ref, _excluded);
37
+ return /*#__PURE__*/React__namespace.createElement("svg", _extends({
38
+ width: 32,
39
+ height: 32,
40
+ viewBox: "0 0 32 32",
41
+ fill: "none",
42
+ xmlns: "http://www.w3.org/2000/svg",
43
+ "aria-labelledby": titleId
44
+ }, props), title ? /*#__PURE__*/React__namespace.createElement("title", {
45
+ id: titleId
46
+ }, title) : null, _path || (_path = /*#__PURE__*/React__namespace.createElement("path", {
47
+ fillRule: "evenodd",
48
+ clipRule: "evenodd",
49
+ d: "M16 32c8.837 0 16-7.163 16-16S24.837 0 16 0 0 7.163 0 16s7.163 16 16 16Zm4.667-23.467c0-1.03-.836-1.866-1.867-1.866h-8.4A3.734 3.734 0 0 0 6.727 9.73a3.723 3.723 0 0 1 2.74-1.198h11.2ZM21.6 10.4a3.733 3.733 0 0 1 3.733 3.733V21.6a3.733 3.733 0 0 1-3.733 3.733H10.4A3.733 3.733 0 0 1 6.667 21.6v-7.467A3.733 3.733 0 0 1 10.4 10.4h11.2Z",
50
+ fill: "#4779FF"
51
+ })), _path2 || (_path2 = /*#__PURE__*/React__namespace.createElement("path", {
52
+ fillRule: "evenodd",
53
+ clipRule: "evenodd",
54
+ d: "M17.455 12.667c.2 0 .38.123.452.31l.572 1.486c.145.379.191.488.254.576a.97.97 0 0 0 .228.228c.088.063.197.109.576.255l1.486.57a.485.485 0 0 1 0 .906l-1.486.571c-.379.146-.488.192-.576.255a.97.97 0 0 0-.228.228c-.063.088-.109.197-.254.576l-.572 1.485a.485.485 0 0 1-.905 0l-.571-1.485c-.146-.379-.192-.488-.254-.576a.97.97 0 0 0-.229-.229c-.088-.062-.197-.108-.576-.254l-1.485-.571a.485.485 0 0 1 0-.905l1.485-.572c.38-.145.488-.191.576-.254a.97.97 0 0 0 .229-.228c.062-.088.108-.197.254-.576l.571-1.486a.485.485 0 0 1 .453-.31ZM13.333 18c.184 0 .352.104.434.268l.38.76c.137.275.18.353.23.42.05.065.11.124.176.175.066.051.144.093.418.23l.761.38a.485.485 0 0 1 0 .867l-.76.38c-.274.138-.353.18-.42.23a.968.968 0 0 0-.175.176c-.05.066-.093.145-.23.419l-.38.76a.485.485 0 0 1-.867 0l-.38-.76c-.138-.274-.18-.353-.23-.419a.968.968 0 0 0-.176-.176c-.066-.05-.145-.092-.419-.23l-.76-.38a.485.485 0 0 1 0-.867l.76-.38c.274-.137.353-.179.419-.23a.968.968 0 0 0 .176-.176c.05-.066.092-.144.23-.418l.38-.761a.485.485 0 0 1 .433-.268Z",
55
+ fill: "#4779FF"
56
+ })));
57
+ };
58
+
59
+ exports.ReactComponent = SvgSmartWallet;
@@ -0,0 +1,35 @@
1
+ 'use client'
2
+ import * as React from 'react';
3
+
4
+ var _path, _path2;
5
+ var _excluded = ["title", "titleId"];
6
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
7
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
8
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
9
+ var SvgSmartWallet = function SvgSmartWallet(_ref) {
10
+ var title = _ref.title,
11
+ titleId = _ref.titleId,
12
+ props = _objectWithoutProperties(_ref, _excluded);
13
+ return /*#__PURE__*/React.createElement("svg", _extends({
14
+ width: 32,
15
+ height: 32,
16
+ viewBox: "0 0 32 32",
17
+ fill: "none",
18
+ xmlns: "http://www.w3.org/2000/svg",
19
+ "aria-labelledby": titleId
20
+ }, props), title ? /*#__PURE__*/React.createElement("title", {
21
+ id: titleId
22
+ }, title) : null, _path || (_path = /*#__PURE__*/React.createElement("path", {
23
+ fillRule: "evenodd",
24
+ clipRule: "evenodd",
25
+ d: "M16 32c8.837 0 16-7.163 16-16S24.837 0 16 0 0 7.163 0 16s7.163 16 16 16Zm4.667-23.467c0-1.03-.836-1.866-1.867-1.866h-8.4A3.734 3.734 0 0 0 6.727 9.73a3.723 3.723 0 0 1 2.74-1.198h11.2ZM21.6 10.4a3.733 3.733 0 0 1 3.733 3.733V21.6a3.733 3.733 0 0 1-3.733 3.733H10.4A3.733 3.733 0 0 1 6.667 21.6v-7.467A3.733 3.733 0 0 1 10.4 10.4h11.2Z",
26
+ fill: "#4779FF"
27
+ })), _path2 || (_path2 = /*#__PURE__*/React.createElement("path", {
28
+ fillRule: "evenodd",
29
+ clipRule: "evenodd",
30
+ d: "M17.455 12.667c.2 0 .38.123.452.31l.572 1.486c.145.379.191.488.254.576a.97.97 0 0 0 .228.228c.088.063.197.109.576.255l1.486.57a.485.485 0 0 1 0 .906l-1.486.571c-.379.146-.488.192-.576.255a.97.97 0 0 0-.228.228c-.063.088-.109.197-.254.576l-.572 1.485a.485.485 0 0 1-.905 0l-.571-1.485c-.146-.379-.192-.488-.254-.576a.97.97 0 0 0-.229-.229c-.088-.062-.197-.108-.576-.254l-1.485-.571a.485.485 0 0 1 0-.905l1.485-.572c.38-.145.488-.191.576-.254a.97.97 0 0 0 .229-.228c.062-.088.108-.197.254-.576l.571-1.486a.485.485 0 0 1 .453-.31ZM13.333 18c.184 0 .352.104.434.268l.38.76c.137.275.18.353.23.42.05.065.11.124.176.175.066.051.144.093.418.23l.761.38a.485.485 0 0 1 0 .867l-.76.38c-.274.138-.353.18-.42.23a.968.968 0 0 0-.175.176c-.05.066-.093.145-.23.419l-.38.76a.485.485 0 0 1-.867 0l-.38-.76c-.138-.274-.18-.353-.23-.419a.968.968 0 0 0-.176-.176c-.066-.05-.145-.092-.419-.23l-.76-.38a.485.485 0 0 1 0-.867l.76-.38c.274-.137.353-.179.419-.23a.968.968 0 0 0 .176-.176c.05-.066.092-.144.23-.418l.38-.761a.485.485 0 0 1 .433-.268Z",
31
+ fill: "#4779FF"
32
+ })));
33
+ };
34
+
35
+ export { SvgSmartWallet as ReactComponent };
@@ -37,6 +37,7 @@ const useNetworkConfigurationsFromProjectSettings = ({ projectSettings, cosmosNe
37
37
  return networkConfigurations;
38
38
  }, [projectSettings === null || projectSettings === void 0 ? void 0 : projectSettings.networks, cosmosNetworkOverrides, evmNetworksOverrides]);
39
39
  const createNetwork = (network, parser = (input) => input) => ({
40
+ bech32Prefix: network.bech32Prefix,
40
41
  blockExplorerUrls: network.blockExplorerUrls,
41
42
  chainId: parser(network.chainId),
42
43
  iconUrls: network.iconUrls,
@@ -33,6 +33,7 @@ const useNetworkConfigurationsFromProjectSettings = ({ projectSettings, cosmosNe
33
33
  return networkConfigurations;
34
34
  }, [projectSettings === null || projectSettings === void 0 ? void 0 : projectSettings.networks, cosmosNetworkOverrides, evmNetworksOverrides]);
35
35
  const createNetwork = (network, parser = (input) => input) => ({
36
+ bech32Prefix: network.bech32Prefix,
36
37
  blockExplorerUrls: network.blockExplorerUrls,
37
38
  chainId: parser(network.chainId),
38
39
  iconUrls: network.iconUrls,
@@ -101,6 +101,7 @@ const socialProviders = [
101
101
  'github',
102
102
  'google',
103
103
  'instagram',
104
+ 'line',
104
105
  'spotify',
105
106
  'telegram',
106
107
  'twitch',
@@ -97,6 +97,7 @@ const socialProviders = [
97
97
  'github',
98
98
  'google',
99
99
  'instagram',
100
+ 'line',
100
101
  'spotify',
101
102
  'telegram',
102
103
  'twitch',
@@ -21,7 +21,7 @@ require('../../../shared/consts/index.cjs');
21
21
  var createLinkedWalletsFromWalletOptions = require('./utils/createLinkedWalletsFromWalletOptions/createLinkedWalletsFromWalletOptions.cjs');
22
22
  var updateUserWalletsFromLinkedWallets = require('./utils/updateUserWalletsFromLinkedWallets/updateUserWalletsFromLinkedWallets.cjs');
23
23
 
24
- const useWalletConnectors = ({ authMode, connectedWallets, walletConnectorOptions, setMultiWalletWidgetState, primaryWalletId, setPrimaryWalletId, user, canHaveMultipleWalletsConnected, }) => {
24
+ const useWalletConnectors = ({ authMode, connectedWallets, walletConnectorOptions, setMultiWalletWidgetState, primaryWalletId, setPrimaryWalletId, user, canHaveMultipleWalletsConnected, separateSmartWalletAndSigner = false, }) => {
25
25
  const [showQrcodeModal, setShowQrcodeModal] = React.useState(false);
26
26
  const linkedWallets = React.useMemo(() => {
27
27
  if (!user) {
@@ -29,10 +29,16 @@ const useWalletConnectors = ({ authMode, connectedWallets, walletConnectorOption
29
29
  }
30
30
  return createLinkedWalletsFromWalletOptions.createLinkedWalletsFromWalletOptions({
31
31
  primaryWalletId,
32
+ separateSmartWalletAndSigner,
32
33
  user,
33
34
  walletConnectorOptions,
34
35
  });
35
- }, [user, primaryWalletId, walletConnectorOptions]);
36
+ }, [
37
+ user,
38
+ primaryWalletId,
39
+ walletConnectorOptions,
40
+ separateSmartWalletAndSigner,
41
+ ]);
36
42
  logger.logger.logVerboseTroubleshootingMessage('linkedWallets', linkedWallets);
37
43
  const wallets = React.useMemo(() => {
38
44
  // Before signing the first message we are using connected wallets list
@@ -11,6 +11,7 @@ type Props = {
11
11
  setPrimaryWalletId: (walletId: string) => void;
12
12
  user?: UserProfile;
13
13
  canHaveMultipleWalletsConnected?: boolean;
14
+ separateSmartWalletAndSigner?: boolean;
14
15
  };
15
16
  export interface UseWalletConnectors {
16
17
  primaryWallet: Wallet | null;
@@ -20,5 +21,5 @@ export interface UseWalletConnectors {
20
21
  showQrcodeModal: boolean;
21
22
  wallets: Wallet[];
22
23
  }
23
- export declare const useWalletConnectors: ({ authMode, connectedWallets, walletConnectorOptions, setMultiWalletWidgetState, primaryWalletId, setPrimaryWalletId, user, canHaveMultipleWalletsConnected, }: Props) => UseWalletConnectors;
24
+ export declare const useWalletConnectors: ({ authMode, connectedWallets, walletConnectorOptions, setMultiWalletWidgetState, primaryWalletId, setPrimaryWalletId, user, canHaveMultipleWalletsConnected, separateSmartWalletAndSigner, }: Props) => UseWalletConnectors;
24
25
  export {};
@@ -17,7 +17,7 @@ import '../../../shared/consts/index.js';
17
17
  import { createLinkedWalletsFromWalletOptions } from './utils/createLinkedWalletsFromWalletOptions/createLinkedWalletsFromWalletOptions.js';
18
18
  import { updateUserWalletsFromLinkedWallets } from './utils/updateUserWalletsFromLinkedWallets/updateUserWalletsFromLinkedWallets.js';
19
19
 
20
- const useWalletConnectors = ({ authMode, connectedWallets, walletConnectorOptions, setMultiWalletWidgetState, primaryWalletId, setPrimaryWalletId, user, canHaveMultipleWalletsConnected, }) => {
20
+ const useWalletConnectors = ({ authMode, connectedWallets, walletConnectorOptions, setMultiWalletWidgetState, primaryWalletId, setPrimaryWalletId, user, canHaveMultipleWalletsConnected, separateSmartWalletAndSigner = false, }) => {
21
21
  const [showQrcodeModal, setShowQrcodeModal] = useState(false);
22
22
  const linkedWallets = useMemo(() => {
23
23
  if (!user) {
@@ -25,10 +25,16 @@ const useWalletConnectors = ({ authMode, connectedWallets, walletConnectorOption
25
25
  }
26
26
  return createLinkedWalletsFromWalletOptions({
27
27
  primaryWalletId,
28
+ separateSmartWalletAndSigner,
28
29
  user,
29
30
  walletConnectorOptions,
30
31
  });
31
- }, [user, primaryWalletId, walletConnectorOptions]);
32
+ }, [
33
+ user,
34
+ primaryWalletId,
35
+ walletConnectorOptions,
36
+ separateSmartWalletAndSigner,
37
+ ]);
32
38
  logger.logVerboseTroubleshootingMessage('linkedWallets', linkedWallets);
33
39
  const wallets = useMemo(() => {
34
40
  // Before signing the first message we are using connected wallets list
@@ -10,7 +10,7 @@ var shouldManuallyReconnectOnRefresh = require('../../../../functions/shouldManu
10
10
  var convertLegacyPhantomLedgerConnector = require('../convertLegacyPhantomLedgerConnector/convertLegacyPhantomLedgerConnector.cjs');
11
11
  var smartWallet = require('../smartWallet/smartWallet.cjs');
12
12
 
13
- const createLinkedWalletsFromWalletOptions = ({ user, walletConnectorOptions, primaryWalletId, }) => {
13
+ const createLinkedWalletsFromWalletOptions = ({ user, walletConnectorOptions, primaryWalletId, separateSmartWalletAndSigner, }) => {
14
14
  // wallet state should be null while loading all the wallets or when there is no user
15
15
  if (!walletConnectorOptions || !user) {
16
16
  return [];
@@ -37,7 +37,8 @@ const createLinkedWalletsFromWalletOptions = ({ user, walletConnectorOptions, pr
37
37
  wallet.walletConnector.isHardwareWalletEnabled = true;
38
38
  }
39
39
  // this account is the owner of a smart wallet, and should not be surfaced
40
- if (smartWallet.isOwnerOfASmartWallet(account, user.verifiedCredentials)) {
40
+ if (!separateSmartWalletAndSigner &&
41
+ smartWallet.isOwnerOfASmartWallet(account, user.verifiedCredentials)) {
41
42
  return null;
42
43
  }
43
44
  if (account.address && account.chain) {
@@ -4,6 +4,7 @@ type CreateWalletsFromWalletOptionsProps = {
4
4
  user: UserProfile;
5
5
  primaryWalletId: string | undefined;
6
6
  walletConnectorOptions: WalletOption[] | undefined;
7
+ separateSmartWalletAndSigner?: boolean;
7
8
  };
8
- export declare const createLinkedWalletsFromWalletOptions: ({ user, walletConnectorOptions, primaryWalletId, }: CreateWalletsFromWalletOptionsProps) => Wallet[];
9
+ export declare const createLinkedWalletsFromWalletOptions: ({ user, walletConnectorOptions, primaryWalletId, separateSmartWalletAndSigner, }: CreateWalletsFromWalletOptionsProps) => Wallet[];
9
10
  export {};
@@ -6,7 +6,7 @@ import { shouldManuallyReconnectOnRefresh } from '../../../../functions/shouldMa
6
6
  import { convertLegacyPhantomLedgerConnector } from '../convertLegacyPhantomLedgerConnector/convertLegacyPhantomLedgerConnector.js';
7
7
  import { isOwnerOfASmartWallet, initializeSmartWallet } from '../smartWallet/smartWallet.js';
8
8
 
9
- const createLinkedWalletsFromWalletOptions = ({ user, walletConnectorOptions, primaryWalletId, }) => {
9
+ const createLinkedWalletsFromWalletOptions = ({ user, walletConnectorOptions, primaryWalletId, separateSmartWalletAndSigner, }) => {
10
10
  // wallet state should be null while loading all the wallets or when there is no user
11
11
  if (!walletConnectorOptions || !user) {
12
12
  return [];
@@ -33,7 +33,8 @@ const createLinkedWalletsFromWalletOptions = ({ user, walletConnectorOptions, pr
33
33
  wallet.walletConnector.isHardwareWalletEnabled = true;
34
34
  }
35
35
  // this account is the owner of a smart wallet, and should not be surfaced
36
- if (isOwnerOfASmartWallet(account, user.verifiedCredentials)) {
36
+ if (!separateSmartWalletAndSigner &&
37
+ isOwnerOfASmartWallet(account, user.verifiedCredentials)) {
37
38
  return null;
38
39
  }
39
40
  if (account.address && account.chain) {
@@ -102,7 +102,7 @@ const useWalletOptions = () => {
102
102
  const walletOptions = React.useMemo(() => {
103
103
  var _a;
104
104
  return (_a = walletConnectorOptions === null || walletConnectorOptions === void 0 ? void 0 : walletConnectorOptions.filter((option) => !embeddedWalletsKeys.includes(option.walletConnector.key)).map((option) => {
105
- const groupName = option.group
105
+ const groupName = option.group && Boolean(Object.keys(walletBook$1).length)
106
106
  ? walletBook.getWalletGroup(walletBook$1, option.group).name
107
107
  : undefined;
108
108
  return {
@@ -98,7 +98,7 @@ const useWalletOptions = () => {
98
98
  const walletOptions = useMemo(() => {
99
99
  var _a;
100
100
  return (_a = walletConnectorOptions === null || walletConnectorOptions === void 0 ? void 0 : walletConnectorOptions.filter((option) => !embeddedWalletsKeys.includes(option.walletConnector.key)).map((option) => {
101
- const groupName = option.group
101
+ const groupName = option.group && Boolean(Object.keys(walletBook).length)
102
102
  ? getWalletGroup(walletBook, option.group).name
103
103
  : undefined;
104
104
  return {