feat(#439): syntax highlighting for markdown code blocks#688
Open
feat(#439): syntax highlighting for markdown code blocks#688
Conversation
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Merge in new multi-stage meal planning skill that: - Fixes partial-save issue by enforcing dual bulk_add_to_list calls - Adds 4-stage flow: preference collection → high-level plan → detailed recipes → iteration - Implements state persistence across context window changes - Enforces grouped questions (2-3 per batch) instead of sequential Replaces the basic meal planner from commit 5419b84 with the enhanced version.
…ill sequencing in the tool-use prompt\n- explicitly forbid run_intent during skill selection and loading\n- reject skill names passed to run_intent with a helpful error\n- fix meal planner examples to use bulk_add_to_list\n- clarify meal planner only uses run_intent during save stage\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…amples with exact runIntent syntax\n- forbid creating a master meal plan list\n- require full per-day ingredient payloads for shopping list saves\n- enforce metric/NZ-friendly units instead of imperial output\n- remove meal-plan anchoring from generic create_list example\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…n a meal' and similar phrasing as tool queries\n- treat short confirmations like 'continue' and 'ok let\'s do it' as tool follow-ups when prior exchange is tool-driven\n- preserve previous exchange context for tool follow-up turns\n- add focused tests for meal planner follow-up routing\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Add CodeTokenizer with 8 language tokenizers (Kotlin, Java, JS/TS, Python, Swift, Go, Rust, JSON) - Integrate tokenized highlighting into MarkdownRenderer FencedCodeBlock using Material 3 semantic colors - Add Compose previews for all supported languages - Unit tests for all tokenizers with 40+ assertions
- Fix redundant isUpperCase() && isUpperCase() condition in JSTokenizer - Remove duplicate entries from KOTLIN_KEYWORDS (is, apply) - Remove duplicate entries from JS_KEYWORDS (delete, typeof, true, false) - Remove duplicate entries from GO_KEYWORDS (go, select) - Remove built-in functions from JS_KEYWORDS (string, number, boolean)
- Add produceState for async tokenization to avoid UI jank - Fix JS tokenizer: add 'await' to keyword set - Fix Go tokenizer: check GO_TYPES before Variable fallback - Fix Java tokenizer: simplify keyword/type checking logic - Fix Python tokenizer: check PYTHON_TYPES, remove built-in functions from keywords - Fix Kotlin tokenizer: use find() instead of matchEntire() for annotations, check KOTLIN_TYPES, fix function name fallback to Other - Remove unused imports and dead code
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
CodeTokenizerwith 8 language tokenizers (Kotlin, Java, JS/TS, Python, Swift, Go, Rust, JSON)MarkdownRenderer.FencedCodeBlockusing Material 3 semantic colorsWhy
Syntax highlighting for code blocks is a core UX feature (issue #439) that improves readability of code snippets in chat responses.
How to test
CodeTokenizerTestunit testsScreenshots
Compose previews included for Kotlin, Python, JavaScript, Rust, Go, Swift, TypeScript, and Java code blocks.
Related issues
Closes #439