diff options
author | tomasz1986 <twilczynski@naver.com> | 2023-11-16 22:07:15 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-16 22:07:15 +0100 |
commit | 13d9317a386d172960dc9e2f39709d85bdfb22e1 (patch) | |
tree | a859a96c2556f26a4fccfb6d9b706041d2d8bd1f | |
parent | b184d46d8a3e0a6357cb5180f40cab241b05cb76 (diff) | |
download | syncthing-13d9317a386d172960dc9e2f39709d85bdfb22e1.tar.gz syncthing-13d9317a386d172960dc9e2f39709d85bdfb22e1.zip |
gui: Allow to translate "unknown device" (#9229)
The string is currently hard-coded in English, so allow to translate it
into other languages. It appears mainly in the browser title bar before
logging in into the GUI or when the GUI is still loading.
Signed-off-by: Tomasz WilczyĆski <twilczynski@naver.com>
-rw-r--r-- | gui/default/assets/lang/lang-en.json | 1 | ||||
-rwxr-xr-x | gui/default/syncthing/core/syncthingController.js | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/gui/default/assets/lang/lang-en.json b/gui/default/assets/lang/lang-en.json index 354437cd5..4a34c972f 100644 --- a/gui/default/assets/lang/lang-en.json +++ b/gui/default/assets/lang/lang-en.json @@ -545,6 +545,7 @@ "light": "Light" } }, + "unknown device": "unknown device", "{%device%} wants to share folder \"{%folder%}\".": "{{device}} wants to share folder \"{{folder}}\".", "{%device%} wants to share folder \"{%folderlabel%}\" ({%folder%}).": "{{device}} wants to share folder \"{{folderlabel}}\" ({{folder}}).", "{%reintroducer%} might reintroduce this device.": "{{reintroducer}} might reintroduce this device." diff --git a/gui/default/syncthing/core/syncthingController.js b/gui/default/syncthing/core/syncthingController.js index 6b4d18ab7..bc04e8fe2 100755 --- a/gui/default/syncthing/core/syncthingController.js +++ b/gui/default/syncthing/core/syncthingController.js @@ -1378,7 +1378,7 @@ angular.module('syncthing.core') $scope.thisDeviceName = function () { var device = $scope.thisDevice(); if (typeof device === 'undefined') { - return "(unknown device)"; + return '(' + $translate.instant("unknown device") + ')'; } if (device.name) { return device.name; |