From 5bb9bdaf2cba52820b342179a545f7831103ed1d Mon Sep 17 00:00:00 2001 From: Antonin Godard Date: Tue, 4 Aug 2026 17:59:35 +0200 Subject: [PATCH] Documentation: html: adjust sidebar section titles styling Now that section titles are displayed in the sidebar, make them bold to have them stand out compared to the subsection titles, and decrease their bottom margin to group them with their subsections. Signed-off-by: Antonin Godard Tested-by: Randy Dunlap [jc: tweaked the sidebar CSS slightly] Signed-off-by: Jonathan Corbet Message-ID: <20260804-show-sections-in-sidebar-v2-2-a68d23bbc79d@bootlin.com> --- Documentation/sphinx-static/custom.css | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Documentation/sphinx-static/custom.css b/Documentation/sphinx-static/custom.css index 9b08be290014..6c03dca44c82 100644 --- a/Documentation/sphinx-static/custom.css +++ b/Documentation/sphinx-static/custom.css @@ -83,6 +83,13 @@ div.kerneltoc li.current ul { background-color: white; } */ section#the-linux-kernel-documentation p.caption { display: none; } +/* + * Make section titles bold in the sidebar, and decrease their bottom margin to + * group them with their subsections. + */ +div.sphinxsidebar p.caption { font-weight: bold; margin-bottom: 0; } +div.sphinxsidebar p.caption + ul { margin-top: 0; } + /* * The CSS magic to toggle the contents on small screens. */