Handoff: Event Log (with EventLogItem)
Rewritten 2026-11-20 against v2.0.0-beta.21 to the lessons template (
docs/LESSONS.md, L1 to L11). Every prop, class and token below was checked againstEventLog.tsx,EventLogItem.tsx,event-log.css,event-log-item.cssand the stories. Nothing was checked by eye in a session, and the a11y panel was not run (see Accessibility).
What and why
A product often needs a log of events over time: deploys, checks, approvals, an agent joining and working. PDS has nothing for it, so teams draw the rail, the times and the status icons by hand. This proposal is two components: EventLogItem, one event or piece of work (an optional status icon, a label, quiet secondary text, a time, optional expandable detail and a slot for content under it), and Event Log, the list that owns list semantics, spacing and an optional rail joining the icons. EventLogItem is the former AgentStep, renamed and generalized (2026-10-16): an agent run is one region of a larger log, so the row is generic and the agent flavor is a boolean, isAgentic.
Dividers, a Chain of Thought or a Thinking State can sit between items. The full "agent joins an event log" composition is a recipe, Recipes/Event log with agent (proposals/EventLogWithAgent/), not a component.
- Figma / Jira: Figma page below under Preview; Jira none. Sources were designer screenshots (2026-10-12 and 2026-10-16): a deploy log with a "Zappy engaged" divider, an agent sandbox investigation, and a plain neutral log.
- Context:
context.md
Exploration and decisions
- Rename AgentStep to EventLogItem rather than keep a wrapper or build a second row. One row, with
isAgentic. Chain of Thought renders anEventLogfor its body. - Event Log is a thin list. It earns its place because the rail must run through the gap between items, and something has to own the
ol/lisemantics. Each child becomes a list item. - Rail is optional (
hasRail, defaultfalse). It joins only neighbouringEventLogItems, so a divider, a Chain of Thought or a Thinking State between items breaks it. It is drawn by each entry's::after, inemandlh, so it follows the item's text size. - The full event log is a recipe, not a component. Where the agent starts and stops, the divider wording and which entries are agentic are screen decisions.
isAgenticchanges the status icon color to the discovery foreground; errors stay critical.timesits at the end of the row; an expandable item with a time spans the full row and the chevron comes after the time.- Names:
EventLog/EventLogItemoverActivityLogandStep(Step implies a sequence). - Carried over from AgentStep (see
decisions.md): optionalstatus, configurableiconName, tool calls are items withdetail, achildrenslot under the row, Tag for file identifiers, detail text inherits the item's size. decisions.mdentries written before 2026-11-04 use the old names (Timeline, TimelineItem); read them as Event Log and Event Log Item. A dated note at the end ofdecisions.mdrecords the 2026-11-20 review.
API
Event Log
| Prop | Type | Default | Purpose |
|---|---|---|---|
children |
ReactNode |
none | What goes in the list. Each child becomes a list item. |
className |
string |
none | Additional class names. |
hasRail |
boolean |
false |
Draw a vertical rail joining neighbouring EventLogItems. Decorative. |
size |
'xs' | 's' |
'xs' |
Text size of the items, applied as a pds-copy-* class on the list. Items inherit it. |
Extends ComponentPropsWithoutRef<'ol'>. Exported type: EventLogSize.
EventLogItem
| Prop | Type | Default | Purpose |
|---|---|---|---|
children |
ReactNode |
none | Content under the item, always visible, lined up with the label when the item has an icon. |
className |
string |
none | Additional class names. |
detail |
ReactNode |
none | Expandable content. An item with detail becomes a native details/summary toggle. |
isAgentic |
boolean |
false |
The agent's own item: the status icon takes the agent color (errors stay critical). |
isQuiet |
boolean |
false |
Quiet (secondary) text color for secondary rows. |
iconName |
IconProps['iconName'] |
none | Replaces the status icon. The active spinner still shows; status color and hidden text still follow status. |
label |
ReactNode |
required | What happened or is happening. |
labelStrings |
Record<EventLogItemStatus, string> |
In progress, Done, Failed, Pending | Translatable screen-reader text for each status (keys active, done, error, pending). |
secondaryText |
ReactNode |
none | Quiet supporting text after the label (always pds-copy-xs). |
size |
'xs' | 's' |
none (inherits) | Text size, applied as a pds-copy-* class on the item. Unset inherits, for example from an EventLog's size. |
status |
'active' | 'done' | 'error' | 'pending' |
none | Where the item is at. Without it (and without iconName) there is no icon. |
time |
string |
none | When it happened, formatted by the consumer. Shown at the end of the row (always pds-copy-xs). |
timeDateTime |
string |
none | Machine-readable value for the time element. |
Extends ComponentPropsWithoutRef<'div'>. Exported types: EventLogItemSize, EventLogItemStatus.
Note: in EventLogItem.tsx the interface and destructuring put iconName after isQuiet; alphabetical order puts it before isAgentic. Fix it in the port (the table above follows the file as it is, except for this note). The old handoff table claimed alphabetical order and was wrong on this one prop.
Default icons by status (from the code): active is a Spinner (size='s', colored by --event-log-item-status-color), done is check, error is diamondExclamation, pending is circle.
Variants and states: with and without rail; the four statuses; isAgentic on and off; with and without time, secondary text, detail and content; items with a custom icon; isQuiet; sizes xs and s.
Story-only (L9, the engineer drops or rewrites these): the Progression story in EventLog.stories.tsx (a Play and Restart demo with ProgressionDemo, useEffect timers, a Button and SlotPlaceholder from proposals/_story-helpers/); SlotPlaceholder in the Slot and Default stories of EventLogItem.stories.tsx; the sample text in every story. None of it is component API.
Tokens used
From the CSS as it is now (event-log.css, event-log-item.css):
--pds-animation-transition-rotation--pds-border-radius-default--pds-border-width-default--pds-border-width-outline--pds-color-border-separator--pds-color-foreground-default--pds-color-foreground-default-secondary--pds-color-interactive-focus--pds-color-status-critical-foreground--pds-color-status-discovery-foreground--pds-color-status-success-foreground--pds-spacing-2xs--pds-spacing-5xs--pds-spacing-l--pds-spacing-s--pds-spacing-xs--pds-typography-ff-code
Removed from the old list because the CSS no longer uses them: --pds-typography-ff-default, --pds-typography-lh-m, --pds-typography-size-xs (text size now comes from the pds-copy-* classes).
No raw values. Custom variables (see custom.md): --event-log-gap, --event-log-item-status-color, --event-log-rail-color. Text size classes used: pds-copy-xs, pds-copy-s.
Impact
From impact.md: nothing reaches existing PDS components; everything is scoped to pds-event-log and pds-event-log-item. Proposals that build on this one: Chain of Thought (it renders EventLog and its rows are EventLogItem) and Agent Inbox (it uses the classes). Event log with agent and Chat with an agent compose it (docs/PORT-ORDER.md). The old handoff named only Chain of Thought. The rename's classes (pds-agent-step to pds-event-log-item, --agent-step-* to --event-log-item-*) reached Chain of Thought, which was updated. Port Event Log and EventLogItem before those.
Reused vs net-new
- Reused:
Icon(local wrapper inproposals/Icon/, which adds only icons this proposal does not use; every icon name used here is already in the package, see Target-version check),Spinner(local proposal, for the active status); in stories, the package'sButton,CodeBlock,Tag,FlexContainer. - Net-new:
EventLogandEventLogItem(classespds-event-log*andpds-event-log-item*, three custom variables, no raw values). Seecustom.md.
Accessibility
What the code does (read from the files; not tested with a screen reader):
EventLogis anol; each child is anli, so a screen reader announces the number of entries. A divider child keeps its ownseparatorrole.- The rail is a CSS pseudo-element, decorative, not announced.
- An item's status is visually-hidden text (
labelStrings, translatable) next to the icon. Foractive, the Spinner carrieslabelStrings.activeas its label instead. The status icon itself: whether the localIconwrapper hides it from assistive tech is not verified. timerenders atimeelement; passtimeDateTimefor a machine-readable value.- An item with
detailis a nativedetails/summary: Enter and Space toggle it, and the summary row takes a visible focus ring (--pds-color-interactive-focus,--pds-border-width-outline). With a time, the whole row is the click target. The chevron (angleDown, flips 180 degrees when open) is the same disclosure icon as the Chain of Thought summary and the PDS Panel Row. - Not announced twice: the status text is announced once with the label. Pass
labeltext that does not repeat the status ("Deployed", not "Done: deployed"). - Translatable strings:
labelStringsand the text the consumer passes (label,secondaryText,time). Nothing is hardcoded in the component except the English defaults oflabelStrings. - Keyboard: only
detailitems are focusable. Items with onlychildrenhave no tab stop. - a11y panel: not checked in a session. An earlier pass found no violations on the Event log with agent story in light; it has not been run on the other stories, nor in dark. Run it in both before the port.
- Contrast of the status colors (secondary foreground, discovery, critical, success) in light and dark: not checked.
Decisions and open questions
Each carries a recommended answer (the designer decides).
- Tone. Items take
isAgenticone by one. Should anEventLogGrouptint a region between two dividers? Recommendation: no, not for this release; add it only if the same region keeps being rebuilt. - Live tail.
ThinkingStateis a plain child today. ShouldEventLogItemget an active look instead? Recommendation: keepThinkingStateas the live last entry (it already owns shimmer and timer);status='active'on an item is for a step that has its own row. - Time column on narrow widths. The time is
flex-shrink: 0; a long label wraps. Recommendation: keep; confirm at narrow widths (not checked). - Collapsing old entries ("Show N earlier events") is not built. Recommendation: leave out; screens own it.
- Nesting depth. One level (a Chain of Thought inside the log) is tested; deeper is not. Recommendation: document one level.
- Custom icon on a done item replaces the check, so completion shows only by color and hidden text. Recommendation: keep as is; use
status='done'withouticonNamewhen completion matters. - Content when an item finishes. The consumer decides whether to collapse it. Recommendation: keep it the consumer's call.
- Divider styling. Closed: the dividers use the gradient
tone='agentic'(purple removed 2026-10-21, see../LabeledDivider/). - Not built: a larger, bolder item style, and a Chain of Thought header with a metadata line.
- Which one to use (2026-10-22): the Usage pages open with a TL;DR guide (Chain of Thought, Event Log or Timeline). Timeline now ships in the package (
src/components/lists/Timeline/, steps with a heading and a paragraph each); keep the guide, and have the engineer check its wording against the shipped Timeline page.
The convention-breaking choices are under "Expect to change".
Extension or new component
New components, not an extension. Checked against the package at beta.21:
TimelineandTimelineItem(shipped,src/components/lists/Timeline/): anolof cards, each with a title, subtitle and paragraph, one line running down the list. An Event Log row is one line with a status icon, a time and optional detail, with no heading or card, so extendingTimelineItemwould add a second layout to it. The Usage pages say not to mix the two in one list.StepList(lists/StepList, numberedstepsarray) andVerticalStepper(steppers/, an interactive wizard): neither has status icons,timeor a rail.StatusIndicator(status/) is one dot, not a log row.
Reuse still holds inside: Event Log items are plain div rows, the list is an ol, and the Chain of Thought body is an EventLog. The agent flavor (isAgentic) is an addition to EventLogItem behind a flag, with the neutral version and its stories untouched (L1).
Footprint
From the CSS (not measured, not checked by eye):
- The rail draws outside the entry box. It is an
::afteron each joined entry (.pds-event-log__entry--joined), positioned fromtop: calc(1lh / 2 + 0.5em + 5xs)tobottom: calc((1em - 1lh) / 2 + 5xs). When the line height is larger than1em, thebottomoffset is negative-leaning, so the line reaches into the next entry to meet the next icon. A parent that clips (overflow: hidden) at the list edge cuts nothing at the sides (it sits atinset-inline-start: calc(0.5em - 1px/2), inside the list), but the rail's position depends on the entry's padding and the text metrics. - The rail assumes an icon. It sits at
0.5emfrom the start, the center of a 1em icon. A joined item with nostatusand noiconNamehas no icon there, so the line would run under its label. Not checked; the stories give every joined item an icon. - It assumes the icon is 1em and centered on the first line. A different icon size, a label that wraps with a taller first line, or
sizeset differently on an item than on the list moves the line off the icon. - Gap is padding, not a flex gap. Each entry carries
padding-block-end: var(--event-log-gap)(default--pds-spacing-s) so the rail can cross it. Overriding--event-log-gapchanges both the spacing and the rail length. The last entry has none. - Joined detection is by element type.
EventLogmarks an entry joined when the child and the next one areEventLogItemelements (node.type === EventLogItem). A wrapped, memoised or re-exported item is not detected, and loses its rail silently. EventLogItemis adiv(block), full width of its parent. The expandable summary isinline-flex(only as wide as its content) unless the item has atime, when it isflexand spans the row.- The Chain of Thought and Thinking State children have no
--joinedclass, so the rail stops at them by design.
Dark mode and per-size values
All colors come from semantic tokens, with no per-theme override in either CSS file. Whether each token is tuned for dark is the package's; this proposal did not check or adjust it, and dark mode was not looked at in a session.
| Part | size='xs' (default) |
size='s' |
Light and dark |
|---|---|---|---|
| Label text size | pds-copy-xs |
pds-copy-s |
no per-theme override |
| Status icon and chevron box | 1em (follows the text size) |
1em (follows the text size) |
no per-theme override |
| Active spinner | Spinner size='s' (fixed, not tied to size) |
same | arc color from --event-log-item-status-color |
| Secondary text and time | pds-copy-xs |
pds-copy-xs (does not grow) |
--pds-color-foreground-default-secondary |
| Gap between entries | --pds-spacing-s |
same | single size |
| Row gap (icon, label, text) | --pds-spacing-xs |
same | single size |
| Content indent (when icon) | calc(1em + --pds-spacing-xs) |
same formula | single size |
| Detail indent and top margin | --pds-spacing-l and --pds-spacing-2xs |
same | single size |
| Rail width | --pds-border-width-default |
same | --event-log-rail-color = --pds-color-border-separator |
| Rail offsets | em, lh and --pds-spacing-5xs (see Footprint) |
same | single size |
| Status color: neutral | --pds-color-foreground-default-secondary |
same | token |
Status color: isAgentic |
--pds-color-status-discovery-foreground |
same | token |
Status color: error |
--pds-color-status-critical-foreground |
same | token (wins over isAgentic: --error comes later in the CSS) |
| Pending text and icon | --pds-color-foreground-default-secondary |
same | token |
| Quiet text | --pds-color-foreground-default-secondary |
same | token |
Diff counts (__added, __removed) |
success and critical foreground | same | tokens |
| Focus ring (summary) | --pds-border-width-outline solid --pds-color-interactive-focus |
same | token |
Open: the Spinner's fixed s size and the 1em status box both set a width and height; which one wins depends on CSS order and was not verified. Check the active item at xs and s before the port.
Expect to change
Each choice that breaks a toolkit convention, with a recommended answer. The designer has not decided these.
isAgenticname (L1, L2). Shipped components useisAgentwith a top-levelagentLabel(AvatarLabel,IdentityBlock);isAgenticis the unshipped Button convention. Recommendation:isAgent, to match what shipped. Leave the agent color as the only effect. NoagentLabelis needed here (the status text already says what happened); do not add one.labelStringsis a fullRecord(L2, L3). Passing one translated string means passing all four. The default object is a module constant, so it is not recreated per render.VerticalStepperalso takes a full object (labelStringswithstep,completed,hasError), so this follows precedent. Recommendation: acceptPartial<Record<EventLogItemStatus, string>>merged over the defaults. It is a top-level translatable prop, which is right (L3).- Child sniffing for the rail (L2).
EventLogdecides--joinedwithnode.type === EventLogItem. Recommendation: keep it and document "a wrapped item loses its rail", or have the engineer replace it with a CSS rule on adjacent entries; either is fine. sizeon both components (L2, L11). Event Log defaults toxsand appliespds-copy-xseven when unset; the item'ssizehas no default and wins over the list's. Two places to set one thing. Recommendation: keep both (items are used standalone), state the precedence in TSDoc, and keep one default (xs) on the list.isQuietandiconNameplacement (L2).iconNameis out of alphabetical order. Recommendation: reorder.timeis a pre-formattedstringwith a separatetimeDateTime(L11). Content of its own kind, not a position value, so the shape is right. Recommendation: keep.- No knobs with one right value found (L2).
hasRailandisQuietboth change the look and default off. Recommendation: keep. ReactNodelabelandsecondaryText. Consumers pass<strong>and<code>inside them. Recommendation: keep, and document that code goes in<code>.- Types exported from the component file (
EventLogSize,EventLogItemSize,EventLogItemStatus). Recommendation: reuse one shared text-size type if the toolkit has one; the engineer picks.
Target-version check
Checked 2026-11-20 against .pds-reference/src at v2.0.0-beta.21 (CHANGELOG.mdx has no entry for Event Log, Event Log Item, isAgentic or a rail).
| Item | Exists at beta.21? |
|---|---|
EventLog, EventLogItem, classes pds-event-log*, pds-event-log-item* |
no (no files or matches) |
isAgentic prop anywhere |
no. isAgent exists on AvatarLabel (and IdentityBlock) |
Icons check, circle, diamondExclamation, angleDown, codeBranch, circleInfo, zappy |
yes, all in icon-registry.ts. None is new |
Spinner with color (any CSS color or var()), label, size='s' |
yes in the package. The Spinner proposal adds color='agentic' and hasAvatar; EventLogItem uses neither, so the port does not need the Spinner proposal for the active status. The old note said it did |
Timeline, TimelineItem (lists) |
yes, shipped; see Extension or new component |
ThinkingState (a story child) |
yes, shipped |
Tag, CodeBlock, FlexContainer, Button (story only) |
yes |
pds-copy-xs, pds-copy-s classes |
yes (utilities/typography/typography-styles.css) |
lh CSS unit |
used in the package already (Table, ComparisonList, Timeline CSS) |
Browser support policy for lh |
not verified (no browserslist entry found in the reference package.json) |
visually-hidden class |
not verified in the reference |
Port notes
- New components, likely
src/components/lists/or its ownevent-logfolder holding both (the engineer's call). Usenpm run generate:componentfor each, then copy the files over. - Swap the local
Iconwrapper andmergeClassesfor the real ones. For the active status, use the packageSpinnerwithcolor,labelandsize='s'; no Spinner port is needed for this. lhis already used by the package CSS, so it is probably within support; not verified against a stated browser policy.- Port Event Log and EventLogItem before Chain of Thought and Agent Inbox, which depend on them.
- AgentStep never shipped, so there is nothing to migrate in
pds-toolkit-react. - Fix on the way:
iconNameorder (Expect to change 5); drop the story-only pieces listed under API. - Docs: the Usage and Accessibility sections are written in
EventLog.mdxandEventLogItem.mdx; the engineer should not have to write them.
Preview
npm run storybook, then Component Proposals/Event Log/Event Log and Component Proposals/Event Log/Event Log Item. The composition is under Recipes/Event log with agent.
Figma: https://www.figma.com/design/AMGWJbraJoi2PKWnxo29Ah/PDS-Proposals?node-id=306-43