ZZ constructor
const
ZZ({
- required Widget child,
- void onTap()?,
- EdgeInsets? margin,
- EdgeInsets? padding,
- Decoration? decoration,
- double? height,
- double? width,
- int? flex,
- bool? canScroll,
- Key? key,
Creates the desired Widget hierarchy based on the provided arguments.
Widgets are created in the following order
- Padding (margin)
- DecoratedBox
- Padding (padding)
- GestureDetector
- SingleChildScrollView
- Expanded / SizedBox
Understanding the order is helpful in understanding the outcome when multiple properties are defined.
Implementation
const ZZ(
{required this.child,
this.onTap,
this.margin,
this.padding,
this.decoration,
this.height,
this.width,
this.flex,
this.canScroll,
Key? key})
: super(key: key);