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>
This commit is contained in:
15
sx/sxc/examples/delete-row.sx
Normal file
15
sx/sxc/examples/delete-row.sx
Normal file
@@ -0,0 +1,15 @@
|
||||
(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"))))
|
||||
Reference in New Issue
Block a user