From a26d3cdbaed878a738946881b629dc2638a7dda2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20van=20der=20Essen?= <fva@openerp.com> Date: Tue, 30 Jul 2013 20:24:33 +0200 Subject: [PATCH] styling improvements on ecommerce and blog bzr revid: fva@openerp.com-20130730182433-33t3ggw722usd82w --- addons/website/static/src/css/snippets.css | 2 +- addons/website/static/src/css/website.css | 6 +++++- addons/website/static/src/css/website.sass | 8 +++++++- addons/website/views/views.xml | 10 +++++----- addons/website_mail/views/website_mail.xml | 2 +- .../website_sale/static/src/css/ecommerce.css | 19 ++++++++++--------- .../static/src/css/ecommerce.sass | 3 ++- addons/website_sale/views/ecommerce.xml | 14 +++++++------- 8 files changed, 38 insertions(+), 26 deletions(-) diff --git a/addons/website/static/src/css/snippets.css b/addons/website/static/src/css/snippets.css index b4b8a4b518fc..65a6e714f970 100644 --- a/addons/website/static/src/css/snippets.css +++ b/addons/website/static/src/css/snippets.css @@ -37,6 +37,7 @@ top:0px; left:0px; right:0px; bottom:0px; background: rgba(151, 137, 255, 0.2); } +*/ .oe_snippet_editor{ position: fixed; @@ -50,7 +51,6 @@ overflow-y: hidden; overflow-x: scroll; } -*/ .oe_snippet_list{ width: auto; diff --git a/addons/website/static/src/css/website.css b/addons/website/static/src/css/website.css index 2e1d58764899..020700f4dfb2 100644 --- a/addons/website/static/src/css/website.css +++ b/addons/website/static/src/css/website.css @@ -54,7 +54,7 @@ html, body { footer { box-sizing: border-box; height: 300px; - background: #ddebe3; + background: #eff8f8; padding-top: 64px; padding-bottom: 64px; } @@ -73,6 +73,10 @@ header.navbar-fixed-top { padding: 64px; } +h5 { + font-weight: bold; +} + .nav > .pull-right { float: right !important; } diff --git a/addons/website/static/src/css/website.sass b/addons/website/static/src/css/website.sass index de9bb526d328..52ef7d5fd565 100644 --- a/addons/website/static/src/css/website.sass +++ b/addons/website/static/src/css/website.sass @@ -19,6 +19,7 @@ .mt0 margin-top: 0px !important + html,body height: 100% box-sizing: border-box @@ -36,9 +37,11 @@ html,body footer box-sizing: border-box height: 300px - background: rgb(221, 235, 227) + background: rgb(239, 248, 248) // rgb(221, 235, 227) padding-top: 64px padding-bottom: 64px + //* + color: #1abc9c !important .subheader letter-spacing: 3px @@ -51,5 +54,8 @@ header.navbar-fixed-top background: rgb(239, 248, 248) padding: 64px +h5 + font-weight: bold + .nav > .pull-right float: right !important //bugfix for flatly theme diff --git a/addons/website/views/views.xml b/addons/website/views/views.xml index 248213b79da3..6371811aef73 100644 --- a/addons/website/views/views.xml +++ b/addons/website/views/views.xml @@ -23,7 +23,7 @@ <div class="row"> <div class="span4"> <h5>Product and services</h5> - <ul> + <ul class='unstyled'> <li><a href="https://www.openerp.com/start?download">Download</a></li> <li><a href="https://launchpad.net/openobject">Launchpad</a></li> <li><a href="http://runbot.openerp.com">Automated Tests</a></li> @@ -31,7 +31,7 @@ </div> <div class="span4"> <h5>Social</h5> - <ul> + <ul class='unstyled'> <li><a href="http://twitter.com/openerp"><i class="icon-twitter-sign"></i>Twitter</a></li> <li><a href="http://www.facebook.com/OpenERP"><i class="icon-facebook-sign"></i>Facebook</a></li> <li><a href="https://plus.google.com/+openerp/posts"><i class="icon-google-plus-sign"></i>Google+</a></li> @@ -39,11 +39,11 @@ </div> <div class="span4" name="about_us"> <h5 t-record="res_company" t-field="name">Company name</h5> - <ul> + <ul class='unstyled'> <li><a href="/page/website.contactus">Contact us</a></li> <li><a href="/page/website.news">News</a></li> <li><a href="/page/website.contactus">About us</a></li> - <li>&#x2706; <span t-record="res_company" t-field="phone"/></li> + <li><a href='#'>&#x2706; <span t-record="res_company" t-field="phone"/></a></li> </ul> </div> </div> @@ -72,7 +72,7 @@ <link rel='stylesheet' href='/website/static/lib/bootstrap/css/bootstrap-flatly.css'/> <link rel='stylesheet' href='/web/static/lib/fontawesome/css/font-awesome.css'/> <link rel='stylesheet' href='/website/static/src/css/website.css'/> - <!--<link rel='stylesheet' href='/website/static/lib/bootstrap/css/bootstrap-responsive.css'/>--> + <link rel='stylesheet' href='/website/static/lib/bootstrap/css/bootstrap-responsive.css'/> </head> <body> <div id='wrap'> diff --git a/addons/website_mail/views/website_mail.xml b/addons/website_mail/views/website_mail.xml index b0774ccb8d97..f35a8e65447c 100644 --- a/addons/website_mail/views/website_mail.xml +++ b/addons/website_mail/views/website_mail.xml @@ -26,7 +26,7 @@ <t t-raw="head"/> </t> <t t-set="title">Blog</t> - <div class="container css_website_mail js_website_mail"> + <div class="container mt48 css_website_mail js_website_mail"> <div class="row"> <div class="span4"> <ul class="nav nav-list"> diff --git a/addons/website_sale/static/src/css/ecommerce.css b/addons/website_sale/static/src/css/ecommerce.css index 3a5bdb629c6f..42d72a434b1b 100644 --- a/addons/website_sale/static/src/css/ecommerce.css +++ b/addons/website_sale/static/src/css/ecommerce.css @@ -8,6 +8,12 @@ .oe_ecommerce .oe_total table { width: auto; } +.oe_ecommerce .oe_total td:last-child { + text-align: right; +} +.oe_ecommerce .oe_total th:last-child { + text-align: center; +} .oe_ecommerce .oe_products .oe_product { text-align: center; display: inline-block; @@ -16,6 +22,7 @@ height: 220px; margin-right: 15px; margin-left: 3px; + padding-top: 8px; } .oe_ecommerce .oe_products .oe_product .oe_hidden { visibility: hidden; @@ -90,9 +97,9 @@ -o-border-radius: 5px; border-radius: 5px; border: 1px solid rgba(0, 0, 0, 0.1); - -webkit-box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.1); - -moz-box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.1); - box-shadow: 0 0 3px 1px rgba(0, 0, 0, 0.1); + -webkit-box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.1); + -moz-box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.1); + box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.1); } .oe_ecommerce .oe_button_cart { width: 100%; @@ -189,9 +196,3 @@ left: 0; cursor: pointer; } -.oe_ecommerce .oe_total td:last-child { - text-align: right; -} -.oe_ecommerce .oe_total th:last-child { - text-align: center; -} \ No newline at end of file diff --git a/addons/website_sale/static/src/css/ecommerce.sass b/addons/website_sale/static/src/css/ecommerce.sass index 2a4d4c46db9b..25735c49f58b 100644 --- a/addons/website_sale/static/src/css/ecommerce.sass +++ b/addons/website_sale/static/src/css/ecommerce.sass @@ -37,6 +37,7 @@ height: 220px margin-right: 15px margin-left: 3px + padding-top: 8px &:nth-child(3n) margin-right: 0 .oe_ecommerce_price @@ -77,7 +78,7 @@ margin-bottom: 15px +border-radius(5px) border: 1px solid rgba(0,0,0,.1) - +box-shadow(0 0 3px 1px rgba(0,0,0,.1)) + +box-shadow(0px 1px 3px rgba(0,0,0,.1)) .oe_button_cart width: 100% font-size: 11px diff --git a/addons/website_sale/views/ecommerce.xml b/addons/website_sale/views/ecommerce.xml index 879108f14e2e..af3a666c3e3e 100644 --- a/addons/website_sale/views/ecommerce.xml +++ b/addons/website_sale/views/ecommerce.xml @@ -27,7 +27,7 @@ <t t-raw="head"/> </t> <t t-set="title">Shop - <t t-raw="title">Categories</t></t> - <div class="container oe_ecommerce"> + <div class="container mt48 oe_ecommerce"> <div class="row"> <div class="span4 css_noprint"> <ul class="nav nav-list"> @@ -64,8 +64,8 @@ <t t-call="website_sale.page"> <t t-set="title">Product</t> <t t-set="shop_content"> - <div class="oe_search"> - <form action="/shop" method="get" class="navbar-search"> + <div class="oe_search clearfix"> + <form action="/shop" method="get" class="navbar-search pull-right"> <input type="text" name="search" class="search-query span4" placeholder="Search" t-att-value="search or '' or ''"/> <button type="submit" class="btn">Submit</button> </form> @@ -81,15 +81,15 @@ </template> <template id="product_card"> - <div class="media oe_product"> + <div class="media oe_product span3"> <a t-att-href="'/shop/product/%%s' %% product.id"><h4 class="media-heading"><span t-record="product" t-field="name"><t t-esc="product.name"/></span></h4></a> <a class="pull-left" t-att-href="'/shop/product/%%s' %% product.id"><img class="media-object" t-att-src="'data:image/png;base64,' + product.image"/></a> <div class="media-body"> <div class="oe_ecommerce_description" t-record="product" t-field="description_sale"><t t-esc="product.description_sale"/></div> <div class="oe_ecommerce_price"><span><span t-record="product" t-field="list_price"><t t-esc="product.list_price"/></span>€</span></div> <div class="oe_button_cart"> - <button t-att-class="'btn btn-inverse %%s' %% (not quantity and 'oe_hidden' or '')" t-att-data-id="product.id">Remove one</button> - <button t-att-class="'btn %%s' %% (quantity and 'btn-success' or 'btn-primary')" t-att-data-id="product.id">Add to cart + <button t-att-class="'btn btn-small btn-inverse %%s' %% (not quantity and 'oe_hidden' or '')" t-att-data-id="product.id">Remove one</button> + <button t-att-class="'btn btn-small %%s' %% (quantity and 'btn-success' or 'btn-primary')" t-att-data-id="product.id">Add to cart <span class="oe_txt">(<span class="oe_quantity"><t t-esc="quantity"/></span>)</span> </button> </div> @@ -180,7 +180,7 @@ <t t-raw="head"/> </t> <t t-set="title">Shop - Checkout</t> - <div class="container oe_ecommerce"> + <div class="container mt48 oe_ecommerce"> <div class="row"> <div class="span4 oe_total"> <table class="table table-condensed" t-if="order.order_line"> -- GitLab