Skip to content

Grid columns headers have no width on refresh #2193

@severin2

Description

@severin2

We have an app where we change the columns of the grid often, we do this by building a list of columns from the data property keys.

  1. click the 'data set 3' button, observe that data set 3 is displayed and its columns are correctly drawn
  2. click the 'data set 2' button, observe that data set 2 is displayed and its columns are correct
  3. click the 'data set 1' button, observe that data set 1 is displayed but its column headers have no width and overlap
  4. notice that now switching between 'data set 1' and 'data set 2' will not fix the headers, but switching to 'data set 3' will (presumably because the significant change between the columnDefs?)

plunker example: http://plnkr.co/edit/RDEC8e?p=preview

I've noticed that in our app, the column headers get classes dynamically added to them like .grid1416592787863 .ui-grid-coluiGrid-082 and on the columns that are correctly drawn these classes are what gives the headers their width and on the columns that are drawn incorrectly they do not.

I am experimenting with using a custom headerTemplate to enforce the header width but I am still working on getting the header to play nice with the rest of the grid's concept of the column width.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions