Universal constructor
const
Universal({
- Key? key,
- bool addCard = false,
- bool addInkWell = false,
- bool isScroll = false,
- bool useSingleChildScrollView = true,
- bool isStack = false,
- bool isWrap = false,
- bool expanded = false,
- bool expand = false,
- bool shrink = false,
- bool intrinsicHeight = false,
- bool intrinsicWidth = false,
- bool isOval = false,
- bool isClipRRect = false,
- bool isClipRect = false,
- bool visible = true,
- bool offstage = false,
- bool enabled = false,
- bool reverse = false,
- bool autoFocus = false,
- bool maintainState = false,
- bool transitionOnUserGestures = false,
- bool isCircleAvatar = false,
- bool maintainAnimation = false,
- bool maintainSize = false,
- bool maintainSemantics = false,
- bool maintainInteractivity = false,
- bool excludeFromSemantics = false,
- bool? enableFeedback = true,
- bool canRequestFocus = true,
- bool noScrollBehavior = true,
- bool sized = true,
- bool gaussian = false,
- bool safeLeft = false,
- bool safeTop = false,
- bool safeRight = false,
- bool safeBottom = false,
- double fuzzyDegree = 4,
- double wrapSpacing = 0.0,
- double runSpacing = 0.0,
- DragStartBehavior dragStartBehavior = DragStartBehavior.start,
- Color? shadowColor = Colors.transparent,
- Widget replacement = const SizedBox.shrink(),
- StackFit stackFit = StackFit.loose,
- MainAxisSize mainAxisSize = MainAxisSize.max,
- MainAxisAlignment mainAxisAlignment = MainAxisAlignment.start,
- CrossAxisAlignment crossAxisAlignment = CrossAxisAlignment.center,
- WrapAlignment wrapAlignment = WrapAlignment.start,
- WrapAlignment runAlignment = WrapAlignment.start,
- WrapCrossAlignment wrapCrossAlignment = WrapCrossAlignment.start,
- VerticalDirection verticalDirection = VerticalDirection.down,
- Axis direction = Axis.vertical,
- Axis? scrollDirection,
- HitTestBehavior behavior = HitTestBehavior.opaque,
- BorderRadius? borderRadius,
- Color? color,
- AlignmentGeometry? alignment,
- Widget? child,
- List<
Widget> ? children, - EdgeInsetsGeometry? padding,
- ScrollPhysics? physics,
- ScrollController? scrollController,
- bool? primary,
- Decoration? foregroundDecoration,
- Matrix4? transform,
- Offset? origin,
- BoxConstraints? constraints,
- double? width,
- double? height,
- EdgeInsetsGeometry? margin,
- Decoration? decoration,
- TextBaseline? textBaseline,
- TextDirection? textDirection,
- GestureTapCallback? onTap,
- GestureTapDownCallback? onTapDown,
- GestureTapUpCallback? onTapUp,
- GestureTapCancelCallback? onTapCancel,
- GestureTapDownCallback? onSecondaryTapDown,
- GestureTapUpCallback? onSecondaryTapUp,
- GestureTapCancelCallback? onSecondaryTapCancel,
- GestureTapCallback? onDoubleTap,
- GestureLongPressCallback? onLongPress,
- GestureLongPressStartCallback? onLongPressStart,
- GestureLongPressMoveUpdateCallback? onLongPressMoveUpdate,
- GestureLongPressUpCallback? onLongPressUp,
- GestureLongPressEndCallback? onLongPressEnd,
- GestureDragDownCallback? onVerticalDragDown,
- GestureDragStartCallback? onVerticalDragStart,
- GestureDragUpdateCallback? onVerticalDragUpdate,
- GestureDragEndCallback? onVerticalDragEnd,
- GestureDragCancelCallback? onVerticalDragCancel,
- GestureDragDownCallback? onHorizontalDragDown,
- GestureDragStartCallback? onHorizontalDragStart,
- GestureDragUpdateCallback? onHorizontalDragUpdate,
- GestureDragEndCallback? onHorizontalDragEnd,
- GestureDragCancelCallback? onHorizontalDragCancel,
- GestureDragDownCallback? onPanDown,
- GestureDragStartCallback? onPanStart,
- GestureDragUpdateCallback? onPanUpdate,
- GestureDragEndCallback? onPanEnd,
- GestureDragCancelCallback? onPanCancel,
- GestureScaleStartCallback? onScaleStart,
- GestureScaleUpdateCallback? onScaleUpdate,
- GestureScaleEndCallback? onScaleEnd,
- GestureForcePressStartCallback? onForcePressStart,
- GestureForcePressPeakCallback? onForcePressPeak,
- GestureForcePressUpdateCallback? onForcePressUpdate,
- GestureForcePressEndCallback? onForcePressEnd,
- ShapeBorder? shape,
- ValueChanged<
bool> ? onHighlightChanged, - ValueChanged<
bool> ? onHover, - Color? focusColor,
- Color? hoverColor,
- Color? highlightColor,
- Color? splashColor,
- InteractiveInkFeatureFactory? splashFactory,
- double? radius,
- ShapeBorder? customBorder,
- FocusNode? focusNode,
- ValueChanged<
bool> ? onFocusChange, - String? heroTag,
- CreateRectTween? createRectTween,
- HeroFlightShuttleBuilder? flightShuttleBuilder,
- HeroPlaceholderBuilder? placeholderBuilder,
- ImageProvider<
Object> ? backgroundImage, - ImageErrorListener? onBackgroundImageError,
- Color? foregroundColor,
- double? minRadius,
- double? maxRadius,
- CustomClipper? clipper,
- Size? size,
- GestureTapCallback? onSecondaryTap,
- GestureLongPressMoveUpdateCallback? onSecondaryLongPressMoveUpdate,
- GestureLongPressCallback? onSecondaryLongPressUp,
- GestureLongPressCallback? onSecondaryLongPress,
- GestureLongPressEndCallback? onSecondaryLongPressEnd,
- GestureLongPressStartCallback? onSecondaryLongPressStart,
- double? left,
- double? top,
- double? right,
- double? bottom,
- int? flex,
- double? elevation,
- double? opacity,
- Clip? clipBehavior,
- RefreshConfig? refreshConfig,
- double? widthFactor,
- double? heightFactor,
- ImageFilter? filter,
- dynamic builder,
- BoxFit? fit,
- SystemUiOverlayStyle? systemOverlayStyle,
Implementation
const Universal({
super.key,
this.addCard = false,
this.addInkWell = false,
this.isScroll = false,
this.useSingleChildScrollView = true,
this.isStack = false,
this.isWrap = false,
this.expanded = false,
this.expand = false,
this.shrink = false,
this.intrinsicHeight = false,
this.intrinsicWidth = false,
this.isOval = false,
this.isClipRRect = false,
this.isClipRect = false,
this.visible = true,
this.offstage = false,
this.enabled = false,
this.reverse = false,
this.autoFocus = false,
this.maintainState = false,
this.transitionOnUserGestures = false,
this.isCircleAvatar = false,
this.maintainAnimation = false,
this.maintainSize = false,
this.maintainSemantics = false,
this.maintainInteractivity = false,
this.excludeFromSemantics = false,
this.enableFeedback = true,
this.canRequestFocus = true,
this.noScrollBehavior = true,
this.sized = true,
this.gaussian = false,
this.safeLeft = false,
this.safeTop = false,
this.safeRight = false,
this.safeBottom = false,
this.fuzzyDegree = 4,
this.wrapSpacing = 0.0,
this.runSpacing = 0.0,
this.dragStartBehavior = DragStartBehavior.start,
this.shadowColor = Colors.transparent,
this.replacement = const SizedBox.shrink(),
this.stackFit = StackFit.loose,
this.mainAxisSize = MainAxisSize.max,
this.mainAxisAlignment = MainAxisAlignment.start,
this.crossAxisAlignment = CrossAxisAlignment.center,
this.wrapAlignment = WrapAlignment.start,
this.runAlignment = WrapAlignment.start,
this.wrapCrossAlignment = WrapCrossAlignment.start,
this.verticalDirection = VerticalDirection.down,
this.direction = Axis.vertical,
this.scrollDirection,
this.behavior = HitTestBehavior.opaque,
this.borderRadius,
this.color,
this.alignment,
this.child,
this.children,
this.padding,
this.physics,
this.scrollController,
this.primary,
this.foregroundDecoration,
this.transform,
this.origin,
this.constraints,
this.width,
this.height,
this.margin,
this.decoration,
this.textBaseline,
this.textDirection,
this.onTap,
this.onTapDown,
this.onTapUp,
this.onTapCancel,
this.onSecondaryTapDown,
this.onSecondaryTapUp,
this.onSecondaryTapCancel,
this.onDoubleTap,
this.onLongPress,
this.onLongPressStart,
this.onLongPressMoveUpdate,
this.onLongPressUp,
this.onLongPressEnd,
this.onVerticalDragDown,
this.onVerticalDragStart,
this.onVerticalDragUpdate,
this.onVerticalDragEnd,
this.onVerticalDragCancel,
this.onHorizontalDragDown,
this.onHorizontalDragStart,
this.onHorizontalDragUpdate,
this.onHorizontalDragEnd,
this.onHorizontalDragCancel,
this.onPanDown,
this.onPanStart,
this.onPanUpdate,
this.onPanEnd,
this.onPanCancel,
this.onScaleStart,
this.onScaleUpdate,
this.onScaleEnd,
this.onForcePressStart,
this.onForcePressPeak,
this.onForcePressUpdate,
this.onForcePressEnd,
this.shape,
this.onHighlightChanged,
this.onHover,
this.focusColor,
this.hoverColor,
this.highlightColor,
this.splashColor,
this.splashFactory,
this.radius,
this.customBorder,
this.focusNode,
this.onFocusChange,
this.heroTag,
this.createRectTween,
this.flightShuttleBuilder,
this.placeholderBuilder,
this.backgroundImage,
this.onBackgroundImageError,
this.foregroundColor,
this.minRadius,
this.maxRadius,
this.clipper,
this.size,
this.onSecondaryTap,
this.onSecondaryLongPressMoveUpdate,
this.onSecondaryLongPressUp,
this.onSecondaryLongPress,
this.onSecondaryLongPressEnd,
this.onSecondaryLongPressStart,
this.left,
this.top,
this.right,
this.bottom,
this.flex,
this.elevation,
this.opacity,
this.clipBehavior,
this.refreshConfig,
this.widthFactor,
this.heightFactor,
this.filter,
this.builder,
this.fit,
this.systemOverlayStyle,
}) : assert(!(addCard && addInkWell), 'One of them must be true');