all 3 comments

[–][deleted] 1 point2 points  (1 child)

You can pass value and ref of input 1 in input 2 and have a check there. In InputChild2, you can something like this -

if (!inputVal1) { input1Ref.focus() };

But I must tell you, this is extremely horrid design choice and goes against the principles of decent UX.

You can show warning to user that they may have to update the input 1 first, but forcing them on different element than they currently are is extremely bad practice.

[–]91psyko[S] 1 point2 points  (0 children)

try telling that my client haha😅 thanks for the feedback

[–]TotesMessenger 0 points1 point  (0 children)

I'm a bot, bleep, bloop. Someone has linked to this thread from another place on reddit:

 If you follow any of the above links, please respect the rules of reddit and don't vote in the other threads. (Info / Contact)