diff --git a/frontend/src/app.js b/frontend/src/app.js index 35f4a4da5..6236fbd3e 100644 --- a/frontend/src/app.js +++ b/frontend/src/app.js @@ -109,7 +109,7 @@ const router = new Router({ }); router.beforeEach((to, from, next) => { - if (document.documentElement.className) { + if (document.querySelector(".v-dialog--active.v-dialog--fullscreen")) { // Disable back button in full-screen viewers and editors. next(false); } else if (to.matched.some((record) => record.meta.settings) && config.values.disable.settings) { diff --git a/frontend/src/share.js b/frontend/src/share.js index 3f8ffc907..adcea4ba2 100644 --- a/frontend/src/share.js +++ b/frontend/src/share.js @@ -109,7 +109,7 @@ const router = new Router({ }); router.beforeEach((to, from, next) => { - if (document.documentElement.className) { + if (document.querySelector(".v-dialog--active.v-dialog--fullscreen")) { // Disable back button in full-screen viewers and editors. next(false); } else if (to.matched.some((record) => record.meta.settings) && config.values.disable.settings) {