Closed kasumi-1 closed 1 day ago
This turned out to be a bigger task. I managed to add succesfully the validations, also I needed to add extra inputs because we need the user to be able to specify a maxjobTime using units, also with categories and tags (because we're using mece tags). After I added everything, I noticed that the listboxes weren't working. I spent some time debugging it and came to the conclusion that the problem comes from the headlessUI library. Basically when you use the Dialog from the headlessUI AND the listbox from headlessUI simultaneously, the html from the listbox breaks, and it doesn't allow you to hover other items or select anything.
Tried to fix it, but it is really mesed up. What I'm seeing is the dom is a component completely different. I assume this happens because both dialog and listbox components has similar properties
Possible solutions:
At the end the neccesary solution was to use the "Select" headlessUI component. I created a new reusable component that looks the same as the rest, the dropdown isn't the same of the postJob but I think its fair enough for our Dialog editjob post.
https://github.com/semperai/effectiveacceleration.ai/commit/9ff50bd9979481a16982d08294b1a437b5353e70
all fields should be properly validated like on create job page