@uniformdev/transformer 1.1.7 → 1.1.8
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/cli/index.js +10 -7
- package/dist/cli/index.js.map +1 -1
- package/package.json +1 -1
package/dist/cli/index.js
CHANGED
|
@@ -1098,8 +1098,7 @@ var PatternAnalyzerService = class {
|
|
|
1098
1098
|
const sortedSlotNames = Object.keys(slots).sort();
|
|
1099
1099
|
for (const slotName of sortedSlotNames) {
|
|
1100
1100
|
const instances = slots[slotName];
|
|
1101
|
-
if (!Array.isArray(instances)) {
|
|
1102
|
-
node.slots.set(slotName, []);
|
|
1101
|
+
if (!Array.isArray(instances) || instances.length === 0) {
|
|
1103
1102
|
continue;
|
|
1104
1103
|
}
|
|
1105
1104
|
const nextDepth = remainingDepth === -1 ? -1 : remainingDepth - 1;
|
|
@@ -1255,17 +1254,21 @@ var PatternAnalyzerService = class {
|
|
|
1255
1254
|
return type;
|
|
1256
1255
|
}
|
|
1257
1256
|
const sortedSlotNames = Object.keys(slots).sort();
|
|
1258
|
-
const slotFingerprints =
|
|
1257
|
+
const slotFingerprints = [];
|
|
1258
|
+
for (const slotName of sortedSlotNames) {
|
|
1259
1259
|
const instances = slots[slotName];
|
|
1260
1260
|
if (!Array.isArray(instances) || instances.length === 0) {
|
|
1261
|
-
|
|
1261
|
+
continue;
|
|
1262
1262
|
}
|
|
1263
1263
|
const nextDepth = remainingDepth === -1 ? -1 : remainingDepth - 1;
|
|
1264
1264
|
const instanceFingerprints = instances.map(
|
|
1265
1265
|
(instance) => this.generateNodeFingerprint(instance.type, instance.slots, nextDepth)
|
|
1266
1266
|
);
|
|
1267
|
-
|
|
1268
|
-
}
|
|
1267
|
+
slotFingerprints.push(`${slotName}:[${instanceFingerprints.join(",")}]`);
|
|
1268
|
+
}
|
|
1269
|
+
if (slotFingerprints.length === 0) {
|
|
1270
|
+
return type;
|
|
1271
|
+
}
|
|
1269
1272
|
return `${type}{${slotFingerprints.join(";")}}`;
|
|
1270
1273
|
}
|
|
1271
1274
|
/**
|
|
@@ -3375,7 +3378,7 @@ function createPropagateRootComponentSlotCommand() {
|
|
|
3375
3378
|
// package.json
|
|
3376
3379
|
var package_default = {
|
|
3377
3380
|
name: "@uniformdev/transformer",
|
|
3378
|
-
version: "1.1.
|
|
3381
|
+
version: "1.1.8",
|
|
3379
3382
|
description: "CLI tool for transforming Uniform.dev serialization files offline",
|
|
3380
3383
|
type: "module",
|
|
3381
3384
|
bin: {
|