Fix examples.sx: paren balance + dict eval crash at startup

1. Extra closing paren in ex-tabs handler
2. tab-content dict values contained (div ...) HTML tags which crash
   during register_components since HTML primitives aren't in env

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-12 01:30:21 +00:00
parent c23d0888ea
commit 17c58a2b5b
10 changed files with 110 additions and 1103 deletions

View File

@@ -24,19 +24,9 @@
(list "admin@example.com" "test@example.com" "user@example.com"))
(define tab-content
{"tab1" (div (p :class "text-stone-700" "Welcome to the Overview tab.")
(p :class "text-stone-500 text-sm mt-2"
"This is the default tab content loaded via sx-get."))
"tab2" (div (p :class "text-stone-700" "Here are the details.")
(ul :class "mt-2 space-y-1 text-sm text-stone-600"
(li "Version: 1.0.0")
(li "Build: 2024-01-15")
(li "Engine: sx")))
"tab3" (div (p :class "text-stone-700" "Recent history:")
(ol :class "mt-2 space-y-1 text-sm text-stone-600 list-decimal list-inside"
(li "Initial release")
(li "Added component caching")
(li "Wire format v2")))})
{"tab1" "Welcome to the Overview tab. This is the default tab content loaded via sx-get."
"tab2" "Here are the details. Version: 1.0.0, Build: 2024-01-15, Engine: sx"
"tab3" "Recent history: Initial release, Added component caching, Wire format v2"})
(define kbd-actions
{"s" "Search panel activated"