/* Shared concept icons & primitives — exported to window. */ const Icon = { // brand mark mark: ( ), // navigation home: , calendar: , sleep: , brain: , heart: , bolt: , // chrome menu: , cl: , cr: , plus: , search: , refresh: , gear: , sidebar: , }; /* Compact week-grid data — Mon..Sun for May 11–17, 2026. Wed=13 is today. */ const WEEK = { head: [ { name:'Mon', num:11 }, { name:'Tue', num:12 }, { name:'Wed', num:13, today:true }, { name:'Thu', num:14 }, { name:'Fri', num:15 }, { name:'Sat', num:16 }, { name:'Sun', num:17 }, ], allDay: [ [], [], [], [], [{ kind:'purple', label:'Society retreat' }], [{ kind:'green', label:'Flight · LHR → BCN' }], [], ], // each col: events with top% + height% (of grid 9am→6pm = 9h) cols: [ [ // Mon { top:5, h:11, kind:'blue', title:'CS 240 lecture', time:'9:00 — 10:00' }, { top:44, h:17, kind:'teal', title:'Study group', time:'1:00 — 2:30' }, { top:67, h:11, kind:'orange',title:'Sprint planning',time:'3:00 — 4:00' }, ], [ // Tue { top:5, h:11, kind:'blue', title:'CS 240 lecture', time:'9:00' }, { top:14, h:22, kind:'purple',title:'Tutorial · Lab 3', time:'10:30 — 12:30' }, { top:56, h:15, kind:'orange',title:'5k run', time:'2:30 — 3:30' }, ], [ // Wed (today) { top:5, h:11, kind:'blue', title:'CS 240 lecture', time:'9:00' }, { top:24, h:14, kind:'indigo',title:'Office hours', time:'11:30' }, { top:46, h:12, kind:'teal', title:'Project deadline', time:'1:00 — 2:00' }, { top:73, h:12, kind:'green', title:'Climbing', time:'5:00 — 6:30' }, ], [ // Thu { top:8, h:24, kind:'teal', title:'Deep work · Project', time:'10:00 — 12:30' }, { top:46, h:11, kind:'purple',title:'Therapy', time:'1:00' }, { top:62, h:14, kind:'indigo',title:'1:1 manager', time:'2:30' }, ], [ // Fri { top:5, h:11, kind:'blue', title:'CS 240 lecture' }, { top:18, h:26, kind:'purple',title:'Society exec', time:'10:30 — 12:30' }, { top:50, h:11, kind:'indigo',title:'Dinner — Sam', time:'1:30' }, { top:76, h:12, kind:'red', title:'Flight · LHR → BCN', time:'3:45' }, ], [ // Sat { top:14, h:14, kind:'orange',title:'Long run', time:'11:00 — 12:30' }, { top:44, h:14, kind:'indigo',title:'Match · Sunday League' }, { top:66, h:14, kind:'red', title:'Anniversary dinner' }, ], [ // Sun { top:24, h:12, kind:'red', title:'Brunch · Sam' }, { top:50, h:22, kind:'purple',title:'Study block · CS 240' }, ], ], }; function WeekHead() { return (
{WEEK.head.map(d => (
{d.name}
{d.num}
))}
); } function AllDayRow() { return (
all-day
{WEEK.allDay.map((items, i) => (
{items.map((it, j) =>
{it.label}
)}
))}
); } function WeekBody({ showNow = true }) { return (
{['9 AM','10','11','12 PM','1','2','3','4','5','6'].map(h =>
{h}
)}
{WEEK.cols.map((evs, i) => { const isToday = WEEK.head[i].today; return (
{/* half-hour gridlines */} {[1,2,3,4,5,6,7,8,9].map(k => (
))} {evs.map((ev, j) => (
{ev.title}{ev.time ? {ev.time} : null}
))} {isToday && showNow ?
: null}
); })}
); } /* Mini cal — May 2026, today=13. */ function MiniCalendar() { const days = [ [26,27,28,29,30, 1, 2], [ 3, 4, 5, 6, 7, 8, 9], [10,11,12,13,14,15,16], [17,18,19,20,21,22,23], [24,25,26,27,28,29,30], ]; const HAS = new Set([2,5,8,15,19,23,28]); return (
May 2026‹ ›
{['S','M','T','W','T','F','S'].map((d,i) => {d})} {days.flat().map((n,i) => { const ri = Math.floor(i/7); const muted = (ri===0 && n>7); const today = (n===13 && !muted); const has = HAS.has(n) && !muted; const cls = [muted&&'muted', today&&'today', has&&'has'].filter(Boolean).join(' '); return {n}; })}
); } /* Standard toolbar */ function Toolbar({ withSidebar = true }) { return (
{withSidebar ? ( ) : null}

May 11 – 17, 2026

DayWeekMonthYear P
); } window.Icon = Icon; window.WEEK = WEEK; window.WeekHead = WeekHead; window.AllDayRow = AllDayRow; window.WeekBody = WeekBody; window.MiniCalendar = MiniCalendar; window.Toolbar = Toolbar;