Skip to content

book-theme: appendices TOC section renders no sidebar-nav header, so appendix pages nest under the preceding Part #67

Description

@mmcky

Symptom

In a book-mode project whose TOC mixes section: parts and section: appendices groups, the left sidebar nav renders each parts group with its own "Part N — …" header, but the appendices group's children are rendered flat, with no group header — so the appendix pages (A, B) appear nested under the last Part instead of as their own group.

Evidence that this is a nav-rendering bug (not a config issue)

The same TOC data renders correctly on the contents/landing page: there, "Appendices" appears as its own group containing "Mathematical Background" and "Solutions". Only the sidebar nav drops the group header and lets the appendix entries fall under the preceding Part. So the project config is correct; the inconsistency is in how the sidebar nav renders appendices vs parts.

Reproduce

QuantEcon/book-dp2 (mystmd-conversion branch), built with the qe-v8 fork. The relevant myst.yml TOC shape:

toc:
  - title: General Theory
    section: parts
    children: [ ... ]
  - title: Models and Applications
    section: parts
    children: [ ... ]          # "Part II"
  - title: Appendices
    section: appendices
    children:
      - file: ch_math_foundations.md   # Appendix A
      - file: ch_solutions.md          # Appendix B

In the deployed sidebar, "A Mathematical Background" and "B Solutions" render indented under "Part II — Models and Applications" rather than under an "Appendices" header.

Expected

The appendices group should render its own sidebar-nav header (parallel to the "Part N —" header used for parts), or otherwise visually separate appendix pages from the preceding part — matching how the contents page already groups them.

Notes

The only book-side workaround is to drop section: appendices, but that sacrifices the A/B (Alph) appendix numbering, so this needs to be addressed in the theme.

Reported downstream in QuantEcon/book-dp-public#29 and tracked in QuantEcon/book-dp2#162.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions