Updated on 2026-08-14

This commit is contained in:
Tangem 2026-02-05 14:28:48 +05:00
parent fa86588528
commit bb1ff81252
3 changed files with 13 additions and 8 deletions

View file

@ -14,7 +14,7 @@ internal sealed class WalletSettingsItemUM {
data class WithItems(
override val id: String,
val description: TextReference,
val description: TextReference?,
val blocks: ImmutableList<BlockUM>,
) : WalletSettingsItemUM()

View file

@ -167,6 +167,7 @@ private fun Content(state: WalletSettingsUM, modifier: Modifier = Modifier) {
@Composable
private fun ItemsBlock(model: WalletSettingsItemUM.WithItems, modifier: Modifier = Modifier) {
val description = model.description
Column(
modifier = modifier,
horizontalAlignment = Alignment.Start,
@ -190,12 +191,16 @@ private fun ItemsBlock(model: WalletSettingsItemUM.WithItems, modifier: Modifier
}
}
Text(
modifier = Modifier.padding(horizontal = TangemTheme.dimens.spacing12),
text = model.description.resolveReference(),
color = TangemTheme.colors.text.tertiary,
style = TangemTheme.typography.caption2,
)
AnimatedVisibility(visible = description != null) {
if (description != null) {
Text(
modifier = Modifier.padding(horizontal = TangemTheme.dimens.spacing12),
text = description.resolveReference(),
color = TangemTheme.colors.text.tertiary,
style = TangemTheme.typography.caption2,
)
}
}
}
}

View file

@ -144,7 +144,7 @@ internal class ItemsBuilder @Inject constructor() {
onCardSettingsClick: () -> Unit,
) = WalletSettingsItemUM.WithItems(
id = "card",
description = resourceReference(R.string.settings_card_settings_footer),
description = null,
blocks = buildList {
val isHotWallet = userWallet is UserWallet.Hot
if (isHotWallet) {