-
Notifications
You must be signed in to change notification settings - Fork 1.2k
[DataTable] Allow JSX in the headers #2635
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
Conversation
💦 Potential splash zone of changes introduced to No significant changes to This comment automatically updates as changes are made to this pull request. |
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.
@PabloVallejo Good call, I just added a test and example to component README. |
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.
Test and README ✅ 💯
fcd77a2
to
3447e1d
Compare
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.
You can simplify the typing to just React.ReactNode[]
.
Petty but this appears in a few places so it's worth being as simple as possible :)
Fix up that and then this should be good to go
Thanks! I forgot that string was included. I've updated it to include your suggestion. |
bc223f5
to
56ef852
Compare
56ef852
to
73a8d3a
Compare
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.
WHY are these changes introduced?
Fixes #2597
We needed check boxes in our header but it was not supported. (Part of https://github.com/Shopify/store/issues/12522)
WHAT is this pull request doing?
Allow the header prop of DataTable to receive and display React Nodes.
How to 🎩
🖥 Local development instructions
🗒 General tophatting guidelines
📄 Changelog guidelines
Copy-paste this code in
playground/Playground.tsx
:🎩 checklist
README.md
with documentation changes