浏览代码

Merge pull request #219 from ckeditor/t/205

Internal: Removed obsolete `BalloonPanelView#maxWidth` attibute, replaced by `BalloonPanelView#className` in the past. Closes #205.
Oskar Wróbel 8 年之前
父节点
当前提交
af71b347ad

+ 1 - 9
packages/ckeditor5-ui/src/panel/balloon/balloonpanelview.js

@@ -98,13 +98,6 @@ export default class BalloonPanelView extends View {
 		this.set( 'className' );
 		this.set( 'className' );
 
 
 		/**
 		/**
-		 * Max width of the balloon panel, as in CSS.
-		 *
-		 * @observable
-		 * @member {Number} #maxWidth
-		 */
-
-		/**
 		 * A callback that starts pining the panel when {@link #isVisible} gets
 		 * A callback that starts pining the panel when {@link #isVisible} gets
 		 * `true`. Used by {@link #pin}.
 		 * `true`. Used by {@link #pin}.
 		 *
 		 *
@@ -133,8 +126,7 @@ export default class BalloonPanelView extends View {
 
 
 				style: {
 				style: {
 					top: bind.to( 'top', toPx ),
 					top: bind.to( 'top', toPx ),
-					left: bind.to( 'left', toPx ),
-					maxWidth: bind.to( 'maxWidth', toPx )
+					left: bind.to( 'left', toPx )
 				}
 				}
 			},
 			},
 
 

+ 0 - 10
packages/ckeditor5-ui/tests/panel/balloon/balloonpanelview.js

@@ -20,8 +20,6 @@ describe( 'BalloonPanelView', () => {
 	beforeEach( () => {
 	beforeEach( () => {
 		view = new BalloonPanelView();
 		view = new BalloonPanelView();
 
 
-		view.set( 'maxWidth', 200 );
-
 		return view.init();
 		return view.init();
 	} );
 	} );
 
 
@@ -95,14 +93,6 @@ describe( 'BalloonPanelView', () => {
 
 
 				expect( view.element.style.left ).to.equal( '10px' );
 				expect( view.element.style.left ).to.equal( '10px' );
 			} );
 			} );
-
-			it( 'should react on view#maxWidth', () => {
-				expect( view.element.style.maxWidth ).to.equal( '200px' );
-
-				view.maxWidth = 10;
-
-				expect( view.element.style.maxWidth ).to.equal( '10px' );
-			} );
 		} );
 		} );
 
 
 		describe( 'className', () => {
 		describe( 'className', () => {