You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
According to the documention (https://ionicframework.com/docs/theming/dark-mode) for Ionic v5, you don't have to do anything more than using the CSS Media Query @media (prefers-color-scheme: dark) in order to support native Dark Mode on mobiles.
But this is not true.
As I undestand it, it was working natively with Cordova, but doesn't anymore with Capacitor (An issue has been opened on ionic-team/capacitor#4677).
I think a disclaimer as below should be added to the documentation to warn the user about Capacitor not yet supporting this :
I has never worked natively on Android WebView, not even in Cordova.
But starting in Chrome/system WebView 90, the WebView started respecting the app theme (not the system theme).
But turns out if you change the theme to DayNight it will use the system theme.
Newly created Capacitor 4 apps will use that theme by default, existing apps will need to change the theme. No plugins needed anymore, it's explained in the linked issue.
According to the documention (https://ionicframework.com/docs/theming/dark-mode) for Ionic v5, you don't have to do anything more than using the CSS Media Query
@media (prefers-color-scheme: dark)
in order to support native Dark Mode on mobiles.But this is not true.
As I undestand it, it was working natively with Cordova, but doesn't anymore with Capacitor (An issue has been opened on ionic-team/capacitor#4677).
I think a disclaimer as below should be added to the documentation to warn the user about Capacitor not yet supporting this :
The text was updated successfully, but these errors were encountered: