qcobjects-sdk 2.4.44 → 2.4.45
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/VERSION +1 -1
- package/package.json +1 -1
- package/src/js/org.qcobjects.i18n_messages.js +31 -27
package/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
2.4.
|
|
1
|
+
2.4.45
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "qcobjects-sdk",
|
|
3
|
-
"version": "2.4.
|
|
3
|
+
"version": "2.4.45",
|
|
4
4
|
"description": "QCObjects SDK is a set of Controllers, Views and Components that are elementary and useful to assist developers to build applications under MVC patterns using QCObjects, Cross Browser Javascript Framework for MVC Patterns",
|
|
5
5
|
"main": "src/index.cjs",
|
|
6
6
|
"module": "src/index.mjs",
|
|
@@ -21,37 +21,41 @@
|
|
|
21
21
|
*
|
|
22
22
|
* Everyone is permitted to copy and distribute verbatim copies of this
|
|
23
23
|
* license document, but changing it is not allowed.
|
|
24
|
-
*/
|
|
25
|
-
(function() {
|
|
26
|
-
"use strict";
|
|
27
|
-
Package("org.qcobjects.i18n_messages", [
|
|
24
|
+
*/
|
|
25
|
+
(function () {
|
|
26
|
+
"use strict";
|
|
27
|
+
Package("org.qcobjects.i18n_messages", [
|
|
28
28
|
|
|
29
|
-
|
|
29
|
+
class i18n_messages extends InheritClass {
|
|
30
30
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
31
|
+
constructor({
|
|
32
|
+
messages = []
|
|
33
|
+
}) {
|
|
34
|
+
super({
|
|
35
|
+
messages
|
|
36
|
+
});
|
|
37
|
+
if (CONFIG.get("use_i18n")) {
|
|
38
|
+
CONFIG.set("lang", "en");
|
|
39
|
+
if (!global.get("i18n")) {
|
|
40
|
+
global.set("i18n", {
|
|
41
|
+
messages: messages
|
|
42
|
+
});
|
|
43
|
+
} else {
|
|
44
|
+
global.set("i18n", {
|
|
45
|
+
messages: global.get("i18n").messages.concat(messages)
|
|
46
|
+
});
|
|
47
|
+
}
|
|
43
48
|
}
|
|
49
|
+
|
|
44
50
|
}
|
|
45
51
|
|
|
46
|
-
|
|
52
|
+
_load_i18n_packages_() {
|
|
53
|
+
return CONFIG.get("i18n_languages", []).map((i18n_packagename) => {
|
|
54
|
+
Import(`org.quickcorp.i18n_messages.${i18n_packagename}`);
|
|
55
|
+
});
|
|
56
|
+
}
|
|
47
57
|
|
|
48
|
-
_load_i18n_packages_ (){
|
|
49
|
-
return CONFIG.get("i18n_languages",[]).map((i18n_packagename)=>{
|
|
50
|
-
Import(`org.quickcorp.i18n_messages.${i18n_packagename}`);
|
|
51
|
-
});
|
|
52
58
|
}
|
|
53
|
-
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
(new i18n_messages())._load_i18n_packages_();
|
|
57
|
-
}).call(null);
|
|
59
|
+
]);
|
|
60
|
+
(new i18n_messages({}))._load_i18n_packages_();
|
|
61
|
+
}).call(null);
|