Add the dark theme colors

This commit is contained in:
Tommaso Berlose
2020-10-02 17:36:39 +02:00
parent 72bf3b04a7
commit e8f3c110a8
9 changed files with 330 additions and 76 deletions

View File

@ -172,7 +172,7 @@ fun String.isValidEmail(): Boolean
= this.isNotEmpty() &&
Patterns.EMAIL_ADDRESS.matcher(this).matches()
fun Activity.isDarkTheme(): Boolean {
fun Context.isDarkTheme(): Boolean {
return resources.configuration.uiMode and Configuration.UI_MODE_NIGHT_MASK == Configuration.UI_MODE_NIGHT_YES
}