Repository navigation
site: accept indented and titled Pro source fences - #488
Merged
Merged
Conversation
The Echo Pro exporter now nests source includes under numbered list steps (1 to 3 spaces) and allows one literal title from a small alphabet. Mirror both rules in the publication checker; every other rejection stays.
Mirror the exporter's sourceFence rule: indent, language, an optional title as its own token, then the file. Removing the title before splitting could join tokens and check a different language or file than the site renders. The publication corpus is the exporter's copy.
Match the exporter's explicit [a-zA-Z0-9_./#-]+ path class so both sides accept the same lines; the corpus copy adds a Unicode-space case.
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.
Prepares for the next Echo Pro docs export (labstack/echo-pro#166 follow-ups): the install page nests its code blocks under numbered steps and titles the
.netrcblock.site/scripts/pro-publication.mjsnow mirrors the exporter's rules exactly: a source-include fence may be indented by 1 to 3 spaces with a matching empty closing fence, and may carry onetitle="..."limited to[a-zA-Z0-9_./~ -]. Fences indented 4 or more spaces, extra attributes and every other existing rejection still fail. Tests and the publication corpus cover both new forms.Checks:
npm test(495 passed);npm run buildwith the new export renders all three install code blocks inside their list items and the~/.netrctitle.