diff --git a/app/components/AdminView.js b/app/components/AdminView.js
new file mode 100644
index 0000000..5570d5f
--- /dev/null
+++ b/app/components/AdminView.js
@@ -0,0 +1,34 @@
+import React, { Fragment } from 'react';
+import { Tabs, Tab } from 'react-bootstrap';
+import 'bootstrap/dist/css/bootstrap.css';
+import TopNavbar from './topnavbar';
+import TestTokenUI from './testtoken';
+import ERC20TokenUI from './erc20token';
+import ProposalManager from './proposal-manager/proposal-manager'
+import VotingDapp from './voting-dapp/voting-dapp';
+import SNTUI from './snt-ui';
+
+export default ({ setAccount }) => {
+ return (
+
+
setAccount(e)} />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ )
+}
diff --git a/app/components/Voting.js b/app/components/Voting.js
new file mode 100644
index 0000000..3f0abbc
--- /dev/null
+++ b/app/components/Voting.js
@@ -0,0 +1,11 @@
+import React, { Fragment } from 'react';
+import CssBaseline from '@material-ui/core/CssBaseline';
+import 'typeface-roboto';
+import AppBar from './standard/AppBar';
+
+export default ({ toggleAdmin }) => (
+
+
+
+
+)
diff --git a/app/components/standard/AppBar.js b/app/components/standard/AppBar.js
new file mode 100644
index 0000000..bc343d8
--- /dev/null
+++ b/app/components/standard/AppBar.js
@@ -0,0 +1,48 @@
+import React from 'react';
+import PropTypes from 'prop-types';
+import { withStyles } from '@material-ui/core/styles';
+import AppBar from '@material-ui/core/AppBar';
+import Toolbar from '@material-ui/core/Toolbar';
+import Typography from '@material-ui/core/Typography';
+import Button from '@material-ui/core/Button';
+import IconButton from '@material-ui/core/IconButton';
+import MenuIcon from '@material-ui/icons/Menu';
+
+const styles = {
+ root: {
+ flexGrow: 1,
+ fontSize: '16px'
+ },
+ flex: {
+ flex: 1,
+ },
+ menuButton: {
+ marginLeft: -12,
+ marginRight: 20,
+ },
+};
+
+function ButtonAppBar(props) {
+ const { classes, toggleAdmin } = props;
+ return (
+
+
+
+
+
+
+
+ What should we build next?
+
+
+
+
+
+ );
+}
+
+ButtonAppBar.propTypes = {
+ classes: PropTypes.object.isRequired,
+};
+
+export default withStyles(styles)(ButtonAppBar);
diff --git a/app/dapp.js b/app/dapp.js
index 2a17365..777b0e4 100644
--- a/app/dapp.js
+++ b/app/dapp.js
@@ -1,15 +1,9 @@
-import React from 'react';
+import React, { Fragment } from 'react';
import ReactDOM from 'react-dom';
-import { Tabs, Tab } from 'react-bootstrap';
import EmbarkJS from 'Embark/EmbarkJS';
-import TopNavbar from './components/topnavbar';
-import TestTokenUI from './components/testtoken';
-import ERC20TokenUI from './components/erc20token';
-import ProposalManager from './components/proposal-manager/proposal-manager'
-import VotingDapp from './components/voting-dapp/voting-dapp';
-import SNTUI from './components/snt-ui';
-
+import AdminView from './components/AdminView';
+import Voting from './components/Voting';
import SNT from 'Embark/contracts/SNT';
window['SNT'] = SNT;
@@ -20,6 +14,7 @@ class App extends React.Component {
constructor(props) {
super(props);
}
+ state = { admin: false };
componentDidMount(){
__embarkContext.execWhenReady(() => {
@@ -32,34 +27,20 @@ class App extends React.Component {
_renderStatus(title, available) {
let className = available ? 'pull-right status-online' : 'pull-right status-offline';
- return
+ return
{title}
- ;
+ ;
}
render(){
+ const { admin } = this.state;
+ const toggleAdmin = () => this.setState({ admin: true });
return (
-
-
this.setAccount(e)} />
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- );
+
+ {admin ? : }
+
+ );
}
}
diff --git a/app/index.html b/app/index.html
index 1fb8607..8f974fd 100644
--- a/app/index.html
+++ b/app/index.html
@@ -1,10 +1,8 @@
Status.im - Contracts
-
-
-
+
diff --git a/package.json b/package.json
index 0461ff5..2ab4749 100644
--- a/package.json
+++ b/package.json
@@ -17,9 +17,12 @@
},
"homepage": "https://github.com/status-im/contracts#readme",
"dependencies": {
+ "@material-ui/core": "^1.3.0",
+ "@material-ui/icons": "^1.1.0",
"babel-plugin-transform-object-rest-spread": "^6.26.0",
"babel-preset-stage-2": "^6.24.1",
"bignumber.js": "^5.0.0",
+ "bootstrap": "^3.3.7",
"formik": "^0.11.11",
"jquery": "^3.3.1",
"lodash": "^4.17.10",
@@ -28,6 +31,7 @@
"react-bootstrap": "^0.32.1",
"react-dom": "^16.3.2",
"react-toggle": "^4.0.2",
- "rlp": "^2.0.0"
+ "rlp": "^2.0.0",
+ "typeface-roboto": "0.0.54"
}
}