aboutsummaryrefslogtreecommitdiff
path: root/src/index.tsx
diff options
context:
space:
mode:
authorEugene Sokolov <eug-vs@keemail.me>2020-06-25 14:41:14 +0300
committerGitHub <noreply@github.com>2020-06-25 14:41:14 +0300
commit9dfc98d5014f91afb45ad4eebbe9f0f704ddfdf5 (patch)
treeb5a47cce16b224dd74625db72f721e5e797a1611 /src/index.tsx
parent190916329611704b1035158363302f09152794ee (diff)
parenta3afe917442fb29627aa9deade1baefbea9a60c5 (diff)
downloadwhich-ui-9dfc98d5014f91afb45ad4eebbe9f0f704ddfdf5.tar.gz
Merge pull request #41 from which-ecosystem/votes
Votes
Diffstat (limited to 'src/index.tsx')
-rw-r--r--src/index.tsx10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/index.tsx b/src/index.tsx
index 1777e90..50b19f7 100644
--- a/src/index.tsx
+++ b/src/index.tsx
@@ -9,11 +9,12 @@ import { CssBaseline } from '@material-ui/core';
import teal from '@material-ui/core/colors/teal';
import 'typeface-roboto';
+import { User } from 'which-types';
import Header from './components/Header/Header';
import ProfilePage from './pages/ProfilePage/ProfilePage';
import FeedPage from './pages/FeedPage/FeedPage';
import AuthPage from './pages/AuthPage/AuthPage';
-import { User, Page } from './types';
+import { Page } from './types';
import { get, post } from './requests';
import ScrollTopArrow from './components/ScrollTopArrow/ScrollTopArrow';
@@ -21,7 +22,8 @@ import ScrollTopArrow from './components/ScrollTopArrow/ScrollTopArrow';
const theme = createMuiTheme({
palette: {
primary: {
- main: teal[700]
+ main: teal[700],
+ light: teal[100]
}
}
});
@@ -53,10 +55,10 @@ const App: React.FC = () => {
}
};
- const logIn = (name: string, password: string): Promise<boolean> => {
+ const logIn = (username: string, password: string): Promise<boolean> => {
return post('/authentication', {
strategy: 'local',
- name,
+ username,
password
}).then(response => {
const me = response.data.user;