From 16985b6545cb940cdb58d6a065cf4b37e5342c58 Mon Sep 17 00:00:00 2001 From: Kgothatso Ngako Date: Sun, 31 May 2026 02:32:40 +0200 Subject: [PATCH] Design change --- .../widgets/detail/MetadataEventDetail.kt | 34 +++++++++---------- 1 file changed, 16 insertions(+), 18 deletions(-) diff --git a/composeApp/src/commonMain/kotlin/ac/cord/auxiliary/compose/ui/composable/widgets/detail/MetadataEventDetail.kt b/composeApp/src/commonMain/kotlin/ac/cord/auxiliary/compose/ui/composable/widgets/detail/MetadataEventDetail.kt index 904624ba..7ca91efe 100644 --- a/composeApp/src/commonMain/kotlin/ac/cord/auxiliary/compose/ui/composable/widgets/detail/MetadataEventDetail.kt +++ b/composeApp/src/commonMain/kotlin/ac/cord/auxiliary/compose/ui/composable/widgets/detail/MetadataEventDetail.kt @@ -164,24 +164,6 @@ fun MetadataEventDetail( modifier = Modifier.weight(1f) ) - if (!metadataEventDetailViewModel.isActiveUser()) { - IconButton( - onClick = { - onNavigateToChatRoom.invoke( - ChatRoomDetailRoute( - directMessageIdentifier = localNostrEvent.nostrEvent.id - ) - ) - } - ) { - Icon( - Icons.Default.Mail, - contentDescription = "Direct Message" - ) - } - } - - when(val metadataEventDetailUIState = metadataEventDetailViewModel.metadataEventDetailUIState) { MetadataEventDetailUIState.Error -> { Icon( @@ -240,6 +222,22 @@ fun MetadataEventDetail( LoadingIndicator() } } + + IconButton( + onClick = { + onNavigateToChatRoom.invoke( + ChatRoomDetailRoute( + directMessageIdentifier = localNostrEvent.nostrEvent.id + ) + ) + } + ) { + Icon( + Icons.Default.Mail, + contentDescription = "Direct Message" + ) + } + } Text( modifier = Modifier.fillMaxWidth().padding(