From d6d9e2602de2a7467fad2e2cbb3eb4e2208aae33 Mon Sep 17 00:00:00 2001 From: Antony Lesuisse Date: Wed, 28 Mar 2012 00:20:41 +0200 Subject: [PATCH] sane table based layouting for oe_main bzr revid: al@openerp.com-20120327222041-kum3fp8nopnnbcdp --- addons/web/static/src/css/Makefile | 3 ++ addons/web/static/src/css/base.css | 49 +++++++++------------ addons/web/static/src/css/base.sass | 67 ++++++++++++----------------- addons/web/static/src/xml/base.xml | 26 +++++------ 4 files changed, 65 insertions(+), 80 deletions(-) create mode 100644 addons/web/static/src/css/Makefile diff --git a/addons/web/static/src/css/Makefile b/addons/web/static/src/css/Makefile new file mode 100644 index 00000000000..eca044497ef --- /dev/null +++ b/addons/web/static/src/css/Makefile @@ -0,0 +1,3 @@ +base.css: base.sass + sass -t expanded base.sass base.css + diff --git a/addons/web/static/src/css/base.css b/addons/web/static/src/css/base.css index b08d4607e02..be9e873bb77 100644 --- a/addons/web/static/src/css/base.css +++ b/addons/web/static/src/css/base.css @@ -10,18 +10,14 @@ .openerp2 a { text-decoration: none; } -.openerp2 .oe_webclient .oe_application { - position: absolute; - top: 33px; - bottom: 0; - left: 222px; - right: 0; +.openerp2 .oe_left { + float: left; } -.openerp2 .oe_webclient .oe_application a { - color: #8a89ba; +.openerp2 .oe_right { + float: right; } -.openerp2 .oe_webclient .oe_application a:hover { - text-decoration: underline; +.openerp2 .oe_clear { + clear: both; } .openerp2 .oe_content_full_screen .oe_application { top: 0; @@ -30,6 +26,10 @@ .openerp2 .oe_content_full_screen .topbar, .openerp2 .oe_content_full_screen .leftbar { display: none; } +.openerp2 .oe_webclient { + width: 100%; + height: 100%; +} .openerp2 .oe_topbar { width: 100%; height: 31px; @@ -88,19 +88,15 @@ .openerp2 .oe_topbar .oe_topbar_avatar { vertical-align: top; } -.openerp2 .oe_leftbarbg { - position: fixed; - width: 220px; - top: 0; - left: 0; +.openerp2 .oe_main { + width: 100%; height: 100%; - background: #f0eeee; - border-right: 1px solid #afafb6; - z-index: -1; + border-spacing: 0px; } .openerp2 .oe_leftbar { - float: left; width: 221px; + background: #f0eeee; + border-right: 1px solid #afafb6; text-shadow: 0 1px 1px white; } .openerp2 a.oe_logo { @@ -132,6 +128,12 @@ color: #c81010; font-style: italic; } +.openerp2 .oe_application a { + color: #8a89ba; +} +.openerp2 .oe_application a:hover { + text-decoration: underline; +} .openerp2 .oe_menu { float: left; padding: 0; @@ -328,15 +330,6 @@ -webkit-box-shadow: none; -box-shadow: none; } -.openerp2 .oe_left { - float: left; -} -.openerp2 .oe_right { - float: right; -} -.openerp2 .oe_clear { - clear: both; -} .openerp2 .oe_form { border: 1px solid black; margin: 5%; diff --git a/addons/web/static/src/css/base.sass b/addons/web/static/src/css/base.sass index 0f731d167fe..5dead080904 100644 --- a/addons/web/static/src/css/base.sass +++ b/addons/web/static/src/css/base.sass @@ -1,8 +1,8 @@ + // Variables {{{ $colour4: #8a89ba //$colour4: #d14836 // }}} - // Mixins {{{ @mixin vertical-gradient($startColor: #555, $endColor: #333) background-color: $startColor @@ -61,21 +61,14 @@ $colour4: #8a89ba a text-decoration: none // }}} - - // WebClient {{{ - .oe_webclient - .oe_application - position: absolute - top: 33px - bottom: 0 - left: 222px - right: 0 - a - color: $colour4 - &:hover - text-decoration: underline + // Generic classes {{{ + .oe_left + float: left + .oe_right + float: right + .oe_clear + clear: both // }}} - // Fullscreen mode {{{ .oe_content_full_screen .oe_application @@ -84,7 +77,11 @@ $colour4: #8a89ba .topbar, .leftbar display: none // }}} - + // Webclient {{{ + .oe_webclient + width: 100% + height: 100% + // }}} // Topbar {{{ .oe_topbar width: 100% @@ -128,20 +125,17 @@ $colour4: #8a89ba .oe_topbar_avatar vertical-align: top // }}} - - // Leftbar {{{ - .oe_leftbarbg - position: fixed - width: 220px - top: 0 - left: 0 + // Main {{{ + .oe_main + width: 100% height: 100% + border-spacing: 0px + // }}} + // Leftbar {{{ + .oe_leftbar + width: 221px background: #f0eeee border-right: 1px solid #afafb6 - z-index: -1 - .oe_leftbar - float: left - width: 221px text-shadow: 0 1px 1px white a.oe_logo display: block @@ -168,7 +162,13 @@ $colour4: #8a89ba color: #c81010 font-style: italic // }}} - + // Application {{{ + .oe_application + a + color: $colour4 + &:hover + text-decoration: underline + // }}} // Menu {{{ .oe_menu float: left @@ -259,7 +259,6 @@ $colour4: #8a89ba border-right: 4px solid transparent border-top: 4px solid #4c4c4c // }}} - // UserMenu {{{ .oe_user_menu float: right @@ -321,15 +320,6 @@ $colour4: #8a89ba @include vertical-gradient(#292929, #191919) @include box-shadow(none) // }}} - - // Generic classes {{{ - .oe_left - float: left - .oe_right - float: right - .oe_clear - clear: both - // }}} // FormView Layout {{{ .oe_form border: 1px solid black @@ -361,7 +351,6 @@ $colour4: #8a89ba .oe_form_label_help[for], .oe_form_label[for] white-space: nowrap // }}} - // Transitional overrides for old styles {{{ .openerp .oe_form_field_many2one diff --git a/addons/web/static/src/xml/base.xml b/addons/web/static/src/xml/base.xml index 1bbdea327e8..100689bd22c 100644 --- a/addons/web/static/src/xml/base.xml +++ b/addons/web/static/src/xml/base.xml @@ -24,19 +24,19 @@
- -
-
-
- -
- -
-
-
- + + + + + +
+ +
+ +
+