makes sure the bottom bar buttons are moved when resizing the left pane and that their position stays relative during tab changing.

This commit is contained in:
Shannon
2015-08-02 11:32:43 +02:00
parent 60af7deacd
commit 3a7853dcbe
2 changed files with 13 additions and 0 deletions

View File

@@ -31,10 +31,13 @@ angular.module("umbraco.directives")
var wrapper = $("#mainwrapper");
var contentPanel = $("#leftcolumn").next();
var apps = $("#applications");
var bottomBar = contentPanel.find(".umb-bottom-bar");
var navOffeset = ui.element.next();
var leftPanelWidth = ui.element.width() + apps.width();
contentPanel.css({ left: leftPanelWidth });
bottomBar.css({ left: leftPanelWidth });
navOffeset.css({ "margin-left": ui.element.outerWidth() });
},
stop: function(e, ui) {

View File

@@ -29,6 +29,16 @@ angular.module("umbraco.directives.html")
//var belowFold = (el.offset().top + el.height()) > winHeight;
if (hasOverflow) {
el.addClass("umb-bottom-bar");
//I wish we didn't have to put this logic here but unfortunately we
// do. This needs to calculate the left offest to place the bottom bar
// depending on if the left column splitter has been moved by the user
// (based on the nav-resize directive)
var wrapper = $("#mainwrapper");
var contentPanel = $("#leftcolumn").next();
var contentPanelLeftPx = contentPanel.css("left");
el.css({ left: contentPanelLeftPx });
}
}
return firstRun;