mirror of
https://github.com/mempool/mempool.git
synced 2024-12-30 18:24:25 +01:00
Merge pull request #1312 from nymkappa/feature/shorter-stats
Shorten reward stats
This commit is contained in:
commit
5d16a30cf2
@ -18,7 +18,7 @@
|
|||||||
<div class="item">
|
<div class="item">
|
||||||
<h5 class="card-title" i18n="">Reward Per Tx</h5>
|
<h5 class="card-title" i18n="">Reward Per Tx</h5>
|
||||||
<div class="card-text">
|
<div class="card-text">
|
||||||
{{ rewardStats.rewardPerTx }}
|
{{ rewardStats.rewardPerTx | amountShortener }}
|
||||||
<span class="symbol">sats/tx</span>
|
<span class="symbol">sats/tx</span>
|
||||||
<div class="symbol">in the last 8 blocks</div>
|
<div class="symbol">in the last 8 blocks</div>
|
||||||
</div>
|
</div>
|
||||||
@ -26,7 +26,7 @@
|
|||||||
<div class="item">
|
<div class="item">
|
||||||
<h5 class="card-title" i18n="">Average Fee</h5>
|
<h5 class="card-title" i18n="">Average Fee</h5>
|
||||||
<div class="card-text">
|
<div class="card-text">
|
||||||
{{ rewardStats.feePerTx }}
|
{{ rewardStats.feePerTx | amountShortener}}
|
||||||
<span class="symbol">sats/tx</span>
|
<span class="symbol">sats/tx</span>
|
||||||
<div class="symbol">in the last 8 blocks</div>
|
<div class="symbol">in the last 8 blocks</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -2,8 +2,6 @@ import { ChangeDetectionStrategy, Component, Inject, LOCALE_ID, OnDestroy, OnIni
|
|||||||
import { map } from 'rxjs/operators';
|
import { map } from 'rxjs/operators';
|
||||||
import { SeoService } from 'src/app/services/seo.service';
|
import { SeoService } from 'src/app/services/seo.service';
|
||||||
import { StateService } from 'src/app/services/state.service';
|
import { StateService } from 'src/app/services/state.service';
|
||||||
import { formatNumber } from '@angular/common';
|
|
||||||
import { WebsocketService } from 'src/app/services/websocket.service';
|
|
||||||
import { Observable } from 'rxjs';
|
import { Observable } from 'rxjs';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
@ -22,7 +20,6 @@ export class MiningDashboardComponent implements OnInit {
|
|||||||
|
|
||||||
constructor(private seoService: SeoService,
|
constructor(private seoService: SeoService,
|
||||||
public stateService: StateService,
|
public stateService: StateService,
|
||||||
private websocketService: WebsocketService,
|
|
||||||
@Inject(LOCALE_ID) private locale: string,
|
@Inject(LOCALE_ID) private locale: string,
|
||||||
) {
|
) {
|
||||||
this.seoService.setTitle($localize`:@@mining.mining-dashboard:Mining Dashboard`);
|
this.seoService.setTitle($localize`:@@mining.mining-dashboard:Mining Dashboard`);
|
||||||
@ -39,8 +36,8 @@ export class MiningDashboardComponent implements OnInit {
|
|||||||
|
|
||||||
return {
|
return {
|
||||||
'totalReward': totalReward,
|
'totalReward': totalReward,
|
||||||
'rewardPerTx': formatNumber(totalReward / totalTx, this.locale, '1.0-0'),
|
'rewardPerTx': totalReward / totalTx,
|
||||||
'feePerTx': formatNumber(totalFee / totalTx, this.locale, '1.0-0'),
|
'feePerTx': totalFee / totalTx,
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
Loading…
Reference in New Issue
Block a user