We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2b6e374 commit 19f3792Copy full SHA for 19f3792
1 file changed
output-tab.js
@@ -812,7 +812,12 @@ function renderHighlights(d) {
812
}
813
814
host.querySelectorAll('.hl-row.clickable').forEach(row => {
815
- row.addEventListener('click', () => show(Number(row.dataset.jump)));
+ row.addEventListener('click', () => {
816
+ const n = Number(row.dataset.jump);
817
+ show(n);
818
+ const behavior = matchMedia('(prefers-reduced-motion: reduce)').matches ? 'auto' : 'smooth';
819
+ document.getElementById('t' + n)?.scrollIntoView({ behavior, block: 'start' });
820
+ });
821
});
822
823
0 commit comments