[FIX] web: make submodals backdrop appear on top of parent modals

Commit https://github.com/odoo/odoo/commit/7dcb8fea642858e0bb1d68cea9707cb3c8d4328d
(and https://github.com/odoo/odoo/commit/e64cf3d606bd94f7e0d82ec907ce7d1d66222287)
were supposed to make submodals backdrop appear on top of parent modals.

The feature was however broken by another commit before it was released:
https://github.com/odoo/odoo/commit/f997c128c7295b5e76d7f77d79c4a82898debbcf
This commit is contained in:
qsm-odoo
2017-12-01 13:56:58 +01:00
parent 673b9e6a4a
commit 4974f8edb7
2 changed files with 14 additions and 14 deletions
+13
View File
@@ -72,6 +72,19 @@
@modal-inner-padding: @odoo-horizontal-padding;
@modal-title-padding: @odoo-horizontal-padding;
// Change the z-index of the modal-backdrop elements to be equal to the
// modal elements' ones. Bootstrap does not support multi-modals, and without
// this rule all the modal-backdrops are below all the opened modals.
// Indeed, bootstrap forces them to a lower z-index as the modal-backdrop
// element (unique in their supported cases) might be put after the modal
// element (if the modal is already in the DOM, hidden, then opened). This
// cannot happen in odoo though as modals are not hidden but removed from
// the DOM and are always put at the end of the body when opened.
//
// Note that the variable @zindex-modal-background may be renamed/removed in
// newer versions of bootstrap.
@zindex-modal-background: @zindex-modal;
//== Navs
@nav-link-padding: 10px 15px;
@nav-pills-border-radius: 0;
+1 -14
View File
@@ -77,21 +77,8 @@
}
}
// Change the z-index of the modal-backdrop elements to be equal to the
// modal elements' ones. Bootstrap does not support multi-modals, and without
// this rule all the modal-backdrops are below all the opened modals.
// Indeed, bootstrap forces them to a lower z-index as the modal-backdrop
// element (unique in their supported cases) might be put after the modal
// element (if the modal is already in the DOM, hidden, then opened). This
// cannot happen in odoo though as modals are not hidden but removed from
// the DOM and are always put at the end of the body when opened.
//
// Note that the variable @zindex-modal-background may be renamed/removed in
// newer versions of bootstrap.
@zindex-modal-background: @zindex-modal;
// Temporary fix for modals which are not instantiated thanks to the Dialog
// JS classes (deprecated case) + Frontend.
// JS classes (deprecated case) (see bootstrap_overridden.less) + Frontend.
:not(body) > .modal {
z-index: @zindex-modal-background + 1;
}