@orangecheck/design 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.
- package/LICENSE +21 -0
- package/README.md +88 -0
- package/dist/components.d.mts +1 -0
- package/dist/components.d.ts +1 -0
- package/dist/components.js +14 -0
- package/dist/components.js.map +1 -0
- package/dist/components.mjs +3 -0
- package/dist/components.mjs.map +1 -0
- package/dist/index.d.mts +16 -0
- package/dist/index.d.ts +16 -0
- package/dist/index.js +1588 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +1488 -0
- package/dist/index.mjs.map +1 -0
- package/dist/primitives.d.mts +205 -0
- package/dist/primitives.d.ts +205 -0
- package/dist/primitives.js +1235 -0
- package/dist/primitives.js.map +1 -0
- package/dist/primitives.mjs +1147 -0
- package/dist/primitives.mjs.map +1 -0
- package/dist/styles/theme.css +482 -0
- package/dist/styles/themes/aurora.css +129 -0
- package/dist/styles/themes/midnight.css +105 -0
- package/dist/styles/themes/orangecheck.css +128 -0
- package/dist/styles/themes/phosphor.css +104 -0
- package/dist/styles/themes.css +11 -0
- package/dist/styles.css +20 -0
- package/dist/tokens.d.mts +41 -0
- package/dist/tokens.d.ts +41 -0
- package/dist/tokens.js +266 -0
- package/dist/tokens.js.map +1 -0
- package/dist/tokens.mjs +254 -0
- package/dist/tokens.mjs.map +1 -0
- package/package.json +116 -0
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
3
|
+
import { VariantProps } from 'class-variance-authority';
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import { ReactNode } from 'react';
|
|
6
|
+
import * as LabelPrimitive from '@radix-ui/react-label';
|
|
7
|
+
import { LucideIcon } from 'lucide-react';
|
|
8
|
+
import * as SeparatorPrimitive from '@radix-ui/react-separator';
|
|
9
|
+
import * as DialogPrimitive from '@radix-ui/react-dialog';
|
|
10
|
+
import * as PopoverPrimitive from '@radix-ui/react-popover';
|
|
11
|
+
import * as AccordionPrimitive from '@radix-ui/react-accordion';
|
|
12
|
+
import * as SelectPrimitive from '@radix-ui/react-select';
|
|
13
|
+
import { ToasterProps } from 'sonner';
|
|
14
|
+
|
|
15
|
+
declare const buttonVariants: (props?: ({
|
|
16
|
+
variant?: "link" | "default" | "destructive" | "outline" | "secondary" | "ghost" | null | undefined;
|
|
17
|
+
size?: "default" | "sm" | "lg" | "icon" | null | undefined;
|
|
18
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
19
|
+
declare function Button({ className, variant, size, asChild, ...props }: React.ComponentProps<'button'> & VariantProps<typeof buttonVariants> & {
|
|
20
|
+
asChild?: boolean;
|
|
21
|
+
}): react_jsx_runtime.JSX.Element;
|
|
22
|
+
|
|
23
|
+
declare const badgeVariants: (props?: ({
|
|
24
|
+
variant?: "default" | "destructive" | "outline" | "secondary" | "warning" | "success" | "info" | null | undefined;
|
|
25
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
26
|
+
declare function Badge({ className, variant, asChild, ...props }: React.ComponentProps<'span'> & VariantProps<typeof badgeVariants> & {
|
|
27
|
+
asChild?: boolean;
|
|
28
|
+
}): react_jsx_runtime.JSX.Element;
|
|
29
|
+
|
|
30
|
+
declare function Input({ className, type, ...props }: React.ComponentProps<'input'>): react_jsx_runtime.JSX.Element;
|
|
31
|
+
|
|
32
|
+
declare function Label({ className, ...props }: React.ComponentProps<typeof LabelPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
33
|
+
|
|
34
|
+
declare const alertVariants: (props?: ({
|
|
35
|
+
variant?: "default" | "destructive" | "warning" | "success" | null | undefined;
|
|
36
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
37
|
+
declare function Alert({ className, variant, ...props }: React.ComponentProps<'div'> & VariantProps<typeof alertVariants>): react_jsx_runtime.JSX.Element;
|
|
38
|
+
declare function AlertTitle({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
39
|
+
declare function AlertDescription({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
40
|
+
|
|
41
|
+
type AlertVariant = 'default' | 'destructive' | 'warning' | 'success';
|
|
42
|
+
interface AlertWithActionProps {
|
|
43
|
+
variant?: AlertVariant;
|
|
44
|
+
icon?: LucideIcon;
|
|
45
|
+
title?: string;
|
|
46
|
+
description: React.ReactNode;
|
|
47
|
+
actionLabel?: string;
|
|
48
|
+
onAction?: () => void;
|
|
49
|
+
actionVariant?: 'default' | 'outline' | 'ghost' | 'destructive';
|
|
50
|
+
actionIcon?: React.ReactNode;
|
|
51
|
+
actionDisabled?: boolean;
|
|
52
|
+
actionContent?: React.ReactNode;
|
|
53
|
+
className?: string;
|
|
54
|
+
}
|
|
55
|
+
declare function AlertWithAction({ variant, icon: Icon, title, description, actionLabel, onAction, actionVariant, actionIcon, actionDisabled, actionContent, className, }: AlertWithActionProps): react_jsx_runtime.JSX.Element;
|
|
56
|
+
interface AlertWithCountdownProps {
|
|
57
|
+
variant?: AlertVariant;
|
|
58
|
+
icon?: LucideIcon;
|
|
59
|
+
title?: string;
|
|
60
|
+
description: React.ReactNode;
|
|
61
|
+
countdown: number;
|
|
62
|
+
countdownLabel?: string;
|
|
63
|
+
countdownIcon?: React.ReactNode;
|
|
64
|
+
actionLabel?: string;
|
|
65
|
+
onAction?: () => void;
|
|
66
|
+
actionIcon?: React.ReactNode;
|
|
67
|
+
actionDisabled?: boolean;
|
|
68
|
+
className?: string;
|
|
69
|
+
}
|
|
70
|
+
declare function AlertWithCountdown({ variant, icon: Icon, title, description, countdown, countdownLabel, countdownIcon, actionLabel, onAction, actionIcon, actionDisabled, className, }: AlertWithCountdownProps): react_jsx_runtime.JSX.Element;
|
|
71
|
+
|
|
72
|
+
declare function Textarea({ className, ...props }: React.ComponentProps<'textarea'>): react_jsx_runtime.JSX.Element;
|
|
73
|
+
|
|
74
|
+
declare function ThemeToggle({ className }: {
|
|
75
|
+
className?: string;
|
|
76
|
+
}): react_jsx_runtime.JSX.Element;
|
|
77
|
+
declare function ThemeToggleLink(): react_jsx_runtime.JSX.Element;
|
|
78
|
+
|
|
79
|
+
interface WorkingProps {
|
|
80
|
+
text: string;
|
|
81
|
+
size?: 'sm' | 'md';
|
|
82
|
+
progress?: string;
|
|
83
|
+
className?: string;
|
|
84
|
+
}
|
|
85
|
+
declare function Working({ text, size, progress, className }: WorkingProps): react_jsx_runtime.JSX.Element;
|
|
86
|
+
declare function WorkingPanel({ text, progress }: Pick<WorkingProps, 'text' | 'progress'>): react_jsx_runtime.JSX.Element;
|
|
87
|
+
|
|
88
|
+
interface Props {
|
|
89
|
+
children: React.ReactNode;
|
|
90
|
+
fallback?: (error: Error, reset: () => void) => React.ReactNode;
|
|
91
|
+
}
|
|
92
|
+
interface State {
|
|
93
|
+
error: Error | null;
|
|
94
|
+
}
|
|
95
|
+
declare class ErrorBoundary extends React.Component<Props, State> {
|
|
96
|
+
state: State;
|
|
97
|
+
static getDerivedStateFromError(error: Error): State;
|
|
98
|
+
componentDidCatch(error: Error, info: React.ErrorInfo): void;
|
|
99
|
+
reset: () => void;
|
|
100
|
+
render(): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | react_jsx_runtime.JSX.Element | null | undefined;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
interface SkeletonProps {
|
|
104
|
+
className?: string;
|
|
105
|
+
}
|
|
106
|
+
declare function Skeleton({ className }: SkeletonProps): react_jsx_runtime.JSX.Element;
|
|
107
|
+
|
|
108
|
+
declare function Separator({ className, orientation, decorative, ...props }: React.ComponentProps<typeof SeparatorPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
109
|
+
|
|
110
|
+
declare function Sheet(props: React.ComponentProps<typeof DialogPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
111
|
+
declare function SheetTrigger(props: React.ComponentProps<typeof DialogPrimitive.Trigger>): react_jsx_runtime.JSX.Element;
|
|
112
|
+
declare function SheetPortal(props: React.ComponentProps<typeof DialogPrimitive.Portal>): react_jsx_runtime.JSX.Element;
|
|
113
|
+
declare function SheetOverlay({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Overlay>): react_jsx_runtime.JSX.Element;
|
|
114
|
+
declare function SheetContent({ className, children, side, ...props }: React.ComponentProps<typeof DialogPrimitive.Content> & {
|
|
115
|
+
side?: 'left' | 'right' | 'top' | 'bottom';
|
|
116
|
+
}): react_jsx_runtime.JSX.Element;
|
|
117
|
+
declare function SheetHeader({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
118
|
+
declare function SheetTitle({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Title>): react_jsx_runtime.JSX.Element;
|
|
119
|
+
declare function SheetDescription({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Description>): react_jsx_runtime.JSX.Element;
|
|
120
|
+
|
|
121
|
+
declare function Dialog({ ...props }: React.ComponentProps<typeof DialogPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
122
|
+
declare function DialogTrigger({ ...props }: React.ComponentProps<typeof DialogPrimitive.Trigger>): react_jsx_runtime.JSX.Element;
|
|
123
|
+
declare function DialogPortal({ ...props }: React.ComponentProps<typeof DialogPrimitive.Portal>): react_jsx_runtime.JSX.Element;
|
|
124
|
+
declare function DialogClose({ ...props }: React.ComponentProps<typeof DialogPrimitive.Close>): react_jsx_runtime.JSX.Element;
|
|
125
|
+
declare function DialogOverlay({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Overlay>): react_jsx_runtime.JSX.Element;
|
|
126
|
+
declare function DialogContent({ className, children, showCloseButton, ...props }: React.ComponentProps<typeof DialogPrimitive.Content> & {
|
|
127
|
+
showCloseButton?: boolean;
|
|
128
|
+
}): react_jsx_runtime.JSX.Element;
|
|
129
|
+
declare function DialogHeader({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
130
|
+
declare function DialogFooter({ className, ...props }: React.ComponentProps<'div'>): react_jsx_runtime.JSX.Element;
|
|
131
|
+
declare function DialogTitle({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Title>): react_jsx_runtime.JSX.Element;
|
|
132
|
+
declare function DialogDescription({ className, ...props }: React.ComponentProps<typeof DialogPrimitive.Description>): react_jsx_runtime.JSX.Element;
|
|
133
|
+
|
|
134
|
+
interface ConfirmOptions {
|
|
135
|
+
title: string;
|
|
136
|
+
message: string;
|
|
137
|
+
confirmLabel?: string;
|
|
138
|
+
cancelLabel?: string;
|
|
139
|
+
destructive?: boolean;
|
|
140
|
+
}
|
|
141
|
+
declare function confirm(opts: ConfirmOptions): Promise<boolean>;
|
|
142
|
+
declare function ConfirmHost(): react_jsx_runtime.JSX.Element | null;
|
|
143
|
+
|
|
144
|
+
interface PromptOptions {
|
|
145
|
+
title: string;
|
|
146
|
+
message?: string;
|
|
147
|
+
label?: string;
|
|
148
|
+
placeholder?: string;
|
|
149
|
+
defaultValue?: string;
|
|
150
|
+
confirmLabel?: string;
|
|
151
|
+
cancelLabel?: string;
|
|
152
|
+
secret?: boolean;
|
|
153
|
+
confirmField?: boolean;
|
|
154
|
+
minLength?: number;
|
|
155
|
+
validate?: (value: string) => string | null;
|
|
156
|
+
}
|
|
157
|
+
declare function prompt(opts: PromptOptions): Promise<string | null>;
|
|
158
|
+
declare function PromptHost(): react_jsx_runtime.JSX.Element | null;
|
|
159
|
+
|
|
160
|
+
interface ModalProps {
|
|
161
|
+
open: boolean;
|
|
162
|
+
onOpenChange: (open: boolean) => void;
|
|
163
|
+
title: string;
|
|
164
|
+
subtitle?: string;
|
|
165
|
+
children: ReactNode;
|
|
166
|
+
actions?: ReactNode;
|
|
167
|
+
width?: 'wide' | 'narrow';
|
|
168
|
+
}
|
|
169
|
+
declare function Modal({ open, onOpenChange, title, subtitle, children, actions, width }: ModalProps): react_jsx_runtime.JSX.Element;
|
|
170
|
+
|
|
171
|
+
interface PaginationProps {
|
|
172
|
+
page: number;
|
|
173
|
+
pageSize: number;
|
|
174
|
+
total: number;
|
|
175
|
+
onPage: (page: number) => void;
|
|
176
|
+
className?: string;
|
|
177
|
+
}
|
|
178
|
+
declare function Pagination({ page, pageSize, total, onPage, className }: PaginationProps): react_jsx_runtime.JSX.Element | null;
|
|
179
|
+
|
|
180
|
+
declare function Popover({ ...props }: React.ComponentProps<typeof PopoverPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
181
|
+
declare function PopoverTrigger({ ...props }: React.ComponentProps<typeof PopoverPrimitive.Trigger>): react_jsx_runtime.JSX.Element;
|
|
182
|
+
declare function PopoverContent({ className, align, sideOffset, ...props }: React.ComponentProps<typeof PopoverPrimitive.Content>): react_jsx_runtime.JSX.Element;
|
|
183
|
+
declare function PopoverAnchor({ ...props }: React.ComponentProps<typeof PopoverPrimitive.Anchor>): react_jsx_runtime.JSX.Element;
|
|
184
|
+
|
|
185
|
+
declare const Accordion: React.ForwardRefExoticComponent<(AccordionPrimitive.AccordionSingleProps | AccordionPrimitive.AccordionMultipleProps) & React.RefAttributes<HTMLDivElement>>;
|
|
186
|
+
declare const AccordionItem: React.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
187
|
+
declare const AccordionTrigger: React.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
188
|
+
declare const AccordionContent: React.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
189
|
+
|
|
190
|
+
declare function Select({ ...props }: React.ComponentProps<typeof SelectPrimitive.Root>): react_jsx_runtime.JSX.Element;
|
|
191
|
+
declare function SelectGroup({ ...props }: React.ComponentProps<typeof SelectPrimitive.Group>): react_jsx_runtime.JSX.Element;
|
|
192
|
+
declare function SelectValue({ ...props }: React.ComponentProps<typeof SelectPrimitive.Value>): react_jsx_runtime.JSX.Element;
|
|
193
|
+
declare function SelectTrigger({ className, size, children, ...props }: React.ComponentProps<typeof SelectPrimitive.Trigger> & {
|
|
194
|
+
size?: 'sm' | 'default';
|
|
195
|
+
}): react_jsx_runtime.JSX.Element;
|
|
196
|
+
declare function SelectContent({ className, children, position, ...props }: React.ComponentProps<typeof SelectPrimitive.Content>): react_jsx_runtime.JSX.Element;
|
|
197
|
+
declare function SelectLabel({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Label>): react_jsx_runtime.JSX.Element;
|
|
198
|
+
declare function SelectItem({ className, children, ...props }: React.ComponentProps<typeof SelectPrimitive.Item>): react_jsx_runtime.JSX.Element;
|
|
199
|
+
declare function SelectSeparator({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.Separator>): react_jsx_runtime.JSX.Element;
|
|
200
|
+
declare function SelectScrollUpButton({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.ScrollUpButton>): react_jsx_runtime.JSX.Element;
|
|
201
|
+
declare function SelectScrollDownButton({ className, ...props }: React.ComponentProps<typeof SelectPrimitive.ScrollDownButton>): react_jsx_runtime.JSX.Element;
|
|
202
|
+
|
|
203
|
+
declare const Toaster: ({ ...props }: ToasterProps) => react_jsx_runtime.JSX.Element;
|
|
204
|
+
|
|
205
|
+
export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertTitle, AlertWithAction, type AlertWithActionProps, AlertWithCountdown, type AlertWithCountdownProps, Badge, Button, ConfirmHost, type ConfirmOptions, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, ErrorBoundary, Input, Label, Modal, type ModalProps, Pagination, type PaginationProps, Popover, PopoverAnchor, PopoverContent, PopoverTrigger, PromptHost, type PromptOptions, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetContent, SheetDescription, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Skeleton, type SkeletonProps, Textarea, ThemeToggle, ThemeToggleLink, Toaster, Working, WorkingPanel, type WorkingProps, badgeVariants, buttonVariants, confirm, prompt };
|