Documentation•Installation

Installation

How to install and set up ORYN UI in your project. Choose your framework below to view tailored, step-by-step instructions.

Direct NPM Install (Fastest & Recommended)2 Steps

No copying required. Install the package, import the stylesheet, and start using any of the 76+ components right away.

1Install package
terminal
npm install oryn-ui
2Import stylesheet in root layout
example.tsx
// In app/layout.tsx (Next.js) or src/main.tsx (Vite)
import "oryn-ui/styles.css"
B&W / Monochrome (Default)

Zero configuration needed. Works automatically when you import the stylesheet. All buttons, tabs, inputs, and dialogs render in sleek monochrome zinc.

Normal (Vibrant Blue)

Simply add data-style="normal" to your <html> element. All components instantly adapt to royal blue accents.

Select Framework

Choose your target framework for step-by-step setup guides.

Package Manager:
Base Color Palette:
B&W / Monochrome Aesthetic Selected— Clean, modern black & white palette (Shadcn Zinc default). All buttons and primary accents render in monochrome.
CLI: --style monochrome

Next.js Setup Guide

Optimized for Next.js 14, 15, and 16 App Router, React 19, and Turbopack.

1

Install ORYN UI

Add the package to your Next.js project. All primitives, hooks, and icons are bundled with zero external UI runtime dependencies:

terminal
npm install oryn-ui
Starting a brand new Next.js project from scratch? Click to view create-next-app command
terminal
npx create-next-app@latest my-app --typescript --tailwind --eslint --app
2

Import Styles in app/layout.tsx

Import the pre-compiled stylesheet in your root layout. B&W (Monochrome Zinc) is active automatically; for Vibrant Blue, just set data-style="normal":

Zero content scanning required. All component styles are pre-compiled and tree-shaken into a single optimized CSS stylesheet:

app/layout.tsx
1// app/layout.tsx (Method 1: Zero-config precompiled CSS)
2import "oryn-ui/styles.css"
3import type { Metadata } from "next"
4
5export const metadata: Metadata = {
6  title: "My ORYN UI App",
7  description: "Built with Next.js and ORYN UI",
8}
9
10export default function RootLayout({
11  children,
12}: {
13  children: React.ReactNode
14}) {
15  return (
16    <html lang="en" className="dark" data-style="monochrome">
17      <body className="min-h-screen bg-background text-foreground antialiased">
18        {children}
19      </body>
20    </html>
21  )
22}
3

Import and Use Components in Page

Import any component directly into your page:

app/page.tsx
1'use client'
2
3import { Button, Card, CardHeader, CardTitle, CardDescription, CardContent, Input, Badge } from 'oryn-ui'
4
5export default function Home() {
6  return (
7    <main className="min-h-screen flex items-center justify-center p-6 bg-background">
8      <Card className="max-w-md w-full p-6 space-y-4 shadow-lg border-border">
9        <div className="flex items-center justify-between">
10          <Badge variant="primary">Next.js 16 + React 19</Badge>
11          <span className="text-xs text-muted-foreground">Ready</span>
12        </div>
13        <CardHeader className="p-0">
14          <CardTitle className="text-xl font-bold">Welcome to ORYN UI</CardTitle>
15          <CardDescription>
16            Zero external dependencies, accessible, high-craft UI components.
17          </CardDescription>
18        </CardHeader>
19        <CardContent className="p-0 space-y-3 pt-2">
20          <Input placeholder="Enter your email" type="email" />
21          <Button variant="default" className="w-full">
22            Get Started
23          </Button>
24        </CardContent>
25      </Card>
26    </main>
27  )
28}
+

Optional: ThemeProvider for Dynamic Theme & Style Switching

Wrap your root layout with ORYN UI's built-in ThemeProvider if your application allows users to toggle dark mode or switch between B&W and Normal styles dynamically:

