GUI: Aufnahmen-Liste startet mit nur dem neuesten Tag geoeffnet

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0113vDKdSNtD3Dwcw4QMu9yV
This commit is contained in:
schakal00783
2026-07-17 01:49:27 +02:00
co-authored by Claude Fable 5
parent d55442a41f
commit 46f8327832
2 changed files with 13 additions and 0 deletions
+6
View File
@@ -283,6 +283,9 @@ function ensureAnaTicker() {
// audio element — was re-rendered every 5s, stopping playback).
function viewRecordings() {
const v = document.querySelector('#view');
// Entering the tab: show only the newest day expanded, the rest collapsed
// (applied in refreshRecList once the day groups are known).
state.resetCollapse = true;
v.innerHTML = `
<div class="rec-layout">
<aside class="rec-list-pane"><div id="reclist" class="list">Lade…</div></aside>
@@ -325,6 +328,9 @@ async function refreshRecList() {
if (!byDay[day]) { byDay[day] = []; groups.push(day); }
byDay[day].push(r);
}
// Fresh tab entry: only the newest day (first group, recs are newest-first)
// stays open; manual toggles afterwards are respected until the next entry.
if (state.resetCollapse) { state.collapsedDates = new Set(groups.slice(1)); state.resetCollapse = false; }
listEl.innerHTML = groups.map(day => {
const collapsed = state.collapsedDates.has(day);
const items = byDay[day].map(r => { const at = anaTimeSpan(r); return `