v13.0.0
Features
- Added an additional event in markers conversion. Improved how
MarkerOperation
is transformed during undo. Closes #1604. (da5a390) - Implemented
Selection#is()
andDocumentSelection#is()
methods in both the model and the view. Closes #1663. (aac4948) - Introduce the
selection.getTopMostBlocks()
method. (a9c41c8) - Introduce the read-only
View#isRenderingInProgress
flag to check if the document is in the rendering phase. Closes ckeditor/ckeditor5#1530. (6577d04) - Introduced
Differ#getChangedMarkers
. Closes #1658. (2e04af7) - Introduced
DocumentSelection#markers
collection. Closes #1615. (b2c1d72) - Introduced support for inline objects (enables support for inline widgets). Introduced
Schema#isInline()
. Closes [ckeditor/ckeditor5#1049](ckeditor/ckeditor5#1049). Closes [ckeditor/ckeditor5#1426](ckeditor/ckeditor5#1426). (6b36bf1) - Introduced whitespace trimming to
Model#hasContent()
.DataController#get()
method can now trim empty data (so it returns empty string instead of<p> </p>
). Closes [ckeditor/ckeditor5#401](ckeditor/ckeditor5#401). (2b95dc3) - Moved the root element DOM attributes management from the UI to the engine. Made it possible to use
addPlaceholder()
(nowenablePlaceholder()
) on the root editable. Introduced theView.detachDomRoot()
method. Implemented additional placeholder helpers (showPlaceholder()
,hidePlaceholder()
,needsPlaceholder()
) (see ckeditor/ckeditor5#479). Closes #899. (21dee6b)
Bug fixes
-
MarkerOperation
transformation in undo. Closes #1668. (c9932b8) -
Selection#getTopMostBlocks()
should not leak from limit elements. Closes ckeditor/ckeditor5-table#163. (7bc0338) -
All content is properly removed after undoing paste in some scenarios. Closes [ckeditor/ckeditor5#1540](ckeditor/ckeditor5#1540). (08855d3)
-
Converter priority passing in
conversion.attributeToElement()
. Closes #1617. (fe6d17d) -
Fake selection container should be correctly appended to the new editable element when creating a new fake selection in a different editable element than the one which was focused before. Closes [ckeditor/ckeditor5#1523](ckeditor/ckeditor5#1523). (3b53d5a)
-
Filter out fake selection container before comparing DOM view root children in view renderer. Closes ckeditor/ckeditor5#1578. (6591f87)
-
Moving to the same position is not handled by the
Differ
as a change. (7dfaae6) -
Prevented
model.Writer
from inserting empty text nodes. Closes #1320. (47070b5) -
Prevented
View
from firing therender
event if there were no changes since the last rendering. Closes #1653. Closes #1660. (558638c) -
Renamed the event during selection attributes conversion.
attribute:key
becomes toattribute:key:$text
. Closes #1597. (fd7734e) -
Stopped invoking
view.render()
byEditingController
when the model document isn't changed. Closes #1653. (5d97fd6) -
Fixed memory leaks during editor initialization and destruction (see ckeditor/ckeditor5#1341). (bf86ffa)
-
Undo and redo no longer crashes in scenarios featuring pasting content into earlier pasted content. Closes [ckeditor/ckeditor5#1385](ckeditor/ckeditor5#1385). (551ab50)
-
Update model selection attributes and markers after each change that affects the selection. Closes #1673. (4f9ac0e)
-
Add selection post-fixer improvements. Closes #1593. (7f40831)
Other changes
- Added support for handling data in multiple roots in
DataController
. Closes #1626. (0fb4295) - Change
Conversion
class API. Closes #1640. (e7d09cd) - Introduced
editor.data#ready
event. (46d9243) - Removed
wrap()
from public API. Closes #1616. (1c7ef68) - Swapped the order of parameters in
Schema#findAllowedParent()
. Now those parameters match to parameters in other methods of theSchema
class. Closes #1636. (6515558) - Upcast element to attribute defaults to
low
priority instead ofnormal
. Closes ckeditor/ckeditor5#1399. (c33c49c) - Expose conversion utilities. Closes #1556. (9306c22)
BREAKING CHANGES
- Upgraded minimal versions of Node to
8.0.0
and npm to5.7.1
. See: ckeditor/ckeditor5#1507. (612ea3c) DataController#get()
method now returns an empty string when the editor content is empty (instead of returning e.g.<p> </p>
).- The wrap() conversion helper was removed from public API.
- The
attachPlaceholder()
has been renamed toenablePlaceholder()
. enablePlaceholder()
accepts a configuration object instead of separate parameters.- The
detachPlaceholder()
has been renamed todisablePlaceholder()
. - The
Conversion#register()
method was removed from the public API. Use constructor parameters to pass dispatchers andConversion#addAlias()
to register an alternative conversion group for registered upcast or downcast dispatchers. - The
editor#dataReady
event was removed. Theeditor.data#ready
event has been introduced and should be used instead. - Swapped the order of parameters in
Schema#findAllowedParent()
. - The second parameter (
rootName
) fromDataController#init()
method has been removed. To initialize data on a root different than default one an object withrootName
-data
pair should be passed. - The second parameter (
rootName
) fromDataController#set()
method has been removed. To set data on a root different than default one an object withrootName
-data
pair should be passed. - The
editing.view.render()
method was renamed toediting.view.forceRender()
. It should be used with caution as it will re-render editing view and repaint the UI. - The
conversion.register()
method now accepts single options object as a parameter. - The
downcastElementToElement()
helper was removed from public API. Useconversion.for( 'downcast' ).elementToElement()
instead. - The
downcastAttributeToElement()
helper was removed from public API. Useconversion.for( 'downcast' ).attributeToElement()
instead. - The
downcastAttributeToAttribute()
helper was removed from public API. Useconversion.for( 'downcast' ).attributeToAttribute()
instead. - The
downcastMarkerToElement()
helper was removed from public API. Useconversion.for( 'downcast' ).markerToElement()
instead. - The
downcastMarkerToHighlight()
helper was removed from public API. Useconversion.for( 'downcast' ).markerToHighlight()
instead. - The
upcastElementToElement()
helper was removed from public API. Useconversion.for( 'upcast' ).elementToElement()
instead. - The
upcastElementToAttribute()
helper was removed from public API. Useconversion.for( 'upcast' ).elementToAttribute()
instead. - The
upcastAttributeToAttribute()
helper was removed from public API. Useconversion.for( 'upcast' ).attributeToAttribute()
instead. - The
upcastElementToMarker()
helper was removed from public API. Useconversion.for( 'upcast' ).elementToMarker()
instead. - The
insertUIElement()
andremoveUIElement()
downcast converters were removed from public API. Useconversion.for( 'downcast' ).markerToElement()
instead. - The
highlightText()
,highlightElement()
andremoveHighlight()
downcast converters were removed from public API. Useconversion.for( 'downcast' ).markerToHighlight()
instead. - The
insertElement()
downcast converter was removed from public API. Useconversion.for( 'downcast' ).elementToElement()
instead. - The
changeAttribute()
downcast converter was removed from public API. Useconversion.for( 'downcast' ).attributeToAttribute()
instead.