From ece83848ab1957f65dcc379e63564d2290c73a6a Mon Sep 17 00:00:00 2001 From: Kyle Mathews Date: Thu, 11 Jun 2015 16:41:30 -0700 Subject: [PATCH] Basics are in place --- .gitignore | 1 + app.coffee | 2 + components/ReadNext.cjsx | 50 ++++++++ config.toml | 2 + css/styles.css | 7 ++ css/zenburn.css | 150 +++++++++++++++++++++++ html.cjsx | 41 +++++++ pages/2015-05-01-hello-world/index.md | 17 +++ pages/2015-05-06-my-second-post/index.md | 11 ++ pages/2015-05-28-hi-folks/index.md | 19 +++ pages/app.cjsx | 57 +++++++++ pages/favicon.ico | Bin 0 -> 198 bytes pages/index.cjsx | 49 ++++++++ pages/kyle-round-small-pantheon.jpg | Bin 0 -> 20276 bytes pages/robots.txt | 2 + wrappers/html.cjsx | 11 ++ wrappers/md.cjsx | 47 +++++++ 17 files changed, 466 insertions(+) create mode 100644 .gitignore create mode 100644 app.coffee create mode 100644 components/ReadNext.cjsx create mode 100644 config.toml create mode 100644 css/styles.css create mode 100644 css/zenburn.css create mode 100644 html.cjsx create mode 100644 pages/2015-05-01-hello-world/index.md create mode 100644 pages/2015-05-06-my-second-post/index.md create mode 100644 pages/2015-05-28-hi-folks/index.md create mode 100644 pages/app.cjsx create mode 100644 pages/favicon.ico create mode 100644 pages/index.cjsx create mode 100644 pages/kyle-round-small-pantheon.jpg create mode 100644 pages/robots.txt create mode 100644 wrappers/html.cjsx create mode 100644 wrappers/md.cjsx diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c2658d7 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +node_modules/ diff --git a/app.coffee b/app.coffee new file mode 100644 index 0000000..0e06299 --- /dev/null +++ b/app.coffee @@ -0,0 +1,2 @@ +exports.context = -> + return require.context './pages', true diff --git a/components/ReadNext.cjsx b/components/ReadNext.cjsx new file mode 100644 index 0000000..4d49aeb --- /dev/null +++ b/components/ReadNext.cjsx @@ -0,0 +1,50 @@ +React = require 'react' +Router = require 'react-router' +{Link} = Router +prune = require 'underscore.string/prune' +includes = require 'underscore.string/include' +find = require 'lodash/collection/find' + +module.exports = React.createClass + + render: -> + {rhythm, fontSizeToMS} = @props.typography + readNext = @props.post.readNext + if readNext? + nextPost = find @props.pages, (page) -> includes page.path, readNext.slice(1, -1) + unless nextPost +