Restructuring and layout fixes

This commit is contained in:
Moris Zen
2018-07-07 00:07:28 +02:00
parent 3ec8275596
commit 81ab174b02
4 changed files with 129 additions and 127 deletions

View File

@@ -11,7 +11,6 @@ let menuClasses =
class Header extends Component { class Header extends Component {
render() { render() {
return ( return (
<div>
<header className="bg-saburly-indigo"> <header className="bg-saburly-indigo">
<nav className="container mx-auto flex items-center justify-between lg:p-6 p-4"> <nav className="container mx-auto flex items-center justify-between lg:p-6 p-4">
<Link to="/"> <Link to="/">
@@ -50,7 +49,6 @@ class Header extends Component {
</div> </div>
</nav> </nav>
</header> </header>
</div>
) )
} }
} }

View File

@@ -10,17 +10,19 @@ const PageIntro = ({ ...props }) => (
<SectionIntro <SectionIntro
light light
intro={props.intro} intro={props.intro}
classes="lg:text-left lg:max-w-xs content-center" classes={`lg:text-left lg:max-w-sm content-center ${
props.sectionClasses
}`}
headline={props.headline} headline={props.headline}
text={props.text} text={props.text}
/> />
{ props.button && {props.button && (
<Button <Button
text={props.buttonText} text={props.buttonText}
url={props.url} url={props.url}
classes={props.buttonClasses} classes={props.buttonClasses}
/> />
} )}
</div> </div>
{props.image && ( {props.image && (
<img <img

View File

@@ -16,9 +16,10 @@ import LogoKinnarps from '../images/logo-kinnarps-color.svg'
import LogoCoor from '../images/logo-coor-color.svg' import LogoCoor from '../images/logo-coor-color.svg'
const IndexPage = ({ ...props }) => ( const IndexPage = ({ ...props }) => (
<main> <div>
<PageIntro button buttonText="Let's Build Together" buttonUrl="/proposal" buttonClasses="text-white shadow-md hover:shadow-lg rounded-full mt-4 font-light btn-saburly-green mb-20" intro="Welcome To Saburly" headline="We build the right software for your needs" text="We are a team of creative, open minded, skilled and passionate engineers that ship success every day" image={ImgIntro} /> <PageIntro button buttonText="Let's Build Together" url="/proposal" buttonClasses="text-white shadow-md hover:shadow-lg rounded-full mt-4 font-light btn-saburly-green mb-20" intro="Welcome To Saburly" headline="We build the right software for your needs" text="We are a team of creative, open minded, skilled and passionate engineers that ship success daily" image={ImgIntro} />
<main>
<section className="container mx-auto text-center my-12 p-4"> <section className="container mx-auto text-center my-12 p-4">
<SectionIntro <SectionIntro
intro="Services" intro="Services"
@@ -140,6 +141,7 @@ const IndexPage = ({ ...props }) => (
/> />
</section> </section>
</main> </main>
</div>
) )
export const query = graphql` export const query = graphql`

View File

@@ -9,10 +9,10 @@ class Blog extends Component {
const data = this.props.data const data = this.props.data
return ( return (
<div> <div>
<PageIntro intro="Blog" headline="Occasionally we find the time to have fun and publish" /> <PageIntro intro="Blog" headline="Occasionally we find the time to have fun and publish" sectionClasses="mb-16 lg:mb-4" />
<div className="container mx-auto p-4 w-full md:flex md:flex-wrap items-stretch w-full"> <div className="container mx-auto p-4 w-full md:flex md:flex-wrap items-stretch w-full">
{data.allWordpressPost.edges.map(({ node }) => ( {data.allWordpressPost.edges.map(({ node }) => (
<div key={node.id} className="md:w-1/2 p-2"> <div key={node.id} className="mt-4 md:w-1/2 p-2">
<Card <Card
url={`blog/${node.slug}`} url={`blog/${node.slug}`}
title={node.title} title={node.title}