From: Radek Czajka Date: Tue, 6 Mar 2012 15:47:48 +0000 (+0100) Subject: css for smaller screens X-Git-Url: https://git.mdrn.pl/wolnelektury.git/commitdiff_plain/00191feb9676be79e2f1da3fca8345f582d8e7d0?ds=inline;hp=-c css for smaller screens --- 00191feb9676be79e2f1da3fca8345f582d8e7d0 diff --git a/wolnelektury/settings.py b/wolnelektury/settings.py index a1ad8785c..8ee4e43de 100644 --- a/wolnelektury/settings.py +++ b/wolnelektury/settings.py @@ -207,6 +207,13 @@ COMPRESS_CSS = { ], 'output_filename': 'css/all.min?.css', }, + 'screen': { + 'source_filenames': ['css/screen.css'], + 'output_filename': ['css/screen.min?.css'], + 'extra_context': { + 'media': 'screen and (min-width: 800px)', + }, + }, 'ie': { 'source_filenames': [ 'css/ie.css', diff --git a/wolnelektury/static/css/base.css b/wolnelektury/static/css/base.css index 70aa172de..3160611e5 100755 --- a/wolnelektury/static/css/base.css +++ b/wolnelektury/static/css/base.css @@ -64,14 +64,6 @@ ul.plain { padding: 0; } -.left-column { - width: 47em; - float: left; -} -.right-column { - float:right; - width: 47em; -} .normal-text { font-size: 1.3em; line-height: 1.3em; @@ -125,13 +117,6 @@ h2 { box-shadow: 2px 2px 2px #ddd; } - -#header-content, div#main-content, div#half-header-content, #footer-content { - width: 97.5em; - margin: auto; -} - - .page-desc { margin-left: 1.5em; } @@ -175,7 +160,6 @@ h2 { column-width: 12em; -moz-column-width: 12em; -webkit-column-width: 12em; - width: 48em; } .hidden-box li { margin-bottom: .5em; diff --git a/wolnelektury/static/css/book_box.css b/wolnelektury/static/css/book_box.css index 876bf06b0..6b2806851 100755 --- a/wolnelektury/static/css/book_box.css +++ b/wolnelektury/static/css/book_box.css @@ -17,8 +17,6 @@ } .book-wide-box { - width: 97.5em; - /** This is a fullpage box, it must be aligned with the top menu. This corresponds to a .1em margin below **/ margin-left: -0.1em; @@ -60,16 +58,11 @@ min-height: 24.4em; } -.search-result { - width: 97.5em; -} - .search-result .book-box-body { width: 31em; } .book-list-header { - width: 97.5em; padding: 0em; margin-left: -0.1em; } @@ -202,6 +195,9 @@ font-size: 1.1em; } +.book-wide-box { + min-width: 48.75em; +} .book-wide-box .book-box-tools { margin-left: 14em; width: 32em; @@ -209,6 +205,7 @@ .book-wide-box #theme-list-wrapper { margin-left: 15.4em; + margin-bottom: 3em; width: 30em; } @@ -260,11 +257,6 @@ ul.book-box-tools { width: 7em; } -.book-wide-box .right-column { - float: right; - width: 41.5em; -} - ul.inline-items, ul.inline-items li { margin: 0; padding: 0; @@ -329,11 +321,6 @@ ul.inline-items li { display: none; } -.snippets { - width: 44em; - float: right; -} - .snippets .snippet-text { background: #f7f7f7; font-size: 1.2em; diff --git a/wolnelektury/static/css/catalogue.css b/wolnelektury/static/css/catalogue.css index 74338f877..0e952ba7d 100755 --- a/wolnelektury/static/css/catalogue.css +++ b/wolnelektury/static/css/catalogue.css @@ -14,15 +14,12 @@ } -#tagged-object-list .left-column, #tagged-object-list .right-column { - width: 48em; -} - - /* listing of all books */ #book-list { padding-left: 50px; } +/* FIXME: MEDIA? + * #book-list-nav { position: absolute; right: 50px; @@ -31,6 +28,7 @@ padding: 10px; font-size: 1.2em; } + */ #book-list-nav ul { list-style-type: none; @@ -112,7 +110,6 @@ width: 7em; } .inline-body { - width: 35em; display: inline-block; vertical-align: top; margin-bottom: .5em; diff --git a/wolnelektury/static/css/cite.css b/wolnelektury/static/css/cite.css index 91c685138..69c28a7f2 100755 --- a/wolnelektury/static/css/cite.css +++ b/wolnelektury/static/css/cite.css @@ -26,13 +26,14 @@ #big-cite { - background-color: #bd9a89; /* average image color */ - color: white; + background-color: white; /* #bd9a89; /* average image color */ + color: black; padding: 0; margin: 0; background-image: url(/static/img/backdrop/horiavarlan-4268896468.jpg); background-size: 100%; background-position: 50% 70%; + background-repeat: no-repeat; } #big-cite .cite { @@ -49,7 +50,7 @@ #big-cite .cite-body { - margin: .05em .05em .05em 17.5em; + margin: .05em .05em .05em 1em; } #big-cite .cite-body span { font-size: 3em; @@ -57,9 +58,7 @@ } #big-cite .vip { - float:left; - text-align:right; - width: 14.7em; + margin-left: 1em; margin-top: .25em; } @@ -86,7 +85,7 @@ #big-cite .source { - margin: 1.6em 0.2em 1.6em 17.5em; + margin: 1.6em 0.2em 1.6em 1em; } #big-cite .source span { font-size: 1.2em; diff --git a/wolnelektury/static/css/header.css b/wolnelektury/static/css/header.css index ef47897e3..0cde9e025 100755 --- a/wolnelektury/static/css/header.css +++ b/wolnelektury/static/css/header.css @@ -7,7 +7,6 @@ } #header { - height: 3em; padding-top: 1.9em; padding-bottom: 0; color: #989898; @@ -27,17 +26,6 @@ } -#user-info { - float: right; - margin: 0; -} - -#logo { - position: absolute; - top: -1.6em; - margin-left: 1.5em; -} - #logo a { color:#f7f7f7; font-size: 2.05em; @@ -45,27 +33,30 @@ } #tagline { - display: inline-block; - margin-left: 25.5em; + margin-left: 1.5em; } + #tagline span { font-size: 1.3em; color: #bbb; } +#user-info { + margin: 0; + padding: 1em 0; + margin-left: 1.5em; +} + #search-area { margin: 0; background: #444; color: white; - margin-left: 24em; - width: 73.5em; } #search-field { display: inline-block; - width: 63.1em; padding-left: .5em; - padding-right: 0; + padding-right: .5em; padding-top: 0.5em; padding-bottom: 0; } @@ -84,7 +75,6 @@ -moz-box-shadow:0 0 .5em #444 inset; box-shadow: 0 0 .5em #444 inset;*/ height: 2.54em; - width: 47.47em; padding-left: 1em; -webkit-border-radius: .38em; -moz-border-radius: .38em; @@ -132,7 +122,6 @@ padding: 0; margin: 0; width: 9.4em; - float: right; } #search-button button { font-size: 1em; diff --git a/wolnelektury/static/css/logo.css b/wolnelektury/static/css/logo.css index c7e788299..611b4ba94 100644 --- a/wolnelektury/static/css/logo.css +++ b/wolnelektury/static/css/logo.css @@ -9,7 +9,9 @@ src: url(/static/fonts/WL.ttf) format("truetype"); } +#logo { + margin-left: 1.5em; +} #logo a { font-family: WL-Logo; - line-height: 7em; } diff --git a/wolnelektury/static/css/main_page.css b/wolnelektury/static/css/main_page.css index bc8e68fda..b564e825b 100755 --- a/wolnelektury/static/css/main_page.css +++ b/wolnelektury/static/css/main_page.css @@ -1,8 +1,6 @@ #promo-box { - float: right; width: 32em; - margin-top: -5.1em; } #promo-box-header { padding-top: 2em; @@ -19,7 +17,6 @@ #promo-box-body { border-bottom: 2px solid #efefef; padding: 2em 2.8em; - height: 30em; background: #efefef; } #promo-box-title { @@ -89,7 +86,7 @@ } .infopages-box .social-links a { - font-family: WL-Nav; + font-family: WL-Nav, courier; font-size: 3em; color: #281d1c; margin-right: .2em; diff --git a/wolnelektury/static/css/screen.css b/wolnelektury/static/css/screen.css new file mode 100644 index 000000000..3a344dc59 --- /dev/null +++ b/wolnelektury/static/css/screen.css @@ -0,0 +1,132 @@ +.left-column { + width: 47em; + float: left; +} +.right-column { + float:right; + width: 47em; +} + +.hidden-box ul { + width: 48em; +} + +#header-content, div#main-content, div#half-header-content, #footer-content { + width: 97.5em; + margin: auto; +} + +#promo-box { + float: right; + margin-top: -5.1em; +} + +#promo-box-body { + height: 30em; +} + +#big-cite .vip { + float:left; + text-align:right; + width: 14.7em; +} + +#big-cite .cite-body { + margin-left: 17.5em; +} + +#big-cite .source { + margin-left: 17.5em; +} + + +.book-wide-box { + width: 97.5em; +} +.book-wide-box .book-box-body { + width: 38.2em; +} + + +#tagged-object-list .left-column, #tagged-object-list .right-column { + width: 48em; +} + + + + +.inline-body { + width: 35em; +} + + +.search-result { + width: 97.5em; +} + + +.book-list-header { + width: 97.5em; +} + +.book-wide-box .right-column { + width: 41.5em; + margin-top: -23em; +} + +.book-wide-box #theme-list-wrapper { + margin-bottom: 0; +} + +.snippets { + width: 44em; + float: right; + margin-top: -20em; +} + +/* LOGO */ + +#logo a { + line-height: 7em; +} + + +/* HEADER */ + +#header { + height: 3em; +} + +#logo { + position: absolute; + top: -1.6em; +} + +#user-info { + float: right; + padding: 0 !important; + margin-left: 0; +} + +#tagline { + display: inline-block; + margin-left: 25.5em; +} + +#search-area { + margin-left: 24em; + width: 73.5em; +} + +#search-field { + width: 63.1em; + padding-right: 0 !important; +} + +#search { + width: 47.47em; +} + +#search-button { + float: right; +} diff --git a/wolnelektury/templates/base.html b/wolnelektury/templates/base.html index 554e6d39b..e3faca161 100644 --- a/wolnelektury/templates/base.html +++ b/wolnelektury/templates/base.html @@ -11,6 +11,7 @@ {% compressed_css "all" %} + {% compressed_css "screen" %} diff --git a/wolnelektury/templates/catalogue/book_short.html b/wolnelektury/templates/catalogue/book_short.html index 77e775ed3..3541d0f74 100644 --- a/wolnelektury/templates/catalogue/book_short.html +++ b/wolnelektury/templates/catalogue/book_short.html @@ -16,8 +16,6 @@ " alt="Cover" /> {% endif %} - {% block right-column %} - {% endblock %}
@@ -106,6 +104,8 @@ {% block book-box-extra-info %}{% endblock %} {% block box-append %} {% endblock %} + {% block right-column %} + {% endblock %}
diff --git a/wolnelektury/templates/lesmianator/poem.html b/wolnelektury/templates/lesmianator/poem.html index 78c5d5fb3..5d44a26f9 100644 --- a/wolnelektury/templates/lesmianator/poem.html +++ b/wolnelektury/templates/lesmianator/poem.html @@ -20,9 +20,7 @@ Wolne Lektury przepuszczone przez mikser.

diff --git a/wolnelektury/templates/main_page.html b/wolnelektury/templates/main_page.html index 77dff582a..9e8f92243 100755 --- a/wolnelektury/templates/main_page.html +++ b/wolnelektury/templates/main_page.html @@ -57,9 +57,9 @@