EditingKeystrokeHandler should prevent default action only for commands. Closes #90. (82ff39a)ToggleAttributeCommand should listen to reliable events in order to determine its state. Closes #50. (6816505)EditingKeystrokeHandler should support priorities and proper cancelling. Closes #101. (c74b9a3)Editor#destroy() will destroy all loaded plugins. Closes #86. (77e5217)Added default implementation for Plugin#destroy(). Introduced PluginCollection#destroy() method which calls Plugin#destroy() for every loaded plugin.
PluginCollection will warn if the user wants to load two or more plugins with the same name. Closes #85. (e00a282)Editor#isReadOnly property which disables all commands and prevents from modifying the document. Closes #96. Closes https://github.com/ckeditor/ckeditor5/issues/492. (1ca5608)EditingController#isReadOnly to the editor. Closes #98. (ec02906)PluginInterface. A plugin doesn't need to inherit directly from the Plugin class, as long as it implements some minimal interface. See #78. (f476f34)ToggleAttributeCommand class as well as other helpers from the core/command namespace. Closes #14. (7c68581)The command API has been redesigned. The Command methods are now public and consistent. Commands can be used in a standalone mode (without the editor). The CommandCollection was introduced and replaced the Map of commands used in editor.commands. Closes #88. (b76983b)
Besides changes mentioned in this point and in the "Breaking changes" section, other minor changes were done:
Editor#execute() now accepts multiple command arguments.Command#value property was standardized.ToggleAttributeCommand was moved to the ckeditor5-basic-styles package as AttributeCommand and the other command helpers to ckeditor5-engine as Schema methods.Command's protected _doExecute() and _checkEnabled() methods have been replaced by public execute() and refresh() methods.Command's refreshState event was removed and one should use change:isEnabled in order to control and override its state.core/command/command module has been moved to the root directory (so the Command class is core/command~Command now).Command#refresh() method is now automatically called on editor.document#changesDone.editor.commands map was replaced by a CommandCollection instance so editor.commands.set() calls need to be replaced with editor.commands.add().config.removePlugins for real (we said that we did this in the previous release, but we didn't). Closes #49. (5834fed)config.removePlugins option. Closes #49. (dfee52e)