publ-echo-test 0.0.99 → 0.0.100
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.
@@ -457,21 +457,24 @@ export var findAccessibleChildrenBlocks = function (blockStructure, targetGroupI
|
|
457
457
|
for (var _i = 0, _a = block.children; _i < _a.length; _i++) {
|
458
458
|
var child = _a[_i];
|
459
459
|
if (blockIds.includes(child.blockId)) {
|
460
|
-
result.add(block.blockId);
|
460
|
+
result.add(block.blockId);
|
461
|
+
return true; // Stop traversal for this branch
|
461
462
|
}
|
462
|
-
|
463
|
-
|
463
|
+
if (traverse(child)) {
|
464
|
+
result.add(block.blockId);
|
465
|
+
return true; // Stop traversal for this branch
|
464
466
|
}
|
465
467
|
}
|
466
468
|
}
|
469
|
+
return false;
|
467
470
|
};
|
468
471
|
for (var _i = 0, _a = targetBlock.children; _i < _a.length; _i++) {
|
469
472
|
var child = _a[_i];
|
470
473
|
if (blockIds.includes(child.blockId)) {
|
471
|
-
result.add(child.blockId);
|
474
|
+
result.add(child.blockId);
|
472
475
|
}
|
473
476
|
else {
|
474
|
-
traverse(child);
|
477
|
+
traverse(child);
|
475
478
|
}
|
476
479
|
}
|
477
480
|
return Array.from(result);
|