{% extends "admin/change_form.html" %}{% load i18n wysiwyg %}

{% block object-tools-items %}
<li><a href="history/" class="historylink">{% trans "History" %}</a></li>
{% if has_absolute_url %}<li><a {% if preview_error %}onclick="alert('{{ preview_error|escapejs }}'); return false;" href="#"{% else %}href="{{ original.url }}"{% endif %} class="viewsitelink">{% trans "View on site" %}</a></li>{% endif%}
{% endblock %}

{% comment %}
  The django-parler `change_form_template` trick is disabled, so explicitly enable the language tabs here.
  This makes life much easier for developers that extend the admin,
  as they can just redefine `change_form_template` and enjoy language tabs nonetheless.
{% endcomment %}
{% block field_sets %}
{% if language_tabs %}{% include "admin/parler/language_tabs.html" %}{% endif %}
{{ block.super }}
{% endblock %}

{% block content %}
  {{ block.super }}
  {% include "admin/fluent_blogs/entry/change_form_navigation.html" %}

  {% block wysiwyg_editor %}
    {% for field_name in html_fields %}
      {% wysiwyg_editor field_name %}
    {% endfor %}
  {% endblock %}
{% endblock %}
