Skip to content

Commit

Permalink
make 'Severity' translatable (via #2396)
Browse files Browse the repository at this point in the history
  • Loading branch information
noomorph authored Mar 14, 2024
1 parent 3fc7530 commit a59f8f1
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 8 deletions.
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
import { View } from "backbone.marionette";
import { escapeExpression } from "handlebars/runtime";
import { className } from "../../decorators/index";
import translate from "../../helpers/t";

@className("pane__section")
class SeverityView extends View {
template(data) {
return data.severity
? `${translate("testResult.severity.name")}: ${escapeExpression(data.severity)}`
template({ severity }) {
return severity
? `${translate("testResult.severity.name")}: ${translate(`testResult.severity.${severity}`)}`
: "";
}

Expand Down
7 changes: 6 additions & 1 deletion allure-generator/src/main/javascript/translations/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,12 @@
"time": "{{date}} at {{time}}"
},
"severity": {
"name": "Severity"
"name": "Severity",
"blocker": "blocker",
"critical": "critical",
"normal": "normal",
"minor": "minor",
"trivial": "trivial"
},
"stats": {
"count": {
Expand Down
7 changes: 6 additions & 1 deletion allure-generator/src/main/javascript/translations/isv.json
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,12 @@
"name": "Minule proby"
},
"severity": {
"name": "Važnost"
"name": "Važnost",
"blocker": "bloker",
"critical": "kritična",
"normal": "obyčajna",
"minor": "mala",
"trivial": "kosmetična"
},
"stats": {
"count": {
Expand Down
7 changes: 6 additions & 1 deletion allure-generator/src/main/javascript/translations/pl.json
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,12 @@
"name": "Powtórzenia"
},
"severity": {
"name": "Ważność"
"name": "Ważność",
"blocker": "bloker",
"critical": "krytyczna",
"normal": "zwyczajna",
"minor": "niewielka",
"trivial": "minimalna"
},
"stats": {
"count": {
Expand Down
7 changes: 6 additions & 1 deletion allure-generator/src/main/javascript/translations/ru.json
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,12 @@
"name": "Перезапуски"
},
"severity": {
"name": "Важность"
"name": "Важность",
"blocker": "блокер",
"critical": "критическая",
"normal": "обычная",
"minor": "невысокая",
"trivial": "минимальная"
},
"stats": {
"count": {
Expand Down

0 comments on commit a59f8f1

Please sign in to comment.