OudsCardItem.labelContent constructor
- Key? key,
- required Widget labelContent(
- BuildContext context,
- OudsListItemControlState state
- OudsListItemContentAlignment contentAlignment = OudsCardItemDefaults.contentAlignment,
- OudsListItemDecoration decoration = OudsCardItemDefaults.decoration,
- String? overline,
- String? extraLabel,
- String? description,
- Widget belowTextContent(
- BuildContext context,
- OudsListItemControlState state
- OudsListItemLeading? leading,
- OudsListItemTrailing? trailing,
- Widget bottomContent(
- BuildContext context,
- OudsListItemControlState state
- String? helperText,
- bool boldLabel = false,
- bool enable = true,
- VoidCallback? onTap,
- OudsListItemIndicator indicator = OudsCardItemDefaults.indicator,
- OudsSkeleton? skeleton,
Creates an OUDS card item with fully custom labelContent instead of a
plain text label.
Implementation
const OudsCardItem.labelContent({
super.key,
required Widget Function(
BuildContext context,
OudsListItemControlState state,
)
labelContent,
this.contentAlignment = OudsCardItemDefaults.contentAlignment,
this.decoration = OudsCardItemDefaults.decoration,
this.overline,
this.extraLabel,
this.description,
this.belowTextContent,
this.leading,
this.trailing,
this.bottomContent,
this.helperText,
this.boldLabel = false,
this.enable = true,
this.onTap,
this.indicator = OudsCardItemDefaults.indicator,
this.skeleton,
}) : label = null,
// Field is nullable for the default constructor; the parameter stays
// non-nullable so that `labelContent: null` is a compile-time error.
// ignore: prefer_initializing_formals
labelContent = labelContent;