First off — I use jcode daily and it's great. This is the one papercut I keep hitting.
Problem
When the model produces a mermaid diagram, it never renders visually for me. The artifact side panel shows the raw HTML markup as plain text (<div>, <svg>, … printed literally) instead of a diagram or any readable fallback.
I'm genuinely unsure whether I'm missing a setting on my side or whether this is a bug, hence the issue rather than a PR.
Environment
- jcode
v0.76.0 (bbef1f6a8)
- macOS (Darwin 25.2.0), Apple Silicon
- Terminal: VS Code integrated terminal —
TERM=xterm-256color, TERM_PROGRAM=vscode
What I expect
I understand the VS Code terminal supports no inline image protocol (no kitty, no iTerm2, no Sixel), so I don't expect a real rendered diagram there. But I'd expect one of:
- the documented half-block / text fallback with the
TERMINAL_IMAGE_FALLBACK_NOTE message, or
- at minimum the original mermaid source, which is readable,
instead of the generated HTML wrapper dumped as text — that's the least useful of the three, since it's neither a picture nor something a human reads.
Questions
- Is there a config flag or env var to pick the fallback renderer explicitly for terminals with no image protocol?
- Is native rendering in the artifact side panel expected to work at all in the VS Code terminal, or is a graphics-capable terminal (Ghostty / kitty / WezTerm / iTerm2) a hard requirement? If it's a hard requirement, saying so in the docs would already save people the guesswork.
Related
Happy to provide a repro session, logs, or test a patch.
First off — I use jcode daily and it's great. This is the one papercut I keep hitting.
Problem
When the model produces a mermaid diagram, it never renders visually for me. The artifact side panel shows the raw HTML markup as plain text (
<div>,<svg>, … printed literally) instead of a diagram or any readable fallback.I'm genuinely unsure whether I'm missing a setting on my side or whether this is a bug, hence the issue rather than a PR.
Environment
v0.76.0 (bbef1f6a8)TERM=xterm-256color,TERM_PROGRAM=vscodeWhat I expect
I understand the VS Code terminal supports no inline image protocol (no kitty, no iTerm2, no Sixel), so I don't expect a real rendered diagram there. But I'd expect one of:
TERMINAL_IMAGE_FALLBACK_NOTEmessage, orinstead of the generated HTML wrapper dumped as text — that's the least useful of the three, since it's neither a picture nor something a human reads.
Questions
Related
WT_SESSIONmissing frominfer_protocol_from_env). Same family of problem (protocol detection falling through to a fallback), but that one is Windows-specific; this is the macOS / VS Code terminal path and the fallback output itself.Happy to provide a repro session, logs, or test a patch.