CardTheme constructor
- Key? key,
- Clip? clipBehavior,
- Color? color,
- Color? surfaceTintColor,
- Color? shadowColor,
- double? elevation,
- EdgeInsetsGeometry? margin,
- ShapeBorder? shape,
- CardThemeData? data,
- Widget? child,
Creates a theme that can be used for ThemeData.cardTheme.
The elevation
must be null or non-negative.
Implementation
const CardTheme({
super.key,
Clip? clipBehavior,
Color? color,
Color? surfaceTintColor,
Color? shadowColor,
double? elevation,
EdgeInsetsGeometry? margin,
ShapeBorder? shape,
CardThemeData? data,
Widget? child,
}) : assert(
data == null ||
(clipBehavior ??
color ??
surfaceTintColor ??
shadowColor ??
elevation ??
margin ??
shape) == null),
assert(elevation == null || elevation >= 0.0),
_data = data,
_clipBehavior = clipBehavior,
_color = color,
_surfaceTintColor = surfaceTintColor,
_shadowColor = shadowColor,
_elevation = elevation,
_margin = margin,
_shape = shape,
super(child: child ?? const SizedBox());