Skip to content

Commit

Permalink
Update Settings: Address Ship Review comments (#5447)
Browse files Browse the repository at this point in the history
Task/Issue URL:
https://app.asana.com/0/1207908166761516/1209088011471676/f

### Description
- Updates feedback button theming to support system default theme
- Removes beta pill from Email Protection settings
- Updates cookie popup blocking icon and colors
- Adjusts spacing and icon sizes in settings menu
- Updates "Add Widget to Home Screen" text
- Fixes link color in cookie popup settings to use theme attribute

### Steps to test this PR


[Designs](https://www.figma.com/design/CjH849hL53lhsPlf6Ufeo4/%E2%9A%99%EF%B8%8F-Browser-Settings-Documentation-(All-Platforms)?node-id=7605-431390&t=q43oylMYVk670ayn-4)

_Theme Support_
- [ ] Verify feedback buttons show correct theme when using system
default
- [ ] Confirm feedback buttons display correctly in light theme
- [ ] Confirm feedback buttons display correctly in dark theme

_Settings Updates_
- [ ] Verify "Privacy Protections" header text is now "Protections"
- [ ] Verify Email Protection no longer shows beta pill
- [ ] Verify "Main Settings" header text is now "Other Settings"
- [ ] Check that "DuckDuckGo on Other Platforms" uses smaller trailing
icon
- [ ] Check that "DuckDuckGo on Other Platforms" uses correct color for
trailing icon
- [ ] Confirm widget text now reads "Add Widget to Home Screen"

_Cookie Popup Changes_
- [ ] Verify new cookie blocking icon displays correctly
- [ ] Confirm link colors use theme-appropriate blue
- [ ] Check spacing adjustments in cookie popup settings

### UI changes
| Before  | After |
| ------ | ----- |

![Screenshot_20250108_110358](https://github.com/user-attachments/assets/6d63e62d-62bd-4e46-9b4d-1a17383fa677)|![Screenshot_20250108_110601](https://github.com/user-attachments/assets/e3a92089-f7af-45ca-852c-dac7d0dbc2a0)|

![Screenshot_20250108_110348](https://github.com/user-attachments/assets/9741fa94-6d5b-4cd7-88b0-cf58f0a2fdaa)|![Screenshot_20250108_105021](https://github.com/user-attachments/assets/0c706296-e142-4d69-a2a4-bfac17767644)|

![Screenshot_20250108_110253](https://github.com/user-attachments/assets/82a030c4-cb16-4a65-90b6-edd2d833aaa4)|![Screenshot_20250108_105914](https://github.com/user-attachments/assets/33402758-248b-46f4-90f3-021c91822c96)|

![Screenshot_20250108_110338](https://github.com/user-attachments/assets/fe542bf8-1af1-422e-9a4e-58602720f3fe)|![Screenshot_20250108_105010](https://github.com/user-attachments/assets/8e47c266-b8ae-4f2e-9677-8530ffd8b3ee)|

![Screenshot_20250108_110327](https://github.com/user-attachments/assets/2cc06b3b-c325-412e-aeaf-69ff17465049)|![Screenshot_20250108_163608](https://github.com/user-attachments/assets/bb3b399e-a4a5-4c31-a876-a618ff022163)|

![Screenshot_20250108_163349](https://github.com/user-attachments/assets/3e0870c2-9f80-4389-ad87-becc3dbd19b6)|![Screenshot_20250108_163222](https://github.com/user-attachments/assets/e21e18e0-baa7-4215-9abc-0300403d0254)|

![Screenshot_20250108_163349](https://github.com/user-attachments/assets/3e0870c2-9f80-4389-ad87-becc3dbd19b6)|![Screenshot_20250110_103121](https://github.com/user-attachments/assets/057e3c3c-9474-42d7-b50a-d6f796936a89)|

---------

Co-authored-by: Dax The Translator <[email protected]>
  • Loading branch information
mikescamell and daxmobile authored Jan 15, 2025
1 parent f1ba7d5 commit 27a830d
Show file tree
Hide file tree
Showing 44 changed files with 266 additions and 187 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,17 @@

package com.duckduckgo.app.feedback.ui.initial

import android.app.UiModeManager
import android.os.Bundle
import androidx.core.content.ContextCompat.getSystemService
import com.duckduckgo.anvil.annotations.InjectWith
import com.duckduckgo.app.browser.R
import com.duckduckgo.app.browser.databinding.ContentFeedbackBinding
import com.duckduckgo.app.feedback.ui.common.FeedbackFragment
import com.duckduckgo.app.feedback.ui.initial.InitialFeedbackFragmentViewModel.Command.*
import com.duckduckgo.common.ui.DuckDuckGoTheme
import com.duckduckgo.common.ui.DuckDuckGoTheme.DARK
import com.duckduckgo.common.ui.DuckDuckGoTheme.LIGHT
import com.duckduckgo.common.ui.DuckDuckGoTheme.SYSTEM_DEFAULT
import com.duckduckgo.common.ui.store.ThemingDataStore
import com.duckduckgo.common.ui.viewbinding.viewBinding
import com.duckduckgo.di.scopes.FragmentScope
Expand Down Expand Up @@ -50,15 +54,29 @@ class InitialFeedbackFragment : FeedbackFragment(R.layout.content_feedback) {
override fun onActivityCreated(savedInstanceState: Bundle?) {
super.onActivityCreated(savedInstanceState)

if (themingDataStore.theme == DuckDuckGoTheme.LIGHT) {
binding.positiveFeedbackButton.setImageResource(R.drawable.button_happy_light_theme)
binding.negativeFeedbackButton.setImageResource(R.drawable.button_sad_light_theme)
} else {
binding.positiveFeedbackButton.setImageResource(R.drawable.button_happy_dark_theme)
binding.negativeFeedbackButton.setImageResource(R.drawable.button_sad_dark_theme)
when (themingDataStore.theme) {
SYSTEM_DEFAULT -> {
val uiManager = getSystemService(requireContext(), UiModeManager::class.java)
when (uiManager?.nightMode) {
UiModeManager.MODE_NIGHT_YES -> renderDarkButtons()
else -> renderLightButtons()
}
}
DARK -> renderDarkButtons()
LIGHT -> renderLightButtons()
}
}

private fun renderLightButtons() {
binding.positiveFeedbackButton.setImageResource(R.drawable.button_happy_light_theme)
binding.negativeFeedbackButton.setImageResource(R.drawable.button_sad_light_theme)
}

private fun renderDarkButtons() {
binding.positiveFeedbackButton.setImageResource(R.drawable.button_happy_dark_theme)
binding.negativeFeedbackButton.setImageResource(R.drawable.button_sad_dark_theme)
}

override fun configureViewModelObservers() {
viewModel.command.observe(this) {
when (it) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ import com.duckduckgo.autofill.api.AutofillScreens.AutofillSettingsScreen
import com.duckduckgo.autofill.api.AutofillSettingsLaunchSource
import com.duckduckgo.common.ui.DuckDuckGoActivity
import com.duckduckgo.common.ui.view.gone
import com.duckduckgo.common.ui.view.listitem.DaxListItem.IconSize.Small
import com.duckduckgo.common.ui.view.listitem.TwoLineListItem
import com.duckduckgo.common.ui.view.show
import com.duckduckgo.common.ui.viewbinding.viewBinding
Expand Down Expand Up @@ -201,6 +202,7 @@ class NewSettingsActivity : DuckDuckGoActivity() {
with(viewsOther) {
aboutSetting.setOnClickListener { viewModel.onAboutSettingClicked() }
shareFeedbackSetting.setOnClickListener { viewModel.onShareFeedbackClicked() }
ddgOnOtherPlatformsSetting.setTrailingIconSize(Small)
ddgOnOtherPlatformsSetting.setOnClickListener { viewModel.onDdgOnOtherPlatformsClicked() }
}
}
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/res/layout/activity_private_search.xml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginHorizontal="@dimen/keyline_5"
android:layout_marginTop="@dimen/keyline_4"
android:layout_marginTop="@dimen/keyline_2"
android:gravity="center"
android:text="@string/privateSearchActivityTitle"
android:visibility="gone"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
android:layout_marginTop="@dimen/keyline_4"
android:layout_marginEnd="@dimen/keyline_4"
android:gravity="center"
android:text="@string/webTrackingProtectionTitle"
android:text="@string/webTrackingProtectionIsEnabledTitle"
app:typography="h2"
tools:visibility="gone" />

Expand Down
3 changes: 2 additions & 1 deletion app/src/main/res/layout/content_settings_new_other.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
android:layout_height="wrap_content"
app:leadingIcon="@drawable/ic_downloads_color_24"
app:primaryText="@string/settingsDDGOnOtherPlatforms"
app:trailingIcon="@drawable/ic_open_in_24" />
app:trailingIcon="@drawable/ic_open_in_16"
app:trailingIconTint="?attr/daxColorSecondaryIcon"/>

</LinearLayout>
5 changes: 2 additions & 3 deletions app/src/main/res/layout/content_settings_new_privacy.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
android:id="@+id/settingsPrivacyTitle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:primaryText="@string/settingsHeadingPrivacyProtections" />
app:primaryText="@string/settingsHeadingProtections" />

<com.duckduckgo.common.ui.view.listitem.SettingsListItem
android:id="@+id/setAsDefaultBrowserSetting"
Expand Down Expand Up @@ -69,7 +69,6 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:leadingIcon="@drawable/ic_email_protection_color_24"
app:primaryText="@string/settingsEmailProtectionTitle"
app:showBetaPill="true" />
app:primaryText="@string/settingsEmailProtectionTitle" />

</LinearLayout>
9 changes: 5 additions & 4 deletions app/src/main/res/values-bg/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@
<string name="settingsActivityTitle">Настройки</string>
<string name="settingsMenuItemTitle">Настройки</string>
<string name="settingsHeadingPrivacy">Поверителност</string>
<string name="settingsHeadingPrivacyProtections">Защита на поверителността</string>
<string name="settingsHeadingProtections">Защити</string>
<string name="settingsHeadingAppearance">Външен вид</string>
<string name="settingsHeadingCustomize">Персонализиране</string>
<string name="settingsHeadingAbout">За нас</string>
Expand Down Expand Up @@ -158,14 +158,14 @@
<string name="settingsWebTrackingProtectionTitle">Защита от проследяване в мрежата</string>
<string name="settingsWebTrackingProtectionDescription">Активирано по подразбиране</string>
<string name="settingsHeadingSettings">Настройки</string>
<string name="settingsHeadingMainSettings">Основни настройки</string>
<string name="settingsHeadingMainSettings">Други Настройки</string>
<string name="settingsPermissionsSetting">Разрешения</string>
<string name="settingsSyncSetting">Синхронизиране и архивиране</string>
<string name="settingsFireButton">Fire Button</string>
<string name="settingsDataClearing">Изчистване на данни</string>
<string name="settingsAddWidget">Добавяне на приспособлението към началния екран</string>
<string name="settingsAddressBarPosition">Задайте позицията на адресната лента</string>
<string name="settingsEnableVoiceSearch">Активиране на гласово търсене</string>
<string name="settingsEnableVoiceSearch">Активиране на поверително гласово търсене</string>
<string name="settingsDDGOnOtherPlatforms">DuckDuckGo на други платформи</string>

<!-- Private Search -->
Expand All @@ -190,7 +190,8 @@
<!-- Web Tracking Protection -->
<string name="webTrackingProtectionActivityTitle">Защита от проследяване в мрежата</string>
<string name="webTrackingProtectionLearnMoreTitle">Защита от проследяване в мрежата</string>
<string name="webTrackingProtectionTitle">Защитата от проследяване в мрежата е активирана</string>
<string name="webTrackingProtectionIsEnabledTitle">Защитата от проследяване в мрежата е активирана</string>
<string name="webTrackingProtectionTitle">Защита от проследяване в мрежата</string>
<string name="webTrackingProtectionDescription"><![CDATA[DuckDuckGo никога не Ви проследява и се стремим да защитим Вашата поверителност във възможно най-голяма степен. Непрекъснато поддържаме и развиваме слоеве на защита, за да сме в крак с новите методи за проследяване и да осигуряваме много защити, които другите браузъри не предлагат по подразбиране. <u><a href=\"\">Научете повече</a><u/>]]></string>
<string name="webTrackingProtectionDescriptionNew"><![CDATA[DuckDuckGo автоматично блокира скритите тракери, докато сърфирате в мрежата.\n<a href=\"\">Научете повече</a>]]></string>

Expand Down
9 changes: 5 additions & 4 deletions app/src/main/res/values-cs/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@
<string name="settingsActivityTitle">Nastavení</string>
<string name="settingsMenuItemTitle">Nastavení</string>
<string name="settingsHeadingPrivacy">Soukromí</string>
<string name="settingsHeadingPrivacyProtections">Ochrana osobních údajů</string>
<string name="settingsHeadingProtections">Ochrany</string>
<string name="settingsHeadingAppearance">Vzhled</string>
<string name="settingsHeadingCustomize">Přizpůsobit</string>
<string name="settingsHeadingAbout">Informace</string>
Expand Down Expand Up @@ -158,14 +158,14 @@
<string name="settingsWebTrackingProtectionTitle">Ochrana před sledováním na webu</string>
<string name="settingsWebTrackingProtectionDescription">Ve výchozím nastavení povoleno</string>
<string name="settingsHeadingSettings">Nastavení</string>
<string name="settingsHeadingMainSettings">Hlavní nastavení</string>
<string name="settingsHeadingMainSettings">Další nastavení</string>
<string name="settingsPermissionsSetting">Oprávnění</string>
<string name="settingsSyncSetting">Synchronizace a zálohování</string>
<string name="settingsFireButton">Fire Button</string>
<string name="settingsDataClearing">Vymazání dat</string>
<string name="settingsAddWidget">Přidat widget na domovskou obrazovku</string>
<string name="settingsAddressBarPosition">Nastavte pozici adresního řádku</string>
<string name="settingsEnableVoiceSearch">Povolit hlasové vyhledávání</string>
<string name="settingsEnableVoiceSearch">Povolit soukromé hlasové vyhledávání</string>
<string name="settingsDDGOnOtherPlatforms">DuckDuckGo na jiných platformách</string>

<!-- Private Search -->
Expand All @@ -190,7 +190,8 @@
<!-- Web Tracking Protection -->
<string name="webTrackingProtectionActivityTitle">Ochrana před sledováním na webu</string>
<string name="webTrackingProtectionLearnMoreTitle">Ochrana před sledováním na webu</string>
<string name="webTrackingProtectionTitle">Ochrana před sledováním na webu je povolená</string>
<string name="webTrackingProtectionIsEnabledTitle">Ochrana před sledováním na webu je povolená</string>
<string name="webTrackingProtectionTitle">Ochrana před sledováním na webu</string>
<string name="webTrackingProtectionDescription"><![CDATA[DuckDuckGo tě nikdy nesleduje a snaží se co nejvíc chránit tvoje soukromí. Neustále vylepšujeme a vyvíjíme další vrstvy ochrany, abychom drželi krok s novými metodami sledování a poskytovali co nejkomplexnější ochranu. Něco takového jiné prohlížeče ve výchozím nastavení nenabízejí. <u><a href=\"\">Další informace</a><u/>]]></string>
<string name="webTrackingProtectionDescriptionNew"><![CDATA[DuckDuckGo automaticky blokuje skryté trackery při procházení webu.\n<a href=\"\">Další informace</a>]]></string>

Expand Down
9 changes: 5 additions & 4 deletions app/src/main/res/values-da/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@
<string name="settingsActivityTitle">Indstillinger</string>
<string name="settingsMenuItemTitle">Indstillinger</string>
<string name="settingsHeadingPrivacy">Privatliv</string>
<string name="settingsHeadingPrivacyProtections">Beskyttelse af privatlivet</string>
<string name="settingsHeadingProtections">Beskyttelser</string>
<string name="settingsHeadingAppearance">udseende</string>
<string name="settingsHeadingCustomize">Tilpas</string>
<string name="settingsHeadingAbout">Omkring</string>
Expand Down Expand Up @@ -158,14 +158,14 @@
<string name="settingsWebTrackingProtectionTitle">Beskyttelse mod sporing på nettet</string>
<string name="settingsWebTrackingProtectionDescription">Aktiveret som standard</string>
<string name="settingsHeadingSettings">Indstillinger</string>
<string name="settingsHeadingMainSettings">Generelle indstillinger</string>
<string name="settingsHeadingMainSettings">Andre indstillinger</string>
<string name="settingsPermissionsSetting">Tilladelser</string>
<string name="settingsSyncSetting">Synkronisering og sikkerhedskopiering</string>
<string name="settingsFireButton">Fire Button</string>
<string name="settingsDataClearing">Datarydning</string>
<string name="settingsAddWidget">Tilføj widget til startskærmen</string>
<string name="settingsAddressBarPosition">Angiv placeringen af adresselinjen</string>
<string name="settingsEnableVoiceSearch">Aktivér stemmesøgning</string>
<string name="settingsEnableVoiceSearch">Aktiver privat stemmesøgning</string>
<string name="settingsDDGOnOtherPlatforms">DuckDuckGo på andre platforme</string>

<!-- Private Search -->
Expand All @@ -190,7 +190,8 @@
<!-- Web Tracking Protection -->
<string name="webTrackingProtectionActivityTitle">Beskyttelse mod sporing på nettet</string>
<string name="webTrackingProtectionLearnMoreTitle">Beskyttelse mod sporing på nettet</string>
<string name="webTrackingProtectionTitle">Beskyttelse mod sporing på nettet er aktiveret</string>
<string name="webTrackingProtectionIsEnabledTitle">Beskyttelse mod sporing på nettet er aktiveret</string>
<string name="webTrackingProtectionTitle">Beskyttelse mod sporing på nettet</string>
<string name="webTrackingProtectionDescription"><![CDATA[DuckDuckGo sporer dig aldrig, og vi bestræber os på at beskytte dit privatliv så meget som muligt. Vi vedligeholder og udvikler løbende beskyttelseslagene for at holde trit med nye sporingsmetoder og beskytter mod mange ting, som andre browsere ikke tilbyder som standard. <u><a href=\"\">Lær mere</a><u/>]]></string>
<string name="webTrackingProtectionDescriptionNew"><![CDATA[DuckDuckGo blokerer automatisk skjulte trackere, når du surfer på nettet.\n<a href=\"\">Mere info</a>]]></string>

Expand Down
9 changes: 5 additions & 4 deletions app/src/main/res/values-de/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@
<string name="settingsActivityTitle">Einstellungen</string>
<string name="settingsMenuItemTitle">Einstellungen</string>
<string name="settingsHeadingPrivacy">Privatsphäre</string>
<string name="settingsHeadingPrivacyProtections">Datenschutz</string>
<string name="settingsHeadingProtections">Schutz</string>
<string name="settingsHeadingAppearance">Aussehen</string>
<string name="settingsHeadingCustomize">Anpassen</string>
<string name="settingsHeadingAbout">Über</string>
Expand Down Expand Up @@ -158,14 +158,14 @@
<string name="settingsWebTrackingProtectionTitle">Web Tracking Protection</string>
<string name="settingsWebTrackingProtectionDescription">Standardmäßig aktiviert</string>
<string name="settingsHeadingSettings">Einstellungen</string>
<string name="settingsHeadingMainSettings">Haupteinstellungen</string>
<string name="settingsHeadingMainSettings">Andere Einstellungen</string>
<string name="settingsPermissionsSetting">Berechtigungen</string>
<string name="settingsSyncSetting">Synchronisieren und sichern</string>
<string name="settingsFireButton">Fire Button</string>
<string name="settingsDataClearing">Datenlöschung</string>
<string name="settingsAddWidget">Widget zum Startbildschirm hinzufügen</string>
<string name="settingsAddressBarPosition">Position deiner Adressleiste festlegen</string>
<string name="settingsEnableVoiceSearch">Sprachsuche aktivieren</string>
<string name="settingsEnableVoiceSearch">Private Sprachsuche aktivieren</string>
<string name="settingsDDGOnOtherPlatforms">DuckDuckGo auf anderen Plattformen</string>

<!-- Private Search -->
Expand All @@ -190,7 +190,8 @@
<!-- Web Tracking Protection -->
<string name="webTrackingProtectionActivityTitle">Web Tracking Protection</string>
<string name="webTrackingProtectionLearnMoreTitle">Web Tracking Protection</string>
<string name="webTrackingProtectionTitle">Web Tracking Protection ist aktiviert</string>
<string name="webTrackingProtectionIsEnabledTitle">Web Tracking Protection ist aktiviert</string>
<string name="webTrackingProtectionTitle">Web Tracking Protection</string>
<string name="webTrackingProtectionDescription"><![CDATA[DuckDuckGo trackt dich niemals und wir versuchen, deine Privatsphäre so weit wie möglich zu schützen. Wir pflegen und entwickeln kontinuierlich Schutzmechanismen, um mit neuen Tracking-Methoden Schritt zu halten und viele Schutzfunktionen bereitzustellen, die andere Browser standardmäßig nicht bieten. <u><a href=\"\">Mehr erfahren</a><u/>]]></string>
<string name="webTrackingProtectionDescriptionNew"><![CDATA[DuckDuckGo blockiert automatisch versteckte Tracker, während du browst.\n<a href=\"\">Mehr erfahren</a>]]></string>

Expand Down
Loading

0 comments on commit 27a830d

Please sign in to comment.