Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion src/core/bounds/bounds.utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,12 @@ export const calculateBounds = (
const { centerZoomedOut } = contextInstance.setup;

if (!wrapperComponent || !contentComponent) {
throw new Error("Components are not mounted");
return {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately, this causes resetTransform to not work

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How exactly? I mean this change should affect anything only at first render time to prevent this component throwing an error in case of a delayed render of a children.

minPositionX: 0,
maxPositionX: 0,
minPositionY: 0,
maxPositionY: 0,
}
}

const {
Expand Down