Hiding page actions when overlays/mobile menu is open
authorAlexander Ebert <ebert@woltlab.com>
Thu, 14 Jul 2016 16:41:48 +0000 (18:41 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Thu, 14 Jul 2016 16:41:54 +0000 (18:41 +0200)
wcfsetup/install/files/js/WoltLab/WCF/Ui/Dialog.js
wcfsetup/install/files/js/WoltLab/WCF/Ui/Page/Menu/Abstract.js
wcfsetup/install/files/style/ui/pageAction.scss

index 373b79af8d8527d9942d7e78ecccdc2219161f75..0ca68efd78a9a31db4da34f71db8ec9714ca4ead 100644 (file)
@@ -220,6 +220,8 @@ define(
                                this._createDialog(id, html, options);
                        }
                        
+                       document.documentElement.classList.add('pageOverlayActive');
+                       
                        return _dialogs.get(id);
                },
                
@@ -520,6 +522,7 @@ define(
                                elData(_container, 'close-on-click', 'false');
                                
                                window.removeEventListener('keyup', _keyupListener);
+                               document.documentElement.classList.remove('pageOverlayActive');
                        }
                        else {
                                data = _dialogs.get(_activeDialog);
index 6a88b2ff33144fb4966afc146c9e1744545c3579..cab400d7930ba97932fdddf6b23e3b96463dfaa6 100644 (file)
@@ -99,6 +99,8 @@ define(['Environment', 'EventHandler', 'ObjectMap', 'Dom/Traverse', 'Dom/Util',
                        UiScreen.scrollDisable();
                        
                        _pageContainer.classList.add('menuOverlay-' + this._menu.id);
+                       
+                       document.documentElement.classList.add('pageOverlayActive');
                },
                
                /**
@@ -117,6 +119,8 @@ define(['Environment', 'EventHandler', 'ObjectMap', 'Dom/Traverse', 'Dom/Util',
                                UiScreen.scrollEnable();
                                
                                _pageContainer.classList.remove('menuOverlay-' + this._menu.id);
+                               
+                               document.documentElement.classList.remove('pageOverlayActive');
                        }
                },
                
index af87592160a46d7bf4977aea665791ffca82efb4..8c7ff31b6faf09b103939f93ab0fdabc18b818c7 100644 (file)
@@ -68,3 +68,7 @@
                }
        }
 }
+
+.pageOverlayActive .pageAction {
+       display: none;
+}