diff --git a/demo_docs/source/index.rst b/demo_docs/source/index.rst index 4436c48f..47e7c5f4 100644 --- a/demo_docs/source/index.rst +++ b/demo_docs/source/index.rst @@ -19,6 +19,11 @@ Contents: demo list +.. toctree:: + :titlesonly: + + toc + .. toctree:: :maxdepth: 2 :caption: This is an incredibly long caption for a long menu diff --git a/demo_docs/source/toc.rst b/demo_docs/source/toc.rst new file mode 100644 index 00000000..286b50c9 --- /dev/null +++ b/demo_docs/source/toc.rst @@ -0,0 +1,12 @@ +========= +TOC Tests +========= + +One +=== + +Two +--- + +Three +````` diff --git a/sphinx_rtd_theme/static/js/theme.js b/sphinx_rtd_theme/static/js/theme.js index 749e58f4..d7e59d26 100644 --- a/sphinx_rtd_theme/static/js/theme.js +++ b/sphinx_rtd_theme/static/js/theme.js @@ -31,7 +31,7 @@ $(document).ready(function() { $("table.docutils:not(.field-list)").wrap("
"); // Add expand links to all parents of nested ul - $('.wy-menu-vertical ul').siblings('a').each(function () { + $('.wy-menu-vertical ul').not('.simple').siblings('a').each(function () { var link = $(this); expand = $(''); expand.on('click', function (ev) {