-
-
Notifications
You must be signed in to change notification settings - Fork 749
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Add confirm dialogs when toggling dangerous settings #2072
base: compose-dev
Are you sure you want to change the base?
Conversation
app/src/main/java/app/revanced/manager/ui/component/settings/BooleanItem.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/app/revanced/manager/ui/component/settings/BooleanItem.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/app/revanced/manager/ui/component/settings/BooleanItem.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/app/revanced/manager/ui/component/SafeguardConfirmationDialog.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/app/revanced/manager/ui/component/settings/SafeguardBooleanItem.kt
Outdated
Show resolved
Hide resolved
…afeguardBooleanItem.kt Co-authored-by: Ax333l <main@axelen.xyz>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The UI code looks good to me
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔥 The dialog's title & description for safeguard must tell the user what the feature does and the consequences of enabling/disabling it.
- (consequences): https://m3.material.io/foundations/content-design/style-guide/ux-writing-best-practices#d7f04666-89f8-4795-a563-16d060b5ccf2
- (not really important that much, title): https://m3.material.io/components/dialogs/guidelines#0cff8b6b-d4f3-4442-8194-31212f5d1a12
Additionally, this isn't very clear to the user,
"Enforce selection of the suggested app version"
- Yes (Toggle the preference - which is on by default)
- No (Dismiss the dialog)
I assume you already knew that, so this is just a red flag check to tell maintainer to not accidentally merge.
Are there strings in flutter manager that could be used for this? |
We have these two in flutter {
"enablePatchesSelectionWarningText": "Changing the selection of patches may cause unexpected issues.\n\nEnable anyways?",
"requireSuggestedAppVersionDialogText": "Selecting an app that is not the suggested version may cause unexpected issues.\n\nDo you want to proceed anyways?"
} |
I guess those strings can be reused unless there is a better alternative |
Note: Strings need to be set