@raydenui/ui 0.7.0 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -6,414 +6,56 @@
6
6
 
7
7
  # Rayden UI
8
8
 
9
- A modern, accessible React component library built with Tailwind CSS v4. Rayden UI brings the [Rayna UI](https://www.raynaui.com/) Figma design system to life with pixel-perfect React components.
9
+ A modern, accessible React component library built with Tailwind CSS v4.
10
+ Pixel-perfect components from the [Rayna UI](https://www.raynaui.com/) design system.
10
11
 
11
12
  [![npm version](https://img.shields.io/npm/v/@raydenui/ui.svg)](https://www.npmjs.com/package/@raydenui/ui)
12
13
  [![npm downloads](https://img.shields.io/npm/dm/@raydenui/ui.svg)](https://www.npmjs.com/package/@raydenui/ui)
13
14
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
14
15
  [![Documentation](https://img.shields.io/badge/docs-rayden--docs.vercel.app-F56630)](https://rayden-docs.vercel.app)
15
16
  [![Storybook](https://img.shields.io/badge/Storybook-FF4785?logo=storybook&logoColor=white)](https://main--69b6d5d8527b4eddb882e0a7.chromatic.com)
16
- [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](https://github.com/playbookTV/Rayden/pulls)
17
-
18
- ## Features
19
-
20
- - **24+ Production-Ready Components** — Buttons, Inputs, Tables, Selects, Sidebars, and more
21
- - **Pre-built Blocks** — Login forms, notifications, tables, and more ready to drop in
22
- - **AI Compatibility** — `@raydenui/ai` package for reliable LLM code generation
23
- - **Tailwind CSS v4** — Modern styling with custom design tokens
24
- - **Fully Typed** — Complete TypeScript support with exported types
25
- - **Accessible** — Built with ARIA attributes and keyboard navigation
26
- - **Tree-Shakeable** — Import only what you need
27
- - **Dual Format** — ESM and CommonJS builds included
28
17
 
29
18
  ## Installation
30
19
 
31
20
  ```bash
32
- # npm
33
21
  npm install @raydenui/ui
34
-
35
- # pnpm
36
- pnpm add @raydenui/ui
37
-
38
- # yarn
39
- yarn add @raydenui/ui
40
- ```
41
-
42
- ### Peer Dependencies
43
-
44
- Rayden UI requires React 18 or higher:
45
-
46
- ```bash
47
- npm install react react-dom
48
22
  ```
49
23
 
50
24
  ## Quick Start
51
25
 
52
- ### 1. Import the Styles
53
-
54
- Add the Rayden UI stylesheet to your app's entry point:
55
-
56
26
  ```tsx
57
- // App.tsx or main.tsx
58
27
  import "@raydenui/ui/styles.css";
59
- ```
60
-
61
- Or in CSS:
62
-
63
- ```css
64
- /* globals.css */
65
- @import "@raydenui/ui/styles.css";
66
- ```
67
-
68
- ### 2. Use Components
69
-
70
- ```tsx
71
28
  import { Button, Input, Badge } from "@raydenui/ui";
72
29
 
73
30
  function App() {
74
31
  return (
75
32
  <div className="flex flex-col gap-4 p-8">
76
- <Input
77
- label="Email"
78
- placeholder="you@example.com"
79
- helperText="We'll never share your email"
80
- />
81
- <Button variant="primary" size="lg">
82
- Subscribe
83
- </Button>
33
+ <Input label="Email" placeholder="you@example.com" />
34
+ <Button variant="primary" size="lg">Subscribe</Button>
84
35
  <Badge color="success">Active</Badge>
85
36
  </div>
86
37
  );
87
38
  }
88
39
  ```
89
40
 
90
- ## Tailwind Integration
91
-
92
- Rayden UI ships pre-compiled CSS, so components work out of the box. However, if you want to use Rayden's design tokens in your own Tailwind classes (e.g., `bg-primary-400`, `text-grey-700`), you need additional configuration.
93
-
94
- ### Using Rayden Tokens in Your Code
95
-
96
- Extend your Tailwind config with Rayden's color palette:
97
-
98
- ```js
99
- // tailwind.config.js (Tailwind v3)
100
- import { colors } from "@raydenui/ui/preset";
101
-
102
- export default {
103
- theme: {
104
- extend: {
105
- colors,
106
- },
107
- },
108
- content: [
109
- "./src/**/*.{js,ts,jsx,tsx}",
110
- // Include Rayden UI components so Tailwind scans them
111
- "node_modules/@raydenui/ui/dist/**/*.js",
112
- ],
113
- };
114
- ```
115
-
116
- For Tailwind v4 with CSS-based config:
117
-
118
- ```css
119
- /* app.css */
120
- @import "tailwindcss";
121
- @import "@raydenui/ui/styles.css";
122
-
123
- @source "node_modules/@raydenui/ui/dist/**/*.js";
124
- ```
125
-
126
- Or extend the theme in CSS:
127
-
128
- ```css
129
- @import "tailwindcss";
130
- @import "@raydenui/ui/styles.css";
131
-
132
- @theme {
133
- --color-primary-400: #F56630;
134
- --color-primary-500: #EB5017;
135
- /* ... other tokens from @raydenui/ui/preset */
136
- }
137
- ```
138
-
139
- ### Available Token Exports
140
-
141
- ```tsx
142
- import {
143
- colors, // Color palette (primary, grey, success, error, warning, info)
144
- shadows, // Box shadows (soft, hard variants)
145
- spacing, // Spacing scale (4px base)
146
- typography, // Font sizes, line heights, letter spacing
147
- grid, // Breakpoints and layout tokens
148
- } from "@raydenui/ui/preset";
149
- ```
150
-
151
- ## Components
152
-
153
- ### Forms & Inputs
154
-
155
- | Component | Description |
156
- |-----------|-------------|
157
- | [Button](./docs/components/Button.md) | Primary action buttons with variants and icon support |
158
- | [ButtonGroup](./docs/components/ButtonGroup.md) | Horizontal grouping of related buttons |
159
- | [Input](./docs/components/Input.md) | Text input with label, helper text, and validation states |
160
- | [Select](./docs/components/Select.md) | Dropdown select with icons, avatars, and status indicators |
161
- | [Checkbox](./docs/components/FormControl.md#checkbox) | Checkbox input with label and description |
162
- | [Radio](./docs/components/FormControl.md#radio) | Radio button input with label and description |
163
- | [Toggle](./docs/components/FormControl.md#toggle) | Switch/toggle input for boolean values |
164
- | [Chip](./docs/components/Chip.md) | Compact input tags with close/filter actions |
165
- | [FileUpload](./docs/components/FileUpload.md) | Drag-and-drop file upload with progress and states |
166
-
167
- ### Navigation
168
-
169
- | Component | Description |
170
- |-----------|-------------|
171
- | [Tabs](./docs/components/Tabs.md) | Tabbed navigation with line and pill variants |
172
- | [Breadcrumb](./docs/components/Breadcrumb.md) | Hierarchical page navigation |
173
- | [Pagination](./docs/components/Pagination.md) | Page navigation with prev/next controls |
174
- | [SidebarMenu](./docs/components/SidebarMenu.md) | Collapsible sidebar navigation with sections |
175
- | [DropdownMenu](./docs/components/DropdownMenu.md) | Accessible dropdown menu with keyboard navigation |
176
-
177
- ### Data Display
178
-
179
- | Component | Description |
180
- |-----------|-------------|
181
- | [Table](./docs/components/Table.md) | Data table with sorting, selection, and avatars |
182
- | [Avatar](./docs/components/Avatar.md) | User avatar with image, initials, icon, and status |
183
- | [ActivityFeed](./docs/components/ActivityFeed.md) | Activity timelines and notification feeds |
184
- | [MetricsCard](./docs/components/MetricsCard.md) | Dashboard metric cards with 6 layout variations |
185
- | [Icon](./docs/components/Icon.md) | 200+ icons with outline and solid variants |
186
- | [EmptyStateIllustration](./docs/components/EmptyStateIllustration.md) | 19 empty state illustrations with custom palettes |
187
-
188
- ### Feedback
189
-
190
- | Component | Description |
191
- |-----------|-------------|
192
- | [Alert](./docs/components/Alert.md) | Toast and banner notifications with actions |
193
- | [Badge](./docs/components/Badge.md) | Status indicators and labels |
194
- | [ProgressBar](./docs/components/ProgressBar.md) | Linear progress indicator |
195
- | [ProgressCircle](./docs/components/ProgressCircle.md) | Circular progress indicator |
196
- | [Tooltip](./docs/components/Tooltip.md) | Contextual information popover |
197
-
198
- ### Layout
199
-
200
- | Component | Description |
201
- |-----------|-------------|
202
- | [Divider](./docs/components/Divider.md) | Content separator with optional label/button |
203
-
204
- ## Blocks
205
-
206
- Pre-built UI patterns combining multiple components for common use cases. [View all blocks →](./docs/blocks.md)
207
-
208
- | Block | Description |
209
- |-------|-------------|
210
- | [LoginBlock](./docs/blocks.md#loginblock) | Complete login form with social providers |
211
- | [NotificationsBlock](./docs/blocks.md#notificationsblock) | Notification feed with actions and timestamps |
212
- | [TableBlock](./docs/blocks.md#tableblock) | Full-featured data table with search and filters |
213
- | [QuickSendBlock](./docs/blocks.md#quicksendblock) | Quick send interface for payments/transfers |
214
- | [RecentTransactionsBlock](./docs/blocks.md#recenttransactionsblock) | Transaction history display |
215
- | [EmptyStateBlock](./docs/blocks.md#emptystateblock) | Empty state with illustration and CTA |
216
- | [SearchableTableBlock](./docs/blocks.md#searchabletableblock) | Table with integrated search |
217
-
218
- ```tsx
219
- import { LoginBlock, NotificationsBlock } from "@raydenui/ui";
220
-
221
- function App() {
222
- return (
223
- <LoginBlock
224
- variant="split"
225
- onSubmit={handleLogin}
226
- socialProviders={["google", "github"]}
227
- />
228
- );
229
- }
230
- ```
231
-
232
- ## AI Integration
41
+ ## Components (33+)
233
42
 
234
- The `@raydenui/ai` package enables LLMs to reliably generate Rayden UI code without hallucination.
43
+ **Forms & Inputs**: Button, ButtonGroup, Input, Select, FormControl, Chip, FileUpload, Counter, Slider, DatePicker
235
44
 
236
- ```bash
237
- # Run directly with npx (no install needed)
238
- npx @raydenui/ai
45
+ **Navigation**: Tabs, Breadcrumb, Pagination, SidebarMenu, DropdownMenu, Stepper
239
46
 
240
- # Or install globally
241
- npm install -g @raydenui/ai
242
- ```
47
+ **Data Display**: Table, Avatar, ActivityFeed, MetricsCard, Icon, EmptyStateIllustration, Chart
243
48
 
244
- ### Features
49
+ **Feedback**: Alert, Badge, Banner, ProgressBar, ProgressCircle, Spinner, Tooltip
245
50
 
246
- - **Component Manifests** — Structured definitions of all components, props, and examples
247
- - **Design Tokens** — Complete token system in JSON format
248
- - **Composition Rules** — Guidelines for combining components correctly
249
- - **MCP Server** — Model Context Protocol server for AI assistants
51
+ **Layout**: Accordion, Divider, Modal
250
52
 
251
- ### Claude Desktop Integration
53
+ ## Resources
252
54
 
253
- Add to `~/Library/Application Support/Claude/claude_desktop_config.json`:
254
-
255
- ```json
256
- {
257
- "mcpServers": {
258
- "rayden-ai": {
259
- "command": "npx",
260
- "args": ["@raydenui/ai"]
261
- }
262
- }
263
- }
264
- ```
265
-
266
- ### Claude Code Integration
267
-
268
- Add to your project's `.mcp.json`:
269
-
270
- ```json
271
- {
272
- "mcpServers": {
273
- "rayden-ai": {
274
- "command": "npx",
275
- "args": ["@raydenui/ai"]
276
- }
277
- }
278
- }
279
- ```
280
-
281
- ### Programmatic Usage
282
-
283
- ```tsx
284
- import { getComponentManifest, getAllManifests } from "@raydenui/ai/manifests";
285
- import { tokens } from "@raydenui/ai/tokens";
286
-
287
- // Get all component definitions
288
- const manifests = getAllManifests();
289
-
290
- // Get a specific component
291
- const buttonManifest = getComponentManifest("Button");
292
- ```
293
-
294
- See the full [AI Integration Guide](./docs/rayden-ai.md) for setup instructions.
295
-
296
- ## Design Tokens
297
-
298
- Rayden UI includes a complete design token system extracted from the Rayna UI Figma design system.
299
-
300
- ### Using Tokens with Tailwind
301
-
302
- All tokens are available as Tailwind CSS v4 theme variables:
303
-
304
- ```tsx
305
- // Use token colors directly in Tailwind classes
306
- <div className="bg-primary-400 text-grey-900">
307
- Primary background with grey text
308
- </div>
309
-
310
- // Custom shadows
311
- <div className="shadow-soft-lg">
312
- Soft shadow effect
313
- </div>
314
- ```
315
-
316
- ### Importing Tokens Programmatically
317
-
318
- ```tsx
319
- import { colors, shadows, spacing, typography } from "@raydenui/ui/preset";
320
-
321
- // Access tokens in JavaScript
322
- console.log(colors.primary[400]); // "#F56630"
323
- console.log(shadows.soft.lg); // "0px 4px 6px..."
324
- ```
325
-
326
- ### Color Palette
327
-
328
- | Scale | Primary | Secondary | Grey | Success | Error | Warning |
329
- |-------|---------|-----------|------|---------|-------|---------|
330
- | 50 | ![#FFECE5](https://via.placeholder.com/12/FFECE5/FFECE5.png) `#FFECE5` | ![#E3EFFC](https://via.placeholder.com/12/E3EFFC/E3EFFC.png) `#E3EFFC` | ![#F9FAFB](https://via.placeholder.com/12/F9FAFB/F9FAFB.png) `#F9FAFB` | ![#E7F6EC](https://via.placeholder.com/12/E7F6EC/E7F6EC.png) `#E7F6EC` | ![#FBEAE9](https://via.placeholder.com/12/FBEAE9/FBEAE9.png) `#FBEAE9` | ![#FEF6E7](https://via.placeholder.com/12/FEF6E7/FEF6E7.png) `#FEF6E7` |
331
- | 400 | ![#F56630](https://via.placeholder.com/12/F56630/F56630.png) `#F56630` | ![#1671D9](https://via.placeholder.com/12/1671D9/1671D9.png) `#1671D9` | ![#98A2B3](https://via.placeholder.com/12/98A2B3/98A2B3.png) `#98A2B3` | ![#0F973D](https://via.placeholder.com/12/0F973D/0F973D.png) `#0F973D` | ![#D42620](https://via.placeholder.com/12/D42620/D42620.png) `#D42620` | ![#F3A218](https://via.placeholder.com/12/F3A218/F3A218.png) `#F3A218` |
332
- | 700 | ![#AD3307](https://via.placeholder.com/12/AD3307/AD3307.png) `#AD3307` | ![#04326B](https://via.placeholder.com/12/04326B/04326B.png) `#04326B` | ![#344054](https://via.placeholder.com/12/344054/344054.png) `#344054` | ![#036B26](https://via.placeholder.com/12/036B26/036B26.png) `#036B26` | ![#9E0A05](https://via.placeholder.com/12/9E0A05/9E0A05.png) `#9E0A05` | ![#865503](https://via.placeholder.com/12/865503/865503.png) `#865503` |
333
-
334
- See [Design Tokens Documentation](./docs/design-tokens.md) for the complete reference.
335
-
336
- ## Development
337
-
338
- ### Prerequisites
339
-
340
- - Node.js 18+
341
- - pnpm 8+
342
-
343
- ### Setup
344
-
345
- ```bash
346
- # Clone the repository
347
- git clone https://github.com/your-org/rayden.git
348
- cd rayden
349
-
350
- # Install dependencies
351
- pnpm install
352
-
353
- # Start Storybook
354
- pnpm storybook
355
- ```
356
-
357
- ### Commands
358
-
359
- ```bash
360
- pnpm build # Build the library
361
- pnpm dev # Watch mode for development
362
- pnpm typecheck # Run TypeScript type checking
363
- pnpm storybook # Start Storybook on port 6006
364
- pnpm build-storybook # Build static Storybook
365
- ```
366
-
367
- ### Testing
368
-
369
- Tests run via Storybook's Vitest addon with Playwright browser testing:
370
-
371
- ```bash
372
- pnpm exec vitest # Run all tests
373
- pnpm exec vitest Button # Run tests matching "Button"
374
- pnpm exec vitest --watch # Watch mode
375
- ```
376
-
377
- ### Project Structure
378
-
379
- ```
380
- src/
381
- ├── components/ # React components
382
- │ ├── Button/
383
- │ │ ├── Button.tsx
384
- │ │ ├── Button.stories.tsx
385
- │ │ └── index.ts
386
- │ └── ...
387
- ├── styles/
388
- │ └── globals.css # Tailwind v4 theme tokens
389
- ├── utils/
390
- │ └── cn.ts # Class merging utility
391
- ├── index.ts # Component exports
392
- └── preset.ts # Design token exports
393
- ```
394
-
395
- ## Contributing
396
-
397
- We welcome contributions! Please see our [Contributing Guide](./CONTRIBUTING.md) for details.
398
-
399
- ### Development Workflow
400
-
401
- 1. Fork and clone the repository
402
- 2. Create a feature branch: `git checkout -b feature/my-feature`
403
- 3. Make your changes and add tests
404
- 4. Run `pnpm typecheck` and `pnpm exec vitest`
405
- 5. Commit your changes following [Conventional Commits](https://www.conventionalcommits.org/)
406
- 6. Submit a pull request
55
+ - [Documentation](https://rayden-docs.vercel.app) Full component API and guides
56
+ - [Storybook](https://main--69b6d5d8527b4eddb882e0a7.chromatic.com) — Interactive component explorer
57
+ - [@raydenui/ai](https://www.npmjs.com/package/@raydenui/ai) — MCP server for AI-assisted development
407
58
 
408
59
  ## License
409
60
 
410
- MIT License - see [LICENSE](./LICENSE) for details.
411
-
412
- ## Acknowledgments
413
-
414
- - Design system based on [Rayna UI](https://raynaui.com) by Rayna UI Team
415
- - Built with [React](https://react.dev/), [Tailwind CSS](https://tailwindcss.com/), and [Storybook](https://storybook.js.org/)
416
-
417
- ---
418
-
419
- Made with care for the React community. By Ovalay Studios (https://ovalay.studio)
61
+ MIT