Bladeren bron

Docs update.

Piotr Jasiun 9 jaren geleden
bovenliggende
commit
9c52e05404

+ 2 - 1
packages/ckeditor5-utils/src/dom/createelement.js

@@ -9,13 +9,14 @@ import isString from '../lib/lodash/isString.js';
 import utils from '../utils.js';
 
 /**
- * Create element with attributes and children.
+ * Creates element with attributes and children.
  *
  *		createElement( document, 'p' ); // <p>
  *		createElement( document, 'p', { class: 'foo' } ); // <p class="foo">
  *		createElement( document, 'p', null, 'foo' ); // <p>foo</p>
  *		createElement( document, 'p', null, [ 'foo', createElement( document, 'img' ) ] ); // <p>foo<img></p>
  *
+ * @method utils.dom.createElement
  * @param {Document} doc Document used to create element.
  * @param {String} name Name of the element.
  * @param {Object} attributes Object keys will become attributes keys and object values will became attributes values.

+ 2 - 0
packages/ckeditor5-utils/src/dom/indexof.js

@@ -8,6 +8,8 @@
 /**
  * Returns index of the node in the parent element.
  *
+ * @method utils.dom.indexOf
+ * @param {Node} node Node which index is tested.
  * @returns {Number} Index of the node in the parent element. Returns 0 if node has no parent.
  */
 export default function indexOf( node ) {

+ 1 - 1
packages/ckeditor5-utils/src/dom/insertat.js

@@ -6,7 +6,7 @@
 'use strict';
 
 /**
- * Insert node to the parent at given index.
+ * Inserts node to the parent at given index.
  *
  * @param {Element} parentElement Parent element.
  * @param {Number} index Insertions index.

+ 1 - 1
packages/ckeditor5-utils/src/dom/remove.js

@@ -6,7 +6,7 @@
 'use strict';
 
 /**
- * Remove given node from parent.
+ * Removes given node from parent.
  *
  * @param {Node} node Node to remove.
  */