Skip to content

Commit

Permalink
remove logout from menu and oauth/login components
Browse files Browse the repository at this point in the history
  • Loading branch information
celloman committed Jun 14, 2021
1 parent f6b018e commit 70f3078
Show file tree
Hide file tree
Showing 8 changed files with 1 addition and 94 deletions.
2 changes: 0 additions & 2 deletions src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ const App = () => {
<>
<Switch>
<Route exact path="/" component={DashboardContainer} />
{/* <Route exact path="/login" component={LoginContainer} /> */}
{/* <Route exact path="/register" component={RegisterContainer} /> */}
<Route exact path="/contracts/:uuid" component={ContractContainer} />
<Route exact path="/contracts" component={ContractListContainer} />
<Route exact path="/scopes/:scopeUuid/history/:uuid" component={ScopeHistoryContainer} />
Expand Down
1 change: 0 additions & 1 deletion src/Constant/identity.ts

This file was deleted.

25 changes: 0 additions & 25 deletions src/actions/identity-actions.ts

This file was deleted.

12 changes: 1 addition & 11 deletions src/components/Layout/Menu/MenuContainer.tsx
Original file line number Diff line number Diff line change
@@ -1,30 +1,20 @@
import React from 'react';
import { useDispatch } from 'react-redux';
import { withRouter } from 'react-router-dom';
import { logout } from 'actions/identity-actions';
import { Menu, MenuLink, MenuLinkText, MenuListItem } from './index';
import { Menu, MenuLink } from './index';
import { Location } from 'history';

type MenuContainerProps = {
location: Location;
}

const MenuContainer = ({ location }) => {
const dispatch = useDispatch();
const handleLogout = () => {
dispatch(logout());
};

return (
<Menu>
<ul>
<MenuLink pathname="/" location={location} text="Dashboard" />
<MenuLink pathname="/contracts" location={location} text="Contracts" />
<MenuLink pathname="/scopes" location={location} text="Scopes" />
<MenuLink pathname="/key-management" location={location} text="Key Management" />
<MenuListItem>
<MenuLinkText onClick={handleLogout}>Logout</MenuLinkText>
</MenuListItem>
</ul>
</Menu>
);
Expand Down
34 changes: 0 additions & 34 deletions src/components/Login/LoginContainer.tsx

This file was deleted.

1 change: 0 additions & 1 deletion src/components/Login/index.ts

This file was deleted.

19 changes: 0 additions & 19 deletions src/components/OAuth/OAuthCallback.tsx

This file was deleted.

1 change: 0 additions & 1 deletion src/components/OAuth/index.ts

This file was deleted.

0 comments on commit 70f3078

Please sign in to comment.