Skip to content

Commit 8b1ba4c

Browse files
authored
Merge pull request #53 from chrishavlin/fix_landing_alignement
center the text and image on landing page
2 parents 56341f4 + 0ee795a commit 8b1ba4c

2 files changed

Lines changed: 21 additions & 4 deletions

File tree

content/_index.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@ date = "2017-09-07"
55
description = "iSTRUM"
66
+++
77

8-
![](images/istrum-logo-mod.png)
9-
108
**i**nve**S**tigating the **T**ransient **R**heology of the **U**pper **M**antle
119

1210
To learn more about iSTRUM, read more about the project [here](/about) or check out the [blog](/blog).

layouts/partials/home/card.html

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,27 @@
11
<div class="relative pt-16 pb-32">
22
<div aria-hidden="true" class="absolute inset-x-0 top-0 h-48 bg-gradient-to-b from-gray-100"></div>
33
<div class="relative">
4-
<article class="max-w-full prose dark:prose-invert">
5-
<section>{{ .Content | emojify }}</section>
4+
<article class="max-w-full prose dark:prose-invert" style="text-align: center;">
5+
{{ $homepageImage := "" }}
6+
{{ with .Site.Params.defaultBackgroundImage }}
7+
{{ if or (strings.HasPrefix . "http:") (strings.HasPrefix . "https:") }}
8+
{{ $homepageImage = resources.GetRemote . }}
9+
{{ else }}
10+
{{ $homepageImage = resources.Get . }}
11+
{{ end }}
12+
{{ end }}
13+
{{ with .Site.Params.homepage.homepageImage }}
14+
{{ if or (strings.HasPrefix . "http:") (strings.HasPrefix . "https:") }}
15+
{{ $homepageImage = resources.GetRemote . }}
16+
{{ else }}
17+
{{ $homepageImage = resources.Get . }}
18+
{{ end }}
19+
{{ end }}
20+
{{ if $homepageImage }}
21+
<img style="display: block; margin-left: auto; margin-right: auto; width: 60%;"
22+
src="{{ $homepageImage.RelPermalink }}">
23+
{{ end }}
24+
<section>{{ .Content | emojify }}</section>
625
</article>
726
</div>
827
</div>

0 commit comments

Comments
 (0)