Skip to content

Commit

Permalink
Add missing whitespace after "Posted by" on the post list
Browse files Browse the repository at this point in the history
The `post_list.html` is missing a whitespace between the "Posted by" and the author's name.

This whitespace is however present in the `single.html` page.
https://github.com/zhaohuabing/hugo-theme-cleanwhite/blob/7b64a06446db7aa1620e99186302a5ebe3f976cf/layouts/_default/single.html#L36

I'm proposing this change to make the layout consistent.
  • Loading branch information
antoinedelia authored and zhaohuabing committed Apr 11, 2022
1 parent 7b64a06 commit 2eeaf18
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion layouts/partials/post_list.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ <h3 class="post-subtitle">
{{ end }}
{{ end }}
{{ else }}
Posted by{{ with .Params.author }}{{ . }}{{ else }}{{ .Site.Title }}{{ end }} {{ .Date.Format "Monday, January 2, 2006" }}
Posted by {{ with .Params.author }}{{ . }}{{ else }}{{ .Site.Title }}{{ end }} {{ .Date.Format "Monday, January 2, 2006" }}
<!-- Don't show "Last Modified on" if update happened on the same day. -->
{{ if (and (not .Lastmod.IsZero) (not (eq (dateFormat "2006-01-02" .Lastmod) (dateFormat "2006-01-02" .Date)))) }}
<br>Last Modified on {{ dateFormat "Monday, January 2, 2006" .Params.LastMod }}
Expand Down

0 comments on commit 2eeaf18

Please sign in to comment.