mirror of
https://github.com/mempool/mempool.git
synced 2025-03-13 11:36:07 +01:00
Fixes to block reward display on Liquid.
This commit is contained in:
parent
b6b9001406
commit
23f5e229c9
3 changed files with 9 additions and 4 deletions
|
@ -98,7 +98,9 @@ class Blocks {
|
|||
vin: [{
|
||||
scriptsig: tx.vin[0].scriptsig
|
||||
}],
|
||||
vout: tx.vout.map((vout) => ({ scriptpubkey_address: vout.scriptpubkey_address, value: vout.value }))
|
||||
vout: tx.vout
|
||||
.map((vout) => ({ scriptpubkey_address: vout.scriptpubkey_address, value: vout.value }))
|
||||
.filter((vout) => vout.value)
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
@ -48,7 +48,10 @@
|
|||
<ng-template [ngIf]="fees !== undefined" [ngIfElse]="loadingFees">
|
||||
<tr>
|
||||
<td>Total fees</td>
|
||||
<td><app-amount [satoshis]="fees * 100000000" digitsInfo="1.2-2" [noFiat]="true"></app-amount> (<app-fiat [value]="fees * 100000000" digitsInfo="1.0-0"></app-fiat>)</td>
|
||||
<td *ngIf="network !== 'liquid'; else liquidTotalFees"><app-amount [satoshis]="fees * 100000000" digitsInfo="1.2-2" [noFiat]="true"></app-amount> (<app-fiat [value]="fees * 100000000" digitsInfo="1.0-0"></app-fiat>)</td>
|
||||
<ng-template #liquidTotalFees>
|
||||
<td>{{ fees | number }} L-sat (<app-fiat [value]="fees * 100000000" digitsInfo="1.2-2"></app-fiat>)</td>
|
||||
</ng-template>
|
||||
</tr>
|
||||
<tr *ngIf="network !== 'liquid'">
|
||||
<td>Subsidy + fees:</td>
|
||||
|
@ -62,7 +65,7 @@
|
|||
<td>Total fees</td>
|
||||
<td style="width: 75%;"><span class="skeleton-loader"></span></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<tr *ngIf="network !== 'liquid'">
|
||||
<td>Subsidy + fees:</td>
|
||||
<td><span class="skeleton-loader"></span></td>
|
||||
</tr>
|
||||
|
|
|
@ -98,7 +98,7 @@ export class BlockComponent implements OnInit, OnDestroy {
|
|||
this.coinbaseTx = block.coinbaseTx;
|
||||
}
|
||||
this.setBlockSubsidy();
|
||||
if (block.reward) {
|
||||
if (block.reward !== undefined) {
|
||||
this.fees = block.reward / 100000000 - this.blockSubsidy;
|
||||
}
|
||||
this.stateService.markBlock$.next({ blockHeight: this.blockHeight });
|
||||
|
|
Loading…
Add table
Reference in a new issue