Change category overview

This commit is contained in:
sqozz 2017-12-28 19:13:27 +01:00
parent c028559650
commit 8fe644a993
2 changed files with 26 additions and 17 deletions

View file

@ -1,10 +1,16 @@
.inner.cover {
display: flex;
flex-direction: column;
align-items: center;
}
#categories {
display: flex;
align-items: baseline;
flex-wrap: wrap;
}
.inner.cover > span {
#categories span {
width: 33%;
margin-bottom: 10px;
}

View file

@ -6,20 +6,23 @@ vim: ts=2 noexpandtab
{% set active_page = "categories" %}
{% block content %}
<link href="{{ url_for("static", filename="css/categories.css") }}" rel="stylesheet">
{% for category in categories %}
<span>
<ul>
<li>
<a href="search?c={{ category }}">{{ category }}</a>
<ul>
{% for sub_category in categories[category] %}
<li>
<a href="search?s={{ sub_category }}">{{ sub_category }}</a>
</li>
{% endfor %}
</ul>
</li>
</ul>
</span>
{% endfor %}
<h2 class="headline">Categories</h2>
<div id="categories">
{% for category in categories %}
<span>
<ul>
<li>
<a href="search?c={{ category }}">{{ category }}</a>
<ul>
{% for sub_category in categories[category] %}
<li>
<a href="search?s={{ sub_category }}">{{ sub_category }}</a>
</li>
{% endfor %}
</ul>
</li>
</ul>
</span>
{% endfor %}
</div>
{% endblock content%}