Add reactive render stepper to home page, fix nil→NIL in platform JS
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 3m13s
All checks were successful
Build and Deploy / build-and-deploy (push) Successful in 3m13s
Home page stepper: reactive code view with syntax colouring where tokens highlight as you step through DOM construction. Each token is a span with signal-driven classes — current step bold+violet, completed steps dimmed, upcoming normal. CSSX styling via ~cssx/tw spreads. Lake preserves imperative DOM across reactive re-renders. Also fixes: bare lowercase 'nil' in platform_js.py eventDetail and domGetData — should be NIL (the SX sentinel object). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
// =========================================================================
|
||||
|
||||
var NIL = Object.freeze({ _nil: true, toString: function() { return "nil"; } });
|
||||
var SX_VERSION = "2026-03-14T18:56:40Z";
|
||||
var SX_VERSION = "2026-03-14T20:39:57Z";
|
||||
|
||||
function isNil(x) { return x === NIL || x === null || x === undefined; }
|
||||
function isSxTruthy(x) { return x !== false && !isNil(x); }
|
||||
@@ -5867,7 +5867,7 @@ PRIMITIVES["resource"] = resource;
|
||||
}
|
||||
|
||||
function eventDetail(e) {
|
||||
return (e && e.detail != null) ? e.detail : nil;
|
||||
return (e && e.detail != null) ? e.detail : NIL;
|
||||
}
|
||||
|
||||
function domQuery(sel) {
|
||||
@@ -5912,7 +5912,7 @@ PRIMITIVES["resource"] = resource;
|
||||
if (el) { if (!el._sxData) el._sxData = {}; el._sxData[key] = val; }
|
||||
}
|
||||
function domGetData(el, key) {
|
||||
return (el && el._sxData) ? (el._sxData[key] != null ? el._sxData[key] : nil) : nil;
|
||||
return (el && el._sxData) ? (el._sxData[key] != null ? el._sxData[key] : NIL) : NIL;
|
||||
}
|
||||
function domInnerHtml(el) {
|
||||
return (el && el.innerHTML != null) ? el.innerHTML : "";
|
||||
|
||||
@@ -1821,7 +1821,7 @@ PLATFORM_DOM_JS = """
|
||||
}
|
||||
|
||||
function eventDetail(e) {
|
||||
return (e && e.detail != null) ? e.detail : nil;
|
||||
return (e && e.detail != null) ? e.detail : NIL;
|
||||
}
|
||||
|
||||
function domQuery(sel) {
|
||||
@@ -1866,7 +1866,7 @@ PLATFORM_DOM_JS = """
|
||||
if (el) { if (!el._sxData) el._sxData = {}; el._sxData[key] = val; }
|
||||
}
|
||||
function domGetData(el, key) {
|
||||
return (el && el._sxData) ? (el._sxData[key] != null ? el._sxData[key] : nil) : nil;
|
||||
return (el && el._sxData) ? (el._sxData[key] != null ? el._sxData[key] : NIL) : NIL;
|
||||
}
|
||||
function domInnerHtml(el) {
|
||||
return (el && el.innerHTML != null) ? el.innerHTML : "";
|
||||
|
||||
Reference in New Issue
Block a user