Improved Error Messages in PreferencesComponent.tsx#1603
Improved Error Messages in PreferencesComponent.tsx#1603BrianRaymond800 wants to merge 1 commit into
Conversation
huss
left a comment
There was a problem hiding this comment.
@BrianRaymond800 Thank you for addressing this issue. I made a couple of comments to consider. In the bigger picture, I looked (may not have found every one) but this change makes this warning message different than other pages:
- The date range min/max on the same page.
- The reading min/max on the unit page.
- Both of these on the meter page.
It is a little nicer that your change consistently shows about negative values but I think OED wants to be consistent. Assuming the other comments are resolved, a careful check for all other places with changes to be consistent would be needed to move this forward.
Please let me know if anything is not clear or you have thoughts/questions.
| /> | ||
| ) : ( | ||
| <FormattedMessage | ||
| id="error.bounds" |
There was a problem hiding this comment.
There are formatting issues with this file: 1) wrong indenting; 2) space indenting instead of tabs. VSC can fix this with commands.
| ) : ( | ||
| <FormattedMessage | ||
| id="error.greater" | ||
| values={{ min: Number(localAdminPref.defaultWarningFileSize) }} |
There was a problem hiding this comment.
This used to check for max of infinity. Now one can enter a really big value and submit it. Then it fails to save. I prefer the other way.
Description
This is a simple change to address a concern from Issue Nineteen. Most of Issue Nineteen's problems have already been fixed by other contributors, but this pull request addresses an issue with error messages that were not fully descriptive.
Fixes Issue 19
Type of change
Checklist
Limitations
A few of the areas mentioned in Issue 19 could have further error message improvements in order to be more clear for users, but this would best be done in a larger assessment of all of the routes and their associated error messages.