docs(config): add documentation for navbar dropdown menu

This commit is contained in:
Xin
2025-08-13 15:41:37 +08:00
committed by GitHub
parent 9a20f07d4e
commit b4d7d982f9

View File

@@ -67,6 +67,27 @@ There are different types of menu items:
These menu items can be sorted by setting the `weight` parameter.
### Nested Menus
You can create dropdown menus by defining child menu items. Child menus appear when clicking on the parent menu item.
```yaml {filename="hugo.yaml"}
menu:
main:
- identifier: sdk
name: SDK
- identifier: python
name: Python ↗
url: https://python.org
parent: sdk
- identifier: go
name: Go
url: https://go.dev
parent: sdk
```
Child menu items need to specify the `parent` parameter with the parent's `identifier` value.
### Logo and Title
To modify the default logo, edit `hugo.yaml` and add the path to your logo file under `static` directory.
@@ -302,6 +323,7 @@ To customize the search tokenize, set the `params.search.flexsearch.tokenize` pa
```yaml {filename="hugo.yaml"}
params:
search:
# ...
flexsearch:
# full | forward | reverse | strict
@@ -363,6 +385,7 @@ outputs:
```
This will generate an `llms.txt` file at your site's root containing:
- Site title and description
- Hierarchical listing of all sections and pages
- Page summaries and publication dates