expose `FormControlFeedback` (props?) in `Form.Autosuggest`
brian-smith-tcril opened this issue · comments
from openedx/frontend-app-authn#1133 (comment)
In addition to the missing onErrorStateChange, the reason for not using the internal error state provided by Form.Autosuggest is the way it renders error. It is prefixed with "x" icon with no way to remove it. All other errors on Authn don't have it and this makes the form errors inconsistent.
This is happening because we are using default props for FormControlFeedback
in Form.Autosuggest
, meaning hasIcon
is always set to true
paragon/src/Form/FormAutosuggest.jsx
Lines 333 to 343 in 2801667
paragon/src/Form/FormControlFeedback.jsx
Lines 48 to 54 in 2801667
The simplest solution to this exact use case would be to just expose hasIcon
, but it's worth exploring how/how much of FormControlFeedback
we want to expose here.
https://paragon-openedx.netlify.app/components/datatable/#paginated-selection example of bulk actions components being passed in was discussed in Paragon WG. I will try following that pattern to implement this