Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

MINOR: better widget test content

MINOR: comments
MINOR: moved footer and header into includes
  • Loading branch information...
commit 664cf257e69c1ee0de73dd7dc3d5bc2a9e5559ac 1 parent 316b7d0
authored February 24, 2012
1  css/responsive.css
@@ -27,6 +27,7 @@
27 27
     /* in this layout we have 2 per row, so enable it  */
28 28
     clear: both; } }
29 29
 /* this applies to handhelds in portrait orientation */
  30
+/* TODO test all mobile devices */
30 31
 @media only screen and (max-width: 479px),
31 32
 	   only screen and (-webkit-min-device-pixel-ratio : 1.5),
32 33
 	   only screen and (min-device-pixel-ratio : 1.5) {
1  scss/responsive.scss
@@ -47,6 +47,7 @@
47 47
 }
48 48
 
49 49
 /* this applies to handhelds in portrait orientation */
  50
+/* TODO test all mobile devices */
50 51
 @media only screen and (max-width: 479px),
51 52
 	   only screen and (-webkit-min-device-pixel-ratio : 1.5),
52 53
 	   only screen and (min-device-pixel-ratio : 1.5) {
12  templates/Includes/Footer.ss
... ...
@@ -0,0 +1,12 @@
11  templates/Includes/Header.ss
... ...
@@ -0,0 +1,11 @@
  1
+<div class="header-wrapper">
  2
+	<div class="header">
  3
+		<div class="logo">
  4
+			<h1>$SiteConfig.Title</h1>
  5
+			<p>$SiteConfig.Tagline</p>
  6
+		</div>
  7
+		$SearchForm
  8
+		<% include Navigation %>
  9
+		<div class="clear"></div>
  10
+	</div>
  11
+</div>
28  templates/Includes/Widgets.ss
... ...
@@ -1,20 +1,28 @@
1 1
 <%-- 2 widget areas are expected, named "WidgetsRight" and "WidgetsBottm" --%>
2 2
 <%-- see the readme on how to add widgets to your site --%>
  3
+
  4
+<%-- only display the widgets container if we have widgets, this 'if' is also in Page.ss, to make the content holder full width if no widgets are avaliable --%>
  5
+<%-- the URLSegment == 'home' part is only for the preview, and will be removed on release --%>
  6
+<% if WidgetsRight || WidgetsBottom || URLSegment == 'home' %>
3 7
 <div class="widgets-right">
4 8
 	$WidgetsRight
5 9
 	
6  
-	<%-- temporary some example content for widgets, tuntil widgets work in ss3 --%>
7  
-	<div class="typography column widget columns-2perrow-newrow"><h2>headline</h2>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. </div>
8  
-	<div class="typography column widget "><h2>headline</h2>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. </div>
9  
-	<div class="typography column widget columns-2perrow-newrow"><h2>headline</h2>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. </div>
  10
+	<% if URLSegment == 'home' %>
  11
+		<%-- temporary some example content for widgets, tuntil widgets work in ss3 --%>
  12
+		<div class="typography column widget columns-2perrow-newrow"><h2>Widget</h2>This is a place holder, here will soon be a bunch of real widgets.<br><br>Widgets can be easily and dynamically added and removed in the CMS.</div>
  13
+		<div class="typography column widget "><h2>Blog</h2>This could be a blog widget, showing you the last blog posts.<br>If only widgets and the blog module would work with ss3 already ;)</div>
  14
+		<div class="typography column widget columns-2perrow-newrow"><h2>Widget Headline</h2>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. </div>
  15
+	<% end_if %>
10 16
 	
11 17
 </div>
12 18
 <div class="widgets-bottom">
13 19
 	$WidgetsBottom
14 20
 	
15  
-	<%-- temporary some example content for widgets, tuntil widgets work in ss3 --%>
16  
-	<div class="typography column widget widget-bottom columns-3perrow-newrow"><h2>headline</h2>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. </div>
17  
-	<div class="typography column widget widget-bottom columns-2perrow-newrow"><h2>headline</h2>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. </div>
18  
-	<div class="typography column widget widget-bottom"><h2>headline</h2>Erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. </div>
19  
-		
20  
-</div>
  21
+	<% if URLSegment == 'home' %>
  22
+		<%-- temporary some example content for widgets, tuntil widgets work in ss3 --%>
  23
+		<div class="typography column widget widget-bottom columns-3perrow-newrow"><h2>Widget Headline</h2>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. </div>
  24
+		<div class="typography column widget widget-bottom columns-2perrow-newrow"><h2>Widget Headline</h2>Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. </div>
  25
+		<div class="typography column widget widget-bottom"><h2>Widget Headline</h2>Erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. </div>
  26
+	<% end_if %>
  27
+</div>
  28
+<% end_if %>
6  templates/Layout/Page.ss
... ...
@@ -1,5 +1,7 @@
1  
-<div class="typography column big content">
  1
+<%-- if we have a sidebar, make it a big column, if we have no sidebar, make it a full width column --%>
  2
+<%-- the URLSegment == 'home' part is only for the preview, and will be removed on release --%>
  3
+<div class="typography content column <% if Menu(2) || WidgetsRight || URLSegment == 'home' %>big<% else %>full<% end_if %>">
2 4
 	<h1>$Title</h1>
3 5
 	$Content
4 6
 	$Form
5  
-</div> 
  7
+</div>
24  templates/Page.ss
@@ -22,16 +22,7 @@
22 22
 	<body>
23 23
 		<div id="top" class="container">
24 24
 			
25  
-			<div class="header-wrapper">
26  
-				<div class="header">
27  
-					<div class="logo">
28  
-						<h1>$SiteConfig.Title</h1>
29  
-						<p>$SiteConfig.Tagline</p>
30  
-					</div>
31  
-					<% include Navigation %>
32  
-					<div class="clear"></div>
33  
-				</div>
34  
-			</div>
  25
+			<% include Header %>
35 26
 			
36 27
 			<div class="layout-wrapper">
37 28
 				<div class="layout">
@@ -43,18 +34,7 @@
43 34
 				<% include SocialMedia %>
44 35
 			</div>
45 36
 			
46  
-			<div class="footer">
47  
-				<p class="left"><a class="icons-backtotop" href="#top"><% _t('BACKTOTOP', 'Back to top') %></a></p>
48  
-				<%-- hardcoded link to your site notice, contact page or something like this, which doesn't really belong into the navigation --%>
49  
-				<p class="right"><a class="icons-sitenotice" href="/sitenotice"><% _t('SITENOTICE', 'site notice') %></a></p>
50  
-				<p>
51  
-					<% _t('COPYRIGHT', 'Copyright') %> &copy; $Now.Year
52  
-					<span class="seperator"> | </span><span class="break"><br /></span><%-- use seperator on desktop, and line break on handhelds --%>
53  
-					<% _t('THEMEBY', 'Theme by') %> <a href="http://www.jungbrunnen.xxx" title="Hannes Wizany (Design) and Zauberfisch (Code)" target="_blank">jungbrunnen</a>
54  
-					<span class="seperator"> | </span><span class="break"><br /></span><%-- use seperator on desktop, and line break on handhelds --%>
55  
-					<% _t('POWEREDBY', 'Powered by') %> <a href="http://silverstripe.org" title="This site runs on the SilverStripe CMS" target="_blank">SilverStripe Open Source CMS</a>
56  
-				</p>
57  
-			</div>
  37
+			<% include Footer %>
58 38
 			
59 39
 		</div>
60 40
 	</body>

0 notes on commit 664cf25

Please sign in to comment.
Something went wrong with that request. Please try again.