jomarko commented on PR #2254:
URL: 
https://github.com/apache/incubator-kie-tools/pull/2254#issuecomment-2078738447

   @ljmotta thank you for your help! The `useRef` hook usage with string was 
knowledge that I was missing. In examples, it is often used more with some 
`input` element. I like we use it for string variable.
   
   Also, I like the change we added `nodeId` parameter to `setBounds` and we 
pass it from `onBlur` handlers.
   
   The only change I needed to do, was a place we 'sync' `previousNodeId`, 
because during a manual checks I found another corner scenario, not original 
one, that was not working, I describe it here so you can double-check my 
changes are appropriate.
   
   - Imagine we have a diagram with two nodes, lest say **A** and **B**
   - Lets resize them, you can use drag handler in the corner of the node, to 
make the behavior obvious, for the **A** lets increase its width and for the 
**B** lets increase its height
   - Now, please open **A** properties panel, its Shape section, set focus to 
its **width** field, i.e. click into it, or use **Tab** until the cursor is in 
the **width**
   - Keep the focus in the **width** and keep the Properties panel open please
   - Now, click the node **B**, i.e. select the node **B**
   - Repeat the previous focus exercise for this node **B**. Set focus to its 
**width** or **height** field. However, just set focus to them, do not change 
the value.
   - Now, again without closing or reopening the Properties panel, select node 
**A**
   - ❗ here you will see that the node **A** would be inappropriately resized 
using **width**/**height** values of the node **B**


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to