ColorCodeField constructor

const ColorCodeField({
  1. Key? key,
  2. required Color color,
  3. bool readOnly = false,
  4. required ValueChanged<Color> onColorChanged,
  5. required ValueChanged<bool> onEditFocused,
  6. TextStyle? textStyle,
  7. TextStyle? prefixStyle,
  8. bool colorCodeHasColor = false,
  9. ColorPickerActionButtons toolIcons = const ColorPickerActionButtons(),
  10. ColorPickerCopyPasteBehavior copyPasteBehavior = const ColorPickerCopyPasteBehavior(),
  11. bool enableTooltips = true,
  12. bool shouldUpdate = false,
})

Default const constructor.

Implementation

const ColorCodeField({
  super.key,
  required this.color,
  this.readOnly = false,
  required this.onColorChanged,
  required this.onEditFocused,
  this.textStyle,
  this.prefixStyle,
  this.colorCodeHasColor = false,
  this.toolIcons = const ColorPickerActionButtons(),
  this.copyPasteBehavior = const ColorPickerCopyPasteBehavior(),
  this.enableTooltips = true,
  this.shouldUpdate = false,
});