@trustwallet/wallet-core 3.1.20 → 3.1.22
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.
@@ -11046,6 +11046,12 @@ export namespace TW {
|
|
11046
11046
|
/** Namespace Proto. */
|
11047
11047
|
namespace Proto {
|
11048
11048
|
|
11049
|
+
/** DerivationType enum. */
|
11050
|
+
enum DerivationType {
|
11051
|
+
SECP256K1 = 0,
|
11052
|
+
DELEGATED = 1
|
11053
|
+
}
|
11054
|
+
|
11049
11055
|
/** Properties of a SigningInput. */
|
11050
11056
|
interface ISigningInput {
|
11051
11057
|
|
@@ -11069,6 +11075,12 @@ export namespace TW {
|
|
11069
11075
|
|
11070
11076
|
/** SigningInput gasPremium */
|
11071
11077
|
gasPremium?: (Uint8Array|null);
|
11078
|
+
|
11079
|
+
/** SigningInput params */
|
11080
|
+
params?: (Uint8Array|null);
|
11081
|
+
|
11082
|
+
/** SigningInput derivation */
|
11083
|
+
derivation?: (TW.Filecoin.Proto.DerivationType|null);
|
11072
11084
|
}
|
11073
11085
|
|
11074
11086
|
/** Represents a SigningInput. */
|
@@ -11101,6 +11113,12 @@ export namespace TW {
|
|
11101
11113
|
/** SigningInput gasPremium. */
|
11102
11114
|
public gasPremium: Uint8Array;
|
11103
11115
|
|
11116
|
+
/** SigningInput params. */
|
11117
|
+
public params: Uint8Array;
|
11118
|
+
|
11119
|
+
/** SigningInput derivation. */
|
11120
|
+
public derivation: TW.Filecoin.Proto.DerivationType;
|
11121
|
+
|
11104
11122
|
/**
|
11105
11123
|
* Creates a new SigningInput instance using the specified properties.
|
11106
11124
|
* @param [properties] Properties to set
|
@@ -11160,6 +11178,9 @@ export namespace TW {
|
|
11160
11178
|
|
11161
11179
|
/** SigningOutput json */
|
11162
11180
|
json?: (string|null);
|
11181
|
+
|
11182
|
+
/** SigningOutput errorMessage */
|
11183
|
+
errorMessage?: (string|null);
|
11163
11184
|
}
|
11164
11185
|
|
11165
11186
|
/** Represents a SigningOutput. */
|
@@ -11174,6 +11195,9 @@ export namespace TW {
|
|
11174
11195
|
/** SigningOutput json. */
|
11175
11196
|
public json: string;
|
11176
11197
|
|
11198
|
+
/** SigningOutput errorMessage. */
|
11199
|
+
public errorMessage: string;
|
11200
|
+
|
11177
11201
|
/**
|
11178
11202
|
* Creates a new SigningOutput instance using the specified properties.
|
11179
11203
|
* @param [properties] Properties to set
|
@@ -29342,6 +29366,9 @@ export namespace TW {
|
|
29342
29366
|
|
29343
29367
|
/** SigningInput privateKey */
|
29344
29368
|
privateKey?: (Uint8Array|null);
|
29369
|
+
|
29370
|
+
/** SigningInput txId */
|
29371
|
+
txId?: (string|null);
|
29345
29372
|
}
|
29346
29373
|
|
29347
29374
|
/** Represents a SigningInput. */
|
@@ -29359,6 +29386,9 @@ export namespace TW {
|
|
29359
29386
|
/** SigningInput privateKey. */
|
29360
29387
|
public privateKey: Uint8Array;
|
29361
29388
|
|
29389
|
+
/** SigningInput txId. */
|
29390
|
+
public txId: string;
|
29391
|
+
|
29362
29392
|
/**
|
29363
29393
|
* Creates a new SigningInput instance using the specified properties.
|
29364
29394
|
* @param [properties] Properties to set
|
@@ -32720,6 +32720,20 @@
|
|
32720
32720
|
*/
|
32721
32721
|
var Proto = {};
|
32722
32722
|
|
32723
|
+
/**
|
32724
|
+
* DerivationType enum.
|
32725
|
+
* @name TW.Filecoin.Proto.DerivationType
|
32726
|
+
* @enum {number}
|
32727
|
+
* @property {number} SECP256K1=0 SECP256K1 value
|
32728
|
+
* @property {number} DELEGATED=1 DELEGATED value
|
32729
|
+
*/
|
32730
|
+
Proto.DerivationType = (function() {
|
32731
|
+
var valuesById = {}, values = Object.create(valuesById);
|
32732
|
+
values[valuesById[0] = "SECP256K1"] = 0;
|
32733
|
+
values[valuesById[1] = "DELEGATED"] = 1;
|
32734
|
+
return values;
|
32735
|
+
})();
|
32736
|
+
|
32723
32737
|
Proto.SigningInput = (function() {
|
32724
32738
|
|
32725
32739
|
/**
|
@@ -32733,6 +32747,8 @@
|
|
32733
32747
|
* @property {Long|null} [gasLimit] SigningInput gasLimit
|
32734
32748
|
* @property {Uint8Array|null} [gasFeeCap] SigningInput gasFeeCap
|
32735
32749
|
* @property {Uint8Array|null} [gasPremium] SigningInput gasPremium
|
32750
|
+
* @property {Uint8Array|null} [params] SigningInput params
|
32751
|
+
* @property {TW.Filecoin.Proto.DerivationType|null} [derivation] SigningInput derivation
|
32736
32752
|
*/
|
32737
32753
|
|
32738
32754
|
/**
|
@@ -32806,6 +32822,22 @@
|
|
32806
32822
|
*/
|
32807
32823
|
SigningInput.prototype.gasPremium = $util.newBuffer([]);
|
32808
32824
|
|
32825
|
+
/**
|
32826
|
+
* SigningInput params.
|
32827
|
+
* @member {Uint8Array} params
|
32828
|
+
* @memberof TW.Filecoin.Proto.SigningInput
|
32829
|
+
* @instance
|
32830
|
+
*/
|
32831
|
+
SigningInput.prototype.params = $util.newBuffer([]);
|
32832
|
+
|
32833
|
+
/**
|
32834
|
+
* SigningInput derivation.
|
32835
|
+
* @member {TW.Filecoin.Proto.DerivationType} derivation
|
32836
|
+
* @memberof TW.Filecoin.Proto.SigningInput
|
32837
|
+
* @instance
|
32838
|
+
*/
|
32839
|
+
SigningInput.prototype.derivation = 0;
|
32840
|
+
|
32809
32841
|
/**
|
32810
32842
|
* Creates a new SigningInput instance using the specified properties.
|
32811
32843
|
* @function create
|
@@ -32844,6 +32876,10 @@
|
|
32844
32876
|
writer.uint32(/* id 6, wireType 2 =*/50).bytes(message.gasFeeCap);
|
32845
32877
|
if (message.gasPremium != null && Object.hasOwnProperty.call(message, "gasPremium"))
|
32846
32878
|
writer.uint32(/* id 7, wireType 2 =*/58).bytes(message.gasPremium);
|
32879
|
+
if (message.params != null && Object.hasOwnProperty.call(message, "params"))
|
32880
|
+
writer.uint32(/* id 8, wireType 2 =*/66).bytes(message.params);
|
32881
|
+
if (message.derivation != null && Object.hasOwnProperty.call(message, "derivation"))
|
32882
|
+
writer.uint32(/* id 9, wireType 0 =*/72).int32(message.derivation);
|
32847
32883
|
return writer;
|
32848
32884
|
};
|
32849
32885
|
|
@@ -32886,6 +32922,12 @@
|
|
32886
32922
|
case 7:
|
32887
32923
|
message.gasPremium = reader.bytes();
|
32888
32924
|
break;
|
32925
|
+
case 8:
|
32926
|
+
message.params = reader.bytes();
|
32927
|
+
break;
|
32928
|
+
case 9:
|
32929
|
+
message.derivation = reader.int32();
|
32930
|
+
break;
|
32889
32931
|
default:
|
32890
32932
|
reader.skipType(tag & 7);
|
32891
32933
|
break;
|
@@ -32926,6 +32968,17 @@
|
|
32926
32968
|
if (message.gasPremium != null && message.hasOwnProperty("gasPremium"))
|
32927
32969
|
if (!(message.gasPremium && typeof message.gasPremium.length === "number" || $util.isString(message.gasPremium)))
|
32928
32970
|
return "gasPremium: buffer expected";
|
32971
|
+
if (message.params != null && message.hasOwnProperty("params"))
|
32972
|
+
if (!(message.params && typeof message.params.length === "number" || $util.isString(message.params)))
|
32973
|
+
return "params: buffer expected";
|
32974
|
+
if (message.derivation != null && message.hasOwnProperty("derivation"))
|
32975
|
+
switch (message.derivation) {
|
32976
|
+
default:
|
32977
|
+
return "derivation: enum value expected";
|
32978
|
+
case 0:
|
32979
|
+
case 1:
|
32980
|
+
break;
|
32981
|
+
}
|
32929
32982
|
return null;
|
32930
32983
|
};
|
32931
32984
|
|
@@ -32981,6 +33034,21 @@
|
|
32981
33034
|
$util.base64.decode(object.gasPremium, message.gasPremium = $util.newBuffer($util.base64.length(object.gasPremium)), 0);
|
32982
33035
|
else if (object.gasPremium.length)
|
32983
33036
|
message.gasPremium = object.gasPremium;
|
33037
|
+
if (object.params != null)
|
33038
|
+
if (typeof object.params === "string")
|
33039
|
+
$util.base64.decode(object.params, message.params = $util.newBuffer($util.base64.length(object.params)), 0);
|
33040
|
+
else if (object.params.length)
|
33041
|
+
message.params = object.params;
|
33042
|
+
switch (object.derivation) {
|
33043
|
+
case "SECP256K1":
|
33044
|
+
case 0:
|
33045
|
+
message.derivation = 0;
|
33046
|
+
break;
|
33047
|
+
case "DELEGATED":
|
33048
|
+
case 1:
|
33049
|
+
message.derivation = 1;
|
33050
|
+
break;
|
33051
|
+
}
|
32984
33052
|
return message;
|
32985
33053
|
};
|
32986
33054
|
|
@@ -33037,6 +33105,14 @@
|
|
33037
33105
|
if (options.bytes !== Array)
|
33038
33106
|
object.gasPremium = $util.newBuffer(object.gasPremium);
|
33039
33107
|
}
|
33108
|
+
if (options.bytes === String)
|
33109
|
+
object.params = "";
|
33110
|
+
else {
|
33111
|
+
object.params = [];
|
33112
|
+
if (options.bytes !== Array)
|
33113
|
+
object.params = $util.newBuffer(object.params);
|
33114
|
+
}
|
33115
|
+
object.derivation = options.enums === String ? "SECP256K1" : 0;
|
33040
33116
|
}
|
33041
33117
|
if (message.privateKey != null && message.hasOwnProperty("privateKey"))
|
33042
33118
|
object.privateKey = options.bytes === String ? $util.base64.encode(message.privateKey, 0, message.privateKey.length) : options.bytes === Array ? Array.prototype.slice.call(message.privateKey) : message.privateKey;
|
@@ -33058,6 +33134,10 @@
|
|
33058
33134
|
object.gasFeeCap = options.bytes === String ? $util.base64.encode(message.gasFeeCap, 0, message.gasFeeCap.length) : options.bytes === Array ? Array.prototype.slice.call(message.gasFeeCap) : message.gasFeeCap;
|
33059
33135
|
if (message.gasPremium != null && message.hasOwnProperty("gasPremium"))
|
33060
33136
|
object.gasPremium = options.bytes === String ? $util.base64.encode(message.gasPremium, 0, message.gasPremium.length) : options.bytes === Array ? Array.prototype.slice.call(message.gasPremium) : message.gasPremium;
|
33137
|
+
if (message.params != null && message.hasOwnProperty("params"))
|
33138
|
+
object.params = options.bytes === String ? $util.base64.encode(message.params, 0, message.params.length) : options.bytes === Array ? Array.prototype.slice.call(message.params) : message.params;
|
33139
|
+
if (message.derivation != null && message.hasOwnProperty("derivation"))
|
33140
|
+
object.derivation = options.enums === String ? $root.TW.Filecoin.Proto.DerivationType[message.derivation] : message.derivation;
|
33061
33141
|
return object;
|
33062
33142
|
};
|
33063
33143
|
|
@@ -33082,6 +33162,7 @@
|
|
33082
33162
|
* @memberof TW.Filecoin.Proto
|
33083
33163
|
* @interface ISigningOutput
|
33084
33164
|
* @property {string|null} [json] SigningOutput json
|
33165
|
+
* @property {string|null} [errorMessage] SigningOutput errorMessage
|
33085
33166
|
*/
|
33086
33167
|
|
33087
33168
|
/**
|
@@ -33107,6 +33188,14 @@
|
|
33107
33188
|
*/
|
33108
33189
|
SigningOutput.prototype.json = "";
|
33109
33190
|
|
33191
|
+
/**
|
33192
|
+
* SigningOutput errorMessage.
|
33193
|
+
* @member {string} errorMessage
|
33194
|
+
* @memberof TW.Filecoin.Proto.SigningOutput
|
33195
|
+
* @instance
|
33196
|
+
*/
|
33197
|
+
SigningOutput.prototype.errorMessage = "";
|
33198
|
+
|
33110
33199
|
/**
|
33111
33200
|
* Creates a new SigningOutput instance using the specified properties.
|
33112
33201
|
* @function create
|
@@ -33133,6 +33222,8 @@
|
|
33133
33222
|
writer = $Writer.create();
|
33134
33223
|
if (message.json != null && Object.hasOwnProperty.call(message, "json"))
|
33135
33224
|
writer.uint32(/* id 1, wireType 2 =*/10).string(message.json);
|
33225
|
+
if (message.errorMessage != null && Object.hasOwnProperty.call(message, "errorMessage"))
|
33226
|
+
writer.uint32(/* id 2, wireType 2 =*/18).string(message.errorMessage);
|
33136
33227
|
return writer;
|
33137
33228
|
};
|
33138
33229
|
|
@@ -33157,6 +33248,9 @@
|
|
33157
33248
|
case 1:
|
33158
33249
|
message.json = reader.string();
|
33159
33250
|
break;
|
33251
|
+
case 2:
|
33252
|
+
message.errorMessage = reader.string();
|
33253
|
+
break;
|
33160
33254
|
default:
|
33161
33255
|
reader.skipType(tag & 7);
|
33162
33256
|
break;
|
@@ -33179,6 +33273,9 @@
|
|
33179
33273
|
if (message.json != null && message.hasOwnProperty("json"))
|
33180
33274
|
if (!$util.isString(message.json))
|
33181
33275
|
return "json: string expected";
|
33276
|
+
if (message.errorMessage != null && message.hasOwnProperty("errorMessage"))
|
33277
|
+
if (!$util.isString(message.errorMessage))
|
33278
|
+
return "errorMessage: string expected";
|
33182
33279
|
return null;
|
33183
33280
|
};
|
33184
33281
|
|
@@ -33196,6 +33293,8 @@
|
|
33196
33293
|
var message = new $root.TW.Filecoin.Proto.SigningOutput();
|
33197
33294
|
if (object.json != null)
|
33198
33295
|
message.json = String(object.json);
|
33296
|
+
if (object.errorMessage != null)
|
33297
|
+
message.errorMessage = String(object.errorMessage);
|
33199
33298
|
return message;
|
33200
33299
|
};
|
33201
33300
|
|
@@ -33212,10 +33311,14 @@
|
|
33212
33311
|
if (!options)
|
33213
33312
|
options = {};
|
33214
33313
|
var object = {};
|
33215
|
-
if (options.defaults)
|
33314
|
+
if (options.defaults) {
|
33216
33315
|
object.json = "";
|
33316
|
+
object.errorMessage = "";
|
33317
|
+
}
|
33217
33318
|
if (message.json != null && message.hasOwnProperty("json"))
|
33218
33319
|
object.json = message.json;
|
33320
|
+
if (message.errorMessage != null && message.hasOwnProperty("errorMessage"))
|
33321
|
+
object.errorMessage = message.errorMessage;
|
33219
33322
|
return object;
|
33220
33323
|
};
|
33221
33324
|
|
@@ -84202,6 +84305,7 @@
|
|
84202
84305
|
* @interface ISigningInput
|
84203
84306
|
* @property {TW.Tron.Proto.ITransaction|null} [transaction] SigningInput transaction
|
84204
84307
|
* @property {Uint8Array|null} [privateKey] SigningInput privateKey
|
84308
|
+
* @property {string|null} [txId] SigningInput txId
|
84205
84309
|
*/
|
84206
84310
|
|
84207
84311
|
/**
|
@@ -84235,6 +84339,14 @@
|
|
84235
84339
|
*/
|
84236
84340
|
SigningInput.prototype.privateKey = $util.newBuffer([]);
|
84237
84341
|
|
84342
|
+
/**
|
84343
|
+
* SigningInput txId.
|
84344
|
+
* @member {string} txId
|
84345
|
+
* @memberof TW.Tron.Proto.SigningInput
|
84346
|
+
* @instance
|
84347
|
+
*/
|
84348
|
+
SigningInput.prototype.txId = "";
|
84349
|
+
|
84238
84350
|
/**
|
84239
84351
|
* Creates a new SigningInput instance using the specified properties.
|
84240
84352
|
* @function create
|
@@ -84263,6 +84375,8 @@
|
|
84263
84375
|
$root.TW.Tron.Proto.Transaction.encode(message.transaction, writer.uint32(/* id 1, wireType 2 =*/10).fork()).ldelim();
|
84264
84376
|
if (message.privateKey != null && Object.hasOwnProperty.call(message, "privateKey"))
|
84265
84377
|
writer.uint32(/* id 2, wireType 2 =*/18).bytes(message.privateKey);
|
84378
|
+
if (message.txId != null && Object.hasOwnProperty.call(message, "txId"))
|
84379
|
+
writer.uint32(/* id 3, wireType 2 =*/26).string(message.txId);
|
84266
84380
|
return writer;
|
84267
84381
|
};
|
84268
84382
|
|
@@ -84290,6 +84404,9 @@
|
|
84290
84404
|
case 2:
|
84291
84405
|
message.privateKey = reader.bytes();
|
84292
84406
|
break;
|
84407
|
+
case 3:
|
84408
|
+
message.txId = reader.string();
|
84409
|
+
break;
|
84293
84410
|
default:
|
84294
84411
|
reader.skipType(tag & 7);
|
84295
84412
|
break;
|
@@ -84317,6 +84434,9 @@
|
|
84317
84434
|
if (message.privateKey != null && message.hasOwnProperty("privateKey"))
|
84318
84435
|
if (!(message.privateKey && typeof message.privateKey.length === "number" || $util.isString(message.privateKey)))
|
84319
84436
|
return "privateKey: buffer expected";
|
84437
|
+
if (message.txId != null && message.hasOwnProperty("txId"))
|
84438
|
+
if (!$util.isString(message.txId))
|
84439
|
+
return "txId: string expected";
|
84320
84440
|
return null;
|
84321
84441
|
};
|
84322
84442
|
|
@@ -84342,6 +84462,8 @@
|
|
84342
84462
|
$util.base64.decode(object.privateKey, message.privateKey = $util.newBuffer($util.base64.length(object.privateKey)), 0);
|
84343
84463
|
else if (object.privateKey.length)
|
84344
84464
|
message.privateKey = object.privateKey;
|
84465
|
+
if (object.txId != null)
|
84466
|
+
message.txId = String(object.txId);
|
84345
84467
|
return message;
|
84346
84468
|
};
|
84347
84469
|
|
@@ -84367,11 +84489,14 @@
|
|
84367
84489
|
if (options.bytes !== Array)
|
84368
84490
|
object.privateKey = $util.newBuffer(object.privateKey);
|
84369
84491
|
}
|
84492
|
+
object.txId = "";
|
84370
84493
|
}
|
84371
84494
|
if (message.transaction != null && message.hasOwnProperty("transaction"))
|
84372
84495
|
object.transaction = $root.TW.Tron.Proto.Transaction.toObject(message.transaction, options);
|
84373
84496
|
if (message.privateKey != null && message.hasOwnProperty("privateKey"))
|
84374
84497
|
object.privateKey = options.bytes === String ? $util.base64.encode(message.privateKey, 0, message.privateKey.length) : options.bytes === Array ? Array.prototype.slice.call(message.privateKey) : message.privateKey;
|
84498
|
+
if (message.txId != null && message.hasOwnProperty("txId"))
|
84499
|
+
object.txId = message.txId;
|
84375
84500
|
return object;
|
84376
84501
|
};
|
84377
84502
|
|
package/dist/lib/wallet-core.js
CHANGED
@@ -34,7 +34,7 @@ function Ua(){Qa++;g.monitorRunDependencies&&g.monitorRunDependencies(Qa);assert
|
|
34
34
|
function Va(){return G.startsWith("data:application/octet-stream;base64,")}function ma(a){return a.startsWith("file://")}function H(a){return function(){var b=g.asm;assert(Oa,"native function `"+a+"` called before runtime initialization");b[a]||assert(b[a],"exported native function `"+a+"` not found");return b[a].apply(null,arguments)}}var G;G="wallet-core.wasm";if(!Va()){var Wa=G;G=g.locateFile?g.locateFile(Wa,w):w+Wa}
|
35
35
|
function Xa(){var a=G;try{if(a==G&&qa)return new Uint8Array(qa);if(ka)return ka(a);throw"both async and sync fetching of the wasm failed";}catch(b){n(b)}}
|
36
36
|
function Ya(){if(!qa&&(ea||fa)){if("function"==typeof fetch&&!ma(G))return fetch(G,{credentials:"same-origin"}).then(function(a){if(!a.ok)throw"failed to load wasm binary file at '"+G+"'";return a.arrayBuffer()}).catch(function(){return Xa()});if(ja)return new Promise(function(a,b){ja(G,function(c){a(new Uint8Array(c))},b)})}return Promise.resolve().then(function(){return Xa()})}
|
37
|
-
var Za,$a,ab={
|
37
|
+
var Za,$a,ab={653860:()=>{if(void 0===g.ea)try{var a="object"===typeof window?window:self,b="undefined"!==typeof a.crypto?a.crypto:a.msCrypto;a=function(){var d=new Uint32Array(1);b.getRandomValues(d);return d[0]>>>0};a();g.ea=a}catch(d){try{var c=require("crypto");a=function(){var e=c.randomBytes(4);return(e[0]<<24|e[1]<<16|e[2]<<8|e[3])>>>0};a();g.ea=a}catch(e){throw"No secure random number generator found";}}},654582:()=>g.ea()};function bb(a){for(;0<a.length;)a.shift()(g)}
|
38
38
|
function va(a){assert("number"===typeof a);return"0x"+a.toString(16).padStart(8,"0")}function pa(a){cb||(cb={});cb[a]||(cb[a]=1,v&&(a="warning: "+a),y(a))}var cb,db=0;
|
39
39
|
function eb(a){this.l=a-24;this.Sa=function(b){F[this.l+4>>2]=b};this.Ca=function(){return F[this.l+4>>2]};this.Ia=function(b){F[this.l+8>>2]=b};this.Ja=function(){E[this.l>>2]=0};this.Ha=function(){C[this.l+12>>0]=0};this.Ma=function(){C[this.l+13>>0]=0};this.Da=function(b,c){this.F(0);this.Sa(b);this.Ia(c);this.Ja();this.Ha();this.Ma()};this.F=function(b){F[this.l+16>>2]=b}}
|
40
40
|
var fb=0,gb=(a,b)=>{for(var c=0,d=a.length-1;0<=d;d--){var e=a[d];"."===e?a.splice(d,1):".."===e?(a.splice(d,1),c++):c&&(a.splice(d,1),c--)}if(b)for(;c;c--)a.unshift("..");return a},hb=a=>{var b="/"===a.charAt(0),c="/"===a.substr(-1);(a=gb(a.split("/").filter(d=>!!d),!b).join("/"))||b||(a=".");a&&c&&(a+="/");return(b?"/":"")+a},ib=a=>{var b=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/.exec(a).slice(1);a=b[0];b=b[1];if(!a&&!b)return".";b&&(b=b.substr(0,b.length-1));return a+b},jb=
|
@@ -153,10 +153,10 @@ a)}catch(f){y("Module.instantiateWasm callback failed with error: "+f),ba(f)}(fu
|
|
153
153
|
var zd=g._malloc=H("malloc"),V=g._free=H("free"),Od=g.___errno_location=H("__errno_location");g._fflush=H("fflush");var Vc=g.___getTypeName=H("__getTypeName");g.__embind_initialize_bindings=H("_embind_initialize_bindings");g._htonl=H("htonl");g._htons=H("htons");var xb=g._emscripten_builtin_memalign=H("emscripten_builtin_memalign");g._ntohs=H("ntohs");
|
154
154
|
var X=g._setThrew=H("setThrew"),Md=g.setTempRet0=H("setTempRet0"),de=g._emscripten_stack_init=function(){return(de=g._emscripten_stack_init=g.asm.emscripten_stack_init).apply(null,arguments)};g._emscripten_stack_get_free=function(){return(g._emscripten_stack_get_free=g.asm.emscripten_stack_get_free).apply(null,arguments)};g._emscripten_stack_get_base=function(){return(g._emscripten_stack_get_base=g.asm.emscripten_stack_get_base).apply(null,arguments)};
|
155
155
|
var Ha=g._emscripten_stack_get_end=function(){return(Ha=g._emscripten_stack_get_end=g.asm.emscripten_stack_get_end).apply(null,arguments)},Y=g.stackSave=H("stackSave"),Z=g.stackRestore=H("stackRestore");g.stackAlloc=H("stackAlloc");g._emscripten_stack_get_current=function(){return(g._emscripten_stack_get_current=g.asm.emscripten_stack_get_current).apply(null,arguments)};g.___cxa_free_exception=H("__cxa_free_exception");var Nd=g.___cxa_can_catch=H("__cxa_can_catch");g.___cxa_is_pointer_type=H("__cxa_is_pointer_type");
|
156
|
-
g.dynCall_jii=H("dynCall_jii");g.dynCall_ji=H("dynCall_ji");g.dynCall_iiji=H("dynCall_iiji");g.dynCall_iiiji=H("dynCall_iiiji");g.dynCall_jiii=H("dynCall_jiii");g.dynCall_jiiii=H("dynCall_jiiii");g.dynCall_iiij=H("dynCall_iiij");g.dynCall_iiiij=H("dynCall_iiiij");g.dynCall_jijjj=H("dynCall_jijjj");g.dynCall_jij=H("dynCall_jij");g.dynCall_viijii=H("dynCall_viijii");g.dynCall_viiiijijji=H("dynCall_viiiijijji");
|
157
|
-
g.dynCall_jj=H("dynCall_jj");g.dynCall_viji=H("dynCall_viji");g.dynCall_jiji=H("dynCall_jiji");g.dynCall_iiiiij=H("dynCall_iiiiij");g.dynCall_iiiiijj=H("dynCall_iiiiijj");g.dynCall_iiiiiijj=H("dynCall_iiiiiijj");function
|
158
|
-
function
|
159
|
-
function
|
156
|
+
g.dynCall_jii=H("dynCall_jii");g.dynCall_ji=H("dynCall_ji");g.dynCall_iiji=H("dynCall_iiji");g.dynCall_iiiji=H("dynCall_iiiji");g.dynCall_jiii=H("dynCall_jiii");g.dynCall_jiiii=H("dynCall_jiiii");g.dynCall_iiij=H("dynCall_iiij");g.dynCall_iiiij=H("dynCall_iiiij");g.dynCall_jijjj=H("dynCall_jijjj");g.dynCall_jij=H("dynCall_jij");g.dynCall_viijii=H("dynCall_viijii");g.dynCall_viiiijijji=H("dynCall_viiiijijji");g.dynCall_iij=H("dynCall_iij");g.dynCall_vij=H("dynCall_vij");var ee=g.dynCall_viiji=H("dynCall_viiji");
|
157
|
+
g.dynCall_jj=H("dynCall_jj");g.dynCall_viji=H("dynCall_viji");g.dynCall_jiji=H("dynCall_jiji");g.dynCall_iiiiij=H("dynCall_iiiiij");g.dynCall_iiiiijj=H("dynCall_iiiiijj");g.dynCall_iiiiiijj=H("dynCall_iiiiiijj");function Xd(a,b,c,d){var e=Y();try{U(a)(b,c,d)}catch(f){Z(e);if(f!==f+0)throw f;X(1,0)}}function Rd(a,b,c){var d=Y();try{return U(a)(b,c)}catch(e){Z(d);if(e!==e+0)throw e;X(1,0)}}function Zd(a,b,c,d,e,f){var h=Y();try{U(a)(b,c,d,e,f)}catch(l){Z(h);if(l!==l+0)throw l;X(1,0)}}
|
158
|
+
function Wd(a,b,c){var d=Y();try{U(a)(b,c)}catch(e){Z(d);if(e!==e+0)throw e;X(1,0)}}function Vd(a,b){var c=Y();try{U(a)(b)}catch(d){Z(c);if(d!==d+0)throw d;X(1,0)}}function Qd(a,b){var c=Y();try{return U(a)(b)}catch(d){Z(c);if(d!==d+0)throw d;X(1,0)}}function Yd(a,b,c,d,e){var f=Y();try{U(a)(b,c,d,e)}catch(h){Z(f);if(h!==h+0)throw h;X(1,0)}}function Sd(a,b,c,d){var e=Y();try{return U(a)(b,c,d)}catch(f){Z(e);if(f!==f+0)throw f;X(1,0)}}
|
159
|
+
function Ud(a){var b=Y();try{U(a)()}catch(c){Z(b);if(c!==c+0)throw c;X(1,0)}}function $d(a,b,c,d,e,f,h){var l=Y();try{U(a)(b,c,d,e,f,h)}catch(p){Z(l);if(p!==p+0)throw p;X(1,0)}}function Pd(a){var b=Y();try{return U(a)()}catch(c){Z(b);if(c!==c+0)throw c;X(1,0)}}function ae(a,b,c,d,e,f,h,l,p){var m=Y();try{U(a)(b,c,d,e,f,h,l,p)}catch(q){Z(m);if(q!==q+0)throw q;X(1,0)}}function Td(a,b,c,d,e,f){var h=Y();try{return U(a)(b,c,d,e,f)}catch(l){Z(h);if(l!==l+0)throw l;X(1,0)}}
|
160
160
|
function be(a,b,c,d,e,f){var h=Y();try{ee(a,b,c,d,e,f)}catch(l){Z(h);if(l!==l+0)throw l;X(1,0)}}
|
161
161
|
"run UTF8ArrayToString UTF8ToString stringToUTF8Array stringToUTF8 lengthBytesUTF8 addOnPreRun addOnInit addOnPreMain addOnExit addOnPostRun addRunDependency removeRunDependency FS_createFolder FS_createPath FS_createDataFile FS_createPreloadedFile FS_createLazyFile FS_createLink FS_createDevice FS_unlink getLEB getFunctionTables alignFunctionTables registerFunctions prettyPrint getCompilerSetting out err callMain abort keepRuntimeAlive wasmMemory stackAlloc stackSave stackRestore getTempRet0 setTempRet0 writeStackCookie checkStackCookie ptrToString zeroMemory stringToNewUTF8 exitJS getHeapMax emscripten_realloc_buffer ENV ERRNO_CODES ERRNO_MESSAGES setErrNo inetPton4 inetNtop4 inetPton6 inetNtop6 readSockaddr writeSockaddr DNS getHostByName Protocols Sockets getRandomDevice warnOnce traverseStack UNWIND_CACHE convertPCtoSourceLocation readEmAsmArgsArray readEmAsmArgs runEmAsmFunction runMainThreadEmAsm jstoi_q jstoi_s getExecutableName listenOnce autoResumeAudioContext dynCallLegacy getDynCaller dynCall handleException runtimeKeepalivePush runtimeKeepalivePop callUserCallback maybeExit safeSetTimeout asmjsMangle asyncLoad alignMemory mmapAlloc handleAllocator writeI53ToI64 writeI53ToI64Clamped writeI53ToI64Signaling writeI53ToU64Clamped writeI53ToU64Signaling readI53FromI64 readI53FromU64 convertI32PairToI53 convertI32PairToI53Checked convertU32PairToI53 getCFunc ccall cwrap uleb128Encode sigToWasmTypes generateFuncType convertJsFunctionToWasm freeTableIndexes functionsInTableMap getEmptyTableSlot updateTableMap addFunction removeFunction reallyNegative unSign strLen reSign formatString setValue getValue PATH PATH_FS intArrayFromString intArrayToString AsciiToString stringToAscii UTF16Decoder UTF16ToString stringToUTF16 lengthBytesUTF16 UTF32ToString stringToUTF32 lengthBytesUTF32 allocateUTF8 allocateUTF8OnStack writeStringToMemory writeArrayToMemory writeAsciiToMemory SYSCALLS getSocketFromFD getSocketAddress JSEvents registerKeyEventCallback specialHTMLTargets maybeCStringToJsString findEventTarget findCanvasEventTarget getBoundingClientRect fillMouseEventData registerMouseEventCallback registerWheelEventCallback registerUiEventCallback registerFocusEventCallback fillDeviceOrientationEventData registerDeviceOrientationEventCallback fillDeviceMotionEventData registerDeviceMotionEventCallback screenOrientation fillOrientationChangeEventData registerOrientationChangeEventCallback fillFullscreenChangeEventData registerFullscreenChangeEventCallback JSEvents_requestFullscreen JSEvents_resizeCanvasForFullscreen registerRestoreOldStyle hideEverythingExceptGivenElement restoreHiddenElements setLetterbox currentFullscreenStrategy restoreOldWindowedStyle softFullscreenResizeWebGLRenderTarget doRequestFullscreen fillPointerlockChangeEventData registerPointerlockChangeEventCallback registerPointerlockErrorEventCallback requestPointerLock fillVisibilityChangeEventData registerVisibilityChangeEventCallback registerTouchEventCallback fillGamepadEventData registerGamepadEventCallback registerBeforeUnloadEventCallback fillBatteryEventData battery registerBatteryEventCallback setCanvasElementSize getCanvasElementSize demangle demangleAll jsStackTrace stackTrace ExitStatus getEnvStrings checkWasiClock doReadv doWritev createDyncallWrapper setImmediateWrapped clearImmediateWrapped polyfillSetImmediate promiseMap newNativePromise getPromise uncaughtExceptionCount exceptionLast exceptionCaught ExceptionInfo exception_addRef exception_decRef Browser setMainLoop wget FS MEMFS TTY PIPEFS SOCKFS _setNetworkCallback InternalError BindingError UnboundTypeError PureVirtualError init_embind throwInternalError throwBindingError throwUnboundTypeError ensureOverloadTable exposePublicSymbol replacePublicSymbol extendError createNamedFunction embindRepr registeredInstances getBasestPointer registerInheritedInstance unregisterInheritedInstance getInheritedInstance getInheritedInstanceCount getLiveInheritedInstances registeredTypes awaitingDependencies typeDependencies registeredPointers registerType whenDependentTypesAreResolved embind_charCodes embind_init_charCodes readLatin1String getTypeName heap32VectorToArray requireRegisteredType getShiftFromSize integerReadValueFromPointer enumReadValueFromPointer floatReadValueFromPointer simpleReadValueFromPointer runDestructors new_ craftInvokerFunction embind__requireFunction tupleRegistrations structRegistrations genericPointerToWireType constNoSmartPtrRawPointerToWireType nonConstNoSmartPtrRawPointerToWireType init_RegisteredPointer RegisteredPointer RegisteredPointer_getPointee RegisteredPointer_destructor RegisteredPointer_deleteObject RegisteredPointer_fromWireType runDestructor releaseClassHandle finalizationRegistry detachFinalizer_deps detachFinalizer attachFinalizer makeClassHandle init_ClassHandle ClassHandle ClassHandle_isAliasOf throwInstanceAlreadyDeleted ClassHandle_clone ClassHandle_delete deletionQueue ClassHandle_isDeleted ClassHandle_deleteLater flushPendingDeletes delayFunction setDelayFunction RegisteredClass shallowCopyInternalPointer downcastPointer upcastPointer validateThis char_0 char_9 makeLegalFunctionName emval_handle_array emval_free_list emval_symbols init_emval count_emval_handles get_first_emval getStringOrSymbol Emval emval_newers craftEmvalAllocator emval_get_global emval_lookupTypes emval_allocateDestructors emval_methodCallers emval_addMethodCaller emval_registeredMethods".split(" ").forEach(function(a){Object.getOwnPropertyDescriptor(g,a)||
|
162
162
|
Object.defineProperty(g,a,{configurable:!0,get:function(){var b="'"+a+"' was not exported. add it to EXPORTED_RUNTIME_METHODS (see the FAQ)";oa(a)&&(b+=". Alternatively, forcing filesystem support (-sFORCE_FILESYSTEM) can export this for you");n(b)}})});
|
Binary file
|
@@ -84,6 +84,7 @@ export class AnyAddress {
|
|
84
84
|
static createWithPublicKeyDerivation(publicKey: PublicKey, coin: CoinType, derivation: Derivation): AnyAddress;
|
85
85
|
static createBech32WithPublicKey(publicKey: PublicKey, coin: CoinType, hrp: string): AnyAddress;
|
86
86
|
static createSS58WithPublicKey(publicKey: PublicKey, coin: CoinType, ss58Prefix: number): AnyAddress;
|
87
|
+
static createWithPublicKeyFilecoinAddressType(publicKey: PublicKey, filecoinAddressType: FilecoinAddressType): AnyAddress;
|
87
88
|
description(): string;
|
88
89
|
coin(): CoinType;
|
89
90
|
data(): Uint8Array;
|
@@ -314,6 +315,7 @@ export class CoinType {
|
|
314
315
|
static agoric: CoinType;
|
315
316
|
static ton: CoinType;
|
316
317
|
static sui: CoinType;
|
318
|
+
static stargaze: CoinType;
|
317
319
|
static polygonzkEVM: CoinType;
|
318
320
|
}
|
319
321
|
export class CoinTypeConfiguration {
|
@@ -470,9 +472,9 @@ export class EthereumChainID {
|
|
470
472
|
static zksync: EthereumChainID;
|
471
473
|
static heco: EthereumChainID;
|
472
474
|
static metis: EthereumChainID;
|
475
|
+
static polygonzkevm: EthereumChainID;
|
473
476
|
static moonbeam: EthereumChainID;
|
474
477
|
static moonriver: EthereumChainID;
|
475
|
-
static polygonzkevm: EthereumChainID;
|
476
478
|
static ronin: EthereumChainID;
|
477
479
|
static kavaevm: EthereumChainID;
|
478
480
|
static klaytn: EthereumChainID;
|
@@ -495,6 +497,15 @@ export class FIOAccount {
|
|
495
497
|
description(): string;
|
496
498
|
delete(): void;
|
497
499
|
}
|
500
|
+
export class FilecoinAddressConverter {
|
501
|
+
static convertToEthereum(filecoinAddress: string): string;
|
502
|
+
static convertFromEthereum(ethAddress: string): string;
|
503
|
+
}
|
504
|
+
export class FilecoinAddressType {
|
505
|
+
value: number;
|
506
|
+
static default: FilecoinAddressType;
|
507
|
+
static delegated: FilecoinAddressType;
|
508
|
+
}
|
498
509
|
export class GroestlcoinAddress {
|
499
510
|
static equal(lhs: GroestlcoinAddress, rhs: GroestlcoinAddress): boolean;
|
500
511
|
static isValidString(string: string): boolean;
|
@@ -579,6 +590,7 @@ export class HRP {
|
|
579
590
|
static nativeInjective: HRP;
|
580
591
|
static osmosis: HRP;
|
581
592
|
static terraV2: HRP;
|
593
|
+
static stargaze: HRP;
|
582
594
|
static nativeEvmos: HRP;
|
583
595
|
}
|
584
596
|
|
@@ -846,6 +858,8 @@ export interface WalletCore {
|
|
846
858
|
EthereumChainID: typeof EthereumChainID;
|
847
859
|
EthereumMessageSigner: typeof EthereumMessageSigner;
|
848
860
|
FIOAccount: typeof FIOAccount;
|
861
|
+
FilecoinAddressConverter: typeof FilecoinAddressConverter;
|
862
|
+
FilecoinAddressType: typeof FilecoinAddressType;
|
849
863
|
GroestlcoinAddress: typeof GroestlcoinAddress;
|
850
864
|
HDVersion: typeof HDVersion;
|
851
865
|
HDWallet: typeof HDWallet;
|