Unverified Commit 1700596a authored by Yuge Zhang's avatar Yuge Zhang Committed by GitHub
Browse files

Readme index update (#4722)

parent f9bbd8d0
This diff is collapsed.
......@@ -42,16 +42,6 @@ function hide_nav() {
}
}
function hide_toc_header() {
const d = $(".md-nav__title.md-nav__title--site");
// https://stackoverflow.com/questions/11362085/jquery-get-text-for-element-without-children-text
const pageTitle = $("#index--page-root").clone().children().remove().end().text();
if (d.text().trim() == pageTitle) {
d.hide();
}
}
$(document).ready(function() {
hide_nav();
hide_toc_header();
});
......@@ -2,6 +2,9 @@
{% if toctree and sidebars and 'globaltoc.html' in sidebars %}
{% set toctree_nodes = derender_toc(toctree, False) %}
<ul class="md-nav__list">
<li class="md-nav__item md-nav__overview">
<a href="{{ pathto('index')|e }}" class="md-nav__link{% if pagename == 'index' %} md-nav__link--active{% endif %}">{{ _('Overview') }}</a>
</li>
{%- for item in toctree_nodes recursive %}
<li class="md-nav__item">
{% if "caption" in item %}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment