-
Notifications
You must be signed in to change notification settings - Fork 7
Support anchors in .md links #12
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
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: George Melikov <[email protected]>
Signed-off-by: George Melikov <[email protected]>
Signed-off-by: George Melikov <[email protected]>
✅ Deploy Preview for ocispecs ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
Thanks @gmelikov! I'm testing and I don't visibly notice any behavior change. Can you walk me through your logic? |
|
@vsoch I've tested it locally via changed to (see last link with #compatibility-matrix anchor) Just tested that without my patches I'll have original 404 link http://127.0.0.1:4000/image-spec/manifest/media-types.md#compatibility-matrix instead of correct one http://127.0.0.1:4000/image-spec/media-types/?v=v1.0.1#compatibility-matrix . Maybe I've something wrong and there's different way to run it? |
|
How to reproduce scroll problems: open from scratch http://127.0.0.1:4000/image-spec/media-types/?v=v1.0.1#compatibility-matrix , check that you'll be at the top of page instead of compatibility-matrix section. It may have some races because of images load still, but it's better than nothing. Problem is that browsers scroll to anchor on page load, but we change the page after full load, and we have to scroll manually after that. |
|
Gotcha - thank you for that example. I'm looking at the preview:
And I'm starting at https://specs.opencontainers.org/image-spec/media-types/?v=v1.0.1. I'm using firefox and I don't notice any difference in behavior - when I click in either, it resolves to the same URL and jumps down the page. Is there a different browser I should be using? Maybe others can test and reproduce. |
|
Do you have correct links here https://specs.opencontainers.org/image-spec/manifest/?v=v1.0.1 ? I've tried to describe my problem here #11 , it's reproducible for me on Linux: firefox 128.14.0esr (64-bit) , chrome Version 140.0.7339.127 (Official Build) (64-bit), Just to be precise:
Link that you've gave me in #11 specs.opencontainers.org/_layouts/page.html Line 147 in b02f767
|
|
Preview here https://deploy-preview-12--ocispecs.netlify.app/image-spec/manifest/?v=v1.0.1 have code from this PR and works as I intended, JFYI. Major logic to fix #11 is in this commit 78cce33 |
|
@st3penta as the reporter of #10 - could you please check if your problems are fixed via this link https://deploy-preview-12--ocispecs.netlify.app/image-spec/manifest/?v=v1.0.1 ? |
@vsoch are you checking the link and not the destination? The link is on https://specs.opencontainers.org/image-spec/manifest/?v=v1.0.1 where the link for "matrix" points to https://specs.opencontainers.org/image-spec/manifest/media-types.md#compatibility-matrix |
This basic PR have several atomic commits:
Feel free to remove latest commit about spaces cleanup, it's totally optional.
Closes: #11 #10