Merge branch 'worktree-sx-loop-cleanup' into macros

# Conflicts:
#	blog/sx/sx_components.py
#	federation/sx/profile.sx
#	federation/sx/sx_components.py
#	orders/sx/sx_components.py
This commit is contained in:
2026-03-05 16:08:36 +00:00
9 changed files with 356 additions and 0 deletions

View File

@@ -47,6 +47,17 @@
(h2 :class "text-base sm:text-lg font-semibold" "Event tickets in this order")
(ul :class "divide-y divide-stone-200 rounded-2xl border border-stone-200 bg-white/80" items)))
;; Data-driven ticket items (replaces Python loop)
(defcomp ~checkout-return-tickets-from-data (&key tickets)
(~checkout-return-tickets
:items (<> (map (lambda (tk)
(~checkout-return-ticket
:name (get tk "name") :pill (get tk "pill")
:state (get tk "state") :type-name (get tk "type_name")
:date-str (get tk "date_str") :code (get tk "code")
:price (get tk "price")))
(or tickets (list))))))
(defcomp ~checkout-return-content (&key summary items calendar tickets status-message)
(div :class "max-w-full px-1 py-1"
(when summary