From 73de7dc57ecf2a53f0569c58e8aa8ed9d26b100f Mon Sep 17 00:00:00 2001 From: Jonathan Neuteboom <--global> Date: Mon, 24 Jun 2024 17:58:34 +0200 Subject: [PATCH] Don't show button container if there are no buttons --- src/components/Lightbox.tsx | 34 ++++++++++++++++++---------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/src/components/Lightbox.tsx b/src/components/Lightbox.tsx index 9c23068..0185ba2 100644 --- a/src/components/Lightbox.tsx +++ b/src/components/Lightbox.tsx @@ -59,22 +59,24 @@ const getLightboxFooterComponent = )} {content && {content}} - - {onPressDelete && ( - - - - - - )} - {onPressCrop && ( - - - - - - )} - + {(onPressDelete || onPressCrop) && ( + + {onPressDelete && ( + + + + + + )} + {onPressCrop && ( + + + + + + )} + + )} )