IntSliderField constructor
IntSliderField({
- required String name,
- int? initialValue = 0,
- @Deprecated('Fields should not be aware of their context') void onChanged(
- BuildContext context,
- int? value
- required int min,
- required int max,
- int? divisions,
Implementation
IntSliderField({
required super.name,
super.initialValue = 0,
@Deprecated('Fields should not be aware of their context') super.onChanged,
required super.min,
required super.max,
this.divisions,
}) : super(
type: FieldType.intSlider,
codec: FieldCodec<int>(
toParam: (value) => value.toString(),
toValue: (param) => double.tryParse(param ?? '')?.round(),
),
);