-
Notifications
You must be signed in to change notification settings - Fork 74
Table: Error message styling for all Inputs #2721
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for moduswebcomponents ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
…t' into 2711---Input-Fire-valueError-event-on-error
@prashanthr6383 There are two scenarios with respect to validation.
Our form components already have the required support for consumer side validation so we will first focus on extending the same for the table component as a first step. This PR is related to the inbuild constraint validation that is not implemented in our form components yet, the proposed changes rely on the errorText that is passed by the consumer to emit the error event back to the consumer. With that said I'll move the PR to draft state for now until we decide on the desired behavior and what we are going to support. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AI generated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
File: stencil-workspace/src/components/modus-number-input/modus-number-input.tsx (line 70-78)
The valueError.emit(null) call in the else branch might not be necessary if the purpose is just to signal an error. Consider only emitting when there is an actual error rather than emitting null values.
File: stencil-workspace/src/components/modus-text-input/modus-text-input.tsx (line 137-145)
Similar to the number input, the valueError.emit(null) call in the else branch creates unnecessary event traffic. Consider only emitting when there is an actual error to report.
File: stencil-workspace/src/components/modus-select/modus-select.tsx (line 80-84)
The errorText check and error emission in connectedCallback could lead to unwanted error events during initial component setup. Consider if this is necessary at this lifecycle stage.
File: stencil-workspace/src/components/modus-autocomplete/modus-autocomplete.tsx (line 111-116)
The valueError emission is present in multiple handler methods but does not follow the pattern of emitting null when there is no error. Consider standardizing the error handling approach across components.
File: stencil-workspace/src/components/modus-number-input/modus-number-input.spec.tsx (line 14)
There is an unexpected space in the part attribute (input-container vs input-container ). This change appears in multiple component tests and may cause styling issues.
Description
Added new styles to the table inputs error message
note: for autocomplete duplicate error message is shown which is part of another issue #2720.
References
Fixes #2711, Fixes #2712, Fixes #2722, Fixes #2725, Fixes #2727
Type of change
How Has This Been Tested?
Checklist