Merge pull request #5528 from mempool/natsoni/tracker-support-error

Show http error in pizza tracker
This commit is contained in:
softsimon 2024-09-18 22:33:48 +08:00 committed by GitHub
commit 1fe08a9ecc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -42,7 +42,7 @@
<div class="blockchain-wrapper" [style]="{ height: blockchainHeight * 1.16 + 'px' }"> <div class="blockchain-wrapper" [style]="{ height: blockchainHeight * 1.16 + 'px' }">
<app-clockchain [height]="blockchainHeight" [width]="blockchainWidth" mode="none"></app-clockchain> <app-clockchain [height]="blockchainHeight" [width]="blockchainWidth" mode="none"></app-clockchain>
</div> </div>
<div class="panel"> <div class="panel" *ngIf="!error || waitingForTransaction">
@if (replaced) { @if (replaced) {
<div class="alert-replaced" role="alert"> <div class="alert-replaced" role="alert">
<span i18n="transaction.rbf.replacement|RBF replacement">This transaction has been replaced by:</span> <span i18n="transaction.rbf.replacement|RBF replacement">This transaction has been replaced by:</span>
@ -111,7 +111,7 @@
</div> </div>
</div> </div>
<div class="bottom-panel"> <div class="bottom-panel" *ngIf="!error || waitingForTransaction">
@if (isLoading) { @if (isLoading) {
<div class="progress-icon"> <div class="progress-icon">
<div class="spinner-border text-light" style="width: 1em; height: 1em"></div> <div class="spinner-border text-light" style="width: 1em; height: 1em"></div>
@ -184,6 +184,12 @@
</div> </div>
} }
</div> </div>
<div class="bottom-panel" *ngIf="error && !waitingForTransaction">
<app-http-error [error]="error">
<span i18n="transaction.error.loading-transaction-data">Error loading transaction data.</span>
</app-http-error>
</div>
<div class="footer-link" <div class="footer-link"
[routerLink]="['/tx' | relativeUrl, tx?.txid || txId]" [routerLink]="['/tx' | relativeUrl, tx?.txid || txId]"