{
 "id": "calendar-agenda",
 "name": "Calendar day agenda",
 "purpose": "One day's schedule: a date header with previous, today and next, an all-day event, and timed events on an hour rail with overlaps side by side and a now line.",
 "use_when": [
  "for one day's events in a scheduling or CRM tool",
  "a side panel that shows the rest of today next to other work, with what is happening now marked"
 ],
 "avoid_when": [
  "a week or month at a glance: this day view does not stretch to it; build a week grid instead",
  "a short list of upcoming items without times on a rail: use activity-feed"
 ],
 "type": "data",
 "style": "quiet",
 "width": "medium",
 "tags": {
  "audience": "work",
  "industries": [
   "productivity",
   "saas",
   "any"
  ],
  "keywords": [
   "calendar",
   "agenda",
   "schedule",
   "day view",
   "events"
  ]
 },
 "root": ".odl-calendar-agenda",
 "parts": [
  {
   "name": "day_num",
   "selector": ".odl-day-num",
   "what": "the day of the month in a tile; hidden in a narrow box",
   "slot": "number"
  },
  {
   "name": "date",
   "selector": "h3",
   "what": "the weekday and date, the one heading",
   "slot": "text"
  },
  {
   "name": "summary",
   "selector": ".odl-date p",
   "what": "how many events and how much time is booked",
   "slot": "text"
  },
  {
   "name": "nav",
   "selector": ".odl-nav button",
   "what": "previous day, Today and next day",
   "slot": "action"
  },
  {
   "name": "all_day",
   "selector": ".odl-allday .odl-event",
   "what": "the all-day event, a link with its title and a short note",
   "slot": "list"
  },
  {
   "name": "rail",
   "selector": ".odl-rail li",
   "what": "the hour labels down the left side",
   "slot": "list"
  },
  {
   "name": "events",
   "selector": ".odl-grid .odl-event",
   "what": "one timed event, a link with title, time, place and optional attendee photos; two overlapping events sit side by side",
   "slot": "list"
  },
  {
   "name": "attendees",
   "selector": ".odl-people",
   "what": "small photos and names of who is invited, inside an event",
   "slot": "media"
  },
  {
   "name": "now",
   "selector": ".odl-now",
   "what": "the line marking the current time, with its label",
   "slot": "text"
  }
 ],
 "data": {
  "type": "object",
  "required": [
   "date",
   "events"
  ],
  "properties": {
   "day_num": {
    "type": "number",
    "part": "day_num"
   },
   "date": {
    "type": "string",
    "maxLength": 28,
    "part": "date"
   },
   "summary": {
    "type": "string",
    "maxLength": 40,
    "part": "summary"
   },
   "all_day": {
    "type": "array",
    "minItems": 0,
    "maxItems": 1,
    "part": "all_day",
    "items": {
     "type": "object",
     "required": [
      "title"
     ],
     "properties": {
      "title": {
       "type": "string",
       "maxLength": 28
      },
      "note": {
       "type": "string",
       "maxLength": 24
      },
      "tone": {
       "enum": [
        "accent",
        "info",
        "warn",
        "neutral"
       ]
      },
      "href": {
       "type": "string",
       "maxLength": 200
      }
     }
    }
   },
   "rail_start": {
    "type": "string",
    "maxLength": 5,
    "part": "rail"
   },
   "events": {
    "type": "array",
    "minItems": 1,
    "maxItems": 8,
    "part": "events",
    "items": {
     "type": "object",
     "required": [
      "title",
      "start",
      "end"
     ],
     "properties": {
      "title": {
       "type": "string",
       "maxLength": 32
      },
      "start": {
       "type": "string",
       "maxLength": 5
      },
      "end": {
       "type": "string",
       "maxLength": 5
      },
      "place": {
       "type": "string",
       "maxLength": 28
      },
      "tone": {
       "enum": [
        "accent",
        "info",
        "warn",
        "neutral"
       ]
      },
      "past": {
       "type": "boolean"
      },
      "column": {
       "enum": [
        "full",
        "left",
        "right"
       ]
      },
      "href": {
       "type": "string",
       "maxLength": 200
      },
      "people": {
       "type": "object",
       "part": "attendees",
       "properties": {
        "photos": {
         "type": "array",
         "minItems": 0,
         "maxItems": 3,
         "items": {
          "type": "string",
          "maxLength": 300
         }
        },
        "names": {
         "type": "string",
         "maxLength": 48
        }
       }
      },
      "people_names": {
       "type": "string",
       "maxLength": 80
      }
     }
    }
   },
   "now": {
    "type": "string",
    "maxLength": 5,
    "part": "now"
   }
  }
 },
 "states": {
  "shown": [
   "hover",
   "focus",
   "past",
   "now",
   "overlapping",
   "all day"
  ],
  "edge": {
   "empty": {
    "status": "handled",
    "evidence": "data-od-list",
    "how": "the Smart UI renderer puts one plain 'Nothing to show yet.' line in an empty list"
   },
   "loading": {
    "status": "handled",
    "evidence": "data-od-slot",
    "how": "the Smart UI renderer draws each marked slot as a quiet block of its size while the data arrives; the static file shows the filled part"
   },
   "error": {
    "status": "not_built",
    "how": "if the day fails to load, keep the header and show an alert-banners line under it with a retry"
   },
   "disabled": {
    "status": "not_built",
    "how": "set disabled on the previous and next buttons at the ends of the range the tool allows"
   },
   "overflow": {
    "status": "handled",
    "how": "in a narrow box the rail and padding shrink, and side-by-side events drop their place and use smaller titles",
    "evidence": ".odl-event.is-half .odl-place { display: none; }"
   },
   "long_text": {
    "status": "not_built",
    "how": "the event box is a fixed number of quarter-hour rows, so clamp each event title to one or two lines with an ellipsis"
   },
   "missing_image": {
    "status": "not_built",
    "how": "a photo that fails to load shows the browser's broken image"
   }
  }
 },
 "tokens": [
  "--ds-border-width-default",
  "--ds-border-width-emphasis",
  "--ds-border-width-selected",
  "--ds-color-bg-accent-subtle",
  "--ds-color-bg-accent-subtle-hover",
  "--ds-color-bg-danger-bold",
  "--ds-color-bg-info-subtle",
  "--ds-color-bg-neutral-subtle",
  "--ds-color-bg-neutral-subtle-hover",
  "--ds-color-bg-warning-subtle",
  "--ds-color-border-accent",
  "--ds-color-border-danger",
  "--ds-color-border-default",
  "--ds-color-border-focus",
  "--ds-color-border-info",
  "--ds-color-border-separator",
  "--ds-color-border-strong",
  "--ds-color-border-subtle",
  "--ds-color-border-warning",
  "--ds-color-surface-raised",
  "--ds-color-surface-sunken",
  "--ds-color-text-accent",
  "--ds-color-text-on-danger",
  "--ds-color-text-primary",
  "--ds-color-text-secondary",
  "--ds-color-text-tertiary",
  "--ds-elevation-raised",
  "--ds-focus-ring-width",
  "--ds-font-weight-heading",
  "--ds-font-weight-label",
  "--ds-icon-stroke-md",
  "--ds-motion-duration-short",
  "--ds-motion-easing-standard",
  "--ds-radius-container",
  "--ds-radius-control",
  "--ds-radius-detail",
  "--ds-radius-full",
  "--ds-radius-person",
  "--ds-size-control-md",
  "--ds-size-control-sm",
  "--ds-size-icon-md",
  "--ds-size-icon-sm",
  "--ds-size-target-min",
  "--ds-space-2",
  "--ds-space-24",
  "--ds-space-4",
  "--ds-space-8",
  "--ds-space-inline-md",
  "--ds-space-inline-sm",
  "--ds-space-inline-xs",
  "--ds-space-inset-lg",
  "--ds-space-inset-md",
  "--ds-space-inset-sm",
  "--ds-space-inset-xl",
  "--ds-space-inset-xs",
  "--ds-space-stack-xs",
  "--ds-text-body-md",
  "--ds-text-body-sm",
  "--ds-text-label-md",
  "--ds-text-label-sm",
  "--ds-text-title-md"
 ],
 "a11y": {
  "summary": "Events are links in a labelled list with the title, time and place in their text; the hour rail is hidden from screen readers and the now line has a text label.",
  "roles": [
   "img",
   "list",
   "listitem",
   "region"
  ],
  "keyboard": [
   "Tab reaches the previous day, Today and next day buttons, then the all-day event and each timed event in order",
   "Enter on an event follows its link",
   "Enter or Space presses a day button, but the file wires no action to them"
  ],
  "controls": {
   "button": 3,
   "input": 0,
   "link": 6,
   "select": 0,
   "textarea": 0,
   "summary": 0
  },
  "focus_visible": true,
  "reduced_motion": true,
  "min_target": true
 },
 "files": {
  "html": "components/calendar-agenda/component.html",
  "bytes": 14950,
  "script": false
 },
 "source": null,
 "photos": 2,
 "urls": {
  "html": "https://opendesigner.dev/library/calendar-agenda.html",
  "json": "https://opendesigner.dev/library/calendar-agenda.json",
  "page": "https://opendesigner.dev/library/calendar-agenda/"
 },
 "get": {
  "curl": "curl -fsSLo calendar-agenda.html https://opendesigner.dev/library/calendar-agenda.html",
  "opendesigner": "python3 path/to/skills/opendesigner/scripts/library.py add calendar-agenda --from https://opendesigner.dev",
  "prompt": "Add the OpenDesigner component calendar-agenda to this project: https://opendesigner.dev/library/calendar-agenda.html. Keep its markup and states; map its --ds-* variables to my tokens."
 }
}
