From cf8e992c24e43857eaa44fe66e8b6b1cdc55ea5f Mon Sep 17 00:00:00 2001 From: squidfunk Date: Sat, 12 Mar 2016 13:20:19 +0100 Subject: [PATCH] Fixed empty list in table of contents when no headline is defined --- CHANGELOG | 1 + material/nav.html | 2 +- src/nav.html | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG b/CHANGELOG index 487edfaf3..95881f06a 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -2,6 +2,7 @@ mkdocs-material-0.2.1 (2016-03-12) * Fixed #10: Invisible header after closing search bar with ESC key * Fixed #13: Table cells don't wrap + * Fixed empty list in table of contents when no headline is defined * Corrected wrong path for static asset monitoring in Gulpfile.js * Set up tracking of site search for Google Analytics diff --git a/material/nav.html b/material/nav.html index d4641b8be..c926c085b 100644 --- a/material/nav.html +++ b/material/nav.html @@ -16,7 +16,7 @@ {% if h1 %} {% set toc = (toc | first).children %} {% endif %} - {% if toc %} + {% if toc and (toc | first) %}