/** * adowire client — adowire:poll directive * * Periodically calls `component.$refresh()` on the owning [adowire:id] * component at a configurable interval. Mirrors Livewire's wire:poll behaviour. * * Attribute value formats: * adowire:poll → 2000ms (default) * adowire:poll="2s" → 2000ms * adowire:poll="500ms" → 500ms * adowire:poll="10s" → 10000ms * * Behaviour: * - Polling is paused while the tab is not visible (`document.hidden`). * - Polling stops when the component's root element leaves the DOM. * - A WeakMap prevents double-registration when the MutationObserver fires * on the same element more than once. * - `registerPollDirective()` is idempotent — safe to call multiple times. */ /** * Parse the string value of an `adowire:poll` attribute into a millisecond * duration. * * Recognised formats: * - `null` / `""` → {@link DEFAULT_INTERVAL_MS} * - `"500ms"` → 500 * - `"2s"` → 2000 * - `"10s"` → 10000 * - bare number → treated as milliseconds * * Unrecognised values fall back to the default and emit a console warning. */ export declare function parsePollInterval(value: string | null): number; /** * Register the `adowire:poll` directive. * * 1. Immediately scans the current DOM for `[adowire:poll]` elements and * starts their intervals. * 2. Attaches a `MutationObserver` on `document.body` to handle elements * added or removed after initial page load. * * Safe to call multiple times — subsequent calls are no-ops. */ export declare function registerPollDirective(): void;