Skip to content

Commit

Permalink
Don't import _editor_css.html on Wagtail >=4 (#122)
Browse files Browse the repository at this point in the history
The additional CSS is now incorporated into the core admin CSS, and so this include no longer exists.
  • Loading branch information
gasman committed Jun 23, 2022
1 parent 1d24848 commit 3f3dfd9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
4 changes: 3 additions & 1 deletion wagtail_transfer/templates/wagtail_transfer/choose_page.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
{% block extra_css %}
{{ block.super }}

{% include "wagtailadmin/pages/_editor_css.html" %}
{% if include_legacy_editor_css %}
{% include "wagtailadmin/pages/_editor_css.html" %}
{% endif %}
<link rel="stylesheet" href="{% versioned_static 'wagtail_transfer/css/transfer-styles.css' %}">
{% endblock %}

Expand Down
1 change: 1 addition & 0 deletions wagtail_transfer/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,7 @@ def choose_page(request):
}
for source_name in getattr(settings, 'WAGTAILTRANSFER_SOURCES', {}).keys()
]),
'include_legacy_editor_css': WAGTAIL_VERSION < (4, 0),
})


Expand Down

0 comments on commit 3f3dfd9

Please sign in to comment.