#682 Replace The Position Card Stat Tiles With Four Status Circles - #685
cielbellerose wants to merge 6 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
cielbellerose
left a comment
There was a problem hiding this comment.
Code Review — Cycle 1 · needs revision
1 open — 1 🟡 Low (see inline)
Human feedback — apply alongside the Cycle 1 review findingsTwo design changes to 1. The circles must touch — no gap in the 2×2 gridDrop the grid gap to zero so adjacent circles are tangent and the cluster reads as one bubble cluster rather than four separate tiles. Two knock-on effects that must be handled, not ignored:
Each circle must still meet the ~44px touch-target minimum ( 2. Make the hover animation more "bubbly"The current
Constraints that still hold:
Verify the result at 375 / 768 / 1280 and in dark mode, per the plan's existing testing checklist. |
Revision — Cycle 1fixed R1-L1 · 78edb06 Also applied the human-feedback design changes to |
Human feedback — Cycle 2 colour changeOne change, requested by the ticket owner after reviewing the rendered circles. No other scope. Replace the "In progress" bucket's amber fill with violet, and put white text on itWhy: the current Target colour:
All four circles now carry white text uniformly. Scope this to the circles — do NOT repoint the global
|
Revision — Cycle 2 colour changein-progress circle fill moved to new |
cielbellerose
left a comment
There was a problem hiding this comment.
Code Review — Cycle 2 · needs revision
1 open — 1 🟡 Low (see inline)
cielbellerose
left a comment
There was a problem hiding this comment.
Code Review — Cycle 4 · approved
0 open — clean
Human feedback — Cycle 5: Total moves left of the circlesLayout-only change, requested by the ticket owner after seeing the approved version. The The changeCurrently the cluster is a vertical stack: the circle row, with
Alignment detail that mattersOn coarse-pointer devices the Suggested approach: make the outer wrapper Keep unchanged
Verify
|
The old cluster omitted reached_out/reviewing from its four tiles, so Total never matched their sum. The new buckets partition every status getPositionApplicationStats counts, so the circles always sum to Total. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Trim the oversize bucket comment (R1-L1) and, per the ticket owner's follow-up, make the stat circles tangent with a stacking bump on hover/focus and a springy overshoot easing. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Adds a --progress token (identical light/dark) so all four status circles carry AA-compliant white text; --warning is untouched since it still drives the callout/banner/date-line caution uses. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Replace the 2x2 filled grid with four smaller border-only circles in a horizontal row, per the Cycle 3 owner feedback. Border-only fill removes the need for text-on-color contrast, so in_progress reverts to the stock warning token and --progress/--progress-foreground are deleted entirely (resolves R3-M1) rather than replaced. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Total now sits in a min-h-11 flex-centered box beside the row so it stays aligned to the circles' centre line even when pointer-coarse labels render beneath them. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
9d75799 to
0f7e633
Compare
Revision — Cycle 5 |
cielbellerose
left a comment
There was a problem hiding this comment.
Code Review — Cycle 5 · approved
0 open — clean
Closes #682
Summary
reached_out/reviewing) with a 2×2 grid of four status circles plus aTotal: Nline — the new buckets partition every statusgetPositionApplicationStatscounts, so the circles now always sum to Total.PositionCardstays a server component; the new circles are a small'use client'leaf (PositionStatCircles) since Radix Tooltip requires it.Changes
lib/constants.ts— removedPOSITION_CARD_STAT_STATUSES(single consumer, being replaced); addedPOSITION_STAT_BUCKETS(Applied / In progress / Accepted / Rejected, ordered, each mapped to aBadgeVariant) andSTATUS_BADGE_VARIANT_TO_FILL(fill classes, sibling to the existingSTATUS_BADGE_VARIANT_TO_DOT).components/features/position-stat-circles.tsx— new'use client'leaf rendering the 2×2 circle grid, tooltips (category + count on hover/focus),sr-independentaria-labels, hover/focus scale animation (motion-reduce:transition-none), apointer-coarse:blockvisible label per circle for touch devices, and theTotal: Nline.components/features/position-card.tsx— removed the oldPositionStatClusterand its now-unused imports; rendersPositionStatCirclesin the existing right-column slot.tests/unit/constants.test.ts— added two invariants tostatus-set invariants: the bucket statuses union to every status butdraft/withdrawn, and the buckets are pairwise disjoint.docs/WORKFLOWS.md— updated PM-2's happy path to describe the four status circles and theTotal: Nline.Testing plan
/manage/positions. Confirm the four circle counts sum exactly toTotal: N, including a position with applications inreached_outorreviewing(the old cluster under-reported these)./manage/applications?positionId=<id>filtered by status.In progress — 4).0circles andTotal: 0, same footprint as a populated card./manage/positions/[id]/editfor an archived position and confirm the archived callout's unresolved-count line is unchanged (this page doesn't renderPositionCard).Automated checks
npm run prettier:check— passnpm run eslint:check— passnpm run tsc:check— passnpm run test:unit— 351 passed; 1 pre-existing failure (tests/unit/email-delivery-events.test.ts, missingDATABASE_URLin this sandbox) reproduces identically ondevbefore this change — unrelated to this PR.Notes
PositionApplicationStatsis unchanged./manage/positions/[id]/editnever renderedPositionCard(it only reads the archived-callout count), so that acceptance criterion is "verify unaffected" rather than a code change.