blob: 2bb7f08ea1fd36baf2279ba183f689a57156e2fb (
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
{{ $allPosts := where .Site.RegularPages "Params.section" "issue" }}
{{ $active := where $allPosts "Params.resolved" "=" false }}
{{ $informationals := where $allPosts "Params.informational" "=" true }}
{{ $pinned := where $informationals "Params.pin" "=" true }}
{{ if or ($active) ($pinned) }}
<div class="announcement-box" style="border-bottom: 0">
{{ range $active }}
<div class="padding">
<p>
<a href="{{ .RelPermalink }}"><strong class="bold">{{ .Title }} →</strong></a>
</p>
<p><small>
{{ range .Params.Affected }}
<a href="{{ printf "affected/%s/" (. | urlize) | relURL }}" class="tag no-underline">{{ . }}</a>
{{ end }}
</small></p>
{{ .Content | safeHTML | truncate 500 "…" }}
<p></p>
</div>
<hr class="clean announcement-box">
{{ end }}
{{ range $pinned }}
{{ if .Params.informational }}
<div class="padding">
<p>
<a href="{{ .RelPermalink }}"><strong class="bold">{{ .Title }} →</strong></a>
</p>
<p><small>
{{ range .Params.Affected }}
<a href="{{ printf "affected/%s/" (. | urlize) | relURL }}" class="tag no-underline">{{ . }}</a>
{{ end }}
</small></p>
{{ .Content | safeHTML | truncate 500 "…" }}
<p></p>
</div>
<hr class="clean announcement-box">
{{ end }}
{{ end }}
</div>
{{ end }}
|