From 02d8d14edeb7a9f3c2def3ab445b5ea3d16148b4 Mon Sep 17 00:00:00 2001 From: dankito Date: Tue, 15 Oct 2024 01:39:40 +0200 Subject: [PATCH] Showing action in bold --- .../banking/ui/dialogs/EnterTanDialogPreview.kt | 6 +++--- .../net/codinux/banking/ui/dialogs/EnterTanDialog.kt | 10 +++++----- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/composeApp/src/androidMain/kotlin/net/codinux/banking/ui/dialogs/EnterTanDialogPreview.kt b/composeApp/src/androidMain/kotlin/net/codinux/banking/ui/dialogs/EnterTanDialogPreview.kt index cb8db20..9be7140 100644 --- a/composeApp/src/androidMain/kotlin/net/codinux/banking/ui/dialogs/EnterTanDialogPreview.kt +++ b/composeApp/src/androidMain/kotlin/net/codinux/banking/ui/dialogs/EnterTanDialogPreview.kt @@ -29,7 +29,7 @@ fun EnterTanDialogPreview_TanImage() { val bank = BankViewInfo("10010010", "Ihr krasser Login Name", "Phantasie Bank", BankingGroup.Comdirect) - val tanChallenge = TanChallenge(TanChallengeType.Image, ActionRequiringTan.GetAccountInfo, "Geben Sie die TAN ein", tanMethod.identifier, listOf(tanMethod), null, emptyList(), tanImage, null, bank) + val tanChallenge = TanChallenge(TanChallengeType.Image, ActionRequiringTan.TransferMoney, "Geben Sie die TAN ein", tanMethod.identifier, listOf(tanMethod), null, emptyList(), tanImage, null, bank) EnterTanDialog(TanChallengeReceived(tanChallenge) { }) { } } @@ -76,7 +76,7 @@ fun EnterTanDialogPreview_WithMultipleTanMedia() { // shows that dialog is reall fun EnterTanDialogPreview_Flickercode() { val tanMethods = listOf(TanMethod("chipTAN Flickercode", TanMethodType.ChipTanFlickercode, "902")) val bank = BankViewInfo("12345678", "SupiDupiNutzer", "Abzockbank", BankingGroup.Postbank) - val tanChallenge = TanChallenge(TanChallengeType.Flickercode, ActionRequiringTan.GetAccountInfo, "Geben Sie die TAN ein", tanMethods.first().identifier, tanMethods, bank = bank, flickerCode = FlickerCode("100880077104", "0604800771040F")) + val tanChallenge = TanChallenge(TanChallengeType.Flickercode, ActionRequiringTan.GetTanMedia, "Geben Sie die TAN ein", tanMethods.first().identifier, tanMethods, bank = bank, flickerCode = FlickerCode("100880077104", "0604800771040F")) EnterTanDialog(TanChallengeReceived(tanChallenge) { }) { } } @@ -86,7 +86,7 @@ fun EnterTanDialogPreview_Flickercode() { fun EnterTanDialogPreview_Flickercode_DecodingError() { val tanMethods = listOf(TanMethod("chipTAN Flickercode", TanMethodType.ChipTanFlickercode, "902")) val bank = BankViewInfo("12345678", "SupiDupiNutzer", "Abzockbank", BankingGroup.Postbank) - val tanChallenge = TanChallenge(TanChallengeType.Flickercode, ActionRequiringTan.GetAccountInfo, "Geben Sie die TAN ein", tanMethods.first().identifier, tanMethods, bank = bank, flickerCode = FlickerCode("100880077104", null, decodingError = "Ja Hoppla, da ist dann wohl etwas schief gelaufen.")) + val tanChallenge = TanChallenge(TanChallengeType.Flickercode, ActionRequiringTan.ChangeTanMedium, "Geben Sie die TAN ein", tanMethods.first().identifier, tanMethods, bank = bank, flickerCode = FlickerCode("100880077104", null, decodingError = "Ja Hoppla, da ist dann wohl etwas schief gelaufen.")) EnterTanDialog(TanChallengeReceived(tanChallenge) { }) { } } \ No newline at end of file diff --git a/composeApp/src/commonMain/kotlin/net/codinux/banking/ui/dialogs/EnterTanDialog.kt b/composeApp/src/commonMain/kotlin/net/codinux/banking/ui/dialogs/EnterTanDialog.kt index c1b1f55..c4522c9 100644 --- a/composeApp/src/commonMain/kotlin/net/codinux/banking/ui/dialogs/EnterTanDialog.kt +++ b/composeApp/src/commonMain/kotlin/net/codinux/banking/ui/dialogs/EnterTanDialog.kt @@ -9,8 +9,8 @@ import androidx.compose.ui.Alignment import androidx.compose.ui.Modifier import androidx.compose.ui.focus.FocusRequester import androidx.compose.ui.focus.focusRequester -import androidx.compose.ui.graphics.Color import androidx.compose.ui.layout.ContentScale +import androidx.compose.ui.text.font.FontWeight import androidx.compose.ui.text.input.KeyboardType import androidx.compose.ui.unit.dp import kotlinx.datetime.TimeZone @@ -100,10 +100,10 @@ fun EnterTanDialog(tanChallengeReceived: TanChallengeReceived, onDismiss: () -> Text("${challenge.bank.bankName}, Nutzer ${challenge.bank.loginName}${challenge.account?.let { ", Konto ${it.productName ?: it.identifier}" } ?: ""}") } - Text( - "TAN benötigt ${Internationalization.getTextForActionRequiringTan(challenge.forAction)}", - Modifier.padding(top = 6.dp) - ) + Row(Modifier.padding(top = 6.dp), verticalAlignment = Alignment.CenterVertically) { + Text("TAN benötigt ") + Text(Internationalization.getTextForActionRequiringTan(challenge.forAction), fontWeight = FontWeight.Bold) + } }