-
Notifications
You must be signed in to change notification settings - Fork 97
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
20 changed files
with
242 additions
and
147 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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
/** | ||
* Created by vaibhav on 2/4/18 | ||
*/ | ||
import React from 'react' | ||
import PropTypes from 'prop-types' | ||
import { ContactPageTemplate } from '../../templates/contact-page' | ||
|
||
const ContactPagePreview = ({ entry, getAsset }) => { | ||
const entryContacts = entry.getIn(['data', 'contacts']); | ||
const contacts = entryContacts ? entryContacts.toJS() : []; | ||
|
||
return ( | ||
<ContactPageTemplate | ||
title={entry.getIn(['data', 'title'])} | ||
subtitle={entry.getIn(['data', 'subtitle'])} | ||
meta_title={entry.getIn(['data', 'meta_title'])} | ||
meta_description={entry.getIn(['data', 'meta_description'])} | ||
contacts={contacts} | ||
/> | ||
) | ||
}; | ||
|
||
ContactPagePreview.propTypes = { | ||
entry: PropTypes.shape({ | ||
getIn: PropTypes.func, | ||
}), | ||
getAsset: PropTypes.func, | ||
}; | ||
|
||
export default ContactPagePreview; |
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 |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/** | ||
* Created by vaibhav on 2/4/18 | ||
*/ | ||
import React from 'react'; | ||
import PropTypes from 'prop-types'; | ||
|
||
const Contact = ({email, description}) => { | ||
return ( | ||
<div | ||
className="content" | ||
style={{border: '1px solid #eaecee', padding: '2em 4em'}}> | ||
<p><a href={`mailto:${email}`}>{email}</a></p> | ||
<p>{description}</p> | ||
</div> | ||
); | ||
}; | ||
|
||
Contact.propTypes = { | ||
email: PropTypes.string.isRequired, | ||
description: PropTypes.string, | ||
}; | ||
|
||
|
||
export default Contact |
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 |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/** | ||
* Created by vaibhav on 2/4/18 | ||
*/ | ||
import React from 'react' | ||
import Link from 'gatsby-link' | ||
|
||
const PostCard = ({posts}) => { | ||
return ( | ||
<div className="container"> | ||
{posts | ||
.filter(post => post.node.frontmatter.templateKey === 'article-page') | ||
.map(({node: post}) => ( | ||
<div | ||
className="content" | ||
style={{border: '1px solid #eaecee', padding: '2em 4em'}} | ||
key={post.id} | ||
> | ||
<p> | ||
<Link className="has-text-primary" to={post.fields.slug}> | ||
{post.frontmatter.title} | ||
</Link> | ||
<span> • </span> | ||
<small>{post.frontmatter.date}</small> | ||
</p> | ||
<p> | ||
{post.excerpt} | ||
<br/> | ||
<br/> | ||
<Link className="button is-small" to={post.fields.slug}> | ||
Keep Reading → | ||
</Link> | ||
</p> | ||
</div> | ||
))} | ||
</div> | ||
); | ||
}; | ||
|
||
export default PostCard |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
templateKey: 'contact-page' | ||
title: Contact Us | ||
subtitle: We'd Love To Help You, Feel Free To Drop A Mail | ||
meta_title: Contact Us | Gatsby Starter Business | ||
meta_description: >- | ||
Cum sociis natoque penatibus et magnis dis parturient montes, nascetur | ||
ridiculus mus. Aenean eu leo quam. Pellentesque ornare sem lacinia quam | ||
venenatis vestibulum. Sed posuere consectetur est at lobortis. Cras mattis | ||
consectetur purus sit amet fermentum. | ||
contacts: | ||
- email: support@lorem.com | ||
description: >- | ||
Donec scelerisque magna nec condimentum porttitor. Aliquam vel diam sed diam luctus pretium. | ||
Sed quis egestas libero. Vestibulum nec venenatis ligula. | ||
- email: contact@lorem.com | ||
description: >- | ||
Fusce porttitor vulputate enim, nec blandit magna gravida et. Etiam et dignissim ligula. | ||
Lorem ipsum dolor sit amet, consectetur adipiscing elit. | ||
--- |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.