summaryrefslogtreecommitdiff
path: root/animism-align/frontend/app/views/nav
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2020-07-24 15:04:58 +0200
committerJules Laplace <julescarbon@gmail.com>2020-07-24 15:04:58 +0200
commit483fdeac8f6f4f6d6ddca9d770bb37a405feaf41 (patch)
tree27084d55d7d70b3c2adb178c8ed9563c56be8c58 /animism-align/frontend/app/views/nav
parent4c2cdb059628dfb5a3abb303c90d74599c4497dc (diff)
showing and hiding stuff
Diffstat (limited to 'animism-align/frontend/app/views/nav')
-rw-r--r--animism-align/frontend/app/views/nav/header.component.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/animism-align/frontend/app/views/nav/header.component.js b/animism-align/frontend/app/views/nav/header.component.js
index 5e14ce4..96e4f2a 100644
--- a/animism-align/frontend/app/views/nav/header.component.js
+++ b/animism-align/frontend/app/views/nav/header.component.js
@@ -8,6 +8,9 @@ import PlayButton from 'app/views/align/components/player/playButton.component'
import './nav.css'
function Header(props) {
+ if (props.router.location && props.router.location.pathname.match("/viewer")) {
+ return <span />
+ }
return (
<header>
<PlayButton />
@@ -33,6 +36,7 @@ function Header(props) {
const mapStateToProps = (state) => ({
// auth: state.auth,
site: state.site,
+ router: state.router,
// username: session.get('username'),
// isAuthenticated: state.auth.isAuthenticated,
})
@@ -40,4 +44,4 @@ const mapStateToProps = (state) => ({
const mapDispatchToProps = (dispatch) => ({
})
-export default connect(mapStateToProps, mapDispatchToProps)(Header)
+export default connect(mapStateToProps, mapDispatchToProps)(React.memo(Header))