injectivejs 1.9.14 → 1.9.16

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.
Files changed (88) hide show
  1. package/README.md +1 -1
  2. package/binary.d.ts +1 -1
  3. package/binary.js +1 -1
  4. package/cosmos/authz/v1beta1/tx.rpc.func.d.ts +3 -3
  5. package/cosmos/bank/v1beta1/tx.rpc.func.d.ts +4 -4
  6. package/cosmos/base/v1beta1/coin.js +7 -7
  7. package/cosmos/distribution/v1beta1/distribution.js +16 -16
  8. package/cosmos/distribution/v1beta1/tx.rpc.func.d.ts +7 -7
  9. package/cosmos/feegrant/v1beta1/tx.rpc.func.d.ts +3 -3
  10. package/cosmos/gov/v1/tx.rpc.func.d.ts +7 -7
  11. package/cosmos/gov/v1beta1/gov.js +4 -4
  12. package/cosmos/gov/v1beta1/tx.rpc.func.d.ts +4 -4
  13. package/cosmos/group/v1/tx.rpc.func.d.ts +14 -14
  14. package/cosmos/staking/v1beta1/staking.js +22 -22
  15. package/cosmos/staking/v1beta1/tx.js +4 -4
  16. package/cosmos/staking/v1beta1/tx.rpc.func.d.ts +7 -7
  17. package/cosmos/vesting/v1beta1/tx.rpc.func.d.ts +3 -3
  18. package/cosmwasm/wasm/v1/tx.rpc.func.d.ts +17 -17
  19. package/esm/binary.js +1 -1
  20. package/esm/cosmos/base/v1beta1/coin.js +3 -3
  21. package/esm/cosmos/distribution/v1beta1/distribution.js +6 -6
  22. package/esm/cosmos/gov/v1beta1/gov.js +2 -2
  23. package/esm/cosmos/staking/v1beta1/staking.js +8 -8
  24. package/esm/cosmos/staking/v1beta1/tx.js +2 -2
  25. package/esm/extern.js +1 -1
  26. package/esm/helper-func-types.js +1 -1
  27. package/esm/helpers.js +1 -1
  28. package/esm/injective/auction/v1beta1/auction.js +2 -2
  29. package/esm/injective/exchange/v1beta1/events.js +7 -7
  30. package/esm/injective/exchange/v1beta1/exchange.js +92 -92
  31. package/esm/injective/exchange/v1beta1/genesis.js +3 -3
  32. package/esm/injective/exchange/v1beta1/proposal.js +50 -50
  33. package/esm/injective/exchange/v1beta1/query.js +45 -45
  34. package/esm/injective/exchange/v1beta1/tx.js +41 -41
  35. package/esm/injective/ocr/v1beta1/ocr.js +9 -9
  36. package/esm/injective/oracle/v1beta1/events.js +7 -7
  37. package/esm/injective/oracle/v1beta1/oracle.js +16 -16
  38. package/esm/injective/oracle/v1beta1/query.js +7 -7
  39. package/esm/injective/oracle/v1beta1/tx.js +3 -3
  40. package/esm/injective/stream/v1beta1/query.js +11 -11
  41. package/esm/registry.js +1 -1
  42. package/esm/types.js +1 -1
  43. package/esm/utf8.js +1 -1
  44. package/esm/varint.js +1 -1
  45. package/extern.d.ts +1 -1
  46. package/extern.js +1 -1
  47. package/helper-func-types.d.ts +3 -66
  48. package/helper-func-types.js +1 -1
  49. package/helpers.d.ts +1 -1
  50. package/helpers.js +1 -1
  51. package/ibc/applications/transfer/v1/tx.rpc.func.d.ts +2 -2
  52. package/ibc/core/channel/v1/tx.rpc.func.d.ts +19 -19
  53. package/ibc/core/client/v1/tx.rpc.func.d.ts +7 -7
  54. package/ibc/core/connection/v1/tx.rpc.func.d.ts +5 -5
  55. package/injective/auction/v1beta1/auction.js +4 -4
  56. package/injective/auction/v1beta1/tx.rpc.func.d.ts +2 -2
  57. package/injective/exchange/v1beta1/events.js +19 -19
  58. package/injective/exchange/v1beta1/exchange.js +274 -274
  59. package/injective/exchange/v1beta1/genesis.js +7 -7
  60. package/injective/exchange/v1beta1/proposal.js +148 -148
  61. package/injective/exchange/v1beta1/query.js +133 -133
  62. package/injective/exchange/v1beta1/tx.js +121 -121
  63. package/injective/exchange/v1beta1/tx.rpc.func.d.ts +35 -35
  64. package/injective/insurance/v1beta1/tx.rpc.func.d.ts +4 -4
  65. package/injective/ocr/v1beta1/ocr.js +25 -25
  66. package/injective/ocr/v1beta1/tx.rpc.func.d.ts +9 -9
  67. package/injective/oracle/v1beta1/events.js +19 -19
  68. package/injective/oracle/v1beta1/oracle.js +46 -46
  69. package/injective/oracle/v1beta1/query.js +19 -19
  70. package/injective/oracle/v1beta1/tx.js +7 -7
  71. package/injective/oracle/v1beta1/tx.rpc.func.d.ts +8 -8
  72. package/injective/peggy/v1/msgs.rpc.func.d.ts +14 -14
  73. package/injective/permissions/v1beta1/tx.rpc.func.d.ts +7 -7
  74. package/injective/stream/v1beta1/query.js +31 -31
  75. package/injective/tokenfactory/v1beta1/tx.rpc.func.d.ts +6 -6
  76. package/injective/wasmx/v1/tx.rpc.func.d.ts +6 -6
  77. package/package.json +8 -8
  78. package/registry.d.ts +1 -1
  79. package/registry.js +1 -1
  80. package/types.d.ts +1 -1
  81. package/types.js +1 -1
  82. package/utf8.d.ts +1 -1
  83. package/utf8.js +1 -1
  84. package/varint.d.ts +1 -1
  85. package/varint.js +1 -1
  86. package/decimals.d.ts +0 -20
  87. package/decimals.js +0 -102
  88. package/esm/decimals.js +0 -98
