Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parse position or selection from link fragment #2049

Merged
merged 10 commits into from
Sep 12, 2022

Conversation

jwortmann
Copy link
Member

Should handle the following formats which are supported by VSCode:
https://github.com/microsoft/vscode/blob/835ace5796cec0ed19a7eec119b26b57220b0f1a/src/vs/platform/opener/common/opener.ts#L153-L160

It applies to Markdown links in the hover content and also to DocumentLink.target from the "Document Link" response.

Can be tested for example with LSP-html and the following file:

<!DOCTYPE html>
<html>
<body>
    <h1 id="anchor">Heading</h1>

    <a href="#anchor">link</a>
</body>
</html>

Closes #2009.

plugin/core/open.py Outdated Show resolved Hide resolved
plugin/core/open.py Outdated Show resolved Hide resolved
plugin/core/open.py Outdated Show resolved Hide resolved
plugin/core/open.py Outdated Show resolved Hide resolved
plugin/core/open.py Outdated Show resolved Hide resolved
plugin/core/open.py Outdated Show resolved Hide resolved
@rchl rchl merged commit 5926089 into sublimelsp:main Sep 12, 2022
@jwortmann jwortmann deleted the uri-fragment branch September 12, 2022 21:44
rchl added a commit that referenced this pull request Sep 27, 2022
* main:
  Parse position or selection from link fragment (#2049)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support URI navigation
3 participants