Skip to content

Commit

Permalink
Add hero image configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
maxsaber committed Dec 7, 2022
1 parent e51f243 commit 1cd0154
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 6 deletions.
8 changes: 8 additions & 0 deletions _layouts/post.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,14 @@
<h1 class="post-title">{{ page.title }}</h1>
{% if page.man-date %} <div id="post-date">{{ page.man-date }}</div>{% else %}<time datetime="{{ page.date | date: "%B %-d, %Y" }}" class="post-date">{{ page.date | date: "%B %-d, %Y" }}</time> {% endif %}
{% include breadcrumbs.html %}

<div class="cv-spacer-medium"></div>
{% if page.hero %}
<div class="blog-post-hero">
<img class="img" src="{{ page.hero }}" alt="{{ page.hero-alt }}">
</div>
{% endif %}

{{ content }}

<hr />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,19 @@ title: Charleston, SC
author: Max Saber
man-date: September 2017
categories: [travel]
hero: /images/posts/travel/2017/09-charleston/IMG_8900.JPEG
hero-alt: "Max Saber standing in front of a stone sign reading Medical University of South Carolina"
permalink: blog/travel/2017/charleston-sc
---

Ah, my first trip to Charleston as a doctorate student at the Medical University of South Carolina!

<!--more-->
<!-- hide anything under the more tag from the /blog listing -->

<!-- ...start blog post here -->

{% include image-gallery.html folder="/images/posts/travel/2017/09-charleston" %}

<div class="cv-spacer-small"></div>
<div class="img-description">
Images from left to right, top to bottom:
Max's new MUSC student ID; 5 Church restaurant facade; interior of 455 King restaurant; the daily handwritten menu from Chez Nous; harbor view from our hotel; a fort turned restaurant, California Dreaming; MUSC exterior sign; Max with the MUSC sign; our 35,000ft view over the clouds; Max and Dominic enjoying a few minutes alone at the end of the trip.
</div>
<!-- single photo
![The Green "Pocket Park", Charlotte, NC](/images/posts/travel/2015/charlotte/IMG_2792.jpg)
-->
9 changes: 9 additions & 0 deletions _sass/_papers.scss
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,15 @@ $blog-author-image-size: 60px;
margin-bottom: 0.5rem;
}

#blog-post-hero {
width: fit-content;
}

.img {
width: 100%;
height: auto;
}

#venue {
grid-column: text;
color: $mid-gray;
Expand Down

0 comments on commit 1cd0154

Please sign in to comment.