import { DomMetadata } from './types/additional.type'; import { SearchingProps } from './feature-searching/types'; import { ContextMenuDropdownItem, ContextMenuDropDownProps } from './feature-context-menu/types'; import { DropdownProps } from '../Dropdown'; import { CellClickArgs, CellMouseEvent, DataGridHandle, SortColumn } from 'react-data-grid'; import { default as React, PropsWithChildren } from 'react'; import { ActiveViewModsType, ObjectForExtending, SIZE } from '.'; type RowContextV = { rowSize: SIZE; }; export declare const useRowContext: () => CustomType extends ObjectForExtending ? CustomType & RowContextV : RowContextV; export type ExpandedRowsContextV = Set; export type ExpandedRowsChangeContextV = React.Dispatch>; export declare const useExpandedRowsContext: () => { expandedRowsIds: ExpandedRowsContextV | null; setExpandedRowsIds: ExpandedRowsChangeContextV | null; }; export type HeaderContextValueTypeInstance> = { filters: FilterStateType | undefined; setFilters: React.Dispatch> | undefined; clearedFiltersValue: FilterStateType | undefined; sortState: readonly SortColumn[] | undefined; setSortState: React.Dispatch> | undefined; sortIsVisible: boolean; setSortIsVisible: React.Dispatch>; rowSize: SIZE; setRowSize: React.Dispatch>; onRowSizeChange?: (size: SIZE) => void; isExpandedAllRows: boolean; toggleExpandAllButton: () => void; activeView: ActiveViewModsType; setActiveView: React.Dispatch>; }; export declare const HeaderContext: React.Context>; export declare const useHeaderContext: () => CustomType extends ObjectForExtending ? CustomType & HeaderContextValueTypeInstance : HeaderContextValueTypeInstance; type CommonContextMenuProps = { isOpen: boolean; items: DropdownProps['items'] | null; position: { x: number; y: number; } | null; open: (params: { position: { x: number; y: number; }; items?: DropdownProps['items'] | null; targetElement?: HTMLElement; }) => void; close: () => void; targetElement: HTMLElement | undefined; }; export type ContextMenuContextV = CommonContextMenuProps & ContextMenuDropDownProps & { enableHeaderContextMenu: boolean; enableCellContextMenu: boolean; openHeaderContextMenu: (event: React.MouseEvent) => void; getClosestColumn: (event: React.MouseEvent) => { columnLabel: string; } | undefined; onItemSelect?: (item: ContextMenuDropdownItem, event?: React.SyntheticEvent) => void; openCellContextMenu: (args: CellClickArgs, event: CellMouseEvent) => void; }; export declare const useContextMenu: () => ContextMenuContextV; type SearchContextValue = SearchingProps & { searchQuery: string; setSearchQuery: React.Dispatch>; clearSearch: () => void; internalLocalValue: string; setInternalLocalValue: React.Dispatch>; domMetadata?: DomMetadata; searchOnType?: boolean; }; export declare const useSearchContext: () => SearchContextValue; export type SidebarContextValue = { isOpen: boolean; width: number; toggle: () => void; setWidth: (width: number) => void; }; export declare const useSidebar: () => SidebarContextValue; export type TableCollapseContextValue = { isCollapsed: boolean; toggleCollapse: () => void; collapseText: string; expandText: string; enableCollapse: boolean; domMetadata?: DomMetadata; collapseButtonPlacement?: 'inside' | 'above'; collapseButtonAboveRightSlot?: React.ReactNode; }; export declare const useTableCollapse: () => TableCollapseContextValue; export declare const ContextProviders: ({ children, headerCtxV, rowCtxV, expandedRowCtxV, searchCtxV, contextMenuCtxV, sideBarCtxV, tableCollapseCtxV, }: PropsWithChildren & { headerCtxV: HeaderContextValueTypeInstance; rowCtxV: RowContextV; expandedRowCtxV: [ExpandedRowsContextV, ExpandedRowsChangeContextV]; searchCtxV: SearchContextValue; contextMenuCtxV: ContextMenuContextV; sideBarCtxV: SidebarContextValue; tableCollapseCtxV: TableCollapseContextValue; }) => import("react/jsx-runtime").JSX.Element; export declare const RefTableContext: React.Context | null>; export declare const useRefTableContext: () => React.RefObject | null; export declare const RefTableGlobalContainerContext: React.Context | null>; export declare const useRefTableGlobalContainerContext: () => React.MutableRefObject | undefined; export declare const RefTableContainerContext: React.Context | null>; export declare const useRefTableContainerContext: () => React.MutableRefObject | undefined; export { TableResizeObserverProvider, TableResizeObserverProviderWrapper, useTableResizeObserver, useTableResizeObserverWidth, } from './resize-observer-context';