diff --git a/frontend/src/app/components/rbf-timeline/rbf-timeline.component.html b/frontend/src/app/components/rbf-timeline/rbf-timeline.component.html index 206b3f01f..e9d531cb8 100644 --- a/frontend/src/app/components/rbf-timeline/rbf-timeline.component.html +++ b/frontend/src/app/components/rbf-timeline/rbf-timeline.component.html @@ -17,6 +17,7 @@
{ this.scrollToSelected(); }); + } } // converts a tree of RBF events into a format that can be more easily rendered in HTML @@ -166,6 +169,13 @@ export class RbfTimelineComponent implements OnInit, OnChanges { return rows; } + scrollToSelected() { + const node = document.getElementById('node-' + this.txid); + if (node) { + node.scrollIntoView({ block: 'nearest', inline: 'center' }); + } + } + @HostListener('pointermove', ['$event']) onPointerMove(event) { this.tooltipPosition = { x: event.clientX, y: event.clientY };