PixelDosa UI

Use Case Explorer

Help visitors explore how a product fits different roles or workflows.

Built around the work you do

Ship with shared context.

Connect customer needs to the work your team plans and delivers.

  • Prioritize requests together
  • Keep decisions beside the work
  • Review outcomes after launch

Installation

bash
npx shadcn@latest add @pixeldosa/use-case-explorer

Requires `cn` at `@/lib/utils`. Provide short labels and outcome copy for each audience; all case content is local and available without a network request.

Usage

<UseCaseExplorer
  title="Built around the work you do"
  cases={[
    {
      id: "product",
      label: "Product teams",
      title: "Ship with shared context.",
      description: "Connect customer needs to delivered work.",
      outcomes: ["Prioritize requests", "Review outcomes"],
    },
  ]}
/>

Props

PropTypeDefaultDescription
titlestring—Section heading.
casesUseCase[]—Cases with id, label, title, description, and outcome strings.
layout"cards" | "compact""cards"Spacing preset.
classNamestring—Extra section classes.

why it's built this way

Engineering Notes

Uses an explicit audience selector and a single associated content panel instead of rendering every persona as a separate long card. This makes the audience choice the organizing action and keeps each benefit list tied to its intended visitor. Native buttons and aria-pressed avoid a bespoke tab system while preserving standard keyboard activation.

how it moves, and when it doesn't

Motion Notes

Changing audience replaces the panel content immediately with no slide or fade, preventing motion from obscuring the newly selected audience's message. A visible pressed state and clear labels communicate selection. Reduced-motion settings require no behavior change because the interaction has no animation.