taler-android

Android apps for GNU Taler (wallet, PoS, cashier)
Log | Files | Refs | README | LICENSE

commit 5e3372158e92f4d4b46b06b40fd9a4e2c1118201
parent 29c72ecc95276a9ed4fc564fe224a05a04b717ea
Author: Iván Ávalos <avalos@disroot.org>
Date:   Fri,  5 Dec 2025 17:49:14 +0100

[wallet] render zero amounts as neutral

Diffstat:
Mwallet/src/main/java/net/taler/wallet/transactions/TransactionsComposable.kt | 4+++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/wallet/src/main/java/net/taler/wallet/transactions/TransactionsComposable.kt b/wallet/src/main/java/net/taler/wallet/transactions/TransactionsComposable.kt @@ -421,7 +421,9 @@ fun TransactionAmountInfo( Column(horizontalAlignment = Alignment.End) { ProvideTextStyle(MaterialTheme.typography.titleLarge) { val amountStr = tx.amountEffective.withSpec(spec).toString(showSymbol = false) - when (tx.amountType) { + if (tx.amountEffective.isZero()) { + Text(amountStr) + } else when (tx.amountType) { Positive -> Text( stringResource(R.string.amount_positive, amountStr), color = if (tx.txState.major == Pending || tx.txState.major == Dialog)