diff --git a/public/sw.js b/public/sw.js index aff8dc2..cf74ce9 100644 --- a/public/sw.js +++ b/public/sw.js @@ -1,7 +1,7 @@ // Tchatou service worker — installable PWA + offline app shell. // Scope: /app/. Only handles same-origin /app/ GETs; the IRC websocket and all // API calls (cloudflare, change_password, upload) pass straight through. -const CACHE = 'tchatou-v53'; +const CACHE = 'tchatou-v54'; const SHELL = ['/app/', '/app/index.html', '/app/favicon.svg', '/app/orbit-icon.svg', '/app/manifest.webmanifest']; self.addEventListener('install', (e) => { diff --git a/src/index.css b/src/index.css index d2f7890..a34627c 100644 --- a/src/index.css +++ b/src/index.css @@ -1695,3 +1695,14 @@ input:focus-visible, textarea:focus-visible, select:focus-visible { background: var(--green); color: #fff; padding: .6rem 1rem; border-radius: 0 0 12px 12px; font-weight: 600; text-decoration: none; transition: top .15s ease; } .skip-link:focus { top: 0; } + +/* ── Large-channel virtualization (browser-native) ────────────────────────── + Member rows skip layout & paint while off-screen, so a 2,000-member panel + only does real rendering work for the handful of visible rows — the rest cost + ~nothing until scrolled into view. contain-intrinsic-size gives off-screen + rows a placeholder height (so the scrollbar is right); `auto` makes the + browser remember each row's real height after it first renders. Visible rows + render exactly as before, so small channels are unchanged. Degrades to normal + rendering on browsers without content-visibility. */ +.member { content-visibility: auto; contain-intrinsic-size: auto 44px; } +[data-theme^="yomirc"] .member { contain-intrinsic-size: auto 20px; }