@injectivelabs/wallet-strategy 1.20.11 → 1.20.13
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/dist/cjs/index.cjs +6 -0
- package/dist/esm/index.js +6 -0
- package/package.json +12 -12
package/dist/cjs/index.cjs
CHANGED
|
@@ -11,6 +11,7 @@ let cachedPrivateKeyStrategy = null;
|
|
|
11
11
|
let cachedTurnkeyStrategy = null;
|
|
12
12
|
let cachedMagicStrategy = null;
|
|
13
13
|
let cachedWalletConnectStrategy = null;
|
|
14
|
+
let cachedPrivateKeyCosmosStrategy = null;
|
|
14
15
|
const loadEvmStrategy = async () => {
|
|
15
16
|
if (!cachedEvmStrategy) cachedEvmStrategy = (await import("@injectivelabs/wallet-evm")).EvmWalletStrategy;
|
|
16
17
|
return cachedEvmStrategy;
|
|
@@ -43,6 +44,10 @@ const loadPrivateKeyStrategy = async () => {
|
|
|
43
44
|
if (!cachedPrivateKeyStrategy) cachedPrivateKeyStrategy = (await import("@injectivelabs/wallet-private-key")).PrivateKeyWalletStrategy;
|
|
44
45
|
return cachedPrivateKeyStrategy;
|
|
45
46
|
};
|
|
47
|
+
const loadPrivateKeyCosmosStrategy = async () => {
|
|
48
|
+
if (!cachedPrivateKeyCosmosStrategy) cachedPrivateKeyCosmosStrategy = (await import("@injectivelabs/wallet-private-key")).PrivateKeyCosmosWalletStrategy;
|
|
49
|
+
return cachedPrivateKeyCosmosStrategy;
|
|
50
|
+
};
|
|
46
51
|
const loadTurnkeyStrategy = async () => {
|
|
47
52
|
if (!cachedTurnkeyStrategy) cachedTurnkeyStrategy = (await import("@injectivelabs/wallet-turnkey")).TurnkeyWalletStrategy;
|
|
48
53
|
return cachedTurnkeyStrategy;
|
|
@@ -163,6 +168,7 @@ const createStrategy = async ({ args, wallet, emitter }) => {
|
|
|
163
168
|
return new TrezorBip44Strategy(ethWalletArgs);
|
|
164
169
|
}
|
|
165
170
|
case __injectivelabs_wallet_base_light.Wallet.PrivateKey: return new (await (loadPrivateKeyStrategy()))(ethWalletArgs);
|
|
171
|
+
case __injectivelabs_wallet_base_light.Wallet.PrivateKeyCosmos: return new (await (loadPrivateKeyCosmosStrategy()))(cosmosWalletArgs);
|
|
166
172
|
case __injectivelabs_wallet_base_light.Wallet.Turnkey:
|
|
167
173
|
var _args$metadata;
|
|
168
174
|
if (!((_args$metadata = args.metadata) === null || _args$metadata === void 0 || (_args$metadata = _args$metadata.turnkey) === null || _args$metadata === void 0 ? void 0 : _args$metadata.defaultOrganizationId)) return;
|
package/dist/esm/index.js
CHANGED
|
@@ -11,6 +11,7 @@ let cachedPrivateKeyStrategy = null;
|
|
|
11
11
|
let cachedTurnkeyStrategy = null;
|
|
12
12
|
let cachedMagicStrategy = null;
|
|
13
13
|
let cachedWalletConnectStrategy = null;
|
|
14
|
+
let cachedPrivateKeyCosmosStrategy = null;
|
|
14
15
|
const loadEvmStrategy = async () => {
|
|
15
16
|
if (!cachedEvmStrategy) cachedEvmStrategy = (await import("@injectivelabs/wallet-evm")).EvmWalletStrategy;
|
|
16
17
|
return cachedEvmStrategy;
|
|
@@ -43,6 +44,10 @@ const loadPrivateKeyStrategy = async () => {
|
|
|
43
44
|
if (!cachedPrivateKeyStrategy) cachedPrivateKeyStrategy = (await import("@injectivelabs/wallet-private-key")).PrivateKeyWalletStrategy;
|
|
44
45
|
return cachedPrivateKeyStrategy;
|
|
45
46
|
};
|
|
47
|
+
const loadPrivateKeyCosmosStrategy = async () => {
|
|
48
|
+
if (!cachedPrivateKeyCosmosStrategy) cachedPrivateKeyCosmosStrategy = (await import("@injectivelabs/wallet-private-key")).PrivateKeyCosmosWalletStrategy;
|
|
49
|
+
return cachedPrivateKeyCosmosStrategy;
|
|
50
|
+
};
|
|
46
51
|
const loadTurnkeyStrategy = async () => {
|
|
47
52
|
if (!cachedTurnkeyStrategy) cachedTurnkeyStrategy = (await import("@injectivelabs/wallet-turnkey")).TurnkeyWalletStrategy;
|
|
48
53
|
return cachedTurnkeyStrategy;
|
|
@@ -163,6 +168,7 @@ const createStrategy = async ({ args, wallet, emitter }) => {
|
|
|
163
168
|
return new TrezorBip44Strategy(ethWalletArgs);
|
|
164
169
|
}
|
|
165
170
|
case Wallet.PrivateKey: return new (await (loadPrivateKeyStrategy()))(ethWalletArgs);
|
|
171
|
+
case Wallet.PrivateKeyCosmos: return new (await (loadPrivateKeyCosmosStrategy()))(cosmosWalletArgs);
|
|
166
172
|
case Wallet.Turnkey:
|
|
167
173
|
var _args$metadata;
|
|
168
174
|
if (!((_args$metadata = args.metadata) === null || _args$metadata === void 0 || (_args$metadata = _args$metadata.turnkey) === null || _args$metadata === void 0 ? void 0 : _args$metadata.defaultOrganizationId)) return;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@injectivelabs/wallet-strategy",
|
|
3
|
-
"version": "1.20.
|
|
3
|
+
"version": "1.20.13",
|
|
4
4
|
"description": "Wallet strategy with instantiated wallets",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": {
|
|
@@ -42,17 +42,17 @@
|
|
|
42
42
|
"dist"
|
|
43
43
|
],
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@injectivelabs/
|
|
46
|
-
"@injectivelabs/wallet-
|
|
47
|
-
"@injectivelabs/wallet-
|
|
48
|
-
"@injectivelabs/
|
|
49
|
-
"@injectivelabs/wallet-
|
|
50
|
-
"@injectivelabs/wallet-
|
|
51
|
-
"@injectivelabs/wallet-magic": "1.20.
|
|
52
|
-
"@injectivelabs/wallet-private-key": "1.20.
|
|
53
|
-
"@injectivelabs/wallet-trezor": "1.20.
|
|
54
|
-
"@injectivelabs/wallet-turnkey": "1.20.
|
|
55
|
-
"@injectivelabs/wallet-wallet-connect": "1.20.
|
|
45
|
+
"@injectivelabs/wallet-base": "1.20.13",
|
|
46
|
+
"@injectivelabs/wallet-core": "1.20.13",
|
|
47
|
+
"@injectivelabs/wallet-cosmos": "1.20.13",
|
|
48
|
+
"@injectivelabs/exceptions": "1.20.13",
|
|
49
|
+
"@injectivelabs/wallet-ledger": "1.20.13",
|
|
50
|
+
"@injectivelabs/wallet-evm": "1.20.13",
|
|
51
|
+
"@injectivelabs/wallet-magic": "1.20.13",
|
|
52
|
+
"@injectivelabs/wallet-private-key": "1.20.13",
|
|
53
|
+
"@injectivelabs/wallet-trezor": "1.20.13",
|
|
54
|
+
"@injectivelabs/wallet-turnkey": "1.20.13",
|
|
55
|
+
"@injectivelabs/wallet-wallet-connect": "1.20.13"
|
|
56
56
|
},
|
|
57
57
|
"publishConfig": {
|
|
58
58
|
"access": "public"
|