2016-03-24 21:10:15 +00:00
|
|
|
/**
|
|
|
|
* Copyright (c) 2015-present, Facebook, Inc.
|
|
|
|
* All rights reserved.
|
|
|
|
*
|
|
|
|
* This source code is licensed under the BSD-style license found in the
|
|
|
|
* LICENSE file in the root directory of this source tree. An additional grant
|
|
|
|
* of patent rights can be found in the PATENTS file in the same directory.
|
|
|
|
*
|
|
|
|
* @providesModule BlogPostLayout
|
|
|
|
*/
|
|
|
|
|
|
|
|
'use strict';
|
|
|
|
|
|
|
|
var React = require('React');
|
|
|
|
var Site = require('Site');
|
2016-11-02 12:31:52 +00:00
|
|
|
var Hero = require('Hero');
|
|
|
|
var MetadataBlog = require('MetadataBlog');
|
|
|
|
var BlogPost = require('BlogPost');
|
|
|
|
var BlogPostHeader = require('BlogPostHeader');
|
|
|
|
var Marked = require('Marked');
|
2016-03-24 21:10:15 +00:00
|
|
|
|
|
|
|
var BlogPostLayout = React.createClass({
|
|
|
|
render: function() {
|
|
|
|
return (
|
|
|
|
<Site
|
|
|
|
section="blog"
|
|
|
|
title={this.props.metadata.title}
|
2016-11-02 12:31:52 +00:00
|
|
|
description={this.props.metadata.excerpt}
|
2016-08-25 18:02:27 +00:00
|
|
|
path={'blog/' + this.props.metadata.path}
|
2016-08-30 06:08:50 +00:00
|
|
|
author={this.props.metadata.author}
|
|
|
|
authorTwitter={this.props.metadata.authorTwitter}
|
2016-11-02 12:31:52 +00:00
|
|
|
image={this.props.metadata.hero ? 'https://facebook.github.io' + this.props.metadata.hero : 'https://facebook.github.io/react-native/img/opengraph.png' }
|
2016-08-25 18:02:27 +00:00
|
|
|
>
|
2016-11-02 12:31:52 +00:00
|
|
|
<Hero title="React Native Blog" subtitle="Stay up-to-date with the latest React Native news and events." />
|
2016-03-24 21:10:15 +00:00
|
|
|
<section className="content wrap documentationContent">
|
2016-11-02 12:31:52 +00:00
|
|
|
<BlogPost
|
|
|
|
post={this.props.metadata}
|
|
|
|
content={this.props.children} />
|
2016-03-24 21:10:15 +00:00
|
|
|
</section>
|
|
|
|
</Site>
|
|
|
|
);
|
|
|
|
}
|
|
|
|
});
|
|
|
|
|
|
|
|
module.exports = BlogPostLayout;
|