Repository navigation
feat: expose original-source attribute ranges for editors - #508
Closed
tubarao312 wants to merge 2 commits into
Closed
tubarao312 wants to merge 2 commits into
tubarao312 wants to merge 2 commits into
Conversation
|
@tubarao312 is attempting to deploy a commit to the NuxtLabs Team on Vercel. A member of the Team first needs to authorize it. |
Contributor
Documentation previewsPreviews are disabled for pull requests from forks. |
Contributor
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: true
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
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.
Add an opt-in comark/source entry point that locates original Markdown link destinations and component attribute values as half-open UTF-16 ranges. Keep offsets separate from the renderable AST and ordinary parsing; disable streaming repair for source analysis. Preserve duplicate/bound attributes and source order so editors can respect effective values.
Reuse the canonical component/attribute grammar and Markdown destination helper. Map LF/CRLF/frontmatter offsets back to original input. Omit references, images, YAML props, raw HTML attributes, malformed values, and transformed source. Escaped-pipe table rows deliberately have no ranges; unmapped groups cannot search backward into literal code.
Independent thermo-nuclear review found and verified fixes for transformed-table false ranges, tab-separated fence offsets, malformed-value endpoints, and quadratic owner lookup. A 16,000-component probe improved from approximately 1,289 ms to 63 ms. No remaining actionable finding was reported.
Validation: 12 source tests and package build/changed-source lint pass. Combined preview with independent heading-generator PR #509 passes 1,054 core tests with 4 skips; two existing Windows-incompatible suites were excluded (CRLF spec fixtures and absolute-path handling). Full verification is also blocked by baseline checkout formatting. External Vercel checks require repository-owner authorization.
Downstream integration: https://github.com/tooling-test/docs/pull/619. Review artifact and provenance: https://github.com/tubarao312/comark/releases/tag/brief-reviewed-87bc46e1d9e6. Draft API proposal; an official registry release is required before downstream publication.