Zen plays a looping black noise track the moment you enter the scene. It operates in two modes: a silent auto-play mode where audio runs in the background with no visible interface, and a controls mode where the browser’s native audio bar appears so you can adjust volume, pause, or seek. Which mode you get depends entirely on a single checkbox on the welcome screen.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/mr-sunset/zen/llms.txt
Use this file to discover all available pages before exploring further.
Enabling controls
To reveal the native audio bar, check the Controls checkbox on the welcome screen before clicking Enter Zen. You can do this at any time — just reload the page to return to the welcome screen.Open the welcome screen
Navigate to https://mr-sunset.github.io/zen. The welcome card will be displayed over the island background.
Check the Controls checkbox
Click the checkbox labelled Controls. A checkmark will appear and the underlying
<audio> element’s controls attribute will be enabled immediately.script.js:
event.target.checked is true, so blackNoise.controls is set to true, which adds the controls attribute to the <audio> element and renders the native browser UI. Unchecking it removes the bar again.
What the controls provide
When controls are enabled, the browser renders its standard<audio controls> interface. While the exact appearance varies by browser and operating system, every modern browser provides at minimum:
- Play / Pause toggle — start and stop the black noise track at will.
- Seek bar — scrub to any position in the audio file. Because the track is set to
loop, reaching the end simply begins the file again. - Volume slider — adjust the playback level independently of your system volume, which is especially useful for blending Zen into a multi-app workspace.
<audio> element itself is absolutely positioned at the top of the viewport (top: 20px) and constrained to 300px wide (capped at 90vw on narrow screens), so it sits unobtrusively above the island scene.
The audio bar always uses a
light color-scheme in light mode and a dark color-scheme in dark mode (color-scheme: light / color-scheme: dark is set directly on #black-noise in the CSS). This keeps the bar legible regardless of the OS theme.Autoplay behavior
The<audio> element in index.html is declared with both the autoplay and loop attributes:
Audio file
The track is stored atassets/black-noise.ogg and served as a static asset alongside the rest of the project. Key details:
- Format: OGG Vorbis (
.ogg) — a free, open-source lossy audio codec with broad browser support. - Looping: the
loopattribute on the<audio>element handles seamless repetition natively; no JavaScript is needed. - Offline playback: once the page has loaded and the file is cached, the audio plays with no active internet connection required.
OGG Vorbis is supported in all modern browsers: Chrome, Firefox, Edge, and Safari 12 and later. If you encounter a browser that does not support
.ogg, updating to the latest version of your browser will resolve it.