padding property Null safety
final
The amount of padding to apply to the snack bar's content and optional action.
If this property is null, the default padding values for:
- content
- Top and bottom paddings are 14.
- Left padding is 24 if behavior is SnackBarBehavior.fixed, 16 if behavior is SnackBarBehavior.floating
- Right padding is same as start padding if there is no action, otherwise 0.
- action
- Top and bottom paddings are 14
- Left and right paddings are half of content's left padding.
If this property is not null, the padding assignment for:
- content
- Left, top and bottom paddings are assigned normally.
- Right padding is assigned normally if there is no action, otherwise 0.
- action
- Left padding is replaced with half value of right padding.
- Top and bottom paddings are assigned normally.
- Right padding has an additional half value of right padding.
right + (right / 2)
Implementation
final EdgeInsetsGeometry? padding;