Flip name and key fields in manual entry screen (#46)

This commit is contained in:
Patrick Honkonen
2024-04-24 01:05:13 -04:00
committed by GitHub
parent 6b88bcf02f
commit 5167b2c491
2 changed files with 15 additions and 17 deletions

View File

@@ -130,6 +130,21 @@ fun ManualCodeEntryScreen(
modifier = Modifier.padding(horizontal = 16.dp),
)
Spacer(modifier = Modifier.height(8.dp))
BitwardenTextField(
label = stringResource(id = R.string.name),
value = state.accountName,
onValueChange = remember(viewModel) {
{
viewModel.trySendAction(
ManualCodeEntryAction.IssuerTextChange(it),
)
}
},
modifier = Modifier
.fillMaxWidth()
.padding(horizontal = 16.dp),
)
Spacer(modifier = Modifier.height(8.dp))
BitwardenTextField(
singleLine = false,
@@ -147,22 +162,6 @@ fun ManualCodeEntryScreen(
.padding(horizontal = 16.dp),
)
Spacer(modifier = Modifier.height(8.dp))
BitwardenTextField(
label = stringResource(id = R.string.account_name),
value = state.accountName,
onValueChange = remember(viewModel) {
{
viewModel.trySendAction(
ManualCodeEntryAction.IssuerTextChange(it),
)
}
},
modifier = Modifier
.fillMaxWidth()
.padding(horizontal = 16.dp),
)
Spacer(modifier = Modifier.height(16.dp))
BitwardenFilledTonalButton(
label = stringResource(id = R.string.add_totp),

View File

@@ -32,7 +32,6 @@
<string name="you_dont_have_items_to_display">You don\'t have any items to display.</string>
<string name="empty_item_list_instruction">Add a new code, sync an existing account, or import codes to secure your accounts.</string>
<string name="add_code">Add code</string>
<string name="account_name">Account Name</string>
<string name="authenticator_key_read_error">Cannot read authenticator key.</string>
<string name="authenticator_key_added">Authenticator key added.</string>
<string name="item_added">Item added</string>