solid-intlayer 8.0.2 → 8.0.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.
- package/dist/cjs/markdown/compiler.cjs +1 -1
- package/dist/cjs/markdown/index.cjs +1 -1
- package/dist/esm/UI/ContentSelector.mjs +4 -4
- package/dist/esm/client/IntlayerProvider.mjs +3 -3
- package/dist/esm/editor/contexts/CommunicatorContext.mjs +4 -4
- package/dist/esm/editor/contexts/DictionariesRecordContext.mjs +1 -1
- package/dist/esm/editor/contexts/EditedContentContext.mjs +1 -1
- package/dist/esm/editor/contexts/EditorEnabledContext.mjs +3 -3
- package/dist/esm/html/HTMLProvider.mjs +2 -2
- package/dist/esm/markdown/compiler.mjs +1 -1
- package/dist/esm/markdown/index.mjs +4 -4
- package/package.json +7 -7
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("@intlayer/core"),c=require("./runtime.cjs"),e=(o="",r={})=>t.compileWithOptions(o,c.default,r),i=e,n=e;exports.compile=n;exports.compileMarkdown=e;exports.compiler=i;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./compiler.cjs"),o=require("./MarkdownProvider.cjs"),r=require("./MarkdownRenderer.cjs"),n=require("./runtime.cjs");exports.compile=e.compile;exports.compileMarkdown=e.compileMarkdown;exports.compiler=e.compiler;exports.MarkdownContext=o.MarkdownContext;exports.MarkdownProvider=o.MarkdownProvider;exports.useMarkdown=o.useMarkdown;exports.MarkdownMetadataRenderer=r.MarkdownMetadataRenderer;exports.MarkdownRenderer=r.MarkdownRenderer;exports.renderMarkdown=r.renderMarkdown;exports.useMarkdownRenderer=r.useMarkdownRenderer;exports.solidRuntime=n.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./compiler.cjs"),o=require("./MarkdownProvider.cjs"),r=require("./MarkdownRenderer.cjs"),n=require("./runtime.cjs");exports.compile=e.compile;exports.compileMarkdown=e.compileMarkdown;exports.compiler=e.compiler;exports.MarkdownContext=o.MarkdownContext;exports.MarkdownProvider=o.MarkdownProvider;exports.useMarkdown=o.useMarkdown;exports.MarkdownMetadataRenderer=r.MarkdownMetadataRenderer;exports.MarkdownRenderer=r.MarkdownRenderer;exports.renderMarkdown=r.renderMarkdown;exports.useMarkdownRenderer=r.useMarkdownRenderer;exports.solidRuntime=n.default;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { d as p,
|
|
1
|
+
import { d as p, s as T, i as k, t as L, u as y } from "../../web-mv0y5CK4.mjs";
|
|
2
2
|
import { createSignal as m, createEffect as C, onCleanup as P, mergeProps as w } from "solid-js";
|
|
3
|
-
var D = /* @__PURE__ */
|
|
3
|
+
var D = /* @__PURE__ */ L("<span role=button tabindex=0>");
|
|
4
4
|
const O = 250, x = (t) => {
|
|
5
5
|
let n;
|
|
6
6
|
const [f, l] = m(!1), [a, r] = m(t.isSelecting);
|
|
@@ -34,7 +34,7 @@ const O = 250, x = (t) => {
|
|
|
34
34
|
};
|
|
35
35
|
return (() => {
|
|
36
36
|
var e = D(), d = n;
|
|
37
|
-
return typeof d == "function" ? y(d, e) : n = e, e.addEventListener("mouseenter", g), e.addEventListener("blur", S), e.addEventListener("touchcancel", o), e.$$touchend = o, e.$$touchstart = u, e.addEventListener("mouseleave", o), e.$$mouseup = o, e.$$mousedown = u, e.$$click = E, e.$$keyup = () => null,
|
|
37
|
+
return typeof d == "function" ? y(d, e) : n = e, e.addEventListener("mouseenter", g), e.addEventListener("blur", S), e.addEventListener("touchcancel", o), e.$$touchend = o, e.$$touchstart = u, e.addEventListener("mouseleave", o), e.$$mouseup = o, e.$$mousedown = u, e.$$click = E, e.$$keyup = () => null, T(e, w({
|
|
38
38
|
get style() {
|
|
39
39
|
return {
|
|
40
40
|
display: h ? "inline" : "inline-block",
|
|
@@ -48,7 +48,7 @@ const O = 250, x = (t) => {
|
|
|
48
48
|
transition: "all 100ms 50ms ease-in-out"
|
|
49
49
|
};
|
|
50
50
|
}
|
|
51
|
-
}, t), !1, !0),
|
|
51
|
+
}, t), !1, !0), k(e, () => t.children), e;
|
|
52
52
|
})();
|
|
53
53
|
};
|
|
54
54
|
p(["keyup", "click", "mousedown", "mouseup", "touchstart", "touchend"]);
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import s from "@intlayer/config/built";
|
|
2
2
|
import { localeResolver as v } from "@intlayer/core";
|
|
3
|
-
import { createContext as y, createComponent as n,
|
|
3
|
+
import { createContext as y, createComponent as n, createSignal as I, createEffect as c, useContext as w } from "solid-js";
|
|
4
4
|
import { IntlayerEditorProvider as b } from "../editor/IntlayerEditorProvider.mjs";
|
|
5
5
|
import { localeCookie as d, setLocaleInStorage as A } from "./useLocaleStorage.mjs";
|
|
6
6
|
const f = y({
|
|
7
7
|
locale: () => d ?? s?.internationalization?.defaultLocale,
|
|
8
8
|
setLocale: () => null,
|
|
9
9
|
disableEditor: !1
|
|
10
|
-
}), R = () =>
|
|
10
|
+
}), R = () => w(f), x = (t) => {
|
|
11
11
|
const {
|
|
12
12
|
internationalization: u
|
|
13
13
|
} = s ?? {}, {
|
|
14
14
|
defaultLocale: L,
|
|
15
15
|
locales: a
|
|
16
|
-
} = u ?? {}, m = t.locale ?? d ?? t.defaultLocale ?? L, [o, l] =
|
|
16
|
+
} = u ?? {}, m = t.locale ?? d ?? t.defaultLocale ?? L, [o, l] = I(m);
|
|
17
17
|
c(() => {
|
|
18
18
|
if (typeof window < "u") {
|
|
19
19
|
const e = (r) => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import i from "@intlayer/config/built";
|
|
2
|
-
import { createContext as s,
|
|
2
|
+
import { createContext as s, createMemo as a, createComponent as c, useContext as d } from "solid-js";
|
|
3
3
|
const m = () => Math.random().toString(36).slice(2), {
|
|
4
4
|
editor: o
|
|
5
5
|
} = i, t = s({
|
|
@@ -7,12 +7,12 @@ const m = () => Math.random().toString(36).slice(2), {
|
|
|
7
7
|
allowedOrigins: [o?.applicationURL, o?.editorURL, o?.cmsURL],
|
|
8
8
|
senderId: ""
|
|
9
9
|
}), g = (e) => {
|
|
10
|
-
const n = m(), r =
|
|
10
|
+
const n = m(), r = a(() => ({
|
|
11
11
|
postMessage: e.postMessage,
|
|
12
12
|
allowedOrigins: e.allowedOrigins,
|
|
13
13
|
senderId: n
|
|
14
14
|
}));
|
|
15
|
-
return
|
|
15
|
+
return c(t.Provider, {
|
|
16
16
|
get value() {
|
|
17
17
|
return r();
|
|
18
18
|
},
|
|
@@ -20,7 +20,7 @@ const m = () => Math.random().toString(36).slice(2), {
|
|
|
20
20
|
return e.children;
|
|
21
21
|
}
|
|
22
22
|
});
|
|
23
|
-
}, C = () =>
|
|
23
|
+
}, C = () => d(t);
|
|
24
24
|
export {
|
|
25
25
|
g as CommunicatorProvider,
|
|
26
26
|
C as useCommunicator
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MessageKey as C } from "@intlayer/editor";
|
|
2
|
-
import { createContext as c,
|
|
2
|
+
import { createContext as c, createMemo as i, createComponent as n, useContext as s } from "solid-js";
|
|
3
3
|
import { useCrossFrameState as m } from "./useCrossFrameState.mjs";
|
|
4
4
|
const a = c(void 0), d = c(void 0), g = (t) => {
|
|
5
5
|
const [e, o] = m(C.INTLAYER_LOCALE_DICTIONARIES_CHANGED, void 0), u = i(() => ({
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { getContentNodeByKeyPath as f, renameContentNodeByKeyPath as j, editDictionaryByKeyPath as B } from "@intlayer/core";
|
|
2
2
|
import { MessageKey as m } from "@intlayer/editor";
|
|
3
3
|
import { NodeType as h } from "@intlayer/types";
|
|
4
|
-
import { createContext as g,
|
|
4
|
+
import { createContext as g, createComponent as T, useContext as p } from "solid-js";
|
|
5
5
|
import { useDictionariesRecord as H } from "./DictionariesRecordContext.mjs";
|
|
6
6
|
import { useCrossFrameMessageListener as _ } from "./useCrossFrameMessageListener.mjs";
|
|
7
7
|
import { useCrossFrameState as W } from "./useCrossFrameState.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MessageKey as t } from "@intlayer/editor";
|
|
2
|
-
import { createContext as n,
|
|
2
|
+
import { createContext as n, createComponent as E, useContext as a } from "solid-js";
|
|
3
3
|
import { useCrossFrameMessageListener as r } from "./useCrossFrameMessageListener.mjs";
|
|
4
4
|
import { useCrossFrameState as d } from "./useCrossFrameState.mjs";
|
|
5
5
|
const o = n({
|
|
@@ -9,7 +9,7 @@ const o = n({
|
|
|
9
9
|
emit: !1,
|
|
10
10
|
receive: !0
|
|
11
11
|
});
|
|
12
|
-
return
|
|
12
|
+
return E(o.Provider, {
|
|
13
13
|
value: {
|
|
14
14
|
enabled: s
|
|
15
15
|
},
|
|
@@ -17,7 +17,7 @@ const o = n({
|
|
|
17
17
|
return e.children;
|
|
18
18
|
}
|
|
19
19
|
});
|
|
20
|
-
}, L = () =>
|
|
20
|
+
}, L = () => a(o);
|
|
21
21
|
export {
|
|
22
22
|
p as EditorEnabledProvider,
|
|
23
23
|
L as useEditorEnabled,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { createContext as n,
|
|
2
|
-
const t = n(), s = () =>
|
|
1
|
+
import { createContext as n, createComponent as o, useContext as r } from "solid-js";
|
|
2
|
+
const t = n(), s = () => r(t), u = (e) => o(t.Provider, {
|
|
3
3
|
get value() {
|
|
4
4
|
return {
|
|
5
5
|
components: e.components
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { compile as o, compileMarkdown as d, compiler as n } from "./compiler.mjs";
|
|
2
2
|
import { MarkdownContext as t, MarkdownProvider as M, useMarkdown as k } from "./MarkdownProvider.mjs";
|
|
3
|
-
import { MarkdownMetadataRenderer as w, MarkdownRenderer as p, renderMarkdown as i, useMarkdownRenderer as
|
|
4
|
-
import {
|
|
3
|
+
import { MarkdownMetadataRenderer as w, MarkdownRenderer as p, renderMarkdown as i, useMarkdownRenderer as f } from "./MarkdownRenderer.mjs";
|
|
4
|
+
import { default as x } from "./runtime.mjs";
|
|
5
5
|
export {
|
|
6
6
|
t as MarkdownContext,
|
|
7
7
|
w as MarkdownMetadataRenderer,
|
|
@@ -11,7 +11,7 @@ export {
|
|
|
11
11
|
d as compileMarkdown,
|
|
12
12
|
n as compiler,
|
|
13
13
|
i as renderMarkdown,
|
|
14
|
-
|
|
14
|
+
x as solidRuntime,
|
|
15
15
|
k as useMarkdown,
|
|
16
|
-
|
|
16
|
+
f as useMarkdownRenderer
|
|
17
17
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "solid-intlayer",
|
|
3
|
-
"version": "8.0.
|
|
3
|
+
"version": "8.0.4",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Easily internationalize i18n your Solid applications with type-safe multilingual content management.",
|
|
6
6
|
"keywords": [
|
|
@@ -74,14 +74,14 @@
|
|
|
74
74
|
"typecheck": "tsc --noEmit --project tsconfig.types.json"
|
|
75
75
|
},
|
|
76
76
|
"dependencies": {
|
|
77
|
-
"@intlayer/api": "8.0.
|
|
78
|
-
"@intlayer/config": "8.0.
|
|
79
|
-
"@intlayer/core": "8.0.
|
|
80
|
-
"@intlayer/editor": "8.0.
|
|
81
|
-
"@intlayer/types": "8.0.
|
|
77
|
+
"@intlayer/api": "8.0.4",
|
|
78
|
+
"@intlayer/config": "8.0.4",
|
|
79
|
+
"@intlayer/core": "8.0.4",
|
|
80
|
+
"@intlayer/editor": "8.0.4",
|
|
81
|
+
"@intlayer/types": "8.0.4"
|
|
82
82
|
},
|
|
83
83
|
"devDependencies": {
|
|
84
|
-
"@intlayer/unmerged-dictionaries-entry": "8.0.
|
|
84
|
+
"@intlayer/unmerged-dictionaries-entry": "8.0.4",
|
|
85
85
|
"@solidjs/testing-library": "0.8.10",
|
|
86
86
|
"@testing-library/jest-dom": "6.9.1",
|
|
87
87
|
"@testing-library/user-event": "14.6.1",
|