Skip to content

Commit

Permalink
Add super neat styling to posts
Browse files Browse the repository at this point in the history
  • Loading branch information
chesterhow committed Mar 21, 2017
1 parent 4850bf9 commit 6bd82c7
Show file tree
Hide file tree
Showing 12 changed files with 40 additions and 24 deletions.
2 changes: 1 addition & 1 deletion _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
permalink: pretty

# Setup
title: tale
title: Tale
subtitle: by Chester
paginate: 5
baseurl: ""
Expand Down
2 changes: 1 addition & 1 deletion _layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<div class="container">
<header>
<a href="{{ site.baseurl }}/" title="Home">
<h2>{{ site.title }}</h2>
<h2>{{ site.title | downcase }}</h2>
</a>

<div class="line"></div>
Expand Down
16 changes: 10 additions & 6 deletions _layouts/post.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,18 @@
layout: default
---

<div>
<div class="post">
<time class="post-time" datetime="{{ page.date }}">{{ page.date | date_to_string | upcase }}</time>
<h1 class="post-title">{{ page.title }}</h1>
<div class="post">
<div class="post-info">
<span>Written by&nbsp;</span>{{ page.author }}
<br>
<span>on&nbsp;</span><time datetime="{{ page.date }}">{{ page.date | date: "%B %d, %Y" }}</time>
</div>

{{ content }}
<h1 class="post-title">{{ page.title }}</h1>
<div class="post-line"></div>

{{ content }}

</div>
</div>

<div class="pagination">
Expand Down
1 change: 1 addition & 0 deletions _posts/2017-03-05-empty-post.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
layout: post
title: "Empty Post"
author: "Chester"
---

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras eu ipsum feugiat, condimentum est et, faucibus nulla. Praesent libero lectus, volutpat sed quam eget, volutpat viverra dui. Duis sapien nisi, posuere sit amet eros ac, blandit egestas odio. Sed elementum arcu ac ante sodales, ut molestie velit tempor. Nulla ultricies, tortor eu laoreet pharetra, velit turpis tempor lectus, nec cursus leo dui vel leo. Quisque vulputate eget dui et dapibus. Sed eu ornare leo, in mollis leo. Mauris sapien nisl, congue et diam eget, pretium iaculis nisl. In non ex posuere, volutpat neque ac, ultrices urna. Sed bibendum ipsum eget quam pellentesque, ut lacinia tortor placerat. Duis condimentum et ante nec tincidunt. Fusce interdum suscipit ipsum, sit amet mattis sem consequat quis.
1 change: 1 addition & 0 deletions _posts/2017-03-06-empty-post.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
layout: post
title: "Empty Post"
author: "Chester"
---

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras eu ipsum feugiat, condimentum est et, faucibus nulla. Praesent libero lectus, volutpat sed quam eget, volutpat viverra dui. Duis sapien nisi, posuere sit amet eros ac, blandit egestas odio. Sed elementum arcu ac ante sodales, ut molestie velit tempor. Nulla ultricies, tortor eu laoreet pharetra, velit turpis tempor lectus, nec cursus leo dui vel leo. Quisque vulputate eget dui et dapibus. Sed eu ornare leo, in mollis leo. Mauris sapien nisl, congue et diam eget, pretium iaculis nisl. In non ex posuere, volutpat neque ac, ultrices urna. Sed bibendum ipsum eget quam pellentesque, ut lacinia tortor placerat. Duis condimentum et ante nec tincidunt. Fusce interdum suscipit ipsum, sit amet mattis sem consequat quis.
1 change: 1 addition & 0 deletions _posts/2017-03-07-empty-post.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
layout: post
title: "Empty Post"
author: "Chester"
---

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras eu ipsum feugiat, condimentum est et, faucibus nulla. Praesent libero lectus, volutpat sed quam eget, volutpat viverra dui. Duis sapien nisi, posuere sit amet eros ac, blandit egestas odio. Sed elementum arcu ac ante sodales, ut molestie velit tempor. Nulla ultricies, tortor eu laoreet pharetra, velit turpis tempor lectus, nec cursus leo dui vel leo. Quisque vulputate eget dui et dapibus. Sed eu ornare leo, in mollis leo. Mauris sapien nisl, congue et diam eget, pretium iaculis nisl. In non ex posuere, volutpat neque ac, ultrices urna. Sed bibendum ipsum eget quam pellentesque, ut lacinia tortor placerat. Duis condimentum et ante nec tincidunt. Fusce interdum suscipit ipsum, sit amet mattis sem consequat quis.
1 change: 1 addition & 0 deletions _posts/2017-03-08-welcome-to-jekyll.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
layout: post
title: "Introducing Tale 2"
author: "Chester"
---

