meno-core 1.0.46 → 1.0.48
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/build-astro.ts +13 -77
- package/dist/build-static.js +7 -7
- package/dist/chunks/{chunk-FED5MME6.js → chunk-3FHJUHAS.js} +5 -4
- package/dist/chunks/chunk-3FHJUHAS.js.map +7 -0
- package/dist/chunks/{chunk-XSWR3QLI.js → chunk-B2RTLDXY.js} +130 -130
- package/dist/chunks/chunk-B2RTLDXY.js.map +7 -0
- package/dist/chunks/{chunk-ZTKHJQ2Z.js → chunk-BJRKEPMP.js} +2 -2
- package/dist/chunks/{chunk-ORN7S4AP.js → chunk-D5E3OKSL.js} +5 -5
- package/dist/chunks/{chunk-KITQJYZV.js → chunk-EK4KESLU.js} +33 -3
- package/dist/chunks/chunk-EK4KESLU.js.map +7 -0
- package/dist/chunks/{chunk-C6U5T5S5.js → chunk-NKUV77SR.js} +43 -10
- package/dist/chunks/chunk-NKUV77SR.js.map +7 -0
- package/dist/chunks/{chunk-ZWYDT3QJ.js → chunk-NP76N4HQ.js} +4 -4
- package/dist/chunks/{chunk-ZWYDT3QJ.js.map → chunk-NP76N4HQ.js.map} +2 -2
- package/dist/chunks/{chunk-IF3RATBY.js → chunk-RQSTH2BS.js} +2 -2
- package/dist/chunks/{chunk-77ZB6353.js → chunk-TPQ7APVQ.js} +42 -86
- package/dist/chunks/chunk-TPQ7APVQ.js.map +7 -0
- package/dist/chunks/{configService-DYCUEURL.js → configService-IGJEC3MC.js} +3 -3
- package/dist/entries/server-router.js +8 -8
- package/dist/lib/client/index.js +16 -4
- package/dist/lib/client/index.js.map +2 -2
- package/dist/lib/server/index.js +1803 -383
- package/dist/lib/server/index.js.map +4 -4
- package/dist/lib/shared/index.js +8 -4
- package/dist/lib/shared/index.js.map +1 -1
- package/lib/client/core/ComponentBuilder.test.ts +38 -0
- package/lib/client/core/ComponentBuilder.ts +25 -1
- package/lib/server/astro/astroEmitHelpers.ts +5 -0
- package/lib/server/astro/cmsPageEmitter.ts +15 -2
- package/lib/server/astro/componentEmitter.ts +13 -5
- package/lib/server/astro/nodeToAstro.ts +23 -9
- package/lib/server/astro/pageEmitter.ts +15 -2
- package/lib/server/index.ts +1 -1
- package/lib/server/jsonLoader.test.ts +0 -17
- package/lib/server/jsonLoader.ts +0 -81
- package/lib/server/routes/api/variables.ts +4 -2
- package/lib/server/ssr/htmlGenerator.test.ts +4 -4
- package/lib/server/ssr/htmlGenerator.ts +7 -2
- package/lib/server/ssr/imageMetadata.ts +15 -9
- package/lib/server/ssr/ssrRenderer.test.ts +103 -1
- package/lib/server/ssr/ssrRenderer.ts +41 -35
- package/lib/server/utils/jsonLineMapper.test.ts +53 -1
- package/lib/server/utils/jsonLineMapper.ts +43 -3
- package/lib/server/webflow/buildWebflow.ts +343 -123
- package/lib/server/webflow/index.ts +1 -0
- package/lib/server/webflow/nodeToWebflow.test.ts +3170 -0
- package/lib/server/webflow/nodeToWebflow.ts +2141 -129
- package/lib/server/webflow/styleMapper.test.ts +389 -0
- package/lib/server/webflow/styleMapper.ts +517 -63
- package/lib/server/webflow/templateWrapper.ts +49 -0
- package/lib/server/webflow/types.ts +218 -18
- package/lib/shared/elementClassName.test.ts +15 -0
- package/lib/shared/elementClassName.ts +7 -3
- package/lib/shared/registry/nodeTypes/ListNodeType.ts +1 -1
- package/lib/shared/styleNodeUtils.test.ts +47 -1
- package/lib/shared/styleNodeUtils.ts +7 -7
- package/lib/shared/types/index.ts +1 -0
- package/lib/shared/types/variables.ts +37 -0
- package/package.json +1 -1
- package/dist/chunks/chunk-77ZB6353.js.map +0 -7
- package/dist/chunks/chunk-C6U5T5S5.js.map +0 -7
- package/dist/chunks/chunk-FED5MME6.js.map +0 -7
- package/dist/chunks/chunk-KITQJYZV.js.map +0 -7
- package/dist/chunks/chunk-XSWR3QLI.js.map +0 -7
- /package/dist/chunks/{chunk-ZTKHJQ2Z.js.map → chunk-BJRKEPMP.js.map} +0 -0
- /package/dist/chunks/{chunk-ORN7S4AP.js.map → chunk-D5E3OKSL.js.map} +0 -0
- /package/dist/chunks/{chunk-IF3RATBY.js.map → chunk-RQSTH2BS.js.map} +0 -0
- /package/dist/chunks/{configService-DYCUEURL.js.map → configService-IGJEC3MC.js.map} +0 -0
|
@@ -11,15 +11,14 @@ import {
|
|
|
11
11
|
loadI18nConfig,
|
|
12
12
|
loadJSONFile,
|
|
13
13
|
loadProjectConfig,
|
|
14
|
-
loadResponsiveScalesConfig,
|
|
15
14
|
mapPageNameToPath,
|
|
16
15
|
parseJSON,
|
|
17
16
|
resolveSlugToPageId,
|
|
18
17
|
variableService
|
|
19
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-TPQ7APVQ.js";
|
|
20
19
|
import {
|
|
21
20
|
configService
|
|
22
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-BJRKEPMP.js";
|
|
23
22
|
import {
|
|
24
23
|
bundleFile,
|
|
25
24
|
createRuntimeServer,
|
|
@@ -39,16 +38,16 @@ import {
|
|
|
39
38
|
} from "./chunk-WQFG7PAH.js";
|
|
40
39
|
import {
|
|
41
40
|
extractStringValue
|
|
42
|
-
} from "./chunk-
|
|
41
|
+
} from "./chunk-RQSTH2BS.js";
|
|
43
42
|
import {
|
|
44
43
|
isPathWithinRoot
|
|
45
|
-
} from "./chunk-
|
|
44
|
+
} from "./chunk-EK4KESLU.js";
|
|
46
45
|
import {
|
|
47
46
|
addItemUrls
|
|
48
|
-
} from "./chunk-
|
|
47
|
+
} from "./chunk-3FHJUHAS.js";
|
|
49
48
|
import {
|
|
50
49
|
parseLocaleFromPath
|
|
51
|
-
} from "./chunk-
|
|
50
|
+
} from "./chunk-B2RTLDXY.js";
|
|
52
51
|
import {
|
|
53
52
|
API_ROUTES,
|
|
54
53
|
HMR_ROUTE,
|
|
@@ -306,6 +305,13 @@ function buildLineMap(jsonText) {
|
|
|
306
305
|
}
|
|
307
306
|
return { start: startPos, end: pos };
|
|
308
307
|
}
|
|
308
|
+
function recordTrackedRoot(path2) {
|
|
309
|
+
const { start, end } = parseValue(path2, true);
|
|
310
|
+
lineMap.set("", {
|
|
311
|
+
startLine: charToLine[start],
|
|
312
|
+
endLine: charToLine[end - 1] || charToLine[start]
|
|
313
|
+
});
|
|
314
|
+
}
|
|
309
315
|
function parseObject(path2, trackChildren) {
|
|
310
316
|
pos++;
|
|
311
317
|
skipWhitespace();
|
|
@@ -316,7 +322,9 @@ function buildLineMap(jsonText) {
|
|
|
316
322
|
pos++;
|
|
317
323
|
skipWhitespace();
|
|
318
324
|
if (key === "root" && path2.length === 0) {
|
|
319
|
-
|
|
325
|
+
recordTrackedRoot(path2);
|
|
326
|
+
} else if (key === "component" && path2.length === 0) {
|
|
327
|
+
parseComponentWrapper(path2);
|
|
320
328
|
} else if (key === "children" && trackChildren) {
|
|
321
329
|
parseValue(path2, true);
|
|
322
330
|
} else {
|
|
@@ -328,6 +336,30 @@ function buildLineMap(jsonText) {
|
|
|
328
336
|
}
|
|
329
337
|
pos++;
|
|
330
338
|
}
|
|
339
|
+
function parseComponentWrapper(path2) {
|
|
340
|
+
if (jsonText[pos] !== "{") {
|
|
341
|
+
parseValue(path2, false);
|
|
342
|
+
return;
|
|
343
|
+
}
|
|
344
|
+
pos++;
|
|
345
|
+
skipWhitespace();
|
|
346
|
+
while (pos < jsonText.length && jsonText[pos] !== "}") {
|
|
347
|
+
skipWhitespace();
|
|
348
|
+
const key = parseString();
|
|
349
|
+
skipWhitespace();
|
|
350
|
+
pos++;
|
|
351
|
+
skipWhitespace();
|
|
352
|
+
if (key === "structure") {
|
|
353
|
+
recordTrackedRoot(path2);
|
|
354
|
+
} else {
|
|
355
|
+
parseValue(path2, false);
|
|
356
|
+
}
|
|
357
|
+
skipWhitespace();
|
|
358
|
+
if (jsonText[pos] === ",") pos++;
|
|
359
|
+
skipWhitespace();
|
|
360
|
+
}
|
|
361
|
+
pos++;
|
|
362
|
+
}
|
|
331
363
|
function parseArray(path2, trackChildren) {
|
|
332
364
|
pos++;
|
|
333
365
|
skipWhitespace();
|
|
@@ -2029,9 +2061,10 @@ async function handleVariablesStatusRoute() {
|
|
|
2029
2061
|
return jsonResponse(result);
|
|
2030
2062
|
}
|
|
2031
2063
|
async function handleVariablesCSSRoute() {
|
|
2064
|
+
await configService.load();
|
|
2032
2065
|
const variablesConfig = await variableService.loadConfig();
|
|
2033
2066
|
const breakpointConfig = await loadBreakpointConfig();
|
|
2034
|
-
const responsiveScalesConfig =
|
|
2067
|
+
const responsiveScalesConfig = configService.getResponsiveScales();
|
|
2035
2068
|
const css = generateVariablesCSS(variablesConfig, breakpointConfig, responsiveScalesConfig);
|
|
2036
2069
|
return new Response(css, {
|
|
2037
2070
|
headers: { "Content-Type": "text/css" }
|
|
@@ -3221,4 +3254,4 @@ export {
|
|
|
3221
3254
|
createServer,
|
|
3222
3255
|
FileSystemPageProvider
|
|
3223
3256
|
};
|
|
3224
|
-
//# sourceMappingURL=chunk-
|
|
3257
|
+
//# sourceMappingURL=chunk-NKUV77SR.js.map
|