import type { Ref } from '@stacksjs/stx'; /** * Promise-based utility to wait for a ref to meet a condition. * * @param r - The reactive ref to watch * @returns A chainable instance with condition methods * * @example * ```ts * const ready = ref(false) * await until(ready).toBe(true) * ``` */ export declare function until(r: Ref): UntilBaseInstance; export declare interface UntilToMatchOptions { timeout?: number throwOnTimeout?: boolean } export declare interface UntilBaseInstance { toMatch: (condition: (v: T) => boolean, options?: UntilToMatchOptions) => Promise toBe: (value: T, options?: UntilToMatchOptions) => Promise toBeTruthy: (options?: UntilToMatchOptions) => Promise toBeNull: (options?: UntilToMatchOptions) => Promise toBeUndefined: (options?: UntilToMatchOptions) => Promise toBeNaN: (options?: UntilToMatchOptions) => Promise changed: (options?: UntilToMatchOptions) => Promise not: { toBe: (value: T, options?: UntilToMatchOptions) => Promise toBeTruthy: (options?: UntilToMatchOptions) => Promise toBeNull: (options?: UntilToMatchOptions) => Promise toBeUndefined: (options?: UntilToMatchOptions) => Promise toBeNaN: (options?: UntilToMatchOptions) => Promise } }