You’ll find this post in your `_posts` directory. Go ahead and edit it and re-build the site to see your changes. You can rebuild the site in many different ways, but the most common way is to run `jekyll serve`, which launches a web server and auto-regenerates your site when a file is updated.
Expand Down
1 change: 1 addition & 0 deletions _posts/2017-03-10-welcome-to-jekyll.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
layout: post
title: "Welcome to Jekyll!"
author: "Chester"
---

You’ll find this post in your `_posts` directory. Go ahead and edit it and re-build the site to see your changes. You can rebuild the site in many different ways, but the most common way is to run `jekyll serve`, which launches a web server and auto-regenerates your site when a file is updated.
Expand Down
1 change: 1 addition & 0 deletions _posts/2017-03-16-example-content.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
layout: post
title: "Example Content"
author: "Chester"
---

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Maecenas tincidunt ornare nibh, non elementum augue tempus eget. Pellentesque tempus scelerisque iaculis. Nullam interdum ultricies nibh quis sollicitudin. Donec ornare fermentum facilisis. Ut at sem ac sem imperdiet varius a eget tortor. Nam eu augue eget orci semper maximus in eget augue. Mauris ornare, nisl ut suscipit consectetur, mi quam interdum tellus, at rutrum quam eros ultrices mi.
Expand Down
6 changes: 5 additions & 1 deletion _sass/_base.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,11 @@ body {

html {
font-family: $baskerville;
font-size: $default-font-size;
font-size: 14px;

@media (min-width: 600px) {
font-size: 16px;
}
}

body {
Expand All @@ -26,6 +29,7 @@ h3,
h4,
h5,
h6 {
color: $default-shade;
font-family: $palatino;
line-height: normal;
}
Expand Down
31 changes: 17 additions & 14 deletions _sass/_post.scss
Original file line number Diff line number Diff line change
@@ -1,27 +1,30 @@
.post {
padding: 3rem 0;

&:not(:last-child) {
border-bottom: .5px solid $grey-2;
}

&-time {
&-info {
color: $default-tint;
font-family: $sans-font;
font-weight: 700;
font-family: $palatino;
letter-spacing: .5px;
text-align: center;

span {
font-style: italic;
}
}

&-title {
color: $default-shade;
font-size: 2.7rem;
margin: 0 0 .8rem;
font-family: $sans-font;
font-size: 4rem;
margin: 1rem 0;
text-align: center;
}

a {
color: $default-shade;
font-size: 2.7rem;
line-height: normal;
}
&-line {
border-top: .4rem solid $default-color;
display: block;
margin: 0 auto 3rem;
width: 4rem;
}

p {
Expand Down
1 change: 0 additions & 1 deletion _sass/_variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ $blue: #4a9ae1;
$baskerville: 'Libre Baskerville', 'Times New Roman', Times, serif;
$palatino: Palatino, 'Palatino LT STD', 'Palatino Linotype', 'Book Antiqua', 'Georgia', serif;
$sans-font: 'Helvetica Neue', Helvetica, Arial, sans-serif;
$default-font-size: 16px;

$monospaced-font: Menlo, Monaco, monospace;
$code-color: #bf616a;
Expand Down

0 comments on commit 6bd82c7

Please sign in to comment.