You've already forked wp-bootstrap
Replace FSE block markup on the frontend with proper Bootstrap 5 HTML rendered through Twig templates. The Site Editor remains functional for admin editing while the public site outputs Bootstrap navbar, cards, pagination, grid layout, and responsive components. New PHP classes: TemplateController, ContextBuilder, NavWalker New Twig templates: 20 files (base, pages, partials, components) Enhanced TwigService with WordPress functions and globals Co-Authored-By: Claude <noreply@anthropic.com>
27 lines
1.2 KiB
Twig
27 lines
1.2 KiB
Twig
{% if pagination and pagination.pages is defined and pagination.pages|length > 1 %}
|
|
<nav aria-label="{{ __('Page navigation') }}" class="my-5">
|
|
<ul class="pagination justify-content-center">
|
|
<li class="page-item{{ pagination.prev_url is null ? ' disabled' : '' }}">
|
|
<a class="page-link" href="{{ pagination.prev_url ?? '#' }}"
|
|
{% if pagination.prev_url is null %}tabindex="-1" aria-disabled="true"{% endif %}>
|
|
{{ pagination.prev_text }}
|
|
</a>
|
|
</li>
|
|
{% for page in pagination.pages %}
|
|
<li class="page-item{{ page.is_current ? ' active' : '' }}">
|
|
<a class="page-link" href="{{ page.url }}"
|
|
{% if page.is_current %}aria-current="page"{% endif %}>
|
|
{{ page.number }}
|
|
</a>
|
|
</li>
|
|
{% endfor %}
|
|
<li class="page-item{{ pagination.next_url is null ? ' disabled' : '' }}">
|
|
<a class="page-link" href="{{ pagination.next_url ?? '#' }}"
|
|
{% if pagination.next_url is null %}tabindex="-1" aria-disabled="true"{% endif %}>
|
|
{{ pagination.next_text }}
|
|
</a>
|
|
</li>
|
|
</ul>
|
|
</nav>
|
|
{% endif %}
|