summary refs log tree commit diff stats
path: root/config/nimdoc.cfg
diff options
context:
space:
mode:
authorJake Leahy <jake@leahy.dev>2022-07-17 07:41:18 +1000
committerGitHub <noreply@github.com>2022-07-16 17:41:18 -0400
commitc43a377057c56d5213eb298feba883363f2b2a26 (patch)
tree54db4270070a74f4438f9d6c3fa2d15bee51224e /config/nimdoc.cfg
parent094d86f99783f1366394fa444277c417dcbd1af3 (diff)
downloadNim-c43a377057c56d5213eb298feba883363f2b2a26.tar.gz
Make imports/exports not be a dropdown in sidebar (#19907)
* Don't make a section be a dropdown if it has no child links

* - Cleaned up code

- Updated tests

* Document what the 'if' is checking
Diffstat (limited to 'config/nimdoc.cfg')
-rw-r--r--config/nimdoc.cfg8
1 files changed, 8 insertions, 0 deletions
diff --git a/config/nimdoc.cfg b/config/nimdoc.cfg
index 3b0afe8d6..7aee50d8c 100644
--- a/config/nimdoc.cfg
+++ b/config/nimdoc.cfg
@@ -16,6 +16,14 @@ doc.section = """
 </div>
 """
 
+# Just a single item in the TOC (e.g. imports, exports)
+doc.section.toc_item = """
+<li>
+  <a class="reference reference-toplevel" href="#$sectionID" id="$sectionTitleID">$sectionTitle</a>
+</li>
+"""
+
+# This is a section (e.g. procs, types) in the TOC which gets turned into a drop down
 doc.section.toc = """
 <li>
   <details open>