@trustwallet/wallet-core 2.7.0 → 2.9.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/dist/generated/core_proto.d.ts +219 -12
- package/dist/generated/core_proto.js +829 -83
- package/dist/lib/wallet-core.js +96 -95
- package/dist/lib/wallet-core.wasm +0 -0
- package/package.json +1 -1
@@ -3424,7 +3424,8 @@ export namespace TW {
|
|
3424
3424
|
Error_input_parse = 19,
|
3425
3425
|
Error_no_support_n2n = 20,
|
3426
3426
|
Error_signatures_count = 21,
|
3427
|
-
Error_invalid_params = 22
|
3427
|
+
Error_invalid_params = 22,
|
3428
|
+
Error_invalid_requested_token_amount = 23
|
3428
3429
|
}
|
3429
3430
|
}
|
3430
3431
|
}
|
@@ -4652,6 +4653,9 @@ export namespace TW {
|
|
4652
4653
|
|
4653
4654
|
/** TxOutput amount */
|
4654
4655
|
amount?: (Long|null);
|
4656
|
+
|
4657
|
+
/** TxOutput tokenAmount */
|
4658
|
+
tokenAmount?: (TW.Cardano.Proto.ITokenAmount[]|null);
|
4655
4659
|
}
|
4656
4660
|
|
4657
4661
|
/** Represents a TxOutput. */
|
@@ -4669,6 +4673,9 @@ export namespace TW {
|
|
4669
4673
|
/** TxOutput amount. */
|
4670
4674
|
public amount: Long;
|
4671
4675
|
|
4676
|
+
/** TxOutput tokenAmount. */
|
4677
|
+
public tokenAmount: TW.Cardano.Proto.ITokenAmount[];
|
4678
|
+
|
4672
4679
|
/**
|
4673
4680
|
* Creates a new TxOutput instance using the specified properties.
|
4674
4681
|
* @param [properties] Properties to set
|
@@ -4723,6 +4730,79 @@ export namespace TW {
|
|
4723
4730
|
public toJSON(): { [k: string]: any };
|
4724
4731
|
}
|
4725
4732
|
|
4733
|
+
/** Properties of a TokenBundle. */
|
4734
|
+
interface ITokenBundle {
|
4735
|
+
|
4736
|
+
/** TokenBundle token */
|
4737
|
+
token?: (TW.Cardano.Proto.ITokenAmount[]|null);
|
4738
|
+
}
|
4739
|
+
|
4740
|
+
/** Represents a TokenBundle. */
|
4741
|
+
class TokenBundle implements ITokenBundle {
|
4742
|
+
|
4743
|
+
/**
|
4744
|
+
* Constructs a new TokenBundle.
|
4745
|
+
* @param [properties] Properties to set
|
4746
|
+
*/
|
4747
|
+
constructor(properties?: TW.Cardano.Proto.ITokenBundle);
|
4748
|
+
|
4749
|
+
/** TokenBundle token. */
|
4750
|
+
public token: TW.Cardano.Proto.ITokenAmount[];
|
4751
|
+
|
4752
|
+
/**
|
4753
|
+
* Creates a new TokenBundle instance using the specified properties.
|
4754
|
+
* @param [properties] Properties to set
|
4755
|
+
* @returns TokenBundle instance
|
4756
|
+
*/
|
4757
|
+
public static create(properties?: TW.Cardano.Proto.ITokenBundle): TW.Cardano.Proto.TokenBundle;
|
4758
|
+
|
4759
|
+
/**
|
4760
|
+
* Encodes the specified TokenBundle message. Does not implicitly {@link TW.Cardano.Proto.TokenBundle.verify|verify} messages.
|
4761
|
+
* @param message TokenBundle message or plain object to encode
|
4762
|
+
* @param [writer] Writer to encode to
|
4763
|
+
* @returns Writer
|
4764
|
+
*/
|
4765
|
+
public static encode(message: TW.Cardano.Proto.ITokenBundle, writer?: $protobuf.Writer): $protobuf.Writer;
|
4766
|
+
|
4767
|
+
/**
|
4768
|
+
* Decodes a TokenBundle message from the specified reader or buffer.
|
4769
|
+
* @param reader Reader or buffer to decode from
|
4770
|
+
* @param [length] Message length if known beforehand
|
4771
|
+
* @returns TokenBundle
|
4772
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
4773
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
4774
|
+
*/
|
4775
|
+
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): TW.Cardano.Proto.TokenBundle;
|
4776
|
+
|
4777
|
+
/**
|
4778
|
+
* Verifies a TokenBundle message.
|
4779
|
+
* @param message Plain object to verify
|
4780
|
+
* @returns `null` if valid, otherwise the reason why it is not
|
4781
|
+
*/
|
4782
|
+
public static verify(message: { [k: string]: any }): (string|null);
|
4783
|
+
|
4784
|
+
/**
|
4785
|
+
* Creates a TokenBundle message from a plain object. Also converts values to their respective internal types.
|
4786
|
+
* @param object Plain object
|
4787
|
+
* @returns TokenBundle
|
4788
|
+
*/
|
4789
|
+
public static fromObject(object: { [k: string]: any }): TW.Cardano.Proto.TokenBundle;
|
4790
|
+
|
4791
|
+
/**
|
4792
|
+
* Creates a plain object from a TokenBundle message. Also converts values to other types if specified.
|
4793
|
+
* @param message TokenBundle
|
4794
|
+
* @param [options] Conversion options
|
4795
|
+
* @returns Plain object
|
4796
|
+
*/
|
4797
|
+
public static toObject(message: TW.Cardano.Proto.TokenBundle, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
4798
|
+
|
4799
|
+
/**
|
4800
|
+
* Converts this TokenBundle to JSON.
|
4801
|
+
* @returns JSON object
|
4802
|
+
*/
|
4803
|
+
public toJSON(): { [k: string]: any };
|
4804
|
+
}
|
4805
|
+
|
4726
4806
|
/** Properties of a Transfer. */
|
4727
4807
|
interface ITransfer {
|
4728
4808
|
|
@@ -4735,8 +4815,14 @@ export namespace TW {
|
|
4735
4815
|
/** Transfer amount */
|
4736
4816
|
amount?: (Long|null);
|
4737
4817
|
|
4818
|
+
/** Transfer tokenAmount */
|
4819
|
+
tokenAmount?: (TW.Cardano.Proto.ITokenBundle|null);
|
4820
|
+
|
4738
4821
|
/** Transfer useMaxAmount */
|
4739
4822
|
useMaxAmount?: (boolean|null);
|
4823
|
+
|
4824
|
+
/** Transfer forceFee */
|
4825
|
+
forceFee?: (Long|null);
|
4740
4826
|
}
|
4741
4827
|
|
4742
4828
|
/** Represents a Transfer. */
|
@@ -4757,9 +4843,15 @@ export namespace TW {
|
|
4757
4843
|
/** Transfer amount. */
|
4758
4844
|
public amount: Long;
|
4759
4845
|
|
4846
|
+
/** Transfer tokenAmount. */
|
4847
|
+
public tokenAmount?: (TW.Cardano.Proto.ITokenBundle|null);
|
4848
|
+
|
4760
4849
|
/** Transfer useMaxAmount. */
|
4761
4850
|
public useMaxAmount: boolean;
|
4762
4851
|
|
4852
|
+
/** Transfer forceFee. */
|
4853
|
+
public forceFee: Long;
|
4854
|
+
|
4763
4855
|
/**
|
4764
4856
|
* Creates a new Transfer instance using the specified properties.
|
4765
4857
|
* @param [properties] Properties to set
|
@@ -4817,18 +4909,27 @@ export namespace TW {
|
|
4817
4909
|
/** Properties of a TransactionPlan. */
|
4818
4910
|
interface ITransactionPlan {
|
4819
4911
|
|
4820
|
-
/** TransactionPlan amount */
|
4821
|
-
amount?: (Long|null);
|
4822
|
-
|
4823
4912
|
/** TransactionPlan availableAmount */
|
4824
4913
|
availableAmount?: (Long|null);
|
4825
4914
|
|
4915
|
+
/** TransactionPlan amount */
|
4916
|
+
amount?: (Long|null);
|
4917
|
+
|
4826
4918
|
/** TransactionPlan fee */
|
4827
4919
|
fee?: (Long|null);
|
4828
4920
|
|
4829
4921
|
/** TransactionPlan change */
|
4830
4922
|
change?: (Long|null);
|
4831
4923
|
|
4924
|
+
/** TransactionPlan availableTokens */
|
4925
|
+
availableTokens?: (TW.Cardano.Proto.ITokenAmount[]|null);
|
4926
|
+
|
4927
|
+
/** TransactionPlan outputTokens */
|
4928
|
+
outputTokens?: (TW.Cardano.Proto.ITokenAmount[]|null);
|
4929
|
+
|
4930
|
+
/** TransactionPlan changeTokens */
|
4931
|
+
changeTokens?: (TW.Cardano.Proto.ITokenAmount[]|null);
|
4932
|
+
|
4832
4933
|
/** TransactionPlan utxos */
|
4833
4934
|
utxos?: (TW.Cardano.Proto.ITxInput[]|null);
|
4834
4935
|
|
@@ -4845,18 +4946,27 @@ export namespace TW {
|
|
4845
4946
|
*/
|
4846
4947
|
constructor(properties?: TW.Cardano.Proto.ITransactionPlan);
|
4847
4948
|
|
4848
|
-
/** TransactionPlan amount. */
|
4849
|
-
public amount: Long;
|
4850
|
-
|
4851
4949
|
/** TransactionPlan availableAmount. */
|
4852
4950
|
public availableAmount: Long;
|
4853
4951
|
|
4952
|
+
/** TransactionPlan amount. */
|
4953
|
+
public amount: Long;
|
4954
|
+
|
4854
4955
|
/** TransactionPlan fee. */
|
4855
4956
|
public fee: Long;
|
4856
4957
|
|
4857
4958
|
/** TransactionPlan change. */
|
4858
4959
|
public change: Long;
|
4859
4960
|
|
4961
|
+
/** TransactionPlan availableTokens. */
|
4962
|
+
public availableTokens: TW.Cardano.Proto.ITokenAmount[];
|
4963
|
+
|
4964
|
+
/** TransactionPlan outputTokens. */
|
4965
|
+
public outputTokens: TW.Cardano.Proto.ITokenAmount[];
|
4966
|
+
|
4967
|
+
/** TransactionPlan changeTokens. */
|
4968
|
+
public changeTokens: TW.Cardano.Proto.ITokenAmount[];
|
4969
|
+
|
4860
4970
|
/** TransactionPlan utxos. */
|
4861
4971
|
public utxos: TW.Cardano.Proto.ITxInput[];
|
4862
4972
|
|
@@ -5114,7 +5224,7 @@ export namespace TW {
|
|
5114
5224
|
denom?: (string|null);
|
5115
5225
|
|
5116
5226
|
/** Amount amount */
|
5117
|
-
amount?: (
|
5227
|
+
amount?: (string|null);
|
5118
5228
|
}
|
5119
5229
|
|
5120
5230
|
/** Represents an Amount. */
|
@@ -5130,7 +5240,7 @@ export namespace TW {
|
|
5130
5240
|
public denom: string;
|
5131
5241
|
|
5132
5242
|
/** Amount amount. */
|
5133
|
-
public amount:
|
5243
|
+
public amount: string;
|
5134
5244
|
|
5135
5245
|
/**
|
5136
5246
|
* Creates a new Amount instance using the specified properties.
|
@@ -5383,6 +5493,9 @@ export namespace TW {
|
|
5383
5493
|
|
5384
5494
|
/** Message thorchainSendMessage */
|
5385
5495
|
thorchainSendMessage?: (TW.Cosmos.Proto.Message.ITHORChainSend|null);
|
5496
|
+
|
5497
|
+
/** Message wasmTerraExecuteContractGeneric */
|
5498
|
+
wasmTerraExecuteContractGeneric?: (TW.Cosmos.Proto.Message.IWasmTerraExecuteContractGeneric|null);
|
5386
5499
|
}
|
5387
5500
|
|
5388
5501
|
/** Represents a Message. */
|
@@ -5424,8 +5537,11 @@ export namespace TW {
|
|
5424
5537
|
/** Message thorchainSendMessage. */
|
5425
5538
|
public thorchainSendMessage?: (TW.Cosmos.Proto.Message.ITHORChainSend|null);
|
5426
5539
|
|
5540
|
+
/** Message wasmTerraExecuteContractGeneric. */
|
5541
|
+
public wasmTerraExecuteContractGeneric?: (TW.Cosmos.Proto.Message.IWasmTerraExecuteContractGeneric|null);
|
5542
|
+
|
5427
5543
|
/** Message messageOneof. */
|
5428
|
-
public messageOneof?: ("sendCoinsMessage"|"transferTokensMessage"|"stakeMessage"|"unstakeMessage"|"restakeMessage"|"withdrawStakeRewardMessage"|"rawJsonMessage"|"wasmTerraExecuteContractTransferMessage"|"wasmTerraExecuteContractSendMessage"|"thorchainSendMessage");
|
5544
|
+
public messageOneof?: ("sendCoinsMessage"|"transferTokensMessage"|"stakeMessage"|"unstakeMessage"|"restakeMessage"|"withdrawStakeRewardMessage"|"rawJsonMessage"|"wasmTerraExecuteContractTransferMessage"|"wasmTerraExecuteContractSendMessage"|"thorchainSendMessage"|"wasmTerraExecuteContractGeneric");
|
5429
5545
|
|
5430
5546
|
/**
|
5431
5547
|
* Creates a new Message instance using the specified properties.
|
@@ -6326,6 +6442,97 @@ export namespace TW {
|
|
6326
6442
|
public toJSON(): { [k: string]: any };
|
6327
6443
|
}
|
6328
6444
|
|
6445
|
+
/** Properties of a WasmTerraExecuteContractGeneric. */
|
6446
|
+
interface IWasmTerraExecuteContractGeneric {
|
6447
|
+
|
6448
|
+
/** WasmTerraExecuteContractGeneric senderAddress */
|
6449
|
+
senderAddress?: (string|null);
|
6450
|
+
|
6451
|
+
/** WasmTerraExecuteContractGeneric contractAddress */
|
6452
|
+
contractAddress?: (string|null);
|
6453
|
+
|
6454
|
+
/** WasmTerraExecuteContractGeneric executeMsg */
|
6455
|
+
executeMsg?: (string|null);
|
6456
|
+
|
6457
|
+
/** WasmTerraExecuteContractGeneric coins */
|
6458
|
+
coins?: (TW.Cosmos.Proto.IAmount[]|null);
|
6459
|
+
}
|
6460
|
+
|
6461
|
+
/** Represents a WasmTerraExecuteContractGeneric. */
|
6462
|
+
class WasmTerraExecuteContractGeneric implements IWasmTerraExecuteContractGeneric {
|
6463
|
+
|
6464
|
+
/**
|
6465
|
+
* Constructs a new WasmTerraExecuteContractGeneric.
|
6466
|
+
* @param [properties] Properties to set
|
6467
|
+
*/
|
6468
|
+
constructor(properties?: TW.Cosmos.Proto.Message.IWasmTerraExecuteContractGeneric);
|
6469
|
+
|
6470
|
+
/** WasmTerraExecuteContractGeneric senderAddress. */
|
6471
|
+
public senderAddress: string;
|
6472
|
+
|
6473
|
+
/** WasmTerraExecuteContractGeneric contractAddress. */
|
6474
|
+
public contractAddress: string;
|
6475
|
+
|
6476
|
+
/** WasmTerraExecuteContractGeneric executeMsg. */
|
6477
|
+
public executeMsg: string;
|
6478
|
+
|
6479
|
+
/** WasmTerraExecuteContractGeneric coins. */
|
6480
|
+
public coins: TW.Cosmos.Proto.IAmount[];
|
6481
|
+
|
6482
|
+
/**
|
6483
|
+
* Creates a new WasmTerraExecuteContractGeneric instance using the specified properties.
|
6484
|
+
* @param [properties] Properties to set
|
6485
|
+
* @returns WasmTerraExecuteContractGeneric instance
|
6486
|
+
*/
|
6487
|
+
public static create(properties?: TW.Cosmos.Proto.Message.IWasmTerraExecuteContractGeneric): TW.Cosmos.Proto.Message.WasmTerraExecuteContractGeneric;
|
6488
|
+
|
6489
|
+
/**
|
6490
|
+
* Encodes the specified WasmTerraExecuteContractGeneric message. Does not implicitly {@link TW.Cosmos.Proto.Message.WasmTerraExecuteContractGeneric.verify|verify} messages.
|
6491
|
+
* @param message WasmTerraExecuteContractGeneric message or plain object to encode
|
6492
|
+
* @param [writer] Writer to encode to
|
6493
|
+
* @returns Writer
|
6494
|
+
*/
|
6495
|
+
public static encode(message: TW.Cosmos.Proto.Message.IWasmTerraExecuteContractGeneric, writer?: $protobuf.Writer): $protobuf.Writer;
|
6496
|
+
|
6497
|
+
/**
|
6498
|
+
* Decodes a WasmTerraExecuteContractGeneric message from the specified reader or buffer.
|
6499
|
+
* @param reader Reader or buffer to decode from
|
6500
|
+
* @param [length] Message length if known beforehand
|
6501
|
+
* @returns WasmTerraExecuteContractGeneric
|
6502
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
6503
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
6504
|
+
*/
|
6505
|
+
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): TW.Cosmos.Proto.Message.WasmTerraExecuteContractGeneric;
|
6506
|
+
|
6507
|
+
/**
|
6508
|
+
* Verifies a WasmTerraExecuteContractGeneric message.
|
6509
|
+
* @param message Plain object to verify
|
6510
|
+
* @returns `null` if valid, otherwise the reason why it is not
|
6511
|
+
*/
|
6512
|
+
public static verify(message: { [k: string]: any }): (string|null);
|
6513
|
+
|
6514
|
+
/**
|
6515
|
+
* Creates a WasmTerraExecuteContractGeneric message from a plain object. Also converts values to their respective internal types.
|
6516
|
+
* @param object Plain object
|
6517
|
+
* @returns WasmTerraExecuteContractGeneric
|
6518
|
+
*/
|
6519
|
+
public static fromObject(object: { [k: string]: any }): TW.Cosmos.Proto.Message.WasmTerraExecuteContractGeneric;
|
6520
|
+
|
6521
|
+
/**
|
6522
|
+
* Creates a plain object from a WasmTerraExecuteContractGeneric message. Also converts values to other types if specified.
|
6523
|
+
* @param message WasmTerraExecuteContractGeneric
|
6524
|
+
* @param [options] Conversion options
|
6525
|
+
* @returns Plain object
|
6526
|
+
*/
|
6527
|
+
public static toObject(message: TW.Cosmos.Proto.Message.WasmTerraExecuteContractGeneric, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
6528
|
+
|
6529
|
+
/**
|
6530
|
+
* Converts this WasmTerraExecuteContractGeneric to JSON.
|
6531
|
+
* @returns JSON object
|
6532
|
+
*/
|
6533
|
+
public toJSON(): { [k: string]: any };
|
6534
|
+
}
|
6535
|
+
|
6329
6536
|
/** Properties of a RawJSON. */
|
6330
6537
|
interface IRawJSON {
|
6331
6538
|
|
@@ -13555,7 +13762,7 @@ export namespace TW {
|
|
13555
13762
|
interface IFunctionCall {
|
13556
13763
|
|
13557
13764
|
/** FunctionCall methodName */
|
13558
|
-
methodName?: (
|
13765
|
+
methodName?: (string|null);
|
13559
13766
|
|
13560
13767
|
/** FunctionCall args */
|
13561
13768
|
args?: (Uint8Array|null);
|
@@ -13577,7 +13784,7 @@ export namespace TW {
|
|
13577
13784
|
constructor(properties?: TW.NEAR.Proto.IFunctionCall);
|
13578
13785
|
|
13579
13786
|
/** FunctionCall methodName. */
|
13580
|
-
public methodName:
|
13787
|
+
public methodName: string;
|
13581
13788
|
|
13582
13789
|
/** FunctionCall args. */
|
13583
13790
|
public args: Uint8Array;
|