Fixed CSS stacking context on Android
authorAlexander Ebert <ebert@woltlab.com>
Thu, 22 Dec 2016 12:35:03 +0000 (13:35 +0100)
committerAlexander Ebert <ebert@woltlab.com>
Thu, 22 Dec 2016 12:35:09 +0000 (13:35 +0100)
wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Screen.js

index cef32a587218eb7925fdc5e9a977f39996be48ae..77008cc1d51cccc2f01a46adca57f2b0309c50b5 100644 (file)
@@ -117,12 +117,7 @@ define(['Core', 'Dictionary', 'Environment'], function(Core, Dictionary, Environ
                                        pageContainer.style.setProperty('top', '-' + _scrollTop + 'px', '');
                                }
                                else {
-                                       pageContainer.style.setProperty('transform', 'translateY(-' + _scrollTop + 'px)', '');
-                                       
-                                       if (_dialogContainer !== null) {
-                                               // the same value for `pageContainer` but in reverse
-                                               _dialogContainer.style.setProperty('transform', 'translateY(' + _scrollTop + 'px)', '');
-                                       }
+                                       pageContainer.style.setProperty('margin-top', '-' + _scrollTop + 'px', '');
                                }
                                
                                document.documentElement.classList.add('disableScrolling');
@@ -147,11 +142,7 @@ define(['Core', 'Dictionary', 'Environment'], function(Core, Dictionary, Environ
                                                pageContainer.style.removeProperty('top');
                                        }
                                        else {
-                                               pageContainer.style.removeProperty('transform');
-                                               
-                                               if (_dialogContainer !== null) {
-                                                       _dialogContainer.style.removeProperty('transform');
-                                               }
+                                               pageContainer.style.removeProperty('margin-top');
                                        }
                                        
                                        if (_scrollTop) {