import type { FilterItemValues } from '../../filters/filter/types/shared-filter-types.js'; /** * Facilitates easy usage of the FilterBar for filtering entries in the DataTable. * * Supports hierarchical data with sub-rows. When filtering, if a parent * row doesn't match but one of its sub-rows does, the parent is included * with with appropriate sub-rows. * * @param data - The initial, unfiltered data array. * @param filterData - Optional custom filter function that receives the applied filters, * the current entry, its index, and the original data array. Returns `true` to include * the entry in the filtered results. When provided, this overrides the default filter logic. * @param subrowMatchingBehavior - Controls how non-matching sibling sub-rows are handled when a * parent or sibling are in the matching path: * - `'includeNonMatchingSiblings'` (default): Include all sibling sub-rows even if they don't match. * - `'excludeNonMatchingSiblings'`: Only include sub-rows that match the filter or are on the path of a match. * @returns An object containing: * - `onChange`: Callback to be passed to FilterBar's onChange prop to apply filters. * - `filteredData`: The filtered data array to be used as input for the DataTable. * - `expandedRowIds`: Only relevant for data with sub-rows. IDs of all ancestor rows that contain matching * descendant nodes. This can be used to expand the correct nodes so that the matches * are visible. * @public */ export declare function useFilteredData>(data: T[], filterData?: (appliedFilters: FilterItemValues, entry: T, index: number, originalEntries: T[]) => boolean, subrowMatchingBehavior?: 'includeNonMatchingSiblings' | 'excludeNonMatchingSiblings'): { onChange: (appliedFilters: FilterItemValues) => void; filteredData: T[]; expandedRowIds?: string[]; };