@camstack/ui-library 0.1.25
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/assets/brand/stacked-lens-current.svg +14 -0
- package/assets/brand/stacked-lens-light.svg +13 -0
- package/assets/brand/stacked-lens-mono.svg +13 -0
- package/assets/brand/stacked-lens-primary.svg +13 -0
- package/dist/index.cjs +2086 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +415 -0
- package/dist/index.d.ts +415 -0
- package/dist/index.js +2043 -0
- package/dist/index.js.map +1 -0
- package/dist/theme/index.cjs +306 -0
- package/dist/theme/index.cjs.map +1 -0
- package/dist/theme/index.d.cts +128 -0
- package/dist/theme/index.d.ts +128 -0
- package/dist/theme/index.js +273 -0
- package/dist/theme/index.js.map +1 -0
- package/package.json +58 -0
- package/src/tailwind/camstack-theme.css +96 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,415 @@
|
|
|
1
|
+
export { CamStackColorTokens, CamStackTheme, DeepPartial, ThemeMode, ThemeProvider, UseThemeModeReturn, createTheme, darkColors, defaultTheme, lightColors, themeToCss, useThemeMode } from './theme/index.js';
|
|
2
|
+
import { ClassValue } from 'clsx';
|
|
3
|
+
import { LucideIcon } from 'lucide-react';
|
|
4
|
+
import * as react from 'react';
|
|
5
|
+
import { ButtonHTMLAttributes, HTMLAttributes, LabelHTMLAttributes, InputHTMLAttributes, ReactNode, SelectHTMLAttributes } from 'react';
|
|
6
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
7
|
+
import { VariantProps } from 'class-variance-authority';
|
|
8
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
9
|
+
import { ColumnDef, SortingState, ColumnFiltersState, PaginationState } from '@tanstack/react-table';
|
|
10
|
+
export { ColumnDef, ColumnFiltersState, PaginationState, SortingState } from '@tanstack/react-table';
|
|
11
|
+
|
|
12
|
+
declare function cn(...inputs: ClassValue[]): string;
|
|
13
|
+
|
|
14
|
+
type ProviderType = 'frigate' | 'scrypted' | 'reolink' | 'homeAssistant' | 'rtsp';
|
|
15
|
+
declare const providerIcons: Record<ProviderType, LucideIcon>;
|
|
16
|
+
|
|
17
|
+
type StatusType = 'online' | 'offline' | 'degraded' | 'unknown';
|
|
18
|
+
declare const statusIcons: Record<StatusType, LucideIcon>;
|
|
19
|
+
|
|
20
|
+
declare const buttonVariants: (props?: ({
|
|
21
|
+
variant?: "primary" | "danger" | "secondary" | "ghost" | "outline" | null | undefined;
|
|
22
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
23
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
24
|
+
interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
|
|
25
|
+
}
|
|
26
|
+
declare const Button: react.ForwardRefExoticComponent<ButtonProps & react.RefAttributes<HTMLButtonElement>>;
|
|
27
|
+
|
|
28
|
+
declare const iconButtonVariants: (props?: ({
|
|
29
|
+
variant?: "primary" | "danger" | "secondary" | "ghost" | "outline" | null | undefined;
|
|
30
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
31
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
32
|
+
interface IconButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'children'>, VariantProps<typeof iconButtonVariants> {
|
|
33
|
+
icon: LucideIcon;
|
|
34
|
+
'aria-label': string;
|
|
35
|
+
}
|
|
36
|
+
declare const IconButton: react.ForwardRefExoticComponent<IconButtonProps & react.RefAttributes<HTMLButtonElement>>;
|
|
37
|
+
|
|
38
|
+
declare const badgeVariants: (props?: ({
|
|
39
|
+
variant?: "success" | "warning" | "danger" | "info" | "default" | null | undefined;
|
|
40
|
+
styleVariant?: "outline" | "solid" | null | undefined;
|
|
41
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
42
|
+
interface BadgeProps extends Omit<HTMLAttributes<HTMLSpanElement>, 'style'>, VariantProps<typeof badgeVariants> {
|
|
43
|
+
style?: 'solid' | 'outline';
|
|
44
|
+
}
|
|
45
|
+
declare const Badge: react.ForwardRefExoticComponent<BadgeProps & react.RefAttributes<HTMLSpanElement>>;
|
|
46
|
+
|
|
47
|
+
declare const cardVariants: (props?: ({
|
|
48
|
+
variant?: "flat" | "bordered" | null | undefined;
|
|
49
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
50
|
+
interface CardProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof cardVariants> {
|
|
51
|
+
}
|
|
52
|
+
declare const Card: react.ForwardRefExoticComponent<CardProps & react.RefAttributes<HTMLDivElement>>;
|
|
53
|
+
|
|
54
|
+
interface LabelProps extends LabelHTMLAttributes<HTMLLabelElement> {
|
|
55
|
+
}
|
|
56
|
+
declare const Label: react.ForwardRefExoticComponent<LabelProps & react.RefAttributes<HTMLLabelElement>>;
|
|
57
|
+
|
|
58
|
+
declare const separatorVariants: (props?: ({
|
|
59
|
+
orientation?: "horizontal" | "vertical" | null | undefined;
|
|
60
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
61
|
+
interface SeparatorProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof separatorVariants> {
|
|
62
|
+
}
|
|
63
|
+
declare const Separator: react.ForwardRefExoticComponent<SeparatorProps & react.RefAttributes<HTMLDivElement>>;
|
|
64
|
+
|
|
65
|
+
interface SkeletonProps extends HTMLAttributes<HTMLDivElement> {
|
|
66
|
+
}
|
|
67
|
+
declare const Skeleton: react.ForwardRefExoticComponent<SkeletonProps & react.RefAttributes<HTMLDivElement>>;
|
|
68
|
+
|
|
69
|
+
declare const inputVariants: (props?: ({
|
|
70
|
+
state?: "default" | "error" | null | undefined;
|
|
71
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
72
|
+
interface InputProps extends InputHTMLAttributes<HTMLInputElement>, VariantProps<typeof inputVariants> {
|
|
73
|
+
leftSlot?: ReactNode;
|
|
74
|
+
rightSlot?: ReactNode;
|
|
75
|
+
}
|
|
76
|
+
declare const Input: react.ForwardRefExoticComponent<InputProps & react.RefAttributes<HTMLInputElement>>;
|
|
77
|
+
|
|
78
|
+
interface SelectOption {
|
|
79
|
+
value: string;
|
|
80
|
+
label: string;
|
|
81
|
+
}
|
|
82
|
+
interface SelectProps extends SelectHTMLAttributes<HTMLSelectElement> {
|
|
83
|
+
options: SelectOption[];
|
|
84
|
+
}
|
|
85
|
+
declare const Select: react.ForwardRefExoticComponent<SelectProps & react.RefAttributes<HTMLSelectElement>>;
|
|
86
|
+
|
|
87
|
+
interface CheckboxProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'type'> {
|
|
88
|
+
}
|
|
89
|
+
declare const Checkbox: react.ForwardRefExoticComponent<CheckboxProps & react.RefAttributes<HTMLInputElement>>;
|
|
90
|
+
|
|
91
|
+
interface SwitchProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'onClick'> {
|
|
92
|
+
checked: boolean;
|
|
93
|
+
onCheckedChange: (checked: boolean) => void;
|
|
94
|
+
label?: string;
|
|
95
|
+
}
|
|
96
|
+
declare const Switch: react.ForwardRefExoticComponent<SwitchProps & react.RefAttributes<HTMLButtonElement>>;
|
|
97
|
+
|
|
98
|
+
interface DialogProps {
|
|
99
|
+
children: ReactNode;
|
|
100
|
+
open?: boolean;
|
|
101
|
+
onOpenChange?: (open: boolean) => void;
|
|
102
|
+
}
|
|
103
|
+
declare function Dialog({ children, open: controlledOpen, onOpenChange }: DialogProps): react_jsx_runtime.JSX.Element;
|
|
104
|
+
declare function DialogTrigger({ children, ...props }: HTMLAttributes<HTMLButtonElement>): react_jsx_runtime.JSX.Element;
|
|
105
|
+
declare const contentVariants: (props?: ({
|
|
106
|
+
width?: "sm" | "md" | "lg" | null | undefined;
|
|
107
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
108
|
+
interface DialogContentProps extends HTMLAttributes<HTMLDialogElement>, VariantProps<typeof contentVariants> {
|
|
109
|
+
}
|
|
110
|
+
declare const DialogContent: react.ForwardRefExoticComponent<DialogContentProps & react.RefAttributes<HTMLDialogElement>>;
|
|
111
|
+
declare function DialogHeader({ className, ...props }: HTMLAttributes<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
112
|
+
declare function DialogFooter({ className, ...props }: HTMLAttributes<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
113
|
+
declare function DialogTitle({ className, ...props }: HTMLAttributes<HTMLHeadingElement>): react_jsx_runtime.JSX.Element;
|
|
114
|
+
declare function DialogDescription({ className, ...props }: HTMLAttributes<HTMLParagraphElement>): react_jsx_runtime.JSX.Element;
|
|
115
|
+
|
|
116
|
+
declare function Dropdown({ children }: {
|
|
117
|
+
children: ReactNode;
|
|
118
|
+
}): react_jsx_runtime.JSX.Element;
|
|
119
|
+
declare function DropdownTrigger({ children, ...props }: ButtonHTMLAttributes<HTMLButtonElement>): react_jsx_runtime.JSX.Element;
|
|
120
|
+
declare function DropdownContent({ className, children, ...props }: HTMLAttributes<HTMLDivElement>): react_jsx_runtime.JSX.Element | null;
|
|
121
|
+
interface DropdownItemProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
122
|
+
icon?: LucideIcon;
|
|
123
|
+
variant?: 'default' | 'danger';
|
|
124
|
+
}
|
|
125
|
+
declare function DropdownItem({ className, icon: Icon, variant, children, onClick, ...props }: DropdownItemProps): react_jsx_runtime.JSX.Element;
|
|
126
|
+
|
|
127
|
+
declare function Tooltip({ children }: {
|
|
128
|
+
children: ReactNode;
|
|
129
|
+
}): react_jsx_runtime.JSX.Element;
|
|
130
|
+
declare function TooltipTrigger({ children, ...props }: HTMLAttributes<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
131
|
+
declare function TooltipContent({ className, children, ...props }: HTMLAttributes<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
132
|
+
|
|
133
|
+
interface PopoverProps {
|
|
134
|
+
children: ReactNode;
|
|
135
|
+
open?: boolean;
|
|
136
|
+
onOpenChange?: (open: boolean) => void;
|
|
137
|
+
}
|
|
138
|
+
declare function Popover({ children, open: controlledOpen, onOpenChange }: PopoverProps): react_jsx_runtime.JSX.Element;
|
|
139
|
+
declare function PopoverTrigger({ children, ...props }: ButtonHTMLAttributes<HTMLButtonElement>): react_jsx_runtime.JSX.Element;
|
|
140
|
+
declare function PopoverContent({ className, children, ...props }: HTMLAttributes<HTMLDivElement>): react_jsx_runtime.JSX.Element | null;
|
|
141
|
+
|
|
142
|
+
interface TabsProps extends HTMLAttributes<HTMLDivElement> {
|
|
143
|
+
value?: string;
|
|
144
|
+
onValueChange?: (value: string) => void;
|
|
145
|
+
defaultValue?: string;
|
|
146
|
+
}
|
|
147
|
+
declare function Tabs({ value: controlledValue, onValueChange, defaultValue, className, ...props }: TabsProps): react_jsx_runtime.JSX.Element;
|
|
148
|
+
declare function TabsList({ className, ...props }: HTMLAttributes<HTMLDivElement>): react_jsx_runtime.JSX.Element;
|
|
149
|
+
interface TabsTriggerProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
150
|
+
value: string;
|
|
151
|
+
}
|
|
152
|
+
declare function TabsTrigger({ value, className, ...props }: TabsTriggerProps): react_jsx_runtime.JSX.Element;
|
|
153
|
+
interface TabsContentProps extends HTMLAttributes<HTMLDivElement> {
|
|
154
|
+
value: string;
|
|
155
|
+
}
|
|
156
|
+
declare function TabsContent({ value, className, ...props }: TabsContentProps): react_jsx_runtime.JSX.Element | null;
|
|
157
|
+
|
|
158
|
+
interface ScrollAreaProps extends HTMLAttributes<HTMLDivElement> {
|
|
159
|
+
}
|
|
160
|
+
declare const ScrollArea: react.ForwardRefExoticComponent<ScrollAreaProps & react.RefAttributes<HTMLDivElement>>;
|
|
161
|
+
|
|
162
|
+
interface FloatingPanelProps {
|
|
163
|
+
/** Panel title displayed in the title bar */
|
|
164
|
+
title: string;
|
|
165
|
+
/** Called when the close button is clicked */
|
|
166
|
+
onClose: () => void;
|
|
167
|
+
/** Panel content */
|
|
168
|
+
children: ReactNode;
|
|
169
|
+
/** Default width in pixels */
|
|
170
|
+
defaultWidth?: number;
|
|
171
|
+
/** Default height in pixels */
|
|
172
|
+
defaultHeight?: number;
|
|
173
|
+
/** Minimum width in pixels */
|
|
174
|
+
minWidth?: number;
|
|
175
|
+
/** Minimum height in pixels */
|
|
176
|
+
minHeight?: number;
|
|
177
|
+
/** Offset index to stagger multiple panels (adds 30px offset per index) */
|
|
178
|
+
offsetIndex?: number;
|
|
179
|
+
/** Additional CSS classes for the panel container */
|
|
180
|
+
className?: string;
|
|
181
|
+
}
|
|
182
|
+
declare function FloatingPanel({ title, onClose, children, defaultWidth, defaultHeight, minWidth, minHeight, offsetIndex, className, }: FloatingPanelProps): react_jsx_runtime.JSX.Element;
|
|
183
|
+
|
|
184
|
+
type Status = 'online' | 'offline' | 'degraded' | 'unknown';
|
|
185
|
+
interface StatusBadgeProps {
|
|
186
|
+
status: Status;
|
|
187
|
+
showDot?: boolean;
|
|
188
|
+
showLabel?: boolean;
|
|
189
|
+
size?: 'sm' | 'md';
|
|
190
|
+
className?: string;
|
|
191
|
+
}
|
|
192
|
+
declare function StatusBadge({ status, showDot, showLabel, size, className, }: StatusBadgeProps): react_jsx_runtime.JSX.Element;
|
|
193
|
+
|
|
194
|
+
interface ProviderBadgeProps {
|
|
195
|
+
provider: ProviderType;
|
|
196
|
+
showLabel?: boolean;
|
|
197
|
+
className?: string;
|
|
198
|
+
}
|
|
199
|
+
declare function ProviderBadge({ provider, showLabel, className, }: ProviderBadgeProps): react_jsx_runtime.JSX.Element;
|
|
200
|
+
|
|
201
|
+
interface FormFieldProps {
|
|
202
|
+
label: string;
|
|
203
|
+
description?: string;
|
|
204
|
+
error?: string;
|
|
205
|
+
required?: boolean;
|
|
206
|
+
children: ReactNode;
|
|
207
|
+
orientation?: 'vertical' | 'horizontal';
|
|
208
|
+
className?: string;
|
|
209
|
+
}
|
|
210
|
+
declare function FormField({ label, description, error, required, children, orientation, className, }: FormFieldProps): react_jsx_runtime.JSX.Element;
|
|
211
|
+
|
|
212
|
+
interface PageHeaderProps {
|
|
213
|
+
title: string;
|
|
214
|
+
subtitle?: string;
|
|
215
|
+
actions?: ReactNode;
|
|
216
|
+
className?: string;
|
|
217
|
+
}
|
|
218
|
+
declare function PageHeader({ title, subtitle, actions, className }: PageHeaderProps): react_jsx_runtime.JSX.Element;
|
|
219
|
+
|
|
220
|
+
interface EmptyStateProps {
|
|
221
|
+
icon?: LucideIcon;
|
|
222
|
+
title: string;
|
|
223
|
+
description?: string;
|
|
224
|
+
action?: ReactNode;
|
|
225
|
+
className?: string;
|
|
226
|
+
}
|
|
227
|
+
declare function EmptyState({ icon: Icon, title, description, action, className, }: EmptyStateProps): react_jsx_runtime.JSX.Element;
|
|
228
|
+
|
|
229
|
+
interface ConfirmDialogProps {
|
|
230
|
+
title: string;
|
|
231
|
+
message: string;
|
|
232
|
+
confirmLabel?: string;
|
|
233
|
+
cancelLabel?: string;
|
|
234
|
+
onConfirm: () => void;
|
|
235
|
+
onCancel: () => void;
|
|
236
|
+
variant?: 'danger' | 'default';
|
|
237
|
+
open: boolean;
|
|
238
|
+
onOpenChange: (open: boolean) => void;
|
|
239
|
+
}
|
|
240
|
+
declare function ConfirmDialog({ title, message, confirmLabel, cancelLabel, onConfirm, onCancel, variant, open, onOpenChange, }: ConfirmDialogProps): react_jsx_runtime.JSX.Element;
|
|
241
|
+
|
|
242
|
+
interface StatCardProps {
|
|
243
|
+
value: string | number;
|
|
244
|
+
label: string;
|
|
245
|
+
trend?: {
|
|
246
|
+
value: number;
|
|
247
|
+
direction: 'up' | 'down';
|
|
248
|
+
};
|
|
249
|
+
className?: string;
|
|
250
|
+
}
|
|
251
|
+
declare function StatCard({ value, label, trend, className }: StatCardProps): react_jsx_runtime.JSX.Element;
|
|
252
|
+
|
|
253
|
+
interface KeyValueListProps {
|
|
254
|
+
items: {
|
|
255
|
+
key: string;
|
|
256
|
+
value: ReactNode;
|
|
257
|
+
}[];
|
|
258
|
+
className?: string;
|
|
259
|
+
}
|
|
260
|
+
declare function KeyValueList({ items, className }: KeyValueListProps): react_jsx_runtime.JSX.Element;
|
|
261
|
+
|
|
262
|
+
interface CodeBlockProps {
|
|
263
|
+
children: string;
|
|
264
|
+
maxHeight?: number;
|
|
265
|
+
className?: string;
|
|
266
|
+
}
|
|
267
|
+
declare function CodeBlock({ children, maxHeight, className }: CodeBlockProps): react_jsx_runtime.JSX.Element;
|
|
268
|
+
|
|
269
|
+
type FilterDef = {
|
|
270
|
+
type: 'search';
|
|
271
|
+
key: string;
|
|
272
|
+
placeholder?: string;
|
|
273
|
+
} | {
|
|
274
|
+
type: 'select';
|
|
275
|
+
key: string;
|
|
276
|
+
label: string;
|
|
277
|
+
options: {
|
|
278
|
+
value: string;
|
|
279
|
+
label: string;
|
|
280
|
+
}[];
|
|
281
|
+
} | {
|
|
282
|
+
type: 'badge-toggle';
|
|
283
|
+
key: string;
|
|
284
|
+
options: {
|
|
285
|
+
value: string;
|
|
286
|
+
label: string;
|
|
287
|
+
}[];
|
|
288
|
+
};
|
|
289
|
+
|
|
290
|
+
interface FilterBarProps {
|
|
291
|
+
filters: FilterDef[];
|
|
292
|
+
values: Record<string, unknown>;
|
|
293
|
+
onChange: (values: Record<string, unknown>) => void;
|
|
294
|
+
className?: string;
|
|
295
|
+
}
|
|
296
|
+
declare function FilterBar({ filters, values, onChange, className }: FilterBarProps): react_jsx_runtime.JSX.Element;
|
|
297
|
+
|
|
298
|
+
interface SidebarItemProps {
|
|
299
|
+
label: string;
|
|
300
|
+
icon: LucideIcon;
|
|
301
|
+
href: string;
|
|
302
|
+
badge?: string | number;
|
|
303
|
+
active?: boolean;
|
|
304
|
+
className?: string;
|
|
305
|
+
}
|
|
306
|
+
declare function SidebarItem({ label, icon: Icon, href, badge, active, className, }: SidebarItemProps): react_jsx_runtime.JSX.Element;
|
|
307
|
+
|
|
308
|
+
interface SidebarSection {
|
|
309
|
+
label?: string;
|
|
310
|
+
items: SidebarItemProps[];
|
|
311
|
+
}
|
|
312
|
+
interface SidebarProps {
|
|
313
|
+
logo?: ReactNode;
|
|
314
|
+
sections: SidebarSection[];
|
|
315
|
+
footer?: SidebarItemProps[];
|
|
316
|
+
className?: string;
|
|
317
|
+
}
|
|
318
|
+
declare function Sidebar({ logo, sections, footer, className }: SidebarProps): react_jsx_runtime.JSX.Element;
|
|
319
|
+
|
|
320
|
+
interface AppShellProps {
|
|
321
|
+
sidebar: SidebarProps;
|
|
322
|
+
header?: {
|
|
323
|
+
breadcrumbs?: {
|
|
324
|
+
label: string;
|
|
325
|
+
href?: string;
|
|
326
|
+
}[];
|
|
327
|
+
actions?: ReactNode;
|
|
328
|
+
};
|
|
329
|
+
children: ReactNode;
|
|
330
|
+
className?: string;
|
|
331
|
+
}
|
|
332
|
+
declare function AppShell({ sidebar, header, children, className }: AppShellProps): react_jsx_runtime.JSX.Element;
|
|
333
|
+
|
|
334
|
+
interface DataTableAction {
|
|
335
|
+
label: string;
|
|
336
|
+
icon?: LucideIcon;
|
|
337
|
+
onClick: () => void;
|
|
338
|
+
variant?: 'danger' | 'default';
|
|
339
|
+
}
|
|
340
|
+
interface DataTableProps<T> {
|
|
341
|
+
data: T[];
|
|
342
|
+
columns: ColumnDef<T, unknown>[];
|
|
343
|
+
sorting?: SortingState;
|
|
344
|
+
onSortingChange?: (sorting: SortingState) => void;
|
|
345
|
+
filtering?: ColumnFiltersState;
|
|
346
|
+
onFilteringChange?: (filtering: ColumnFiltersState) => void;
|
|
347
|
+
pagination?: {
|
|
348
|
+
page: number;
|
|
349
|
+
pageSize: number;
|
|
350
|
+
total: number;
|
|
351
|
+
};
|
|
352
|
+
onPaginationChange?: (pagination: PaginationState) => void;
|
|
353
|
+
loading?: boolean;
|
|
354
|
+
emptyState?: ReactNode;
|
|
355
|
+
rowActions?: (row: T) => DataTableAction[];
|
|
356
|
+
onRowClick?: (row: T) => void;
|
|
357
|
+
selectable?: boolean;
|
|
358
|
+
compact?: boolean;
|
|
359
|
+
stickyHeader?: boolean;
|
|
360
|
+
className?: string;
|
|
361
|
+
}
|
|
362
|
+
|
|
363
|
+
declare function DataTable<T>({ data, columns: userColumns, sorting, onSortingChange, filtering, onFilteringChange, pagination, onPaginationChange, loading, emptyState, rowActions, onRowClick, selectable, compact, stickyHeader, className, }: DataTableProps<T>): react_jsx_runtime.JSX.Element;
|
|
364
|
+
|
|
365
|
+
interface DeviceCardBadge {
|
|
366
|
+
/** Badge label text */
|
|
367
|
+
label: string;
|
|
368
|
+
/** Optional icon rendered before the label */
|
|
369
|
+
icon?: ReactNode;
|
|
370
|
+
/** Click handler — makes the badge interactive */
|
|
371
|
+
onClick?: () => void;
|
|
372
|
+
}
|
|
373
|
+
interface DeviceCardAction {
|
|
374
|
+
/** Icon to render */
|
|
375
|
+
icon: ReactNode;
|
|
376
|
+
/** Tooltip / aria-label */
|
|
377
|
+
label: string;
|
|
378
|
+
/** Click handler */
|
|
379
|
+
onClick: () => void;
|
|
380
|
+
}
|
|
381
|
+
interface DeviceCardProps {
|
|
382
|
+
/** Primary title (e.g., device name) */
|
|
383
|
+
title: string;
|
|
384
|
+
/** Secondary text (e.g., model, IP) */
|
|
385
|
+
subtitle?: string;
|
|
386
|
+
/** Status: determines the color of the status dot */
|
|
387
|
+
status?: 'online' | 'offline' | 'warning' | 'unknown';
|
|
388
|
+
/** Whether this card is currently selected */
|
|
389
|
+
selected?: boolean;
|
|
390
|
+
/** Click handler for the card body */
|
|
391
|
+
onClick?: () => void;
|
|
392
|
+
/** Clickable badges (e.g., stream profiles) */
|
|
393
|
+
badges?: DeviceCardBadge[];
|
|
394
|
+
/** Action icons shown at the bottom (e.g., PTZ, events) */
|
|
395
|
+
actions?: DeviceCardAction[];
|
|
396
|
+
/** Content rendered at the bottom when status is offline (e.g., Connect button) */
|
|
397
|
+
offlineAction?: ReactNode;
|
|
398
|
+
/** Additional CSS classes */
|
|
399
|
+
className?: string;
|
|
400
|
+
}
|
|
401
|
+
declare function DeviceCard({ title, subtitle, status, selected, onClick, badges, actions, offlineAction, className, }: DeviceCardProps): react_jsx_runtime.JSX.Element;
|
|
402
|
+
|
|
403
|
+
interface DeviceGridProps {
|
|
404
|
+
/** Grid items */
|
|
405
|
+
children: ReactNode;
|
|
406
|
+
/** Minimum card width in pixels (default 220) */
|
|
407
|
+
minCardWidth?: number;
|
|
408
|
+
/** Gap between cards in Tailwind spacing units (default 3) */
|
|
409
|
+
gap?: number;
|
|
410
|
+
/** Additional CSS classes */
|
|
411
|
+
className?: string;
|
|
412
|
+
}
|
|
413
|
+
declare function DeviceGrid({ children, minCardWidth, gap, className, }: DeviceGridProps): react_jsx_runtime.JSX.Element;
|
|
414
|
+
|
|
415
|
+
export { AppShell, type AppShellProps, Badge, type BadgeProps, Button, type ButtonProps, Card, type CardProps, Checkbox, type CheckboxProps, CodeBlock, type CodeBlockProps, ConfirmDialog, type ConfirmDialogProps, DataTable, type DataTableAction, type DataTableProps, DeviceCard, type DeviceCardAction, type DeviceCardBadge, type DeviceCardProps, DeviceGrid, type DeviceGridProps, Dialog, DialogContent, type DialogContentProps, DialogDescription, DialogFooter, DialogHeader, DialogTitle, DialogTrigger, Dropdown, DropdownContent, DropdownItem, DropdownTrigger, EmptyState, type EmptyStateProps, FilterBar, type FilterBarProps, type FilterDef, FloatingPanel, type FloatingPanelProps, FormField, type FormFieldProps, IconButton, type IconButtonProps, Input, type InputProps, KeyValueList, type KeyValueListProps, Label, type LabelProps, PageHeader, type PageHeaderProps, Popover, PopoverContent, PopoverTrigger, ProviderBadge, type ProviderBadgeProps, type ProviderType, ScrollArea, type ScrollAreaProps, Select, type SelectOption, type SelectProps, Separator, type SeparatorProps, Sidebar, SidebarItem, type SidebarItemProps, type SidebarProps, type SidebarSection, Skeleton, type SkeletonProps, StatCard, type StatCardProps, StatusBadge, type StatusBadgeProps, type StatusType, Switch, type SwitchProps, Tabs, TabsContent, TabsList, TabsTrigger, Tooltip, TooltipContent, TooltipTrigger, cn, providerIcons, statusIcons };
|