-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Peter Macdonald <[email protected]>
- Loading branch information
1 parent
81973cf
commit 4a8f86b
Showing
7 changed files
with
18 additions
and
8 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
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
File renamed without changes.
17 changes: 13 additions & 4 deletions
17
...ponents/QuotesCardComponent/DevQuotes.tsx → .../components/QuotesComponent/DevQuotes.tsx
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,14 +1,23 @@ | ||
import { Typography } from '@material-ui/core'; | ||
import { Typography, makeStyles } from '@material-ui/core'; | ||
import React from 'react'; | ||
import { quotes } from '../../quotes'; | ||
|
||
const useStyles = makeStyles((theme) => ({ | ||
footer: { | ||
width: '100%', | ||
textAlign: 'center', | ||
padding: theme.spacing(2), | ||
}, | ||
})); | ||
|
||
export const DevQuote = () => { | ||
const classes = useStyles(); | ||
const randomQuote = quotes[Math.floor(Math.random() * quotes.length)]; | ||
|
||
return ( | ||
<> | ||
<footer className={classes.footer}> | ||
<Typography variant="h6">{randomQuote.text}</Typography> | ||
<Typography variant="subtitle2">{randomQuote.author}</Typography> | ||
</> | ||
</footer> | ||
); | ||
}; | ||
}; |
File renamed without changes.
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 +1 @@ | ||
export * from './components/QuotesCardComponent'; | ||
export * from './components/QuotesComponent'; |
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