Apply some bootstrap styling

This commit is contained in:
ItsDrike 2021-08-25 11:53:41 +02:00
parent a82ab80745
commit 71fc71e30a
No known key found for this signature in database
GPG key ID: B5F6B41F708C3ADD
4 changed files with 48 additions and 33 deletions

View file

@ -1,11 +1,13 @@
{{ define "main" }}
<div id="main">
<div class="container">
{{ partial "content.html" . }}
<!--Group posts by months-->
{{ range .Pages.GroupByDate "2006-01" }}
{{ $month := print .Key "-01"}}
{{ $display := dateFormat "2006-01" $month }}
<h3 id="{{ $display }}">
<h3 class="mt-5" id="{{ $display }}">
<a href="#{{ $display }}">
<time datetime="{{ $month }}" title='{{ dateFormat "January 2006" $month }}'>{{ $display }}</time>
</a>
@ -15,4 +17,6 @@
{{ partial "list_item.html" . }}
{{ end }}
{{ end }}
</div>
</div>
{{ end }}

View file

@ -1,9 +1,11 @@
{{ if not .Date.IsZero }}
<span title='{{ .Date.Format "January 2 2006" }}'>{{ .Date.Format "2006-01-02" }}</span>
<span class="pr-2" title='{{ .Date.Format "January 2 2006" }}'>
<i class="far fa-calendar-alt pr-1>"></i>{{ .Date.Format "2006-01-02" }}
</span>
{{ end }}
{{ if .Params.tags }}
{{ range $1, $e := .Params.tags }}
<a href="/tags/{{ urlize . }}">#{{ . }}</a>
<a class="mr-1" href="/tags/{{ urlize . }}">#{{ . }}</a>
{{ end }}
{{ end }}

View file

@ -1,14 +1,21 @@
<h1>{{ .Title }}</h1>
<h1 class="display-4">{{ .Title }}</h1>
{{ if .Params.subtitle }}
<h5 class="my-3">{{ markdownify .Params.subtitle | emojify }}</h5>
{{ end }}
{{ if .IsPage }}
<p>{{ partial "content-details.html" . }}</p>
{{ end }}
{{ if .Content }}
<hr>
<div class="content">
<div class="content mt-3">
{{ if .TableOfContents }}
<div class="content">
<div class="float-1g-right ml-lg-3 mb-3 p-3">
{{ .TableOfContents }}
</div>
{{ end }}
{{ .Content }}
</div>
{{ end }}

View file

@ -1,7 +1,9 @@
<div class="media list-page-item mb-3" data-id="{{ .File.UniqueID }}">
<div class="media-body">
<a href="{{ .RelPermalink }}">
<h5>{{ .Title }}</h5>
<h5 class="my-0">{{ .Title }}</h5>
</a>
<small>{{ partial "content-details.html" . }}</small>
<p>{{ partial "summary.html" . }}</p>
</div>
</div>