BubbleBox constructor

BubbleBox({
  1. required Widget child,
  2. Key? key,
  3. double pointerBias = 0.5,
  4. double opacity = 0.5,
  5. double strokeWidth = 1.2,
  6. Color color = Colors.black,
  7. Color strokeColor = Colors.white,
  8. double borderRadius = 8,
  9. double peakRadius = 3,
  10. double pointerWidth = 10,
  11. double pointerHeight = 6,
  12. double startPadding = 0,
  13. double endPadding = 0,
  14. bool isUpward = true,
  15. bool isWrapped = true,
  16. ImageFilter? filter,
  17. BlendMode blendMode = BlendMode.srcOver,
})

Implementation

BubbleBox({
  required Widget child,
  Key? key,
  this.pointerBias = 0.5,
  this.opacity = 0.5,
  this.strokeWidth = 1.2,
  this.color = Colors.black,
  this.strokeColor = Colors.white,
  this.borderRadius = 8,
  this.peakRadius = 3,
  this.pointerWidth = 10,
  this.pointerHeight = 6,
  this.startPadding = 0,
  this.endPadding = 0,
  this.isUpward = true,
  this.isWrapped = true,
  this.filter,
  this.blendMode = BlendMode.srcOver,
}) : super(
        key: key,
        child: Padding(
          padding: isWrapped
              ? EdgeInsets.only(
                      top: isUpward ? pointerHeight : 0,
                      bottom: isUpward ? 0 : pointerHeight) +
                  EdgeInsets.all(borderRadius)
              : EdgeInsets.zero,
          child: child,
        ),
      );