JavaScript UI Libraries & Blazor Components Suite – Smart UI › Forums › Data Grid › Dynamic resize of a row due to complex cell editor › Reply To: Dynamic resize of a row due to complex cell editor
I have another question regarding row resizing.
I have the grid in an Angular application so it is created when the component it lives in is created. When I first bring up the component the row resizing works correctly. I set the height on the row via row.height = xxxx. I also tried grid.setRowProperty.
If I close the component then re-open it resizing on longer works. I can set row.height to anything, nothing sticks. Maybe there is some old data or references that were not cleaned up. I assume there is an ngOnDestroy method for any angular representation of a SmartHTML component. Is there anything I am not doing that I need to when destroying the table?
I have not set any properties on grid.layout (no auto height). My guess is it is getting re-created and kills any changes. The template/editors are re-drawn throughout the grids life. I was under the impression if I changed the rowHeight to xxx it would stick, but I must be misunderstanding nuances of how the properties are persisted.
Overall is dynamically changing the height of a row something that is supported? I am sure it is technically in that it is possible, but is it something that is considered “normal” for the Grid? I am asking in terms of just setting row.height several times after the grid has been initialized. I know there is layout.rowHeight, onRowInit, behavior of growAndShrink which I believe is you manually use the mouse to change the height.
My use case is I have a cell editor that is complex, needs more height. I don’t want to set the row height to a fixed value that is good for the editor because the template/renderer does not need to be that high. I’d like the row to use as little height as possible.