-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.hbs
executable file
·76 lines (71 loc) · 2.93 KB
/
index.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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
{{> head}}
{{> navbar}}
{{#checkIf @config.custom.frontSource '==' "post" }}
{{> frontpage-post}}
{{else}}
<main class="main">
<div class="main__left">
{{#if @config.custom.uploadHero}}
<figure class="hero">
<img
src="{{@config.custom.uploadHero}}"
{{#if @config.site.responsiveImages}}
{{responsiveImageAttributes @config.custom.uploadHero}}
{{/if}}
{{ lazyload "eager" }}
{{imageDimensions @config.custom.uploadHero}}
alt="{{@config.custom.uploadHeroAlt}}">
{{#if @config.custom.uploadHeroCaption}}
<figcaption class="hero__caption">
{{@config.custom.uploadHeroCaption}}
</figcaption>
{{/if}}
</figure>
{{/if}}
<header>
{{{@config.custom.textHero}}}
</header>
</div>
<div class="main__right feed">
<div>
{{#each posts}}
<article class="feed__item">
<header>
<h2>
<a href="{{url}}">
{{title}}
</a>
</h2>
{{#checkIfAny @config.custom.listingDate @config.custom.listingAuthor}}
<div class="post__meta">
{{#if @config.custom.listingDate}}
<time datetime="{{date createdAt 'YYYY-MM-DDTHH:mm'}}">
{{#checkIf @config.custom.formatDate '!=' 'custom'}}
{{date createdAt @config.custom.formatDate}}
{{else}}
{{date createdAt @config.custom.formatDateCustom}}
{{/checkIf}}
</time>
{{/if}}
{{#if @config.custom.listingAuthor}}
{{ translate 'common.publishedBy' }}
{{#author}}
<a href="{{url}}">{{name}}</a>
{{/author}}
{{/if}}
</div>
{{/checkIfAny}}
</header>
{{#if hasCustomExcerpt}}
{{{ excerpt }}}
{{else}}
<p>{{{ excerpt }}}</p>
{{/if}}
</article>
{{/each}}
{{> pagination}}
</div>
</div>
</main>
{{/checkIf}}
{{> footer}}