feat: connect prepared run and refine presenter notes
This commit is contained in:
@@ -232,7 +232,7 @@ describe("AssistantOperatorThread", () => {
|
||||
}
|
||||
});
|
||||
|
||||
it("can show the latest response in a static comparison transcript", async () => {
|
||||
it("can show the latest response even when an authoring group is synchronized", async () => {
|
||||
const setScrollTop = vi.fn();
|
||||
const descriptors = {
|
||||
scrollTop: Object.getOwnPropertyDescriptor(HTMLDivElement.prototype, "scrollTop"),
|
||||
@@ -246,7 +246,14 @@ describe("AssistantOperatorThread", () => {
|
||||
scrollHeight: { configurable: true, get: () => 240 },
|
||||
clientHeight: { configurable: true, get: () => 80 },
|
||||
});
|
||||
render(<AssistantOperatorThread mode="dock" messages={[]} scrollMode="end" />);
|
||||
render(
|
||||
<AssistantOperatorThread
|
||||
mode="dock"
|
||||
messages={[]}
|
||||
activeToolGroupId="authoring-deployment"
|
||||
scrollMode="end"
|
||||
/>,
|
||||
);
|
||||
|
||||
await waitFor(() => expect(setScrollTop).toHaveBeenCalledWith(160));
|
||||
} finally {
|
||||
|
||||
@@ -276,9 +276,9 @@ export const AssistantOperatorThread = ({
|
||||
const viewport = viewportRef.current;
|
||||
if (!viewport) return;
|
||||
|
||||
// Static comparison transcripts should show their final answer; live
|
||||
// presentation docks instead keep the beat-owned tool group in view.
|
||||
if (!activeToolGroupId && scrollMode === "end") {
|
||||
// A terminal exchange must override phase anchoring so its result and
|
||||
// final assistant response remain visible after the composer submits.
|
||||
if (scrollMode === "end") {
|
||||
viewport.scrollTop = Math.max(0, viewport.scrollHeight - viewport.clientHeight);
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user