UNPKG

@jiaozhiye/qm-design-vue

Version:

A Component Library for Vue3.0

20 lines (19 loc) 808 B
import { Ref } from 'vue'; type InViewHookResponse = [(node?: Element | null) => void, Ref<boolean>, Ref<IntersectionObserverEntry> | undefined] & { $ref: (node?: Element | null) => void; inView: Ref<boolean>; entry?: Ref<IntersectionObserverEntry>; }; type Options = { root?: Ref<Element | null | undefined>; rootMargin?: Ref<string>; threshold?: Ref<number | number[]>; triggerOnce?: Ref<boolean>; fallbackInView?: Ref<boolean>; trackVisibility?: Ref<boolean>; skip?: Ref<boolean>; delay?: Ref<number>; onChange?: (inView: boolean, entry: IntersectionObserverEntry) => void; }; export declare const useInView: ({ root, rootMargin, threshold, triggerOnce, fallbackInView, trackVisibility, skip, delay, onChange, }?: Options) => InViewHookResponse; export {};