Skip to content
Permalink
Browse files
slides: Move templates into the plugin
Signed-off-by: Chris Warrick <kwpolska@gmail.com>
  • Loading branch information
Kwpolska committed Feb 18, 2018
1 parent 6561058 commit 334f7dea3e3e62a7905dd93d66e054e5de3ebebd
Showing 2 changed files with 48 additions and 0 deletions.
@@ -0,0 +1,24 @@
{% block content %}
<div id="{{ carousel_id }}" class="carousel slide">
<ol class="carousel-indicators">
{% for i in range(slides_content|length) %}
{% if i == 0 %}
<li data-target="#{{ carousel_id }}" data-slide-to="{{ i }}" class="active"></li>
{% else %}
<li data-target="#{{ carousel_id }}" data-slide-to="{{ i }}"></li>
{% endif %}
{% endfor %}
</ol>
<div class="carousel-inner">
{% for i, image in enumerate(slides_content) %}
{% if i == 0 %}
<div class="item active"><img src="{{ image }}" alt="" style="margin: 0 auto 0 auto;"></div>
{% else %}
<div class="item"><img src="{{ image }}" alt="" style="margin: 0 auto 0 auto;"></div>
{% endif %}
{% endfor %}
</div>
<a class="left carousel-control" href="#{{ carousel_id }}" data-slide="prev">&lsaquo;</a>
<a class="right carousel-control" href="#{{ carousel_id }}" data-slide="next">&rsaquo;</a>
</div>
{% endblock %}
@@ -0,0 +1,24 @@
<%block name="content">
<div id="${carousel_id}" class="carousel slide">
<ol class="carousel-indicators">
% for i in range(len(slides_content)):
% if i == 0:
<li data-target="#${carousel_id}" data-slide-to="${i}" class="active"></li>
% else:
<li data-target="#${carousel_id}" data-slide-to="${i}"></li>
% endif
% endfor
</ol>
<div class="carousel-inner">
% for i, image in enumerate(slides_content):
% if i == 0:
<div class="item active"><img src="${image}" alt="" style="margin: 0 auto 0 auto;"></div>
% else:
<div class="item"><img src="${image}" alt="" style="margin: 0 auto 0 auto;"></div>
% endif
% endfor
</div>
<a class="left carousel-control" href="#${carousel_id}" data-slide="prev">&lsaquo;</a>
<a class="right carousel-control" href="#${carousel_id}" data-slide="next">&rsaquo;</a>
</div>
</%block>

0 comments on commit 334f7de

Please sign in to comment.