sensei
sensei copied to clipboard
Improve classic editor support for questions
Background
The classic editor plugin offers a choice to edit something in the block editor or classic editor. We previously forced falling back to metaboxes for quizzes and questions when the classic editor plugin was active, which breaks the case when the post is edited in the block editor.
Some new question types only work with the block editor, so this enables the option to create/edit those with the block editor and use the classic editor for other cases.
Changes proposed in this Pull Request
- Change check for block/metabox-based question/quiz editor to be based on the current screen being the block editor
- Add support for Question post types to be opened in the classic or the block editor
TODO
- [ ] Consider
is_legacy_quiz_editortracking flag - [ ] REST APIs? Seem to be working but the current screen check shouldn't work there
Testing instructions
- Add the classic editor plugin
- Try to edit questions and lessons with quizzes both in classic and block editor. Make sure both work.