Something went wrong. Try again.
Monorepo for Aesthetic.Computer aesthetic.computer
Something went wrong. Try again.
Markdown
Solo Mode Feature Plan #
Goal: Add a "solo" mode to aesthetic.computer that locks a piece in place, preventing navigation away via keyboard shortcuts, prompt HUD corner label taps, or any other escape mechanism.
URL Patterns #
Option 1: Pipe Suffix (Quick Typing) #
aesthetic.computer/notepat|
- Trailing
|expands to?solo=trueinternally - Fast to type, visually clean URL
- Processed in
index.mjs(router) — redirect or rewrite to query param
Option 2: Query Parameter #
aesthetic.computer/notepat?solo
aesthetic.computer/notepat&solo
- Standard query param approach
- More explicit, easier to understand
Recommendation: Support both — | as syntactic sugar that expands to ?solo.
Implementation Locations #
1. Router (system/netlify/functions/index.mjs) #
- Detect trailing
|in slug/path - Strip the
|and redirect to?soloversion (302) - Example:
/notepat|→/notepat?solo
2. Boot (system/public/aesthetic.computer/boot.mjs) #
- Add
'solo'toLEGITIMATE_PARAMSarray (~line 466) - Parse
soloparam liketv,device, etc. (~line 1097+) - Pass
solo: truetoboot()via resolution object - Example pattern follows existing
tv/devicehandling
3. Bios (system/public/aesthetic.computer/bios.mjs) #
- Accept
soloin resolution object (already receivestv,device, etc.) - Store in
preservedParamsfor refresh functionality (~line 758) - Pass through to disk init message
4. Disk (system/public/aesthetic.computer/lib/disk.mjs) #
Primary implementation location
A. Add SOLO_MODE flag (~line 632) #
let SOLO_MODE = false; // Whether running in solo mode (prevents navigating away from piece)
B. Set flag from init message (~line 9258) #
SOLO_MODE = content.resolution?.solo === true;
C. Disable keyboard navigation shortcuts (~line 10860+) #
- Block
Escapekey handling whenSOLO_MODEis true - Block
Back to promptfunctionality - Possibly block
Tabfor HUD toggle (or keep but read-only)
D. Disable prompt HUD corner label interactivity #
- The corner label tap functionality is handled via
qr-corner-tapmessage (~line 14216) - In solo mode:
- Don't register the
qr-cornerhitbox (skipbutton:hitbox:add) - Or don't handle the tap message
- Skip sound effects on touch/tap in that area
- Don't register the
E. Prevent $commonApi.jump() (~line 2686) #
jump: function jump(to, ahistorical = false, alias = false) {
if (SOLO_MODE) {
console.log("🔒 Jump blocked: solo mode active");
return;
}
// ... existing code
}
Behavior in Solo Mode #
| Feature | Normal | Solo Mode |
|---|---|---|
| Escape key → prompt | ✅ Works | ❌ Blocked |
| Back navigation | ✅ Works | ❌ Blocked |
| Corner label tap | ✅ Opens prompt | ❌ No action, no sound |
| Tab (HUD toggle) | ✅ Toggles HUD | ❓ Optional: keep or disable |
| Shift (QR fullscreen) | ✅ Works | ❓ Optional: keep for sharing |
jump() API |
✅ Works | ❌ Blocked |
| Page refresh | ✅ Works | ✅ Works (stays in solo) |
Files to Modify #
- system/netlify/functions/index.mjs — Pipe suffix detection & redirect
- system/public/aesthetic.computer/boot.mjs — Add
soloparam handling - system/public/aesthetic.computer/bios.mjs — Pass
soloto disk - system/public/aesthetic.computer/lib/disk.mjs — Core blocking logic
Testing Checklist #
Implementation Order #
- Add
solotoLEGITIMATE_PARAMSin boot.mjs - Parse and pass
solothrough boot→bios→disk chain - Add
SOLO_MODEflag and blocking logic in disk.mjs - Add
|suffix handling in index.mjs router - Test all edge cases
Notes #
- Similar pattern to existing
TV_MODEandDEVICE_MODEflags - Solo mode is purely client-side (no server changes needed beyond router)
- Could extend to support "presentation mode" or "kiosk mode" variants later