Mobile remote: per-track trim (in/out) + waveform + times + scrub/seek + gap

- Queue cards expand to a detail panel with the waveform, elapsed/total/remaining
  times, draggable in/out handles, scrub-to-seek and a 'pausa dopo' gap.
- /api/peaks now also returns exact duration (samples/8000) so non-playing tracks
  have correct times/trim without relying on the output media probe.
- Service worker switched to network-first (+v2) so UI updates aren't masked by
  a stale cache; output.js probeDurations hardened (load()+timeout fallback).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
lucianoandClaude Opus 4.8 committed 2026-06-29 14:37:43 +02:00
1 parent f3f4d0f81e
commit c0230ee1d6
5 files changed
+167 -19

No files matched your search

+4 -2
View File
@@ -103,8 +103,10 @@ app.get('/api/peaks', (req, res) => {
peaks[b] = m; if (m > top) top = m;
}
for (let b = 0; b < buckets; b++) peaks[b] = Math.min(1, peaks[b] / top);
peaksCache.set(key, peaks);
res.json(peaks);
// Exact duration from the decoded mono 8 kHz stream: samples / 8000.
const out = { peaks, duration: n / 8000 };
peaksCache.set(key, out);
res.json(out);
});
});