From ed618caf707da8733066bbd8bb9e0628e876b9a5 Mon Sep 17 00:00:00 2001 From: Silvio Giebl <silvio.giebl@hivemq.com> Date: Mon, 15 Jun 2020 23:00:53 +0200 Subject: [PATCH] Fixed table of children --- _layouts/default.html | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/_layouts/default.html b/_layouts/default.html index 860efe6c..a40c0b79 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -100,13 +100,11 @@ layout: table_wrappers <hr> <h2 class="text-delta">Table of contents</h2> <ul> - {%- assign children_list = pages_list | where: "parent", node.title -%} + {%- assign children_list = pages_list | where: "parent", page.title | where: "grand_parent", page.parent -%} {% for child in children_list %} - {% if child.parent == page.title and child.title != page.title and child.grand_parent == page.parent %} - <li> - <a href="{{ child.url | absolute_url }}">{{ child.title }}</a>{% if child.summary %} - {{ child.summary }}{% endif %} - </li> - {% endif %} + <li> + <a href="{{ child.url | absolute_url }}">{{ child.title }}</a>{% if child.summary %} - {{ child.summary }}{% endif %} + </li> {% endfor %} </ul> {% endif %} -- GitLab