From ae947d5405511384416c8215e2716d020554c2f9 Mon Sep 17 00:00:00 2001 From: Brandon Presley Date: Sun, 16 Oct 2022 17:20:13 +1300 Subject: [PATCH] Wait for data before displaying workouts on plans Closes #92 --- StartPlan.tsx | 43 +++++++++++++++++++++++-------------------- 1 file changed, 23 insertions(+), 20 deletions(-) diff --git a/StartPlan.tsx b/StartPlan.tsx index 55939de..bd416fd 100644 --- a/StartPlan.tsx +++ b/StartPlan.tsx @@ -166,26 +166,29 @@ export default function StartPlan() { innerRef={unitRef} /> )} - ( - select(index)} - left={() => ( - - select(index)} - value={index.toString()} - status={selected === index ? 'checked' : 'unchecked'} - color={color} - /> - - )} - /> - )} - /> + {counts && distinctSets && ( + ( + select(index)} + left={() => ( + + select(index)} + value={index.toString()} + status={selected === index ? 'checked' : 'unchecked'} + color={color} + /> + + )} + /> + )} + /> + )}