-
Notifications
You must be signed in to change notification settings - Fork 1.9k
fix(OverflowMenu): forwardsRef #19035
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
fix(OverflowMenu): forwardsRef #19035
Conversation
✅ Deploy Preview for v11-carbon-web-components ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
✅ Deploy Preview for v11-carbon-react ready!Built without sensitive environment variables
To edit notification comments on pull requests, go to your Netlify site configuration. |
✅ Deploy Preview for v11-carbon-react ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
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.
Curious, were you relying on innerRef
before?
Would you mind adding a couple tests to ensure each usage works as expected? Something lightweight like this maybe?
carbon/packages/react/src/components/Breadcrumb/__tests__/Breadcrumb-test.js
Lines 77 to 82 in ae084a4
it('should accept a `ref` for the outermost element', () => { | |
const ref = jest.fn(); | |
const { container } = render(<Breadcrumb ref={ref} />); | |
expect(ref).toHaveBeenCalledWith(container.firstChild); | |
}); |
@tay1orjones haha yes I was just on that |
Pushing the test while we talk 👍🏻 |
@AlexanderMelox Hey I don't think this will fix #19046 since |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #19035 +/- ##
=======================================
Coverage 84.96% 84.96%
=======================================
Files 391 391
Lines 14490 14491 +1
Branches 4773 4721 -52
=======================================
+ Hits 12312 12313 +1
- Misses 2029 2030 +1
+ Partials 149 148 -1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
65f005a
Fixes test issue over in ibm-products carbon-design-system/ibm-products#7199
Currently updating to the latest version of carbon
v11.79.0
fails our forwardRef testsCurrently our
ButtonMenu
component utilizesOverflowMenu
under the hoodChangelog
Changed
OverflowMenu