Skip to content

Commit 41ad363

Browse files
committed
v0.19.1; fixed issue with localization;
1 parent 1458803 commit 41ad363

File tree

4 files changed

+14
-11
lines changed

4 files changed

+14
-11
lines changed

www/scripts/sepiaFW.account.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -490,13 +490,13 @@ function sepiaFW_build_account(){
490490
});
491491
//id placeholder
492492
var idInput = document.getElementById("sepiaFW-login-id");
493-
idInput.placeholder = SepiaFW.local.username;
493+
idInput.placeholder = SepiaFW.local.g('username');
494494
$(idInput).off().on("keypress", function(e){
495495
if (e.keyCode === 13) { sendLoginFromBox(); }
496496
});
497497
//keypress on pwd
498498
var pwdInput = document.getElementById("sepiaFW-login-pwd");
499-
pwdInput.placeholder = SepiaFW.local.password;
499+
pwdInput.placeholder = SepiaFW.local.g('password');
500500
$(pwdInput).off().on("keypress", function (e) {
501501
if (e.keyCode === 13) { sendLoginFromBox(); }
502502
});

www/scripts/sepiaFW.local.js

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -302,20 +302,23 @@ function sepiaFW_build_strings(){
302302
//--------------------------------------------------------
303303

304304
var StringsLocale = {};
305-
if (SepiaFW.config.appLanguage.toLowerCase() === "de"){
306-
StringsLocale = StringsDE;
307-
}else{
308-
StringsLocale = StringsEN;
309-
}
310305

311306
//get string
312307
StringsLocale.g = function(name){
313-
return StringsLocale[name];
308+
if (SepiaFW.config.appLanguage.toLowerCase() === "de"){
309+
return StringsDE[name];
310+
}else{
311+
return StringsEN[name];
312+
}
314313
}
315314

316315
//write string
317316
StringsLocale.w = function(name){
318-
document.write(StringsLocale[name]);
317+
if (SepiaFW.config.appLanguage.toLowerCase() === "de"){
318+
document.write(StringsDE[name]);
319+
}else{
320+
document.write(StringsEN[name]);
321+
}
319322
}
320323

321324
//specials:

www/scripts/sepiaFW.ui.build.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ function sepiaFW_build_ui_build(){
285285
//Send message if enter is pressed in the input field
286286
var chatInput = document.getElementById("sepiaFW-chat-input");
287287
if (chatInput){
288-
chatInput.placeholder = SepiaFW.local.chatInputPlaceholder;
288+
chatInput.placeholder = SepiaFW.local.g('chatInputPlaceholder');
289289
$(chatInput).off()
290290
//pressed RETURN
291291
.on("keypress", function(e){

www/scripts/sepiaFW.ui.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ function sepiaFW_build_ui(){
33
var UI = {};
44

55
//some constants
6-
UI.version = "v0.19.0";
6+
UI.version = "v0.19.1";
77
UI.requiresServerVersion = "2.3.0";
88
UI.JQ_RES_VIEW_IDS = "#sepiaFW-result-view, #sepiaFW-chat-output, #sepiaFW-my-view"; //a selector to get all result views e.g. $(UI.JQ_RES_VIEW_IDS).find(...) - TODO: same as $('.sepiaFW-results-container') ??
99
UI.JQ_ALL_MAIN_VIEWS = "#sepiaFW-result-view, #sepiaFW-chat-output, #sepiaFW-my-view, #sepiaFW-teachUI-editor, #sepiaFW-teachUI-manager, #sepiaFW-frame-page-0, #sepiaFW-frame-page-1, #sepiaFW-frame-page-2, #sepiaFW-frame-page-3"; //TODO: frames can have more ...

0 commit comments

Comments
 (0)