Skip to content

Conversation

@benji-glitsos-ga
Copy link
Collaborator

@benji-glitsos-ga benji-glitsos-ga commented May 5, 2025

Fixed cross-reference links by reverting nbsphinx version from 0.9.3 to 0.9.1. I checked the DEA Notebooks to ensure that they are rendering properly.

Tests:

Tested in this PR: #458

@github-actions
Copy link

github-actions bot commented May 5, 2025

Preview is ready!

View the preview: 🌐 PR Preview 460

You can also view the deploy log or read the documentation.

@benji-glitsos-ga benji-glitsos-ga marked this pull request as draft May 5, 2025 07:03
@benji-glitsos-ga
Copy link
Collaborator Author

benji-glitsos-ga commented May 5, 2025

This change currently breaks the existing root-relative links due to myst_all_links_external = False unfortunately. The makeshift solution is to find-and-replace project: in front of all the links or define your own reference target like external: to get all these links to be resolved properly. https://myst-parser.readthedocs.io/en/latest/syntax/cross-referencing.html#examples

URL schemes: https://myst-parser.readthedocs.io/en/latest/syntax/cross-referencing.html#customising-external-url-resolution

If that doesn't work, the doc role can be used:

{doc}`/lorem/ipsum`

@benji-glitsos-ga benji-glitsos-ga changed the title Fix cross reference links Test cross reference links (2) May 6, 2025
@benji-glitsos-ga
Copy link
Collaborator Author

benji-glitsos-ga commented May 6, 2025

I've found a solution.

In Markdown content, these can be used:

[DEA Maps](#dea-maps)

[DEA Maps](root:guides/setup/dea_maps/)

In Restructured Text content (including templates), these can be used:

:any:`DEA Maps <dea-maps>`

:any:`DEA Maps </guides/setup/dea_maps/>`         <== But this doesn't work with ?tab=specifications#product-information at the end of the URL

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.

1 participant