typing/utils/utils
@ckeditor/ckeditor5-typing/src/utils/utils
Filtering
Functions
-
compareChildNodes( oldChild, newChild ) → Boolean
module:typing/utils/utils~compareChildNodes
private
Checks whether two view nodes are identical, which means they are the same object or contain exactly same data (in case of text nodes).
Parameters
Returns
Boolean
-
containerChildrenMutated( mutations ) → Boolean
module:typing/utils/utils~containerChildrenMutated
private
Returns true if container children have mutated or more than a single text node was changed.
Parameters
mutations : Array.<(MutatedText | MutatedChildren)>
Returns
Boolean
-
getSingleTextNodeChange( mutation ) → Object | undefined
module:typing/utils/utils~getSingleTextNodeChange
private
Returns change made to a single text node.
Parameters
mutation : MutatedText | MutatedChildren
Returns
Object | undefined
Change object (see
diffToChanges
output) or undefined if more than a single text node was changed.
-
isShiftDeleteOnNonCollapsedSelection( domEventData, document ) → Boolean
module:typing/utils/utils~isShiftDeleteOnNonCollapsedSelection
Checks if Shift + Delete keystroke was pressed on a non-collapsed selection.
This key combination has a special meaning on Windows machines and it should work in the same way as the
cut
event on a non-collapsed selection.Parameters
domEventData : DomEventData
Event data.
document : Document
The document instance on which the event has been fired.
Returns
Boolean
Every day, we work hard to keep our documentation complete. Have you spotted an outdated information? Is something missing? Please report it via our issue tracker.