@sellgar/kit 0.0.171 → 0.0.173
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.css +1 -1
- package/dist/index.js +4843 -4697
- package/package.json +6 -6
- package/types/components/table/components/get-pinned-styles.hook.d.ts +19 -0
- package/types/components/table/components/tbody/cell/cell.context.d.ts +9 -0
- package/types/components/table/components/tbody/cell/cell.d.ts +10 -0
- package/types/components/table/components/tbody/cell/index.d.ts +2 -0
- package/types/components/table/components/tbody/index.d.ts +1 -0
- package/types/components/table/components/tbody/tbody.d.ts +4 -0
- package/types/components/table/components/thead/cell/cell.d.ts +10 -0
- package/types/components/table/components/thead/cell/index.d.ts +1 -0
- package/types/components/table/components/thead/index.d.ts +1 -0
- package/types/components/table/components/thead/thead.d.ts +2 -0
- package/types/components/table/configuration/cell/cell.d.ts +9 -0
- package/types/components/table/configuration/cell/index.d.ts +2 -0
- package/types/components/table/configuration/column/column.d.ts +18 -0
- package/types/components/table/configuration/column/index.d.ts +2 -0
- package/types/components/table/configuration/create-columns-config.d.ts +16 -0
- package/types/components/table/configuration/create-data-nodes.d.ts +2 -0
- package/types/components/table/configuration/create-expand-config.d.ts +6 -0
- package/types/components/table/configuration/create-grid-template.hook.d.ts +2 -0
- package/types/components/table/configuration/expand/expand.d.ts +8 -0
- package/types/components/table/configuration/get-columns-width.hook.d.ts +3 -0
- package/types/components/table/configuration/head/head.d.ts +9 -0
- package/types/components/table/configuration/head/index.d.ts +2 -0
- package/types/components/table/feature/expand/expand.trigger.d.ts +6 -0
- package/types/components/table/feature/expand/hooks/expanded.hook.d.ts +5 -0
- package/types/components/table/feature/expand/index.d.ts +2 -0
- package/types/components/table/feature/select/cell/cell.d.ts +6 -0
- package/types/components/table/feature/select/cell/index.d.ts +1 -0
- package/types/components/table/feature/select/compare-columns-config.d.ts +2 -0
- package/types/components/table/feature/select/head/head.d.ts +2 -0
- package/types/components/table/feature/select/head/index.d.ts +1 -0
- package/types/components/table/feature/select/index.d.ts +5 -0
- package/types/components/table/feature/select/select.context.d.ts +14 -0
- package/types/components/table/feature/select/select.provider.d.ts +6 -0
- package/types/components/table/feature/sort/arrow/arrow.d.ts +2 -0
- package/types/components/table/feature/sort/arrow/index.d.ts +1 -0
- package/types/components/table/feature/sort/index.d.ts +3 -0
- package/types/components/table/feature/sort/sort.context.d.ts +8 -0
- package/types/components/table/feature/sort/sort.provider.d.ts +10 -0
- package/types/components/table/feature/tree/cell/cell.d.ts +5 -0
- package/types/components/table/feature/tree/cell/index.d.ts +1 -0
- package/types/components/table/feature/tree/compare-columns-config.d.ts +2 -0
- package/types/components/table/feature/tree/head/head.d.ts +2 -0
- package/types/components/table/feature/tree/head/index.d.ts +1 -0
- package/types/components/table/feature/tree/index.d.ts +5 -0
- package/types/components/table/feature/tree/tree.context.d.ts +6 -0
- package/types/components/table/feature/tree/tree.provider.d.ts +5 -0
- package/types/components/table/index.d.ts +2 -7
- package/types/components/table/table.context.d.ts +14 -9
- package/types/components/table/table.d.ts +33 -7
- package/types/components/table3/table-rows/table-row.context.d.ts +2 -0
- package/types/components/table4/components/get-pinned-styles.d.ts +13 -0
- package/types/components/table4/components/get-pinned-styles.hook.d.ts +13 -0
- package/types/components/table4/components/tbody/cell/cell.context.d.ts +4 -0
- package/types/components/table4/components/tbody/cell/cell.d.ts +10 -0
- package/types/components/table4/components/tbody/cell/index.d.ts +2 -0
- package/types/components/table4/components/tbody/index.d.ts +1 -0
- package/types/components/table4/components/tbody/tbody.d.ts +2 -0
- package/types/components/table4/components/thead/cell/cell.d.ts +10 -0
- package/types/components/table4/components/thead/cell/index.d.ts +1 -0
- package/types/components/table4/components/thead/index.d.ts +1 -0
- package/types/components/table4/components/thead/thead.d.ts +2 -0
- package/types/components/table4/configuration/cell/cell.d.ts +8 -0
- package/types/components/table4/configuration/cell/index.d.ts +2 -0
- package/types/components/table4/configuration/column/column.d.ts +17 -0
- package/types/components/table4/configuration/column/index.d.ts +2 -0
- package/types/components/table4/configuration/create-columns-config.d.ts +13 -0
- package/types/components/table4/configuration/create-data-nodes.d.ts +4 -0
- package/types/components/table4/configuration/create-grid-template.hook.d.ts +2 -0
- package/types/components/table4/configuration/get-columns-width.hook.d.ts +3 -0
- package/types/components/table4/configuration/head/head.d.ts +9 -0
- package/types/components/table4/configuration/head/index.d.ts +2 -0
- package/types/components/table4/feature/select/cell/cell.d.ts +7 -0
- package/types/components/table4/feature/select/cell/index.d.ts +1 -0
- package/types/components/table4/feature/select/compare-columns-config.d.ts +2 -0
- package/types/components/table4/feature/select/head/head.d.ts +2 -0
- package/types/components/table4/feature/select/head/index.d.ts +1 -0
- package/types/components/table4/feature/select/index.d.ts +5 -0
- package/types/components/table4/feature/select/select.context.d.ts +13 -0
- package/types/components/table4/feature/select/select.provider.d.ts +7 -0
- package/types/components/table4/feature/sort/arrow/arrow.d.ts +2 -0
- package/types/components/table4/feature/sort/arrow/index.d.ts +1 -0
- package/types/components/table4/feature/sort/index.d.ts +3 -0
- package/types/components/table4/feature/sort/sort.context.d.ts +7 -0
- package/types/components/table4/feature/sort/sort.provider.d.ts +7 -0
- package/types/components/table4/feature/tree/cell/cell.d.ts +5 -0
- package/types/components/table4/feature/tree/cell/index.d.ts +1 -0
- package/types/components/table4/feature/tree/compare-columns-config.d.ts +2 -0
- package/types/components/table4/feature/tree/head/head.d.ts +2 -0
- package/types/components/table4/feature/tree/head/index.d.ts +1 -0
- package/types/components/table4/feature/tree/index.d.ts +5 -0
- package/types/components/table4/feature/tree/tree.context.d.ts +5 -0
- package/types/components/table4/feature/tree/tree.provider.d.ts +5 -0
- package/types/components/table4/get-columns-width.hook.d.ts +3 -0
- package/types/components/table4/index.d.ts +2 -0
- package/types/components/table4/select/index.d.ts +3 -0
- package/types/components/table4/select/row-checkbox/index.d.ts +1 -0
- package/types/components/table4/select/row-checkbox/row-checkbox.d.ts +6 -0
- package/types/components/table4/select/select.context.d.ts +14 -0
- package/types/components/table4/select/select.provider.d.ts +6 -0
- package/types/components/table4/select/title-checkbox/index.d.ts +1 -0
- package/types/components/table4/select/title-checkbox/title-checkbox.d.ts +2 -0
- package/types/components/table4/table-cell/index.d.ts +2 -0
- package/types/components/table4/table-cell/table-cell.d.ts +10 -0
- package/types/components/table4/table-rows/cell/cell.context.d.ts +7 -0
- package/types/components/table4/table-rows/cell/cell.d.ts +8 -0
- package/types/components/table4/table-rows/cell/cell.provider.d.ts +7 -0
- package/types/components/table4/table-rows/cell/hook/cell-data.hook.d.ts +3 -0
- package/types/components/table4/table-rows/cell/index.d.ts +3 -0
- package/types/components/table4/table-rows/index.d.ts +1 -0
- package/types/components/table4/table-rows/row/index.d.ts +1 -0
- package/types/components/table4/table-rows/row/row.d.ts +7 -0
- package/types/components/table4/table-rows/table-row.context.d.ts +11 -0
- package/types/components/table4/table-rows/table-row.provider.d.ts +8 -0
- package/types/components/table4/table-rows/table-rows.d.ts +10 -0
- package/types/components/table4/table.context.d.ts +10 -0
- package/types/components/table4/table.d.ts +39 -0
- package/types/components/table4/tree/index.d.ts +3 -0
- package/types/components/table4/tree/row-arrow/index.d.ts +1 -0
- package/types/components/table4/tree/row-arrow/row-arrow.d.ts +5 -0
- package/types/components/table4/tree/title-arrow/index.d.ts +1 -0
- package/types/components/table4/tree/title-arrow/title-arrow.d.ts +2 -0
- package/types/components/table4/tree/tree.context.d.ts +6 -0
- package/types/index.d.ts +1 -1
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sellgar/kit",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.173",
|
|
5
5
|
"description": "Sellgar kit",
|
|
6
6
|
"main": "./dist/index.js",
|
|
7
7
|
"module": "./dist/index.js",
|
|
@@ -34,14 +34,14 @@
|
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@emotion/react": "11.14.0",
|
|
37
|
-
"@floating-ui/dom": "1.7.
|
|
38
|
-
"@floating-ui/react": "0.27.
|
|
37
|
+
"@floating-ui/dom": "1.7.5",
|
|
38
|
+
"@floating-ui/react": "0.27.17",
|
|
39
39
|
"@react-input/mask": "2.0.4",
|
|
40
40
|
"@react-input/number-format": "2.0.3",
|
|
41
41
|
"classnames": "2.5.1",
|
|
42
42
|
"date-fns": "4.1.0",
|
|
43
43
|
"moment": "2.30.1",
|
|
44
|
-
"overlayscrollbars": "2.
|
|
44
|
+
"overlayscrollbars": "2.14.0",
|
|
45
45
|
"overlayscrollbars-react": "0.5.6",
|
|
46
46
|
"react-baron": "3.0.0",
|
|
47
47
|
"react-slider": "2.0.6"
|
|
@@ -59,9 +59,9 @@
|
|
|
59
59
|
}
|
|
60
60
|
},
|
|
61
61
|
"devDependencies": {
|
|
62
|
-
"@storybook/react-vite": "10.
|
|
62
|
+
"@storybook/react-vite": "10.2.7",
|
|
63
63
|
"@types/react-slider": "1.3.6",
|
|
64
|
-
"@vitejs/plugin-react": "5.1.
|
|
64
|
+
"@vitejs/plugin-react": "5.1.3",
|
|
65
65
|
"typescript": "5.9.3",
|
|
66
66
|
"vite": "7.3.1",
|
|
67
67
|
"vite-plugin-dts": "4.5.4",
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export declare const useGetPinnedStyles: <T>(columnIndex: number) => {
|
|
2
|
+
left?: undefined;
|
|
3
|
+
zIndex?: undefined;
|
|
4
|
+
borderRight?: undefined;
|
|
5
|
+
right?: undefined;
|
|
6
|
+
borderLeft?: undefined;
|
|
7
|
+
} | {
|
|
8
|
+
left: string;
|
|
9
|
+
zIndex: number;
|
|
10
|
+
borderRight: string | undefined;
|
|
11
|
+
right?: undefined;
|
|
12
|
+
borderLeft?: undefined;
|
|
13
|
+
} | {
|
|
14
|
+
right: string;
|
|
15
|
+
zIndex: number;
|
|
16
|
+
borderLeft: string | undefined;
|
|
17
|
+
left?: undefined;
|
|
18
|
+
borderRight?: undefined;
|
|
19
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { INode } from '../../../table.tsx';
|
|
3
|
+
interface IContext<T> {
|
|
4
|
+
data: T;
|
|
5
|
+
deps: number;
|
|
6
|
+
}
|
|
7
|
+
export declare const createContext: <T>() => React.Context<IContext<T>>;
|
|
8
|
+
export declare const useCellData: <T extends INode>() => IContext<T>;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
interface IProps<T> {
|
|
3
|
+
originIndex: number;
|
|
4
|
+
align?: 'left' | 'center' | 'right';
|
|
5
|
+
collapse?: boolean;
|
|
6
|
+
data: T;
|
|
7
|
+
className?: string;
|
|
8
|
+
}
|
|
9
|
+
export declare const Cell: <T>(props: React.PropsWithChildren<IProps<T>>) => React.JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TBody } from './tbody.tsx';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ISort } from '../../../configuration/column';
|
|
3
|
+
interface IProps {
|
|
4
|
+
originIndex: number;
|
|
5
|
+
align?: 'left' | 'center' | 'right';
|
|
6
|
+
collapse?: boolean;
|
|
7
|
+
sort?: ISort;
|
|
8
|
+
}
|
|
9
|
+
export declare const Cell: (props: React.PropsWithChildren<IProps>) => React.JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Cell } from './cell.tsx';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { THead } from './thead.tsx';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export interface IProps {
|
|
3
|
+
className?: string;
|
|
4
|
+
}
|
|
5
|
+
interface ITableCellPropsWithDisplayName extends React.FC<React.PropsWithChildren<IProps>> {
|
|
6
|
+
displayName: string;
|
|
7
|
+
}
|
|
8
|
+
export declare const Cell: ITableCellPropsWithDisplayName;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export interface ISort {
|
|
3
|
+
directionDefault?: 'asc' | 'desc';
|
|
4
|
+
onToggle(direction?: 'asc' | 'desc'): void;
|
|
5
|
+
onReset?(): void;
|
|
6
|
+
}
|
|
7
|
+
export interface IProps {
|
|
8
|
+
width?: number;
|
|
9
|
+
align?: 'left' | 'center' | 'right';
|
|
10
|
+
pinLeft?: boolean;
|
|
11
|
+
pinRight?: boolean;
|
|
12
|
+
sort?: ISort;
|
|
13
|
+
}
|
|
14
|
+
interface IColumnPropsWithDisplayName extends React.FC<React.PropsWithChildren<IProps>> {
|
|
15
|
+
displayName: string;
|
|
16
|
+
}
|
|
17
|
+
export declare const Column: IColumnPropsWithDisplayName;
|
|
18
|
+
export {};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ISort } from './column';
|
|
3
|
+
import { INode } from '../table.tsx';
|
|
4
|
+
export interface IConfigColumn<T> {
|
|
5
|
+
label: React.ReactNode;
|
|
6
|
+
align?: 'left' | 'center' | 'right';
|
|
7
|
+
sort?: ISort;
|
|
8
|
+
width?: number;
|
|
9
|
+
collapse?: boolean;
|
|
10
|
+
pinLeft?: boolean;
|
|
11
|
+
pinRight?: boolean;
|
|
12
|
+
pinSource?: 'user' | 'system';
|
|
13
|
+
cellClassName?: string;
|
|
14
|
+
renderCell: (nodes: T) => React.ReactNode;
|
|
15
|
+
}
|
|
16
|
+
export declare const createColumnConfig: <T extends INode>(children: React.ReactNode) => IConfigColumn<T>[];
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { INode } from '../table.tsx';
|
|
3
|
+
export interface IConfigExpand<T> {
|
|
4
|
+
renderExpanded: (node: T) => React.ReactNode;
|
|
5
|
+
}
|
|
6
|
+
export declare const createExpandConfig: <T extends INode>(children: React.ReactNode) => IConfigExpand<T> | null;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export interface IExpandProps {
|
|
3
|
+
}
|
|
4
|
+
interface IExpandPropsWithDisplayName extends React.FC<React.PropsWithChildren<IExpandProps>> {
|
|
5
|
+
displayName: string;
|
|
6
|
+
}
|
|
7
|
+
export declare const Expand: IExpandPropsWithDisplayName;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Cell } from './cell.tsx';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Head } from './head.tsx';
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
interface IContext<T> {
|
|
3
|
+
isSelectedAll: boolean;
|
|
4
|
+
isIndeterminate: boolean;
|
|
5
|
+
selectedItems: T[];
|
|
6
|
+
hasSelected: (item: T) => boolean;
|
|
7
|
+
addItem: (item: T) => void;
|
|
8
|
+
deleteItem: (item: T) => void;
|
|
9
|
+
selectAll: () => void;
|
|
10
|
+
deleteAll: () => void;
|
|
11
|
+
}
|
|
12
|
+
export declare const createContext: <T>() => React.Context<IContext<T>>;
|
|
13
|
+
export declare const useContext: <T>() => IContext<T>;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Arrow } from './arrow.tsx';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
interface IProps {
|
|
3
|
+
directionDefault?: 'asc' | 'desc';
|
|
4
|
+
onToggle?(direction?: 'asc' | 'desc'): void;
|
|
5
|
+
isActive?: boolean;
|
|
6
|
+
onActivate?(): void;
|
|
7
|
+
onReset?(): void;
|
|
8
|
+
}
|
|
9
|
+
export declare const SortProvider: (props: React.PropsWithChildren<IProps>) => React.JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Cell } from './cell.tsx';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Head } from './head.tsx';
|
|
@@ -1,8 +1,3 @@
|
|
|
1
1
|
export { Table } from './table.tsx';
|
|
2
|
-
export {
|
|
3
|
-
export {
|
|
4
|
-
export { context as rowContext } from './row';
|
|
5
|
-
export { context as cellContext } from './cell';
|
|
6
|
-
export { useCellData } from './cell/hook/useCellData.ts';
|
|
7
|
-
export { type ITitleProps } from './title';
|
|
8
|
-
export { type ICellProps } from './cell';
|
|
2
|
+
export { useRowExpanded } from './feature/expand';
|
|
3
|
+
export { useCellData } from './components/tbody/cell';
|
|
@@ -1,11 +1,16 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
import { IData } from './table.tsx';
|
|
3
|
+
import { IConfigColumn } from './configuration/create-columns-config.ts';
|
|
4
|
+
interface IContext<T> {
|
|
5
|
+
data: IData<T>;
|
|
6
|
+
columns: IConfigColumn<T>[];
|
|
7
|
+
columnsWidth: number[];
|
|
8
|
+
expand?: {
|
|
9
|
+
isExpanded(id: string | number): boolean;
|
|
10
|
+
toggle(node: T): void;
|
|
11
|
+
renderExpanded(node: T): React.ReactNode;
|
|
12
|
+
};
|
|
5
13
|
}
|
|
6
|
-
export
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
}
|
|
10
|
-
export declare const context: React.Context<IContext<any>>;
|
|
11
|
-
export declare const Provider: React.Provider<IContext<any>>;
|
|
14
|
+
export declare const createContext: <T>() => React.Context<IContext<T>>;
|
|
15
|
+
export declare const useContext: <T>() => IContext<T>;
|
|
16
|
+
export {};
|
|
@@ -1,12 +1,38 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
|
|
2
|
+
import { Cell } from './configuration/cell';
|
|
3
|
+
import { Head } from './configuration/head';
|
|
4
|
+
import { Column } from './configuration/column';
|
|
5
|
+
import { Expand } from './configuration/expand/expand';
|
|
6
|
+
import { ExpandTrigger } from './feature/expand';
|
|
7
|
+
export interface INode {
|
|
8
|
+
id: string | number;
|
|
9
|
+
nodes?: INode[];
|
|
10
|
+
[prop: string]: any;
|
|
11
|
+
}
|
|
12
|
+
export interface IData<T> {
|
|
13
|
+
nodes: T[];
|
|
14
|
+
}
|
|
15
|
+
interface ITreeProps<T> {
|
|
16
|
+
isUse: boolean;
|
|
3
17
|
accessor: keyof T;
|
|
4
|
-
defaultExpanded?: boolean;
|
|
5
18
|
}
|
|
6
|
-
interface
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
19
|
+
interface ISelectProps<T> {
|
|
20
|
+
isUse: boolean;
|
|
21
|
+
onSelect(nodes: T[]): void;
|
|
22
|
+
}
|
|
23
|
+
interface IProps<T extends INode> {
|
|
24
|
+
data: IData<T>;
|
|
25
|
+
tree?: ITreeProps<T>;
|
|
26
|
+
select?: ISelectProps<T>;
|
|
27
|
+
isBordered?: boolean;
|
|
10
28
|
}
|
|
11
|
-
export declare const
|
|
29
|
+
export declare const TableComponent: <T extends INode>(props: React.PropsWithChildren<IProps<T>>) => React.JSX.Element;
|
|
30
|
+
type TTable = typeof TableComponent & {
|
|
31
|
+
Column: typeof Column;
|
|
32
|
+
Head: typeof Head;
|
|
33
|
+
Cell: typeof Cell;
|
|
34
|
+
Expand: typeof Expand;
|
|
35
|
+
ExpandTrigger: typeof ExpandTrigger;
|
|
36
|
+
};
|
|
37
|
+
export declare const Table: TTable;
|
|
12
38
|
export {};
|
|
@@ -4,6 +4,8 @@ export interface IContext<T> {
|
|
|
4
4
|
deps: number;
|
|
5
5
|
expanded: boolean;
|
|
6
6
|
setExpanded: (expanded: boolean) => void;
|
|
7
|
+
selected: boolean;
|
|
8
|
+
setSelected: (selected: boolean) => void;
|
|
7
9
|
}
|
|
8
10
|
export declare const context: React.Context<IContext<any>>;
|
|
9
11
|
export declare const Provider: React.Provider<IContext<any>>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare const useGetPinnedStyles: <T>(columnIndex: number) => {
|
|
2
|
+
left?: undefined;
|
|
3
|
+
zIndex?: undefined;
|
|
4
|
+
right?: undefined;
|
|
5
|
+
} | {
|
|
6
|
+
left: string;
|
|
7
|
+
zIndex: number;
|
|
8
|
+
right?: undefined;
|
|
9
|
+
} | {
|
|
10
|
+
right: string;
|
|
11
|
+
zIndex: number;
|
|
12
|
+
left?: undefined;
|
|
13
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare const useGetPinnedStyles: <T>(columnIndex: number) => {
|
|
2
|
+
left?: undefined;
|
|
3
|
+
zIndex?: undefined;
|
|
4
|
+
right?: undefined;
|
|
5
|
+
} | {
|
|
6
|
+
left: string;
|
|
7
|
+
zIndex: number;
|
|
8
|
+
right?: undefined;
|
|
9
|
+
} | {
|
|
10
|
+
right: string;
|
|
11
|
+
zIndex: number;
|
|
12
|
+
left?: undefined;
|
|
13
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { INode } from '../../../table.tsx';
|
|
3
|
+
interface IProps<T> {
|
|
4
|
+
originIndex: number;
|
|
5
|
+
align?: 'left' | 'center' | 'right';
|
|
6
|
+
collapse?: boolean;
|
|
7
|
+
node: INode<T>;
|
|
8
|
+
}
|
|
9
|
+
export declare const Cell: <T>(props: React.PropsWithChildren<IProps<T>>) => React.JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TBody } from './tbody.tsx';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ISort } from '../../../configuration/column';
|
|
3
|
+
interface IProps {
|
|
4
|
+
originIndex: number;
|
|
5
|
+
align?: 'left' | 'center' | 'right';
|
|
6
|
+
collapse?: boolean;
|
|
7
|
+
sort?: ISort;
|
|
8
|
+
}
|
|
9
|
+
export declare const Cell: (props: React.PropsWithChildren<IProps>) => React.JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Cell } from './cell.tsx';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { THead } from './thead.tsx';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export interface IProps {
|
|
3
|
+
}
|
|
4
|
+
interface ITableCellPropsWithDisplayName extends React.FC<React.PropsWithChildren<IProps>> {
|
|
5
|
+
displayName: string;
|
|
6
|
+
}
|
|
7
|
+
export declare const Cell: ITableCellPropsWithDisplayName;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export interface ISort {
|
|
3
|
+
directionDefault?: 'asc' | 'desc';
|
|
4
|
+
onToggle(direction?: 'asc' | 'desc'): void;
|
|
5
|
+
}
|
|
6
|
+
export interface IProps {
|
|
7
|
+
width?: number;
|
|
8
|
+
align?: 'left' | 'center' | 'right';
|
|
9
|
+
pinLeft?: boolean;
|
|
10
|
+
pinRight?: boolean;
|
|
11
|
+
sort?: ISort;
|
|
12
|
+
}
|
|
13
|
+
interface IColumnPropsWithDisplayName extends React.FC<React.PropsWithChildren<IProps>> {
|
|
14
|
+
displayName: string;
|
|
15
|
+
}
|
|
16
|
+
export declare const Column: IColumnPropsWithDisplayName;
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ISort } from './column';
|
|
3
|
+
export interface IConfigColumn<T> {
|
|
4
|
+
label: React.ReactNode;
|
|
5
|
+
align?: 'left' | 'center' | 'right';
|
|
6
|
+
sort?: ISort;
|
|
7
|
+
width?: number;
|
|
8
|
+
collapse?: boolean;
|
|
9
|
+
pinLeft?: boolean;
|
|
10
|
+
pinRight?: boolean;
|
|
11
|
+
renderCell: (nodes: T) => React.ReactNode;
|
|
12
|
+
}
|
|
13
|
+
export declare const createColumnConfig: <T>(children: React.ReactNode) => IConfigColumn<T>[];
|