remove scroll in drag & drop context (#69710)
This commit is contained in:
parent
29fbdd56d9
commit
e3d01bf450
|
@ -168,18 +168,6 @@ export const DragDropContextWrapper = connector(DragDropContextWrapperComponent)
|
|||
DragDropContextWrapper.displayName = 'DragDropContextWrapper';
|
||||
|
||||
const onBeforeCapture = (before: BeforeCapture) => {
|
||||
const x =
|
||||
window.pageXOffset !== undefined
|
||||
? window.pageXOffset
|
||||
: (document.documentElement || document.body.parentNode || document.body).scrollLeft;
|
||||
|
||||
const y =
|
||||
window.pageYOffset !== undefined
|
||||
? window.pageYOffset
|
||||
: (document.documentElement || document.body.parentNode || document.body).scrollTop;
|
||||
|
||||
window.onscroll = () => window.scrollTo(x, y);
|
||||
|
||||
if (!draggableIsField(before)) {
|
||||
document.body.classList.add(IS_DRAGGING_CLASS_NAME);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue