Skip to content

Commit

Permalink
Use width/height from node, not default (but doesn't change anything …
Browse files Browse the repository at this point in the history
…because the node isn't rendered)
  • Loading branch information
Vadorequest committed Feb 4, 2021
1 parent bae5192 commit 8ac3059
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/components/nodes/InformationNode.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,11 @@ const InformationNode: BaseNodeComponent<Props> = (props) => {
console.log('event ...rest', rest);
console.log('event', event);

const {
width,
height,
} = event;

/**
* When textarea input height changes, we need to increase the height of the element accordingly.
*
Expand All @@ -59,8 +64,8 @@ const InformationNode: BaseNodeComponent<Props> = (props) => {
return (
<foreignObject
className={'information-node-container node-container'}
width={defaultWidth}
height={defaultHeight}
width={width}
height={height}
x={0}
y={0}
css={css`
Expand Down

0 comments on commit 8ac3059

Please sign in to comment.