v40.0.0
We are happy to announce the release of CKEditor 5 v40.0.0.
Release highlights
AI Assistant
We are tremendously excited to share our AI Assistant plugin with you!
With the AI Assistant, you can boost your editing effectiveness and creativity in a completely new way. This feature gives writers and editors the power to seamlessly interact with artificial intelligence. Users can generate, expand, rewrite, improve, translate, and process the content in many different ways.
The AI Assistant can be used in two ways. You can quickly re-work selected content by choosing one of the predefined AI commands. Or, you can write your own query to generate or process the content in any way you like!
Make sure to visit the documentation and try the demo!
Introduction of the image height and width support
No more layout shifts! We have introduced setting of the image width
and height
attributes automatically during the upload/paste process to ensure the highest-quality content with no text jumping all around. While existing images won't be automatically retroactively altered, any changes to images in the editor (like resizing) will automatically set these attributes.
We've also ensured backward compatibility with CKEditor 4, particularly while maintaining user-changed aspect ratios. More details on the changes can be found in the update guide.
Drag and drop of blocks
Just drag it!™ We have introduced a more intuitive drag-and-drop functionality for blocks and widgets. This makes content rearrangement and editing faster and easier, offering users better control over their content. Dragging by the balloon block toolbar handle is also possible, and we've updated its default icon to reflect this new drag-and-drop capability better (but it's still changeable).
Document lists feature parity
Document lists — our second-generation list plugin that supports multiple content blocks in list items — have finally landed the support for to-do lists! We also added the configuration that enforces the document list to have only a single block inside the list item (we call it “simple lists”). All this is to start deprecating the Lists v1 implementation and use the document lists as default. Coming soon!
Contextual balloon fixes
Last but not least, we prepared significant fixes to the way the contextual balloons work. They had the tendency to overflow on other elements, especially in the fixed height editors. We polished their internals, and problems should exist no more!
Please refer to the update guide to learn more about these changes.
MAJOR BREAKING CHANGES ℹ️
- image: The model attribute name of the resized image has been changed to
resizedWidth
. Thewidth
andheight
attributes are now used to preserve the image's natural width and height. - image: The
srcset
model attribute has been simplified. It is no longer an object{ data: "...", width: "..." }
, but a value previously stored in thedata
part.
MINOR BREAKING CHANGES ℹ️
- comments: The comment thread's "resolved" state has been separated from the "unlinked" state (a state, when the related editor content was removed from the document). A thread can have any combination of these states. If a comment thread is either "resolved" or "unlinked", it is moved to the comments archive. This new approach is reflected in the comments archive UI. Notably, an "unlinked" comment thread can become resolved and reopened while still being in the comments archive. Additionally, the "unlinked" comment threads have a gray header color to differentiate them from the "resolved" comment threads.
- comments: The
Comment#archivedAt
is now the property to check when deciding whether the comment thread is inside the comments archive or not (that property was#resolvedAt
before). - comments:
CommentsArchive#resolvedThreads
has been renamed to#archivedThreads
. If your custom code used that property, make sure to apply this change. - comments: The
deletedAt
property is no longer passed inAddCommentThreadEvent
as it is not needed anymore. Instead, deleted comment threads should never be handled inaddCommentThread
as they should never be added to the repository. If your custom code used that property, make sure to apply this change. - comments: In a real-time collaboration environment, removed comment threads will no longer be added to
CommentsRepository
after re-initializing the editor. Before, the comment thread was removed fromCommentsRepository
but was added back when the editor re-connected to Cloud Services. If your custom code expected the old (incorrect) behavior, it might need a change. This change was reflected in the comments outside editor documentation page.
Features
- ai: Introduced the AI assistant feature.
- clipboard: Enabled the block drag and drop by default. Closes #14734. (commit)
- clipboard: Extended the drag and drop selection to parent elements when all their children are selected. Closes #14640. (commit)
- image: The image
width
andheight
attributes are now preserved while loading editor content. Closes #14146. (commit) - image: Images without a specified size will automatically gain natural image width and height dimensions on any interaction with the image. See #14146. (commit)
- list: Allow restricting list item content to a single text block by disabling the
list.multiBlock
configuration option. Closes #14634. (commit) - list: Introducing the to-do lists compatible with the document list feature. Closes #14663. (commit)
- ui: Implemented new UI components:
ListItemGroupView
,TextareaView
,SpinnerView
,SearchView
andAutocompleteView
. (commit) - ui: Introduced the
HighlightedTextView
component for better search results presentation. (commit)
Bug fixes
- clipboard: Improved displaying preview of the drag and drop content. Closes #14968. (commit)
- comments: Comment threads that were permanently deleted will be removed from
CommentsRepository
and, in case of real-time collaboration, they will not be added back after re-connecting to the document. - engine: The editor wil no longer throw an error when clicking on a balloon with input on Firefox. Closes #9635. (commit)
- image: Image should not be replaced when dropped below a widget. Closes #14710, #14740. (commit)
- list: A dragged whole list item should still be a list item when dropped. Closes #14969. (commit)
- mention: Fixed typing of the
Mention#toMentionAttribute()
method. Closes #14923. (commit) - utils: Balloon panels should not stick out of the visible part of the editor while scrolling. (commit)
- utils: Fixed wrong tooltip when hovering over the toolbar buttons in Chrome on iOS. Closes #13812. (commit)
- utils: The coordinates of an element are now correctly calculated relative to the positioned ancestor element. Closes #14992. (commit)
Other changes
- comments: Introduced the
Comment#unlinkedAt
andComment#archivedAt
properties and theComment#setUnlinkedAt()
method. - comments: The
deletedAt
property is no longer passed inAddCommentThreadEvent
as it is not needed anymore. - comments: Renamed
CommentsArchive#resolvedThreads
to#archivedThreads
. - comments: Comment threads are no longer treated as "resolved" when their related content is removed from the document. These threads are now in the "unlinked" state.
- theme-lark: Improved the drag and drop target line. Closes #14645. (commit)
- ui: Made the
ButtonView
label logic open for extension. (commit) - ui: Changed the default icon for the
BallonEditor
toolbar handle and added the ability to customize it. Closes #14646. (commit) - Optimized icons. (commit)
- Updated translations. (commit, commit, commit)
- Added support to execute the
yarn run clean-up-svg-icons
script without arguments to optimize all icons in the entire project. Closes #14912. (commit)
Released packages
Check out the Versioning policy guide for more information.
Released packages (summary)
New packages:
- @ckeditor/ckeditor5-ai: v40.0.0
Major releases (contain major breaking changes):
- @ckeditor/ckeditor5-image: v39.0.2 => v40.0.0
Minor releases (contain minor breaking changes):
- @ckeditor/ckeditor5-comments: v39.0.2 => v40.0.0
Other releases:
- @ckeditor/ckeditor5-adapter-ckfinder: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-alignment: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-autoformat: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-autosave: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-basic-styles: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-block-quote: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-build-balloon: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-build-balloon-block: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-build-classic: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-build-decoupled-document: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-build-inline: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-build-multi-root: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-ckbox: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-ckfinder: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-clipboard: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-cloud-services: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-code-block: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-collaboration-core: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-core: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-document-outline: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-easy-image: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-editor-balloon: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-editor-classic: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-editor-decoupled: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-editor-inline: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-editor-multi-root: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-engine: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-enter: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-essentials: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-export-pdf: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-export-word: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-find-and-replace: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-font: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-format-painter: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-heading: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-highlight: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-horizontal-line: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-html-embed: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-html-support: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-import-word: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-indent: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-language: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-link: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-list: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-markdown-gfm: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-media-embed: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-mention: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-minimap: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-operations-compressor: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-page-break: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-pagination: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-paragraph: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-paste-from-office: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-paste-from-office-enhanced: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-real-time-collaboration: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-remove-format: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-restricted-editing: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-revision-history: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-select-all: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-show-blocks: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-slash-command: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-source-editing: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-special-characters: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-style: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-table: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-template: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-theme-lark: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-track-changes: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-typing: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-ui: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-undo: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-upload: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-utils: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-watchdog: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-widget: v39.0.2 => v40.0.0
- @ckeditor/ckeditor5-word-count: v39.0.2 => v40.0.0
- ckeditor5-collaboration: v39.0.2 => v40.0.0