kff-ui-kit 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/README.md +30 -0
- package/dist/index.cjs +6145 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +490 -0
- package/dist/index.d.ts +490 -0
- package/dist/index.js +5977 -0
- package/dist/index.js.map +1 -0
- package/package.json +58 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,490 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as React$1 from 'react';
|
|
3
|
+
import { ComponentProps, ReactNode, ElementType } from 'react';
|
|
4
|
+
import { VariantProps } from 'class-variance-authority';
|
|
5
|
+
import { useRender } from '@base-ui/react/use-render';
|
|
6
|
+
import { Button as Button$1 } from '@base-ui/react/button';
|
|
7
|
+
import { Checkbox as Checkbox$1 } from '@base-ui/react/checkbox';
|
|
8
|
+
import { Collapsible as Collapsible$1 } from '@base-ui/react/collapsible';
|
|
9
|
+
import { Dialog as Dialog$1 } from '@base-ui/react/dialog';
|
|
10
|
+
import { Menu } from '@base-ui/react/menu';
|
|
11
|
+
import { Progress as Progress$1 } from '@base-ui/react/progress';
|
|
12
|
+
import { Separator as Separator$1 } from '@base-ui/react/separator';
|
|
13
|
+
import { Tooltip as Tooltip$1 } from '@base-ui/react/tooltip';
|
|
14
|
+
import { ToasterProps } from 'sonner';
|
|
15
|
+
import { Tabs as Tabs$1 } from '@base-ui/react/tabs';
|
|
16
|
+
import { Toggle as Toggle$1 } from '@base-ui/react/toggle';
|
|
17
|
+
import { ToggleGroup as ToggleGroup$1 } from '@base-ui/react/toggle-group';
|
|
18
|
+
import { ClassValue } from 'clsx';
|
|
19
|
+
|
|
20
|
+
declare const alertVariants: (props?: ({
|
|
21
|
+
variant?: "default" | "destructive" | null | undefined;
|
|
22
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
23
|
+
declare function Alert({ className, variant, ...props }: React$1.ComponentProps<'div'> & VariantProps<typeof alertVariants>): React$1.JSX.Element;
|
|
24
|
+
declare function AlertTitle({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
25
|
+
declare function AlertDescription({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
26
|
+
declare function AlertAction({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
27
|
+
|
|
28
|
+
declare const badgeVariants: (props?: ({
|
|
29
|
+
variant?: "default" | "destructive" | "link" | "secondary" | "outline" | "ghost" | null | undefined;
|
|
30
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
31
|
+
declare function Badge({ className, variant, render, ...props }: useRender.ComponentProps<'span'> & VariantProps<typeof badgeVariants>): React$1.ReactElement<unknown, string | React$1.JSXElementConstructor<any>>;
|
|
32
|
+
|
|
33
|
+
declare function Breadcrumb({ className, ...props }: React$1.ComponentProps<'nav'>): React$1.JSX.Element;
|
|
34
|
+
declare function BreadcrumbList({ className, ...props }: React$1.ComponentProps<'ol'>): React$1.JSX.Element;
|
|
35
|
+
declare function BreadcrumbItem({ className, ...props }: React$1.ComponentProps<'li'>): React$1.JSX.Element;
|
|
36
|
+
declare function BreadcrumbLink({ className, render, ...props }: useRender.ComponentProps<'a'>): React$1.ReactElement<unknown, string | React$1.JSXElementConstructor<any>>;
|
|
37
|
+
declare function BreadcrumbPage({ className, ...props }: React$1.ComponentProps<'span'>): React$1.JSX.Element;
|
|
38
|
+
declare function BreadcrumbSeparator({ children, className, ...props }: React$1.ComponentProps<'li'>): React$1.JSX.Element;
|
|
39
|
+
declare function BreadcrumbEllipsis({ className, ...props }: React$1.ComponentProps<'span'>): React$1.JSX.Element;
|
|
40
|
+
|
|
41
|
+
declare const buttonVariants: (props?: ({
|
|
42
|
+
variant?: "default" | "destructive" | "link" | "secondary" | "outline" | "ghost" | null | undefined;
|
|
43
|
+
size?: "default" | "xs" | "sm" | "lg" | "icon" | "icon-xs" | "icon-sm" | "icon-lg" | null | undefined;
|
|
44
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
45
|
+
declare function Button({ className, variant, size, ...props }: Button$1.Props & VariantProps<typeof buttonVariants>): React$1.JSX.Element;
|
|
46
|
+
|
|
47
|
+
declare function Card({ className, size, ...props }: React$1.ComponentProps<'div'> & {
|
|
48
|
+
size?: 'default' | 'sm';
|
|
49
|
+
}): React$1.JSX.Element;
|
|
50
|
+
declare function CardHeader({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
51
|
+
declare function CardTitle({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
52
|
+
declare function CardDescription({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
53
|
+
declare function CardAction({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
54
|
+
declare function CardContent({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
55
|
+
declare function CardFooter({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
56
|
+
|
|
57
|
+
declare function Checkbox({ className, ...props }: Checkbox$1.Root.Props): React$1.JSX.Element;
|
|
58
|
+
|
|
59
|
+
declare function Collapsible({ ...props }: Collapsible$1.Root.Props): React$1.JSX.Element;
|
|
60
|
+
declare function CollapsibleTrigger({ ...props }: Collapsible$1.Trigger.Props): React$1.JSX.Element;
|
|
61
|
+
declare function CollapsibleContent({ ...props }: Collapsible$1.Panel.Props): React$1.JSX.Element;
|
|
62
|
+
|
|
63
|
+
declare function Dialog({ ...props }: Dialog$1.Root.Props): React$1.JSX.Element;
|
|
64
|
+
declare function DialogTrigger({ ...props }: Dialog$1.Trigger.Props): React$1.JSX.Element;
|
|
65
|
+
declare function DialogPortal({ ...props }: Dialog$1.Portal.Props): React$1.JSX.Element;
|
|
66
|
+
declare function DialogClose({ ...props }: Dialog$1.Close.Props): React$1.JSX.Element;
|
|
67
|
+
declare function DialogOverlay({ className, ...props }: Dialog$1.Backdrop.Props): React$1.JSX.Element;
|
|
68
|
+
declare function DialogContent({ className, children, showCloseButton, ...props }: Dialog$1.Popup.Props & {
|
|
69
|
+
showCloseButton?: boolean;
|
|
70
|
+
}): React$1.JSX.Element;
|
|
71
|
+
declare function DialogHeader({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
72
|
+
declare function DialogFooter({ className, showCloseButton, children, ...props }: React$1.ComponentProps<'div'> & {
|
|
73
|
+
showCloseButton?: boolean;
|
|
74
|
+
}): React$1.JSX.Element;
|
|
75
|
+
declare function DialogTitle({ className, ...props }: Dialog$1.Title.Props): React$1.JSX.Element;
|
|
76
|
+
declare function DialogDescription({ className, ...props }: Dialog$1.Description.Props): React$1.JSX.Element;
|
|
77
|
+
|
|
78
|
+
declare function DropdownMenu({ ...props }: Menu.Root.Props): React$1.JSX.Element;
|
|
79
|
+
declare function DropdownMenuPortal({ ...props }: Menu.Portal.Props): React$1.JSX.Element;
|
|
80
|
+
declare function DropdownMenuTrigger({ ...props }: Menu.Trigger.Props): React$1.JSX.Element;
|
|
81
|
+
declare function DropdownMenuContent({ align, alignOffset, side, sideOffset, className, ...props }: Menu.Popup.Props & Pick<Menu.Positioner.Props, 'align' | 'alignOffset' | 'side' | 'sideOffset'>): React$1.JSX.Element;
|
|
82
|
+
declare function DropdownMenuGroup({ ...props }: Menu.Group.Props): React$1.JSX.Element;
|
|
83
|
+
declare function DropdownMenuLabel({ className, inset, ...props }: Menu.GroupLabel.Props & {
|
|
84
|
+
inset?: boolean;
|
|
85
|
+
}): React$1.JSX.Element;
|
|
86
|
+
declare function DropdownMenuItem({ className, inset, variant, ...props }: Menu.Item.Props & {
|
|
87
|
+
inset?: boolean;
|
|
88
|
+
variant?: 'default' | 'destructive';
|
|
89
|
+
}): React$1.JSX.Element;
|
|
90
|
+
declare function DropdownMenuSub({ ...props }: Menu.SubmenuRoot.Props): React$1.JSX.Element;
|
|
91
|
+
declare function DropdownMenuSubTrigger({ className, inset, children, ...props }: Menu.SubmenuTrigger.Props & {
|
|
92
|
+
inset?: boolean;
|
|
93
|
+
}): React$1.JSX.Element;
|
|
94
|
+
declare function DropdownMenuSubContent({ align, alignOffset, side, sideOffset, className, ...props }: React$1.ComponentProps<typeof DropdownMenuContent>): React$1.JSX.Element;
|
|
95
|
+
declare function DropdownMenuCheckboxItem({ className, children, checked, inset, ...props }: Menu.CheckboxItem.Props & {
|
|
96
|
+
inset?: boolean;
|
|
97
|
+
}): React$1.JSX.Element;
|
|
98
|
+
declare function DropdownMenuRadioGroup({ ...props }: Menu.RadioGroup.Props): React$1.JSX.Element;
|
|
99
|
+
declare function DropdownMenuRadioItem({ className, children, inset, ...props }: Menu.RadioItem.Props & {
|
|
100
|
+
inset?: boolean;
|
|
101
|
+
}): React$1.JSX.Element;
|
|
102
|
+
declare function DropdownMenuSeparator({ className, ...props }: Menu.Separator.Props): React$1.JSX.Element;
|
|
103
|
+
declare function DropdownMenuShortcut({ className, ...props }: React$1.ComponentProps<'span'>): React$1.JSX.Element;
|
|
104
|
+
|
|
105
|
+
declare function Input({ className, type, ...props }: React$1.ComponentProps<'input'>): React$1.JSX.Element;
|
|
106
|
+
|
|
107
|
+
declare function Progress({ className, children, value, ...props }: Progress$1.Root.Props): React$1.JSX.Element;
|
|
108
|
+
declare function ProgressTrack({ className, ...props }: Progress$1.Track.Props): React$1.JSX.Element;
|
|
109
|
+
declare function ProgressIndicator({ className, ...props }: Progress$1.Indicator.Props): React$1.JSX.Element;
|
|
110
|
+
declare function ProgressLabel({ className, ...props }: Progress$1.Label.Props): React$1.JSX.Element;
|
|
111
|
+
declare function ProgressValue({ className, ...props }: Progress$1.Value.Props): React$1.JSX.Element;
|
|
112
|
+
|
|
113
|
+
declare function Separator({ className, orientation, ...props }: Separator$1.Props): React$1.JSX.Element;
|
|
114
|
+
|
|
115
|
+
declare function Sheet({ ...props }: Dialog$1.Root.Props): React$1.JSX.Element;
|
|
116
|
+
declare function SheetTrigger({ ...props }: Dialog$1.Trigger.Props): React$1.JSX.Element;
|
|
117
|
+
declare function SheetClose({ ...props }: Dialog$1.Close.Props): React$1.JSX.Element;
|
|
118
|
+
declare function SheetContent({ className, children, side, showCloseButton, ...props }: Dialog$1.Popup.Props & {
|
|
119
|
+
side?: 'top' | 'right' | 'bottom' | 'left';
|
|
120
|
+
showCloseButton?: boolean;
|
|
121
|
+
}): React$1.JSX.Element;
|
|
122
|
+
declare function SheetHeader({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
123
|
+
declare function SheetFooter({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
124
|
+
declare function SheetTitle({ className, ...props }: Dialog$1.Title.Props): React$1.JSX.Element;
|
|
125
|
+
declare function SheetDescription({ className, ...props }: Dialog$1.Description.Props): React$1.JSX.Element;
|
|
126
|
+
|
|
127
|
+
declare function TooltipProvider({ delay, ...props }: Tooltip$1.Provider.Props): React$1.JSX.Element;
|
|
128
|
+
declare function Tooltip({ ...props }: Tooltip$1.Root.Props): React$1.JSX.Element;
|
|
129
|
+
declare function TooltipTrigger({ ...props }: Tooltip$1.Trigger.Props): React$1.JSX.Element;
|
|
130
|
+
declare function TooltipContent({ className, side, sideOffset, align, alignOffset, children, ...props }: Tooltip$1.Popup.Props & Pick<Tooltip$1.Positioner.Props, 'align' | 'alignOffset' | 'side' | 'sideOffset'>): React$1.JSX.Element;
|
|
131
|
+
|
|
132
|
+
type SidebarContextProps = {
|
|
133
|
+
state: 'expanded' | 'collapsed';
|
|
134
|
+
open: boolean;
|
|
135
|
+
setOpen: (open: boolean) => void;
|
|
136
|
+
openMobile: boolean;
|
|
137
|
+
setOpenMobile: (open: boolean) => void;
|
|
138
|
+
isMobile: boolean;
|
|
139
|
+
toggleSidebar: () => void;
|
|
140
|
+
};
|
|
141
|
+
declare function useSidebar(): SidebarContextProps;
|
|
142
|
+
declare function SidebarProvider({ defaultOpen, open: openProp, onOpenChange: setOpenProp, className, style, children, ...props }: React$1.ComponentProps<'div'> & {
|
|
143
|
+
defaultOpen?: boolean;
|
|
144
|
+
open?: boolean;
|
|
145
|
+
onOpenChange?: (open: boolean) => void;
|
|
146
|
+
}): React$1.JSX.Element;
|
|
147
|
+
declare function Sidebar({ side, variant, collapsible, className, children, dir, ...props }: React$1.ComponentProps<'div'> & {
|
|
148
|
+
side?: 'left' | 'right';
|
|
149
|
+
variant?: 'sidebar' | 'floating' | 'inset';
|
|
150
|
+
collapsible?: 'offcanvas' | 'icon' | 'none';
|
|
151
|
+
}): React$1.JSX.Element;
|
|
152
|
+
declare function SidebarTrigger({ className, onClick, ...props }: React$1.ComponentProps<typeof Button>): React$1.JSX.Element;
|
|
153
|
+
declare function SidebarRail({ className, ...props }: React$1.ComponentProps<'button'>): React$1.JSX.Element;
|
|
154
|
+
declare function SidebarInset({ className, ...props }: React$1.ComponentProps<'main'>): React$1.JSX.Element;
|
|
155
|
+
declare function SidebarInput({ className, ...props }: React$1.ComponentProps<typeof Input>): React$1.JSX.Element;
|
|
156
|
+
declare function SidebarHeader({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
157
|
+
declare function SidebarFooter({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
158
|
+
declare function SidebarSeparator({ className, ...props }: React$1.ComponentProps<typeof Separator>): React$1.JSX.Element;
|
|
159
|
+
declare function SidebarContent({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
160
|
+
declare function SidebarGroup({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
161
|
+
declare function SidebarGroupLabel({ className, render, ...props }: useRender.ComponentProps<'div'> & React$1.ComponentProps<'div'>): React$1.ReactElement<unknown, string | React$1.JSXElementConstructor<any>>;
|
|
162
|
+
declare function SidebarGroupAction({ className, render, ...props }: useRender.ComponentProps<'button'> & React$1.ComponentProps<'button'>): React$1.ReactElement<unknown, string | React$1.JSXElementConstructor<any>>;
|
|
163
|
+
declare function SidebarGroupContent({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
164
|
+
declare function SidebarMenu({ className, ...props }: React$1.ComponentProps<'ul'>): React$1.JSX.Element;
|
|
165
|
+
declare function SidebarMenuItem({ className, ...props }: React$1.ComponentProps<'li'>): React$1.JSX.Element;
|
|
166
|
+
declare const sidebarMenuButtonVariants: (props?: ({
|
|
167
|
+
variant?: "default" | "outline" | null | undefined;
|
|
168
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
169
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
170
|
+
declare function SidebarMenuButton({ render, isActive, variant, size, tooltip, className, ...props }: useRender.ComponentProps<'button'> & React$1.ComponentProps<'button'> & {
|
|
171
|
+
isActive?: boolean;
|
|
172
|
+
tooltip?: string | React$1.ComponentProps<typeof TooltipContent>;
|
|
173
|
+
} & VariantProps<typeof sidebarMenuButtonVariants>): React$1.JSX.Element;
|
|
174
|
+
declare function SidebarMenuAction({ className, render, showOnHover, ...props }: useRender.ComponentProps<'button'> & React$1.ComponentProps<'button'> & {
|
|
175
|
+
showOnHover?: boolean;
|
|
176
|
+
}): React$1.ReactElement<unknown, string | React$1.JSXElementConstructor<any>>;
|
|
177
|
+
declare function SidebarMenuBadge({ className, ...props }: React$1.ComponentProps<'div'>): React$1.JSX.Element;
|
|
178
|
+
declare function SidebarMenuSkeleton({ className, showIcon, ...props }: React$1.ComponentProps<'div'> & {
|
|
179
|
+
showIcon?: boolean;
|
|
180
|
+
}): React$1.JSX.Element;
|
|
181
|
+
declare function SidebarMenuSub({ className, ...props }: React$1.ComponentProps<'ul'>): React$1.JSX.Element;
|
|
182
|
+
declare function SidebarMenuSubItem({ className, ...props }: React$1.ComponentProps<'li'>): React$1.JSX.Element;
|
|
183
|
+
declare function SidebarMenuSubButton({ render, size, isActive, className, ...props }: useRender.ComponentProps<'a'> & React$1.ComponentProps<'a'> & {
|
|
184
|
+
size?: 'sm' | 'md';
|
|
185
|
+
isActive?: boolean;
|
|
186
|
+
}): React$1.ReactElement<unknown, string | React$1.JSXElementConstructor<any>>;
|
|
187
|
+
|
|
188
|
+
declare function Skeleton({ className, ...props }: React.ComponentProps<'div'>): React$1.JSX.Element;
|
|
189
|
+
|
|
190
|
+
declare const Toaster$1: ({ ...props }: ToasterProps) => React$1.JSX.Element;
|
|
191
|
+
|
|
192
|
+
declare function Table({ className, ...props }: React$1.ComponentProps<'table'>): React$1.JSX.Element;
|
|
193
|
+
declare function TableHeader({ className, ...props }: React$1.ComponentProps<'thead'>): React$1.JSX.Element;
|
|
194
|
+
declare function TableBody({ className, ...props }: React$1.ComponentProps<'tbody'>): React$1.JSX.Element;
|
|
195
|
+
declare function TableFooter({ className, ...props }: React$1.ComponentProps<'tfoot'>): React$1.JSX.Element;
|
|
196
|
+
declare function TableRow({ className, ...props }: React$1.ComponentProps<'tr'>): React$1.JSX.Element;
|
|
197
|
+
declare function TableHead({ className, ...props }: React$1.ComponentProps<'th'>): React$1.JSX.Element;
|
|
198
|
+
declare function TableCell({ className, ...props }: React$1.ComponentProps<'td'>): React$1.JSX.Element;
|
|
199
|
+
declare function TableCaption({ className, ...props }: React$1.ComponentProps<'caption'>): React$1.JSX.Element;
|
|
200
|
+
|
|
201
|
+
declare function Tabs({ className, orientation, ...props }: Tabs$1.Root.Props): React$1.JSX.Element;
|
|
202
|
+
declare const tabsListVariants: (props?: ({
|
|
203
|
+
variant?: "default" | "line" | null | undefined;
|
|
204
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
205
|
+
declare function TabsList({ className, variant, ...props }: Tabs$1.List.Props & VariantProps<typeof tabsListVariants>): React$1.JSX.Element;
|
|
206
|
+
declare function TabsTrigger({ className, ...props }: Tabs$1.Tab.Props): React$1.JSX.Element;
|
|
207
|
+
declare function TabsContent({ className, ...props }: Tabs$1.Panel.Props): React$1.JSX.Element;
|
|
208
|
+
|
|
209
|
+
declare const toggleVariants: (props?: ({
|
|
210
|
+
variant?: "default" | "outline" | null | undefined;
|
|
211
|
+
size?: "default" | "sm" | "lg" | null | undefined;
|
|
212
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
213
|
+
declare function Toggle({ className, variant, size, ...props }: Toggle$1.Props & VariantProps<typeof toggleVariants>): React$1.JSX.Element;
|
|
214
|
+
|
|
215
|
+
declare function ToggleGroup({ className, variant, size, spacing, orientation, children, ...props }: ToggleGroup$1.Props & VariantProps<typeof toggleVariants> & {
|
|
216
|
+
spacing?: number;
|
|
217
|
+
orientation?: 'horizontal' | 'vertical';
|
|
218
|
+
}): React$1.JSX.Element;
|
|
219
|
+
declare function ToggleGroupItem({ className, children, variant, size, ...props }: Toggle$1.Props & VariantProps<typeof toggleVariants>): React$1.JSX.Element;
|
|
220
|
+
|
|
221
|
+
type Props = ComponentProps<typeof Button> & {
|
|
222
|
+
dashed?: boolean;
|
|
223
|
+
accent?: boolean;
|
|
224
|
+
};
|
|
225
|
+
declare function ActionButton({ className, variant, size, dashed, accent, render, ...props }: Props): React$1.JSX.Element;
|
|
226
|
+
|
|
227
|
+
type SidebarNavItem = {
|
|
228
|
+
id: string;
|
|
229
|
+
href: string;
|
|
230
|
+
glyph: string;
|
|
231
|
+
label: string;
|
|
232
|
+
badge?: number;
|
|
233
|
+
};
|
|
234
|
+
type SidebarNavGroup = {
|
|
235
|
+
label: string;
|
|
236
|
+
items: SidebarNavItem[];
|
|
237
|
+
};
|
|
238
|
+
type SidebarLinkComponent = ElementType<{
|
|
239
|
+
href: string;
|
|
240
|
+
} & ComponentProps<'a'>>;
|
|
241
|
+
declare function AppSidebar({ groups, activeId, header, footer, linkAs: LinkAs, }: {
|
|
242
|
+
groups: SidebarNavGroup[];
|
|
243
|
+
activeId: string;
|
|
244
|
+
header?: ReactNode;
|
|
245
|
+
footer?: ReactNode;
|
|
246
|
+
linkAs?: SidebarLinkComponent;
|
|
247
|
+
}): React$1.JSX.Element;
|
|
248
|
+
|
|
249
|
+
declare const ACCEPTED_MIME: readonly ["application/pdf", "application/vnd.openxmlformats-officedocument.wordprocessingml.document", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", "image/png", "image/jpeg"];
|
|
250
|
+
declare const MAX_FILE_BYTES: number;
|
|
251
|
+
type ScanState = 'SCANNING' | 'CLEAN' | 'INFECTED';
|
|
252
|
+
type AttachmentValue = {
|
|
253
|
+
name: string;
|
|
254
|
+
scan: ScanState;
|
|
255
|
+
};
|
|
256
|
+
declare function validateAttachment(file: File): string | null;
|
|
257
|
+
declare function AttachmentField({ value, error, onUpload, onRemove, }: {
|
|
258
|
+
value?: AttachmentValue;
|
|
259
|
+
error?: string;
|
|
260
|
+
onUpload: (file?: File) => void;
|
|
261
|
+
onRemove: () => void;
|
|
262
|
+
}): React$1.JSX.Element;
|
|
263
|
+
|
|
264
|
+
type ChecklistItem = {
|
|
265
|
+
title: string;
|
|
266
|
+
covered: boolean;
|
|
267
|
+
};
|
|
268
|
+
declare function ChecklistPanel({ items, covered }: {
|
|
269
|
+
items: ChecklistItem[];
|
|
270
|
+
covered: number;
|
|
271
|
+
}): React$1.JSX.Element;
|
|
272
|
+
|
|
273
|
+
type ColumnDef<T> = {
|
|
274
|
+
key: keyof T & string;
|
|
275
|
+
header: string;
|
|
276
|
+
width?: string;
|
|
277
|
+
align?: 'left' | 'right';
|
|
278
|
+
kind?: 'text' | 'amount' | 'date' | 'status';
|
|
279
|
+
total?: boolean;
|
|
280
|
+
};
|
|
281
|
+
type DetailBlockConfig<T> = {
|
|
282
|
+
formNumber: string;
|
|
283
|
+
title: string;
|
|
284
|
+
targetLine: string;
|
|
285
|
+
columns: ColumnDef<T>[];
|
|
286
|
+
emptyConfirmable: boolean;
|
|
287
|
+
rowAttachments: boolean;
|
|
288
|
+
};
|
|
289
|
+
declare function DetailTable<T extends {
|
|
290
|
+
id: string;
|
|
291
|
+
}>({ config, rows, onAdd, onEdit, onDelete, }: {
|
|
292
|
+
config: DetailBlockConfig<T>;
|
|
293
|
+
rows: T[];
|
|
294
|
+
onAdd: () => void;
|
|
295
|
+
onEdit: (row: T) => void;
|
|
296
|
+
onDelete: (row: T) => void;
|
|
297
|
+
}): React$1.JSX.Element;
|
|
298
|
+
|
|
299
|
+
type JobState = 'QUEUED' | 'RUNNING' | 'DONE' | 'FAILED';
|
|
300
|
+
type ExportJobFile = {
|
|
301
|
+
name: string;
|
|
302
|
+
sha: string;
|
|
303
|
+
size: string;
|
|
304
|
+
url: string;
|
|
305
|
+
};
|
|
306
|
+
type ExportJob = {
|
|
307
|
+
title: string;
|
|
308
|
+
state: JobState;
|
|
309
|
+
progress?: number;
|
|
310
|
+
error?: string;
|
|
311
|
+
files?: ExportJobFile[];
|
|
312
|
+
};
|
|
313
|
+
declare function ExportJobCard({ job, onRetry }: {
|
|
314
|
+
job: ExportJob;
|
|
315
|
+
onRetry: () => void;
|
|
316
|
+
}): React$1.JSX.Element;
|
|
317
|
+
|
|
318
|
+
type FormDialogProps = {
|
|
319
|
+
open: boolean;
|
|
320
|
+
onOpenChange: (open: boolean) => void;
|
|
321
|
+
requirement: string;
|
|
322
|
+
title: string;
|
|
323
|
+
description: string;
|
|
324
|
+
errors?: string[];
|
|
325
|
+
children?: ReactNode;
|
|
326
|
+
primaryLabel: string;
|
|
327
|
+
onSubmit: () => void;
|
|
328
|
+
};
|
|
329
|
+
declare function FormDialog({ open, onOpenChange, requirement, title, description, errors, children, primaryLabel, onSubmit, }: FormDialogProps): React$1.JSX.Element;
|
|
330
|
+
|
|
331
|
+
type CellState = 'value' | 'unanswered' | 'empty' | 'na' | 'computed';
|
|
332
|
+
declare function ValueCell({ state, value, reason, source, onEdit, }: {
|
|
333
|
+
state: CellState;
|
|
334
|
+
value?: number;
|
|
335
|
+
reason?: string;
|
|
336
|
+
source?: string;
|
|
337
|
+
onEdit?: () => void;
|
|
338
|
+
}): React$1.JSX.Element;
|
|
339
|
+
|
|
340
|
+
type RowKind = 'group' | 'row' | 'additive' | 'memo' | 'subtotal' | 'total';
|
|
341
|
+
type FormRowModel = {
|
|
342
|
+
id: string;
|
|
343
|
+
kind: RowKind;
|
|
344
|
+
name: string;
|
|
345
|
+
value?: number;
|
|
346
|
+
current: Omit<ComponentProps<typeof ValueCell>, 'onEdit'>;
|
|
347
|
+
};
|
|
348
|
+
declare function FormTableHeader({ title, date }: {
|
|
349
|
+
title: string;
|
|
350
|
+
date: string;
|
|
351
|
+
}): React$1.JSX.Element;
|
|
352
|
+
declare function FormRow({ row, onEdit }: {
|
|
353
|
+
row: FormRowModel;
|
|
354
|
+
onEdit: () => void;
|
|
355
|
+
}): React$1.JSX.Element;
|
|
356
|
+
declare const sumChildren: (rows: FormRowModel[]) => number;
|
|
357
|
+
|
|
358
|
+
type IssueLevel = 'BLOCKING' | 'WARNING' | 'INFO';
|
|
359
|
+
type Issue = {
|
|
360
|
+
level: IssueLevel;
|
|
361
|
+
ruleCode: string;
|
|
362
|
+
message: string;
|
|
363
|
+
scope?: string;
|
|
364
|
+
};
|
|
365
|
+
declare function IssueCard({ issue }: {
|
|
366
|
+
issue: Issue;
|
|
367
|
+
}): React$1.JSX.Element;
|
|
368
|
+
declare const sortIssues: (list: Issue[]) => Issue[];
|
|
369
|
+
|
|
370
|
+
type PageHeaderTrailItem = {
|
|
371
|
+
label: string;
|
|
372
|
+
href?: string;
|
|
373
|
+
};
|
|
374
|
+
declare function PageHeader({ trail, title, actions, }: {
|
|
375
|
+
trail: PageHeaderTrailItem[];
|
|
376
|
+
title: string;
|
|
377
|
+
actions?: ReactNode;
|
|
378
|
+
}): React$1.JSX.Element;
|
|
379
|
+
|
|
380
|
+
declare function SectionTabs({ value, onChange, items, }: {
|
|
381
|
+
value: string;
|
|
382
|
+
onChange: (v: string) => void;
|
|
383
|
+
items: {
|
|
384
|
+
value: string;
|
|
385
|
+
label: string;
|
|
386
|
+
badge?: number;
|
|
387
|
+
}[];
|
|
388
|
+
}): React$1.JSX.Element;
|
|
389
|
+
type FormChipItem = {
|
|
390
|
+
id: string;
|
|
391
|
+
title: string;
|
|
392
|
+
readiness: 'ready' | 'progress' | 'errors';
|
|
393
|
+
};
|
|
394
|
+
declare function FormChips({ value, onChange, forms, }: {
|
|
395
|
+
value: string;
|
|
396
|
+
onChange: (v: string) => void;
|
|
397
|
+
forms: FormChipItem[];
|
|
398
|
+
}): React$1.JSX.Element;
|
|
399
|
+
|
|
400
|
+
declare const REPORT_STATUS: {
|
|
401
|
+
readonly draft: {
|
|
402
|
+
readonly glyph: "○";
|
|
403
|
+
readonly label: "черновик";
|
|
404
|
+
readonly ring: "border-dashed";
|
|
405
|
+
};
|
|
406
|
+
readonly submitted: {
|
|
407
|
+
readonly glyph: "◐";
|
|
408
|
+
readonly label: "отправлен";
|
|
409
|
+
readonly ring: "bg-primary text-primary-foreground";
|
|
410
|
+
};
|
|
411
|
+
readonly review: {
|
|
412
|
+
readonly glyph: "⟳";
|
|
413
|
+
readonly label: "на проверке";
|
|
414
|
+
readonly ring: "bg-hatch";
|
|
415
|
+
};
|
|
416
|
+
readonly needsRevision: {
|
|
417
|
+
readonly glyph: "↩";
|
|
418
|
+
readonly label: "на доработке";
|
|
419
|
+
readonly ring: "border-2";
|
|
420
|
+
};
|
|
421
|
+
readonly accepted: {
|
|
422
|
+
readonly glyph: "✓";
|
|
423
|
+
readonly label: "принят";
|
|
424
|
+
readonly ring: "bg-accent";
|
|
425
|
+
};
|
|
426
|
+
};
|
|
427
|
+
type ReportStatus = keyof typeof REPORT_STATUS;
|
|
428
|
+
declare const DEBT_STATUS: {
|
|
429
|
+
readonly overdue: {
|
|
430
|
+
readonly glyph: "▲";
|
|
431
|
+
readonly label: "просроченная";
|
|
432
|
+
readonly ring: "border-2 bg-hatch";
|
|
433
|
+
readonly doc: true;
|
|
434
|
+
};
|
|
435
|
+
readonly deferred: {
|
|
436
|
+
readonly glyph: "→";
|
|
437
|
+
readonly label: "отсроченная";
|
|
438
|
+
readonly ring: "border-dashed";
|
|
439
|
+
readonly doc: true;
|
|
440
|
+
};
|
|
441
|
+
readonly disputed: {
|
|
442
|
+
readonly glyph: "≠";
|
|
443
|
+
readonly label: "оспариваемая";
|
|
444
|
+
readonly ring: "border-2 border-double";
|
|
445
|
+
readonly doc: true;
|
|
446
|
+
};
|
|
447
|
+
readonly review: {
|
|
448
|
+
readonly glyph: "⟳";
|
|
449
|
+
readonly label: "на рассмотрении";
|
|
450
|
+
readonly ring: "bg-muted";
|
|
451
|
+
readonly doc: true;
|
|
452
|
+
};
|
|
453
|
+
readonly conditional: {
|
|
454
|
+
readonly glyph: "?";
|
|
455
|
+
readonly label: "условная";
|
|
456
|
+
readonly ring: "border-dotted bg-secondary";
|
|
457
|
+
readonly doc: true;
|
|
458
|
+
};
|
|
459
|
+
readonly current: {
|
|
460
|
+
readonly glyph: "○";
|
|
461
|
+
readonly label: "непросроченная";
|
|
462
|
+
readonly ring: "";
|
|
463
|
+
readonly doc: false;
|
|
464
|
+
};
|
|
465
|
+
readonly paid: {
|
|
466
|
+
readonly glyph: "✓";
|
|
467
|
+
readonly label: "оплачена";
|
|
468
|
+
readonly ring: "bg-primary text-primary-foreground";
|
|
469
|
+
readonly doc: false;
|
|
470
|
+
};
|
|
471
|
+
};
|
|
472
|
+
type DebtStatus = keyof typeof DEBT_STATUS;
|
|
473
|
+
type StatusBadgeProps = {
|
|
474
|
+
kind: 'report';
|
|
475
|
+
status: ReportStatus;
|
|
476
|
+
} | {
|
|
477
|
+
kind: 'debt';
|
|
478
|
+
status: DebtStatus;
|
|
479
|
+
};
|
|
480
|
+
declare function StatusBadge(props: StatusBadgeProps): React$1.JSX.Element;
|
|
481
|
+
|
|
482
|
+
declare function Toaster(): React$1.JSX.Element;
|
|
483
|
+
|
|
484
|
+
declare function ValidationSummary({ errors }: {
|
|
485
|
+
errors: string[];
|
|
486
|
+
}): React$1.JSX.Element | null;
|
|
487
|
+
|
|
488
|
+
declare function cn(...inputs: ClassValue[]): string;
|
|
489
|
+
|
|
490
|
+
export { ACCEPTED_MIME, ActionButton, Alert, AlertAction, AlertDescription, AlertTitle, AppSidebar, AttachmentField, type AttachmentValue, Badge, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type CellState, Checkbox, type ChecklistItem, ChecklistPanel, Collapsible, CollapsibleContent, CollapsibleTrigger, type ColumnDef, DEBT_STATUS, type DebtStatus, type DetailBlockConfig, DetailTable, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, type ExportJob, ExportJobCard, type ExportJobFile, type FormChipItem, FormChips, FormDialog, type FormDialogProps, FormRow, type FormRowModel, FormTableHeader, Input, type Issue, IssueCard, type IssueLevel, type JobState, MAX_FILE_BYTES, PageHeader, type PageHeaderTrailItem, Progress, ProgressIndicator, ProgressLabel, ProgressTrack, ProgressValue, REPORT_STATUS, type ReportStatus, type RowKind, type ScanState, SectionTabs, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, type SidebarNavGroup, type SidebarNavItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, StatusBadge, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Toaster, Toaster$1 as ToasterPrimitive, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, ValidationSummary, ValueCell, badgeVariants, buttonVariants, cn, sortIssues, sumChildren, tabsListVariants, toggleVariants, useSidebar, validateAttachment };
|