shadcn.io is not affiliated with official shadcn/ui
Centered Activity Feed Hero Block for React
A split hero with a live pill, a headline and two actions beside a ruled feed of recent activity, each row with an avatar, a name, an action and how long ago.
Installation
Overview
A split hero with a feed of recent activity beside the copy, for a fictional team planning tool. Between solid page rails, an announcement pill with a pulsing Live dot links to your live stats on the start side, then a headline, one sentence and two calls to action: a ShineButton that sweeps a light across it on hover, and an outline Button, both links. Across a solid divider, the end side is titled Recent activity and lists seven people and what they just did, from publishing a roadmap to creating a sprint board, each row ruled from the next, with an initials avatar and a relative time. The header's rule meets the divider and the right rail in + marks, and the list fades out at its foot. It's built from Announcement, Badge, Status Pulse Text, Avatar, Shine Button and Button, with a CSS entrance that brings the rows in one after another and stays still under reduced motion. For collaboration tools, developer platforms, marketplaces and any product where visible momentum makes the case that others are already on board.
FAQ
How do I show my own activity in the feed?
Edit ACTIVITIES at the top of the file. Each row has a name, the initials for its avatar, an action that reads after the name, and a time. Keep the times relative (2 min ago) so the feed never shows a date that has passed, keep names to a first name and an initial for privacy, and keep six or seven rows: the feed is social proof, not a log.
How do I connect the feed to real events?
Render the rows from your own data instead of the constant: fetch the latest events on the server, or subscribe to them on the client and put each new one at the top of the list, keeping the last seven. Compute each relative time from the event's timestamp when you render it.
On the client, keep the rows in useState and update them from a WebSocket or Server-Sent Events listener set up in useEffect.
If rows arrive on their own, don't make the list a live region: a screen reader would interrupt the visitor with every event.
How do screen readers read the feed?
Recent activity is an h2 under the page's h1, and the rows are a plain list, so a screen reader announces seven items and reads each one as a sentence: Sarah M. published the Q3 roadmap, Just now. The avatars are hidden, since the name beside them says the same, and the pill is one link whose name is its whole text. The pulsing dot is decoration: the word Live carries the meaning.
What moves, and what happens with reduced motion?
The pill, the headline, the sentence and the buttons fade and rise in one after another, then the seven rows follow, 60 ms apart. The Live dot sends out a soft ring every two seconds. It's all CSS, with no animation library. With reduced motion, everything is in place from the first frame and the dot stays still.
How does the feed fit on a phone?
The two sides stack below lg: the copy first, with both actions on the first screen, then the feed under a rule that runs the width of the page column. Each row keeps its avatar, its sentence and its time on one line: a long action shortens with an ellipsis so the time stays at the end of the row, down to 320px.
When should I use an activity feed instead of customer logos?
Use the activity feed when people use your product often and in plain sight, with sign-ups, deploys or purchases every few minutes: recency says the product is alive. Use customer logos or testimonials when you sell to fewer, larger customers, where who trusts you matters more than how many.
Related
- Pro
Centered Online Pulse Hero
Stats and live dataA centered showcase hero led by a live presence pill, a pulsing dot and a count of the people online, with two actions and a live project board in a band below.
- Pro
Left-Aligned Social Proof Bar Hero
Logos and social proofA compact start-aligned hero closed by a three-cell social proof bar on its own rule: an avatar stack with the user count, a five-star rating with the review count and a compliance mark.
- Pro
Avatar Stack Side Rail Hero
Logos and social proofA compact hero for a community: a headline, a Shine Button and a second action beside a side rail of proof: a stack of member avatars over a line of social proof, then three stats in ruled rows.
- Pro
Split Layout Notification Stack Hero
Stats and live dataA reverse split hero for a notifications product: a panel flush to the start rail with a stack of notification cards, then a divider, the headline, three checks and a Shine Button.
- Pro
Hero With Stats
Stats and live dataA split hero with a headline, a Shine Button and a second action beside a rail of four key figures on shared hairlines, each with its period and a small bar trend.
- Pro
Centered Star Rating Hero
TestimonialsA showcase centered hero led by its review score, with five stars and the average, a Shine Button, review-site badges and three reviews below in cells whose hairlines overshoot their corners.