misc refactors

This commit is contained in:
William Casarin
2023-01-02 18:57:51 -08:00
parent ba03be5b91
commit aaa21bf1bf
2 changed files with 7 additions and 6 deletions

View File

@@ -103,12 +103,13 @@ struct BuilderEventView: View {
var body: some View {
VStack {
if event == nil {
ProgressView().padding()
} else {
NavigationLink(destination: BuildThreadV2View(damus: damus, event_id: event!.id)) {
EventView(damus: damus, event: event!, show_friend_icon: true, size: .small)
if let event = event {
let ev = event.inner_event ?? event
NavigationLink(destination: BuildThreadV2View(damus: damus, event_id: ev.id)) {
EventView(damus: damus, event: event, show_friend_icon: true, size: .small)
}.buttonStyle(.plain)
} else {
ProgressView().padding()
}
}
.frame(minWidth: 0, maxWidth: .infinity)