feat(desktop): wide code blocks + syntax highlighting in agent window (T-126) #117

Merged
ahitosly merged 1 commit from feat/T-126-agent-code-blocks-width-syntax-highlight into main 2026-09-08 20:09:54 +02:00
Owner

Tâche

T-xxx — (titre dans docs/STATUS.md)

Changements

Contrat modifié ?

  • Non
  • Oui : packages/contract / supabase/migrations — docs/API.md / docs/DATA.md mis à jour, label contract, approbation humaine requise

Tests

  • scripts/check.sh vert
  • Test manuel (OS, scénario) :

Impacts cross-domaine

Fichiers hors périmètre de l'agent (et pourquoi) :

Suivi

  • docs/STATUS.md mis à jour (ligne de la tâche)
  • docs/CHANGELOG.md : entrée ajoutée sous Unreleased
  • docs/DECISIONS.md / docs/ECARTS.md mis à jour si décision ou écart
## Tâche T-xxx — (titre dans docs/STATUS.md) ## Changements - ## Contrat modifié ? - [ ] Non - [ ] Oui : `packages/contract` / `supabase/migrations` — `docs/API.md` / `docs/DATA.md` mis à jour, label `contract`, approbation humaine requise ## Tests - [ ] `scripts/check.sh` vert - [ ] Test manuel (OS, scénario) : ## Impacts cross-domaine Fichiers hors périmètre de l'agent (et pourquoi) : ## Suivi - [ ] `docs/STATUS.md` mis à jour (ligne de la tâche) - [ ] `docs/CHANGELOG.md` : entrée ajoutée sous Unreleased - [ ] `docs/DECISIONS.md` / `docs/ECARTS.md` mis à jour si décision ou écart
feat(desktop): wide code blocks + syntax highlighting in agent window (T-126)
All checks were successful
ci / server (pull_request) Successful in 15s
ci / desktop-ts (pull_request) Successful in 28s
ci / desktop-rust (pull_request) Successful in 3m15s
688609aac7
Agent chat bubbles containing a code block (or an ASCII table sent as
code by Hermes, the concrete case that triggered this) now widen to
min(100%, 900px) instead of staying capped at 85%; default agent
window size bumped 720x620 -> 860x640 accordingly.

Code blocks with a recognized language now get real syntax
highlighting via a custom rehype plugin (rehype-highlight was tried
first but discarded after measuring the actual bundle cost: it
unconditionally imports lowlight's 37-language `common` set as a
fallback, which is not tree-shakeable even when a custom `languages`
subset is passed - confirmed empirically, bundle stayed at 344 kB
either way). The custom plugin registers 19 curated languages
directly via lowlight/createLowlight, bringing the agent bundle to
272.5 kB/83.2 kB gzip instead of 344.0 kB/104.1 kB gzip for the same
result. Highlight colors are defined in tokens.css from existing
--aria-* tokens (light/dark), not an imported highlight.js theme.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011MSWGSF3VJrGALNM8JsE2u
ahitosly scheduled this pull request to auto merge when all checks succeed 2026-09-08 20:09:49 +02:00
ahitosly deleted branch feat/T-126-agent-code-blocks-width-syntax-highlight 2026-09-08 20:09:54 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
cloud-rennais/aria!117
No description provided.