UNPKG

downshift

Version:

🏎 A set of primitives to build simple, flexible, WAI-ARIA compliant React autocomplete, combobox or select dropdown components.

13 lines (12 loc) 665 B
import { Environment } from '../downshift.types'; /** * Checks if event target is within the downshift elements. * * @param target Target to check. * @param downshiftElements The elements that form downshift (list, toggle button etc). * @param environment The window context where downshift renders. * @param checkActiveElement Whether to also check activeElement. * * @returns Whether or not the target is within downshift elements. */ export declare function targetWithinDownshift(target: EventTarget | undefined | null, downshiftElements: (HTMLElement | undefined | null)[], environment: Environment | undefined, checkActiveElement?: boolean): boolean;