Upgrade to Bootstrap 3
This commit is contained in:
parent
e7de3d0196
commit
eca8612ed6
@ -459,8 +459,8 @@ define([
|
|||||||
$menuPanelElt.on('show.bs.collapse', function(e) {
|
$menuPanelElt.on('show.bs.collapse', function(e) {
|
||||||
if(e.target === $menuPanelElt[0]) {
|
if(e.target === $menuPanelElt[0]) {
|
||||||
isMenuPanelShown = true;
|
isMenuPanelShown = true;
|
||||||
//menuPanelBackdropElt = utils.createBackdrop('collapse', '.menu-panel');
|
menuPanelBackdropElt = utils.createBackdrop('collapse', '.menu-panel');
|
||||||
//$menuPanelElt.addClass('move-to-front');
|
$menuPanelElt.addClass('move-to-front');
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
// Close all open sub-menus when one submenu opens
|
// Close all open sub-menus when one submenu opens
|
||||||
@ -469,8 +469,8 @@ define([
|
|||||||
}).on('hide.bs.collapse', function(e) {
|
}).on('hide.bs.collapse', function(e) {
|
||||||
if(e.target === $menuPanelElt[0]) {
|
if(e.target === $menuPanelElt[0]) {
|
||||||
isMenuPanelShown = false;
|
isMenuPanelShown = false;
|
||||||
//menuPanelBackdropElt.remove();
|
menuPanelBackdropElt.remove();
|
||||||
//$menuPanelElt.removeClass('move-to-front');
|
$menuPanelElt.removeClass('move-to-front');
|
||||||
}
|
}
|
||||||
}).on('hidden.bs.collapse', function(e) {
|
}).on('hidden.bs.collapse', function(e) {
|
||||||
if(e.target === $menuPanelElt[0]) {
|
if(e.target === $menuPanelElt[0]) {
|
||||||
|
@ -181,11 +181,14 @@ define([
|
|||||||
// Create a backdrop and add to the body
|
// Create a backdrop and add to the body
|
||||||
utils.createBackdrop = function(toggle, target) {
|
utils.createBackdrop = function(toggle, target) {
|
||||||
var result = crel('div', {
|
var result = crel('div', {
|
||||||
'class': 'modal-backdrop in',
|
'class': 'modal-backdrop in'
|
||||||
'data-toggle': toggle,
|
|
||||||
'data-target': target,
|
|
||||||
});
|
});
|
||||||
document.body.appendChild(result);
|
document.body.appendChild(result);
|
||||||
|
if(toggle == 'collapse') {
|
||||||
|
$(result).click(function() {
|
||||||
|
$(target).collapse('hide');
|
||||||
|
});
|
||||||
|
}
|
||||||
return result;
|
return result;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user