From e80015680a81cb5c81fe1ea00687ebf279ba9484 Mon Sep 17 00:00:00 2001 From: Swift Coder Date: Mon, 28 Oct 2024 23:14:38 -0400 Subject: [PATCH] Add share button in Full screen image carousel view (for Image only) The ellipsis (share button) allows you to share the current image being displayed in the full screen carousel viewer. Changelog-Changes: Add share button in Full screen image carousel view (for Image only) Signed-off-by: Swift Coder --- .../Views/Images/FullScreenCarouselView.swift | 20 +++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/damus/Views/Images/FullScreenCarouselView.swift b/damus/Views/Images/FullScreenCarouselView.swift index a6b6b3d48..07ec738cc 100644 --- a/damus/Views/Images/FullScreenCarouselView.swift +++ b/damus/Views/Images/FullScreenCarouselView.swift @@ -96,8 +96,24 @@ struct FullScreenCarouselView: View { GeometryReader { geo in VStack { if showMenu { - NavDismissBarView(navDismissBarContainer: .fullScreenCarousel) - .foregroundColor(.white) + + HStack { + NavDismissBarView(navDismissBarContainer: .fullScreenCarousel) + .foregroundColor(.white) + + if let url = urls[safe: selectedIndex], + case .image = url { + ShareLink(item: url.url) { + Image(systemName: "ellipsis") + .foregroundColor(.white) + .frame(width: 33, height: 33) + .background(.damusBlack) + .clipShape(Circle()) + } + .padding(20) + } + } + Spacer() if urls.count > 1 {