Skip to content
项目

kevintngo/looseleaf has 751 GitHub stars and 42 forks. GitHot measured +9 stars in 24 hours and +35 in 7 days. Last checked 2026-11-25 06:38 UTC. Last push 2026-11-01.

这些数字如何统计

实测星标增长

24小时
+9
7天
+35
15天
正在收集历史
1个月
正在收集历史

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

关于

手绘风格的 shadcn/ui:123 个符合无障碍要求、看起来像画在纸上的 React 组件,并提供 shadcn registry。

网站与应用

README.md

原文

Looseleaf

shadcn/ui, drawn by hand.

kevintngo.github.io/looseleaf

Looseleaf

Looseleaf is a React + Tailwind v4 + Radix component library and shadcn registry where every surface is paper and every line is drawn with a pen: clean outlines and solid color, with stickers and stamps when you want them. It keeps shadcn/ui's parts, props and data-slot names, so you can swap it in without touching your JSX. The charm is decoration; the semantics are ordinary Radix.

123 components every shadcn/ui part, from button to sidebar to chart, plus paper objects, marks, stickers, a sketchpad and a chat kit
61 blocks sidebars, logins, sign-ups, dashboards, settings, pricing, chat, notes and landing sections
Art 160 icons, 48 doodles, 88 stickers, badges and stamps, and Stubby in 15 poses, all drawn in code
Kevin Sans one hand-drawn typeface, tuned for three roles: interface text, titles and stamps
Accessible keyboard, visible focus, AA text, 24 px targets, reduced motion, forced colors, RTL and three densities

Install

Add the registry to components.json once:

{
  "registries": { "@looseleaf": "https://kevintngo.github.io/looseleaf/r/{name}.json" }
}

Then add what you need:

npx shadcn@latest add @looseleaf/button
npx shadcn@latest add @looseleaf/login-01
npx shadcn@latest add @looseleaf/looseleaf

The theme brings Kevin Sans with it. To load the font by hand instead:

@import url("https://kevintngo.github.io/looseleaf/fonts/kevin-sans.css");
import { InkProvider } from "@/lib/ink/react"
import { Button } from "@/components/ui/button"

export function App() {
  return (
    <InkProvider>
      <Button>Save changes</Button>
    </InkProvider>
  )
}

Components land in your repo as source (components/ui/*.tsx, lib/ink/*): your code, not a dependency.

Develop

npm install
npm run dev              # the documentation site
npm run build            # static site in dist/
npm test                 # vitest
npm run registry:build   # registry.json and public/r/*.json

Run npm run registry:build after changing a component, so the registry serves the new source. Pushing to main deploys the site to GitHub Pages.

How it works

Everything that is drawn is one <svg data-ink> behind the real DOM label. The drawing is a pure, seeded TypeScript function (src/lib/ink/recipes/<component>-ink.ts) that writes SVG colored by CSS variables, so the same seed draws the same line on the server and in the browser. States are CSS, not React: hover, press and focus reveal layers that were drawn ahead of time. Every color, pen width and density is a token (--ll-*), aliased onto shadcn's semantic variables.

License

MIT, for the code, the art and Kevin Sans. IBM Plex Mono is SIL OFL 1.1.

探索相关项目

加载中…