Explorar el Código

Internal: Postfixing the previous merge.

Piotrek Koszuliński hace 6 años
padre
commit
dbfd40f44a
Se han modificado 1 ficheros con 5 adiciones y 2 borrados
  1. 5 2
      packages/ckeditor5-widget/src/widgetresize/resizerstate.js

+ 5 - 2
packages/ckeditor5-widget/src/widgetresize/resizerstate.js

@@ -126,8 +126,11 @@ export default class ResizeState {
 
 		const widthStyle = domResizeHost.style.width;
 
-		this.originalWidthPercents = widthStyle && widthStyle.match( /^\d+\.?\d*%$/ ) ?
-			parseFloat( widthStyle ) : calculateHostPercentageWidth( domResizeHost, clientRect );
+		if ( widthStyle && widthStyle.match( /^\d+\.?\d*%$/ ) ) {
+			this.originalWidthPercents = parseFloat( widthStyle );
+		} else {
+			this.originalWidthPercents = calculateHostPercentageWidth( domResizeHost, clientRect );
+		}
 	}
 
 	update( newSize ) {