Allow Markdown for header.image.caption

- Simplify and remove extra variables by condensing into one
This commit is contained in:
Michael Rose 2016-02-25 08:15:54 -05:00
parent 63f8c36348
commit acd8720126
7 changed files with 7 additions and 19 deletions

View file

@ -24,8 +24,8 @@ layout: compress
"{{ page.header.image | prepend: "/images/" | prepend: absurl }}" "{{ page.header.image | prepend: "/images/" | prepend: absurl }}"
{% endif %} {% endif %}
alt="{{ page.title }}"> alt="{{ page.title }}">
{% if page.header.credit %} {% if page.header.caption %}
<span class="image-credit">Photo Credit: <a href="{{ page.header.credit.url }}">{{ page.header.credit.caption }}</a></span> <span class="image-caption">{{ page.header.caption | markdownify | remove: "<p>" | remove: "</p>" }}</span>
{% endif %} {% endif %}
</div><!-- /.image-wrap --> </div><!-- /.image-wrap -->
{% endif %} {% endif %}

View file

@ -2,10 +2,6 @@
permalink: /about/ permalink: /about/
title: "About the Theme" title: "About the Theme"
modified: 2014-08-08T20:53:07.573882-04:00 modified: 2014-08-08T20:53:07.573882-04:00
image:
feature: sample-image-2.jpg
credit: WeGraphics
creditlink: http://wegraphics.net/downloads/free-ultimate-blurred-background-pack/
--- ---
Minimal Mistakes is responsive Jekyll theme with large featured images and solid typography. As the name implies the styling is fairly minimal to make it easier for you to build on top of. Minimal Mistakes is responsive Jekyll theme with large featured images and solid typography. As the name implies the styling is fairly minimal to make it easier for you to build on top of.

View file

@ -4,7 +4,5 @@ permalink: /
excerpt: "A minimal Jekyll theme for your blog by designer Michael Rose." excerpt: "A minimal Jekyll theme for your blog by designer Michael Rose."
header: header:
image: unsplash-image-7.jpg image: unsplash-image-7.jpg
credit: caption: "Photo credit: [**Unsplash**](https://unsplash.com)"
caption: Unsplash
url: https://unsplash.com
--- ---

View file

@ -3,9 +3,7 @@ title: "Template: Featured Image (Horizontal)"
date: 2012-03-15T15:15:12+00:00 date: 2012-03-15T15:15:12+00:00
header: header:
image: unsplash-image-1.jpg image: unsplash-image-1.jpg
credit: caption: "Photo credit: [**Unsplash**](https://unsplash.com)"
caption: Unsplash
url: https://unsplash.com
categories: categories:
- Template - Template
- Uncategorized - Uncategorized

View file

@ -2,9 +2,7 @@
title: "Template: Featured Image And Text Readability" title: "Template: Featured Image And Text Readability"
header: header:
image: unsplash-image-4.jpg image: unsplash-image-4.jpg
credit: caption: "Photo credit: [**Unsplash**](https://unsplash.com)"
caption: Unsplash
url: https://unsplash.com
tags: tags:
- sample post - sample post
- readability - readability

View file

@ -3,9 +3,7 @@ title: "Template: Featured Image (Vertical)"
date: 2012-03-15T15:36:32+00:00 date: 2012-03-15T15:36:32+00:00
header: header:
image: unsplash-image-6.jpg image: unsplash-image-6.jpg
credit: caption: "Photo credit: [**Unsplash**](https://unsplash.com)"
caption: Unsplash
url: https://unsplash.com
categories: categories:
- Template - Template
- Uncategorized - Uncategorized

View file

@ -66,7 +66,7 @@ figcaption {
Feature image captions Feature image captions
========================================================================== */ ========================================================================== */
.image-credit { .image-caption {
@include grid(12,10); @include grid(12,10);
@include prefix(12,1); @include prefix(12,1);
@include suffix(12,1); @include suffix(12,1);