Repository navigation
docs: render code blocks and multi-paragraph content inside notes (#312) - #313
Merged
Merged
Conversation
The Note component only kept plain-string children, so anything after the first blank line inside a <note> (code blocks, extra paragraphs) was dropped. On query-methods the blank line sat inside a code fence, which ended the raw HTML block mid-fence: the rest of the example leaked out as a heading and the stray fence swallowed the following section. - Note renders already-parsed element children alongside its markdown strings, with note-sized paragraph styles. - query-methods: blank line before the fence so it parses as markdown. - semantic-table: blank line before </note> so a trailing paragraph doesn't absorb the closing tag. 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.
Fixes #312.
Problem
On querying/methods#aggregate, the CRITICAL note showed only the first two lines of its code example as inline text, followed by a large empty box. The same bug cut off three other notes, without the empty box:
aggregate()Cause
Note.tsxkept only plain-string children. Markdown ends a raw<note>HTML block at the first blank line, so everything after it arrives as already-rendered elements, which were dropped.query-methods.md, that blank line sat inside the code fence. The raw HTML block ended mid-fence,# ❌ WRONG …became a heading, and the closing ``` opened a new fence that swallowed</note>and the following section.Fix
Note.tsx: strings still go through the note's own markdown; element children are now rendered as they are. Paragraphs inside a note get note-sized text.query-methods.md: blank line before the fence.semantic-table.md: blank line before</note>, so a trailing paragraph doesn't absorb the closing tag. Fixing the component exposed this: the note grew to 2878px and wrapped the rest of the page.bsl-data/*.json: only themarkdownline is updated. Running the full docs build also changes query outputs (row order, SQL aliases), so I left those out.Verification
eslintpasses onNote.tsx, andtscreports no errors in it.🤖 Generated with Claude Code