docs(site): rename Overview sidebar labels to fix pagination
Generate documentation / build-docs (push) Has been cancelled

Renamed the root 'Overview' entry under 'Functions Reference' to 'Categories'. Also renamed the inner category 'Overview' entries to '{Category} Overview'. Because Starlight uses the sidebar label for the 'Next/Previous' pagination buttons at the bottom of pages, having multiple pages labeled just 'Overview' caused the button text to ambiguously say 'Next: Overview' even when linking to a new category.
This commit is contained in:
2026-07-27 01:08:24 -04:00
parent 3e00f4e321
commit ea66507c76
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -698,7 +698,7 @@ def build_site(root: Path, out: Path) -> list[dict]:
functions_group = { functions_group = {
"label": fm["title"], "label": fm["title"],
"collapsed": True, "collapsed": True,
"items": [{"label": "Overview", "link": f"/{slug_dir}/"}], "items": [{"label": "Categories", "link": f"/{slug_dir}/"}],
} }
sidebar.append(functions_group) sidebar.append(functions_group)
continue continue
@@ -756,7 +756,7 @@ def build_site(root: Path, out: Path) -> list[dict]:
"label": fm["title"], "label": fm["title"],
"collapsed": True, "collapsed": True,
"items": [ "items": [
{"label": "Overview", "link": f"/{slug_dir}/{category}/"}, {"label": f"{fm['title']} Overview", "link": f"/{slug_dir}/{category}/"},
*links, *links,
], ],
} }
+1 -1
View File
@@ -760,7 +760,7 @@ def test_sidebar_has_no_duplicate_functions_entry():
assert group["label"] not in labels[1:], ( assert group["label"] not in labels[1:], (
f"'{group['label']}' is repeated inside its own group: {labels}" f"'{group['label']}' is repeated inside its own group: {labels}"
) )
assert labels[0] == "Overview", f"group should lead with Overview, got {labels[0]}" assert labels[0] == "Categories", f"group should lead with Categories, got {labels[0]}"
assert not any( assert not any(
"autogenerate" in item for item in group["items"] "autogenerate" in item for item in group["items"]
), "categories should be listed explicitly, not autogenerated from slugs" ), "categories should be listed explicitly, not autogenerated from slugs"