Add UI to edit and display event notices

Add a warning like display of event notices to the event card and the
event slot card and indicate in the timesheet that an event has a
notice.  Also includes the input controls needed to edit the notice.
This commit is contained in:
Hornwitser 2025-09-06 19:25:20 +02:00
parent adeef4f629
commit 5898a46a1b
5 changed files with 70 additions and 2 deletions

View file

@ -43,6 +43,7 @@ let eventId = 1;
const events = [
{
name: "Arcade",
notice: "No food or drinks allowed!\n\nClosed drinking containers are okay.",
description: "Play retro games!\n\nWe have anything from C64 to PS5.",
slots: [
"d1 12:00 4h clubhouse",
@ -339,10 +340,11 @@ export function generateDemoSchedule(): ApiSchedule {
id: 111,
updatedAt: toIso(toDate(origin, "d-2", "10:01")),
events: events.map(
({ id, name, crew, description, slots }) => ({
({ id, name, crew, notice, description, slots }) => ({
id,
name,
crew,
notice,
description,
interested: eventCounts.get(id),
slots: slots.map(shorthand => toSlot(origin, shorthand, slotCounts, eventSlotIdToAssigned)),