mirror of
https://github.com/billsonnn/nitro-react.git
synced 2024-11-27 08:00:51 +01:00
Fix stuff i busted
This commit is contained in:
parent
28060820b5
commit
deb5461d6a
@ -93,10 +93,10 @@ export const CatalogView: FC<CatalogViewProps> = props =>
|
|||||||
<NitroCardView className="nitro-catalog">
|
<NitroCardView className="nitro-catalog">
|
||||||
<NitroCardHeaderView headerText={ LocalizeText('catalog.title') } onCloseClick={ event => setIsVisible(false) } />
|
<NitroCardHeaderView headerText={ LocalizeText('catalog.title') } onCloseClick={ event => setIsVisible(false) } />
|
||||||
<NitroCardTabsView>
|
<NitroCardTabsView>
|
||||||
{ root && root.children.length && root.children.map(page =>
|
{ root && root.children.length && root.children.map((page, index) =>
|
||||||
{
|
{
|
||||||
return (
|
return (
|
||||||
<NitroCardTabsItemView key={ page.pageId } isActive={ (currentTab === page) } onClick={ event => setCurrentTab(page) }>
|
<NitroCardTabsItemView key={ index } isActive={ (currentTab === page) } onClick={ event => setCurrentTab(page) }>
|
||||||
{ page.localization }
|
{ page.localization }
|
||||||
</NitroCardTabsItemView>
|
</NitroCardTabsItemView>
|
||||||
);
|
);
|
||||||
|
@ -35,11 +35,11 @@ export const CatalogNavigationSetView: FC<CatalogNavigationSetViewProps> = props
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="row row-cols-1 g-0 catalog-navigation-set-container w-100">
|
<div className="row row-cols-1 g-0 catalog-navigation-set-container w-100">
|
||||||
{ page && (page.children.length > 0) && page.children.map(page =>
|
{ page && (page.children.length > 0) && page.children.map((page, index) =>
|
||||||
{
|
{
|
||||||
if(!page.visible) return null;
|
if(!page.visible) return null;
|
||||||
|
|
||||||
return <CatalogNavigationItemView key={ page.pageId } page={ page } isActive={ (activeChild === page) } setActiveChild={ setActiveChild } />
|
return <CatalogNavigationItemView key={ index } page={ page } isActive={ (activeChild === page) } setActiveChild={ setActiveChild } />
|
||||||
}) }
|
}) }
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
Loading…
Reference in New Issue
Block a user