Merge pull request #4802 from mempool/natsoni/fix-bowtie-tooltip-bug

Fix bowtie tooltip bug
This commit is contained in:
softsimon authored and GitHub committed 2024-03-21 11:31:18 +09:00
commit 7bf7d02a18
1 file changed
+9 -7
@@ -71,13 +71,15 @@ export class TxBowtieGraphTooltipComponent implements OnChanges {
if (changes.line?.currentValue) {
if (changes.line.currentValue.type === 'input') {
if (!this.inputStatus[changes.line.currentValue.index]) {
this.apiService.getTransactionStatus$(changes.line.currentValue.txid).pipe(
tap((status) => {
changes.line.currentValue.status = status;
this.inputStatus[changes.line.currentValue.index] = status;
this.fetchPrices(changes);
})
).subscribe();
if (changes.line.currentValue.txid) {
this.apiService.getTransactionStatus$(changes.line.currentValue.txid).pipe(
tap((status) => {
changes.line.currentValue.status = status;
this.inputStatus[changes.line.currentValue.index] = status;
this.fetchPrices(changes);
})
).subscribe();
}
} else {
changes.line.currentValue.status = this.inputStatus[changes.line.currentValue.index];
this.fetchPrices(changes);