mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2025-09-29 10:02:42 +02:00
Moves tags calculation to Launched Effect
This commit is contained in:
@@ -566,11 +566,15 @@ fun DisplayFollowingHashtagsInPost(
|
||||
account: Account,
|
||||
navController: NavController
|
||||
) {
|
||||
var firstTag by remember { mutableStateOf<String?>(null) }
|
||||
|
||||
LaunchedEffect(key1 = noteEvent) {
|
||||
firstTag = noteEvent.firstIsTaggedHashes(account.followingTagSet())
|
||||
}
|
||||
|
||||
Column() {
|
||||
Row(verticalAlignment = Alignment.CenterVertically) {
|
||||
val firstTag =
|
||||
noteEvent.firstIsTaggedHashes(account.followingTagSet())
|
||||
if (firstTag != null) {
|
||||
firstTag?.let {
|
||||
ClickableText(
|
||||
text = AnnotatedString(" #$firstTag"),
|
||||
onClick = { navController.navigate("Hashtag/$firstTag") },
|
||||
|
Reference in New Issue
Block a user