<DataGrid
  {...data}
  localeText={{
    toolbarDensity: 'Size',
    toolbarDensityLabel: 'Size',
    toolbarDensityCompact: 'Small',
    toolbarDensityStandard: 'Medium',
    toolbarDensityComfortable: 'Large',
  }}
  slots={{
    toolbar: GridToolbar,
  }}
/>