@ledgerhq/vault-cli 0.67.1 → 0.68.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.
- package/bin/commands/index.d.ts +7 -0
- package/bin/commands/send.d.ts +10 -0
- package/bin/commands/send.js +15 -2
- package/bin/commands/send.js.map +1 -1
- package/package.json +4 -4
package/bin/commands/index.d.ts
CHANGED
|
@@ -464,6 +464,13 @@ declare const _default: {
|
|
|
464
464
|
type: StringConstructor;
|
|
465
465
|
description: string;
|
|
466
466
|
required: boolean;
|
|
467
|
+
defaultValue?: undefined;
|
|
468
|
+
} | {
|
|
469
|
+
name: string;
|
|
470
|
+
description: string;
|
|
471
|
+
type: StringConstructor;
|
|
472
|
+
defaultValue: string;
|
|
473
|
+
required?: undefined;
|
|
467
474
|
})[];
|
|
468
475
|
run: (options: import("./send").SendOpts) => Promise<void>;
|
|
469
476
|
} | {
|
package/bin/commands/send.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { GateTransactionType } from "@ledgerhq/vault-common";
|
|
1
2
|
import { GateOptions } from "../types";
|
|
2
3
|
export interface SendOpts extends GateOptions {
|
|
3
4
|
noApproval: boolean;
|
|
@@ -5,7 +6,9 @@ export interface SendOpts extends GateOptions {
|
|
|
5
6
|
account: string;
|
|
6
7
|
recipient: string;
|
|
7
8
|
amount: string;
|
|
9
|
+
feesLevel: "SLOW" | "NORMAL" | "FAST";
|
|
8
10
|
contractPayload?: string;
|
|
11
|
+
txType?: GateTransactionType;
|
|
9
12
|
}
|
|
10
13
|
declare function sendTransaction(options: SendOpts): Promise<void>;
|
|
11
14
|
declare const _default: {
|
|
@@ -28,6 +31,13 @@ declare const _default: {
|
|
|
28
31
|
type: StringConstructor;
|
|
29
32
|
description: string;
|
|
30
33
|
required: boolean;
|
|
34
|
+
defaultValue?: undefined;
|
|
35
|
+
} | {
|
|
36
|
+
name: string;
|
|
37
|
+
description: string;
|
|
38
|
+
type: StringConstructor;
|
|
39
|
+
defaultValue: string;
|
|
40
|
+
required?: undefined;
|
|
31
41
|
})[];
|
|
32
42
|
run: typeof sendTransaction;
|
|
33
43
|
};
|
package/bin/commands/send.js
CHANGED
|
@@ -32,6 +32,8 @@ function sendTransaction(options) {
|
|
|
32
32
|
account: options.account,
|
|
33
33
|
recipient: options.recipient,
|
|
34
34
|
amount: options.amount,
|
|
35
|
+
transactionType: options.txType,
|
|
36
|
+
feesLevel: options.feesLevel,
|
|
35
37
|
};
|
|
36
38
|
if (options.strategy) {
|
|
37
39
|
Object.assign(transaction, {
|
|
@@ -90,13 +92,19 @@ exports.default = {
|
|
|
90
92
|
name: "recipient",
|
|
91
93
|
description: "Address of the recipient",
|
|
92
94
|
type: String,
|
|
93
|
-
|
|
95
|
+
defaultValue: "",
|
|
94
96
|
},
|
|
95
97
|
{
|
|
96
98
|
name: "amount",
|
|
97
99
|
description: "Amount in default unit (e.g in BTC for Bitcoin)",
|
|
98
100
|
type: String,
|
|
99
|
-
|
|
101
|
+
defaultValue: "0",
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
name: "feesLevel",
|
|
105
|
+
description: "Fees level (SLOW|NORMAL|FAST)",
|
|
106
|
+
type: String,
|
|
107
|
+
defaultValue: "NORMAL",
|
|
100
108
|
},
|
|
101
109
|
{
|
|
102
110
|
name: "noApproval",
|
|
@@ -113,6 +121,11 @@ exports.default = {
|
|
|
113
121
|
type: String,
|
|
114
122
|
description: "Raw hex smart-contract input (only for Ethereum account types)",
|
|
115
123
|
},
|
|
124
|
+
{
|
|
125
|
+
name: "txType",
|
|
126
|
+
type: String,
|
|
127
|
+
description: "Transaction type (SEND|RECEIVE|PREBURN|BURN|MINT|DELEGATE|UNDELEGATE)",
|
|
128
|
+
},
|
|
116
129
|
...gateOptions_1.default,
|
|
117
130
|
],
|
|
118
131
|
run: sendTransaction,
|
package/bin/commands/send.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"send.js","sourceRoot":"","sources":["../../src/commands/send.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"send.js","sourceRoot":"","sources":["../../src/commands/send.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,yDAMgC;AAGhC,uDAA+B;AAC/B,iEAAyC;AACzC,oCAAwC;AAaxC,SAAe,eAAe,CAAC,OAAiB;;QAE9C,MAAM,IAAI,GAAG,gCAAiB,CAAC,OAAO,CAAC,CAAC;QAExC,MAAM,MAAM,GAAG,MAAM,6BAAc,CAAC,IAAI,CAAC,CAAC;QAC1C,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,MAAM,CAAC;QAErC,IAAI,CAAC,QAAQ,CAAC,QAAQ,EAAE;YACtB,MAAM,IAAI,KAAK,CAAC,mBAAmB,CAAC,CAAC;SACtC;QAED,MAAM,OAAO,GAAG,QAAQ,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;QAE1E,IAAI,CAAC,OAAO,EAAE;YACZ,MAAM,IAAI,KAAK,CAAC,YAAY,OAAO,CAAC,OAAO,aAAa,CAAC,CAAC;SAC3D;QAED,MAAM,WAAW,GAAG;YAClB,OAAO,EAAE,OAAO,CAAC,OAAO;YACxB,SAAS,EAAE,OAAO,CAAC,SAAS;YAC5B,MAAM,EAAE,OAAO,CAAC,MAAM;YACtB,eAAe,EAAE,OAAO,CAAC,MAAM;YAC/B,SAAS,EAAE,OAAO,CAAC,SAAS;SAC7B,CAAC;QAEF,IAAI,OAAO,CAAC,QAAQ,EAAE;YACpB,MAAM,CAAC,MAAM,CAAC,WAAW,EAAE;gBACzB,oBAAoB,EAAE,OAAO,CAAC,QAAQ;aACvC,CAAC,CAAC;SACJ;QAED,IAAI,OAAO,CAAC,eAAe,EAAE;YAC3B,IAAI,CAAC,wBAAwB,CAAC,OAAO,CAAC,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MAAM;YACZ,YAAY,EAAE,EAAE;SACjB;QACD;YACE,IAAI,EAAE,QAAQ;YACd,WAAW,EAAE,iDAAiD;YAC9D,IAAI,EAAE,MAAM;YACZ,YAAY,EAAE,GAAG;SAClB;QACD;YACE,IAAI,EAAE,WAAW;YACjB,WAAW,EAAE,+BAA+B;YAC5C,IAAI,EAAE,MAAM;YACZ,YAAY,EAAE,QAAQ;SACvB;QACD;YACE,IAAI,EAAE,YAAY;YAClB,IAAI,EAAE,OAAO;YACb,WAAW,EAAE,6CAA6C;SAC3D;QACD;YACE,IAAI,EAAE,UAAU;YAChB,IAAI,EAAE,MAAM;YACZ,WAAW,EACT,+EAA+E;SAClF;QACD;YACE,IAAI,EAAE,iBAAiB;YACvB,IAAI,EAAE,MAAM;YACZ,WAAW,EACT,gEAAgE;SACnE;QACD;YACE,IAAI,EAAE,QAAQ;YACd,IAAI,EAAE,MAAM;YACZ,WAAW,EACT,uEAAuE;SAC1E;QACD,GAAG,qBAAW;KACf;IACD,GAAG,EAAE,eAAe;CACrB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ledgerhq/vault-cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.68.0",
|
|
4
4
|
"description": "> TODO: description",
|
|
5
5
|
"homepage": "https://github.com/LedgerHQ/vault-js",
|
|
6
6
|
"license": "BSD-2-Clause",
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"@ledgerhq/cryptoassets": "^5.51.0",
|
|
24
|
-
"@ledgerhq/live-common-stub": "^0.
|
|
25
|
-
"@ledgerhq/vault-common": "^0.
|
|
24
|
+
"@ledgerhq/live-common-stub": "^0.68.0",
|
|
25
|
+
"@ledgerhq/vault-common": "^0.68.0",
|
|
26
26
|
"axios": "^0.21.0",
|
|
27
27
|
"bignumber.js": "^9.0.1",
|
|
28
28
|
"body-parser": "^1.19.0",
|
|
@@ -48,5 +48,5 @@
|
|
|
48
48
|
"@types/node": "^15.0.2",
|
|
49
49
|
"@types/progress": "^2.0.3"
|
|
50
50
|
},
|
|
51
|
-
"gitHead": "
|
|
51
|
+
"gitHead": "d8e42122ef9ee21d9019d201be3f970a06c7e8b2"
|
|
52
52
|
}
|