diff --git a/public/js/clinicalAssistant.js b/public/js/clinicalAssistant.js index d1895ad4..a4bf0758 100644 --- a/public/js/clinicalAssistant.js +++ b/public/js/clinicalAssistant.js @@ -545,8 +545,11 @@ import { // assistant is still working — drawing a figure, completing a cut-off // reply. It now sits above the partial answer until the answer is done. showStreamStatus(bubble, streamStatus); - var wrap = document.getElementById('assistant-messages'); - if (wrap) wrap.scrollTop = wrap.scrollHeight; + // The view stays where the reader left it while the answer streams in. + // It used to be dragged to the bottom on every render, so the reader + // could not start at the top of a long answer, and a finger on the + // screen fought the auto-scroll. The answer grows below the fold; the + // reader scrolls into it at their own pace. } function handleEvent(type, data) { @@ -950,8 +953,8 @@ import { ''; row.appendChild(actions); } - var wrap = document.getElementById('assistant-messages'); - if (wrap) wrap.scrollTop = wrap.scrollHeight; + // No jump to the end when the answer completes either: the reader may be + // partway through it. messages.push({ role: 'assistant', content: content, sources: sources || [] }); row.dataset.messageIndex = String(messages.length - 1); updateConversationBudget();