diff --git a/tailbone/app.py b/tailbone/app.py index 556189e4..419c9b70 100644 --- a/tailbone/app.py +++ b/tailbone/app.py @@ -1,4 +1,4 @@ -# -*- coding: utf-8 -*- +# -*- coding: utf-8; -*- ################################################################################ # # Rattail -- Retail Software Framework @@ -175,9 +175,7 @@ def main(global_config, **settings): """ This function returns a Pyramid WSGI application. """ - settings.setdefault('mako.directories', [ - 'tailbone:templates/themes/better', - 'tailbone:templates']) + settings.setdefault('mako.directories', ['tailbone:templates']) rattail_config = make_rattail_config(settings) pyramid_config = make_pyramid_config(settings) pyramid_config.include('tailbone') diff --git a/tailbone/static/css/base.css b/tailbone/static/css/base.css index c59635b3..f3cd2ebe 100644 --- a/tailbone/static/css/base.css +++ b/tailbone/static/css/base.css @@ -13,7 +13,7 @@ body { } a { - color: #3D6E1C; + color: #0972a5; text-decoration: none; } @@ -76,6 +76,11 @@ div.error-messages div.ui-state-error { margin-bottom: 8px; } +.flash-messages, +.error-messages { + margin: 0.5em 0 0 0; +} + div.error { color: #dd6666; font-weight: bold; diff --git a/tailbone/static/css/forms.css b/tailbone/static/css/forms.css index 0338f5ec..a08bf6d5 100644 --- a/tailbone/static/css/forms.css +++ b/tailbone/static/css/forms.css @@ -36,6 +36,10 @@ div.fieldset { margin-top: 10px; } +.form { + padding-left: 5em; +} + /****************************** * Fieldsets diff --git a/tailbone/static/css/grids.css b/tailbone/static/css/grids.css index c9692c85..04cb867f 100644 --- a/tailbone/static/css/grids.css +++ b/tailbone/static/css/grids.css @@ -21,6 +21,11 @@ white-space: nowrap; } +.grid-wrapper .grid-header #context-menu { + float: none; + margin: 0; +} + .grid-wrapper .grid-header td.tools { margin: 0; padding: 0; diff --git a/tailbone/static/css/layout.css b/tailbone/static/css/layout.css index 5c303d21..39e38164 100644 --- a/tailbone/static/css/layout.css +++ b/tailbone/static/css/layout.css @@ -57,6 +57,59 @@ body > #body-wrapper { margin-left: 0.5em; } +/* new stuff from 'better' theme begins here */ + +header .global { + background-color: #eaeaea; + height: 60px; +} + +header .global a.home, +header .global a.global, +header .global span.global { + display: block; + float: left; + font-size: 2em; + font-weight: bold; + line-height: 60px; + margin-left: 10px; +} + +header .global a.home img { + display: block; + float: left; + padding: 5px 5px 5px 30px; +} + +header .global .grid-nav { + display: inline-block; + font-size: 16px; + font-weight: bold; + line-height: 60px; + margin-left: 5em; +} + +header .global .grid-nav .ui-button, +header .global .grid-nav span.viewing { + margin-left: 1em; +} + +header .global .feedback { + float: right; + line-height: 60px; + margin-right: 1em; +} + +header .page { + border-bottom: 1px solid lightgrey; + padding: 0.5em; +} + +header .page h1 { + margin: 0; + padding: 0 0 0 0.5em; +} + /****************************** * Logo ******************************/ @@ -67,6 +120,29 @@ body > #body-wrapper { } +/**************************************** + * content + ****************************************/ + +body > #body-wrapper { + margin: 0px; + position: relative; +} + +.content-wrapper { + height: 100%; + padding-bottom: 30px; +} + +#scrollpane { + height: 100%; +} + +#scrollpane .inner-content { + padding: 0 0.5em 0.5em 0.5em; +} + + /****************************** * context menu ******************************/ @@ -74,7 +150,9 @@ body > #body-wrapper { #context-menu { float: right; list-style-type: none; + margin: 0.5em; text-align: right; + white-space: nowrap; } @@ -110,3 +188,19 @@ body > #body-wrapper { overflow: auto; padding: 5px; } + +/**************************************** + * footer + ****************************************/ + +#footer { + border-top: 1px solid lightgray; + bottom: 0; + font-size: 9pt; + height: 20px; + left: 0; + line-height: 20px; + margin: 0; + position: absolute; + width: 100%; +} diff --git a/tailbone/static/css/theme-better.css b/tailbone/static/css/theme-better.css deleted file mode 100644 index d06584df..00000000 --- a/tailbone/static/css/theme-better.css +++ /dev/null @@ -1,124 +0,0 @@ - -/********************************************************************** - * styles for 'better' theme - **********************************************************************/ - -/**************************************** - * core overrides - ****************************************/ - -a { - color: #0972a5; -} - -.flash-messages, -.error-messages { - margin: 0.5em 0 0 0; -} - -#context-menu { - margin: 0.5em; - white-space: nowrap; -} - -.form { - padding-left: 5em; -} - -.grid-wrapper .grid-header #context-menu { - float: none; - margin: 0; -} - -/**************************************** - * header - ****************************************/ - -header .global { - background-color: #eaeaea; - height: 60px; -} - -header .global a.home, -header .global a.global, -header .global span.global { - display: block; - float: left; - font-size: 2em; - font-weight: bold; - line-height: 60px; - margin-left: 10px; -} - -header .global a.home img { - display: block; - float: left; - padding: 5px 5px 5px 30px; -} - -header .global .grid-nav { - display: inline-block; - font-size: 16px; - font-weight: bold; - line-height: 60px; - margin-left: 5em; -} - -header .global .grid-nav .ui-button, -header .global .grid-nav span.viewing { - margin-left: 1em; -} - -header .global .feedback { - float: right; - line-height: 60px; - margin-right: 1em; -} - -header .page { - border-bottom: 1px solid lightgrey; - padding: 0.5em; -} - -header .page h1 { - margin: 0; - padding: 0 0 0 0.5em; -} - -/**************************************** - * content - ****************************************/ - -body > #body-wrapper { - margin: 0px; - position: relative; -} - -.content-wrapper { - height: 100%; - padding-bottom: 30px; -} - -#scrollpane { - height: 100%; -} - -#scrollpane .inner-content { - padding: 0 0.5em 0.5em 0.5em; -} - -/**************************************** - * footer - ****************************************/ - -#footer { - border-top: 1px solid lightgray; - bottom: 0; - font-size: 9pt; - height: 20px; - left: 0; - line-height: 20px; - margin: 0; - position: absolute; - width: 100%; -} diff --git a/tailbone/templates/base.mako b/tailbone/templates/base.mako index a929dfe1..c4f8b01d 100644 --- a/tailbone/templates/base.mako +++ b/tailbone/templates/base.mako @@ -1,124 +1,132 @@ -## -*- coding: utf-8 -*- +## -*- coding: utf-8; -*- +<%namespace file="/menu.mako" import="main_menu_items" /> +<%namespace file="/grids/nav.mako" import="grid_index_nav" /> - + - ${self.global_title()} » ${capture(self.title)} - - ${self.core_javascript()} - ${self.core_styles()} - ${self.extra_styles()} + ${self.global_title()} » ${capture(self.title)|n} + ${self.favicon()} + ${self.header_core()} + + % if not request.rattail_config.production(): + + % endif + ${self.head_tags()} -
-