metrotranscom / doorway

Bloom is Exygy’s affordable housing platform. Bloom's goal is to be a single entry point for affordable housing seekers and a hub for application and listing management for developers.
https://www.bloomhousing.com
Apache License 2.0
3 stars 1 forks source link

Open house field validation #771

Open sarahlazarich opened 4 months ago

sarahlazarich commented 4 months ago

Bug: On Doorway Partners, you can enter letters in the open house date/time field, which causes the field to read "invalid date" on the public and partners sites.

https://www.loom.com/share/ebc3396871d94700bd69378bacc7722e

Expected behavior: You should not be able to enter letters in the date field, or anything that would cause the date to be invalid

sarahlazarich commented 3 months ago

ML: Do we have this validation for other date fields? Not sure ML: FE validation only? Or do we want BE? EM: You can do this in the FE because it's part of it's own form ML: Does the BE error when this happens or just let it through? EM: Not sure

Is this a validation check, or literally not allowing letters to be entered into the field? Probably just a validation thing - you can't publish the listing without validating the dates/times vs doing something at the input level. But, it would be better UX probably to prevent users from inputting letters, which would be a UIC change, but that is a much larger lift.

Only issue is that the current field is in a modal, which means the error is a bit hidden. There might be validation in that drawer for required fields, but only for required fields. This ticket should also apply to core.

ML: Go forward with the UIC validation on the date field, limit it to just entering letters. There is other validation we can do going forward.

JW: In storybook, there is validation on date/time for these fields so maybe this is some kind of other bug here? Do more investigation as a part of this ticket. As a part of this investigation, can we check all the other spots in partners to see if this is the only place this is happening?

Update from chat: looks like we are only validating date fields in uic if the field is required

jaredcwhite commented 2 months ago

D'oh! No sooner did bloom-housing/ui-components#157 get merged in than I realized I'd only updated the Date field, not the Time field. Back to the drawing board!

sarahlazarich commented 4 weeks ago

looks good!