diff --git a/webclient/src/Admin.js b/webclient/src/Admin.js new file mode 100644 index 0000000..965c041 --- /dev/null +++ b/webclient/src/Admin.js @@ -0,0 +1,29 @@ +import React, { Component } from 'react'; +import { Breadcrumb, Dropdown, Header, Icon, Item, Menu, Segment, Input } from 'semantic-ui-react' +import { Link } from 'react-router-dom'; + +class Admin extends Component { + render() { + const data = this.props.data; + const match = this.props.match; + + return ( +
+ + Admin + + + + + + Auth Server + Manage tools, members, courses, and firmware + + + +
+ ); + } +} + +export default Admin; diff --git a/webclient/src/App.js b/webclient/src/App.js index 0ee4cb0..654f141 100644 --- a/webclient/src/App.js +++ b/webclient/src/App.js @@ -235,7 +235,7 @@ class App extends Component { {user.profile.selected_courses ?
- + } /> diff --git a/webclient/src/Categories.js b/webclient/src/Categories.js index 473e7f8..aaad40b 100644 --- a/webclient/src/Categories.js +++ b/webclient/src/Categories.js @@ -1,14 +1,16 @@ import React, { Component } from 'react'; -import { Breadcrumb, Dropdown, Header, Icon, Item, Menu, Segment, Input } from 'semantic-ui-react' +import { Breadcrumb, Container, Dropdown, Header, Icon, Item, Menu, Segment, Input } from 'semantic-ui-react' import { Link } from 'react-router-dom'; +import Admin from './Admin'; class Categories extends Component { render() { const data = this.props.data; + const user = this.props.user; const match = this.props.match; return ( -
+ Categories @@ -25,7 +27,8 @@ class Categories extends Component { )} -
+ {user.profile.lockout_admin && } + ); } } diff --git a/webclient/src/Category.js b/webclient/src/Category.js index bb74686..e26248f 100644 --- a/webclient/src/Category.js +++ b/webclient/src/Category.js @@ -13,36 +13,34 @@ class Category extends Component { ); return ( -
- - - Categories - - {category.name} - + + + Categories + + {category.name} + - - {category.tools.map((x, n) => - - - - {x.name} - - {user.profile.authorized_tools.includes(x.slug) ? - : - } - - Wiki ID: {x.wikiId} - - - )} - - -
+ + {category.tools.map((x, n) => + + + + {x.name} + + {user.profile.authorized_tools.includes(x.slug) ? + : + } + + Wiki ID: {x.wikiId} + + + )} + + ); } } diff --git a/webclient/src/Tool.js b/webclient/src/Tool.js index aaca7fe..6afede3 100644 --- a/webclient/src/Tool.js +++ b/webclient/src/Tool.js @@ -43,65 +43,63 @@ class Tool extends Component { const approved = user.profile.authorized_tools.includes(tool.slug); return ( -
- - - Categories - - {category.name} - - {tool.name} - + + + Categories + + {category.name} + + {tool.name} + - - - -

Status: {decodedStatus.msg}

-
- - -
- {approved || } -
-
+ + + +

Status: {decodedStatus.msg}

+
+ + +
+ {approved || } +
+
- - - - Cat - Meow - - - Dog - - - Bark - - - - Bird - Chrip - - -
+ + + + Cat + Meow + + + Dog + + + Bark + + + + Bird + Chrip + + +
-
Notes
-

{tool.notes}

-
-
-
+
Notes
+

{tool.notes}

+ + ); } }