URL restructure, 404 page, trailing slash normalization, layout fixes
- Rename /reactive-islands/ → /reactive/, /reference/ → /hypermedia/reference/, /examples/ → /hypermedia/examples/ across all .sx and .py files - Add 404 error page (not-found.sx) working on both server refresh and client-side SX navigation via orchestration.sx error response handling - Add trailing slash redirect (GET only, excludes /api/, /static/, /internal/) - Remove blue sky-500 header bar from SX docs layout (conditional on header-rows) - Fix 405 on API endpoints from trailing slash redirect hitting POST/PUT/DELETE - Fix client-side 404: orchestration.sx now swaps error response content instead of silently dropping it - Add new plan files and home page component Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
20
sx/sx/not-found.sx
Normal file
20
sx/sx/not-found.sx
Normal file
@@ -0,0 +1,20 @@
|
||||
;; 404 Not Found page content
|
||||
|
||||
(defcomp ~not-found-content (&key path)
|
||||
(div :class "max-w-3xl mx-auto px-4 py-12 text-center"
|
||||
(h1 :style (cssx (:text (colour "stone" 800) (size "3xl") (weight "bold")))
|
||||
"404")
|
||||
(p :class "mt-4"
|
||||
:style (cssx (:text (colour "stone" 500) (size "lg")))
|
||||
"Page not found")
|
||||
(when path
|
||||
(p :class "mt-2"
|
||||
:style (cssx (:text (colour "stone" 400) (size "sm") (family "mono")))
|
||||
path))
|
||||
(a :href "/"
|
||||
:sx-get "/" :sx-target "#main-panel" :sx-select "#main-panel"
|
||||
:sx-swap "outerHTML" :sx-push-url "true"
|
||||
:class "inline-block mt-6 px-4 py-2 rounded border transition-colors"
|
||||
:style (cssx (:text (colour "violet" 700) (size "sm"))
|
||||
(:border (colour "violet" 200)))
|
||||
"Back to home")))
|
||||
Reference in New Issue
Block a user