Read a .wimport path that contains spaces, and cut 1.5.2 - #128
Merged
Merged
Conversation
A destination stopped at the first whitespace, so an image or link naming a file with a space in it never matched and the section fell through to a plain text container showing the raw Markdown. The path now runs to the closing parenthesis, with an optional link title recognized so it cannot be swallowed into the path, and newlines excluded so an unclosed parenthesis cannot match across lines. Bumps the version to 1.5.2, whose notes also cover the Prompt text type that merged in #127 without a version bump of its own. Co-Authored-By: Claude Opus 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.
Why
A
.wimportthat names a file with a space in it —— did not import the picture. Both the image and the link pattern ended a destination at the first whitespace, so the section matched neither and fell through to the last resort inRecognize: a plain text container showing the raw Markdown. The file was never opened, so it did not even appear in the missing-files dialog.Strict CommonMark does require
<...>around a destination with spaces, and that form already worked. But a recipe names files on a Windows disk, where a space in a name is ordinary, so the parser should accept what the author typed.What changed
Both patterns now share one
Destinationfragment: the path runs to the closing parenthesis, an optional"title"is recognized so it cannot be swallowed into the path, and newlines are excluded so an unclosed parenthesis cannot match across lines. A name containing)still needs angle brackets, anddocs/wimport.mdnow says so.works as a side effect; it previously fell through to plain text as well.This also bumps the version to 1.5.2. Its notes carry two entries, because the Prompt text type merged in #127 without a version bump of its own.
Validation
dotnet build Whiteboard.sln -c Release— 0 warnings, 0 errorsTest with space.wimport, now resolvestest - Copy.svg(6126 bytes) as an image container, with no missing files🤖 Generated with Claude Code