mirror of
https://github.com/bitwarden/android.git
synced 2026-06-07 23:58:03 -05:00
Remove scaffolding for identity autofill (#563)
This commit is contained in:
committed by
Álison Fernandes
parent
9c023bca9e
commit
75a08e72a6
@@ -16,13 +16,6 @@ sealed class AutofillPartition {
|
||||
override val views: List<AutofillView.Card>,
|
||||
) : AutofillPartition()
|
||||
|
||||
/**
|
||||
* The identity [AutofillPartition] data.
|
||||
*/
|
||||
data class Identity(
|
||||
override val views: List<AutofillView.Identity>,
|
||||
) : AutofillPartition()
|
||||
|
||||
/**
|
||||
* The login [AutofillPartition] data.
|
||||
*/
|
||||
|
||||
@@ -54,44 +54,6 @@ sealed class AutofillView {
|
||||
) : Card()
|
||||
}
|
||||
|
||||
/**
|
||||
* A view that corresponds to the personal info data partition for autofill fields.
|
||||
*/
|
||||
sealed class Identity : AutofillView() {
|
||||
|
||||
/**
|
||||
* The name [AutofillView] for the [Identity] data partition.
|
||||
*/
|
||||
data class Name(
|
||||
override val autofillId: AutofillId,
|
||||
override val isFocused: Boolean,
|
||||
) : Identity()
|
||||
|
||||
/**
|
||||
* The phone number [AutofillView] for the [Identity] data partition.
|
||||
*/
|
||||
data class PhoneNumber(
|
||||
override val autofillId: AutofillId,
|
||||
override val isFocused: Boolean,
|
||||
) : Identity()
|
||||
|
||||
/**
|
||||
* The postal address [AutofillView] for the [Identity] data partition.
|
||||
*/
|
||||
data class PostalAddress(
|
||||
override val autofillId: AutofillId,
|
||||
override val isFocused: Boolean,
|
||||
) : Identity()
|
||||
|
||||
/**
|
||||
* The postal code [AutofillView] for the [Identity] data partition.
|
||||
*/
|
||||
data class PostalCode(
|
||||
override val autofillId: AutofillId,
|
||||
override val isFocused: Boolean,
|
||||
) : Identity()
|
||||
}
|
||||
|
||||
/**
|
||||
* A view that corresponds to the login data partition for autofill fields.
|
||||
*/
|
||||
|
||||
@@ -33,12 +33,6 @@ class AutofillParserImpl : AutofillParser {
|
||||
)
|
||||
}
|
||||
|
||||
is AutofillView.Identity -> {
|
||||
AutofillPartition.Identity(
|
||||
views = autofillViews.filterIsInstance<AutofillView.Identity>(),
|
||||
)
|
||||
}
|
||||
|
||||
is AutofillView.Login -> {
|
||||
AutofillPartition.Login(
|
||||
views = autofillViews.filterIsInstance<AutofillView.Login>(),
|
||||
|
||||
@@ -68,13 +68,6 @@ private fun buildAutofillView(
|
||||
)
|
||||
}
|
||||
|
||||
View.AUTOFILL_HINT_NAME -> {
|
||||
AutofillView.Identity.Name(
|
||||
autofillId = autofillId,
|
||||
isFocused = isFocused,
|
||||
)
|
||||
}
|
||||
|
||||
View.AUTOFILL_HINT_PASSWORD -> {
|
||||
AutofillView.Login.Password(
|
||||
autofillId = autofillId,
|
||||
@@ -82,27 +75,6 @@ private fun buildAutofillView(
|
||||
)
|
||||
}
|
||||
|
||||
View.AUTOFILL_HINT_PHONE -> {
|
||||
AutofillView.Identity.PhoneNumber(
|
||||
autofillId = autofillId,
|
||||
isFocused = isFocused,
|
||||
)
|
||||
}
|
||||
|
||||
View.AUTOFILL_HINT_POSTAL_ADDRESS -> {
|
||||
AutofillView.Identity.PostalAddress(
|
||||
autofillId = autofillId,
|
||||
isFocused = isFocused,
|
||||
)
|
||||
}
|
||||
|
||||
View.AUTOFILL_HINT_POSTAL_CODE -> {
|
||||
AutofillView.Identity.PostalCode(
|
||||
autofillId = autofillId,
|
||||
isFocused = isFocused,
|
||||
)
|
||||
}
|
||||
|
||||
View.AUTOFILL_HINT_USERNAME -> {
|
||||
AutofillView.Login.Username(
|
||||
autofillId = autofillId,
|
||||
@@ -122,10 +94,6 @@ private val SUPPORTED_HINTS: List<String> = listOf(
|
||||
View.AUTOFILL_HINT_CREDIT_CARD_NUMBER,
|
||||
View.AUTOFILL_HINT_CREDIT_CARD_SECURITY_CODE,
|
||||
View.AUTOFILL_HINT_EMAIL_ADDRESS,
|
||||
View.AUTOFILL_HINT_NAME,
|
||||
View.AUTOFILL_HINT_PASSWORD,
|
||||
View.AUTOFILL_HINT_PHONE,
|
||||
View.AUTOFILL_HINT_POSTAL_ADDRESS,
|
||||
View.AUTOFILL_HINT_POSTAL_CODE,
|
||||
View.AUTOFILL_HINT_USERNAME,
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user