{% sw_extends '@Storefront/storefront/component/product/listing.html.twig' %}
{# when hacking the search total, we can have the horrible situation
where there is a grand total of zero sortings available, thus breaking the frontend #}
{% block element_product_listing_sorting %}
{% if searchResult.sorting %}
{{ parent() }}
{% endif %}
{% endblock %}
{% block element_product_listing_col_empty %}
{% if page.extensions.blogpages and page.extensions.blogpages.total > 0 %}
{% else %}
{{ parent() }}
{% endif %}
{% endblock %}
{% block element_product_listing_row %}
{{ parent() }}
{% if page.extensions.blogpages and page.extensions.blogpages.total > 0 %}
{% block blog_listing %}
{% set blogpages = page.extensions.blogpages %}
<div class="h1webblog-overview">
<div class="cms-block-h1webblog-listing">
<div class="cms-element-blog-listing">
{% block element_h1webblog_listing_row %}
<div class="row cms-listing-row js-listing-wrapper">
{% block element_blog_listing_col %}
{% for blog in blogpages %}
<div class="cms-listing-col {{ listingColumns }}">
{% block element_h1webblog_listing_box %}
{% sw_include '@Storefront/storefront/component/h1webblog/card/box.html.twig' %}
{% endblock %}
</div>
{% endfor %}
{% endblock %}
</div>
{% endblock %}
</div>
</div>
</div>
{% endblock %}
{% endif %}
{% endblock %}