SnackBarConfig constructor

const SnackBarConfig({
  1. LinearGradient? backgroundGradient,
  2. Color backgroundColor = Colors.black54,
  3. Color colorText = Colors.white,
  4. double barBlur = 7,
  5. double borderRadius = 15,
  6. double maxWidth = 600,
  7. EdgeInsets margin = const EdgeInsets.all(15),
  8. EdgeInsets padding = const EdgeInsets.all(15),
  9. SnackPosition snackPosition = SnackPosition.TOP,
})

构造函数

参数说明

  • backgroundGradient 背景渐变色
  • backgroundColor 背景色,默认为Colors.black54
  • colorText 文字颜色,默认为白
  • barBlur 背景模糊度,默认7
  • borderRadius 圆角,默认15
  • maxWidth 最大宽度,默认600
  • margin 外边距,默认EdgeInsets.all(15)
  • padding 内边距,默认EdgeInsets.all(15)
  • snackPosition 弹窗位置,默认顶部

Implementation

const SnackBarConfig({
  this.backgroundGradient,
  this.backgroundColor = Colors.black54,
  this.colorText = Colors.white,
  this.barBlur = 7,
  this.borderRadius = 15,
  this.maxWidth = 600,
  this.margin = const EdgeInsets.all(15),
  this.padding = const EdgeInsets.all(15),
  this.snackPosition = SnackPosition.TOP,
});