Skip to content
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

Adding support for custom header cells #110

Closed
norav1 opened this issue Dec 7, 2021 · 5 comments
Closed

Adding support for custom header cells #110

norav1 opened this issue Dec 7, 2021 · 5 comments

Comments

@norav1
Copy link

norav1 commented Dec 7, 2021

Would it be possible to add support for custom rendering of the header cells as well?

Ideally I'd like to be able to have the capability to do something like this within the header cells:
https://codesandbox.io/s/9m9qs

I imagine the easiest way to implement this would be an additional prop such as the following:
drawHeaderCell?: (args) => boolean;

Otherwise, this library is perfect for my needs. Fantastic job.

@jassmith
Copy link
Contributor

jassmith commented Dec 7, 2021

I'll add a draw callback, will need to sit down and work out the details

@jassmith
Copy link
Contributor

Support has shipped in 3.1.3-alpha6. Please give it a try. There is an example committed to storybook for how to use it. You can return true to prevent the default drawing from happening, or you can just draw a background and return false to let the default foreground draw.

@jassmith
Copy link
Contributor

There will probably be some additional args added to handle dropdown menus but I wanted to give you a chance to test.

@norav1
Copy link
Author

norav1 commented Dec 10, 2021

Impressive how quickly you are able to build in features!
What is the name of the example in Storybook? I am flipping through each of the examples and I am not able to find it.
Thank you for your hard work.

@jassmith
Copy link
Contributor

You would need to look in the 3.1.3 branch. The production storybook wont update until I merge 3.1.3 to the main branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants