Only showing the paid relay icon when the relay is paid.

This commit is contained in:
Vitor Pamplona
2023-06-23 18:09:03 -04:00
parent aa931a4cc5
commit f8acb26763
@@ -282,22 +282,19 @@ fun ServerConfig(
Column(Modifier.weight(1f)) { Column(Modifier.weight(1f)) {
Row(verticalAlignment = Alignment.CenterVertically) { Row(verticalAlignment = Alignment.CenterVertically) {
Icon( if (item.paidRelay) {
imageVector = Icons.Default.Paid, Icon(
null, imageVector = Icons.Default.Paid,
modifier = Modifier null,
.padding(end = 5.dp) modifier = Modifier
.size(15.dp), .padding(end = 5.dp)
tint = if (item.paidRelay) { .size(14.dp),
Color.Green tint = Color.Green
} else { )
MaterialTheme.colors.onSurface.copy( }
alpha = 0.32f
)
}
)
Text( Text(
text = item.url.removePrefix("wss://"), text = item.url.removePrefix("wss://").removeSuffix("/"),
modifier = Modifier modifier = Modifier
.weight(1f) .weight(1f)
.clickable { .clickable {