import type { FilterFieldProps } from '../../FilterField.types.js'; import type { FilterFieldValueOperationResult, FilterFieldValueOperationStatement } from '../../types/value-operations.js'; /** * Adds a filter statement or value to an existing FilterField value string. * * - If no statement with the given key exists, a new one is appended at the end. * - If a matching `key = value` statement exists, it is converted to `key in (existingValue, newValue)`. * - If a matching `key in (...)` statement exists, the new value is appended to the list. * - The same merge logic applies to `!=` / `not in`. * - When multiple statements with the same key exist, the rightmost one (in document order) wins. * * @public * @param currentValue - The current FilterField value string. * @param filter - The filter statement or value to add. * @param options - Optional configuration. `parserConfig` controls how `currentValue` is parsed * and which leaf types are constructed for new keys / values. * @returns The new FilterField value string and whether the operation produced a change. */ export declare function addFilter(currentValue: string, filter: FilterFieldValueOperationStatement, options?: { /** Parser config to apply when interpreting the existing value and constructing new nodes. */ parserConfig?: FilterFieldProps['parserConfig']; }): FilterFieldValueOperationResult;