Skip to content

Commit e439e24

Browse files
Merge pull request #1094 from flutter-form-builder-ecosystem/248
Deprecate reset icon from FormBuilderDateTimePicker
2 parents f54da3a + 22f02ac commit e439e24

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

lib/src/fields/form_builder_date_time_picker.dart

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,8 @@ class FormBuilderDateTimePicker extends FormBuilderField<DateTime> {
4040
/// to noon. Explicitly set this to `null` to use the current time.
4141
final TimeOfDay initialTime;
4242

43-
/// If defined, the TextField [decoration]'s [suffixIcon] will be
44-
/// overridden to reset the input using the icon defined here.
45-
/// Set this to `null` to stop that behavior. Defaults to [Icons.close].
43+
@Deprecated(
44+
'This property is no used anymore. Please use decoration.suffixIcon to set your desired icon')
4645
final Widget? resetIcon;
4746

4847
/// Called when an enclosing form is saved. The value passed will be `null`
@@ -213,7 +212,7 @@ class FormBuilderDateTimePicker extends FormBuilderField<DateTime> {
213212
textAlign: textAlign,
214213
maxLength: maxLength,
215214
autofocus: autofocus,
216-
decoration: state.decoration.copyWith(suffixIcon: resetIcon),
215+
decoration: state.decoration,
217216
readOnly: true,
218217
enabled: state.enabled,
219218
autocorrect: autocorrect,

0 commit comments

Comments
 (0)