import type { SelectorEngine } from './engine.js'; /** * Internal selector engines for advanced filtering and composition. * These are used within selector chains, not as standalone selectors. * * Supported engines: * - internal:has - Filter elements that contain matching descendants * - internal:has-not - Filter elements that DON'T contain matching descendants * - internal:has-text - Filter elements by text content * - internal:has-not-text - Filter elements that don't match text * - internal:and - Intersection of multiple selectors * - internal:or - Union of multiple selectors * - internal:label - Find form controls by associated label text * - internal:visible - Filter only visible elements * - internal:left-of - Find elements to the left of reference * - internal:right-of - Find elements to the right of reference * - internal:above - Find elements above reference * - internal:below - Find elements below reference * - internal:near - Find elements near reference (within 50px by default) */ /** * Parse text selector body into text content and matching options. * Supports three formats: * - Substring match (default): text * - Exact match: "text" or 'text' * - Regex match: /pattern/ or /pattern/flags */ export declare function parseTextSelectorBody(body: string): { text: string; exact: boolean; regex: RegExp | null; }; /** * Parse the body of internal:and or internal:or selectors. * Uses && as separator between selectors. */ export declare function parseCompoundSelectorBody(body: string): string[]; /** * internal:has - Filter elements that contain matching descendants * Example: "div >> internal:has=button" - divs that contain a button */ export declare function createHasEngine(): SelectorEngine; /** * internal:has-not - Filter elements that DON'T contain matching descendants * Example: "div >> internal:has-not=button" - divs without buttons */ export declare function createHasNotEngine(): SelectorEngine; /** * internal:has-text - Filter elements by text content * Supports: exact ("text"), substring (text), regex (/pattern/) * Example: "button >> internal:has-text=Submit" */ export declare function createHasTextEngine(): SelectorEngine; /** * internal:has-not-text - Filter elements that don't match text */ export declare function createHasNotTextEngine(): SelectorEngine; /** * internal:and - Intersection of multiple selectors * All selectors must match the same element * Example: "internal:and=css=.foo&&css=.bar" - elements with both classes */ export declare function createAndEngine(): SelectorEngine; /** * internal:or - Union of multiple selectors * Returns elements matching any selector, in DOM order * Example: "internal:or=button&&a" - all buttons and links */ export declare function createOrEngine(): SelectorEngine; /** * internal:label - Find form controls by associated label text * Example: "internal:label=Username" - input with label "Username" */ export declare function createLabelEngine(): SelectorEngine; /** * internal:visible - Filter only visible elements * Example: "button >> internal:visible" */ export declare function createVisibleEngine(): SelectorEngine; /** * Export all internal engines as a map */ export declare const internalEngines: Record; /** * Register all internal engines with the global registry. * This includes both filtering engines and layout engines. */ export declare function registerInternalEngines(): void; //# sourceMappingURL=internal.d.ts.map