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

docs: Added material mkdocs tags plugin #5153

Merged
merged 11 commits into from
Feb 26, 2025

Conversation

cwhite911
Copy link
Contributor

@cwhite911 cwhite911 commented Feb 19, 2025

This uses existing keywords in Material MkDocs tags plugin to show tag. The tags mirror the keywords in terms of list and index, but are simpler, completely driven by mkdocs without any needed for custom code. The tool family and topic logic is obviously not include. More evaluation and de-duplication with keywords is needed (as a next step).

Adds tags to parser output which are just keywords but in full YAML syntax (mkdocs consumes tags by default, but can be configured).

Uses absolute URL instead of relative links in footer to make links from addons work.

Addresses Issue #5091

This pull request includes multiple changes to improve the documentation and tagging system in the project.

Modified md keyword generation in documentation:

Updates to build process and documentation files:

image

@cwhite911 cwhite911 self-assigned this Feb 19, 2025
@github-actions github-actions bot added C Related code is in C HTML Related code is in HTML libraries docs labels Feb 19, 2025
@wenzeslaus
Copy link
Member

While just using the tags instead of a currently working custom keywords system is not a priority, and some pieces will need to me preserved for keeping functioning URLs (if someone links https://grass.osgeo.org/grass-stable/manuals/keywords.html), this may help solving keywords for addons which currently work for HTML, but not for Markdown. However, given this needs the addon situation to be resolved, let's wait with this a bit to see how #5152 develops.

Example with a addon-only keyword is v.vect.stats.multi.md with keyword 'columns'.

@cwhite911
Copy link
Contributor Author

While just using the tags instead of a currently working custom keywords system is not a priority, and some pieces will need to me preserved for keeping functioning URLs (if someone links https://grass.osgeo.org/grass-stable/manuals/keywords.html), this may help solving keywords for addons which currently work for HTML, but not for Markdown.

This is an easy fix. We just need to leave the keyword tag in the header for now.

Example with a addon-only keyword is v.vect.stats.multi.md with keyword 'columns'.

I'll need to see this because I'm not following.

However, given this needs the addon situation to be resolved, let's wait with this a bit to see how #5152 develops.

I agree this can wait until we resolve the addons.

Copy link
Member

@wenzeslaus wenzeslaus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like it, but I meant to request changes for the footer.

@github-actions github-actions bot added the markdown Related to markdown, markdown files label Feb 25, 2025
@wenzeslaus
Copy link
Member

Please, update from main. #5152, #5177, and #5175 are now on main, so the custom keyword system including addons is in a good shape and running the the CI. Then, we can see the result in the artifact from the Documentation workflow.

@petrasovaa
Copy link
Contributor

petrasovaa commented Feb 25, 2025

The Tags index in the footer doesn't work, links to ./addons/tags.html, but that's the same for keywords.

@cwhite911
Copy link
Contributor Author

The Tags index in the footer doesn't work, links to ./addons/tags.html, but that's the same for keywords.

This is fixed now. They needed to be set not to use relative paths that why it was picking up the sub-directory.

@cwhite911 cwhite911 requested a review from wenzeslaus February 25, 2025 22:55
Copy link
Member

@wenzeslaus wenzeslaus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me as far as functionality. Next step is to decide on the details and interaction between custom keywords representation and the tags.

The TOC on tags page does not work, but it does not work on the keywords one either. The solution in the HTML doc was TOC by first letter, but I don't know if a TOC is even needed here.

I think the footer needs some other solution (some which will work for local files and multiple versions), but it is not directly related, so let's address that separately.

@wenzeslaus wenzeslaus merged commit 144279e into OSGeo:main Feb 26, 2025
28 checks passed
@github-actions github-actions bot added this to the 8.5.0 milestone Feb 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C Related code is in C docs HTML Related code is in HTML libraries markdown Related to markdown, markdown files
Projects
Development

Successfully merging this pull request may close these issues.

3 participants