update: add router link accounts to validator and height

Signed-off-by: Salman Wahib <sxlmnwb@sxlzptprjkt.xyz>
This commit is contained in:
Salman Wahib 2023-04-25 02:14:19 +00:00
parent d73002a973
commit 4c3b2cdc77
3 changed files with 4 additions and 4 deletions

View File

@ -217,7 +217,7 @@ loadAccount(props.address)
</thead> </thead>
<tbody> <tbody>
<tr v-for="v in delegations"> <tr v-for="v in delegations">
<td>{{ format.validatorFromBech32(v.delegation.validator_address) }} </td> <td class="text-caption text-primary"><RouterLink :to="`/${chain}/staking/${v.delegation.validator_address}`">{{ format.validatorFromBech32(v.delegation.validator_address) }}</RouterLink></td>
<td>{{ format.formatToken(v.balance, true, "0,0.[00]") }} </td> <td>{{ format.formatToken(v.balance, true, "0,0.[00]") }} </td>
<td>{{ format.formatTokens(rewards?.rewards?.find(x => x.validator_address ===v.delegation.validator_address)?.reward) }} </td> <td>{{ format.formatTokens(rewards?.rewards?.find(x => x.validator_address ===v.delegation.validator_address)?.reward) }} </td>
<td> <td>
@ -238,7 +238,7 @@ loadAccount(props.address)
<tbody> <tbody>
<div v-for="v in unbonding"> <div v-for="v in unbonding">
<tr> <tr>
<td>{{ format.validatorFromBech32(v.validator_address) }} </td> <td class="text-caption text-primary"><RouterLink :to="`/${chain}/staking/${v.validator_address}`">{{ format.validatorFromBech32(v.validator_address) }}</RouterLink></td>
</tr> </tr>
<tr v-for="entry in v.entries"> <tr v-for="entry in v.entries">
<td>{{ entry.creation_height }}</td> <td>{{ entry.creation_height }}</td>

View File

@ -24,7 +24,7 @@ const format = useFormatter()
<VTable> <VTable>
<thead> <thead>
<tr> <tr>
<th>Height</th><th>Hash</th><th>Proposor</th><th>Txs</th><th>Time</th> <th>Height</th><th>Hash</th><th>Proposer</th><th>Txs</th><th>Time</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>

View File

@ -254,7 +254,7 @@ onMounted(()=> {
</thead> </thead>
<tbody> <tbody>
<tr v-for="(item, i) in txs.tx_responses"> <tr v-for="(item, i) in txs.tx_responses">
<td>{{ item.height }}</td> <td class="text-sm text-primary"><RouterLink :to="`/${props.chain}/block/${item.height}`">{{ item.height }}</RouterLink></td>
<td class="text-truncate" style="max-width: 200px;">{{ item.txhash }}</td> <td class="text-truncate" style="max-width: 200px;">{{ item.txhash }}</td>
<td>{{ format.messages(item.tx.body.messages) }}</td> <td>{{ format.messages(item.tx.body.messages) }}</td>
<td width="150">{{ format.toDay(item.timestamp,'from') }}</td> <td width="150">{{ format.toDay(item.timestamp,'from') }}</td>