{#- chirp-ui: Wizard form component Server-driven multi-step form wrapper. Bundles stepper + swap target + form slot. Use for HTMX fragment-style wizards: forms submit and replace the entire wrapper so the step indicator stays in sync. Uses hx-disinherit for HTMX-safe swaps. Usage: {% from "chirpui/wizard_form.html" import wizard_form %} {% call wizard_form("checkout", steps=steps, current=step) %}
...fields...
{% end %} Backend: return the full wizard_form wrapper for fragment requests. -#} {% from "chirpui/stepper.html" import stepper %} {% def wizard_form(id, steps, current=1, cls="", attrs="") %}
{{ stepper(steps=steps, current=current) }}
{% slot %}
{% end %}