Skip to content

Commit

Permalink
OpenConceptLab/ocl_issues#1144 | fixing about tab nav
Browse files Browse the repository at this point in the history
  • Loading branch information
snyaggarwal committed Dec 13, 2021
1 parent d8bbf44 commit 8e3c4b4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/components/collections/CollectionHome.jsx
Expand Up @@ -49,7 +49,7 @@ class CollectionHome extends React.Component {
const { location } = this.props;

if(location.pathname.indexOf('/about') > -1 && this.shouldShowAboutTab())
return 5;
return 4;
if(location.pathname.indexOf('/versions') > -1)
return 3;
if(location.pathname.indexOf('/references') > -1)
Expand Down
2 changes: 1 addition & 1 deletion src/components/collections/CollectionHomeTabs.jsx
Expand Up @@ -75,7 +75,7 @@ const CollectionHomeTabs = props => {
}

const width = configFormWidth ? "calc(100% - " + (configFormWidth - 15) + "px)" : '100%';
const isInvalidTabConfig = !includes(['concepts', 'mappings', 'about', 'versions', 'text', 'references', 'expansions'], selectedTabConfig.type) && !selectedTabConfig.uri;
const isInvalidTabConfig = selectedTabConfig && !includes(['concepts', 'mappings', 'about', 'versions', 'text', 'references', 'expansions'], selectedTabConfig.type) && !selectedTabConfig.uri;
return (
<div className='col-md-12 sub-tab' style={{width: width}}>
<Tabs className='sub-tab-header col-md-11 no-side-padding' value={tab} onChange={onTabChange} aria-label="collection-home-tabs" classes={{indicator: 'hidden'}}>
Expand Down

0 comments on commit 8e3c4b4

Please sign in to comment.