1
0
mirror of https://github.com/ascribe/onion.git synced 2024-11-15 17:45:10 +01:00
onion/js/components/whitelabel/prize/prize_app.js

36 lines
930 B
JavaScript
Raw Normal View History

'use strict';
import React from 'react';
import Router from 'react-router';
import Hero from './components/prize_hero';
2015-07-13 16:34:26 +02:00
import Header from '../../header';
import Footer from '../../footer';
import GlobalNotification from '../../global_notification';
let RouteHandler = Router.RouteHandler;
let PrizeApp = React.createClass({
2015-07-13 16:34:26 +02:00
mixins: [Router.State],
render() {
2015-07-13 16:34:26 +02:00
let header = null;
2015-07-14 18:55:34 +02:00
if (this.isActive('landing') || this.isActive('login') || this.isActive('signup')) {
header = <Hero />;
} else {
2015-07-14 21:06:11 +02:00
header = <Header showAddWork={false} />;
2015-07-13 16:34:26 +02:00
}
return (
<div className="container ascribe-prize-app">
2015-07-13 16:34:26 +02:00
{header}
<RouteHandler />
<GlobalNotification />
<div id="modal" className="container"></div>
<Footer />
</div>
);
}
});
export default PrizeApp;