# Inline visuals

When the agent's answer is a diagram, a table, or an equation, Foxora draws it instead of dumping the source. Mermaid diagrams, CSV/JSON tables, and LaTeX math all render inline — in chat and on the Stage — with a fall-back to the raw source if anything's off.

## One registry, both places

A single set of visual renderers powers both the inline cards in chat and the full-height surfaces on the Stage. A fenced code block or an artifact whose language Foxora recognises gets drawn; anything it doesn’t recognise simply shows as highlighted source. Every renderer is crash-proof by contract — a load failure or malformed source falls back to exactly the code you’d have seen anyway.

## Mermaid diagrams

Fenced mermaid blocks compile to an SVG diagram, themed from the live design tokens so it matches light or dark mode — no hardcoded colours. Diagrams render in a strict security mode that strips any scripts from agent-authored source, and a half-streamed diagram shows its source until it’s complete and valid.

## Tables

CSV (and table artifacts) render as a real, scrollable table with a sticky header — zoomable like every Stage visual — and you can flip to the raw text with the Preview / Code toggle.

## Math

LaTeX / math sources render with KaTeX. Malformed TeX shows an inline error marker rather than crashing, and a hard failure falls back to the raw source.

> See the source any timeOn the Stage, the header’s Preview / Code toggle ( / ) flips a diagram, table, or doc between its rendered form and its source — and Copy / Download ( / ) grab the source or save the file with the right extension.
