@intlayer/nuxtjs-i18n 9.7.0 → 9.7.1
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/dist/esm/constants.mjs +1 -2
- package/dist/esm/module.mjs +1 -2
- package/dist/esm/runtime/NuxtLinkLocale.mjs +1 -2
- package/dist/esm/runtime/composer.mjs +2 -3
- package/dist/esm/runtime/define.mjs +1 -2
- package/dist/esm/runtime/index.mjs +2 -2
- package/dist/esm/runtime/nuxtPlugin.mjs +1 -2
- package/dist/esm/runtime/routing.mjs +2 -3
- package/dist/types/constants.d.ts +0 -2
- package/dist/types/constants.d.ts.map +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/module.d.ts +0 -2
- package/dist/types/module.d.ts.map +1 -1
- package/dist/types/runtime/NuxtLinkLocale.d.ts +0 -2
- package/dist/types/runtime/NuxtLinkLocale.d.ts.map +1 -1
- package/dist/types/runtime/composer.d.ts +1 -2
- package/dist/types/runtime/composer.d.ts.map +1 -1
- package/dist/types/runtime/define.d.ts +0 -2
- package/dist/types/runtime/define.d.ts.map +1 -1
- package/dist/types/runtime/index.d.ts +1 -1
- package/dist/types/runtime/nuxtPlugin.d.ts +0 -2
- package/dist/types/runtime/nuxtPlugin.d.ts.map +1 -1
- package/dist/types/runtime/nuxtVirtualModules.d.ts +0 -1
- package/dist/types/runtime/nuxtVirtualModules.d.ts.map +1 -1
- package/dist/types/runtime/routing.d.ts +0 -2
- package/dist/types/runtime/routing.d.ts.map +1 -1
- package/dist/types/types.d.ts +0 -2
- package/dist/types/types.d.ts.map +1 -1
- package/package.json +14 -14
package/dist/esm/constants.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/constants.ts
|
|
2
2
|
const STRATEGY_PREFIX = "prefix";
|
|
3
3
|
const STRATEGY_PREFIX_EXCEPT_DEFAULT = "prefix_except_default";
|
|
4
4
|
const STRATEGY_PREFIX_AND_DEFAULT = "prefix_and_default";
|
|
@@ -10,6 +10,5 @@ const STRATEGIES = {
|
|
|
10
10
|
NO_PREFIX: "no_prefix"
|
|
11
11
|
};
|
|
12
12
|
|
|
13
|
-
//#endregion
|
|
14
13
|
export { STRATEGIES, STRATEGY_NO_PREFIX, STRATEGY_PREFIX, STRATEGY_PREFIX_AND_DEFAULT, STRATEGY_PREFIX_EXCEPT_DEFAULT };
|
|
15
14
|
//# sourceMappingURL=constants.mjs.map
|
package/dist/esm/module.mjs
CHANGED
|
@@ -2,7 +2,7 @@ import { NUXTJS_I18N_CALLERS } from "@intlayer/config/callers";
|
|
|
2
2
|
import { addComponent, addImports, addPlugin, createResolver, defineNuxtModule, installModule } from "@nuxt/kit";
|
|
3
3
|
import nuxtIntlayerModule from "nuxt-intlayer";
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
// src/module.ts
|
|
6
6
|
/** Specifier of the client runtime, as auto-imports and the registry see it. */
|
|
7
7
|
const RUNTIME_MODULE = "@intlayer/nuxtjs-i18n/runtime";
|
|
8
8
|
/** Composables and helpers @nuxtjs/i18n auto-imports. */
|
|
@@ -70,6 +70,5 @@ const nuxtjsI18nModule = defineNuxtModule({
|
|
|
70
70
|
}
|
|
71
71
|
});
|
|
72
72
|
|
|
73
|
-
//#endregion
|
|
74
73
|
export { nuxtjsI18nModule as default, nuxtjsI18nModule };
|
|
75
74
|
//# sourceMappingURL=module.mjs.map
|
|
@@ -2,7 +2,7 @@ import { useLocalePath } from "./routing.mjs";
|
|
|
2
2
|
import { defineComponent, h } from "vue";
|
|
3
3
|
import { NuxtLink } from "#components";
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
// src/runtime/NuxtLinkLocale.ts
|
|
6
6
|
/**
|
|
7
7
|
* `<NuxtLinkLocale to="/about" locale="fr">` — a `<NuxtLink>` whose target
|
|
8
8
|
* is localized for the active (or given) locale.
|
|
@@ -37,6 +37,5 @@ const NuxtLinkLocale = defineComponent({
|
|
|
37
37
|
}
|
|
38
38
|
});
|
|
39
39
|
|
|
40
|
-
//#endregion
|
|
41
40
|
export { NuxtLinkLocale };
|
|
42
41
|
//# sourceMappingURL=NuxtLinkLocale.mjs.map
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { defaultLocale, detectBrowserLocale, getActiveLocale, getCurrentFullPath, getRouter, localeCodes, localizeFullPath, strategy } from "./routing.mjs";
|
|
2
|
+
import { computed } from "vue";
|
|
2
3
|
import { getHTMLTextDir, getLocaleName } from "@intlayer/core/localization";
|
|
3
4
|
import { getCachedLocaleFromStorageClient, localeStorageOptions, setLocaleInStorageClient } from "@intlayer/core/utils";
|
|
4
|
-
import { computed } from "vue";
|
|
5
5
|
import { createIntlayerClient } from "vue-intlayer";
|
|
6
6
|
import { useDictionary as useDictionary$1, useDictionaryDynamic as useDictionaryDynamic$1, useI18n as useI18n$1 } from "@intlayer/vue-i18n";
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
// src/runtime/composer.ts
|
|
9
9
|
/** The @nuxtjs/i18n locale object describing a locale code. */
|
|
10
10
|
const toLocaleObject = (code) => ({
|
|
11
11
|
code,
|
|
@@ -66,6 +66,5 @@ const useDictionaryDynamic = ((dictionaryLoaders, key, options) => ({
|
|
|
66
66
|
...createComposerExtras()
|
|
67
67
|
}));
|
|
68
68
|
|
|
69
|
-
//#endregion
|
|
70
69
|
export { toLocaleObject, useDictionary, useDictionaryDynamic, useI18n };
|
|
71
70
|
//# sourceMappingURL=composer.mjs.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/runtime/define.ts
|
|
2
2
|
/**
|
|
3
3
|
* Identity helper for `i18n.config.ts`. Kept for migration: message catalogs
|
|
4
4
|
* move to intlayer dictionaries, so the returned config is never loaded.
|
|
@@ -18,6 +18,5 @@ const useSetI18nParams = () => () => {};
|
|
|
18
18
|
/** Preload hint for message keys; dictionaries are already bundled. */
|
|
19
19
|
const useI18nPreloadKeys = (_keys) => {};
|
|
20
20
|
|
|
21
|
-
//#endregion
|
|
22
21
|
export { defineI18nConfig, defineI18nLocale, defineI18nLocaleDetector, defineI18nRoute, useI18nPreloadKeys, useSetI18nParams };
|
|
23
22
|
//# sourceMappingURL=define.mjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { STRATEGIES, STRATEGY_NO_PREFIX, STRATEGY_PREFIX, STRATEGY_PREFIX_AND_DEFAULT, STRATEGY_PREFIX_EXCEPT_DEFAULT } from "../constants.mjs";
|
|
2
|
-
import { useBrowserLocale, useCookieLocale, useLocaleHead, useLocalePath, useLocaleRoute, useRouteBaseName, useSwitchLocalePath } from "./routing.mjs";
|
|
3
2
|
import { useDictionary, useDictionaryDynamic, useI18n } from "./composer.mjs";
|
|
4
|
-
import { NuxtLinkLocale } from "./NuxtLinkLocale.mjs";
|
|
5
3
|
import { defineI18nConfig, defineI18nLocale, defineI18nLocaleDetector, defineI18nRoute, useI18nPreloadKeys, useSetI18nParams } from "./define.mjs";
|
|
4
|
+
import { NuxtLinkLocale } from "./NuxtLinkLocale.mjs";
|
|
5
|
+
import { useBrowserLocale, useCookieLocale, useLocaleHead, useLocalePath, useLocaleRoute, useRouteBaseName, useSwitchLocalePath } from "./routing.mjs";
|
|
6
6
|
|
|
7
7
|
export { NuxtLinkLocale, STRATEGIES, STRATEGY_NO_PREFIX, STRATEGY_PREFIX, STRATEGY_PREFIX_AND_DEFAULT, STRATEGY_PREFIX_EXCEPT_DEFAULT, defineI18nConfig, defineI18nLocale, defineI18nLocaleDetector, defineI18nRoute, useBrowserLocale, useCookieLocale, useDictionary, useDictionaryDynamic, useI18n, useI18nPreloadKeys, useLocaleHead, useLocalePath, useLocaleRoute, useRouteBaseName, useSetI18nParams, useSwitchLocalePath };
|
|
@@ -2,7 +2,7 @@ import { createLocalePath, createLocaleRoute, createRouteBaseName, createSwitchL
|
|
|
2
2
|
import { createI18n } from "@intlayer/vue-i18n";
|
|
3
3
|
import { defineNuxtPlugin } from "#app";
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
// src/runtime/nuxtPlugin.ts
|
|
6
6
|
/**
|
|
7
7
|
* Installs vue-i18n's globals (`$t`, `$d`, `$n`, `v-t`…) and the
|
|
8
8
|
* @nuxtjs/i18n helpers (`$localePath`, `$switchLocalePath`…) on the app.
|
|
@@ -27,6 +27,5 @@ var nuxtPlugin_default = defineNuxtPlugin({
|
|
|
27
27
|
}
|
|
28
28
|
});
|
|
29
29
|
|
|
30
|
-
//#endregion
|
|
31
30
|
export { nuxtPlugin_default as default };
|
|
32
31
|
//# sourceMappingURL=nuxtPlugin.mjs.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
+
import { computed, getCurrentInstance, ref } from "vue";
|
|
1
2
|
import { internationalization, routing } from "@intlayer/config/built";
|
|
2
3
|
import { getHTMLTextDir, getLocalizedUrl, getPathWithoutLocale } from "@intlayer/core/localization";
|
|
3
4
|
import { getCachedLocaleFromStorageClient } from "@intlayer/core/utils";
|
|
4
|
-
import { computed, getCurrentInstance, ref } from "vue";
|
|
5
5
|
import { createIntlayerClient } from "vue-intlayer";
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
// src/runtime/routing.ts
|
|
8
8
|
const defaultLocale = internationalization?.defaultLocale ?? "en";
|
|
9
9
|
const localeCodes = internationalization?.locales ?? [defaultLocale];
|
|
10
10
|
/** Separator of localized route names generated by `nuxt-intlayer`. */
|
|
@@ -138,6 +138,5 @@ const useLocaleHead = (options = {}) => {
|
|
|
138
138
|
/** Non-reactive head attributes, for `$localeHead()`. */
|
|
139
139
|
const getLocaleHead = (options = {}, router) => resolveLocaleHead(options, router);
|
|
140
140
|
|
|
141
|
-
//#endregion
|
|
142
141
|
export { createLocalePath, createLocaleRoute, createRouteBaseName, createSwitchLocalePath, defaultLocale, detectBrowserLocale, getActiveLocale, getCurrentFullPath, getLocaleHead, getRouter, localeCodes, localizeFullPath, strategy, useBrowserLocale, useCookieLocale, useLocaleHead, useLocalePath, useLocaleRoute, useRouteBaseName, useSwitchLocalePath };
|
|
143
142
|
//# sourceMappingURL=routing.mjs.map
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
//#region src/constants.d.ts
|
|
2
1
|
export declare const STRATEGY_PREFIX = "prefix";
|
|
3
2
|
export declare const STRATEGY_PREFIX_EXCEPT_DEFAULT = "prefix_except_default";
|
|
4
3
|
export declare const STRATEGY_PREFIX_AND_DEFAULT = "prefix_and_default";
|
|
@@ -9,5 +8,4 @@ export declare const STRATEGIES: {
|
|
|
9
8
|
readonly PREFIX_AND_DEFAULT: 'prefix_and_default';
|
|
10
9
|
readonly NO_PREFIX: 'no_prefix';
|
|
11
10
|
};
|
|
12
|
-
//#endregion
|
|
13
11
|
//# sourceMappingURL=constants.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","names":[],"sources":["../../src/constants.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"constants.d.ts","names":[],"sources":["../../src/constants.ts"],"mappings":"A,qBAAa;qBACA;qBACA;qBACA;qBAEA;WACX;WACA;WACA;WACA"}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { STRATEGIES, STRATEGY_NO_PREFIX, STRATEGY_PREFIX, STRATEGY_PREFIX_AND_DEFAULT, STRATEGY_PREFIX_EXCEPT_DEFAULT } from "./constants.js";
|
|
2
|
-
import { ConfigLoader, Directions, I18nHeadMetaInfo, I18nHeadOptions, I18nRoute, LocaleHeadFunction, LocaleLoader, LocaleObject, LocalePathFunction, LocaleRouteFunction, LocaleType, LocalizedRoute, MetaAttrs, NuxtI18nOptions, RouteBaseNameFunction, RouteLocationGeneric, SetI18nParamsFunction, Strategies, SwitchLocalePathFunction } from "./types.js";
|
|
3
2
|
import nuxtjsI18nModule from "./module.js";
|
|
3
|
+
import { ConfigLoader, Directions, I18nHeadMetaInfo, I18nHeadOptions, I18nRoute, LocaleHeadFunction, LocaleLoader, LocaleObject, LocalePathFunction, LocaleRouteFunction, LocaleType, LocalizedRoute, MetaAttrs, NuxtI18nOptions, RouteBaseNameFunction, RouteLocationGeneric, SetI18nParamsFunction, Strategies, SwitchLocalePathFunction } from "./types.js";
|
|
4
4
|
export { type ConfigLoader, type Directions, type I18nHeadMetaInfo, type I18nHeadOptions, type I18nRoute, type LocaleHeadFunction, type LocaleLoader, type LocaleObject, type LocalePathFunction, type LocaleRouteFunction, type LocaleType, type LocalizedRoute, type MetaAttrs, type NuxtI18nOptions, type RouteBaseNameFunction, type RouteLocationGeneric, STRATEGIES, STRATEGY_NO_PREFIX, STRATEGY_PREFIX, STRATEGY_PREFIX_AND_DEFAULT, STRATEGY_PREFIX_EXCEPT_DEFAULT, type SetI18nParamsFunction, type Strategies, type SwitchLocalePathFunction, nuxtjsI18nModule as default, nuxtjsI18nModule };
|
package/dist/types/module.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { NuxtI18nOptions } from "./types.js";
|
|
2
2
|
import { NuxtModule } from "@nuxt/schema";
|
|
3
|
-
//#region src/module.d.ts
|
|
4
3
|
/**
|
|
5
4
|
* Nuxt module replacing `@nuxtjs/i18n` with intlayer.
|
|
6
5
|
*
|
|
@@ -23,6 +22,5 @@ import { NuxtModule } from "@nuxt/schema";
|
|
|
23
22
|
* ```
|
|
24
23
|
*/
|
|
25
24
|
export declare const nuxtjsI18nModule: NuxtModule<NuxtI18nOptions>;
|
|
26
|
-
//#endregion
|
|
27
25
|
export { nuxtjsI18nModule as default };
|
|
28
26
|
//# sourceMappingURL=module.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"module.d.ts","names":[],"sources":["../../src/module.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"module.d.ts","names":[],"sources":["../../src/module.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;qBAyDa,kBAAkB,WAAW"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { RouteLocationGeneric } from "../types.js";
|
|
2
2
|
import { PropType } from "vue";
|
|
3
|
-
//#region src/runtime/NuxtLinkLocale.d.ts
|
|
4
3
|
/**
|
|
5
4
|
* `<NuxtLinkLocale to="/about" locale="fr">` — a `<NuxtLink>` whose target
|
|
6
5
|
* is localized for the active (or given) locale.
|
|
@@ -38,5 +37,4 @@ export declare const NuxtLinkLocale: import("vue").DefineComponent<import("vue")
|
|
|
38
37
|
href: RouteLocationGeneric;
|
|
39
38
|
locale: string;
|
|
40
39
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
41
|
-
//#endregion
|
|
42
40
|
//# sourceMappingURL=NuxtLinkLocale.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NuxtLinkLocale.d.ts","names":[],"sources":["../../../src/runtime/NuxtLinkLocale.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"NuxtLinkLocale.d.ts","names":[],"sources":["../../../src/runtime/NuxtLinkLocale.ts"],"mappings":";;;;;;qBASa,8BAAc,8BAAA;;IAKK,MAAA,SAAS;;;;IAIT,MAAA,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;qCAsBvC"}
|
|
@@ -3,7 +3,6 @@ import { ComputedRef } from "vue";
|
|
|
3
3
|
import { Dictionary } from "@intlayer/types/dictionary";
|
|
4
4
|
import { DictionaryKeys, StrictModeLocaleMap } from "@intlayer/types/module_augmentation";
|
|
5
5
|
import { LooseComposer, ScopedComposer, TypedComposer } from "@intlayer/vue-i18n";
|
|
6
|
-
//#region src/runtime/composer.d.ts
|
|
7
6
|
/** What @nuxtjs/i18n adds to vue-i18n's composer. */
|
|
8
7
|
export type NuxtI18nComposerExtras = {
|
|
9
8
|
locales: ComputedRef<LocaleObject[]>;
|
|
@@ -62,5 +61,5 @@ export declare const useI18n: NuxtUseI18n;
|
|
|
62
61
|
export declare const useDictionary: NuxtUseDictionary;
|
|
63
62
|
/** Per-locale lazy variant of {@link useDictionary}. */
|
|
64
63
|
export declare const useDictionaryDynamic: NuxtUseDictionaryDynamic;
|
|
65
|
-
|
|
64
|
+
export {};
|
|
66
65
|
//# sourceMappingURL=composer.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"composer.d.ts","names":[],"sources":["../../../src/runtime/composer.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"composer.d.ts","names":[],"sources":["../../../src/runtime/composer.ts"],"mappings":";;;;;;YAmCY;EACV,SAAS,YAAY;EACrB,aAAa;EACb,kBAAkB,YAAY;EAC9B;EACA,UAAU;;EAEV,YAAY,mBAAmB;EAC/B;EACA;EACA,kBAAkB;;EAElB,mCAAmC;;EAEnC,kCAAkC;;EAElC,qBAAqB,mBAAmB;;;qBAI7B,iBAAc,iBAAmB;KA+CzC,kBAAkB;KAElB;GACF,UAAU,gBACT,SAAS;IAAoB,WAAW;MACvC,cAAc,KAAK;GAEpB,UAAU;IAAoB;MAC7B,gBAAgB;;KAGhB;GACF,UAAU,YACT,YAAY,GACZ,UAAU;IAAoB;MAC7B,cAAc,WAAW,kBAAkB;GAC7C,UAAU,YAAY,uBACrB,YAAY,GACZ,SAAS;IAAoB,WAAW;MACvC,eAAe,WAAW,gBAAgB,UAAU;;KAGpD;GACF,UAAU,YAAY,UAAU,gBAC/B,mBAAmB,0BAA0B,QAAQ,KACrD,KAAK,GACL,UAAU;IAAoB;MAC7B,cAAc,KAAK;GACrB,UAAU,YAAY,UAAU,gBAAgB,uBAC/C,mBAAmB,0BAA0B,QAAQ,KACrD,KAAK,GACL,SAAS;IAAoB,WAAW;MACvC,eAAe,GAAG,UAAU;;;;;;qBAOpB,SAGN;;;;;qBAMM,eAMN;;qBAGM,sBAON"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { ConfigLoader, I18nRoute, LocaleLoader, SetI18nParamsFunction } from "../types.js";
|
|
2
2
|
import { I18nOptions } from "vue-i18n";
|
|
3
|
-
//#region src/runtime/define.d.ts
|
|
4
3
|
/**
|
|
5
4
|
* Identity helper for `i18n.config.ts`. Kept for migration: message catalogs
|
|
6
5
|
* move to intlayer dictionaries, so the returned config is never loaded.
|
|
@@ -19,5 +18,4 @@ export declare const defineI18nRoute: (_route: I18nRoute | false) => void;
|
|
|
19
18
|
export declare const useSetI18nParams: () => SetI18nParamsFunction;
|
|
20
19
|
/** Preload hint for message keys; dictionaries are already bundled. */
|
|
21
20
|
export declare const useI18nPreloadKeys: (_keys: string[]) => void;
|
|
22
|
-
//#endregion
|
|
23
21
|
//# sourceMappingURL=define.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"define.d.ts","names":[],"sources":["../../../src/runtime/define.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"define.d.ts","names":[],"sources":["../../../src/runtime/define.ts"],"mappings":";;;;;;qBAYa,mBAAoB,eAAe,aAAW,QACjD,aAAa,YACpB,aAAa;;qBAGH,mBAAoB,WAAW,yBAAuB,QACzD,aAAa,cACpB,aAAa;;qBAGH,2BACX,qBAAqB,0BAAwB,UAEnC,aACT;;;;;qBAMU,kBAAe,QAAY;;qBAG3B,wBAAuB;;qBAGvB,qBAAkB"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { STRATEGIES, STRATEGY_NO_PREFIX, STRATEGY_PREFIX, STRATEGY_PREFIX_AND_DEFAULT, STRATEGY_PREFIX_EXCEPT_DEFAULT } from "../constants.js";
|
|
2
|
-
import { NuxtLinkLocale } from "./NuxtLinkLocale.js";
|
|
3
2
|
import { NuxtI18nComposerExtras, useDictionary, useDictionaryDynamic, useI18n } from "./composer.js";
|
|
4
3
|
import { defineI18nConfig, defineI18nLocale, defineI18nLocaleDetector, defineI18nRoute, useI18nPreloadKeys, useSetI18nParams } from "./define.js";
|
|
4
|
+
import { NuxtLinkLocale } from "./NuxtLinkLocale.js";
|
|
5
5
|
import { useBrowserLocale, useCookieLocale, useLocaleHead, useLocalePath, useLocaleRoute, useRouteBaseName, useSwitchLocalePath } from "./routing.js";
|
|
6
6
|
export { type NuxtI18nComposerExtras, NuxtLinkLocale, STRATEGIES, STRATEGY_NO_PREFIX, STRATEGY_PREFIX, STRATEGY_PREFIX_AND_DEFAULT, STRATEGY_PREFIX_EXCEPT_DEFAULT, defineI18nConfig, defineI18nLocale, defineI18nLocaleDetector, defineI18nRoute, useBrowserLocale, useCookieLocale, useDictionary, useDictionaryDynamic, useI18n, useI18nPreloadKeys, useLocaleHead, useLocalePath, useLocaleRoute, useRouteBaseName, useSetI18nParams, useSwitchLocalePath };
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
//#region src/runtime/nuxtPlugin.d.ts
|
|
2
1
|
/**
|
|
3
2
|
* Installs vue-i18n's globals (`$t`, `$d`, `$n`, `v-t`…) and the
|
|
4
3
|
* @nuxtjs/i18n helpers (`$localePath`, `$switchLocalePath`…) on the app.
|
|
@@ -7,6 +6,5 @@
|
|
|
7
6
|
* client every helper reads the locale from.
|
|
8
7
|
*/
|
|
9
8
|
declare const _default: any;
|
|
10
|
-
//#endregion
|
|
11
9
|
export { _default as default };
|
|
12
10
|
//# sourceMappingURL=nuxtPlugin.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nuxtPlugin.d.ts","names":[],"sources":["../../../src/runtime/nuxtPlugin.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"nuxtPlugin.d.ts","names":[],"sources":["../../../src/runtime/nuxtPlugin.ts"],"mappings":""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nuxtVirtualModules.d.ts","names":[],"sources":["../../../src/runtime/nuxtVirtualModules.d.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"nuxtVirtualModules.d.ts","names":[],"sources":["../../../src/runtime/nuxtVirtualModules.d.ts"],"mappings":";;gBAEgB;eAED,UAAU"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { I18nHeadMetaInfo, I18nHeadOptions, LocalePathFunction, LocaleRouteFunction, RouteBaseNameFunction, Strategies, SwitchLocalePathFunction } from "../types.js";
|
|
2
2
|
import { Ref } from "vue";
|
|
3
3
|
import { Router } from "vue-router";
|
|
4
|
-
//#region src/runtime/routing.d.ts
|
|
5
4
|
export declare const defaultLocale: string;
|
|
6
5
|
export declare const localeCodes: string[];
|
|
7
6
|
/** @nuxtjs/i18n strategy equivalent to intlayer's `routing.mode`. */
|
|
@@ -43,5 +42,4 @@ export declare const useRouteBaseName: () => RouteBaseNameFunction;
|
|
|
43
42
|
export declare const useLocaleHead: (options?: I18nHeadOptions) => Ref<I18nHeadMetaInfo>;
|
|
44
43
|
/** Non-reactive head attributes, for `$localeHead()`. */
|
|
45
44
|
export declare const getLocaleHead: (options?: I18nHeadOptions, router?: Router) => I18nHeadMetaInfo;
|
|
46
|
-
//#endregion
|
|
47
45
|
//# sourceMappingURL=routing.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"routing.d.ts","names":[],"sources":["../../../src/runtime/routing.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"routing.d.ts","names":[],"sources":["../../../src/runtime/routing.ts"],"mappings":";;;qBAuBa;qBAEA;;qBAQA,UAAU;;qBAUV;;qBAIA;;qBAYA;;qBAIA,uBAAsB;;qBAItB,iBAAgB;;qBAMhB,qBAAkB,QAAY;;qBAuD9B,mBAAgB,kBAAoB;;qBAOpC,mBAAgB,QAClB,uBAAqB;;qBAKnB,yBAAsB,QACxB,uBAAqB;;qBAKnB,oBAAiB,QACpB,uBACP;;;;;qBAiBU,sBAAmB,QACrB,uBAAqB;;qBAqBnB,qBAAoB;;qBAIpB,2BAA0B;;qBAI1B,sBAAqB;;qBAIrB,wBAAuB;;qBAiDvB,gBAAa,UACf,oBACR,IAAI;;qBAOM,gBAAa,UACf,iBAAe,SACf,WACR"}
|
package/dist/types/types.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { I18nOptions } from "vue-i18n";
|
|
2
|
-
//#region src/types.d.ts
|
|
3
2
|
export type Strategies = 'prefix' | 'prefix_except_default' | 'prefix_and_default' | 'no_prefix';
|
|
4
3
|
export type Directions = 'ltr' | 'rtl' | 'auto';
|
|
5
4
|
export type LocaleObject<T extends string = string> = {
|
|
@@ -78,5 +77,4 @@ export type NuxtI18nOptions = {
|
|
|
78
77
|
useCookie?: boolean;
|
|
79
78
|
} | false;
|
|
80
79
|
};
|
|
81
|
-
//#endregion
|
|
82
80
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","names":[],"sources":["../../src/types.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.d.ts","names":[],"sources":["../../src/types.ts"],"mappings":";YAEY;YAMA;YAEA,aAAa;EACvB,MAAM;EACN;EACA,MAAM;EACN;EACA;EACA;EACA;EACA;;EAEA;;YAGU,sBAAsB;;YAGtB;EACV,QAAQ,QAAQ;EAChB;;YAGU;EACV;EACA;EACA;IAAkB;;;YAGR,YAAY;YAEZ;EACV,YAAY;EACZ,OAAO;EACP,OAAO;;;YAIG;EAGN;EACA;EACA,QAAQ;EACR;EACA,SAAS;;;YAIH;EACV;EACA;EACA;EACA,QAAQ;EACR;EACA,SAAS;;YAGC,sBACV,OAAO,sBACP;YAGU,4BAA4B;YAE5B,uBACV,OAAO,sBACP,oBACG;YAEO,yBACV,QAAQ;YAGE,sBACV,UAAU,oBACP;YAEO,yBACV,QAAQ,eAAe;YAGb,aAAa,WAAW,4BAClC,mBACG,WAAW,QAAQ;YAEZ,aAAa,eAAe,cAAc,qBAClD,SACA,QAAQ;;;;;YAMA;EACV;EACA,UAAU;EACV,WAAW;EACX;EACA;EACA;EACA;EACA;IAEM;IACA;IACA;IACA;IACA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@intlayer/nuxtjs-i18n",
|
|
3
|
-
"version": "9.7.
|
|
3
|
+
"version": "9.7.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "@nuxtjs/i18n API adapter for intlayer — drop-in compatibility layer",
|
|
6
6
|
"keywords": [
|
|
@@ -70,28 +70,28 @@
|
|
|
70
70
|
"typecheck": "tsc --noEmit --project tsconfig.types.json"
|
|
71
71
|
},
|
|
72
72
|
"dependencies": {
|
|
73
|
-
"@intlayer/config": "9.
|
|
74
|
-
"@intlayer/core": "9.7.
|
|
75
|
-
"@intlayer/types": "9.7.
|
|
76
|
-
"@intlayer/vue-i18n": "9.7.
|
|
77
|
-
"nuxt-intlayer": "9.
|
|
78
|
-
"vue-intlayer": "9.
|
|
73
|
+
"@intlayer/config": "9.7.1",
|
|
74
|
+
"@intlayer/core": "9.7.1",
|
|
75
|
+
"@intlayer/types": "9.7.1",
|
|
76
|
+
"@intlayer/vue-i18n": "9.7.1",
|
|
77
|
+
"nuxt-intlayer": "9.7.1",
|
|
78
|
+
"vue-intlayer": "9.7.1"
|
|
79
79
|
},
|
|
80
80
|
"devDependencies": {
|
|
81
|
-
"@nuxt/kit": "4.
|
|
82
|
-
"@nuxt/schema": "4.
|
|
81
|
+
"@nuxt/kit": "4.6.4",
|
|
82
|
+
"@nuxt/schema": "4.6.4",
|
|
83
83
|
"@nuxtjs/i18n": "^10.4.0",
|
|
84
84
|
"@types/node": "^26",
|
|
85
85
|
"@utils/ts-config": "1.0.4",
|
|
86
86
|
"@utils/ts-config-types": "1.0.4",
|
|
87
87
|
"@utils/tsdown-config": "1.0.4",
|
|
88
88
|
"rimraf": "6.1.3",
|
|
89
|
-
"tsdown": "0.23.
|
|
89
|
+
"tsdown": "0.23.4",
|
|
90
90
|
"typescript": "7.0.2",
|
|
91
|
-
"vitest": "5.0
|
|
92
|
-
"vue": "3.5.
|
|
93
|
-
"vue-i18n": "11.4.
|
|
94
|
-
"vue-router": "5.
|
|
91
|
+
"vitest": "5.1.0",
|
|
92
|
+
"vue": "3.5.44",
|
|
93
|
+
"vue-i18n": "11.4.17",
|
|
94
|
+
"vue-router": "5.4.0"
|
|
95
95
|
},
|
|
96
96
|
"peerDependencies": {
|
|
97
97
|
"@nuxt/kit": ">=3.0.0",
|