gantri-components 2.80.0-beta.4 → 2.80.0-beta.5

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.
@@ -1,8 +1,8 @@
1
1
  import { CustomColumnOption } from '../../../../custom-columns-toggle.types';
2
2
  import { SyncState } from '../../../../../../table.types';
3
3
  export interface UserPreferencesModalProps {
4
- activeIndex: number;
5
4
  checklistOptions: CustomColumnOption[];
5
+ draggingItem: CustomColumnOption | undefined;
6
6
  onClose: () => Promise<void>;
7
7
  onReset: () => Promise<void>;
8
8
  syncState?: SyncState;
@@ -2,8 +2,8 @@ import { Dispatch, SetStateAction } from 'react';
2
2
  import { CustomColumnOption } from '../../custom-columns-toggle.types';
3
3
  import { SyncState } from '../../../../table.types';
4
4
  export interface UserPreferencesToggleProps {
5
- activeIndex: number;
6
5
  checklistOptions: CustomColumnOption[];
6
+ draggingItem: CustomColumnOption | undefined;
7
7
  handleColumnsConfigChange: () => Promise<void>;
8
8
  isActive: boolean;
9
9
  modalHeading: string;
@@ -0,0 +1,3 @@
1
+ import { RowData } from '@tanstack/react-table';
2
+ import { FlattenTableRowsProps } from './flatten-table-rows.types';
3
+ export declare const flattenTableRows: <TData extends RowData<import("../../../..").CustomTData>>(props: FlattenTableRowsProps<TData>) => import("@tanstack/react-table").Row<TData>[];
@@ -0,0 +1,9 @@
1
+ import { Row, RowData } from '@tanstack/react-table';
2
+ export interface GetRowRootParentIdProps<TData extends RowData> {
3
+ parentId: string | undefined;
4
+ rows: Row<TData>[];
5
+ }
6
+ export interface FlattenTableRowsProps<TData extends RowData> {
7
+ draggingRowId: string | undefined;
8
+ rows: Row<TData>[];
9
+ }
@@ -0,0 +1 @@
1
+ export * from './flatten-table-rows';
@@ -0,0 +1 @@
1
+ export * from './is-row-reordering-disabled';
@@ -0,0 +1,3 @@
1
+ import { RowData } from '@tanstack/react-table';
2
+ import { IsRowReorderDisabledProps } from './is-row-reordering-disabled.types';
3
+ export declare const isRowReorderDisabled: <TData extends RowData<import("../../../..").CustomTData>>(props: IsRowReorderDisabledProps<TData>) => boolean;
@@ -0,0 +1,6 @@
1
+ import { Row, RowData } from '@tanstack/react-table';
2
+ import { RowReorderingProps } from '../../../../table.types';
3
+ export interface IsRowReorderDisabledProps<TData extends RowData> {
4
+ reordering: RowReorderingProps<TData> | undefined;
5
+ row: Row<TData>;
6
+ }
@@ -1,15 +1,12 @@
1
1
  import { DragEndEvent, DragStartEvent } from '@dnd-kit/core';
2
- import { Row, RowData } from '@tanstack/react-table';
2
+ import { RowData } from '@tanstack/react-table';
3
3
  import { UseDragAndDropRowsProps } from './use-drag-and-drop-rows.types';
4
4
  export declare const useDragAndDropRows: <TData extends RowData<import("../..").CustomTData>>(props: UseDragAndDropRowsProps<TData>) => {
5
+ draggingItem: TData | undefined;
6
+ draggingRow: import("@tanstack/react-table").Row<TData> | undefined;
5
7
  draggingRowId: string | undefined;
6
- draggingRowIndex: number;
7
8
  handleDragEnd: (event: DragEndEvent) => void;
8
9
  handleDragStart: (event: DragStartEvent) => void;
9
10
  isDragging: boolean;
10
11
  sensors: import("@dnd-kit/core").SensorDescriptor<import("@dnd-kit/core").SensorOptions>[];
11
12
  };
12
- export declare const flattenTableRows: <TData extends RowData<import("../..").CustomTData>>({ draggingRowId, rows, }: {
13
- draggingRowId: string | undefined;
14
- rows: Row<TData>[];
15
- }) => Row<TData>[];
@@ -1,7 +1,8 @@
1
- import { RowData } from '@tanstack/react-table';
1
+ import { Row, RowData } from '@tanstack/react-table';
2
2
  import { RowReorderingProps } from '../../table.types';
3
3
  export type UseDragAndDropRowsProps<TData extends RowData> = {
4
4
  data: TData[];
5
5
  reordering?: RowReorderingProps<TData> | undefined;
6
+ rows?: Row<TData>[];
6
7
  setData: (records: TData[]) => void;
7
8
  };
@@ -1,13 +1,12 @@
1
1
  import { Cell, ColumnDef, Header, Row, RowData, TableOptions } from '@tanstack/react-table';
2
2
  import { Dispatch, HTMLAttributes, MouseEvent, MouseEventHandler, SetStateAction } from 'react';
3
- import { Disabled } from '@dnd-kit/sortable/dist/types';
4
3
  import { PagingProps } from './components/table-actions-wrapper/components/paging/paging.types';
5
4
  import { CustomActionProps, FiltersProps, SearchProps } from './components/table-actions-wrapper/table-actions-wrapper.types';
6
5
  import { SortProps } from './components/table-actions-wrapper/components/sort/sort.types';
7
6
  import { OverlayPosition } from '../overlay/overlay.types';
8
7
  export interface RowReorderingProps<TData extends RowData> {
9
8
  disabled?: boolean;
10
- getDisableSortableRow?: (row: Row<TData>) => Disabled | boolean;
9
+ getDisableSortableRow?: (row: Row<TData>) => boolean;
11
10
  /** Overrides the default index-based row number. */
12
11
  getRowNumber?: (row: Row<TData>) => number | string | undefined;
13
12
  isActive: boolean;