fix: i18n

This commit is contained in:
hydrogen 2020-11-24 22:55:23 +02:00 committed by Iuri Matias
parent a7936e984d
commit e2ec5fa84e
1 changed files with 3 additions and 3 deletions

View File

@ -10,12 +10,12 @@ Item {
width: childrenRect.width
function lastTwoItems(left, right) {
return left + " and " + right;
return qsTr("%1 and %2").arg(left, right);
}
function showReactionAuthors(fromAccounts) {
if (fromAccounts.length < 3)
return fromAccounts.join(" and ");
return fromAccounts.join(qsTr(" and "));
var leftNode = [];
var rightNode = [];
@ -25,7 +25,7 @@ Item {
rightNode = fromAccounts.slice(3, fromAccounts.length);
return (rightNode.length == 1) ?
lastTwoItems(leftNode.join(", "), rightNode[0]) :
lastTwoItems(leftNode.join(", "), `${rightNode.length} more reacted.`);
lastTwoItems(leftNode.join(", "), qsTr("%1 more reacted.").arg(rightNode.length));
}
leftNode = fromAccounts.slice(0, 2);