{% load i18n %}{% load static %}
<link rel="stylesheet" href="{% static 'debug_toolbar/css/print.css' %}" type="text/css" media="print">
<link rel="stylesheet" href="{% static 'debug_toolbar/css/toolbar.css' %}" type="text/css">
<script src="{% static 'debug_toolbar/js/toolbar.js' %}"></script>
<div id="djDebug" class="djdt-hidden" dir="ltr"
     {% if toolbar.store_id %}
     data-store-id="{{ toolbar.store_id }}"
     data-render-panel-url="{% url 'djdt:render_panel' %}"
     {% endif %}
     {{ toolbar.config.ROOT_TAG_EXTRA_ATTRS|safe }}>
	<div class="djdt-hidden" id="djDebugToolbar">
		<ul id="djDebugPanelList">
			{% if toolbar.panels %}
			<li><a id="djHideToolBarButton" href="#" title="{% trans "Hide toolbar" %}">{% trans "Hide" %} &#187;</a></li>
			{% else %}
			<li id="djDebugButton">DEBUG</li>
			{% endif %}
			{% for panel in toolbar.panels %}
				<li class="djDebugPanelButton">
					<input type="checkbox" data-cookie="djdt{{ panel.panel_id }}" {% if panel.enabled %}checked title="{% trans "Disable for next and successive requests" %}"{% else %}title="{% trans "Enable for next and successive requests" %}"{% endif %}>
					{% if panel.has_content and panel.enabled %}
						<a href="#" title="{{ panel.title }}" class="{{ panel.panel_id }}">
					{% else %}
						<div class="djdt-contentless{% if not panel.enabled %} djdt-disabled{% endif %}">
					{% endif %}
					{{ panel.nav_title }}
					{% if panel.enabled %}
					{% with panel.nav_subtitle as subtitle %}
						{% if subtitle %}<br><small>{{ subtitle }}</small>{% endif %}
					{% endwith %}
					{% endif %}
					{% if panel.has_content and panel.enabled %}
						</a>
					{% else %}
						</div>
					{% endif %}
				</li>
			{% endfor %}
		</ul>
	</div>
	<div class="djdt-hidden" id="djDebugToolbarHandle">
		<span title="{% trans "Show toolbar" %}" id="djShowToolBarButton">&#171;</span>
	</div>
	{% for panel in toolbar.panels %}
		{% if panel.has_content and panel.enabled %}
			<div id="{{ panel.panel_id }}" class="djdt-panelContent">
				<div class="djDebugPanelTitle">
					<a href="" class="djDebugClose"></a>
					<h3>{{ panel.title|safe }}</h3>
				</div>
				<div class="djDebugPanelContent">
					{% if toolbar.store_id %}
					<img src="{% static 'debug_toolbar/img/ajax-loader.gif' %}" alt="loading" class="djdt-loader">
					<div class="djdt-scroll"></div>
					{% else %}
					<div class="djdt-scroll">{{ panel.content }}</div>
					{% endif %}
				</div>
			</div>
		{% endif %}
	{% endfor %}
	<div id="djDebugWindow" class="djdt-panelContent"></div>
</div>
