@injectivelabs/wallet-private-key 1.15.30 → 1.15.32
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.
|
@@ -9,7 +9,7 @@ export declare class PrivateKeyWallet extends BaseConcreteStrategy implements Co
|
|
|
9
9
|
disconnect(): Promise<void>;
|
|
10
10
|
getAddresses(): Promise<string[]>;
|
|
11
11
|
getSessionOrConfirm(address: AccountAddress): Promise<string>;
|
|
12
|
-
|
|
12
|
+
sendEvmTransaction(_transaction: unknown, _options: {
|
|
13
13
|
address: AccountAddress;
|
|
14
14
|
ethereumChainId: EthereumChainId;
|
|
15
15
|
}): Promise<string>;
|
|
@@ -27,7 +27,7 @@ export declare class PrivateKeyWallet extends BaseConcreteStrategy implements Co
|
|
|
27
27
|
}): Promise<DirectSignResponse>;
|
|
28
28
|
signArbitrary(signer: AccountAddress, data: string | Uint8Array): Promise<string>;
|
|
29
29
|
getEthereumChainId(): Promise<string>;
|
|
30
|
-
|
|
30
|
+
getEvmTransactionReceipt(_txHash: string): Promise<string>;
|
|
31
31
|
getPubKey(): Promise<string>;
|
|
32
32
|
onChainIdChanged(_callback: (chain: string) => void): Promise<void>;
|
|
33
33
|
onAccountChange(_callback: (account: AccountAddress | string[]) => void): Promise<void>;
|
|
@@ -35,11 +35,11 @@ class PrivateKeyWallet extends wallet_base_1.BaseConcreteStrategy {
|
|
|
35
35
|
async getSessionOrConfirm(address) {
|
|
36
36
|
return Promise.resolve(`0x${Buffer.from(`Confirmation for ${address} at time: ${Date.now()}`).toString('hex')}`);
|
|
37
37
|
}
|
|
38
|
-
async
|
|
38
|
+
async sendEvmTransaction(_transaction, _options) {
|
|
39
39
|
throw new exceptions_1.WalletException(new Error('This wallet does not support sending Ethereum transactions'), {
|
|
40
40
|
code: exceptions_1.UnspecifiedErrorCode,
|
|
41
41
|
type: exceptions_1.ErrorType.WalletError,
|
|
42
|
-
contextModule: wallet_base_1.WalletAction.
|
|
42
|
+
contextModule: wallet_base_1.WalletAction.SendEvmTransaction,
|
|
43
43
|
});
|
|
44
44
|
}
|
|
45
45
|
async sendTransaction(transaction, options) {
|
|
@@ -129,7 +129,7 @@ class PrivateKeyWallet extends wallet_base_1.BaseConcreteStrategy {
|
|
|
129
129
|
});
|
|
130
130
|
}
|
|
131
131
|
}
|
|
132
|
-
async
|
|
132
|
+
async getEvmTransactionReceipt(_txHash) {
|
|
133
133
|
throw new exceptions_1.WalletException(new Error('Not supported'));
|
|
134
134
|
}
|
|
135
135
|
// eslint-disable-next-line class-methods-use-this
|
|
@@ -9,7 +9,7 @@ export declare class PrivateKeyWallet extends BaseConcreteStrategy implements Co
|
|
|
9
9
|
disconnect(): Promise<void>;
|
|
10
10
|
getAddresses(): Promise<string[]>;
|
|
11
11
|
getSessionOrConfirm(address: AccountAddress): Promise<string>;
|
|
12
|
-
|
|
12
|
+
sendEvmTransaction(_transaction: unknown, _options: {
|
|
13
13
|
address: AccountAddress;
|
|
14
14
|
ethereumChainId: EthereumChainId;
|
|
15
15
|
}): Promise<string>;
|
|
@@ -27,7 +27,7 @@ export declare class PrivateKeyWallet extends BaseConcreteStrategy implements Co
|
|
|
27
27
|
}): Promise<DirectSignResponse>;
|
|
28
28
|
signArbitrary(signer: AccountAddress, data: string | Uint8Array): Promise<string>;
|
|
29
29
|
getEthereumChainId(): Promise<string>;
|
|
30
|
-
|
|
30
|
+
getEvmTransactionReceipt(_txHash: string): Promise<string>;
|
|
31
31
|
getPubKey(): Promise<string>;
|
|
32
32
|
onChainIdChanged(_callback: (chain: string) => void): Promise<void>;
|
|
33
33
|
onAccountChange(_callback: (account: AccountAddress | string[]) => void): Promise<void>;
|
|
@@ -32,11 +32,11 @@ export class PrivateKeyWallet extends BaseConcreteStrategy {
|
|
|
32
32
|
async getSessionOrConfirm(address) {
|
|
33
33
|
return Promise.resolve(`0x${Buffer.from(`Confirmation for ${address} at time: ${Date.now()}`).toString('hex')}`);
|
|
34
34
|
}
|
|
35
|
-
async
|
|
35
|
+
async sendEvmTransaction(_transaction, _options) {
|
|
36
36
|
throw new WalletException(new Error('This wallet does not support sending Ethereum transactions'), {
|
|
37
37
|
code: UnspecifiedErrorCode,
|
|
38
38
|
type: ErrorType.WalletError,
|
|
39
|
-
contextModule: WalletAction.
|
|
39
|
+
contextModule: WalletAction.SendEvmTransaction,
|
|
40
40
|
});
|
|
41
41
|
}
|
|
42
42
|
async sendTransaction(transaction, options) {
|
|
@@ -126,7 +126,7 @@ export class PrivateKeyWallet extends BaseConcreteStrategy {
|
|
|
126
126
|
});
|
|
127
127
|
}
|
|
128
128
|
}
|
|
129
|
-
async
|
|
129
|
+
async getEvmTransactionReceipt(_txHash) {
|
|
130
130
|
throw new WalletException(new Error('Not supported'));
|
|
131
131
|
}
|
|
132
132
|
// eslint-disable-next-line class-methods-use-this
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@injectivelabs/wallet-private-key",
|
|
3
3
|
"description": "Private key wallet strategy for use with @injectivelabs/wallet-core.",
|
|
4
|
-
"version": "1.15.
|
|
4
|
+
"version": "1.15.32",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"type": "module",
|
|
7
7
|
"author": {
|
|
@@ -56,12 +56,12 @@
|
|
|
56
56
|
"start": "node dist/index.js"
|
|
57
57
|
},
|
|
58
58
|
"dependencies": {
|
|
59
|
-
"@injectivelabs/exceptions": "^1.15.
|
|
60
|
-
"@injectivelabs/sdk-ts": "^1.15.
|
|
61
|
-
"@injectivelabs/ts-types": "^1.15.
|
|
62
|
-
"@injectivelabs/wallet-base": "^1.15.
|
|
59
|
+
"@injectivelabs/exceptions": "^1.15.29",
|
|
60
|
+
"@injectivelabs/sdk-ts": "^1.15.32",
|
|
61
|
+
"@injectivelabs/ts-types": "^1.15.30",
|
|
62
|
+
"@injectivelabs/wallet-base": "^1.15.32"
|
|
63
63
|
},
|
|
64
|
-
"gitHead": "
|
|
64
|
+
"gitHead": "e8fa12c489c4b3432579c5df30fd6f939d57b442",
|
|
65
65
|
"typedoc": {
|
|
66
66
|
"entryPoint": "./src/index.ts",
|
|
67
67
|
"readmeFile": "./README.md",
|