forked from eddiesigner/liebling
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.hbs
134 lines (125 loc) · 6.3 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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
{{!--
This template is used for the index page.
It can be used also as the home page or the default page.
--}}
{{!-- This block preloads specific assets for the index page --}}
{{#contentFor "preload"}}
<link rel="preload" href="{{asset "css/home.css"}}" as="style" />
<link rel="preload" href="{{asset "css/listing.css"}}" as="style" />
<link rel="preload" href="{{asset "css/retrox.css"}}" as="style" />
<link rel="preload" href="{{asset "js/home.js"}}" as="script" />
<link rel="preload" href="{{asset "js/modal.js"}}" as="script" />
<script src="https://kit.fontawesome.com/3528a730d4.js" crossorigin="anonymous"></script>
{{/contentFor}}
{{!-- This block loads specific styles for the index page --}}
{{#contentFor "styles"}}
<link rel="stylesheet" type="text/css" href="{{asset "css/home.css"}}" media="screen" />
<link rel="stylesheet" type="text/css" href="{{asset "css/listing.css"}}" media="screen" />
<link rel="stylesheet" type="text/css" href="{{asset "css/retrox.css"}}" media="screen" />
{{/contentFor}}
{{!-- The tag below means: insert everything in this file
into the {body} of the default.hbs template --}}
{{!< default}}
{{!-- Special header.hbs partial to generate the <header> tag --}}
{{> header [email protected]_image}}
<main class="main-wrap">
{{!-- Inject styles of the hero image to make it responsive --}}
{{> hero [email protected]_image}}
<div id="myModal" class="modal">
<!-- Modal content -->
<div class="modal-content">
<span class="close">×</span>
<p>Some text in the Modal..</p>
</div>
</div>
<div class="m-hero__content" data-animate="fade-down">
<div class="retrox_hero_content">
<span class="retrox_hero_header">Brand new Minecraft adventure awaits!</span>
<span class="retrox_hero_description">Retrox is a unique, cyber-themed Minecraft server.<br/>Join us and explore for yourself!</span>
<button id="myBtn" style="background-color: #1d169c;">
<i class="fa-solid fa-gamepad" style="padding-right: 5px;"></i> Play Now
</button>
<button style="background-color: rgb(14, 11, 27);">
<form action="http://discord.retrox.gg" target="_blank">
<i class="fa-brands fa-discord"></i>
</form>
</button>
</div>
</div>
</section>
<div class="l-content">
<div class="l-wrapper" data-animate="fade-up">
<div class="l-grid centered">
{{#get "posts" filter="featured:true" include="authors,tags" limit="5" as |featured|}}
{{#if featured}}
<div class="m-featured-slider swiper js-featured-slider">
<div class="m-featured-slider__list swiper-wrapper">
{{#foreach featured}}
<div class="m-featured-slider__list__item swiper-slide">
<article class="m-featured-article {{#unless feature_image}}no-picture{{/unless}}">
<div class="m-featured-article__picture">
{{#if feature_image}}
<style>
#featured-bg-{{id}} {
background-image: url({{img_url feature_image size='l'}});
}
@media(max-width: 768px) {
#featured-bg-{{id}} {
background-image: url({{img_url feature_image size='m'}});
}
}
</style>
<div id="featured-bg-{{id}}"></div>
{{/if}}
</div>
<div class="m-featured-article__meta">
<a href="{{primary_author.url}}" class="m-featured-article__author js-tooltip" aria-label="{{primary_author.name}}" data-tippy-content="{{t "Posted by"}} {{primary_author.name}} {{authors autolink="false" from="2" prefix=(t "Among with") separator=" , "}}">
{{#if primary_author.profile_image}}
<div style="background-image: url({{img_url primary_author.profile_image size="xs"}});"></div>
{{else}}
<div style="background-image: url({{asset "images/default-avatar-square-small.jpg"}});"></div>
{{/if}}
</a>
{{#if primary_tag}}
<a href="{{primary_tag.url}}" class="m-featured-article__tag">{{primary_tag.name}}</a>
{{/if}}
</div>
<div class="m-featured-article__ribbon">
<span class="icon-star"></span>
<span>{{t "Featured"}}</span>
</div>
<a href="{{url}}" class="m-featured-article__content">
<h2 class="m-featured-article__title js-featured-article-title" title="{{title}}">
{{title}}
</h2>
<div class="m-featured-article__timestamp">
<span>{{date published_at timeago="true"}}</span>
<span>•</span>
<span>{{reading_time minute=(t "1 min read") minutes=(t "% min read")}}</span>
</div>
</a>
</article>
</div>
{{/foreach}}
</div>
<button class="m-icon-button in-featured-articles swiper-button-prev js-featured-slider-button" aria-label="{{t "Previous"}}">
<span class="icon-arrow-left" aria-hidden="true"></span>
</button>
<button class="m-icon-button in-featured-articles swiper-button-next js-featured-slider-button" aria-label="{{t "Next"}}">
<span class="icon-arrow-right" aria-hidden="true"></span>
</button>
</div>
{{/if}}
{{/get}}
{{!-- The tag below iterates over all the posts --}}
{{> "loop"}}
</div>
</div>
{{!-- Links to Previous/Next posts --}}
{{pagination}}
</div>
</main>
{{!-- The #contentFor helper here will send everything inside it up to the matching #block helper found in default.hbs --}}
{{#contentFor "scripts"}}
<script defer src="{{asset "js/home.js"}}"></script>
{{/contentFor}}