Răsfoiți Sursa

Internal: Collection now works on iterables.

Marek Lewandowski 5 ani în urmă
părinte
comite
a4b3293605

+ 1 - 1
packages/ckeditor5-ui/src/editorui/bodycollection.js

@@ -37,7 +37,7 @@ export default class BodyCollection extends ViewCollection {
 	 * Creates a new instance of the {@link module:ui/editorui/bodycollection~BodyCollection}.
 	 *
 	 * @param {module:utils/locale~Locale} locale The {@link module:core/editor/editor~Editor editor's locale} instance.
-	 * @param {Array.<module:ui/view~View>} [initialItems] The initial items of the collection.
+	 * @param {Iterable.<module:ui/view~View>} [initialItems] The initial items of the collection.
 	 */
 	constructor( locale, initialItems = [] ) {
 		super( initialItems );

+ 1 - 1
packages/ckeditor5-ui/src/viewcollection.js

@@ -51,7 +51,7 @@ export default class ViewCollection extends Collection {
 	/**
 	 * Creates a new instance of the {@link module:ui/viewcollection~ViewCollection}.
 	 *
-	 * @param {Array.<module:ui/view~View>} [initialItems] The initial items of the collection.
+	 * @param {Iterable.<module:ui/view~View>} [initialItems] The initial items of the collection.
 	 */
 	constructor( initialItems = [] ) {
 		super( initialItems, {