-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathauthor.hbs
57 lines (52 loc) · 2.75 KB
/
author.hbs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
{{!< default}}
{{!-- The tag above means - insert everything in this file into the {body} of the default.hbs template --}}
{{!-- The main content area --}}
<main id="main" class="max-w-7xl mx-auto sm:px-6 lg:px-8">
<div class="py-12 px-4 sm:px-6 lg:px-8">
<div class="max-w-7xl mx-auto">
{{#author}}
<div class="md:flex bg-white rounded-lg p-6 md:p-0">
{{#if profile_image}}
<img class="h-16 w-16 md:h-24 md:w-24 rounded-full mx-auto md:mx-0 md:mr-6" src="{{profile_image}}" alt="{{name}}" />
{{else}}
<span class="h-16 w-16 md:h-24 md:w-24 rounded-full mx-auto md:mx-0 md:mr-6"><i class="fas fa-user-circle fa-2x"></i></span>
{{/if}}
<div class="text-center md:text-left">
<h1 class="text-lg font-semibold">{{name}}</h1>
{{#if bio}}
<h2 class="text-gray-500">{{bio}}</h2>
{{/if}}
<div class="md:flex mt-4 md:mt-1 text-sm leading-5 text-gray-400">
{{#if location}}
<div class="hidden md:block">{{location}}</div>
<span class="mx-2 hidden md:block">·</span>
{{/if}}
<div class="hidden md:block">
{{plural ../pagination.total empty='No posts' singular='% post' plural='% posts'}}
</div>
{{#if website}}
<span class="mx-2 hidden md:block">·</span>
<span class="hover:underline"><a href="{{website}}" target="_blank" rel="noopener">Website</a></span>
{{/if}}
{{#if twitter}}
<span class="mx-2">·</span>
<span class="hover:underline"><a href="{{twitter_url}}" target="_blank" rel="noopener">Twitter</a></span>
{{/if}}
{{#if facebook}}
<span class="mx-2">·</span>
<span class="hover:underline"><a href="{{facebook_url}}" target="_blank" rel="noopener">Facebook</a></span>
{{/if}}
</div>
</div>
</div>
{{/author}}
<div class="mt-12 grid gap-5 max-w-lg mx-auto lg:grid-cols-3 lg:max-w-none">
{{#foreach posts}}
{{!-- The tag below includes the markup for each post - partials/post-card.hbs --}}
{{> "post-card"}}
{{/foreach}}
</div>
{{pagination}}
</div>
</div>
</main>