casper-modified-ghost-theme/author.hbs

62 lines
2.4 KiB
Handlebars
Raw Normal View History

2022-01-06 19:23:20 +01:00
{{!< default}}
{{!-- The tag above means - insert everything in this file into the {body} of the default.hbs template --}}
{{#author}}
{{!-- Everything inside the #author tags pulls data from the author --}}
<header class="site-archive-header">
{{> site-header}}
{{> header-background background=cover_image}} {{!--Special header-image.hbs partial to generate the background image--}}
<div class="inner">
<div class="site-header-content author-header">
{{#if profile_image}}
<img class="author-profile-image" src="{{profile_image}}" alt="{{name}}" />
{{else}}
<span class="author-profile-image">{{> "icons/avatar"}}</span>
{{/if}}
<div class="author-header-content">
<h1 class="site-title">{{name}}</h1>
{{#if bio}}
<h2 class="author-bio">{{bio}}</h2>
{{/if}}
<div class="author-meta">
{{#if location}}
<div class="author-location">{{location}}</div>
{{/if}}
<div class="author-stats">
{{plural ../pagination.total empty='No posts' singular='% post' plural='% posts'}}
</div>
{{#if website}}
<span class="author-social-link"><a href="{{website}}" rel="noopener">Website</a></span>
{{/if}}
{{#if twitter}}
<span class="author-social-link"><a href="{{twitter_url}}" rel="noopener">Twitter</a></span>
{{/if}}
{{#if facebook}}
<span class="author-social-link"><a href="{{facebook_url}}" rel="noopener">Facebook</a></span>
{{/if}}
</div>
</div>
</div>
</div>
</div>
</header>
{{/author}}
{{!-- The main content area --}}
<main id="site-main" class="site-main outer">
<div class="inner posts">
<div class="post-feed">
{{#foreach posts}}
{{!-- The tag below includes the markup for each post - partials/post-card.hbs --}}
{{> "post-card"}}
{{/foreach}}
</div>
</div>
</main>