Toast constructor

const Toast({
  1. Key? key,
  2. String label = 'Feedback Text',
  3. ToastStatus status = ToastStatus.neutral,
  4. bool hasIcon = true,
  5. IconData icon = Icons.error_outline,
  6. double? width = 320.0,
})

Creates a Toast alert instance.

Implementation

const Toast({
  super.key,
  this.label = 'Feedback Text',
  this.status = ToastStatus.neutral,
  this.hasIcon = true,
  this.icon = Icons.error_outline,
  this.width = 320.0,
});