mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-25 14:15:00 +00:00
feat: add translation for "1 hour ago" in multiple languages (#1096)
This commit is contained in:
parent
c3e1fb93b6
commit
db504241ea
10 changed files with 13 additions and 1 deletions
|
@ -129,7 +129,10 @@ namespace SourceGit.Views
|
|||
return App.Text("Period.MinutesAgo", (int)span.TotalMinutes);
|
||||
|
||||
if (span.TotalDays < 1)
|
||||
return App.Text("Period.HoursAgo", (int)span.TotalHours);
|
||||
{
|
||||
var hours = (int)span.TotalHours;
|
||||
return hours == 1 ? App.Text("Period.HourAgo") : App.Text("Period.HoursAgo", hours);
|
||||
}
|
||||
|
||||
var lastDay = now.AddDays(-1).Date;
|
||||
if (localTime >= lastDay)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue