diff options
Diffstat (limited to 'templates/macro.j2')
| -rw-r--r-- | templates/macro.j2 | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/templates/macro.j2 b/templates/macro.j2 new file mode 100644 index 0000000..e0089bc --- /dev/null +++ b/templates/macro.j2 @@ -0,0 +1,3 @@ +{% macro player_button(player) %} +<button class={% if player.status %} "active" {% else %} "dormant" {% endif %} hx-post="{{ "/player-toggle/" ~ player.name}}" hx-trigger="click" hx-swap="outerHTML">{{ player.name }}</button> +{%- endmacro %}
\ No newline at end of file |
