Star 历史趋势
数据来源: GitHub API · 生成自 Stargazers.cn
README.md

Detent UI: animated React components for AI apps and interactive charts

Detent UI

Animated React components for AI apps, agent interfaces and interactive charts.
Install with the shadcn CLI. The source is yours to change.

MIT licence shadcn registry React 19 Tailwind CSS v4 TypeScript GitHub stars

Website · Components · Blocks · Docs · llms.txt · Pro


Detent UI is a React component library for products built on AI: prompt boxes, model pickers, diff review, voice notes, explained metrics and charts you can click into. Every piece ships with its motion, its states (loading, empty, error, where they apply) and reduced-motion support already worked out. You install it with the shadcn CLI, so the TypeScript source lands in your project and you own it.

  • 21 free components and 5 free blocks, MIT licensed
  • Built for React 19, Tailwind CSS v4 and Next.js (App Router), animated with Motion
  • Styled by your shadcn theme, light and dark
  • Readable by coding agents: llms.txt and a markdown copy of every page
Baseline chart: interactive React line chart where any day becomes the baselineMetric explainer: React KPI card with the change in words and its drivers
Prompt box: AI chat input component for ReactDiff review: code diff viewer for reviewing AI agent changes
Outlook chart: forecast chart with a confidence bandModel and effort: AI model picker with reasoning effort and cost

Quick start

Pick a component on detentui.com/components and run its command:

npx shadcn@latest add https://detentui.com/r/popup

The source lands in components/detent. The first install also adds the Detent theme, and anything a piece depends on, such as motion, comes with it. Swap the name for any piece in the tables below: npx shadcn@latest add https://detentui.com/r/<name>.

Requirements: React 19 and Tailwind CSS v4. Next.js is what we test on; Vite with React works the same way.

Wrap your app once so the motion calms down for people who have asked their device for less of it:

import { MotionConfig } from 'motion/react'

export default function RootLayout({ children }: { children: React.ReactNode }) {
  return (
    <html lang="en">
      <body>
        <MotionConfig reducedMotion="user">{children}</MotionConfig>
      </body>
    </html>
  )
}

Free components

All 21 are MIT licensed. Click a name for the live demo, props and code.

AI chat and agent UI

ComponentWhat it doesInstall name
Prompt boxAI chat input whose tray slides out to say what the model is doingprompt
Model & effortAI model picker: choose a model, drag how hard it thinks, see the costmodels
Diff reviewReview an AI agent's code change hunk by hunk, unified or splitdiff
RewriteSelect a phrase, say how it should read, accept the AI rewrite with Tabrewrite
Voice noteAudio player with a waveform that inks in and a transcript that followsvoicenote
BuddyAn animated face for your AI assistant, with moods that react to the userbuddy
AI calendarWeek calendar where you add events by typing, with a live draft and clash warningsweek

Charts and data visualisation

ComponentWhat it doesInstall name
Baseline chartInteractive line chart: click any day to compare everything against itchart
Outlook chartForecast chart drawn as a confidence band that thins where it's less certaintrend
Metric explainerKPI card: the number, its change in words and the drivers behind itmetric
Goal numeralsGoal progress as soft bars with big percentages, flicked through by monthrings
ShiftAnalytics breakdown as a list, bars or change, every number animating to its placeshift

Inputs and interactions

ComponentWhat it doesInstall name
PopupRadial context menu that opens around your finger: press, slide, let gopopup
PhraseSettings written as one sentence, with words to pick and numbers to dragphrase
RewindTextarea with history you can scrub back through, deleted words returning in colourrewind
UploadFile upload dropzone: files tip the folder open and fall in as sheetsupload
Live listReal-time collaborative checklist, each item arriving with who added itlivelist
VaultWeb3 deposit and withdraw card with every wallet and chain state handledvault

Text and background effects

ComponentWhat it doesInstall name
Halo bandsGlow background that restarts at every curved edge and follows the pointerhalo
Announcement pillThe badge above a hero headline, with a line of light that runs round it onceannounce
Slice textAnimated text: strips fly in, align into letters, then cut apart around the pointerslices

Free blocks

Whole page sections, built from the components and wired up.

BlockWhat it isInstall name
FAQFAQ section, searched as you typefaq
TestimonialsTestimonial section with the numbers behind each quotetestimonials
IntegrationsIntegrations grid: your stack, through glassintegrations
Sign inSign-in page: one press, or a code by emailsign-in
Call to actionCTA section: one line, and an email field to startcta

Use Detent UI with coding agents

Detent is set up so Cursor, Claude Code, Codex, Copilot and other agents install the right piece with the right props instead of guessing.

Detent Pro

For teams shipping an AI product who want the whole screen, not only the parts. One payment, every update for life, unlimited projects.

  • 21 more components, including a trace viewer for agent runs, extraction review, ask-your-data charts, a radar chart, lasso scatter plot, dot histogram, funnel and revenue bridge (waterfall) charts, a date range picker, an emoji picker, an agent wallet, a support chat and MCP install, which writes the real config for Cursor, Claude Code, Windsurf and Zed
  • 14 full-screen blocks: agent dashboard, agent chat, evals, code review, task to merge, incident, support inbox, data table, calendar, voice mode, settings, onboarding, metered pricing and live features
  • 2 templates: an AI agent workspace app (sessions, a thread that shows its work, approvals, a composer with tools and skills) and Dusk, a landing page for an AI agent

See everything and the current price at detentui.com/pro.

Pro source lives in a private repository. Without it, this one still builds and runs: each Pro preview becomes a locked stand-in from src/locked.

FAQ

Is Detent UI free?

Yes. The 21 components and 5 blocks listed above are free and MIT licensed, for personal and commercial projects. Detent Pro is a one-time purchase for the additional pieces.

How is Detent UI different from shadcn/ui?

shadcn/ui gives you the primitives: buttons, dialogs, inputs. Detent builds on the same CLI and theme to give you the finished, interactive pieces an AI product needs, such as a prompt box, a model picker, diff review and explained charts. They work side by side in the same project.

Does it work without Next.js?

Yes. The components are React 19 with Tailwind CSS v4. Next.js is what we test on; Vite with React works the same way, with the install paths adjusted.

Does it support dark mode and reduced motion?

Yes. Every piece follows your shadcn theme in light and dark, and respects prefers-reduced-motion through Motion's MotionConfig.

Can my coding agent use it?

Yes. See Use Detent UI with coding agents.

Run the site locally

git clone https://github.com/ds-spec/detent-ui.git
cd detent-ui
npm install
npm run dev
FolderWhat's in it
src/labThe free components and blocks, their demos, and the motion they share
src/catalogWhat every piece is, and the registry the shadcn CLI installs from
src/siteThe website around them: gallery, pages and code browser
src/appThe Next.js routes

Issues and feedback

Found a bug or something that feels off? Open an issue. Small, specific reports help most: what you did, what you expected, and what happened.

If Detent saved you time, a ⭐ helps other developers find it.

Licence

The free components and this site's code are MIT. Detent Pro has its own licence.

关于 About

Premium React components you install with shadcn. Styled by your theme, yours to change. Free and open source.
componentsdesign-engineeringmotionnextjsreactreactjsshadcnshadcn-uitailwindcsstypescriptui-library

语言 Languages

TypeScript97.4%
JavaScript1.3%
CSS1.3%

提交活跃度 Commit Activity

代码提交热力图
过去 52 周的开发活跃度
280
Total Commits
峰值: 114次/周
Less
More

核心贡献者 Contributors