[feature] show status edits on frontend (#3678)

* add 'edited-at' field to status info web template

* make the edited-at text italic

* small change in phrasing
This commit is contained in:
kim 2025-01-24 15:02:13 +00:00 committed by GitHub
parent 5b765d734e
commit 3720251fca
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 13 additions and 1 deletions

View file

@ -436,6 +436,10 @@ main {
display: flex;
flex-wrap: wrap;
column-gap: 1rem;
.edited-at {
font-style: italic;
}
}
.stats-item {
@ -443,7 +447,7 @@ main {
gap: 0.4rem;
}
.stats-item:not(.published-at) {
.stats-item:not(.published-at):not(.edited-at) {
z-index: 1;
user-select: none;
}

View file

@ -26,6 +26,14 @@
<time datetime="{{- .CreatedAt -}}">{{- .CreatedAt | timestampPrecise -}}</time>
</dd>
</div>
{{- if .EditedAt -}}
<div class="stats-item edited-at text-cutoff">
<dt class="sr-only">Edited</dt>
<dd>
(last edited <time datetime="{{- .EditedAt -}}">{{- .EditedAt | timestampPrecise -}}</time>)
</dd>
</div>
{{ end }}
<div class="stats-grouping">
<div class="stats-item" title="Replies">
<dt>