Skip to content
overtruePublic

About

Editable components and page patterns for admin panels, dashboards, and consoles.

Resources

Contributing

Stars

37 stars

Watchers

0 watching

Forks

Latest commit

 

History

62 Commits

Folders and files

Repository files navigation

overtrue/ui

Editable components and page patterns for admin panels, dashboards, and consoles. Built with React, TypeScript, Tailwind CSS v4, and shadcn/ui.

Website · Components · Blocks · Documentation · Examples

overtrue/ui — editable interfaces for the work behind the screen

Install the pieces you need through the shadcn CLI. The source goes into your application, where you can change the markup, styling, and behavior without maintaining a fork of a component package.

What's included

  • 87 components in nine groups: metrics, charts, operations, tables and lists, AI, layout, navigation, forms, and feedback. Each has live examples, source, usage, and installation instructions.
  • Live operations and observability: a service map with animated traffic, a profiler flame graph, a distributed trace waterfall, a latency histogram with percentiles, a log stream, a JSON viewer, a CI/CD pipeline, a fleet host map, and a dot-matrix geo map. Pure SVG and CSS, no extra chart dependency.
  • Analytics and AI: a stacked area chart with stream and 100% modes, an A/B experiment readout with confidence intervals, cohort retention, a treemap, a waterfall bridge, bullet charts, an odometer number ticker, a streaming insight card, and a copilot assistant panel.
  • Forms for dashboards: a date range picker with presets and period comparison, a filter bar with field, operator, and value chips and saved views, a searchable multi-select with groups and async options, a range slider over a histogram, and a file upload queue with progress, cancel, and retry.
  • Work and scheduling: a kanban board with keyboard and touch drag, column limits, and announcements; a week, month, and agenda event calendar; a tree view with lazy loading, filtering, and tri-state checkboxes; and a notification center with tabs, inline actions, and undo.
  • 22 composed blocks: including an AI gateway (model usage), feature flags with per-environment rollouts, a revenue overview, a service explorer, a realtime monitor, an incident review, dashboard and analytics overviews, project portfolio, service status, team access, settings, invoices, and pricing.
  • 174 example card patterns: extracted from the same source used by the workspace pages, including their sample data and local interactions.
  • 121 workspace examples: projects, people, billing, inboxes, settings, authentication, layouts, and component demonstrations.
  • One visual language, light and dark: luminous data marks, frosted tooltips, and motion that explains change, all built from semantic colors with responsive layouts and Tabler Icons throughout. Every preview opens in a full-screen stage with phone, tablet, and desktop widths. The website's theme studio builds a theme from one accent, recolors every preview live, and exports oklch variables for your globals.css; the workspace also includes controls for accent, typography, radius, and navigation.
  • Built to extend: components read only semantic theme tokens and accept className; the newer data components also expose data-slot hooks and state attributes, formatter and render props, and controlled or uncontrolled state. See the extending guide.

The component catalog and generated card catalog are the source of truth. Counts change as examples are added or reorganized.

Install a component

Start with a React application using Tailwind CSS v4 and an initialized shadcn/ui setup. This repository uses React 19; the CLI resolves the dependencies declared by each item.

# Run this first if your application does not have shadcn/ui configured.
npx shadcn@latest init

# Add a component and its dependencies.
npx shadcn@latest add https://ui.overtrue.xyz/r/stat-card.json

Use the installed source:

import { StatCard } from "@/components/overtrue/stat-card"

export function Revenue() {
  return (
    <StatCard
      title="Monthly revenue"
      value="$36,800"
      change="12.8%"
      trend="up"
      description="vs. last month"
      sparkline={[18, 24, 21, 30, 27, 36]}
    />
  )
}

The import assumes your @ alias points to the application source directory. Use the destination configured in your own components.json.

Use a registry namespace

Merge this entry into your application's components.json:

{
  "registries": {
    "@overtrue": "https://ui.overtrue.xyz/r/{name}.json"
  }
}

Then install by name:

npx shadcn@latest add @overtrue/stat-card
npx shadcn@latest add @overtrue/activity-heatmap
npx shadcn@latest add @overtrue/dashboard

@overtrue is a namespace you configure locally. This project is distributed through a shadcn registry, not an npm package. It is not listed in the official shadcn Directory.

Components, blocks, and workspace pages

Choose For What gets installed
Components Individual UI patterns Editable source, local helpers, required shadcn primitives, and npm dependencies
Composed blocks A business card, form, or screen to customize The layout and its component dependencies
Example card blocks A card from a workspace example The card plus a shared foundation with scoped styles and demo interaction primitives
Workspace pages Exploring layouts and workflows Browse or adapt the repository source; these pages are not individually installable registry items

A component owns a focused presentation or interaction contract. A block fixes a business composition, even if it accepts data and callbacks. Card size and the presence of props do not decide the category. See the catalog review for the item-by-item classification.

Core components inherit your application's shadcn theme and do not require the workspace stylesheet. Example card blocks use a separate foundation under components/overtrue/blocks/runtime/ to preserve their appearance without replacing your application's UI primitives. Some card imagery is served from the registry origin; replace it with your own assets before using it in a product.

The optional @overtrue/overtrue-theme item updates global CSS variables. Review those changes if your application already has a theme.

Read the composition guide, card block guide, and dashboard component notes for the installation boundaries and APIs.

Run locally

Requires Node.js 22.18 or newer and pnpm 10.32.1. No application secrets or backend service are needed to run the demos.

git clone https://github.com/overtrue/ui.git
cd ui
pnpm install --frozen-lockfile
pnpm registry:build
pnpm dev

Open http://localhost:5173 for the website, or http://localhost:5173/workspace/ for the workspace. Generate the registry before the first dev run: the site imports the generated card catalog.

To install a locally modified component into another application while the dev server is running:

npx shadcn@latest add http://localhost:5173/r/stat-card.json

Useful commands

Command Purpose
pnpm dev Start the website and workspace development server
pnpm blocks:prepare Extract cards and their catalog from example source
pnpm registry:build Extract cards, resolve dependencies, and generate public registry JSON
pnpm typecheck Check TypeScript after registry generation
pnpm build Regenerate the registry, check types, and build all site entries
pnpm preview --port 4175 Serve the production build locally
pnpm registry:check Rebuild and verify registry sources, dependencies, and installation targets
pnpm content:check Check branding, local asset paths, page metadata, navigation, and attribution
pnpm site:check Run browser checks against a running production preview

Browser checks use Playwright CLI and require Chrome. With a production preview running:

SITE_URL=http://127.0.0.1:4175 pnpm site:check
PREVIEW_URL=http://127.0.0.1:4175/workspace/ node scripts/examples/verify-workspace.mjs
PREVIEW_URL=http://127.0.0.1:4175/workspace/ node scripts/examples/verify-workspace.mjs --mobile

Screenshots and verification output stay in the ignored output/ directory. See registry verification and workspace verification for additional checks. A build passing does not replace reviewing the rendered interface.

GitHub Actions runs clean builds on Node.js 22.18 and 24, registry and content checks, browser verification, and CodeQL. See automated checks for coverage and failure artifacts.

Repository layout

src/registry/overtrue/             Installable components and complete interfaces
src/site/                         Website, documentation, catalogs, and examples
src/pages/workspace/              Workspace route modules
src/components/overtrue/scenes/   Composed business pages
src/components/overtrue/workspace/ Workspace navigation and interaction adapters
src/components/ui/                Shared UI primitives
src/data/workspace/               Route inventory and demo data
src/blocks/                       Card preview runtime and generated card sources
src/styles/                       Scoped workspace styles
scripts/blocks/                   Card extraction and packaging
scripts/registry/                 Registry generation and verification
public/assets/                    Example imagery, icons, and fonts
licenses/                         Third-party notices

Edit the original component or workspace example, then regenerate. registry.json, public/r/, the card catalog, and generated block sources are build outputs and are not committed.

The website, workspace, and isolated card preview are separate Vite entries. Workspace styles are kept out of the component website. DESIGN.md describes typography, density, color, spacing, and interaction conventions.

Deploy

Production is a static Vite build on Cloudflare Pages. The project is overtrue-ui (https://overtrue-ui.pages.dev). Point ui.overtrue.xyz at that hostname with a CNAME. Pull requests get preview deployments once the GitHub integration is connected.

pnpm build writes dist/, including one HTML entry per public route, 404.html, and the registry under dist/r/. The same command refreshes public/_redirects and public/_headers from vercel.json: legacy 301s, directory rewrites, and the registry CORS headers. Pages reads those two files. vercel.json remains the route list the checks compare against.

Set this build variable on the production environment only:

REGISTRY_ORIGIN=https://ui.overtrue.xyz

Preview deployments should leave it unset. Generation then uses CF_PAGES_URL, so install URLs point at that preview. A Vercel build still uses https://$VERCEL_URL. Locally the fallback is http://localhost:5173. Visible install commands in the browser use the website's current origin. For another domain, also update canonical metadata in vite.config.ts and index.html.

The Pages build image needs Node.js 22.18 or newer. This repository pins pnpm 10.32.1 with the packageManager field. Set NODE_VERSION on both Production and Preview when the build image default is older.

Preserve /workspace/, /card-preview.html, and /r/. Registry JSON has to stay public. Pages redirects a directory path such as /components/stat-card to /components/stat-card/. The site routes match both forms. Verify the deployed pages and installation URLs after publishing. Local checks do not establish deployment or DNS status.

Demo boundaries

Acme Studio is a sample workspace. Client records, contact details, and financial figures are demo data. People are fictional except for the maintainer’s public GitHub profile used in a few avatar examples. Forms and business workflows use local state; the examples do not provide authentication, payment processing, email delivery, or a backend. Wire those behaviors into your own application.

Maps fetch external tiles. Charts and tables declare their own dependencies; the newer analytics charts use a separate Recharts 3 alias so they can coexist with the existing Recharts 2 examples. Review the compatibility notes before changing chart dependencies.

Contributing

Small, focused improvements are welcome. See CONTRIBUTING.md for source locations, generation steps, and verification expectations. For UI bugs, include the page, viewport, theme, and a screenshot or reproduction steps.

License and credits

MIT. Built with shadcn/ui, React, Tailwind CSS, and Tabler Icons.

Third-party styles, code, and assets retain their applicable copyright and license notices. Keep those notices when redistributing adapted source.

About

Editable components and page patterns for admin panels, dashboards, and consoles.

Resources

Contributing

Stars

37 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages