future-architect / cheetah-grid

The fastest open-source data table for web.
https://future-architect.github.io/cheetah-grid/
MIT License
1.46k stars 117 forks source link

Fill Cell by message type #383

Closed svalench closed 2 years ago

svalench commented 2 years ago

Hello. Need help with your library. There is a desire to paint cells based on the data that is there by condition. The exclamation mark is removed in the message property, and I want to change the background color. I found your "fillCell" method. But I did not understand how I can get the CellContext of the cell for call this method. Thanks in advance.

ota-meshi commented 2 years ago

Thank you for posting issue.

I think you can use a function to paint different background colors for the cells. The example in the following link is how to change the text color, but I think you just need to change it to use bgColor.

https://future-architect.github.io/cheetah-grid/documents/api/js/column_styles.html#advanced-column-style

svalench commented 2 years ago

thanks a lot for fast answer, this is what i need!