From 0a3239086c5e98eecaa0c7ddaff3435ee114782f Mon Sep 17 00:00:00 2001 From: CuongNV Date: Mon, 29 Jan 2024 16:24:11 +0700 Subject: [PATCH] expose shadowOffset --- lib/src/super_tooltip.dart | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/src/super_tooltip.dart b/lib/src/super_tooltip.dart index 69d3017..106decf 100644 --- a/lib/src/super_tooltip.dart +++ b/lib/src/super_tooltip.dart @@ -22,6 +22,7 @@ class SuperTooltip extends StatefulWidget { final Color? shadowColor; final double? shadowBlurRadius; final double? shadowSpreadRadius; + final Offset? shadowOffset; final double? top, right, bottom, left; final ShowCloseButton? showCloseButton; final Color? closeButtonColor; @@ -74,6 +75,7 @@ class SuperTooltip extends StatefulWidget { this.shadowColor, this.shadowBlurRadius, this.shadowSpreadRadius, + this.shadowOffset, this.top, this.right, this.bottom, @@ -146,6 +148,7 @@ class _SuperTooltipState extends State late Color shadowColor; late double shadowBlurRadius; late double shadowSpreadRadius; + late Offset shadowOffset; late bool showBlur; @override @@ -192,6 +195,7 @@ class _SuperTooltipState extends State shadowColor = widget.shadowColor ?? Colors.black54; shadowBlurRadius = widget.shadowBlurRadius ?? 10.0; shadowSpreadRadius = widget.shadowSpreadRadius ?? 5.0; + shadowOffset = widget.shadowOffset ?? Offset.zero; showBlur = widget.showDropBoxFilter; return CompositedTransformTarget( @@ -380,6 +384,7 @@ class _SuperTooltipState extends State blurRadius: shadowBlurRadius, spreadRadius: shadowSpreadRadius, color: shadowColor, + offset: shadowOffset, ), ] : null,