-
Notifications
You must be signed in to change notification settings - Fork 2
/
twitter_side.html
31 lines (27 loc) · 1.14 KB
/
twitter_side.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<style>
.image-gallery {overflow: auto; }
.image-gallery div {float: left; display: block; margin: 0 0 0.5% 0.5%; width: 32%;}
.image-gallery div a {text-align: center; text-decoration: none!important;;}
.image-gallery div a img {width: 100%; display: block;}
.cropped {
width: 200px; /* width of container */
height: 200px; /* height of container */
object-fit: cover;
}
</style>
<ul class="image-gallery">
{% assign files = site.static_files %}
{% for file in files %}
{% if file.path contains include.folder %}
{% if file.extname == '.jpg' orfile.extname == '.jpg' or file.extname == '.jpeg' or file.extname == '.JPG' or file.extname == '.JPEG' %}
{% assign filenameparts = file.path | split: "/" %}
{% assign filename = filenameparts | last | replace: file.extname,"" %}
<div>
<a href="{{ file.path | relative_url }}" title="{{ filename }}">
<img class="cropped" src="{{file.path}}" alt="{{ filename }}" title="{{ filename }}" />
</a>
</div>
{% endif %}
{% endif %}
{% endfor %}
</ul>