export const title = "Activity feed components"
export const description = "Powerful and customizable React activity feed components built for modern applications and websites. These activity feed components are built using React Aria and styled with Tailwind CSS."
import * as Demos from "@/components/application/activity-feed/activity-feed.story.tsx";
## Installation
Some activity feeds components depend on other components to function properly. Before using them, make sure to add the required components via CLI.
Use the following command to install them:
```bash
npx untitledui@latest add activity-feed
```
Copy the files below into your project:
Great! Now you can start using the activity feed component in your project by just copy/pasting our examples below.
## Activity feed examples
Below are examples and variations of this activity feeds component:
### Activity feed divided {{ tocOnly:true }}
Copy the files below into your project:
Great! Now you can start using the activity feed components in your project by just copy/pasting our examples below.
### Activity feed connected {{ tocOnly:true }}
### Activity feed spaced {{ tocOnly:true }}
### Messages divided {{ tocOnly:true }}
### Messages connected {{ tocOnly:true }}
### Messages spaced {{ tocOnly:true }}
## API reference
`.",
},
{
question: "How do I draw the connecting line between activity feed items?",
answer: "Pass `connector={true}` to `FeedItem` to render the dotted vertical line beneath its avatar. The connected examples compute it per item as `connector={index !== feed.length - 1}` so the last entry has no trailing line, while the divided and spaced examples pass `connector={false}`.",
},
{
question: "What sizes are available for activity feed items?",
answer: "`FeedItem` accepts a `size` prop of `\"sm\"` or `\"md\"`, and it defaults to `\"md\"`. The size drives the avatar, rendering an `\"sm\"` avatar for `\"sm\"` and an `\"md\"` avatar otherwise.",
},
{
question: "How do I show a file attachment in a feed item?",
answer: "Pass an `attachment` object with `name`, `size` and `type`, where `type` is one of `\"jpg\"`, `\"txt\"`, `\"pdf\"` or `\"mp4\"`. The matching icon is rendered with `FileIcon` from `@untitledui/file-icons`, with separate light and dark variants.",
},
{
question: "How do I mark an activity as unread?",
answer: "Set `unseen` to `true` on the item. This renders a small success-colored dot in the top-right corner of that feed item.",
},
{
question: "Can I attach labels or tags to a feed item?",
answer: "Yes. Pass a `labels` array of `{ name, color }` objects, where `color` is any `BadgeColors` value. Each label renders as a `Badge` at `size=\"sm\"` inside an `