goinvo / staffplan-next-app

Next App for Staffplan
https://staffplan-next-app.vercel.app
1 stars 1 forks source link

validation, client modal, redirect #39

Closed HankC138 closed 6 months ago

HankC138 commented 6 months ago

added form validation, add Client modal, redirect to parent page on cancel or submit

vercel[bot] commented 6 months ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
staffplan-next-app ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 15, 2024 6:29pm
fermion commented 6 months ago

@HankC138 would you mind adding a screenshot and/or short clip showing the new stuff in action? I've used https://getkap.co in the past 🙏🏻

fermion commented 6 months ago

At first glance this looks good — did you by any chance look around for a library we might tap into for this sort of thing? Something like https://react-hook-form.com/ came up on a very quick search.

Not at all being prescriptive here! If our needs stay simple enough then a library may be overkill 🤷🏻

HankC138 commented 6 months ago

https://github.com/goinvo/staffplan-next-app/assets/114195647/026f0cc4-2d0f-43bd-8eef-340bf73cc76d

https://github.com/goinvo/staffplan-next-app/assets/114195647/3aff55ae-b006-46d7-87a7-465aeb2aaf00

Here's a couple quick vids of it that show the project modal in it's current state and some validations popping up. Any of the current validations I have in place can be altered to suit our needs.

I'm currently using the formik library to handle the forms and the validation. I think realistically both libraries are immensely popular in terms of managing a form in react, I just chose Formik as I've used it more than react hook form.

MyStarrySpace commented 6 months ago

Looks good to me! I think that Formik is good for our forms.