Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit d7c0cdc

Browse files
blogposts structure / no css
1 parent b955adf commit d7c0cdc

File tree

8 files changed

+42
-25
lines changed

8 files changed

+42
-25
lines changed

content/blog/_index.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
---
22
title: Blog
33
---
4+
5+
We use our blog to post write-ups from competitions or wargame challenges, summaries of our meetings, important upcoming events, or something cool in security

content/resources.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,4 @@ hello
1111

1212
**hi**
1313

14-
![](/resources.jpg)
14+
![a caption for resources.jpg](/resources.jpg)

layouts/_default/list.html

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
11
{{ define "main" }}
22

3-
<h1>{{ .Title }}</h1>
4-
{{ range .Pages.ByPublishDate.Reverse }}
5-
<p>
6-
<a class="font-125" href="{{ .RelPermalink }}">{{ .Title }}</a>
7-
<br>
8-
{{ partial "date-and-tags.html" . }}
9-
</p>
10-
{{ end }}
3+
<div id="home-jumbotron" class="jumbotron text-center hero-content infopage-hero d-flex flex-column justify-content-center">
4+
<h1 class="hero-title py-1">{{ .Title }}</h1>
5+
</div>
6+
7+
<div class="bg-light justify-content-center infopage-content" style="min-height: 60vh;">
8+
<div class="blogcards d-flex flex-wrap justify-content-center">
9+
{{ range .Pages.ByPublishDate.Reverse }}
10+
{{ partial "blogcard.html" . }}
11+
{{ end }}
12+
</div>
13+
</div>
1114

12-
{{ end }}
15+
{{ end }}

layouts/_default/single.html

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
11
{{ define "main" }}
22

3-
<h1>{{ .Title }}</h1>
4-
{{ partial "date-and-tags.html" . }}
5-
<br><br>
6-
{{ .Content }}
3+
<div id="home-jumbotron" class="jumbotron text-center hero-content infopage-hero d-flex flex-column justify-content-center">
4+
<h1 class="hero-title py-1">{{ .Title }}</h1>
5+
</div>
6+
7+
<div class="bg-light justify-content-center infopage-content" style="min-height: 60vh;">
8+
9+
</div>
710

811
{{ end }}

layouts/partials/blogcard.html

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<div class="blogcard-each border border-primary">
2+
<img src="/blog/{{ .Title | urlize }}.jpg" alt="{{ .Params.Caption }}" class="blogcard-img">
3+
<div class="blogcard-content py-4 px-4">
4+
<h3><a href="/{{ .Title | urlize}}">{{ .Title }}</a></h3>
5+
{{ $dateTime := .PublishDate.Format "2006-01-02" }}
6+
{{ $dateFormat := .Site.Params.dateFormat | default "Jan 2, 2006" }}
7+
<time datetime="{{ $dateTime }}">{{ .PublishDate.Format $dateFormat }}</time>
8+
9+
<p><a href="/{{ .Title | urlize }}">Read More</a></p>
10+
</div>
11+
</div>

layouts/partials/date-and-tags.html

Lines changed: 0 additions & 11 deletions
This file was deleted.

static/blog/if-by-rudyard-kipling.jpg

93.4 KB
Loading

static/caseyhates.css

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,3 +213,12 @@ body {
213213
width: 100%;
214214
height: 100vh;
215215
}
216+
217+
218+
.blogcard-each {
219+
width: 20rem;
220+
}
221+
222+
.blogcard-img {
223+
width: 100%;
224+
}

0 commit comments

Comments
 (0)