width property

double? width

The width of the snack bar.

If width is specified, the snack bar will be centered horizontally in the available space. This property is only used when behavior is SnackBarBehavior.floating. It can not be used if margin is specified.

If this property is null, then SnackBarThemeData.width of ThemeData.snackBarTheme is used. If that is null, the snack bar will take up the full device width less the margin.


final double? width;