Skip to content

Conversation

@whscullin
Copy link
Contributor

Makes sure that the fragment part of a link is preserved when in a notebooks. There is existing special handing for links starting with #, but not with both a path and a fragment part.

Fixes #193742

To test this, create a link in a notebook markdown cell in the form of

[Link](file.html#anchor)

When clicking on this link currently, you'll get a dialog. "Unable to open 'file.html#anchor' Cancel/Create File"
With this fix, you will either open file.html if it exists, or get a "Unable to open 'file.html' Cancel/Create File" dialog.

@whscullin
Copy link
Contributor Author

@microsoft-github-policy-service agree [company="Google"]

@whscullin
Copy link
Contributor Author

@microsoft-github-policy-service agree company="Google"

@vscodenpa vscodenpa added this to the October 2023 milestone Oct 5, 2023
@rebornix rebornix merged commit 413e8cb into microsoft:main Oct 5, 2023
Alex0007 pushed a commit to Alex0007/vscode that referenced this pull request Oct 26, 2023
Co-authored-by: Peng Lyu <penn.lv@gmail.com>
@github-actions github-actions bot locked and limited conversation to collaborators Nov 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Notebooks: Links with both a path and fragment in markdown attempt to open incorrect file.

4 participants