@flinbu/seed

中文文档
0.6.0发布于 2026/11/06MITTypeScriptES Module构建来源已验证近 30 天下载 2148

Seed's React components: accessible (Radix), styled with Tailwind CSS v4 and Seed tokens, themeable with createTheme.

原始使用文档
文档目录8 节
  1. Setup
  2. With Tailwind CSS v4
  3. Without Tailwind
  4. Use it
  5. Light, Dark and system
  6. Make it yours
  7. Components
  8. Related

@flinbu/seed

Seed is a calm, neutral-first design system for React and Tailwind CSS v4. Its surfaces are true gray, it has one accent you can make your own, and its contrast passes WCAG AA in Light and Dark. The interactive parts are built on Radix Primitives, so keyboard, focus and screen readers are handled for you.

Docs and live theme builder: seed-lyart.vercel.app

npm i @flinbu/seed @flinbu/seed-tokens lucide-react

lucide-react is optional: Seed takes any icon, and the examples use Lucide.

Setup

With Tailwind CSS v4

/* app.css */
@import "tailwindcss";
@import "@flinbu/seed/styles.css";

That one line brings in Seed's tokens, fonts and type styles, and tells Tailwind to scan Seed's components for their classes. Every token is now a utility you can use in your own code: bg-primary, text-secondary, border-primary, p-base, gap-xs, rounded-control, shadow-elevation-md, label-label-2-medium.

Without Tailwind

import "@flinbu/seed/compiled.css";

Use it

import { Button, Field, Input, ThemeProvider, ThemeScript } from "@flinbu/seed";
import { Plus } from "lucide-react";

export function Invite() {
  return (
    <form className="flex flex-col gap-base">
      <Field label="Email" hint="They get a link that works for 7 days.">
        <Input type="email" placeholder="[email protected]" />
      </Field>
      <Button leftIcon={<Plus />}>Send invite</Button>
    </form>
  );
}

Icons are passed as elements (leftIcon={<Plus />}), so they also work from React Server Components.

Light, Dark and system

// app/layout.tsx (Next.js App Router)
import { ThemeProvider, ThemeScript } from "@flinbu/seed";

export default function RootLayout({ children }: { children: React.ReactNode }) {
  return (
    <html lang="en" suppressHydrationWarning>
      <head><ThemeScript /></head>
      <body><ThemeProvider>{children}</ThemeProvider></body>
    </html>
  );
}

ThemeScript sets the theme before the page paints, so it never flashes. useTheme() reads it and changes it.

Make it yours

The theme builder runs one command. It turns your brand color into a full scale for Light and Dark, checks every accent against WCAG AA, and moves any token that fails until it passes:

npx seed theme --brand "#0d9488" --name acme --radius round --out src/acme.css
@import "tailwindcss";
@import "@flinbu/seed/styles.css";
@import "./acme.css";

Then set data-brand="acme" on <html>, or on any element to theme just that part of the page. You can also try themes live on the theming page.

Components

  • Actions: Button, ButtonGroup, Toggle, ToggleGroup, Toolbar.
  • Forms: Input, Textarea, Field, Label, Checkbox, RadioGroup, Switch, Select, Combobox, Slider, OtpInput, Calendar, DatePicker, DateRangePicker, FileUpload, CopyField + CopyButton, InputGroup, TagInput, PasswordInput, MentionInput, TimePicker, RichTextEditor.
  • Overlays: Dialog, AlertDialog, Sheet, Drawer, Popover, HoverCard, CommandPalette (⌘K), ContextMenu, DropdownMenu (with checkbox, radio and sub menus), Tooltip.
  • Navigation: Tabs (line and pill, with counts), Breadcrumb, Pagination, Stepper, Sidebar (collapses to icons), Menubar, NavigationMenu, TableOfContents, Link.
  • Display: Badge, Avatar (with presence), AvatarGroup, Icon, Kbd, Card, Separator, Table (sortable headers, selected rows), Accordion, FileTree, Tag, DescriptionList, Timeline, CommentThread, Typography + Heading + Text.
  • Feedback: Alert, Banner, toast + Toaster, Meter, ProgressRing, Progress, Skeleton, Spinner, EmptyState, Tour.
  • AI chat: Message + MessageGroup, Bubble + BubbleGroup, MessageScroller, Attachment + AttachmentGroup, CodeBlock, Marker, Trace, Questionnaire.
  • Design system tools: ColorSwatch, ColorScale, TokenPreview, TypeSpecimen, ContrastPair, ColorPicker, TokenInput, NumberInput, Stage, PropsTable, plus the color math (parseColor, contrastRatio, formatRatio, formatOklch).
  • Data: DataTable, Chart (bar, stacked, line, area), StatTile, Carousel.
  • Layout: Stack, Inline, Grid, Container, VisuallyHidden, PageHeader, Collapsible, ScrollArea, Item + ItemGroup, AspectRatio, Resizable, DirectionProvider.
  • Theme: ThemeProvider, ThemeScript, useTheme.

Every component in the Seed design system is now in the package.

  • @flinbu/seed-tokens: the tokens on their own, as CSS variables, a Tailwind theme and DTCG JSON, plus createTheme() and the seed CLI.
  • GitHub

Seed is the UI of Fenly, open for everyone. MIT © Felipe Linares.

版本与发布记录

@flinbu/seed 共发布 14 个版本,首次发布于 2026/10/17;过去 12 个月发布了 14 个版本。最新版本附带 npm provenance 构建来源证明,可追溯到公开的 CI 构建记录。

版本发布日期距今
0.6.0latest2026/11/069 天前
0.5.12026/11/069 天前
0.5.02026/11/0411 天前
0.4.12026/11/0312 天前
0.4.02026/10/2126 天前
0.3.22026/10/2126 天前

关于 @flinbu/seed 的常见问题

@flinbu/seed 是什么?

Seed's React components: accessible (Radix), styled with Tailwind CSS v4 and Seed tokens, themeable with createTheme.

如何安装 @flinbu/seed?

在项目目录运行 npm install @flinbu/seed,或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖:react(^18.2.0 || ^19.0.0)、react-dom(^18.2.0 || ^19.0.0)。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖,Yarn 需要手动安装。

@flinbu/seed 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@flinbu/seed 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@flinbu/seed 可以商用吗?

@flinbu/seed 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@flinbu/seed 的下载量有多少?

根据 npm 官方下载统计,@flinbu/seed 在 2026/10/15 – 2026/11/13 这 30 天内被下载 2,148 次,日均约 72 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@flinbu/seed 还在维护吗?

最新版本 0.6.0 发布于 2026/11/06(9 天前);至今共发布 14 个版本,其中过去 12 个月发布了 14 个;首次发布于 2026/10/17。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。