Quellcode durchsuchen

Add blog and example posts to the website

Artur Paikin vor 8 Jahren
Ursprung
Commit
1b1ae9238e

+ 8 - 0
website/src/_posts/0.6.0.md

@@ -0,0 +1,8 @@
+---
+title: Uppy 0.6.0 Released
+date: 2016-06-04 10:00:00
+---
+
+> Hi! We released Uppy 0.6.0. It was mainly a refactor release, but nonetheless very important, so we are proud.
+
+<!-- more -->

+ 0 - 13
website/src/_posts/hello-world.md

@@ -1,13 +0,0 @@
----
-title: Hello, world
-date: 2015-11-27 15:02:14
-tags:
----
-
-Hello, world! We're building a new open source javascript file uploader with integrations for ALL THE THINGS.
-
-It's nowhere near finished yet, but that also means it's not to late to get involved and help steer this project
-
-into a direction of your liking!
-
-Shoot us a [tweet](https://twitter.com/uppy_io) if you're interested!

+ 6 - 0
website/src/_posts/uppy-begins.md

@@ -0,0 +1,6 @@
+---
+title: Uppy Begins
+date: 2015-10-26 10:00:00
+---
+
+> On November 26 we gathered in Skype and that’s how Uppy was born. We didn’t know it would be called Uppy yet.

+ 5 - 1
website/themes/uppy/layout/layout.ejs

@@ -33,7 +33,11 @@
       </header>
 
       <main class="MainContent js-MainContent" id="main">
-        <%- body %>
+        <% if (page.blog_index) { %>
+          <%- partial('partials/blog') %>
+        <% } else { %>
+          <%- body %>
+        <% } %>
       </main>
 
       <% if (!isIndex) { %>

+ 10 - 15
website/themes/uppy/layout/partials/blog.ejs

@@ -1,16 +1,11 @@
-<div class="sidebar">
-  <ul class="main-menu">
-      <%- partial('partials/main_menu') %>
-  </ul>
-</div>
-<div class="content blog">
-<h1 style="text-align: center; margin-bottom:.5em">The <%- config.title %> Blog</h1>
-<% site.posts.sort('date', -1).each(function (post) { %>
-    <div class="post">
-        <h2><a href="/<%- post.path %>"><%- post.title %></a></h2>
-        <h4><%- post.date.format('MMM D[,] YYYY') %></h4>
-        <div><%- post.excerpt %></div>
-        <a href="/<%- post.path %>">... continue reading</a>
-    </div>
-<% }) %>
+<div class="Content js-Content">
+  <h1 style="text-align: center; margin-bottom:.5em">The <%- config.title %> Blog</h1>
+  <% site.posts.sort('date', -1).each(function (post) { %>
+      <div class="post">
+          <h2><a href="/<%- post.path %>"><%- post.title %></a></h2>
+          <h4><%- post.date.format('MMM D[,] YYYY') %></h4>
+          <div><%- post.excerpt %></div>
+          <a href="/<%- post.path %>">... continue reading</a>
+      </div>
+  <% }) %>
 </div>

+ 2 - 5
website/themes/uppy/layout/post.ejs

@@ -1,7 +1,4 @@
-<div class="sidebar blog">
-    <ul class="main-menu">
-        <%- partial('partials/main_menu') %>
-    </ul>
+<div class="Sidebar js-Sidebar">
     <div class="list">
         <h2>Recent Posts</h2>
         <ul>
@@ -13,7 +10,7 @@
         </ul>
     </div>
 </div>
-<div class="content blog post">
+<div class="Content js-Content">
     <h1><%- page.title %></h1>
     <h4><%- page.date.format('MMM D[,] YYYY') %></h4>
     <%- page.content %>