apache / cordova-plugin-statusbar

Apache Cordova Status Bar Plugin
https://cordova.apache.org/
Apache License 2.0
619 stars 481 forks source link

Not working at all on IOS #102

Closed pixelgroup-israel closed 6 years ago

pixelgroup-israel commented 6 years ago

Hi,

I'm using Cordova CLI 7.1.0 and this plugin is not working on IOS at all. Not when I'm trying to set values via config.xml or ondeviceready. When I do console.log to the StatusBar object it's present, But the methods has no effect what so ever. Tested on Iphone 5s, 6, 6 plus, 8 plus.

Please advise.

janpio commented 6 years ago

Start with using the most recent Cordova CLI version 8.0.0. What version of cordova-ios are you using? What code are you using, or just configuration?

pixelgroup-israel commented 6 years ago

The use of Cordova CLI 7.1.0 is mandatory. I can not upgrade at the the time to 8.0.0 because of other dependencies.

I'm using Cordova IOS 4.5.4.

I have tried with the config.xml variables and they didn't work. Then I tried Javascript commands and they too didn't work.

StatusBar.styleDefault(); StatusBar.backgroundColorByName("red"); StatusBar.hide();

Off course everything after device ready event.

janpio commented 6 years ago

So https://github.com/apache/cordova-plugin-statusbar#methods logs nothing?

Please reproduce with a new project created with cordova create and log all commands you are executing and output you are getting. If it fails there as well, post that all.

pixelgroup-israel commented 6 years ago

No, it logs nothing.

I'm using Monaca IDE, not the Cordova CLI but this has happened to me on 2 separate apps both using Cordova 7.1.0

janpio commented 6 years ago

Please reproduce with a new project created with cordova create and log all commands you are executing and output you are getting. If it fails there as well, post that all.

... and post the project to a GitHub repository so we can simply reproduce. Thanks.

guigralho commented 6 years ago

Hi, I'm facing the same problem.

I'm using Cordova 8.0.0 and Cordova IOS 4.5.4 on phonegap and it didn't work. StatusBar.isVisible says me that the bar is there but everything stays white. Tried every configurations that is available and nothing.

janpio commented 6 years ago

@guigralho Please open your own issue to get this debugged. What does "on phonegap" mean?

guigralho commented 6 years ago

But my issue is the same as this one, why opening a new issue to talk about the same thing?

I mean that I'm developing my app on PhoneGap and I've installed this plugin to change the statusbar's color. I'm using Cordova 8.0.0 and Cordova IOS 4.5.4 but it didn't work on IOS at all.

Please if you could help I would be thankful

janpio commented 6 years ago

I repeat, what does "on Phonegap" mean? I know Phonegap CLI and Phonegap Build.

rurouniKaung commented 6 years ago

Hi, I was facing the same problem. But now it is working by following

# uninstall app from device
# close xcode
cordova plugin remove cordova-plugin-statusbar
cordova prepare
cordova clean ios
# open up xcode
# clean project in xcode
# run project from xcode onto device
# stop the app
# close xcode
cordova plugin add cordova-plugin-statusbar
# add preferences to config.xml
cordova prepare
cordova clean ios
# open up xcode
# clean project in xcode
# run project from xcode onto device

There is an answer on following link. Thanks to @tyler.frankenstein

https://stackoverflow.com/a/47005553/3089616

guigralho commented 6 years ago

Thank you @rurouniKaung ! I will try these steps.

@janpio it's Phonegap CLI

pixelgroup-israel commented 6 years ago

Hi All,

I have managed to find a solution to this issue. There seem to be a problem when implementing this plugin with the cordova-admob-pro plugin.

Please see the following link: https://stackoverflow.com/questions/44052250/ios10-cordova-status-bar-overlap-with-content