orcasvn-react-diagrams 0.2.7 → 0.2.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/CHANGELOG.md +11 -0
- package/README.md +6 -12
- package/ai/manifest.json +1 -1
- package/dist/cjs/examples.js +253 -13
- package/dist/cjs/index.js +4 -2
- package/dist/esm/examples.js +253 -13
- package/dist/esm/examples.js.map +1 -1
- package/dist/esm/index.js +4 -2
- package/dist/esm/index.js.map +1 -1
- package/docs/DOCUMENTATION_WORKFLOW.md +2 -1
- package/package.json +1 -1
- package/src/displaybox/demos/AutoLayoutDemoTab.tsx +11 -5
- package/src/displaybox/demos/autoLayoutDemo.ts +233 -0
- package/src/displaybox/demos/basicDemo.ts +6 -6
- package/src/displaybox/demos/selectionDemo.ts +12 -12
package/dist/esm/index.js
CHANGED
|
@@ -2439,6 +2439,8 @@ var AutoLayoutService = /** @class */ (function () {
|
|
|
2439
2439
|
return this.applyResolvedLayout(parentId, parent, desiredPositions, desiredSizes, {
|
|
2440
2440
|
width: newParentWidth,
|
|
2441
2441
|
height: newParentHeight,
|
|
2442
|
+
}, {
|
|
2443
|
+
preserveResizedLayoutParentSize: true,
|
|
2442
2444
|
});
|
|
2443
2445
|
};
|
|
2444
2446
|
AutoLayoutService.prototype.resolveGridCellWidths = function (rowInnerWidth, weights) {
|
|
@@ -2448,7 +2450,7 @@ var AutoLayoutService = /** @class */ (function () {
|
|
|
2448
2450
|
var safeWeights = weights.map(function (weight) { return _this.clampGridUnits(weight); });
|
|
2449
2451
|
return this.distributeWeightedSizes(Math.max(0, rowInnerWidth), safeWeights);
|
|
2450
2452
|
};
|
|
2451
|
-
AutoLayoutService.prototype.applyResolvedLayout = function (parentId, parent, desiredPositions, desiredSizes, parentSize) {
|
|
2453
|
+
AutoLayoutService.prototype.applyResolvedLayout = function (parentId, parent, desiredPositions, desiredSizes, parentSize, options) {
|
|
2452
2454
|
var _this = this;
|
|
2453
2455
|
var _a;
|
|
2454
2456
|
var patches = [];
|
|
@@ -2467,7 +2469,7 @@ var AutoLayoutService = /** @class */ (function () {
|
|
|
2467
2469
|
var resizePatches = _this.commandQueue.run(createResizeElementCommand(childId, fittedSize), _this.model);
|
|
2468
2470
|
patches.push.apply(patches, resizePatches);
|
|
2469
2471
|
movedPortIds.push.apply(movedPortIds, _this.collectElementPortIds(childId));
|
|
2470
|
-
var nested = _this.applyLayoutForParent(childId);
|
|
2472
|
+
var nested = _this.applyLayoutForParent(childId, (options === null || options === void 0 ? void 0 : options.preserveResizedLayoutParentSize) ? { preserveParentSize: true } : undefined);
|
|
2471
2473
|
patches.push.apply(patches, nested.patches);
|
|
2472
2474
|
movedPortIds.push.apply(movedPortIds, nested.movedPortIds);
|
|
2473
2475
|
}
|