[Bug]: LaTeX in chat is broken: display math renders twice and unstyled, inline $...$ does not render
@aliarain arbeitet bereits daran.
Seit 24.9.2026.
Bewertung
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Anfängerfreundlichkeit
- 70/100
Rechercherichtung
Start with the math plugin's getStyles() entry point and inspect the generated index-.css and terminal-.css assets in the 0.1.35 build. Verify how KaTeX CSS and font files are included, then reproduce display and inline formulas to confirm each display renders once with styling and inline math is no longer literal text.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
GUI version
0.1.35
Operating system
Linux (Debian/Ubuntu)
Reproduction steps
- Send a single display formula, e.g.
$$x = \frac{a}{b}$$
or a message with several formulas (fractions, integrals, aligned blocks), e.g.$$e = mc^2$$. - Also send inline math, e.g.
$x^2$. -
- Display formulas appear twice. In the minimal repro (a single
$$x = \frac{a}{b}$$) the first copy shows the fraction stacked, but small and unstyled, immediately followed by a second copy using plain characters. - Inline math is not rendered at all:
$x^2$stays as literal text.
- Display formulas appear twice. In the minimal repro (a single
Expected behavior
Each formula should be rendered only once, using a better style.
Actual behavior
Display math parses and renders, but the output is doubled and visually broken; inline math does not render at all.
AI analysis
Doubling: looking at the installed 0.1.35 build, the likely cause is the KaTeX stylesheet. The renderer ships only index-.css and terminal-.css and neither contains any .katex rules — katex.min.css appears nowhere in the app. KaTeX emits both HTML and a MathML fallback; the stylesheet is what normally hides the MathML and lays out the HTML. Without it, both outputs are visible: the native MathML copy renders on top, and the HTML copy collapses into a run of unstyled characters next to it.
Inline: $x^2$ stays as literal text.
Suggested fix: bundle katex.min.css together with the KaTeX font files (KaTeX_Main, KaTeX_Math, KaTeX_Size*) — neither is in the 0.1.35 build (only the Geist UI fonts ship). The math plugin already declares the stylesheet via getStyles() -> "katex/dist/katex.min.css", but it never reaches the build.
Screenshots, recordings, or sanitized logs
Safety check
- I removed credentials and private project information from this report.
- Vorherrschende Sprache
- Shell
- Sterne
- 85
- Forks
- 5
- Ø Merge
- 2 Std. 46 Min.
- Gemergte PRs (30 T.)
- 1
Entwicklungsumgebung
Dieses Projekt bietet weder Dev-Container noch Dockerfile noch Beitragsleitfaden – die Einrichtung liegt bei Ihnen. Beginnen Sie mit der README; die allgemeinen Schritte stehen in unserem Leitfaden für den ersten Beitrag.
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus CommandCodeAI/desktop
-
bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 70/100
CommandCodeAI/desktop#125 ·
-
[Feedback]: add copy block under a code blockEvtl. vergeben @aliarain hat das vor 5 Tagen übernommen. Offenenhancement
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
CommandCodeAI/desktop#94 · 1 zugewiesene Person ·
-
[Feedback]: Add Expand & Collapse for changesEvtl. vergeben @aliarain hat das vor 5 Tagen übernommen. Offenenhancement
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
CommandCodeAI/desktop#66 · 1 Kommentar · 2 Reaktionen · 1 zugewiesene Person ·
-
bug
Schwierigkeit 3/5 1-2 Tage Anfängerfreundlichkeit 68/100
CommandCodeAI/desktop#126 ·
-
bug
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 35/100
CommandCodeAI/desktop#124 ·
Alle Issues in CommandCodeAI/desktop
Ähnliche Issues
-
Update vtm to 2026.9.28Offenpackage-update
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
oSoWoSo/vOid_Community_repOsitory#207 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
alunduil/alunduil-chezmoi#815 ·
Maintainer antworten meist innerhalb von 1 Tag
-
good first issue new package
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
wimpysworld/deb-get#2035 ·
Maintainer antworten meist innerhalb von 1 Tag
-
automation documentation
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 92/100
termux/termux-packages#32085 ·
Maintainer antworten meist innerhalb von 1 Tag