package/README.md CHANGED
@@ -66,7 +66,7 @@ import { createQueryRpc } from "@interchainjs/cosmos/utils";
66
66
  import { createGetAllBalances } from "injectivejs/cosmos/bank/v1beta1/query.rpc.func";
67
67
  import { createGetExchangeBalances } from "injectivejs/injective/exchange/v1beta1/query.rpc.func";
68
68
 
69
- { getRpcEndpoint } = useChain("osmosis");
69
+ { getRpcEndpoint } = useChain("injective");
70
70
 
71
71
  const endpoint = await getRpcEndpoint();
72
72
  const rpc = createQueryRpc(endpoint);
package/binary.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * This file and any referenced files were automatically generated by @cosmology/telescope@1.11.20
2
+ * This file and any referenced files were automatically generated by @cosmology/telescope@1.11.25
3
3
  * DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
4
4
  * and run the transpile command or npm scripts command that is used to regenerate this bundle.
5
5
  */
package/binary.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  /**
3
- * This file and any referenced files were automatically generated by @cosmology/telescope@1.11.20
3
+ * This file and any referenced files were automatically generated by @cosmology/telescope@1.11.25
4
4
  * DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
5
5
  * and run the transpile command or npm scripts command that is used to regenerate this bundle.
6
6
  */
@@ -1,5 +1,5 @@
1
1
  import { SigningClientResolver } from "../../../helper-func-types";
2
2
  import { MsgGrant, MsgExec, MsgRevoke } from "./tx";
