2017-10-19 21:09:59 +03:00
|
|
|
{% import "partials/language.html" as lang with context %}
|
2016-09-23 12:56:25 +03:00
|
|
|
<nav class="md-nav md-nav--secondary">
|
2017-01-02 10:57:19 +03:00
|
|
|
{% set toc_ = page.toc %}
|
2017-02-09 01:13:13 +03:00
|
|
|
{% if toc_ | first is defined and "\x3ch1 id=" in page.content %}
|
2017-01-02 10:57:19 +03:00
|
|
|
{% set toc_ = (toc_ | first).children %}
|
2016-09-23 12:56:25 +03:00
|
|
|
{% endif %}
|
2017-02-09 01:13:13 +03:00
|
|
|
{% if toc_ | first is defined %}
|
2018-06-10 15:45:16 +03:00
|
|
|
<label class="md-nav__title" for="__toc">{{ lang.t("toc.title") }}</label>
|
2016-12-29 16:19:26 +03:00
|
|
|
<ul class="md-nav__list" data-md-scrollfix>
|
2017-01-02 10:57:19 +03:00
|
|
|
{% for toc_item in toc_ %}
|
2016-09-23 12:56:25 +03:00
|
|
|
{% include "partials/toc-item.html" %}
|
|
|
|
{% endfor %}
|
2017-03-11 16:07:07 +03:00
|
|
|
{% if page.meta.source and page.meta.source | length > 0 %}
|
|
|
|
<li class="md-nav__item">
|
2017-10-18 22:38:33 +03:00
|
|
|
<a href="#__source" title="{{ lang.t('meta.source') }}" class="md-nav__link md-nav__link--active">
|
|
|
|
{{ lang.t("meta.source") }}
|
2017-03-11 16:07:07 +03:00
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
{% endif %}
|
2018-02-11 21:04:29 +03:00
|
|
|
{% set disqus = config.extra.disqus %}
|
|
|
|
{% if page and page.meta and page.meta.disqus is string %}
|
|
|
|
{% set disqus = page.meta.disqus %}
|
|
|
|
{% endif %}
|
2018-03-21 22:05:27 +03:00
|
|
|
{% if not page.is_homepage and disqus %}
|
2017-03-11 16:07:07 +03:00
|
|
|
<li class="md-nav__item">
|
2017-10-18 22:38:33 +03:00
|
|
|
<a href="#__comments" title="{{ lang.t('meta.comments') }}" class="md-nav__link md-nav__link--active">
|
|
|
|
{{ lang.t("meta.comments") }}
|
2017-03-11 16:07:07 +03:00
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
{% endif %}
|
2016-09-23 12:56:25 +03:00
|
|
|
</ul>
|
|
|
|
{% endif %}
|
2016-09-30 14:29:45 +03:00
|
|
|
</nav>
|