From 219edc67a28d1d4a453eacb4dea59e4885d6d641 Mon Sep 17 00:00:00 2001 From: stefanorigano Date: Mon, 26 Jun 2017 15:25:02 +0200 Subject: [PATCH] [IMP] web, web_planner: remove navbar unnecessary borders Although a dark 'border-bottom' is necessary in some occasions (to add contrast between the page's content and the navbar itself), the other borders were totally unnecessary. Moreover, having a complete border causes complications to calculate the sidebar height and to manage buttons' size and line-height. This fix will keep the border-bottom only, removing the other ones. Compensation rules ("- 2px") are no longer necessary. --- addons/web/static/src/less/navbar.less | 20 +++++++++---------- .../static/src/less/web_planner_common.less | 2 +- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/addons/web/static/src/less/navbar.less b/addons/web/static/src/less/navbar.less index 8d68773ecff..d000ed4f469 100644 --- a/addons/web/static/src/less/navbar.less +++ b/addons/web/static/src/less/navbar.less @@ -2,17 +2,17 @@ .o_main_navbar { position: relative; height: @odoo-navbar-height; - border: 1px solid @odoo-navbar-inverse-link-hover-bg; + border-bottom: 1px solid @odoo-navbar-inverse-link-hover-bg; background-color: @odoo-brand-primary; color: white; > a, > button { float: left; - width: @odoo-navbar-height - 2; - height: @odoo-navbar-height - 2; + width: @odoo-navbar-height; + height: @odoo-navbar-height; border: none; padding: 0; - line-height: @odoo-navbar-height - 2; + line-height: @odoo-navbar-height; background-color: transparent; text-align: center; color: inherit; @@ -37,7 +37,7 @@ color: white; font-size: 22px; font-weight: 500; - line-height: @odoo-navbar-height - 2; + line-height: @odoo-navbar-height; @media (max-width: @screen-xs-max) { float: none; @@ -65,10 +65,10 @@ > a { display: block; - height: @odoo-navbar-height - 2; + height: @odoo-navbar-height; padding: 0 10px; color: white; - line-height: @odoo-navbar-height - 2; + line-height: @odoo-navbar-height; &:hover { background-color: @odoo-navbar-inverse-link-hover-bg; @@ -81,7 +81,7 @@ &.o_extra_menu_items { > a { - width: @odoo-navbar-height - 2; + width: @odoo-navbar-height; text-align: center; } &.open > ul { @@ -176,8 +176,8 @@ } &.o_menu_systray { - .o-position-absolute(0px, @odoo-navbar-height - 2, auto, @odoo-navbar-height - 2); - height: @odoo-navbar-height - 2; + .o-position-absolute(0px, @odoo-navbar-height, auto, @odoo-navbar-height); + height: @odoo-navbar-height; text-align: right; > li { diff --git a/addons/web_planner/static/src/less/web_planner_common.less b/addons/web_planner/static/src/less/web_planner_common.less index 043bdbb6528..cf6c20da7b3 100644 --- a/addons/web_planner/static/src/less/web_planner_common.less +++ b/addons/web_planner/static/src/less/web_planner_common.less @@ -33,7 +33,7 @@ > .progress { width: 70px; height: @planner-height; - margin: floor((@odoo-navbar-height - 2 - @planner-height)/2) 10px 0; + margin: floor((@odoo-navbar-height - @planner-height)/2) 10px 0; cursor: pointer; > .progress-bar {