vue-intlayer 9.5.4-canary.0 → 9.5.5
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/README.md
CHANGED
|
@@ -188,7 +188,8 @@ Explore our comprehensive documentation to get started with Intlayer and learn h
|
|
|
188
188
|
<li><a href="https://intlayer.org/doc/environment/create-react-app" rel=''>React CRA</a></li>
|
|
189
189
|
<li><a href="https://intlayer.org/doc/environment/vite-and-react" rel=''>Vite + React</a></li>
|
|
190
190
|
<li><a href="https://intlayer.org/doc/environment/vite-and-react" rel=''>Vite + React using Compiler</a></li>
|
|
191
|
-
<li><a href="https://intlayer.org/doc/environment/vite-and-react/
|
|
191
|
+
<li><a href="https://intlayer.org/doc/environment/vite-and-react/react-router-v7" rel=''>React-router-v7</a></li>
|
|
192
|
+
<li><a href="https://intlayer.org/doc/environment/remix-3" rel=''>Remix 3</a></li>
|
|
192
193
|
<li><a href="https://intlayer.org/doc/environment/tanstack-start" rel=''>Tanstack start</a>
|
|
193
194
|
<ul>
|
|
194
195
|
<li><a href="https://intlayer.org/doc/environment/tanstack-start/solid" rel=''>Solid</a></li>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./installIntlayer.cjs"),t=require("./useDictionary.cjs");let n=require("@intlayer/config/built"),r=require("vue"),i=require("@intlayer/core/dictionaryManipulator");var a=async(a,o)=>{let s=(0,r.inject)(e.INTLAYER_SYMBOL),c=(0,r.computed)(()=>o??s?.locale?.value??n.internationalization.defaultLocale),l=(0,i.getPreloadedDictionary)(a,c.value),u=(0,r.ref)(l??await a[c.value]?.());return(0,r.watch)(()=>c.value,async e=>{let t=await a[e]?.();t&&(u.value=t)}),t.useDictionary(u,c)};exports.useDictionaryAsync=a;
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./installIntlayer.cjs"),t=require("./useDictionary.cjs");let n=require("@intlayer/config/built"),r=require("vue"),i=require("@intlayer/core/dictionaryManipulator");var a=async(a,o)=>{let s=(0,r.inject)(e.INTLAYER_SYMBOL),c=(0,r.computed)(()=>(0,r.toValue)(o)??s?.locale?.value??n.internationalization.defaultLocale),l=(0,i.getPreloadedDictionary)(a,c.value),u=(0,r.ref)(l??await a[c.value]?.());return(0,r.watch)(()=>c.value,async e=>{let t=await a[e]?.();t&&(u.value=t)}),t.useDictionary(u,c)};exports.useDictionaryAsync=a;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { INTLAYER_SYMBOL as e } from "./installIntlayer.mjs";
|
|
2
2
|
import { useDictionary as t } from "./useDictionary.mjs";
|
|
3
3
|
import { internationalization as n } from "@intlayer/config/built";
|
|
4
|
-
import { computed as r, inject as i, ref as a,
|
|
5
|
-
import { getPreloadedDictionary as
|
|
4
|
+
import { computed as r, inject as i, ref as a, toValue as o, watch as s } from "vue";
|
|
5
|
+
import { getPreloadedDictionary as c } from "@intlayer/core/dictionaryManipulator";
|
|
6
6
|
//#region src/client/useDictionaryAsync.ts
|
|
7
|
-
var
|
|
8
|
-
let
|
|
9
|
-
return
|
|
10
|
-
let t = await
|
|
11
|
-
t && (
|
|
12
|
-
}), t(
|
|
7
|
+
var l = async (l, u) => {
|
|
8
|
+
let d = i(e), f = r(() => o(u) ?? d?.locale?.value ?? n.defaultLocale), p = c(l, f.value), m = a(p ?? await l[f.value]?.());
|
|
9
|
+
return s(() => f.value, async (e) => {
|
|
10
|
+
let t = await l[e]?.();
|
|
11
|
+
t && (m.value = t);
|
|
12
|
+
}), t(m, f);
|
|
13
13
|
};
|
|
14
14
|
//#endregion
|
|
15
|
-
export {
|
|
15
|
+
export { l as useDictionaryAsync };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { QualifiedDynamicLoaderMap } from '@intlayer/core/dictionaryManipulator';
|
|
2
2
|
import { Dictionary } from '@intlayer/types/dictionary';
|
|
3
|
-
import { DictionaryKeys, DictionarySelectorForKey, LocalesValues, StrictModeLocaleMap } from '@intlayer/types/module_augmentation';
|
|
3
|
+
import { DeclaredLocales, DictionaryKeys, DictionarySelectorForKey, LocalesValues, StrictModeLocaleMap } from '@intlayer/types/module_augmentation';
|
|
4
4
|
import { MaybeRefOrGetter } from 'vue';
|
|
5
5
|
/**
|
|
6
6
|
* Lazily loads a dictionary (plain or qualified) and returns its content.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vue-intlayer",
|
|
3
|
-
"version": "9.5.
|
|
3
|
+
"version": "9.5.5",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Easily internationalize i18n your Vue applications with type-safe multilingual content management.",
|
|
6
6
|
"keywords": [
|
|
@@ -103,12 +103,12 @@
|
|
|
103
103
|
"typecheck": "vue-tsc --noEmit --project tsconfig.types.json"
|
|
104
104
|
},
|
|
105
105
|
"dependencies": {
|
|
106
|
-
"@intlayer/api": "9.5.
|
|
107
|
-
"@intlayer/config": "9.5.
|
|
108
|
-
"@intlayer/core": "9.5.
|
|
109
|
-
"@intlayer/dictionaries-entry": "9.5.
|
|
110
|
-
"@intlayer/editor": "9.5.
|
|
111
|
-
"@intlayer/types": "9.5.
|
|
106
|
+
"@intlayer/api": "9.5.5",
|
|
107
|
+
"@intlayer/config": "9.5.5",
|
|
108
|
+
"@intlayer/core": "9.5.5",
|
|
109
|
+
"@intlayer/dictionaries-entry": "9.5.5",
|
|
110
|
+
"@intlayer/editor": "9.5.5",
|
|
111
|
+
"@intlayer/types": "9.5.5",
|
|
112
112
|
"@vue/devtools-api": "^6.6.4"
|
|
113
113
|
},
|
|
114
114
|
"devDependencies": {
|
|
@@ -128,7 +128,7 @@
|
|
|
128
128
|
"vue-tsc": "3.3.9"
|
|
129
129
|
},
|
|
130
130
|
"peerDependencies": {
|
|
131
|
-
"intlayer": "9.5.
|
|
131
|
+
"intlayer": "9.5.5",
|
|
132
132
|
"vue": ">=3.0.0"
|
|
133
133
|
},
|
|
134
134
|
"peerDependenciesMeta": {
|
|
@@ -137,7 +137,7 @@
|
|
|
137
137
|
}
|
|
138
138
|
},
|
|
139
139
|
"optionalDependencies": {
|
|
140
|
-
"@intlayer/analytics": "9.5.
|
|
140
|
+
"@intlayer/analytics": "9.5.5"
|
|
141
141
|
},
|
|
142
142
|
"engines": {
|
|
143
143
|
"node": ">=14.18"
|