Fix missing hints and error messages for input-type list & tag#2133
Merged
tdonohue merged 3 commits intoDSpace:mainfrom Apr 3, 2023
Merged
Conversation
- Added mapping for required & hint properties - Set the required type on the checkbox group instead of on each checkbox individually
list & tag
…nd-required-attributes-main # Conflicts: # src/app/shared/form/builder/ds-dynamic-form-ui/ds-dynamic-form-control-container.component.ts # src/app/shared/form/builder/ds-dynamic-form-ui/models/list/dynamic-list-checkbox-group.model.ts
08c2394 to
441eac2
Compare
tdonohue
approved these changes
Apr 3, 2023
Member
There was a problem hiding this comment.
👍 Thanks @alexandrevryghem ! Code looks good. Tested both tag and list and they now seem to work properly displaying hints and errors.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
References
listinput-type, the submission is rejected due to missing input, but no message displayed. #1770Description
Fixed a problem causing the hints for input types
listandtagto always be hidden.Fixed some problems causing the error messages and the asterisk not being displayed for input type
list.Instructions for Reviewers
List of changes in this PR:
tag&list) could not display their hint property when they were marked as<repeatable>true</repeatable>. This was because repeatable fields normally show their hints not underneath each field but in a section underneath all the input fields of that group with the+ Add morebutton, but for those 2 types of input types that whole section to add more input fields is hidden. So I added an exception inDsDynamicFormControlContainerComponentto also display the hint under repeatable dynamic array fields.listalso checked if every checkbox was selected individually instead of checking if at least one was selected.Guidance for how to test or review your PR:
submission-forms.xml➜ check that the hint of thedc.subjectfield is visibleinput-typeofdc.type&dc.language.isotolistrequiredtag:requiredtag empty:Checklist
yarn lintyarn check-circ-deps)package.json), I've made sure their licenses align with the DSpace BSD License based on the Licensing of Contributions documentation.