Skip to content

Add support for hidden files in documentation TOC #381

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

Merged
merged 1 commit into from
Jan 30, 2025

Conversation

Mpdreamz
Copy link
Member

@Mpdreamz Mpdreamz commented Jan 30, 2025

Hidden files can now be excluded from navigation and indexing but still linked directly if needed. Adjustments include handling hidden attributes in TOC parsing and ensuring related navigation logic respects these exclusions.

Hidden pages can be included just as you would any file in the TOC.

   hidden: my-page.md
  • Still only one place to configure files.
  • Participates in dangling documentation detection
  • Is picked up as a MarkdownFile in our codebase like any other.
  • Includes a hidden flag so that we:
    • Never render it in any navigation item.
    • Always include a noindex header.
    • Advertise it as hidden in links.json artifact.
hiddenpages.mp4

Hidden files can now be excluded from navigation and indexing but still linked directly if needed. Adjustments include handling hidden attributes in TOC parsing and ensuring related navigation logic respects these exclusions.
@Mpdreamz Mpdreamz linked an issue Jan 30, 2025 that may be closed by this pull request
2 tasks
Copy link
Contributor

@shainaraskas shainaraskas left a comment

Choose a reason for hiding this comment

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

!! NICE!

if I want to hide multiple files in the same TOC, do I need individual hidden entries, or does it accept an array? either works just interested for clarity

@Mpdreamz
Copy link
Member Author

You can place multiple hidden entries just like you would multiple file entries.

Youm ay have hidden pages anywhere in the TOC they themselves however may not have any children.

@Mpdreamz Mpdreamz merged commit 12f9ed1 into main Jan 30, 2025
6 checks passed
@Mpdreamz Mpdreamz deleted the feature/hidden-pages branch January 30, 2025 15:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature Request]: Allow for hidden pages
3 participants