From 5b9af49ff400d6cf42613ab2483420175ca4028a Mon Sep 17 00:00:00 2001 From: Gabriel Luong Date: Mon, 3 Jan 2022 23:26:29 -0500 Subject: [PATCH] [fenix] For https://github.com/mozilla-mobile/fenix/issues/23049 - Consolidate @color/fx_mobile_text_color_accent with @color/fx_mobile_text_color_action - Removes @color/fx_mobile_text_color_action - Use the colors from @color/fx_mobile_text_color_action in @color/fx_mobile_text_color_accent --- .../src/main/java/org/mozilla/fenix/theme/FirefoxTheme.kt | 12 ++---------- .../app/src/main/res/layout/recent_bookmarks_header.xml | 2 +- .../fenix/app/src/main/res/layout/recent_tabs_header.xml | 2 +- .../fenix/app/src/main/res/layout/recent_visits_header.xml | 2 +- .../android/fenix/app/src/main/res/values-night/colors.xml | 6 ++---- mobile/android/fenix/app/src/main/res/values/colors.xml | 6 ++---- mobile/android/fenix/app/src/main/res/values/styles.xml | 2 +- 7 files changed, 10 insertions(+), 22 deletions(-) diff --git a/mobile/android/fenix/app/src/main/java/org/mozilla/fenix/theme/FirefoxTheme.kt b/mobile/android/fenix/app/src/main/java/org/mozilla/fenix/theme/FirefoxTheme.kt index 8c06ff1531ee..2b72e0af7fa9 100644 --- a/mobile/android/fenix/app/src/main/java/org/mozilla/fenix/theme/FirefoxTheme.kt +++ b/mobile/android/fenix/app/src/main/java/org/mozilla/fenix/theme/FirefoxTheme.kt @@ -65,7 +65,6 @@ private val darkColorPalette = FirefoxColors( textSecondary = PhotonColors.LightGrey40, textDisabled = PhotonColors.LightGrey05A40, textWarning = PhotonColors.Red40, - textLink = PhotonColors.Violet40, textAccent = PhotonColors.Violet40, textInverted = PhotonColors.White, iconPrimary = PhotonColors.LightGrey05, @@ -114,8 +113,7 @@ private val lightColorPalette = FirefoxColors( textSecondary = PhotonColors.DarkGrey05, textDisabled = PhotonColors.DarkGrey90A40, textWarning = PhotonColors.Red80, - textLink = PhotonColors.Violet70, - textAccent = PhotonColors.Violet90, + textAccent = PhotonColors.Violet70, textInverted = PhotonColors.White, iconPrimary = PhotonColors.DarkGrey90, iconSecondary = PhotonColors.DarkGrey05, @@ -168,7 +166,6 @@ class FirefoxColors( textSecondary: Color, textDisabled: Color, textWarning: Color, - textLink: Color, textAccent: Color, textInverted: Color, iconPrimary: Color, @@ -268,10 +265,7 @@ class FirefoxColors( // Warning text var textWarning by mutableStateOf(textWarning) private set - // Text link - var textLink by mutableStateOf(textLink) - private set - // Small heading + // Small heading, Text link var textAccent by mutableStateOf(textAccent) private set // Text Inverted/On Color @@ -359,7 +353,6 @@ class FirefoxColors( textSecondary = other.textSecondary textDisabled = other.textDisabled textWarning = other.textWarning - textLink = other.textLink textAccent = other.textAccent textInverted = other.textInverted iconPrimary = other.iconPrimary @@ -408,7 +401,6 @@ class FirefoxColors( textSecondary = textSecondary, textDisabled = textDisabled, textWarning = textWarning, - textLink = textLink, textAccent = textAccent, textInverted = textInverted, iconPrimary = iconPrimary, diff --git a/mobile/android/fenix/app/src/main/res/layout/recent_bookmarks_header.xml b/mobile/android/fenix/app/src/main/res/layout/recent_bookmarks_header.xml index 47acefde75f5..1f3c6c0bdb58 100644 --- a/mobile/android/fenix/app/src/main/res/layout/recent_bookmarks_header.xml +++ b/mobile/android/fenix/app/src/main/res/layout/recent_bookmarks_header.xml @@ -38,7 +38,7 @@ android:maxLines="1" android:nestedScrollingEnabled="false" android:text="@string/recently_saved_show_all" - android:textColor="@color/fx_mobile_text_color_action" + android:textColor="@color/fx_mobile_text_color_accent" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintBottom_toBottomOf="@id/header" /> diff --git a/mobile/android/fenix/app/src/main/res/layout/recent_tabs_header.xml b/mobile/android/fenix/app/src/main/res/layout/recent_tabs_header.xml index 64afb4ef0e00..02796a3e0af4 100644 --- a/mobile/android/fenix/app/src/main/res/layout/recent_tabs_header.xml +++ b/mobile/android/fenix/app/src/main/res/layout/recent_tabs_header.xml @@ -36,7 +36,7 @@ android:maxLines="1" android:nestedScrollingEnabled="false" android:text="@string/recent_tabs_show_all" - android:textColor="@color/fx_mobile_text_color_action" + android:textColor="@color/fx_mobile_text_color_accent" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintBottom_toBottomOf="@id/header" /> diff --git a/mobile/android/fenix/app/src/main/res/layout/recent_visits_header.xml b/mobile/android/fenix/app/src/main/res/layout/recent_visits_header.xml index 3debf583cc8b..bfb02ee534ba 100644 --- a/mobile/android/fenix/app/src/main/res/layout/recent_visits_header.xml +++ b/mobile/android/fenix/app/src/main/res/layout/recent_visits_header.xml @@ -37,7 +37,7 @@ android:maxLines="1" android:nestedScrollingEnabled="false" android:text="@string/recent_tabs_show_all" - android:textColor="@color/fx_mobile_text_color_action" + android:textColor="@color/fx_mobile_text_color_accent" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintBottom_toBottomOf="@id/header" /> diff --git a/mobile/android/fenix/app/src/main/res/values-night/colors.xml b/mobile/android/fenix/app/src/main/res/values-night/colors.xml index 9f2efa53b2e7..63245d376f96 100644 --- a/mobile/android/fenix/app/src/main/res/values-night/colors.xml +++ b/mobile/android/fenix/app/src/main/res/values-night/colors.xml @@ -55,10 +55,8 @@ @color/photonLightGrey05A40 @color/photonRed40 - - @color/photonViolet40 - - @color/photonViolet40 + + @color/photonViolet40 @color/photonWhite diff --git a/mobile/android/fenix/app/src/main/res/values/colors.xml b/mobile/android/fenix/app/src/main/res/values/colors.xml index ca7982ad6662..d975642241c7 100644 --- a/mobile/android/fenix/app/src/main/res/values/colors.xml +++ b/mobile/android/fenix/app/src/main/res/values/colors.xml @@ -55,10 +55,8 @@ @color/photonDarkGrey90A40 @color/photonRed80 - - @color/photonViolet70 - - @color/photonViolet90 + + @color/photonViolet70 @color/photonWhite diff --git a/mobile/android/fenix/app/src/main/res/values/styles.xml b/mobile/android/fenix/app/src/main/res/values/styles.xml index cc809c9db217..b36963b0176c 100644 --- a/mobile/android/fenix/app/src/main/res/values/styles.xml +++ b/mobile/android/fenix/app/src/main/res/values/styles.xml @@ -22,7 +22,7 @@ false false @style/BottomSheet - @color/fx_mobile_text_color_action + @color/fx_mobile_text_color_accent @color/destructive_normal_theme -- 2.11.4.GIT