Fixes night mode colors
This commit is contained in:
parent
2d2f8f5479
commit
051adad0ed
|
@ -0,0 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<bool name="isDarkMode">true</bool>
|
||||
|
||||
</resources>
|
|
@ -0,0 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<color name="modal_background_color">@color/element_system_dark</color>
|
||||
|
||||
</resources>
|
|
@ -3,5 +3,6 @@
|
|||
|
||||
<!-- Created to detect what has to be implemented (especially in the settings) -->
|
||||
<bool name="false_not_implemented">false</bool>
|
||||
<bool name="isDarkMode">false</bool>
|
||||
|
||||
</resources>
|
||||
</resources>
|
||||
|
|
|
@ -36,6 +36,8 @@
|
|||
<color name="android_status_bar_background_dark">@color/element_background_dark</color>
|
||||
<color name="android_navigation_bar_background_dark">@color/element_system_dark</color>
|
||||
|
||||
<color name="modal_background_color">#FFFFFF</color>
|
||||
|
||||
<!-- Used for toolbar background -->
|
||||
<attr name="vctr_toolbar_background" format="color" />
|
||||
|
||||
|
|
|
@ -46,6 +46,7 @@ import androidx.viewbinding.ViewBinding
|
|||
import com.airbnb.mvrx.MavericksView
|
||||
import com.bumptech.glide.util.Util
|
||||
import com.google.android.material.appbar.MaterialToolbar
|
||||
import com.google.android.material.color.MaterialColors
|
||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||
import com.google.android.material.snackbar.Snackbar
|
||||
import dagger.hilt.android.EntryPointAccessors
|
||||
|
@ -238,8 +239,9 @@ abstract class VectorBaseActivity<VB : ViewBinding> : AppCompatActivity(), Maver
|
|||
|
||||
initUiAndData()
|
||||
|
||||
window.statusBarColor = ContextCompat.getColor(this, android.R.color.white)
|
||||
window.navigationBarColor = ContextCompat.getColor(this, android.R.color.white)
|
||||
val toolbarBackgroundRes = R.color.modal_background_color
|
||||
window.statusBarColor = ContextCompat.getColor(this, toolbarBackgroundRes)
|
||||
window.navigationBarColor = ContextCompat.getColor(this, toolbarBackgroundRes)
|
||||
val titleRes = getTitleRes()
|
||||
if (titleRes != -1) {
|
||||
supportActionBar?.let {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<solid android:color="#FFF"/>
|
||||
<solid android:color="@color/modal_background_color"/>
|
||||
<corners
|
||||
android:bottomLeftRadius="12dp"
|
||||
android:bottomRightRadius="12dp" />
|
||||
|
|
|
@ -56,7 +56,7 @@
|
|||
app:layout_constraintEnd_toEndOf="@id/add_space_icon_background"
|
||||
app:layout_constraintStart_toStartOf="@id/add_space_icon_background"
|
||||
app:layout_constraintTop_toTopOf="@id/add_space_icon_background"
|
||||
app:tint="#000" />
|
||||
app:tint="?attr/vctr_spoiler_background_color" />
|
||||
|
||||
<TextView
|
||||
style="@style/Widget.Vector.TextView.Body.Medium"
|
||||
|
|
Loading…
Reference in New Issue