- {_this.state.section === 'Send/Receive' && (
-
- )}
-
- {_this.state.section === 'Wallet' && (
-
- )}
-
- {_this.state.section === 'Tokens' && (
-
- )}
-
- {_this.state.section === 'Configure' && (
-
- )}
-
- {_this.renderNewViewItems()}
+ {_this.renderNewViewItems(_this.props)}
@@ -329,9 +283,10 @@ class AdminLTEPage extends React.Component {
// Render non-default menu items. The catch ensures that the render function
// won't be interrupted if there is an issue porting new menu items.
- renderNewMenuItems () {
+ renderNewMenuItems (props) {
try {
- return menuComponents && menuComponents.map(m => m.menuItem)
+ const _menuComponents = menuComponents(props)
+ return _menuComponents && _menuComponents.map(m => m.menuItem)
} catch (err) {
// TODO: Figure out how to return an invisible Item.
return _this.getInvisibleMenuItem() //