ExtWidget extension
- on
Methods
-
align(
Alignment alignment) → Widget -
Available on Widget, provided by the ExtWidget extension
Aligns this widget with the givenalignment. -
aspectRatio(
double ratio) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in an AspectRatio with the givenratio. -
blurred(
double sigmaX, double sigmaY, [Duration duration = const Duration(milliseconds: 300)]) → Widget -
Available on Widget, provided by the ExtWidget extension
Applies a blur effect to this widget with the givensigmaXandsigmaY. -
card(
{Color? color, Color? shadowColor, Color? surfaceTintColor, double? elevation, ShapeBorder? shape, bool borderOnForeground = true, EdgeInsetsGeometry? margin, Clip? clipBehavior, bool semanticContainer = true}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a Card. -
center(
) → Widget - Centers this widget.
-
clipped(
[BorderRadius? borderRadius]) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a ClipRRect with the givenborderRadius. IfborderRadiusis not provided, a circular radius of 8.0 is used. Example: -
container(
{Color? color, DecorationImage? image, BoxBorder? border, BorderRadiusGeometry? borderRadius, List< BoxShadow> ? boxShadow, Gradient? gradient, BlendMode? backgroundBlendMode, BoxShape shape = BoxShape.rectangle, EdgeInsetsGeometry? padding, EdgeInsetsGeometry? margin, double? width, double? height, BoxConstraints? constraints, AlignmentGeometry? alignment, Clip clipBehavior = Clip.none}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a Container with the given decoration parameters. -
expanded(
{int flex = 1}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget with Expanded with optionalflex. -
expandedIf(
bool condition, {int flex = 1}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget with Expanded ifconditionistrue, otherwise returns this widget. -
faded(
double opacity, [Duration duration = const Duration(milliseconds: 300)]) → Widget -
Available on Widget, provided by the ExtWidget extension
Fades this widget to the givenopacity. Animate if opacity changes. -
fadedIn(
[Duration duration = const Duration(milliseconds: 300)]) → Widget -
Available on Widget, provided by the ExtWidget extension
Fades this widget in with the givenduration. -
fadedOut(
[Duration duration = const Duration(milliseconds: 300)]) → Widget -
Available on Widget, provided by the ExtWidget extension
Fades this widget out with the givenduration. -
flexible(
{int flex = 1, FlexFit fit = FlexFit.loose}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget with Flexible with optionalflexandfit. -
hero(
Object tag, {CreateRectTween? createRectTween, HeroFlightShuttleBuilder? flightShuttleBuilder, HeroPlaceholderBuilder? placeholderBuilder, bool transitionOnUserGestures = false}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a Hero with the giventag. -
offstage(
bool isOffstage) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget with Offstage based onisOffstage. -
onLongPress(
[VoidCallback? callback]) → Widget -
Available on Widget, provided by the ExtWidget extension
Adds an onLongPress gesture using InkWell over a transparent Material. -
onTap(
[VoidCallback? callback]) → Widget -
Available on Widget, provided by the ExtWidget extension
Adds an onTap gesture using InkWell over a transparent Material. -
positioned(
{double? left, double? top, double? right, double? bottom}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a Positioned with the given parameters. -
positionedFill(
{double? left, double? top, double? right, double? bottom}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a Positioned.fill with the given parameters. -
rotated(
double degree, [Duration duration = const Duration(milliseconds: 300)]) → Widget -
Available on Widget, provided by the ExtWidget extension
Rotates this widget bydegreedegrees. Animate if degree changes. -
safe(
) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a SafeArea. -
scaled(
double scale, [Duration duration = const Duration(milliseconds: 300)]) → Widget -
Available on Widget, provided by the ExtWidget extension
Scales this widget byscale. Animate if scale changes. -
scrollable(
{Axis scrollDirection = Axis.vertical, bool reverse = false, EdgeInsetsGeometry? padding, bool? primary, ScrollPhysics? physics, ScrollController? controller, DragStartBehavior dragStartBehavior = DragStartBehavior.start, Clip clipBehavior = Clip.hardEdge, String? restorationId, ScrollViewKeyboardDismissBehavior keyboardDismissBehavior = ScrollViewKeyboardDismissBehavior.manual}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a SingleChildScrollView. -
shimmer(
{bool isLoading = true, Color baseColor = const Color(0xFFE0E0E0), Color highlightColor = const Color(0xFFF5F5F5), Duration duration = const Duration(milliseconds: 1500)}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a shimmer loading effect whenisLoadingis true. -
sized(
{double? width, double? height}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a SizedBox with the givenwidthand/orheight. -
sizedSquare(
double size) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a square SizedBox with both width and height set tosize. -
sliver(
) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a SliverToBoxAdapter, useful for slivers in CustomScrollView. -
tooltip(
String message, {Decoration? decoration, BoxConstraints? constraints, EdgeInsetsGeometry? padding, TextStyle? textStyle, Duration? waitDuration, Duration? showDuration}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a Tooltip. -
translated(
double x, double y, [Duration duration = const Duration(milliseconds: 300)]) → Widget -
Available on Widget, provided by the ExtWidget extension
Translates this widget byoffset. Animate if offset changes. -
unfocusOnTap(
) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a GestureDetector that unfocuses the current keyboard/focus on tap. -
visibility(
bool isVisible) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget with Visibility based onisVisible. -
visibilityAnimated(
bool isVisible, [Duration duration = const Duration(milliseconds: 300)]) → Widget -
Available on Widget, provided by the ExtWidget extension
Animates the visibility of this widget based onisVisible. -
withPadding(
{double? all, double? horizontal, double? vertical, double? top, double? bottom, double? left, double? right}) → Widget -
Available on Widget, provided by the ExtWidget extension
Wraps this widget in a Padding with the given values. Ifallis provided, it overrides other parameters. Example: