coreum-js 2.16.2 → 2.17.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/dist/main/client/index.js +16 -17
- package/dist/main/coreum/asset/ft/v1/authz.d.ts +38 -0
- package/dist/main/coreum/asset/ft/v1/authz.js +122 -0
- package/dist/main/coreum/asset/ft/v1/event.d.ts +52 -120
- package/dist/main/coreum/asset/ft/v1/event.js +744 -138
- package/dist/main/coreum/asset/ft/v1/genesis.d.ts +31 -517
- package/dist/main/coreum/asset/ft/v1/genesis.js +273 -62
- package/dist/main/coreum/asset/ft/v1/params.d.ts +12 -63
- package/dist/main/coreum/asset/ft/v1/params.js +37 -33
- package/dist/main/coreum/asset/ft/v1/query.d.ts +86 -1950
- package/dist/main/coreum/asset/ft/v1/query.js +697 -217
- package/dist/main/coreum/asset/ft/v1/token.d.ts +17 -249
- package/dist/main/coreum/asset/ft/v1/token.js +273 -197
- package/dist/main/coreum/asset/ft/v1/tx.d.ts +30 -755
- package/dist/main/coreum/asset/ft/v1/tx.js +502 -386
- package/dist/main/coreum/asset/index.d.ts +2 -3
- package/dist/main/coreum/asset/nft/v1/authz.d.ts +33 -0
- package/dist/main/coreum/asset/nft/v1/authz.js +137 -0
- package/dist/main/coreum/asset/nft/v1/event.d.ts +35 -147
- package/dist/main/coreum/asset/nft/v1/event.js +475 -147
- package/dist/main/coreum/asset/nft/v1/genesis.d.ts +27 -286
- package/dist/main/coreum/asset/nft/v1/genesis.js +311 -119
- package/dist/main/coreum/asset/nft/v1/nft.d.ts +20 -108
- package/dist/main/coreum/asset/nft/v1/nft.js +136 -101
- package/dist/main/coreum/asset/nft/v1/params.d.ts +12 -38
- package/dist/main/coreum/asset/nft/v1/params.js +17 -20
- package/dist/main/coreum/asset/nft/v1/query.d.ts +110 -706
- package/dist/main/coreum/asset/nft/v1/query.js +1079 -185
- package/dist/main/coreum/asset/nft/v1/tx.d.ts +96 -266
- package/dist/main/coreum/asset/nft/v1/tx.js +865 -234
- package/dist/main/coreum/asset/nft/v1/types.d.ts +38 -19
- package/dist/main/coreum/asset/nft/v1/types.js +273 -45
- package/dist/main/coreum/customparams/v1/genesis.d.ts +12 -32
- package/dist/main/coreum/customparams/v1/genesis.js +26 -22
- package/dist/main/coreum/customparams/v1/params.d.ts +11 -19
- package/dist/main/coreum/customparams/v1/params.js +23 -20
- package/dist/main/coreum/customparams/v1/query.d.ts +14 -40
- package/dist/main/coreum/customparams/v1/query.js +35 -29
- package/dist/main/coreum/dex/index.d.ts +1 -0
- package/dist/main/coreum/dex/index.js +12 -0
- package/dist/main/coreum/dex/v1/event.d.ts +73 -0
- package/dist/main/coreum/dex/v1/event.js +470 -0
- package/dist/main/coreum/dex/v1/genesis.d.ts +49 -0
- package/dist/main/coreum/dex/v1/genesis.js +318 -0
- package/dist/main/coreum/dex/v1/order.d.ts +172 -0
- package/dist/main/coreum/dex/v1/order.js +1137 -0
- package/dist/main/coreum/dex/v1/params.d.ts +34 -0
- package/dist/main/coreum/dex/v1/params.js +139 -0
- package/dist/main/coreum/dex/v1/query.d.ts +133 -0
- package/dist/main/coreum/dex/v1/query.js +873 -0
- package/dist/main/coreum/dex/v1/tx.d.ts +102 -0
- package/dist/main/coreum/dex/v1/tx.js +521 -0
- package/dist/main/coreum/extensions/dex.d.ts +12 -0
- package/dist/main/coreum/extensions/dex.js +32 -0
- package/dist/main/coreum/feemodel/v1/genesis.d.ts +13 -233
- package/dist/main/coreum/feemodel/v1/genesis.js +23 -24
- package/dist/main/coreum/feemodel/v1/params.d.ts +14 -337
- package/dist/main/coreum/feemodel/v1/params.js +113 -66
- package/dist/main/coreum/feemodel/v1/query.d.ts +30 -261
- package/dist/main/coreum/feemodel/v1/query.js +196 -43
- package/dist/main/coreum/index.d.ts +46 -0
- package/dist/main/coreum/index.js +58 -1
- package/dist/main/coreum/nft/index.d.ts +1 -2
- package/dist/main/coreum/nft/v1beta1/event.d.ts +23 -79
- package/dist/main/coreum/nft/v1beta1/event.js +103 -77
- package/dist/main/coreum/nft/v1beta1/genesis.d.ts +13 -435
- package/dist/main/coreum/nft/v1beta1/genesis.js +50 -52
- package/dist/main/coreum/nft/v1beta1/nft.d.ts +15 -114
- package/dist/main/coreum/nft/v1beta1/nft.js +111 -81
- package/dist/main/coreum/nft/v1beta1/query.d.ts +54 -1628
- package/dist/main/coreum/nft/v1beta1/query.js +259 -223
- package/dist/main/coreum/nft/v1beta1/tx.d.ts +13 -39
- package/dist/main/coreum/nft/v1beta1/tx.js +54 -43
- package/dist/main/cosmos/extensions/distribution.d.ts +4 -4
- package/dist/main/cosmos/extensions/distribution.js +9 -9
- package/dist/main/cosmos/extensions/gov.d.ts +13 -13
- package/dist/main/cosmos/extensions/gov.js +14 -8
- package/dist/main/cosmos/index.d.ts +8 -8
- package/dist/main/google/api/http.js +18 -21
- package/dist/main/google/protobuf/any.js +3 -4
- package/dist/main/google/protobuf/duration.js +3 -4
- package/dist/main/google/protobuf/timestamp.js +3 -4
- package/dist/main/services/cosmostation.js +1 -1
- package/dist/main/tendermint/abci/types.js +183 -223
- package/dist/main/tendermint/crypto/keys.js +3 -4
- package/dist/main/tendermint/crypto/proof.js +19 -24
- package/dist/main/tendermint/types/params.js +15 -20
- package/dist/main/tendermint/types/types.js +57 -68
- package/dist/main/tendermint/types/validator.js +10 -13
- package/dist/main/tendermint/version/types.js +6 -8
- package/dist/main/types/core.d.ts +2 -1
- package/dist/main/types/core.js +2 -0
- package/dist/main/wasm/v1/authz.d.ts +20 -471
- package/dist/main/wasm/v1/authz.js +129 -148
- package/dist/main/wasm/v1/genesis.d.ts +14 -1020
- package/dist/main/wasm/v1/genesis.js +169 -140
- package/dist/main/wasm/v1/ibc.d.ts +13 -62
- package/dist/main/wasm/v1/ibc.js +91 -76
- package/dist/main/wasm/v1/index.d.ts +1 -2
- package/dist/main/wasm/v1/pagination.js +9 -11
- package/dist/main/wasm/v1/proposal.d.ts +23 -720
- package/dist/main/wasm/v1/proposal.js +634 -465
- package/dist/main/wasm/v1/query.d.ts +35 -1201
- package/dist/main/wasm/v1/query.js +370 -363
- package/dist/main/wasm/v1/tx.d.ts +37 -788
- package/dist/main/wasm/v1/tx.js +621 -497
- package/dist/main/wasm/v1/types.d.ts +19 -297
- package/dist/main/wasm/v1/types.js +219 -190
- package/dist/module/client/index.js +4 -3
- package/dist/module/coreum/asset/ft/v1/authz.d.ts +38 -0
- package/dist/module/coreum/asset/ft/v1/authz.js +119 -0
- package/dist/module/coreum/asset/ft/v1/event.d.ts +52 -120
- package/dist/module/coreum/asset/ft/v1/event.js +721 -109
- package/dist/module/coreum/asset/ft/v1/genesis.d.ts +31 -517
- package/dist/module/coreum/asset/ft/v1/genesis.js +266 -50
- package/dist/module/coreum/asset/ft/v1/params.d.ts +12 -63
- package/dist/module/coreum/asset/ft/v1/params.js +35 -27
- package/dist/module/coreum/asset/ft/v1/query.d.ts +86 -1950
- package/dist/module/coreum/asset/ft/v1/query.js +672 -180
- package/dist/module/coreum/asset/ft/v1/token.d.ts +17 -249
- package/dist/module/coreum/asset/ft/v1/token.js +236 -152
- package/dist/module/coreum/asset/ft/v1/tx.d.ts +30 -755
- package/dist/module/coreum/asset/ft/v1/tx.js +437 -301
- package/dist/module/coreum/asset/index.d.ts +2 -3
- package/dist/module/coreum/asset/nft/v1/authz.d.ts +33 -0
- package/dist/module/coreum/asset/nft/v1/authz.js +134 -0
- package/dist/module/coreum/asset/nft/v1/event.d.ts +35 -147
- package/dist/module/coreum/asset/nft/v1/event.js +448 -112
- package/dist/module/coreum/asset/nft/v1/genesis.d.ts +27 -286
- package/dist/module/coreum/asset/nft/v1/genesis.js +299 -100
- package/dist/module/coreum/asset/nft/v1/nft.d.ts +20 -108
- package/dist/module/coreum/asset/nft/v1/nft.js +121 -81
- package/dist/module/coreum/asset/nft/v1/params.d.ts +12 -38
- package/dist/module/coreum/asset/nft/v1/params.js +16 -16
- package/dist/module/coreum/asset/nft/v1/query.d.ts +110 -706
- package/dist/module/coreum/asset/nft/v1/query.js +1057 -153
- package/dist/module/coreum/asset/nft/v1/tx.d.ts +96 -266
- package/dist/module/coreum/asset/nft/v1/tx.js +825 -184
- package/dist/module/coreum/asset/nft/v1/types.d.ts +38 -19
- package/dist/module/coreum/asset/nft/v1/types.js +269 -39
- package/dist/module/coreum/customparams/v1/genesis.d.ts +12 -32
- package/dist/module/coreum/customparams/v1/genesis.js +25 -18
- package/dist/module/coreum/customparams/v1/params.d.ts +11 -19
- package/dist/module/coreum/customparams/v1/params.js +21 -14
- package/dist/module/coreum/customparams/v1/query.d.ts +14 -40
- package/dist/module/coreum/customparams/v1/query.js +32 -23
- package/dist/module/coreum/dex/index.d.ts +1 -0
- package/dist/module/coreum/dex/index.js +9 -0
- package/dist/module/coreum/dex/v1/event.d.ts +73 -0
- package/dist/module/coreum/dex/v1/event.js +467 -0
- package/dist/module/coreum/dex/v1/genesis.d.ts +49 -0
- package/dist/module/coreum/dex/v1/genesis.js +315 -0
- package/dist/module/coreum/dex/v1/order.d.ts +172 -0
- package/dist/module/coreum/dex/v1/order.js +1128 -0
- package/dist/module/coreum/dex/v1/params.d.ts +34 -0
- package/dist/module/coreum/dex/v1/params.js +136 -0
- package/dist/module/coreum/dex/v1/query.d.ts +133 -0
- package/dist/module/coreum/dex/v1/query.js +871 -0
- package/dist/module/coreum/dex/v1/tx.d.ts +102 -0
- package/dist/module/coreum/dex/v1/tx.js +519 -0
- package/dist/module/coreum/extensions/dex.d.ts +12 -0
- package/dist/module/coreum/extensions/dex.js +28 -0
- package/dist/module/coreum/feemodel/v1/genesis.d.ts +13 -233
- package/dist/module/coreum/feemodel/v1/genesis.js +22 -20
- package/dist/module/coreum/feemodel/v1/params.d.ts +14 -337
- package/dist/module/coreum/feemodel/v1/params.js +105 -54
- package/dist/module/coreum/feemodel/v1/query.d.ts +30 -261
- package/dist/module/coreum/feemodel/v1/query.js +191 -35
- package/dist/module/coreum/index.d.ts +46 -0
- package/dist/module/coreum/index.js +57 -0
- package/dist/module/coreum/nft/index.d.ts +1 -2
- package/dist/module/coreum/nft/v1beta1/event.d.ts +23 -79
- package/dist/module/coreum/nft/v1beta1/event.js +90 -58
- package/dist/module/coreum/nft/v1beta1/genesis.d.ts +13 -435
- package/dist/module/coreum/nft/v1beta1/genesis.js +44 -41
- package/dist/module/coreum/nft/v1beta1/nft.d.ts +15 -114
- package/dist/module/coreum/nft/v1beta1/nft.js +99 -64
- package/dist/module/coreum/nft/v1beta1/query.d.ts +54 -1628
- package/dist/module/coreum/nft/v1beta1/query.js +231 -183
- package/dist/module/coreum/nft/v1beta1/tx.d.ts +13 -39
- package/dist/module/coreum/nft/v1beta1/tx.js +47 -32
- package/dist/module/cosmos/extensions/distribution.d.ts +4 -4
- package/dist/module/cosmos/extensions/gov.d.ts +13 -13
- package/dist/module/cosmos/index.d.ts +8 -8
- package/dist/module/services/cosmostation.js +1 -1
- package/dist/module/types/core.d.ts +2 -1
- package/dist/module/types/core.js +2 -0
- package/dist/module/wasm/v1/authz.d.ts +20 -471
- package/dist/module/wasm/v1/authz.js +111 -119
- package/dist/module/wasm/v1/genesis.d.ts +14 -1020
- package/dist/module/wasm/v1/genesis.js +161 -125
- package/dist/module/wasm/v1/ibc.d.ts +13 -62
- package/dist/module/wasm/v1/ibc.js +83 -62
- package/dist/module/wasm/v1/index.d.ts +1 -2
- package/dist/module/wasm/v1/proposal.d.ts +23 -720
- package/dist/module/wasm/v1/proposal.js +562 -377
- package/dist/module/wasm/v1/query.d.ts +35 -1201
- package/dist/module/wasm/v1/query.js +330 -301
- package/dist/module/wasm/v1/tx.d.ts +37 -788
- package/dist/module/wasm/v1/tx.js +551 -404
- package/dist/module/wasm/v1/types.d.ts +19 -297
- package/dist/module/wasm/v1/types.js +196 -156
- package/package.json +11 -10
|
@@ -3,11 +3,12 @@ import { cosmwasmRegistry } from "../wasm/v1";
|
|
|
3
3
|
import { setupFTExtension } from "../coreum/extensions/ft";
|
|
4
4
|
import { setupNFTExtension } from "../coreum/extensions/nft";
|
|
5
5
|
import { setupNFTBetaExtension } from "../coreum/extensions/nftbeta";
|
|
6
|
+
import { setupDexExtension } from "../coreum/extensions/dex";
|
|
6
7
|
import { connectKeplr, connectCosmostation, getCosmosOfflineSigner, connectLeap, getLeapOfflineSigner, } from "../services";
|
|
7
8
|
import { COREUM_CONFIG } from "../types/coreum";
|
|
8
9
|
import { QueryClientImpl as FeeModelClient } from "../coreum/feemodel/v1/query";
|
|
9
10
|
import { Registry, } from "@cosmjs/proto-signing";
|
|
10
|
-
import {
|
|
11
|
+
import { Tendermint37Client, WebsocketClient } from "@cosmjs/tendermint-rpc";
|
|
11
12
|
import { ExtensionWallets } from "../types";
|
|
12
13
|
import { generateWalletFromMnemonic, generateMultisigFromPubkeys, } from "../utils";
|
|
13
14
|
import { GasPrice, QueryClient, StargateClient, calculateFee, createProtobufRpcClient, decodeCosmosSdkDecFromProto, defaultRegistryTypes, setupAuthExtension, setupFeegrantExtension, setupIbcExtension, setupMintExtension, setupStakingExtension, setupTxExtension, } from "@cosmjs/stargate";
|
|
@@ -362,10 +363,10 @@ export class Client {
|
|
|
362
363
|
throw new Error("Signing Client is not initialized");
|
|
363
364
|
}
|
|
364
365
|
async _initTendermintClient(rpcEndpoint) {
|
|
365
|
-
this._tmClient = await
|
|
366
|
+
this._tmClient = await Tendermint37Client.connect(rpcEndpoint);
|
|
366
367
|
}
|
|
367
368
|
_initQueryClient() {
|
|
368
|
-
this._queryClient = QueryClient.withExtensions(this._tmClient, setupFTExtension, setupNFTExtension, setupNFTBetaExtension, setupStakingExtension, setupBankExtension, setupDistributionExtension, setupTxExtension, setupAuthExtension, setupMintExtension, setupFeegrantExtension, setupGovExtension, setupIbcExtension, setupWasmExtension);
|
|
369
|
+
this._queryClient = QueryClient.withExtensions(this._tmClient, setupFTExtension, setupNFTExtension, setupNFTBetaExtension, setupStakingExtension, setupBankExtension, setupDistributionExtension, setupTxExtension, setupAuthExtension, setupMintExtension, setupFeegrantExtension, setupGovExtension, setupIbcExtension, setupWasmExtension, setupDexExtension);
|
|
369
370
|
}
|
|
370
371
|
_initFeeModel() {
|
|
371
372
|
const rpcClient = createProtobufRpcClient(this._queryClient);
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { BinaryReader, BinaryWriter } from "cosmjs-types/binary";
|
|
2
|
+
import { Coin } from "cosmjs-types/cosmos/base/v1beta1/coin";
|
|
3
|
+
export declare const protobufPackage = "coreum.asset.ft.v1";
|
|
4
|
+
/**
|
|
5
|
+
* MintAuthorization allows the grantee to mint up to mint_limit coin from
|
|
6
|
+
* the granter's account.
|
|
7
|
+
*/
|
|
8
|
+
export interface MintAuthorization {
|
|
9
|
+
mintLimit: Coin[];
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* BurnAuthorization allows the grantee to burn up to burn_limit coin from
|
|
13
|
+
* the granter's account.
|
|
14
|
+
*/
|
|
15
|
+
export interface BurnAuthorization {
|
|
16
|
+
burnLimit: Coin[];
|
|
17
|
+
}
|
|
18
|
+
export declare const MintAuthorization: MessageFns<MintAuthorization>;
|
|
19
|
+
export declare const BurnAuthorization: MessageFns<BurnAuthorization>;
|
|
20
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
21
|
+
export type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
|
|
22
|
+
[K in keyof T]?: DeepPartial<T[K]>;
|
|
23
|
+
} : Partial<T>;
|
|
24
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
25
|
+
export type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
26
|
+
[K in keyof P]: Exact<P[K], I[K]>;
|
|
27
|
+
} & {
|
|
28
|
+
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
29
|
+
};
|
|
30
|
+
export interface MessageFns<T> {
|
|
31
|
+
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
32
|
+
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
33
|
+
fromJSON(object: any): T;
|
|
34
|
+
toJSON(message: T): unknown;
|
|
35
|
+
create<I extends Exact<DeepPartial<T>, I>>(base?: I): T;
|
|
36
|
+
fromPartial<I extends Exact<DeepPartial<T>, I>>(object: I): T;
|
|
37
|
+
}
|
|
38
|
+
export {};
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
2
|
+
// versions:
|
|
3
|
+
// protoc-gen-ts_proto v2.7.0
|
|
4
|
+
// protoc v3.21.12
|
|
5
|
+
// source: coreum-protos/ft/authz.proto
|
|
6
|
+
/* eslint-disable */
|
|
7
|
+
import { BinaryReader, BinaryWriter } from "cosmjs-types/binary";
|
|
8
|
+
import { Coin } from "cosmjs-types/cosmos/base/v1beta1/coin";
|
|
9
|
+
export const protobufPackage = "coreum.asset.ft.v1";
|
|
10
|
+
function createBaseMintAuthorization() {
|
|
11
|
+
return { mintLimit: [] };
|
|
12
|
+
}
|
|
13
|
+
export const MintAuthorization = {
|
|
14
|
+
encode(message, writer = new BinaryWriter()) {
|
|
15
|
+
for (const v of message.mintLimit) {
|
|
16
|
+
Coin.encode(v, writer.uint32(10).fork()).ldelim();
|
|
17
|
+
}
|
|
18
|
+
return writer;
|
|
19
|
+
},
|
|
20
|
+
decode(input, length) {
|
|
21
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
22
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
23
|
+
const message = createBaseMintAuthorization();
|
|
24
|
+
while (reader.pos < end) {
|
|
25
|
+
const tag = reader.uint32();
|
|
26
|
+
switch (tag >>> 3) {
|
|
27
|
+
case 1: {
|
|
28
|
+
if (tag !== 10) {
|
|
29
|
+
break;
|
|
30
|
+
}
|
|
31
|
+
message.mintLimit.push(Coin.decode(reader, reader.uint32()));
|
|
32
|
+
continue;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
36
|
+
break;
|
|
37
|
+
}
|
|
38
|
+
reader.skip(tag & 7);
|
|
39
|
+
}
|
|
40
|
+
return message;
|
|
41
|
+
},
|
|
42
|
+
fromJSON(object) {
|
|
43
|
+
return {
|
|
44
|
+
mintLimit: globalThis.Array.isArray(object?.mintLimit)
|
|
45
|
+
? object.mintLimit.map((e) => Coin.fromJSON(e))
|
|
46
|
+
: [],
|
|
47
|
+
};
|
|
48
|
+
},
|
|
49
|
+
toJSON(message) {
|
|
50
|
+
const obj = {};
|
|
51
|
+
if (message.mintLimit?.length) {
|
|
52
|
+
obj.mintLimit = message.mintLimit.map((e) => Coin.toJSON(e));
|
|
53
|
+
}
|
|
54
|
+
return obj;
|
|
55
|
+
},
|
|
56
|
+
create(base) {
|
|
57
|
+
return MintAuthorization.fromPartial(base ?? {});
|
|
58
|
+
},
|
|
59
|
+
fromPartial(object) {
|
|
60
|
+
const message = createBaseMintAuthorization();
|
|
61
|
+
message.mintLimit = object.mintLimit?.map((e) => Coin.fromPartial(e)) || [];
|
|
62
|
+
return message;
|
|
63
|
+
},
|
|
64
|
+
};
|
|
65
|
+
function createBaseBurnAuthorization() {
|
|
66
|
+
return { burnLimit: [] };
|
|
67
|
+
}
|
|
68
|
+
export const BurnAuthorization = {
|
|
69
|
+
encode(message, writer = new BinaryWriter()) {
|
|
70
|
+
for (const v of message.burnLimit) {
|
|
71
|
+
Coin.encode(v, writer.uint32(10).fork()).ldelim();
|
|
72
|
+
}
|
|
73
|
+
return writer;
|
|
74
|
+
},
|
|
75
|
+
decode(input, length) {
|
|
76
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
77
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
78
|
+
const message = createBaseBurnAuthorization();
|
|
79
|
+
while (reader.pos < end) {
|
|
80
|
+
const tag = reader.uint32();
|
|
81
|
+
switch (tag >>> 3) {
|
|
82
|
+
case 1: {
|
|
83
|
+
if (tag !== 10) {
|
|
84
|
+
break;
|
|
85
|
+
}
|
|
86
|
+
message.burnLimit.push(Coin.decode(reader, reader.uint32()));
|
|
87
|
+
continue;
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
91
|
+
break;
|
|
92
|
+
}
|
|
93
|
+
reader.skip(tag & 7);
|
|
94
|
+
}
|
|
95
|
+
return message;
|
|
96
|
+
},
|
|
97
|
+
fromJSON(object) {
|
|
98
|
+
return {
|
|
99
|
+
burnLimit: globalThis.Array.isArray(object?.burnLimit)
|
|
100
|
+
? object.burnLimit.map((e) => Coin.fromJSON(e))
|
|
101
|
+
: [],
|
|
102
|
+
};
|
|
103
|
+
},
|
|
104
|
+
toJSON(message) {
|
|
105
|
+
const obj = {};
|
|
106
|
+
if (message.burnLimit?.length) {
|
|
107
|
+
obj.burnLimit = message.burnLimit.map((e) => Coin.toJSON(e));
|
|
108
|
+
}
|
|
109
|
+
return obj;
|
|
110
|
+
},
|
|
111
|
+
create(base) {
|
|
112
|
+
return BurnAuthorization.fromPartial(base ?? {});
|
|
113
|
+
},
|
|
114
|
+
fromPartial(object) {
|
|
115
|
+
const message = createBaseBurnAuthorization();
|
|
116
|
+
message.burnLimit = object.burnLimit?.map((e) => Coin.fromPartial(e)) || [];
|
|
117
|
+
return message;
|
|
118
|
+
},
|
|
119
|
+
};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import { Feature } from "./token";
|
|
1
|
+
import { BinaryReader, BinaryWriter } from "cosmjs-types/binary";
|
|
2
|
+
import { DEXSettings, Feature } from "./token";
|
|
4
3
|
export declare const protobufPackage = "coreum.asset.ft.v1";
|
|
5
4
|
/** EventIssued is emitted on MsgIssue. */
|
|
6
5
|
export interface EventIssued {
|
|
@@ -16,6 +15,8 @@ export interface EventIssued {
|
|
|
16
15
|
sendCommissionRate: string;
|
|
17
16
|
uri: string;
|
|
18
17
|
uriHash: string;
|
|
18
|
+
admin: string;
|
|
19
|
+
dexSettings: DEXSettings | undefined;
|
|
19
20
|
}
|
|
20
21
|
export interface EventFrozenAmountChanged {
|
|
21
22
|
account: string;
|
|
@@ -23,130 +24,53 @@ export interface EventFrozenAmountChanged {
|
|
|
23
24
|
previousAmount: string;
|
|
24
25
|
currentAmount: string;
|
|
25
26
|
}
|
|
27
|
+
export interface EventAmountClawedBack {
|
|
28
|
+
account: string;
|
|
29
|
+
denom: string;
|
|
30
|
+
amount: string;
|
|
31
|
+
}
|
|
26
32
|
export interface EventWhitelistedAmountChanged {
|
|
27
33
|
account: string;
|
|
28
34
|
denom: string;
|
|
29
35
|
previousAmount: string;
|
|
30
36
|
currentAmount: string;
|
|
31
37
|
}
|
|
32
|
-
export
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
issuer?: string;
|
|
67
|
-
symbol?: string;
|
|
68
|
-
subunit?: string;
|
|
69
|
-
precision?: number;
|
|
70
|
-
initialAmount?: string;
|
|
71
|
-
description?: string;
|
|
72
|
-
features?: Feature[];
|
|
73
|
-
burnRate?: string;
|
|
74
|
-
sendCommissionRate?: string;
|
|
75
|
-
uri?: string;
|
|
76
|
-
uriHash?: string;
|
|
77
|
-
} & {
|
|
78
|
-
denom?: string;
|
|
79
|
-
issuer?: string;
|
|
80
|
-
symbol?: string;
|
|
81
|
-
subunit?: string;
|
|
82
|
-
precision?: number;
|
|
83
|
-
initialAmount?: string;
|
|
84
|
-
description?: string;
|
|
85
|
-
features?: Feature[] & Feature[] & { [K_2 in Exclude<keyof I_1["features"], keyof Feature[]>]: never; };
|
|
86
|
-
burnRate?: string;
|
|
87
|
-
sendCommissionRate?: string;
|
|
88
|
-
uri?: string;
|
|
89
|
-
uriHash?: string;
|
|
90
|
-
} & { [K_3 in Exclude<keyof I_1, keyof EventIssued>]: never; }>(object: I_1): EventIssued;
|
|
91
|
-
};
|
|
92
|
-
export declare const EventFrozenAmountChanged: {
|
|
93
|
-
encode(message: EventFrozenAmountChanged, writer?: _m0.Writer): _m0.Writer;
|
|
94
|
-
decode(input: _m0.Reader | Uint8Array, length?: number): EventFrozenAmountChanged;
|
|
95
|
-
fromJSON(object: any): EventFrozenAmountChanged;
|
|
96
|
-
toJSON(message: EventFrozenAmountChanged): unknown;
|
|
97
|
-
create<I extends {
|
|
98
|
-
account?: string;
|
|
99
|
-
denom?: string;
|
|
100
|
-
previousAmount?: string;
|
|
101
|
-
currentAmount?: string;
|
|
102
|
-
} & {
|
|
103
|
-
account?: string;
|
|
104
|
-
denom?: string;
|
|
105
|
-
previousAmount?: string;
|
|
106
|
-
currentAmount?: string;
|
|
107
|
-
} & { [K in Exclude<keyof I, keyof EventFrozenAmountChanged>]: never; }>(base?: I): EventFrozenAmountChanged;
|
|
108
|
-
fromPartial<I_1 extends {
|
|
109
|
-
account?: string;
|
|
110
|
-
denom?: string;
|
|
111
|
-
previousAmount?: string;
|
|
112
|
-
currentAmount?: string;
|
|
113
|
-
} & {
|
|
114
|
-
account?: string;
|
|
115
|
-
denom?: string;
|
|
116
|
-
previousAmount?: string;
|
|
117
|
-
currentAmount?: string;
|
|
118
|
-
} & { [K_1 in Exclude<keyof I_1, keyof EventFrozenAmountChanged>]: never; }>(object: I_1): EventFrozenAmountChanged;
|
|
119
|
-
};
|
|
120
|
-
export declare const EventWhitelistedAmountChanged: {
|
|
121
|
-
encode(message: EventWhitelistedAmountChanged, writer?: _m0.Writer): _m0.Writer;
|
|
122
|
-
decode(input: _m0.Reader | Uint8Array, length?: number): EventWhitelistedAmountChanged;
|
|
123
|
-
fromJSON(object: any): EventWhitelistedAmountChanged;
|
|
124
|
-
toJSON(message: EventWhitelistedAmountChanged): unknown;
|
|
125
|
-
create<I extends {
|
|
126
|
-
account?: string;
|
|
127
|
-
denom?: string;
|
|
128
|
-
previousAmount?: string;
|
|
129
|
-
currentAmount?: string;
|
|
130
|
-
} & {
|
|
131
|
-
account?: string;
|
|
132
|
-
denom?: string;
|
|
133
|
-
previousAmount?: string;
|
|
134
|
-
currentAmount?: string;
|
|
135
|
-
} & { [K in Exclude<keyof I, keyof EventWhitelistedAmountChanged>]: never; }>(base?: I): EventWhitelistedAmountChanged;
|
|
136
|
-
fromPartial<I_1 extends {
|
|
137
|
-
account?: string;
|
|
138
|
-
denom?: string;
|
|
139
|
-
previousAmount?: string;
|
|
140
|
-
currentAmount?: string;
|
|
141
|
-
} & {
|
|
142
|
-
account?: string;
|
|
143
|
-
denom?: string;
|
|
144
|
-
previousAmount?: string;
|
|
145
|
-
currentAmount?: string;
|
|
146
|
-
} & { [K_1 in Exclude<keyof I_1, keyof EventWhitelistedAmountChanged>]: never; }>(object: I_1): EventWhitelistedAmountChanged;
|
|
147
|
-
};
|
|
38
|
+
export interface EventDEXLockedAmountChanged {
|
|
39
|
+
account: string;
|
|
40
|
+
denom: string;
|
|
41
|
+
previousAmount: string;
|
|
42
|
+
currentAmount: string;
|
|
43
|
+
}
|
|
44
|
+
export interface EventDEXExpectedToReceiveAmountChanged {
|
|
45
|
+
account: string;
|
|
46
|
+
denom: string;
|
|
47
|
+
previousAmount: string;
|
|
48
|
+
currentAmount: string;
|
|
49
|
+
}
|
|
50
|
+
export interface EventAdminTransferred {
|
|
51
|
+
denom: string;
|
|
52
|
+
previousAdmin: string;
|
|
53
|
+
currentAdmin: string;
|
|
54
|
+
}
|
|
55
|
+
export interface EventAdminCleared {
|
|
56
|
+
denom: string;
|
|
57
|
+
previousAdmin: string;
|
|
58
|
+
}
|
|
59
|
+
export interface EventDEXSettingsChanged {
|
|
60
|
+
previousSettings: DEXSettings | undefined;
|
|
61
|
+
newSettings: DEXSettings | undefined;
|
|
62
|
+
}
|
|
63
|
+
export declare const EventIssued: MessageFns<EventIssued>;
|
|
64
|
+
export declare const EventFrozenAmountChanged: MessageFns<EventFrozenAmountChanged>;
|
|
65
|
+
export declare const EventAmountClawedBack: MessageFns<EventAmountClawedBack>;
|
|
66
|
+
export declare const EventWhitelistedAmountChanged: MessageFns<EventWhitelistedAmountChanged>;
|
|
67
|
+
export declare const EventDEXLockedAmountChanged: MessageFns<EventDEXLockedAmountChanged>;
|
|
68
|
+
export declare const EventDEXExpectedToReceiveAmountChanged: MessageFns<EventDEXExpectedToReceiveAmountChanged>;
|
|
69
|
+
export declare const EventAdminTransferred: MessageFns<EventAdminTransferred>;
|
|
70
|
+
export declare const EventAdminCleared: MessageFns<EventAdminCleared>;
|
|
71
|
+
export declare const EventDEXSettingsChanged: MessageFns<EventDEXSettingsChanged>;
|
|
148
72
|
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
149
|
-
export type DeepPartial<T> = T extends Builtin ? T : T extends
|
|
73
|
+
export type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
|
|
150
74
|
[K in keyof T]?: DeepPartial<T[K]>;
|
|
151
75
|
} : Partial<T>;
|
|
152
76
|
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
@@ -155,4 +79,12 @@ export type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
|
155
79
|
} & {
|
|
156
80
|
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
157
81
|
};
|
|
82
|
+
export interface MessageFns<T> {
|
|
83
|
+
encode(message: T, writer?: BinaryWriter): BinaryWriter;
|
|
84
|
+
decode(input: BinaryReader | Uint8Array, length?: number): T;
|
|
85
|
+
fromJSON(object: any): T;
|
|
86
|
+
toJSON(message: T): unknown;
|
|
87
|
+
create<I extends Exact<DeepPartial<T>, I>>(base?: I): T;
|
|
88
|
+
fromPartial<I extends Exact<DeepPartial<T>, I>>(object: I): T;
|
|
89
|
+
}
|
|
158
90
|
export {};
|