From 3bfbee18adeb38cbc63dec4bdee028acae8f335b Mon Sep 17 00:00:00 2001 From: Pascal Hartig Date: Tue, 19 Sep 2023 10:57:28 +0100 Subject: [PATCH] [android][sample] Display fresco image on demand --- .../java/com/facebook/flipper/sample/RootComponentSpec.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/android/sample/src/main/java/com/facebook/flipper/sample/RootComponentSpec.java b/android/sample/src/main/java/com/facebook/flipper/sample/RootComponentSpec.java index 5c8a703a1ee..d22723b9c52 100644 --- a/android/sample/src/main/java/com/facebook/flipper/sample/RootComponentSpec.java +++ b/android/sample/src/main/java/com/facebook/flipper/sample/RootComponentSpec.java @@ -125,11 +125,11 @@ static Component onCreateLayout(final ComponentContext c, @State boolean display .textSizeSp(20) .clickHandler(RootComponent.triggerCrash(c))) .child( - FrescoVitoImage2.create(c) + displayImage ? FrescoVitoImage2.create(c) .uri(Uri.parse("https://fbflipper.com/img/icon.png")) .marginDip(YogaEdge.ALL, 10) .widthDip(150) - .heightDip(150)) + .heightDip(150) : null) .build(); return VerticalScroll.create(c).childComponent(col).build();