Parcourir la source

Make resizeObserver protected value

panr il y a 6 ans
Parent
commit
8a4315a2d9
1 fichiers modifiés avec 2 ajouts et 2 suppressions
  1. 2 2
      packages/ckeditor5-ui/src/toolbar/balloon/balloontoolbar.js

+ 2 - 2
packages/ckeditor5-ui/src/toolbar/balloon/balloontoolbar.js

@@ -78,7 +78,7 @@ export default class BalloonToolbar extends Plugin {
 		 *
 		 * **Note:** Created in {@link #init}.
 		 *
-		 * @readonly
+		 * @protected
 		 * @member {module:utils/dom/getresizeobserver~ResizeObserver}
 		 */
 		this.resizeObserver = null;
@@ -154,7 +154,7 @@ export default class BalloonToolbar extends Plugin {
 				const editableElement = editor.ui.view.editable.element;
 
 				// Set toolbar's max-width on the initialization and update it on the editable resize.
-				this.widthObserver = new ResizeObserver( editableElement, () => {
+				this.resizeObserver = new ResizeObserver( editableElement, () => {
 					// We need to check if there's already the editable element in the DOM.
 					// Otherwise the `Rect` instance will complain that source (editableElement) is not available
 					// to obtain the element's geometry.