tcce-design-system-test 0.3.30 → 0.3.32
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/tcce-design-system-components.css +1 -1
- package/dist/tcce-design-system-components.d.ts +968 -195
- package/dist/tcce-design-system-components.js +9550 -6214
- package/dist/tcce-design-system-components.umd.cjs +810 -515
- package/package.json +26 -24
- package/dist/assets/brand/Logo_Total_Civil_Construction_Optimize/Entrega_Logo_Total_AW.webp:Zone.Identifier +0 -0
- package/dist/assets/brand/Logo_Total_Civil_Construction_Optimize/Entrega_Logo_Total_CB.webp:Zone.Identifier +0 -0
- package/dist/assets/brand/Logo_Total_Civil_Construction_Optimize/Entrega_Logo_Total_CBT.webp:Zone.Identifier +0 -0
- package/dist/assets/brand/Logo_Total_Civil_Construction_Optimize/Entrega_Logo_Total_CC.webp:Zone.Identifier +0 -0
- package/dist/assets/brand/Logo_Total_Civil_Construction_Optimize/Entrega_Logo_Total_M.webp:Zone.Identifier +0 -0
- package/dist/assets/brand/Logo_Total_Civil_Construction_Optimize/Entrega_Logo_Total_NT.webp:Zone.Identifier +0 -0
|
@@ -1,26 +1,48 @@
|
|
|
1
1
|
import { AnchorHTMLAttributes } from 'react';
|
|
2
2
|
import { ButtonHTMLAttributes } from 'react';
|
|
3
|
+
import { Cell } from '@tanstack/react-table';
|
|
4
|
+
import { ChangeEvent } from 'react';
|
|
5
|
+
import { ClipboardEvent as ClipboardEvent_2 } from 'react';
|
|
6
|
+
import { Column } from '@tanstack/react-table';
|
|
7
|
+
import { ColumnDef } from '@tanstack/react-table';
|
|
8
|
+
import { ColumnFiltersState } from '@tanstack/react-table';
|
|
3
9
|
import { Component } from 'react';
|
|
4
10
|
import { Context } from 'react';
|
|
5
|
-
import {
|
|
11
|
+
import { createColumnHelper } from '@tanstack/react-table';
|
|
12
|
+
import { CSSProperties } from 'react';
|
|
6
13
|
import { DetailedHTMLProps } from 'react';
|
|
14
|
+
import { Dispatch } from 'react';
|
|
7
15
|
import { FastOmit } from 'styled-components';
|
|
8
16
|
import { ForwardRefComponent } from 'motion/react';
|
|
9
17
|
import { ForwardRefExoticComponent } from 'react';
|
|
18
|
+
import { Header as Header_2 } from '@tanstack/react-table';
|
|
19
|
+
import { HeaderGroup } from '@tanstack/react-table';
|
|
10
20
|
import { HTMLAttributeAnchorTarget } from 'react';
|
|
11
21
|
import { HTMLAttributes } from 'react';
|
|
12
22
|
import { HTMLMotionProps } from 'motion/react';
|
|
23
|
+
import { InputHTMLAttributes } from 'react';
|
|
13
24
|
import { IStyledComponentBase } from 'styled-components/dist/types';
|
|
14
25
|
import { JSX } from 'react/jsx-runtime';
|
|
26
|
+
import { KeyboardEvent as KeyboardEvent_2 } from 'react';
|
|
27
|
+
import { LabelHTMLAttributes } from 'react';
|
|
28
|
+
import { MemoExoticComponent } from 'react';
|
|
15
29
|
import { MouseEventHandler } from 'react';
|
|
16
30
|
import { PropsWithChildren } from 'react';
|
|
17
31
|
import { ReactNode } from 'react';
|
|
18
32
|
import { RefAttributes } from 'react';
|
|
33
|
+
import { RefObject } from 'react';
|
|
19
34
|
import { RemixiconComponentType } from '@remixicon/react';
|
|
35
|
+
import { Row } from '@tanstack/react-table';
|
|
20
36
|
import { RuleSet } from 'styled-components';
|
|
37
|
+
import { SelectHTMLAttributes } from 'react';
|
|
38
|
+
import { SetStateAction } from 'react';
|
|
39
|
+
import { SortingState } from '@tanstack/react-table';
|
|
21
40
|
import { Substitute } from 'styled-components/dist/types';
|
|
41
|
+
import { Table as TanStackTableType } from '@tanstack/react-table';
|
|
42
|
+
import { TextareaHTMLAttributes } from 'react';
|
|
22
43
|
import { toast } from 'sonner';
|
|
23
44
|
import { ToasterProps } from 'sonner';
|
|
45
|
+
import { Updater } from '@tanstack/react-table';
|
|
24
46
|
|
|
25
47
|
/**
|
|
26
48
|
* Valid input types supported by the FormField component
|
|
@@ -44,7 +66,7 @@ $open: boolean;
|
|
|
44
66
|
* @param param0 - Props for the Badge component.
|
|
45
67
|
* @returns The Badge component.
|
|
46
68
|
*/
|
|
47
|
-
export declare const Badge:
|
|
69
|
+
export declare const Badge: ({ children, variant, size, color, leftIcon, rightIcon, iconColor, iconSize, ...props }: BadgeProps) => JSX.Element;
|
|
48
70
|
|
|
49
71
|
/**
|
|
50
72
|
* Props for the Badge component.
|
|
@@ -56,7 +78,7 @@ export declare const Badge: default_2.FC<BadgeProps>;
|
|
|
56
78
|
* @param iconColor - Color of the icons. Default is 'currentColor'.
|
|
57
79
|
* @param iconSize - Size of the icons. Default is 'sm'.
|
|
58
80
|
*/
|
|
59
|
-
declare interface BadgeProps extends
|
|
81
|
+
declare interface BadgeProps extends HTMLAttributes<HTMLSpanElement>, WithIconsProps {
|
|
60
82
|
variant?: BadgeVariant;
|
|
61
83
|
size?: BadgeSize;
|
|
62
84
|
color?: string;
|
|
@@ -79,11 +101,9 @@ declare type BadgeSize = 'sm' | 'md' | 'lg';
|
|
|
79
101
|
*/
|
|
80
102
|
declare type BadgeVariant = 'primary' | 'secondary' | 'success' | 'warning' | 'danger' | 'neutral' | 'outline';
|
|
81
103
|
|
|
82
|
-
export declare const baseContentTableStyles: RuleSet<object>;
|
|
83
|
-
|
|
84
104
|
export declare const baseFieldStyles: RuleSet<object>;
|
|
85
105
|
|
|
86
|
-
export declare interface BaseFormFieldProps extends Omit<
|
|
106
|
+
export declare interface BaseFormFieldProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size'> {
|
|
87
107
|
size?: FormFieldSize;
|
|
88
108
|
hasError?: boolean;
|
|
89
109
|
disabled?: boolean;
|
|
@@ -99,18 +119,31 @@ export declare interface BaseInputProps extends Omit<BaseFormFieldProps, 'type'>
|
|
|
99
119
|
|
|
100
120
|
export declare const baseInputStyles: RuleSet<object>;
|
|
101
121
|
|
|
102
|
-
export declare interface BaseLabelProps extends
|
|
122
|
+
export declare interface BaseLabelProps extends LabelHTMLAttributes<HTMLLabelElement> {
|
|
103
123
|
size?: LabelSize;
|
|
104
124
|
disabled?: boolean;
|
|
105
125
|
required?: boolean;
|
|
106
126
|
className?: string;
|
|
107
127
|
}
|
|
108
128
|
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
}
|
|
129
|
+
/**
|
|
130
|
+
* Base props for the Spinner component.
|
|
131
|
+
* @interface BaseSpinnerProps
|
|
132
|
+
* @property {Size} [size] - Size of the spinner.
|
|
133
|
+
* @property {ColorKey} [color] - Color variant of the spinner.
|
|
134
|
+
* @property {boolean} [centered] - Whether to center the spinner in a container.
|
|
135
|
+
* @property {string} [message] - Optional message to display with the spinner.
|
|
136
|
+
* @property {string} [title] - Optional title for accessibility.
|
|
137
|
+
* @property {Variant} [variant] - Animation variant of the spinner.
|
|
138
|
+
*/
|
|
139
|
+
export declare interface BaseSpinnerProps {
|
|
140
|
+
size?: Size;
|
|
141
|
+
color?: ColorKey;
|
|
142
|
+
centered?: boolean;
|
|
143
|
+
message?: string;
|
|
144
|
+
title?: string;
|
|
145
|
+
variant?: Variant;
|
|
146
|
+
}
|
|
114
147
|
|
|
115
148
|
export declare const bodyTextStyles: {
|
|
116
149
|
80: RuleSet<object>;
|
|
@@ -127,9 +160,9 @@ export declare const bodyTextStyles: {
|
|
|
127
160
|
|
|
128
161
|
export declare const BrandLogo: IStyledComponentBase<"web", FastOmit<DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
129
162
|
|
|
130
|
-
export declare const Button:
|
|
163
|
+
export declare const Button: ({ children, variant, size, isLoading, disabled, leftIcon, rightIcon, iconSize, iconColor, ...props }: ButtonProps) => JSX.Element;
|
|
131
164
|
|
|
132
|
-
declare interface ButtonProps extends
|
|
165
|
+
declare interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement>, WithIconsProps {
|
|
133
166
|
variant?: ButtonVariant;
|
|
134
167
|
size?: ButtonSize;
|
|
135
168
|
isLoading?: boolean;
|
|
@@ -137,49 +170,54 @@ declare interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonEleme
|
|
|
137
170
|
|
|
138
171
|
declare type ButtonSize = 'sm' | 'md' | 'lg';
|
|
139
172
|
|
|
140
|
-
export declare const ButtonSpinner: default_2.FC<{
|
|
141
|
-
color?: ColorKey;
|
|
142
|
-
variant?: Variant;
|
|
143
|
-
}>;
|
|
144
|
-
|
|
145
173
|
declare type ButtonVariant = 'primary' | 'secondary' | 'cancel' | 'outline';
|
|
146
174
|
|
|
147
|
-
export declare const Card:
|
|
175
|
+
export declare const Card: ({ variant, size, disabled, onClick, children, ...props }: CardProps) => JSX.Element;
|
|
176
|
+
|
|
177
|
+
export declare const CardBody: ({ children, showDivider, ...props }: CardBodyProps) => JSX.Element;
|
|
178
|
+
|
|
179
|
+
declare interface CardBodyProps extends HTMLAttributes<HTMLDivElement> {
|
|
180
|
+
showDivider?: boolean;
|
|
181
|
+
}
|
|
148
182
|
|
|
149
|
-
export declare const
|
|
183
|
+
export declare const CardFooter: ({ children, ...props }: HTMLAttributes<HTMLDivElement>) => JSX.Element;
|
|
150
184
|
|
|
151
|
-
export declare const
|
|
185
|
+
export declare const CardHeader: ({ children, showDivider, ...props }: CardHeaderProps) => JSX.Element;
|
|
152
186
|
|
|
153
|
-
|
|
187
|
+
declare interface CardHeaderProps extends HTMLAttributes<HTMLDivElement> {
|
|
188
|
+
showDivider?: boolean;
|
|
189
|
+
}
|
|
154
190
|
|
|
155
|
-
export declare interface CardProps extends
|
|
191
|
+
export declare interface CardProps extends HTMLAttributes<HTMLDivElement> {
|
|
156
192
|
variant?: CardVariant;
|
|
157
193
|
size?: CardSize;
|
|
158
194
|
disabled?: boolean;
|
|
159
195
|
}
|
|
160
196
|
|
|
161
|
-
declare type CardSize = 'sm' | 'md' | 'lg';
|
|
197
|
+
export declare type CardSize = 'sm' | 'md' | 'lg';
|
|
198
|
+
|
|
199
|
+
export declare type CardVariant = 'elevated' | 'flat' | 'info';
|
|
162
200
|
|
|
163
|
-
declare type
|
|
201
|
+
export declare type CellAlignment = 'left' | 'center' | 'right';
|
|
164
202
|
|
|
165
203
|
export declare const Checkbox: ForwardRefExoticComponent<CheckboxProps & RefAttributes<HTMLInputElement>>;
|
|
166
204
|
|
|
167
|
-
export declare const CheckboxInput:
|
|
205
|
+
export declare const CheckboxInput: ForwardRefExoticComponent<CheckboxInputProps & RefAttributes<HTMLInputElement>>;
|
|
168
206
|
|
|
169
|
-
declare interface CheckboxInputProps extends Omit<
|
|
207
|
+
declare interface CheckboxInputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size'> {
|
|
170
208
|
size?: FormFieldSize;
|
|
171
209
|
hasError?: boolean;
|
|
172
210
|
indeterminate?: boolean;
|
|
173
211
|
checkboxClassName?: string;
|
|
174
212
|
}
|
|
175
213
|
|
|
176
|
-
export declare const CheckboxLabel:
|
|
214
|
+
export declare const CheckboxLabel: ({ children, size, disabled, htmlFor, onLabelClick, className, onClick, ...props }: CheckboxLabelProps) => JSX.Element;
|
|
177
215
|
|
|
178
216
|
declare interface CheckboxLabelProps extends BaseLabelProps {
|
|
179
217
|
onLabelClick?: () => void;
|
|
180
218
|
}
|
|
181
219
|
|
|
182
|
-
export declare interface CheckboxProps extends Omit<
|
|
220
|
+
export declare interface CheckboxProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size'> {
|
|
183
221
|
size?: FormFieldSize;
|
|
184
222
|
label?: string;
|
|
185
223
|
hasError?: boolean;
|
|
@@ -200,10 +238,147 @@ export declare interface CheckboxSpecificProps {
|
|
|
200
238
|
*/
|
|
201
239
|
export declare const CloseOpenButton: IStyledComponentBase<"web", FastOmit<DetailedHTMLProps<ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, never>> & string;
|
|
202
240
|
|
|
203
|
-
declare type ColorKey = 'primary' | 'orange' | 'white' | 'gray';
|
|
241
|
+
export declare type ColorKey = 'primary' | 'orange' | 'white' | 'gray';
|
|
204
242
|
|
|
205
243
|
declare type ColorKey_2 = 'primary' | 'orange' | 'white' | 'gray';
|
|
206
244
|
|
|
245
|
+
export { Column }
|
|
246
|
+
|
|
247
|
+
export { ColumnDef }
|
|
248
|
+
|
|
249
|
+
export declare const ColumnFilter: {
|
|
250
|
+
<T extends Record<string, unknown>>({ column, uniqueValues, selectedValues, onChange, }: ColumnFilterProps<T>): JSX.Element;
|
|
251
|
+
displayName: string;
|
|
252
|
+
};
|
|
253
|
+
|
|
254
|
+
export declare const ColumnFilterMenu: {
|
|
255
|
+
({ options, selectedValues, onChange, onClose, searchPlaceholder, }: ColumnFilterMenuProps): JSX.Element;
|
|
256
|
+
displayName: string;
|
|
257
|
+
};
|
|
258
|
+
|
|
259
|
+
export declare interface ColumnFilterMenuProps {
|
|
260
|
+
options: string[];
|
|
261
|
+
selectedValues: string[];
|
|
262
|
+
onChange: (values: string[]) => void;
|
|
263
|
+
onClose: () => void;
|
|
264
|
+
searchPlaceholder?: string;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
export declare interface ColumnFilterProps<T extends Record<string, unknown>> {
|
|
268
|
+
column: Column<T, unknown>;
|
|
269
|
+
uniqueValues: string[];
|
|
270
|
+
selectedValues: string[];
|
|
271
|
+
onChange: (values: string[]) => void;
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
export { ColumnFiltersState }
|
|
275
|
+
|
|
276
|
+
/**
|
|
277
|
+
* Converts ColumnFiltersState to individual query params per value
|
|
278
|
+
* Example: [{ id: 'status', value: ['Active', 'Pending'] }]
|
|
279
|
+
* => 'filter[status][]=Active&filter[status][]=Pending'
|
|
280
|
+
*
|
|
281
|
+
* @param filters - The column filters state from TanStack Table
|
|
282
|
+
* @returns Object suitable for URLSearchParams with array notation
|
|
283
|
+
*/
|
|
284
|
+
export declare function columnFiltersToArrayQueryParams(filters: ColumnFiltersState): Record<string, string[]>;
|
|
285
|
+
|
|
286
|
+
/**
|
|
287
|
+
* Converts ColumnFiltersState to a JSON string
|
|
288
|
+
* Useful for API calls that expect JSON format
|
|
289
|
+
*
|
|
290
|
+
* @param filters - The column filters state from TanStack Table
|
|
291
|
+
* @returns JSON string representation of filters
|
|
292
|
+
*/
|
|
293
|
+
export declare function columnFiltersToJsonString(filters: ColumnFiltersState): string;
|
|
294
|
+
|
|
295
|
+
/**
|
|
296
|
+
* Converts ColumnFiltersState to URL query params format
|
|
297
|
+
* Example: [{ id: 'status', value: ['Active', 'Pending'] }]
|
|
298
|
+
* => 'filter[status]=Active,Pending'
|
|
299
|
+
*
|
|
300
|
+
* @param filters - The column filters state from TanStack Table
|
|
301
|
+
* @param separator - Separator for multiple values (default: ',')
|
|
302
|
+
* @returns Object suitable for URLSearchParams
|
|
303
|
+
*/
|
|
304
|
+
export declare function columnFiltersToQueryParams(filters: ColumnFiltersState, separator?: string): Record<string, string>;
|
|
305
|
+
|
|
306
|
+
/**
|
|
307
|
+
* Converts ColumnFiltersState to a simple object format
|
|
308
|
+
* Example: [{ id: 'status', value: ['Active', 'Pending'] }]
|
|
309
|
+
* => { status: ['Active', 'Pending'] }
|
|
310
|
+
*
|
|
311
|
+
* @param filters - The column filters state from TanStack Table
|
|
312
|
+
* @returns Object with columnId as keys and filter values as values
|
|
313
|
+
*/
|
|
314
|
+
export declare function columnFiltersToRecord(filters: ColumnFiltersState): Record<string, string[]>;
|
|
315
|
+
|
|
316
|
+
/**
|
|
317
|
+
*
|
|
318
|
+
* Column metadata for additional configurations
|
|
319
|
+
* Includes alignment, size, sortable, filterable, truncate, variant, and width
|
|
320
|
+
*/
|
|
321
|
+
export declare interface ColumnMeta {
|
|
322
|
+
align?: CellAlignment;
|
|
323
|
+
size?: TableCellSize;
|
|
324
|
+
sortable?: boolean;
|
|
325
|
+
filterable?: boolean;
|
|
326
|
+
ellipsis?: boolean;
|
|
327
|
+
variant?: 'default' | 'numeric';
|
|
328
|
+
width?: string | number;
|
|
329
|
+
className?: string;
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
/**
|
|
333
|
+
* Creates URLSearchParams for backend pagination with sorting
|
|
334
|
+
* Compatible with Laravel PaginateHelper
|
|
335
|
+
*
|
|
336
|
+
* @param options - Pagination and sorting options
|
|
337
|
+
* @returns URLSearchParams ready to append to API request
|
|
338
|
+
*
|
|
339
|
+
* @example
|
|
340
|
+
* ```ts
|
|
341
|
+
* const params = createBackendParams({
|
|
342
|
+
* sorting: [{ id: 'name', desc: false }],
|
|
343
|
+
* perPage: 20,
|
|
344
|
+
* genericSearch: 'john',
|
|
345
|
+
* filters: { role: 'admin', status: 'active' }
|
|
346
|
+
* });
|
|
347
|
+
*
|
|
348
|
+
* fetch(`/api/users?${params.toString()}`);
|
|
349
|
+
* // Result: /api/users?sorts={"name":"asc"}&perPage=20&genericSearch=john&filters={"role":"admin","status":"active"}
|
|
350
|
+
* ```
|
|
351
|
+
*/
|
|
352
|
+
export declare function createBackendParams(options: {
|
|
353
|
+
sorting?: SortingState;
|
|
354
|
+
perPage?: number;
|
|
355
|
+
genericSearch?: string;
|
|
356
|
+
filters?: Record<string, unknown>;
|
|
357
|
+
}): URLSearchParams;
|
|
358
|
+
|
|
359
|
+
/**
|
|
360
|
+
* Creates complete backend request params with filters, sorting, and pagination
|
|
361
|
+
* Combines filtering with other table features
|
|
362
|
+
*
|
|
363
|
+
* @param options - Configuration object
|
|
364
|
+
* @param options.filters - Column filters state
|
|
365
|
+
* @param options.sorts - Optional sorting state
|
|
366
|
+
* @param options.page - Optional page number
|
|
367
|
+
* @param options.perPage - Optional items per page
|
|
368
|
+
* @returns Complete params object for API requests
|
|
369
|
+
*/
|
|
370
|
+
export declare function createBackendParamsWithFilters({ filters, sorts, page, perPage, }: {
|
|
371
|
+
filters: ColumnFiltersState;
|
|
372
|
+
sorts?: Array<{
|
|
373
|
+
id: string;
|
|
374
|
+
desc: boolean;
|
|
375
|
+
}>;
|
|
376
|
+
page?: number;
|
|
377
|
+
perPage?: number;
|
|
378
|
+
}): Record<string, string | number>;
|
|
379
|
+
|
|
380
|
+
export { createColumnHelper }
|
|
381
|
+
|
|
207
382
|
/**
|
|
208
383
|
* Helper to create field configurations for common patterns
|
|
209
384
|
*/
|
|
@@ -234,36 +409,79 @@ export declare const createInputRefs: (length: number) => InputRef[];
|
|
|
234
409
|
*/
|
|
235
410
|
export declare function deleteCookie(name: string): void;
|
|
236
411
|
|
|
237
|
-
|
|
412
|
+
/**
|
|
413
|
+
* Dialog component for displaying modal dialogs.
|
|
414
|
+
* @params props - DialogProps
|
|
415
|
+
* @return JSX.Element
|
|
416
|
+
*/
|
|
417
|
+
export declare const Dialog: ({ isOpen, onClose, children, className, closeOnBackdropClick, showCloseButton, size, fullScreen, closeOnEsc, ariaLabel, ariaLabelledBy, ariaDescribedBy, }: DialogProps) => JSX.Element;
|
|
238
418
|
|
|
239
|
-
|
|
419
|
+
/**
|
|
420
|
+
* DialogBody component for displaying the main content of a dialog.
|
|
421
|
+
* @params props - DialogBodyProps
|
|
422
|
+
* @return JSX.Element
|
|
423
|
+
*/
|
|
424
|
+
export declare const DialogBody: ({ children, padded, showTopDivider, showBottomDivider, className, ...props }: DialogBodyProps) => JSX.Element;
|
|
240
425
|
|
|
241
|
-
|
|
426
|
+
/**
|
|
427
|
+
* Props for the DialogBody component.
|
|
428
|
+
* @param padded: Whether to apply padding to the body content.
|
|
429
|
+
* @param showTopDivider: Whether to show a divider at the top of the body.
|
|
430
|
+
* @param showBottomDivider: Whether to show a divider at the bottom of the body.
|
|
431
|
+
*/
|
|
432
|
+
export declare interface DialogBodyProps extends HTMLAttributes<HTMLDivElement> {
|
|
242
433
|
padded?: boolean;
|
|
243
434
|
showTopDivider?: boolean;
|
|
244
435
|
showBottomDivider?: boolean;
|
|
245
436
|
}
|
|
246
437
|
|
|
247
|
-
|
|
438
|
+
/**
|
|
439
|
+
* DialogFooter component for displaying footer content in a dialog.
|
|
440
|
+
* @params props - DialogFooterProps
|
|
441
|
+
* @return JSX.Element
|
|
442
|
+
*/
|
|
443
|
+
export declare const DialogFooter: ({ align, showDivider, gap, sticky, children, className, ...props }: DialogFooterProps) => JSX.Element;
|
|
248
444
|
|
|
249
|
-
|
|
445
|
+
/**
|
|
446
|
+
* Props for the DialogFooter component.
|
|
447
|
+
* @param align: Alignment of the footer content.
|
|
448
|
+
* @param showDivider: Whether to show a divider at the top of the footer.
|
|
449
|
+
* @param gap: Gap between footer items in pixels.
|
|
450
|
+
* @param sticky: Whether the footer should be sticky at the bottom.
|
|
451
|
+
*/
|
|
452
|
+
export declare interface DialogFooterProps extends HTMLAttributes<HTMLDivElement> {
|
|
250
453
|
align?: 'start' | 'center' | 'end' | 'space-between';
|
|
251
454
|
showDivider?: boolean;
|
|
252
455
|
gap?: number;
|
|
253
456
|
sticky?: boolean;
|
|
254
457
|
}
|
|
255
458
|
|
|
256
|
-
export declare const DialogHeader:
|
|
459
|
+
export declare const DialogHeader: ({ showDivider, variant, children, className, ...props }: DialogHeaderProps) => JSX.Element;
|
|
257
460
|
|
|
258
|
-
declare interface DialogHeaderProps extends
|
|
461
|
+
export declare interface DialogHeaderProps extends HTMLAttributes<HTMLDivElement> {
|
|
259
462
|
showDivider?: boolean;
|
|
260
463
|
variant?: 'default' | 'compact';
|
|
261
464
|
}
|
|
262
465
|
|
|
263
|
-
|
|
466
|
+
/**
|
|
467
|
+
* 'Props for the Dialog component.
|
|
468
|
+
* @param isOpen: Whether the dialog is open.
|
|
469
|
+
* @param onClose: Callback function to close the dialog.
|
|
470
|
+
* @param children: Content of the dialog.
|
|
471
|
+
* @param className: Optional additional class name for styling.
|
|
472
|
+
* @param closeOnBackdropClick: Whether clicking the backdrop closes the dialog.
|
|
473
|
+
* @param showCloseButton: Whether to show a close button in the dialog.
|
|
474
|
+
* @param size: Size of the dialog ('sm', 'md', 'lg').
|
|
475
|
+
* @param fullScreen: Whether the dialog should be full screen.
|
|
476
|
+
* @param closeOnEsc: Whether pressing the Escape key closes the dialog.
|
|
477
|
+
* @param ariaLabel: ARIA label for accessibility.
|
|
478
|
+
* @param ariaLabelledBy: ID of the element that labels the dialog for accessibility.
|
|
479
|
+
* @param ariaDescribedBy: ID of the element that describes the dialog for accessibility.
|
|
480
|
+
*/
|
|
481
|
+
export declare interface DialogProps {
|
|
264
482
|
isOpen: boolean;
|
|
265
483
|
onClose: () => void;
|
|
266
|
-
children:
|
|
484
|
+
children: ReactNode;
|
|
267
485
|
className?: string;
|
|
268
486
|
closeOnBackdropClick?: boolean;
|
|
269
487
|
showCloseButton?: boolean;
|
|
@@ -282,7 +500,7 @@ export declare const disabledStyles: RuleSet<object>;
|
|
|
282
500
|
* @param param0 - Props for the Divider component.
|
|
283
501
|
* @returns The Divider component.
|
|
284
502
|
*/
|
|
285
|
-
export declare const Divider:
|
|
503
|
+
export declare const Divider: ({ orientation, color, length, thickness, className, }: DividerProps) => JSX.Element;
|
|
286
504
|
|
|
287
505
|
/**
|
|
288
506
|
* Divider component to separate content either horizontally or vertically.
|
|
@@ -300,14 +518,14 @@ export declare interface DividerProps {
|
|
|
300
518
|
className?: string;
|
|
301
519
|
}
|
|
302
520
|
|
|
303
|
-
export declare const ErrorMessage:
|
|
521
|
+
export declare const ErrorMessage: ({ children, className, size, ...props }: ErrorMessageProps) => JSX.Element;
|
|
304
522
|
|
|
305
|
-
declare interface ErrorMessageProps extends
|
|
523
|
+
declare interface ErrorMessageProps extends HTMLAttributes<HTMLDivElement> {
|
|
306
524
|
size?: ErrorMessageSize;
|
|
307
525
|
className?: string;
|
|
308
526
|
}
|
|
309
527
|
|
|
310
|
-
declare type ErrorMessageSize = 'sm' | 'md' | 'lg';
|
|
528
|
+
declare type ErrorMessageSize = 'xs' | 'sm' | 'md' | 'lg';
|
|
311
529
|
|
|
312
530
|
export declare const errorStyles: RuleSet<object>;
|
|
313
531
|
|
|
@@ -343,6 +561,8 @@ export declare interface FieldConfig {
|
|
|
343
561
|
messageErrorClassName?: string;
|
|
344
562
|
}
|
|
345
563
|
|
|
564
|
+
declare type FieldType = 'text' | 'email' | 'password' | 'number' | 'tel' | 'url' | 'date' | 'datetime-local' | 'time' | 'search' | 'textarea' | 'select' | 'checkbox' | 'radio' | 'pin';
|
|
565
|
+
|
|
346
566
|
/**
|
|
347
567
|
*
|
|
348
568
|
* @param files - Array of files to display
|
|
@@ -350,7 +570,7 @@ export declare interface FieldConfig {
|
|
|
350
570
|
* @param disabled - Whether the component is disabled
|
|
351
571
|
* @returns FileList component
|
|
352
572
|
*/
|
|
353
|
-
declare const FileList_2:
|
|
573
|
+
declare const FileList_2: ({ files, onRemove, disabled }: FileListProps) => JSX.Element | null;
|
|
354
574
|
export { FileList_2 as FileList }
|
|
355
575
|
|
|
356
576
|
/**
|
|
@@ -370,9 +590,9 @@ declare interface FileListProps {
|
|
|
370
590
|
* Controlled mode: Provide `value` prop and handle `onChange`
|
|
371
591
|
* Uncontrolled mode: Optionally provide `defaultValue` for initial files
|
|
372
592
|
*/
|
|
373
|
-
export declare const FileUpload:
|
|
593
|
+
export declare const FileUpload: ({ variant, multiple, maxFileSize, accept, helperText, value, defaultValue, onChange, onError, onFileRemove, disabled, hasError, errorMessage, className, dropZoneContainerClassName, size, }: FileUploadProps) => JSX.Element;
|
|
374
594
|
|
|
375
|
-
export declare interface FileUploadProps extends Omit<
|
|
595
|
+
export declare interface FileUploadProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'onChange' | 'value' | 'defaultValue' | 'onError'> {
|
|
376
596
|
variant?: FileUploadVariant;
|
|
377
597
|
size?: FormFieldSize;
|
|
378
598
|
multiple?: boolean;
|
|
@@ -393,15 +613,24 @@ export declare interface FileUploadProps extends Omit<React.InputHTMLAttributes<
|
|
|
393
613
|
|
|
394
614
|
export declare type FileUploadVariant = 'default' | 'compact';
|
|
395
615
|
|
|
616
|
+
export declare const FilterOption: MemoExoticComponent<({ value, label, checked, onChange }: FilterOptionProps) => JSX.Element>;
|
|
617
|
+
|
|
618
|
+
export declare interface FilterOptionProps {
|
|
619
|
+
value: string;
|
|
620
|
+
label: string;
|
|
621
|
+
checked: boolean;
|
|
622
|
+
onChange: (value: string, checked: boolean) => void;
|
|
623
|
+
}
|
|
624
|
+
|
|
396
625
|
export declare const flushedStyles: RuleSet<object>;
|
|
397
626
|
|
|
398
|
-
export declare const FormField:
|
|
627
|
+
export declare const FormField: ({ id, name, label, type, size, placeholder, disabled, required, options, checkboxLabel, radioName, pinLength, pinType, rows, className, inputClassName, labelClassName, messageErrorClassName, leftIcon, rightIcon, iconSize, iconColor, onOptionSelect, onRadioChange, onPinComplete, onChange, ...props }: FormFieldComponentProps) => JSX.Element;
|
|
399
628
|
|
|
400
629
|
export declare interface FormFieldComponentProps extends WithIconsProps {
|
|
401
630
|
id?: string | number;
|
|
402
631
|
name: string;
|
|
403
632
|
label?: string;
|
|
404
|
-
type?:
|
|
633
|
+
type?: FieldType;
|
|
405
634
|
size?: FormFieldSize;
|
|
406
635
|
placeholder?: string;
|
|
407
636
|
disabled?: boolean;
|
|
@@ -410,19 +639,19 @@ export declare interface FormFieldComponentProps extends WithIconsProps {
|
|
|
410
639
|
value: string | number;
|
|
411
640
|
label: string;
|
|
412
641
|
}>;
|
|
413
|
-
checkboxValue?: boolean;
|
|
414
642
|
checkboxLabel?: string;
|
|
415
643
|
radioName?: string;
|
|
416
644
|
pinLength?: number;
|
|
417
645
|
pinType?: 'text' | 'number';
|
|
646
|
+
rows?: number;
|
|
418
647
|
className?: string;
|
|
419
648
|
inputClassName?: string;
|
|
420
649
|
labelClassName?: string;
|
|
421
650
|
messageErrorClassName?: string;
|
|
422
651
|
onOptionSelect?: (option: SelectOption) => void;
|
|
423
|
-
onRadioChange?: (event:
|
|
652
|
+
onRadioChange?: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
424
653
|
onPinComplete?: (value: string) => void;
|
|
425
|
-
onChange?: (event:
|
|
654
|
+
onChange?: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
426
655
|
[key: string]: any;
|
|
427
656
|
}
|
|
428
657
|
|
|
@@ -433,15 +662,55 @@ export declare interface FormFieldProps extends BaseFormFieldProps, Omit<WithIco
|
|
|
433
662
|
className?: string;
|
|
434
663
|
}
|
|
435
664
|
|
|
436
|
-
export declare type FormFieldSize = 'sm' | 'md' | 'lg';
|
|
665
|
+
export declare type FormFieldSize = 'xs' | 'sm' | 'md' | 'lg';
|
|
437
666
|
|
|
438
667
|
export declare type FormFieldState = 'default' | 'hover' | 'focus' | 'error' | 'disabled';
|
|
439
668
|
|
|
440
|
-
|
|
669
|
+
/**
|
|
670
|
+
* FullScreenSpinner Component
|
|
671
|
+
* Renders a full-screen spinner with an optional message.
|
|
672
|
+
* @param {FullScreenSpinnerProps} props - Props for the FullScreenSpinner component see in Spinner.types.ts .
|
|
673
|
+
* @returns JSX.Element The rendered FullScreenSpinner component.
|
|
674
|
+
*/
|
|
675
|
+
export declare const FullScreenSpinner: ({ message, color, variant, }: FullScreenSpinnerProps) => JSX.Element;
|
|
676
|
+
|
|
677
|
+
/**
|
|
678
|
+
* Props for the FullScreenSpinner component.
|
|
679
|
+
* @interface FullScreenSpinnerProps
|
|
680
|
+
* @property {string} [message] - Optional message to display with the spinner.
|
|
681
|
+
* @property {ColorKey} [color] - Color variant of the spinner.
|
|
682
|
+
* @property {Variant} [variant] - Animation variant of the spinner.
|
|
683
|
+
*/
|
|
684
|
+
export declare interface FullScreenSpinnerProps {
|
|
441
685
|
message?: string;
|
|
442
686
|
color?: ColorKey;
|
|
443
687
|
variant?: Variant;
|
|
444
|
-
}
|
|
688
|
+
}
|
|
689
|
+
|
|
690
|
+
/**
|
|
691
|
+
* Gets the count of active filters across all columns
|
|
692
|
+
* @param columnFilters - Current column filters state
|
|
693
|
+
* @returns Total number of active filter values
|
|
694
|
+
*/
|
|
695
|
+
export declare function getActiveFilterCount(columnFilters: ColumnFiltersState): number;
|
|
696
|
+
|
|
697
|
+
/**
|
|
698
|
+
* Gets the active filter values for a specific column
|
|
699
|
+
* @param columnFilters - Current column filters state
|
|
700
|
+
* @param columnId - The column identifier
|
|
701
|
+
* @returns Array of active filter values for the column
|
|
702
|
+
*/
|
|
703
|
+
export declare function getActiveFilterValues(columnFilters: ColumnFiltersState, columnId: string): string[];
|
|
704
|
+
|
|
705
|
+
/**
|
|
706
|
+
* Gets the count of rows for each unique value in a column
|
|
707
|
+
* Useful for showing counts next to filter options (e.g., "Active (5)")
|
|
708
|
+
* @param data - The array of data objects
|
|
709
|
+
* @param columnId - The column identifier
|
|
710
|
+
* @param accessor - Optional accessor function to get the value from a row
|
|
711
|
+
* @returns Object mapping values to their counts
|
|
712
|
+
*/
|
|
713
|
+
export declare function getColumnValueCounts<T>(data: T[], columnId: string, accessor?: (row: T, index: number) => unknown): Record<string, number>;
|
|
445
714
|
|
|
446
715
|
/**
|
|
447
716
|
* Retrieves the value of a cookie by name
|
|
@@ -459,6 +728,15 @@ export declare const getPropsForInputType: (type: string | null | undefined, bas
|
|
|
459
728
|
props: any;
|
|
460
729
|
};
|
|
461
730
|
|
|
731
|
+
/**
|
|
732
|
+
* Extracts unique values from a column in the dataset
|
|
733
|
+
* @param data - The array of data objects
|
|
734
|
+
* @param columnId - The column identifier
|
|
735
|
+
* @param accessor - Optional accessor function to get the value from a row
|
|
736
|
+
* @returns Array of unique string values, sorted alphabetically
|
|
737
|
+
*/
|
|
738
|
+
export declare function getUniqueColumnValues<T>(data: T[], columnId: string, accessor?: (row: T, index: number) => unknown): string[];
|
|
739
|
+
|
|
462
740
|
/**
|
|
463
741
|
* Handles user input in a single digit field of a verification code.
|
|
464
742
|
*
|
|
@@ -487,7 +765,7 @@ export declare const getPropsForInputType: (type: string | null | undefined, bas
|
|
|
487
765
|
* />
|
|
488
766
|
* ```
|
|
489
767
|
*/
|
|
490
|
-
export declare const handleDigitChange: (e:
|
|
768
|
+
export declare const handleDigitChange: (e: ChangeEvent<HTMLInputElement>, index: number, digits: string[], setDigits: SetDigits, inputRefs: InputRefs, length: number, type?: "text" | "number", onChange?: (value: string) => void, onComplete?: (value: string) => void) => void;
|
|
491
769
|
|
|
492
770
|
/**
|
|
493
771
|
* Handles keyboard navigation in verification code input fields.
|
|
@@ -511,7 +789,7 @@ export declare const handleDigitChange: (e: default_2.ChangeEvent<HTMLInputEleme
|
|
|
511
789
|
* />
|
|
512
790
|
* ```
|
|
513
791
|
*/
|
|
514
|
-
export declare const handleKeyDown: (e:
|
|
792
|
+
export declare const handleKeyDown: (e: KeyboardEvent_2<HTMLInputElement>, index: number, digits: string[], inputRefs: InputRefs, setDigits: SetDigits, onChange?: (value: string) => void) => void;
|
|
515
793
|
|
|
516
794
|
/**
|
|
517
795
|
* Handles paste operations for verification code input fields.
|
|
@@ -547,7 +825,15 @@ export declare const handleKeyDown: (e: default_2.KeyboardEvent<HTMLInputElement
|
|
|
547
825
|
* />
|
|
548
826
|
* ```
|
|
549
827
|
*/
|
|
550
|
-
export declare const handlePaste: (e:
|
|
828
|
+
export declare const handlePaste: (e: ClipboardEvent_2<HTMLInputElement>, index: number, digits: string[], setDigits: SetDigits, inputRefs: InputRefs, length: number, type?: "text" | "number", onChange?: (value: string) => void, onComplete?: (value: string) => void) => void;
|
|
829
|
+
|
|
830
|
+
/**
|
|
831
|
+
* Checks if a column has active filters
|
|
832
|
+
* @param columnFilters - Current column filters state
|
|
833
|
+
* @param columnId - The column identifier
|
|
834
|
+
* @returns true if the column has active filters
|
|
835
|
+
*/
|
|
836
|
+
export declare function hasActiveFilters(columnFilters: ColumnFiltersState, columnId: string): boolean;
|
|
551
837
|
|
|
552
838
|
/**
|
|
553
839
|
* Tipo helper para determinar si un componente tiene iconos
|
|
@@ -575,9 +861,12 @@ export declare const hasPermission: (userRoles?: string[], permissions?: string[
|
|
|
575
861
|
* Displays notifications, user profile, and optional children.
|
|
576
862
|
*
|
|
577
863
|
* @param {HeaderProps} props - Header component props.
|
|
578
|
-
* @returns
|
|
864
|
+
* @returns JSX.Element The rendered header.
|
|
579
865
|
*/
|
|
580
|
-
export declare const Header:
|
|
866
|
+
export declare const Header: {
|
|
867
|
+
({ user, hasNotifications, notificationCount, onNotificationClick, onUserProfileClick, onLogout, userMenuItems, children, }: HeaderProps): JSX.Element;
|
|
868
|
+
displayName: string;
|
|
869
|
+
};
|
|
581
870
|
|
|
582
871
|
/**
|
|
583
872
|
* Props for the Header component.
|
|
@@ -590,7 +879,7 @@ export declare const Header: default_2.FC<HeaderProps>;
|
|
|
590
879
|
* @param userMenuItems: Additional menu items for the user dropdown.
|
|
591
880
|
* @param children: Any additional elements to render in the left section.
|
|
592
881
|
*/
|
|
593
|
-
declare interface HeaderProps {
|
|
882
|
+
export declare interface HeaderProps {
|
|
594
883
|
user?: User;
|
|
595
884
|
hasNotifications?: boolean;
|
|
596
885
|
notificationCount?: number;
|
|
@@ -598,7 +887,7 @@ declare interface HeaderProps {
|
|
|
598
887
|
onUserProfileClick?: () => void;
|
|
599
888
|
onLogout?: () => void;
|
|
600
889
|
userMenuItems?: UserMenuItem[];
|
|
601
|
-
children?:
|
|
890
|
+
children?: ReactNode;
|
|
602
891
|
}
|
|
603
892
|
|
|
604
893
|
export declare const HeadingBold: IStyledComponentBase<"web", Substitute<DetailedHTMLProps<HTMLAttributes<HTMLHeadingElement>, HTMLHeadingElement>, {
|
|
@@ -631,10 +920,10 @@ export declare const headingRegularStyles: {
|
|
|
631
920
|
16: RuleSet<object>;
|
|
632
921
|
};
|
|
633
922
|
|
|
634
|
-
export declare const Icon:
|
|
923
|
+
export declare const Icon: ({ component: Component, size, color, className, iconProps, }: IconProps) => JSX.Element;
|
|
635
924
|
|
|
636
925
|
declare interface IconProps {
|
|
637
|
-
component:
|
|
926
|
+
component: ReactNode | RemixiconComponentType;
|
|
638
927
|
size?: IconSizes | string | number;
|
|
639
928
|
color?: string;
|
|
640
929
|
className?: string;
|
|
@@ -650,7 +939,7 @@ export declare const IconWrapperStyles: RuleSet<object>;
|
|
|
650
939
|
* @param param0 - Props for the InfoLabel component.
|
|
651
940
|
* @returns The InfoLabel component.
|
|
652
941
|
*/
|
|
653
|
-
export declare const InfoLabel:
|
|
942
|
+
export declare const InfoLabel: ({ children, size, color, className, style }: InfoLabelProps) => JSX.Element;
|
|
654
943
|
|
|
655
944
|
/**
|
|
656
945
|
* Props for the InfoLabel component
|
|
@@ -664,8 +953,8 @@ export declare interface InfoLabelProps {
|
|
|
664
953
|
size?: keyof typeof bodyTextStyles;
|
|
665
954
|
color?: string;
|
|
666
955
|
className?: string;
|
|
667
|
-
style?:
|
|
668
|
-
children:
|
|
956
|
+
style?: CSSProperties;
|
|
957
|
+
children: ReactNode;
|
|
669
958
|
}
|
|
670
959
|
|
|
671
960
|
/**
|
|
@@ -681,7 +970,7 @@ export declare interface InputComponentProps {
|
|
|
681
970
|
size: FormFieldSize;
|
|
682
971
|
placeholder?: string;
|
|
683
972
|
type?: string;
|
|
684
|
-
onChange?: (event:
|
|
973
|
+
onChange?: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
685
974
|
[key: string]: any;
|
|
686
975
|
}
|
|
687
976
|
|
|
@@ -699,9 +988,9 @@ export declare interface InputComponentProps {
|
|
|
699
988
|
*
|
|
700
989
|
* Used by: PinInputGroup component for PIN/verification code workflows
|
|
701
990
|
*/
|
|
702
|
-
export declare type InputRef =
|
|
991
|
+
export declare type InputRef = RefObject<HTMLInputElement | null>;
|
|
703
992
|
|
|
704
|
-
export declare type InputRefs =
|
|
993
|
+
export declare type InputRefs = RefObject<HTMLInputElement | null>[];
|
|
705
994
|
|
|
706
995
|
/**
|
|
707
996
|
* Interfaz específica para componentes de input que necesitan iconos
|
|
@@ -717,16 +1006,33 @@ export declare interface InputWithIconsProps extends WithIconsProps {
|
|
|
717
1006
|
*/
|
|
718
1007
|
export declare const isAllowedInputType: (t: string) => t is AllowedInputType;
|
|
719
1008
|
|
|
720
|
-
export declare const Label:
|
|
1009
|
+
export declare const Label: ({ children, htmlFor, className, required, disabled, size, ...props }: BaseLabelProps) => JSX.Element;
|
|
721
1010
|
|
|
722
|
-
export declare type LabelSize = 'sm' | 'md' | 'lg';
|
|
1011
|
+
export declare type LabelSize = 'xs' | 'sm' | 'md' | 'lg';
|
|
723
1012
|
|
|
724
1013
|
/**
|
|
725
1014
|
* Top-level Layout component.
|
|
726
1015
|
* Wraps the layout in a SidebarProvider context.
|
|
727
1016
|
* @param props - Layout properties
|
|
728
1017
|
*/
|
|
729
|
-
export declare const Layout:
|
|
1018
|
+
export declare const Layout: (props: LayoutProps) => JSX.Element;
|
|
1019
|
+
|
|
1020
|
+
/**
|
|
1021
|
+
* LayoutMainContent component for the layout.
|
|
1022
|
+
* Provides the main content area with responsive spacing and scrolling.
|
|
1023
|
+
*/
|
|
1024
|
+
export declare const LayoutMainContent: {
|
|
1025
|
+
({ children, className }: LayoutMainContentProps): JSX.Element;
|
|
1026
|
+
displayName: string;
|
|
1027
|
+
};
|
|
1028
|
+
|
|
1029
|
+
/**
|
|
1030
|
+
* Props for the LayoutMainContent component.
|
|
1031
|
+
*/
|
|
1032
|
+
export declare interface LayoutMainContentProps {
|
|
1033
|
+
children: ReactNode;
|
|
1034
|
+
className?: string;
|
|
1035
|
+
}
|
|
730
1036
|
|
|
731
1037
|
/**
|
|
732
1038
|
* Props for the Layout component.
|
|
@@ -742,7 +1048,7 @@ export declare const Layout: default_2.FC<LayoutProps>;
|
|
|
742
1048
|
* @contentClassName - Optional class name for main content area.
|
|
743
1049
|
*/
|
|
744
1050
|
export declare interface LayoutProps extends SidebarProps {
|
|
745
|
-
children:
|
|
1051
|
+
children: ReactNode;
|
|
746
1052
|
user?: User;
|
|
747
1053
|
hasNotifications?: boolean;
|
|
748
1054
|
notificationCount?: number;
|
|
@@ -761,7 +1067,7 @@ export declare interface LayoutProps extends SidebarProps {
|
|
|
761
1067
|
* @param ref - Ref to the anchor element
|
|
762
1068
|
* @return JSX.Element
|
|
763
1069
|
*/
|
|
764
|
-
export declare const Link:
|
|
1070
|
+
export declare const Link: ForwardRefExoticComponent<LinkProps & RefAttributes<HTMLAnchorElement>>;
|
|
765
1071
|
|
|
766
1072
|
/**
|
|
767
1073
|
* CSS styles applied when the Link is disabled.
|
|
@@ -818,6 +1124,14 @@ export declare const LinkVariantStyles: {
|
|
|
818
1124
|
plain: RuleSet<object>;
|
|
819
1125
|
};
|
|
820
1126
|
|
|
1127
|
+
/**
|
|
1128
|
+
* Merges multiple filter states, with later filters overriding earlier ones
|
|
1129
|
+
*
|
|
1130
|
+
* @param filterStates - Multiple ColumnFiltersState arrays to merge
|
|
1131
|
+
* @returns Merged ColumnFiltersState
|
|
1132
|
+
*/
|
|
1133
|
+
export declare function mergeFilters(...filterStates: ColumnFiltersState[]): ColumnFiltersState;
|
|
1134
|
+
|
|
821
1135
|
/**
|
|
822
1136
|
* Button to open sidebar on mobile devices.
|
|
823
1137
|
* @param $hidden - Whether the button is hidden.
|
|
@@ -826,6 +1140,16 @@ export declare const MobileOpenBtn: IStyledComponentBase<"web", Substitute<Detai
|
|
|
826
1140
|
$hidden: boolean;
|
|
827
1141
|
}>> & string;
|
|
828
1142
|
|
|
1143
|
+
/**
|
|
1144
|
+
* Custom filter function for TanStack Table multi-select filtering
|
|
1145
|
+
* Checks if the row's value is included in the array of selected filter values
|
|
1146
|
+
* @param row - The row being filtered
|
|
1147
|
+
* @param columnId - The column identifier
|
|
1148
|
+
* @param filterValue - Array of selected filter values
|
|
1149
|
+
* @returns true if the row should be included in filtered results
|
|
1150
|
+
*/
|
|
1151
|
+
export declare function multiSelectFilter<T>(row: Row<T>, columnId: string, filterValue: unknown): boolean;
|
|
1152
|
+
|
|
829
1153
|
/**
|
|
830
1154
|
* Navigation container for sidebar menu items.
|
|
831
1155
|
*/
|
|
@@ -847,7 +1171,7 @@ export declare const Nav: IStyledComponentBase<"web", FastOmit<DetailedHTMLProps
|
|
|
847
1171
|
export declare interface NavigationItem {
|
|
848
1172
|
id: string;
|
|
849
1173
|
label: string;
|
|
850
|
-
icon?:
|
|
1174
|
+
icon?: ReactNode | RemixiconComponentType;
|
|
851
1175
|
iconSize?: IconSizes | string | number;
|
|
852
1176
|
iconColor?: string;
|
|
853
1177
|
href?: string;
|
|
@@ -873,6 +1197,24 @@ export declare const normalizeSelectOptions: (options: Array<{
|
|
|
873
1197
|
label: string;
|
|
874
1198
|
}> | SelectOption[]) => SelectOption[];
|
|
875
1199
|
|
|
1200
|
+
/**
|
|
1201
|
+
* NotificationButton component with badge and count display.
|
|
1202
|
+
* Handles notification state and provides accessible interaction.
|
|
1203
|
+
*/
|
|
1204
|
+
export declare const NotificationButton: {
|
|
1205
|
+
({ hasNotifications, notificationCount, onNotificationClick, }: NotificationButtonProps): JSX.Element;
|
|
1206
|
+
displayName: string;
|
|
1207
|
+
};
|
|
1208
|
+
|
|
1209
|
+
/**
|
|
1210
|
+
* Props for the NotificationButton component.
|
|
1211
|
+
*/
|
|
1212
|
+
export declare interface NotificationButtonProps {
|
|
1213
|
+
hasNotifications?: boolean;
|
|
1214
|
+
notificationCount?: number;
|
|
1215
|
+
onNotificationClick?: () => void;
|
|
1216
|
+
}
|
|
1217
|
+
|
|
876
1218
|
/**
|
|
877
1219
|
* Overlay component for mobile sidebar.
|
|
878
1220
|
*/
|
|
@@ -898,7 +1240,25 @@ export declare const overlayAnimation: {
|
|
|
898
1240
|
};
|
|
899
1241
|
};
|
|
900
1242
|
|
|
901
|
-
|
|
1243
|
+
/**
|
|
1244
|
+
* Parses JSON string back to ColumnFiltersState
|
|
1245
|
+
*
|
|
1246
|
+
* @param jsonString - JSON string representation of filters
|
|
1247
|
+
* @returns ColumnFiltersState
|
|
1248
|
+
*/
|
|
1249
|
+
export declare function parseJsonToFilters(jsonString: string): ColumnFiltersState;
|
|
1250
|
+
|
|
1251
|
+
/**
|
|
1252
|
+
* Parses URL query params back to ColumnFiltersState
|
|
1253
|
+
* Useful for restoring filters from URL
|
|
1254
|
+
*
|
|
1255
|
+
* @param params - URLSearchParams or query string
|
|
1256
|
+
* @param separator - Separator used in the query params (default: ',')
|
|
1257
|
+
* @returns ColumnFiltersState
|
|
1258
|
+
*/
|
|
1259
|
+
export declare function parseQueryParamsToFilters(params: URLSearchParams | string, separator?: string): ColumnFiltersState;
|
|
1260
|
+
|
|
1261
|
+
export declare const PasswordInput: ({ size, leftIcon, iconSize, iconColor, placeholder, hasError, disabled, className, ...props }: PasswordInputProps) => JSX.Element;
|
|
902
1262
|
|
|
903
1263
|
export declare interface PasswordInputProps extends BaseFormFieldProps, Omit<WithIconsProps, 'rightIcon'> {
|
|
904
1264
|
}
|
|
@@ -907,7 +1267,10 @@ export declare type Permission = string;
|
|
|
907
1267
|
|
|
908
1268
|
export declare const PinInput: ForwardRefExoticComponent<PinInputProps & RefAttributes<HTMLInputElement>>;
|
|
909
1269
|
|
|
910
|
-
export declare const PinInputGroup:
|
|
1270
|
+
export declare const PinInputGroup: {
|
|
1271
|
+
({ length, size, variant, hasError, type, onChange, onComplete, className, pinInputClassName, }: PinInputGroupProps): JSX.Element;
|
|
1272
|
+
displayName: string;
|
|
1273
|
+
};
|
|
911
1274
|
|
|
912
1275
|
export declare interface PinInputGroupProps {
|
|
913
1276
|
length?: number;
|
|
@@ -933,17 +1296,20 @@ export declare interface PinSpecificProps {
|
|
|
933
1296
|
|
|
934
1297
|
export declare const RadioInput: ForwardRefExoticComponent<RadioInputProps & RefAttributes<HTMLInputElement>>;
|
|
935
1298
|
|
|
936
|
-
export declare const RadioInputDot:
|
|
1299
|
+
export declare const RadioInputDot: ForwardRefExoticComponent<RadioInputDotProps & RefAttributes<HTMLInputElement>>;
|
|
937
1300
|
|
|
938
|
-
declare interface RadioInputDotProps extends Omit<
|
|
1301
|
+
declare interface RadioInputDotProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'type'> {
|
|
939
1302
|
size?: FormFieldSize;
|
|
940
1303
|
hasError?: boolean;
|
|
941
1304
|
dotClassName?: string;
|
|
942
1305
|
}
|
|
943
1306
|
|
|
944
|
-
export declare const RadioInputLabel:
|
|
1307
|
+
export declare const RadioInputLabel: {
|
|
1308
|
+
({ children, htmlFor, className, disabled, size, ...props }: BaseLabelProps): JSX.Element;
|
|
1309
|
+
displayName: string;
|
|
1310
|
+
};
|
|
945
1311
|
|
|
946
|
-
export declare interface RadioInputProps extends Omit<
|
|
1312
|
+
export declare interface RadioInputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'type'> {
|
|
947
1313
|
size?: FormFieldSize;
|
|
948
1314
|
label?: string;
|
|
949
1315
|
hasError?: boolean;
|
|
@@ -957,10 +1323,20 @@ export declare interface RadioSpecificProps {
|
|
|
957
1323
|
label: string;
|
|
958
1324
|
}>;
|
|
959
1325
|
radioName?: string;
|
|
960
|
-
onRadioChange?: (event:
|
|
1326
|
+
onRadioChange?: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
961
1327
|
}
|
|
962
1328
|
|
|
963
|
-
export
|
|
1329
|
+
export { Row }
|
|
1330
|
+
|
|
1331
|
+
/**
|
|
1332
|
+
* Searches for a term within an array of items (case-insensitive)
|
|
1333
|
+
* @param items - Array of items to search through
|
|
1334
|
+
* @param searchTerm - The search term
|
|
1335
|
+
* @returns Filtered array of items matching the search term
|
|
1336
|
+
*/
|
|
1337
|
+
export declare function searchInArray(items: string[], searchTerm: string): string[];
|
|
1338
|
+
|
|
1339
|
+
export declare const SearchInput: ({ size, leftIcon, rightIcon, iconSize, iconColor, placeholder, onSearch, className, ...props }: SearchInputProps) => JSX.Element;
|
|
964
1340
|
|
|
965
1341
|
export declare interface SearchInputProps extends BaseInputProps {
|
|
966
1342
|
size?: FormFieldSize;
|
|
@@ -973,15 +1349,30 @@ export declare interface SearchSpecificProps {
|
|
|
973
1349
|
onSearch?: (value: string) => void;
|
|
974
1350
|
}
|
|
975
1351
|
|
|
976
|
-
|
|
1352
|
+
/**
|
|
1353
|
+
* SectionSpinner Component
|
|
1354
|
+
* Renders a spinner suitable for section loading states with an optional message.
|
|
1355
|
+
* @param {SectionSpinnerProps} props - Props for the SectionSpinner component see in Spinner.types.ts .
|
|
1356
|
+
* @returns JSX.Element The rendered SectionSpinner component.
|
|
1357
|
+
*/
|
|
1358
|
+
export declare const SectionSpinner: ({ message, color, variant, }: SectionSpinnerProps) => JSX.Element;
|
|
1359
|
+
|
|
1360
|
+
/**
|
|
1361
|
+
* Props for the SectionSpinner component
|
|
1362
|
+
* @interface SectionSpinnerProps
|
|
1363
|
+
* @property {string} [message] - Optional message to display with the spinner.
|
|
1364
|
+
* @property {ColorKey} [color] - Color variant of the spinner.
|
|
1365
|
+
* @property {Variant} [variant] - Animation variant of the spinner.
|
|
1366
|
+
*/
|
|
1367
|
+
export declare interface SectionSpinnerProps {
|
|
977
1368
|
message?: string;
|
|
978
1369
|
color?: ColorKey;
|
|
979
1370
|
variant?: Variant;
|
|
980
|
-
}
|
|
1371
|
+
}
|
|
981
1372
|
|
|
982
|
-
export declare const SelectInput:
|
|
1373
|
+
export declare const SelectInput: ForwardRefExoticComponent<SelectInputProps & RefAttributes<HTMLButtonElement>>;
|
|
983
1374
|
|
|
984
|
-
export declare interface SelectInputProps extends Omit<
|
|
1375
|
+
export declare interface SelectInputProps extends Omit<SelectHTMLAttributes<HTMLSelectElement>, 'size'> {
|
|
985
1376
|
size?: FormFieldSize;
|
|
986
1377
|
hasError?: boolean;
|
|
987
1378
|
disabled?: boolean;
|
|
@@ -1016,7 +1407,7 @@ export declare interface SelectSpecificProps {
|
|
|
1016
1407
|
*/
|
|
1017
1408
|
export declare function setCookie(name: string, value: string, days?: number): void;
|
|
1018
1409
|
|
|
1019
|
-
export declare type SetDigits =
|
|
1410
|
+
export declare type SetDigits = Dispatch<SetStateAction<string[]>>;
|
|
1020
1411
|
|
|
1021
1412
|
/**
|
|
1022
1413
|
* Sidebar component for navigation.
|
|
@@ -1026,7 +1417,10 @@ export declare type SetDigits = default_2.Dispatch<default_2.SetStateAction<stri
|
|
|
1026
1417
|
* @param logoImgExpanded - Logo when sidebar is expanded.
|
|
1027
1418
|
* @param logoImgCollapsed - Logo when sidebar is collapsed.
|
|
1028
1419
|
*/
|
|
1029
|
-
export declare const Sidebar:
|
|
1420
|
+
export declare const Sidebar: {
|
|
1421
|
+
({ navigationConfig, userRoles, activePath, logoImgExpanded, logoImgCollapsed, onNavigate, }: SidebarProps): JSX.Element;
|
|
1422
|
+
displayName: string;
|
|
1423
|
+
};
|
|
1030
1424
|
|
|
1031
1425
|
export declare const SidebarContext: Context<SidebarContextValue | undefined>;
|
|
1032
1426
|
|
|
@@ -1066,16 +1460,27 @@ export declare interface SidebarProps {
|
|
|
1066
1460
|
navigationConfig: NavigationItem[];
|
|
1067
1461
|
userRoles?: string[];
|
|
1068
1462
|
activePath?: string;
|
|
1069
|
-
logoImgExpanded?:
|
|
1070
|
-
logoImgCollapsed?:
|
|
1463
|
+
logoImgExpanded?: ReactNode;
|
|
1464
|
+
logoImgCollapsed?: ReactNode;
|
|
1071
1465
|
onNavigate?: (href: string) => void;
|
|
1072
1466
|
}
|
|
1073
1467
|
|
|
1074
1468
|
export declare const SidebarProvider: ({ children }: PropsWithChildren) => JSX.Element;
|
|
1075
1469
|
|
|
1076
|
-
|
|
1470
|
+
/**
|
|
1471
|
+
* Size options for the Spinner component.
|
|
1472
|
+
* typedef {('sm' | 'md' | 'lg' | 'xl')} Size
|
|
1473
|
+
*
|
|
1474
|
+
* Color key options for the Spinner component.
|
|
1475
|
+
* typedef {('primary' | 'orange' | 'white' | 'gray')} ColorKey
|
|
1476
|
+
*
|
|
1477
|
+
* Animation variant options for the Spinner component.
|
|
1478
|
+
* typedef {('rotate' | 'sweep')} Variant
|
|
1479
|
+
*/
|
|
1480
|
+
export declare type Size = 'sm' | 'md' | 'lg' | 'xl';
|
|
1077
1481
|
|
|
1078
1482
|
export declare const sizeStyles: {
|
|
1483
|
+
xs: RuleSet<object>;
|
|
1079
1484
|
sm: RuleSet<object>;
|
|
1080
1485
|
md: RuleSet<object>;
|
|
1081
1486
|
lg: RuleSet<object>;
|
|
@@ -1198,21 +1603,79 @@ export declare const smartAnimation: {
|
|
|
1198
1603
|
|
|
1199
1604
|
export declare type SortDirection = 'asc' | 'desc' | 'none';
|
|
1200
1605
|
|
|
1201
|
-
export
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1606
|
+
export { SortingState }
|
|
1607
|
+
|
|
1608
|
+
/**
|
|
1609
|
+
* Converts SortingState to JSON string ready to send to Laravel backend
|
|
1610
|
+
* This is a convenience function for API calls
|
|
1611
|
+
*
|
|
1612
|
+
* @param sortingState - TanStack sorting state array
|
|
1613
|
+
* @returns JSON string representation of sort record
|
|
1614
|
+
*
|
|
1615
|
+
* @example
|
|
1616
|
+
* ```ts
|
|
1617
|
+
* const sortingState = [{ id: 'name', desc: false }];
|
|
1618
|
+
* const sortsParam = sortingStateToJsonString(sortingState);
|
|
1619
|
+
* // Result: '{"name":"asc"}'
|
|
1620
|
+
*
|
|
1621
|
+
* // Use in API call:
|
|
1622
|
+
* fetch(`/api/users?sorts=${sortsParam}`);
|
|
1623
|
+
* ```
|
|
1624
|
+
*/
|
|
1625
|
+
export declare function sortingStateToJsonString(sortingState: SortingState): string;
|
|
1205
1626
|
|
|
1206
|
-
|
|
1627
|
+
/**
|
|
1628
|
+
* Converts TanStack Table SortingState to backend-friendly record format
|
|
1629
|
+
*
|
|
1630
|
+
* @param sortingState - TanStack sorting state array
|
|
1631
|
+
* @returns Object with field names as keys and 'asc'/'desc' as values
|
|
1632
|
+
*
|
|
1633
|
+
* @example
|
|
1634
|
+
* ```ts
|
|
1635
|
+
* const sortingState = [
|
|
1636
|
+
* { id: 'name', desc: false },
|
|
1637
|
+
* { id: 'created_at', desc: true }
|
|
1638
|
+
* ];
|
|
1639
|
+
*
|
|
1640
|
+
* const sortRecord = sortingStateToRecord(sortingState);
|
|
1641
|
+
* // Result: { name: 'asc', created_at: 'desc' }
|
|
1642
|
+
* ```
|
|
1643
|
+
*/
|
|
1644
|
+
export declare function sortingStateToRecord(sortingState: SortingState): SortRecord;
|
|
1207
1645
|
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1646
|
+
/**
|
|
1647
|
+
* Backend sorting format - object representation
|
|
1648
|
+
* Example: { name: 'asc', created_at: 'desc' }
|
|
1649
|
+
*/
|
|
1650
|
+
export declare type SortRecord = Record<string, 'asc' | 'desc'>;
|
|
1651
|
+
|
|
1652
|
+
/**
|
|
1653
|
+
* Converts backend sort record to TanStack Table SortingState
|
|
1654
|
+
* Useful for initializing sorting state from backend response
|
|
1655
|
+
*
|
|
1656
|
+
* @param sortRecord - Object with field names and sort directions
|
|
1657
|
+
* @returns TanStack sorting state array
|
|
1658
|
+
*
|
|
1659
|
+
* @example
|
|
1660
|
+
* ```ts
|
|
1661
|
+
* const sortRecord = { name: 'asc', created_at: 'desc' };
|
|
1662
|
+
*
|
|
1663
|
+
* const sortingState = sortRecordToSortingState(sortRecord);
|
|
1664
|
+
* // Result: [
|
|
1665
|
+
* // { id: 'name', desc: false },
|
|
1666
|
+
* // { id: 'created_at', desc: true }
|
|
1667
|
+
* // ]
|
|
1668
|
+
* ```
|
|
1669
|
+
*/
|
|
1670
|
+
export declare function sortRecordToSortingState(sortRecord: SortRecord): SortingState;
|
|
1671
|
+
|
|
1672
|
+
/**
|
|
1673
|
+
* Spinner Component
|
|
1674
|
+
* Renders a customizable spinner with optional message and centering.
|
|
1675
|
+
* @param {BaseSpinnerProps} props - Props for the Spinner component see in Spinner.types.ts .
|
|
1676
|
+
* @returns JSX.Element The rendered Spinner component.
|
|
1677
|
+
*/
|
|
1678
|
+
export declare const Spinner: ({ size, color, centered, message, title, variant, }: BaseSpinnerProps) => JSX.Element;
|
|
1216
1679
|
|
|
1217
1680
|
/**
|
|
1218
1681
|
* Represents a single step in the Stepper.
|
|
@@ -1220,14 +1683,14 @@ declare interface SpinnerProps {
|
|
|
1220
1683
|
export declare interface Step {
|
|
1221
1684
|
id: string | number;
|
|
1222
1685
|
label?: string;
|
|
1223
|
-
content?:
|
|
1686
|
+
content?: ReactNode | string;
|
|
1224
1687
|
}
|
|
1225
1688
|
|
|
1226
1689
|
/**
|
|
1227
1690
|
* Stepper component for displaying multi-step navigation UI.
|
|
1228
1691
|
* Simple and functional with hover labels.
|
|
1229
1692
|
*/
|
|
1230
|
-
export declare const Stepper:
|
|
1693
|
+
export declare const Stepper: ({ steps, currentStep, orientation, size, onStepClick, className, }: StepperProps) => JSX.Element;
|
|
1231
1694
|
|
|
1232
1695
|
/**
|
|
1233
1696
|
* Orientation options for the Stepper component.
|
|
@@ -1283,119 +1746,197 @@ export declare const submenuAnimationTopDown: {
|
|
|
1283
1746
|
};
|
|
1284
1747
|
|
|
1285
1748
|
/**
|
|
1286
|
-
* Table component
|
|
1287
|
-
*
|
|
1288
|
-
*
|
|
1289
|
-
* @param columns - Array of column definitions.
|
|
1290
|
-
* @param rows - Array of row data.
|
|
1291
|
-
* @param size - Table size variant ('sm', 'md', 'lg'). Default is 'md'.
|
|
1292
|
-
* @param variant - Table visual variant. Default is 'default'.
|
|
1293
|
-
* @param className - Optional CSS class for the table.
|
|
1294
|
-
* @param stickyHeader - Enables sticky table headers.
|
|
1295
|
-
* @param onSortChange - Callback for sort direction changes.
|
|
1749
|
+
* Main Table component
|
|
1750
|
+
* Uses TanStack Table v8 as headless layer
|
|
1296
1751
|
*/
|
|
1297
1752
|
export declare const Table: {
|
|
1298
|
-
({
|
|
1753
|
+
<T extends Record<string, unknown>>({ data, columns, size, variant, stickyHeader, maxHeight, sorting, defaultSorting, onSortingChange, columnFilters, defaultColumnFilters, onColumnFiltersChange, onRowClick, classNames, enableSorting, manualSorting, enableFiltering, manualFiltering, isLoading, getUniqueValues: getUniqueValuesProp, }: TableProps<T>): JSX.Element;
|
|
1299
1754
|
displayName: string;
|
|
1300
1755
|
};
|
|
1301
1756
|
|
|
1302
|
-
|
|
1303
|
-
* TableCell component for rendering a styled table cell with optional icons and content.
|
|
1304
|
-
*
|
|
1305
|
-
* @param {TableCellProps} props - Props for the TableCell component you can see them in @components/tables/types/table.types.ts.
|
|
1306
|
-
* @returns {JSX.Element} The rendered table cell.
|
|
1307
|
-
*/
|
|
1308
|
-
export declare const TableCell: default_2.FC<TableCellProps>;
|
|
1757
|
+
export declare const TableBody: <T extends Record<string, unknown>>({ rows, className, rowClassName, cellClassName, }: TableBodyProps<T>) => JSX.Element;
|
|
1309
1758
|
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
size?: TableCellSize;
|
|
1313
|
-
align?: 'left' | 'center' | 'right';
|
|
1314
|
-
width?: string | number;
|
|
1315
|
-
truncate?: boolean;
|
|
1316
|
-
variant?: 'default' | 'numeric';
|
|
1759
|
+
declare interface TableBodyProps<T extends Record<string, unknown>> {
|
|
1760
|
+
rows: Row<T>[];
|
|
1317
1761
|
className?: string;
|
|
1762
|
+
rowClassName?: string | ((row: Row<T>) => string);
|
|
1763
|
+
cellClassName?: string | ((row: Row<T>) => string);
|
|
1318
1764
|
}
|
|
1319
1765
|
|
|
1320
|
-
export declare
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
truncate?: boolean;
|
|
1326
|
-
variant?: 'default' | 'numeric';
|
|
1766
|
+
export declare const TableCell: <T extends Record<string, unknown>>({ cell, rowClassName, }: TableCellProps<T>) => JSX.Element;
|
|
1767
|
+
|
|
1768
|
+
declare interface TableCellProps<T extends Record<string, unknown>> {
|
|
1769
|
+
cell: Cell<T, unknown>;
|
|
1770
|
+
rowClassName?: string;
|
|
1327
1771
|
}
|
|
1328
1772
|
|
|
1329
1773
|
export declare type TableCellSize = 'sm' | 'md' | 'lg';
|
|
1330
1774
|
|
|
1331
|
-
export declare interface
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
stickyHeader?: boolean;
|
|
1339
|
-
onSort?: (direction: SortDirection) => void;
|
|
1775
|
+
export declare interface TableClassNames<T> {
|
|
1776
|
+
wrapper?: string;
|
|
1777
|
+
table?: string;
|
|
1778
|
+
header?: string;
|
|
1779
|
+
body?: string;
|
|
1780
|
+
row?: string | ((row: Row<T>) => string);
|
|
1781
|
+
cell?: string | ((row: Row<T>) => string);
|
|
1340
1782
|
}
|
|
1341
1783
|
|
|
1342
1784
|
/**
|
|
1343
|
-
*
|
|
1344
|
-
*
|
|
1345
|
-
* @param {TableHeaderCellProps} props - The props for the TableHeaderCell component.
|
|
1346
|
-
* @returns {JSX.Element} The rendered table header cell.
|
|
1785
|
+
* Extended ColumnDef type that includes metadata
|
|
1347
1786
|
*/
|
|
1348
|
-
export declare
|
|
1787
|
+
export declare type TableColumnDef<T> = ColumnDef<T, unknown> & {
|
|
1788
|
+
meta?: ColumnMeta;
|
|
1789
|
+
};
|
|
1349
1790
|
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1791
|
+
/**
|
|
1792
|
+
* Table context to share state between components
|
|
1793
|
+
*/
|
|
1794
|
+
export declare interface TableContextType<T> {
|
|
1795
|
+
size: TableCellSize;
|
|
1796
|
+
variant: TableVariant;
|
|
1797
|
+
sorting: SortingState;
|
|
1798
|
+
setSorting: (state: SortingState) => void;
|
|
1799
|
+
columnFilters: ColumnFiltersState;
|
|
1800
|
+
setColumnFilters: (state: ColumnFiltersState) => void;
|
|
1801
|
+
getUniqueValues: (columnId: string) => unknown[];
|
|
1802
|
+
onRowClick?: (row: T) => void;
|
|
1803
|
+
}
|
|
1804
|
+
|
|
1805
|
+
export declare const TableHeader: <T extends Record<string, unknown>>({ headerGroups, stickyHeader, className, }: TableHeadProps<T>) => JSX.Element;
|
|
1806
|
+
|
|
1807
|
+
export declare const TableHeaderCell: <T extends Record<string, unknown>>({ header, }: TableHeaderCellProps<T>) => JSX.Element;
|
|
1808
|
+
|
|
1809
|
+
declare interface TableHeaderCellProps<T extends Record<string, unknown>> {
|
|
1810
|
+
header: Header_2<T, unknown>;
|
|
1360
1811
|
}
|
|
1361
1812
|
|
|
1362
|
-
export declare const
|
|
1813
|
+
export declare const TableHeaderRow: <T extends Record<string, unknown>>({ headerGroup, }: TableHeaderRowProps<T>) => JSX.Element;
|
|
1814
|
+
|
|
1815
|
+
declare interface TableHeaderRowProps<T extends Record<string, unknown>> {
|
|
1816
|
+
headerGroup: HeaderGroup<T>;
|
|
1817
|
+
}
|
|
1818
|
+
|
|
1819
|
+
declare interface TableHeadProps<T extends Record<string, unknown>> {
|
|
1820
|
+
headerGroups: HeaderGroup<T>[];
|
|
1821
|
+
stickyHeader?: boolean;
|
|
1822
|
+
className?: string;
|
|
1823
|
+
}
|
|
1363
1824
|
|
|
1364
|
-
|
|
1825
|
+
/**
|
|
1826
|
+
*
|
|
1827
|
+
* TablePagination component for paginating table data
|
|
1828
|
+
* @params TablePaginationProps
|
|
1829
|
+
* @returns JSX.Element
|
|
1830
|
+
*/
|
|
1831
|
+
export declare const TablePagination: ({ onPageChange, onPerPageChange, perPage, page, totalPages, totalRecords, rowsPerPageOptions, }: TablePaginationProps) => JSX.Element;
|
|
1832
|
+
|
|
1833
|
+
/**
|
|
1834
|
+
* Props for TablePagination component
|
|
1835
|
+
* @prop onPageChange - Callback when page changes
|
|
1836
|
+
* @prop onPerPageChange - Callback when rows per page changes
|
|
1837
|
+
* @prop perPage - Current rows per page
|
|
1838
|
+
* @prop page - Current active page
|
|
1839
|
+
* @prop totalPages - Total number of pages
|
|
1840
|
+
* @prop totalRecords - (Optional) Total number of records
|
|
1841
|
+
* @prop rowsPerPageOptions - (Optional) Options for rows per page selection
|
|
1842
|
+
*/
|
|
1843
|
+
export declare interface TablePaginationProps {
|
|
1844
|
+
onPageChange: (newPage: number) => void;
|
|
1845
|
+
onPerPageChange: (newPerPage: number) => void;
|
|
1846
|
+
perPage: number;
|
|
1847
|
+
page: number;
|
|
1848
|
+
totalPages: number;
|
|
1849
|
+
totalRecords?: number;
|
|
1850
|
+
rowsPerPageOptions?: SelectOption[];
|
|
1851
|
+
}
|
|
1365
1852
|
|
|
1366
|
-
|
|
1853
|
+
/**
|
|
1854
|
+
* Main Table component props
|
|
1855
|
+
*/
|
|
1856
|
+
export declare interface TableProps<T = unknown> {
|
|
1857
|
+
data: T[];
|
|
1367
1858
|
columns: TableColumnDef<T>[];
|
|
1368
|
-
rows: TableRowData<T>[];
|
|
1369
1859
|
size?: TableCellSize;
|
|
1370
1860
|
variant?: TableVariant;
|
|
1371
|
-
|
|
1372
|
-
tableClassName?: string;
|
|
1861
|
+
isLoading?: boolean;
|
|
1373
1862
|
stickyHeader?: boolean;
|
|
1374
|
-
|
|
1375
|
-
|
|
1863
|
+
maxHeight?: string | number;
|
|
1864
|
+
/**
|
|
1865
|
+
* Controlled sorting state
|
|
1866
|
+
* When provided, the table operates in controlled mode
|
|
1867
|
+
*/
|
|
1868
|
+
sorting?: SortingState;
|
|
1869
|
+
/**
|
|
1870
|
+
* Default sorting for uncontrolled mode
|
|
1871
|
+
* @default []
|
|
1872
|
+
*/
|
|
1873
|
+
defaultSorting?: SortingState;
|
|
1874
|
+
/**
|
|
1875
|
+
* Callback fired when sorting changes
|
|
1876
|
+
* Required for controlled mode, optional for uncontrolled
|
|
1877
|
+
*/
|
|
1878
|
+
onSortingChange?: (state: SortingState) => void;
|
|
1879
|
+
/**
|
|
1880
|
+
* Enable/disable sorting functionality
|
|
1881
|
+
* @default true
|
|
1882
|
+
*/
|
|
1883
|
+
enableSorting?: boolean;
|
|
1884
|
+
/**
|
|
1885
|
+
* Enable manual sorting mode (sorting handled by backend)
|
|
1886
|
+
* When true, the table will not sort data locally.
|
|
1887
|
+
* Data must be pre-sorted by the backend and passed via the 'data' prop.
|
|
1888
|
+
* The table will maintain sorting UI state and fire onSortingChange callbacks.
|
|
1889
|
+
* @default false
|
|
1890
|
+
*/
|
|
1891
|
+
manualSorting?: boolean;
|
|
1892
|
+
/**
|
|
1893
|
+
* Controlled column filters state
|
|
1894
|
+
* When provided, the table operates in controlled mode
|
|
1895
|
+
*/
|
|
1896
|
+
columnFilters?: ColumnFiltersState;
|
|
1897
|
+
/**
|
|
1898
|
+
* Default column filters for uncontrolled mode
|
|
1899
|
+
* @default []
|
|
1900
|
+
*/
|
|
1901
|
+
defaultColumnFilters?: ColumnFiltersState;
|
|
1902
|
+
/**
|
|
1903
|
+
* Callback fired when column filters change
|
|
1904
|
+
* Required for controlled mode, optional for uncontrolled
|
|
1905
|
+
*/
|
|
1906
|
+
onColumnFiltersChange?: (state: ColumnFiltersState) => void;
|
|
1907
|
+
/**
|
|
1908
|
+
* Enable/disable filtering functionality
|
|
1909
|
+
* @default true
|
|
1910
|
+
*/
|
|
1911
|
+
enableFiltering?: boolean;
|
|
1912
|
+
/**
|
|
1913
|
+
* Enable manual filtering mode (filtering handled by backend)
|
|
1914
|
+
* When true, the table will not filter data locally.
|
|
1915
|
+
* Data must be pre-filtered by the backend and passed via the 'data' prop.
|
|
1916
|
+
* The table will maintain filtering UI state and fire onColumnFiltersChange callbacks.
|
|
1917
|
+
* @default false
|
|
1918
|
+
*/
|
|
1919
|
+
manualFiltering?: boolean;
|
|
1920
|
+
onRowClick?: (row: T) => void;
|
|
1921
|
+
classNames?: TableClassNames<T>;
|
|
1922
|
+
getUniqueValues?: (columnId: string) => string[];
|
|
1376
1923
|
}
|
|
1377
1924
|
|
|
1378
|
-
export declare const
|
|
1925
|
+
export declare const TableRow: typeof TableRowComponent;
|
|
1379
1926
|
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
align?: 'left' | 'center' | 'right';
|
|
1385
|
-
width?: string | number;
|
|
1386
|
-
truncate?: boolean;
|
|
1387
|
-
variant?: 'default' | 'numeric';
|
|
1927
|
+
declare function TableRowComponent<T extends Record<string, unknown>>({ row, className, cellClassName, }: TableRowProps<T>): JSX.Element;
|
|
1928
|
+
|
|
1929
|
+
declare interface TableRowProps<T extends Record<string, unknown>> {
|
|
1930
|
+
row: Row<T>;
|
|
1388
1931
|
className?: string;
|
|
1932
|
+
cellClassName?: string;
|
|
1389
1933
|
}
|
|
1390
1934
|
|
|
1391
1935
|
export declare type TableVariant = 'default' | 'striped';
|
|
1392
1936
|
|
|
1393
|
-
export
|
|
1394
|
-
default: RuleSet<object>;
|
|
1395
|
-
striped: RuleSet<object>;
|
|
1396
|
-
};
|
|
1937
|
+
export { TanStackTableType }
|
|
1397
1938
|
|
|
1398
|
-
export declare const TermsAndConditions:
|
|
1939
|
+
export declare const TermsAndConditions: ({ isOpen, onAccept, onCancel, title, subtitle, content, bodyFooter, confirmationLabel, acceptLabel, cancelLabel, size, fullScreen, showCloseButton, closeOnBackdropClick, containerClassName, headerClassName, bodyClassName, footerClassName, initiallyConfirmed, onConfirmChange, }: TermsAndConditionsProps) => JSX.Element;
|
|
1399
1940
|
|
|
1400
1941
|
export declare interface TermsAndConditionsProps {
|
|
1401
1942
|
isOpen: boolean;
|
|
@@ -1403,8 +1944,8 @@ export declare interface TermsAndConditionsProps {
|
|
|
1403
1944
|
onCancel: () => void;
|
|
1404
1945
|
title: string;
|
|
1405
1946
|
subtitle?: string;
|
|
1406
|
-
content:
|
|
1407
|
-
bodyFooter?:
|
|
1947
|
+
content: ReactNode;
|
|
1948
|
+
bodyFooter?: ReactNode;
|
|
1408
1949
|
confirmationLabel?: string;
|
|
1409
1950
|
acceptLabel?: string;
|
|
1410
1951
|
cancelLabel?: string;
|
|
@@ -1428,7 +1969,7 @@ export { Text_2 as Text }
|
|
|
1428
1969
|
|
|
1429
1970
|
export declare const TextAreaInput: ForwardRefExoticComponent<TextAreaInputProps & RefAttributes<HTMLTextAreaElement>>;
|
|
1430
1971
|
|
|
1431
|
-
export declare interface TextAreaInputProps extends Omit<
|
|
1972
|
+
export declare interface TextAreaInputProps extends Omit<TextareaHTMLAttributes<HTMLTextAreaElement>, 'size'> {
|
|
1432
1973
|
size?: FormFieldSize;
|
|
1433
1974
|
hasError?: boolean;
|
|
1434
1975
|
disabled?: boolean;
|
|
@@ -1458,6 +1999,61 @@ declare type ToastProviderProps = ToasterProps & {
|
|
|
1458
1999
|
spinnerColor?: ColorKey_2;
|
|
1459
2000
|
};
|
|
1460
2001
|
|
|
2002
|
+
/**
|
|
2003
|
+
* Tooltip component to display contextual information on hover or click.
|
|
2004
|
+
*
|
|
2005
|
+
* @example
|
|
2006
|
+
* ```tsx
|
|
2007
|
+
* <Tooltip content="This is a tooltip" placement="top">
|
|
2008
|
+
* <button>Hover me</button>
|
|
2009
|
+
* </Tooltip>
|
|
2010
|
+
* ```
|
|
2011
|
+
*/
|
|
2012
|
+
export declare const Tooltip: {
|
|
2013
|
+
({ content, children, placement, trigger, className, arrowClassName, delay, showArrow, }: TooltipProps): JSX.Element;
|
|
2014
|
+
displayName: string;
|
|
2015
|
+
};
|
|
2016
|
+
|
|
2017
|
+
/**
|
|
2018
|
+
* Placement options for the tooltip
|
|
2019
|
+
*/
|
|
2020
|
+
export declare type TooltipPlacement = 'top' | 'bottom' | 'left' | 'right';
|
|
2021
|
+
|
|
2022
|
+
/**
|
|
2023
|
+
* Props for the Tooltip component
|
|
2024
|
+
*/
|
|
2025
|
+
export declare interface TooltipProps {
|
|
2026
|
+
content: ReactNode;
|
|
2027
|
+
children: ReactNode;
|
|
2028
|
+
placement?: TooltipPlacement;
|
|
2029
|
+
trigger?: TooltipTrigger;
|
|
2030
|
+
className?: string;
|
|
2031
|
+
arrowClassName?: string;
|
|
2032
|
+
delay?: number;
|
|
2033
|
+
showArrow?: boolean;
|
|
2034
|
+
}
|
|
2035
|
+
|
|
2036
|
+
/**
|
|
2037
|
+
* Trigger mechanism for showing/hiding the tooltip
|
|
2038
|
+
*/
|
|
2039
|
+
export declare type TooltipTrigger = 'hover' | 'click';
|
|
2040
|
+
|
|
2041
|
+
export declare const useColumnFilter: (columnId: string) => {
|
|
2042
|
+
selectedValues: string[];
|
|
2043
|
+
handleChange: (values: string[]) => void;
|
|
2044
|
+
};
|
|
2045
|
+
|
|
2046
|
+
/**
|
|
2047
|
+
* Custom hook to handle notification logic and state.
|
|
2048
|
+
* Returns computed values for notification display.
|
|
2049
|
+
*/
|
|
2050
|
+
export declare const useNotifications: ({ hasNotifications, notificationCount, }: Pick<NotificationButtonProps, "hasNotifications" | "notificationCount">) => {
|
|
2051
|
+
effectiveHasNotifications: boolean;
|
|
2052
|
+
displayCount: number | undefined;
|
|
2053
|
+
badgeLabel: string;
|
|
2054
|
+
bellAriaLabel: string;
|
|
2055
|
+
};
|
|
2056
|
+
|
|
1461
2057
|
/**
|
|
1462
2058
|
* User interface for the UserProfile component
|
|
1463
2059
|
*/
|
|
@@ -1469,17 +2065,194 @@ export declare interface User {
|
|
|
1469
2065
|
|
|
1470
2066
|
/**
|
|
1471
2067
|
* User menu item configuration
|
|
1472
|
-
|
|
1473
|
-
|
|
2068
|
+
* Defines a single item in the user profile dropdown menu.
|
|
2069
|
+
* @param id Unique identifier for the menu item
|
|
2070
|
+
* @param label Display text for the menu item
|
|
2071
|
+
* @param icon Icon component to display next to the label
|
|
2072
|
+
* @param onClick Function to call when the item is clicked
|
|
2073
|
+
* @param variant Optional styling variant ('default' or 'danger')
|
|
2074
|
+
*/
|
|
2075
|
+
export declare interface UserMenuItem {
|
|
1474
2076
|
id: string;
|
|
1475
2077
|
label: string;
|
|
1476
|
-
icon:
|
|
2078
|
+
icon: ReactNode | RemixiconComponentType;
|
|
1477
2079
|
onClick: () => void;
|
|
1478
2080
|
variant?: 'default' | 'danger';
|
|
1479
2081
|
}
|
|
1480
2082
|
|
|
2083
|
+
/**
|
|
2084
|
+
* UserProfile component with dropdown menu functionality.
|
|
2085
|
+
* Displays user avatar, name, role, and provides a dropdown menu with configurable actions.
|
|
2086
|
+
*/
|
|
2087
|
+
export declare const UserProfile: {
|
|
2088
|
+
({ user, onProfileClick, onLogout, menuItems, }: UserProfileProps): JSX.Element;
|
|
2089
|
+
displayName: string;
|
|
2090
|
+
};
|
|
2091
|
+
|
|
2092
|
+
/**
|
|
2093
|
+
* Props for the UserProfile component.
|
|
2094
|
+
* @param user The user object containing name and role information
|
|
2095
|
+
* @param onProfileClick Optional function to call when profile is clicked
|
|
2096
|
+
* @param onLogout Optional function to call when logout is selected
|
|
2097
|
+
* @param menuItems Optional array of custom menu items to display
|
|
2098
|
+
*/
|
|
2099
|
+
export declare interface UserProfileProps {
|
|
2100
|
+
user: User;
|
|
2101
|
+
onProfileClick?: () => void;
|
|
2102
|
+
onLogout?: () => void;
|
|
2103
|
+
menuItems?: UserMenuItem[];
|
|
2104
|
+
}
|
|
2105
|
+
|
|
1481
2106
|
export declare const useSidebar: () => SidebarContextValue;
|
|
1482
2107
|
|
|
2108
|
+
export declare const useTableContext: <T extends Record<string, unknown>>() => TableContextType<T>;
|
|
2109
|
+
|
|
2110
|
+
export declare const useTableData: <T extends Record<string, unknown>>({ data, columns, initialPage, initialPerPage, initialSorting, initialColumnFilters, }: UseTableDataProps<T>) => UseTableDataReturn<T>;
|
|
2111
|
+
|
|
2112
|
+
declare interface UseTableDataProps<T> {
|
|
2113
|
+
data: T[];
|
|
2114
|
+
columns: ColumnDef<T, unknown>[];
|
|
2115
|
+
initialPage?: number;
|
|
2116
|
+
initialPerPage?: number;
|
|
2117
|
+
initialSorting?: SortingState;
|
|
2118
|
+
initialColumnFilters?: ColumnFiltersState;
|
|
2119
|
+
}
|
|
2120
|
+
|
|
2121
|
+
declare interface UseTableDataReturn<T> {
|
|
2122
|
+
paginatedData: T[];
|
|
2123
|
+
processedData: T[];
|
|
2124
|
+
page: number;
|
|
2125
|
+
perPage: number;
|
|
2126
|
+
totalPages: number;
|
|
2127
|
+
totalRecords: number;
|
|
2128
|
+
filteredRecords: number;
|
|
2129
|
+
setPage: (page: number) => void;
|
|
2130
|
+
setPerPage: (perPage: number) => void;
|
|
2131
|
+
sorting: SortingState;
|
|
2132
|
+
setSorting: (sorting: SortingState) => void;
|
|
2133
|
+
columnFilters: ColumnFiltersState;
|
|
2134
|
+
setColumnFilters: (filters: ColumnFiltersState) => void;
|
|
2135
|
+
getUniqueValues: (columnId: string) => string[];
|
|
2136
|
+
}
|
|
2137
|
+
|
|
2138
|
+
/**
|
|
2139
|
+
* Hook to manage table column filtering state (controlled or uncontrolled)
|
|
2140
|
+
*
|
|
2141
|
+
* @example Uncontrolled mode
|
|
2142
|
+
* ```tsx
|
|
2143
|
+
* const { columnFiltersState, handleColumnFiltersChange } = useTableFiltering({
|
|
2144
|
+
* defaultColumnFilters: [{ id: 'status', value: ['Active'] }],
|
|
2145
|
+
* onColumnFiltersChange: (state) => console.log(state)
|
|
2146
|
+
* });
|
|
2147
|
+
* ```
|
|
2148
|
+
*
|
|
2149
|
+
* @example Controlled mode
|
|
2150
|
+
* ```tsx
|
|
2151
|
+
* const [filters, setFilters] = useState<ColumnFiltersState>([]);
|
|
2152
|
+
* const { columnFiltersState, handleColumnFiltersChange } = useTableFiltering({
|
|
2153
|
+
* columnFilters: filters,
|
|
2154
|
+
* onColumnFiltersChange: setFilters
|
|
2155
|
+
* });
|
|
2156
|
+
* ```
|
|
2157
|
+
*/
|
|
2158
|
+
export declare const useTableFiltering: ({ columnFilters: controlledFilters, defaultColumnFilters, onColumnFiltersChange, }: UseTableFilteringProps) => UseTableFilteringReturn;
|
|
2159
|
+
|
|
2160
|
+
declare interface UseTableFilteringProps {
|
|
2161
|
+
/**
|
|
2162
|
+
* Controlled column filters state (optional)
|
|
2163
|
+
* If provided, the component operates in controlled mode
|
|
2164
|
+
*/
|
|
2165
|
+
columnFilters?: ColumnFiltersState;
|
|
2166
|
+
/**
|
|
2167
|
+
* Default column filters state for uncontrolled mode
|
|
2168
|
+
* @default []
|
|
2169
|
+
*/
|
|
2170
|
+
defaultColumnFilters?: ColumnFiltersState;
|
|
2171
|
+
/**
|
|
2172
|
+
* Callback fired when column filters change
|
|
2173
|
+
* Required for controlled mode, optional for uncontrolled
|
|
2174
|
+
*/
|
|
2175
|
+
onColumnFiltersChange?: (columnFilters: ColumnFiltersState) => void;
|
|
2176
|
+
}
|
|
2177
|
+
|
|
2178
|
+
declare interface UseTableFilteringReturn {
|
|
2179
|
+
/**
|
|
2180
|
+
* Current column filters state (controlled or internal)
|
|
2181
|
+
*/
|
|
2182
|
+
columnFiltersState: ColumnFiltersState;
|
|
2183
|
+
/**
|
|
2184
|
+
* Handler for TanStack Table's onColumnFiltersChange
|
|
2185
|
+
*/
|
|
2186
|
+
handleColumnFiltersChange: (updater: Updater<ColumnFiltersState>) => void;
|
|
2187
|
+
/**
|
|
2188
|
+
* Whether the component is in controlled mode
|
|
2189
|
+
*/
|
|
2190
|
+
isControlled: boolean;
|
|
2191
|
+
/**
|
|
2192
|
+
* Manual setter for uncontrolled mode (useful for imperative actions)
|
|
2193
|
+
*/
|
|
2194
|
+
setColumnFilters: (columnFilters: ColumnFiltersState) => void;
|
|
2195
|
+
}
|
|
2196
|
+
|
|
2197
|
+
/**
|
|
2198
|
+
* Hook to manage table sorting state (controlled or uncontrolled)
|
|
2199
|
+
*
|
|
2200
|
+
* @example Uncontrolled mode
|
|
2201
|
+
* ```tsx
|
|
2202
|
+
* const { sortingState, handleSortingChange } = useTableSorting({
|
|
2203
|
+
* defaultSorting: [{ id: 'name', desc: false }],
|
|
2204
|
+
* onSortingChange: (state) => console.log(state)
|
|
2205
|
+
* });
|
|
2206
|
+
* ```
|
|
2207
|
+
*
|
|
2208
|
+
* @example Controlled mode
|
|
2209
|
+
* ```tsx
|
|
2210
|
+
* const [sorting, setSorting] = useState<SortingState>([]);
|
|
2211
|
+
* const { sortingState, handleSortingChange } = useTableSorting({
|
|
2212
|
+
* sorting,
|
|
2213
|
+
* onSortingChange: setSorting
|
|
2214
|
+
* });
|
|
2215
|
+
* ```
|
|
2216
|
+
*/
|
|
2217
|
+
export declare const useTableSorting: ({ sorting: controlledSorting, defaultSorting, onSortingChange, }: UseTableSortingProps) => UseTableSortingReturn;
|
|
2218
|
+
|
|
2219
|
+
declare interface UseTableSortingProps {
|
|
2220
|
+
/**
|
|
2221
|
+
* Controlled sorting state (optional)
|
|
2222
|
+
* If provided, the component operates in controlled mode
|
|
2223
|
+
*/
|
|
2224
|
+
sorting?: SortingState;
|
|
2225
|
+
/**
|
|
2226
|
+
* Default sorting state for uncontrolled mode
|
|
2227
|
+
* @default []
|
|
2228
|
+
*/
|
|
2229
|
+
defaultSorting?: SortingState;
|
|
2230
|
+
/**
|
|
2231
|
+
* Callback fired when sorting changes
|
|
2232
|
+
* Required for controlled mode, optional for uncontrolled
|
|
2233
|
+
*/
|
|
2234
|
+
onSortingChange?: (sorting: SortingState) => void;
|
|
2235
|
+
}
|
|
2236
|
+
|
|
2237
|
+
declare interface UseTableSortingReturn {
|
|
2238
|
+
/**
|
|
2239
|
+
* Current sorting state (controlled or internal)
|
|
2240
|
+
*/
|
|
2241
|
+
sortingState: SortingState;
|
|
2242
|
+
/**
|
|
2243
|
+
* Handler for TanStack Table's onSortingChange
|
|
2244
|
+
*/
|
|
2245
|
+
handleSortingChange: (updater: Updater<SortingState>) => void;
|
|
2246
|
+
/**
|
|
2247
|
+
* Whether the component is in controlled mode
|
|
2248
|
+
*/
|
|
2249
|
+
isControlled: boolean;
|
|
2250
|
+
/**
|
|
2251
|
+
* Manual setter for uncontrolled mode (useful for imperative actions)
|
|
2252
|
+
*/
|
|
2253
|
+
setSorting: (sorting: SortingState) => void;
|
|
2254
|
+
}
|
|
2255
|
+
|
|
1483
2256
|
/**
|
|
1484
2257
|
* Validates if a complete code meets certain criteria
|
|
1485
2258
|
*
|
|
@@ -1490,15 +2263,15 @@ export declare const useSidebar: () => SidebarContextValue;
|
|
|
1490
2263
|
*/
|
|
1491
2264
|
export declare const validateCode: (code: string, length: number, type?: "text" | "number") => boolean;
|
|
1492
2265
|
|
|
1493
|
-
declare type Variant = 'rotate' | 'sweep';
|
|
2266
|
+
export declare type Variant = 'rotate' | 'sweep';
|
|
1494
2267
|
|
|
1495
2268
|
/**
|
|
1496
2269
|
* Interfaz base para componentes que soportan iconos a la izquierda y derecha
|
|
1497
2270
|
* Puede ser extendida por cualquier componente que necesite funcionalidad de iconos
|
|
1498
2271
|
*/
|
|
1499
2272
|
export declare interface WithIconsProps {
|
|
1500
|
-
leftIcon?:
|
|
1501
|
-
rightIcon?:
|
|
2273
|
+
leftIcon?: ReactNode | RemixiconComponentType;
|
|
2274
|
+
rightIcon?: ReactNode | RemixiconComponentType;
|
|
1502
2275
|
iconSize?: IconSizes | string | number;
|
|
1503
2276
|
iconColor?: string;
|
|
1504
2277
|
}
|