How can I get rid of this extra space?
dag.AgGrid(rowData=test_df.to_dict("records"), columnDefs=column_defs,
defaultColDef={'filter': False,"wrapText": True,"cellStyle": {"wordBreak": "normal", "lineHeight": "unset"}},
columnSize="responsiveSizeToFit", dashGridOptions={"domLayout": "autoHeight"}, style={'height': None})
As per the documentation I have the autoHeight
set.
I have the table rendered in a DMC Grid under a GridCol
dmc.GridCol(span=12, children=html.Div(children=,id=‘input_processed_comparison_table’,style={‘height’:‘150px’}),style={‘height’:‘150px’})
Even forcing the heights to specific resolution did not work for me. Anything I am missing?
The dag-docs need to be updated for V31. But the upstream AG grid docs had the answer:
Min Height with Auto Height
When using Auto Height, there is a minimum of 150px set to the grid rows section. This is to avoid an empty grid which would look weird. In particular, this allows room to show the ‘no rows’ message when no rows are in the grid, otherwise this message would be overlaying on top of the header. To remove this minimum height, add the following CSS:
.ag-center-cols-viewport {
min-height: unset !important;
}
It is not possible to specify a max height when using auto-height.
Users ask is it possible to set a max height when using auto-height? The answer is no. If using auto-height, the grid is set up to work in a different way. It is not possible to switch. If you do need to switch, you will need to turn auto-height off.