Fix some accent colors

- Buttons in debug options (debug build only)
- Play button for video previews

Change-Id: I3de5a41ae93d0293e3322dae03a7da4593baee95
This commit is contained in:
SpiritCroc 2021-02-05 12:15:52 +01:00
parent 29a308b7c2
commit ed2ed5bef4
15 changed files with 28 additions and 8 deletions

View file

@ -9,7 +9,8 @@ source "$mydir/merge_helpers.sh"
require_clean_git
# Color corrections | TODO more?
sed -i 's|@color/riotx_accent|?colorAccent|g' vector/src/main/res/layout/*
sed -i 's|"@color/riotx_accent"|"?colorAccent"|g' vector/src/*/res/layout/*
sed -i 's|"@style/VectorButtonStyle"|"?materialButtonStyle"|g' vector/src/*/res/layout/*
uncommitted=`git status --porcelain`
if [ -z "$uncommitted" ]; then
echo "Seems like colors are still fine :)"

View file

@ -22,49 +22,49 @@
<com.google.android.material.button.MaterialButton
android:id="@+id/debug_test_text_view_link"
style="@style/VectorButtonStyle"
style="?materialButtonStyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Test linkification" />
<com.google.android.material.button.MaterialButton
android:id="@+id/debug_test_notification"
style="@style/VectorButtonStyle"
style="?materialButtonStyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Test Notification" />
<com.google.android.material.button.MaterialButton
android:id="@+id/debug_test_material_theme_light"
style="@style/VectorButtonStyle"
style="?materialButtonStyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Test Material theme Light" />
<com.google.android.material.button.MaterialButton
android:id="@+id/debug_test_material_theme_dark"
style="@style/VectorButtonStyle"
style="?materialButtonStyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Test Material theme Dark" />
<com.google.android.material.button.MaterialButton
android:id="@+id/debug_show_sas_emoji"
style="@style/VectorButtonStyle"
style="?materialButtonStyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Display all SAS emoji" />
<com.google.android.material.button.MaterialButton
android:id="@+id/debug_test_crash"
style="@style/VectorButtonStyle"
style="?materialButtonStyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Crash the app" />
<com.google.android.material.button.MaterialButton
android:id="@+id/debug_scan_qr_code"
style="@style/VectorButtonStyle"
style="?materialButtonStyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Scan QR-code" />

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 921 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6 KiB

View file

@ -0,0 +1,7 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:height="24dp"
android:width="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path android:fillColor="?colorAccentPale" android:pathData="M10,16.5V7.5L16,12M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z" />
</vector>

View file

@ -6,6 +6,7 @@
<attr name="sc_message_bg_incoming" format="color" />
<attr name="sc_message_bg_outgoing" format="color" />
<attr name="colorAccentPale" format="color" />
<attr name="riotx_positive_accent" format="color" />
<attr name="riotx_positive_accent_alpha12" format="color" />
<attr name="riotx_toolbar_bg" format="color" />

View file

@ -7,7 +7,10 @@
<color name="accent_sc_dark">#689F38</color>
<color name="accent_sc_50">#F1F8E9</color>
<color name="accent_sc_100">#DCEDC8</color>
<color name="accent_sc_200">#C5E1A5</color>
<color name="accent_sc_300">#AED581</color>
<color name="accent_sc_900">#33691E</color>
<color name="accent_sc_pale">@color/accent_sc_300</color>
<color name="direct_chat_ring_color_sc">@color/accent_sc_dark</color>
<color name="avatar_fill_sc_1">@color/accent_sc</color>
@ -31,4 +34,7 @@
<color name="sc_reaction_background_on_light">@color/accent_sc_50</color>
<color name="sc_reaction_background_on_dark">@color/accent_sc_900</color>
<!-- This is actually not an SC color, but the one found in element for ic_material_play_circle PNGs -->
<color name="element_accent_pale">#76cfa6</color>
</resources>

View file

@ -194,6 +194,7 @@
<item name="riotx_unread_unimportant_room_badge">@color/riotx_unread_room_badge_dark</item>
<item name="timestamp_overlay_fg">@color/timestamp_overlay_fg</item>
<item name="timestamp_overlay_bg">@color/timestamp_overlay_bg</item>
<item name="colorAccentPale">@color/element_accent_pale</item>
<item name="android:statusBarColor">@color/riotx_header_panel_background_dark</item>
<item name="android:navigationBarColor">@color/riotx_header_panel_background_dark</item>

View file

@ -194,6 +194,7 @@
<item name="riotx_unread_unimportant_room_badge">@color/riotx_unread_room_badge_light</item>
<item name="timestamp_overlay_fg">@color/timestamp_overlay_fg</item>
<item name="timestamp_overlay_bg">@color/timestamp_overlay_bg</item>
<item name="colorAccentPale">@color/element_accent_pale</item>
<!-- Use dark color, to have enough contrast with icons color. windowLightStatusBar is only available in API 23+ -->
<item name="android:statusBarColor">@color/riotx_header_panel_background_dark</item>

View file

@ -166,12 +166,14 @@
<!-- Style to use for message text within a SnackBar in this theme. -->
<item name="snackbarTextViewStyle">@style/VectorSnackBarText</item>
<!-- SC additions -->
<item name="sc_message_bg_incoming">@color/background_floating_sc</item>
<item name="sc_message_bg_outgoing">@color/background_sc</item>
<item name="riotx_positive_accent">@color/accent_sc</item>
<item name="riotx_positive_accent_alpha12">@color/accent_sc_alpha12</item>
<item name="riotx_toolbar_bg">?riotx_background</item>
<item name="riotx_unread_unimportant_room_badge">@color/background_floating_sc</item>
<item name="colorAccentPale">@color/accent_sc_pale</item>
<item name="android:statusBarColor">@color/background_black_sc</item>
<item name="android:navigationBarColor">@color/background_black_sc</item>

View file

@ -32,6 +32,7 @@
<item name="riotx_positive_accent_alpha12">@color/accent_sc_alpha12</item>
<item name="riotx_toolbar_bg">?riotx_background</item>
<item name="riotx_unread_unimportant_room_badge">?riotx_header_panel_text_secondary</item>
<item name="colorAccentPale">@color/accent_sc_pale</item>
<item name="bottomSheetDialogTheme">@style/Vector.BottomSheet.SC.Light</item>