Chat Textarea loses focus after value is entered
complete
Esther White
I have tried https://www.getmerlin.in/chat on:
Chrome Version 134.0.6998.36 (Official Build) (64-bit)
Firefox version 136.0 (64-bit)
Brave 1.76.73 Chromium: 134.0.6998.45 (Official Build) (64-bit)
So no - not a browser issue.
The same behaviour repeats, which is a strong indication that in your app, built with - React 18.3.0-canary-178c267a4e-20241218, Tailwind CSS 3.4.17, amongst other tech, you have not handled the focus of the textarea properly. I believe I explained that very clearly when I first reported it, but let me be even more clear:
The send button is set to be disabled if the textarea has no value, I assume something like textareaValue = "", now as soon as this condition changes - user writes any value, of course the send button becomes enabled, which is fine, however at the same time - the unwanted behaviour is that the textarea loses focus and user has to click on it to continue typing.
This issue typically occurs when the React component re-renders due to state or props changes, causing the textarea to lose focus. In your case, it seems that when the textareaValue changes, React is performing a re-render, and the textarea loses focus because it's not properly managed.
Please have someone look into it.
S
Siddhartha
complete
We have pushed a fix for this, please let us know if it still persists.
Esther White
Siddhartha I can confirmed that right now the issue is resolved, thank you very much, your efforts are highly appreciated, working with Merlin AI is a lot easier and far more enjoyable now
S
Siddhartha
Esther White Sorry for the issue in the first place!
S
Siddhartha
in progress
Esther White
I don't want to be all negative - I do know that it is a lot of hard work and there are some really cool features implemented in awesome way, they are a lot so I will not go into listing them one by one but I just thought it was worth mentioning too, it is noticed and appreciated