persianlabsui
v0.1.2
Published
Scaffold and theme RTL-first, Persian-typography shadcn projects - init from a /create preset, add components from the Persian Labs registry.
Maintainers
Readme
persianlabsui
The CLI for Persian Labs UI — scaffold and theme RTL-first, Persian-typography projects built on shadcn/ui and Base UI.
Quick start
Build your design system visually at /create, then scaffold a project from the generated preset code:
npx persianlabsui@latest init -p <preset-code> -t next -n my-appOr without a preset — you'll be prompted:
npx persianlabsui@latest initScaffolded projects ship with the Persian-first font stack (Vazirmatn by default, Estedad optional), Farsi digit handling, RTL, and the full theming tokens.
Commands
| Command | What it does |
| ---------- | ----------------------------------------------------------------------- |
| init | Create a new project from a template (next, vite, monorepo variants) |
| apply | Apply a preset (theme + fonts) to an existing project — --only theme / --only font |
| add | Add components from the Persian Labs registry |
| preset | decode, url, or open a preset code |
Full reference: ui.persian-labs.ir/docs/cli
How it works
init scaffolds a ready-to-run template — sparse-cloned from the persianlabs/ui repo's templates/ directory (requires git; forks can override with PERSIANLABSUI_GITHUB_URL, and local development can point PERSIANLABSUI_TEMPLATE_DIR at a checkout) — then fetches a registry base from https://ui.persian-labs.ir/init and applies it through the stock shadcn CLI. Fonts install offline: the Persian cuts are Latin-free arabic subsets bundled with the templates, and English fonts are pulled fresh from Google Fonts (with a CDN fallback). Everything it produces is a normal shadcn project you fully own.
