import type { ShallowUnwrapRef, WatchOptions, WatchSource } from 'vue'; import type { ElementOf, MaybeRefOrGetter } from '../../vueuse/interface'; export interface UntilToMatchOptions { timeout?: number; throwOnTimeout?: boolean; flush?: WatchOptions['flush']; deep?: WatchOptions['deep']; } export interface UntilBaseInstance { toMatch: ((condition: (v: T) => v is U, options?: UntilToMatchOptions) => Not extends true ? Promise> : Promise) & ((condition: (v: T) => boolean, options?: UntilToMatchOptions) => Promise); changed: (options?: UntilToMatchOptions) => Promise; changedTimes: (n?: number, options?: UntilToMatchOptions) => Promise; } type Falsy = false | void | null | undefined | 0 | 0n | ''; export interface UntilValueInstance extends UntilBaseInstance { readonly not: UntilValueInstance; toBe:

(value: MaybeRefOrGetter

, options?: UntilToMatchOptions) => Not extends true ? Promise : Promise

; toBeTruthy: (options?: UntilToMatchOptions) => Not extends true ? Promise : Promise>; toBeNull: (options?: UntilToMatchOptions) => Not extends true ? Promise> : Promise; toBeUndefined: (options?: UntilToMatchOptions) => Not extends true ? Promise> : Promise; toBeNaN: (options?: UntilToMatchOptions) => Promise; } export interface UntilArrayInstance extends UntilBaseInstance { readonly not: UntilArrayInstance; toContains: (value: MaybeRefOrGetter>>, options?: UntilToMatchOptions) => Promise; } export declare function until(r: WatchSource | MaybeRefOrGetter): UntilArrayInstance; export declare function until(r: WatchSource | MaybeRefOrGetter): UntilValueInstance; export {};