Repository navigation
Workspace: Markdown files as a page; the visualizer shows the file that ran - #55
Merged
Merged
Conversation
… / Text» With the new prop renderMarkdown (the host's renderer, returning sanitized HTML), a .md tab has a switch at the end of the tabs: a read-only file opens as the page, an editable one as its text. The page lies over the editor, which stays mounted (inert meanwhile). Styles in the tokens: headings, lists, code in the code font, tables, quotes. Without the prop, nothing changes (the embed doesn't pass it). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The module frame was drawn for the open tab (activeFile), while the trace is of the main file: with another tab open (a helper, a library, a Markdown file), «Visualisieren» showed an empty view. Now it shows the main file (or a visualized REPL input), as the → chain already did. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
For P45 (instructions as a tab in an IDE project): the editor part. The IDE part is glpython-edu.github.io#39 (it installs this branch until a tag exists).
1. Markdown as a page (
renderMarkdown)A new optional workspace prop,
renderMarkdown?: (source: string) => string. It is the host's renderer, and it must return sanitized HTML. The IDE passes marked + DOMPurify; the embed passes nothing and is unchanged.With the prop, a
.mdtab gets a switch at the end of the tabs: Ansicht / Text (en: View / Text).inertmeanwhile, so Tab doesn't reach it. The page itself takes the focus and scrolls.--glp-*tokens: headings, lists, links in the info colour, inline code and code blocks in the code font on the surface colour, tables that scroll sideways, quotes, images capped at the width, and narrower padding below 700 px.markdownViewLabel,markdownPageandmarkdownText, optional and in both languages.2. Fix: «Visualisieren» with another tab open
The visualizer drew its root frame for the open tab (
activeFile), while the trace is ofmainFile. With a helper, a library or a Markdown file open, the view was empty. Now it draws the main file (or a visualized REPL input), as the → chain already did. The IDE's new browser check found this: «Visualisieren» withaufgabe.mdopen.Checks
Lint (the known warning only), build and
test:protocolpass locally. The behaviour is checked in the IDE'stest:browser(the PR there), since only the IDE passesrenderMarkdown.Going live
The embed doesn't pass
renderMarkdown, so for it only the visualizer fix applies (the embed has one file open anyway). The IDE needs this tag and its own PR.🤖 Generated with Claude Code