@true-engineering/true-react-common-ui-kit 4.0.0-alpha24 → 4.0.0-alpha26
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/components/FlexibleTable/FlexibleTable.d.ts +1 -1
- package/dist/components/FlexibleTable/types.d.ts +12 -4
- package/dist/hooks/index.d.ts +1 -0
- package/dist/hooks/use-intersection-ref.d.ts +8 -0
- package/dist/true-react-common-ui-kit.js +195 -114
- package/dist/true-react-common-ui-kit.js.map +1 -1
- package/dist/true-react-common-ui-kit.umd.cjs +195 -114
- package/dist/true-react-common-ui-kit.umd.cjs.map +1 -1
- package/package.json +1 -1
- package/src/components/FlexibleTable/FlexibleTable.tsx +27 -51
- package/src/components/FlexibleTable/types.ts +12 -4
- package/src/components/MultiSelectList/MultiSelectList.tsx +15 -11
- package/src/components/WithPopup/WithPopup.tsx +3 -5
- package/src/hooks/index.ts +1 -0
- package/src/hooks/use-intersection-ref.ts +30 -0
|
@@ -30,4 +30,4 @@ export interface IFlexibleTableProps<Row extends ITableRow, HeaderContent extend
|
|
|
30
30
|
/** @default false */
|
|
31
31
|
isExpandableRowComponentInitiallyOpen?: boolean | ((row: Row, index: number) => boolean);
|
|
32
32
|
}
|
|
33
|
-
export declare function FlexibleTable<Row extends ITableRow, HeaderContent extends IHeaderContent<Row> = IHeaderContent<Row>, UniqueField extends keyof Row = keyof Row>({ content, headerContent, config, enabledColumns, activeRows, uniqueField, isLoading, isFirstColumnSticky, isHorizontallyScrollable, isRowFocusable, infinityScrollConfig, renderMode, refForScroll, nothingFoundContent, data, testId, tweakStyles, shouldRenderHeader, onHeadClick, isExpandableRowComponentInitiallyOpen: isRowInitiallyOpen, ...restProps }: IFlexibleTableProps<Row, HeaderContent, UniqueField>): JSX.Element;
|
|
33
|
+
export declare function FlexibleTable<Row extends ITableRow, HeaderContent extends IHeaderContent<Row> = IHeaderContent<Row>, UniqueField extends keyof Row = keyof Row>({ content, headerContent, config, enabledColumns, activeRows, uniqueField, isLoading, isFirstColumnSticky, isHorizontallyScrollable, isRowFocusable, infinityScrollConfig: infinityScrollConfigDeprecated, renderMode, refForScroll, nothingFoundContent, data, testId, tweakStyles, shouldRenderHeader, onHeadClick, isExpandableRowComponentInitiallyOpen: isRowInitiallyOpen, ...restProps }: IFlexibleTableProps<Row, HeaderContent, UniqueField>): JSX.Element;
|
|
@@ -44,11 +44,19 @@ export type IFlexibleTableConfigType<Values extends ITableRow, HeaderContent ext
|
|
|
44
44
|
[Key in keyof Values]?: IFlexibleTableRowConfig<Values, Key, HeaderContent>;
|
|
45
45
|
};
|
|
46
46
|
export interface IInfinityScrollConfig {
|
|
47
|
-
|
|
48
|
-
totalPages: number;
|
|
47
|
+
isEnabled?: boolean;
|
|
49
48
|
isLoading: boolean;
|
|
50
|
-
|
|
51
|
-
|
|
49
|
+
onInfinityScroll: {
|
|
50
|
+
(_: never): void;
|
|
51
|
+
/** @deprecated use activePage directly */
|
|
52
|
+
(skip: number): void;
|
|
53
|
+
};
|
|
54
|
+
/** @deprecated use activePage in onInfinityScroll */
|
|
55
|
+
activePage?: number;
|
|
56
|
+
/** @deprecated use isEnabled */
|
|
57
|
+
isLastPage?: boolean;
|
|
58
|
+
/** @deprecated use isEnabled */
|
|
59
|
+
totalPages?: number;
|
|
52
60
|
}
|
|
53
61
|
export interface INestedComponent<T extends PropertyKey = string> {
|
|
54
62
|
isOpen: boolean;
|
package/dist/hooks/index.d.ts
CHANGED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { RefCallback } from 'react';
|
|
2
|
+
export interface IInsertionRefOptions {
|
|
3
|
+
/** @default false */
|
|
4
|
+
isDisabled?: boolean;
|
|
5
|
+
onIntersection?: VoidFunction;
|
|
6
|
+
onIntersectionEnd?: VoidFunction;
|
|
7
|
+
}
|
|
8
|
+
export declare const useIntersectionRef: (options?: IInsertionRefOptions) => RefCallback<Element>;
|