Skip to content

Dynamically changing rowSpan #3661

@RudmanMario

Description

@RudmanMario

I have a problem when trying to update my table. This is how my initial table looks like:

Image of initial table

So the rowspan here works fine. My "Row" table cell looks like this:

<th className="rotate header" rowSpan={this.props.tableFoo.axisY.ordinates.length}><div><span>Row</span></div></th>

So I'm looking for the length of ordinates array for axis Y and that is the number of rows which I want my "Row" cell to cover.
Then when user clicks "Add new Y ordinate", a new ordinate is pushed and table re-renders. This is the end result:
Image of final table

So for some reason, although the rowspan changes to 4 and I can see that when inspecting elements, for some reason the table cell spans only across 3 rows. Why is that? Is it a bug?
I made a fiddle so you can see the problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions