Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions packages/core-ui/chat/session-chat-presentation-provider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,20 @@ import {
SessionChatSimpleModeContext,
} from './session-chat-simple-mode';

/** CDXC:SessionChat 2026-09-14 WHY:
* Pi, OMP, Hermes, and Antigravity terminals preserve single newlines in assistant replies, including emoji lists that CommonMark otherwise collapses into one paragraph.
/** CDXC:SessionChat 2026-09-17 WHY:
* Pi, OMP, Hermes, Antigravity, and ZCode terminals preserve single newlines in assistant replies, including emoji glyph lists that CommonMark otherwise collapses into one paragraph; the ZCode TUI paints every soft-break newline as its own row.
* Supersedes the 2026-09-14 wording, which predated ZCode becoming a chat agent family.
* Apply this only to assistant prose, keeping reasoning normalization and user quote handling independent.
*/
export const SessionChatAgentLineBreaksContext = createContext(false);

/** CDXC:SessionChat 2026-09-14 DECISION:
* User: Claude, Codex, Grok Build, and Cursor already look good; leave their newline rendering unchanged.
/** CDXC:SessionChat 2026-09-17 DECISION:
* User: ZCode joins the preserve list — its replies are written one row per line for the terminal, so chat must not collapse them.
* User, 2026-09-14: Claude, Codex, Grok Build, and Cursor already look good; leave their newline rendering unchanged.
*/
export function sessionChatPreservesAgentLineBreaks(agent: string | null | undefined): boolean {
const family = resolveSessionChatTranscriptAgent(agent);
return family === 'pi' || family === 'hermes' || family === 'antigravity';
return family === 'pi' || family === 'hermes' || family === 'antigravity' || family === 'zcode';
}

export function SessionChatPresentationProvider({
Expand Down
Loading