aboutsummaryrefslogtreecommitdiffstats
path: root/gum/templates
diff options
context:
space:
mode:
authorPatrick <4002194+askpatrickw@users.noreply.github.com>2019-01-17 17:18:18 -0800
committerGitHub <noreply@github.com>2019-01-17 17:18:18 -0800
commit3fd6c5cd6bc414c54e1bce9ea214c6402e97b725 (patch)
tree7bfcede3fc8c12bfb1e0cea6d2347cdd6cb7f14a /gum/templates
parentb0d1a0b1facf05805e09c7e7994ca225cd55bcea (diff)
downloadpelican-themes-3fd6c5cd6bc414c54e1bce9ea214c6402e97b725.tar.gz
Conditional Categories and Pages not honored
There were category links inside pages. There was a Pages H4 outside the conditional check for if pages should be shown.
Diffstat (limited to 'gum/templates')
-rw-r--r--gum/templates/sidebar.html42
1 files changed, 20 insertions, 22 deletions
diff --git a/gum/templates/sidebar.html b/gum/templates/sidebar.html
index a65192a..3eccf79 100644
--- a/gum/templates/sidebar.html
+++ b/gum/templates/sidebar.html
@@ -1,32 +1,30 @@
<div class="three columns">
-<h4>Pages</h4>
-
- <ul>
- {% for title, link in MENUITEMS %}
- <li><a href="{{ link }}">{{ title }}</a></li>
- {% endfor %}
{% if DISPLAY_PAGES_ON_MENU %}
+ <h4>Pages</h4>
+
+ <ul>
+ {% for title, link in MENUITEMS %}
+ <li><a href="{{ link }}">{{ title }}</a></li>
+ {% endfor %}
+
{% for p in pages %}
- <li{% if p == page %} class="active"{% endif %}><a href="{{ SITEURL }}/{{ p.url }}">{{ p.title }}</a></li>
+ <li {% if p==page %} class="active" {% endif %}><a href="{{ SITEURL }}/{{ p.url }}">{{ p.title }}</a></li>
{% endfor %}
- {% else %}
- {% if DISPLAY_CATEGORIES_ON_MENU %}
- {% for cat, null in categories %}
- <li{% if cat == category %} class="active"{% endif %}><a href="{{ SITEURL }}/{{ cat.url }}">{{ cat }}</a></li>
- {% endfor %}
- {% endif %}
+ {% else %}
+ </ul>
{% endif %}
+
+ {% if DISPLAY_CATEGORIES_ON_MENU %}
+ {% if categories and categories|length > 1 %}
+ <h4>Categories</h4>
+ <ul class="blank">
+ {% for cat, null in categories %}
+ <li><a href="{{ SITEURL }}/{{ cat.url|e }}">{{ cat }}</a></li>
+ {% endfor %}
</ul>
-
-{% if categories and categories|length > 1 %}
-<h4>Categories</h4>
-<ul class="blank">
- {% for cat, null in categories %}
- <li><a href="{{ SITEURL }}/{{ cat.url|e }}">{{ cat }}</a></li>
- {% endfor %}
-</ul>
-{% endif %}
+ {% endif %}
+ {% endif %}
{% if tag_cloud %}