/**
*
* Copyright (c) "Neo4j"
* Neo4j Sweden AB [http://neo4j.com]
*
* This file is part of Neo4j.
*
* Neo4j is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
import { type Cell, type CellContext, type Header as HeaderType, type Row, type RowData, type SortDirection } from '@tanstack/react-table';
import type React from 'react';
import { type CommonProps, type PolymorphicCommonProps } from '../_common/types';
import { CleanIconButton } from '../clean-icon-button';
import { DataGridCrossIcon } from '../icons';
import { Menu } from '../menu';
import { type ColumnAction } from './datagrid-types';
export declare const DEFAULT_SORT_ACTIONS: (cell: HeaderType) => {
[key in SortDirection | 'default']: ColumnAction;
};
type ResizingBarProps = {
header: HeaderType;
};
declare const ResizingBar: ({ header, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"button", ResizingBarProps>) => import("react/jsx-runtime").JSX.Element;
type ScrollableProps = {
children?: React.ReactNode;
};
declare const Scrollable: ({ children, ref, className, style, htmlAttributes, ...restProps }: CommonProps<"div", ScrollableProps> & {
ref: React.RefObject;
}) => import("react/jsx-runtime").JSX.Element;
type HeaderProps = {
children?: React.ReactNode;
};
declare const Header: ({ children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", HeaderProps>) => import("react/jsx-runtime").JSX.Element;
type ActionButtonProps = {
action: ColumnAction;
onClose: () => void;
};
export declare const ActionButton: ({ action, onClose, as, className, style, htmlAttributes, ref, ...restProps }: PolymorphicCommonProps) => import("react/jsx-runtime").JSX.Element;
export interface ActionCellProps {
cell?: CellContext;
innerCleanIconButtonProps?: Partial>;
innerMenuProps?: Partial>;
}
declare const ActionCell: ({ cell, innerCleanIconButtonProps, innerMenuProps, }: ActionCellProps) => import("react/jsx-runtime").JSX.Element | null;
type ColumnControlsProps = {
cell: HeaderType;
children?: React.ReactNode;
};
export declare const ColumnControls: ({ cell, children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", ColumnControlsProps>) => import("react/jsx-runtime").JSX.Element | null;
type HeaderCellProps = {
cell: HeaderType;
children?: React.ReactNode;
};
declare const HeaderCell: ({ cell, children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", HeaderCellProps>) => import("react/jsx-runtime").JSX.Element;
type HeaderTitleProps = {
cell: HeaderType;
children?: React.ReactNode;
};
declare const HeaderTitle: ({ cell, children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", HeaderTitleProps>) => import("react/jsx-runtime").JSX.Element;
type BodyProps = {
children?: React.ReactNode;
};
declare const Body: ({ children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", BodyProps>) => import("react/jsx-runtime").JSX.Element;
type BodyCellProps = {
cell: Cell;
children?: React.ReactNode;
};
declare const BodyCell: ({ cell, children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", BodyCellProps>) => import("react/jsx-runtime").JSX.Element;
type BodyRowProps = {
row: Row;
children?: React.ReactNode;
};
declare const BodyRow: ({ row, children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", BodyRowProps>) => import("react/jsx-runtime").JSX.Element;
type TableResultProps = {
manualPagination?: {
from: number;
to: number;
totalRows: number;
};
children?: React.ReactNode;
/**
* The label to use for the results, meaning the word "results" in the sentence "Showing X-Y of Z results".
* @defaultValue 'results'
*/
resultsLabel?: string;
};
declare const TableResults: ({ manualPagination, children, className, style, htmlAttributes, ref, resultsLabel, ...restProps }: CommonProps<"span", TableResultProps>) => import("react/jsx-runtime").JSX.Element | null;
type RowsPerPageProps = {
/**
* The target element to portal the menu of the select component to.
* Should be document.body normally, or the modal root if the select is inside a modal.
* Defaults to the portalTarget prop of the DataGrid root component.
*/
portalTarget?: HTMLElement | null;
children?: React.ReactNode;
};
declare const RowsPerPage: ({ portalTarget: portalTargetProp, children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", RowsPerPageProps>) => import("react/jsx-runtime").JSX.Element;
type PaginationArrowButtonProps = {
action: 'previous' | 'next';
children?: React.ReactNode;
onClick?: (e: React.MouseEvent) => void;
};
declare const PaginationArrowButton: ({ action, children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"button", PaginationArrowButtonProps>) => import("react/jsx-runtime").JSX.Element;
type PaginationNumericButtonProps = {
currentIndex: number | string;
isSelected: boolean;
children?: React.ReactNode;
onClick?: (e: React.MouseEvent) => void;
};
declare const PaginationNumericButton: ({ currentIndex, isSelected, children, className, style, htmlAttributes, onClick, ref, ...restProps }: CommonProps<"button", PaginationNumericButtonProps>) => import("react/jsx-runtime").JSX.Element;
declare const PaginationNumericButtons: () => import("react/jsx-runtime").JSX.Element;
type PaginationProps = {
children?: React.ReactNode;
};
declare const Pagination: ({ children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"nav", PaginationProps>) => import("react/jsx-runtime").JSX.Element;
type NavigationProps = {
children?: React.ReactNode;
};
declare const Navigation: ({ children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", NavigationProps>) => import("react/jsx-runtime").JSX.Element;
type LoadingPlaceholderProps = {
children?: React.ReactNode;
};
declare const LoadingPlaceholder: ({ children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", LoadingPlaceholderProps>) => import("react/jsx-runtime").JSX.Element;
type NoDataPlaceholderProps = {
children?: React.ReactNode;
};
declare const NoDataPlaceholder: ({ children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", NoDataPlaceholderProps>) => import("react/jsx-runtime").JSX.Element;
type NoDataPlaceholderContentWrapperProps = {
children?: React.ReactNode;
};
export declare const NoDataPlaceholderContentWrapper: ({ children, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"div", NoDataPlaceholderContentWrapperProps>) => import("react/jsx-runtime").JSX.Element;
export interface InlineEditCellProps {
cell: CellContext;
value: string;
ariaLabel: string;
}
declare const InlineEditCell: ({ cell, value, ariaLabel, className, style, htmlAttributes, ref, ...restProps }: CommonProps<"input", InlineEditCellProps>) => import("react/jsx-runtime").JSX.Element | null;
type DropDownCellProps = {
cell: CellContext;
options: {
value: string;
label: string;
}[];
/**
* The target element to portal the menu of the select component to, e.g. the modal root if the data grid is inside a modal.
* Defaults to the portalTarget prop of the DataGrid root component.
*/
portalTarget?: HTMLElement | null;
/** Aria label of the select component. Required for accessibility. */
ariaLabel: string;
/** Whether the select component is disabled */
isDisabled?: boolean;
};
declare const DropDownCell: ({ cell, options, portalTarget: portalTargetProp, ariaLabel, className, style, htmlAttributes, ref: forwardRef, isDisabled, ...restProps }: CommonProps<"div", DropDownCellProps>) => import("react/jsx-runtime").JSX.Element | null;
declare const NoDataIcon: ({ className, ...restProps }: React.ComponentPropsWithoutRef) => import("react/jsx-runtime").JSX.Element;
export { ResizingBar, Header, Body, BodyCell, BodyRow, InlineEditCell, DropDownCell, ActionCell, HeaderCell, HeaderTitle, Navigation, TableResults, RowsPerPage, Pagination, PaginationNumericButtons, PaginationArrowButton, PaginationNumericButton, NoDataPlaceholder, NoDataIcon, LoadingPlaceholder, Scrollable, };
//# sourceMappingURL=Components.d.ts.map