Cordova Android status Bar set to transparent

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP


Cordova Android status Bar set to transparent



I am trying to use this plugin below to set the statusbar to transparent. But i can not achieve it, i can change it to different colours, but not transparent.
https://github.com/apache/cordova-plugin-statusbar



Also it works on my Android 5.0.2, but not 5.0.



I tried just leaving out the hexcode value like they suggested but doesnt work, i tried all those below, none of those set my statusbar to transparent.


<preference name="StatusBarBackgroundColor"/>

<preference name="StatusBarStyle" value="lightcontent" />



if (cordova.platformId == 'android') {
StatusBar.styleBlackTranslucent();
}





Did you ever have any luck with this? I have the same issue
– Giovanni
Sep 3 '16 at 20:09





Not on Android 5.0....only on the versions after that
– John
Sep 7 '16 at 2:48




1 Answer
1



I just found it, its not mention in their documentation, but its simple as that:


<preference name="StatusBarBackgroundColor" value="transparent" />



And voilà, Its working :)





This way is not working for me, any help, please?
– Eusthace
May 31 '16 at 22:52





@Eusthace You need to install the plugin StatusBarBackgroundColor first cordova plugin add cordova-plugin-statusbar See cordova.apache.org/docs/en/latest/reference/…
– odiseo
Aug 14 '17 at 21:36


cordova plugin add cordova-plugin-statusbar





I've tried and still not working :(
– Eusthace
Aug 15 '17 at 1:32





Adding the above line to config.xml does not make status bar transparent at all.
– Angel Todorov
Jul 11 at 12:01






By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Popular posts from this blog

Keycloak server returning user_not_found error when user is already imported with LDAP

PHP parse/syntax errors; and how to solve them?

How to scale/resize CVPixelBufferRef in objective C, iOS