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.
Python agent-orchestrationai-agentai-coding-assistantclaude-codecoding-agentcomputer-usedesktop-applocal-firstmcppersonal-jarvisvoice-assistantvoice-coding
feat(agentic-ide): pane history view with a real scrollbar
rubenluetke10-beepb632c5281427
diff --git a/jarvis/ui/web/frontend/src/components/agentic/AgenticTerminal.tsx b/jarvis/ui/web/frontend/src/components/agentic/AgenticTerminal.tsxindex 721b1f39aa..102757e023 100644--- a/jarvis/ui/web/frontend/src/components/agentic/AgenticTerminal.tsx+++ b/jarvis/ui/web/frontend/src/components/agentic/AgenticTerminal.tsx@@ -56,6 +56,7 @@ import { CanvasAddon } from "@xterm/addon-canvas";import { Unicode11Addon } from "@xterm/addon-unicode11";import "@xterm/xterm/css/xterm.css";import {+ BookOpenText,Check,Columns2,Loader2,@@ -122,6 +123,8 @@ import {} from "./paneSocket";import { PromptReceipt } from "./PromptReceipt";import { PromptHistoryButton } from "./PromptHistoryButton";+import { PaneConversationDialog } from "./PaneConversationDialog";+import { useT } from "@/i18n";/*** How old a delivery may be and still raise its receipt on a fresh connection.@@ -420,6 +423,10 @@ export function AgenticTerminal({const [dismissedAt, setDismissedAt] = useState<number | null>(null);/** Briefly true right after a delivery — draws the eye to the right pane. */const [justDelivered, setJustDelivered] = useState(false);+ /** The pane's recorded conversation, opened from the header book button or+ * a click on the scroll rail's grip. Lives HERE and not in the rail so the+ * entry point survives the CLI flipping its scroll-owner mode mid-session. */+ const [historyOpen, setHistoryOpen] = useState(false);// Latest callbacks/appearance without re-running the connect effect.const onStatusRef = useRef(onStatus);const onAttachErrorRef = useRef(onAttachError);@@ -1409,6 +1416,7 @@ export function AgenticTerminal({onRename={onRename}onClose={onClose}splitDisabled={splitDisabled}+ onOpenConversation={() => setHistoryOpen(true)}/>{/*Keep the visual inset OUTSIDE xterm's measured host. FitAddon reads the@@ -1445,6 +1453,12 @@ export function AgenticTerminal({epoch={terminalEpoch}appearance={appearance}onFocus={onFocus}+ onOpenHistory={() => setHistoryOpen(true)}+ />+ <PaneConversationDialog+ terminal={name}+ open={historyOpen}+ onOpenChange={setHistoryOpen}/>{/*The pane says it is starting, instead of being a black rectangle.@@ -1540,6 +1554,7 @@ function PaneHeader({onRestart,onArrangeStart,arranging = false,+ onOpenConversation,}: {workspaceId?: string;name: string;@@ -1565,7 +1580,10 @@ function PaneHeader({/** Press on the header picks the pane up; absent leaves it undraggable. */onArrangeStart?: (event: React.PointerEvent) => void;arranging?: boolean;+ /** Opens the pane's recorded conversation — the mode-proof scroll history. */+ onOpenConversation?: () => void;}) {+ const t = useT();const light = appearance === "light";// Which split button opened the CLI picker, if any.const [picking, setPicking] = useState<SplitDirection | null>(null);@@ -1824,6 +1842,17 @@ function PaneHeader({count={promptCount}light={light}/>+ {/* The one scroll-history entry point that cannot flicker away: the+ CLI may flip its scroll-owner mode mid-session (Claude Code does),+ but the pane's recorded conversation is always openable. */}+ <PaneAction+ label={t("agentic_grid.conversation.open").replace("{0}", name)}+ testId={`pane-conversation-${name}`}+ light={light}+ onClick={onOpenConversation}+ >+ <BookOpenText className="h-3.5 w-3.5" aria-hidden="true" />+ </PaneAction><PaneActionlabel={maximized ? `Restore ${name}` : `Maximize ${name}`}testId={`pane-maximize-${name}`}diff --git a/jarvis/ui/web/frontend/src/components/agentic/PaneConversationDialog.test.tsx b/jarvis/ui/web/frontend/src/components/agentic/PaneConversationDialog.test.tsxnew file mode 100644index 0000000000..d3a4b33688--- /dev/null+++ b/jarvis/ui/web/frontend/src/components/agentic/PaneConversationDialog.test.tsx@@ -0,0 +1,89 @@+import { render, screen, waitFor } from "@testing-library/react";+import { afterEach, describe, expect, it, vi } from "vitest";+import { PaneConversationDialog } from "./PaneConversationDialog";+import type { ConversationResponse } from "@/lib/agenticIdeApi";++const CONVERSATION: ConversationResponse = {+ terminal: "T7",+ agent: "claude",+ readable: true,+ available: true,+ turns: [+ { role: "user", text: "fix the scrollbar please", steps: [] },+ {+ role: "assistant",+ text: "Rebuilding it now.",+ steps: [+ { tool: "Read", target: "PaneScrollRail.tsx", detail: "{}" },+ { tool: "Edit", target: "PaneScrollRail.tsx", detail: "{}" },+ ],+ },+ ],+};++function stubFetch(payload: unknown, ok = true): ReturnType<typeof vi.fn> {+ const stub = vi.fn().mockResolvedValue({+ ok,+ status: ok ? 200 : 500,+ json: () => Promise.resolve(payload),+ });+ vi.stubGlobal("fetch", stub);+ return stub;+}++afterEach(() => {+ vi.unstubAllGlobals();+});++describe("PaneConversationDialog", () => {+ it("renders the recorded turns with a scrollable history surface", async () => {+ const fetchStub = stubFetch(CONVERSATION);+ render(+ <PaneConversationDialog terminal="T7" open onOpenChange={() => {}} />,+ );++ await waitFor(() =>+ expect(screen.getByText("fix the scrollbar please")).toBeTruthy(),+ );+ expect(screen.getByText("Rebuilding it now.")).toBeTruthy();+ // The tool work is summarised, not dumped: count plus tool names.+ expect(screen.getByText(/Read, Edit/)).toBeTruthy();+ // The scroller is a real overflow container — ITS scrollbar is the honest+ // "where am I", which the live TUI pane can never give.+ const scroller = screen.getByTestId("pane-conversation-scroller");+ expect(scroller.className).toContain("overflow-y-auto");+ expect(fetchStub).toHaveBeenCalledWith(+ "/api/agentic-ide/terminals/T7/conversation",+ expect.anything(),+ );+ });++ it("says honestly when this CLI keeps no readable record", async () => {+ stubFetch({+ terminal: "T2",+ agent: "shell",+ readable: false,+ available: false,+ turns: [],+ });+ render(+ <PaneConversationDialog terminal="T2" open onOpenChange={() => {}} />,+ );++ await waitFor(() =>+ expect(screen.getByText("No history yet")).toBeTruthy(),+ );+ });++ it("loads nothing while closed", () => {+ const fetchStub = stubFetch(CONVERSATION);+ render(+ <PaneConversationDialog+ terminal="T7"+ open={false}+ onOpenChange={() => {}}+ />,+ );+ expect(fetchStub).not.toHaveBeenCalled();+ });+});diff --git a/jarvis/ui/web/frontend/src/components/agentic/PaneConversationDialog.tsx b/jarvis/ui/web/frontend/src/components/agentic/PaneConversationDialog.tsxnew file mode 100644index 0000000000..9f6968abde--- /dev/null+++ b/jarvis/ui/web/frontend/src/components/agentic/PaneConversationDialog.tsx@@ -0,0 +1,230 @@+/**+ * The pane's conversation history with a REAL scrollbar.+ *+ * A coding TUI owns its screen, and 2.1.226-era Claude Code even switches+ * buffer modes mid-session, so no rail over the live terminal can honestly+ * show "where am I in the history". This dialog can: it renders the+ * conversation the CLI itself recorded on disk (see terminal_conversation in+ * agentic_ide_routes.py), which Jarvis owns end-to-end — so the scrollbar+ * here is a normal, accurate browser scrollbar over real content, identical+ * for every provider. Opened from the pane scroll rail.+ */+import { useEffect, useRef, useState } from "react";+import * as Dialog from "@radix-ui/react-dialog";+import { AlertCircle, BookOpenText, RefreshCw, X } from "lucide-react";++import { useT } from "@/i18n";+import {+ fetchTerminalConversation,+ type ConversationResponse,+ type ConversationTurn,+} from "@/lib/agenticIdeApi";+import { cn } from "@/lib/utils";++function fill(template: string, ...values: Array<string | number>): string {+ return values.reduce<string>(+ (text, value, index) => text.replace(`{${index}}`, String(value)),+ template,+ );+}++export function PaneConversationDialog({+ terminal,+ open,+ onOpenChange,+}: {+ terminal: string;+ open: boolean;+ onOpenChange: (open: boolean) => void;+}): JSX.Element {+ const t = useT();+ const [loading, setLoading] = useState(false);+ const [error, setError] = useState("");+ const [conversation, setConversation] = useState<ConversationResponse | null>(+ null,+ );+ const [reloadToken, setReloadToken] = useState(0);+ const scrollerRef = useRef<HTMLDivElement | null>(null);++ useEffect(() => {+ if (!open) return;+ let current = true;+ setLoading(true);+ setError("");+ fetchTerminalConversation(terminal)+ .then((result) => {+ if (current) setConversation(result);+ })+ .catch((reason: unknown) => {+ if (current) {+ setError(reason instanceof Error ? reason.message : String(reason));+ }+ })+ .finally(() => {+ if (current) setLoading(false);+ });+ return () => {+ current = false;+ };+ }, [open, reloadToken, terminal]);++ useEffect(() => {+ // The newest exchange is what the user scrolled up FROM, so the view+ // starts at the bottom — exactly like the terminal it explains.+ if (loading || !conversation) return;+ const scroller = scrollerRef.current;+ if (scroller) scroller.scrollTop = scroller.scrollHeight;+ }, [loading, conversation]);++ const turns = conversation?.turns ?? [];+ const empty =+ !loading && !error && (!conversation || !conversation.available || turns.length === 0);++ return (+ <Dialog.Root open={open} onOpenChange={onOpenChange}>+ <Dialog.Portal>+ <Dialog.Overlay className="fixed inset-0 z-[80] bg-[#090909]/75 backdrop-blur-sm data-[state=open]:animate-in data-[state=open]:fade-in-0 motion-reduce:animate-none" />+ <Dialog.Content+ data-testid={`pane-conversation-dialog-${terminal}`}+ className={cn(+ "fixed left-1/2 top-1/2 z-[90] flex h-[min(84dvh,52rem)] w-[min(880px,calc(100vw-2rem))]",+ "-translate-x-1/2 -translate-y-1/2 flex-col overflow-hidden rounded-2xl border border-border",+ "bg-card shadow-[0_28px_90px_-24px_rgba(0,0,0,0.75)] outline-none",+ "data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 motion-reduce:animate-none",+ )}+ >+ <header className="flex items-start justify-between gap-4 border-b border-border px-5 py-4">+ <div className="min-w-0">+ <div className="mb-1 flex items-center gap-2">+ <BookOpenText className="h-4 w-4 text-primary" aria-hidden="true" />+ <Dialog.Title className="font-display text-base font-semibold tracking-tight text-foreground">+ {fill(t("agentic_grid.conversation.title"), terminal)}+ </Dialog.Title>+ </div>+ <Dialog.Description className="text-xs leading-relaxed text-muted-foreground">+ {t("agentic_grid.conversation.description")}+ </Dialog.Description>+ </div>+ <div className="flex shrink-0 items-center gap-1.5">+ <button+ type="button"+ aria-label={t("agentic_grid.conversation.refresh")}+ title={t("agentic_grid.conversation.refresh")}+ data-testid="pane-conversation-refresh"+ onClick={() => setReloadToken((token) => token + 1)}+ className="flex h-8 w-8 items-center justify-center rounded-lg text-muted-foreground transition-colors hover:bg-muted hover:text-foreground active:translate-y-px"+ >+ <RefreshCw className="h-4 w-4" aria-hidden="true" />+ </button>+ <Dialog.Close asChild>+ <button+ type="button"+ aria-label={t("agentic_grid.conversation.close")}+ className="flex h-8 w-8 items-center justify-center rounded-lg text-muted-foreground transition-colors hover:bg-muted hover:text-foreground active:translate-y-px"+ >+ <X className="h-4 w-4" aria-hidden="true" />+ </button>+ </Dialog.Close>+ </div>+ </header>++ {loading ? (+ <div className="flex-1 space-y-4 overflow-hidden p-6">+ {["w-3/4", "w-full", "w-5/6", "w-2/3", "w-full", "w-4/5"].map(+ (width, row) => (+ <div+ key={row}+ className={cn("h-3 animate-pulse rounded bg-muted/70", width)}+ />+ ),+ )}+ </div>+ ) : error ? (+ <div className="flex flex-1 flex-col items-center justify-center px-6 text-center">+ <AlertCircle className="mb-3 h-6 w-6 text-destructive" aria-hidden="true" />+ <p className="text-sm font-medium text-foreground">+ {t("agentic_grid.conversation.load_failed")}+ </p>+ <p className="mt-1 max-w-md text-xs text-muted-foreground" role="alert">+ {error}+ </p>+ <button+ type="button"+ onClick={() => setReloadToken((token) => token + 1)}+ className="mt-4 inline-flex h-9 items-center gap-2 rounded-lg border border-border px-3 text-xs font-medium text-foreground transition-colors hover:bg-muted active:translate-y-px"+ >+ <RefreshCw className="h-3.5 w-3.5" aria-hidden="true" />+ {t("agentic_grid.conversation.retry")}+ </button>+ </div>+ ) : empty ? (+ <div className="flex flex-1 flex-col items-center justify-center px-6 text-center">+ <div className="mb-4 flex h-12 w-12 items-center justify-center rounded-2xl border border-border bg-muted/30">+ <BookOpenText className="h-5 w-5 text-muted-foreground" aria-hidden="true" />+ </div>+ <p className="text-sm font-medium text-foreground">+ {t("agentic_grid.conversation.empty_title")}+ </p>+ <p className="mt-1 max-w-sm text-xs leading-relaxed text-muted-foreground">+ {t("agentic_grid.conversation.empty_detail")}+ </p>+ </div>+ ) : (+ <div+ ref={scrollerRef}+ data-testid="pane-conversation-scroller"+ className="min-h-0 flex-1 overflow-y-auto scroll-pt-4 px-5 py-4 scrollbar-jarvis"+ >+ {turns.map((turn, index) => (+ <TurnBlock key={index} turn={turn} />+ ))}+ </div>+ )}+ </Dialog.Content>+ </Dialog.Portal>+ </Dialog.Root>+ );+}++function TurnBlock({ turn }: { turn: ConversationTurn }): JSX.Element {+ const t = useT();+ const user = turn.role === "user";+ const tools = [...new Set(turn.steps.map((step) => step.tool))];+ return (+ <div className="mb-4 last:mb-0">+ <div+ className={cn(+ "mb-1 text-[10px] font-semibold uppercase tracking-[0.14em]",+ user ? "text-primary" : "text-muted-foreground",+ )}+ >+ {t(user ? "agentic_grid.conversation.you" : "agentic_grid.conversation.agent")}+ </div>+ {turn.text && (+ <div+ className={cn(+ "whitespace-pre-wrap break-words rounded-xl border px-3.5 py-2.5 text-[12.5px] leading-relaxed",+ user+ ? "border-primary/25 bg-primary/[0.07] text-foreground"+ : "border-border/60 bg-background/35 text-foreground/90",+ )}+ >+ {turn.text}+ </div>+ )}+ {turn.steps.length > 0 && (+ <div className="mt-1 truncate text-[10px] text-muted-foreground/80">+ {fill(+ t(+ turn.steps.length === 1+ ? "agentic_grid.conversation.steps_one"+ : "agentic_grid.conversation.steps_many",+ ),+ turn.steps.length,+ )}+ {tools.length > 0 && <> · {tools.slice(0, 6).join(", ")}</>}+ </div>+ )}+ </div>+ );+}diff --git a/jarvis/ui/web/frontend/src/components/agentic/PaneScrollRail.test.tsx b/jarvis/ui/web/frontend/src/components/agentic/PaneScrollRail.test.tsxindex 853fe3f6d4..e7d1634a10 100644--- a/jarvis/ui/web/frontend/src/components/agentic/PaneScrollRail.test.tsx+++ b/jarvis/ui/web/frontend/src/components/agentic/PaneScrollRail.test.tsx@@ -121,7 +121,15 @@ function fakeTerminal({};}-function RailHarness({ name, term }: { name: string; term: Terminal }) {+function RailHarness({+ name,+ term,+ onOpenHistory,+}: {+ name: string;+ term: Terminal;+ onOpenHistory?: () => void;+}) {const regionRef = useRef<HTMLDivElement | null>(null);const hostRef = useRef<HTMLDivElement | null>(null);const terminalRef = useRef<Terminal | null>(term);@@ -138,6 +146,7 @@ function RailHarness({ name, term }: { name: string; term: Terminal }) {terminalRef={terminalRef}epoch={1}appearance="dark"+ onOpenHistory={onOpenHistory}/></div>);@@ -265,6 +274,32 @@ describe("PaneScrollRail", () => {expect(screen.queryByTestId("pane-scroll-thumb-Rex")).toBeNull();});+ it("opens the recorded conversation on a grip click, but not after a drag", () => {+ const harness = fakeTerminal({ owner: "mouse-app" });+ const onOpenHistory = vi.fn();+ render(+ <RailHarness name="Uma" term={harness.term} onOpenHistory={onOpenHistory} />,+ );+ const rail = giveTrackGeometry("Uma");+ const grip = screen.getByTestId("pane-scroll-grip-Uma");++ // A real drag scrolls; it must NOT also open the history on release.+ fireEvent.pointerDown(grip, { button: 0, clientY: 100, pointerId: 11 });+ fireEvent.pointerMove(rail, { clientY: 60, pointerId: 11 });+ fireEvent.pointerUp(rail, { clientY: 60, pointerId: 11 });+ expect(onOpenHistory).not.toHaveBeenCalled();++ // A press-and-release that never moved is a click, and a click opens it.+ fireEvent.pointerDown(grip, { button: 0, clientY: 100, pointerId: 12 });+ fireEvent.pointerUp(rail, { clientY: 101, pointerId: 12 });+ expect(onOpenHistory).toHaveBeenCalledTimes(1);++ // Pressing the empty track is a stroke gesture, never a click-open.+ fireEvent.pointerDown(rail, { button: 0, clientY: 40, pointerId: 13 });+ fireEvent.pointerUp(rail, { clientY: 40, pointerId: 13 });+ expect(onOpenHistory).toHaveBeenCalledTimes(1);+ });+it("pages the application from the visible arrow caps", () => {const harness = fakeTerminal({ owner: "mouse-app" });render(<RailHarness name="Odo" term={harness.term} />);diff --git a/jarvis/ui/web/frontend/src/components/agentic/PaneScrollRail.tsx b/jarvis/ui/web/frontend/src/components/agentic/PaneScrollRail.tsxindex 4c62794fe6..026c168e99 100644--- a/jarvis/ui/web/frontend/src/components/agentic/PaneScrollRail.tsx+++ b/jarvis/ui/web/frontend/src/components/agentic/PaneScrollRail.tsx@@ -30,6 +30,7 @@ import {type RefObject,} from "react";import type { Terminal } from "@xterm/xterm";+import { useT } from "@/i18n";import { cn } from "@/lib/utils";import { PANE_CHROME, type TerminalAppearance } from "./terminalThemes";import {@@ -53,9 +54,17 @@ interface DragSession {/** Where the pointer went down — the grip's visual travel is measured from* here so it can spring back to centre on release. Application rails only. */originY: number;+ /** Did this gesture start on the grip capsule itself? */+ grabbedGrip: boolean;+ /** Farthest the pointer travelled — a release under the click threshold+ * opens the pane's conversation history instead of having scrolled. */+ movedPx: number;captured: boolean;}+/** Pointer travel below which a grip press-and-release counts as a click. */+const GRIP_CLICK_PX = 5;+/** Height of the application grip capsule, in px. Must match the render. */const GRIP_PX = 28;/** Height of one arrow cap, which the grip must never slide under. */@@ -71,6 +80,9 @@ interface PaneScrollRailProps {epoch: number;appearance: TerminalAppearance;onFocus?: () => void;+ /** A click (not a drag) on the application grip asks for the pane's+ * recorded conversation — the owner of that dialog lives in the pane. */+ onOpenHistory?: () => void;}function sameView(@@ -94,9 +106,12 @@ export function PaneScrollRail({epoch,appearance,onFocus,+ onOpenHistory,}: PaneScrollRailProps) {+ const t = useT();const trackRef = useRef<HTMLDivElement | null>(null);const thumbRef = useRef<HTMLDivElement | null>(null);+ const gripRef = useRef<HTMLDivElement | null>(null);const dragRef = useRef<DragSession | null>(null);const frameRef = useRef<number | null>(null);const [view, setView] = useState<TerminalScrollView | null>(null);@@ -260,6 +275,10 @@ export function PaneScrollRail({grabOffset,lastY: event.clientY,originY: event.clientY,+ grabbedGrip:+ gripRef.current !== null &&+ gripRef.current.contains(event.target as Node),+ movedPx: 0,captured: false,};setDragging(true);@@ -289,6 +308,10 @@ export function PaneScrollRail({if (!drag || !term || drag.pointerId !== event.pointerId) return;event.preventDefault();const current = readTerminalScrollView(term);+ drag.movedPx = Math.max(+ drag.movedPx,+ Math.abs(event.clientY - drag.originY),+ );if (drag.owner === "terminal" && current.owner === "terminal") {moveExact(current, event.clientY, drag.grabOffset);} else {@@ -330,14 +353,25 @@ export function PaneScrollRail({const onPointerUp = useCallback((event: ReactPointerEvent<HTMLDivElement>) => {+ const drag = dragRef.current;+ // A press-and-release on the grip that never really moved is a CLICK,+ // and a click on the grip opens the one history that can honestly show+ // a position: the pane's own recorded conversation.+ const clickedGrip =+ drag !== null &&+ drag.pointerId === event.pointerId &&+ drag.owner === "application" &&+ drag.grabbedGrip &&+ drag.movedPx < GRIP_CLICK_PX;finishDrag(event.pointerId);try {event.currentTarget.releasePointerCapture(event.pointerId);} catch {// No capture was available; the drag still completed on this event.}+ if (clickedGrip) onOpenHistory?.();},- [finishDrag],+ [finishDrag, onOpenHistory],);const onKeyDown = useCallback(@@ -484,8 +518,10 @@ export function PaneScrollRail({*/}{!exact && (<div+ ref={gripRef}data-testid={`pane-scroll-grip-${name}`}- aria-hidden="true"+ role="presentation"+ title={t("agentic_grid.conversation.grip_hint")}className={cn("absolute left-1/2 top-1/2 w-2 rounded-full bg-[#e7c46e]/45","shadow-[0_0_0_1px_rgba(0,0,0,0.18)]",diff --git a/jarvis/ui/web/frontend/src/i18n/locales/de.json b/jarvis/ui/web/frontend/src/i18n/locales/de.jsonindex 005fca291a..d9986ab76b 100644--- a/jarvis/ui/web/frontend/src/i18n/locales/de.json+++ b/jarvis/ui/web/frontend/src/i18n/locales/de.json@@ -3861,6 +3861,22 @@"waiting": "Wartet auf Enter","unconfirmed": "Zustellung unbestätigt"},+ "conversation": {+ "title": "Verlauf von {0}",+ "description": "Die Unterhaltung, wie dieser Agent sie selbst aufgezeichnet hat — mit echter Scrollbar.",+ "open": "Verlauf von {0} öffnen",+ "close": "Verlauf schließen",+ "refresh": "Verlauf neu laden",+ "load_failed": "Der Verlauf konnte nicht geladen werden.",+ "retry": "Erneut versuchen",+ "empty_title": "Noch kein Verlauf",+ "empty_detail": "Sobald dieser Agent Nachrichten ausgetauscht hat, erscheint hier die komplette Unterhaltung.",+ "you": "Du",+ "agent": "Agent",+ "steps_one": "1 Arbeitsschritt",+ "steps_many": "{0} Arbeitsschritte",+ "grip_hint": "Klicken: Verlauf öffnen · Ziehen: scrollen"+ },"selection": {"start": "Terminals auswählen","finish": "Auswahl beenden",diff --git a/jarvis/ui/web/frontend/src/i18n/locales/en.json b/jarvis/ui/web/frontend/src/i18n/locales/en.jsonindex e9bfc390e1..0ca2d81510 100644--- a/jarvis/ui/web/frontend/src/i18n/locales/en.json+++ b/jarvis/ui/web/frontend/src/i18n/locales/en.json@@ -3861,6 +3861,22 @@"waiting": "Waiting for Enter","unconfirmed": "Delivery unconfirmed"},+ "conversation": {+ "title": "History of {0}",+ "description": "The conversation as this agent recorded it — with a real scrollbar.",+ "open": "Open the history of {0}",+ "close": "Close history",+ "refresh": "Reload history",+ "load_failed": "The history could not be loaded.",+ "retry": "Try again",+ "empty_title": "No history yet",+ "empty_detail": "Once this agent has exchanged messages, the full conversation appears here.",+ "you": "You",+ "agent": "Agent",+ "steps_one": "1 tool step",+ "steps_many": "{0} tool steps",+ "grip_hint": "Click: open history · drag: scroll"+ },"selection": {"start": "Select terminals","finish": "Done selecting",diff --git a/jarvis/ui/web/frontend/src/i18n/locales/es.json b/jarvis/ui/web/frontend/src/i18n/locales/es.jsonindex f05508e5e1..0a47bd009a 100644--- a/jarvis/ui/web/frontend/src/i18n/locales/es.json+++ b/jarvis/ui/web/frontend/src/i18n/locales/es.json@@ -3861,6 +3861,22 @@"waiting": "Esperando Enter","unconfirmed": "Entrega sin confirmar"},+ "conversation": {+ "title": "Historial de {0}",+ "description": "La conversación tal como la registró este agente — con una barra de desplazamiento real.",+ "open": "Abrir el historial de {0}",+ "close": "Cerrar historial",+ "refresh": "Recargar historial",+ "load_failed": "No se pudo cargar el historial.",+ "retry": "Reintentar",+ "empty_title": "Aún sin historial",+ "empty_detail": "Cuando este agente haya intercambiado mensajes, la conversación completa aparecerá aquí.",+ "you": "Tú",+ "agent": "Agente",+ "steps_one": "1 paso de herramienta",+ "steps_many": "{0} pasos de herramienta",+ "grip_hint": "Clic: abrir historial · arrastrar: desplazar"+ },"selection": {"start": "Seleccionar terminales","finish": "Terminar selección",diff --git a/jarvis/ui/web/frontend/src/lib/agenticIdeApi.ts b/jarvis/ui/web/frontend/src/lib/agenticIdeApi.tsindex e2c72d2883..d9fa393891 100644--- a/jarvis/ui/web/frontend/src/lib/agenticIdeApi.ts+++ b/jarvis/ui/web/frontend/src/lib/agenticIdeApi.ts@@ -591,6 +591,41 @@ export function fetchPromptHistory();}+export interface ConversationStep {+ tool: string;+ target: string;+ detail: string;+}++export interface ConversationTurn {+ role: "user" | "assistant" | string;+ text: string;+ steps: ConversationStep[];+}++export interface ConversationResponse {+ terminal: string;+ agent: string;+ /** False when this CLI's session records exist but cannot be parsed. */+ readable: boolean;+ /** False when this CLI keeps no session record to read at all. */+ available: boolean;+ turns: ConversationTurn[];+}++/**+ * The pane's conversation as the CLI itself recorded it on disk — the one+ * scroll-history source that does not depend on what the TUI happens to be+ * painting, which is why the pane history view is built on it.+ */+export function fetchTerminalConversation(+ name: string,+): Promise<ConversationResponse> {+ return getJson<ConversationResponse>(+ `/api/agentic-ide/terminals/${encodeURIComponent(name)}/conversation`,+ );+}+function recapUrl(name: string, workspaceId?: string, suffix = ""): string {const query = workspaceId? `?workspace_id=${encodeURIComponent(workspaceId)}`