mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-21 12: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
|
@ -443,6 +443,7 @@
|
|||
<x:String x:Key="Text.Paste" xml:space="preserve">Einfügen</x:String>
|
||||
<x:String x:Key="Text.Period.JustNow" xml:space="preserve">Gerade eben</x:String>
|
||||
<x:String x:Key="Text.Period.MinutesAgo" xml:space="preserve">Vor {0} Minuten</x:String>
|
||||
<x:String x:Key="Text.Period.HourAgo" xml:space="preserve">Vor 1 Stunde</x:String>
|
||||
<x:String x:Key="Text.Period.HoursAgo" xml:space="preserve">Vor {0} Stunden</x:String>
|
||||
<x:String x:Key="Text.Period.Yesterday" xml:space="preserve">Gestern</x:String>
|
||||
<x:String x:Key="Text.Period.DaysAgo" xml:space="preserve">Vor {0} Tagen</x:String>
|
||||
|
|
|
@ -444,6 +444,7 @@
|
|||
<x:String x:Key="Text.Paste" xml:space="preserve">Paste</x:String>
|
||||
<x:String x:Key="Text.Period.JustNow" xml:space="preserve">Just now</x:String>
|
||||
<x:String x:Key="Text.Period.MinutesAgo" xml:space="preserve">{0} minutes ago</x:String>
|
||||
<x:String x:Key="Text.Period.HourAgo" xml:space="preserve">1 hour ago</x:String>
|
||||
<x:String x:Key="Text.Period.HoursAgo" xml:space="preserve">{0} hours ago</x:String>
|
||||
<x:String x:Key="Text.Period.Yesterday" xml:space="preserve">Yesterday</x:String>
|
||||
<x:String x:Key="Text.Period.DaysAgo" xml:space="preserve">{0} days ago</x:String>
|
||||
|
|
|
@ -447,6 +447,7 @@
|
|||
<x:String x:Key="Text.Paste" xml:space="preserve">Pegar</x:String>
|
||||
<x:String x:Key="Text.Period.JustNow" xml:space="preserve">Justo ahora</x:String>
|
||||
<x:String x:Key="Text.Period.MinutesAgo" xml:space="preserve">Hace {0} minutos</x:String>
|
||||
<x:String x:Key="Text.Period.HourAgo" xml:space="preserve">Hace 1 hora</x:String>
|
||||
<x:String x:Key="Text.Period.HoursAgo" xml:space="preserve">Hace {0} horas</x:String>
|
||||
<x:String x:Key="Text.Period.Yesterday" xml:space="preserve">Ayer</x:String>
|
||||
<x:String x:Key="Text.Period.DaysAgo" xml:space="preserve">Hace {0} días</x:String>
|
||||
|
|
|
@ -422,6 +422,7 @@
|
|||
<x:String x:Key="Text.Paste" xml:space="preserve">Coller</x:String>
|
||||
<x:String x:Key="Text.Period.JustNow" xml:space="preserve">A l'instant</x:String>
|
||||
<x:String x:Key="Text.Period.MinutesAgo" xml:space="preserve">il y a {0} minutes</x:String>
|
||||
<x:String x:Key="Text.Period.HourAgo" xml:space="preserve">il y a 1 heure</x:String>
|
||||
<x:String x:Key="Text.Period.HoursAgo" xml:space="preserve">il y a {0} heures</x:String>
|
||||
<x:String x:Key="Text.Period.Yesterday" xml:space="preserve">Hier</x:String>
|
||||
<x:String x:Key="Text.Period.DaysAgo" xml:space="preserve">il y a {0} jours</x:String>
|
||||
|
|
|
@ -448,6 +448,7 @@
|
|||
<x:String x:Key="Text.Paste" xml:space="preserve">Incolla</x:String>
|
||||
<x:String x:Key="Text.Period.JustNow" xml:space="preserve">Proprio ora</x:String>
|
||||
<x:String x:Key="Text.Period.MinutesAgo" xml:space="preserve">{0} minuti fa</x:String>
|
||||
<x:String x:Key="Text.Period.HourAgo" xml:space="preserve">1 ora fa</x:String>
|
||||
<x:String x:Key="Text.Period.HoursAgo" xml:space="preserve">{0} ore fa</x:String>
|
||||
<x:String x:Key="Text.Period.Yesterday" xml:space="preserve">Ieri</x:String>
|
||||
<x:String x:Key="Text.Period.DaysAgo" xml:space="preserve">{0} giorni fa</x:String>
|
||||
|
|
|
@ -435,6 +435,7 @@
|
|||
<x:String x:Key="Text.Paste" xml:space="preserve">Colar</x:String>
|
||||
<x:String x:Key="Text.Period.JustNow" xml:space="preserve">Agora mesmo</x:String>
|
||||
<x:String x:Key="Text.Period.MinutesAgo" xml:space="preserve">{0} minutos atrás</x:String>
|
||||
<x:String x:Key="Text.Period.HourAgo" xml:space="preserve">1 hora atrás</x:String>
|
||||
<x:String x:Key="Text.Period.HoursAgo" xml:space="preserve">{0} horas atrás</x:String>
|
||||
<x:String x:Key="Text.Period.Yesterday" xml:space="preserve">Ontem</x:String>
|
||||
<x:String x:Key="Text.Period.DaysAgo" xml:space="preserve">{0} dias atrás</x:String>
|
||||
|
|
|
@ -448,6 +448,7 @@
|
|||
<x:String x:Key="Text.Paste" xml:space="preserve">Вставить</x:String>
|
||||
<x:String x:Key="Text.Period.JustNow" xml:space="preserve">Сейчас</x:String>
|
||||
<x:String x:Key="Text.Period.MinutesAgo" xml:space="preserve">{0} минут назад</x:String>
|
||||
<x:String x:Key="Text.Period.HourAgo" xml:space="preserve">1 час назад</x:String>
|
||||
<x:String x:Key="Text.Period.HoursAgo" xml:space="preserve">{0} часов назад</x:String>
|
||||
<x:String x:Key="Text.Period.Yesterday" xml:space="preserve">Вчера</x:String>
|
||||
<x:String x:Key="Text.Period.DaysAgo" xml:space="preserve">{0} дней назад</x:String>
|
||||
|
|
|
@ -447,6 +447,7 @@
|
|||
<x:String x:Key="Text.Paste" xml:space="preserve">粘贴</x:String>
|
||||
<x:String x:Key="Text.Period.JustNow" xml:space="preserve">刚刚</x:String>
|
||||
<x:String x:Key="Text.Period.MinutesAgo" xml:space="preserve">{0}分钟前</x:String>
|
||||
<x:String x:Key="Text.Period.HourAgo" xml:space="preserve">1小时前</x:String>
|
||||
<x:String x:Key="Text.Period.HoursAgo" xml:space="preserve">{0}小时前</x:String>
|
||||
<x:String x:Key="Text.Period.Yesterday" xml:space="preserve">昨天</x:String>
|
||||
<x:String x:Key="Text.Period.DaysAgo" xml:space="preserve">{0}天前</x:String>
|
||||
|
|
|
@ -447,6 +447,7 @@
|
|||
<x:String x:Key="Text.Paste" xml:space="preserve">貼上</x:String>
|
||||
<x:String x:Key="Text.Period.JustNow" xml:space="preserve">剛剛</x:String>
|
||||
<x:String x:Key="Text.Period.MinutesAgo" xml:space="preserve">{0} 分鐘前</x:String>
|
||||
<x:String x:Key="Text.Period.HourAgo" xml:space="preserve">1 小時前</x:String>
|
||||
<x:String x:Key="Text.Period.HoursAgo" xml:space="preserve">{0} 小時前</x:String>
|
||||
<x:String x:Key="Text.Period.Yesterday" xml:space="preserve">昨天</x:String>
|
||||
<x:String x:Key="Text.Period.DaysAgo" xml:space="preserve">{0} 天前</x:String>
|
||||
|
|
|
@ -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