@dynamic-labs-sdk/client 1.7.0 → 1.8.1
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/android/build.gradle +231 -0
- package/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/android/gradle/wrapper/gradle-wrapper.properties +7 -0
- package/android/gradle.properties +8 -0
- package/android/gradlew +251 -0
- package/android/gradlew.bat +94 -0
- package/android/settings.gradle +30 -0
- package/android/src/main/java/xyz/dynamic/client/DynamicClientPackage.kt +52 -0
- package/android/src/main/java/xyz/dynamic/client/keychain/KeyStoreKeyManager.kt +147 -0
- package/android/src/main/java/xyz/dynamic/client/keychain/KeychainModule.kt +85 -0
- package/android/src/main/java/xyz/dynamic/client/manifest/ReactNativeManifestModule.kt +25 -0
- package/android/src/main/java/xyz/dynamic/client/webview/DynamicWebViewClient.kt +83 -0
- package/android/src/main/java/xyz/dynamic/client/webview/DynamicWebViewHost.kt +518 -0
- package/android/src/main/java/xyz/dynamic/client/webview/DynamicWebViewModule.kt +147 -0
- package/android/src/test/java/xyz/dynamic/client/keychain/KeyStoreKeyManagerTest.kt +288 -0
- package/android/src/test/java/xyz/dynamic/client/webview/DynamicWebViewClientTest.kt +196 -0
- package/android/src/test/java/xyz/dynamic/client/webview/DynamicWebViewHostOpenTest.kt +347 -0
- package/android/src/test/java/xyz/dynamic/client/webview/DynamicWebViewHostTest.kt +171 -0
- package/android/src/test/java/xyz/dynamic/client/webview/DynamicWebViewModuleTest.kt +191 -0
- package/dist/{InvalidParamError-Crwntjl7.native.esm.js → InvalidParamError-BKnC9rcJ.esm.js} +441 -10
- package/dist/InvalidParamError-BKnC9rcJ.esm.js.map +1 -0
- package/dist/{InvalidParamError-fQLJaGBW.esm.js → InvalidParamError-Btv8VGSa.native.esm.js} +3 -3
- package/dist/InvalidParamError-Btv8VGSa.native.esm.js.map +1 -0
- package/dist/{InvalidParamError-CTssOe86.cjs → InvalidParamError-DGBih-LJ.cjs} +550 -4
- package/dist/InvalidParamError-DGBih-LJ.cjs.map +1 -0
- package/dist/{NotWaasWalletAccountError-DF_S7gqo.esm.js → NotWaasWalletAccountError-CHr72wTH.esm.js} +3 -3
- package/dist/{NotWaasWalletAccountError-DF_S7gqo.esm.js.map → NotWaasWalletAccountError-CHr72wTH.esm.js.map} +1 -1
- package/dist/{NotWaasWalletAccountError-BJLGGYmU.native.esm.js → NotWaasWalletAccountError-CRmyVoB3.native.esm.js} +3 -3
- package/dist/{NotWaasWalletAccountError-BJLGGYmU.native.esm.js.map → NotWaasWalletAccountError-CRmyVoB3.native.esm.js.map} +1 -1
- package/dist/{NotWaasWalletAccountError-2RaDipZu.cjs → NotWaasWalletAccountError-i1FozGep.cjs} +3 -3
- package/dist/{NotWaasWalletAccountError-2RaDipZu.cjs.map → NotWaasWalletAccountError-i1FozGep.cjs.map} +1 -1
- package/dist/core.cjs +23 -23
- package/dist/core.cjs.map +1 -1
- package/dist/core.esm.js +5 -5
- package/dist/core.native.esm.js +7 -7
- package/dist/core.native.esm.js.map +1 -1
- package/dist/errors/WebViewLoadFailedError.d.ts +1 -1
- package/dist/errors/WebViewLoadFailedError.d.ts.map +1 -1
- package/dist/exports/index.d.ts +2 -0
- package/dist/exports/index.d.ts.map +1 -1
- package/dist/{getNetworkProviderFromNetworkId-C1p9Rrg3.cjs → getNetworkProviderFromNetworkId-BdgI7g5U.cjs} +11 -317
- package/dist/getNetworkProviderFromNetworkId-BdgI7g5U.cjs.map +1 -0
- package/dist/{getNetworkProviderFromNetworkId-BCSmILlH.native.esm.js → getNetworkProviderFromNetworkId-Bm41knUq.native.esm.js} +6 -6
- package/dist/getNetworkProviderFromNetworkId-Bm41knUq.native.esm.js.map +1 -0
- package/dist/{getNetworkProviderFromNetworkId-BWhaD23J.esm.js → getNetworkProviderFromNetworkId-CRuh5pgc.esm.js} +4 -242
- package/dist/getNetworkProviderFromNetworkId-CRuh5pgc.esm.js.map +1 -0
- package/dist/{getSignedSessionId-CxxYNC_8.cjs → getSignedSessionId-Cwmt4BkY.cjs} +3 -3
- package/dist/{getSignedSessionId-CxxYNC_8.cjs.map → getSignedSessionId-Cwmt4BkY.cjs.map} +1 -1
- package/dist/{getSignedSessionId-c7dS4PQ9.esm.js → getSignedSessionId-D2w_IRdt.esm.js} +3 -3
- package/dist/{getSignedSessionId-c7dS4PQ9.esm.js.map → getSignedSessionId-D2w_IRdt.esm.js.map} +1 -1
- package/dist/{getSignedSessionId-DPOXdh6y.native.esm.js → getSignedSessionId-S6CBWkOn.native.esm.js} +3 -3
- package/dist/{getSignedSessionId-DPOXdh6y.native.esm.js.map → getSignedSessionId-S6CBWkOn.native.esm.js.map} +1 -1
- package/dist/getVerifiedCredentialForWalletAccount-CDuP1kaI.cjs +347 -0
- package/dist/getVerifiedCredentialForWalletAccount-CDuP1kaI.cjs.map +1 -0
- package/dist/{getVerifiedCredentialForWalletAccount-Cahp763h.esm.js → getVerifiedCredentialForWalletAccount-D33r7Drd.native.esm.js} +2 -2
- package/dist/{getVerifiedCredentialForWalletAccount-DuNbORNW.native.esm.js.map → getVerifiedCredentialForWalletAccount-D33r7Drd.native.esm.js.map} +1 -1
- package/dist/getVerifiedCredentialForWalletAccount-QwfkKHfr.esm.js +269 -0
- package/dist/getVerifiedCredentialForWalletAccount-QwfkKHfr.esm.js.map +1 -0
- package/dist/index.cjs +67 -67
- package/dist/index.cjs.map +1 -1
- package/dist/index.esm.js +5 -5
- package/dist/index.esm.js.map +1 -1
- package/dist/index.native.esm.js +5 -5
- package/dist/index.native.esm.js.map +1 -1
- package/dist/isMfaRequiredForAction-5p3i98-Z.esm.js +318 -0
- package/dist/isMfaRequiredForAction-5p3i98-Z.esm.js.map +1 -0
- package/dist/{isMfaRequiredForAction-D8G5PBAd.native.esm.js → isMfaRequiredForAction-cmElIVof.native.esm.js} +2 -2
- package/dist/{isMfaRequiredForAction-D8G5PBAd.native.esm.js.map → isMfaRequiredForAction-cmElIVof.native.esm.js.map} +1 -1
- package/dist/isMfaRequiredForAction-z74isCQ7.cjs +405 -0
- package/dist/isMfaRequiredForAction-z74isCQ7.cjs.map +1 -0
- package/dist/modules/waas/createWaasClient/createWaasClient.d.ts.map +1 -1
- package/dist/modules/waas/createWaasClient/translateNativeOpenError.d.ts.map +1 -1
- package/dist/modules/wallets/walletProvider/events/onWalletProviderEvent/onWalletProviderEvent.d.ts +1 -2
- package/dist/modules/wallets/walletProvider/events/onWalletProviderEvent/onWalletProviderEvent.d.ts.map +1 -1
- package/dist/tsconfig.lib.tsbuildinfo +1 -1
- package/dist/waas.cjs +9 -9
- package/dist/waas.cjs.map +1 -1
- package/dist/waas.esm.js +3 -3
- package/dist/waas.native.esm.js +3 -3
- package/dist/waasCore.cjs +8 -5
- package/dist/waasCore.cjs.map +1 -1
- package/dist/waasCore.esm.js +8 -4
- package/dist/waasCore.esm.js.map +1 -1
- package/dist/waasCore.native.esm.js +9 -8
- package/dist/waasCore.native.esm.js.map +1 -1
- package/dynamic-labs-sdk-client.podspec +27 -0
- package/ios/DynamicClientKeychain.h +4 -0
- package/ios/DynamicClientKeychain.mm +101 -0
- package/ios/DynamicClientManifest.h +4 -0
- package/ios/DynamicClientManifest.mm +45 -0
- package/ios/DynamicClientWebView.h +5 -0
- package/ios/DynamicClientWebView.mm +143 -0
- package/ios/DynamicWebViewImpl.swift +603 -0
- package/ios/LiveSecKeyAPI.swift +86 -0
- package/ios/ReactNativeManifestImpl.swift +20 -0
- package/ios/SecKeyAPI.swift +57 -0
- package/ios/SecureEnclaveKeyManager.swift +191 -0
- package/package.json +14 -5
- package/react-native.config.cjs +14 -0
- package/src/turboModules/NativeDynamicWebView.native.spec.ts +61 -0
- package/src/turboModules/NativeDynamicWebView.ts +40 -0
- package/src/turboModules/NativeKeychain.native.spec.ts +47 -0
- package/src/turboModules/NativeKeychain.ts +19 -0
- package/src/turboModules/NativeReactNativeManifest.native.spec.ts +55 -0
- package/src/turboModules/NativeReactNativeManifest.ts +28 -0
- package/dist/InvalidParamError-CTssOe86.cjs.map +0 -1
- package/dist/InvalidParamError-Crwntjl7.native.esm.js.map +0 -1
- package/dist/InvalidParamError-fQLJaGBW.esm.js.map +0 -1
- package/dist/getNetworkProviderFromNetworkId-BCSmILlH.native.esm.js.map +0 -1
- package/dist/getNetworkProviderFromNetworkId-BWhaD23J.esm.js.map +0 -1
- package/dist/getNetworkProviderFromNetworkId-C1p9Rrg3.cjs.map +0 -1
- package/dist/getVerifiedCredentialForWalletAccount-Cahp763h.esm.js.map +0 -1
- package/dist/getVerifiedCredentialForWalletAccount-Di8dM5Wx.cjs +0 -887
- package/dist/getVerifiedCredentialForWalletAccount-Di8dM5Wx.cjs.map +0 -1
- package/dist/getVerifiedCredentialForWalletAccount-DuNbORNW.native.esm.js +0 -701
- package/dist/isMfaRequiredForAction-BjRvPrU6.esm.js +0 -79
- package/dist/isMfaRequiredForAction-BjRvPrU6.esm.js.map +0 -1
- package/dist/isMfaRequiredForAction-hlhj0qAC.cjs +0 -96
- package/dist/isMfaRequiredForAction-hlhj0qAC.cjs.map +0 -1
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
const
|
|
1
|
+
const require_isMfaRequiredForAction = require('./isMfaRequiredForAction-z74isCQ7.cjs');
|
|
2
2
|
let _dynamic_labs_sdk_api_core = require("@dynamic-labs/sdk-api-core");
|
|
3
3
|
|
|
4
4
|
//#region package.json
|
|
5
5
|
var name = "@dynamic-labs-sdk/client";
|
|
6
|
-
var version = "1.
|
|
6
|
+
var version = "1.8.1";
|
|
7
7
|
var dependencies = {
|
|
8
8
|
"@dynamic-labs-sdk/assert-package-version": "workspace:*",
|
|
9
|
-
"@dynamic-labs-wallet/browser-wallet-client": "1.0.
|
|
9
|
+
"@dynamic-labs-wallet/browser-wallet-client": "1.0.16",
|
|
10
10
|
"@dynamic-labs-wallet/forward-mpc-client": "0.10.1",
|
|
11
11
|
"@dynamic-labs/sdk-api-core": "catalog:",
|
|
12
12
|
"@simplewebauthn/browser": "13.1.0",
|
|
@@ -1017,6 +1017,152 @@ const fetchAndStoreNonces = async (client) => {
|
|
|
1017
1017
|
});
|
|
1018
1018
|
};
|
|
1019
1019
|
|
|
1020
|
+
//#endregion
|
|
1021
|
+
//#region src/utils/setCookie/setCookie.ts
|
|
1022
|
+
/**
|
|
1023
|
+
* Sefelly sets the cookie in the browser.
|
|
1024
|
+
* @not-instrumented
|
|
1025
|
+
*/
|
|
1026
|
+
const setCookie = (cookie) => {
|
|
1027
|
+
document.cookie = cookie;
|
|
1028
|
+
};
|
|
1029
|
+
|
|
1030
|
+
//#endregion
|
|
1031
|
+
//#region src/modules/clientEvents/clientEvents.ts
|
|
1032
|
+
/**
|
|
1033
|
+
* Adds an event listener for Dynamic client events.
|
|
1034
|
+
*
|
|
1035
|
+
* This function allows you to listen for various events emitted by the Dynamic client,
|
|
1036
|
+
* such as authentication state changes, wallet connections, and more.
|
|
1037
|
+
*
|
|
1038
|
+
* @param params.event - The event name to listen for.
|
|
1039
|
+
* @param params.listener - The callback function to execute when the event is fired.
|
|
1040
|
+
* @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.
|
|
1041
|
+
* @returns A function that can be called to remove the listener.
|
|
1042
|
+
* @not-instrumented
|
|
1043
|
+
*/
|
|
1044
|
+
const onEvent = ({ event, listener }, client = getDefaultClient()) => {
|
|
1045
|
+
const { eventEmitter } = getCore(client);
|
|
1046
|
+
eventEmitter.on(event, listener);
|
|
1047
|
+
return () => {
|
|
1048
|
+
eventEmitter.off(event, listener);
|
|
1049
|
+
};
|
|
1050
|
+
};
|
|
1051
|
+
/**
|
|
1052
|
+
* Removes an event listener from Dynamic client events.
|
|
1053
|
+
*
|
|
1054
|
+
* This function unsubscribes a previously registered event listener
|
|
1055
|
+
* from the specified Dynamic client event.
|
|
1056
|
+
*
|
|
1057
|
+
* @param params.event - The event name to remove the listener from.
|
|
1058
|
+
* @param params.listener - The callback function to remove.
|
|
1059
|
+
* @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.
|
|
1060
|
+
* @not-instrumented
|
|
1061
|
+
*/
|
|
1062
|
+
const offEvent = ({ event, listener }, client = getDefaultClient()) => {
|
|
1063
|
+
const { eventEmitter } = getCore(client);
|
|
1064
|
+
eventEmitter.off(event, listener);
|
|
1065
|
+
};
|
|
1066
|
+
/**
|
|
1067
|
+
* Adds a one-time event listener for Dynamic client events.
|
|
1068
|
+
*
|
|
1069
|
+
* This function listens for an event that will automatically remove itself
|
|
1070
|
+
* after being triggered once.
|
|
1071
|
+
*
|
|
1072
|
+
* @param params.event - The event name to listen for.
|
|
1073
|
+
* @param params.listener - The callback function to execute when the event is fired.
|
|
1074
|
+
* @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.
|
|
1075
|
+
* @returns A function that can be called to remove the listener before it fires.
|
|
1076
|
+
* @not-instrumented
|
|
1077
|
+
*/
|
|
1078
|
+
const onceEvent = ({ event, listener }, client = getDefaultClient()) => {
|
|
1079
|
+
const { eventEmitter } = getCore(client);
|
|
1080
|
+
eventEmitter.once(event, listener);
|
|
1081
|
+
return () => {
|
|
1082
|
+
eventEmitter.off(event, listener);
|
|
1083
|
+
};
|
|
1084
|
+
};
|
|
1085
|
+
/**
|
|
1086
|
+
* Emits a Dynamic client event.
|
|
1087
|
+
*
|
|
1088
|
+
* This function triggers an event that will be received by all registered
|
|
1089
|
+
* listeners for the specified event type.
|
|
1090
|
+
*
|
|
1091
|
+
* @param params.event - The event name to emit.
|
|
1092
|
+
* @param params.args - The arguments to pass to event listeners.
|
|
1093
|
+
* @param client - The Dynamic client instance.
|
|
1094
|
+
* @not-instrumented
|
|
1095
|
+
*/
|
|
1096
|
+
const emitEvent = ({ event, args }, client) => {
|
|
1097
|
+
const { eventEmitter } = getCore(client);
|
|
1098
|
+
eventEmitter.emit(event, args);
|
|
1099
|
+
};
|
|
1100
|
+
|
|
1101
|
+
//#endregion
|
|
1102
|
+
//#region src/errors/InvalidWalletProviderKeyError.ts
|
|
1103
|
+
var InvalidWalletProviderKeyError = class extends BaseError {
|
|
1104
|
+
constructor(value) {
|
|
1105
|
+
super({
|
|
1106
|
+
cause: null,
|
|
1107
|
+
code: "invalid_wallet_provider_key",
|
|
1108
|
+
docsUrl: null,
|
|
1109
|
+
name: "InvalidWalletProviderKeyError",
|
|
1110
|
+
shortMessage: `Invalid wallet provider key: ${value}. Key must be in the format of <normalizedWalletNameWithChain>:<walletProviderType>[:<suffix>]`
|
|
1111
|
+
});
|
|
1112
|
+
}
|
|
1113
|
+
};
|
|
1114
|
+
|
|
1115
|
+
//#endregion
|
|
1116
|
+
//#region src/modules/wallets/walletProvider/splitWalletProviderKey/splitWalletProviderKey.ts
|
|
1117
|
+
/** @not-instrumented */
|
|
1118
|
+
const splitWalletProviderKey = (walletProviderKey) => {
|
|
1119
|
+
const [normalizedWalletNameWithChain, walletProviderType, suffix, ...rest] = walletProviderKey.split(":");
|
|
1120
|
+
if (!normalizedWalletNameWithChain || !Object.values(_dynamic_labs_sdk_api_core.WalletProviderEnum).includes(walletProviderType) || rest.length > 0) throw new InvalidWalletProviderKeyError(walletProviderKey);
|
|
1121
|
+
return {
|
|
1122
|
+
normalizedWalletNameWithChain,
|
|
1123
|
+
suffix,
|
|
1124
|
+
walletProviderType
|
|
1125
|
+
};
|
|
1126
|
+
};
|
|
1127
|
+
|
|
1128
|
+
//#endregion
|
|
1129
|
+
//#region src/modules/wallets/utils/normalizeAddress/normalizeAddress.ts
|
|
1130
|
+
/** @not-instrumented */
|
|
1131
|
+
const normalizeAddress = ({ address, chain }) => {
|
|
1132
|
+
let normalizedAddress = address;
|
|
1133
|
+
if (normalizedAddress?.startsWith("0x")) normalizedAddress = normalizedAddress.slice(2);
|
|
1134
|
+
normalizedAddress = ["EVM", "FLOW"].includes(chain) ? normalizedAddress?.toLowerCase() : normalizedAddress;
|
|
1135
|
+
return normalizedAddress;
|
|
1136
|
+
};
|
|
1137
|
+
|
|
1138
|
+
//#endregion
|
|
1139
|
+
//#region src/modules/wallets/utils/formatWalletAccountId/formatWalletAccountId.ts
|
|
1140
|
+
/** @not-instrumented */
|
|
1141
|
+
const formatWalletAccountId = ({ address, chain, walletProviderKey }) => {
|
|
1142
|
+
const { normalizedWalletNameWithChain } = splitWalletProviderKey(walletProviderKey);
|
|
1143
|
+
return `${normalizedWalletNameWithChain}:${normalizeAddress({
|
|
1144
|
+
address,
|
|
1145
|
+
chain
|
|
1146
|
+
})}`;
|
|
1147
|
+
};
|
|
1148
|
+
|
|
1149
|
+
//#endregion
|
|
1150
|
+
//#region src/modules/wallets/utils/convertUnverifiedWalletAccountToWalletAccount/convertUnverifiedWalletAccountToWalletAccount.ts
|
|
1151
|
+
/** @not-instrumented */
|
|
1152
|
+
const convertUnverifiedWalletAccountToWalletAccount = ({ unverifiedWalletAccount }) => ({
|
|
1153
|
+
address: unverifiedWalletAccount.address,
|
|
1154
|
+
addressesWithTypes: unverifiedWalletAccount.addressesWithTypes,
|
|
1155
|
+
chain: unverifiedWalletAccount.chain,
|
|
1156
|
+
id: formatWalletAccountId({
|
|
1157
|
+
address: unverifiedWalletAccount.address,
|
|
1158
|
+
chain: unverifiedWalletAccount.chain,
|
|
1159
|
+
walletProviderKey: unverifiedWalletAccount.walletProviderKey
|
|
1160
|
+
}),
|
|
1161
|
+
lastSelectedAt: unverifiedWalletAccount.lastSelectedAt,
|
|
1162
|
+
verifiedCredentialId: null,
|
|
1163
|
+
walletProviderKey: unverifiedWalletAccount.walletProviderKey
|
|
1164
|
+
});
|
|
1165
|
+
|
|
1020
1166
|
//#endregion
|
|
1021
1167
|
//#region src/modules/wallets/constants.ts
|
|
1022
1168
|
const CHAINS_INFO_MAP = {
|
|
@@ -1120,6 +1266,292 @@ const getChainFromVerifiedCredentialChain = (verifiedCredentialChain) => {
|
|
|
1120
1266
|
return chain;
|
|
1121
1267
|
};
|
|
1122
1268
|
|
|
1269
|
+
//#endregion
|
|
1270
|
+
//#region src/modules/wallets/utils/normalizeWalletNameWithChain/normalizeWalletNameWithChain.ts
|
|
1271
|
+
/**
|
|
1272
|
+
* Format the raw wallet name and chain to get the value we can use for
|
|
1273
|
+
* verified credentials' `walletName` field.
|
|
1274
|
+
* @not-instrumented
|
|
1275
|
+
*/
|
|
1276
|
+
const normalizeWalletNameWithChain = ({ displayName, chain }) => {
|
|
1277
|
+
const sanitizedWalletName = displayName.replace(/[^a-zA-Z0-9]/g, "").toLowerCase();
|
|
1278
|
+
const chainLowered = chain.toLocaleLowerCase();
|
|
1279
|
+
if (sanitizedWalletName.endsWith(chainLowered)) return sanitizedWalletName;
|
|
1280
|
+
return `${sanitizedWalletName}${chainLowered}`;
|
|
1281
|
+
};
|
|
1282
|
+
|
|
1283
|
+
//#endregion
|
|
1284
|
+
//#region src/modules/wallets/utils/formatWalletProviderKey/formatWalletProviderKey.ts
|
|
1285
|
+
/**
|
|
1286
|
+
* Assembles the wallet provider key from the wallet name, chain, and wallet provider type.
|
|
1287
|
+
*
|
|
1288
|
+
* The suffix is optional and can be used to add a uniquely identifying string to the key, which
|
|
1289
|
+
* might be necessary for some wallet providers (like Wallet Connect).
|
|
1290
|
+
*
|
|
1291
|
+
* IMPORTANT: Do NOT add a suffix unless absolutely necessary, as it will cause the wallet account
|
|
1292
|
+
* to not be able to find its wallet provider when connecting to a new device (it won't be possible
|
|
1293
|
+
* to determine the full key just from the Verified Credential data).
|
|
1294
|
+
* @not-instrumented
|
|
1295
|
+
*/
|
|
1296
|
+
const formatWalletProviderKey = ({ suffix, chain, displayName, walletProviderType }) => {
|
|
1297
|
+
return `${normalizeWalletNameWithChain({
|
|
1298
|
+
chain,
|
|
1299
|
+
displayName
|
|
1300
|
+
})}:${walletProviderType}${suffix ? `:${suffix}` : ""}`;
|
|
1301
|
+
};
|
|
1302
|
+
|
|
1303
|
+
//#endregion
|
|
1304
|
+
//#region src/modules/wallets/walletProvider/walletProviderKeyMap/getWalletProviderKeyFromVerifiedCredential/getWalletProviderKeyFromVerifiedCredential.ts
|
|
1305
|
+
/** @not-instrumented */
|
|
1306
|
+
const getWalletProviderKeyFromVerifiedCredential = ({ verifiedCredential }, client) => {
|
|
1307
|
+
const { walletProviderKeyMap } = getCore(client).state.get();
|
|
1308
|
+
const storedWalletProviderKey = walletProviderKeyMap[verifiedCredential.id];
|
|
1309
|
+
if (storedWalletProviderKey) return { walletProviderKey: storedWalletProviderKey };
|
|
1310
|
+
/**
|
|
1311
|
+
* We fallback to comprising the wallet provider key from walletName and walletProvider.
|
|
1312
|
+
*
|
|
1313
|
+
* Some wallet provider types (like Wallet Connect) also use a special suffix for their wallet provider
|
|
1314
|
+
* keys, so this won't be enough for them.
|
|
1315
|
+
* Therefore, for those specific wallet providers, the wallet account will remain without a wallet provider
|
|
1316
|
+
* and will require reconnection.
|
|
1317
|
+
* Read walletProvider.types.ts for more info.
|
|
1318
|
+
*/
|
|
1319
|
+
assertDefined(verifiedCredential.walletName, `Failed to get wallet provider for verified credential with ID ${verifiedCredential.id}: missing walletName`);
|
|
1320
|
+
assertDefined(verifiedCredential.walletProvider, `Failed to get wallet provider for verified credential with ID ${verifiedCredential.id}: missing walletProvider`);
|
|
1321
|
+
assertDefined(verifiedCredential.chain, `Failed to get wallet provider for verified credential with ID ${verifiedCredential.id}: missing chain`);
|
|
1322
|
+
return { walletProviderKey: formatWalletProviderKey({
|
|
1323
|
+
chain: getChainFromVerifiedCredentialChain(verifiedCredential.chain),
|
|
1324
|
+
displayName: verifiedCredential.walletName,
|
|
1325
|
+
walletProviderType: verifiedCredential.walletProvider
|
|
1326
|
+
}) };
|
|
1327
|
+
};
|
|
1328
|
+
|
|
1329
|
+
//#endregion
|
|
1330
|
+
//#region src/modules/wallets/utils/convertVerifiedCredentialToWalletAccount/convertVerifiedCredentialToWalletAccount.ts
|
|
1331
|
+
/** @not-instrumented */
|
|
1332
|
+
const convertVerifiedCredentialToWalletAccount = ({ verifiedCredential }, client) => {
|
|
1333
|
+
assertDefined(verifiedCredential.address, "Missing address in verified credential");
|
|
1334
|
+
assertDefined(verifiedCredential.chain, "Missing chain in verified credential");
|
|
1335
|
+
const chain = getChainFromVerifiedCredentialChain(verifiedCredential.chain);
|
|
1336
|
+
const { walletProviderKey } = getWalletProviderKeyFromVerifiedCredential({ verifiedCredential }, client);
|
|
1337
|
+
const walletAccountId = formatWalletAccountId({
|
|
1338
|
+
address: verifiedCredential.address,
|
|
1339
|
+
chain,
|
|
1340
|
+
walletProviderKey
|
|
1341
|
+
});
|
|
1342
|
+
return {
|
|
1343
|
+
address: verifiedCredential.address,
|
|
1344
|
+
addressesWithTypes: verifiedCredential.walletAdditionalAddresses,
|
|
1345
|
+
chain,
|
|
1346
|
+
hardwareWalletVendor: verifiedCredential.walletProperties?.hardwareWallet,
|
|
1347
|
+
id: walletAccountId,
|
|
1348
|
+
lastSelectedAt: verifiedCredential.lastSelectedAt ?? null,
|
|
1349
|
+
verifiedCredentialId: verifiedCredential.id,
|
|
1350
|
+
walletProviderKey
|
|
1351
|
+
};
|
|
1352
|
+
};
|
|
1353
|
+
|
|
1354
|
+
//#endregion
|
|
1355
|
+
//#region src/modules/wallets/getWalletAccounts/getWalletAccountsFromState/getWalletAccountsFromState.ts
|
|
1356
|
+
/** @not-instrumented */
|
|
1357
|
+
const getWalletAccountsFromState = ({ unverifiedWalletAccounts, user }, client) => {
|
|
1358
|
+
const walletAccountsMap = /* @__PURE__ */ new Map();
|
|
1359
|
+
/**
|
|
1360
|
+
* Handle the unverified wallet accounts before the user verified credentials
|
|
1361
|
+
* so the later verified wallet accounts can override the unverified wallet accounts
|
|
1362
|
+
*/
|
|
1363
|
+
unverifiedWalletAccounts.forEach((unverifiedWalletAccount) => {
|
|
1364
|
+
const walletAccount = convertUnverifiedWalletAccountToWalletAccount({ unverifiedWalletAccount });
|
|
1365
|
+
walletAccountsMap.set(walletAccount.id, walletAccount);
|
|
1366
|
+
});
|
|
1367
|
+
(user?.verifiedCredentials ?? []).filter((verified) => verified.format === _dynamic_labs_sdk_api_core.JwtVerifiedCredentialFormatEnum.Blockchain).forEach((verifiedWalletAccount) => {
|
|
1368
|
+
const walletAccount = convertVerifiedCredentialToWalletAccount({ verifiedCredential: verifiedWalletAccount }, client);
|
|
1369
|
+
walletAccountsMap.set(walletAccount.id, walletAccount);
|
|
1370
|
+
});
|
|
1371
|
+
return Array.from(walletAccountsMap.values());
|
|
1372
|
+
};
|
|
1373
|
+
|
|
1374
|
+
//#endregion
|
|
1375
|
+
//#region src/modules/wallets/getWalletAccounts/getWalletAccounts.ts
|
|
1376
|
+
/**
|
|
1377
|
+
* Retrieves all wallet accounts associated with the current session.
|
|
1378
|
+
*
|
|
1379
|
+
* This function returns both verified and unverified wallet accounts,
|
|
1380
|
+
* combining data from user credentials and local unverified accounts.
|
|
1381
|
+
* You can differentiate between verified and unverified wallet accounts by
|
|
1382
|
+
* checking the `verifiedCredentialId` property.
|
|
1383
|
+
*
|
|
1384
|
+
* @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.
|
|
1385
|
+
* @returns An array of wallet accounts associated with the session.
|
|
1386
|
+
* @not-instrumented
|
|
1387
|
+
*/
|
|
1388
|
+
const getWalletAccounts = (client = getDefaultClient()) => {
|
|
1389
|
+
const { unverifiedWalletAccounts, user } = getCore(client).state.get();
|
|
1390
|
+
return getWalletAccountsFromState({
|
|
1391
|
+
unverifiedWalletAccounts,
|
|
1392
|
+
user
|
|
1393
|
+
}, client);
|
|
1394
|
+
};
|
|
1395
|
+
|
|
1396
|
+
//#endregion
|
|
1397
|
+
//#region src/errors/NoWalletProviderFoundError.ts
|
|
1398
|
+
var NoWalletProviderFoundError = class extends BaseError {
|
|
1399
|
+
constructor({ walletProviderKey }) {
|
|
1400
|
+
super({
|
|
1401
|
+
cause: null,
|
|
1402
|
+
code: "no_wallet_provider_found_error",
|
|
1403
|
+
docsUrl: null,
|
|
1404
|
+
name: "NoWalletProviderFoundError",
|
|
1405
|
+
shortMessage: `No wallet provider found with key: ${walletProviderKey}`
|
|
1406
|
+
});
|
|
1407
|
+
}
|
|
1408
|
+
};
|
|
1409
|
+
|
|
1410
|
+
//#endregion
|
|
1411
|
+
//#region src/services/runtimeServices/createRuntimeServiceAccessKey/createRuntimeServiceAccessKey.ts
|
|
1412
|
+
/**
|
|
1413
|
+
* Creates a service accessor function that manages service instantiation and caching.
|
|
1414
|
+
* The returned function will either retrieve an existing service from the registry or
|
|
1415
|
+
* create a new one using the provided builder function.
|
|
1416
|
+
*
|
|
1417
|
+
* @template - The type of service to be created/accessed
|
|
1418
|
+
* @param key - Unique identifier for the service in the registry
|
|
1419
|
+
* @param builder - Function that creates the service instance when called with a DynamicClient
|
|
1420
|
+
* @not-instrumented
|
|
1421
|
+
*/
|
|
1422
|
+
const createRuntimeServiceAccessKey = (key, builder) => (client) => {
|
|
1423
|
+
const { runtimeServices } = getCore(client);
|
|
1424
|
+
const currentService = runtimeServices.getByKey(key);
|
|
1425
|
+
if (currentService) return currentService;
|
|
1426
|
+
const service = builder(client);
|
|
1427
|
+
runtimeServices.register(key, service);
|
|
1428
|
+
return service;
|
|
1429
|
+
};
|
|
1430
|
+
|
|
1431
|
+
//#endregion
|
|
1432
|
+
//#region src/modules/wallets/walletProviderRegistry/createWalletProviderRegistry/createWalletProviderRegistry.ts
|
|
1433
|
+
/**
|
|
1434
|
+
* Creates a new wallet provider registry that manages wallet providers with priority-based registration.
|
|
1435
|
+
*
|
|
1436
|
+
* @returns The wallet provider registry instance
|
|
1437
|
+
*
|
|
1438
|
+
* @example
|
|
1439
|
+
* ```typescript
|
|
1440
|
+
* const registry = createWalletProviderRegistry();
|
|
1441
|
+
*
|
|
1442
|
+
* registry.register({
|
|
1443
|
+
* priority: WalletProviderPriority.WALLET_SDK,
|
|
1444
|
+
* walletProvider: myWalletProvider
|
|
1445
|
+
* });
|
|
1446
|
+
*
|
|
1447
|
+
* const provider = registry.getByKey('my-wallet-key');
|
|
1448
|
+
* const providers = registry.listProviders();
|
|
1449
|
+
* ```
|
|
1450
|
+
* @not-instrumented
|
|
1451
|
+
*/
|
|
1452
|
+
const createWalletProviderRegistry = (client) => {
|
|
1453
|
+
const registry = /* @__PURE__ */ new Map();
|
|
1454
|
+
return {
|
|
1455
|
+
getByKey: (key) => registry.get(key)?.walletProvider,
|
|
1456
|
+
listProviderEntries: () => Array.from(registry.values()),
|
|
1457
|
+
listProviders: () => Array.from(registry.values()).map((v) => v.walletProvider),
|
|
1458
|
+
register: (args) => {
|
|
1459
|
+
const existingEntry = registry.get(args.walletProvider.key);
|
|
1460
|
+
if (existingEntry) {
|
|
1461
|
+
if (existingEntry.priority < args.priority) {
|
|
1462
|
+
registry.set(args.walletProvider.key, args);
|
|
1463
|
+
emitEvent({
|
|
1464
|
+
args: { walletProviderKey: args.walletProvider.key },
|
|
1465
|
+
event: "walletProviderChanged"
|
|
1466
|
+
}, client);
|
|
1467
|
+
}
|
|
1468
|
+
} else {
|
|
1469
|
+
registry.set(args.walletProvider.key, args);
|
|
1470
|
+
emitEvent({
|
|
1471
|
+
args: { walletProvider: args.walletProvider },
|
|
1472
|
+
event: "walletProviderRegistered"
|
|
1473
|
+
}, client);
|
|
1474
|
+
emitEvent({
|
|
1475
|
+
args: { walletProviderKey: args.walletProvider.key },
|
|
1476
|
+
event: "walletProviderChanged"
|
|
1477
|
+
}, client);
|
|
1478
|
+
}
|
|
1479
|
+
},
|
|
1480
|
+
unregister: (key) => {
|
|
1481
|
+
registry.delete(key);
|
|
1482
|
+
emitEvent({
|
|
1483
|
+
args: { walletProviderKey: key },
|
|
1484
|
+
event: "walletProviderUnregistered"
|
|
1485
|
+
}, client);
|
|
1486
|
+
}
|
|
1487
|
+
};
|
|
1488
|
+
};
|
|
1489
|
+
|
|
1490
|
+
//#endregion
|
|
1491
|
+
//#region src/modules/wallets/walletProviderRegistry/getWalletProviderRegistry/getWalletProviderRegistry.ts
|
|
1492
|
+
/**
|
|
1493
|
+
* This function provides access to a shared instance of the wallet provider registry.
|
|
1494
|
+
*
|
|
1495
|
+
* It ensures that the same registry instance is used throughout the client to maintaining
|
|
1496
|
+
* consistency of registered wallet providers across different parts of the codebase.
|
|
1497
|
+
*
|
|
1498
|
+
* @returns The wallet provider registry instance
|
|
1499
|
+
*
|
|
1500
|
+
* @example
|
|
1501
|
+
* ```typescript
|
|
1502
|
+
* // Get the registry instance
|
|
1503
|
+
* const registry = getWalletProviderRegistry();
|
|
1504
|
+
*
|
|
1505
|
+
* // Register a wallet provider
|
|
1506
|
+
* registry.register({
|
|
1507
|
+
* priority: WalletProviderPriority.WALLET_SDK,
|
|
1508
|
+
* walletProvider: myWalletProvider
|
|
1509
|
+
* });
|
|
1510
|
+
*
|
|
1511
|
+
* // Retrieve a specific provider
|
|
1512
|
+
* const provider = registry.getByKey('metamaskevm');
|
|
1513
|
+
* ```
|
|
1514
|
+
*/
|
|
1515
|
+
const getWalletProviderRegistry = createRuntimeServiceAccessKey("walletProviderRegistry", (client) => createWalletProviderRegistry(client));
|
|
1516
|
+
|
|
1517
|
+
//#endregion
|
|
1518
|
+
//#region src/modules/wallets/walletProviderRegistry/walletProviderRegistry.types.ts
|
|
1519
|
+
let WalletProviderPriority = /* @__PURE__ */ function(WalletProviderPriority$1) {
|
|
1520
|
+
/**
|
|
1521
|
+
* Highest priority should be used by wallet providers that implement
|
|
1522
|
+
* the most reliable wallet integration.
|
|
1523
|
+
* example: The SDK provided by the wallet provider.
|
|
1524
|
+
*/
|
|
1525
|
+
WalletProviderPriority$1[WalletProviderPriority$1["WALLET_SDK"] = 100] = "WALLET_SDK";
|
|
1526
|
+
/**
|
|
1527
|
+
* Medium priority should be used by wallet providers that implement
|
|
1528
|
+
* a wallet integration via some reliable standard.
|
|
1529
|
+
* example: A wallet provider that uses EIP6963 announcement.
|
|
1530
|
+
*/
|
|
1531
|
+
WalletProviderPriority$1[WalletProviderPriority$1["WALLET_SELF_ANNOUNCEMENT_STANDARD"] = 50] = "WALLET_SELF_ANNOUNCEMENT_STANDARD";
|
|
1532
|
+
/**
|
|
1533
|
+
* Low priority should be used by wallet providers that implement
|
|
1534
|
+
* a wallet integration on a less reliable standard.
|
|
1535
|
+
* example: A wallet provider that uses window.ethereum, where the
|
|
1536
|
+
* window key can be overridden by other extensions.
|
|
1537
|
+
*/
|
|
1538
|
+
WalletProviderPriority$1[WalletProviderPriority$1["WINDOW_INJECT"] = 20] = "WINDOW_INJECT";
|
|
1539
|
+
return WalletProviderPriority$1;
|
|
1540
|
+
}({});
|
|
1541
|
+
|
|
1542
|
+
//#endregion
|
|
1543
|
+
//#region src/modules/wallets/utils/getWalletProviderFromWalletAccount/getWalletProviderFromWalletAccount.ts
|
|
1544
|
+
/** @not-instrumented */
|
|
1545
|
+
const getWalletProviderFromWalletAccount = ({ walletAccount }, client) => {
|
|
1546
|
+
const walletProvider = getWalletProviderRegistry(client).getByKey(walletAccount.walletProviderKey);
|
|
1547
|
+
if (!walletProvider) throw new NoWalletProviderFoundError({ walletProviderKey: walletAccount.walletProviderKey });
|
|
1548
|
+
return walletProvider;
|
|
1549
|
+
};
|
|
1550
|
+
|
|
1551
|
+
//#endregion
|
|
1552
|
+
//#region src/modules/auth/consts.ts
|
|
1553
|
+
const DYNAMIC_AUTH_COOKIE_NAME = "DYNAMIC_JWT_TOKEN";
|
|
1554
|
+
|
|
1123
1555
|
//#endregion
|
|
1124
1556
|
//#region src/constants.ts
|
|
1125
1557
|
const SDK_API_CORE_VERSION = dependencies["@dynamic-labs/sdk-api-core"];
|
|
@@ -1198,6 +1630,12 @@ Object.defineProperty(exports, 'DEFAULT_WAAS_BASE_MPC_RELAY_API_URL', {
|
|
|
1198
1630
|
return DEFAULT_WAAS_BASE_MPC_RELAY_API_URL;
|
|
1199
1631
|
}
|
|
1200
1632
|
});
|
|
1633
|
+
Object.defineProperty(exports, 'DYNAMIC_AUTH_COOKIE_NAME', {
|
|
1634
|
+
enumerable: true,
|
|
1635
|
+
get: function () {
|
|
1636
|
+
return DYNAMIC_AUTH_COOKIE_NAME;
|
|
1637
|
+
}
|
|
1638
|
+
});
|
|
1201
1639
|
Object.defineProperty(exports, 'DYNAMIC_ICONIC_SPRITE_URL', {
|
|
1202
1640
|
enumerable: true,
|
|
1203
1641
|
get: function () {
|
|
@@ -1228,6 +1666,12 @@ Object.defineProperty(exports, 'InvalidParamError', {
|
|
|
1228
1666
|
return InvalidParamError;
|
|
1229
1667
|
}
|
|
1230
1668
|
});
|
|
1669
|
+
Object.defineProperty(exports, 'InvalidWalletProviderKeyError', {
|
|
1670
|
+
enumerable: true,
|
|
1671
|
+
get: function () {
|
|
1672
|
+
return InvalidWalletProviderKeyError;
|
|
1673
|
+
}
|
|
1674
|
+
});
|
|
1231
1675
|
Object.defineProperty(exports, 'LinkCredentialError', {
|
|
1232
1676
|
enumerable: true,
|
|
1233
1677
|
get: function () {
|
|
@@ -1252,6 +1696,12 @@ Object.defineProperty(exports, 'NONCE_POOL_SIZE', {
|
|
|
1252
1696
|
return NONCE_POOL_SIZE;
|
|
1253
1697
|
}
|
|
1254
1698
|
});
|
|
1699
|
+
Object.defineProperty(exports, 'NoWalletProviderFoundError', {
|
|
1700
|
+
enumerable: true,
|
|
1701
|
+
get: function () {
|
|
1702
|
+
return NoWalletProviderFoundError;
|
|
1703
|
+
}
|
|
1704
|
+
});
|
|
1255
1705
|
Object.defineProperty(exports, 'SDK_API_CORE_VERSION', {
|
|
1256
1706
|
enumerable: true,
|
|
1257
1707
|
get: function () {
|
|
@@ -1276,6 +1726,12 @@ Object.defineProperty(exports, 'ValueMustBeDefinedError', {
|
|
|
1276
1726
|
return ValueMustBeDefinedError;
|
|
1277
1727
|
}
|
|
1278
1728
|
});
|
|
1729
|
+
Object.defineProperty(exports, 'WalletProviderPriority', {
|
|
1730
|
+
enumerable: true,
|
|
1731
|
+
get: function () {
|
|
1732
|
+
return WalletProviderPriority;
|
|
1733
|
+
}
|
|
1734
|
+
});
|
|
1279
1735
|
Object.defineProperty(exports, '__getElevatedAccessToken_wrapped', {
|
|
1280
1736
|
enumerable: true,
|
|
1281
1737
|
get: function () {
|
|
@@ -1300,6 +1756,18 @@ Object.defineProperty(exports, 'createDeviceSignatureHeadersMiddleware', {
|
|
|
1300
1756
|
return createDeviceSignatureHeadersMiddleware;
|
|
1301
1757
|
}
|
|
1302
1758
|
});
|
|
1759
|
+
Object.defineProperty(exports, 'createRuntimeServiceAccessKey', {
|
|
1760
|
+
enumerable: true,
|
|
1761
|
+
get: function () {
|
|
1762
|
+
return createRuntimeServiceAccessKey;
|
|
1763
|
+
}
|
|
1764
|
+
});
|
|
1765
|
+
Object.defineProperty(exports, 'emitEvent', {
|
|
1766
|
+
enumerable: true,
|
|
1767
|
+
get: function () {
|
|
1768
|
+
return emitEvent;
|
|
1769
|
+
}
|
|
1770
|
+
});
|
|
1303
1771
|
Object.defineProperty(exports, 'extractSessionId', {
|
|
1304
1772
|
enumerable: true,
|
|
1305
1773
|
get: function () {
|
|
@@ -1312,6 +1780,18 @@ Object.defineProperty(exports, 'fetchAndStoreNonces', {
|
|
|
1312
1780
|
return fetchAndStoreNonces;
|
|
1313
1781
|
}
|
|
1314
1782
|
});
|
|
1783
|
+
Object.defineProperty(exports, 'formatWalletAccountId', {
|
|
1784
|
+
enumerable: true,
|
|
1785
|
+
get: function () {
|
|
1786
|
+
return formatWalletAccountId;
|
|
1787
|
+
}
|
|
1788
|
+
});
|
|
1789
|
+
Object.defineProperty(exports, 'formatWalletProviderKey', {
|
|
1790
|
+
enumerable: true,
|
|
1791
|
+
get: function () {
|
|
1792
|
+
return formatWalletProviderKey;
|
|
1793
|
+
}
|
|
1794
|
+
});
|
|
1315
1795
|
Object.defineProperty(exports, 'getChainFromVerifiedCredentialChain', {
|
|
1316
1796
|
enumerable: true,
|
|
1317
1797
|
get: function () {
|
|
@@ -1360,6 +1840,30 @@ Object.defineProperty(exports, 'getUserAgent', {
|
|
|
1360
1840
|
return getUserAgent;
|
|
1361
1841
|
}
|
|
1362
1842
|
});
|
|
1843
|
+
Object.defineProperty(exports, 'getWalletAccounts', {
|
|
1844
|
+
enumerable: true,
|
|
1845
|
+
get: function () {
|
|
1846
|
+
return getWalletAccounts;
|
|
1847
|
+
}
|
|
1848
|
+
});
|
|
1849
|
+
Object.defineProperty(exports, 'getWalletAccountsFromState', {
|
|
1850
|
+
enumerable: true,
|
|
1851
|
+
get: function () {
|
|
1852
|
+
return getWalletAccountsFromState;
|
|
1853
|
+
}
|
|
1854
|
+
});
|
|
1855
|
+
Object.defineProperty(exports, 'getWalletProviderFromWalletAccount', {
|
|
1856
|
+
enumerable: true,
|
|
1857
|
+
get: function () {
|
|
1858
|
+
return getWalletProviderFromWalletAccount;
|
|
1859
|
+
}
|
|
1860
|
+
});
|
|
1861
|
+
Object.defineProperty(exports, 'getWalletProviderRegistry', {
|
|
1862
|
+
enumerable: true,
|
|
1863
|
+
get: function () {
|
|
1864
|
+
return getWalletProviderRegistry;
|
|
1865
|
+
}
|
|
1866
|
+
});
|
|
1363
1867
|
Object.defineProperty(exports, 'instrumentFunction', {
|
|
1364
1868
|
enumerable: true,
|
|
1365
1869
|
get: function () {
|
|
@@ -1378,6 +1882,36 @@ Object.defineProperty(exports, 'name', {
|
|
|
1378
1882
|
return name;
|
|
1379
1883
|
}
|
|
1380
1884
|
});
|
|
1885
|
+
Object.defineProperty(exports, 'normalizeAddress', {
|
|
1886
|
+
enumerable: true,
|
|
1887
|
+
get: function () {
|
|
1888
|
+
return normalizeAddress;
|
|
1889
|
+
}
|
|
1890
|
+
});
|
|
1891
|
+
Object.defineProperty(exports, 'normalizeWalletNameWithChain', {
|
|
1892
|
+
enumerable: true,
|
|
1893
|
+
get: function () {
|
|
1894
|
+
return normalizeWalletNameWithChain;
|
|
1895
|
+
}
|
|
1896
|
+
});
|
|
1897
|
+
Object.defineProperty(exports, 'offEvent', {
|
|
1898
|
+
enumerable: true,
|
|
1899
|
+
get: function () {
|
|
1900
|
+
return offEvent;
|
|
1901
|
+
}
|
|
1902
|
+
});
|
|
1903
|
+
Object.defineProperty(exports, 'onEvent', {
|
|
1904
|
+
enumerable: true,
|
|
1905
|
+
get: function () {
|
|
1906
|
+
return onEvent;
|
|
1907
|
+
}
|
|
1908
|
+
});
|
|
1909
|
+
Object.defineProperty(exports, 'onceEvent', {
|
|
1910
|
+
enumerable: true,
|
|
1911
|
+
get: function () {
|
|
1912
|
+
return onceEvent;
|
|
1913
|
+
}
|
|
1914
|
+
});
|
|
1381
1915
|
Object.defineProperty(exports, 'randomString', {
|
|
1382
1916
|
enumerable: true,
|
|
1383
1917
|
get: function () {
|
|
@@ -1390,16 +1924,28 @@ Object.defineProperty(exports, 'scrubParameters', {
|
|
|
1390
1924
|
return scrubParameters;
|
|
1391
1925
|
}
|
|
1392
1926
|
});
|
|
1927
|
+
Object.defineProperty(exports, 'setCookie', {
|
|
1928
|
+
enumerable: true,
|
|
1929
|
+
get: function () {
|
|
1930
|
+
return setCookie;
|
|
1931
|
+
}
|
|
1932
|
+
});
|
|
1393
1933
|
Object.defineProperty(exports, 'setDefaultClient', {
|
|
1394
1934
|
enumerable: true,
|
|
1395
1935
|
get: function () {
|
|
1396
1936
|
return setDefaultClient;
|
|
1397
1937
|
}
|
|
1398
1938
|
});
|
|
1939
|
+
Object.defineProperty(exports, 'splitWalletProviderKey', {
|
|
1940
|
+
enumerable: true,
|
|
1941
|
+
get: function () {
|
|
1942
|
+
return splitWalletProviderKey;
|
|
1943
|
+
}
|
|
1944
|
+
});
|
|
1399
1945
|
Object.defineProperty(exports, 'version', {
|
|
1400
1946
|
enumerable: true,
|
|
1401
1947
|
get: function () {
|
|
1402
1948
|
return version;
|
|
1403
1949
|
}
|
|
1404
1950
|
});
|
|
1405
|
-
//# sourceMappingURL=InvalidParamError-
|
|
1951
|
+
//# sourceMappingURL=InvalidParamError-DGBih-LJ.cjs.map
|