From 047dbb632735bf4b6c2e6cb4644bd785064bff77 Mon Sep 17 00:00:00 2001 From: Matt Dunn-Rankin Date: Sat, 25 Apr 2020 19:02:30 -0700 Subject: [PATCH] use ItemContainer in skeleton, too --- src/ItemList.js | 80 +++++++++++++++++++++++++++---------------------- 1 file changed, 45 insertions(+), 35 deletions(-) diff --git a/src/ItemList.js b/src/ItemList.js index 96c7412..0e946df 100644 --- a/src/ItemList.js +++ b/src/ItemList.js @@ -49,9 +49,7 @@ export function ItemListSkeleton({ count }) { return ( {Array.from({ length: count }).map((_, i) => ( - - - + ))} ); @@ -63,33 +61,7 @@ export function Item({ item, outfitState, dispatchToOutfit }) { const theme = useTheme(); return ( - + {item.name} @@ -120,16 +92,54 @@ export function Item({ item, outfitState, dispatchToOutfit }) { /> )} - + ); } function ItemSkeleton() { return ( - - - - + + + + + + + + ); +} + +function ItemContainer({ children }) { + const theme = useTheme(); + + return ( + + {children} ); }