mirror of
https://github.com/GitbookIO/gitbook.git
synced 2026-09-22 02:23:30 +00:00
99d9d49610
Use i18n for introduction title
39 lines
1.2 KiB
HTML
39 lines
1.2 KiB
HTML
{% extends "./page.html" %}
|
|
|
|
{% block title %}{% i18n "SUMMARY" %}Table of Contents{% endi18n %} | {{ title }}{% endblock %}
|
|
|
|
{% macro articles(_articles) %}
|
|
{% for item in _articles %}
|
|
<li>
|
|
{% if item.path and item.exists %}
|
|
{% if not item.external %}
|
|
<a href="{{ basePath }}/{{ item.path|contentLink }}">{% if item.introduction %}{% i18n "SUMMARY_INTRODUCTION" %}Introduction{% endi18n %}{% else %}{{ item.title }}{% endif %}</a>
|
|
{% else %}
|
|
<a target="_blank" href="{{ item.path }}">{{ item.title }}</a>
|
|
{% endif %}
|
|
{% else %}
|
|
{{ item.title }}
|
|
{% endif %}
|
|
{% if item.articles.length > 0 %}
|
|
<ol>
|
|
{{ articles(item.articles) }}
|
|
</ol>
|
|
{% endif %}
|
|
</li>
|
|
{% endfor %}
|
|
{% endmacro %}
|
|
|
|
{% block content %}
|
|
<div class="page page-toc">
|
|
<h1>{% i18n "SUMMARY" %}Table of Contents{% endi18n %}</h1>
|
|
<ol>
|
|
{{ articles(summary.chapters) }}
|
|
|
|
{% if glossary.length > 0 %}
|
|
<li><a href="{{ basePath }}/GLOSSARY.html">{% i18n "GLOSSARY" %}Glossary{% endi18n %}</a></li>
|
|
{% endif %}
|
|
</ol>
|
|
</div>
|
|
{% endblock %}
|
|
|