rnadigital / agentcloud

Agent Cloud is like having your own GPT builder with a bunch extra goodies. The GUI features 1) RAG pipeline which can natively embed 260+ datasources 2) Create Conversational apps (like GPTs) 3) Create Multi Agent process automation apps (crewai) 4) Tools 5) Teams+user permissions. Get started fast with Docker and our install.sh
https://agentcloud.dev
GNU Affero General Public License v3.0
421 stars 90 forks source link

[webapp] Improve client side form handling/errors UX #241

Open tomlynchRNA opened 1 week ago

tomlynchRNA commented 1 week ago

Currently there is very little frontend form validation besides some required and pattern fields. This needs to be expanded to encompass all fields of all forms. Most forms are located and named like components/*Form.tsx

One option is relying on native form validation (required, pattern, minlength, maxlength, etc). This means as long as a form is submitted in a <form> and our handler is in the onSubmit, we don't have to write custom code to validate each input field. However this will struggle with custom components such as react-tailwindcss-select because they don't have an underlying input field that matches the state of what is selected.

Alternatively, you could use an approach similar to material ui where they have a helperText and error props on input fields that you set yourself.

Discuss in this comment which solution (or suggest another) you think is best before going ahead.