-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding Blog page and latest articles on homepage
- Loading branch information
Michel Moraes
committed
Sep 23, 2018
1 parent
7827c4a
commit d482761
Showing
20 changed files
with
206 additions
and
135 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
|
||
.blog | ||
|
||
&__item | ||
|
||
&-thumbnail | ||
background: $gray-dark center / cover no-repeat | ||
min-height: 190px | ||
margin-bottom: 25px | ||
|
||
&-title | ||
@extend .title | ||
margin-bottom: 8px !important | ||
|
||
+mobile | ||
font-size: 28px | ||
|
||
&-meta | ||
margin-bottom: 25px |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
|
||
@import tickets | ||
@import tickets | ||
@import blog |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,26 @@ | ||
<article class="base-camp-article post-type-{{ post.post_type }}" id="post-{{ post.ID }}"> | ||
<div class="blog__item column is-half-tablet is-one-quarter-desktop" id="post-{{ post.ID }}"> | ||
|
||
<header> | ||
<h2 class="title is-h2"> | ||
<a href="{{ post.link }}">{{ post.title }}</a> | ||
</h2> | ||
<div class="article-meta"> | ||
<time class="timestamp"><i class="fa fa-calendar" aria-hidden="true"></i> <span>{{ post.date }}</span></time> | ||
<div> | ||
<a href="{{ post.author.link }}"><i class="fa fa-user" aria-hidden="true"></i> <span>{{ post.author }}</span></a> | ||
</div> | ||
{% if post.can_edit %} | ||
<div><a href="{{ post.get_edit_url }}"><i class="fa fa-pencil" aria-hidden="true"></i> <span>{{ messages.article.edit }}</span></a></div> | ||
{% endif %} | ||
</div> | ||
</header> | ||
{% set post_thumb = TimberImage(post.thumbnail) %} | ||
|
||
<a href="{{ post.link }}"> | ||
<div class="blog__item-thumbnail" | ||
style="background-image: url('{{ post_thumb.src|resize(1320)}}')"></div> | ||
</a> | ||
|
||
<p class="content">{{ post.content }}</p> | ||
<h2 class="blog__item-title"> | ||
<a href="{{ post.link }}">{{ post.title }}</a> | ||
</h2> | ||
|
||
{# Tags #} | ||
<footer> | ||
<div class="blog__item-meta article-meta"> | ||
<time class="timestamp"><i class="fa fa-calendar" aria-hidden="true"></i> <span>{{ post.date }}</span></time> | ||
</div> | ||
|
||
<p class="content">{{ post.preview.length(30).force }}</p> | ||
|
||
<ul class="article-tags"> | ||
{% for tag in post.tags %} | ||
{% for tag in post.tags %} | ||
<li><a href="{{ tag.link }}" class="button is-danger is-outlined is-small">{{ tag.name }}</a></li> | ||
{% endfor %} | ||
</ul> | ||
</footer> | ||
{% endfor %} | ||
</ul> | ||
|
||
</article> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,17 @@ | ||
{% extends "base.twig" %} | ||
|
||
{% block content %} | ||
{% for post in posts %} | ||
{% include 'components/article.twig' %} | ||
<hr /> | ||
{% endfor %} | ||
|
||
|
||
{% if posts.pagination.pages %} | ||
{% include 'components/pagination.twig' %} | ||
{% endif %} | ||
<section class="blog section"> | ||
<div class="container"> | ||
<div class="columns"> | ||
{% for post in posts %} | ||
{% include 'components/article.twig' %} | ||
{% endfor %} | ||
</div> | ||
</div> | ||
</section> | ||
|
||
{% if posts.pagination.pages %} | ||
{% include 'components/pagination.twig' %} | ||
{% endif %} | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
Oops, something went wrong.