react-18-ui-library 0.1.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.
Files changed (156) hide show
  1. package/README.md +202 -0
  2. package/dist/components/actions/CopyButton/CopyButton.d.ts +14 -0
  3. package/dist/components/actions/CopyButton/index.d.ts +2 -0
  4. package/dist/components/display/Avatar/Avatar.d.ts +21 -0
  5. package/dist/components/display/Avatar/index.d.ts +2 -0
  6. package/dist/components/display/Badge/Badge.d.ts +20 -0
  7. package/dist/components/display/Badge/index.d.ts +2 -0
  8. package/dist/components/display/Box/Box.d.ts +18 -0
  9. package/dist/components/display/Box/index.d.ts +2 -0
  10. package/dist/components/display/Card/Card.d.ts +11 -0
  11. package/dist/components/display/Card/index.d.ts +2 -0
  12. package/dist/components/display/Collapsible/Collapsible.d.ts +15 -0
  13. package/dist/components/display/Collapsible/index.d.ts +2 -0
  14. package/dist/components/display/DataTable/DataTable.d.ts +46 -0
  15. package/dist/components/display/EmptyState/EmptyState.d.ts +10 -0
  16. package/dist/components/display/EmptyState/index.d.ts +2 -0
  17. package/dist/components/display/Icon/Icon.d.ts +9 -0
  18. package/dist/components/display/Icon/index.d.ts +2 -0
  19. package/dist/components/display/Image/Image.d.ts +15 -0
  20. package/dist/components/display/Image/index.d.ts +2 -0
  21. package/dist/components/display/List/List.d.ts +24 -0
  22. package/dist/components/display/List/index.d.ts +2 -0
  23. package/dist/components/display/MarkdownReader/MarkdownReader.d.ts +7 -0
  24. package/dist/components/display/SVG/SVG.d.ts +18 -0
  25. package/dist/components/display/SVG/index.d.ts +2 -0
  26. package/dist/components/display/Stat/Stat.d.ts +13 -0
  27. package/dist/components/display/Stat/index.d.ts +2 -0
  28. package/dist/components/display/Table/Table.d.ts +31 -0
  29. package/dist/components/display/Table/index.d.ts +2 -0
  30. package/dist/components/display/Tag/Tag.d.ts +16 -0
  31. package/dist/components/display/Tag/index.d.ts +2 -0
  32. package/dist/components/display/Timeline/Timeline.d.ts +15 -0
  33. package/dist/components/display/Timeline/index.d.ts +2 -0
  34. package/dist/components/display/TreeView/TreeView.d.ts +23 -0
  35. package/dist/components/display/TreeView/index.d.ts +2 -0
  36. package/dist/components/feedback/Alert/Alert.d.ts +15 -0
  37. package/dist/components/feedback/Alert/index.d.ts +2 -0
  38. package/dist/components/feedback/ErrorBoundary/ErrorBoundary.d.ts +18 -0
  39. package/dist/components/feedback/ErrorBoundary/index.d.ts +2 -0
  40. package/dist/components/feedback/FullScreenLoader/FullScreenLoader.d.ts +27 -0
  41. package/dist/components/feedback/ProgressBar/ProgressBar.d.ts +15 -0
  42. package/dist/components/feedback/ProgressBar/index.d.ts +2 -0
  43. package/dist/components/feedback/Skeleton/Skeleton.d.ts +16 -0
  44. package/dist/components/feedback/Skeleton/index.d.ts +2 -0
  45. package/dist/components/feedback/Spinner/Spinner.d.ts +9 -0
  46. package/dist/components/feedback/Spinner/index.d.ts +2 -0
  47. package/dist/components/feedback/Toast/Toast.d.ts +7 -0
  48. package/dist/components/feedback/Toast/index.d.ts +2 -0
  49. package/dist/components/forms/FileUpload/FileUpload.d.ts +24 -0
  50. package/dist/components/forms/FileUpload/index.d.ts +2 -0
  51. package/dist/components/forms/FormField/FormField.d.ts +12 -0
  52. package/dist/components/forms/FormField/index.d.ts +2 -0
  53. package/dist/components/forms/JSONForm/FormValidator.d.ts +157 -0
  54. package/dist/components/forms/JSONForm/JSONForm.d.ts +53 -0
  55. package/dist/components/forms/JSONForm/index.d.ts +4 -0
  56. package/dist/components/inputs/Button/Button.d.ts +15 -0
  57. package/dist/components/inputs/Button/index.d.ts +2 -0
  58. package/dist/components/inputs/Checkbox/Checkbox.d.ts +14 -0
  59. package/dist/components/inputs/Checkbox/index.d.ts +2 -0
  60. package/dist/components/inputs/ChipSelect/ChipSelect.d.ts +24 -0
  61. package/dist/components/inputs/DatePicker/DatePicker.d.ts +39 -0
  62. package/dist/components/inputs/DatePicker/index.d.ts +2 -0
  63. package/dist/components/inputs/IconButton/IconButton.d.ts +14 -0
  64. package/dist/components/inputs/IconButton/index.d.ts +2 -0
  65. package/dist/components/inputs/MultiSelect/MultiSelect.d.ts +35 -0
  66. package/dist/components/inputs/MultiSelect/index.d.ts +2 -0
  67. package/dist/components/inputs/NumberInput/NumberInput.d.ts +23 -0
  68. package/dist/components/inputs/NumberInput/index.d.ts +2 -0
  69. package/dist/components/inputs/OTPInput/OTPInput.d.ts +18 -0
  70. package/dist/components/inputs/OTPInput/index.d.ts +2 -0
  71. package/dist/components/inputs/PhoneInput/PhoneInput.d.ts +35 -0
  72. package/dist/components/inputs/PhoneInput/index.d.ts +2 -0
  73. package/dist/components/inputs/Radio/Radio.d.ts +20 -0
  74. package/dist/components/inputs/Radio/index.d.ts +2 -0
  75. package/dist/components/inputs/Rating/Rating.d.ts +19 -0
  76. package/dist/components/inputs/Rating/index.d.ts +2 -0
  77. package/dist/components/inputs/SearchSelect/SearchSelect.d.ts +39 -0
  78. package/dist/components/inputs/Select/Select.d.ts +25 -0
  79. package/dist/components/inputs/Select/index.d.ts +2 -0
  80. package/dist/components/inputs/Slider/Slider.d.ts +20 -0
  81. package/dist/components/inputs/Slider/index.d.ts +2 -0
  82. package/dist/components/inputs/Switch/Switch.d.ts +14 -0
  83. package/dist/components/inputs/Switch/index.d.ts +2 -0
  84. package/dist/components/inputs/TagInput/TagInput.d.ts +17 -0
  85. package/dist/components/inputs/TextArea/TextArea.d.ts +18 -0
  86. package/dist/components/inputs/TextArea/index.d.ts +2 -0
  87. package/dist/components/inputs/TextField/TextField.d.ts +21 -0
  88. package/dist/components/inputs/TextField/index.d.ts +2 -0
  89. package/dist/components/layout/AppShell/AppShell.d.ts +12 -0
  90. package/dist/components/layout/AppShell/index.d.ts +2 -0
  91. package/dist/components/layout/Container/Container.d.ts +8 -0
  92. package/dist/components/layout/Container/index.d.ts +2 -0
  93. package/dist/components/layout/Divider/Divider.d.ts +10 -0
  94. package/dist/components/layout/Divider/index.d.ts +2 -0
  95. package/dist/components/layout/Grid/Grid.d.ts +13 -0
  96. package/dist/components/layout/Grid/index.d.ts +2 -0
  97. package/dist/components/layout/Navbar/Navbar.d.ts +19 -0
  98. package/dist/components/layout/Navbar/index.d.ts +2 -0
  99. package/dist/components/layout/Sidebar/Sidebar.d.ts +24 -0
  100. package/dist/components/layout/Sidebar/index.d.ts +2 -0
  101. package/dist/components/layout/Spacer/Spacer.d.ts +6 -0
  102. package/dist/components/layout/Spacer/index.d.ts +2 -0
  103. package/dist/components/layout/Stack/Stack.d.ts +14 -0
  104. package/dist/components/layout/Stack/index.d.ts +2 -0
  105. package/dist/components/navigation/Breadcrumb/Breadcrumb.d.ts +13 -0
  106. package/dist/components/navigation/Breadcrumb/index.d.ts +2 -0
  107. package/dist/components/navigation/Pagination/Pagination.d.ts +10 -0
  108. package/dist/components/navigation/Pagination/index.d.ts +2 -0
  109. package/dist/components/navigation/StepIndicator/StepIndicator.d.ts +15 -0
  110. package/dist/components/navigation/StepIndicator/index.d.ts +2 -0
  111. package/dist/components/navigation/Tabs/Tabs.d.ts +25 -0
  112. package/dist/components/navigation/Tabs/index.d.ts +2 -0
  113. package/dist/components/overlay/CommandPalette/CommandPalette.d.ts +35 -0
  114. package/dist/components/overlay/CommandPalette/index.d.ts +2 -0
  115. package/dist/components/overlay/ConfirmDialog/ConfirmDialog.d.ts +20 -0
  116. package/dist/components/overlay/ContextMenu/ContextMenu.d.ts +19 -0
  117. package/dist/components/overlay/ContextMenu/index.d.ts +2 -0
  118. package/dist/components/overlay/Drawer/Drawer.d.ts +18 -0
  119. package/dist/components/overlay/Drawer/index.d.ts +2 -0
  120. package/dist/components/overlay/Modal/Modal.d.ts +17 -0
  121. package/dist/components/overlay/Modal/index.d.ts +2 -0
  122. package/dist/components/overlay/Popover/Popover.d.ts +15 -0
  123. package/dist/components/overlay/Popover/index.d.ts +2 -0
  124. package/dist/components/overlay/Tooltip/Tooltip.d.ts +13 -0
  125. package/dist/components/overlay/Tooltip/index.d.ts +2 -0
  126. package/dist/components/typography/Code/Code.d.ts +11 -0
  127. package/dist/components/typography/Code/index.d.ts +2 -0
  128. package/dist/components/typography/Heading/Heading.d.ts +12 -0
  129. package/dist/components/typography/Heading/index.d.ts +2 -0
  130. package/dist/components/typography/Kbd/Kbd.d.ts +8 -0
  131. package/dist/components/typography/Kbd/index.d.ts +2 -0
  132. package/dist/components/typography/Label/Label.d.ts +8 -0
  133. package/dist/components/typography/Label/index.d.ts +2 -0
  134. package/dist/components/typography/Link/Link.d.ts +9 -0
  135. package/dist/components/typography/Link/index.d.ts +2 -0
  136. package/dist/components/typography/Text/Text.d.ts +16 -0
  137. package/dist/components/typography/Text/index.d.ts +2 -0
  138. package/dist/hooks/useClickOutside.d.ts +2 -0
  139. package/dist/hooks/useClipboard.d.ts +11 -0
  140. package/dist/hooks/useDebounce.d.ts +1 -0
  141. package/dist/hooks/useIntersectionObserver.d.ts +5 -0
  142. package/dist/hooks/useKeyboard.d.ts +9 -0
  143. package/dist/hooks/useLocalStorage.d.ts +1 -0
  144. package/dist/hooks/useMediaQuery.d.ts +1 -0
  145. package/dist/hooks/useTheme.d.ts +4 -0
  146. package/dist/hooks/useToast.d.ts +16 -0
  147. package/dist/hooks/useWindowSize.d.ts +8 -0
  148. package/dist/index.cjs.js +3639 -0
  149. package/dist/index.cjs.js.map +1 -0
  150. package/dist/index.d.ts +1587 -0
  151. package/dist/index.esm.js +3512 -0
  152. package/dist/index.esm.js.map +1 -0
  153. package/dist/styles.css +1 -0
  154. package/dist/theme/ThemeProvider.d.ts +59 -0
  155. package/dist/utils/cn.d.ts +2 -0
  156. package/package.json +112 -0
