We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 31b6626 commit 8855f24Copy full SHA for 8855f24
packages/core/useScroll/index.ts
@@ -162,7 +162,9 @@ export function useScroll(
162
163
const setArrivedState = (target: HTMLElement | SVGElement | Window | Document | null | undefined) => {
164
const el = (
165
- target === document ? (target as Document).documentElement : target
+ target === window
166
+ ? (target as Window).document.documentElement
167
+ : target === document ? (target as Document).documentElement : target
168
) as HTMLElement
169
170
const { display, flexDirection } = getComputedStyle(el)
0 commit comments