@empathyco/x-archetype-utils 2.0.0-alpha.2 → 2.0.0-alpha.4
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.
|
@@ -40,6 +40,7 @@ class I18n {
|
|
|
40
40
|
*/
|
|
41
41
|
install(vue) {
|
|
42
42
|
this.vueI18n = vueI18n.createI18n({
|
|
43
|
+
legacy: false,
|
|
43
44
|
locale: this.locale,
|
|
44
45
|
silentFallbackWarn: true,
|
|
45
46
|
messages: this.currentMessages ? { [this.locale]: this.currentMessages } : {},
|
|
@@ -82,7 +83,7 @@ class I18n {
|
|
|
82
83
|
if (this.locale !== newLocale) {
|
|
83
84
|
this.locale = newLocale;
|
|
84
85
|
await this.changeMessages();
|
|
85
|
-
this.vueI18n.global.locale = this.locale;
|
|
86
|
+
this.vueI18n.global.locale.value = this.locale;
|
|
86
87
|
}
|
|
87
88
|
}
|
|
88
89
|
/**
|
|
@@ -38,6 +38,7 @@ class I18n {
|
|
|
38
38
|
*/
|
|
39
39
|
install(vue) {
|
|
40
40
|
this.vueI18n = createI18n({
|
|
41
|
+
legacy: false,
|
|
41
42
|
locale: this.locale,
|
|
42
43
|
silentFallbackWarn: true,
|
|
43
44
|
messages: this.currentMessages ? { [this.locale]: this.currentMessages } : {},
|
|
@@ -80,7 +81,7 @@ class I18n {
|
|
|
80
81
|
if (this.locale !== newLocale) {
|
|
81
82
|
this.locale = newLocale;
|
|
82
83
|
await this.changeMessages();
|
|
83
|
-
this.vueI18n.global.locale = this.locale;
|
|
84
|
+
this.vueI18n.global.locale.value = this.locale;
|
|
84
85
|
}
|
|
85
86
|
}
|
|
86
87
|
/**
|
|
@@ -7,7 +7,7 @@ import { AnyMessages, Device, I18nOptions, Locale } from './i18n.types';
|
|
|
7
7
|
* @public
|
|
8
8
|
*/
|
|
9
9
|
export declare class I18n<SomeMessages> {
|
|
10
|
-
vueI18n: VueI18n
|
|
10
|
+
vueI18n: VueI18n<Record<string, unknown>, Record<string, unknown>, Record<string, unknown>, Locale, false>;
|
|
11
11
|
protected locale: Locale;
|
|
12
12
|
protected device: Device;
|
|
13
13
|
protected messages: Record<Locale, AnyMessages<SomeMessages>>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@empathyco/x-archetype-utils",
|
|
3
|
-
"version": "2.0.0-alpha.
|
|
3
|
+
"version": "2.0.0-alpha.4",
|
|
4
4
|
"description": "Utilities for x-archetype",
|
|
5
5
|
"author": "Empathy Systems Corporation S.L.",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -36,24 +36,24 @@
|
|
|
36
36
|
"prepublishOnly": "pnpm run build"
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@empathyco/x-deep-merge": "^2.0.3-alpha.
|
|
39
|
+
"@empathyco/x-deep-merge": "^2.0.3-alpha.2",
|
|
40
40
|
"@empathyco/x-utils": "^1.0.3-alpha.1",
|
|
41
41
|
"tslib": "~2.6.0",
|
|
42
42
|
"vue-i18n": "~9.14.0"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
|
-
"@types/jest": "
|
|
46
|
-
"@types/node": "
|
|
45
|
+
"@types/jest": "27.5.0",
|
|
46
|
+
"@types/node": "18.19.0",
|
|
47
47
|
"@vue/test-utils": "~2.4.6",
|
|
48
|
-
"jest": "
|
|
49
|
-
"rimraf": "
|
|
50
|
-
"rollup": "
|
|
51
|
-
"rollup-plugin-copy": "
|
|
52
|
-
"rollup-plugin-delete": "
|
|
53
|
-
"rollup-plugin-typescript2": "
|
|
54
|
-
"ts-jest": "
|
|
55
|
-
"typescript": "
|
|
56
|
-
"vue": "
|
|
48
|
+
"jest": "27.5.0",
|
|
49
|
+
"rimraf": "3.0.2",
|
|
50
|
+
"rollup": "4.9.1",
|
|
51
|
+
"rollup-plugin-copy": "3.5.0",
|
|
52
|
+
"rollup-plugin-delete": "2.0.0",
|
|
53
|
+
"rollup-plugin-typescript2": "0.36.0",
|
|
54
|
+
"ts-jest": "27.1.0",
|
|
55
|
+
"typescript": "4.9.4",
|
|
56
|
+
"vue": "3.4.31"
|
|
57
57
|
},
|
|
58
58
|
"peerDependencies": {
|
|
59
59
|
"vue": "^3.4.31",
|
|
@@ -62,5 +62,5 @@
|
|
|
62
62
|
"publishConfig": {
|
|
63
63
|
"access": "public"
|
|
64
64
|
},
|
|
65
|
-
"gitHead": "
|
|
65
|
+
"gitHead": "782271b380929cc378d5414ebeaa98d1e4cd7858"
|
|
66
66
|
}
|