Add link to gallery in included list

This commit is contained in:
2016-01-30 22:41:40 +00:00
parent 94a6950a61
commit 9c52683d99
4 changed files with 21 additions and 12 deletions

View File

@@ -3,10 +3,12 @@
<script type="text/javascript"> <script type="text/javascript">
var disqus_shortname = '{{ site.disqus }}'; var disqus_shortname = '{{ site.disqus }}';
var disqus_identifier = '{{ page.id }}'; var disqus_identifier = '{{ page.id }}';
var disqus_title = '{{ page.title|replace:"'":"\\'" }}'; var disqus_title = '{{ page.title | replace:"'":"\\'" }}';
var disqus_url = '{{ site.absolute }}{{ page.url }}'; var disqus_url = '{{ site.absolute }}{{ page.url }}';
(function() { (function() {
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true; var dsq = document.createElement('script');
dsq.type = 'text/javascript';
dsq.async = true;
dsq.src = 'http://' + disqus_shortname + '.disqus.com/embed.js'; dsq.src = 'http://' + disqus_shortname + '.disqus.com/embed.js';
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq); (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
})(); })();

View File

@@ -1,6 +1,13 @@
{% assign photos=site.data.gallery[include.gallery].photos | sort:'date' %} {% assign gallery=site.data.gallery[include.gallery] %}
<div style="line-height:0; padding:4px 0 0 1px;"> {% assign photos=gallery.photos | sort:'date' %}
<div style="text-align: center;">
{% if include.no-link == null %}
<a href="/{{ site.baseurl }}/gallery/{{ include.gallery }}/">[ gallery ]</a><br />
{% endif %}
{% for photo in photos %} {% for photo in photos %}
<a href="/{{ site.baseurl }}/{{ photo.url }}" style="display: inline-block; margin: 3px; text-decoration: none;"><img alt="Photo: {{ photo.title }}" height="96" src="{{ site.asset_prefix }}/gallery/{{ include.gallery }}/{{ photo.name | remove:'.md' }}~96x96.jpg" title="{{ photo.title }}" width="96" style="padding: 1px;" /></a> <a href="/{{ site.baseurl }}/{{ photo.url }}" style="display: inline-block; margin: 3px; text-decoration: none;"><img alt="Photo: {{ photo.title }}" height="96" src="{{ site.asset_prefix }}/gallery/{{ include.gallery }}/{{ photo.name | remove:'.md' }}~96x96.jpg" title="{{ photo.title }}" width="96" style="padding: 1px;" /></a>
{% endfor %} {% endfor %}
</div> </div>
{% if include.no-link %}
<a href="/{{ site.baseurl }}/gallery/{{ include.gallery }}/">[ gallery ]</a>
{% endif %}

View File

@@ -17,7 +17,7 @@
<small class="print-only" itemprop="datePublished" content="{{ page.date|date:'%F') }}">{{ page.date|date:'%A, %B %d, %Y' }}</small> <small class="print-only" itemprop="datePublished" content="{{ page.date|date:'%F') }}">{{ page.date|date:'%A, %B %d, %Y' }}</small>
</h1> </h1>
{% if page.end_date %} {% if page.end_date %}
<span class="date-range">&#x1f557; {{ page.date|date:"%d/%m/%Y" }} - {{ page.end_date|date:"%d/%m/%Y" }}</span> <span class="date-range">&#x1f557; {{ page.date | date:"%d/%m/%Y" }} - {{ page.end_date | date:"%d/%m/%Y" }}</span>
{% endif %} {% endif %}
</header> </header>
<section class="post-content" itemprop="articleBody"> <section class="post-content" itemprop="articleBody">