{{/* Shared empty / error / pending state blocks. state-empty — genuine empty state (no data yet, nothing to show) state-error — request failed; includes optional Retry button state-pending — in-flight indicator (spinner + optional label) Fields (all optional unless noted): .Title string — main heading text .Subtext string — secondary supporting copy .Icon string — icon sprite id (defaults per block) .ActionURL string — primary CTA href (state-empty only) .ActionLabel string — primary CTA label (state-empty only) .RetryURL string — htmx GET URL for retry (state-error only) .RetryTarget string — htmx target selector (default: "closest [data-state-container]") */}} {{ define "state-empty" }}
{{ icon (or .Icon "inbox") "size-12 mx-auto mb-4" }}

{{ or .Title "Nothing here yet." }}

{{ if .Subtext }}

{{ .Subtext }}

{{ end }} {{ if and .ActionURL .ActionLabel }} {{ .ActionLabel }} {{ end }}
{{ end }} {{ define "state-error" }} {{ end }} {{ define "state-pending" }}
{{ if .Title }}

{{ .Title }}

{{ end }}
{{ end }}