gantri-components 2.83.0-beta.1 → 2.83.0-beta.11
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/dropdown/dropdown.styles.d.ts +1 -0
- package/dist/components/table/components/after-row-component/after-row-component.d.ts +3 -0
- package/dist/components/table/components/after-row-component/after-row-component.types.d.ts +22 -0
- package/dist/components/table/components/after-row-component/index.d.ts +1 -0
- package/dist/components/table/components/table-row/table-row.types.d.ts +2 -0
- package/dist/components/table/hooks/use-track-sticky-cells/use-track-sticky-cells.types.d.ts +1 -0
- package/dist/components/table/index.d.ts +1 -0
- package/dist/components/table/table.styles.d.ts +2 -0
- package/dist/components/table/table.types.d.ts +4 -0
- package/dist/components/text-area/index.d.ts +1 -0
- package/dist/index.cjs.js +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/index.umd.js +1 -1
- package/package.json +1 -1
|
@@ -6,6 +6,7 @@ export declare const StyledSelect: import("styled-components").StyledComponent<"
|
|
|
6
6
|
}, never>;
|
|
7
7
|
export declare const StyledCustomPlaceholderContainer: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
8
8
|
$hasTopPadding: boolean;
|
|
9
|
+
disabled: boolean | undefined;
|
|
9
10
|
}, never>;
|
|
10
11
|
export declare const StyledTextField: import("styled-components").StyledComponent<import("react").FC<import("../text-field").TextFieldProps>, import("styled-components").DefaultTheme, {
|
|
11
12
|
$transparentInputText: boolean;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { RowData } from '@tanstack/react-table';
|
|
2
|
+
import { AfterRowComponentProps } from './after-row-component.types';
|
|
3
|
+
export declare const AfterRowComponent: <TData extends RowData<import("../..").CustomTData>>(props: AfterRowComponentProps<TData>) => JSX.Element | null;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { HTMLAttributes, JSXElementConstructor } from 'react';
|
|
2
|
+
import { Row, RowData } from '@tanstack/react-table';
|
|
3
|
+
export interface AfterRowComponentProps<TData extends RowData> {
|
|
4
|
+
getAfterRowComponent: GetAfterRowComponentDef<TData> | undefined;
|
|
5
|
+
row: Row<TData>;
|
|
6
|
+
}
|
|
7
|
+
export type GetAfterRowComponentDef<TData extends RowData> = (props: {
|
|
8
|
+
row: Row<TData>;
|
|
9
|
+
}) => {
|
|
10
|
+
Component: AfterRowComponentDef<TData> | false | null | undefined;
|
|
11
|
+
/** If `false`, your `Component` will not be wrapped in `tr`/`td` elements, but you can use the props passed to Component to create them. */
|
|
12
|
+
disableTableFormatting?: boolean;
|
|
13
|
+
};
|
|
14
|
+
export type AfterRowComponentDef<TData extends RowData> = JSXElementConstructor<{
|
|
15
|
+
/** Can be used to calculate the `colSpan` for your `td` elements. */
|
|
16
|
+
numColumns: number;
|
|
17
|
+
row: Row<TData>;
|
|
18
|
+
/** If `disableTableFormatting === true`, you can pass these attributes to your own `td` elements. */
|
|
19
|
+
tdAttrs: HTMLAttributes<HTMLTableCellElement>;
|
|
20
|
+
/** If `disableTableFormatting === true`, you can pass these attributes to your own `tr` element. */
|
|
21
|
+
trAttrs: HTMLAttributes<HTMLTableRowElement>;
|
|
22
|
+
}>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './after-row-component';
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { Row, RowData } from '@tanstack/react-table';
|
|
2
2
|
import { CustomRowProps, GetCellProps, OnRowClick, RowReorderingProps } from '../../table.types';
|
|
3
|
+
import { GetAfterRowComponentDef } from '../after-row-component/after-row-component.types';
|
|
3
4
|
export interface TableRowProps<TData extends RowData> {
|
|
4
5
|
customRowProps: CustomRowProps;
|
|
6
|
+
getAfterRowComponent: GetAfterRowComponentDef<TData> | undefined;
|
|
5
7
|
getCellProps: GetCellProps<TData> | undefined;
|
|
6
8
|
index?: number;
|
|
7
9
|
onRowClick?: OnRowClick<TData>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { Property } from 'csstype';
|
|
1
2
|
import { DefaultTheme } from 'styled-components';
|
|
2
3
|
export declare const getTableRowBackgroundColors: ({ theme, backgroundColor, clickableRowHoverBackgroundColor, }: {
|
|
3
4
|
backgroundColor: string | undefined;
|
|
@@ -20,4 +21,5 @@ export declare const StyledTable: import("styled-components").StyledComponent<"t
|
|
|
20
21
|
stickyFirstColumn: boolean | undefined;
|
|
21
22
|
stickyFooter: boolean | undefined;
|
|
22
23
|
stickyLastColumn: boolean | undefined;
|
|
24
|
+
verticalAlign: Property.VerticalAlign | undefined;
|
|
23
25
|
}, never>;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
+
import { Property } from 'csstype';
|
|
1
2
|
import { Cell, ColumnDef, Header, Row, RowData, TableOptions } from '@tanstack/react-table';
|
|
2
3
|
import { Dispatch, HTMLAttributes, MouseEvent, MouseEventHandler, SetStateAction } from 'react';
|
|
3
4
|
import { PagingProps } from './components/table-actions-wrapper/components/paging/paging.types';
|
|
4
5
|
import { CustomActionProps, FiltersProps, SearchProps } from './components/table-actions-wrapper/table-actions-wrapper.types';
|
|
5
6
|
import { SortProps } from './components/table-actions-wrapper/components/sort/sort.types';
|
|
6
7
|
import { OverlayPosition } from '../overlay/overlay.types';
|
|
8
|
+
import { GetAfterRowComponentDef } from './components/after-row-component/after-row-component.types';
|
|
7
9
|
export interface RowReorderingProps<TData extends RowData> {
|
|
8
10
|
disabled?: boolean;
|
|
9
11
|
getDisableSortableRow?: (row: Row<TData>) => boolean;
|
|
@@ -43,6 +45,7 @@ export interface TableProps<TData extends RowData> extends Partial<TableDefaultP
|
|
|
43
45
|
/** If your data is collapsable, passing `true` here will expand all the data by default. */
|
|
44
46
|
expandAllRows?: boolean;
|
|
45
47
|
filters?: FiltersProps;
|
|
48
|
+
getAfterRowComponent?: GetAfterRowComponentDef<TData>;
|
|
46
49
|
getCellProps?: GetCellProps<TData>;
|
|
47
50
|
/**
|
|
48
51
|
* If getColumnsConfig and onColumnsConfigChange are provided,
|
|
@@ -69,6 +72,7 @@ export interface TableDefaultProps {
|
|
|
69
72
|
stickyFooter: boolean;
|
|
70
73
|
/** Providing `customColumns` will automatically make the last column sticky. */
|
|
71
74
|
stickyLastColumn: boolean;
|
|
75
|
+
verticalAlign: Property.VerticalAlign;
|
|
72
76
|
}
|
|
73
77
|
export type GetHeaderCellProps<TData extends RowData, TValue = unknown> = (cell?: Header<TData, TValue>) => CustomCellProps;
|
|
74
78
|
/** Include `status` in the returned object to set the row status color. */
|