Skip to content

Dodaios is an open-source agent OS for your desktop: it runs your coding agents, browser and apps by voice or chat, on your own machine. Formerly Personal Jarvis.

revert(agentic-ide): remove the pane scrollbar and Codex's --no-alt-screen (#802)

Ruben Lütke73dcf75b1fd8
diff --git a/dodaios/ui/web/frontend/src/components/agentic/AgenticTerminal.test.tsx b/dodaios/ui/web/frontend/src/components/agentic/AgenticTerminal.test.tsx
index d9795f3967..6465f00d68 100644
--- a/dodaios/ui/web/frontend/src/components/agentic/AgenticTerminal.test.tsx
+++ b/dodaios/ui/web/frontend/src/components/agentic/AgenticTerminal.test.tsx
@@ -290,7 +290,7 @@ describe("AgenticTerminal layout", () => {
expect(terminalHarness.wheel.current).not.toBeNull();
});
- it("keeps conversation history in the header and draws no scrollbar while there is nothing to scroll", () => {
+ it("keeps conversation history in the header without a scrollbar overlay", () => {
render(
<AgenticTerminal
name="Dana"
diff --git a/dodaios/ui/web/frontend/src/components/agentic/AgenticTerminal.tsx b/dodaios/ui/web/frontend/src/components/agentic/AgenticTerminal.tsx
index 12303429d7..2345aa9835 100644
--- a/dodaios/ui/web/frontend/src/components/agentic/AgenticTerminal.tsx
+++ b/dodaios/ui/web/frontend/src/components/agentic/AgenticTerminal.tsx
@@ -144,7 +144,6 @@ import {
import { installQuerySuppression } from "./terminalQueries";
import { installSynchronizedOutput } from "./terminalSynchronizedOutput";
import { FULL_SCREEN_ERASE_SCAN_TAIL, hasFullScreenErase } from "./terminalRepaint";
-import { PaneScrollbar } from "./PaneScrollbar";
import {
bindTerminalScrollRegion,
captureWheelForTerminalHistory,
@@ -3116,17 +3115,6 @@ export function AgenticTerminal({
*/
className="agentic-terminal-host h-full min-h-0 w-full overflow-hidden"
/>
- <PaneScrollbar
- termRef={termRef}
- epoch={terminalEpoch}
- regionRef={terminalRegionRef}
- testId={`agentic-pane-scrollbar-${name}`}
- labels={{
- bar: t("agentic_grid.pane.scrollbar"),
- up: t("agentic_grid.pane.scroll_up"),
- down: t("agentic_grid.pane.scroll_down"),
- }}
- />
<PaneConversationDialog
terminal={name}
open={historyOpen}
diff --git a/dodaios/ui/web/frontend/src/components/agentic/PaneScrollbar.test.tsx b/dodaios/ui/web/frontend/src/components/agentic/PaneScrollbar.test.tsx
deleted file mode 100644
index ef0001861e..0000000000
--- a/dodaios/ui/web/frontend/src/components/agentic/PaneScrollbar.test.tsx
+++ /dev/null
@@ -1,203 +0,0 @@
-import { act, fireEvent, render, screen } from "@testing-library/react";
-import { afterEach, beforeEach, describe, expect, it, vi } from "vitest";
-import type { Terminal } from "@xterm/xterm";
-import { useRef } from "react";
-import {
- PaneScrollbar,
- SCROLLBAR_LINGER_MS,
- readPaneScrollState,
- sendWheelNotches,
-} from "./PaneScrollbar";
-
-type FakeOptions = {
- type?: "normal" | "alternate";
- baseY?: number;
- viewportY?: number;
- tracking?: "none" | "any" | "vt200" | "drag" | "x10";
- rows?: number;
-};
-
-function fakeTerminal(opts: FakeOptions = {}) {
- const element = document.createElement("div");
- const screenEl = document.createElement("div");
- screenEl.className = "xterm-screen";
- element.appendChild(screenEl);
- const wheels: WheelEvent[] = [];
- screenEl.addEventListener("wheel", (e) => wheels.push(e as WheelEvent));
- const listeners: Array<() => void> = [];
- const sub = (fn: () => void) => {
- listeners.push(fn);
- return { dispose: () => listeners.splice(listeners.indexOf(fn), 1) };
- };
- const active = {
- type: opts.type ?? "normal",
- baseY: opts.baseY ?? 0,
- viewportY: opts.viewportY ?? 0,
- };
- const term = {
- element,
- rows: opts.rows ?? 30,
- modes: { mouseTrackingMode: opts.tracking ?? "none" },
- buffer: { active, onBufferChange: sub },
- onScroll: sub,
- onWriteParsed: sub,
- onResize: sub,
- scrollLines: vi.fn((n: number) => {
- active.viewportY = Math.max(0, Math.min(active.baseY, active.viewportY + n));
- }),
- scrollPages: vi.fn(),
- scrollToLine: vi.fn((n: number) => {
- active.viewportY = n;
- }),
- };
- return { term, wheels, active, emit: () => listeners.slice().forEach((fn) => fn()) };
-}
-
-function Harness({ term }: { term: unknown }) {
- const termRef = useRef(term as Terminal | null);
- const regionRef = useRef<HTMLDivElement | null>(null);
- return (
- <div ref={regionRef} data-testid="region">
- <PaneScrollbar
- termRef={termRef}
- epoch={0}
- regionRef={regionRef}
- testId="bar"
- labels={{ bar: "Scroll the terminal", up: "Scroll up", down: "Scroll down" }}
- />
- </div>
- );
-}
-
-describe("readPaneScrollState", () => {
- it("is history on a normal buffer with scrollback", () => {
- const { term } = fakeTerminal({ baseY: 120, viewportY: 40 });
- expect(readPaneScrollState(term as unknown as Terminal)).toMatchObject({
- mode: "history",
- baseY: 120,
- viewportY: 40,
- });
- });
-
- it("is app on an alternate screen that reports the mouse (Claude Code, Codex)", () => {
- const { term } = fakeTerminal({ type: "alternate", tracking: "any" });
- expect(readPaneScrollState(term as unknown as Terminal).mode).toBe("app");
- });
-
- it("is none on an alternate screen without mouse reporting, where a wheel would type arrow keys", () => {
- const { term } = fakeTerminal({ type: "alternate", tracking: "none" });
- expect(readPaneScrollState(term as unknown as Terminal).mode).toBe("none");
- });
-
- it("is none on a normal buffer that has nothing above the screen", () => {
- const { term } = fakeTerminal({ baseY: 0 });
- expect(readPaneScrollState(term as unknown as Terminal).mode).toBe("none");
- });
-});
-
-describe("sendWheelNotches", () => {
- it("dispatches one line-mode wheel per notch on xterm's screen", () => {
- const { term, wheels } = fakeTerminal({ type: "alternate", tracking: "any" });
- expect(sendWheelNotches(term as unknown as Terminal, -1, 3)).toBe(3);
- expect(wheels).toHaveLength(3);
- expect(wheels.every((w) => w.deltaY === -1 && w.deltaMode === WheelEvent.DOM_DELTA_LINE)).toBe(true);
- });
-
- it("sends nothing once the CLI stops reporting the mouse", () => {
- const { term, wheels } = fakeTerminal({ type: "alternate", tracking: "none" });
- expect(sendWheelNotches(term as unknown as Terminal, 1, 4)).toBe(0);
- expect(wheels).toHaveLength(0);
- });
-});
-
-describe("PaneScrollbar", () => {
- beforeEach(() => vi.useFakeTimers());
- afterEach(() => vi.useRealTimers());
-
- it("draws nothing while there is nothing to scroll", () => {
- const { term } = fakeTerminal();
- render(<Harness term={term} />);
- expect(screen.queryByRole("scrollbar")).toBeNull();
- });
-
- it("appears when the pane is scrolled and fades out after a pause", () => {
- const { term } = fakeTerminal({ baseY: 100, viewportY: 100 });
- render(<Harness term={term} />);
- const bar = screen.getByTestId("bar");
- expect(bar.dataset.visible).toBe("false");
- fireEvent.wheel(screen.getByTestId("region"), { deltaY: -100 });
- expect(bar.dataset.visible).toBe("true");
- act(() => {
- vi.advanceTimersByTime(SCROLLBAR_LINGER_MS + 10);
- });
- expect(bar.dataset.visible).toBe("false");
- });
-
- it("scrolls xterm's own history from the arrows in history mode", () => {
- const { term } = fakeTerminal({ baseY: 100, viewportY: 50 });
- render(<Harness term={term} />);
- fireEvent.pointerDown(screen.getByTestId("bar-up"), { button: 0 });
- fireEvent.pointerUp(window);
- expect(term.scrollLines).toHaveBeenCalledWith(-3);
- fireEvent.pointerDown(screen.getByTestId("bar-down"), { button: 0 });
- fireEvent.pointerUp(window);
- expect(term.scrollLines).toHaveBeenCalledWith(3);
- });
-
- it("keeps stepping while an arrow is held", () => {
- const { term } = fakeTerminal({ baseY: 1000, viewportY: 500 });
- render(<Harness term={term} />);
- fireEvent.pointerDown(screen.getByTestId("bar-up"), { button: 0 });
- act(() => {
- vi.advanceTimersByTime(320 + 60 * 5 + 5);
- });
- fireEvent.pointerUp(window);
- const calls = term.scrollLines.mock.calls.length;
- expect(calls).toBeGreaterThanOrEqual(6);
- act(() => {
- vi.advanceTimersByTime(500);
- });
- expect(term.scrollLines.mock.calls.length).toBe(calls);
- });
-
- it("sends wheel notches to a full-screen CLI from the arrows in app mode", () => {
- const { term, wheels } = fakeTerminal({ type: "alternate", tracking: "any" });
- render(<Harness term={term} />);
- expect(screen.getByTestId("bar").dataset.mode).toBe("app");
- fireEvent.pointerDown(screen.getByTestId("bar-up"), { button: 0 });
- fireEvent.pointerUp(window);
- expect(wheels).toHaveLength(1);
- expect(wheels[0].deltaY).toBe(-1);
- fireEvent.pointerDown(screen.getByTestId("bar-down"), { button: 0 });
- fireEvent.pointerUp(window);
- expect(wheels).toHaveLength(2);
- expect(wheels[1].deltaY).toBe(1);
- expect(term.scrollLines).not.toHaveBeenCalled();
- // No thumb: a full-screen CLI's position is not knowable from outside.
- expect(screen.queryByTestId("bar-thumb")).toBeNull();
- });
-
- it("follows a wheel scroll on an idle pane while the bar is shown", () => {
- const { term, active } = fakeTerminal({ baseY: 100, viewportY: 100 });
- render(<Harness term={term} />);
- fireEvent.wheel(screen.getByTestId("region"), { deltaY: -100 });
- active.viewportY = 0;
- act(() => {
- vi.advanceTimersByTime(250);
- });
- expect(screen.getByTestId("bar").getAttribute("aria-valuenow")).toBe("0");
- });
-
- it("follows the terminal into app mode when the CLI takes the screen", () => {
- const { term, active, emit } = fakeTerminal();
- render(<Harness term={term} />);
- expect(screen.queryByRole("scrollbar")).toBeNull();
- active.type = "alternate";
- term.modes.mouseTrackingMode = "any";
- act(() => {
- emit();
- vi.advanceTimersByTime(20);
- });
- expect(screen.getByTestId("bar").dataset.mode).toBe("app");
- });
-});
diff --git a/dodaios/ui/web/frontend/src/components/agentic/PaneScrollbar.tsx b/dodaios/ui/web/frontend/src/components/agentic/PaneScrollbar.tsx
deleted file mode 100644
index d291206207..0000000000
--- a/dodaios/ui/web/frontend/src/components/agentic/PaneScrollbar.tsx
+++ /dev/null
@@ -1,411 +0,0 @@
-/**
- * The scrollbar of an Agentic IDE terminal pane.
- *
- * Hidden until the reader scrolls (or points at the pane's right edge), then it
- * fades in and can be used to scroll up and down; it fades out again after a
- * short pause. It works in the two shapes a coding CLI's history takes:
- *
- * - `history`: the terminal itself holds the scrollback (a shell, Codex with
- * `--no-alt-screen`, Claude Code without its full-screen renderer). The thumb
- * is exact: it is xterm's own viewport, dragging seeks, the track pages.
- * - `app`: a full-screen CLI on the alternate screen (Claude Code with
- * `CLAUDE_CODE_NO_FLICKER`, Codex by default) keeps its history inside its own
- * UI, and the terminal has nothing to scroll. Measured 2026-10-19: both
- * negotiate mouse reporting (?1003/?1006). The bar then drives the CLI with
- * real wheel notches through xterm's own mouse encoder, exactly as the
- * physical wheel would. No position is shown there, because none is knowable
- * from outside the CLI: there is no thumb at all, only the arrows and the
- * track halves, which step and page. (A centred "jog" grip shipped first and
- * was read as "you are in the middle" while the pane sat at its end.)
- *
- * Codex panes start with `--no-alt-screen` (see its `launch_args`) and run in
- * `history` mode. Claude Code keeps the person's own renderer, so it runs in
- * `app` mode when their `CLAUDE_CODE_NO_FLICKER` is on.
- *
- * Wheel notches are only ever sent while the CLI reports the mouse. On an
- * alternate screen WITHOUT mouse reporting xterm turns a wheel into arrow keys,
- * which a coding CLI reads as "recall the previous prompt"; there the bar stays
- * hidden instead.
- */
-import { ChevronDown, ChevronUp } from "lucide-react";
-import {
- useCallback,
- useEffect,
- useRef,
- useState,
- type MutableRefObject,
- type PointerEvent as ReactPointerEvent,
-} from "react";
-import type { Terminal } from "@xterm/xterm";
-import { cn } from "@/lib/utils";
-
-export type PaneScrollMode = "history" | "app" | "none";
-
-export type PaneScrollState = {
- mode: PaneScrollMode;
- /** First line in view (history mode). */
- viewportY: number;
- /** Lines above the live screen (history mode). */
- baseY: number;
- rows: number;
-};
-
-/** How long the bar stays after the last scroll or hover, in ms. */
-export const SCROLLBAR_LINGER_MS = 1800;
-/** Width of the right-edge strip that reveals the bar on hover, in px. */
-const EDGE_REVEAL_PX = 28;
-/** Auto-repeat of a held arrow or track press. */
-const REPEAT_DELAY_MS = 320;
-const REPEAT_INTERVAL_MS = 60;
-/** Smallest thumb in history mode, so a long history keeps a grabbable thumb. */
-const MIN_THUMB_PX = 28;
-
-/** What the pane can be scrolled by, read fresh from the terminal. */
-export function readPaneScrollState(term: Terminal | null): PaneScrollState {
- const none: PaneScrollState = { mode: "none", viewportY: 0, baseY: 0, rows: 0 };
- if (!term) return none;
- const buffer = term.buffer?.active;
- if (!buffer) return none;
- const rows = Math.max(1, term.rows || 1);
- if (buffer.type === "normal") {
- if (buffer.baseY > 0) {
- return { mode: "history", viewportY: buffer.viewportY, baseY: buffer.baseY, rows };
- }
- return { ...none, rows };
- }
- const tracking = term.modes?.mouseTrackingMode ?? "none";
- return { mode: tracking === "none" ? "none" : "app", viewportY: 0, baseY: 0, rows };
-}
-
-/**
- * Send `count` wheel notches to a full-screen CLI, the way the real wheel does.
- *
- * Dispatched on xterm's screen element so xterm encodes them in whatever mouse
- * protocol the CLI negotiated. Re-checked per notch: should the CLI drop mouse
- * reporting mid-gesture, nothing else may be sent (see the module comment).
- */
-export function sendWheelNotches(term: Terminal, direction: -1 | 1, count: number): number {
- const screen = term.element?.querySelector<HTMLElement>(".xterm-screen");
- if (!screen) return 0;
- const rect = screen.getBoundingClientRect();
- let sent = 0;
- for (let i = 0; i < count; i++) {
- if (readPaneScrollState(term).mode !== "app") break;
- screen.dispatchEvent(
- new WheelEvent("wheel", {
- deltaY: direction,
- deltaMode: WheelEvent.DOM_DELTA_LINE,
- clientX: rect.left + rect.width / 2,
- clientY: rect.top + rect.height / 2,
- bubbles: true,
- cancelable: true,
- }),
- );
- sent += 1;
- }
- return sent;
-}
-
-type Props = {
- termRef: MutableRefObject<Terminal | null>;
- /** Bumped whenever the pane builds a new Terminal. */
- epoch: number;
- /** The pane's terminal region: scrolling or hovering there reveals the bar. */
- regionRef: MutableRefObject<HTMLElement | null>;
- labels: { bar: string; up: string; down: string };
- testId?: string;
-};
-
-export function PaneScrollbar({ termRef, epoch, regionRef, labels, testId }: Props) {
- const [state, setState] = useState<PaneScrollState>(() => readPaneScrollState(termRef.current));
- const [shown, setShown] = useState(false);
- const [hovered, setHovered] = useState(false);
- const [dragging, setDragging] = useState(false);
- const trackRef = useRef<HTMLDivElement | null>(null);
- const hideTimer = useRef<number | null>(null);
- const repeatTimer = useRef<number | null>(null);
- const stateRef = useRef(state);
- stateRef.current = state;
-
- const refresh = useCallback(() => {
- const next = readPaneScrollState(termRef.current);
- setState((prev) =>
- prev.mode === next.mode &&
- prev.viewportY === next.viewportY &&
- prev.baseY === next.baseY &&
- prev.rows === next.rows
- ? prev
- : next,
- );
- return next;
- }, [termRef]);
-
- const reveal = useCallback(() => {
- if (refresh().mode === "none") return;
- setShown(true);
- if (hideTimer.current !== null) window.clearTimeout(hideTimer.current);
- hideTimer.current = window.setTimeout(() => {
- hideTimer.current = null;
- setShown(false);
- }, SCROLLBAR_LINGER_MS);
- }, [refresh]);
-
- // Follow the terminal: its scroll, its writes, its buffer switches.
- useEffect(() => {
- const term = termRef.current;
- refresh();
- if (!term) return;
- let frame: number | null = null;
- const soon = () => {
- if (frame !== null) return;
- frame = window.requestAnimationFrame(() => {
- frame = null;
- refresh();
- });
- };
- const subs = [
- term.onScroll?.(soon),
- term.onWriteParsed?.(soon),
- term.onResize?.(soon),
- term.buffer?.onBufferChange?.(soon),
- ];
- return () => {
- if (frame !== null) window.cancelAnimationFrame(frame);
- for (const sub of subs) sub?.dispose();
- };
- }, [termRef, epoch, refresh]);
-
- // While the bar is on screen, re-read the position a few times a second. A
- // wheel scroll on an idle pane writes nothing, and the 2026-08 rail showed
- // stale positions for exactly that reason.
- useEffect(() => {
- if (!shown && !hovered && !dragging) return;
- const timer = window.setInterval(refresh, 200);
- return () => window.clearInterval(timer);
- }, [shown, hovered, dragging, refresh]);
-
- // Scrolling inside the pane, or pointing at its right edge, shows the bar.
- useEffect(() => {
- const region = regionRef.current;
- if (!region) return;
- const onWheel = (event: WheelEvent) => {
- if (event.ctrlKey || event.metaKey) return;
- if (Math.abs(event.deltaY) <= Math.abs(event.deltaX)) return;
- reveal();
- };
- const onMove = (event: MouseEvent) => {
- const rect = region.getBoundingClientRect();
- if (rect.right - event.clientX <= EDGE_REVEAL_PX) reveal();
- };
- region.addEventListener("wheel", onWheel, { capture: true, passive: true });
- region.addEventListener("mousemove", onMove, { capture: true, passive: true });
- return () => {
- region.removeEventListener("wheel", onWheel, { capture: true });
- region.removeEventListener("mousemove", onMove, { capture: true });
- };
- }, [regionRef, reveal]);
-
- const stopRepeat = useCallback(() => {
- if (repeatTimer.current !== null) {
- window.clearTimeout(repeatTimer.current);
- repeatTimer.current = null;
- }
- }, []);
-
- useEffect(
- () => () => {
- stopRepeat();
- if (hideTimer.current !== null) window.clearTimeout(hideTimer.current);
- },
- [stopRepeat],
- );
-
- /** One step: lines in history mode, notches in app mode. */
- const step = useCallback(
- (direction: -1 | 1, size: "line" | "page") => {
- const term = termRef.current;
- if (!term) return;
- const current = readPaneScrollState(term);
- if (current.mode === "history") {
- if (size === "page") term.scrollPages(direction);
- else term.scrollLines(direction * 3);
- } else if (current.mode === "app") {
- const notches = size === "page" ? Math.max(3, Math.round(current.rows / 3)) : 1;
- sendWheelNotches(term, direction, notches);
- }
- reveal();
- },
- [termRef, reveal],
- );
-
- /** Press-and-hold: step now, then keep stepping until the pointer lets go. */
- const holdStep = useCallback(
- (event: ReactPointerEvent, direction: -1 | 1, size: "line" | "page") => {
- if (event.button > 0) return;
- event.preventDefault();
- event.stopPropagation();
- stopRepeat();
- step(direction, size);
- const again = (delay: number) => {
- repeatTimer.current = window.setTimeout(() => {
- step(direction, size);
- again(REPEAT_INTERVAL_MS);
- }, delay);
- };
- again(REPEAT_DELAY_MS);
- const release = () => {
- stopRepeat();
- window.removeEventListener("pointerup", release);
- window.removeEventListener("pointercancel", release);
- };
- window.addEventListener("pointerup", release);
- window.addEventListener("pointercancel", release);
- },
- [step, stopRepeat],
- );
-
- const trackHeight = () => trackRef.current?.clientHeight ?? 0;
-
- const historyThumb = () => {
- const h = trackHeight();
- const total = state.baseY + state.rows;
- const size = Math.min(h, Math.max(MIN_THUMB_PX, (h * state.rows) / Math.max(1, total)));
- const travel = Math.max(0, h - size);
- const top = state.baseY > 0 ? (travel * state.viewportY) / state.baseY : travel;
- return { size, top, travel };
- };
-
- /** Drag the thumb. The mode is fixed at the press: a flip mid-drag ends it. */
- const startDrag = (event: ReactPointerEvent<HTMLDivElement>) => {
- if (event.button > 0) return;
- const term = termRef.current;
- if (!term) return;
- event.preventDefault();
- event.stopPropagation();
- const mode = readPaneScrollState(term).mode;
- if (mode !== "history") return;
- const target = event.currentTarget;
- target.setPointerCapture?.(event.pointerId);
- const startY = event.clientY;
- const startLine = term.buffer.active.viewportY;
- const { travel } = historyThumb();
- const baseY = Math.max(1, term.buffer.active.baseY);
- setDragging(true);
-
- const move = (ev: PointerEvent) => {
- const dy = ev.clientY - startY;
- if (readPaneScrollState(term).mode !== mode) return;
- if (travel <= 0) return;
- const line = Math.round(startLine + (dy * baseY) / travel);
- term.scrollToLine(Math.max(0, Math.min(term.buffer.active.baseY, line)));
- reveal();
- };
- const end = () => {
- target.removeEventListener("pointermove", move);
- target.removeEventListener("pointerup", end);
- target.removeEventListener("pointercancel", end);
- setDragging(false);
- reveal();
- };
- target.addEventListener("pointermove", move);
- target.addEventListener("pointerup", end);
- target.addEventListener("pointercancel", end);
- };
-
- /** A press on the track (not the thumb) pages towards the press. */
- const pressTrack = (event: ReactPointerEvent<HTMLDivElement>) => {
- if (event.target !== event.currentTarget) return;
- const rect = event.currentTarget.getBoundingClientRect();
- const y = event.clientY - rect.top;
- let direction: -1 | 1;
- if (state.mode === "history") {
- const { size, top } = historyThumb();
- direction = y < top ? -1 : 1;
- if (y >= top && y <= top + size) return;
- } else {
- direction = y < rect.height / 2 ? -1 : 1;
- }
- holdStep(event, direction, "page");
- };
-
- // Nothing to scroll: no bar at all, not even an invisible one in the way.
- if (state.mode === "none") return null;
-
- const visible = shown || hovered || dragging;
- const thumb = state.mode === "history" ? historyThumb() : null;
- const atTop = state.mode === "history" && state.viewportY <= 0;
- const atBottom = state.mode === "history" && state.viewportY >= state.baseY;
-
- return (
- <div
- data-testid={testId}
- data-mode={state.mode}
- data-visible={visible ? "true" : "false"}
- role="scrollbar"
- aria-label={labels.bar}
- aria-orientation="vertical"
- aria-valuemin={0}
- aria-valuemax={state.mode === "history" ? state.baseY : undefined}
- aria-valuenow={state.mode === "history" ? state.viewportY : undefined}
- onPointerEnter={() => setHovered(true)}
- onPointerLeave={() => {
- setHovered(false);
- reveal();
- }}
- onMouseDown={(e) => e.stopPropagation()}
- onWheel={(e) => {
- // A wheel over the bar itself scrolls the pane like a wheel anywhere else.
- if (Math.abs(e.deltaY) <= Math.abs(e.deltaX)) return;
- step(e.deltaY < 0 ? -1 : 1, "line");
- }}
- className={cn(
- "absolute bottom-1 right-0.5 top-1 z-20 flex w-3.5 select-none flex-col items-center gap-0.5 rounded-full",
- "transition-opacity duration-200",
- visible ? "pointer-events-auto opacity-100" : "pointer-events-none opacity-0",
- (hovered || dragging) && "bg-[hsl(var(--muted)/0.55)]",
- )}
- >
- <button
- type="button"
- tabIndex={-1}
- aria-label={labels.up}
- data-testid={testId ? `${testId}-up` : undefined}
- disabled={atTop}
- onPointerDown={(e) => holdStep(e, -1, "line")}
- className="flex h-3.5 w-3.5 shrink-0 items-center justify-center rounded-full text-muted-foreground hover:text-foreground disabled:opacity-30"
- >
- <ChevronUp className="h-3 w-3" strokeWidth={2.5} />
- </button>
- <div
- ref={trackRef}
- data-testid={testId ? `${testId}-track` : undefined}
- onPointerDown={pressTrack}
- className="relative w-full min-h-0 flex-1 cursor-default"
- >
- {thumb && (
- <div
- data-testid={testId ? `${testId}-thumb` : undefined}
- onPointerDown={startDrag}
- className={cn(
- "absolute left-1/2 w-1.5 -translate-x-1/2 rounded-full",
- "bg-[hsl(var(--muted-foreground)/0.6)] hover:w-2 hover:bg-[hsl(var(--muted-foreground))]",
- dragging && "w-2 bg-[hsl(var(--foreground)/0.75)]",
- )}
- style={{ top: thumb.top, height: thumb.size }}
- />
- )}
- </div>
- <button
- type="button"
- tabIndex={-1}
- aria-label={labels.down}
- data-testid={testId ? `${testId}-down` : undefined}
- disabled={atBottom}
- onPointerDown={(e) => holdStep(e, 1, "line")}
- className="flex h-3.5 w-3.5 shrink-0 items-center justify-center rounded-full text-muted-foreground hover:text-foreground disabled:opacity-30"
- >
- <ChevronDown className="h-3 w-3" strokeWidth={2.5} />
- </button>
- </div>
- );
-}
diff --git a/dodaios/ui/web/frontend/src/components/agentic/terminalScrollSurface.ts b/dodaios/ui/web/frontend/src/components/agentic/terminalScrollSurface.ts
index 872a47ea6c..e62346b658 100644
--- a/dodaios/ui/web/frontend/src/components/agentic/terminalScrollSurface.ts
+++ b/dodaios/ui/web/frontend/src/components/agentic/terminalScrollSurface.ts
@@ -1,8 +1,9 @@
/**
* Invisible terminal scrolling helpers.
*
- * xterm owns the scroll position and wheel input remains contained inside the
- * pane. The visible scrollbar is drawn by ./PaneScrollbar, not by xterm.
+ * Agentic IDE panes intentionally draw no scrollbar. xterm still owns the
+ * scroll position, wheel input remains contained inside the pane, and the
+ * recorded conversation is opened from the book button in the pane header.
*
* `captureWheelForTerminalHistory` covers the one awkward input shape: a
* NORMAL-buffer CLI that has negotiated mouse tracking. There xterm has real
diff --git a/dodaios/ui/web/frontend/src/i18n/locales/de.json b/dodaios/ui/web/frontend/src/i18n/locales/de.json
index af7c8454ce..3845d3e528 100644
--- a/dodaios/ui/web/frontend/src/i18n/locales/de.json
+++ b/dodaios/ui/web/frontend/src/i18n/locales/de.json
@@ -5803,10 +5803,7 @@
"restart_aria": "{pane} neu starten",
"restart_title": "Ein frisches {agent} in {pane} starten",
"restart": "Neu starten",
- "show_in_git": "Änderungen von {pane} in Git anzeigen",
- "scrollbar": "Terminal scrollen",
- "scroll_up": "Nach oben scrollen",
- "scroll_down": "Nach unten scrollen"
+ "show_in_git": "Änderungen von {pane} in Git anzeigen"
}
},
"prompt_writer": {
diff --git a/dodaios/ui/web/frontend/src/i18n/locales/en.json b/dodaios/ui/web/frontend/src/i18n/locales/en.json
index 8574caa5c1..7ffc65b9fd 100644
--- a/dodaios/ui/web/frontend/src/i18n/locales/en.json
+++ b/dodaios/ui/web/frontend/src/i18n/locales/en.json
@@ -5803,10 +5803,7 @@
"restart_aria": "Restart {pane}",
"restart_title": "Start a fresh {agent} in {pane}",
"restart": "Restart",
- "show_in_git": "Show {pane}'s changes in Git",
- "scrollbar": "Scroll the terminal",
- "scroll_up": "Scroll up",
- "scroll_down": "Scroll down"
+ "show_in_git": "Show {pane}'s changes in Git"
}
},
"prompt_writer": {
diff --git a/dodaios/ui/web/frontend/src/i18n/locales/es.json b/dodaios/ui/web/frontend/src/i18n/locales/es.json
index a66415bd53..7118e83340 100644
--- a/dodaios/ui/web/frontend/src/i18n/locales/es.json
+++ b/dodaios/ui/web/frontend/src/i18n/locales/es.json
@@ -5803,10 +5803,7 @@
"restart_aria": "Reiniciar {pane}",
"restart_title": "Iniciar un {agent} nuevo en {pane}",
"restart": "Reiniciar",
- "show_in_git": "Mostrar los cambios de {pane} en Git",
- "scrollbar": "Desplazar la terminal",
- "scroll_up": "Desplazar hacia arriba",
- "scroll_down": "Desplazar hacia abajo"
+ "show_in_git": "Mostrar los cambios de {pane} en Git"
}
},
"prompt_writer": {
diff --git a/dodaios/ui/web/frontend/src/i18n/locales/pt.json b/dodaios/ui/web/frontend/src/i18n/locales/pt.json
index cf93312f91..aa1f760f68 100644
--- a/dodaios/ui/web/frontend/src/i18n/locales/pt.json
+++ b/dodaios/ui/web/frontend/src/i18n/locales/pt.json
@@ -5803,10 +5803,7 @@
"restart_aria": "Reiniciar {pane}",
"restart_title": "Iniciar um {agent} novo em {pane}",
"restart": "Reiniciar",
- "show_in_git": "Mostrar as alterações de {pane} no Git",
- "scrollbar": "Rolar o terminal",
- "scroll_up": "Rolar para cima",
- "scroll_down": "Rolar para baixo"
+ "show_in_git": "Mostrar as alterações de {pane} no Git"
}
},
"prompt_writer": {
diff --git a/dodaios/ui/web/frontend/src/i18n/locales/zh.json b/dodaios/ui/web/frontend/src/i18n/locales/zh.json
index 7924577b0a..5eff38a825 100644
--- a/dodaios/ui/web/frontend/src/i18n/locales/zh.json
+++ b/dodaios/ui/web/frontend/src/i18n/locales/zh.json
@@ -5803,10 +5803,7 @@
"restart_aria": "重启 {pane}",
"restart_title": "在 {pane} 中重新启动一个 {agent}",
"restart": "重启",
- "show_in_git": "在 Git 中显示 {pane} 的更改",
- "scrollbar": "滚动终端",
- "scroll_up": "向上滚动",
- "scroll_down": "向下滚动"
+ "show_in_git": "在 Git 中显示 {pane} 的更改"
}
},
"prompt_writer": {
diff --git a/dodaios/ui/web/frontend/src/index.css b/dodaios/ui/web/frontend/src/index.css
index ef33cc9e6c..edad4c111d 100644
--- a/dodaios/ui/web/frontend/src/index.css
+++ b/dodaios/ui/web/frontend/src/index.css
@@ -460,10 +460,10 @@ label,
display: none;
}
-/* Agentic IDE panes hide xterm's native scrollbar: they draw their own, which
- appears while scrolling and also drives full-screen CLIs that keep their
- history inside their own UI (./components/agentic/PaneScrollbar). Keep these
- rules top-level because xterm creates the viewport at runtime. */
+/* Agentic IDE panes intentionally show no scrollbar. Scrolling still works
+ through xterm's wheel handling, while recorded conversation history opens
+ from the book button in the pane header. Keep these rules top-level because
+ xterm creates the viewport at runtime. */
.agentic-terminal-host .xterm-viewport {
overscroll-behavior: contain;
scrollbar-width: none;
diff --git a/dodaios/workspace/agents.py b/dodaios/workspace/agents.py
index 7ea1362d2b..327b39a3ec 100644
--- a/dodaios/workspace/agents.py
+++ b/dodaios/workspace/agents.py
@@ -815,13 +815,7 @@ _AGENTS: dict[str, WorkspaceAgent] = {
# of embedded panes. A per-launch override leaves standalone Codex and
# the account's saved settings untouched; installation remains available
# through Jarvis's CLI controls.
- #
- # ``--no-alt-screen``: the pane's terminal keeps the conversation as
- # real scrollback, so the pane scrollbar can show and seek the true
- # position. On the alternate screen Codex keeps its history inside its
- # own UI, and no position is knowable from outside (measured on 0.160:
- # ?1049 plus ?1003 mouse reporting). Also accepted after ``resume``.
- launch_args=("-c", "check_for_update_on_startup=false", "--no-alt-screen"),
+ launch_args=("-c", "check_for_update_on_startup=false"),
trust=CODEX_TRUST,
account=AccountSpec(env=(("CODEX_HOME", "{dir}"),), native_dir="~/.codex"),
win_shim=WinShim(
diff --git a/tests/unit/agentic_ide/test_session.py b/tests/unit/agentic_ide/test_session.py
index d3d7fcfd9c..db1929b8b0 100644
--- a/tests/unit/agentic_ide/test_session.py
+++ b/tests/unit/agentic_ide/test_session.py
@@ -89,7 +89,7 @@ def test_codex_npm_shim_is_bypassed_with_absolute_node(tmp_path, monkeypatch) ->
assert tuple(os.path.normcase(part) for part in argv[:2]) == tuple(
os.path.normcase(str(path)) for path in (node_exe, codex_js)
)
- assert argv[2:] == ("-c", "check_for_update_on_startup=false", "--no-alt-screen")
+ assert argv[2:] == ("-c", "check_for_update_on_startup=false")
assert not any(part.lower().endswith((".cmd", ".bat")) for part in argv)
diff --git a/tests/unit/workspace/test_codex_embedded_launch.py b/tests/unit/workspace/test_codex_embedded_launch.py
index f591828c56..d216f343ef 100644
--- a/tests/unit/workspace/test_codex_embedded_launch.py
+++ b/tests/unit/workspace/test_codex_embedded_launch.py
@@ -27,8 +27,6 @@ def test_embedded_codex_suppresses_update_box_on_every_launch(
assert argv[-2:] == ("resume", "conversation")
assert argv[1:3] == ("-c", "check_for_update_on_startup=false")
- # Real scrollback in the pane, so its scrollbar shows the true position.
- assert argv[3] == "--no-alt-screen"
# Only pane launches get the override, never detection or the plain CLI
# command used outside the embedded IDE.
agent = get_agent("codex")