mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-08-15 19:26:42 +08:00
Set length value to auto when length is undefined
This commit is contained in:
@ -1116,7 +1116,7 @@ function createNativePercentLengthProperty(options: NativePercentLengthPropertyO
|
||||
setPercent = options.setPercent || percentNotSupported;
|
||||
options = null;
|
||||
}
|
||||
if (length == "auto") { // tslint:disable-line
|
||||
if (length == "auto" || !length) { // tslint:disable-line
|
||||
setPixels(this.nativeViewProtected, auto);
|
||||
} else if (typeof length === "number") {
|
||||
setPixels(this.nativeViewProtected, layout.round(layout.toDevicePixels(length)));
|
||||
|
Reference in New Issue
Block a user