Patterns

Activity feed

Decisions waiting on a person. list (in a card) · cards (tone edge + icon tile) · compact (sidebar, phone).

  • Gate 2 offline

    6 min

    No heartbeat for 6 minutes

  • Cash shift unbalanced

    22:10

    ৳350 short at Banani

  • 3 monthly parkers to approve

    1 h

    Night pass · Gulshan

Import#

Everything comes from the package root. The example above uses:

your-component.tsx
import { ActivityFeed, Button, Card, Segmented } from "@waveinno/ui";

Props#

Read from the source of this version, so they match the code exactly.

<ActivityFeed>

src/components/patterns/activity-feed.tsx
PropTypeDefaultDescription
itemsrequiredFeedItem[]—
variant"list" | "cards" | "compact""list"
classNamestring—

<Button>

src/components/ui/button.tsx
PropTypeDefaultDescription
asChildbooleanfalse
loadingboolean—

Also takes ButtonHTMLAttributes<HTMLButtonElement> & VariantProps<typeof buttonVariants>.

<Card>

src/components/ui/card.tsx
PropTypeDefaultDescription
interactiveboolean—

Also takes HTMLAttributes<HTMLDivElement>.

<Segmented>

src/components/ui/segmented.tsx
PropTypeDefaultDescription
valuerequiredT—
onChangerequired(v: T) => void—
optionsrequiredSegmentedOption<T>[]—
classNamestring—
ariaLabelstring—
variantkeyof typeof TRACK"pill"
sizekeyof typeof SIZES"sm"
fullWidthbooleanfalseStretch to the container, options sharing the width equally.

Install#

If the project does not have the package yet, add it, then follow the setup for Next.js or Vite once.

$ npm install @waveinno/ui