NestedHeaders specific row header

Tags: #<Tag:0x00007efc64853ec0> #<Tag:0x00007efc64853d80>

Hi, I’m just wondering is there any way to specify the specific rowHeaders for the specific nested Headers. I have the table as follows.
image
I want the above image to be updated as below,
updated%20nestedHeaders

Hi @rohithnaircn225

You can inject the custom HTML in the “zero” column with the afterGetColHeader hook, but it will apply for the whole column. This part of the table is not treated as the row headers.

Here’s an example: https://jsfiddle.net/handsoncode/rkpqb5j7/

so are you saying there is no way that we can do the nested headers as in the updated image that I posted? If yes, Can we add that as a feature in the latest versions. I think that feature come in handy for some persons and it makes sense.

@rohithnaircn225

Yes, currently something like this isn’t possible. I will let you know when this behavior change and we will allow altering the specific parts of the column headers with nested headers structure.

Thank you slight_smile:

Hi @adrian.szymanski
Can we merge all 4 rows in nested headers into one cell in the image I have provided. Could you provide an example, that would be appreciated.

Hi @rohithnaircn225

Do you mean to merge row headers? If so, that’s not possible, we allow only for merging the cells. You can see how it can be done here: https://handsontable.com/docs/react-data-grid/merge-cells/

Yes, I want to merge the first 4 empty row headers in the nested headers into one cell. Thanks for the reply.

One more thing, Can we define maximum column width for the nested headers. I didn’t find anything in the documentation. In the documentation there is only colWidths property.

@rohithnaircn225

That’s correct. We only allow for the general column width manipulation. Headers are bound to those values and depend on the column width.

Hi @adrian.szymanski

Do you have any plans to introduce a new feature for updating nested headers column width in the upcoming versions? If yes, when can we expect it. Thanks for the assistance.

Hi @rohithnaircn225

Currently, we don’t have such plans, but if anything will change in that topic I will let you know.

1 Like