Add page sections to front page
This commit is contained in:
+1
-1
@@ -17,7 +17,7 @@ body {
|
||||
}
|
||||
|
||||
body {
|
||||
padding: 0 1rem;
|
||||
padding: 0;
|
||||
margin: auto !important;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
.front-page {
|
||||
display: flex;
|
||||
flex-flow: row wrap;
|
||||
flex-flow: column wrap;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
|
||||
@@ -7,6 +7,8 @@ import { StaticContext } from "../../server/StaticContext";
|
||||
|
||||
// @ts-ignore
|
||||
import * as BeerImage from "../../assets/img/beer.jpeg";
|
||||
import PageSection from "../../components/PageSection";
|
||||
import { BackgroundColor as PageSectionColor } from "../../components/PageSection/PageSection";
|
||||
|
||||
interface FrontPageProps {
|
||||
staticContext: StaticContext;
|
||||
@@ -60,14 +62,20 @@ class FrontPage extends React.Component<FrontPageProps, FrontPageState> {
|
||||
const { events } = this.state;
|
||||
return (
|
||||
<div className="front-page">
|
||||
{ events.map(event => (
|
||||
<Card
|
||||
title={event.title}
|
||||
text={event.description}
|
||||
key={event.id}
|
||||
image={BeerImage}
|
||||
/>
|
||||
))}
|
||||
<PageSection backgroundColor={PageSectionColor.DarkBlue}>
|
||||
{events.map(event => (
|
||||
<Card
|
||||
title={event.title}
|
||||
text={event.description}
|
||||
key={event.id}
|
||||
image={BeerImage}
|
||||
/>
|
||||
))}
|
||||
</PageSection>
|
||||
<PageSection backgroundColor={PageSectionColor.White}>
|
||||
Huumori huiskaus
|
||||
</PageSection>
|
||||
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user