@djangocfg/ui-nextjs 2.1.103 → 2.1.104
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/package.json +26 -30
- package/src/components/index.ts +2 -0
- package/src/components/ssr-pagination.tsx +2 -1
- package/src/hooks/index.ts +1 -6
- package/src/index.ts +2 -0
- package/src/theme/index.ts +2 -0
- package/dist/animations.cjs +0 -880
- package/dist/animations.cjs.map +0 -1
- package/dist/animations.d.mts +0 -36
- package/dist/animations.d.ts +0 -36
- package/dist/animations.mjs +0 -877
- package/dist/animations.mjs.map +0 -1
- package/dist/blocks.cjs +0 -1609
- package/dist/blocks.cjs.map +0 -1
- package/dist/blocks.d.mts +0 -278
- package/dist/blocks.d.ts +0 -278
- package/dist/blocks.mjs +0 -1589
- package/dist/blocks.mjs.map +0 -1
- package/dist/components.cjs +0 -1946
- package/dist/components.cjs.map +0 -1
- package/dist/components.d.mts +0 -322
- package/dist/components.d.ts +0 -322
- package/dist/components.mjs +0 -1860
- package/dist/components.mjs.map +0 -1
- package/dist/hooks.cjs +0 -530
- package/dist/hooks.cjs.map +0 -1
- package/dist/hooks.d.mts +0 -364
- package/dist/hooks.d.ts +0 -364
- package/dist/hooks.mjs +0 -506
- package/dist/hooks.mjs.map +0 -1
- package/dist/index.cjs +0 -4080
- package/dist/index.cjs.map +0 -1
- package/dist/index.d.mts +0 -1044
- package/dist/index.d.ts +0 -1044
- package/dist/index.mjs +0 -3962
- package/dist/index.mjs.map +0 -1
- package/dist/theme.cjs +0 -189
- package/dist/theme.cjs.map +0 -1
- package/dist/theme.d.mts +0 -60
- package/dist/theme.d.ts +0 -60
- package/dist/theme.mjs +0 -184
- package/dist/theme.mjs.map +0 -1
- package/src/hooks/useCfgRouter.ts +0 -153
- package/src/hooks/useQueryParams.ts +0 -73
package/dist/index.d.mts
DELETED
|
@@ -1,1044 +0,0 @@
|
|
|
1
|
-
import * as _djangocfg_ui_core_components from '@djangocfg/ui-core/components';
|
|
2
|
-
import { ButtonProps, TooltipContent, Separator } from '@djangocfg/ui-core/components';
|
|
3
|
-
export * from '@djangocfg/ui-core/components';
|
|
4
|
-
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
|
-
import * as React from 'react';
|
|
6
|
-
import React__default, { RefObject, ReactNode } from 'react';
|
|
7
|
-
import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
|
|
8
|
-
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
9
|
-
import { VariantProps } from 'class-variance-authority';
|
|
10
|
-
export * from '@djangocfg/ui-core/hooks';
|
|
11
|
-
import { Keys, HotkeyCallback, Options } from 'react-hotkeys-hook';
|
|
12
|
-
export { HotkeyCallback, HotkeysProvider, Keys, isHotkeyPressed, useHotkeysContext } from 'react-hotkeys-hook';
|
|
13
|
-
import { ThemeProviderProps as ThemeProviderProps$1 } from 'next-themes';
|
|
14
|
-
|
|
15
|
-
declare const Breadcrumb: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
|
|
16
|
-
separator?: React.ReactNode;
|
|
17
|
-
} & React.RefAttributes<HTMLElement>>;
|
|
18
|
-
declare const BreadcrumbList: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.OlHTMLAttributes<HTMLOListElement>, HTMLOListElement>, "ref"> & React.RefAttributes<HTMLOListElement>>;
|
|
19
|
-
declare const BreadcrumbItem$1: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & {
|
|
20
|
-
key?: React.Key;
|
|
21
|
-
} & React.RefAttributes<HTMLLIElement>>;
|
|
22
|
-
declare const BreadcrumbLink: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "ref"> & {
|
|
23
|
-
asChild?: boolean;
|
|
24
|
-
href?: string;
|
|
25
|
-
} & React.RefAttributes<HTMLAnchorElement>>;
|
|
26
|
-
declare const BreadcrumbPage: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
|
27
|
-
declare const BreadcrumbSeparator: {
|
|
28
|
-
({ children, className, ...props }: React.ComponentProps<"li"> & {
|
|
29
|
-
key?: React.Key;
|
|
30
|
-
}): react_jsx_runtime.JSX.Element;
|
|
31
|
-
displayName: string;
|
|
32
|
-
};
|
|
33
|
-
declare const BreadcrumbEllipsis: {
|
|
34
|
-
({ className, ...props }: React.ComponentProps<"span">): react_jsx_runtime.JSX.Element;
|
|
35
|
-
displayName: string;
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
interface BreadcrumbItem {
|
|
39
|
-
/** Display text for the breadcrumb */
|
|
40
|
-
label: string;
|
|
41
|
-
/** URL to navigate to. If not provided, item will be rendered as current page */
|
|
42
|
-
href?: string;
|
|
43
|
-
/** Whether this item is the current page (will be rendered as BreadcrumbPage) */
|
|
44
|
-
isCurrentPage?: boolean;
|
|
45
|
-
/** Optional icon to display before the label */
|
|
46
|
-
icon?: React__default.ReactNode;
|
|
47
|
-
}
|
|
48
|
-
interface BreadcrumbNavigationProps {
|
|
49
|
-
/** Array of breadcrumb items */
|
|
50
|
-
items: BreadcrumbItem[];
|
|
51
|
-
/** Custom separator between items */
|
|
52
|
-
separator?: React__default.ReactNode;
|
|
53
|
-
/** Maximum number of items to show before collapsing with ellipsis */
|
|
54
|
-
maxItems?: number;
|
|
55
|
-
/** Custom className for the breadcrumb container */
|
|
56
|
-
className?: string;
|
|
57
|
-
/** Whether to use Next.js Link component for navigation */
|
|
58
|
-
useNextLink?: boolean;
|
|
59
|
-
}
|
|
60
|
-
declare const BreadcrumbNavigation: React__default.FC<BreadcrumbNavigationProps>;
|
|
61
|
-
|
|
62
|
-
declare const DropdownMenu: React.FC<DropdownMenuPrimitive.DropdownMenuProps>;
|
|
63
|
-
declare const DropdownMenuTrigger: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
64
|
-
declare const DropdownMenuGroup: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuGroupProps & React.RefAttributes<HTMLDivElement>>;
|
|
65
|
-
declare const DropdownMenuSub: React.FC<DropdownMenuPrimitive.DropdownMenuSubProps>;
|
|
66
|
-
declare const DropdownMenuRadioGroup: React.ForwardRefExoticComponent<DropdownMenuPrimitive.DropdownMenuRadioGroupProps & React.RefAttributes<HTMLDivElement>>;
|
|
67
|
-
declare const DropdownMenuSubTrigger: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubTriggerProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
68
|
-
inset?: boolean;
|
|
69
|
-
} & React.RefAttributes<HTMLDivElement>>;
|
|
70
|
-
declare const DropdownMenuSubContent: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
71
|
-
declare const DropdownMenuContent: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
72
|
-
declare const DropdownMenuItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
73
|
-
inset?: boolean;
|
|
74
|
-
href?: string;
|
|
75
|
-
key?: React.Key;
|
|
76
|
-
} & React.RefAttributes<HTMLDivElement>>;
|
|
77
|
-
declare const DropdownMenuCheckboxItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuCheckboxItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
78
|
-
key?: React.Key;
|
|
79
|
-
} & React.RefAttributes<HTMLDivElement>>;
|
|
80
|
-
declare const DropdownMenuRadioItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuRadioItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
81
|
-
key?: React.Key;
|
|
82
|
-
} & React.RefAttributes<HTMLDivElement>>;
|
|
83
|
-
declare const DropdownMenuLabel: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
|
|
84
|
-
inset?: boolean;
|
|
85
|
-
} & React.RefAttributes<HTMLDivElement>>;
|
|
86
|
-
declare const DropdownMenuSeparator: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
87
|
-
declare const DropdownMenuShortcut: {
|
|
88
|
-
({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>): react_jsx_runtime.JSX.Element;
|
|
89
|
-
displayName: string;
|
|
90
|
-
};
|
|
91
|
-
|
|
92
|
-
declare const Pagination: {
|
|
93
|
-
({ className, ...props }: React.ComponentProps<"nav">): react_jsx_runtime.JSX.Element;
|
|
94
|
-
displayName: string;
|
|
95
|
-
};
|
|
96
|
-
declare const PaginationContent: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLUListElement>, HTMLUListElement>, "ref"> & React.RefAttributes<HTMLUListElement>>;
|
|
97
|
-
declare const PaginationItem: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLLIElement> & React.LiHTMLAttributes<HTMLLIElement> & {
|
|
98
|
-
key?: React.Key;
|
|
99
|
-
}, "ref"> & React.RefAttributes<HTMLLIElement>>;
|
|
100
|
-
type PaginationLinkProps = {
|
|
101
|
-
isActive?: boolean;
|
|
102
|
-
href?: string;
|
|
103
|
-
} & Pick<ButtonProps, "size"> & React.ComponentProps<"a">;
|
|
104
|
-
declare const PaginationLink: {
|
|
105
|
-
({ className, isActive, size, href, children, ...props }: PaginationLinkProps): react_jsx_runtime.JSX.Element;
|
|
106
|
-
displayName: string;
|
|
107
|
-
};
|
|
108
|
-
declare const PaginationPrevious: {
|
|
109
|
-
({ className, ...props }: React.ComponentProps<typeof PaginationLink>): react_jsx_runtime.JSX.Element;
|
|
110
|
-
displayName: string;
|
|
111
|
-
};
|
|
112
|
-
declare const PaginationNext: {
|
|
113
|
-
({ className, ...props }: React.ComponentProps<typeof PaginationLink>): react_jsx_runtime.JSX.Element;
|
|
114
|
-
displayName: string;
|
|
115
|
-
};
|
|
116
|
-
declare const PaginationEllipsis: {
|
|
117
|
-
({ className, ...props }: React.ComponentProps<"span">): react_jsx_runtime.JSX.Element;
|
|
118
|
-
displayName: string;
|
|
119
|
-
};
|
|
120
|
-
|
|
121
|
-
interface SSRPaginationProps {
|
|
122
|
-
currentPage: number;
|
|
123
|
-
totalPages: number;
|
|
124
|
-
totalItems: number;
|
|
125
|
-
itemsPerPage: number;
|
|
126
|
-
hasNextPage: boolean;
|
|
127
|
-
hasPreviousPage: boolean;
|
|
128
|
-
className?: string;
|
|
129
|
-
showInfo?: boolean;
|
|
130
|
-
maxVisiblePages?: number;
|
|
131
|
-
baseUrl?: string;
|
|
132
|
-
pathname?: string;
|
|
133
|
-
preserveQuery?: boolean;
|
|
134
|
-
}
|
|
135
|
-
declare const SSRPagination: React__default.FC<SSRPaginationProps>;
|
|
136
|
-
|
|
137
|
-
/**
|
|
138
|
-
* DRF Static Pagination Component
|
|
139
|
-
*
|
|
140
|
-
* Universal pagination component that works with Django REST Framework pagination format.
|
|
141
|
-
* Manages page state internally and provides callbacks for page changes.
|
|
142
|
-
*
|
|
143
|
-
* DRF Pagination Response Format:
|
|
144
|
-
* {
|
|
145
|
-
* "count": 150, // Total number of items
|
|
146
|
-
* "page": 1, // Current page number
|
|
147
|
-
* "pages": 15, // Total number of pages
|
|
148
|
-
* "page_size": 10, // Items per page
|
|
149
|
-
* "has_next": true, // Whether there's a next page
|
|
150
|
-
* "has_previous": false, // Whether there's a previous page
|
|
151
|
-
* "next_page": 2, // Next page number (or null)
|
|
152
|
-
* "previous_page": null, // Previous page number (or null)
|
|
153
|
-
* "results": [...] // Array of items
|
|
154
|
-
* }
|
|
155
|
-
*
|
|
156
|
-
* Usage with SWR:
|
|
157
|
-
* ```tsx
|
|
158
|
-
* import { StaticPagination, useDRFPagination } from '@djangocfg/ui-nextjs';
|
|
159
|
-
*
|
|
160
|
-
* function MyComponent() {
|
|
161
|
-
* const pagination = useDRFPagination();
|
|
162
|
-
* const { data, isLoading } = useMyAPI(pagination.params);
|
|
163
|
-
*
|
|
164
|
-
* return (
|
|
165
|
-
* <div>
|
|
166
|
-
* {data?.results?.map(item => <Item key={item.id} {...item} />)}
|
|
167
|
-
* <StaticPagination data={data} onPageChange={pagination.setPage} />
|
|
168
|
-
* </div>
|
|
169
|
-
* );
|
|
170
|
-
* }
|
|
171
|
-
* ```
|
|
172
|
-
*/
|
|
173
|
-
|
|
174
|
-
/**
|
|
175
|
-
* DRF Pagination Response type
|
|
176
|
-
*/
|
|
177
|
-
interface DRFPaginatedResponse<T = any> {
|
|
178
|
-
count: number;
|
|
179
|
-
page: number;
|
|
180
|
-
pages: number;
|
|
181
|
-
page_size: number;
|
|
182
|
-
has_next: boolean;
|
|
183
|
-
has_previous: boolean;
|
|
184
|
-
next_page?: number | null;
|
|
185
|
-
previous_page?: number | null;
|
|
186
|
-
results: T[];
|
|
187
|
-
}
|
|
188
|
-
interface StaticPaginationProps {
|
|
189
|
-
/** The DRF paginated response data */
|
|
190
|
-
data?: DRFPaginatedResponse | null;
|
|
191
|
-
/** Callback when page changes */
|
|
192
|
-
onPageChange: (page: number) => void;
|
|
193
|
-
/** Additional CSS class */
|
|
194
|
-
className?: string;
|
|
195
|
-
/** Show pagination info (default: true) */
|
|
196
|
-
showInfo?: boolean;
|
|
197
|
-
/** Maximum visible page numbers (default: 7) */
|
|
198
|
-
maxVisiblePages?: number;
|
|
199
|
-
}
|
|
200
|
-
declare const StaticPagination: React__default.FC<StaticPaginationProps>;
|
|
201
|
-
/**
|
|
202
|
-
* Hook to manage DRF pagination state
|
|
203
|
-
*
|
|
204
|
-
* Manages page and page_size state and provides methods to change them.
|
|
205
|
-
* Works seamlessly with SWR hooks that accept params.
|
|
206
|
-
*
|
|
207
|
-
* Usage:
|
|
208
|
-
* ```tsx
|
|
209
|
-
* import { useDRFPagination } from '@djangocfg/ui-nextjs';
|
|
210
|
-
* import { useMyPaginatedAPI } from './api/hooks';
|
|
211
|
-
*
|
|
212
|
-
* function MyComponent() {
|
|
213
|
-
* const pagination = useDRFPagination();
|
|
214
|
-
* const { data, isLoading } = useMyPaginatedAPI(pagination.params);
|
|
215
|
-
*
|
|
216
|
-
* return (
|
|
217
|
-
* <div>
|
|
218
|
-
* {data?.results?.map(item => <Item key={item.id} {...item} />)}
|
|
219
|
-
* <StaticPagination data={data} onPageChange={pagination.setPage} />
|
|
220
|
-
* </div>
|
|
221
|
-
* );
|
|
222
|
-
* }
|
|
223
|
-
* ```
|
|
224
|
-
*/
|
|
225
|
-
declare function useDRFPagination(initialPage?: number, initialPageSize?: number): {
|
|
226
|
-
page: number;
|
|
227
|
-
pageSize: number;
|
|
228
|
-
setPage: React__default.Dispatch<React__default.SetStateAction<number>>;
|
|
229
|
-
setPageSize: (newPageSize: number) => void;
|
|
230
|
-
params: {
|
|
231
|
-
page: number;
|
|
232
|
-
page_size: number;
|
|
233
|
-
};
|
|
234
|
-
reset: () => void;
|
|
235
|
-
};
|
|
236
|
-
/**
|
|
237
|
-
* Hook to extract pagination info from DRF response
|
|
238
|
-
*
|
|
239
|
-
* Useful when you need pagination metadata in your component logic.
|
|
240
|
-
*
|
|
241
|
-
* Usage:
|
|
242
|
-
* ```tsx
|
|
243
|
-
* const paginationInfo = useDRFPaginationInfo(data);
|
|
244
|
-
* if (paginationInfo) {
|
|
245
|
-
* console.log(`Page ${paginationInfo.currentPage} of ${paginationInfo.totalPages}`);
|
|
246
|
-
* }
|
|
247
|
-
* ```
|
|
248
|
-
*/
|
|
249
|
-
declare function useDRFPaginationInfo(data?: DRFPaginatedResponse | null): {
|
|
250
|
-
totalItems: number;
|
|
251
|
-
currentPage: number;
|
|
252
|
-
totalPages: number;
|
|
253
|
-
itemsPerPage: number;
|
|
254
|
-
hasNext: boolean;
|
|
255
|
-
hasPrevious: boolean;
|
|
256
|
-
nextPage: number;
|
|
257
|
-
previousPage: number;
|
|
258
|
-
results: any[];
|
|
259
|
-
resultsCount: number;
|
|
260
|
-
};
|
|
261
|
-
|
|
262
|
-
type SidebarContextProps = {
|
|
263
|
-
state: "expanded" | "collapsed";
|
|
264
|
-
open: boolean;
|
|
265
|
-
setOpen: (open: boolean) => void;
|
|
266
|
-
openMobile: boolean;
|
|
267
|
-
setOpenMobile: (open: boolean) => void;
|
|
268
|
-
isMobile: boolean;
|
|
269
|
-
toggleSidebar: () => void;
|
|
270
|
-
};
|
|
271
|
-
declare function useSidebar(): SidebarContextProps;
|
|
272
|
-
declare const SidebarProvider: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & {
|
|
273
|
-
defaultOpen?: boolean;
|
|
274
|
-
open?: boolean;
|
|
275
|
-
onOpenChange?: (open: boolean) => void;
|
|
276
|
-
}, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
277
|
-
declare const Sidebar: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & {
|
|
278
|
-
side?: "left" | "right";
|
|
279
|
-
variant?: "sidebar" | "floating" | "inset";
|
|
280
|
-
collapsible?: "offcanvas" | "icon" | "none";
|
|
281
|
-
}, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
282
|
-
declare const SidebarTrigger: React.ForwardRefExoticComponent<Omit<_djangocfg_ui_core_components.ButtonProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
283
|
-
declare const SidebarRail: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
284
|
-
declare const SidebarInset: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
285
|
-
declare const SidebarInput: React.ForwardRefExoticComponent<Omit<Omit<React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
286
|
-
declare const SidebarHeader: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
287
|
-
declare const SidebarFooter: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
288
|
-
declare const SidebarSeparator: React.ForwardRefExoticComponent<React.ComponentProps<typeof Separator> & React.RefAttributes<React.ElementRef<typeof Separator>>>;
|
|
289
|
-
declare const SidebarContent: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
290
|
-
declare const SidebarGroup: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
291
|
-
declare const SidebarGroupLabel: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & {
|
|
292
|
-
asChild?: boolean;
|
|
293
|
-
}, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
294
|
-
declare const SidebarGroupAction: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLButtonElement> & React.ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
295
|
-
asChild?: boolean;
|
|
296
|
-
}, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
297
|
-
declare const SidebarGroupContent: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
298
|
-
declare const SidebarMenu: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLUListElement>, HTMLUListElement>, "ref"> & React.RefAttributes<HTMLUListElement>>;
|
|
299
|
-
declare const SidebarMenuItem: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
|
|
300
|
-
declare const SidebarMenuButton: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLButtonElement> & React.ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
301
|
-
asChild?: boolean;
|
|
302
|
-
isActive?: boolean;
|
|
303
|
-
tooltip?: string | React.ComponentProps<typeof TooltipContent>;
|
|
304
|
-
href?: string;
|
|
305
|
-
} & VariantProps<(props?: {
|
|
306
|
-
variant?: "default" | "outline";
|
|
307
|
-
size?: "default" | "sm" | "lg";
|
|
308
|
-
} & class_variance_authority_types.ClassProp) => string>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
309
|
-
declare const SidebarMenuAction: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLButtonElement> & React.ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
310
|
-
asChild?: boolean;
|
|
311
|
-
showOnHover?: boolean;
|
|
312
|
-
}, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
313
|
-
declare const SidebarMenuBadge: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
314
|
-
declare const SidebarMenuSkeleton: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement> & {
|
|
315
|
-
showIcon?: boolean;
|
|
316
|
-
}, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
317
|
-
declare const SidebarMenuSub: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLUListElement>, HTMLUListElement>, "ref"> & React.RefAttributes<HTMLUListElement>>;
|
|
318
|
-
declare const SidebarMenuSubItem: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
|
|
319
|
-
declare const SidebarMenuSubButton: React.ForwardRefExoticComponent<Omit<React.ClassAttributes<HTMLAnchorElement> & React.AnchorHTMLAttributes<HTMLAnchorElement> & {
|
|
320
|
-
asChild?: boolean;
|
|
321
|
-
size?: "sm" | "md";
|
|
322
|
-
isActive?: boolean;
|
|
323
|
-
href?: string;
|
|
324
|
-
}, "ref"> & React.RefAttributes<HTMLAnchorElement>>;
|
|
325
|
-
|
|
326
|
-
type ResolvedTheme = 'light' | 'dark';
|
|
327
|
-
/**
|
|
328
|
-
* Hook to detect the current resolved theme (light or dark)
|
|
329
|
-
*
|
|
330
|
-
* Standalone hook - doesn't require ThemeProvider.
|
|
331
|
-
* Detects theme from:
|
|
332
|
-
* 1. 'dark' class on html element
|
|
333
|
-
* 2. System preference (prefers-color-scheme)
|
|
334
|
-
*
|
|
335
|
-
* For full theme control (setTheme, toggleTheme), use useThemeContext instead.
|
|
336
|
-
*
|
|
337
|
-
* @example
|
|
338
|
-
* ```tsx
|
|
339
|
-
* const theme = useResolvedTheme(); // 'light' | 'dark'
|
|
340
|
-
* ```
|
|
341
|
-
*/
|
|
342
|
-
declare const useResolvedTheme: () => ResolvedTheme;
|
|
343
|
-
|
|
344
|
-
/**
|
|
345
|
-
* useQueryParams Hook
|
|
346
|
-
*
|
|
347
|
-
* Safe hook to access URL query parameters without requiring Suspense boundary.
|
|
348
|
-
* Works on client-side only, returns empty URLSearchParams during SSR/prerendering.
|
|
349
|
-
*
|
|
350
|
-
* @example
|
|
351
|
-
* ```tsx
|
|
352
|
-
* const params = useQueryParams();
|
|
353
|
-
* const flow = params.get('flow');
|
|
354
|
-
* const hasFlow = params.has('flow');
|
|
355
|
-
* const allTags = params.getAll('tags');
|
|
356
|
-
* ```
|
|
357
|
-
*/
|
|
358
|
-
/**
|
|
359
|
-
* Hook to safely access URL query parameters without useSearchParams()
|
|
360
|
-
*
|
|
361
|
-
* This hook reads query parameters directly from window.location.search,
|
|
362
|
-
* avoiding the need for Suspense boundaries that useSearchParams() requires.
|
|
363
|
-
*
|
|
364
|
-
* Automatically updates when URL changes (navigation, back/forward, etc.)
|
|
365
|
-
* Uses pathname from Next.js to detect route changes and polls for query param changes.
|
|
366
|
-
*
|
|
367
|
-
* Returns a URLSearchParams object with get(), getAll(), has(), etc.
|
|
368
|
-
*
|
|
369
|
-
* @returns URLSearchParams object (empty during SSR)
|
|
370
|
-
*/
|
|
371
|
-
declare function useQueryParams(): URLSearchParams;
|
|
372
|
-
|
|
373
|
-
/**
|
|
374
|
-
* Universal Router Hook with BasePath Support
|
|
375
|
-
*
|
|
376
|
-
* Wrapper around Next.js useRouter that automatically handles basePath
|
|
377
|
-
* for static builds served via iframe or subdirectory
|
|
378
|
-
*
|
|
379
|
-
* IMPORTANT: In Next.js 15 App Router, router.push() does NOT automatically
|
|
380
|
-
* handle basePath (unlike Pages Router). This is a breaking change in App Router.
|
|
381
|
-
*
|
|
382
|
-
* This hook ensures basePath is always included when navigating, especially
|
|
383
|
-
* important for static exports served via iframe where basePath is critical.
|
|
384
|
-
*
|
|
385
|
-
* @see https://nextjs.org/docs/app/building-your-application/upgrading/app-router-migration
|
|
386
|
-
*/
|
|
387
|
-
/**
|
|
388
|
-
* Router with basePath support
|
|
389
|
-
*
|
|
390
|
-
* Automatically adds basePath to all navigation methods when basePath is configured.
|
|
391
|
-
* In Next.js 15 App Router, router.push() doesn't handle basePath automatically,
|
|
392
|
-
* so this hook uses window.location to ensure basePath is always included.
|
|
393
|
-
*
|
|
394
|
-
* @example
|
|
395
|
-
* ```tsx
|
|
396
|
-
* const router = useCfgRouter();
|
|
397
|
-
*
|
|
398
|
-
* // With basePath='/cfg/admin':
|
|
399
|
-
* router.push('/dashboard'); // Client-side navigation to '/cfg/admin/dashboard'
|
|
400
|
-
* router.replace('/auth'); // Client-side replace with '/cfg/admin/auth'
|
|
401
|
-
* router.hardPush('/dashboard'); // Full page reload to '/cfg/admin/dashboard'
|
|
402
|
-
* router.hardReplace('/auth'); // Full page replace with '/cfg/admin/auth'
|
|
403
|
-
* ```
|
|
404
|
-
*/
|
|
405
|
-
declare function useCfgRouter(): {
|
|
406
|
-
push: (href: string, options?: {
|
|
407
|
-
scroll?: boolean;
|
|
408
|
-
}) => void;
|
|
409
|
-
replace: (href: string, options?: {
|
|
410
|
-
scroll?: boolean;
|
|
411
|
-
}) => void;
|
|
412
|
-
hardPush: (href: string) => void;
|
|
413
|
-
hardReplace: (href: string) => void;
|
|
414
|
-
prefetch: (href: string) => void;
|
|
415
|
-
back: () => void;
|
|
416
|
-
forward: () => void;
|
|
417
|
-
refresh: () => void;
|
|
418
|
-
};
|
|
419
|
-
|
|
420
|
-
/**
|
|
421
|
-
* Options for the useHotkey hook
|
|
422
|
-
*/
|
|
423
|
-
interface UseHotkeyOptions extends Omit<Options, 'enabled'> {
|
|
424
|
-
/** Whether the hotkey is enabled (default: true) */
|
|
425
|
-
enabled?: boolean;
|
|
426
|
-
/** Scope for the hotkey - useful for context-specific shortcuts */
|
|
427
|
-
scope?: string;
|
|
428
|
-
/** Only trigger when focus is within a specific element */
|
|
429
|
-
scopes?: string[];
|
|
430
|
-
/** Prevent default browser behavior */
|
|
431
|
-
preventDefault?: boolean;
|
|
432
|
-
/** Enable in input fields and textareas */
|
|
433
|
-
enableOnFormTags?: boolean | readonly ('input' | 'textarea' | 'select')[];
|
|
434
|
-
/** Enable when contentEditable element is focused */
|
|
435
|
-
enableOnContentEditable?: boolean;
|
|
436
|
-
/** Split key for multiple hotkey combinations (default: ',') */
|
|
437
|
-
splitKey?: string;
|
|
438
|
-
/** Key up/down events */
|
|
439
|
-
keyup?: boolean;
|
|
440
|
-
keydown?: boolean;
|
|
441
|
-
/** Description for the hotkey (useful for help dialogs) */
|
|
442
|
-
description?: string;
|
|
443
|
-
}
|
|
444
|
-
/**
|
|
445
|
-
* Simple wrapper hook for react-hotkeys-hook
|
|
446
|
-
*
|
|
447
|
-
* @example
|
|
448
|
-
* // Single key
|
|
449
|
-
* useHotkey('escape', () => closeModal());
|
|
450
|
-
*
|
|
451
|
-
* @example
|
|
452
|
-
* // Key combination
|
|
453
|
-
* useHotkey('ctrl+s', (e) => {
|
|
454
|
-
* e.preventDefault();
|
|
455
|
-
* saveDocument();
|
|
456
|
-
* });
|
|
457
|
-
*
|
|
458
|
-
* @example
|
|
459
|
-
* // Multiple keys (any of them will trigger)
|
|
460
|
-
* useHotkey(['ArrowLeft', '['], () => goToPrevious());
|
|
461
|
-
* useHotkey(['ArrowRight', ']'], () => goToNext());
|
|
462
|
-
*
|
|
463
|
-
* @example
|
|
464
|
-
* // With options
|
|
465
|
-
* useHotkey('/', () => focusSearch(), {
|
|
466
|
-
* preventDefault: true,
|
|
467
|
-
* enableOnFormTags: false,
|
|
468
|
-
* description: 'Focus search input'
|
|
469
|
-
* });
|
|
470
|
-
*
|
|
471
|
-
* @example
|
|
472
|
-
* // Scoped hotkeys
|
|
473
|
-
* useHotkey('delete', () => deleteItem(), { scopes: ['list-view'] });
|
|
474
|
-
*
|
|
475
|
-
* @param keys - Hotkey or array of hotkeys (e.g., 'ctrl+s', 'ArrowLeft', ['[', 'ArrowLeft'])
|
|
476
|
-
* @param callback - Function to call when hotkey is pressed
|
|
477
|
-
* @param options - Configuration options
|
|
478
|
-
* @returns Ref to attach to element for scoped hotkeys
|
|
479
|
-
*/
|
|
480
|
-
declare function useHotkey<T extends HTMLElement = HTMLElement>(keys: Keys, callback: HotkeyCallback, options?: UseHotkeyOptions): RefObject<T | null>;
|
|
481
|
-
|
|
482
|
-
/**
|
|
483
|
-
* Device detection hook wrapper for react-device-detect
|
|
484
|
-
*
|
|
485
|
-
* Provides a convenient interface to access device information including:
|
|
486
|
-
* - Device type (mobile, tablet, desktop, etc.)
|
|
487
|
-
* - Browser information (name, version, etc.)
|
|
488
|
-
* - OS information (name, version, etc.)
|
|
489
|
-
* - Orientation (portrait/landscape)
|
|
490
|
-
*
|
|
491
|
-
* @param userAgent - Optional user agent string (useful for SSR)
|
|
492
|
-
* @returns Device detection object with all available information
|
|
493
|
-
*
|
|
494
|
-
* @example
|
|
495
|
-
* ```tsx
|
|
496
|
-
* const device = useDeviceDetect();
|
|
497
|
-
*
|
|
498
|
-
* if (device.isMobile) {
|
|
499
|
-
* return <MobileView />;
|
|
500
|
-
* }
|
|
501
|
-
*
|
|
502
|
-
* return <DesktopView />;
|
|
503
|
-
* ```
|
|
504
|
-
*/
|
|
505
|
-
declare function useDeviceDetect(userAgent?: string): {
|
|
506
|
-
isMobile: boolean;
|
|
507
|
-
isTablet: boolean;
|
|
508
|
-
isDesktop: boolean;
|
|
509
|
-
isBrowser: boolean;
|
|
510
|
-
isMobileOnly: boolean;
|
|
511
|
-
isSmartTV: boolean;
|
|
512
|
-
isConsole: boolean;
|
|
513
|
-
isWearable: boolean;
|
|
514
|
-
isEmbedded: boolean;
|
|
515
|
-
isAndroid: boolean;
|
|
516
|
-
isIOS: boolean;
|
|
517
|
-
isWindows: boolean;
|
|
518
|
-
isMacOs: boolean;
|
|
519
|
-
isWinPhone: boolean;
|
|
520
|
-
isChrome: boolean;
|
|
521
|
-
isFirefox: boolean;
|
|
522
|
-
isSafari: boolean;
|
|
523
|
-
isOpera: boolean;
|
|
524
|
-
isIE: boolean;
|
|
525
|
-
isEdge: boolean;
|
|
526
|
-
isEdgeChromium: boolean;
|
|
527
|
-
isLegacyEdge: boolean;
|
|
528
|
-
isChromium: boolean;
|
|
529
|
-
isMobileSafari: boolean;
|
|
530
|
-
isYandex: boolean;
|
|
531
|
-
isMIUI: boolean;
|
|
532
|
-
isSamsungBrowser: boolean;
|
|
533
|
-
isElectron: boolean;
|
|
534
|
-
isIOS13: boolean;
|
|
535
|
-
isIPad13: boolean;
|
|
536
|
-
isIPhone13: boolean;
|
|
537
|
-
isIPod13: boolean;
|
|
538
|
-
deviceType: string;
|
|
539
|
-
osName: string;
|
|
540
|
-
osVersion: string;
|
|
541
|
-
browserName: string;
|
|
542
|
-
browserVersion: string;
|
|
543
|
-
fullBrowserVersion: string;
|
|
544
|
-
mobileVendor: string;
|
|
545
|
-
mobileModel: string;
|
|
546
|
-
engineName: string;
|
|
547
|
-
engineVersion: string;
|
|
548
|
-
getUA: string;
|
|
549
|
-
isPortrait: boolean;
|
|
550
|
-
isLandscape: boolean;
|
|
551
|
-
orientation: "portrait" | "landscape";
|
|
552
|
-
selectors: {
|
|
553
|
-
isMobile: boolean;
|
|
554
|
-
isTablet: boolean;
|
|
555
|
-
isDesktop: boolean;
|
|
556
|
-
isBrowser: boolean;
|
|
557
|
-
isMobileOnly: boolean;
|
|
558
|
-
isSmartTV: boolean;
|
|
559
|
-
isConsole: boolean;
|
|
560
|
-
isWearable: boolean;
|
|
561
|
-
isEmbedded: boolean;
|
|
562
|
-
isAndroid: boolean;
|
|
563
|
-
isIOS: boolean;
|
|
564
|
-
isWindows: boolean;
|
|
565
|
-
isMacOs: boolean;
|
|
566
|
-
isWinPhone: boolean;
|
|
567
|
-
isChrome: boolean;
|
|
568
|
-
isFirefox: boolean;
|
|
569
|
-
isSafari: boolean;
|
|
570
|
-
isOpera: boolean;
|
|
571
|
-
isIE: boolean;
|
|
572
|
-
isEdge: boolean;
|
|
573
|
-
isEdgeChromium: boolean;
|
|
574
|
-
isLegacyEdge: boolean;
|
|
575
|
-
isChromium: boolean;
|
|
576
|
-
isMobileSafari: boolean;
|
|
577
|
-
isYandex: boolean;
|
|
578
|
-
isMIUI: boolean;
|
|
579
|
-
isSamsungBrowser: boolean;
|
|
580
|
-
isElectron: boolean;
|
|
581
|
-
osVersion: string;
|
|
582
|
-
osName: string;
|
|
583
|
-
fullBrowserVersion: string;
|
|
584
|
-
browserVersion: string;
|
|
585
|
-
browserName: string;
|
|
586
|
-
mobileVendor: string;
|
|
587
|
-
mobileModel: string;
|
|
588
|
-
engineName: string;
|
|
589
|
-
engineVersion: string;
|
|
590
|
-
getUA: string;
|
|
591
|
-
deviceType: string;
|
|
592
|
-
isIOS13: boolean;
|
|
593
|
-
isIPad13: boolean;
|
|
594
|
-
isIPhone13: boolean;
|
|
595
|
-
isIPod13: boolean;
|
|
596
|
-
};
|
|
597
|
-
deviceData: {
|
|
598
|
-
deviceType: string;
|
|
599
|
-
osName: string;
|
|
600
|
-
osVersion: string;
|
|
601
|
-
browserName: string;
|
|
602
|
-
browserVersion: string;
|
|
603
|
-
fullBrowserVersion: string;
|
|
604
|
-
mobileVendor: string;
|
|
605
|
-
mobileModel: string;
|
|
606
|
-
engineName: string;
|
|
607
|
-
engineVersion: string;
|
|
608
|
-
getUA: string;
|
|
609
|
-
};
|
|
610
|
-
};
|
|
611
|
-
type DeviceDetectResult = ReturnType<typeof useDeviceDetect>;
|
|
612
|
-
|
|
613
|
-
/**
|
|
614
|
-
* Advanced browser detection hook
|
|
615
|
-
*
|
|
616
|
-
* Detects modern browsers including Chromium-based browsers that may
|
|
617
|
-
* incorrectly report as Safari (Arc, Brave, Vivaldi, Comet, etc.)
|
|
618
|
-
*/
|
|
619
|
-
interface BrowserInfo {
|
|
620
|
-
isChrome: boolean;
|
|
621
|
-
isChromium: boolean;
|
|
622
|
-
isSafari: boolean;
|
|
623
|
-
isFirefox: boolean;
|
|
624
|
-
isEdge: boolean;
|
|
625
|
-
isOpera: boolean;
|
|
626
|
-
isBrave: boolean;
|
|
627
|
-
isArc: boolean;
|
|
628
|
-
isVivaldi: boolean;
|
|
629
|
-
isYandex: boolean;
|
|
630
|
-
isSamsungBrowser: boolean;
|
|
631
|
-
isUCBrowser: boolean;
|
|
632
|
-
isComet: boolean;
|
|
633
|
-
isOperaMini: boolean;
|
|
634
|
-
isIE: boolean;
|
|
635
|
-
isFacebookInApp: boolean;
|
|
636
|
-
isInstagramInApp: boolean;
|
|
637
|
-
isTikTokInApp: boolean;
|
|
638
|
-
isSnapchatInApp: boolean;
|
|
639
|
-
isWeChatInApp: boolean;
|
|
640
|
-
isThreadsInApp: boolean;
|
|
641
|
-
isLinkedInInApp: boolean;
|
|
642
|
-
isTwitterInApp: boolean;
|
|
643
|
-
isInAppBrowser: boolean;
|
|
644
|
-
isWebView: boolean;
|
|
645
|
-
browserName: string;
|
|
646
|
-
isWebKit: boolean;
|
|
647
|
-
isBlink: boolean;
|
|
648
|
-
isGecko: boolean;
|
|
649
|
-
/**
|
|
650
|
-
* Whether the browser supports Web Push Notifications.
|
|
651
|
-
* Returns false for browsers known to NOT support push:
|
|
652
|
-
* - Opera Mini (no service worker support)
|
|
653
|
-
* - Internet Explorer (deprecated, no Push API)
|
|
654
|
-
* - UC Browser (unreliable push support)
|
|
655
|
-
* - In-App browsers (Facebook, Instagram, TikTok, Snapchat, etc.)
|
|
656
|
-
* - Generic WebViews (except Twitter/LinkedIn on Android which use Chrome WebView)
|
|
657
|
-
*
|
|
658
|
-
* Note: Comet (Perplexity) is Chromium-based and DOES support push notifications.
|
|
659
|
-
* Note: This is a browser-level check. For full push support,
|
|
660
|
-
* also check 'serviceWorker' in navigator && 'PushManager' in window
|
|
661
|
-
*/
|
|
662
|
-
supportsPushNotifications: boolean;
|
|
663
|
-
isIOSBrowser: boolean;
|
|
664
|
-
userAgent: string;
|
|
665
|
-
}
|
|
666
|
-
/**
|
|
667
|
-
* Detect browser with improved accuracy for Chromium-based browsers
|
|
668
|
-
*
|
|
669
|
-
* @example
|
|
670
|
-
* ```tsx
|
|
671
|
-
* const browser = useBrowserDetect();
|
|
672
|
-
*
|
|
673
|
-
* if (browser.isSafari && !browser.isChromium) {
|
|
674
|
-
* // Real Safari
|
|
675
|
-
* }
|
|
676
|
-
*
|
|
677
|
-
* if (browser.isChromium) {
|
|
678
|
-
* // Any Chromium-based browser (Chrome, Edge, Brave, Arc, etc.)
|
|
679
|
-
* }
|
|
680
|
-
* ```
|
|
681
|
-
*/
|
|
682
|
-
declare function useBrowserDetect(): BrowserInfo;
|
|
683
|
-
|
|
684
|
-
type ArticleType = 'security' | 'release' | 'announcement' | 'feature';
|
|
685
|
-
interface ArticleCardProps {
|
|
686
|
-
title: string;
|
|
687
|
-
description?: string;
|
|
688
|
-
date: string;
|
|
689
|
-
type: ArticleType;
|
|
690
|
-
href: string;
|
|
691
|
-
author?: string;
|
|
692
|
-
tags?: string[];
|
|
693
|
-
featured?: boolean;
|
|
694
|
-
className?: string;
|
|
695
|
-
}
|
|
696
|
-
declare const ArticleCard: React__default.FC<ArticleCardProps>;
|
|
697
|
-
|
|
698
|
-
interface Article {
|
|
699
|
-
title: string;
|
|
700
|
-
description?: string;
|
|
701
|
-
date: string;
|
|
702
|
-
type: ArticleType;
|
|
703
|
-
href: string;
|
|
704
|
-
author?: string;
|
|
705
|
-
tags?: string[];
|
|
706
|
-
featured?: boolean;
|
|
707
|
-
}
|
|
708
|
-
interface ArticleListProps {
|
|
709
|
-
articles: Article[];
|
|
710
|
-
title?: string;
|
|
711
|
-
description?: string;
|
|
712
|
-
showFeatured?: boolean;
|
|
713
|
-
columns?: 1 | 2 | 3;
|
|
714
|
-
className?: string;
|
|
715
|
-
}
|
|
716
|
-
declare const ArticleList: React__default.FC<ArticleListProps>;
|
|
717
|
-
|
|
718
|
-
interface CTAButton {
|
|
719
|
-
label: string;
|
|
720
|
-
href?: string;
|
|
721
|
-
onClick?: () => void;
|
|
722
|
-
variant?: 'default' | 'destructive' | 'outline' | 'secondary' | 'ghost' | 'link';
|
|
723
|
-
size?: 'default' | 'sm' | 'lg' | 'icon';
|
|
724
|
-
}
|
|
725
|
-
interface CTASectionProps {
|
|
726
|
-
title: string;
|
|
727
|
-
subtitle?: string;
|
|
728
|
-
primaryCTA?: CTAButton;
|
|
729
|
-
secondaryCTA?: CTAButton;
|
|
730
|
-
background?: 'default' | 'muted' | 'primary' | 'gradient';
|
|
731
|
-
className?: string;
|
|
732
|
-
children?: React__default.ReactNode;
|
|
733
|
-
}
|
|
734
|
-
declare const CTASection: React__default.FC<CTASectionProps>;
|
|
735
|
-
|
|
736
|
-
interface Feature {
|
|
737
|
-
icon?: React__default.ReactNode;
|
|
738
|
-
title: string;
|
|
739
|
-
description: string;
|
|
740
|
-
gradient?: string;
|
|
741
|
-
}
|
|
742
|
-
interface FeatureSectionProps {
|
|
743
|
-
title?: string;
|
|
744
|
-
subtitle?: string;
|
|
745
|
-
features: Feature[];
|
|
746
|
-
columns?: 1 | 2 | 3 | 4 | 6;
|
|
747
|
-
className?: string;
|
|
748
|
-
background?: 'dark' | 'card' | 'gradient' | 'none';
|
|
749
|
-
/** Compact variant: smaller icons, no cards, minimal spacing */
|
|
750
|
-
variant?: 'default' | 'compact';
|
|
751
|
-
}
|
|
752
|
-
declare const FeatureSection: React__default.FC<FeatureSectionProps>;
|
|
753
|
-
|
|
754
|
-
interface HeroProps {
|
|
755
|
-
title: string;
|
|
756
|
-
subtitle?: string;
|
|
757
|
-
description?: string;
|
|
758
|
-
primaryAction?: {
|
|
759
|
-
label: string;
|
|
760
|
-
href: string;
|
|
761
|
-
variant?: 'default' | 'destructive' | 'outline' | 'secondary' | 'ghost' | 'link';
|
|
762
|
-
};
|
|
763
|
-
secondaryAction?: {
|
|
764
|
-
label: string;
|
|
765
|
-
href: string;
|
|
766
|
-
variant?: 'default' | 'destructive' | 'outline' | 'secondary' | 'ghost' | 'link';
|
|
767
|
-
};
|
|
768
|
-
background?: 'gradient' | 'solid' | 'image' | 'dark';
|
|
769
|
-
className?: string;
|
|
770
|
-
children?: React__default.ReactNode;
|
|
771
|
-
}
|
|
772
|
-
declare const Hero: React__default.FC<HeroProps>;
|
|
773
|
-
|
|
774
|
-
interface NewsletterSectionProps {
|
|
775
|
-
title?: string;
|
|
776
|
-
description?: string;
|
|
777
|
-
placeholder?: string;
|
|
778
|
-
buttonText?: string;
|
|
779
|
-
disclaimer?: string;
|
|
780
|
-
background?: 'default' | 'muted' | 'primary' | 'gradient';
|
|
781
|
-
className?: string;
|
|
782
|
-
onSubmit?: (email: string) => void;
|
|
783
|
-
}
|
|
784
|
-
/**
|
|
785
|
-
* NewsletterSection - Email subscription block
|
|
786
|
-
* Fully responsive and theme-aware (light/dark mode)
|
|
787
|
-
* Follows Tailwind CSS v4 canons - no custom utilities
|
|
788
|
-
*/
|
|
789
|
-
declare const NewsletterSection: React__default.FC<NewsletterSectionProps>;
|
|
790
|
-
|
|
791
|
-
interface SplitHeroBadge {
|
|
792
|
-
icon?: ReactNode;
|
|
793
|
-
text: string;
|
|
794
|
-
}
|
|
795
|
-
interface SplitHeroAction {
|
|
796
|
-
label: string;
|
|
797
|
-
href?: string;
|
|
798
|
-
onClick?: () => void;
|
|
799
|
-
icon?: ReactNode;
|
|
800
|
-
variant?: 'default' | 'outline' | 'ghost' | 'secondary';
|
|
801
|
-
}
|
|
802
|
-
interface SplitHeroFeature {
|
|
803
|
-
icon?: ReactNode;
|
|
804
|
-
text: string;
|
|
805
|
-
}
|
|
806
|
-
/** Image media type */
|
|
807
|
-
interface SplitHeroMediaImage {
|
|
808
|
-
type: 'image';
|
|
809
|
-
src: string;
|
|
810
|
-
alt?: string;
|
|
811
|
-
}
|
|
812
|
-
/** Video media type - uses VideoPlayer */
|
|
813
|
-
interface SplitHeroMediaVideo {
|
|
814
|
-
type: 'video';
|
|
815
|
-
url: string;
|
|
816
|
-
title?: string;
|
|
817
|
-
poster?: string;
|
|
818
|
-
autoplay?: boolean;
|
|
819
|
-
muted?: boolean;
|
|
820
|
-
}
|
|
821
|
-
/** Custom component media type */
|
|
822
|
-
interface SplitHeroMediaCustom {
|
|
823
|
-
type: 'custom';
|
|
824
|
-
content: ReactNode;
|
|
825
|
-
}
|
|
826
|
-
type SplitHeroMedia$1 = SplitHeroMediaImage | SplitHeroMediaVideo | SplitHeroMediaCustom;
|
|
827
|
-
interface SplitHeroProps {
|
|
828
|
-
/** Badge above title */
|
|
829
|
-
badge?: SplitHeroBadge;
|
|
830
|
-
/** Main title */
|
|
831
|
-
title: string;
|
|
832
|
-
/** Gradient part of title (optional) */
|
|
833
|
-
titleGradient?: string;
|
|
834
|
-
/** Subtitle text */
|
|
835
|
-
subtitle?: string;
|
|
836
|
-
/** Feature list */
|
|
837
|
-
features?: SplitHeroFeature[];
|
|
838
|
-
/** Primary CTA button */
|
|
839
|
-
primaryAction?: SplitHeroAction;
|
|
840
|
-
/** Secondary CTA button */
|
|
841
|
-
secondaryAction?: SplitHeroAction;
|
|
842
|
-
/** Media content - image, video, or custom component */
|
|
843
|
-
media?: SplitHeroMedia$1;
|
|
844
|
-
/** Layout direction */
|
|
845
|
-
layout?: 'text-left' | 'text-right';
|
|
846
|
-
/** Mobile stack order */
|
|
847
|
-
mobileOrder?: 'media-first' | 'text-first';
|
|
848
|
-
/** Content vertical alignment */
|
|
849
|
-
align?: 'top' | 'center' | 'bottom';
|
|
850
|
-
/** Container max width */
|
|
851
|
-
maxWidth?: 'sm' | 'md' | 'lg' | 'xl' | 'full';
|
|
852
|
-
/** Background style */
|
|
853
|
-
background?: 'none' | 'muted' | 'gradient';
|
|
854
|
-
/** Custom className */
|
|
855
|
-
className?: string;
|
|
856
|
-
}
|
|
857
|
-
|
|
858
|
-
declare const SplitHero: React__default.FC<SplitHeroProps>;
|
|
859
|
-
|
|
860
|
-
interface SplitHeroContentProps {
|
|
861
|
-
badge?: SplitHeroBadge;
|
|
862
|
-
title: string;
|
|
863
|
-
titleGradient?: string;
|
|
864
|
-
subtitle?: string;
|
|
865
|
-
features?: SplitHeroFeature[];
|
|
866
|
-
primaryAction?: SplitHeroAction;
|
|
867
|
-
secondaryAction?: SplitHeroAction;
|
|
868
|
-
align?: 'top' | 'center' | 'bottom';
|
|
869
|
-
className?: string;
|
|
870
|
-
}
|
|
871
|
-
declare const SplitHeroContent: React__default.FC<SplitHeroContentProps>;
|
|
872
|
-
|
|
873
|
-
interface SplitHeroMediaProps {
|
|
874
|
-
media: SplitHeroMedia$1;
|
|
875
|
-
className?: string;
|
|
876
|
-
}
|
|
877
|
-
declare const SplitHeroMedia: React__default.FC<SplitHeroMediaProps>;
|
|
878
|
-
|
|
879
|
-
interface Stat {
|
|
880
|
-
number: string;
|
|
881
|
-
label: string;
|
|
882
|
-
description?: string;
|
|
883
|
-
icon?: React__default.ReactNode;
|
|
884
|
-
}
|
|
885
|
-
interface StatsSectionProps {
|
|
886
|
-
title: string;
|
|
887
|
-
subtitle?: string;
|
|
888
|
-
stats: Stat[];
|
|
889
|
-
columns?: 2 | 3 | 4;
|
|
890
|
-
className?: string;
|
|
891
|
-
background?: 'dark' | 'card' | 'gradient';
|
|
892
|
-
}
|
|
893
|
-
declare const StatsSection: React__default.FC<StatsSectionProps>;
|
|
894
|
-
|
|
895
|
-
type BackgroundVariant = 'aurora-borealis' | 'mesh-gradient' | 'floating-orbs' | 'geometric-flow' | 'liquid-gradient' | 'spotlight' | 'none' | 'gradient-mesh' | 'dot-matrix' | 'grid-lines' | 'aurora' | 'particles' | 'waves';
|
|
896
|
-
interface AnimatedBackgroundProps {
|
|
897
|
-
variant?: BackgroundVariant;
|
|
898
|
-
className?: string;
|
|
899
|
-
intensity?: 'subtle' | 'medium' | 'strong';
|
|
900
|
-
/** Color scheme - 'vibrant' uses multiple colors, 'monochrome' uses primary only */
|
|
901
|
-
colorScheme?: 'vibrant' | 'monochrome' | 'cool' | 'warm';
|
|
902
|
-
}
|
|
903
|
-
declare const AnimatedBackground: React__default.FC<AnimatedBackgroundProps>;
|
|
904
|
-
|
|
905
|
-
type MouseFollowerVariant = 'glow' | 'spotlight' | 'gradient-blob' | 'ring' | 'trail';
|
|
906
|
-
interface MouseFollowerProps {
|
|
907
|
-
/** Visual style of the follower */
|
|
908
|
-
variant?: MouseFollowerVariant;
|
|
909
|
-
/** Size of the effect in pixels */
|
|
910
|
-
size?: number;
|
|
911
|
-
/** Color - can be CSS color or 'primary' to use theme */
|
|
912
|
-
color?: string;
|
|
913
|
-
/** Smoothness of following (0.05 = very smooth, 0.3 = snappy) */
|
|
914
|
-
smoothness?: number;
|
|
915
|
-
/** Opacity of the effect (0-1) */
|
|
916
|
-
opacity?: number;
|
|
917
|
-
/** Blur amount for glow effects */
|
|
918
|
-
blur?: 'sm' | 'md' | 'lg' | 'xl' | '2xl' | '3xl';
|
|
919
|
-
/** Additional className for the container */
|
|
920
|
-
className?: string;
|
|
921
|
-
/** Whether to show on mobile (touch devices) */
|
|
922
|
-
showOnMobile?: boolean;
|
|
923
|
-
/** Disable the effect */
|
|
924
|
-
disabled?: boolean;
|
|
925
|
-
}
|
|
926
|
-
declare const MouseFollower: React__default.FC<MouseFollowerProps>;
|
|
927
|
-
|
|
928
|
-
interface HeroFeature {
|
|
929
|
-
icon: React__default.ReactNode;
|
|
930
|
-
text: string;
|
|
931
|
-
}
|
|
932
|
-
interface StatItem {
|
|
933
|
-
number: string;
|
|
934
|
-
label: string;
|
|
935
|
-
icon?: React__default.ReactNode;
|
|
936
|
-
}
|
|
937
|
-
interface SuperHeroProps {
|
|
938
|
-
badge?: {
|
|
939
|
-
icon?: React__default.ReactNode;
|
|
940
|
-
text: string;
|
|
941
|
-
};
|
|
942
|
-
title: string;
|
|
943
|
-
titleGradient?: string;
|
|
944
|
-
subtitle: string;
|
|
945
|
-
features?: HeroFeature[];
|
|
946
|
-
primaryAction?: {
|
|
947
|
-
label: string;
|
|
948
|
-
href?: string;
|
|
949
|
-
onClick?: () => void;
|
|
950
|
-
};
|
|
951
|
-
secondaryAction?: {
|
|
952
|
-
label: string;
|
|
953
|
-
href?: string;
|
|
954
|
-
onClick?: () => void;
|
|
955
|
-
icon?: React__default.ReactNode;
|
|
956
|
-
};
|
|
957
|
-
stats?: StatItem[];
|
|
958
|
-
floatingElements?: React__default.ReactNode;
|
|
959
|
-
backgroundVariant?: BackgroundVariant;
|
|
960
|
-
backgroundIntensity?: 'subtle' | 'medium' | 'strong';
|
|
961
|
-
showBackgroundSwitcher?: boolean;
|
|
962
|
-
/** Single command (for backwards compatibility) */
|
|
963
|
-
codeCommand?: string;
|
|
964
|
-
/** Array of commands to display with copy buttons */
|
|
965
|
-
codeCommands?: string[];
|
|
966
|
-
className?: string;
|
|
967
|
-
}
|
|
968
|
-
declare const SuperHero: React__default.FC<SuperHeroProps>;
|
|
969
|
-
|
|
970
|
-
interface Testimonial {
|
|
971
|
-
content: string;
|
|
972
|
-
author: {
|
|
973
|
-
name: string;
|
|
974
|
-
title?: string;
|
|
975
|
-
company?: string;
|
|
976
|
-
avatar?: string;
|
|
977
|
-
};
|
|
978
|
-
rating?: number;
|
|
979
|
-
}
|
|
980
|
-
interface TestimonialSectionProps {
|
|
981
|
-
title?: string;
|
|
982
|
-
subtitle?: string;
|
|
983
|
-
testimonials: Testimonial[];
|
|
984
|
-
columns?: 1 | 2 | 3;
|
|
985
|
-
className?: string;
|
|
986
|
-
background?: 'dark' | 'card' | 'gradient';
|
|
987
|
-
}
|
|
988
|
-
declare const TestimonialSection: React__default.FC<TestimonialSectionProps>;
|
|
989
|
-
|
|
990
|
-
type Theme = 'light' | 'dark' | 'system';
|
|
991
|
-
type ThemeProviderProps = ThemeProviderProps$1;
|
|
992
|
-
/**
|
|
993
|
-
* ThemeProvider wraps next-themes with sensible defaults
|
|
994
|
-
*/
|
|
995
|
-
declare function ThemeProvider({ children, attribute, defaultTheme, enableSystem, disableTransitionOnChange, ...props }: ThemeProviderProps): react_jsx_runtime.JSX.Element;
|
|
996
|
-
/**
|
|
997
|
-
* Hook to access theme context
|
|
998
|
-
* Returns theme, setTheme, resolvedTheme, systemTheme, and themes
|
|
999
|
-
*/
|
|
1000
|
-
declare function useThemeContext(): {
|
|
1001
|
-
theme: Theme | undefined;
|
|
1002
|
-
setTheme: React.Dispatch<React.SetStateAction<string>>;
|
|
1003
|
-
resolvedTheme: "light" | "dark" | undefined;
|
|
1004
|
-
systemTheme: "light" | "dark" | undefined;
|
|
1005
|
-
themes: string[];
|
|
1006
|
-
toggleTheme: () => void;
|
|
1007
|
-
};
|
|
1008
|
-
|
|
1009
|
-
/**
|
|
1010
|
-
* ThemeToggle - Theme switcher component
|
|
1011
|
-
*
|
|
1012
|
-
* Switches between light and dark themes.
|
|
1013
|
-
* Must be used within ThemeProvider.
|
|
1014
|
-
*
|
|
1015
|
-
* @example
|
|
1016
|
-
* ```tsx
|
|
1017
|
-
* import { ThemeToggle } from '@djangocfg/ui-nextjs';
|
|
1018
|
-
*
|
|
1019
|
-
* // Default
|
|
1020
|
-
* <ThemeToggle />
|
|
1021
|
-
*
|
|
1022
|
-
* // Compact (for mobile/tight spaces)
|
|
1023
|
-
* <ThemeToggle size="compact" />
|
|
1024
|
-
*
|
|
1025
|
-
* // Custom className
|
|
1026
|
-
* <ThemeToggle className="ml-auto" />
|
|
1027
|
-
* ```
|
|
1028
|
-
*/
|
|
1029
|
-
interface ThemeToggleProps {
|
|
1030
|
-
/** Custom className */
|
|
1031
|
-
className?: string;
|
|
1032
|
-
/** Size variant (auto-detects mobile if not specified) */
|
|
1033
|
-
size?: 'default' | 'compact' | 'auto';
|
|
1034
|
-
}
|
|
1035
|
-
declare function ThemeToggle({ className, size }: ThemeToggleProps): react_jsx_runtime.JSX.Element;
|
|
1036
|
-
|
|
1037
|
-
interface ForceThemeProps {
|
|
1038
|
-
theme: 'light' | 'dark';
|
|
1039
|
-
children: ReactNode;
|
|
1040
|
-
className?: string;
|
|
1041
|
-
}
|
|
1042
|
-
declare function ForceTheme({ theme, children, className }: ForceThemeProps): react_jsx_runtime.JSX.Element;
|
|
1043
|
-
|
|
1044
|
-
export { AnimatedBackground, type Article, ArticleCard, ArticleList, type ArticleType, type BackgroundVariant, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem$1 as BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbNavigation, type BreadcrumbItem as BreadcrumbNavigationItem, type BreadcrumbNavigationProps, BreadcrumbPage, BreadcrumbSeparator, type BrowserInfo, CTASection, type DRFPaginatedResponse, type DeviceDetectResult, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, FeatureSection, ForceTheme, Hero, MouseFollower, type MouseFollowerVariant, NewsletterSection, Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, type ResolvedTheme, SSRPagination, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, SplitHero, type SplitHeroAction, type SplitHeroBadge, SplitHeroContent, type SplitHeroFeature, SplitHeroMedia, type SplitHeroMediaCustom, type SplitHeroMediaImage, type SplitHeroMedia$1 as SplitHeroMediaType, type SplitHeroMediaVideo, type SplitHeroProps, StaticPagination, StatsSection, SuperHero, TestimonialSection, type Theme, ThemeProvider, type ThemeProviderProps, ThemeToggle, type UseHotkeyOptions, useBrowserDetect, useCfgRouter, useDRFPagination, useDRFPaginationInfo, useDeviceDetect, useHotkey, useQueryParams, useResolvedTheme, useSidebar, useThemeContext };
|