mirror of
https://github.com/billsonnn/nitro-react.git
synced 2024-11-26 15:40:51 +01:00
Inventory tabs fix
This commit is contained in:
parent
3f64ecb644
commit
e7bbdf179c
@ -15,7 +15,7 @@ export const InventoryView: FC<InventoryViewProps> = props =>
|
||||
const [ isVisible, setIsVisible ] = useState(false);
|
||||
const [ currentTab, setCurrentTab ] = useState<string>(null);
|
||||
const [ tabs, setTabs ] = useState<string[]>([
|
||||
InventoryTabs.FURNITURE, InventoryTabs.BOTS, InventoryTabs.PETS, InventoryTabs.PETS
|
||||
InventoryTabs.FURNITURE, InventoryTabs.BOTS, InventoryTabs.PETS, InventoryTabs.BADGES
|
||||
]);
|
||||
|
||||
useEffect(() => {
|
||||
|
@ -13,10 +13,10 @@ export const InventoryTabsContentView: FC<InventoryTabsContentViewProps> = props
|
||||
|
||||
return (
|
||||
<div className="p-3">
|
||||
{ inventoryContext && inventoryContext.currentTab && inventoryContext.currentTab === InventoryTabs.FURNITURE } <InventoryTabFurnitureView />
|
||||
{ inventoryContext && inventoryContext.currentTab && inventoryContext.currentTab === InventoryTabs.BOTS } <InventoryTabBotsView />
|
||||
{ inventoryContext && inventoryContext.currentTab && inventoryContext.currentTab === InventoryTabs.PETS } <InventoryTabPetsView />
|
||||
{ inventoryContext && inventoryContext.currentTab && inventoryContext.currentTab === InventoryTabs.BADGES } <InventoryTabBadgesView />
|
||||
{ inventoryContext && inventoryContext.currentTab && inventoryContext.currentTab === InventoryTabs.FURNITURE && <InventoryTabFurnitureView /> }
|
||||
{ inventoryContext && inventoryContext.currentTab && inventoryContext.currentTab === InventoryTabs.BOTS && <InventoryTabBotsView /> }
|
||||
{ inventoryContext && inventoryContext.currentTab && inventoryContext.currentTab === InventoryTabs.PETS && <InventoryTabPetsView /> }
|
||||
{ inventoryContext && inventoryContext.currentTab && inventoryContext.currentTab === InventoryTabs.BADGES && <InventoryTabBadgesView /> }
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
@ -7,6 +7,6 @@ export const InventoryTabBadgesView: FC<InventoryTabBadgesViewProps> = props =>
|
||||
const inventoryContext = useContext(InventoryContext);
|
||||
|
||||
return (
|
||||
<></>
|
||||
<>Badges content</>
|
||||
);
|
||||
}
|
||||
|
@ -7,6 +7,6 @@ export const InventoryTabBotsView: FC<InventoryTabBotsViewProps> = props =>
|
||||
const inventoryContext = useContext(InventoryContext);
|
||||
|
||||
return (
|
||||
<></>
|
||||
<>Bots content</>
|
||||
);
|
||||
}
|
||||
|
@ -7,6 +7,6 @@ export const InventoryTabFurnitureView: FC<InventoryTabFurnitureViewProps> = pro
|
||||
const inventoryContext = useContext(InventoryContext);
|
||||
|
||||
return (
|
||||
<></>
|
||||
<>Furniture content</>
|
||||
);
|
||||
}
|
||||
|
@ -7,6 +7,6 @@ export const InventoryTabPetsView: FC<InventoryTabPetsViewProps> = props =>
|
||||
const inventoryContext = useContext(InventoryContext);
|
||||
|
||||
return (
|
||||
<></>
|
||||
<>Pets content</>
|
||||
);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user