cds-snc / platform-forms-client

NextJS application that serves the public-facing website for Forms
https://forms-staging.cdssandbox.xyz/
MIT License
34 stars 13 forks source link

Repeating sets - Customizable content #4297

Open anikbrazeau opened 1 week ago

anikbrazeau commented 1 week ago

Make customizable content required? Set name and Add/Remove Button copy?

Steps to reproduce

  1. Add a repeating set
  2. Click customize element
  3. Remove all prepopulated content
  4. Save

Expected behaviour

Should this content be mandatory in some aspect? What happens if these are empty?

Screenshots or videos

Screenshot 2024-09-19 at 3 19 09 PM
timarney commented 1 week ago

Should this content be mandatory in some aspect? What happens if these are empty?

1) We can add some can't be empty checks to the modal

2) We can do some handling at the server level - currently "Item" defaults for en and fr --- this has been the case pre form builder.

Screenshot 2024-09-20 at 8 06 46 AM
timarney commented 1 week ago

@anikbrazeau

I added a commit to add a generic error message if any of the fields are empty

https://github.com/cds-snc/platform-forms-client/pull/4263/commits/8fd102541d9caac49f845cb84c34fdbec26b10b6

I think given we default the content (pre-filled in) this should work well.