{# Pagination controls (MNT-14). Import and call: {% import 'layouts/_pagination.html' as pager %} {{ pager.controls(pagination) }} `page_url` is a Jinja global registered in app.py; it rebuilds the current URL at another page number, keeping the rest of the query string. That is the part that gets forgotten — dropping `sort` or `team_id` from a pagination link silently resets the view someone was looking at. Plain links only: no inline handler, nothing for CSP to refuse (tests/test_csp.py). #} {% macro controls(pagination) %} {% if pagination.pages > 1 %} {% endif %} {% endmacro %}