Resume offline preparation on launch and show cache readiness

This commit is contained in:
Jonathan Sykes
2026-10-09 09:33:23 +08:00
parent 0251720fa2
commit 009a155568
6 changed files with 63 additions and 8 deletions

View File

@@ -843,6 +843,7 @@ async function renderSettings() {
<div class="set-group">
<div class="set-group-title">Offline cache</div>
<div class="set-row"><span>App &amp; features</span><small id="offlineAssetStatus" role="status">Checking offline readiness…</small></div>
<label class="set-row">
<span>
Auto-save playlist videos
@@ -1186,6 +1187,8 @@ async function renderSettings() {
fold.addEventListener('toggle', () => { try { localStorage.setItem('ytpCacheFoldOpen', fold.open ? '1' : '0'); } catch { /* blocked */ } });
}
window.SwUpdate?.offlineStatus().catch(() => {});
// ---- Populate live cache stats ----
try {
const res = await API.cacheList();