Files
rose-ash/sx/sxc/examples/delete-row.sx
giles a7da235459 SXC content: docs/examples/home/reference pages + SX testing runner
New sxc/ content tree with 120 page files across docs, examples, home,
and reference demos. sx/sx/testing/ adds page-runner.sx (317L) and
index-runner.sx (394L) — SX-native test runner pages for
browser-based evaluation.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-22 09:08:47 +00:00

16 lines
506 B
Plaintext

(defcomp
(&key id name)
(tr
:id (str "row-" id)
(~tw :tokens "border-b border-stone-100 transition-all")
(td (~tw :tokens "px-3 py-2 text-stone-700") name)
(td
(~tw :tokens "px-3 py-2")
(button
:sx-delete (str "/sx/(geography.(hypermedia.(example.(api.(delete." id ")))))")
:sx-target (str "#row-" id)
:sx-swap "outerHTML"
:sx-confirm "Delete this item?"
(~tw :tokens "text-rose-500 hover:text-rose-700 text-sm")
"delete"))))