summaryrefslogtreecommitdiffstats
path: root/docs/_layouts
diff options
context:
space:
mode:
authorYong He <yonghe@outlook.com>2021-04-24 00:31:38 -0700
committerGitHub <noreply@github.com>2021-04-24 00:31:38 -0700
commitd8c50271fd73cf5def8e6a90c383eb19fe795c86 (patch)
tree8fe3b61450d99a108f2aad09d471ed7e7ad0b41c /docs/_layouts
parent4f83d48b28b417a16d7caa834a9248b1bd50cdb8 (diff)
Always expand root level of table of contents (#1819)
Diffstat (limited to 'docs/_layouts')
-rw-r--r--docs/_layouts/user-guide.html3
1 files changed, 2 insertions, 1 deletions
diff --git a/docs/_layouts/user-guide.html b/docs/_layouts/user-guide.html
index ad4ad2cd9..b3eba9404 100644
--- a/docs/_layouts/user-guide.html
+++ b/docs/_layouts/user-guide.html
@@ -160,7 +160,8 @@
var path = window.location.pathname;
var pageName = path.split("/").pop();
var currentPageID = pageName.substr(0, pageName.lastIndexOf("."));
-
+ if (currentPageID.length == 0)
+ currentPageID = "index";
var tocLists = document.getElementsByClassName("toc_root_list");
for (var i = 0; i < tocLists.length; i++) {
var tocList = tocLists[i];