-
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(dropdown): add renderSelectedItem prop #10188
feat(dropdown): add renderSelectedItem prop #10188
Conversation
✔️ Deploy Preview for carbon-react-next ready! 🔨 Explore the source changes: facc191 🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-react-next/deploys/61af9aad4139e1000780b0bd 😎 Browse the preview: https://deploy-preview-10188--carbon-react-next.netlify.app |
✔️ Deploy Preview for carbon-elements ready! 🔨 Explore the source changes: facc191 🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-elements/deploys/61af9aad98d7200007f3e2a7 😎 Browse the preview: https://deploy-preview-10188--carbon-elements.netlify.app |
✔️ Deploy Preview for carbon-components-react ready! 🔨 Explore the source changes: facc191 🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-components-react/deploys/61af9aadffe84500074f6068 😎 Browse the preview: https://deploy-preview-10188--carbon-components-react.netlify.app |
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.
Hey there! Code lgtm, but do you think we could demonstrate this props intended usage in the story you've built out. Might help with reviews as well 👍🏾
Yep! @dakahn, I just pushed up a version that uses icons in both the |
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.
This looks good to me! The story is a big help thanks. Tested and speaks as expected with both NVDA and JAWS 2021 on Windows 11 🏄🏾
Closes #10038
Adds a renderSelectedItem prop as a callback when it would be helpful to render the currently selected item as an element instead of just text
Changelog
New
selectedItem
as an elementChanged
Testing / Reviewing