@sellgar/kit 0.0.172 → 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 +4924 -4791
- 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/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
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Cell } from './cell.tsx';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Head } from './head.tsx';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export interface SelectContextValue<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 SelectProvider: React.Provider<SelectContextValue<any> | null>;
|
|
13
|
+
export declare const useSelectContext: <T>() => SelectContextValue<T>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { INode } from '../../table.tsx';
|
|
3
|
+
interface IProps<T> {
|
|
4
|
+
onSelect: (items: INode<T>[]) => void;
|
|
5
|
+
}
|
|
6
|
+
export declare const SelectProvider: <T>(props: React.PropsWithChildren<IProps<T>>) => React.JSX.Element;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Arrow } from './arrow.tsx';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export interface SortContextValue {
|
|
3
|
+
direction?: 'asc' | 'desc';
|
|
4
|
+
onToggle(): void;
|
|
5
|
+
}
|
|
6
|
+
export declare const SortProvider: React.Provider<SortContextValue | null>;
|
|
7
|
+
export declare const useSortContext: () => SortContextValue;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Cell } from './cell.tsx';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Head } from './head.tsx';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { RowCheckbox } from './row-checkbox.tsx';
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
interface IContext {
|
|
3
|
+
isSelectedAll: boolean;
|
|
4
|
+
isIndeterminate: boolean;
|
|
5
|
+
selectedItems: any[];
|
|
6
|
+
hasSelected: (item: any) => boolean;
|
|
7
|
+
addItem: (item: any) => void;
|
|
8
|
+
deleteItem: (item: any) => void;
|
|
9
|
+
selectAll: () => void;
|
|
10
|
+
deleteAll: () => void;
|
|
11
|
+
}
|
|
12
|
+
export declare const context: React.Context<IContext>;
|
|
13
|
+
export declare const Provider: React.Provider<IContext>;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TitleCheckbox } from './title-checkbox.tsx';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { TTableDataItem } from '../table.tsx';
|
|
3
|
+
export interface ITableCellProps<T> {
|
|
4
|
+
render?: (item: T) => React.ReactNode;
|
|
5
|
+
}
|
|
6
|
+
interface ITableCellPropsWithDisplayName extends React.FC<React.PropsWithChildren<ITableCellProps<TTableDataItem>>> {
|
|
7
|
+
displayName: string;
|
|
8
|
+
}
|
|
9
|
+
export declare const TableCell: ITableCellPropsWithDisplayName;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TableRows } from './table-rows.tsx';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Row } from './row.tsx';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export interface IContext<T> {
|
|
3
|
+
data: T;
|
|
4
|
+
deps: number;
|
|
5
|
+
expanded: boolean;
|
|
6
|
+
setExpanded: (expanded: boolean) => void;
|
|
7
|
+
selected: boolean;
|
|
8
|
+
setSelected: (selected: boolean) => void;
|
|
9
|
+
}
|
|
10
|
+
export declare const context: React.Context<IContext<any>>;
|
|
11
|
+
export declare const Provider: React.Provider<IContext<any>>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ITree } from '../table.tsx';
|
|
3
|
+
interface ITableRowsProps<T> {
|
|
4
|
+
data: T;
|
|
5
|
+
tree?: ITree<T>;
|
|
6
|
+
deps: number;
|
|
7
|
+
index: number;
|
|
8
|
+
}
|
|
9
|
+
export declare const TableRows: <T>(props: React.PropsWithChildren<ITableRowsProps<T>>) => React.ReactNode[];
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { IData } from './table.tsx';
|
|
3
|
+
import { IConfigColumn } from './configuration/create-columns-config.ts';
|
|
4
|
+
export interface TableContextValue<T> {
|
|
5
|
+
data: IData<T>;
|
|
6
|
+
columns: IConfigColumn<T>[];
|
|
7
|
+
columnsWidth: number[];
|
|
8
|
+
}
|
|
9
|
+
export declare const TableProvider: React.Provider<TableContextValue<any>>;
|
|
10
|
+
export declare const useTableContext: <T>() => TableContextValue<T>;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { Cell } from './configuration/cell';
|
|
3
|
+
import { Head } from './configuration/head';
|
|
4
|
+
import { Column } from './configuration/column';
|
|
5
|
+
export interface INode<T> {
|
|
6
|
+
id: string | number;
|
|
7
|
+
data: T;
|
|
8
|
+
deps: number;
|
|
9
|
+
meta: any;
|
|
10
|
+
nodes?: INode<T>[];
|
|
11
|
+
}
|
|
12
|
+
export interface IData<T> {
|
|
13
|
+
nodes: T[];
|
|
14
|
+
}
|
|
15
|
+
interface ITreeProps<T> {
|
|
16
|
+
isUse: boolean;
|
|
17
|
+
accessor: keyof T;
|
|
18
|
+
}
|
|
19
|
+
interface ISelectProps<T> {
|
|
20
|
+
isUse: boolean;
|
|
21
|
+
onSelect(nodes: INode<T>[]): void;
|
|
22
|
+
}
|
|
23
|
+
interface IProps<T extends {
|
|
24
|
+
id: string | number;
|
|
25
|
+
}> {
|
|
26
|
+
data: IData<T>;
|
|
27
|
+
tree?: ITreeProps<T>;
|
|
28
|
+
select?: ISelectProps<T>;
|
|
29
|
+
}
|
|
30
|
+
export declare const TableComponent: <T extends {
|
|
31
|
+
id: string | number;
|
|
32
|
+
}>(props: React.PropsWithChildren<IProps<T>>) => React.JSX.Element;
|
|
33
|
+
type TTable = typeof TableComponent & {
|
|
34
|
+
Column: typeof Column;
|
|
35
|
+
Head: typeof Head;
|
|
36
|
+
Cell: typeof Cell;
|
|
37
|
+
};
|
|
38
|
+
export declare const Table: TTable;
|
|
39
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { RowArrow } from './row-arrow.tsx';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { TitleArrow } from './title-arrow.tsx';
|
package/types/index.d.ts
CHANGED
|
@@ -4,5 +4,5 @@ export * from './components/wrappers';
|
|
|
4
4
|
export * from './subcomponents';
|
|
5
5
|
export * from './components/helpers/animate';
|
|
6
6
|
export * from './components/modal';
|
|
7
|
-
export * from './components/
|
|
7
|
+
export * from './components/table';
|
|
8
8
|
export * from './components/drawer';
|