components/theme-provider.tsx
1// components/theme-provider.tsx (Optional Dark/Light Theme Switching)
2'use client'
3
4import * as React from 'react'
5import { ThemeProvider as OrynThemeProvider } from 'oryn-ui'
6
7export function ThemeProvider({ children }: { children: React.ReactNode }) {
8  return (
9    <OrynThemeProvider defaultTheme="dark" defaultStyle="monochrome" storageKey="app-theme">
10      {children}
11    </OrynThemeProvider>
12  )
13}
Architecture

The ORYN Way

Built for enterprise-scale web applications with zero external UI runtime dependencies and 3-tier tree-shaking granularity.

Level 1: Full

Convenient root barrel import for rapid prototyping

import { Button } from 'oryn-ui'
Level 2: Category

Grouped subpath module for related components

import { Button } from 'oryn-ui/core'
Level 3: Component

Direct subpath export for absolute zero-bloat tree shaking

import { Button } from 'oryn-ui/button'

Direct CLI Distribution (Optional Alternative)

Prefer full local ownership over your component code? Use our built-in CLI to copy raw source components into your project (shadcn-style).

Note: If you already installed via npm install oryn-ui, you do not need the CLI. The CLI is strictly for developers who want raw source code files in their repository.
terminal
# 1. Initialize project and auto-configure components.json & theme tokens for B&W (Zinc)
npx npx oryn-ui init --style monochrome

# 2. Add individual components (primitives and hooks bundled automatically)
npx oryn-ui add button
npx oryn-ui add dialog
npx oryn-ui add data-table

# Specify custom target directory
npx oryn-ui add form --path src/components/ui

# Explore all available components
npx oryn-ui list
Theme Tokens

Theme Variables (B&W / Monochrome Zinc)

ORYN UI uses HSL channel tokens (--primary: 240 5.9% 10%) without hardcoded color functions. This ensures Tailwind opacity modifiers like bg-primary/80 and ring-primary/20 work without color clipping.

app/globals.css
1/* ORYN UI Theme: B&W / Monochrome (Shadcn Zinc Default) */
2@layer base {
3  :root {
4    --background: 0 0% 100%;
5    --foreground: 240 10% 3.9%;
6    --card: 0 0% 100%;
7    --card-foreground: 240 10% 3.9%;
8    --popover: 0 0% 100%;
9    --popover-foreground: 240 10% 3.9%;
10    --primary: 240 5.9% 10%;              /* Deep Black/Zinc in Light */
11    --primary-foreground: 0 0% 98%;
12    --secondary: 240 4.8% 95.9%;
13    --secondary-foreground: 240 5.9% 10%;
14    --muted: 240 4.8% 95.9%;
15    --muted-foreground: 240 3.8% 46.1%;
16    --accent: 240 4.8% 95.9%;             /* Subtle Zinc Accent */
17    --accent-foreground: 240 5.9% 10%;
18    --destructive: 0 84.2% 60.2%;
19    --destructive-foreground: 0 0% 98%;
20    --border: 240 5.9% 90%;
21    --input: 240 5.9% 90%;
22    --ring: 240 5.9% 10%;
23    --radius: 0.5rem;
24  }
25  .dark {
26    --background: 240 10% 3.9%;
27    --foreground: 0 0% 98%;
28    --card: 240 10% 3.9%;
29    --card-foreground: 0 0% 98%;
30    --popover: 240 10% 3.9%;
31    --popover-foreground: 0 0% 98%;
32    --primary: 0 0% 98%;                  /* Crisp White in Dark */
33    --primary-foreground: 240 5.9% 10%;
34    --secondary: 240 3.7% 15.9%;
35    --secondary-foreground: 0 0% 98%;
36    --muted: 240 3.7% 15.9%;
37    --muted-foreground: 240 5% 64.9%;
38    --accent: 240 3.7% 15.9%;
39    --accent-foreground: 0 0% 98%;
40    --destructive: 0 62.8% 30.6%;
41    --destructive-foreground: 0 0% 98%;
42    --border: 240 3.7% 15.9%;
43    --input: 240 3.7% 15.9%;
44    --ring: 240 4.9% 83.9%;
45  }
46}