FormCast.chips constructor
FormCast.chips({
- required List options,
- Color? backgroundColor,
- Color? selectedColor,
- double headerSpacing = 5,
- OutlinedBorder shape = const RoundedRectangleBorder(borderRadius: BorderRadius.all(Radius.circular(8))),
- BorderSide unselectedSide = const BorderSide(color: Colors.grey, width: 1),
- BorderSide selectedSide = const BorderSide(color: Colors.grey, width: 1),
- TextStyle labelStyle = const TextStyle(fontWeight: FontWeight.bold, color: Colors.black),
- TextStyle unselectedTextStyle = const TextStyle(fontWeight: FontWeight.bold, color: Colors.black),
- TextStyle selectedTextStyle = const TextStyle(fontWeight: FontWeight.bold, color: Colors.white),
- EdgeInsets padding = const EdgeInsets.all(8.0),
- double runSpacing = 8.0,
- double spacing = 8.0,
- Color checkmarkColor = Colors.white,
Cast to a chips
Implementation
FormCast.chips({
required List<dynamic> options,
Color? backgroundColor,
Color? selectedColor,
double headerSpacing = 5,
double footerSpacing = 5,
OutlinedBorder shape = const RoundedRectangleBorder(
borderRadius: BorderRadius.all(Radius.circular(8))),
BorderSide unselectedSide = const BorderSide(color: Colors.grey, width: 1),
BorderSide selectedSide = const BorderSide(color: Colors.grey, width: 1),
TextStyle labelStyle =
const TextStyle(fontWeight: FontWeight.bold, color: Colors.black),
TextStyle unselectedTextStyle =
const TextStyle(fontWeight: FontWeight.bold, color: Colors.black),
TextStyle selectedTextStyle =
const TextStyle(fontWeight: FontWeight.bold, color: Colors.white),
EdgeInsets padding = const EdgeInsets.all(8.0),
double runSpacing = 8.0,
double spacing = 8.0,
Color checkmarkColor = Colors.white,
}) {
type = "chip";
metaData = {};
metaData['options'] = options;
metaData['backgroundColor'] = backgroundColor;
metaData['selectedColor'] = selectedColor;
metaData['headerSpacing'] = headerSpacing;
metaData['footerSpacing'] = footerSpacing;
metaData['shape'] = shape;
metaData['unselectedSide'] = unselectedSide;
metaData['selectedSide'] = selectedSide;
metaData['labelStyle'] = labelStyle;
metaData['unselectedTextStyle'] = unselectedTextStyle;
metaData['selectedTextStyle'] = selectedTextStyle;
metaData['padding'] = padding;
metaData['runSpacing'] = runSpacing;
metaData['spacing'] = spacing;
metaData['checkmarkColor'] = checkmarkColor;
}