Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Mar 9, 2021. It is now read-only.

space page initial construct #42

Merged
merged 6 commits into from
Oct 22, 2017
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
1. top banner component seperated out
2. top-banner included in events and space page
  • Loading branch information
M-ZubairAhmed committed Oct 22, 2017
commit 3192774455676843c985b2979f29e07fe4789c98
25 changes: 25 additions & 0 deletions components/top-banner.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import React from 'react';

export default props => (
<div>
<div>
<div className="top_banner_root">
<h1 className="top_banner_headline">{props.pageTitle}</h1>
<h2>{props.pageSubTitle}</h2>
</div>
<style jsx>{`
.top_banner_root {
background-color: #f4f7fb;
min-height: 200px;
text-align: center;
}
.top_banner_headline {
padding-top: 20px;
font-size: 4em;
color: #df1cb5;
font-weight: 900;
}
`}</style>
</div>
</div>
);
20 changes: 5 additions & 15 deletions pages/events.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import fetch from 'isomorphic-unfetch';
import { Card, Divider, Dimmer, Loader } from 'semantic-ui-react';

import publicPage from '../hocs/public-page';
import TopBanner from '../components/top-banner';
import { baseEventsURL, futureEventsURL, pastEventsURL } from '../utils/urls';
import RowEvent from '../components/row-events';

Expand Down Expand Up @@ -98,10 +99,10 @@ class Events extends React.Component {
render() {
return (
<div>
<div className="top_banner_root">
<h1 className="top_banner_headline">Events</h1>
<h2>Because you cannot change the world alone</h2>
</div>
<TopBanner
pageTitle="Events"
pageSubTitle="Because you cannot change the world alone"
/>
<main>
{this.state.loading ? (
<Dimmer active>
Expand All @@ -124,17 +125,6 @@ class Events extends React.Component {
align-items: center;
flex-direction: column;
}
.top_banner_root {
background-color: #f4f7fb;
min-height: 200px;
text-align: center;
}
.top_banner_headline {
padding-top: 20px;
font-size: 4em;
color: #df1cb5;
font-weight: 900;
}
`}</style>
</div>
);
Expand Down
18 changes: 11 additions & 7 deletions pages/space.js
Original file line number Diff line number Diff line change
@@ -1,19 +1,23 @@
import React from 'react';

import Icon from '../components/icon';
import TopBanner from '../components/top-banner';
import publicPage from '../hocs/public-page';

export default publicPage(() => (
<div>
<main>
<Icon />
<h3>Under Construction, Coming Soon!...</h3>
</main>
<TopBanner
pageTitle="Space"
pageSubTitle="Physical spaces for collaboration, peer-learning and self-learning"
/>
<main>llll</main>
<style jsx>{`
main {
background-color: #ffffff;
padding-top: 30px;
padding-bottom: 30px;
padding-left: 30px;
padding-right: 30px;
min-height: calc(100vh - 70px);
background: #f4f7fb;
color: #314159;
display: flex;
justify-content: center;
align-items: center;
Expand Down