{% load static sekizai_tags %}

<div class="plugin plugin-gallery plugin-gallery-{{ instance.style }}" id="plugin-gallery-{{ instance.pk }}">
    {% block content_gallery %}{% endblock %}
</div>

{% addtoblock "js" %}<script src="{% static "js/libs/class.min.js" %}"></script>{% endaddtoblock %}
{% addtoblock "js" %}<script src="{% static "js/addons/cl.gallery.min.js" %}"></script>{% endaddtoblock %}
{% addtoblock "js" %}
<script>
jQuery(window).load(function () {
    new Cl.Gallery('#plugin-gallery-{{ instance.pk }}', {
        'engine': '{{ instance.engine }}',
        'duration': {{ instance.duration }},
        'timeout': {{ instance.timeout }}
    });
});
</script>
{% endaddtoblock %}