Skip to content

Commit 5963a13

Browse files
committed
Set TextField's readOnly prop to false in DateRangePicker - prevents keyboard popup
1 parent 6585986 commit 5963a13

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/src/fields/form_builder_date_range_picker.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ class FormBuilderDateRangePickerState
221221
textDirection: widget.textDirection,
222222
textInputAction: widget.textInputAction,
223223
strutStyle: widget.strutStyle,
224-
readOnly: _readOnly,
224+
readOnly: true,
225225
expands: widget.expands,
226226
minLines: widget.minLines,
227227
showCursor: widget.showCursor,

lib/src/fields/form_builder_date_time_picker.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@ class _FormBuilderDateTimePickerState extends State<FormBuilderDateTimePicker> {
292292
autofocus: widget.autofocus,
293293
decoration: widget.decoration,
294294
readOnly: true,
295-
enabled: _readOnly ? false : widget.enabled,
295+
enabled: !_readOnly,
296296
autocorrect: widget.autocorrect,
297297
controller: _textFieldController,
298298
focusNode: _focusNode,

0 commit comments

Comments
 (0)