@ctlyst.id/internal-ui 5.1.0 → 5.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +5 -1
- package/dist/index.d.ts +5 -1
- package/dist/index.js +768 -692
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +142 -66
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
@@ -7,7 +7,7 @@ import { SystemStyleObject, HTMLChakraProps, ThemingProps, ColorMode } from '@ch
|
|
7
7
|
import * as React$1 from 'react';
|
8
8
|
import React__default, { PropsWithChildren, ReactNode, FC } from 'react';
|
9
9
|
import * as _tanstack_react_table from '@tanstack/react-table';
|
10
|
-
import { ColumnDef, RowSelectionState, OnChangeFn, SortingState, ColumnPinningState, RowSelectionInstance } from '@tanstack/react-table';
|
10
|
+
import { ColumnDef, RowSelectionState, OnChangeFn, SortingState, ColumnPinningState, RowSelectionInstance, Row } from '@tanstack/react-table';
|
11
11
|
import { DatePickerProps } from 'react-datepicker';
|
12
12
|
import { IconType } from 'react-icons/lib';
|
13
13
|
import * as react_select from 'react-select';
|
@@ -162,6 +162,7 @@ interface CheckboxComponentProps extends CheckboxProps, PropsWithChildren {
|
|
162
162
|
errorText?: string;
|
163
163
|
boxProps?: BoxProps;
|
164
164
|
animated?: boolean;
|
165
|
+
throttleTime?: number;
|
165
166
|
}
|
166
167
|
declare const CheckboxComponent: _chakra_ui_react.ComponentWithAs<"input", CheckboxComponentProps>;
|
167
168
|
|
@@ -260,6 +261,8 @@ interface DataTableProps<T> {
|
|
260
261
|
disabledRow?: (row: T) => boolean;
|
261
262
|
highlightedRow?: (row: T) => boolean;
|
262
263
|
highlightRowColor?: BackgroundProps['bg'];
|
264
|
+
/** paddingRowX in px */
|
265
|
+
paddingRowX?: number;
|
263
266
|
}
|
264
267
|
declare const isCellDisabled: (row: DisabledRowData, cellId: string) => boolean;
|
265
268
|
type DataTableRefs<T> = Pick<RowSelectionInstance<T>, 'toggleAllRowsSelected'>;
|
@@ -268,6 +271,7 @@ declare const useDataTable: <T>({ columns, dataSource, withSelectedRow, onSelect
|
|
268
271
|
action: React$1.MutableRefObject<string>;
|
269
272
|
toggleAllRowsSelected: (value?: boolean | undefined) => void;
|
270
273
|
generateColumn: () => ColumnDef<T>[];
|
274
|
+
throttleRowClick: (val: Row<T>) => void;
|
271
275
|
};
|
272
276
|
declare const _default: <T>(props: DataTableProps<T> & {
|
273
277
|
ref?: React$1.Ref<DataTableRefs<T>>;
|
package/dist/index.d.ts
CHANGED
@@ -7,7 +7,7 @@ import { SystemStyleObject, HTMLChakraProps, ThemingProps, ColorMode } from '@ch
|
|
7
7
|
import * as React$1 from 'react';
|
8
8
|
import React__default, { PropsWithChildren, ReactNode, FC } from 'react';
|
9
9
|
import * as _tanstack_react_table from '@tanstack/react-table';
|
10
|
-
import { ColumnDef, RowSelectionState, OnChangeFn, SortingState, ColumnPinningState, RowSelectionInstance } from '@tanstack/react-table';
|
10
|
+
import { ColumnDef, RowSelectionState, OnChangeFn, SortingState, ColumnPinningState, RowSelectionInstance, Row } from '@tanstack/react-table';
|
11
11
|
import { DatePickerProps } from 'react-datepicker';
|
12
12
|
import { IconType } from 'react-icons/lib';
|
13
13
|
import * as react_select from 'react-select';
|
@@ -162,6 +162,7 @@ interface CheckboxComponentProps extends CheckboxProps, PropsWithChildren {
|
|
162
162
|
errorText?: string;
|
163
163
|
boxProps?: BoxProps;
|
164
164
|
animated?: boolean;
|
165
|
+
throttleTime?: number;
|
165
166
|
}
|
166
167
|
declare const CheckboxComponent: _chakra_ui_react.ComponentWithAs<"input", CheckboxComponentProps>;
|
167
168
|
|
@@ -260,6 +261,8 @@ interface DataTableProps<T> {
|
|
260
261
|
disabledRow?: (row: T) => boolean;
|
261
262
|
highlightedRow?: (row: T) => boolean;
|
262
263
|
highlightRowColor?: BackgroundProps['bg'];
|
264
|
+
/** paddingRowX in px */
|
265
|
+
paddingRowX?: number;
|
263
266
|
}
|
264
267
|
declare const isCellDisabled: (row: DisabledRowData, cellId: string) => boolean;
|
265
268
|
type DataTableRefs<T> = Pick<RowSelectionInstance<T>, 'toggleAllRowsSelected'>;
|
@@ -268,6 +271,7 @@ declare const useDataTable: <T>({ columns, dataSource, withSelectedRow, onSelect
|
|
268
271
|
action: React$1.MutableRefObject<string>;
|
269
272
|
toggleAllRowsSelected: (value?: boolean | undefined) => void;
|
270
273
|
generateColumn: () => ColumnDef<T>[];
|
274
|
+
throttleRowClick: (val: Row<T>) => void;
|
271
275
|
};
|
272
276
|
declare const _default: <T>(props: DataTableProps<T> & {
|
273
277
|
ref?: React$1.Ref<DataTableRefs<T>>;
|