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

43 lines
1.1 KiB
JavaScript
Raw Normal View History

'use strict';
import React from 'react';
import Router from 'react-router';
import Header from '../../header';
import Footer from '../../footer';
import GlobalNotification from '../../global_notification';
import getRoutes from './wallet_routes';
let RouteHandler = Router.RouteHandler;
let WalletApp = React.createClass({
2015-08-19 14:48:22 +02:00
mixins: [Router.State],
render() {
let subdomain = window.location.host.split('.')[0];
let ROUTES = getRoutes(null, subdomain);
let header = null;
if ((this.isActive('landing') || this.isActive('login') || this.isActive('signup'))
&& (['ikonotv', 'cyland']).indexOf(subdomain) > -1) {
2015-08-19 14:48:22 +02:00
header = (
<div className="hero"/>);
} else {
header = <Header showAddWork={true} routes={ROUTES} />;
2015-08-19 14:48:22 +02:00
}
return (
<div className="container ascribe-prize-app">
2015-08-19 14:48:22 +02:00
{header}
2015-08-12 16:26:24 +02:00
<RouteHandler />
<GlobalNotification />
<div id="modal" className="container"></div>
<Footer />
</div>
);
}
});
export default WalletApp;