Skip to content

docs: clarify directory navigation metadata nesting#3768

Open
Mat4m0 wants to merge 1 commit intonuxt:mainfrom
Mat4m0:codex/docs-navigation-metadata
Open

docs: clarify directory navigation metadata nesting#3768
Mat4m0 wants to merge 1 commit intonuxt:mainfrom
Mat4m0:codex/docs-navigation-metadata

Conversation

@Mat4m0
Copy link
Copy Markdown

@Mat4m0 Mat4m0 commented Apr 13, 2026

Summary

  • document that directory-level navigation metadata in .navigation.yml should live under navigation:
  • show that custom flags like section, group, and badge are exposed on ContentNavigationItem
  • add the same clarification to the page type docs for the navigation field

Validation

  • not run in the fork because dependencies are not installed locally (node_modules missing)
  • behavior was verified against the Nuxt Content source implementation in src/runtime/internal/navigation.ts

@vercel
Copy link
Copy Markdown

vercel bot commented Apr 13, 2026

@Mat4m0 is attempting to deploy a commit to the Nuxt Team on Vercel.

A member of the Team first needs to authorize it.

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 13, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 8139764f-3abe-4171-b497-909e5dceec24

📥 Commits

Reviewing files that changed from the base of the PR and between 22e4085 and cf40482.

📒 Files selected for processing (2)
  • docs/content/docs/2.collections/2.types.md
  • docs/content/docs/4.utils/2.query-collection-navigation.md

📝 Walkthrough

Walkthrough

Two documentation files were updated to clarify metadata field placement for the navigation object. The updates specify that custom metadata fields (such as section, group, badge, and icon) must be nested under a navigation: object in page frontmatter or .navigation.yml files to be surfaced on ContentNavigationItem objects returned by queryCollectionNavigation(). Examples in the documentation were updated to reflect this structure, and the behavior of directory-level field merging was explicitly documented.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title 'docs: clarify directory navigation metadata nesting' directly and specifically describes the main change—clarifying how metadata should be nested in navigation configuration.
Description check ✅ Passed The description is directly related to the changeset, explaining the documentation updates about navigation metadata nesting and how custom fields are exposed on ContentNavigationItem.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new bot commented Apr 13, 2026

npm i https://pkg.pr.new/@nuxt/content@3768

commit: cf40482

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