toWidget method

  1. @override
Widget toWidget(
  1. BuildContext context
)
override

Return the associated Widget

Implementation

@override
Widget toWidget(BuildContext context) => Chip(
      key: id == null ? null : Key(id!),
      elevation: elevation,
      backgroundColor: toColor(backgroundColor) ?? Colors.red,
      shadowColor: toColor(shadowColor),
      label: caption != null
          ? Text(caption!,
              style: TextStyle(
                  color: toColor(color) ?? Colors.white, fontSize: fontSize))
          : const Text(''),
      padding: padding == null ? null : EdgeInsets.all(padding!),
    );