From 9583f3b09a1957a6e3e2245f049a8fc731c3144c Mon Sep 17 00:00:00 2001 From: suragch Date: Thu, 25 Jul 2024 05:54:44 +0800 Subject: [PATCH] composable widgets of Shadow are private for now --- lib/src/drawing_and_graphics/shadow.dart | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/lib/src/drawing_and_graphics/shadow.dart b/lib/src/drawing_and_graphics/shadow.dart index 4105a19..b9d5eca 100644 --- a/lib/src/drawing_and_graphics/shadow.dart +++ b/lib/src/drawing_and_graphics/shadow.dart @@ -44,12 +44,12 @@ class Shadow extends StatelessWidget { children: [ Transform.translate( offset: Offset(x, y), - child: Blur( + child: _Blur( sigmaX: radius, sigmaY: radius, - Tint( + _Tint( color: color, - Desaturate( + _Desaturate( child, // The Desaturate widget removes all transparency from the // whatever color the child widget is so that the shadow @@ -69,10 +69,9 @@ class Shadow extends StatelessWidget { } /// A widget that applies a blur filter to its child widget. -class Blur extends StatelessWidget { - const Blur( +class _Blur extends StatelessWidget { + const _Blur( this.child, { - super.key, this.sigmaX = 5.0, this.sigmaY = 5.0, }); @@ -106,10 +105,9 @@ class Blur extends StatelessWidget { /// A widget that applies a color filter to its child widget. /// /// You must specify a color. -class Tint extends StatelessWidget { - const Tint( +class _Tint extends StatelessWidget { + const _Tint( this.child, { - super.key, required this.color, }); @@ -132,10 +130,9 @@ class Tint extends StatelessWidget { } /// A widget that removes the RGB saturation of its child widget. -class Desaturate extends StatelessWidget { - const Desaturate( +class _Desaturate extends StatelessWidget { + const _Desaturate( this.child, { - super.key, required this.retainAlpha, });