Files
gitbook/theme/templates/includes/book/summary.html
T

66 lines
2.9 KiB
HTML

<div class="book-summary">
<div class="book-search">
<input type="text" placeholder="Search" class="form-control" />
</div>
<ul class="summary">
{% if options.links.about !== false && (options.links.about != null || githubId) %}
<li>
<a href="{{ options.links.about|default(githubHost+githubAuthor) }}" target="blank">About the author</a>
</li>
{% endif %}
{% if options.links.issues !== false && (options.links.issues != null || githubId) %}
<li>
<a href="{{ options.links.issues|default(githubHost+githubId+"/issues") }}" target="blank">Questions and Issues</a>
</li>
{% endif %}
{% if options.links.contribute !== false && (options.links.contribute != null || githubId) %}
<li>
<a href="{{ options.links.contribute|default(githubHost+githubId+"/edit/master/"+_input) }}" target="blank">Edit and Contribute</a>
</li>
{% endif %}
{% if options.links.contribute || options.links.issues || options.links.about || githubId %}
<li class="divider"></li>
{% endif %}
<li data-level="0" data-path="index.html">
<a href="{{ basePath }}/"><i class="fa fa-check"></i> Introduction</a>
</li>
{% for item in summary.chapters %}
<li {% if item._path == _input %}class="active"{% endif %} data-level="{{ item.level }}" {% if item.path %}data-path="{{ item.path|mdLink }}"{% endif %}>
{% if item.path %}
<a href="{{ basePath }}/{{ item.path|mdLink }}">
<i class="fa fa-check"></i> <b>{{ item.level }}.</b> {{ item.title }}
</a>
{% else %}
<span><b>{{ item.level }}.</b> {{ item.title }}</span>
{% endif %}
{% if item.articles.length > 0 %}
<ul class="articles">
{% for article in item.articles %}
<li {% if article._path == _input %}class="active"{% endif %} data-level="{{ article.level }}" {% if article.path %}data-path="{{ article.path|mdLink }}"{% endif %}>
{% if article.path %}
<a href="{{ basePath }}/{{ article.path|mdLink }}">
<i class="fa fa-check"></i> <b>{{ article.level }}.</b> {{ article.title }}
</a>
{% else %}
<span><b>{{ article.level }}.</b> {{ article.title }}</span>
{% endif %}
</li>
{% endfor %}
</ul>
{% endif %}
</li>
{% endfor %}
{% if options.links.gitbook !== false %}
<li class="divider"></li>
<li>
<a href="http://www.gitbook.io/" target="blank">Generated using GitBook</a>
</li>
{% endif %}
</ul>
</div>