Skip to content

Commit

Permalink
fix(translation): tableWindow title
Browse files Browse the repository at this point in the history
  • Loading branch information
Oliboy50 committed Aug 25, 2023
1 parent 2749405 commit 8529452
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
12 changes: 7 additions & 5 deletions velonimo.game.php
Original file line number Diff line number Diff line change
Expand Up @@ -1263,11 +1263,13 @@ function stEndRound() {
}
$this->notifyAllPlayers('tableWindow', '', [
'id' => 'finalScoring',
'title' => sprintf(
clienttranslate('Result of round %s/%s'),
$currentRound,
$howManyRounds
),
'title' => [
'str' => clienttranslate('Result of round ${currentRound}/${howManyRounds}'),
'args' => [
'currentRound' => $currentRound,
'howManyRounds' => $howManyRounds,
],
],
'table' => [
$headers,
$previousPoints,
Expand Down
6 changes: 6 additions & 0 deletions velonimo.js
Original file line number Diff line number Diff line change
Expand Up @@ -3276,6 +3276,12 @@ function (dojo, declare) {
///////////////////////////////////////////////////
//// Reaction to cometD notifications
///////////////////////////////////////////////////
ntf_tableWindow: function (notif) {
if(typeof notif.args.title === 'object'){
notif.args.title = this.format_string_recursive(notif.args.title.str, notif.args.title.args);
}
this.inherited(arguments);
},
setupNotifications: function () {
const isReadOnly = this.isReadOnly();
[
Expand Down

0 comments on commit 8529452

Please sign in to comment.