react-intlayer 9.5.2 → 9.5.3

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
@@ -328,4 +328,4 @@ Contribute on [GitHub](https://github.com/aymericzip/intlayer), [GitLab](https:/
328
328
 
329
329
  If you like Intlayer, give us a ⭐ on GitHub. It helps others discover the project! [See why GitHub Stars matter](https://github.com/aymericzip/intlayer/blob/main/CONTRIBUTING.md#why-github-stars-matter-).
330
330
 
331
- [![Star History Chart](https://api.star-history.com/svg?repos=aymericzip/intlayer&type=Date)](https://api.star-history.com/#aymericzip/intlayer&Date)
331
+ [![Star History Chart](https://api.star-history.com/svg?repos=aymericzip/intlayer&type=Date)](https://star-history.com/#aymericzip/intlayer&Date)
@@ -1,4 +1,3 @@
1
- import { LocalesValues } from "../../intlayer/dist/types/index.js";
2
1
  //#region src/client/format/useCompact.d.ts
3
2
  /**
4
3
  * React client hook that provides a compact number formatter
@@ -11,7 +10,7 @@ import { LocalesValues } from "../../intlayer/dist/types/index.js";
11
10
  * ```
12
11
  */
13
12
  export declare const useCompact: () => (value: string | number, options?: Intl.NumberFormatOptions & {
14
- locale?: LocalesValues;
13
+ locale?: import("@intlayer/types").LocalesValues;
15
14
  }) => string;
16
15
  //#endregion
17
16
  //# sourceMappingURL=useCompact.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useCompact.d.ts","names":[],"sources":["../../../../src/client/format/useCompact.ts"],"mappings":";;;;;;;;;;;;qBAgBa,mBAAU,wBAAA,UAAA,KAAA;WAAA"}
1
+ {"version":3,"file":"useCompact.d.ts","names":[],"sources":["../../../../src/client/format/useCompact.ts"],"mappings":";;;;;;;;;;;qBAgBa,mBAAU,wBAAA,UAAA,KAAA"}
@@ -1,4 +1,3 @@
1
- import { LocalesValues } from "../../intlayer/dist/types/index.js";
2
1
  //#region src/client/format/useCurrency.d.ts
3
2
  /**
4
3
  * React client hook that provides a currency formatter
@@ -25,7 +24,7 @@ import { LocalesValues } from "../../intlayer/dist/types/index.js";
25
24
  * ```
26
25
  */
27
26
  export declare const useCurrency: () => (value: string | number, options?: Intl.NumberFormatOptions & {
28
- locale?: LocalesValues;
27
+ locale?: import("@intlayer/types").LocalesValues;
29
28
  }) => string;
30
29
  //#endregion
31
30
  //# sourceMappingURL=useCurrency.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useCurrency.d.ts","names":[],"sources":["../../../../src/client/format/useCurrency.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;qBA8Ba,oBAAW,wBAAA,UAAA,KAAA;WAAA"}
1
+ {"version":3,"file":"useCurrency.d.ts","names":[],"sources":["../../../../src/client/format/useCurrency.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;qBA8Ba,oBAAW,wBAAA,UAAA,KAAA"}
@@ -1,4 +1,3 @@
1
- import { LocalesValues } from "../../intlayer/dist/types/index.js";
2
1
  //#region src/client/format/useList.d.ts
3
2
  /**
4
3
  * React client hook that provides a list formatter
@@ -22,7 +21,7 @@ import { LocalesValues } from "../../intlayer/dist/types/index.js";
22
21
  * ```
23
22
  */
24
23
  export declare const useList: () => (values: (string | number)[], options?: import("@intlayer/core/formatters").ListFormatOptions & {
25
- locale?: LocalesValues;
24
+ locale?: import("@intlayer/types").LocalesValues;
26
25
  }) => string;
27
26
  //#endregion
28
27
  //# sourceMappingURL=useList.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useList.d.ts","names":[],"sources":["../../../../src/client/format/useList.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;qBA2Ba,gBAAO,6BAAA,8CAAA;WAAP"}
1
+ {"version":3,"file":"useList.d.ts","names":[],"sources":["../../../../src/client/format/useList.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;qBA2Ba,gBAAO,6BAAA,8CAAA"}
@@ -1,4 +1,3 @@
1
- import { LocalesValues } from "../../intlayer/dist/types/index.js";
2
1
  //#region src/client/format/useNumber.d.ts
3
2
  /**
4
3
  * React client hook that provides a localized number formatter.
@@ -23,7 +22,7 @@ import { LocalesValues } from "../../intlayer/dist/types/index.js";
23
22
  * A number formatting function bound to the active locale.
24
23
  */
25
24
  export declare const useNumber: () => (value: string | number, args_1?: Intl.NumberFormatOptions & {
26
- locale?: LocalesValues;
25
+ locale?: import("@intlayer/types").LocalesValues;
27
26
  }) => string;
28
27
  //#endregion
29
28
  //# sourceMappingURL=useNumber.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useNumber.d.ts","names":[],"sources":["../../../../src/client/format/useNumber.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;qBA4Ba,kBAAS,wBAAA,SAAA,KAAA;WAAA"}
1
+ {"version":3,"file":"useNumber.d.ts","names":[],"sources":["../../../../src/client/format/useNumber.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;qBA4Ba,kBAAS,wBAAA,SAAA,KAAA"}
@@ -1,4 +1,3 @@
1
- import { LocalesValues } from "../../intlayer/dist/types/index.js";
2
1
  //#region src/client/format/usePercentage.d.ts
3
2
  /**
4
3
  * React hook to provide a percentage formatter function
@@ -19,7 +18,7 @@ import { LocalesValues } from "../../intlayer/dist/types/index.js";
19
18
  * A function that formats numbers or numeric strings into localized percentages.
20
19
  */
21
20
  export declare const usePercentage: () => (value: string | number, args_1?: Intl.NumberFormatOptions & {
22
- locale?: LocalesValues;
21
+ locale?: import("@intlayer/types").LocalesValues;
23
22
  }) => string;
24
23
  //#endregion
25
24
  //# sourceMappingURL=usePercentage.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"usePercentage.d.ts","names":[],"sources":["../../../../src/client/format/usePercentage.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;qBAwBa,sBAAa,wBAAA,SAAA,KAAA;WAAA"}
1
+ {"version":3,"file":"usePercentage.d.ts","names":[],"sources":["../../../../src/client/format/usePercentage.ts"],"mappings":";;;;;;;;;;;;;;;;;;;qBAwBa,sBAAa,wBAAA,SAAA,KAAA"}
@@ -1,4 +1,3 @@
1
- import { LocalesValues } from "../../intlayer/dist/types/index.js";
2
1
  //#region src/client/format/useRelativeTime.d.ts
3
2
  /**
4
3
  * Client-side React hook for accessing a localized relative time formatter.
@@ -19,7 +18,7 @@ import { LocalesValues } from "../../intlayer/dist/types/index.js";
19
18
  * bound to the current client locale.
20
19
  */
21
20
  export declare const useRelativeTime: () => (from: string | number | Date, to?: string | number | Date, options?: Intl.RelativeTimeFormatOptions & {
22
- locale?: LocalesValues;
21
+ locale?: import("@intlayer/types").LocalesValues;
23
22
  unit?: Intl.RelativeTimeFormatUnit;
24
23
  }) => string;
25
24
  //#endregion
@@ -1 +1 @@
1
- {"version":3,"file":"useRelativeTime.d.ts","names":[],"sources":["../../../../src/client/format/useRelativeTime.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;qBAwBa,wBAAe,wBAAA,MAAA,uBAAA,MAAA,UAAA,KAAA;WAAA"}
1
+ {"version":3,"file":"useRelativeTime.d.ts","names":[],"sources":["../../../../src/client/format/useRelativeTime.ts"],"mappings":";;;;;;;;;;;;;;;;;;;qBAwBa,wBAAe,wBAAA,MAAA,uBAAA,MAAA,UAAA,KAAA"}
@@ -1,4 +1,3 @@
1
- import { LocalesValues } from "../../intlayer/dist/types/index.js";
2
1
  //#region src/client/format/useUnit.d.ts
3
2
  /**
4
3
  * React hook that provides a unit formatting function
@@ -18,7 +17,7 @@ import { LocalesValues } from "../../intlayer/dist/types/index.js";
18
17
  * @returns {Function} A unit formatting function that accepts a value and optional formatting options.
19
18
  */
20
19
  export declare const useUnit: () => (value: string | number, options?: Intl.NumberFormatOptions & {
21
- locale?: LocalesValues;
20
+ locale?: import("@intlayer/types").LocalesValues;
22
21
  }) => string;
23
22
  //#endregion
24
23
  //# sourceMappingURL=useUnit.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useUnit.d.ts","names":[],"sources":["../../../../src/client/format/useUnit.ts"],"mappings":";;;;;;;;;;;;;;;;;;;qBAuBa,gBAAO,wBAAA,UAAA,KAAA;WAAA"}
1
+ {"version":3,"file":"useUnit.d.ts","names":[],"sources":["../../../../src/client/format/useUnit.ts"],"mappings":";;;;;;;;;;;;;;;;;;qBAuBa,gBAAO,wBAAA,UAAA,KAAA"}
@@ -1,7 +1,7 @@
1
1
  import { DeepTransformContent } from "../plugins.js";
2
2
  import { DeclaredLocales, DictionaryKeys, DictionaryRegistryContent } from "@intlayer/types/module_augmentation";
3
- import { GetSubPath } from "@intlayer/types/dictionary";
4
3
  import { ValidDotPathsFor } from "@intlayer/core/transpiler";
4
+ import { GetSubPath } from "@intlayer/types/dictionary";
5
5
  //#region src/client/useI18n.d.ts
6
6
  /**
7
7
  * Hook that provides a translation function `t()` for accessing nested content by key.
@@ -1,13 +1,12 @@
1
- import { Locale, LocalesValues } from "../intlayer/dist/types/index.js";
2
1
  //#region src/client/useLocaleBase.d.ts
3
2
  /**
4
3
  * On the client side, hook to get the current locale and all related fields
5
4
  */
6
5
  export declare const useLocaleBase: () => {
7
- locale: LocalesValues;
8
- defaultLocale: Locale;
9
- availableLocales: Locale[];
10
- setLocale: (newLocale: LocalesValues) => void;
6
+ locale: import("@intlayer/types").LocalesValues;
7
+ defaultLocale: import("@intlayer/types").Locale;
8
+ availableLocales: import("@intlayer/types").Locale[];
9
+ setLocale: (newLocale: import("@intlayer/types").LocalesValues) => void;
11
10
  };
12
11
  //#endregion
13
12
  //# sourceMappingURL=useLocaleBase.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useLocaleBase.d.ts","names":[],"sources":["../../../src/client/useLocaleBase.ts"],"mappings":";;;;;qBAWa;UAAA"}
1
+ {"version":3,"file":"useLocaleBase.d.ts","names":[],"sources":["../../../src/client/useLocaleBase.ts"],"mappings":";;;;qBAWa"}
@@ -1,4 +1,3 @@
1
- import { Locale } from "../intlayer/dist/types/index.js";
2
1
  import { LocalesValues } from "@intlayer/types/module_augmentation";
3
2
  //#region src/client/useLocaleStorage.d.ts
4
3
  /**
@@ -7,13 +6,13 @@ import { LocalesValues } from "@intlayer/types/module_augmentation";
7
6
  /**
8
7
  * Get the locale cookie
9
8
  */
10
- export declare const localeInStorage: Locale;
9
+ export declare const localeInStorage: import("@intlayer/types").Locale;
11
10
  /**
12
11
  * @deprecated Use localeInStorage instead
13
12
  *
14
13
  * Get the locale cookie
15
14
  */
16
- export declare const localeCookie: Locale;
15
+ export declare const localeCookie: import("@intlayer/types").Locale;
17
16
  /**
18
17
  * Set the locale cookie
19
18
  */
@@ -28,7 +27,7 @@ export declare const setLocaleCookie: typeof setLocaleInStorage;
28
27
  * Hook that provides the locale cookie and a function to set it
29
28
  */
30
29
  export declare const useLocaleStorage: (isCookieEnabled?: boolean) => {
31
- getLocale: () => Locale;
30
+ getLocale: () => import("@intlayer/types").Locale;
32
31
  setLocale: (locale: LocalesValues) => void;
33
32
  };
34
33
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"useLocaleStorage.d.ts","names":[],"sources":["../../../src/client/useLocaleStorage.ts"],"mappings":";;;;;;;;;qBAea,iBAAA;;;;;;qBAMA,cAAA;;;;qBAKA,qBAAkB,QACrB,eAAa;;;;;;qBAaV,wBAAe;;;;qBAKf,mBAAgB;mBAAhB;sBAAA;;;;;;;;;qBAiBA,wBAAe"}
1
+ {"version":3,"file":"useLocaleStorage.d.ts","names":[],"sources":["../../../src/client/useLocaleStorage.ts"],"mappings":";;;;;;;;qBAea,2CAAe;;;;;;qBAMf,wCAAY;;;;qBAKZ,qBAAkB,QACrB,eAAa;;;;;;qBAaV,wBAAe;;;;qBAKf,mBAAgB;;sBAAhB;;;;;;;;;qBAiBA,wBAAe"}
@@ -1,7 +1,7 @@
1
1
  import { DeepTransformContent } from "../plugins.js";
2
2
  import { DictionaryKeys, DictionaryRegistryContent, LocalesValues } from "@intlayer/types/module_augmentation";
3
- import { GetSubPath } from "@intlayer/types/dictionary";
4
3
  import { ValidDotPathsFor } from "@intlayer/core/transpiler";
4
+ import { GetSubPath } from "@intlayer/types/dictionary";
5
5
  //#region src/server/useI18n.d.ts
6
6
  /**
7
7
  * Hook that provides a translation function `t()` for accessing nested content by key.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-intlayer",
3
- "version": "9.5.2",
3
+ "version": "9.5.3",
4
4
  "private": false,
5
5
  "description": "Easily internationalize i18n your React applications with type-safe multilingual content management.",
6
6
  "keywords": [
@@ -132,12 +132,12 @@
132
132
  "typecheck": "tsc --noEmit --project tsconfig.types.json"
133
133
  },
134
134
  "dependencies": {
135
- "@intlayer/api": "9.5.2",
136
- "@intlayer/config": "9.5.2",
137
- "@intlayer/core": "9.5.2",
138
- "@intlayer/dictionaries-entry": "9.5.2",
139
- "@intlayer/editor": "9.5.2",
140
- "@intlayer/types": "9.5.2"
135
+ "@intlayer/api": "9.5.3",
136
+ "@intlayer/config": "9.5.3",
137
+ "@intlayer/core": "9.5.3",
138
+ "@intlayer/dictionaries-entry": "9.5.3",
139
+ "@intlayer/editor": "9.5.3",
140
+ "@intlayer/types": "9.5.3"
141
141
  },
142
142
  "devDependencies": {
143
143
  "@craco/types": "7.1.0",
@@ -158,7 +158,7 @@
158
158
  "react-dom": ">=16.0.0"
159
159
  },
160
160
  "optionalDependencies": {
161
- "@intlayer/analytics": "9.5.2"
161
+ "@intlayer/analytics": "9.5.3"
162
162
  },
163
163
  "engines": {
164
164
  "node": ">=14.18"
@@ -1,8 +0,0 @@
1
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
- const require_editor_ContentSelector = require('./ContentSelector.cjs');
3
- const require_editor_useEditor = require('./useEditor.cjs');
4
- const require_editor_EditorProvider = require('./EditorProvider.cjs');
5
-
6
- exports.ContentSelector = require_editor_ContentSelector.ContentSelector;
7
- exports.EditorProvider = require_editor_EditorProvider.EditorProvider;
8
- exports.useEditor = require_editor_useEditor.useEditor;
@@ -1,5 +0,0 @@
1
- import { ContentSelector } from "./ContentSelector.mjs";
2
- import { useEditor } from "./useEditor.mjs";
3
- import { EditorProvider } from "./EditorProvider.mjs";
4
-
5
- export { ContentSelector, EditorProvider, useEditor };
@@ -1,4 +0,0 @@
1
- import { ContentSelector, ContentSelectorProps } from "./ContentSelector.js";
2
- import { EditorProvider } from "./EditorProvider.js";
3
- import { useEditor } from "./useEditor.js";
4
- export { ContentSelector, type ContentSelectorProps, EditorProvider, useEditor };
@@ -1,14 +0,0 @@
1
- import "@intlayer/core/interpreter";
2
- import { DeclaredLocales, LocalesValues as LocalesValues$1 } from "@intlayer/types/module_augmentation";
3
- import "@intlayer/types/config";
4
- import { Dictionary } from "@intlayer/types/dictionary";
5
- import { Locale } from "@intlayer/types/allLocales";
6
- import "@intlayer/types/locales";
7
- import "@intlayer/config/built";
8
- import "@intlayer/core/file";
9
- import "@intlayer/core/formatters";
10
- import "@intlayer/core/localization";
11
- import "@intlayer/core/markdown";
12
- import "@intlayer/core/transpiler";
13
- import "@intlayer/core/utils";
14
- export type { Locale, LocalesValues$1 as LocalesValues };