apply blockchain scroll offset when element is ready

This commit is contained in:
Mononaut
2023-07-21 17:10:58 +09:00
parent 135adfecbd
commit 1bd19e1d8d
3 changed files with 19 additions and 6 deletions

View File

@@ -82,9 +82,7 @@ export class BlockchainComponent implements OnInit, OnDestroy {
}
this.mempoolOffset = Math.max(0, width - this.dividerOffset);
this.cd.markForCheck();
setTimeout(() => {
this.mempoolOffsetChange.emit(this.mempoolOffset);
}, 0);
this.mempoolOffsetChange.emit(this.mempoolOffset);
}
@HostListener('window:resize', ['$event'])