representation of onchain data fixes
Signed-off-by: Uncle Fatso <uncle.fatso@ghostchain.io>
This commit is contained in:
parent
b44b6f0c14
commit
772041d5ed
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "ghost-dao-interface",
|
||||
"private": true,
|
||||
"version": "0.3.9",
|
||||
"version": "0.3.10",
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"dev": "vite",
|
||||
|
||||
@ -272,12 +272,8 @@ const Bridge = ({ chainId, address, config, connect }) => {
|
||||
} else {
|
||||
setIsPending(true);
|
||||
|
||||
try {
|
||||
const txHash = await ghost(chainId, address, convertedReceiver, preparedAmount);
|
||||
await ghstBalanceRefetch();
|
||||
|
||||
setReceiver("");
|
||||
setAmount("");
|
||||
setIsPending(false);
|
||||
|
||||
const transaction = {
|
||||
sessionIndex: currentSession ?? 0,
|
||||
@ -296,6 +292,12 @@ const Bridge = ({ chainId, address, config, connect }) => {
|
||||
if (providerDetail) {
|
||||
setActiveTxIndex(newStoredTransactions.length - 1)
|
||||
}
|
||||
} finally {
|
||||
await ghstBalanceRefetch();
|
||||
setReceiver("");
|
||||
setAmount("");
|
||||
setIsPending(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -476,7 +478,7 @@ const Bridge = ({ chainId, address, config, connect }) => {
|
||||
</Box>
|
||||
</Box>
|
||||
|
||||
{(currentRecord?.step ?? 0) < 3 && currentSession > (currentRecord?.sessionIndex ?? 0) + 2 &&
|
||||
{(currentRecord?.step ?? 0) < 3 && (currentSession && currentRecord && currentSession > (currentRecord.sessionIndex ?? 0) + 2) &&
|
||||
<Box display="flex" flexDirection="column" gap="5px">
|
||||
<PrimaryButton
|
||||
fullWidth
|
||||
@ -513,7 +515,7 @@ const Bridge = ({ chainId, address, config, connect }) => {
|
||||
>
|
||||
{authorities?.map((authority, idx) => {
|
||||
const authorityAddress = ss58Address(authority.asHex(), 1996);
|
||||
const disabled = clapsInSession?.at(idx)?.at(1)?.disabled;
|
||||
const disabled = clapsInSession?.find((info => info.at(0) === idx))?.at(1)?.disabled;
|
||||
const clapped = receivedClaps?.some(authId => authId === idx);
|
||||
|
||||
return (
|
||||
@ -775,7 +777,7 @@ const Bridge = ({ chainId, address, config, connect }) => {
|
||||
>
|
||||
{authorities?.map((authority, idx) => {
|
||||
const authorityAddress = ss58Address(authority.asHex(), 1996);
|
||||
const clapInfo = clapsInSession?.at(idx)?.at(1);
|
||||
const clapInfo = clapsInSession?.find((info => info.at(0) === idx))?.at(1);
|
||||
|
||||
return (
|
||||
<Box
|
||||
@ -808,7 +810,7 @@ const Bridge = ({ chainId, address, config, connect }) => {
|
||||
</Box>
|
||||
</>} />
|
||||
</Box>}
|
||||
<Typography fontSize="12px" lineHeight="15px">{clapsInSessionLength}</Typography>
|
||||
<Typography fontSize="12px" lineHeight="15px">{clapsInSessionLength} / {authorities?.length}</Typography>
|
||||
</Box>
|
||||
</Box>
|
||||
)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user