Calc2
All checks were successful
Build and Deploy Nuxt / build (push) Successful in 29s

This commit is contained in:
2026-10-02 02:14:29 +02:00
parent 325394150d
commit e36fef7290
21 changed files with 1745 additions and 46 deletions

View File

@@ -220,7 +220,15 @@ copy + an `APP_LANGUAGES` entry + the code in the backend's `SUPPORTED_LOCALES`.
- `app/utils/markdown.ts` — the single render pipeline: `markdown-it` (**html: false**,
raw HTML is escaped) + `markdown-it-texmath` + KaTeX (`$...$` inline, `$$...$$` display,
macros `\R \N \Z \Q \C`) + highlight.js, sanitized with DOMPurify. It also builds the
TOC. Render all article Markdown through this, not ad-hoc renderers.
TOC. Fenced blocks tagged ` ```example / theorem / corollary / definition / proof /
proposition / lemma ` (optionally followed by a title) render as callout boxes —
blockquote-styled, collapsible through a native `<details>` whose summary is the
label row (always opens open; MarkdownView animates the fold with the Web
Animations API — the intent rides on `data-open`, motion skipped under
`prefers-reduced-motion`), each kind with its own hue (`--box-*` in
`_tokens.scss`, shape `.md-box` in `_prose.scss`) and a label written in the
*article's* language (`MarkdownView`'s `articleLang` → `renderMarkdown`'s env,
never the UI locale). Render all article Markdown through this, not ad-hoc renderers.
- API calls use `$fetch` against `${useRuntimeConfig().public.apiBase}/api`.
## Gotchas