mirror of
https://github.com/glitch-soc/mastodon.git
synced 2025-12-15 16:59:41 +00:00
[Glitch] fix: Prevent content scrolling behind main menu (part 1)
Port c6dddbb66e to glitch-soc
Signed-off-by: Claire <claire.github-309c@sitedethib.com>
This commit is contained in:
@@ -21,7 +21,6 @@ import {
|
||||
IgnoreNotificationsModal,
|
||||
AnnualReportModal,
|
||||
} from 'flavours/glitch/features/ui/util/async-components';
|
||||
import { getScrollbarWidth } from 'flavours/glitch/utils/scrollbar';
|
||||
|
||||
import BundleContainer from '../containers/bundle_container';
|
||||
|
||||
@@ -98,16 +97,6 @@ export default class ModalRoot extends PureComponent {
|
||||
backgroundColor: null,
|
||||
};
|
||||
|
||||
componentDidUpdate () {
|
||||
if (this.props.type) {
|
||||
document.body.classList.add('with-modals--active');
|
||||
document.documentElement.style.marginRight = `${getScrollbarWidth()}px`;
|
||||
} else {
|
||||
document.body.classList.remove('with-modals--active');
|
||||
document.documentElement.style.marginRight = '0';
|
||||
}
|
||||
}
|
||||
|
||||
setBackgroundColor = color => {
|
||||
this.setState({ backgroundColor: color });
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user