package/README.md ADDED
@@ -0,0 +1,202 @@
1
+ # react-18-ui-library
2
+
3
+ A fully customizable, theme-aware React 18 enterprise UI component library. All components consume CSS custom properties from the parent app's `:root` — no hardcoded colors, no runtime CSS-in-JS overhead.
4
+
5
+ ## Quick Start
6
+
7
+ ```bash
8
+ npm install react-18-ui-library
9
+ ```
10
+
11
+ ```tsx
12
+ // 1. Import the default theme tokens (fallback values)
13
+ import 'react-18-ui-library/styles'
14
+
15
+ // 2. Use components directly — they read CSS vars from your app's :root
16
+ import { Button, TextField, AppShell } from 'react-18-ui-library'
17
+ ```
18
+
19
+ ## Theme System
20
+
21
+ Components read CSS custom properties from the parent app's `:root`. Override any token in your app's CSS:
22
+
23
+ ```css
24
+ /* your-app/globals.css */
25
+ :root {
26
+ --color-primary: #7c3aed;
27
+ --color-primary-hover: #6d28d9;
28
+ --color-primary-foreground: #ffffff;
29
+ --color-background: #fafafa;
30
+ --color-surface: #ffffff;
31
+ --color-text: #111827;
32
+ --radius-md: 0.5rem;
33
+ --font-family-base: 'Inter', sans-serif;
34
+ /* ...etc */
35
+ }
36
+ ```
37
+
38
+ Or use the optional `ThemeProvider` to set tokens programmatically:
39
+
40
+ ```tsx
41
+ import { ThemeProvider } from 'react-18-ui-library'
42
+
43
+ <ThemeProvider tokens={{ colorPrimary: '#7c3aed', radiusMd: '0.5rem' }}>
44
+ <App />
45
+ </ThemeProvider>
46
+ ```
47
+
48
+ ## Component Categories
49
+
50
+ | Category | Components |
51
+ |---|---|
52
+ | **Layout** | `AppShell`, `Navbar`, `Sidebar`, `Container`, `Stack`, `Grid`, `Divider`, `Spacer` |
53
+ | **Navigation** | `Tabs`, `Breadcrumb`, `Pagination`, `StepIndicator` |
54
+ | **Inputs** | `Button`, `IconButton`, `TextField`, `TextArea`, `Select`, `Checkbox`, `RadioGroup`, `Switch` |
55
+ | **Forms** | `FormField`, `JSONForm`, `FileUpload` |
56
+ | **Display** | `Card`, `Box`, `Image`, `Avatar`, `Badge`, `Tag`, `Icon`, `SVG`, `Table`, `List`, `Timeline`, `Stat`, `EmptyState` |
57
+ | **Feedback** | `Alert`, `ToastProvider`, `Spinner`, `Skeleton`, `ProgressBar`, `ErrorBoundary` |
58
+ | **Overlay** | `Modal`, `Drawer`, `Tooltip`, `Popover`, `ContextMenu` |
59
+ | **Typography** | `Heading`, `Text`, `Label`, `Code`, `Link` |
60
+
61
+ ## Key Components
62
+
63
+ ### AppShell — Full Layout
64
+
65
+ ```tsx
66
+ import { AppShell } from 'react-18-ui-library'
67
+ import { LayoutDashboard, Users, Settings } from 'lucide-react'
68
+
69
+ <AppShell
70
+ navbar={{
71
+ logo: <Logo />,
72
+ links: [{ label: 'Home', href: '/', active: true }],
73
+ actions: <Button size="sm">Sign Out</Button>,
74
+ }}
75
+ sidebar={{
76
+ items: [
77
+ { id: 'dash', label: 'Dashboard', icon: <LayoutDashboard size={16} />, active: true },
78
+ { id: 'users', label: 'Users', icon: <Users size={16} />, badge: 5 },
79
+ { id: 'settings', label: 'Settings', icon: <Settings size={16} /> },
80
+ ],
81
+ }}
82
+ >
83
+ <main>Your page content</main>
84
+ </AppShell>
85
+ ```
86
+
87
+ ### TextField — Prefix / Suffix
88
+
89
+ ```tsx
90
+ <TextField
91
+ label="Amount"
92
+ prefixText="$"
93
+ suffixText="USD"
94
+ placeholder="0.00"
95
+ />
96
+
97
+ <TextField
98
+ label="Search"
99
+ prefixIcon={<Search size={14} />}
100
+ clearable
101
+ />
102
+
103
+ <TextField
104
+ label="Phone"
105
+ prefixImage="/flags/us.png"
106
+ prefixText="+1"
107
+ type="tel"
108
+ />
109
+ ```
110
+
111
+ ### JSONForm — Schema-Driven Forms
112
+
113
+ ```tsx
114
+ import { JSONForm } from 'react-18-ui-library'
115
+ import type { JSONFormField } from 'react-18-ui-library'
116
+
117
+ const schema: JSONFormField[] = [
118
+ { name: 'name', type: 'text', label: 'Full Name', required: true, prefixIcon: <User size={14} /> },
119
+ { name: 'email', type: 'email', label: 'Email', required: true, prefixIcon: <Mail size={14} /> },
120
+ { name: 'role', type: 'select', label: 'Role', options: [{ value: 'admin', label: 'Admin' }] },
121
+ { name: 'bio', type: 'textarea', label: 'Bio', showCharCount: true, validation: { maxLength: 200 } },
122
+ ]
123
+
124
+ <JSONForm
125
+ schema={schema}
126
+ columns={2}
127
+ onSubmit={(data) => console.log(data)}
128
+ submitLabel="Save"
129
+ />
130
+ ```
131
+
132
+ ### FileUpload — Drag & Drop
133
+
134
+ ```tsx
135
+ import { FileUpload } from 'react-18-ui-library'
136
+
137
+ <FileUpload
138
+ label="Upload Documents"
139
+ accept={{ 'image/*': ['.png', '.jpg'], 'application/pdf': ['.pdf'] }}
140
+ maxSize={5 * 1024 * 1024}
141
+ maxFiles={10}
142
+ files={files}
143
+ onFilesChange={setFiles}
144
+ onFileRemove={(id) => setFiles(prev => prev.filter(f => f.id !== id))}
145
+ />
146
+ ```
147
+
148
+ ### Toast Notifications
149
+
150
+ ```tsx
151
+ import { ToastProvider, useToast } from 'react-18-ui-library'
152
+
153
+ // Wrap your app
154
+ <ToastProvider toasts={toasts} onDismiss={dismiss} position="bottom-right" />
155
+
156
+ // In any component
157
+ const { toast } = useToast()
158
+ toast({ title: 'Saved!', description: 'Changes saved successfully.', variant: 'success' })
159
+ ```
160
+
161
+ ## Development
162
+
163
+ ```bash
164
+ # Install dependencies
165
+ npm install
166
+
167
+ # Start Storybook
168
+ npm run dev
169
+
170
+ # Build library
171
+ npm run build
172
+
173
+ # Run tests
174
+ npm test
175
+ ```
176
+
177
+ ## CSS Token Reference
178
+
179
+ | Token | Default | Purpose |
180
+ |---|---|---|
181
+ | `--color-primary` | `#6366f1` | Primary brand color |
182
+ | `--color-background` | `#f8fafc` | Page background |
183
+ | `--color-surface` | `#ffffff` | Card/panel background |
184
+ | `--color-text` | `#0f172a` | Primary text |
185
+ | `--color-text-muted` | `#64748b` | Secondary text |
186
+ | `--color-border` | `#e2e8f0` | Border color |
187
+ | `--color-error` | `#ef4444` | Error state |
188
+ | `--color-success` | `#22c55e` | Success state |
189
+ | `--radius-md` | `0.375rem` | Default border radius |
190
+ | `--font-family-base` | system-ui | Base font |
191
+ | `--navbar-height` | `64px` | Navbar height |
192
+ | `--sidebar-width` | `260px` | Sidebar expanded width |
193
+ | `--sidebar-collapsed-width` | `64px` | Sidebar collapsed width |
194
+
195
+ ## Peer Dependencies
196
+
197
+ - `react >= 18.0.0`
198
+ - `react-dom >= 18.0.0`
199
+
200
+ ## License
201
+
202
+ MIT
@@ -0,0 +1,14 @@
1
+ export type CopyButtonSize = 'sm' | 'md' | 'lg';
2
+ export type CopyButtonVariant = 'ghost' | 'outline' | 'solid';
3
+ export interface CopyButtonProps {
4
+ value: string;
5
+ size?: CopyButtonSize;
6
+ variant?: CopyButtonVariant;
7
+ label?: string;
8
+ copiedLabel?: string;
9
+ timeout?: number;
10
+ onCopy?: (value: string) => void;
11
+ className?: string;
12
+ disabled?: boolean;
13
+ }
14
+ export declare function CopyButton({ value, size, variant, label, copiedLabel, timeout, onCopy, className, disabled, }: CopyButtonProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { CopyButton } from './CopyButton';
2
+ export type { CopyButtonProps, CopyButtonSize, CopyButtonVariant } from './CopyButton';
@@ -0,0 +1,21 @@
1
+ import React from 'react';
2
+ export type AvatarSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';
3
+ export type AvatarStatus = 'online' | 'offline' | 'away' | 'busy';
4
+ export interface AvatarProps {
5
+ src?: string;
6
+ alt?: string;
7
+ name?: string;
8
+ icon?: React.ReactNode;
9
+ size?: AvatarSize;
10
+ status?: AvatarStatus;
11
+ rounded?: boolean;
12
+ className?: string;
13
+ }
14
+ export interface AvatarGroupProps {
15
+ avatars: AvatarProps[];
16
+ max?: number;
17
+ size?: AvatarSize;
18
+ className?: string;
19
+ }
20
+ export declare function Avatar({ src, alt, name, icon, size, status, rounded, className, }: AvatarProps): import("react/jsx-runtime").JSX.Element;
21
+ export declare function AvatarGroup({ avatars, max, size, className }: AvatarGroupProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { Avatar, AvatarGroup } from './Avatar';
2
+ export type { AvatarProps, AvatarGroupProps, AvatarSize, AvatarStatus } from './Avatar';
@@ -0,0 +1,20 @@
1
+ import React from 'react';
2
+ import { type VariantProps } from 'class-variance-authority';
3
+ declare const badgeVariants: (props?: ({
4
+ variant?: "error" | "info" | "success" | "warning" | "primary" | "secondary" | "outline" | "ghost" | null | undefined;
5
+ size?: "sm" | "md" | "lg" | null | undefined;
6
+ dot?: boolean | null | undefined;
7
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
8
+ export interface BadgeProps extends VariantProps<typeof badgeVariants> {
9
+ children?: React.ReactNode;
10
+ className?: string;
11
+ }
12
+ export declare function Badge({ variant, size, dot, children, className }: BadgeProps): import("react/jsx-runtime").JSX.Element;
13
+ export interface BadgeAnchorProps {
14
+ children: React.ReactNode;
15
+ badge?: React.ReactNode;
16
+ position?: 'top-right' | 'top-left' | 'bottom-right' | 'bottom-left';
17
+ className?: string;
18
+ }
19
+ export declare function BadgeAnchor({ children, badge, position, className }: BadgeAnchorProps): import("react/jsx-runtime").JSX.Element;
20
+ export {};
@@ -0,0 +1,2 @@
1
+ export { Badge, BadgeAnchor } from './Badge';
2
+ export type { BadgeProps, BadgeAnchorProps } from './Badge';
@@ -0,0 +1,18 @@
1
+ import React from 'react';
2
+ export interface BoxProps {
3
+ as?: 'div' | 'section' | 'article' | 'aside' | 'main' | 'header' | 'footer' | 'nav' | 'span' | 'p';
4
+ bg?: 'surface' | 'background' | 'primary' | 'secondary' | 'error' | 'success' | 'warning' | 'info';
5
+ rounded?: 'none' | 'sm' | 'md' | 'lg' | 'xl' | 'full';
6
+ shadow?: 'none' | 'sm' | 'md' | 'lg';
7
+ bordered?: boolean;
8
+ padding?: 'none' | 'xs' | 'sm' | 'md' | 'lg' | 'xl';
9
+ className?: string;
10
+ children?: React.ReactNode;
11
+ style?: React.CSSProperties;
12
+ id?: string;
13
+ onClick?: React.MouseEventHandler<HTMLDivElement>;
14
+ role?: string;
15
+ tabIndex?: number;
16
+ 'aria-label'?: string;
17
+ }
18
+ export declare function Box({ as: Component, bg, rounded, shadow, bordered, padding, className, children, ...props }: BoxProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { Box } from './Box';
2
+ export type { BoxProps } from './Box';
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ export interface CardProps extends React.HTMLAttributes<HTMLDivElement> {
3
+ header?: React.ReactNode;
4
+ footer?: React.ReactNode;
5
+ hoverable?: boolean;
6
+ clickable?: boolean;
7
+ bordered?: boolean;
8
+ shadow?: 'none' | 'sm' | 'md' | 'lg';
9
+ padding?: 'none' | 'sm' | 'md' | 'lg';
10
+ }
11
+ export declare function Card({ header, footer, hoverable, clickable, bordered, shadow, padding, className, children, onClick, ...props }: CardProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { Card } from './Card';
2
+ export type { CardProps } from './Card';
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ export interface CollapsibleProps {
3
+ title: React.ReactNode;
4
+ children: React.ReactNode;
5
+ defaultOpen?: boolean;
6
+ open?: boolean;
7
+ onOpenChange?: (open: boolean) => void;
8
+ disabled?: boolean;
9
+ icon?: React.ReactNode;
10
+ variant?: 'default' | 'bordered' | 'filled';
11
+ className?: string;
12
+ triggerClassName?: string;
13
+ contentClassName?: string;
14
+ }
15
+ export declare function Collapsible({ title, children, defaultOpen, open: controlledOpen, onOpenChange, disabled, icon, variant, className, triggerClassName, contentClassName, }: CollapsibleProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { Collapsible } from './Collapsible';
2
+ export type { CollapsibleProps } from './Collapsible';
@@ -0,0 +1,46 @@
1
+ import React from 'react';
2
+ export type SortDirection = 'asc' | 'desc' | null;
3
+ export interface DataTableColumn<T = Record<string, unknown>> {
4
+ key: string;
5
+ header: React.ReactNode;
6
+ accessor?: (row: T) => React.ReactNode;
7
+ sortValue?: (row: T) => string | number;
8
+ sortable?: boolean;
9
+ width?: string | number;
10
+ align?: 'left' | 'center' | 'right';
11
+ className?: string;
12
+ pin?: 'left' | 'right';
13
+ }
14
+ export interface DataTablePagination {
15
+ mode: 'client' | 'server';
16
+ pageSize?: number;
17
+ pageSizeOptions?: number[];
18
+ totalRows?: number;
19
+ page?: number;
20
+ onPageChange?: (page: number) => void;
21
+ onPageSizeChange?: (size: number) => void;
22
+ }
23
+ export interface DataTableProps<T = Record<string, unknown>> {
24
+ columns: DataTableColumn<T>[];
25
+ data: T[];
26
+ keyExtractor: (row: T, index: number) => string;
27
+ selectable?: boolean;
28
+ selectedKeys?: string[];
29
+ onSelectionChange?: (keys: string[]) => void;
30
+ sortKey?: string;
31
+ sortDirection?: SortDirection;
32
+ onSortChange?: (key: string, direction: SortDirection) => void;
33
+ loading?: boolean;
34
+ emptyMessage?: React.ReactNode;
35
+ stickyHeader?: boolean;
36
+ striped?: boolean;
37
+ hoverable?: boolean;
38
+ bordered?: boolean;
39
+ compact?: boolean;
40
+ className?: string;
41
+ pagination?: DataTablePagination;
42
+ toolbar?: React.ReactNode;
43
+ rowActions?: (row: T) => React.ReactNode;
44
+ caption?: string;
45
+ }
46
+ export declare function DataTable<T = Record<string, unknown>>({ columns, data, keyExtractor, selectable, selectedKeys, onSelectionChange, sortKey, sortDirection, onSortChange, loading, emptyMessage, stickyHeader, striped, hoverable, bordered, compact, className, pagination, toolbar, rowActions, caption, }: DataTableProps<T>): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ export interface EmptyStateProps {
3
+ title?: string;
4
+ description?: string;
5
+ illustration?: React.ReactNode;
6
+ icon?: React.ReactNode;
7
+ action?: React.ReactNode;
8
+ className?: string;
9
+ }
10
+ export declare function EmptyState({ title, description, illustration, icon, action, className, }: EmptyStateProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { EmptyState } from './EmptyState';
2
+ export type { EmptyStateProps } from './EmptyState';
@@ -0,0 +1,9 @@
1
+ import { type LucideIcon, type LucideProps } from 'lucide-react';
2
+ export type IconSize = 'xs' | 'sm' | 'md' | 'lg' | 'xl';
3
+ export interface IconProps extends Omit<LucideProps, 'size'> {
4
+ icon: LucideIcon;
5
+ size?: IconSize | number;
6
+ color?: string;
7
+ className?: string;
8
+ }
9
+ export declare function Icon({ icon: LucideIconComponent, size, color, className, ...props }: IconProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { Icon } from './Icon';
2
+ export type { IconProps, IconSize } from './Icon';
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ export type ImageFit = 'cover' | 'contain' | 'fill' | 'none' | 'scale-down';
3
+ export type ImageRatio = '1/1' | '4/3' | '16/9' | '3/2' | '2/3' | 'auto';
4
+ export interface ImageProps extends Omit<React.ImgHTMLAttributes<HTMLImageElement>, 'src'> {
5
+ src: string;
6
+ fallbackSrc?: string;
7
+ fallbackIcon?: React.ReactNode;
8
+ fit?: ImageFit;
9
+ ratio?: ImageRatio;
10
+ lazy?: boolean;
11
+ rounded?: 'none' | 'sm' | 'md' | 'lg' | 'xl' | 'full';
12
+ blur?: boolean;
13
+ containerClassName?: string;
14
+ }
15
+ export declare function Image({ src, fallbackSrc, fallbackIcon, fit, ratio, lazy, rounded, blur, containerClassName, className, alt, ...props }: ImageProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { Image } from './Image';
2
+ export type { ImageProps, ImageFit, ImageRatio } from './Image';
@@ -0,0 +1,24 @@
1
+ import React from 'react';
2
+ export interface ListItemProps {
3
+ id?: string;
4
+ primary: React.ReactNode;
5
+ secondary?: React.ReactNode;
6
+ leading?: React.ReactNode;
7
+ trailing?: React.ReactNode;
8
+ onClick?: () => void;
9
+ active?: boolean;
10
+ disabled?: boolean;
11
+ divider?: boolean;
12
+ className?: string;
13
+ }
14
+ export interface ListProps {
15
+ items?: ListItemProps[];
16
+ ordered?: boolean;
17
+ divided?: boolean;
18
+ hoverable?: boolean;
19
+ compact?: boolean;
20
+ children?: React.ReactNode;
21
+ className?: string;
22
+ }
23
+ export declare function ListItem({ primary, secondary, leading, trailing, onClick, active, disabled, divider, className, }: ListItemProps): import("react/jsx-runtime").JSX.Element;
24
+ export declare function List({ items, ordered, divided, hoverable, compact, children, className, }: ListProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { List, ListItem } from './List';
2
+ export type { ListProps, ListItemProps } from './List';
@@ -0,0 +1,7 @@
1
+ export interface MarkdownReaderProps {
2
+ children: string;
3
+ className?: string;
4
+ codeTheme?: 'dark' | 'light';
5
+ showLineNumbers?: boolean;
6
+ }
7
+ export declare function MarkdownReader({ children, className, codeTheme, showLineNumbers, }: MarkdownReaderProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,18 @@
1
+ import React from 'react';
2
+ export interface SVGProps {
3
+ src?: string;
4
+ children?: React.ReactNode;
5
+ width?: number | string;
6
+ height?: number | string;
7
+ size?: number | string;
8
+ color?: string;
9
+ className?: string;
10
+ title?: string;
11
+ role?: string;
12
+ 'aria-label'?: string;
13
+ 'aria-hidden'?: boolean | 'true' | 'false';
14
+ viewBox?: string;
15
+ fill?: string;
16
+ stroke?: string;
17
+ }
18
+ export declare function SVG({ src, children, width, height, size, color, className, title, role, viewBox, fill, stroke, ...props }: SVGProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { SVG } from './SVG';
2
+ export type { SVGProps } from './SVG';
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ export interface StatProps {
3
+ label: string;
4
+ value: React.ReactNode;
5
+ delta?: number;
6
+ deltaLabel?: string;
7
+ icon?: React.ReactNode;
8
+ iconBg?: 'primary' | 'success' | 'error' | 'warning' | 'info';
9
+ description?: string;
10
+ loading?: boolean;
11
+ className?: string;
12
+ }
13
+ export declare function Stat({ label, value, delta, deltaLabel, icon, iconBg, description, loading, className, }: StatProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { Stat } from './Stat';
2
+ export type { StatProps } from './Stat';
@@ -0,0 +1,31 @@
1
+ import React from 'react';
2
+ export type SortDirection = 'asc' | 'desc' | null;
3
+ export interface TableColumn<T = Record<string, unknown>> {
4
+ key: string;
5
+ header: React.ReactNode;
6
+ accessor?: (row: T) => React.ReactNode;
7
+ sortable?: boolean;
8
+ width?: string | number;
9
+ align?: 'left' | 'center' | 'right';
10
+ className?: string;
11
+ }
12
+ export interface TableProps<T = Record<string, unknown>> {
13
+ columns: TableColumn<T>[];
14
+ data: T[];
15
+ keyExtractor: (row: T, index: number) => string;
16
+ selectable?: boolean;
17
+ selectedKeys?: string[];
18
+ onSelectionChange?: (keys: string[]) => void;
19
+ sortKey?: string;
20
+ sortDirection?: SortDirection;
21
+ onSortChange?: (key: string, direction: SortDirection) => void;
22
+ loading?: boolean;
23
+ emptyMessage?: React.ReactNode;
24
+ stickyHeader?: boolean;
25
+ striped?: boolean;
26
+ hoverable?: boolean;
27
+ bordered?: boolean;
28
+ compact?: boolean;
29
+ className?: string;
30
+ }
31
+ export declare function Table<T = Record<string, unknown>>({ columns, data, keyExtractor, selectable, selectedKeys, onSelectionChange, sortKey, sortDirection, onSortChange, loading, emptyMessage, stickyHeader, striped, hoverable, bordered, compact, className, }: TableProps<T>): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { Table } from './Table';
2
+ export type { TableProps, TableColumn, SortDirection } from './Table';
@@ -0,0 +1,16 @@
1
+ import React from 'react';
2
+ import { type VariantProps } from 'class-variance-authority';
3
+ declare const tagVariants: (props?: ({
4
+ variant?: "error" | "info" | "success" | "warning" | "default" | "primary" | null | undefined;
5
+ size?: "sm" | "md" | "lg" | null | undefined;
6
+ rounded?: boolean | null | undefined;
7
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
8
+ export interface TagProps extends VariantProps<typeof tagVariants> {
9
+ children: React.ReactNode;
10
+ icon?: React.ReactNode;
11
+ removable?: boolean;
12
+ onRemove?: () => void;
13
+ className?: string;
14
+ }
15
+ export declare function Tag({ variant, size, rounded, children, icon, removable, onRemove, className }: TagProps): import("react/jsx-runtime").JSX.Element;
16
+ export {};
@@ -0,0 +1,2 @@
1
+ export { Tag } from './Tag';
2
+ export type { TagProps } from './Tag';
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ export interface TimelineItem {
3
+ id: string;
4
+ title: React.ReactNode;
5
+ description?: React.ReactNode;
6
+ timestamp?: React.ReactNode;
7
+ icon?: React.ReactNode;
8
+ variant?: 'default' | 'success' | 'error' | 'warning' | 'info';
9
+ }
10
+ export interface TimelineProps {
11
+ items: TimelineItem[];
12
+ orientation?: 'vertical' | 'horizontal';
13
+ className?: string;
14
+ }
15
+ export declare function Timeline({ items, orientation, className }: TimelineProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { Timeline } from './Timeline';
2
+ export type { TimelineProps, TimelineItem } from './Timeline';
@@ -0,0 +1,23 @@
1
+ import React from 'react';
2
+ export interface TreeViewItem {
3
+ id: string;
4
+ label: React.ReactNode;
5
+ icon?: React.ReactNode;
6
+ children?: TreeViewItem[];
7
+ disabled?: boolean;
8
+ badge?: React.ReactNode;
9
+ }
10
+ export interface TreeViewProps {
11
+ items: TreeViewItem[];
12
+ selectedId?: string;
13
+ onSelect?: (id: string, item: TreeViewItem) => void;
14
+ defaultExpandedIds?: string[];
15
+ expandedIds?: string[];
16
+ onExpandedChange?: (ids: string[]) => void;
17
+ multiSelect?: boolean;
18
+ selectedIds?: string[];
19
+ onMultiSelect?: (ids: string[]) => void;
20
+ indent?: number;
21
+ className?: string;
22
+ }
23
+ export declare function TreeView({ items, selectedId, onSelect, defaultExpandedIds, expandedIds: controlledExpandedIds, onExpandedChange, multiSelect, selectedIds, onMultiSelect, indent, className, }: TreeViewProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { TreeView } from './TreeView';
2
+ export type { TreeViewProps, TreeViewItem } from './TreeView';
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ import { type VariantProps } from 'class-variance-authority';
3
+ declare const alertVariants: (props?: ({
4
+ variant?: "error" | "info" | "success" | "warning" | null | undefined;
5
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
6
+ export interface AlertProps extends VariantProps<typeof alertVariants> {
7
+ title?: string;
8
+ children?: React.ReactNode;
9
+ dismissible?: boolean;
10
+ onDismiss?: () => void;
11
+ icon?: React.ReactNode;
12
+ className?: string;
13
+ }
14
+ export declare function Alert({ variant, title, children, dismissible, onDismiss, icon, className, }: AlertProps): import("react/jsx-runtime").JSX.Element | null;
15
+ export {};
@@ -0,0 +1,2 @@
1
+ export { Alert } from './Alert';
2
+ export type { AlertProps } from './Alert';