Update index.html

This commit is contained in:
sairaj mote 2023-09-29 20:05:31 +05:30
parent 1d7e9cd943
commit 26af6173f6

View File

@ -926,12 +926,12 @@
</li>`;
},
blockCard(blockDetails) {
const { height, tx, time } = blockDetails;
const plural = parseInt(tx.length) > 1 ? 's' : '';
const { height, tx, txs, time } = blockDetails;
const plural = parseInt((tx || txs).length) > 1 ? 's' : '';
return html`
<div class="block-card grid align-center">
<a href=${`#/block/${height}`} class="block-height">${height}</a>
<span>${tx.length} Transaction${plural}</span>
<span>${(tx || txs).length} Transaction${plural}</span>
<time>${getFormattedTime(time, 'relative')}</time>
</div>
`;