CustomChip constructor
const
CustomChip({})
Creates a CustomChip with the required label and optional parameters
If onDeleted is provided, a delete icon will be shown.
The backgroundColor and labelColor can be used to override default colors.
If avatar is provided, it will be displayed as an icon at the start of the chip.
Example with avatar:
CustomChip(
label: 'JavaScript',
avatar: Icons.code,
backgroundColor: Colors.amber[100],
labelColor: Colors.amber[900],
onDeleted: () => removeLanguage('JavaScript'),
)
Implementation
const CustomChip({
super.key,
required this.label,
this.onDeleted,
this.backgroundColor,
this.labelColor,
this.avatar,
});