mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-23 19:11:58 +01:00
Fix heatmap localization
Fixes #2552
(cherry picked from commit 708f4bc3b6
)
This commit is contained in:
parent
cc1c000ac8
commit
26e4af4268
25 changed files with 57 additions and 33 deletions
|
@ -1535,7 +1535,7 @@ filter.container.tagged = موسوم
|
|||
[heatmap]
|
||||
less = أقل
|
||||
number_of_contributions_in_the_last_12_months = %s مساهم في آخر 12 شهر
|
||||
no_contributions = بلا مساهمات
|
||||
contributions_zero = بلا مساهمات
|
||||
more = أكثر
|
||||
|
||||
[admin]
|
||||
|
|
|
@ -1357,7 +1357,7 @@ runners.description = Описание
|
|||
[heatmap]
|
||||
less = По-малко
|
||||
number_of_contributions_in_the_last_12_months = %s приноса през последните 12 месеца
|
||||
no_contributions = Няма приноси
|
||||
contributions_zero = Няма приноси
|
||||
more = Повече
|
||||
|
||||
[git.filemode]
|
||||
|
@ -1382,4 +1382,4 @@ recent_commits.what = скорошни подавания
|
|||
component_loading = Зареждане на %s...
|
||||
|
||||
[projects]
|
||||
type-1.display_name = Индивидуален проект
|
||||
type-1.display_name = Индивидуален проект
|
||||
|
|
|
@ -166,7 +166,7 @@ footer.links=Odkazy
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=%s příspěvků za posledních 12 měsíců
|
||||
no_contributions=Žádné příspěvky
|
||||
contributions_zero=Žádné příspěvky
|
||||
less=Méně
|
||||
more=Více
|
||||
|
||||
|
|
|
@ -164,7 +164,7 @@ footer.links=Links
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=%s Beiträge in den letzten 12 Monaten
|
||||
no_contributions=Keine Beiträge
|
||||
contributions_zero=Keine Beiträge
|
||||
less=Weniger
|
||||
more=Mehr
|
||||
|
||||
|
|
|
@ -163,7 +163,7 @@ footer.links=Συνδέσεις
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=%s συνεισφορές τους τελευταίους 12 μήνες
|
||||
no_contributions=Χωρίς συνεισφορές
|
||||
contributions_zero=Χωρίς συνεισφορές
|
||||
less=Λιγότερα
|
||||
more=Περισσότερα
|
||||
|
||||
|
|
|
@ -164,7 +164,10 @@ footer.links = Links
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months = %s contributions in the last 12 months
|
||||
no_contributions = No contributions
|
||||
contributions_zero = No contributions
|
||||
contributions_format = {contributions} on {month} {day}, {year}
|
||||
contributions_one = contribution
|
||||
contributions_few = contributions
|
||||
less = Less
|
||||
more = More
|
||||
|
||||
|
|
|
@ -174,7 +174,7 @@ server_internal = Eraris interno de servilo
|
|||
[heatmap]
|
||||
less = Malpli
|
||||
number_of_contributions_in_the_last_12_months = %s kontribuoj dum la pasintaj 12 monatoj
|
||||
no_contributions = Neniu kontribuo
|
||||
contributions_zero = Neniu kontribuo
|
||||
more = Pli
|
||||
|
||||
[startpage]
|
||||
|
|
|
@ -150,7 +150,7 @@ footer.links=Enlaces
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=%s contribuciones en los últimos 12 meses
|
||||
no_contributions=No hay contribuciones
|
||||
contributions_zero=No hay contribuciones
|
||||
less=Menos
|
||||
more=Más
|
||||
|
||||
|
|
|
@ -165,7 +165,7 @@ footer.links=Liens
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=%s contributions au cours des 12 derniers mois
|
||||
no_contributions=Aucune contribution
|
||||
contributions_zero=Aucune contribution
|
||||
less=Moins
|
||||
more=Plus
|
||||
|
||||
|
@ -3743,4 +3743,4 @@ contributors.what = contributions
|
|||
component_loading = Chargement %s...
|
||||
component_loading_failed = Échec de chargement de %s
|
||||
code_frequency.what = fŕequence de code
|
||||
recent_commits.what = commits récents
|
||||
recent_commits.what = commits récents
|
||||
|
|
|
@ -131,7 +131,7 @@ footer.software = Sobre o Software
|
|||
footer.links = Ligazóns
|
||||
|
||||
[heatmap]
|
||||
no_contributions = Sen Achegas
|
||||
contributions_zero = Sen Achegas
|
||||
less = Menos
|
||||
more = Máis
|
||||
number_of_contributions_in_the_last_12_months = %s de contribucións nos últimos 12 meses
|
||||
|
@ -140,4 +140,4 @@ number_of_contributions_in_the_last_12_months = %s de contribucións nos último
|
|||
buttons.heading.tooltip = Engadir Título
|
||||
buttons.italic.tooltip = Engade texto en cursiva
|
||||
buttons.quote.tooltip = Texto de cita
|
||||
buttons.bold.tooltip = Engadir texto en negriña
|
||||
buttons.bold.tooltip = Engadir texto en negriña
|
||||
|
|
|
@ -164,7 +164,7 @@ footer.software = A proposito del Software
|
|||
|
||||
[heatmap]
|
||||
more = Più
|
||||
no_contributions = Nessun contributo
|
||||
contributions_zero = Nessun contributo
|
||||
less = Meno
|
||||
number_of_contributions_in_the_last_12_months = %s contributi negli ultimi 12 mesi
|
||||
|
||||
|
|
|
@ -164,7 +164,7 @@ footer.links=リンク
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=過去 12 か月間で %s 件の貢献
|
||||
no_contributions=貢献なし
|
||||
contributions_zero=貢献なし
|
||||
less=少
|
||||
more=多
|
||||
|
||||
|
|
|
@ -150,7 +150,7 @@ footer.links=Saites
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=%s darbības pēdējo 12 mēnešu laikā
|
||||
no_contributions=Nav aktivitātes
|
||||
contributions_zero=Nav aktivitātes
|
||||
less=Mazāk
|
||||
more=Vairāk
|
||||
|
||||
|
|
|
@ -164,7 +164,7 @@ footer.links = Verwijzingen
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months = %s contributies in de laatste 12 maanden
|
||||
no_contributions = Geen contributies
|
||||
contributions_zero = Geen contributies
|
||||
less = Minder
|
||||
more = Meer
|
||||
|
||||
|
|
|
@ -157,7 +157,7 @@ footer.links=Links
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=%s contribuições nos últimos 12 meses
|
||||
no_contributions=Sem contribuições
|
||||
contributions_zero=Sem contribuições
|
||||
less=Menos
|
||||
more=Mais
|
||||
|
||||
|
@ -3585,4 +3585,4 @@ executable_file = Arquivo executável
|
|||
component_loading = Carregando %s...
|
||||
component_loading_failed = Não foi possível carregar o(a) %s
|
||||
component_loading_info = Pode demorar um pouco…
|
||||
contributors.what = contribuições
|
||||
contributors.what = contribuições
|
||||
|
|
|
@ -151,7 +151,7 @@ footer.links=Ligações
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=%s contribuições nos últimos 12 meses
|
||||
no_contributions=Nenhuma contribuição
|
||||
contributions_zero=Nenhuma contribuição
|
||||
less=Menos
|
||||
more=Mais
|
||||
|
||||
|
|
|
@ -164,7 +164,10 @@ footer.links=Ссылки
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=Принимал(а) участие %s раз за последние 12 месяцев
|
||||
no_contributions=Не принимал(а) участия
|
||||
contributions_zero=Действий не было
|
||||
contributions_format = {contributions} {day} {month} {year}
|
||||
contributions_one=действие
|
||||
contributions_few=действий
|
||||
less=Меньше
|
||||
more=Больше
|
||||
|
||||
|
|
|
@ -149,7 +149,7 @@ footer.links=Odkazy
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=%s príspevkov za posledných 12 mesiacov
|
||||
no_contributions=Žiadne príspevky
|
||||
contributions_zero=Žiadne príspevky
|
||||
less=Menej
|
||||
more=Viac
|
||||
|
||||
|
|
|
@ -377,7 +377,7 @@ gpg_key_verified_long = Ključ je bil preverjen z žetonom in ga je mogoče upor
|
|||
[heatmap]
|
||||
less = Manj
|
||||
number_of_contributions_in_the_last_12_months = %s prispevkov v zadnjih 12 mesecih
|
||||
no_contributions = Ni prispevkov
|
||||
contributions_zero = Ni prispevkov
|
||||
more = Več
|
||||
|
||||
[filter]
|
||||
|
@ -691,4 +691,4 @@ code = Koda
|
|||
owner.settings.chef.keypair.description = Za preverjanje pristnosti v registru Chef je potreben par ključev. Če ste par ključev ustvarili že prej, se pri ustvarjanju novega para ključev stari par ključev zavrže.
|
||||
|
||||
[actions]
|
||||
runners.runner_manage_panel = Upravljanje tekačev
|
||||
runners.runner_manage_panel = Upravljanje tekačev
|
||||
|
|
|
@ -150,7 +150,7 @@ footer.links=Bağlantılar
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=son 12 ayda %s katkı
|
||||
no_contributions=Katkı yapılmamış
|
||||
contributions_zero=Katkı yapılmamış
|
||||
less=Daha az
|
||||
more=Daha Fazla
|
||||
|
||||
|
|
|
@ -164,7 +164,7 @@ footer.links=链接
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=一年内 %s 次贡献
|
||||
no_contributions=目前还没有贡献。
|
||||
contributions_zero=目前还没有贡献。
|
||||
less=更少的
|
||||
more=更多的
|
||||
|
||||
|
|
|
@ -164,7 +164,7 @@ footer.links=連結
|
|||
|
||||
[heatmap]
|
||||
number_of_contributions_in_the_last_12_months=過去十二個月內有 %s 個貢獻
|
||||
no_contributions=沒有貢獻
|
||||
contributions_zero=沒有貢獻
|
||||
less=少
|
||||
more=多
|
||||
|
||||
|
|
|
@ -2,7 +2,10 @@
|
|||
<div id="user-heatmap" class="is-loading"
|
||||
data-heatmap-data="{{JsonUtils.EncodeToString .HeatmapData}}"
|
||||
data-locale-total-contributions="{{ctx.Locale.Tr "heatmap.number_of_contributions_in_the_last_12_months" (ctx.Locale.PrettyNumber .HeatmapTotalContributions)}}"
|
||||
data-locale-no-contributions="{{ctx.Locale.Tr "heatmap.no_contributions"}}"
|
||||
data-locale-contributions-zero="{{ctx.Locale.Tr "heatmap.contributions_zero"}}"
|
||||
data-locale-contributions-format="{{ctx.Locale.Tr "heatmap.contributions_format"}}"
|
||||
data-locale-contributions-one="{{ctx.Locale.Tr "heatmap.contributions_one"}}"
|
||||
data-locale-contributions-few="{{ctx.Locale.Tr "heatmap.contributions_few"}}"
|
||||
data-locale-more="{{ctx.Locale.Tr "heatmap.more"}}"
|
||||
data-locale-less="{{ctx.Locale.Tr "heatmap.less"}}"
|
||||
></div>
|
||||
|
|
|
@ -59,8 +59,22 @@ export default {
|
|||
</div>
|
||||
<calendar-heatmap
|
||||
:locale="locale"
|
||||
:no-data-text="locale.no_contributions"
|
||||
:tooltip-unit="locale.contributions"
|
||||
:no-data-text="locale.contributions_zero"
|
||||
:tooltip-formatter="
|
||||
(v) =>
|
||||
locale.contributions_format
|
||||
.replace(
|
||||
'{contributions}',
|
||||
`<b>${v.count} ${
|
||||
v.count === 1
|
||||
? locale.contributions_one
|
||||
: locale.contributions_few
|
||||
}</b>`
|
||||
)
|
||||
.replace('{month}', locale.months[v.date.getMonth()])
|
||||
.replace('{day}', v.date.getDate())
|
||||
.replace('{year}', v.date.getFullYear())
|
||||
"
|
||||
:end-date="endDate"
|
||||
:values="values"
|
||||
:range-color="colorRange"
|
||||
|
|
|
@ -18,13 +18,14 @@ export function initHeatmap() {
|
|||
return {date: new Date(v), count: heatmap[v]};
|
||||
});
|
||||
|
||||
// last heatmap tooltip localization attempt https://github.com/go-gitea/gitea/pull/24131/commits/a83761cbbae3c2e3b4bced71e680f44432073ac8
|
||||
const locale = {
|
||||
months: new Array(12).fill().map((_, idx) => translateMonth(idx)),
|
||||
days: new Array(7).fill().map((_, idx) => translateDay(idx)),
|
||||
contributions: 'contributions',
|
||||
contributions_in_the_last_12_months: el.getAttribute('data-locale-total-contributions'),
|
||||
no_contributions: el.getAttribute('data-locale-no-contributions'),
|
||||
contributions_zero: el.getAttribute('data-locale-contributions-zero'),
|
||||
contributions_format: el.getAttribute('data-locale-contributions-format'),
|
||||
contributions_one: el.getAttribute('data-locale-contributions-one'),
|
||||
contributions_few: el.getAttribute('data-locale-contributions-few'),
|
||||
more: el.getAttribute('data-locale-more'),
|
||||
less: el.getAttribute('data-locale-less'),
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue