Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Fix category / collection page name header

dominik-zegleneb518d3fc153
diff --git a/saleor/static/scss/components/_filters.scss b/saleor/static/scss/components/_filters.scss
index a804c08d8c..edccdbb109 100644
--- a/saleor/static/scss/components/_filters.scss
+++ b/saleor/static/scss/components/_filters.scss
@@ -1,4 +1,5 @@
.product-filters {
+ padding-bottom: $global-padding * 2;
.hide {
display: none;
}
@@ -58,8 +59,6 @@
}
}
&__title {
- padding: 0;
- padding-top: $global-padding*1;
@include media-breakpoint-down(sm) {
padding: $global-padding*3 0 $global-padding*2;
}
@@ -73,8 +72,7 @@
}
}
&__categories {
- padding: 0;
- padding-bottom: $global-padding*2;
+ padding: $global-padding 0 0;
@include media-breakpoint-down(sm) {
padding: $global-padding*3 0 $global-padding*2;
}
diff --git a/templates/category/filters.html b/templates/category/filters.html
index d709fda146..40a3de5055 100644
--- a/templates/category/filters.html
+++ b/templates/category/filters.html
@@ -1,13 +1,15 @@
-{% extends "product/_filters.html"%}
+{% extends "product/_filters.html" %}
{% block title_tree %}
- <div class="product-filters__categories">
- <ul class="product-filters__categories__childs no-parent">
- {% for child in category.get_children %}
- <li>
- <a href="{{ child.get_absolute_url }}">{{ child.name }}</a>
- </li>
- {% endfor %}
- </ul>
- </div>
+ {% if category.get_children %}
+ <div class="product-filters__categories">
+ <ul class="product-filters__categories__childs no-parent">
+ {% for child in category.get_children %}
+ <li>
+ <a href="{{ child.get_absolute_url }}">{{ child.name }}</a>
+ </li>
+ {% endfor %}
+ </ul>
+ </div>
+ {% endif %}
{% endblock title_tree %}