commit 4b7444f33871d1f4869f63a2691f2cc58ec1ef7b
parent 57159f7df97297ef0695924817e3bc377b8800db
Author: Terry Yiu <git@tyiu.xyz>
Date: Mon, 3 Jul 2023 11:24:42 -0400
Fix profile navigation bugs from muted users list and relay list views
Changelog-Fixed: Fix profile navigation bugs from muted users list and relay list views
Signed-off-by: Terry Yiu <git@tyiu.xyz>
Reviewed-by: William Casarin <jb55@jb55.com>
Diffstat:
2 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/damus/Views/Muting/MutelistView.swift b/damus/Views/Muting/MutelistView.swift
@@ -42,6 +42,9 @@ struct MutelistView: View {
.swipeActions {
RemoveAction(pubkey: pubkey)
}
+ .onTapGesture {
+ damus_state.nav.push(route: Route.ProfileByKey(pubkey: pubkey))
+ }
}
.navigationTitle(NSLocalizedString("Muted Users", comment: "Navigation title of view to see list of muted users."))
.onAppear {
diff --git a/damus/Views/Relays/RelayDetailView.swift b/damus/Views/Relays/RelayDetailView.swift
@@ -72,9 +72,10 @@ struct RelayDetailView: View {
if let pubkey = nip11.pubkey {
Section(NSLocalizedString("Admin", comment: "Label to display relay contact user.")) {
- NavigationLink(value: Route.ProfileByKey(pubkey: pubkey), label: {
- UserViewRow(damus_state: state, pubkey: pubkey)
- })
+ UserViewRow(damus_state: state, pubkey: pubkey)
+ .onTapGesture {
+ state.nav.push(route: Route.ProfileByKey(pubkey: pubkey))
+ }
}
}
if let relay_connection {