3
- export declare const createGrant: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgGrant | MsgGrant[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
4
- export declare const createExec: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgExec | MsgExec[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
5
- export declare const createRevoke: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgRevoke | MsgRevoke[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
3
+ export declare const createGrant: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgGrant | MsgGrant[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
4
+ export declare const createExec: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgExec | MsgExec[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
5
+ export declare const createRevoke: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgRevoke | MsgRevoke[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
@@ -1,6 +1,6 @@
1
1
  import { SigningClientResolver } from "../../../helper-func-types";
2
2
  import { MsgSend, MsgMultiSend, MsgUpdateParams, MsgSetSendEnabled } from "./tx";
3
- export declare const createSend: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSend | MsgSend[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
4
- export declare const createMultiSend: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgMultiSend | MsgMultiSend[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
5
- export declare const createUpdateParams: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateParams | MsgUpdateParams[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
6
- export declare const createSetSendEnabled: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSetSendEnabled | MsgSetSendEnabled[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
3
+ export declare const createSend: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSend | MsgSend[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
4
+ export declare const createMultiSend: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgMultiSend | MsgMultiSend[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
5
+ export declare const createUpdateParams: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateParams | MsgUpdateParams[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
6
+ export declare const createSetSendEnabled: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSetSendEnabled | MsgSetSendEnabled[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.DecProto = exports.IntProto = exports.DecCoin = exports.Coin = void 0;
4
4
  const binary_1 = require("../../../binary");
5
- const decimals_1 = require("../../../decimals");
5
+ const math_1 = require("@interchainjs/math");
6
6
  function createBaseCoin() {
7
7
  return {
8
8
  denom: "",
@@ -112,7 +112,7 @@ exports.DecCoin = {
112
112
  writer.uint32(10).string(message.denom);
113
113
  }
114
114
  if (message.amount !== "") {
115
- writer.uint32(18).string(decimals_1.Decimal.fromUserInput(message.amount, 18).atomics);
115
+ writer.uint32(18).string(math_1.Decimal.fromUserInput(message.amount, 18).atomics);
116
116
  }
117
117
  return writer;
118
118
  },
@@ -127,7 +127,7 @@ exports.DecCoin = {
127
127
  message.denom = reader.string();
128
128
  break;
129
129
  case 2:
130
- message.amount = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
130
+ message.amount = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
131
131
  break;
132
132
  default:
133
133
  reader.skipType(tag & 7);
@@ -155,7 +155,7 @@ exports.DecCoin = {
155
155
  toAmino(message) {
156
156
  const obj = {};
157
157
  obj.denom = message.denom === "" ? undefined : message.denom;
158
- obj.amount = message.amount === "" ? undefined : message.amount;
158
+ obj.amount = message.amount === "" ? undefined : math_1.Decimal.fromUserInput(message.amount, 18).atomics;
159
159
  return obj;
160
160
  },
161
161
  fromAminoMsg(object) {
@@ -274,7 +274,7 @@ exports.DecProto = {
274
274
  },
275
275
  encode(message, writer = binary_1.BinaryWriter.create()) {
276
276
  if (message.dec !== "") {
277
- writer.uint32(10).string(decimals_1.Decimal.fromUserInput(message.dec, 18).atomics);
277
+ writer.uint32(10).string(math_1.Decimal.fromUserInput(message.dec, 18).atomics);
278
278
  }
279
279
  return writer;
280
280
  },
@@ -286,7 +286,7 @@ exports.DecProto = {
286
286
  const tag = reader.uint32();
287
287
  switch (tag >>> 3) {
288
288
  case 1:
289
- message.dec = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
289
+ message.dec = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
290
290
  break;
291
291
  default:
292
292
  reader.skipType(tag & 7);
@@ -309,7 +309,7 @@ exports.DecProto = {
309
309
  },
310
310
  toAmino(message) {
311
311
  const obj = {};
312
- obj.dec = message.dec === "" ? undefined : message.dec;
312
+ obj.dec = message.dec === "" ? undefined : math_1.Decimal.fromUserInput(message.dec, 18).atomics;
313
313
  return obj;
314
314
  },
315
315
  fromAminoMsg(object) {
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.CommunityPoolSpendProposalWithDeposit = exports.DelegationDelegatorReward = exports.DelegatorStartingInfo = exports.CommunityPoolSpendProposal = exports.FeePool = exports.ValidatorSlashEvents = exports.ValidatorSlashEvent = exports.ValidatorOutstandingRewards = exports.ValidatorAccumulatedCommission = exports.ValidatorCurrentRewards = exports.ValidatorHistoricalRewards = exports.Params = void 0;
4
4
  const coin_1 = require("../../base/v1beta1/coin");
5
5
  const binary_1 = require("../../../binary");
6
- const decimals_1 = require("../../../decimals");
6
+ const math_1 = require("@interchainjs/math");
7
7
  const registry_1 = require("../../../registry");
8
8
  function createBaseParams() {
9
9
  return {
@@ -24,13 +24,13 @@ exports.Params = {
24
24
  },
25
25
  encode(message, writer = binary_1.BinaryWriter.create()) {
26
26
  if (message.communityTax !== "") {
27
- writer.uint32(10).string(decimals_1.Decimal.fromUserInput(message.communityTax, 18).atomics);
27
+ writer.uint32(10).string(math_1.Decimal.fromUserInput(message.communityTax, 18).atomics);
28
28
  }
29
29
  if (message.baseProposerReward !== "") {
30
- writer.uint32(18).string(decimals_1.Decimal.fromUserInput(message.baseProposerReward, 18).atomics);
30
+ writer.uint32(18).string(math_1.Decimal.fromUserInput(message.baseProposerReward, 18).atomics);
31
31
  }
32
32
  if (message.bonusProposerReward !== "") {
33
- writer.uint32(26).string(decimals_1.Decimal.fromUserInput(message.bonusProposerReward, 18).atomics);
33
+ writer.uint32(26).string(math_1.Decimal.fromUserInput(message.bonusProposerReward, 18).atomics);
34
34
  }
35
35
  if (message.withdrawAddrEnabled === true) {
36
36
  writer.uint32(32).bool(message.withdrawAddrEnabled);
@@ -45,13 +45,13 @@ exports.Params = {
45
45
  const tag = reader.uint32();
46
46
  switch (tag >>> 3) {
47
47
  case 1:
48
- message.communityTax = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
48
+ message.communityTax = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
49
49
  break;
50
50
  case 2:
51
- message.baseProposerReward = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
51
+ message.baseProposerReward = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
52
52
  break;
53
53
  case 3:
54
- message.bonusProposerReward = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
54
+ message.bonusProposerReward = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
55
55
  break;
56
56
  case 4:
57
57
  message.withdrawAddrEnabled = reader.bool();
@@ -89,9 +89,9 @@ exports.Params = {
89
89
  },
90
90
  toAmino(message) {
91
91
  const obj = {};
92
- obj.community_tax = message.communityTax ?? "";
93
- obj.base_proposer_reward = message.baseProposerReward ?? "";
94
- obj.bonus_proposer_reward = message.bonusProposerReward ?? "";
92
+ obj.community_tax = math_1.Decimal.fromUserInput(message.communityTax, 18).atomics ?? "";
93
+ obj.base_proposer_reward = math_1.Decimal.fromUserInput(message.baseProposerReward, 18).atomics ?? "";
94
+ obj.bonus_proposer_reward = math_1.Decimal.fromUserInput(message.bonusProposerReward, 18).atomics ?? "";
95
95
  obj.withdraw_addr_enabled = message.withdrawAddrEnabled === false ? undefined : message.withdrawAddrEnabled;
96
96
  return obj;
97
97
  },
@@ -490,7 +490,7 @@ exports.ValidatorSlashEvent = {
490
490
  writer.uint32(8).uint64(message.validatorPeriod);
491
491
  }
492
492
  if (message.fraction !== "") {
493
- writer.uint32(18).string(decimals_1.Decimal.fromUserInput(message.fraction, 18).atomics);
493
+ writer.uint32(18).string(math_1.Decimal.fromUserInput(message.fraction, 18).atomics);
494
494
  }
495
495
  return writer;
496
496
  },
@@ -505,7 +505,7 @@ exports.ValidatorSlashEvent = {
505
505
  message.validatorPeriod = reader.uint64();
506
506
  break;
507
507
  case 2:
508
- message.fraction = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
508
+ message.fraction = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
509
509
  break;
510
510
  default:
511
511
  reader.skipType(tag & 7);
@@ -533,7 +533,7 @@ exports.ValidatorSlashEvent = {
533
533
  toAmino(message) {
534
534
  const obj = {};
535
535
  obj.validator_period = message.validatorPeriod !== BigInt(0) ? message.validatorPeriod?.toString() : undefined;
536
- obj.fraction = message.fraction === "" ? undefined : message.fraction;
536
+ obj.fraction = message.fraction === "" ? undefined : math_1.Decimal.fromUserInput(message.fraction, 18).atomics;
537
537
  return obj;
538
538
  },
539
539
  fromAminoMsg(object) {
@@ -864,7 +864,7 @@ exports.DelegatorStartingInfo = {
864
864
  writer.uint32(8).uint64(message.previousPeriod);
865
865
  }
866
866
  if (message.stake !== "") {
867
- writer.uint32(18).string(decimals_1.Decimal.fromUserInput(message.stake, 18).atomics);
867
+ writer.uint32(18).string(math_1.Decimal.fromUserInput(message.stake, 18).atomics);
868
868
  }
869
869
  if (message.height !== BigInt(0)) {
870
870
  writer.uint32(24).uint64(message.height);
@@ -882,7 +882,7 @@ exports.DelegatorStartingInfo = {
882
882
  message.previousPeriod = reader.uint64();
883
883
  break;
884
884
  case 2:
885
- message.stake = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
885
+ message.stake = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
886
886
  break;
887
887
  case 3:
888
888
  message.height = reader.uint64();
@@ -917,7 +917,7 @@ exports.DelegatorStartingInfo = {
917
917
  toAmino(message) {
918
918
  const obj = {};
919
919
  obj.previous_period = message.previousPeriod !== BigInt(0) ? message.previousPeriod?.toString() : undefined;
920
- obj.stake = message.stake ?? "";
920
+ obj.stake = math_1.Decimal.fromUserInput(message.stake, 18).atomics ?? "";
921
921
  obj.height = message.height ? message.height?.toString() : "0";
922
922
  return obj;
923
923
  },
@@ -1,9 +1,9 @@
1
1
  import { SigningClientResolver } from "../../../helper-func-types";
2
2
  import { MsgSetWithdrawAddress, MsgWithdrawDelegatorReward, MsgWithdrawValidatorCommission, MsgFundCommunityPool, MsgUpdateParams, MsgCommunityPoolSpend, MsgDepositValidatorRewardsPool } from "./tx";
3
- export declare const createSetWithdrawAddress: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSetWithdrawAddress | MsgSetWithdrawAddress[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
4
- export declare const createWithdrawDelegatorReward: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgWithdrawDelegatorReward | MsgWithdrawDelegatorReward[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
5
- export declare const createWithdrawValidatorCommission: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgWithdrawValidatorCommission | MsgWithdrawValidatorCommission[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
6
- export declare const createFundCommunityPool: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgFundCommunityPool | MsgFundCommunityPool[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
7
- export declare const createUpdateParams: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateParams | MsgUpdateParams[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
8
- export declare const createCommunityPoolSpend: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCommunityPoolSpend | MsgCommunityPoolSpend[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
9
- export declare const createDepositValidatorRewardsPool: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgDepositValidatorRewardsPool | MsgDepositValidatorRewardsPool[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
3
+ export declare const createSetWithdrawAddress: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSetWithdrawAddress | MsgSetWithdrawAddress[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
4
+ export declare const createWithdrawDelegatorReward: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgWithdrawDelegatorReward | MsgWithdrawDelegatorReward[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
5
+ export declare const createWithdrawValidatorCommission: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgWithdrawValidatorCommission | MsgWithdrawValidatorCommission[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
6
+ export declare const createFundCommunityPool: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgFundCommunityPool | MsgFundCommunityPool[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
7
+ export declare const createUpdateParams: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateParams | MsgUpdateParams[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
8
+ export declare const createCommunityPoolSpend: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCommunityPoolSpend | MsgCommunityPoolSpend[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
9
+ export declare const createDepositValidatorRewardsPool: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgDepositValidatorRewardsPool | MsgDepositValidatorRewardsPool[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
@@ -1,5 +1,5 @@
1
1
  import { SigningClientResolver } from "../../../helper-func-types";
2
2
  import { MsgGrantAllowance, MsgRevokeAllowance, MsgPruneAllowances } from "./tx";
3
- export declare const createGrantAllowance: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgGrantAllowance | MsgGrantAllowance[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
4
- export declare const createRevokeAllowance: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgRevokeAllowance | MsgRevokeAllowance[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
5
- export declare const createPruneAllowances: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgPruneAllowances | MsgPruneAllowances[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
3
+ export declare const createGrantAllowance: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgGrantAllowance | MsgGrantAllowance[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
4
+ export declare const createRevokeAllowance: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgRevokeAllowance | MsgRevokeAllowance[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
5
+ export declare const createPruneAllowances: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgPruneAllowances | MsgPruneAllowances[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
@@ -1,9 +1,9 @@
1
1
  import { SigningClientResolver } from "../../../helper-func-types";
2
2
  import { MsgSubmitProposal, MsgExecLegacyContent, MsgVote, MsgVoteWeighted, MsgDeposit, MsgUpdateParams, MsgCancelProposal } from "./tx";
3
- export declare const createSubmitProposal: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSubmitProposal | MsgSubmitProposal[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
4
- export declare const createExecLegacyContent: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgExecLegacyContent | MsgExecLegacyContent[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
5
- export declare const createVote: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgVote | MsgVote[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
6
- export declare const createVoteWeighted: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgVoteWeighted | MsgVoteWeighted[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
7
- export declare const createDeposit: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgDeposit | MsgDeposit[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
8
- export declare const createUpdateParams: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateParams | MsgUpdateParams[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
9
- export declare const createCancelProposal: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCancelProposal | MsgCancelProposal[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
3
+ export declare const createSubmitProposal: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSubmitProposal | MsgSubmitProposal[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
4
+ export declare const createExecLegacyContent: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgExecLegacyContent | MsgExecLegacyContent[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
5
+ export declare const createVote: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgVote | MsgVote[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
6
+ export declare const createVoteWeighted: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgVoteWeighted | MsgVoteWeighted[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
7
+ export declare const createDeposit: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgDeposit | MsgDeposit[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
8
+ export declare const createUpdateParams: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateParams | MsgUpdateParams[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
9
+ export declare const createCancelProposal: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCancelProposal | MsgCancelProposal[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
@@ -19,7 +19,7 @@ const proposal_3 = require("../../../injective/peggy/v1/proposal");
19
19
  const proposal_4 = require("../../../injective/wasmx/v1/proposal");
20
20
  const helpers_1 = require("../../../helpers");
21
21
  const binary_1 = require("../../../binary");
22
- const decimals_1 = require("../../../decimals");
22
+ const math_1 = require("@interchainjs/math");
23
23
  const registry_1 = require("../../../registry");
24
24
  /** VoteOption enumerates the valid vote options for a given governance proposal. */
25
25
  var VoteOption;
@@ -175,7 +175,7 @@ exports.WeightedVoteOption = {
175
175
  writer.uint32(8).int32(message.option);
176
176
  }
177
177
  if (message.weight !== "") {
178
- writer.uint32(18).string(decimals_1.Decimal.fromUserInput(message.weight, 18).atomics);
178
+ writer.uint32(18).string(math_1.Decimal.fromUserInput(message.weight, 18).atomics);
179
179
  }
180
180
  return writer;
181
181
  },
@@ -190,7 +190,7 @@ exports.WeightedVoteOption = {
190
190
  message.option = reader.int32();
191
191
  break;
192
192
  case 2:
193
- message.weight = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
193
+ message.weight = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
194
194
  break;
195
195
  default:
196
196
  reader.skipType(tag & 7);
@@ -218,7 +218,7 @@ exports.WeightedVoteOption = {
218
218
  toAmino(message) {
219
219
  const obj = {};
220
220
  obj.option = message.option === 0 ? undefined : message.option;
221
- obj.weight = message.weight ?? "";
221
+ obj.weight = math_1.Decimal.fromUserInput(message.weight, 18).atomics ?? "";
222
222
  return obj;
223
223
  },
224
224
  fromAminoMsg(object) {
@@ -1,6 +1,6 @@
1
1
  import { SigningClientResolver } from "../../../helper-func-types";
2
2
  import { MsgSubmitProposal, MsgVote, MsgVoteWeighted, MsgDeposit } from "./tx";
3
- export declare const createSubmitProposal: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSubmitProposal | MsgSubmitProposal[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
4
- export declare const createVote: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgVote | MsgVote[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
5
- export declare const createVoteWeighted: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgVoteWeighted | MsgVoteWeighted[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
6
- export declare const createDeposit: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgDeposit | MsgDeposit[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
3
+ export declare const createSubmitProposal: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSubmitProposal | MsgSubmitProposal[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
4
+ export declare const createVote: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgVote | MsgVote[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
5
+ export declare const createVoteWeighted: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgVoteWeighted | MsgVoteWeighted[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
6
+ export declare const createDeposit: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgDeposit | MsgDeposit[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
@@ -1,16 +1,16 @@
1
1
  import { SigningClientResolver } from "../../../helper-func-types";
2
2
  import { MsgCreateGroup, MsgUpdateGroupMembers, MsgUpdateGroupAdmin, MsgUpdateGroupMetadata, MsgCreateGroupPolicy, MsgCreateGroupWithPolicy, MsgUpdateGroupPolicyAdmin, MsgUpdateGroupPolicyDecisionPolicy, MsgUpdateGroupPolicyMetadata, MsgSubmitProposal, MsgWithdrawProposal, MsgVote, MsgExec, MsgLeaveGroup } from "./tx";
3
- export declare const createCreateGroup: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCreateGroup | MsgCreateGroup[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
4
- export declare const createUpdateGroupMembers: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupMembers | MsgUpdateGroupMembers[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
5
- export declare const createUpdateGroupAdmin: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupAdmin | MsgUpdateGroupAdmin[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
6
- export declare const createUpdateGroupMetadata: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupMetadata | MsgUpdateGroupMetadata[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
7
- export declare const createCreateGroupPolicy: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCreateGroupPolicy | MsgCreateGroupPolicy[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
8
- export declare const createCreateGroupWithPolicy: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCreateGroupWithPolicy | MsgCreateGroupWithPolicy[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
9
- export declare const createUpdateGroupPolicyAdmin: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupPolicyAdmin | MsgUpdateGroupPolicyAdmin[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
10
- export declare const createUpdateGroupPolicyDecisionPolicy: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupPolicyDecisionPolicy | MsgUpdateGroupPolicyDecisionPolicy[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
11
- export declare const createUpdateGroupPolicyMetadata: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupPolicyMetadata | MsgUpdateGroupPolicyMetadata[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
12
- export declare const createSubmitProposal: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSubmitProposal | MsgSubmitProposal[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
13
- export declare const createWithdrawProposal: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgWithdrawProposal | MsgWithdrawProposal[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
14
- export declare const createVote: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgVote | MsgVote[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
15
- export declare const createExec: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgExec | MsgExec[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
16
- export declare const createLeaveGroup: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgLeaveGroup | MsgLeaveGroup[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
3
+ export declare const createCreateGroup: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCreateGroup | MsgCreateGroup[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
4
+ export declare const createUpdateGroupMembers: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupMembers | MsgUpdateGroupMembers[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
5
+ export declare const createUpdateGroupAdmin: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupAdmin | MsgUpdateGroupAdmin[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
6
+ export declare const createUpdateGroupMetadata: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupMetadata | MsgUpdateGroupMetadata[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
7
+ export declare const createCreateGroupPolicy: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCreateGroupPolicy | MsgCreateGroupPolicy[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
8
+ export declare const createCreateGroupWithPolicy: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCreateGroupWithPolicy | MsgCreateGroupWithPolicy[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
9
+ export declare const createUpdateGroupPolicyAdmin: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupPolicyAdmin | MsgUpdateGroupPolicyAdmin[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
10
+ export declare const createUpdateGroupPolicyDecisionPolicy: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupPolicyDecisionPolicy | MsgUpdateGroupPolicyDecisionPolicy[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
11
+ export declare const createUpdateGroupPolicyMetadata: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateGroupPolicyMetadata | MsgUpdateGroupPolicyMetadata[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
12
+ export declare const createSubmitProposal: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgSubmitProposal | MsgSubmitProposal[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
13
+ export declare const createWithdrawProposal: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgWithdrawProposal | MsgWithdrawProposal[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
14
+ export declare const createVote: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgVote | MsgVote[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
15
+ export declare const createExec: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgExec | MsgExec[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
16
+ export declare const createLeaveGroup: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgLeaveGroup | MsgLeaveGroup[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
@@ -14,7 +14,7 @@ const types_2 = require("../../../tendermint/abci/types");
14
14
  const binary_1 = require("../../../binary");
15
15
  const registry_1 = require("../../../registry");
16
16
  const helpers_1 = require("../../../helpers");
17
- const decimals_1 = require("../../../decimals");
17
+ const math_1 = require("@interchainjs/math");
18
18
  const pubkey_1 = require("@interchainjs/pubkey");
19
19
  /** BondStatus is the status of a validator. */
20
20
  var BondStatus;
@@ -220,13 +220,13 @@ exports.CommissionRates = {
220
220
  },
221
221
  encode(message, writer = binary_1.BinaryWriter.create()) {
222
222
  if (message.rate !== "") {
223
- writer.uint32(10).string(decimals_1.Decimal.fromUserInput(message.rate, 18).atomics);
223
+ writer.uint32(10).string(math_1.Decimal.fromUserInput(message.rate, 18).atomics);
224
224
  }
225
225
  if (message.maxRate !== "") {
226
- writer.uint32(18).string(decimals_1.Decimal.fromUserInput(message.maxRate, 18).atomics);
226
+ writer.uint32(18).string(math_1.Decimal.fromUserInput(message.maxRate, 18).atomics);
227
227
  }
228
228
  if (message.maxChangeRate !== "") {
229
- writer.uint32(26).string(decimals_1.Decimal.fromUserInput(message.maxChangeRate, 18).atomics);
229
+ writer.uint32(26).string(math_1.Decimal.fromUserInput(message.maxChangeRate, 18).atomics);
230
230
  }
231
231
  return writer;
232
232
  },
@@ -238,13 +238,13 @@ exports.CommissionRates = {
238
238
  const tag = reader.uint32();
239
239
  switch (tag >>> 3) {
240
240
  case 1:
241
- message.rate = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
241
+ message.rate = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
242
242
  break;
243
243
  case 2:
244
- message.maxRate = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
244
+ message.maxRate = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
245
245
  break;
246
246
  case 3:
247
- message.maxChangeRate = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
247
+ message.maxChangeRate = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
248
248
  break;
249
249
  default:
250
250
  reader.skipType(tag & 7);
@@ -275,9 +275,9 @@ exports.CommissionRates = {
275
275
  },
276
276
  toAmino(message) {
277
277
  const obj = {};
278
- obj.rate = message.rate ?? "";
279
- obj.max_rate = message.maxRate ?? "";
280
- obj.max_change_rate = message.maxChangeRate ?? "";
278
+ obj.rate = math_1.Decimal.fromUserInput(message.rate, 18).atomics ?? "";
279
+ obj.max_rate = math_1.Decimal.fromUserInput(message.maxRate, 18).atomics ?? "";
280
+ obj.max_change_rate = math_1.Decimal.fromUserInput(message.maxChangeRate, 18).atomics ?? "";
281
281
  return obj;
282
282
  },
283
283
  fromAminoMsg(object) {
@@ -562,7 +562,7 @@ exports.Validator = {
562
562
  writer.uint32(42).string(message.tokens);
563
563
  }
564
564
  if (message.delegatorShares !== "") {
565
- writer.uint32(50).string(decimals_1.Decimal.fromUserInput(message.delegatorShares, 18).atomics);
565
+ writer.uint32(50).string(math_1.Decimal.fromUserInput(message.delegatorShares, 18).atomics);
566
566
  }
567
567
  if (message.description !== undefined) {
568
568
  exports.Description.encode(message.description, writer.uint32(58).fork()).ldelim();
@@ -612,7 +612,7 @@ exports.Validator = {
612
612
  message.tokens = reader.string();
613
613
  break;
614
614
  case 6:
615
- message.delegatorShares = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
615
+ message.delegatorShares = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
616
616
  break;
617
617
  case 7:
618
618
  message.description = exports.Description.decode(reader, reader.uint32());
@@ -715,7 +715,7 @@ exports.Validator = {
715
715
  obj.jailed = message.jailed === false ? undefined : message.jailed;
716
716
  obj.status = message.status === 0 ? undefined : message.status;
717
717
  obj.tokens = message.tokens === "" ? undefined : message.tokens;
718
- obj.delegator_shares = message.delegatorShares === "" ? undefined : message.delegatorShares;
718
+ obj.delegator_shares = message.delegatorShares === "" ? undefined : math_1.Decimal.fromUserInput(message.delegatorShares, 18).atomics;
719
719
  obj.description = message.description ? exports.Description.toAmino(message.description) : exports.Description.toAmino(exports.Description.fromPartial({}));
720
720
  obj.unbonding_height = message.unbondingHeight !== BigInt(0) ? message.unbondingHeight?.toString() : undefined;
721
721
  obj.unbonding_time = message.unbondingTime ? timestamp_1.Timestamp.toAmino((0, helpers_1.toTimestamp)(message.unbondingTime)) : new Date();
@@ -1214,7 +1214,7 @@ exports.Delegation = {
1214
1214
  writer.uint32(18).string(message.validatorAddress);
1215
1215
  }
1216
1216
  if (message.shares !== "") {
1217
- writer.uint32(26).string(decimals_1.Decimal.fromUserInput(message.shares, 18).atomics);
1217
+ writer.uint32(26).string(math_1.Decimal.fromUserInput(message.shares, 18).atomics);
1218
1218
  }
1219
1219
  return writer;
1220
1220
  },
@@ -1232,7 +1232,7 @@ exports.Delegation = {
1232
1232
  message.validatorAddress = reader.string();
1233
1233
  break;
1234
1234
  case 3:
1235
- message.shares = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
1235
+ message.shares = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
1236
1236
  break;
1237
1237
  default:
1238
1238
  reader.skipType(tag & 7);
@@ -1265,7 +1265,7 @@ exports.Delegation = {
1265
1265
  const obj = {};
1266
1266
  obj.delegator_address = message.delegatorAddress === "" ? undefined : message.delegatorAddress;
1267
1267
  obj.validator_address = message.validatorAddress === "" ? undefined : message.validatorAddress;
1268
- obj.shares = message.shares === "" ? undefined : message.shares;
1268
+ obj.shares = message.shares === "" ? undefined : math_1.Decimal.fromUserInput(message.shares, 18).atomics;
1269
1269
  return obj;
1270
1270
  },
1271
1271
  fromAminoMsg(object) {
@@ -1564,7 +1564,7 @@ exports.RedelegationEntry = {
1564
1564
  writer.uint32(26).string(message.initialBalance);
1565
1565
  }
1566
1566
  if (message.sharesDst !== "") {
1567
- writer.uint32(34).string(decimals_1.Decimal.fromUserInput(message.sharesDst, 18).atomics);
1567
+ writer.uint32(34).string(math_1.Decimal.fromUserInput(message.sharesDst, 18).atomics);
1568
1568
  }
1569
1569
  if (message.unbondingId !== BigInt(0)) {
1570
1570
  writer.uint32(40).uint64(message.unbondingId);
@@ -1591,7 +1591,7 @@ exports.RedelegationEntry = {
1591
1591
  message.initialBalance = reader.string();
1592
1592
  break;
1593
1593
  case 4:
1594
- message.sharesDst = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
1594
+ message.sharesDst = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
1595
1595
  break;
1596
1596
  case 5:
1597
1597
  message.unbondingId = reader.uint64();
@@ -1643,7 +1643,7 @@ exports.RedelegationEntry = {
1643
1643
  obj.creation_height = message.creationHeight !== BigInt(0) ? message.creationHeight?.toString() : undefined;
1644
1644
  obj.completion_time = message.completionTime ? timestamp_1.Timestamp.toAmino((0, helpers_1.toTimestamp)(message.completionTime)) : new Date();
1645
1645
  obj.initial_balance = message.initialBalance === "" ? undefined : message.initialBalance;
1646
- obj.shares_dst = message.sharesDst === "" ? undefined : message.sharesDst;
1646
+ obj.shares_dst = message.sharesDst === "" ? undefined : math_1.Decimal.fromUserInput(message.sharesDst, 18).atomics;
1647
1647
  obj.unbonding_id = message.unbondingId !== BigInt(0) ? message.unbondingId?.toString() : undefined;
1648
1648
  obj.unbonding_on_hold_ref_count = message.unbondingOnHoldRefCount !== BigInt(0) ? message.unbondingOnHoldRefCount?.toString() : undefined;
1649
1649
  return obj;
@@ -1825,7 +1825,7 @@ exports.Params = {
1825
1825
  writer.uint32(42).string(message.bondDenom);
1826
1826
  }
1827
1827
  if (message.minCommissionRate !== "") {
1828
- writer.uint32(50).string(decimals_1.Decimal.fromUserInput(message.minCommissionRate, 18).atomics);
1828
+ writer.uint32(50).string(math_1.Decimal.fromUserInput(message.minCommissionRate, 18).atomics);
1829
1829
  }
1830
1830
  return writer;
1831
1831
  },
@@ -1852,7 +1852,7 @@ exports.Params = {
1852
1852
  message.bondDenom = reader.string();
1853
1853
  break;
1854
1854
  case 6:
1855
- message.minCommissionRate = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
1855
+ message.minCommissionRate = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
1856
1856
  break;
1857
1857
  default:
1858
1858
  reader.skipType(tag & 7);
@@ -1900,7 +1900,7 @@ exports.Params = {
1900
1900
  obj.max_entries = message.maxEntries === 0 ? undefined : message.maxEntries;
1901
1901
  obj.historical_entries = message.historicalEntries === 0 ? undefined : message.historicalEntries;
1902
1902
  obj.bond_denom = message.bondDenom === "" ? undefined : message.bondDenom;
1903
- obj.min_commission_rate = message.minCommissionRate ?? "";
1903
+ obj.min_commission_rate = math_1.Decimal.fromUserInput(message.minCommissionRate, 18).atomics ?? "";
1904
1904
  return obj;
1905
1905
  },
1906
1906
  fromAminoMsg(object) {
@@ -9,7 +9,7 @@ const binary_1 = require("../../../binary");
9
9
  const registry_1 = require("../../../registry");
10
10
  const helpers_1 = require("../../../helpers");
11
11
  const pubkey_1 = require("@interchainjs/pubkey");
12
- const decimals_1 = require("../../../decimals");
12
+ const math_1 = require("@interchainjs/math");
13
13
  function createBaseMsgCreateValidator() {
14
14
  return {
15
15
  description: staking_1.Description.fromPartial({}),
@@ -250,7 +250,7 @@ exports.MsgEditValidator = {
250
250
  writer.uint32(18).string(message.validatorAddress);
251
251
  }
252
252
  if (message.commissionRate !== "") {
253
- writer.uint32(26).string(decimals_1.Decimal.fromUserInput(message.commissionRate, 18).atomics);
253
+ writer.uint32(26).string(math_1.Decimal.fromUserInput(message.commissionRate, 18).atomics);
254
254
  }
255
255
  if (message.minSelfDelegation !== "") {
256
256
  writer.uint32(34).string(message.minSelfDelegation);
@@ -271,7 +271,7 @@ exports.MsgEditValidator = {
271
271
  message.validatorAddress = reader.string();
272
272
  break;
273
273
  case 3:
274
- message.commissionRate = decimals_1.Decimal.fromAtomics(reader.string(), 18).toString();
274
+ message.commissionRate = math_1.Decimal.fromAtomics(reader.string(), 18).toString();
275
275
  break;
276
276
  case 4:
277
277
  message.minSelfDelegation = reader.string();
@@ -311,7 +311,7 @@ exports.MsgEditValidator = {
311
311
  const obj = {};
312
312
  obj.description = message.description ? staking_1.Description.toAmino(message.description) : staking_1.Description.toAmino(staking_1.Description.fromPartial({}));
313
313
  obj.validator_address = message.validatorAddress === "" ? undefined : message.validatorAddress;
314
- obj.commission_rate = message.commissionRate === "" ? undefined : message.commissionRate;
314
+ obj.commission_rate = message.commissionRate === "" ? undefined : math_1.Decimal.fromUserInput(message.commissionRate, 18).atomics;
315
315
  obj.min_self_delegation = message.minSelfDelegation === "" ? undefined : message.minSelfDelegation;
316
316
  return obj;
317
317
  },
@@ -1,9 +1,9 @@
1
1
  import { SigningClientResolver } from "../../../helper-func-types";
2
2
  import { MsgCreateValidator, MsgEditValidator, MsgDelegate, MsgBeginRedelegate, MsgUndelegate, MsgCancelUnbondingDelegation, MsgUpdateParams } from "./tx";
3
- export declare const createCreateValidator: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCreateValidator | MsgCreateValidator[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
4
- export declare const createEditValidator: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgEditValidator | MsgEditValidator[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
5
- export declare const createDelegate: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgDelegate | MsgDelegate[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
6
- export declare const createBeginRedelegate: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgBeginRedelegate | MsgBeginRedelegate[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
7
- export declare const createUndelegate: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUndelegate | MsgUndelegate[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
8
- export declare const createCancelUnbondingDelegation: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCancelUnbondingDelegation | MsgCancelUnbondingDelegation[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
9
- export declare const createUpdateParams: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateParams | MsgUpdateParams[], fee: import("../../../helper-func-types").StdFee | "auto", memo: string) => Promise<import("../../../helper-func-types").DeliverTxResponse>;
3
+ export declare const createCreateValidator: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCreateValidator | MsgCreateValidator[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
4
+ export declare const createEditValidator: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgEditValidator | MsgEditValidator[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
5
+ export declare const createDelegate: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgDelegate | MsgDelegate[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
6
+ export declare const createBeginRedelegate: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgBeginRedelegate | MsgBeginRedelegate[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
7
+ export declare const createUndelegate: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUndelegate | MsgUndelegate[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
8
+ export declare const createCancelUnbondingDelegation: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgCancelUnbondingDelegation | MsgCancelUnbondingDelegation[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;
9
+ export declare const createUpdateParams: (clientResolver?: SigningClientResolver) => (signerAddress: string, message: MsgUpdateParams | MsgUpdateParams[], fee: import("../../../types").StdFee | "auto", memo: string) => Promise<import("../../../types").DeliverTxResponse>;