aboutsummaryrefslogtreecommitdiff
path: root/src/index.tsx
diff options
context:
space:
mode:
authorilyayudovin <46264063+ilyayudovin@users.noreply.github.com>2020-06-07 20:21:59 +0300
committerGitHub <noreply@github.com>2020-06-07 20:21:59 +0300
commitfa3f95443c47541e9a7061ea1d3fd079c40b1fa8 (patch)
treeff56c75b023fa166781275adfd65ea917d275968 /src/index.tsx
parentb8b848dfd6e3843c6b455c8344320dcd187b72da (diff)
parent98442762c1bbdf4e4aff317ca8ec660b6817418f (diff)
downloadwhich-ui-fa3f95443c47541e9a7061ea1d3fd079c40b1fa8.tar.gz
Merge pull request #12 from ilyayudovin/feed
Add Feed and fucntionality for creating polls
Diffstat (limited to 'src/index.tsx')
-rw-r--r--src/index.tsx25
1 files changed, 21 insertions, 4 deletions
diff --git a/src/index.tsx b/src/index.tsx
index 48bad48..775c514 100644
--- a/src/index.tsx
+++ b/src/index.tsx
@@ -7,7 +7,7 @@ import teal from '@material-ui/core/colors/teal';
import 'typeface-roboto';
import Header from './Header/Header';
-import PollCard from './PollCard/PollCard';
+import Feed from './Feed/Feed';
const theme = createMuiTheme({
palette: {
@@ -17,7 +17,7 @@ const theme = createMuiTheme({
}
});
-const pollProps = {
+const polls = [{
author: {
name: 'John Doe',
avatarUrl: ''
@@ -34,7 +34,24 @@ const pollProps = {
votes: 17
}
}
-};
+}, {
+ author: {
+ name: 'John Doe',
+ avatarUrl: ''
+ },
+ contents: {
+ left: {
+ // eslint-disable-next-line max-len
+ url: 'https://images.pexels.com/photos/556666/pexels-photo-556666.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500',
+ votes: 15
+ },
+ right: {
+ // eslint-disable-next-line max-len
+ url: 'https://cdn.psychologytoday.com/sites/default/files/field_blog_entry_images/2019-06/pexels-photo-556667.jpeg',
+ votes: 17
+ }
+ }
+}];
const App: React.FC = () => {
@@ -44,7 +61,7 @@ const App: React.FC = () => {
<ThemeProvider theme={theme}>
<CssBaseline />
<Header setPage={setPage} />
- <PollCard author={pollProps.author} contents={pollProps.contents} />
+ <Feed polls={polls} />
<h1> We are on page {page}! </h1>
</ThemeProvider>
);