{%- import 'ui/kit.html' as kit -%} {%- set cols = [('spell', 'spell'), ('when', 'when (action)'), ('status', 'status'), ('runs', 'runs'), ('last', 'last run'), ('act', '')] -%} {%- if flash %}{{ kit.flash(flash, tone) }}{% endif %} {%- call kit.list('wands', cols, page, per, total, 'No spells yet. Create one to react to events.') %} {%- for s in rows %} {{ s.spell }} {{ s.action }} {{ kit.active_pill(s.enabled) }}{% if s.runs %} locked{% endif %} {{ s.runs }} {% if s.last %}{{ s.last }}{% else %}-{% endif %} {%- if principal and principal.superadmin %} {%- endif %} {%- endfor %} {%- endcall %} {%- if close == 'modal' %}{{ kit.close_modal() }}{% elif close == 'drawer' %}{{ kit.close_drawer() }}{% endif %}