8
0
Maciej Gołaszewski 6 лет назад
Родитель
Сommit
66ba078a6b
1 измененных файлов с 5 добавлено и 0 удалено
  1. 5 0
      packages/ckeditor5-mention/src/mentionediting.js

+ 5 - 0
packages/ckeditor5-mention/src/mentionediting.js

@@ -172,6 +172,11 @@ function removePartialMentionPostFixer( writer, doc ) {
 	return wasChanged;
 	return wasChanged;
 }
 }
 
 
+// Checks if node has correct mention attribute if present.
+// Returns false if node is text and has mention attribute and its text does not match expected mention text.
+//
+// @param {module:engine/model/node~Node} node a node to check
+// @returns {Boolean}
 function checkMentionAttributeOnNode( node ) {
 function checkMentionAttributeOnNode( node ) {
 	if ( !node || !node.is( 'text' ) || !node.hasAttribute( 'mention' ) ) {
 	if ( !node || !node.is( 'text' ) || !node.hasAttribute( 'mention' ) ) {
 		return true;
 		return true;