-
Notifications
You must be signed in to change notification settings - Fork 1k
Don't show preimport dialog when launching from password import promo #6278
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
Don't show preimport dialog when launching from password import promo #6278
Conversation
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.
Pull Request Overview
Implements a flag to skip the introductory import prompt when launching from a promo, and updates the dialog, its ViewModel, call sites, and tests to support a “determining first view” state.
- Introduce
showInitialInstructionalPrompt
parameter inImportFromGooglePasswordsDialog
and pass it through ViewModel commands - Add
DeterminingFirstView
andFlowTerminated
states, update UI logic, and adjust existing tests while adding new ones for initial view - Migrate all call sites to use the new
LaunchImportGooglePasswords(showImportInstructions: Boolean)
command
Reviewed Changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
ImportFromGooglePasswordsDialogViewModel.kt | Default viewMode to DeterminingFirstView , add shouldShowInitialInstructionalPrompt and FlowTerminated logic |
ImportFromGooglePasswordsDialog.kt | Add showInitialInstructionalPrompt argument, handle DeterminingFirstView /FlowTerminated , move pixel tracking, adjust dialog lifecycle |
AutofillSettingsActivity.kt & ListMode classes | Update call sites to pass showInitialInstructionalPrompt into dialog instance |
AutofillPasswordsManagementViewModel.kt | Rename command, emit LaunchImportGooglePasswords(showImportInstructions) instead of old command |
Test files | Update imports and assertions for new command, add tests for initial view behavior |
Comments suppressed due to low confidence (1)
autofill/autofill-impl/src/test/java/com/duckduckgo/autofill/impl/ui/credential/management/importpassword/google/ImportFromGooglePasswordsDialogViewModelTest.kt:115
- Add a test verifying that calling
onImportFlowCancelledByUser(stage, canShowPreImportDialog = false)
transitions the view state toFlowTerminated
so that this branch is covered.
@Test
...ofill/impl/ui/credential/management/importpassword/google/ImportFromGooglePasswordsDialog.kt
Show resolved
Hide resolved
...ofill/impl/ui/credential/management/importpassword/google/ImportFromGooglePasswordsDialog.kt
Outdated
Show resolved
Hide resolved
daa0ec7
to
3763867
Compare
3763867
to
2f66be7
Compare
4a20d39
to
6328d9a
Compare
6328d9a
to
f7556c0
Compare
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.
LGTM
I pushed a change into the previous PR and I see conflicts here now. I assume restacking them should solve it.
2f66be7
to
ee5d7b2
Compare
ee5d7b2
to
839a426
Compare
f7556c0
to
1347464
Compare
1347464
to
92e9ebd
Compare
839a426
to
ebc6508
Compare
ebc6508
to
40c2bee
Compare
92e9ebd
to
75b8e66
Compare
Merge activity
|
40c2bee
to
6b9d462
Compare
Task/Issue URL: https://app.asana.com/1/137249556945/project/488551667048375/task/1210614808079934?focus=true
Description
Skips showing the "preimport" dialog for Google Import Passwords flow if launched from the import promo.
For context, this is the preimport dialog
Steps to test this PR
Open Google Passwords
button to import passwordsOpen Google Passwords
button again to import passwordsImport Passwords From Google
button