bug: Status bar not visible on iOS application using Ionic Capacitor
See original GitHub issueBug Report
Capacitor Version
npx cap doctor
output:
๐ Capacitor Doctor ๐
Latest Dependencies:
@capacitor/cli: 1.2.1
@capacitor/core: 1.2.1
@capacitor/android: 1.2.1
@capacitor/ios: 1.2.1
Installed Dependencies:
@capacitor/android not installed
@capacitor/cli 1.2.1
@capacitor/core 1.2.1
@capacitor/ios 1.2.1
Found 7 Capacitor plugins for ios:
capacitor-fcm (0.1.0)
cordova-plugin-facebook4 (6.2.0)
cordova-plugin-ionic (5.4.5)
cordova-plugin-streaming-media (2.2.0)
cordova-plugin-whitelist (1.3.4)
cordova-plugin-x-socialsharing (5.6.2)
es6-promise-plugin (4.2.2)
[success] iOS looking great! ๐
Affected Platform(s)
- Android
- iOS
- Electron
- Web
Current Behavior
When I open the application, I can see the status bar data (provider, time, connection and battery status) during the startup (splash screen). When the application has loaded, the status bar is invisible, but taking up space on the top of the application header.
Setup in Info.plist on the iOS App:
View controller-based status bar appearance = YES
Status bar is initially hidden = NO
Stats bar style = Light Content
(none of these settings seem to have any effect on the behavior)
I am calling this on platform ready in app.component.ts:
Plugins.StatusBar.show()
.then(_ => console.log("Status bar shown: " + JSON.stringify(_)))
.catch(_ => console.log(_));
Plugins.StatusBar.setStyle({ style: StatusBarStyle.Dark })
.then(_ => console.log("Status bar set: " + JSON.stringify(_)))
.catch(_ => console.log(_));
Plugins.StatusBar.addListener("statusTap", () => console.log("Status bar tapped"));
Console output:
[log] - Status bar shown: {}
[log] - Status bar set: {}
Tapping the status bar does not scroll up the current view and does not show the tap event (console log).
Odd: The green battery symbol is visible on the status bar when the phone is plugged in. Nothing else is visible. When there is an overlay on the app (like a modal), the status bar is visible on an iPad.
Expected Behavior
Status bar should show appropriately. On click the view should scroll up.
Setup
I have an Ionic Angular application using Capacitor, with an ion-split-pane
element within the ion-app
root tag.
Issue Analytics
- State:
- Created 4 years ago
- Comments:9 (3 by maintainers)
Top GitHub Comments
If you go to Xcode you can select it:
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Capacitor, please create a new issue and ensure the template is fully filled out.