-
Notifications
You must be signed in to change notification settings - Fork 83
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
chore(flat-table-header): add displayName to component FE-5208 #5214
Conversation
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit d15cb0d:
|
Test summaryRun details
View run in Cypress Dashboard ➡️ This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard |
7434fc8
to
5ed77e7
Compare
5ed77e7
to
8042c45
Compare
…apping row headers Updates functionality to use `child.type.displayName` instead of `child.type`. This will allow wrapping of the `FlatTableRowHeader` component as the wrapper component can set its `displayName` to `FlatTableRowHeader.displayName` to ensure the required columns are sticky. fix #5208
19e86a9
to
d15cb0d
Compare
🎉 This PR is included in version 107.1.6 🎉 The release is available on: Your semantic-release bot 📦🚀 |
fix #5208
Proposed behaviour
Updates functionality to use
child.type.displayName
instead ofchild.type
. This will allowwrapping of the
FlatTableRowHeader
component as the wrapper component can set itsdisplayName
toFlatTableRowHeader.displayName
to ensure the required columns are sticky.Adds
displayName
property to children ofFlatTableRow
.Current behaviour
Wrapping the
FlatTableRowHeader
prevents sticky column functioning correctlyChildren of
FlatTableRow
have nodisplayName
propertyChecklist
QA
Additional context
Testing instructions
Use sandbox below, the one included in the linked issue will not work as there is no way to dynamically set the displayName on the wrapper. I have also added a story to demo how to implement this
flat-table--wrapping-row-headers
The following CodeSandbox is an example of the broken behaviour.
You can see the new behaviour by looking at the version in the comment by
codesandbox[bot]
.https://codesandbox.io/s/carbon-quickstart-forked-y63erp?file=/src/index.js