mirror of
https://github.com/Alamantus/Lexiconga.git
synced 2025-06-23 17:46:39 +02:00
Only show Additional custom tabs if they exist
This commit is contained in:
parent
a05fd9c48d
commit
d6915ce661
1 changed files with 26 additions and 29 deletions
|
@ -32,16 +32,12 @@ export class DetailsSection extends Component {
|
|||
}
|
||||
}
|
||||
|
||||
mapCustomMenuItems (customTabs) {
|
||||
return customTabs.map(tab => {
|
||||
return tab.name;
|
||||
});
|
||||
}
|
||||
|
||||
displayMenu () {
|
||||
const { details } = this.props;
|
||||
|
||||
let additionalMenu = (
|
||||
let additionalMenu = null
|
||||
if (details.hasOwnProperty('custom') && details.custom.length > 0) {
|
||||
additionalMenu = (
|
||||
<div>
|
||||
<p className='menu-label'>
|
||||
Additional
|
||||
|
@ -64,6 +60,7 @@ export class DetailsSection extends Component {
|
|||
</ul>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
return (
|
||||
<div className='details-menu'>
|
||||
|
|
Loading…
Add table
Reference in a new issue