From 2d128620c648332dce7eb50d7506a790ec92000d Mon Sep 17 00:00:00 2001
From: Philipp Oppermann
Date: Sat, 30 Apr 2016 13:32:13 +0200
Subject: [PATCH] Recreate bare-bones and memory-management sections
---
layouts/index.html | 8 ++++++--
static/css/main.css | 47 ++++++++++++++++++++++++++++++++++++++++++++
static/css/poole.css | 5 ++---
3 files changed, 55 insertions(+), 5 deletions(-)
diff --git a/layouts/index.html b/layouts/index.html
index 569eb3af..de73e7d4 100644
--- a/layouts/index.html
+++ b/layouts/index.html
@@ -12,11 +12,15 @@
{{ end }}
-
+
Bare Bones
+
{{ range first 4 (where .Site.Pages.ByDate "Section" "post") }}
{{ .Render "teaser" }}
{{ end }}
-
+
+
+
Memory Management
+
{{ range first 4 (after 4 (where .Site.Pages.ByDate "Section" "post")) }}
{{ .Render "teaser" }}
{{ end }}
diff --git a/static/css/main.css b/static/css/main.css
index b38b1130..996f2eb5 100644
--- a/static/css/main.css
+++ b/static/css/main.css
@@ -6,3 +6,50 @@
.front-page-introduction {
margin-bottom: 2rem;
}
+
+main img {
+ max-width: 100%;
+}
+
+.post {
+ margin-bottom: 2em;
+}
+
+.post:last-child {
+ margin-bottom: 0em;
+}
+
+.posts {
+ padding: 1.5rem 1rem 0.5rem 1rem;
+ border-radius: 10px;
+ margin-bottom: 2rem;
+ margin-left: -0.5rem;
+ margin-right: -0.5rem;
+}
+
+.posts.bare-bones {
+ border: 2px solid #66f;
+}
+
+.posts.memory-management {
+ border: 2px solid #cc0;
+}
+
+.posts hr {
+ margin: 2rem 0;
+}
+
+.post-category {
+ margin-right: 0.5rem;
+ text-transform: uppercase;
+ font-size: 0.8rem;
+ text-align: right;
+}
+
+.post-category.bare-bones {
+ color: #55d;
+}
+
+.post-category.memory-management {
+ color: #990;
+}
diff --git a/static/css/poole.css b/static/css/poole.css
index 3b67577b..19ed23cd 100644
--- a/static/css/poole.css
+++ b/static/css/poole.css
@@ -275,7 +275,7 @@ tbody tr:nth-child(odd) th {
.masthead {
padding-top: 1rem;
padding-bottom: 1rem;
- margin-bottom: 1rem;
+ margin-bottom: 1rem;
}
.masthead-title {
margin-top: 0;
@@ -300,8 +300,7 @@ tbody tr:nth-child(odd) th {
* page is wrapped in `.page` and is only used on the page layout.
*/
-.page,
-.post {
+.page {
margin-bottom: 4em;
}