-
Notifications
You must be signed in to change notification settings - Fork 32
Description
First of all 👍 for this nice plugin.
When I set androidTranslucentStatusBar="true" on Slides:SlideContainer tag, on android it is working fine but on iOS its giving me below error:
file:///app/tns_modules/nativescript-slides/nativescript-slides.js:215:47: JS ERROR TypeError: undefined is not an object (evaluating 'app.android.startActivity'
After digging into code, If found the issue in constructView funciton at below line:
if (this.androidTranslucentStatusBar === true || this._androidTranslucentNavBar === true && app.android && Platform.device.sdkVersion >= '19') {
As || precedence is lower than &&, if androidTranslucentStatusBar is true, the condition will be true and it will try to execute android specific code on iOS and is giving error.
Changing that condition to below, it is working fine.
if(app.android && Platform.device.sdkVersion >= '19' && (this.androidTranslucentStatusBar === true || this._androidTranslucentNavBar === true ))
If it is ok, please correct it in the source code.