streetui 1.7.0 → 1.8.0
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/bin.cjs +1 -1
- package/dist/bin.cjs.map +1 -1
- package/dist/bin.js +1 -1
- package/dist/bin.js.map +1 -1
- package/dist/{compile-Cte0nf06.d.cts → compile-CJJQYi71.d.cts} +137 -2
- package/dist/{compile-Cte0nf06.d.ts → compile-CJJQYi71.d.ts} +137 -2
- package/dist/create-bin.cjs +1 -1
- package/dist/create-bin.cjs.map +1 -1
- package/dist/create-bin.js +1 -1
- package/dist/create-bin.js.map +1 -1
- package/dist/{hydration-diagnostics-zK-fihvd.d.cts → hydration-diagnostics-BQeehq3i.d.cts} +1 -1
- package/dist/{hydration-diagnostics-Ddgs3Puu.d.ts → hydration-diagnostics-DNAJumYF.d.ts} +1 -1
- package/dist/index.cjs +103 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +40 -7
- package/dist/index.d.ts +40 -7
- package/dist/index.js +99 -2
- package/dist/index.js.map +1 -1
- package/dist/{server-D4A8eunr.d.cts → server-CnLEnlYU.d.cts} +1 -1
- package/dist/{server-cgmCiPsz.d.ts → server-DNlg7ou2.d.ts} +1 -1
- package/dist/server.cjs +9 -2
- package/dist/server.cjs.map +1 -1
- package/dist/server.d.cts +2 -2
- package/dist/server.d.ts +2 -2
- package/dist/server.js +9 -2
- package/dist/server.js.map +1 -1
- package/dist/testing.cjs +1088 -2
- package/dist/testing.cjs.map +1 -1
- package/dist/testing.d.cts +63 -4
- package/dist/testing.d.ts +63 -4
- package/dist/testing.js +1082 -2
- package/dist/testing.js.map +1 -1
- package/package.json +1 -1
package/dist/server.cjs
CHANGED
|
@@ -1141,6 +1141,7 @@ function mountNode(ctx, graphNode, parentDom) {
|
|
|
1141
1141
|
instance.addChild(childInstance);
|
|
1142
1142
|
}
|
|
1143
1143
|
dom.appendChild(parentDom, el);
|
|
1144
|
+
if (graphNode.type === "component") wireComponentBehavior(ctx, graphNode, instance);
|
|
1144
1145
|
return instance;
|
|
1145
1146
|
}
|
|
1146
1147
|
function textUpdate(dom, el, textNode) {
|
|
@@ -1309,6 +1310,11 @@ function wireOverlayBehavior(ctx, graphNode, instance, target) {
|
|
|
1309
1310
|
instance.trackCleanup(teardown);
|
|
1310
1311
|
if (openSig.peek() === true) onOpenChange(true);
|
|
1311
1312
|
}
|
|
1313
|
+
function wireComponentBehavior(ctx, graphNode, instance) {
|
|
1314
|
+
const fn = ctx.graph.getHandler(`__component__${graphNode.id}`);
|
|
1315
|
+
if (fn === void 0) return;
|
|
1316
|
+
for (const cleanup of fn()) instance.trackCleanup(cleanup);
|
|
1317
|
+
}
|
|
1312
1318
|
|
|
1313
1319
|
// ../renderer/src/dehydrate.ts
|
|
1314
1320
|
var STATE_MARKER_ATTR = "data-streetui-state";
|
|
@@ -1376,7 +1382,8 @@ function analyzeGraph(graph) {
|
|
|
1376
1382
|
const isList = node.type === "reactive-list";
|
|
1377
1383
|
const isConditional = node.type === "conditional";
|
|
1378
1384
|
const isPortal = node.type === "portal";
|
|
1379
|
-
const
|
|
1385
|
+
const isComponent = node.type === "component";
|
|
1386
|
+
const isStatic = node.stateRefs.length === 0 && !hasEvents && !isList && !isConditional && !isPortal && !isComponent;
|
|
1380
1387
|
const isStaticSubtree = isStatic && allChildrenStatic;
|
|
1381
1388
|
nodes.set(node.id, {
|
|
1382
1389
|
isStatic,
|
|
@@ -1463,7 +1470,7 @@ function renderToString(compiled, options = {}) {
|
|
|
1463
1470
|
}
|
|
1464
1471
|
|
|
1465
1472
|
// src/version.ts
|
|
1466
|
-
var VERSION = "1.
|
|
1473
|
+
var VERSION = "1.8.0";
|
|
1467
1474
|
// Annotate the CommonJS export names for ESM import in node:
|
|
1468
1475
|
0 && (module.exports = {
|
|
1469
1476
|
STATE_MARKER_ATTR,
|