Add Timeline Issues Features stories (Phase 2 Issues surface)#8070
Draft
janmaarten-a11y wants to merge 8 commits into
Draft
Add Timeline Issues Features stories (Phase 2 Issues surface)#8070janmaarten-a11y wants to merge 8 commits into
janmaarten-a11y wants to merge 8 commits into
Conversation
Recreate GitHub's live Issue timeline events as Storybook Features stories using the Primer Timeline component. Covers 9 event groups (59 variants): Closed, State, References, Duplicates, Moderation, Issue Types, Issue Hierarchy, Dependencies, Issue Fields. Part of github/primer#6663. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
…tent Move each variant's story caption out of Timeline.Body into an <h3> heading above its own <Timeline>, so the event row (badge + inline avatar + body) renders undistorted. Remove invented borders/cards from the secondary issue-reference lists and commit-reference rows to match the plain, borderless live GitHub rendering. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…nts/Issues Match live ReferencedEventInner: commit-reference message is default weight/color (drop semibold). Retitle story to Components/Timeline/Events/Issues to nest by surface; filename unchanged so the *.features.stories.tsx docs convention is preserved. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
These stories are intentionally not wired into components-json / primer.style docs; individual events are not consumer-facing components. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Live ReferencedEventInner renders the message headline via .commitHashLink (muted + monospace), not default-color sans-serif. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
10 tasks
Adds the ProjectV2 shared timeline events (added/removed/status-changed) as the Issue-surface version, sourced from live github-ui timeline-items. Documents the PR (ERB) divergence inline for the future PR surface. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…project' Live ClosedEvent.tsx renders the project closer TableIcon at default color (not muted). Reuse .ProjectRefIcon and drop the now-unused .ProjectIcon. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add 7 shared timeline event groups (Issue versions) to the Issues features story file: Labels, Title, Milestones, Assignments, Lock/Unlock, Comment deleted, and Cross-references. Sourced from the live github-ui React timeline-items components; PR (ERB) divergences documented inline. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
13 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds Storybook Features stories that recreate GitHub's live Issue timeline events using the Primer React
Timelinecomponent and its compositional slots. This is the Issues surface of Phase 2 of the Timeline events effort (github/primer#6663). The Pull Request, Shared, and Dependabot surfaces follow separately (Dependabot is in #8071).All examples live in a single new file,
Timeline.issues.features.stories.tsx(+ a.module.css), exported under the titleComponents/Timeline/Events/Issues— one story export per event group.The 9 event groups (59 variants total)
EventClosedEventStateEventReferencesEventDuplicatesEventModerationEventIssueTypesEventIssueHierarchyEventDependenciesEventIssueFieldsSource of truth
Each event was recreated from the live
github-uiReact implementation (packages/timeline-items) as the canonical source, cross-checked against the Figma timeline audit and verified visually against the Figma components. Where the audit and live code disagreed — for example the Closed-event badge icons (CheckCircle/CircleSlash, not the audit'sIssueClosed/Skip) and the Unlinked-PR badge icon — live code won. In each case we confirmed the live render path is actually reached (present in the timeline item map, not feature-flagged-off or superseded by a newer component) before trusting it.Slots used (Phase 1 slots)
Timeline.Body— a 20px avatar + bold link, matching how the livegithub-uievents render the actor. These badge-row events deliberately do not use theTimeline.Avatargutter slot (github/primer#6677); that 40px gutter slot is reserved for comment-style events, which aren't part of this Issue-only set.Timeline.Actions(right-controls slot, github/primer#6678) for the Duplicates "Undo" button — the only right-aligned control in the Issue event set. Everything else (inline commit SHAs, PR-state icons,#numbers) is part of the sentence body text in the live render, so it correctly stays inline inTimeline.Body, not inTimeline.Actions.Scope & conventions
FeatureFlagsdecorator enablingprimer_react_timeline_list_semantics(the future-state<ol>/<li>DOM, so the stories won't need re-authoring when that flag becomes the default; refs Timeline: Use list semantics for screen reader navigation #7910).Timeline.docs.jsonorbuild.ts) — individual timeline events are not consumer-facing components, and the primer.style Timeline page reflects the baseTimelinecomponent's own stories. Any docs-site representation is a Phase 3 consideration.data-*filtering taxonomy (github/primer#6663) is intentionally deferred; a single documented hook location in the file header marks where it'll attach perTimeline.Item.Changelog
New
Timeline.issues.features.stories.tsxandTimeline.issues.features.stories.module.css— Storybook Features stories recreating the Issue timeline events (9 groups, 59 variants).Changed
Removed
Rollout strategy
Stories-only change — no consumer-facing package code is added or modified, so no changeset is needed (the
skip changesetlabel is applied).Testing & Reviewing
@primer/doc-genbaseline error inscript/components-json/build.tsis unchanged).Merge checklist