File diff suppressed because one or more lines are too long
@@ -26,11 +26,11 @@ Dropdown.prototype.listen = function() {
|
|||||||
var submenuHeight = clone.outerHeight();
|
var submenuHeight = clone.outerHeight();
|
||||||
var submenuWidth = clone.outerWidth();
|
var submenuWidth = clone.outerWidth();
|
||||||
|
|
||||||
if (offset.top + submenuHeight - $(window).scrollTop() > $(window).height()) {
|
if (offset.top + submenuHeight - $(window).scrollTop() < $(window).height() || $(window).scrollTop() + offset.top < submenuHeight) {
|
||||||
clone.css('top', offset.top - submenuHeight - 5);
|
clone.css('top', offset.top + $(this).height());
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
clone.css('top', offset.top + $(this).height());
|
clone.css('top', offset.top - submenuHeight - 5);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (offset.left + submenuWidth > $(window).width()) {
|
if (offset.left + submenuWidth > $(window).width()) {
|
||||||
|
|||||||
Reference in New Issue
Block a user