mirror of
https://github.com/kremalicious/blog.git
synced 2024-11-29 23:48:11 +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"
|
||||
|
@ -34,3 +34,20 @@
|
||||
|
||||
.post-title-link
|
||||
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>
|
@ -22,6 +22,8 @@ layout: base
|
||||
|
||||
{% include comments.html %}
|
||||
|
||||
{% include relatedphotos.html %}
|
||||
|
||||
</article>
|
||||
|
||||
</section>
|
Loading…
Reference in New Issue
Block a user