Skip to content

Is it possible to throw custom component into the column header (SheetComponent)? #3156

Closed Answered by Alexzjt
corocoto asked this question in Q&A
Discussion options

You must be logged in to vote

@corocoto Hey there! 👋 I'm not entirely sure what your exact needs are here. If you're trying to customize column header cells, you might want to check out this col-cell customization example. You can achieve custom styling by extending/overriding the col-cell class at packages/s2-core/src/cell/col-cell.ts.

👋 If you're asking about rendering React components inside column header cells, I'd generally advise against mixing DOM elements with Canvas rendering unless absolutely necessary. This approach might lead to unexpected issues like:

⚠️ Z-index conflicts (Canvas vs DOM layers)
⚠️ Performance bottlenecks with frequent re-renders
⚠️ Coordinate synchronization headaches

But if you must rend…

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@corocoto
Comment options

@corocoto
Comment options

Answer selected by corocoto
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants