mirror of
https://github.com/foomo/ui.git
synced 2026-10-06 13:47:02 +00:00
eb711f708da9aa82ac176b23dd5e012979b060cc
Replace the 26 individual @radix-ui/react-* packages with the unified radix-ui package and regenerate all components against the maia preset. - add DataTable built on @tanstack/react-table v9 with sorting, global filtering, row selection, pagination and column visibility - add Admin Dashboard and Data Table stories - clamp the radius scale at lg so maia's 2xl/4xl radii match the system - drop the bundled Inter typeface from ui.css; hosts now load it - fix duplicate ./lib/* export and exclude the Vite playground entry from the library build so react-dom/client is no longer inlined - paint the Storybook canvas from --background so dark mode applies outside fullscreen stories
@foomo/ui
A modern React component library built with Tailwind CSS v4, TypeScript, and Radix UI primitives.
Features
- 🎨 Built with Tailwind CSS v4
- 🔧 Full TypeScript support
- 📦 Tree-shakeable - import only what you need
- 🎯 No barrel exports - better performance
- 🌗 Dark mode support
- ♿ Accessible components via Radix UI
Installation
npm install @foomo/ui
Usage
Import the CSS file once in your app:
// In your app's entry file (e.g., App.tsx or main.tsx)
import "@foomo/ui/ui.css";
// use one of the prefefined shadcn themes
// if you want to bring your own theme do not import this
import "@foomo/ui/themes/neutral.css";
If you want to bring your own theme you can simply define the theme variables yourself
as is normally done in a globals.css. For more information on this check out the
shadcn theming guide
Import components individually:
import { Button } from "@foomo/ui/components/button";
import { cn } from "@foomo/ui/lib/utils";
function App() {
return (
<div>
<Button variant="outline" size="lg">
Get Started
</Button>
<Button variant="destructive" className={cn("mt-4")}>
Delete Item
</Button>
</div>
);
}
Development
# Install dependencies
bun install
# Start Storybook
bun run storybook
# Build the library
bun run build
Languages
TypeScript
97.1%
CSS
2.2%
JavaScript
0.5%