diff --git a/public/player.js b/public/player.js index bd35b6d..b3d1c55 100644 --- a/public/player.js +++ b/public/player.js @@ -296,4 +296,4 @@ function openNow() { updateNow(); syncUI(); } // Tell the page how tall the player is, so buttons that float at the bottom (Home, Ask) sit above it instead of covering it. -{ const pe = $('#player'); if (pe && window.ResizeObserver) new ResizeObserver(() => document.documentElement.style.setProperty('--playerh', (pe.hidden ? 0 : pe.offsetHeight) + 'px')).observe(pe); } +if (typeof ResizeObserver === 'function' && typeof document !== 'undefined') { const pe = document.getElementById('player'); if (pe) new ResizeObserver(() => document.documentElement.style.setProperty('--playerh', (pe.hidden ? 0 : pe.offsetHeight) + 'px')).observe(pe); } diff --git a/public/sw.js b/public/sw.js index c6dadeb..375c2a7 100644 --- a/public/sw.js +++ b/public/sw.js @@ -1,5 +1,5 @@ // App-shell cache only; Seafile/API traffic always goes to the network. -const CACHE = 'hub-v86'; +const CACHE = 'hub-v87'; const SHARE = 'hub-share'; // files shared into the app from other apps, held until the person picks a folder const SHELL = ['/icon.svg', '/manifest.webmanifest', '/icons/icon-192.png', '/icons/apple-touch-icon.png'];