From dcfe89b6da910274fecb0f7d4dd979cf2694e1c8 Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Sun, 11 Aug 2013 23:09:27 +0200 Subject: [PATCH] [IMP] First Theme Example bzr revid: fp@openerp.com-20130811210927-dys2ilkss3553r65 --- addons/website/static/src/css/Makefile | 1 + .../website/static/src/css/website-flatly.css | 84 ++++++++++++++++ .../static/src/css/website-flatly.sass | 76 +++++++++++++++ addons/website/static/src/css/website.css | 96 +++---------------- addons/website/static/src/css/website.sass | 79 ++------------- addons/website/views/views.xml | 22 ++--- addons/website_event/views/website_event.xml | 4 +- addons/website_mail/views/website_mail.xml | 4 +- addons/website_sale/views/ecommerce.xml | 16 ++-- 9 files changed, 204 insertions(+), 178 deletions(-) create mode 100644 addons/website/static/src/css/website-flatly.css create mode 100644 addons/website/static/src/css/website-flatly.sass diff --git a/addons/website/static/src/css/Makefile b/addons/website/static/src/css/Makefile index 238219f8906..2c05352f1e1 100644 --- a/addons/website/static/src/css/Makefile +++ b/addons/website/static/src/css/Makefile @@ -1,3 +1,4 @@ sass: sass -t expanded --unix-newlines --watch website.sass:website.css& + sass -t expanded --unix-newlines --watch website-flatly.sass:website-flatly.css& sass -t expanded --unix-newlines --watch editor.sass:editor.css& diff --git a/addons/website/static/src/css/website-flatly.css b/addons/website/static/src/css/website-flatly.css new file mode 100644 index 00000000000..e06de976539 --- /dev/null +++ b/addons/website/static/src/css/website-flatly.css @@ -0,0 +1,84 @@ +@charset "utf-8"; +/* THIS CSS FILE IS FOR WEBSITE THEMING CUSTOMIZATION ONLY + * + * css for editor buttons, openerp widget included in the website and other + * stuff must go to the editor.css + * + */ +/* ----- GENERIC LAYOUTING HELPERS ---- */ +/* Grid of unequally tall elements */ +.grid > [class*="span"] { + display: inline-block; + float: none; + vertical-align: top; + margin-right: -4px; + box-sizing: border-box; +} +.grid > [class*="span"].grid-align-top > [class*="span"] { + vertical-align: top; +} +.grid > [class*="span"].grid-align-middle > [class*="span"] { + vertical-align: middle; +} +.grid > [class*="span"].grid-align-bottom > [class*="span"] { + vertical-align: bottom; +} + +/* Table with two collumns aligned on the center */ +.table-equalized { + width: 100%; +} +.table-equalized td:first-child { + width: 50%; + text-align: right; + padding-right: 1em; + vertical-align: bottom; +} +.table-equalized td:last-child { + width: 50%; + text-align: left; + vertical-align: bottom; +} + +/* Theming pagination inside navbar */ +.navbar-inner > .pagination { + margin: 6px 0; +} +.navbar-inner > .pagination ul { + position: relative; + top: 2px; + border: solid 2px rgba(0, 0, 0, 0.05); + border-radius: 8px; +} + +/* ---- HOMEPAGE THEME CUSTOMIZATION ---- */ +.subheader { + letter-spacing: 3px; + font-weight: 300; +} + +.dark { + background: #eff8f8; + padding: 64px; +} + +h5 { + font-weight: bold; +} + +#myCarousel .item { + min-height: 300px; + color: white; +} + +.thumbnail { + background: white; +} + +.navbar .nav > li a { + float: none; + padding: 15px 15px 15px; + color: white; + text-decoration: none; + text-shadow: 0 1px 0 #2c3e50; +} diff --git a/addons/website/static/src/css/website-flatly.sass b/addons/website/static/src/css/website-flatly.sass new file mode 100644 index 00000000000..892e3b08f44 --- /dev/null +++ b/addons/website/static/src/css/website-flatly.sass @@ -0,0 +1,76 @@ +@charset "utf-8" + +/* + * THIS CSS FILE IS FOR WEBSITE THEMING CUSTOMIZATION ONLY + * + * css for editor buttons, openerp widget included in the website and other + * stuff must go to the editor.css + * + */ + +/* ----- GENERIC LAYOUTING HELPERS ---- */ + +/* Grid of unequally tall elements */ +.grid > [class*="span"] + display: inline-block + float: none + vertical-align: top + margin-right: -4px + box-sizing: border-box + &.grid-align-top > [class*="span"] + vertical-align: top + &.grid-align-middle > [class*="span"] + vertical-align: middle + &.grid-align-bottom > [class*="span"] + vertical-align: bottom + +/* Table with two collumns aligned on the center */ +.table-equalized + width: 100% + td:first-child + width: 50% + text-align: right + padding-right: 1em + vertical-align: bottom + td:last-child + width: 50% + text-align: left + vertical-align: bottom + +/* Theming pagination inside navbar */ +.navbar-inner > .pagination + margin: 6px 0 + ul + position: relative + top: 2px + border: solid 2px rgba(0,0,0,0.05) + border-radius: 8px + +/* ---- HOMEPAGE THEME CUSTOMIZATION ---- */ + +.subheader + letter-spacing: 3px + font-weight: 300 + +.dark + background: rgb(239, 248, 248) + padding: 64px + +h5 + font-weight: bold + +#myCarousel .item + min-height: 300px + color: white + +.thumbnail + background: white + +.navbar .nav > li a + float: none + padding: 15px 15px 15px + color: #ffffff + text-decoration: none + text-shadow: 0 1px 0 #2c3e50 + + diff --git a/addons/website/static/src/css/website.css b/addons/website/static/src/css/website.css index eff864d500c..c19576b0a3f 100644 --- a/addons/website/static/src/css/website.css +++ b/addons/website/static/src/css/website.css @@ -1,3 +1,4 @@ +@charset "utf-8"; /* THIS CSS FILE IS FOR WEBSITE THEMING CUSTOMIZATION ONLY * * css for editor buttons, openerp widget included in the website and other @@ -78,51 +79,6 @@ margin-bottom: 0px !important; } -/* Grid of unequally tall elements */ -.grid > [class*="span"] { - display: inline-block; - float: none; - vertical-align: top; - margin-right: -4px; - box-sizing: border-box; -} -.grid > [class*="span"].grid-align-top > [class*="span"] { - vertical-align: top; -} -.grid > [class*="span"].grid-align-middle > [class*="span"] { - vertical-align: middle; -} -.grid > [class*="span"].grid-align-bottom > [class*="span"] { - vertical-align: bottom; -} - -/* Table with two collumns aligned on the center */ -.table-equalized { - width: 100%; -} -.table-equalized td:first-child { - width: 50%; - text-align: right; - padding-right: 1em; - vertical-align: bottom; -} -.table-equalized td:last-child { - width: 50%; - text-align: left; - vertical-align: bottom; -} - -/* Theming pagination inside navbar */ -.navbar-inner > .pagination { - margin: 6px 0; -} -.navbar-inner > .pagination ul { - position: relative; - top: 2px; - border: solid 2px rgba(0, 0, 0, 0.05); - border-radius: 8px; -} - /* ----- BOOTSTRAP HACK FOR STICKY FOOTER ----- */ html, body { height: 100%; @@ -147,38 +103,6 @@ footer { padding-bottom: 48px; } -/* ---- HOMEPAGE THEME CUSTOMIZATION ---- */ -.subheader { - letter-spacing: 3px; - font-weight: 300; -} - -header.navbar-fixed-top { - position: static; -} - -.dark { - background: #eff8f8; - padding: 64px; -} - -h5 { - font-weight: bold; -} - -#myCarousel .item { - min-height: 300px; - color: white; -} - -.nav > .pull-right { - float: right !important; -} - -.thumbnail { - background: white; -} - /* ---- HACK FOR COVERING UP CK EDITOR BOGUS P INSERTION --- */ .navbar .nav > li > p { margin-bottom: 0px; @@ -188,14 +112,16 @@ h5 { text-shadow: none; } -.navbar .nav > li a { - float: none; - padding: 15px 15px 15px; - color: white; - text-decoration: none; - text-shadow: 0 1px 0 #2c3e50; -} - .nav > li a { display: block; } + +/* ---- HOMEPAGE THEME CUSTOMIZATION ---- */ +header.navbar-fixed-top { + position: static; +} + +#myCarousel .item { + min-height: 300px; + color: white; +} diff --git a/addons/website/static/src/css/website.sass b/addons/website/static/src/css/website.sass index 3ae32d8830a..a8ae998b1ec 100644 --- a/addons/website/static/src/css/website.sass +++ b/addons/website/static/src/css/website.sass @@ -49,42 +49,6 @@ .mb0 margin-bottom: 0px !important -/* Grid of unequally tall elements */ -.grid > [class*="span"] - display: inline-block - float: none - vertical-align: top - margin-right: -4px - box-sizing: border-box - &.grid-align-top > [class*="span"] - vertical-align: top - &.grid-align-middle > [class*="span"] - vertical-align: middle - &.grid-align-bottom > [class*="span"] - vertical-align: bottom - -/* Table with two collumns aligned on the center */ -.table-equalized - width: 100% - td:first-child - width: 50% - text-align: right - padding-right: 1em - vertical-align: bottom - td:last-child - width: 50% - text-align: left - vertical-align: bottom - -/* Theming pagination inside navbar */ -.navbar-inner > .pagination - margin: 6px 0 - ul - position: relative - top: 2px - border: solid 2px rgba(0,0,0,0.05) - border-radius: 8px - /* ----- BOOTSTRAP HACK FOR STICKY FOOTER ----- */ html,body @@ -107,32 +71,6 @@ footer padding-top: 48px padding-bottom: 48px -/* ---- HOMEPAGE THEME CUSTOMIZATION ---- */ - -.subheader - letter-spacing: 3px - font-weight: 300 - -header.navbar-fixed-top - position: static - -.dark - background: rgb(239, 248, 248) - padding: 64px - -h5 - font-weight: bold - -#myCarousel .item - min-height: 300px - color: white - - -.nav > .pull-right - float: right !important //bugfix for flatly theme - -.thumbnail - background: white /* ---- HACK FOR COVERING UP CK EDITOR BOGUS P INSERTION --- */ @@ -142,13 +80,16 @@ h5 .navbar .nav > li a text-shadow: none -.navbar .nav > li a - float: none - padding: 15px 15px 15px - color: #ffffff - text-decoration: none - text-shadow: 0 1px 0 #2c3e50 - .nav > li a display: block +/* ---- HOMEPAGE THEME CUSTOMIZATION ---- */ + +header.navbar-fixed-top + position: static + +#myCarousel .item + min-height: 300px + color: white + + diff --git a/addons/website/views/views.xml b/addons/website/views/views.xml index 704ad10ace5..c8237224369 100644 --- a/addons/website/views/views.xml +++ b/addons/website/views/views.xml @@ -9,9 +9,9 @@ OpenERP -