question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Scrolling breaks when switching a modal window

See original GitHub issue

Bootstrap v5.0.0-beta.

Sample code:

currentModal.hide ();
newModal.show ();

The windows change, but instead of <body class = "modal-open"> we get <body class>

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:1
  • Comments:8 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
Mrreadinesscommented, May 6, 2021

@GeoSot Everything is fixed in the current release! I close the issue.

1reaction
Jacquesvwcommented, Mar 29, 2021

Was about to report this issue as well.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Bootstrap Modal Issue - Scrolling Gets Disabled - Stack Overflow
One way to make it work, is to use the hidden.bs.modal event triggered by BS when closing a modal, then check if there...
Read more >
Prevent Page Scrolling When a Modal is Open | CSS-Tricks
You open a modal, scroll through it, close it, and wind up somewhere else on the page than you were when you opened...
Read more >
Using modal-full-height breaks scroll - MDBootstrap
My modal loads tabs, so the content on each tab is different heights and results in the modal changing heights for every tab....
Read more >
-webkit-overflow-scrolling - CSS: Cascading Style Sheets | MDN
The -webkit-overflow-scrolling CSS property controls whether or not touch devices use momentum-based scrolling for a given element.
Read more >
Modal · Bootstrap v5.2
Modals are built with HTML, CSS, and JavaScript. They're positioned over everything else in the document and remove scroll from the <body> so...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found