Skip to content
Permalink
Browse files

Fix #3141 — stop calling baguetteBox.run twice

Signed-off-by: Chris Warrick <kwpolska@gmail.com>
  • Loading branch information
Kwpolska committed Sep 3, 2018
1 parent 42a3245 commit 20a0acb6f6ff3dd804d7443041bc96d7063c00d9
@@ -23,6 +23,8 @@ Bugfixes

* Enforce trailing slash for directories in ``nikola auto``
(Issue #3140)
* Galleries with baguetteBox don’t glitch out on the first image
anymore (Issue #3141)

Removed features
----------------
@@ -28,9 +28,5 @@ function renderGallery(jsonContent, thumbnailSize) {
div.appendChild(link);
container.appendChild(div);
}
baguetteBox.run('#gallery_container', {
captions: function(element) {
return element.getElementsByTagName('img')[0].alt;
}});
}

Some generated files are not rendered by default. Learn more.

@@ -90,14 +90,11 @@
<!-- end fancy dates -->
{% block extra_js %}{% endblock %}
<script>
baguetteBox.run('a.reference:not(.islink)', {
baguetteBox.run('div#content', {
ignoreClass: 'islink',
captions: function(element) {
return element.getElementsByTagName('img')[0].alt;
}});
baguetteBox.run('img:not(.islink)', {
captions: function(element) {
return element.alt;
}});
</script>
{{ body_end }}
{{ template_hooks['body_end']() }}
@@ -90,14 +90,11 @@ ${base.late_load_js()}
<!-- end fancy dates -->
<%block name="extra_js"></%block>
<script>
baguetteBox.run('a.reference:not(.islink)', {
baguetteBox.run('div#content', {
ignoreClass: 'islink',
captions: function(element) {
return element.getElementsByTagName('img')[0].alt;
}});
baguetteBox.run('img:not(.islink)', {
captions: function(element) {
return element.alt;
}});
</script>
${body_end}
${template_hooks['body_end']()}

0 comments on commit 20a0acb

Please sign in to comment.
You can’t perform that action at this time.