{#
Knp\Component\Pager\Paginator
Ref/Doc: https://pimcore.com/docs/pimcore/current/Development_Documentation/Objects/Working_with_PHP_API.html#page_Working-with-Knp-Component-Pager-Paginator
#}
<div>
<ul class="uk-pagination uk-flex-center">
{% if (paginationVariables.current != paginationVariables.first) and (paginationVariables.first is defined) and (paginationVariables.current > paginationVariables.first + 2) %}
<li class="page-item">
<a class="page-link first" href="{{ pimcore_url({'page': paginationVariables.first}) }}" aria-label="First">
<span aria-hidden="true"><<</span>
</a>
</li>
{% endif %}
{% if (paginationVariables.previous is defined) %}
<li class="page-item">
<a class="page-link prev" href="{{ pimcore_url({'page': paginationVariables.previous}) }}" aria-label="Previous">
<span aria-hidden="true"><</span>
</a>
</li>
{% endif %}
{% for page in paginationVariables.pagesInRange %}
{% if paginationVariables.pagesInRange|length > 1 %}
{% if (paginationVariables.current == page) %}
<li class="page-item uk-active" aria-current="page">
<span class="page-link">
{{ page }}
<span class="sr-only">(current)</span>
</span>
</li>
{% else %}
<li class="page-item"><a class="page-link" href="{{ pimcore_url({'page': page}) }}">{{ page }}</a></li>
{% endif %}
{% endif %}
{% endfor %}
{% if(paginationVariables.next is defined) %}
<li class="page-item">
<a class="page-link next" href="{{ pimcore_url({'page': paginationVariables.next}) }}" aria-label="Next">
<span class="flip" aria-hidden="true">></span>
</a>
</li>
{% endif %}
{% if (paginationVariables.current != paginationVariables.last) and (paginationVariables.last is defined) and (paginationVariables.current < paginationVariables.last - 2) %}
<li class="page-item">
<a class="page-link first" href="{{ pimcore_url({'page': paginationVariables.last}) }}" aria-label="First">
<span aria-hidden="true">>></span>
</a>
</li>
{% endif %}
</ul>
</div>