From dd44bd779badecd7c5d791ac43a6ee5d78ebc9c4 Mon Sep 17 00:00:00 2001 From: William Casarin Date: Mon, 23 Jan 2023 10:31:51 -0800 Subject: [PATCH] EventView: hide extra previews Getting too busy --- damus/Views/EventView.swift | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/damus/Views/EventView.swift b/damus/Views/EventView.swift index e28e0d9f..db232ee3 100644 --- a/damus/Views/EventView.swift +++ b/damus/Views/EventView.swift @@ -425,13 +425,15 @@ func make_actionbar_model(ev: NostrEvent, damus: DamusState) -> ActionBarModel { struct EventView_Previews: PreviewProvider { static var previews: some View { VStack { + /* EventView(damus: test_damus_state(), event: NostrEvent(content: "hello there https://jb55.com/s/Oct12-150217.png https://jb55.com/red-me.jb55 cool", pubkey: "pk"), show_friend_icon: true, size: .small) EventView(damus: test_damus_state(), event: NostrEvent(content: "hello there https://jb55.com/s/Oct12-150217.png https://jb55.com/red-me.jb55 cool", pubkey: "pk"), show_friend_icon: true, size: .normal) EventView(damus: test_damus_state(), event: NostrEvent(content: "hello there https://jb55.com/s/Oct12-150217.png https://jb55.com/red-me.jb55 cool", pubkey: "pk"), show_friend_icon: true, size: .big) + */ EventView( event: NostrEvent( - content: "hello there https://jb55.com/s/Oct12-150217.png https://jb55.com/red-me.jb55 cool", + content: "hello there https://jb55.com/s/Oct12-150217.png https://jb55.com/red-me.jpg cool", pubkey: "pk", createdAt: Int64(Date().timeIntervalSince1970 - 100) ), @@ -441,6 +443,20 @@ struct EventView_Previews: PreviewProvider { show_friend_icon: true, size: .selected ) + + EventView( + event: NostrEvent( + content: "hello there https://jb55.com/s/Oct12-150217.png https://jb55.com/red-me.jpg cool", + pubkey: "pk", + createdAt: Int64(Date().timeIntervalSince1970 - 100) + ), + highlight: .none, + has_action_bar: true, + damus: test_damus_state(), + show_friend_icon: true, + size: .normal + ) } + .padding() } }