Merge pull request #124 from cosmos/fix/invalid-staking-amount
Fix invalid staking amount type
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { useAppContext } from "../../../context/AppContext";
|
||||
import { printableCoins } from "../../../lib/displayHelpers";
|
||||
import { printableCoin } from "../../../lib/displayHelpers";
|
||||
import { TxMsgDelegate } from "../../../types/txMsg";
|
||||
import HashView from "../HashView";
|
||||
|
||||
@@ -17,7 +17,7 @@ const TxMsgDelegateDetails = ({ msg }: TxMsgDelegateDetailsProps) => {
|
||||
</li>
|
||||
<li>
|
||||
<label>Amount:</label>
|
||||
<div>{printableCoins(msg.value.amount, state.chain)}</div>
|
||||
<div>{printableCoin(msg.value.amount, state.chain)}</div>
|
||||
</li>
|
||||
<li>
|
||||
<label>Validator Address:</label>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { useAppContext } from "../../../context/AppContext";
|
||||
import { printableCoins } from "../../../lib/displayHelpers";
|
||||
import { printableCoin } from "../../../lib/displayHelpers";
|
||||
import { TxMsgRedelegate } from "../../../types/txMsg";
|
||||
import HashView from "../HashView";
|
||||
|
||||
@@ -17,7 +17,7 @@ const TxMsgRedelegateDetails = ({ msg }: TxMsgRedelegateDetailsProps) => {
|
||||
</li>
|
||||
<li>
|
||||
<label>Amount:</label>
|
||||
<div>{printableCoins(msg.value.amount, state.chain)}</div>
|
||||
<div>{printableCoin(msg.value.amount, state.chain)}</div>
|
||||
</li>
|
||||
<li>
|
||||
<label>Src Validator Address:</label>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { useAppContext } from "../../../context/AppContext";
|
||||
import { printableCoins } from "../../../lib/displayHelpers";
|
||||
import { printableCoin } from "../../../lib/displayHelpers";
|
||||
import { TxMsgUndelegate } from "../../../types/txMsg";
|
||||
import HashView from "../HashView";
|
||||
|
||||
@@ -17,7 +17,7 @@ const TxMsgUndelegateDetails = ({ msg }: TxMsgUndelegateDetailsProps) => {
|
||||
</li>
|
||||
<li>
|
||||
<label>Amount:</label>
|
||||
<div>{printableCoins(msg.value.amount, state.chain)}</div>
|
||||
<div>{printableCoin(msg.value.amount, state.chain)}</div>
|
||||
</li>
|
||||
<li>
|
||||
<label>Validator Address:</label>
|
||||
|
||||
@@ -48,7 +48,7 @@ const MsgDelegateForm = ({ delegatorAddress, setCheckAndGetMsg }: MsgDelegateFor
|
||||
value: {
|
||||
delegatorAddress,
|
||||
validatorAddress,
|
||||
amount: [{ amount: amountInAtomics, denom: state.chain.denom }],
|
||||
amount: { amount: amountInAtomics, denom: state.chain.denom },
|
||||
},
|
||||
};
|
||||
|
||||
|
||||
@@ -59,7 +59,7 @@ const MsgRedelegateForm = ({ delegatorAddress, setCheckAndGetMsg }: MsgRedelegat
|
||||
delegatorAddress,
|
||||
validatorSrcAddress,
|
||||
validatorDstAddress,
|
||||
amount: [{ amount: amountInAtomics, denom: state.chain.denom }],
|
||||
amount: { amount: amountInAtomics, denom: state.chain.denom },
|
||||
},
|
||||
};
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@ const MsgUndelegateForm = ({ delegatorAddress, setCheckAndGetMsg }: MsgUndelegat
|
||||
value: {
|
||||
delegatorAddress,
|
||||
validatorAddress,
|
||||
amount: [{ amount: amountInAtomics, denom: state.chain.denom }],
|
||||
amount: { amount: amountInAtomics, denom: state.chain.denom },
|
||||
},
|
||||
};
|
||||
|
||||
|
||||
+3
-3
@@ -21,7 +21,7 @@ export interface TxMsgDelegate {
|
||||
readonly value: {
|
||||
readonly delegatorAddress: string;
|
||||
readonly validatorAddress: string;
|
||||
readonly amount: [{ readonly amount: string; readonly denom: string }];
|
||||
readonly amount: { readonly amount: string; readonly denom: string };
|
||||
};
|
||||
}
|
||||
|
||||
@@ -30,7 +30,7 @@ export interface TxMsgUndelegate {
|
||||
readonly value: {
|
||||
readonly delegatorAddress: string;
|
||||
readonly validatorAddress: string;
|
||||
readonly amount: [{ readonly amount: string; readonly denom: string }];
|
||||
readonly amount: { readonly amount: string; readonly denom: string };
|
||||
};
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@ export interface TxMsgRedelegate {
|
||||
readonly delegatorAddress: string;
|
||||
readonly validatorSrcAddress: string;
|
||||
readonly validatorDstAddress: string;
|
||||
readonly amount: [{ readonly amount: string; readonly denom: string }];
|
||||
readonly amount: { readonly amount: string; readonly denom: string };
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user