diff --git a/examples/folio/composeApp/src/commonMain/kotlin/app/folio/feature/ledger/LedgerScreen.kt b/examples/folio/composeApp/src/commonMain/kotlin/app/folio/feature/ledger/LedgerScreen.kt index 6412e21..f7f60df 100644 --- a/examples/folio/composeApp/src/commonMain/kotlin/app/folio/feature/ledger/LedgerScreen.kt +++ b/examples/folio/composeApp/src/commonMain/kotlin/app/folio/feature/ledger/LedgerScreen.kt @@ -75,7 +75,7 @@ fun LedgerScreen(accountId: String) { val balance = balanceOf(txns) Screen( - modifier = Modifier.testTag("LedgerScreen").semantics { contentDescription = "LedgerScreen" }, + modifier = Modifier.testTag("LedgerScreen").semantics { contentDescription = "LedgerScreen:$accountId" }, header = { Header( title = account.name, @@ -92,11 +92,14 @@ fun LedgerScreen(accountId: String) { ) }, ) { - Box(Modifier.size(1.dp).semantics { contentDescription = "active_account:$accountId" }) - Box(Modifier.size(1.dp).semantics { contentDescription = "ledger_balance:$balance" }) Card { Text("BALANCE", style = Type.label, color = t.textMuted) - Text(formatCents(balance), style = Type.balance, color = t.text) + Text( + formatCents(balance), + style = Type.balance, + color = t.text, + modifier = Modifier.semantics { contentDescription = "ledger_balance_display" }, + ) } Text( "ACTIVITY", @@ -138,7 +141,7 @@ private fun TxnRow(id: String, type: TxnType, amount: Long, note: String, date: modifier = Modifier .fillMaxWidth() .padding(vertical = 14.dp) - .semantics(mergeDescendants = true) { contentDescription = "ledger_row:$id:$signed" }, + .semantics { contentDescription = "ledger_row:$id" }, verticalAlignment = Alignment.CenterVertically, horizontalArrangement = Arrangement.spacedBy(12.dp), ) { @@ -166,6 +169,7 @@ private fun TxnRow(id: String, type: TxnType, amount: Long, note: String, date: formatCents(signed, signed = true), style = Type.bodyStrong, color = t.text, + modifier = Modifier.semantics { contentDescription = "txn_amount" }, ) } }