1
0
mirror of https://github.com/squidfunk/mkdocs-material.git synced 2024-11-12 01:50:52 +01:00

Fixed case where table of contents icon is missing on mobile navigation

This commit is contained in:
squidfunk 2017-03-16 15:57:46 +01:00 committed by Martin Donath
parent 3c1cfa86e0
commit c4c7beaefa
2 changed files with 2 additions and 2 deletions

View File

@ -30,7 +30,7 @@
<li class="{{ class }}">
{% set toc_ = page.toc %}
<input class="md-toggle md-nav__toggle" data-md-toggle="toc" type="checkbox" id="toc">
{% if toc_ | first is defined %}
{% if toc_ | first is defined and "\x3ch1 id=" in page.content %}
{% set toc_ = (toc_ | first).children %}
{% endif %}
{% if toc_ | first is defined %}

View File

@ -71,7 +71,7 @@
type="checkbox" id="toc" />
<!-- Hack: see partials/toc.html for more information -->
{% if toc_ | first is defined %}
{% if toc_ | first is defined and "\x3ch1 id=" in page.content %}
{% set toc_ = (toc_ | first).children %}
{% endif %}