use block.super in extra CSS/JS blocks

- ensure templates that have extra css/js blocks call {{ block.super }} in them
- wagtail.contrib.settings edit
- modeladmin templates
This commit is contained in:
Timothy Bautista 2019-11-13 15:03:58 -07:00 committed by LB
parent dcf5722ebb
commit 1b0aed7b20
8 changed files with 14 additions and 0 deletions

View file

@ -18,6 +18,7 @@ Changelog
* Fix: Prevent error when comparing pages that reference a model with a custom primary key (Fidel Ramos)
* Fix: Moved ``get_document_model`` location so it can be imported when Models are not yet loaded (Andrey Smirnov)
* Fix: Fixed incorrect HTML escaping of Jinja2 form templates for StructBlocks (Brady Moe)
* Fix: All templates with wagtailsettings and modeladmin now use ``block.super`` for ``extra_js`` & ``extra_css`` (Timothy Bautista)
2.7 LTS (06.11.2019)
~~~~~~~~~~~~~~~~~~~~

View file

@ -423,6 +423,7 @@ Contributors
* Tom Readings
* Andrey Smirnov
* Tim Gates
* Timothy Bautista
Translators
===========

View file

@ -32,6 +32,7 @@ Bug fixes
* Prevent error when comparing pages that reference a model with a custom primary key (Fidel Ramos)
* Moved ``get_document_model`` location so it can be imported when Models are not yet loaded (Andrey Smirnov)
* Fixed incorrect HTML escaping of Jinja2 form templates for StructBlocks (Brady Moe)
* All templates with wagtailsettings and modeladmin now use ``block.super`` for ``extra_js`` & ``extra_css`` (Timothy Bautista)
Upgrade considerations

View file

@ -4,6 +4,7 @@
{% block titletag %}{{ view.get_meta_title }}{% endblock %}
{% block extra_css %}
{{ block.super }}
{% include "wagtailadmin/pages/_editor_css.html" %}
{{ form.media.css }}
<link rel="stylesheet" href="{% versioned_static 'wagtailmodeladmin/css/choose_parent_page.css' %}" type="text/css"/>
@ -11,6 +12,7 @@
{% endblock %}
{% block extra_js %}
{{ block.super }}
{% include "wagtailadmin/pages/_editor_js.html" %}
{{ form.media.js }}
{% endblock %}

View file

@ -4,6 +4,8 @@
{% block titletag %}{{ view.get_meta_title }}{% endblock %}
{% block extra_css %}
{{ block.super }}
{% include "wagtailadmin/pages/_editor_css.html" %}
{{ edit_handler.form.media.css }}
@ -11,6 +13,8 @@
{% endblock %}
{% block extra_js %}
{{ block.super }}
{% include "wagtailadmin/pages/_editor_js.html" %}
{{ edit_handler.form.media.js }}
{{ edit_handler.html_declarations }}

View file

@ -9,6 +9,7 @@
{% endblock %}
{% block extra_js %}
{{ block.super }}
{{ view.media.js }}
{% endblock %}

View file

@ -4,11 +4,13 @@
{% block titletag %}{{ view.get_meta_title }}{% endblock %}
{% block extra_css %}
{{ block.super }}
{{ view.media.css }}
<link rel="stylesheet" href="{% versioned_static 'wagtailmodeladmin/css/breadcrumbs_page.css' %}" type="text/css"/>
{% endblock %}
{% block extra_js %}
{{ block.super }}
{{ view.media.js }}
{% endblock %}

View file

@ -42,11 +42,13 @@
{% endblock %}
{% block extra_css %}
{{ block.super }}
{% include "wagtailadmin/pages/_editor_css.html" %}
{{ edit_handler.form.media.css }}
{{ site_switcher.media.css }}
{% endblock %}
{% block extra_js %}
{{ block.super }}
{% include "wagtailadmin/pages/_editor_js.html" %}
{{ edit_handler.form.media.js }}
{{ edit_handler.html_declarations }}