-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
feat(textInput, textArea, Select): move classNames to outer wrapper #9502
feat(textInput, textArea, Select): move classNames to outer wrapper #9502
Conversation
✔️ Deploy Preview for carbon-react-next ready! 🔨 Explore the source changes: 8714b90 🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-react-next/deploys/6130ed3f3d2bfc0007f56fc8 😎 Browse the preview: https://deploy-preview-9502--carbon-react-next.netlify.app/ |
✔️ Deploy Preview for carbon-elements ready! 🔨 Explore the source changes: 60c5512 🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-elements/deploys/611d4929a5e13b0008fcb295 😎 Browse the preview: https://deploy-preview-9502--carbon-elements.netlify.app |
✔️ Deploy Preview for carbon-elements ready! 🔨 Explore the source changes: 8714b90 🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-elements/deploys/6130ed3f4d41b1000709a0e0 😎 Browse the preview: https://deploy-preview-9502--carbon-elements.netlify.app |
✔️ Deploy Preview for carbon-components-react ready! 🔨 Explore the source changes: 8714b90 🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-components-react/deploys/6130ed3fca168d00070cfbbe 😎 Browse the preview: https://deploy-preview-9502--carbon-components-react.netlify.app |
Looks like const textInputClasses = classNames(`${prefix}--text-input`, [enabled ? null : className] |
Co-authored-by: TJ Egan <tw15egan@gmail.com>
Co-authored-by: TJ Egan <tw15egan@gmail.com>
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.
LGTM once test stories are removed
Closes #9465
Uses the
feature-flags
package to move theclassName
prop to the outer wrapper.Changelog
New
className
prop to the outermost wrapper so that all elements inside are targetable via cssChanged
className
prop was being added inside an element, it now returns null when the V11 feature flag is enabled. Instead, it is placed on the outer wrapperTesting / Reviewing
Test the following components, which each have a test story:
Class Name Change Test
that will be removed before merging:Ensure
className
is placed on the outer wrapper if wrapped in theFeatureFlag
element.className
should remain in the same spot otherwise