codeforbtv / baby-equipment-exchange

MIT License
0 stars 8 forks source link

Input fields and event behavior #9

Closed NathanWEdwards closed 10 months ago

NathanWEdwards commented 1 year ago

The login page has two fields email and password that update state based on OnChange events. Input from methods like autocomplete do not trigger OnChange events.

Updating input tags to update state when OnInput events occur may provide a more fluid user experience.

Example use case user scenario: As a user, when selecting an input field within the web application and an auto-fill option is available, when I select the auto-fill option, the page should accept the auto-fill supplied text as input.

bryanparmelee commented 1 year ago

From what I gather, onChange behaves a little differently in React and appears to be what they recommend using. https://react.dev/reference/react-dom/components/select#props Screen Shot 2023-08-14 at 4 00 16 PM

That said, I think these input fields should include an autoFill attribute. I added that to each and was able login using autofill in Chrome, Safari and Firefox, but I'm happy to use onInput instead if that's what we prefer.

NathanWEdwards commented 10 months ago

Input field events are following best practices.