X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=cmd%2Fweb%2Fjs%2Fmain.jsx;h=c95c74888b978f60eea72c99dafbbea87c08b79a;hb=ee902062a71c1ef31176cf5061555618b288b1d4;hp=eb530577fa2ae53e4a075cde960f109fea702d19;hpb=7a9e5112eaaea58d55f181d3e5296e4ff839921c;p=perso%2FImmae%2FProjets%2FCryptomonnaies%2FCryptoportfolio%2FFront.git diff --git a/cmd/web/js/main.jsx b/cmd/web/js/main.jsx index eb53057..c95c748 100644 --- a/cmd/web/js/main.jsx +++ b/cmd/web/js/main.jsx @@ -1,18 +1,40 @@ -var SignupForm = require('./signup.js').SignupForm; -var SigninForm = require('./signin.js').SigninForm; -var OtpEnrollForm = require('./otp.js').OtpEnrollForm; -var PoloniexForm = require('./poloniex.js').PoloniexForm; -var App = require('./app.js'); -var Api = require('./api.js').Api; -var cookies = require('./cookies.js'); - -var Logo = React.createClass({ - render: function() { - return (); +import SignupForm from './signup.js'; +import SigninForm from './signin.js'; +import OtpEnrollForm from './otp.js'; +import PoloniexController from './poloniex.js'; +import App from './app.js'; +import Api from './api.js'; +import cookies from './cookies.js'; +import React from 'react'; + +class Header extends React.Component { + render = () => { + if (this.props.displayLogout === true) { + return ; + } + return ; + } -}); +} + +class Logo extends React.Component { + render() { + return ; + } +} App.page('/signup', false, function(context) { if (App.isUserSignedIn()) { @@ -20,12 +42,10 @@ App.page('/signup', false, function(context) { return; } - App.mount( -
- + App.mount(
+
-
- ); +
); }); App.page('/signin', false, function(context) { @@ -34,12 +54,10 @@ App.page('/signin', false, function(context) { return; } - App.mount( -
- + App.mount(
+
-
- ); +
); }); App.page('/signout', true, function(context) { @@ -49,21 +67,22 @@ App.page('/signout', true, function(context) { }); App.page('/me', true, function(context) { - Api.Call('MARKET', {'name': 'poloniex'}, function(err, status, data) { - if (err) { - console.error(err, data); - return; - } + App.mount(
+
+ +
); +}); - App.mount( -
- -

Poloniex

- +App.page('/not_confirmed', true, function(context) { + App.mount(
+
+
+
+

Please be patient, you account is being confirmed...

+

Refresh

+
- ); - - }.bind(this)); +
); }); App.page('/otp/setup', true, function(context) { @@ -73,23 +92,19 @@ App.page('/otp/setup', true, function(context) { return; } - App.mount( -
- + App.mount(
+
-
- ); +
); - }.bind(this)); + }); }); App.page('/otp/validate', true, function(context) { - App.mount( -
- + App.mount(
+
-
- ); +
); }); App.page('/', false, function(context) {