{% extends "base.html" %}
{% block title_suffix %} - MRs{% endblock %}
{% block content %}
<h2>Merge Requests</h2>
<div class="filter-toggle">
    <button class="outline" data-filter="mine" data-filter-page="mrs"
            hx-get="/fragment/mrs?filter=mine"
            hx-target="#mrs-content"
            hx-swap="innerHTML"
            onclick="localStorage.setItem('filter_mrs','mine'); window.tableSorted=false; updateFilterButtons()">Mine</button>
    <button class="outline" data-filter="all" data-filter-page="mrs"
            hx-get="/fragment/mrs?filter=all"
            hx-target="#mrs-content"
            hx-swap="innerHTML"
            onclick="localStorage.setItem('filter_mrs','all'); window.tableSorted=false; updateFilterButtons()">All</button>
</div>
<div id="mrs-content"
     hx-get="/fragment/mrs"
     hx-trigger="load, every 10s"
     hx-swap="innerHTML"
>
<p class="htmx-indicator-inline" aria-busy="true">Loading from cache…</p>
</div>
{% endblock %}
