{% extends 'online_content/online_content_base.html' %} {% load i18n imagekit static online_content_tags %} {% block content %}

{{ template_content.primary_title }} version {{ localized_template_content.draft_version }} {% if localized_template_content.published_version == localized_template_content.draft_version %} {% trans 'published' %} {% else %} {% if localized_template_content.published_version %} {% trans 'unpublished changes' %} {% else %} {% trans 'not published' %} {% endif %} {% endif %} {% if app.secondary_languages %} {% if localized_template_content.published_version == localized_template_content.draft_version %} {% else %} {% if localized_template_content.translation_ready %} {% trans 'ready for translation' %} {% else %} {% trans 'not ready for translation' %} {% endif %} {% endif %} {% endif %}

{% if localized_template_content.published_version %} {% else %} {% if app.secondary_languages %} {% if localized_template_content.translation_ready %}
{% trans 'You marked the content in this language as ready for translation' %}
{% endif %} {% endif %} {% endif %}
{% if saved_as_draft %}
{% trans 'Successfully saved your content as draft.' %}
{% endif %} {% if tried_publication or tried_translation_ready %} {% if publication_errors or translation_errors %}
{% if tried_publication %} {% trans 'Publication failed:' %}
{% for error in publication_errors %} {{ error }}
{% endfor %} {% else %} {% trans 'Could not set this page as ready for translation:' %}
{% for error in translation_errors %} {{ error }}
{% endfor %} {% endif %}
{% else %} {% if tried_publication %}
{% trans 'publication successful' %}
{% endif %} {% endif %} {% endif %}

{% trans 'Components' %}

{% csrf_token %} {% for field in form %} {% with cms_object=field.field.cms_object %} {% if cms_object.multi %} {% if cms_object.kwargs.is_first %} {% if cms_object.is_file %}
{{ field.label }}
{% endif %}
{% endif %} {% if cms_object.is_file %} {% include 'online_content/filecontent_field.html' %} {% else %}
{% include 'online_content/textcontent_field.html' %}
{% endif %} {% if cms_object.kwargs.is_last %}

{% endif %} {% else %} {% if cms_object.is_file %} {% if field.is_hidden %} {% else %}
{{ field.label }}
{% endif %}
{% include 'online_content/filecontent_field.html' %}
{% else %} {% include 'online_content/textcontent_field.html' %} {% endif %} {% endif %} {% endwith %} {% endfor %}

{% if template_content %}

{% trans 'Preview' %} {% trans 'show in separate window' %}

{% endif %}
{% endblock %} {% block extra_script %} {% include 'online_content/manage_template_content_extra_scripts.html' %} {% endblock %}