layout logic bug fixes

This commit is contained in:
Brandon Rosage 2019-01-30 09:20:51 -06:00
parent 7c53411fcf
commit fce572823f
6 changed files with 31 additions and 45 deletions

View file

@ -4,6 +4,8 @@
{% assign icon_color = "#24292e" %}
{% endif %}
{% assign content = page.content | strip_newlines %}
{% assign posts_total = site.posts | size %}
{% assign user = site.github.owner %}

View file

@ -39,25 +39,29 @@
<div class="col-md-7 col-lg-8 col-xl-9 px-4 py-6 px-lg-7">
<div class="mx-auto" style="max-width: 900px;">
<div class="f4 {% if site.style == 'dark' %}text-white{% endif %} mb-6">
{% if page.is_post %}
<div class="f4 {% if site.style == 'dark' %}text-white{% endif %}">
<p class="f5"><a href="/" class="d-flex flex-items-center {% if site.style == 'dark' %}text-white{% endif %}">{% octicon chevron-left height:16 class:"mr-2 v-align-middle" fill:{{ icon_color }} aria-label:Home %}Home</a></p>
<h1 class="f00-light lh-condensed">{{ page.title }}</h1>
<p class="mb-5">Published {{ page.date | date: "%b %d, %Y"}}</p>
{% unless content == "" %}
<div class="f4 {% if site.style == 'dark' %}text-white{% endif %} mb-6">
{% if page.is_post %}
<div class="f4 {% if site.style == 'dark' %}text-white{% endif %}">
<p class="f5"><a href="/" class="d-flex flex-items-center {% if site.style == 'dark' %}text-white{% endif %}">{% octicon chevron-left height:16 class:"mr-2 v-align-middle" fill:{{ icon_color }} aria-label:Home %}Home</a></p>
<h1 class="f00-light lh-condensed">{{ page.title }}</h1>
<p class="mb-5">Published {{ page.date | date: "%b %d, %Y"}}</p>
{{ content }}
</div>
{% else %}
{{ content }}
</div>
{% else %}
{{ content }}
{% endif %}
</div>
{% endif %}
</div>
{% endunless %}
{% unless page.is_post %}
{% include projects.html %}
{% include interests.html %}
{% if site.topics %}
{% include interests.html %}
{% endif %}
{% unless post_size == 0 %}
{% unless posts_total == 0 %}
{% include thoughts.html %}
{% endunless %}
{% endunless %}

View file

@ -51,11 +51,13 @@
{% include projects.html %}
</div>
<div class="my-6">
{% include interests.html %}
</div>
{% if site.topics %}
<div class="my-6">
{% include interests.html %}
</div>
{% endif %}
{% unless post_size == 0 %}
{% unless posts_total == 0 %}
<div class="my-6">
{% include thoughts.html %}
</div>

View file

@ -1,5 +1,6 @@
---
title: "Welcome to Jekyll!"
published: false
---
**Hello world**, this is my first Jekyll blog post.

View file

@ -4,6 +4,8 @@
<!doctype html>
<html>
<head>
@ -44,12 +46,7 @@
<div class="col-md-7 col-lg-8 col-xl-9 px-4 py-6 px-lg-7">
<div class="mx-auto" style="max-width: 900px;">
<div class="f4 mb-6">
I have stuff to say here.
</div>
<h2 >My Projects</h2>
@ -171,7 +168,8 @@
</div>
<h2 >My Interests</h2>
<h2 >My Interests</h2>
<p class="f4 mb-4 text-gray">Topics that I want to learn more about.</p>
<div class="d-flex flex-wrap gutter-condensed mb-4">
@ -223,26 +221,6 @@
<h2 >My Thoughts</h2>
<p class="f4 mb-4 text-gray">Articles I've written.</p>
<div class="d-sm-flex flex-wrap gutter-condensed mb-4">
<div class="col-sm-6 col-md-12 col-lg-6 col-xl-4 mb-3">
<div class="height-full text-left border border-gray-light bg-white rounded-1 p-3">
<div class="d-flex flex-justify-between flex-items-start mb-1">
<h1 class="f4 lh-condensed mb-1">
<a href="/2019/01/29/hello-world/">
Welcome to Jekyll!
</a>
</h1>
</div>
<div class="text-gray mb-2 ws-normal">Jan 29, 2019</div>
</div>
</div>
</div>
</div>

View file

@ -1,4 +1,3 @@
---
layout: sidebar
---
I have stuff to say here.