More CSS changes to the new theme.

--HG--
branch : dev
This commit is contained in:
Jonathan Wall
2010-10-11 12:48:15 -07:00
parent 925fd6b916
commit dd8297eafd
2 changed files with 82 additions and 58 deletions

View File

@@ -63,7 +63,7 @@ header, footer, aside, nav, article {
visibility: hidden;
}
.group {display: inline-block;} /* for IE/Mac */
/*.group {display: inline-block;}*/ /* for IE/Mac */
/* Typography (Optional)
***************************************************************/
@@ -102,38 +102,67 @@ h4 img, h5 img, h6 img {
margin: 0;
}
p {
p, .meta {
font-size:1.3em;
line-height:2em;
}
/* Structure
***************************************************************/
#layout-wrapper, #layout-header {
#layout-header, #layout-content, #layout-footer {
width:960px;
margin:0 auto;
}
#header {}
#logo {}
#layout-header {
border:1px solid #ff0000;
background: #53a4ca;
}
#branding a {
color:#fff;
text-decoration:none;
padding:48px 12px;
}
/* Navigation
#layout-wrapper {
border:1px solid #CCC;
}
nav ul li {
margin:2em 0 0 0;
/* Sidebar off - Content Zone 960 */
#content {
clear:both;
/*padding:12px;*/
}
/*Right Sidebar on - Content Zone 600 */
.has-sidebar #content {
background-color:#e8e8e8;
width: 600px;
/*padding:12px 6px 6px 12px;*/
float:left;
}
clear:both;
}
nav ul li a {
font-size:1.4em;
margin:0 1.8em;
display:block;
text-decoration:none;
text-transform:uppercase;
float:left;
} */
/*Left Sidebar on - Content Zone 600
.has-sidebar #content {
float:right;
}*/
.sidebar {
background-color:#f6f6f6;
width: 360px;
float:right;
}
#sitemap {
clear:both;
}
/* Navigation */
#navigation {
@@ -232,43 +261,14 @@ form.inline p { margin-bottom:0; }
/* For testing purposes */
#layout-header {
border:1px solid #CCC;
}
#layout-wrapper {
border:1px solid #CCC;
}
/* Sidebar off - Content Zone 960 */
#content {
clear:both;
padding:12px;
}
/* Sidebar on - Content Zone 600 */
.has-sidebar #content {
background-color:#e8e8e8;
width: 582px;
padding:12px 6px 6px 12px;
float:left;
clear:both;
}
.sidebar {
background-color:#f6f6f6;
width: 360px;
float:right;
}
#sitemap {
clear:both;
}
.zone {
padding:6px;
/*padding:6px;*/
}
/* Featured Zone - switch to an image */
.featuredimage {

View File

@@ -8,14 +8,27 @@
Func<dynamic, dynamic> Zone = x => Display(x);
if (Model.Sidebar != null) {
Html.AddPageClassNames(new[]{"has-sidebar"});
Model.Classes.Add("has-sidebar");
}
//Model.Attributes.Add("onclick", "javscript:alert('woot')");
Model.Id = "layout-wrapper";
var tag = Tag (Model, "div");
}
@* Add a wrapping div around everything *@
@tag.StartElement
@* needs to be the page title, not page (head) title... *@
@* Adds text and html to the header zone *@
@using(Capture(branding => WorkContext.Layout.Header.Add(branding) )) {
<h1 id="branding"><a href="@homeUrl">@WorkContext.CurrentSite.SiteName</a></h1>
}
<header id="layout-header">
@* needs to be the page title, not page (head) title... *@
<h1><a href="@homeUrl">@WorkContext.CurrentSite.SiteName</a></h1>
@if(Model.Header != null) {
<div id="header">
@Zone(Model.Header)
@@ -31,7 +44,7 @@
}
<div id="layout-wrapper">
<div id="layout-content" class="group">
@if(Model.Messages != null) {
<div id="messages">
@Zone(Model.Messages)
@@ -60,6 +73,13 @@
</div>
}
@{WorkContext.Layout.Sidebar1.Add("just some text in featured");}
@if(Model.Sidebar1 != null) {
<aside class="sidebar">
@Zone(Model.Sidebar1)
</aside>
}
@* the model content for the page is in the Content zone @ the default position (nothing, zero, zilch) *@
@if(Model.Content != null) {
<div id="content" class="group">
@@ -78,16 +98,20 @@
</aside>
}
</div>
@{
WorkContext.Layout.Footer.Add(@Display.User());
}
@if(Model.Footer != null) {
<footer>
<footer id="layout-footer" class="group">
@Zone(Model.Footer)
</footer>
}
else {
<footer id="sitemap">
<footer id="layout-footer">
Powered by Orchard @Display.User()
</footer>
}
</div>
@tag.EndElement