Skip to content

Commit

Permalink
feat: badges/draft (#382)
Browse files Browse the repository at this point in the history
  • Loading branch information
peaceiris authored Jun 27, 2021
1 parent ec1c7e6 commit 26ec34a
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 1 deletion.
8 changes: 7 additions & 1 deletion layouts/_default/list.html
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,13 @@ <h2 class="title">{{ $title }}</h2>
{{ if .Params.math }}
{{ $math = true }}
{{ end }}
<p>{{ .Date.Format "2006-01-02" }}{{ partial "badges/slide" . }}</p>
<p>
{{ .Date.Format "2006-01-02" }}
<div class="tags">
{{ partial "badges/draft" . }}
{{ partial "badges/slide" . }}
</div>
</p>
</div>
</div>
</a>
Expand Down
3 changes: 3 additions & 0 deletions layouts/partials/badges/draft.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{{ if $.Params.draft }}
<span class="tag is-light">Draft</span>
{{ end }}
7 changes: 7 additions & 0 deletions layouts/partials/header.html
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,13 @@ <h1 class="title is-spaced">
{{ partial "breadcrumb" . }}
{{ end }}
<p class="is-italic has-text-grey-light has-text-weight-light">{{ partial "canonical-link" . }}</p>
{{ if .Params.draft }}
<p>
<div class="tags">
{{ partial "badges/draft" . }}
</div>
</p>
{{ end }}
{{ with .GitInfo }}
<p class="has-text-grey-light is-pulled-right">
<a
Expand Down

0 comments on commit 26ec34a

Please sign in to comment.