From 69f92a320f15effe29e11237fcf2cad6674f55c3 Mon Sep 17 00:00:00 2001 From: Peter Chang Date: Thu, 2 May 2024 17:06:03 +0100 Subject: [PATCH] Add CSS tweak to hide summary when a details section is opened --- manual/source/_static/details_summary_hide.css | 5 +++++ manual/source/conf.py | 3 +++ 2 files changed, 8 insertions(+) create mode 100644 manual/source/_static/details_summary_hide.css diff --git a/manual/source/_static/details_summary_hide.css b/manual/source/_static/details_summary_hide.css new file mode 100644 index 000000000..7b608238c --- /dev/null +++ b/manual/source/_static/details_summary_hide.css @@ -0,0 +1,5 @@ +details[open] > summary { + width: 0.5em; + height: 2.2ex; + overflow: hidden; +} diff --git a/manual/source/conf.py b/manual/source/conf.py index 390432833..9b90263f1 100644 --- a/manual/source/conf.py +++ b/manual/source/conf.py @@ -89,6 +89,9 @@ ], } +def setup(app): + app.add_css_file('details_summary_hide.css') + # The name of an image file (within the static path) to use as favicon of the # docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 # pixels large.