viclafouch / mui-otp-input

📌 A One-Time Password input designed for the React library MUI
https://viclafouch.github.io/mui-otp-input
123 stars 25 forks source link

Improve focus handling #36

Open ceejae-cashew opened 1 year ago

ceejae-cashew commented 1 year ago

I have a use case where as the user types, filled OTP boxes should retain the focused color.

What makes it a little weirder with the current implementation is that I have two focused states (The active OTP box and whichever box is currently hovered).

Screenshot 2023-10-02 at 1 21 13 PM

The ideal expectation is the first 3 OTP boxes should have the active state (since they have values) and the fourth one should also be active because it's the currently focused input.

Great project by the way! 💯

viclafouch commented 8 months ago

Hello here !

I'm not sure what are you expect as a solution :/

Feel free to open a PR or give more details plz :)