diff --git a/src/components/app.jsx b/src/components/app.jsx
index 07c2ca79..330c3902 100644
--- a/src/components/app.jsx
+++ b/src/components/app.jsx
@@ -61,7 +61,10 @@ export default class App extends React.Component {
const { additionalClass, embedded, stylePrefix } = config;
const hide = () => {
- if (!embedded) this.setState({ show: false });
+ if (!embedded) {
+ document.body.classList.remove('klaro-modal-open');
+ this.setState({ show: false });
+ }
};
return (
{innerModal}
;
+ document.body.classList.add('klaro-modal-open');
+
return (
diff --git a/src/components/consent-notice.jsx b/src/components/consent-notice.jsx
index c783e4f1..ebf97eeb 100644
--- a/src/components/consent-notice.jsx
+++ b/src/components/consent-notice.jsx
@@ -111,6 +111,7 @@ export default class ConsentNotice extends React.Component {
const hideModal = () => {
if (config.mustConsent && !config.acceptAll) return;
+ document.body.classList.remove('klaro-modal-open');
if (manager.confirmed && !testing) this.props.hide();
else this.setState({ modal: false });