Improved ArticleView datetime accessibility

This commit is contained in:
Mia Rose Winter 2024-01-16 00:05:30 +01:00
parent db1250213f
commit 47a0c3a8eb
Signed by: miawinter
GPG key ID: 4B6F6A83178F595E

View file

@ -17,9 +17,15 @@
</AuthorizeView> </AuthorizeView>
<p class="mb-6"> <p class="mb-6">
<small class="text-sm text-neutral-content"> <small class="text-sm text-neutral-content">
<time datetime="@Article.PublishDate.ToString("u")"
title="@Article.PublishDate.ToString("g")">
@Article.PublishDate.Humanize() @Article.PublishDate.Humanize()
</time>
@if (Article.LastModified is not null) { @if (Article.LastModified is not null) {
<text>&ensp;(@Localizer["ModifiedOn"] @Article.LastModified.Humanize())</text> <time datetime="@Article.LastModified.Value.ToString("u")"
title="@Article.LastModified.Value.ToString("g")">
&ensp;(@Article.LastModified.Humanize())
</time>
} }
</small> </small>
</p> </p>