From cadb481e201cd83f7a098781ae45b6e02c6d359b Mon Sep 17 00:00:00 2001 From: Simon Lejeune Date: Fri, 29 Jul 2016 10:57:48 +0200 Subject: [PATCH] [FIX] web: oe-view-manager-content display issue on ie11 This tries to be the smallest patch possible in order to avoid triggering another display issues, so we only patch in the ms-hight-contrast section which only applies on ie 10/11. * The view-manager weren't displayed correctly; they didn't fit 100% of the screen width. This is fixed by explicitely seting the top, right, left, bottom attributes. * The modals content were not displayed. This was due to 2 issues: * The rule that we patch in the first point set the position of `oe-view-manager` as absolute with an importang flag. Because of this important, the rule that reset the position of the `oe-view-manager` as static in modals.less was not honored. So we also patch this rule with an important flag inside the same file (so that all the fixes related to ie10/11 are in the same place). * Now that the modals are displayed, they do not fit 100% of the screen. It's because the `max-height: 100%` of `.modal-content` set in modals.less does not work in ie10/11, due to some bug with the flex displays. We set the height to 450px so that the modals are kind of correctly displayed on a 1366x768 screen (their content are still scrollable). related to rev 1ccd87a03753c69a2e12c585de388434ef9ff557 closes #12929 --- addons/web/static/src/css/base.css | 13 +++++++++++++ addons/web/static/src/css/base.sass | 10 +++++++++- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/addons/web/static/src/css/base.css b/addons/web/static/src/css/base.css index 4c82e830d4d..dfc127f7c65 100644 --- a/addons/web/static/src/css/base.css +++ b/addons/web/static/src/css/base.css @@ -3006,10 +3006,23 @@ body { @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) { .oe-view-manager-content > div { position: absolute !important; + top: 0; + right: 0; + bottom: 0; + left: 0; } .oe-view-manager-content .oe-view-manager-content > div { position: relative !important; } + + .modal .oe-view-manager-content > div { + position: static !important; + max-height: 450px; + } + + .modal > .modal-dialog > .modal-content { + max-height: 450px; + } } .o_progressbar > div { display: inline-block; diff --git a/addons/web/static/src/css/base.sass b/addons/web/static/src/css/base.sass index dfcaae29f91..f11fb0a76df 100644 --- a/addons/web/static/src/css/base.sass +++ b/addons/web/static/src/css/base.sass @@ -2556,10 +2556,18 @@ body .oe-view-manager-content > div position: absolute !important + top: 0 + right: 0 + bottom: 0 + left: 0 .oe-view-manager-content > div position: relative !important - + .modal .oe-view-manager-content > div + position: static !important + max-height: 450px + .modal > .modal-dialog > .modal-content + max-height: 450px // au BufWritePost,FileWritePost *.sass :!sass --style expanded --line-numbers > "%:p:r.css"