diff options
author | He Yeshuang <yeshuanghe@gmail.com> | 2020-05-03 17:50:58 +0300 |
---|---|---|
committer | He Yeshuang <yeshuanghe@gmail.com> | 2020-05-18 15:15:49 +0300 |
commit | cd4a30371c715a4fa2e1e5523a02cf99554b2b1b (patch) | |
tree | dff5d1382233daeabe4d81025c44ae13885aa0e7 /layouts/partials | |
parent | 2c5fd2ce2d6a51287a35e384c658b643e589ba5c (diff) |
modding list
Diffstat (limited to 'layouts/partials')
-rwxr-xr-x | layouts/partials/list-header.html | 6 | ||||
-rw-r--r-- | layouts/partials/site-navigation.html | 33 | ||||
-rw-r--r-- | layouts/partials/summary.html | 4 | ||||
-rw-r--r-- | layouts/partials/tags.html | 10 |
4 files changed, 27 insertions, 26 deletions
diff --git a/layouts/partials/list-header.html b/layouts/partials/list-header.html deleted file mode 100755 index 4190fd9..0000000 --- a/layouts/partials/list-header.html +++ /dev/null @@ -1,6 +0,0 @@ - <div class="pb-4"> - <h1> - <a href="{{ .Site.BaseURL }}" title="{{ .Site.Title }}" class="heading">{{ .Site.Title }}</a> - </h1> - </div> - {{ partial "site-navigation.html" . }}
\ No newline at end of file diff --git a/layouts/partials/site-navigation.html b/layouts/partials/site-navigation.html index 0e7601e..033dbc6 100644 --- a/layouts/partials/site-navigation.html +++ b/layouts/partials/site-navigation.html @@ -1,16 +1,17 @@ - <ul class="font-serif flex-grow-0 flex justify-between flex-wrap md:flex-col"> - {{ if .Site.Menus.main }} - {{ range .Site.Menus.main }} - <li> - <a href="{{ .URL }}" title="{{ .Name }} page"> - {{ .Name }} - </a> - </li> - {{ end }} - {{ if .OutputFormats.Get "RSS" }} - <li> - <a href='{{ with .OutputFormats.Get "RSS" }}{{ .RelPermalink }}{{ end }}'>RSS</a> - </li> - {{ end }} - {{ end }} - </ul>
\ No newline at end of file +<ul class="font-serif flex-grow-0 flex justify-between flex-wrap md:flex-col"> + {{ if .Site.Menus.main }} + {{ range .Site.Menus.main }} + <li class="px-1 md:px-0"> + <a href="{{ .URL }}" title="{{ .Name }} page" {{ if eq ($.Permalink| absURL ) (.URL|absURL) }} + class="font-bold text-medium-red-violet-600 hover:text-medium-red-violet-400" {{ end }}> + {{ .Name }} + </a> + </li> + {{ end }} + {{ if .OutputFormats.Get "RSS" }} + <li> + <a href='{{ with .OutputFormats.Get "RSS" }}{{ .RelPermalink }}{{ end }}'>RSS</a> + </li> + {{ end }} + {{ end }} +</ul>
\ No newline at end of file diff --git a/layouts/partials/summary.html b/layouts/partials/summary.html index 55ebacc..641bac3 100644 --- a/layouts/partials/summary.html +++ b/layouts/partials/summary.html @@ -4,9 +4,9 @@ <a href="{{ .Permalink }}"> {{ .Title }} </a> - </div> + </div> {{ with .Description }} - <div>{{.}}</div> + <div>{{.}}</div> {{ end }} </div> </div>
\ No newline at end of file diff --git a/layouts/partials/tags.html b/layouts/partials/tags.html index a7088a8..4c0382a 100644 --- a/layouts/partials/tags.html +++ b/layouts/partials/tags.html @@ -4,15 +4,21 @@ {{ if gt $count 0 }} {{ range $k, $v := .Params.categories}} <a class="post-taxonomy-category text-medium-red-violet-600 hover:text-medium-red-violet-400" - href="/categories/{{ . | urlize }}">{{ . }}</a> / + href="/categories/{{ . | urlize }}">{{ . }}</a>{{ if lt $k (sub $count 1) }} /{{ end }} {{end}} {{end}} {{end}} + + {{ if and (isset .Params "categories") (isset .Params "tags") }} + + {{end}} + {{ if isset .Params "tags" }} {{ $count := len .Params.tags }} {{ if gt $count 0 }} {{ range $k, $v := .Params.tags }} - <a class="post-taxonomy-tag text-eucalyptus-500" href="/tags/{{ . | urlize }}">{{ . }}</a>{{ if lt $k (sub $count 1) }} /{{ end }} + <a class="post-taxonomy-tag text-eucalyptus-500" + href="/tags/{{ . | urlize }}">{{ . }}</a>{{ if lt $k (sub $count 1) }} /{{ end }} {{ end }} {{ end }} {{ end }} |