style: add basic black theme

Finally add black theme support to Auxio. This is abit of a janky
implementation since I had to add an extra set of accents, but it
shouldn't be as big of a problem after the styles refactoring.
Support for black android components is not implemented yet, but
will be eventually.
This commit is contained in:
OxygenCobalt
2021-06-11 09:13:20 -06:00
parent dc2157904a
commit 68bdd0d929
12 changed files with 232 additions and 25 deletions
@@ -79,6 +79,7 @@
android:layout_marginStart="@dimen/spacing_mid_large"
android:layout_marginEnd="@dimen/spacing_mid_large"
android:layout_marginBottom="@dimen/spacing_medium"
android:text="@{song.album.name}"
android:onClick="@{() -> detailModel.navToItem(playbackModel.song.album)}"
app:layout_constraintBottom_toTopOf="@+id/playback_seek_bar"
app:layout_constraintEnd_toEndOf="parent"
+2
View File
@@ -7,6 +7,8 @@
<color name="control_color">#202020</color>
<color name="nav_color">#01fafafa</color>
<color name="background_black">#000000</color>
<color name="selection_color_black">#343434</color>
<!--
Base color set derived from Music Player GO.
+2
View File
@@ -63,6 +63,8 @@
<string name="setting_theme_day">Light</string>
<string name="setting_theme_night">Dark</string>
<string name="setting_accent">Accent</string>
<string name="setting_black_mode">Black night theme</string>
<string name="setting_black_mode_desc">Use a pure-black night theme</string>
<string name="setting_display">Display</string>
<string name="setting_lib_display">Library Items</string>
+5
View File
@@ -36,4 +36,9 @@
<item name="materialAlertDialogTheme">@style/Theme.CustomDialog</item>
<!-- @formatter:on -->
</style>
<style name="Theme.Base.Black" parent="Theme.Base">
<item name="colorSurface">@color/background_black</item>
<item name="colorControlHighlight">@color/selection_color_black</item>
</style>
</resources>
+1 -1
View File
@@ -83,7 +83,7 @@
<item name="colorSecondary">@color/brown</item>
</style>
<style name="Theme.Gray" parent="Theme.Base">
<style name="Theme.Grey" parent="Theme.Base">
<item name="colorPrimary">@color/grey</item>
<item name="colorSecondary">@color/grey</item>
</style>
+100
View File
@@ -0,0 +1,100 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<!--
All the base themes/accents for black mode.
-->
<style name="Theme.Red.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/red</item>
<item name="colorSecondary">@color/red</item>
</style>
<style name="Theme.Pink.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/pink</item>
<item name="colorSecondary">@color/pink</item>
</style>
<style name="Theme.Purple.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/purple</item>
<item name="colorSecondary">@color/purple</item>
</style>
<style name="Theme.DeepPurple.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/deep_purple</item>
<item name="colorSecondary">@color/deep_purple</item>
</style>
<style name="Theme.Indigo.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/indigo</item>
<item name="colorSecondary">@color/indigo</item>
</style>
<style name="Theme.Blue.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/blue</item>
<item name="colorSecondary">@color/blue</item>
</style>
<style name="Theme.LightBlue.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/light_blue</item>
<item name="colorSecondary">@color/light_blue</item>
</style>
<style name="Theme.Cyan.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/cyan</item>
<item name="colorSecondary">@color/cyan</item>
</style>
<style name="Theme.Teal.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/teal</item>
<item name="colorSecondary">@color/teal</item>
</style>
<style name="Theme.Green.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/green</item>
<item name="colorSecondary">@color/green</item>
</style>
<style name="Theme.LightGreen.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/light_green</item>
<item name="colorSecondary">@color/light_green</item>
</style>
<style name="Theme.Lime.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/lime</item>
<item name="colorSecondary">@color/lime</item>
</style>
<style name="Theme.Yellow.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/yellow</item>
<item name="colorSecondary">@color/yellow</item>
</style>
<style name="Theme.Orange.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/orange</item>
<item name="colorSecondary">@color/orange</item>
</style>
<style name="Theme.DeepOrange.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/deep_orange</item>
<item name="colorSecondary">@color/deep_orange</item>
</style>
<style name="Theme.Brown.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/brown</item>
<item name="colorSecondary">@color/brown</item>
</style>
<style name="Theme.Grey.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/grey</item>
<item name="colorSecondary">@color/grey</item>
</style>
<style name="Theme.BlueGrey.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/blue_grey</item>
<item name="colorSecondary">@color/blue_grey</item>
</style>
<style name="Theme.Neutral.Black" parent="Theme.Base.Black">
<item name="colorPrimary">@color/control_color</item>
<item name="colorSecondary">@color/control_color</item>
</style>
</resources>
+8
View File
@@ -20,6 +20,14 @@
app:summary="@string/color_label_blue"
app:title="@string/setting_accent" />
<SwitchPreferenceCompat
app:defaultValue="true"
app:iconSpaceReserved="false"
app:key="KEY_BLACK_THEME"
app:title="@string/setting_black_mode"
app:summary="@string/setting_black_mode_desc"
app:allowDividerBelow="false" />
</PreferenceCategory>
<PreferenceCategory