fix: Bound arrow elements for distribute and wyswig updates (#10702)

* fix: update distributeElements to updateBoundElements

Co-authored-by: Anvi Kudaraya <anvikudaraya417@gmail.com>

* fix: apply updateBoundElements when bound text extends past container height

Co-authored-by: Anvi Kudaraya <anvikudaraya417@gmail.com>

---------

Co-authored-by: Anvi Kudaraya <anvikudaraya417@gmail.com>
This commit is contained in:
Christopher Tangonan
2026-01-26 18:52:13 +01:00
committed by GitHub
co-authored by Anvi Kudaraya
parent 60759d314d
commit 28691e14b1
3 changed files with 24 additions and 9 deletions
@@ -58,6 +58,7 @@ const distributeSelectedElements = (
app.scene.getNonDeletedElementsMap(),
distribution,
appState,
app.scene,
);
const updatedElementsMap = arrayToMap(updatedElements);
@@ -14,6 +14,7 @@ import {
import {
originalContainerCache,
updateBoundElements,
updateOriginalContainerCache,
} from "@excalidraw/element";
@@ -208,6 +209,7 @@ export const textWysiwyg = ({
);
app.scene.mutateElement(container, { height: targetContainerHeight });
updateBoundElements(container, app.scene);
return;
} else if (
// autoshrink container height until original container height
@@ -221,6 +223,7 @@ export const textWysiwyg = ({
container.type,
);
app.scene.mutateElement(container, { height: targetContainerHeight });
updateBoundElements(container, app.scene);
} else {
const { x, y } = computeBoundTextPosition(
container,