Skip to content

Commit 08dbcf0

Browse files
x-zheng16claude
andcommitted
fix page not starting at top on load
selectPrompt() called scrollIntoView on the viewer panel during initial load. Inline the first-row selection without scrolling. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 213b950 commit 08dbcf0

1 file changed

Lines changed: 12 additions & 2 deletions

File tree

index.html

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -576,9 +576,19 @@ <h2 class="section-title font-display font-bold text-3xl md:text-4xl tracking-ti
576576
});
577577
});
578578

579-
// Select first row by default
579+
// Select first row by default (no scroll)
580580
if (prompts.length > 0) {
581-
selectPrompt(0, tbody.querySelector('tr'));
581+
const firstTr = tbody.querySelector('tr');
582+
firstTr.classList.add('active');
583+
activeRow = firstTr;
584+
activeIdx = 0;
585+
const p = prompts[0];
586+
viewerTitle.textContent = p.component ? p.model + ' / ' + p.component : p.model;
587+
const meta = [p.provider, (p.consistency * 100).toFixed(1) + '% consistency'];
588+
if (p.prompt) meta.push(p.prompt.length + ' chars');
589+
viewerMeta.textContent = meta.join(' | ');
590+
viewerBody.textContent = p.prompt;
591+
viewer.style.display = 'block';
582592
}
583593
})();
584594
</script>

0 commit comments

Comments
 (0)