Tag constructor

Tag({
  1. Key? key,
  2. String type = "default",
  3. String size = "default",
  4. String text = "",
  5. bool plain = false,
  6. bool round = false,
  7. bool mark = false,
  8. Color? color,
  9. Color? textColor,
  10. dynamic onClose()?,
})

Implementation

Tag({
  Key? key,
  this.type: "default",
  this.size: "default",
  this.text: "",
  this.plain: false,
  this.round: false,
  this.mark: false,
  this.color,
  this.textColor,
  this.onClose,
})  : assert(["default", "medium", "large"].indexOf(size) > -1,
          "size must be default, medium, or large"),
      assert(
          ["default", "primary", "success", "danger", "warning"]
                  .indexOf(type) >
              -1,
          "type must be default, primary, success, danger or warning"),
      super(key: key);