Skip to content

Commit e9c57a4

Browse files
committed
refactor(modal): improve naming of helper
1 parent fafbb31 commit e9c57a4

File tree

1 file changed

+3
-0
lines changed
  • packages/kit-headless/src/components/modal

1 file changed

+3
-0
lines changed

packages/kit-headless/src/components/modal/modal.tsx

+3
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ import {
1414
activateFocusTrap,
1515
closeModal,
1616
deactivateFocusTrap,
17+
keepModalInPlaceWhileScrollbarReappears as keepModalInPlaceWhenScrollbarReappears,
18+
lockScroll,
1719
overrideNativeDialogEscapeBehaviorWith,
1820
showModal,
1921
trapFocus,
@@ -68,6 +70,7 @@ export const Modal = component$((props: ModalProps) => {
6870

6971
cleanup(() => {
7072
deactivateFocusTrap(focusTrap);
73+
keepModalInPlaceWhenScrollbarReappears(scrollbar, modalRefSig.value);
7174
});
7275
});
7376

0 commit comments

Comments
 (0)