4Stem Band Player surfaces two types of textual song data alongside the playback controls: a floating Lyrics panel for verbatim lyric text and a Song Info panel for structured metadata including key, BPM, time signature, chord progressions, rehearsal notes, and named section markers.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/cocreating/4StemPlayer/llms.txt
Use this file to discover all available pages before exploring further.
Lyrics Panel
The Lyrics button in the Transport Controls bar opens a floating panel below the transport area. The panel includes a close button and hides itself (aria-hidden) when closed so it does not interfere with keyboard navigation when not in use.
Lyrics text is rendered inside a <pre> element that preserves all whitespace, line breaks, and indentation exactly as written in lyrics.md. If no lyrics file exists or the file is empty, the panel shows “No lyrics are available for this song.”
Sample lyrics.md
An empty
lyrics.md is a warning, not a validation error. The song will still load and the Lyrics button will be disabled (or show the empty-state message) rather than blocking playback.Song Info Panel
The Song Info panel lives in the sidebar alongside the stem mixer. It shows the song title, artist, and a metadata grid with the following fields drawn fromsong.json:
| Field | Source key | Example |
|---|---|---|
| Key | key | Am |
| BPM | bpm | 96 |
| Time | timeSignature | 4/4 |
| Duration | duration | 4:06 |
| Seconds | durationSeconds | 246 |
song.json fields are absent.
Below the metadata grid, the panel renders the chord chart (if chords is present in song.json) and rehearsal notes (if notes is present).
Chord Chart
Whensong.json includes a chords field, the Song Info panel renders a formatted chord chart below the metadata grid. The chords field accepts two formats:
- Structured object (preferred)
- Legacy string
A
Record where each key is a section name and the value is either a plain progression string or a full section object with an optional label, required progression, and optional notes.formatChords helper in SongInfoPanel.svelte converts either format into display text.
Section Markers
Section markers appear in the Sections floating panel (opened from the transport bar) as seek buttons. Each marker in thesections array requires a label and a numeric start time in seconds from the beginning of the song. An optional end time is supported in the data contract.
Sample song.json with Sections and Chords
Song Notes
The optionalnotes field in song.json holds freeform rehearsal notes — key changes, capo instructions, performance cues, or anything else the band needs to remember. Notes appear in their own section beneath the chord chart in the Song Info panel.
Section Navigation from the Sections Panel
Pressing the Sections button in the transport opens a floating panel that lists everysections entry as a seek button. Pressing a button jumps the playhead to that section’s start time, exactly as if you had dragged the transport seek slider to that position. See Transport Controls for the full sections panel behaviour.
Mobile scroll behaviour
Mobile scroll behaviour
On mobile, opening any of the floating panels — Sections, Lyrics, or Mixer — automatically scrolls the panel into view. Closing the panel scrolls back to the top of the page so the transport controls are immediately visible again.
Data Contract Summary
song.json Schema
Full TypeScript interface for
SongMetadata including all optional fields, validation rules, and the two chord formats.Ingestion Workflow
How
npm run songs:prepare validates metadata, detects BPM, generates peak files, and regenerates the manifest.