Why the button looked dead on recent pages, what actually broke, and the gate that now stops it · built 2026-06-21 02:20
A handful of recently-generated pages shipped a Kid mode button wired to
onclick="toggleKid()" — but the toggleKid function itself was
never put on the page. So clicking the button threw
toggleKid is not defined and nothing happened.
The button looked perfect in the HTML. It just had nothing behind it.
The page generators emit the button + its CSS, and relied on a separate injector
to add the script. But the idempotency check —
has_button() in kid_mode_inject.py and
ensure_button() in ship.py — treated
"a button tag is present" as "kid mode is satisfied." It never checked
that the toggleKid function existed. A button with no function
sailed through every gate, including the closeout that is supposed to prove it works.
Both gates now require the function, not just the button. A page is
"working" only when it has a button and a real toggleKid
(or a bespoke kid-class toggle). The precise rule:
a page is DEAD only if it references toggleKid() but never defines it.
• kid_mode_inject.py — repairs a dead button by injecting only the
script (no duplicate button), leaves bespoke pages untouched.
• ship.py — ensure_button() repairs before deploy; the live
check now confirms kid_works=true, not just a button tag.
Result: 0 dead buttons remain, and the closeout gate can no longer ship one.
| Modified | Route | Live kid toggle | HTTP |
|---|---|---|---|
| 06-21 02:10 | plans | OK | 200 |
| 06-21 02:05 | straykids-bpm-match | OK·bespoke | 200 |
| 06-21 02:05 | mac-space-map | OK | 200 |
| 06-21 02:03 | chats | OK | 200 |
| 06-21 02:01 | chat-pattern-audit | OK | 200 |
| 06-21 01:57 | magic-the-badgering | OK | 200 |
| 06-21 01:40 | keep-alive-fix | OK | 200 |
| 06-21 01:29 | twin-flame-ceo-audit | OK | 200 |
| 06-21 01:19 | magic-the-badgering-scorecard | OK | 200 |
| 06-21 01:15 | chat-ceo-audit | OK | 200 |
| 06-21 01:14 | tarot-boundaries-betrayal | OK | 200 |
| 06-21 01:14 | tarot-combo-index | OK | 200 |
| 06-21 01:14 | tarot-did-they-cheat | OK | 200 |
| 06-21 01:14 | tv-scripts | OK | 200 |
| 06-21 01:14 | work-products | OK | 200 |
| 06-21 01:14 | zorba | OK | 200 |
| 06-21 01:14 | missing-images-2026-06-20 | OK | 200 |
| 06-21 01:14 | community-deck-status-2026-06-20 | OK | 200 |
| 06-21 01:14 | chiron-sourceaudio-control-tactics | OK | 200 |
| 06-21 01:10 | chat-fix-20 | OK | 200 |
| 06-21 00:50 | python-slam-2026 | OK | 200 |
| 06-20 23:36 | kid-mode-backfill-2026-06-20 | OK | 200 |
| 06-20 23:01 | fix-plan | OK | 200 |
| 06-20 22:59 | buried-treasures | OK | 200 |
| 06-20 22:58 | transcribe-reclaim | OK | 200 |
| 06-20 22:58 | thirteenth-step-charts | OK | 200 |
| 06-20 22:58 | the-mutiny-stem-vs-midi | OK | 200 |
| 06-20 22:58 | the-mutiny-midi-fix | OK | 200 |
| 06-20 22:58 | the-alligator-stem-vs-midi | OK | 200 |
| 06-20 22:58 | tarot-v3-gate-results | OK | 200 |
Measured live at build time.
OK = real toggleKid present · OK·bespoke =
page has its own working kid toggle (e.g. straykids) · DEAD = button with no function.
This box is full of jargon: the midi stems get a demucs pass, then deploy to vercel from the dashboard.
Tap the floating 🧒 Kid mode button (bottom-right). Watch the font warm up, the page tint, and every jargon word above turn into plain English. That is kid mode working — the exact thing that was dead on the broken pages.
Vercel serves with stale-while-revalidate=86400, so the CDN can hand
you a cached copy from up to a day ago while it refreshes in the background. If
you saw a dead button before the fix deployed, your browser/edge may still be holding
that old copy. This deploy purges the edge; a hard refresh
(Cmd + Shift + R) clears the rest.