Add support for Wagtail 3 and Wagtail 4 #63
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR adds support for Wagtail 3.x and 4.x to this project. It modifies the tox testing matrix to now test against Wagtail 2.15 (LTS), 3.0, and 4.0. It also adds a new
tox -e interactive
to make it easier to test changes to this package, and bumps test source code coverage to 100%.Testing
See new test matrix in GitHub Actions.
Notes
Thank you @nickmoreton and @katdom13 for your proposals in #58 and #60; I chose to combine the version upgrades into a single PR along with the other changes described above. If you have a chance to test this branch any feedback would be appreciated.
Todos
Wagtail 4.0 changed the way fields are rendered in wagtail/wagtail@eac5e0b, specifically which broke the (admittedly hacky) hardcoded CSS that breaks how the includes/excludes button was being rendered next to the dropdown:
Given the interest in adding this version support, and since the form is still useable, I'd prefer not to (further) delay this upgrade because of that issue. I'm hopeful that it shouldn't be that difficult to re-add the previous design, but that would require better understanding of how fields are rendered in 4.x+.