/** * Async utility helpers for reliable DOM synchronization and timing control. * These utilities provide browser-native timing mechanisms that are more reliable * than hardcoded setTimeout values across different environments and platforms. */ export declare class SyncUtils { /** * Wait for next microtask (more reliable than setTimeout(0)) * Useful for ensuring state updates are processed before DOM operations */ static nextTick(): Promise; /** * Wait for next animation frame (better for DOM updates) * Ideal for synchronizing with browser rendering cycles */ static nextFrame(): Promise; /** * Wait for DOM element to be available * Useful for web components or dynamically created elements */ static waitForElement(selector: string, maxAttempts?: number): Promise; /** * Wait for a condition to be met with timeout * Generic utility for polling-based waiting */ static waitForCondition(condition: () => boolean | Promise, maxAttempts?: number, delayStrategy?: 'tick' | 'frame'): Promise; /** * Debounce utility for preventing rapid successive calls * Returns a debounced version of the provided function */ static debounce unknown>(func: T, wait: number): (...args: Parameters) => void; /** * Throttle utility for limiting function execution frequency * Returns a throttled version of the provided function */ static throttle unknown>(func: T, limit: number): (...args: Parameters) => void; }