Is there a way to ALWAYS have horizontal scrollbar visible for MUI Data Grid?

Viewed 16

I have a Datagrid table in which column virtualization is enabled. There will always be > 25 columns on this table. With a trackpad; a user can quickly scroll horizontally, however, without a trackpad I am worried users won't be able to access the other columns as the scrollbar only appears after scrolling is triggered already.

Is there a way to make the horizontal scrollbar always visible? I have tried adding overflow-x: scroll on MuiDataGrid-virtualScroller and also on MuiDataGrid-virtualScrollerContent but that did not work. Anyone with a solution?

enter image description here

1 Answers

i think you can try set width absolute value: EX: width:250, not flex:1. i think it can help you .

{ field: "id", headerName: "ID", width: 250},

Related