PM-15037 Add missing title to empty sync import logins error dialog (#4443)

This commit is contained in:
Dave Severns authored and GitHub committed 2024-12-09 19:31:38 +00:00
1 parent 5997579330
commit 4932353003
3 files changed
+9 -5

No files matched your search

@@ -132,7 +132,8 @@ class ImportLoginsViewModel @Inject constructor(
it.copy(
isVaultSyncing = false,
dialogState = ImportLoginsState.DialogState.Error(
R.string.no_logins_were_imported.asText(),
message = R.string.no_logins_were_imported.asText(),
title = R.string.import_error.asText(),
),
)
}
@@ -259,9 +260,8 @@ data class ImportLoginsState(
*/
data class Error(
override val message: Text = R.string.generic_error_message.asText(),
) : DialogState() {
override val title: Text? = null
}
override val title: Text? = null,
) : DialogState()
}
/**
+1
View File
@@ -1074,6 +1074,7 @@ Do you want to switch to this account?</string>
<string name="bitwarden_tools">Bitwarden Tools</string>
<string name="got_it">Got it</string>
<string name="no_logins_were_imported">No logins were imported</string>
<string name="import_error">Import error</string>
<string name="verified_sso_domain_verified">Verified SSO Domain Endpoint</string>
<string name="logins_imported">Logins imported</string>
<string name="remember_to_delete_your_imported_password_file_from_your_computer">Remember to delete your imported password file from your computer</string>
@@ -419,7 +419,10 @@ class ImportLoginsViewModelTest : BaseViewModelTest() {
)
assertEquals(
ImportLoginsState(
dialogState = ImportLoginsState.DialogState.Error(R.string.no_logins_were_imported.asText()),
dialogState = ImportLoginsState.DialogState.Error(
message = R.string.no_logins_were_imported.asText(),
title = R.string.import_error.asText(),
),
viewState = ImportLoginsState.ViewState.InitialContent,
isVaultSyncing = false,
showBottomSheet = false,