open-formulieren / open-forms-sdk

A Javascript SDK for Open Forms
https://open-forms.readthedocs.io/en/stable/developers/sdk/index.html
Other
2 stars 6 forks source link

[OF#4382] Missing client validation for email in the save and resume modal #692

Closed vaszig closed 1 month ago

vaszig commented 2 months ago

Fixes open-formulieren/open-forms#4382

codecov[bot] commented 2 months ago

Codecov Report

Attention: Patch coverage is 14.28571% with 24 lines in your changes missing coverage. Please review.

Project coverage is 63.01%. Comparing base (3a3ec09) to head (44bb611).

Files Patch % Lines
src/components/modals/FormStepSaveModal.js 14.28% 23 Missing and 1 partial :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #692 +/- ## ========================================== + Coverage 62.86% 63.01% +0.15% ========================================== Files 224 224 Lines 4136 4159 +23 Branches 841 844 +3 ========================================== + Hits 2600 2621 +21 Misses 1414 1414 - Partials 122 124 +2 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

vaszig commented 2 months ago

While the fix is indeed adding validation, I'm missing some bits in this PR:

* Story updates/interaction tests -> `src/components/modals/FormStepSaveModal.stories.js`

* Translations - now the validation errors are displayed always in English. See https://open-formulieren.github.io/open-forms-sdk/?path=/docs/developers-documentation--docs#handling-validation-errors-with-zod for instructions

Yes, sorry I forgot to do that as a draft. I wanted to add a story but again I would have forgotten the translations.