-
Notifications
You must be signed in to change notification settings - Fork 0
Navigation
GuideNH builds its navigation tree from page frontmatter.
The navigation map controls whether a page appears in the guide tree.
navigation:
title: Structure Preview
parent: index.md
position: 20
icon: minecraft:diamond_block| Field | Description |
|---|---|
title |
Required display title |
parent |
Optional parent page id |
position |
Optional sibling ordering hint |
icon |
Optional item icon |
icon_texture |
Optional texture icon resolved from guide assets |
icon_components |
Parsed but not currently used by built-in rendering |
GuideNH chooses navigation/search icons in this order:
-
icon_textureif the texture file loads successfully -
iconif the item exists - no icon if neither is usable
Texture icons are read from runtime assets, so relative page-local files such as test1.png work.
- Omit
parentto create a root node. - Set
parent: index.mdor any other page id to create a child node. - The parent page must exist in the same guide navigation tree.
Pages can join one or more named categories using frontmatter:
categories:
- basics
- machinesThose categories become queryable through the built-in <CategoryIndex> tag.
Pages can register item-to-page mappings using item_ids:
item_ids:
- minecraft:compass
- minecraft:wool:*These mappings are used by <ItemLink>.
Lookup behavior:
- exact item + exact meta
- wildcard-meta fallback if present
<SubPages> renders links to navigation children.
| Attribute | Type | Default | Meaning |
|---|---|---|---|
id |
page id or empty string | current page | Page whose children should be listed |
alphabetical |
boolean expression | false |
Sort children by title instead of navigation order |
<SubPages />
<SubPages id="index.md" />
<SubPages id="" alphabetical={true} />Special case: id="" lists root navigation nodes.
<CategoryIndex> renders links to every page in a named category.
<CategoryIndex category="machines" />If the category is missing, GuideNH renders an inline error.
Search titles are derived in this order:
navigation.title- first level-1 heading (
# Heading) - raw page id