Git Product home page Git Product logo

Comments (7)

forumics avatar forumics commented on July 18, 2024 16

edit CDVStatusBar.m
look for this line:

  • (void) styleDefault:(CDVInvokedUrlCommand*)command

replace the whole method with

  • (void) styleDefault:(CDVInvokedUrlCommand*)command
    {
    if (@available(iOS 13.0, *)) {
    [self setStyleForStatusBar:UIStatusBarStyleDarkContent];
    } else {
    [self setStyleForStatusBar:UIStatusBarStyleDefault];
    }
    }

from cordova-plugin-statusbar.

forumics avatar forumics commented on July 18, 2024 1

when i have the time, i will create a fork and implement your suggestion

from cordova-plugin-statusbar.

jcesarmobile avatar jcesarmobile commented on July 18, 2024 1

closing since looks like people wants default to be black as it used to instead of native default.
That behavior has been fixed in #169

from cordova-plugin-statusbar.

jcesarmobile avatar jcesarmobile commented on July 18, 2024

Default should be the native default and we should add styleDark

#164

from cordova-plugin-statusbar.

rml125 avatar rml125 commented on July 18, 2024

edit CDVStatusBar.m
look for this line:

  • (void) styleDefault:(CDVInvokedUrlCommand*)command

replace the whole method with

  • (void) styleDefault:(CDVInvokedUrlCommand*)command
    {
    if (@available(iOS 13.0, *)) {
    [self setStyleForStatusBar:UIStatusBarStyleDarkContent];
    } else {
    [self setStyleForStatusBar:UIStatusBarStyleDefault];
    }
    }

WoooW! I had the same problem. This fix worked perfectly.

from cordova-plugin-statusbar.

jcesarmobile avatar jcesarmobile commented on July 18, 2024

Please, don't comment things out of topic.

The issue is about deprecating styleDefault because the name is confusing (default value of statusbar is lightContent).
Or documenting the iOS 13 behaviour (i.e. default depends on the device mode, dark mode -> white, light mode -> black)
Or just make it always set the text to black as it used to, but in that case I think it would be better to add a new method styleDark and deprecate/remove the default one.

from cordova-plugin-statusbar.

danielehrhardt avatar danielehrhardt commented on July 18, 2024

when i have the time, i will create a fork and implement your suggestion

https://github.com/codextde/cordova-plugin-statusbar-color-fix

from cordova-plugin-statusbar.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.