Skip to content

Commit

Permalink
fix(modal): restore scroll lock on modal destroy
Browse files Browse the repository at this point in the history
  • Loading branch information
nd0ut committed Apr 27, 2023
1 parent 1b10cce commit ecb201f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions blocks/Modal/Modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ export class Modal extends Block {

destroyCallback() {
super.destroyCallback();
document.body.style.overflow = null;
this.ref.dialog.removeEventListener('close', this._handleDialogClose);
this.ref.dialog.removeEventListener('click', this._handleDialogClick);
}
Expand Down

0 comments on commit ecb201f

Please sign in to comment.