refactor away ItemsForZone, it's trivial now

This commit is contained in:
Matt Dunn-Rankin 2020-04-22 04:02:43 -07:00
parent 1f5a7e83e1
commit 09b928865e

View file

@ -192,10 +192,10 @@ function ItemsPanel({ zonesAndItems, onWearItem }) {
<Stack spacing="10">
{zonesAndItems.map(({ zoneName, items, wornItemId }) => (
<Box key={zoneName}>
<ItemsForZone
zoneName={zoneName}
<Heading2 mb="3">{zoneName}</Heading2>
<ItemList
items={items}
wornItemId={wornItemId}
wornItemIds={[wornItemId]}
onWearItem={onWearItem}
/>
</Box>
@ -240,19 +240,6 @@ function OutfitHeading() {
);
}
function ItemsForZone({ zoneName, items, wornItemId, onWearItem }) {
return (
<Box>
<Heading2 mb="3">{zoneName}</Heading2>
<ItemList
items={items}
wornItemIds={[wornItemId]}
onWearItem={onWearItem}
/>
</Box>
);
}
function Heading1({ children, ...props }) {
return (
<Heading fontFamily="Delicious" fontWeight="800" size="2xl" {...props}>