mirror of
https://github.com/kremalicious/blog.git
synced 2024-11-26 11:49:04 +01:00
display recent photos under each photo post
This commit is contained in:
parent
06956d3e00
commit
0061f61b5c
@ -98,3 +98,11 @@ picture:
|
||||
itemprop: "image"
|
||||
source_default:
|
||||
width: "190"
|
||||
photothumb:
|
||||
ppi: [1, 2]
|
||||
attr:
|
||||
class: "related-image"
|
||||
itemprop: "image"
|
||||
source_default:
|
||||
width: "190"
|
||||
height: "190"
|
||||
|
@ -33,4 +33,21 @@
|
||||
transition: none
|
||||
|
||||
.post-title-link
|
||||
display: block
|
||||
display: block
|
||||
|
||||
//
|
||||
// Related Photos
|
||||
//
|
||||
.related-photos
|
||||
@extend .divider-top
|
||||
margin-top: $line-height-computed*2
|
||||
|
||||
.photo-link
|
||||
display: block
|
||||
margin-bottom: 15%
|
||||
border: 2px solid transparent
|
||||
|
||||
&:hover,
|
||||
&:focus
|
||||
border-color: $link-color-hover
|
||||
border-radius: $border-radius-base
|
||||
|
17
_src/_includes/relatedphotos.html
Normal file
17
_src/_includes/relatedphotos.html
Normal file
@ -0,0 +1,17 @@
|
||||
<aside class="related-photos">
|
||||
|
||||
<div class="row">
|
||||
|
||||
{% for post in site.categories['photos'] limit:6 %}
|
||||
|
||||
<article class="related-photo col2">
|
||||
<a class="photo-link" href="{{ post.url }}">
|
||||
{% picture photothumb {{ post.image }} %}
|
||||
</a>
|
||||
</article>
|
||||
|
||||
{% endfor %}
|
||||
|
||||
</div>
|
||||
|
||||
</aside>
|
@ -3,25 +3,27 @@ layout: base
|
||||
---
|
||||
|
||||
<section role="main" id="main" class="page-single row">
|
||||
|
||||
|
||||
<article class="hentry format-photo">
|
||||
|
||||
|
||||
<figure class="hmedia">
|
||||
|
||||
|
||||
{% picture {{ page.image }} %}
|
||||
|
||||
|
||||
<figcaption class="entry-title fn">{{ page.title | titlecase }}</figcaption>
|
||||
|
||||
|
||||
</figure>
|
||||
|
||||
|
||||
<section class="entry-content">
|
||||
{{ content }}
|
||||
</section>
|
||||
|
||||
|
||||
{% include entry_meta.html %}
|
||||
|
||||
|
||||
{% include comments.html %}
|
||||
|
||||
|
||||
{% include relatedphotos.html %}
|
||||
|
||||
</article>
|
||||
|
||||
</section>
|
||||
</section>
|
||||
|
Loading…
Reference in New Issue
Block a user