{% extends 'admin/base_site.html' %}
{% load i18n %}
{% load antichaos %}
{% load tagging_tags %}

{% block extrastyle %}
{{ block.super }}
<link rel="stylesheet" type="text/css" href="{% antichaos_media_prefix %}antichaos.css" />
{% endblock %}

{% block extrahead %}
{{ block.super }}
<script src="{% antichaos_media_prefix %}jquery.js"></script>
<script src="{% antichaos_media_prefix %}ui.core.js"></script>
<script src="{% antichaos_media_prefix %}ui.draggable.js"></script>
<script src="{% antichaos_media_prefix %}ui.droppable.js"></script>
<script src="{% antichaos_media_prefix %}effects.core.js"></script>
<script src="{% antichaos_media_prefix %}effects.explode.js"></script>
<script src="{% antichaos_media_prefix %}simpletip.js"></script>
<script src="{% antichaos_media_prefix %}antichaos.js"></script>
{% endblock %}

{% if not is_popup %}
{% block breadcrumbs %}
<div class="breadcrumbs">
    <a href="{{ root_path }}"> {% trans "Home" %}</a> &rsaquo; 
    <a href="{{ root_path }}tagging/"> {% trans "Tagging" %}</a> &rsaquo; 
    {{ title }}
</div>{% endblock %}

{% endif %}

{% block content %}
    <div id="content-main">
        {{ block.super }}
        {{ model_name }}

        <ul class="tag-cloud">
            <p class="inprogress">{% trans 'Please wait while tag cloud loaded.' %}</p>
        </ul>
        <script type="text/javascript">
            {% block init-antichaos %}
                init_antichaos({
                    top: 5,
                    cloud_json_url: '?json=1',
                    on_cloud_load_end: function() {
                        $('.inprogress').hide();
                    }
                });
            {% endblock %}
        </script>
    </div>
{% endblock %}

{% block sidebar %}
    <div id="content-related">
        <div class="module" id="recent-actions-module">
            <h2>{% trans 'History' %}</h2>
            <ul class="history">
            </ul>
            <form class="tag-cloud" action="" method="POST" >
                <input class="undo" type="submit" value="{% trans 'Undo' %}" disabled="true"/>
                <input type="submit" value="{% trans 'Apply' %}" disabled="true"/>
            </form>
        </div>
    </div>
{% endblock %}

