Removed fixed user panel
authorMarcel Werk <burntime@woltlab.com>
Mon, 13 May 2013 19:09:43 +0000 (21:09 +0200)
committerMarcel Werk <burntime@woltlab.com>
Mon, 13 May 2013 19:09:43 +0000 (21:09 +0200)
com.woltlab.wcf/template/headInclude.tpl
wcfsetup/install/files/js/WCF.js
wcfsetup/install/files/style/layout.less

index 252a4cfe0609da34d82c8aa69d97758275d7c1eb..d783ca2cd0039253da43a4bedc5e9df3bdf5a4bb 100644 (file)
                WCF.Dropdown.init();
                WCF.System.PageNavigation.init('.pageNavigation');
                WCF.Date.Picker.init();
-               WCF.System.JumpToAnchor.execute();
                WCF.System.MobileNavigation.init();
                
                {event name='javascriptInit'}
index 5285678dede2c924ce00d6c2c840618c269107c3..9db62ea1f689b17992ae3f8510e5bb34d8e589f9 100755 (executable)
@@ -5500,36 +5500,6 @@ WCF.System.MobileNavigation = {
        }
 };
 
-/**
- * Fixes scroll offset on page load.
- */
-WCF.System.JumpToAnchor = {
-       execute: function() {
-               if (window.location.hash) {
-                       var $element = $(window.location.hash);
-                       if ($element.length) {
-                               if ($.browser.chrome || $.browser.msie) {
-                                       $element.addClass('userPanelJumpToAnchorFix');
-                                       
-                                       $(document).on('readystatechange', function() {
-                                               if (document.readyState === 'complete') {
-                                                       // wait 100ms
-                                                       new WCF.PeriodicalExecuter(function(pe) {
-                                                               pe.stop();
-                                                               
-                                                               $element.removeClass('userPanelJumpToAnchorFix');
-                                                       }, 100);
-                                               }
-                                       });
-                               }
-                               else {
-                                       window.scrollBy(0, -1 * $('.userPanel').outerHeight());
-                               }
-                       }
-               }
-       }
-};
-
 /**
  * System notification overlays.
  * 
index c7485940b68bac617082ae13973d6617a7972dd9..e718448b29b637c907f7bce7331f3873714c32ea 100644 (file)
@@ -49,7 +49,7 @@
        background-color: @wcfUserPanelBackgroundColor;
        height: 40px;
        left: 0;
-       position: fixed;
+       position: absolute;
        top: 0;
        right: 0;
        z-index: 200;
        }
 }
 
-.userPanelJumpToAnchorFix:before {
-       content: "";
-       display: block;
-       height: 40px;
-       margin-top: -40px;
-}
-
 @media only screen and (max-width: 800px) {
        .userPanel {
                height: auto;