Skip to content
Permalink
Browse files

backport islink support to base theme, re-jinjify

  • Loading branch information
ralsina committed Dec 26, 2017
1 parent 2f4e64c commit 493a1b8ed8c3454f894142f6a25e6fbd99500761
@@ -26,10 +26,16 @@
<script src="/assets/js/baguetteBox.min.js"></script>
{% endif %}
{% block extra_js %}{% endblock %}
<script>baguetteBox.run('a.reference', {
<script>
baguetteBox.run('a.reference:not(.islink)', {
captions: function(element) {
return element.getElementsByTagName('img')[0].alt;
}});</script>
}});
baguetteBox.run('img:not(.islink)', {
captions: function(element) {
return element.alt;
}});
</script>
{{ body_end }}
{{ template_hooks['body_end']() }}
</body>
@@ -26,10 +26,16 @@ ${template_hooks['extra_head']()}
<script src="/assets/js/baguetteBox.min.js"></script>
% endif
<%block name="extra_js"></%block>
<script>baguetteBox.run('a.reference', {
<script>
baguetteBox.run('a.reference:not(.islink)', {
captions: function(element) {
return element.getElementsByTagName('img')[0].alt;
}});</script>
}});
baguetteBox.run('img:not(.islink)', {
captions: function(element) {
return element.alt;
}});
</script>
${body_end}
${template_hooks['body_end']()}
</body>
@@ -87,10 +87,16 @@
</script>
<!-- end fancy dates -->
{% block extra_js %}{% endblock %}
<script>baguetteBox.run('a.reference', {
<script>
baguetteBox.run('a.reference:not(.islink)', {
captions: function(element) {
return element.getElementsByTagName('img')[0].alt;
}});</script>
}});
baguetteBox.run('img:not(.islink)', {
captions: function(element) {
return element.alt;
}});
</script>
{{ body_end }}
{{ template_hooks['body_end']() }}
</body>
@@ -96,6 +96,8 @@ $("#gallery_container").flowr({
}
}
});
$('a.image-reference[href="'+window.location.hash.substring(1,1000)+'"]').click();
</script>
baguetteBox.run('#gallery_container', {
captions: function(element) {
return element.getElementsByTagName('img')[0].alt;
}});</script>
{% endblock %}

0 comments on commit 493a1b8

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