damus

nostr ios client
git clone git://jb55.com/damus
Log | Files | Refs | README | LICENSE

commit 1ab42b4c5c9820b13863e8c34e3a2a0ed4681430
parent 9420a7a0ada9b785ea8e3d5a93d44e14f5c1f0fb
Author: William Casarin <jb55@jb55.com>
Date:   Tue,  9 Aug 2022 16:09:12 -0700

Fix chatroom cruft

Changelog-Fixed: Fixed various issues with chatroom view
Signed-off-by: William Casarin <jb55@jb55.com>

Diffstat:
Mdamus/Views/ChatView.swift | 6+++---
Mdamus/Views/ChatroomView.swift | 2+-
Mdamus/Views/EventDetailView.swift | 3+++
3 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/damus/Views/ChatView.swift b/damus/Views/ChatView.swift @@ -96,13 +96,14 @@ struct ChatView: View { if let ref_id = thread.replies.lookup(event.id) { if !is_reply_to_prev() { ReplyQuoteView(privkey: damus_state.keypair.privkey, quoter: event, event_id: ref_id, image_cache: damus_state.image_cache, profiles: damus_state.profiles) + .frame(maxHeight: 100) .environmentObject(thread) ReplyDescription } } - - NoteContentView(privkey: damus_state.keypair.privkey, event: event, profiles: damus_state.profiles, content: event.content) + NoteContentView(privkey: damus_state.keypair.privkey, event: event, profiles: damus_state.profiles, content: event.content) + if is_active || next_ev == nil || next_ev!.pubkey != event.pubkey { let bar = make_actionbar_model(ev: event, damus: damus_state) EventActionBar(damus_state: damus_state, event: event, bar: bar) @@ -112,7 +113,6 @@ struct ChatView: View { } .padding(6) } - .padding([.leading], 2) .background(Color.secondary.opacity(0.1)) .cornerRadius(8.0) diff --git a/damus/Views/ChatroomView.swift b/damus/Views/ChatroomView.swift @@ -37,7 +37,7 @@ struct ChatroomView: View { } - EndBlock() + EndBlock(height: 500) } .onReceive(NotificationCenter.default.publisher(for: .select_quote)) { notif in let ev = notif.object as! NostrEvent diff --git a/damus/Views/EventDetailView.swift b/damus/Views/EventDetailView.swift @@ -60,11 +60,14 @@ struct EventDetailView: View { switch cev { case .collapsed(let c): Text("··· \(c.count) other notes ···") + .padding([.top,.bottom], 10) .font(.footnote) .foregroundColor(.gray) .onTapGesture { //self.uncollapse_section(scroller: proxy, c: c) //self.toggle_collapse_thread(scroller: proxy, id: nil) + let ev = thread.events[c.start] + thread.set_active_event(ev, privkey: damus.keypair.privkey) toggle_thread_view() } case .event(let ev, let highlight):