Skip to content

Commit

Permalink
style: ktfmt
Browse files Browse the repository at this point in the history
  • Loading branch information
SidonieBouthors committed Jun 2, 2024
1 parent ad6de77 commit aaa9ba6
Showing 1 changed file with 28 additions and 33 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -215,43 +215,38 @@ fun ProfileScreen(navActions: NavigationActions, viewmodel: ProfileViewModel) {

// The below part is association dependent, only available if you're an admin !
if (state.isAdmin) {
Text(
text = "Manage ${state.selectedAssociation.name}",
style = MaterialTheme.typography.titleMedium
)
Text(
text = "Manage ${state.selectedAssociation.name}",
style = MaterialTheme.typography.titleMedium)

Column(
modifier =
Modifier.fillMaxWidth()
.testTag("manageAssociationList")
.clip(RoundedCornerShape(12.dp))
) {
Column(
modifier =
Modifier.fillMaxWidth()
.testTag("manageAssociationList")
.clip(RoundedCornerShape(12.dp))) {
AssociationSettings.entries.forEach { s ->
ListItem(
leadingContent = {
Icon(
imageVector = s.getIcon(),
contentDescription = "${s.name} icon"
)
},
headlineContent = { Text(text = s.toString()) },
trailingContent = {
Icon(
imageVector = Icons.AutoMirrored.Filled.ArrowRight,
contentDescription = "Go to ${s.name} settings"
)
},
colors =
ListItemDefaults.colors(
containerColor =
MaterialTheme.colorScheme.primaryContainer
),
modifier =
Modifier.testTag(s.name).clickable {
ListItem(
leadingContent = {
Icon(
imageVector = s.getIcon(),
contentDescription = "${s.name} icon")
},
headlineContent = { Text(text = s.toString()) },
trailingContent = {
Icon(
imageVector = Icons.AutoMirrored.Filled.ArrowRight,
contentDescription = "Go to ${s.name} settings")
},
colors =
ListItemDefaults.colors(
containerColor =
MaterialTheme.colorScheme.primaryContainer),
modifier =
Modifier.testTag(s.name).clickable {
navActions.navigateTo(s.getDestination())
})
})
}
}
}
}

// log out button (for everyone)
Expand Down

0 comments on commit aaa9ba6

Please sign in to comment.