<!doctype html>
<html lang="en">
    <head>
      {% include "head.html" %}
      <title>Looper: {{ name }} objects</title>
    </head>
    {{ navbar }}
    <body>
    	<div id="top"></div>
    	<div class="container">
			{% if links[0] is defined or figures[0] is defined %}
				<h3>{{ name }}</h3>
			{% else %}
				<p><b>No objects to display for: <code>{{ name }}</code></b><p>
			{% endif %}
			<!-- Expects a 2 lists of lists: figures and links -->
			{% if links[0] is defined %}
				<h5>Links</h5>
				<div class="list-group">
				{% for link in links %}
					<a href='{{ link[1] }}' class="list-group-item">{{ link[0] }}</a>
				{% endfor %}
				</div>
			{% endif %}
			{% if figures[0] is defined %}
				<h5>Figures</h5>
				<div class='row justify-content-start'>
				{% for figure in figures %}
					{% set i = loop.index - 1 %}
					<figure class="figure">
						<a href='{{ figure[0] }}'>
							<img id="fig" src='{{ figure[2] }}' class="figure-img img-fluid rounded" alt="">
						</a>
						<a href='{{ figure[0] }}'>
							<figcaption class="figure-caption text-center"><b>Fig.{{ i }} </b><i>{{ figure[1] }}</i></figcaption>
						</a>
					</figure>
				{% endfor %}
				</div>
			{% endif %}
    	</div>
    </body>
    <hr class="featurette-divider">
    <footer class="text-muted">
        {{ footer }}
    </footer>
</html>
