mirror of https://github.com/MISP/misp-website
new: [tags] update tags partial widget to have working tags links
parent
5e2045e0d6
commit
2f52cc6b30
|
@ -0,0 +1,24 @@
|
|||
{{ if .Site.Params.widgets.tags }}
|
||||
{{ if isset .Site.Taxonomies "tags" }}
|
||||
{{ if not (eq (len .Site.Taxonomies.tags) 0) }}
|
||||
<div class="panel sidebar-menu">
|
||||
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">{{ i18n "tagsTitle" }}</h3>
|
||||
</div>
|
||||
|
||||
<div class="panel-body">
|
||||
<ul class="tag-cloud">
|
||||
{{ $current := . }}
|
||||
{{ range $name, $items := .Site.Taxonomies.tags }}
|
||||
<li {{ if eq $current.RelPermalink (printf "%s/%s/" ("tags" | relLangURL) ($name)) }}class="active"{{ end }}>
|
||||
<a href="{{ "tags/" | relLangURL }}{{ $name | urlize }}"><i class="fas fa-tags"></i> {{ $name }}</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
Loading…
Reference in New Issue