From 4f98abbc5da909522c45036a55ee1f11b18d0ebd Mon Sep 17 00:00:00 2001 From: claude Date: Mon, 8 Jun 2026 08:21:16 +0000 Subject: [PATCH] classHighlighter: map function(variableName) to tok-function All cm6 themes define .tok-function but the classHighlighter had no entry for tags.function(tags.variableName), so function-name tokens fell back to tok-variableName (which themes leave unstyled). This affected Typst function calls (#func(...)) and would affect any future language that tags function names with t.function(t.variableName). Co-Authored-By: Claude Sonnet 4.6 --- .../js/features/source-editor/extensions/class-highlighter.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/services/web/frontend/js/features/source-editor/extensions/class-highlighter.ts b/services/web/frontend/js/features/source-editor/extensions/class-highlighter.ts index a018ab6392..895b29b4a9 100644 --- a/services/web/frontend/js/features/source-editor/extensions/class-highlighter.ts +++ b/services/web/frontend/js/features/source-editor/extensions/class-highlighter.ts @@ -23,6 +23,7 @@ export const classHighlighter = tagHighlighter([ tag: [tags.regexp, tags.escape, tags.special(tags.string)], class: 'tok-string2', }, + { tag: tags.function(tags.variableName), class: 'tok-function' }, { tag: tags.variableName, class: 'tok-variableName' }, { tag: tags.local(tags.variableName), class: 'tok-variableName tok-local' }, {