liebling/author.hbs

90 lines
3 KiB
Handlebars
Raw Normal View History

2019-04-14 18:41:25 +00:00
{{!--
This template is used for the author page.
--}}
2020-11-07 19:18:06 +00:00
{{!-- This block preloads specific assets for the author page --}}
{{#contentFor "preload"}}
2020-07-07 15:13:29 +00:00
<link rel="preload" href="{{asset "css/listing.css"}}" as="style" />
2020-11-07 19:18:06 +00:00
{{/contentFor}}
2020-07-07 15:13:29 +00:00
2020-11-07 19:18:06 +00:00
{{!-- This block loads specific styles for the author page --}}
{{#contentFor "styles"}}
2020-07-07 15:13:29 +00:00
<link rel="stylesheet" type="text/css" href="{{asset "css/listing.css"}}" media="screen" />
2020-07-02 20:23:00 +00:00
{{/contentFor}}
2019-04-14 18:41:25 +00:00
{{!-- The tag below means: insert everything in this file
into the {body} of the default.hbs template --}}
2019-02-24 21:06:24 +00:00
{{!< default}}
2020-07-07 15:13:29 +00:00
{{!-- Special header.hbs partial to generate the <header> tag --}}
{{#author}}
{{> header background=cover_image}}
{{/author}}
<main class="main-wrap">
2019-04-14 18:41:25 +00:00
{{!-- Everything inside the #author tags pulls data from the author --}}
2019-03-08 09:47:48 +00:00
{{#author}}
2020-02-25 16:10:57 +00:00
{{!-- Inject styles of the hero image to make it responsive --}}
{{> hero background=cover_image}}
<div class="m-hero__content" data-aos="fade-down">
{{#if profile_image}}
<div class="m-hero-avatar" style="background-image: url({{profile_image}});"></div>
{{else}}
<div class="m-hero-avatar" style="background-image: url({{asset "images/default-avatar-square-normal.jpg"}});"></div>
2019-03-08 09:47:48 +00:00
{{/if}}
2020-02-25 16:10:57 +00:00
<h1 class="m-hero-title">{{name}}</h1>
{{#if bio}}
<p class="m-hero-description">{{bio}}</p>
2019-03-08 09:47:48 +00:00
{{/if}}
2020-02-25 16:10:57 +00:00
<div class="m-hero__meta">
{{#has any="twitter, facebook, website"}}
<ul class="m-hero-social">
{{#if website}}
<li>
2020-07-07 15:13:29 +00:00
<a href="{{website}}" target="_blank" rel="noopener" aria-label="{{t "Website"}}">
2020-02-25 16:10:57 +00:00
<span class="icon-globe"></span>
</a>
</li>
{{/if}}
{{#if facebook}}
<li>
<a href="https://facebook.com/{{facebook}}" target="_blank" rel="noopener" aria-label="Facebook">
<span class="icon-facebook"></span>
</a>
</li>
{{/if}}
{{#if twitter}}
<li>
<a href="https://twitter.com/{{twitter}}" target="_blank" rel="noopener" aria-label="Twitter">
<span class="icon-twitter"></span>
</a>
</li>
{{/if}}
</ul>
{{/has}}
<ul class="m-hero-stats">
<li>
{{plural ../pagination.total empty=(t "No posts") singular=(t "1 post") plural=(t "% posts")}}
</li>
{{#if location}}
<li>&bull;</li>
<li>{{location}}</li>
{{/if}}
</ul>
</div>
</div>
</section>
2019-03-08 09:47:48 +00:00
{{/author}}
2020-07-07 15:13:29 +00:00
<div class="l-content">
<div class="l-wrapper" data-aos="fade-up" data-aos-delay="300">
<div class="l-grid centered">
{{!-- The tag below iterates over all the posts --}}
{{> "loop"}}
2019-03-08 09:47:48 +00:00
</div>
2019-03-12 10:39:01 +00:00
</div>
2020-07-07 15:13:29 +00:00
{{!-- Links to Previous/Next posts --}}
{{pagination}}
</div>
</main>