I have a kotlin multiplatform app, where I use isSystemInDarkTheme() to determine if the system has dark mode set. However, for the generated webapp, isSystemInDarkTheme() always returns false. I tested this on Firefox and Chromium.
Is this a bug? Do I need to use another function for web?
I have a kotlin multiplatform app, where I use isSystemInDarkTheme() to determine if the system has dark mode set. However, for the generated webapp, isSystemInDarkTheme() always returns false. I tested this on Firefox and Chromium.
Is this a bug? Do I need to use another function for web?
I upgraded to the latest kotlin version (2.1) and now isSystemInDarkTheme() works as expected.
My way to upgrading was generating a new kotlin multiplatform app (https://kmp.jetbrains.com/) and then putting the relevant import statements into my project.