react-intlayer 8.11.0-canary.0 → 8.11.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/cjs/client/useLocaleStorage.cjs +3 -4
- package/dist/cjs/client/useLocaleStorage.cjs.map +1 -1
- package/dist/esm/client/useLocaleStorage.mjs +1 -2
- package/dist/esm/client/useLocaleStorage.mjs.map +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/markdown/MarkdownRenderer.d.ts +1 -1
- package/dist/types/markdown/MarkdownRenderer.d.ts.map +1 -1
- package/package.json +8 -8
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
2
2
|
const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
|
|
3
3
|
let react = require("react");
|
|
4
|
-
let _intlayer_core_localization = require("@intlayer/core/localization");
|
|
5
4
|
let _intlayer_core_utils = require("@intlayer/core/utils");
|
|
6
5
|
|
|
7
6
|
//#region src/client/useLocaleStorage.ts
|
|
@@ -11,7 +10,7 @@ let _intlayer_core_utils = require("@intlayer/core/utils");
|
|
|
11
10
|
/**
|
|
12
11
|
* Get the locale cookie
|
|
13
12
|
*/
|
|
14
|
-
const localeInStorage = (0, _intlayer_core_utils.getLocaleFromStorageClient)(
|
|
13
|
+
const localeInStorage = (0, _intlayer_core_utils.getLocaleFromStorageClient)(_intlayer_core_utils.localeStorageOptions);
|
|
15
14
|
/**
|
|
16
15
|
* @deprecated Use localeInStorage instead
|
|
17
16
|
*
|
|
@@ -22,7 +21,7 @@ const localeCookie = localeInStorage;
|
|
|
22
21
|
* Set the locale cookie
|
|
23
22
|
*/
|
|
24
23
|
const setLocaleInStorage = (locale, isCookieEnabled) => (0, _intlayer_core_utils.setLocaleInStorageClient)(locale, {
|
|
25
|
-
...
|
|
24
|
+
..._intlayer_core_utils.localeStorageOptions,
|
|
26
25
|
isCookieEnabled
|
|
27
26
|
});
|
|
28
27
|
/**
|
|
@@ -35,7 +34,7 @@ const setLocaleCookie = setLocaleInStorage;
|
|
|
35
34
|
* Hook that provides the locale cookie and a function to set it
|
|
36
35
|
*/
|
|
37
36
|
const useLocaleStorage = (isCookieEnabled) => (0, react.useMemo)(() => (0, _intlayer_core_utils.LocaleStorageClient)({
|
|
38
|
-
...
|
|
37
|
+
..._intlayer_core_utils.localeStorageOptions,
|
|
39
38
|
isCookieEnabled
|
|
40
39
|
}), [isCookieEnabled]);
|
|
41
40
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useLocaleStorage.cjs","names":["localeStorageOptions"],"sources":["../../../src/client/useLocaleStorage.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"useLocaleStorage.cjs","names":["localeStorageOptions"],"sources":["../../../src/client/useLocaleStorage.ts"],"sourcesContent":["import {\n getLocaleFromStorageClient,\n LocaleStorageClient,\n localeStorageOptions,\n setLocaleInStorageClient as setLocaleInStorageCore,\n} from '@intlayer/core/utils';\nimport type { LocalesValues } from '@intlayer/types/module_augmentation';\nimport { useMemo } from 'react';\n\n/**\n * Get the locale cookie\n */\n/**\n * Get the locale cookie\n */\nexport const localeInStorage = getLocaleFromStorageClient(localeStorageOptions);\n/**\n * @deprecated Use localeInStorage instead\n *\n * Get the locale cookie\n */\nexport const localeCookie = localeInStorage;\n\n/**\n * Set the locale cookie\n */\nexport const setLocaleInStorage = (\n locale: LocalesValues,\n isCookieEnabled?: boolean\n) =>\n setLocaleInStorageCore(locale, {\n ...localeStorageOptions,\n isCookieEnabled,\n });\n\n/**\n * @deprecated Use setLocaleInStorage instead\n *\n * Set the locale cookie\n */\nexport const setLocaleCookie = setLocaleInStorage;\n\n/**\n * Hook that provides the locale cookie and a function to set it\n */\nexport const useLocaleStorage = (isCookieEnabled?: boolean) =>\n useMemo(\n () =>\n LocaleStorageClient({\n ...localeStorageOptions,\n isCookieEnabled,\n }),\n [isCookieEnabled]\n );\n\n/**\n * @deprecated Use useLocaleStorage instead\n *\n * For GDPR compliance, use useLocaleStorage instead\n *\n * Hook that provides the locale cookie and a function to set it\n */\nexport const useLocaleCookie = useLocaleStorage;\n"],"mappings":";;;;;;;;;;;;AAeA,MAAa,uEAA6CA,yCAAoB;;;;;;AAM9E,MAAa,eAAe;;;;AAK5B,MAAa,sBACX,QACA,uEAEuB,QAAQ;CAC7B,GAAGA;CACH;AACF,CAAC;;;;;;AAOH,MAAa,kBAAkB;;;;AAK/B,MAAa,oBAAoB,2FAGP;CAClB,GAAGA;CACH;AACF,CAAC,GACH,CAAC,eAAe,CAClB;;;;;;;;AASF,MAAa,kBAAkB"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { useMemo } from "react";
|
|
2
|
-
import { localeStorageOptions } from "@intlayer/core/
|
|
3
|
-
import { LocaleStorageClient, getLocaleFromStorageClient, setLocaleInStorageClient } from "@intlayer/core/utils";
|
|
2
|
+
import { LocaleStorageClient, getLocaleFromStorageClient, localeStorageOptions, setLocaleInStorageClient } from "@intlayer/core/utils";
|
|
4
3
|
|
|
5
4
|
//#region src/client/useLocaleStorage.ts
|
|
6
5
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useLocaleStorage.mjs","names":["setLocaleInStorageCore"],"sources":["../../../src/client/useLocaleStorage.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"useLocaleStorage.mjs","names":["setLocaleInStorageCore"],"sources":["../../../src/client/useLocaleStorage.ts"],"sourcesContent":["import {\n getLocaleFromStorageClient,\n LocaleStorageClient,\n localeStorageOptions,\n setLocaleInStorageClient as setLocaleInStorageCore,\n} from '@intlayer/core/utils';\nimport type { LocalesValues } from '@intlayer/types/module_augmentation';\nimport { useMemo } from 'react';\n\n/**\n * Get the locale cookie\n */\n/**\n * Get the locale cookie\n */\nexport const localeInStorage = getLocaleFromStorageClient(localeStorageOptions);\n/**\n * @deprecated Use localeInStorage instead\n *\n * Get the locale cookie\n */\nexport const localeCookie = localeInStorage;\n\n/**\n * Set the locale cookie\n */\nexport const setLocaleInStorage = (\n locale: LocalesValues,\n isCookieEnabled?: boolean\n) =>\n setLocaleInStorageCore(locale, {\n ...localeStorageOptions,\n isCookieEnabled,\n });\n\n/**\n * @deprecated Use setLocaleInStorage instead\n *\n * Set the locale cookie\n */\nexport const setLocaleCookie = setLocaleInStorage;\n\n/**\n * Hook that provides the locale cookie and a function to set it\n */\nexport const useLocaleStorage = (isCookieEnabled?: boolean) =>\n useMemo(\n () =>\n LocaleStorageClient({\n ...localeStorageOptions,\n isCookieEnabled,\n }),\n [isCookieEnabled]\n );\n\n/**\n * @deprecated Use useLocaleStorage instead\n *\n * For GDPR compliance, use useLocaleStorage instead\n *\n * Hook that provides the locale cookie and a function to set it\n */\nexport const useLocaleCookie = useLocaleStorage;\n"],"mappings":";;;;;;;;;;AAeA,MAAa,kBAAkB,2BAA2B,oBAAoB;;;;;;AAM9E,MAAa,eAAe;;;;AAK5B,MAAa,sBACX,QACA,oBAEAA,yBAAuB,QAAQ;CAC7B,GAAG;CACH;AACF,CAAC;;;;;;AAOH,MAAa,kBAAkB;;;;AAK/B,MAAa,oBAAoB,oBAC/B,cAEI,oBAAoB;CAClB,GAAG;CACH;AACF,CAAC,GACH,CAAC,eAAe,CAClB;;;;;;;;AASF,MAAa,kBAAkB"}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -69,7 +69,7 @@ declare const useMarkdownRenderer: ({
|
|
|
69
69
|
forceInline,
|
|
70
70
|
preserveFrontmatter,
|
|
71
71
|
tagfilter
|
|
72
|
-
}?: RenderMarkdownProps$1) => (content: string) => string | number | bigint | boolean | import("react").
|
|
72
|
+
}?: RenderMarkdownProps$1) => (content: string) => string | number | bigint | boolean | Iterable<import("react").ReactNode> | Promise<import("react").ReactNode> | import("react").JSX.Element;
|
|
73
73
|
/**
|
|
74
74
|
* @deprecated import from react-intlayer/markdown instead
|
|
75
75
|
*/
|
|
@@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AAAA;;;;;;cAwBO,kBAAA;eAAwC,cAAA;+CA1CP,yBAAA,EAAA,UAAA,GAAA,cAAA,oBAC5B,OAAA,mBACI,EAAA,iBAAA,cAAA,CAAA,WAAA,uBAAA,SAAA,GAAA,OAAA,iBAAA,SAAA;AAAA;;;;KA4CV,uBAAA,GAA0B,yBAAwB;AAR9D;;;AAAA,cAYa,cAAA,GAAc,OAAA;EAAA,UAAA;EAAA,OAAA;EAAA,UAAA;EAAA,WAAA;EAAA,mBAAA;EAAA;AAAA,IAAA,qBAAA,qBAAA,GAAA,CAAA,OAAA;;;;cAId,mBAAA;EAAmB,UAAA;EAAA,OAAA;EAAA,UAAA;EAAA,WAAA;EAAA,mBAAA;EAAA;AAAA,IAAA,qBAAA,MAa01C,OAAA,kDAAe,QAAA,iBAAA,SAAA,IAAA,OAAA,iBAAA,SAAA,oBAAA,GAAA,CAAA,OAAA;;;;cAT53C,gBAAA,kBAAgB,EAAA,CAAA,uBAAA;;;;KAIjB,mBAAA,GAAsB,qBAAoB;;;;KAI1C,qBAAA,GAAwB,uBAAsB"}
|
|
@@ -133,7 +133,7 @@ declare const useMarkdownRenderer: ({
|
|
|
133
133
|
forceInline,
|
|
134
134
|
preserveFrontmatter,
|
|
135
135
|
tagfilter
|
|
136
|
-
}?: RenderMarkdownProps) => (content: string) => string | number | bigint | boolean |
|
|
136
|
+
}?: RenderMarkdownProps) => (content: string) => string | number | bigint | boolean | Iterable<ReactNode> | Promise<ReactNode> | JSX.Element;
|
|
137
137
|
/**
|
|
138
138
|
* Props for the MarkdownRenderer component.
|
|
139
139
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MarkdownRenderer.d.ts","names":[],"sources":["../../../src/markdown/MarkdownRenderer.tsx"],"mappings":";;;;;;;AA6BA;;;;;;;;;;;;;;;;;KAAY,mBAAA,GAAsB,uBAAA;EAwBO;AA4BzC;;;;;;;;;;;;EAtCE,UAAA,GAAa,cAAA;EAuCb;;;;;;;;;EA7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AAQ,SAAA;AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAgEd,gBAAA,EAAkB,EAAE,CAAC,qBAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-intlayer",
|
|
3
|
-
"version": "8.11.
|
|
3
|
+
"version": "8.11.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Easily internationalize i18n your React applications with type-safe multilingual content management.",
|
|
6
6
|
"keywords": [
|
|
@@ -123,13 +123,13 @@
|
|
|
123
123
|
"typecheck": "tsc --noEmit --project tsconfig.types.json"
|
|
124
124
|
},
|
|
125
125
|
"dependencies": {
|
|
126
|
-
"@intlayer/api": "8.11.
|
|
127
|
-
"@intlayer/config": "8.11.
|
|
128
|
-
"@intlayer/core": "8.11.
|
|
129
|
-
"@intlayer/dictionaries-entry": "8.11.
|
|
130
|
-
"@intlayer/editor": "8.11.
|
|
131
|
-
"@intlayer/editor-react": "8.11.
|
|
132
|
-
"@intlayer/types": "8.11.
|
|
126
|
+
"@intlayer/api": "8.11.1",
|
|
127
|
+
"@intlayer/config": "8.11.1",
|
|
128
|
+
"@intlayer/core": "8.11.1",
|
|
129
|
+
"@intlayer/dictionaries-entry": "8.11.1",
|
|
130
|
+
"@intlayer/editor": "8.11.1",
|
|
131
|
+
"@intlayer/editor-react": "8.11.1",
|
|
132
|
+
"@intlayer/types": "8.11.1"
|
|
133
133
|
},
|
|
134
134
|
"devDependencies": {
|
|
135
135
|
"@craco/types": "7.1.0",
|