import * as react_jsx_runtime from 'react/jsx-runtime'; import * as React from 'react'; import { ColumnDef } from './types.js'; import { TableState } from './table-state-types.js'; import '../../lib/table-properties-types.js'; import '../../lib/column-cell-kind.js'; import '../../lib/status-badge-tints.js'; import './use-table-state.js'; import '../../lib/column-filter-context.js'; import '../../lib/column-filter-person-options.js'; import '../../lib/row-height.js'; interface GroupDisplay { node: React.ReactNode; label: string; /** Declared-tone fill, or undefined for the shared grey wash. */ tint: string | undefined; } /** * The grouped column's own vocabulary for its values, keyed by raw value — * grouping keys on `String(row[groupBy])`, so a status group arrives as * `approved`, not as the chip the column paints in its cells. * * Read off `ColumnDef.filter.options` rather than the resolved filter, because * only the column def carries `node` and `tone`; the resolved def is narrowed * to value and label for the filter menus. */ declare function useGroupDisplay>(columns: ColumnDef[], groupBy: string | null | undefined): (groupLabel: string | null) => GroupDisplay | undefined; /** * The select column's rendered box, which is the slot the group checkbox sits * in. Read from the live width so a consumer that ships a wider select column * keeps the two checkboxes on one axis. */ declare function useSelectColumnWidth>(displayCols: ColumnDef[], colWidths: Record): number | undefined; /** * A group's checkbox, shown in its divider bar. Row ids are derived with the * group-local index so they match the ids the body rows register under, and * the toggle adds or removes only this group's ids — a group is a subset of * the selection, not a replacement for it. * * `interactive: false` renders the mirror for the pinned clone: same box, no * pointer, no Tab stop, because the real bar is still in the table for the * keyboard and screen reader. * * Returns `null` (not an empty element) so `groupBarContent` can skip the slot. */ declare function renderGroupSelect>({ groupLabel, groupRows, interactive, selectable, state, getRowIdProp, }: { groupLabel: string | null; groupRows: TData[]; interactive?: boolean; selectable: boolean; state: TableState; getRowIdProp: ((row: TData, index: number) => string | number) | undefined; }): React.ReactNode; /** Divider row for a group inside the table body. */ declare function GroupBarRow({ colSpan, display, count, selectable, stickyPinsDisabled, select, selectColumnWidth, }: { colSpan: number; display: GroupDisplay; count: number; selectable: boolean; stickyPinsDisabled: boolean; select: React.ReactNode; selectColumnWidth: number | undefined; }): react_jsx_runtime.JSX.Element; /** * The pinned group divider. The clip window is transparent and exactly one bar * tall, so an outgoing divider slides up behind the column header and the * incoming real row shows through the space it vacates. Nothing here is * interactive, and the real divider is still in the table for a screen reader * to read in order, so the clone stays out of the pointer and accessibility trees. */ declare function PinnedGroupClone({ clipRef, slideRef, display, count, selectable, select, selectColumnWidth, }: { clipRef: React.Ref; slideRef: React.Ref; display: GroupDisplay | undefined; count: number; selectable: boolean; select: React.ReactNode; selectColumnWidth: number | undefined; }): react_jsx_runtime.JSX.Element; export { GroupBarRow, type GroupDisplay, PinnedGroupClone, renderGroupSelect, useGroupDisplay, useSelectColumnWidth };