{# Status Components Macros: status_dot, stage_dots, progress_dots #} {% macro status_dot(status, size="sm", animate=true) %} {# Colored dot indicator for status values. Args: status: One of success, failed, error, running, pending, cancelled, skipped, etc. size: "xs" (1.5), "sm" (2), "md" (3) animate: Pulse animation for running/active states Maps: success/ok/healthy/online → green failed/error/unhealthy → red running/active/connected → yellow (pulse) pending/waiting/queued → blue cancelled/stopped/paused → gray skipped/inactive → gray (no pulse) #} {% set sizes = {"xs": "w-1.5 h-1.5", "sm": "w-2 h-2", "md": "w-3 h-3"} %} {% set s = status | lower %} {% if s in ["success", "ok", "healthy", "online", "passed"] %} {% elif s in ["failed", "error", "unhealthy", "offline"] %} {% elif s in ["running", "active", "connected"] %} {% elif s in ["pending", "waiting", "queued"] %} {% elif s in ["cancelled", "stopped", "paused"] %} {% elif s in ["skipped", "inactive"] %} {% elif s in ["warning"] %} {% else %} {% endif %} {% endmacro %} {% macro stage_dots(stages, size="xs") %} {# Row of tiny dots showing stage pass/fail status, for run history rows. Args: stages: List of objects with .status attribute (or dicts with "status" key) size: Dot size — "xs" (1.5), "sm" (2), "md" (3). Default "xs". #} {% for s in stages %} {{ status_dot(s.status, size=size, animate=false) }} {% endfor %} {% endmacro %} {% macro progress_stages(stages) %} {# Full-width progress bar split into colored segments per stage. Use in run detail pages for visual progress overview. Args: stages: List of stage objects with .stage_name and .status attributes #} {% if stages | length > 0 %}