Makes sure a modal is preferably made scrollable inside the modal if it suits the situation.
mentioned in commit 2bf0931c