Skip to content

Commit c4a71b4

Browse files
committed
add window dec
1 parent 2682761 commit c4a71b4

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
// Global type declarations for the fern-docs/components package
2+
3+
declare global {
4+
interface Window {
5+
/**
6+
* Used to restore sidebar scroll position after navigation.
7+
* This helps maintain scroll state when the sidebar is re-mounted
8+
* in Next.js App Router.
9+
*/
10+
_FERN_SIDEBAR_SCROLL_RESTORATION?: number;
11+
12+
/**
13+
* Cancellation callback for the scroll sidebar node into view operation.
14+
* Used to cancel pending scroll operations when a new one is triggered.
15+
*/
16+
__FERN_CANCEL_SCROLL_SIDEBAR_NODE_INTO_VIEW?: () => void;
17+
}
18+
}
19+
20+
export {};

0 commit comments

Comments
 (0)