feat(resizer): Add support for maxWidth and maxHeight

This commit is contained in:
stffabi
2023-02-17 08:28:48 +01:00
parent afa38727fa
commit 5becbb1ebe
3 changed files with 14 additions and 4 deletions
@@ -14,6 +14,8 @@ export default function NodeResizer({
color,
minWidth = 10,
minHeight = 10,
maxWidth = Number.MAX_VALUE,
maxHeight = Number.MAX_VALUE,
shouldResize,
onResizeStart,
onResize,
@@ -36,6 +38,8 @@ export default function NodeResizer({
color={color}
minWidth={minWidth}
minHeight={minHeight}
maxWidth={maxWidth}
maxHeight={maxHeight}
onResizeStart={onResizeStart}
shouldResize={shouldResize}
onResize={onResize}
@@ -52,6 +56,8 @@ export default function NodeResizer({
color={color}
minWidth={minWidth}
minHeight={minHeight}
maxWidth={maxWidth}
maxHeight={maxHeight}
onResizeStart={onResizeStart}
shouldResize={shouldResize}
onResize={onResize}