From e69190abb09661caa19fa3905a0d8f3b7e72648b Mon Sep 17 00:00:00 2001 From: crupest Date: Mon, 13 Jul 2020 20:59:52 +0800 Subject: Move front end to a submodule. --- Timeline/ClientApp/src/app/admin/Admin.tsx | 78 ------------------------------ 1 file changed, 78 deletions(-) delete mode 100644 Timeline/ClientApp/src/app/admin/Admin.tsx (limited to 'Timeline/ClientApp/src/app/admin/Admin.tsx') diff --git a/Timeline/ClientApp/src/app/admin/Admin.tsx b/Timeline/ClientApp/src/app/admin/Admin.tsx deleted file mode 100644 index 9e7d592f..00000000 --- a/Timeline/ClientApp/src/app/admin/Admin.tsx +++ /dev/null @@ -1,78 +0,0 @@ -import React, { Fragment } from 'react'; -import { Nav, NavItem, NavLink } from 'reactstrap'; -import { - Redirect, - Route, - Switch, - useRouteMatch, - useHistory -} from 'react-router'; -import classnames from 'classnames'; - -import AppBar from '../common/AppBar'; -import UserAdmin from './UserAdmin'; - -import { UserWithToken } from '../data/user'; - -interface AdminProps { - user: UserWithToken; -} - -const Admin: React.FC = props => { - const match = useRouteMatch(); - const history = useHistory(); - type TabNames = 'users' | 'more'; - - const tabName = history.location.pathname.replace(match.path + '/', ''); - - function toggle(newTab: TabNames): void { - history.push(`${match.url}/${newTab}`); - } - - const createRoute = ( - name: string, - body: React.ReactNode - ): React.ReactNode => { - return ( - - -
- - {body} - - ); - }; - - return ( - - - - {createRoute('users', )} - {createRoute('more',
More Page Works
)} -
-
- ); -}; - -export default Admin; -- cgit v1.2.3