opencode
opencode copied to clipboard
feat(web): add kiosk mode for simplified UI
Summary
Add kiosk mode to the web UI that provides a simplified user experience by hiding navigation elements.
URL Parameters
| Parameter | Description |
|---|---|
?kiosk=true |
Hides sidebar and header |
?dir=/path |
Auto-opens project and navigates to new session |
Use Cases
- Embedded deployments
- Simplified onboarding experiences
- Kiosk terminals
- Single-project focused workflows
Example URLs
# Basic kiosk mode
http://localhost:4096/?kiosk=true
# Kiosk with auto-project
http://localhost:4096/?kiosk=true&dir=/home/user/my-project
Changes
-
packages/app/src/context/layout.tsx- Addedkiosk.enabled()andkiosk.dir()state -
packages/app/src/pages/layout.tsx- Conditional sidebar rendering -
packages/app/src/components/session/session-header.tsx- Conditional header rendering -
packages/app/src/pages/home.tsx- Auto-redirect logic fordirparameter -
docs/KIOSK_MODE.md- Feature documentation
Test Plan
- [x] Verify
?kiosk=truehides sidebar (desktop) - [x] Verify
?kiosk=truehides sidebar (mobile) - [x] Verify
?kiosk=truehides header - [x] Verify
?dir=/pathauto-redirects to new session - [x] Verify normal mode unaffected without parameters
- [x] Type checking passes