Description Problem
The player writes the current track name to now-playing.txt, but the file still contains stale data after the app is closed.
Downstream tools that read now-playing.txt (e.g., overlays or stream widgets) continue to show the last track even though nothing is playing.
Proposal
Detect when the app window or tab is being closed and clear the contents of now-playing.txt before exiting.
Consider also clearing the file if playback stops because the selected folder is closed or the track list empties.
Acceptance Criteria
Closing the player tab or window results in an empty now-playing.txt file.
Clear behavior does not trigger while general playback is paused or when switching tracks.
Behavior works consistently across supported Chromium-based browsers.
Notes
Ensure the cleanup logic aligns with the File System Access API limitations and handles permission prompts gracefully.
Reactions are currently unavailable
You can’t perform that action at this time.
Problem
now-playing.txt, but the file still contains stale data after the app is closed.now-playing.txt(e.g., overlays or stream widgets) continue to show the last track even though nothing is playing.Proposal
now-playing.txtbefore exiting.Acceptance Criteria
now-playing.txtfile.Notes