dev hax
This commit is contained in:
parent
1758907432
commit
01b93f7e03
@ -1,9 +1,10 @@
|
|||||||
const { connect } = require('react-redux');
|
const { connect } = require('react-redux');
|
||||||
const preact = require('preact');
|
const preact = require('preact');
|
||||||
|
const { Fragment } = require('preact');
|
||||||
const actions = require('../actions');
|
const actions = require('../actions');
|
||||||
|
|
||||||
const testGame = require('./../test.game');
|
const testGame = process.NODE_ENV === 'develop' && require('./../test.game');
|
||||||
const testInstance = require('./../test.instance');
|
const testInstance = process.NODE_ENV === 'develop' && require('./../test.instance');
|
||||||
|
|
||||||
const addState = connect(
|
const addState = connect(
|
||||||
function receiveState(state) {
|
function receiveState(state) {
|
||||||
@ -84,6 +85,14 @@ function Nav(args) {
|
|||||||
return <button key={i} onClick={() => navTo('team')}>+</button>;
|
return <button key={i} onClick={() => navTo('team')}>+</button>;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const haxSection = process.NODE_ENV === 'development'
|
||||||
|
? (<Fragment>
|
||||||
|
<h2>Hax</h2>
|
||||||
|
<button onClick={() => setTestGame(account.id)}>Test Game</button>
|
||||||
|
<button onClick={() => setTestInstance(account.id)}>Test Instance</button>
|
||||||
|
</Fragment>)
|
||||||
|
: null;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<nav>
|
<nav>
|
||||||
<h2>Team</h2>
|
<h2>Team</h2>
|
||||||
@ -93,9 +102,7 @@ function Nav(args) {
|
|||||||
<button onClick={() => navTo('list')}>2. Join</button>
|
<button onClick={() => navTo('list')}>2. Join</button>
|
||||||
<hr />
|
<hr />
|
||||||
{joined}
|
{joined}
|
||||||
<h2>Hax</h2>
|
{haxSection}
|
||||||
<button onClick={() => setTestGame(account.id)}>Test Game</button>
|
|
||||||
<button onClick={() => setTestInstance(account.id)}>Test Instance</button>
|
|
||||||
</nav>
|
</nav>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user