metamaps--metamaps/frontend/src/components/Apps/index.js

25 lines
744 B
JavaScript
Raw Normal View History

import React, { Component } from 'react'
2017-10-14 16:03:05 +00:00
import PropTypes from 'prop-types'
import NavBar from '../App/Navbar'
import NavBarLink from '../App/NavBarLink'
class Apps extends Component {
render = () => {
const { currentUser } = this.props
return (
<NavBar>
2017-10-14 16:03:05 +00:00
{currentUser && currentUser.get('admin') && <NavBarLink show hardReload
matchChildRoutes href="/oauth/applications" linkClass="activeMaps"
text="Registered Apps" />}
<NavBarLink show hardReload matchChildRoutes
href="/oauth/authorized_applications"
linkClass="authedApps" text="Authorized Apps" />
2017-10-14 16:03:05 +00:00
<NavBarLink show href="/" linkClass="myMaps" text="Maps" />
</NavBar>
)
}
}
export default Apps