1
2
3
4
5
6
7
8
9
10
{# Update Hook summary cell: status + install/remove toggle (hook-install.js). Expects mode: unavailable | different | toggle. #}
{% if mode == "unavailable" %}
<span class="text-muted">unavailable</span>
{% elif mode == "different" %}
<span class="text-muted">A custom hook is already installed at one of <code>post-commit</code> / <code>post-receive</code>; refusing to manage it.</span>
{% elif mode == "toggle" %}
<span class="hook-state text-muted me-2" data-sample="{{ bundle }}">{{ state_label }}</span>
<button type="button" class="{{ button_class }}" data-project="{{ project_enc }}" data-sample="{{ bundle }}" data-op="{{ next_op }}">{{ button_label }}</button>
{% endif %}