NeuContainer constructor
const
NeuContainer({
- Key? key,
- Color color = lightWhite,
- int depth = defaultDepth,
- EdgeInsetsGeometry insets = EdgeInsets.zero,
- Curvature curvature = Curvature.convex,
- Swell swell = Swell.emboss,
- double spread = defaultSpread,
- Alignment lightSource = defaultLightSource,
- AlignmentGeometry? alignment,
- double? width,
- double? height,
- EdgeInsetsGeometry? margin,
- EdgeInsetsGeometry? padding,
- BoxConstraints? constraints,
- ShapeBorder shape = defaultShape,
- Decoration? foregroundDecoration,
- Matrix4? transform,
- AlignmentGeometry? transformAlignment,
- Duration duration = defaultDuration,
- Curve curve = Curves.elasticOut,
- VoidCallback? onEnd,
- Widget? child,
A specialized StatelessWidget that builds two layered AnimatedContainers, one as a solid color backdrop with edge insets and the second conforming to the Neu-standard properties, such as depth and curvature, to give the inner container a neumorphic or "clay"-like appearance rising out of the lower container.
SEE ALSO:
- Neu, the base class defining this design system.
- AnimatedContainer, which this
Widget
will render and from which many if its parameters are copied. - NeuToggle for a widget like this container but that handles its own GestureDetector for the purpose of "toggling" between two Neumorphic states.
Implementation
const NeuContainer({
Key? key,
this.color = lightWhite,
this.depth = defaultDepth,
this.insets = EdgeInsets.zero,
this.curvature = Curvature.convex,
this.swell = Swell.emboss,
this.spread = defaultSpread,
this.lightSource = defaultLightSource,
/// Container
this.alignment,
this.width,
this.height,
this.margin,
this.padding,
this.constraints,
this.shape = defaultShape,
this.foregroundDecoration,
this.transform,
this.transformAlignment,
this.duration = defaultDuration,
this.curve = Curves.elasticOut,
this.onEnd,
this.child,
}) : super(key: key);