diff --git a/index-cal.js b/index-cal.js index dbf1bb5..d7191a8 100644 --- a/index-cal.js +++ b/index-cal.js @@ -19,15 +19,19 @@ function drawEventList(events) { weekday: 'long', month: "numeric", day: "numeric", + }; + const timeOptions = { hour: "numeric", minute: "numeric", }; const ul = document.createElement('ul'); events.forEach(event => { const li = document.createElement('li'); - const dateStr = `${event.start.toLocaleString('en-US', dateOptions)}`.toLocaleLowerCase(); + const dateStr = `${event.start.toLocaleDateString('en-US', dateOptions)}`.toLocaleLowerCase(); + const timeStr = `${event.start.toLocaleTimeString('en-US', timeOptions)}–${event.end.toLocaleTimeString('en-US', timeOptions)}`.toLocaleLowerCase(); const recurrenceStr = event.recurrence ? ` (${event.recurrence})` : ''; - li.textContent = `${event.summary}: ${dateStr}${recurrenceStr}`; + const descriptionStr = event.description ? `
${event.description}` : ''; + li.innerHTML = `${event.summary}${descriptionStr}
${dateStr}${recurrenceStr}
${timeStr}
`; ul.appendChild(li); }); return ul; @@ -93,7 +97,9 @@ function getUpcomingEvents(vcalendar, numEvents = 10) { if (next.compare(sixHoursAgo) >= 0) { upcomingEvents.push({ summary: icalEvent.summary, + description: icalEvent.description, start: next.toJSDate(), + end: icalEvent.endDate.toJSDate(), recurrence: describeRecurrence(icalEvent) }); break; @@ -104,7 +110,9 @@ function getUpcomingEvents(vcalendar, numEvents = 10) { if (eventStart.compare(sixHoursAgo) >= 0) { upcomingEvents.push({ summary: icalEvent.summary, - start: eventStart.toJSDate() + description: icalEvent.description, + start: eventStart.toJSDate(), + end: icalEvent.endDate.toJSDate(), }); } } diff --git a/index.html b/index.html index 4a605a5..635e224 100644 --- a/index.html +++ b/index.html @@ -6,25 +6,33 @@ + -

/dev/hack -$ -

-

seattle hackerspace

-

- 4534½ University Way NE, Seattle, WA 98105-4511 - (getting here) -

-

calendar

-
- -
-

contact

- -һëⅼⅼо@devhack.net + - + + \ No newline at end of file diff --git a/style.css b/style.css index 893f96d..61f1fb4 100644 --- a/style.css +++ b/style.css @@ -6,6 +6,11 @@ body { border: 10px red; font-size: 125%; } + +.secondary { + color: #00b300; +} + input[type="text"] { background-color: inherit; color: inherit; @@ -14,16 +19,24 @@ input[type="text"] { font: inherit; caret-shape: block; } -h1,p { + +h1, .block { margin: 40px 0px; } -a { - color: cyan; +p { + margin: 0.5em 0; } -a:visited { - color: mediumaquamarine; + +a, a:visited { + color: #84d7ba; + text-decoration: none; } + +a:hover { + color: #d784a1; + } + dt::before { content: ">"; padding-right: 0.5em; @@ -33,19 +46,8 @@ ul { list-style-type: '- '; } -.address-hide { - opacity: 0.5; -} - -@media only screen and (min-width: 768px) { - /* For desktop, only show the address on hover. For mobile devices let's not - make people go through that. */ - .address-hide { - display: none; - } -} - -.address:hover .address-hide, -.address-hide:hover .address-hide { - display: inline; +.small { + font-style: normal; + font-weight: normal; + font-size: 50%; } \ No newline at end of file