@terminal-blueprint/react 0.1.1 → 0.1.2
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/dist/index.cjs +367 -112
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +56 -3
- package/dist/index.d.ts +56 -3
- package/dist/index.js +360 -102
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.d.cts
CHANGED
|
@@ -49,9 +49,10 @@ interface CardProps extends HTMLAttributes<HTMLElement> {
|
|
|
49
49
|
brackets?: boolean;
|
|
50
50
|
pulse?: boolean;
|
|
51
51
|
hoverable?: boolean;
|
|
52
|
+
href?: string;
|
|
52
53
|
ref?: Ref<HTMLElement>;
|
|
53
54
|
}
|
|
54
|
-
declare function CardRoot({ as, brackets, pulse, hoverable, className, children, ref, ...props }: CardProps): react_jsx_runtime.JSX.Element;
|
|
55
|
+
declare function CardRoot({ as, brackets, pulse, hoverable, href, className, children, ref, ...props }: CardProps): react_jsx_runtime.JSX.Element;
|
|
55
56
|
interface CardSectionProps extends HTMLAttributes<HTMLDivElement> {
|
|
56
57
|
ref?: Ref<HTMLDivElement>;
|
|
57
58
|
}
|
|
@@ -301,15 +302,31 @@ interface ProgressProps {
|
|
|
301
302
|
}
|
|
302
303
|
declare function Progress({ value, variant, animated, indeterminate, label, showValue, className, }: ProgressProps): react_jsx_runtime.JSX.Element;
|
|
303
304
|
|
|
305
|
+
interface SliderProps {
|
|
306
|
+
value: number;
|
|
307
|
+
onChange: (value: number) => void;
|
|
308
|
+
min?: number;
|
|
309
|
+
max?: number;
|
|
310
|
+
step?: number;
|
|
311
|
+
variant?: 'default' | 'success' | 'warning' | 'error';
|
|
312
|
+
label?: string;
|
|
313
|
+
showValue?: boolean;
|
|
314
|
+
disabled?: boolean;
|
|
315
|
+
className?: string;
|
|
316
|
+
ref?: Ref<HTMLInputElement>;
|
|
317
|
+
}
|
|
318
|
+
declare function Slider({ value, onChange, min, max, step, variant, label, showValue, disabled, className, ref, }: SliderProps): react_jsx_runtime.JSX.Element;
|
|
319
|
+
|
|
304
320
|
interface BatteryProps {
|
|
305
321
|
value: number;
|
|
306
322
|
total?: number;
|
|
307
323
|
variant?: 'default' | 'success' | 'warning' | 'error';
|
|
308
324
|
animated?: boolean;
|
|
309
325
|
label?: string;
|
|
326
|
+
showValue?: boolean;
|
|
310
327
|
className?: string;
|
|
311
328
|
}
|
|
312
|
-
declare function Battery({ value, total, variant, animated, label, className, }: BatteryProps): react_jsx_runtime.JSX.Element;
|
|
329
|
+
declare function Battery({ value, total, variant, animated, label, showValue, className, }: BatteryProps): react_jsx_runtime.JSX.Element;
|
|
313
330
|
|
|
314
331
|
interface BatteryInlineProps {
|
|
315
332
|
value: number;
|
|
@@ -407,6 +424,42 @@ declare const Toolbar: typeof ToolbarRoot & {
|
|
|
407
424
|
Divider: typeof ToolbarDivider;
|
|
408
425
|
};
|
|
409
426
|
|
|
427
|
+
interface FileUploadFile {
|
|
428
|
+
file: File;
|
|
429
|
+
preview?: string;
|
|
430
|
+
}
|
|
431
|
+
interface FileUploadProps {
|
|
432
|
+
/** Called when files are added */
|
|
433
|
+
onChange?: (files: File[]) => void;
|
|
434
|
+
/** Controlled file list */
|
|
435
|
+
value?: File[];
|
|
436
|
+
/** Accepted file types (e.g. "image/*,.pdf") */
|
|
437
|
+
accept?: string;
|
|
438
|
+
/** Allow multiple files */
|
|
439
|
+
multiple?: boolean;
|
|
440
|
+
/** Max file size in bytes */
|
|
441
|
+
maxSize?: number;
|
|
442
|
+
/** Compact mode — renders as inline button instead of drop zone */
|
|
443
|
+
compact?: boolean;
|
|
444
|
+
/** Show image thumbnails for image files */
|
|
445
|
+
preview?: boolean;
|
|
446
|
+
/** Label above the drop zone */
|
|
447
|
+
label?: string;
|
|
448
|
+
/** Drop zone prompt text */
|
|
449
|
+
placeholder?: string;
|
|
450
|
+
/** Hint text below drop zone (e.g. "PNG, JPG up to 5MB") */
|
|
451
|
+
hint?: string;
|
|
452
|
+
/** Error message */
|
|
453
|
+
error?: string;
|
|
454
|
+
/** Custom icon in drop zone */
|
|
455
|
+
icon?: ReactNode;
|
|
456
|
+
/** Disabled state */
|
|
457
|
+
disabled?: boolean;
|
|
458
|
+
className?: string;
|
|
459
|
+
ref?: Ref<HTMLInputElement>;
|
|
460
|
+
}
|
|
461
|
+
declare function FileUpload({ onChange, value, accept, multiple, maxSize, compact, preview, label, placeholder, hint, error: errorProp, icon, disabled, className, ref, }: FileUploadProps): react_jsx_runtime.JSX.Element;
|
|
462
|
+
|
|
410
463
|
interface SidenavProps extends HTMLAttributes<HTMLElement> {
|
|
411
464
|
iconPosition?: 'left' | 'right';
|
|
412
465
|
borderSide?: 'left' | 'right';
|
|
@@ -507,4 +560,4 @@ interface SafePortalProps {
|
|
|
507
560
|
}
|
|
508
561
|
declare function SafePortal({ children, target }: SafePortalProps): react.ReactPortal | null;
|
|
509
562
|
|
|
510
|
-
export { Badge, type BadgeProps, Battery, BatteryInline, type BatteryInlineProps, type BatteryProps, type BreadcrumbItem, Breadcrumbs, type BreadcrumbsProps, Button, type ButtonProps, Card, type CardProps, type CardSectionProps, Checkbox, type CheckboxProps, CodeBlock, type CodeBlockProps, type Column, type Contrast, CornerBrackets, type CornerBracketsProps, Input, type InputProps, Modal, type ModalProps, NavDropdown, type NavDropdownItem, type NavDropdownProps, Pagination, type PaginationProps, type PolymorphicProps, Progress, type ProgressProps, RadioGroup, type RadioGroupProps, RadioItem, type RadioItemProps, SafePortal, Select, SelectContent, type SelectContentProps, SelectItem, type SelectItemProps, type SelectProps, SelectTrigger, type SelectTriggerProps, Sidenav, type SidenavGroupProps, type SidenavIconProps, type SidenavItemProps, type SidenavProps, Skeleton, type SkeletonProps, Spinner, type SpinnerProps, Table, type TableProps, Tabs, TabsContent, type TabsContentProps, TabsList, type TabsListProps, type TabsProps, TabsTrigger, type TabsTriggerProps, Tag, type TagProps, Textarea, type TextareaProps, type Theme, type ThemeContextValue, ThemeProvider, type ThemeProviderProps, TitleLine, type TitleLineProps, type ToastEntry, type ToastOptions, Toaster, type ToasterProps, Toggle, type ToggleProps, Toolbar, type ToolbarProps, type ToolbarSelectOption, type ToolbarSelectProps, Tooltip, type TooltipProps, cn, createToast as toast, useDisclosure, useFocusTrap, useKeyboardNav, useMergedRef, useReducedMotion, useTheme };
|
|
563
|
+
export { Badge, type BadgeProps, Battery, BatteryInline, type BatteryInlineProps, type BatteryProps, type BreadcrumbItem, Breadcrumbs, type BreadcrumbsProps, Button, type ButtonProps, Card, type CardProps, type CardSectionProps, Checkbox, type CheckboxProps, CodeBlock, type CodeBlockProps, type Column, type Contrast, CornerBrackets, type CornerBracketsProps, FileUpload, type FileUploadFile, type FileUploadProps, Input, type InputProps, Modal, type ModalProps, NavDropdown, type NavDropdownItem, type NavDropdownProps, Pagination, type PaginationProps, type PolymorphicProps, Progress, type ProgressProps, RadioGroup, type RadioGroupProps, RadioItem, type RadioItemProps, SafePortal, Select, SelectContent, type SelectContentProps, SelectItem, type SelectItemProps, type SelectProps, SelectTrigger, type SelectTriggerProps, Sidenav, type SidenavGroupProps, type SidenavIconProps, type SidenavItemProps, type SidenavProps, Skeleton, type SkeletonProps, Slider, type SliderProps, Spinner, type SpinnerProps, Table, type TableProps, Tabs, TabsContent, type TabsContentProps, TabsList, type TabsListProps, type TabsProps, TabsTrigger, type TabsTriggerProps, Tag, type TagProps, Textarea, type TextareaProps, type Theme, type ThemeContextValue, ThemeProvider, type ThemeProviderProps, TitleLine, type TitleLineProps, type ToastEntry, type ToastOptions, Toaster, type ToasterProps, Toggle, type ToggleProps, Toolbar, type ToolbarProps, type ToolbarSelectOption, type ToolbarSelectProps, Tooltip, type TooltipProps, cn, createToast as toast, useDisclosure, useFocusTrap, useKeyboardNav, useMergedRef, useReducedMotion, useTheme };
|
package/dist/index.d.ts
CHANGED
|
@@ -49,9 +49,10 @@ interface CardProps extends HTMLAttributes<HTMLElement> {
|
|
|
49
49
|
brackets?: boolean;
|
|
50
50
|
pulse?: boolean;
|
|
51
51
|
hoverable?: boolean;
|
|
52
|
+
href?: string;
|
|
52
53
|
ref?: Ref<HTMLElement>;
|
|
53
54
|
}
|
|
54
|
-
declare function CardRoot({ as, brackets, pulse, hoverable, className, children, ref, ...props }: CardProps): react_jsx_runtime.JSX.Element;
|
|
55
|
+
declare function CardRoot({ as, brackets, pulse, hoverable, href, className, children, ref, ...props }: CardProps): react_jsx_runtime.JSX.Element;
|
|
55
56
|
interface CardSectionProps extends HTMLAttributes<HTMLDivElement> {
|
|
56
57
|
ref?: Ref<HTMLDivElement>;
|
|
57
58
|
}
|
|
@@ -301,15 +302,31 @@ interface ProgressProps {
|
|
|
301
302
|
}
|
|
302
303
|
declare function Progress({ value, variant, animated, indeterminate, label, showValue, className, }: ProgressProps): react_jsx_runtime.JSX.Element;
|
|
303
304
|
|
|
305
|
+
interface SliderProps {
|
|
306
|
+
value: number;
|
|
307
|
+
onChange: (value: number) => void;
|
|
308
|
+
min?: number;
|
|
309
|
+
max?: number;
|
|
310
|
+
step?: number;
|
|
311
|
+
variant?: 'default' | 'success' | 'warning' | 'error';
|
|
312
|
+
label?: string;
|
|
313
|
+
showValue?: boolean;
|
|
314
|
+
disabled?: boolean;
|
|
315
|
+
className?: string;
|
|
316
|
+
ref?: Ref<HTMLInputElement>;
|
|
317
|
+
}
|
|
318
|
+
declare function Slider({ value, onChange, min, max, step, variant, label, showValue, disabled, className, ref, }: SliderProps): react_jsx_runtime.JSX.Element;
|
|
319
|
+
|
|
304
320
|
interface BatteryProps {
|
|
305
321
|
value: number;
|
|
306
322
|
total?: number;
|
|
307
323
|
variant?: 'default' | 'success' | 'warning' | 'error';
|
|
308
324
|
animated?: boolean;
|
|
309
325
|
label?: string;
|
|
326
|
+
showValue?: boolean;
|
|
310
327
|
className?: string;
|
|
311
328
|
}
|
|
312
|
-
declare function Battery({ value, total, variant, animated, label, className, }: BatteryProps): react_jsx_runtime.JSX.Element;
|
|
329
|
+
declare function Battery({ value, total, variant, animated, label, showValue, className, }: BatteryProps): react_jsx_runtime.JSX.Element;
|
|
313
330
|
|
|
314
331
|
interface BatteryInlineProps {
|
|
315
332
|
value: number;
|
|
@@ -407,6 +424,42 @@ declare const Toolbar: typeof ToolbarRoot & {
|
|
|
407
424
|
Divider: typeof ToolbarDivider;
|
|
408
425
|
};
|
|
409
426
|
|
|
427
|
+
interface FileUploadFile {
|
|
428
|
+
file: File;
|
|
429
|
+
preview?: string;
|
|
430
|
+
}
|
|
431
|
+
interface FileUploadProps {
|
|
432
|
+
/** Called when files are added */
|
|
433
|
+
onChange?: (files: File[]) => void;
|
|
434
|
+
/** Controlled file list */
|
|
435
|
+
value?: File[];
|
|
436
|
+
/** Accepted file types (e.g. "image/*,.pdf") */
|
|
437
|
+
accept?: string;
|
|
438
|
+
/** Allow multiple files */
|
|
439
|
+
multiple?: boolean;
|
|
440
|
+
/** Max file size in bytes */
|
|
441
|
+
maxSize?: number;
|
|
442
|
+
/** Compact mode — renders as inline button instead of drop zone */
|
|
443
|
+
compact?: boolean;
|
|
444
|
+
/** Show image thumbnails for image files */
|
|
445
|
+
preview?: boolean;
|
|
446
|
+
/** Label above the drop zone */
|
|
447
|
+
label?: string;
|
|
448
|
+
/** Drop zone prompt text */
|
|
449
|
+
placeholder?: string;
|
|
450
|
+
/** Hint text below drop zone (e.g. "PNG, JPG up to 5MB") */
|
|
451
|
+
hint?: string;
|
|
452
|
+
/** Error message */
|
|
453
|
+
error?: string;
|
|
454
|
+
/** Custom icon in drop zone */
|
|
455
|
+
icon?: ReactNode;
|
|
456
|
+
/** Disabled state */
|
|
457
|
+
disabled?: boolean;
|
|
458
|
+
className?: string;
|
|
459
|
+
ref?: Ref<HTMLInputElement>;
|
|
460
|
+
}
|
|
461
|
+
declare function FileUpload({ onChange, value, accept, multiple, maxSize, compact, preview, label, placeholder, hint, error: errorProp, icon, disabled, className, ref, }: FileUploadProps): react_jsx_runtime.JSX.Element;
|
|
462
|
+
|
|
410
463
|
interface SidenavProps extends HTMLAttributes<HTMLElement> {
|
|
411
464
|
iconPosition?: 'left' | 'right';
|
|
412
465
|
borderSide?: 'left' | 'right';
|
|
@@ -507,4 +560,4 @@ interface SafePortalProps {
|
|
|
507
560
|
}
|
|
508
561
|
declare function SafePortal({ children, target }: SafePortalProps): react.ReactPortal | null;
|
|
509
562
|
|
|
510
|
-
export { Badge, type BadgeProps, Battery, BatteryInline, type BatteryInlineProps, type BatteryProps, type BreadcrumbItem, Breadcrumbs, type BreadcrumbsProps, Button, type ButtonProps, Card, type CardProps, type CardSectionProps, Checkbox, type CheckboxProps, CodeBlock, type CodeBlockProps, type Column, type Contrast, CornerBrackets, type CornerBracketsProps, Input, type InputProps, Modal, type ModalProps, NavDropdown, type NavDropdownItem, type NavDropdownProps, Pagination, type PaginationProps, type PolymorphicProps, Progress, type ProgressProps, RadioGroup, type RadioGroupProps, RadioItem, type RadioItemProps, SafePortal, Select, SelectContent, type SelectContentProps, SelectItem, type SelectItemProps, type SelectProps, SelectTrigger, type SelectTriggerProps, Sidenav, type SidenavGroupProps, type SidenavIconProps, type SidenavItemProps, type SidenavProps, Skeleton, type SkeletonProps, Spinner, type SpinnerProps, Table, type TableProps, Tabs, TabsContent, type TabsContentProps, TabsList, type TabsListProps, type TabsProps, TabsTrigger, type TabsTriggerProps, Tag, type TagProps, Textarea, type TextareaProps, type Theme, type ThemeContextValue, ThemeProvider, type ThemeProviderProps, TitleLine, type TitleLineProps, type ToastEntry, type ToastOptions, Toaster, type ToasterProps, Toggle, type ToggleProps, Toolbar, type ToolbarProps, type ToolbarSelectOption, type ToolbarSelectProps, Tooltip, type TooltipProps, cn, createToast as toast, useDisclosure, useFocusTrap, useKeyboardNav, useMergedRef, useReducedMotion, useTheme };
|
|
563
|
+
export { Badge, type BadgeProps, Battery, BatteryInline, type BatteryInlineProps, type BatteryProps, type BreadcrumbItem, Breadcrumbs, type BreadcrumbsProps, Button, type ButtonProps, Card, type CardProps, type CardSectionProps, Checkbox, type CheckboxProps, CodeBlock, type CodeBlockProps, type Column, type Contrast, CornerBrackets, type CornerBracketsProps, FileUpload, type FileUploadFile, type FileUploadProps, Input, type InputProps, Modal, type ModalProps, NavDropdown, type NavDropdownItem, type NavDropdownProps, Pagination, type PaginationProps, type PolymorphicProps, Progress, type ProgressProps, RadioGroup, type RadioGroupProps, RadioItem, type RadioItemProps, SafePortal, Select, SelectContent, type SelectContentProps, SelectItem, type SelectItemProps, type SelectProps, SelectTrigger, type SelectTriggerProps, Sidenav, type SidenavGroupProps, type SidenavIconProps, type SidenavItemProps, type SidenavProps, Skeleton, type SkeletonProps, Slider, type SliderProps, Spinner, type SpinnerProps, Table, type TableProps, Tabs, TabsContent, type TabsContentProps, TabsList, type TabsListProps, type TabsProps, TabsTrigger, type TabsTriggerProps, Tag, type TagProps, Textarea, type TextareaProps, type Theme, type ThemeContextValue, ThemeProvider, type ThemeProviderProps, TitleLine, type TitleLineProps, type ToastEntry, type ToastOptions, Toaster, type ToasterProps, Toggle, type ToggleProps, Toolbar, type ToolbarProps, type ToolbarSelectOption, type ToolbarSelectProps, Tooltip, type TooltipProps, cn, createToast as toast, useDisclosure, useFocusTrap, useKeyboardNav, useMergedRef, useReducedMotion, useTheme };
|