meno-core 1.0.39 → 1.0.41
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/bin/cli.ts +33 -0
- package/build-astro.ts +172 -69
- package/dist/bin/cli.js +30 -2
- package/dist/bin/cli.js.map +2 -2
- package/dist/build-static.js +7 -7
- package/dist/chunks/{chunk-WK5XLASY.js → chunk-EQOSDQS2.js} +4 -4
- package/dist/chunks/{chunk-AIXKUVNG.js → chunk-IBR2F4IL.js} +4 -5
- package/dist/chunks/{chunk-AIXKUVNG.js.map → chunk-IBR2F4IL.js.map} +2 -2
- package/dist/chunks/{chunk-NV25WXCA.js → chunk-IGVQF5GY.js} +11 -7
- package/dist/chunks/chunk-IGVQF5GY.js.map +7 -0
- package/dist/chunks/{chunk-KULPBDC7.js → chunk-LBWIHPN7.js} +9 -3
- package/dist/chunks/chunk-LBWIHPN7.js.map +7 -0
- package/dist/chunks/{chunk-A6KWUEA6.js → chunk-MKB2J6AD.js} +9 -1
- package/dist/chunks/chunk-MKB2J6AD.js.map +7 -0
- package/dist/chunks/{chunk-P3FX5HJM.js → chunk-S2HXJTAF.js} +1 -1
- package/dist/chunks/chunk-S2HXJTAF.js.map +7 -0
- package/dist/chunks/{chunk-W6HDII4T.js → chunk-SK3TLNUP.js} +140 -114
- package/dist/chunks/chunk-SK3TLNUP.js.map +7 -0
- package/dist/chunks/{chunk-HNAS6BSS.js → chunk-SNUROC7E.js} +56 -6
- package/dist/chunks/{chunk-HNAS6BSS.js.map → chunk-SNUROC7E.js.map} +3 -3
- package/dist/chunks/{configService-TXBNUBBL.js → configService-MICL4S2L.js} +2 -2
- package/dist/chunks/{constants-5CRJRQNR.js → constants-ZEU4TZCA.js} +2 -2
- package/dist/entries/server-router.js +7 -7
- package/dist/lib/client/index.js +11 -6
- package/dist/lib/client/index.js.map +2 -2
- package/dist/lib/server/index.js +507 -1587
- package/dist/lib/server/index.js.map +4 -4
- package/dist/lib/shared/index.js +3 -3
- package/dist/lib/test-utils/index.js +1 -1
- package/lib/client/core/ComponentBuilder.ts +1 -1
- package/lib/client/core/builders/embedBuilder.ts +2 -2
- package/lib/client/routing/Router.tsx +6 -0
- package/lib/client/templateEngine.test.ts +178 -0
- package/lib/client/templateEngine.ts +1 -2
- package/lib/server/astro/cmsPageEmitter.ts +420 -0
- package/lib/server/astro/componentEmitter.ts +150 -17
- package/lib/server/astro/nodeToAstro.test.ts +1101 -0
- package/lib/server/astro/nodeToAstro.ts +869 -37
- package/lib/server/astro/pageEmitter.ts +43 -3
- package/lib/server/astro/tailwindMapper.ts +69 -8
- package/lib/server/astro/templateTransformer.ts +107 -0
- package/lib/server/index.ts +26 -3
- package/lib/server/routes/api/components.ts +62 -0
- package/lib/server/routes/api/core-routes.ts +8 -0
- package/lib/server/services/configService.ts +12 -0
- package/lib/server/ssr/htmlGenerator.ts +0 -5
- package/lib/server/ssr/imageMetadata.ts +3 -3
- package/lib/server/ssr/ssrRenderer.ts +78 -29
- package/lib/server/webflow/buildWebflow.ts +415 -0
- package/lib/server/webflow/index.ts +22 -0
- package/lib/server/webflow/nodeToWebflow.ts +423 -0
- package/lib/server/webflow/styleMapper.ts +241 -0
- package/lib/server/webflow/types.ts +196 -0
- package/lib/shared/constants.ts +4 -0
- package/lib/shared/types/components.ts +9 -4
- package/lib/shared/validation/propValidator.ts +2 -1
- package/lib/shared/validation/schemas.ts +4 -1
- package/package.json +1 -1
- package/templates/index-router.html +0 -5
- package/dist/chunks/chunk-A6KWUEA6.js.map +0 -7
- package/dist/chunks/chunk-KULPBDC7.js.map +0 -7
- package/dist/chunks/chunk-NV25WXCA.js.map +0 -7
- package/dist/chunks/chunk-P3FX5HJM.js.map +0 -7
- package/dist/chunks/chunk-W6HDII4T.js.map +0 -7
- /package/dist/chunks/{chunk-WK5XLASY.js.map → chunk-EQOSDQS2.js.map} +0 -0
- /package/dist/chunks/{configService-TXBNUBBL.js.map → configService-MICL4S2L.js.map} +0 -0
- /package/dist/chunks/{constants-5CRJRQNR.js.map → constants-ZEU4TZCA.js.map} +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ConfigService,
|
|
3
3
|
configService
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-MKB2J6AD.js";
|
|
5
5
|
import "./chunk-YSZ5IUFM.js";
|
|
6
6
|
import "./chunk-WQFG7PAH.js";
|
|
7
7
|
import "./chunk-PGH3ATYI.js";
|
|
@@ -10,4 +10,4 @@ export {
|
|
|
10
10
|
ConfigService,
|
|
11
11
|
configService
|
|
12
12
|
};
|
|
13
|
-
//# sourceMappingURL=configService-
|
|
13
|
+
//# sourceMappingURL=configService-MICL4S2L.js.map
|
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
TREE_SCROLL_DELAY_MS,
|
|
20
20
|
WEBSOCKET_STATES,
|
|
21
21
|
init_constants
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-LBWIHPN7.js";
|
|
23
23
|
import "./chunk-KSBZ2L7C.js";
|
|
24
24
|
init_constants();
|
|
25
25
|
export {
|
|
@@ -43,4 +43,4 @@ export {
|
|
|
43
43
|
TREE_SCROLL_DELAY_MS,
|
|
44
44
|
WEBSOCKET_STATES
|
|
45
45
|
};
|
|
46
|
-
//# sourceMappingURL=constants-
|
|
46
|
+
//# sourceMappingURL=constants-ZEU4TZCA.js.map
|
|
@@ -6,27 +6,27 @@ import {
|
|
|
6
6
|
PageService,
|
|
7
7
|
WebSocketManager,
|
|
8
8
|
createServer
|
|
9
|
-
} from "../chunks/chunk-
|
|
9
|
+
} from "../chunks/chunk-SNUROC7E.js";
|
|
10
10
|
import {
|
|
11
11
|
CMSService,
|
|
12
12
|
FileSystemCMSProvider,
|
|
13
13
|
loadProjectConfig,
|
|
14
14
|
migrateTemplatesDirectory
|
|
15
|
-
} from "../chunks/chunk-
|
|
15
|
+
} from "../chunks/chunk-SK3TLNUP.js";
|
|
16
16
|
import {
|
|
17
17
|
configService
|
|
18
|
-
} from "../chunks/chunk-
|
|
18
|
+
} from "../chunks/chunk-MKB2J6AD.js";
|
|
19
19
|
import {
|
|
20
20
|
projectPaths
|
|
21
21
|
} from "../chunks/chunk-YSZ5IUFM.js";
|
|
22
22
|
import "../chunks/chunk-WQFG7PAH.js";
|
|
23
23
|
import "../chunks/chunk-LIHJ6OUH.js";
|
|
24
|
-
import "../chunks/chunk-
|
|
25
|
-
import "../chunks/chunk-
|
|
26
|
-
import "../chunks/chunk-
|
|
24
|
+
import "../chunks/chunk-S2HXJTAF.js";
|
|
25
|
+
import "../chunks/chunk-IBR2F4IL.js";
|
|
26
|
+
import "../chunks/chunk-IGVQF5GY.js";
|
|
27
27
|
import "../chunks/chunk-PGH3ATYI.js";
|
|
28
28
|
import "../chunks/chunk-UB44F4Z2.js";
|
|
29
|
-
import "../chunks/chunk-
|
|
29
|
+
import "../chunks/chunk-LBWIHPN7.js";
|
|
30
30
|
import "../chunks/chunk-KSBZ2L7C.js";
|
|
31
31
|
|
|
32
32
|
// entries/server-router.tsx
|
package/dist/lib/client/index.js
CHANGED
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
resolveLinkMapping,
|
|
13
13
|
resolveStyleMapping,
|
|
14
14
|
skipEmptyTemplateAttributes
|
|
15
|
-
} from "../../chunks/chunk-
|
|
15
|
+
} from "../../chunks/chunk-IBR2F4IL.js";
|
|
16
16
|
import {
|
|
17
17
|
filterCSSProperties,
|
|
18
18
|
logNetworkError,
|
|
@@ -56,7 +56,7 @@ import {
|
|
|
56
56
|
singularize,
|
|
57
57
|
sortClassesByPropertyOrder,
|
|
58
58
|
validatePageData
|
|
59
|
-
} from "../../chunks/chunk-
|
|
59
|
+
} from "../../chunks/chunk-IGVQF5GY.js";
|
|
60
60
|
import {
|
|
61
61
|
DEFAULT_BREAKPOINTS,
|
|
62
62
|
DEFAULT_I18N_CONFIG,
|
|
@@ -79,7 +79,7 @@ import {
|
|
|
79
79
|
NOT_FOUND_TIMEOUT_MS,
|
|
80
80
|
RAW_HTML_PREFIX,
|
|
81
81
|
init_constants
|
|
82
|
-
} from "../../chunks/chunk-
|
|
82
|
+
} from "../../chunks/chunk-LBWIHPN7.js";
|
|
83
83
|
import "../../chunks/chunk-KSBZ2L7C.js";
|
|
84
84
|
|
|
85
85
|
// lib/client/core/ComponentBuilder.ts
|
|
@@ -683,8 +683,8 @@ function hasCMSTemplate(text) {
|
|
|
683
683
|
import { createElement as h2 } from "react";
|
|
684
684
|
import DOMPurify from "isomorphic-dompurify";
|
|
685
685
|
var SANITIZE_CONFIG = {
|
|
686
|
-
ALLOWED_TAGS: ["svg", "path", "circle", "rect", "line", "polyline", "polygon", "g", "text", "tspan", "image", "defs", "use", "linearGradient", "radialGradient", "stop", "clipPath", "mask", "pattern", "marker", "symbol", "a", "div", "span", "p", "br", "button", "img", "iframe", "video", "audio", "source", "canvas", "b", "i", "u", "strong", "em", "sub", "sup", "mark", "s", "small", "del", "ins", "q", "abbr", "code", "pre", "blockquote", "ul", "ol", "li", "h1", "h2", "h3", "h4", "h5", "h6"],
|
|
687
|
-
ALLOWED_ATTR: ["class", "id", "style", "width", "height", "viewBox", "xmlns", "fill", "stroke", "stroke-width", "stroke-linecap", "stroke-linejoin", "stroke-dasharray", "stroke-dashoffset", "d", "cx", "cy", "r", "x", "y", "x1", "y1", "x2", "y2", "points", "href", "src", "alt", "target", "rel", "data-*", "aria-*", "transform", "opacity", "fill-opacity", "stroke-opacity", "font-size", "font-family", "text-anchor", "dominant-baseline", "offset", "stop-color", "stop-opacity", "frameborder", "allowfullscreen", "allow", "title"],
|
|
686
|
+
ALLOWED_TAGS: ["svg", "path", "circle", "rect", "line", "polyline", "polygon", "g", "text", "tspan", "image", "defs", "use", "linearGradient", "radialGradient", "stop", "clipPath", "mask", "pattern", "marker", "symbol", "a", "div", "span", "p", "br", "button", "img", "iframe", "video", "audio", "source", "canvas", "b", "i", "u", "strong", "em", "sub", "sup", "mark", "s", "small", "del", "ins", "q", "abbr", "code", "pre", "blockquote", "ul", "ol", "li", "h1", "h2", "h3", "h4", "h5", "h6", "style", "animate", "animateTransform", "animateMotion", "set"],
|
|
687
|
+
ALLOWED_ATTR: ["class", "id", "style", "width", "height", "viewBox", "xmlns", "fill", "stroke", "stroke-width", "stroke-linecap", "stroke-linejoin", "stroke-dasharray", "stroke-dashoffset", "d", "cx", "cy", "r", "x", "y", "x1", "y1", "x2", "y2", "points", "href", "src", "alt", "target", "rel", "data-*", "aria-*", "transform", "opacity", "fill-opacity", "stroke-opacity", "font-size", "font-family", "text-anchor", "dominant-baseline", "offset", "stop-color", "stop-opacity", "frameborder", "allowfullscreen", "allow", "title", "attributeName", "values", "dur", "begin", "end", "repeatCount", "repeatDur", "keyTimes", "keySplines", "calcMode", "from", "to", "by", "additive", "accumulate", "type", "rotate", "keyPoints", "path"],
|
|
688
688
|
KEEP_CONTENT: true
|
|
689
689
|
};
|
|
690
690
|
function buildEmbed(node, ctx, deps) {
|
|
@@ -2069,7 +2069,7 @@ var ComponentBuilder = class {
|
|
|
2069
2069
|
if (utilityClasses.length > 0) {
|
|
2070
2070
|
const existingClassName = props.className || "";
|
|
2071
2071
|
const classArray = existingClassName ? existingClassName.split(/\s+/) : [];
|
|
2072
|
-
return { ...props, className: [...classArray, ...utilityClasses].filter(Boolean).join(" ") };
|
|
2072
|
+
return { ...props, className: [...classArray, ...utilityClasses].filter(Boolean).join(" "), style: processedStyle };
|
|
2073
2073
|
}
|
|
2074
2074
|
}
|
|
2075
2075
|
return props;
|
|
@@ -3833,6 +3833,11 @@ function Router(props = {}) {
|
|
|
3833
3833
|
useEffect2(() => {
|
|
3834
3834
|
if (typeof window === "undefined") return;
|
|
3835
3835
|
const handleMessage = (event) => {
|
|
3836
|
+
if (event.data?.type === IFRAME_MESSAGE_TYPES.CSS_VARIABLE_UPDATE) {
|
|
3837
|
+
const { name, value } = event.data;
|
|
3838
|
+
document.documentElement.style.setProperty(name, value);
|
|
3839
|
+
return;
|
|
3840
|
+
}
|
|
3836
3841
|
if (event.data?.type === IFRAME_MESSAGE_TYPES.INTERACTIVE_CSS_UPDATE) {
|
|
3837
3842
|
const css = event.data.css;
|
|
3838
3843
|
const styleId = "interactive-styles";
|