From b7a1bd1d558eb954968668b8d69358d4d9faaa23 Mon Sep 17 00:00:00 2001 From: Shav Kinderlehrer Date: Wed, 27 Dec 2023 13:07:20 -0500 Subject: Refactoring + make itemInfo more visible --- Jel/Views/Library/LibraryIconView.swift | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Jel/Views/Library/LibraryIconView.swift') diff --git a/Jel/Views/Library/LibraryIconView.swift b/Jel/Views/Library/LibraryIconView.swift index 9bd3182..800d488 100644 --- a/Jel/Views/Library/LibraryIconView.swift +++ b/Jel/Views/Library/LibraryIconView.swift @@ -24,10 +24,10 @@ struct LibraryIconView: View { @State var placeHolder: AnyView? - var shouldShowCaption: Bool = true + var shouldShowCaption: Bool = false var imageCornerRadius: CGFloat = 5 var body: some View { - VStack { + VStack(alignment: .leading) { LazyImage(url: imageUrl) {state in if let image = state.image { image @@ -60,9 +60,9 @@ struct LibraryIconView: View { } } } - func hideCaption(_ isHidden: Bool = true) -> Self { + func showCaption(_ showCaption: Bool = true) -> Self { var copy = self - copy.shouldShowCaption = !isHidden + copy.shouldShowCaption = showCaption return copy } -- cgit v1.2.3