-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* added linter config files * fixed styling (linter errors) * removed redundant types
- Loading branch information
1 parent
ebe2eca
commit 17529d0
Showing
15 changed files
with
210 additions
and
65 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
node_modules | ||
dist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"root": true, | ||
"parser": "@typescript-eslint/parser", | ||
"plugins": ["@typescript-eslint", "prettier"], | ||
|
||
"extends": [ | ||
"eslint:recommended", | ||
"plugin:@typescript-eslint/eslint-recommended", | ||
"plugin:@typescript-eslint/recommended" | ||
], | ||
"rules": { | ||
"no-console": 1, // Means warning, | ||
"prettier/prettier": "error" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,12 @@ | ||
import React, { FC, ReactElement } from 'react' | ||
import React, { FC, ReactElement } from 'react'; | ||
import { NavLink } from 'react-router-dom'; | ||
|
||
export const About: FC = (): ReactElement => { | ||
|
||
console.log('about...') | ||
return ( | ||
<div> | ||
About meeeeee | ||
<NavLink to="/">Go back to Home</NavLink> | ||
</div> | ||
); | ||
} | ||
console.log('about...'); | ||
return ( | ||
<div> | ||
About meeeeee | ||
<NavLink to="/">Go back to Home</NavLink> | ||
</div> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,6 @@ | ||
import { FC, ReactElement } from 'react' | ||
import { FC, ReactElement } from 'react'; | ||
import WelcomeScreen from './WelcomeScreen/WelcomeScreen'; | ||
|
||
export const Home: FC = (): ReactElement => { | ||
|
||
return ( | ||
<WelcomeScreen /> | ||
) | ||
} | ||
return <WelcomeScreen />; | ||
}; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import React from 'react'; | ||
import styled from '@emotion/styled'; | ||
import { FC, ReactElement } from 'react'; | ||
import { BottomNavigation, BottomNavigationAction } from '@material-ui/core'; | ||
import HomeIcon from '@material-ui/icons/Home'; | ||
import AddCircleIcon from '@material-ui/icons/Add'; | ||
import PersonIcon from '@material-ui/icons/Person'; | ||
import MessageIcon from '@material-ui/icons/Message'; | ||
import { Link } from 'react-router-dom'; | ||
|
||
const StyledBottomNavigation = styled(BottomNavigation)` | ||
&& { | ||
background-color: #f9f9f9; | ||
bottom: 0; | ||
position: fixed; | ||
width: 100%; | ||
}, | ||
`; | ||
|
||
export const BottomNavBar = (): ReactElement => { | ||
const [value, setValue] = React.useState(0); | ||
|
||
return ( | ||
<StyledBottomNavigation | ||
value={value} | ||
onChange={(event, newValue) => { | ||
setValue(newValue); | ||
}} | ||
showLabels | ||
> | ||
<BottomNavigationAction label="Start" icon={<HomeIcon />} component={Link} to="/" /> | ||
<BottomNavigationAction label="Stwórz" icon={<AddCircleIcon />} component={Link} to="/create" /> | ||
<BottomNavigationAction label="Czat" icon={<MessageIcon />} component={Link} to="/chat" /> | ||
<BottomNavigationAction label="Profil" icon={<PersonIcon />} component={Link} to="/profile" /> | ||
</StyledBottomNavigation> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
import { FC, ReactElement } from 'react'; | ||
import AppBar from '@material-ui/core/AppBar'; | ||
import Toolbar from '@material-ui/core/Toolbar'; | ||
import { Search } from '../Search'; | ||
import { StyledAppName } from '../../styles/StyledAppName'; | ||
import styled from '@emotion/styled'; | ||
|
||
export const StyledDiv = styled.div` | ||
display: block; | ||
flex-grow: 1; | ||
padding-right: 2em; | ||
`; | ||
|
||
export const TopNavBar = (): ReactElement => { | ||
return ( | ||
<AppBar position="sticky"> | ||
<Toolbar> | ||
<StyledDiv> | ||
<StyledAppName> | ||
<span>Fisz</span> | ||
<span>QI</span> | ||
</StyledAppName> | ||
</StyledDiv> | ||
<Search /> | ||
</Toolbar> | ||
</AppBar> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
export default function NotFound() { | ||
return ( | ||
<div> | ||
<h1>Sorry, can’t find that.</h1> | ||
</div> | ||
); | ||
} | ||
return ( | ||
<div> | ||
<h1>Sorry, can’t find that.</h1> | ||
</div> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
import { ReactElement } from 'react'; | ||
import SearchIcon from '@material-ui/icons/Search'; | ||
import InputBase from '@material-ui/core/InputBase'; | ||
import IconButton from '@material-ui/core/IconButton'; | ||
import Paper from '@material-ui/core/Paper'; | ||
import styled from '@emotion/styled'; | ||
|
||
const StyledIconButton = styled(IconButton)` | ||
padding: 0; | ||
`; | ||
const StyledIconButtonRoot = styled.span` | ||
& .MuiIconButton-root { | ||
padding: 6px; | ||
} | ||
`; | ||
|
||
const StyledSearchIcon = styled(SearchIcon)` | ||
color: #fff; | ||
padding-right: -20px; | ||
`; | ||
|
||
const StyledInputBase = styled(InputBase)` | ||
color: #fff; | ||
border-radius: 7px; | ||
padding-left: 1em; | ||
& .MuiInputBase-input { | ||
color: rgba(255, 255, 255, 0.9); | ||
} | ||
`; | ||
|
||
const StyledPaper = styled(Paper)` | ||
display: 'flex'; | ||
alignitems: 'center'; | ||
width: 400; | ||
`; | ||
|
||
const StyledMuiPaperRoot = styled.span` | ||
& .MuiPaper-root { | ||
background-color: rgba(255, 255, 255, 0.1); | ||
:hover { | ||
background-color: rgba(255, 255, 255, 0.2); | ||
} | ||
} | ||
display: flex; | ||
justify-items: center; | ||
`; | ||
|
||
export const Search = (): ReactElement => { | ||
return ( | ||
<div> | ||
<StyledMuiPaperRoot> | ||
<StyledPaper component="form" elevation={0}> | ||
<StyledInputBase placeholder="Szukaj..." /> | ||
<StyledIconButtonRoot> | ||
<StyledIconButton type="submit" aria-label="search"> | ||
<StyledSearchIcon /> | ||
</StyledIconButton> | ||
</StyledIconButtonRoot> | ||
</StyledPaper> | ||
</StyledMuiPaperRoot> | ||
</div> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import styled from '@emotion/styled'; | ||
|
||
export const StyledAppName = styled.div` | ||
font-family: righteous; | ||
font-size: 2.5em; | ||
& > span:first-of-type { | ||
color: #ffffff; | ||
} | ||
& > span:last-of-type { | ||
color: #606060; | ||
} | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters