Welcome to mirror list, hosted at ThFree Co, Russian Federation.

content_card_body.html « partials « layouts - github.com/spech66/bootstrap-bp-hugo-theme.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: e4366b98913924571873a1c5b8772eb745c6b4fe (plain)
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
{{ $customDateFormat := "02.01.2006" }}
{{ with .Site.Params.customDateFormat }}{{ $customDateFormat = . }}{{ end }}

<div class="card-body">
    <h1 class="card-title"><a href="{{ .RelPermalink }}">{{ .Title | markdownify }}</a></h1>
    <h6 class="card-subtitle mb-2 text-muted">
        <i class="fas fa-calendar-day"></i>&nbsp;{{ .PublishDate.Format $customDateFormat }}{{ if gt .Lastmod .PublishDate }}, {{ i18n "lastupdated" }} {{ .Lastmod.Format $customDateFormat }}{{ end }} -
        <i class="fas fa-user"></i>&nbsp;{{ range .Site.Author }}{{ . }}{{ end }}
        {{ if ne .Site.Params.hideReadingTime true }}
            {{ if and (not (.Scratch.Get "showPostSummary")) (.Scratch.Get "fullsize") }}
                - <i class="fas fa-clock"></i>&nbsp;~{{ i18n "readingTime" .ReadingTime }}
            {{ end }}
        {{ end }}
    </h6>

    {{ if eq .Type "video" }}
    {{ else if eq .Type "audio" }}
    {{ else if eq .Type "link" }}
        <p class="text-center"><a href="{{ .Params.link }}" target="_blank" rel="noopener noreferrer" class="btn btn-primary btn-lg" tabindex="-1" role="button"><i class="fas fa-link"></i>&nbsp;{{ .Title }}</a></p>
    {{ else if eq .Type "quote" }}
        <blockquote class="blockquote text-center">
            <p class="mb-0"><i class="fas fa-quote-left fa-2x"></i>&nbsp;{{ .Params.quote }}&nbsp;<i class="fas fa-quote-right fa-2x"></i></p>
            <p class="blockquote-footer"><cite title="{{ .Params.quoteauthor }}">{{ .Params.quoteauthor }}</cite></p>
        </blockquote>
    {{ end }}

    {{ if .Scratch.Get "showPostSummary" }}
        <p class="card-text">{{ .Summary }}</p>

        <a href="{{ .RelPermalink }}" class="card-link">{{ i18n "readmore" }}&hellip;</a>
        {{ if ne .Site.Params.hideReadingTime true }}
             (<i class="fas fa-clock"></i>&nbsp;~{{ .ReadingTime }} Min.)
        {{end}}
    {{ else }}
        <p class="card-text">{{ .Content }}</p>
    {{ end }}
</div>