mirror of https://github.com/docker/docs.git
Pre-render nav
This commit is contained in:
parent
69b3a3d434
commit
4b05d07fb7
|
@ -1,4 +1,4 @@
|
|||
{% for item in tree %}{% if item.heading %}{% else %}{% if item.sectiontitle %}<li class="leaf menu-closed"><a href="/" class="expand-menu "><span class="menu-icon" aria-hidden="true"></span>{{ item.sectiontitle }}</a>
|
||||
{% for item in tree %}{% if item.heading %}{% else %}{% if item.sectiontitle %}<li class="leaf menu-closed"><a href="#" class="expand-menu "><span class="menu-icon" aria-hidden="true"></span>{{ item.sectiontitle }}</a>
|
||||
<ul class="nav-sub">
|
||||
{% assign tree = item.section %}{% include tree.html %}
|
||||
</ul>
|
||||
|
|
|
@ -187,7 +187,8 @@ ng\:form {
|
|||
<div class="row">
|
||||
<div class="col-xs-12 col-sm-3 col-md-2 col-xl-2 docsidebarnav_section">
|
||||
<div class="region region-hero-sub"><ul class="nav-sub">
|
||||
|
||||
{% assign tree = site.data.toc.toc %}
|
||||
{% include tree.html %}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -41,12 +41,15 @@ function hookupTOCEvents()
|
|||
});
|
||||
}
|
||||
jQuery(document).ready(function(){
|
||||
/*
|
||||
$.getJSON( "/toc.txt", function( data ) {
|
||||
tocData = data;
|
||||
renderTree(data.toc);
|
||||
$(".nav-sub").html(treeOutput.join(''));
|
||||
hookupTOCEvents();
|
||||
});
|
||||
*/
|
||||
hookupTOCEvents();
|
||||
$("#TableOfContents ul").empty();
|
||||
|
||||
var prevH2Item = null;
|
||||
|
|
Loading…
Reference in New Issue