mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
Changing the default theme to TheThemeMachine, adding some more content widgets @ startup (for lack of a better place ATM - distro or some filler content scheme) and some shape templates
--HG-- branch : dev
This commit is contained in:
@@ -1,14 +0,0 @@
|
||||
<div>
|
||||
<h1>First Leader Aside</h1>
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Curabitur a nibh ut tortor dapibus vestibulum. Aliquam vel sem nibh. Suspendisse vel condimentum tellus.</p>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<h1>Second Leader Aside</h1>
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Curabitur a nibh ut tortor dapibus vestibulum. Aliquam vel sem nibh. Suspendisse vel condimentum tellus.</p>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<h1>Third Leader Aside</h1>
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Curabitur a nibh ut tortor dapibus vestibulum. Aliquam vel sem nibh. Suspendisse vel condimentum tellus.</p>
|
||||
</div>
|
@@ -0,0 +1,17 @@
|
||||
@using Orchard.ContentManagement;
|
||||
@using Orchard.Widgets.Models;
|
||||
@{
|
||||
var title = ((IContent)Model.ContentItem).As<WidgetPart>().Title;
|
||||
}
|
||||
<article>
|
||||
<header>
|
||||
<h1>@title</h1>
|
||||
@Display(Model.Header)
|
||||
</header>
|
||||
@Display(Model.Content)
|
||||
@if(Model.Footer != null) {
|
||||
<footer>
|
||||
@Display(Model.Footer)
|
||||
</footer>
|
||||
}
|
||||
</article>
|
@@ -0,0 +1,11 @@
|
||||
@using Orchard.ContentManagement;
|
||||
@using Orchard.Widgets.Models;
|
||||
@{
|
||||
var title = ((IContent)Model.ContentItem).As<WidgetPart>().Title;
|
||||
}
|
||||
<div>
|
||||
<h1>@title</h1>
|
||||
@Display(Model.Header)
|
||||
@Display(Model.Content)
|
||||
@Display(Model.Footer)
|
||||
</div>
|
@@ -43,71 +43,54 @@
|
||||
@using(Capture(branding => WorkContext.Layout.Header.Add(branding) )) {
|
||||
<h1 id="branding"><a href="@homeUrl">@WorkContext.CurrentSite.SiteName</a></h1>
|
||||
}
|
||||
|
||||
<header id="layout-header">
|
||||
@if(Model.Header != null) {
|
||||
<div id="header">
|
||||
@Zone(Model.Header)
|
||||
</div>
|
||||
}
|
||||
</header>
|
||||
|
||||
|
||||
@if(Model.Navigation != null) {
|
||||
<div id="navigation" class="group">
|
||||
@Zone(Model.Navigation)
|
||||
</div>
|
||||
}
|
||||
|
||||
|
||||
@if(Model.Header != null) {
|
||||
<header id="layout-header">
|
||||
<div id="header">
|
||||
@Zone(Model.Header)
|
||||
</div>
|
||||
</header>
|
||||
}
|
||||
@if(Model.Navigation != null) {
|
||||
<div id="navigation" class="group">
|
||||
@Zone(Model.Navigation)
|
||||
</div>
|
||||
}
|
||||
<div id="layout-content" class="group">
|
||||
@if(Model.Messages != null) {
|
||||
<div id="messages">
|
||||
@Zone(Model.Messages)
|
||||
</div>
|
||||
}
|
||||
|
||||
@if(Model.AsideSecond != null) {
|
||||
<aside class="aside second">
|
||||
@Zone(Model.AsideSecond)
|
||||
</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">
|
||||
@Zone(Model.Content)
|
||||
</div>
|
||||
}
|
||||
|
||||
|
||||
@if(Model.AsideFirst != null) {
|
||||
<aside class="aside first">
|
||||
@Zone(Model.AsideFirst)
|
||||
</aside>
|
||||
|
||||
@* Create a zone and only show it on the home page. *@
|
||||
|
||||
@if (Request.Path == "/OrchardLocal") {
|
||||
WorkContext.Layout.AsideThird.Add(New.AsideThird());
|
||||
}
|
||||
}
|
||||
@if(Model.AsideThird != null) {
|
||||
<aside class="aside third group">
|
||||
@Zone(Model.AsideThird)
|
||||
</aside>
|
||||
}
|
||||
|
||||
</div>
|
||||
|
||||
@if(Model.Footer != null) {
|
||||
<footer id="layout-footer" class="group">
|
||||
@Zone(Model.Footer)
|
||||
</footer>
|
||||
}
|
||||
else {
|
||||
<footer id="layout-footer" class="group">
|
||||
Powered by Orchard © The Theme Machine 2010. @Display.User()
|
||||
</footer>
|
||||
@* span -> p (?) *@
|
||||
@using(Capture(pbo => WorkContext.Layout.Footer.Add(pbo) )) {
|
||||
<span>Powered by Orchard © The Theme Machine 2010.</span>
|
||||
}
|
||||
@if(Model.Footer != null) {
|
||||
<footer id="layout-footer" class="group">
|
||||
@Zone(Model.Footer)
|
||||
@Display.User()
|
||||
</footer>
|
||||
}
|
||||
|
||||
@tag.EndElement
|
@@ -1,10 +0,0 @@
|
||||
@{
|
||||
// Model is Model.Menu from the layout (Layout.Menu)
|
||||
var tag = Tag(Model, "ul");
|
||||
}
|
||||
<nav>
|
||||
@tag.StartElement
|
||||
@* see MenuItem shape template *@
|
||||
@DisplayChildren(Model)
|
||||
@tag.EndElement
|
||||
</nav>
|
@@ -1,22 +0,0 @@
|
||||
@{
|
||||
// odd formatting in this file is to cause more attractive results in the output.
|
||||
var items = (IEnumerable<dynamic>)Enumerable.Cast<dynamic>(Model);
|
||||
}
|
||||
@{
|
||||
if (!HasText(Model.Text)) {
|
||||
@DisplayChildren(Model)
|
||||
} else {
|
||||
if (Model.Href.TrimEnd('/').ToUpperInvariant() == Request.Path.TrimEnd('/').ToUpperInvariant()) {
|
||||
Model.Classes.Add("current");
|
||||
}
|
||||
var tag = Tag(Model, "li");
|
||||
@tag.StartElement
|
||||
<a href="@Model.Href">@Model.Text</a>
|
||||
if (items.Any()) {
|
||||
<ul>
|
||||
@DisplayChildren(Model)
|
||||
</ul>
|
||||
}
|
||||
@tag.EndElement
|
||||
}
|
||||
}
|
@@ -1,21 +0,0 @@
|
||||
@using Orchard.Mvc.Html;
|
||||
@using Orchard.UI.Resources;
|
||||
@{
|
||||
RegisterLink(new LinkEntry {Type = "image/x-icon", Rel = "shortcut icon", Href = Url.Content("~/modules/orchard.themes/Content/orchard.ico")});
|
||||
//todo: (heskew) get conditions (as in conditional comments) hooked up for script tags too
|
||||
Script.Include("html5.js").AtLocation(ResourceLocation.Head);
|
||||
}
|
||||
<!DOCTYPE html>
|
||||
<html lang="en" class="static @Html.ClassForPage()">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<title>@Model.Title</title>
|
||||
@Display(Model.Head)
|
||||
<script>(function(d){d.className="dyn"+d.className.substring(6,d.className.length);})(document.documentElement);</script>
|
||||
</head>
|
||||
<body>
|
||||
@* Layout (template) is in the Body zone @ the default position (nothing, zero, zilch) *@
|
||||
@Display(Model.Body)
|
||||
@Display(Model.Tail)
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user