{% extends "shop/base.html" %}
{% load i18n %}
{% load thumbnail %}
{% load satchmo_util %}

{% block navbar %}
<li class="first"><a href="{{ shop_base }}/">{% trans "Home" %}</a></li>
<li>{% trans "Category Index" %}</li>
{% endblock %}

{% block content %}
<h2>{% trans "Categories" %}</h2>
{% for category in categorylist %}
	<div class="category">
    <div class = "productImage">    
   		{% if category.main_image %}
      	<center>
            {% thumbnail category.main_image.picture 85x85 as image %}
            <a href="{{ category.get_absolute_url }}"><img src="{{ image }}" width="{{ image.width }}" height="{{ image.height }}" /></a>
      	</center>
   		{% endif %}     
    	<p><a href="{{ category.get_absolute_url }}">{{ category.translated_name }}</a><br/>
		</p>
	</div>
	</div>
{% endfor %}
{% endblock %}
