/* Parent → Documents: files the school has shared (reads jl_docs). */ function DocsScreen({ onNav, onBack }) { const SEED = [ { name:'Family Handbook 2026–27', cat:'Policies', type:'PDF', size:'2.4 MB', when:'Jun 1', icon:'book-open', tint:'var(--blue-100)', ic:'var(--blue-500)' }, { name:'June Newsletter', cat:'Newsletters', type:'PDF', size:'860 KB', when:'May 30', icon:'newspaper', tint:'var(--success-100)', ic:'var(--success-500)' }, { name:'Bus Route Map — Fall', cat:'Transportation', type:'PDF', size:'1.1 MB', when:'May 28', icon:'map', tint:'var(--gold-100)', ic:'var(--gold-600)' }, ]; const [docs, setDocs] = React.useState([]); React.useEffect(() => { JLBackend.seed({ docs: SEED }); setDocs(JLBackend.get('docs', SEED)); return JLBackend.subscribe('docs', v => setDocs(v || [])); }, []); return (
{docs.length} shared {docs.length===1?'document':'documents'}
Published by your school
{jlT('l_recent') || 'Recent'}
{docs.length===0 &&
No documents shared yet.
} {docs.map((d,i) => ( {i>0 && } ))}
); } Object.assign(window, { DocsScreen });