Skip to content

Commit 6801cae

Browse files
committed
Fixed text field submitting when adding a tag
1 parent 8386699 commit 6801cae

File tree

3 files changed

+10
-0
lines changed

3 files changed

+10
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
- Increased height of editor toolbar
99
- Changed behaviour of list-button in editor toolbar
1010
- Fixed image sizing in preview
11+
- Fixed text field submitting when adding a tag
1112

1213
## 1.1.1
1314

lib/page/edit.dart

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -328,6 +328,9 @@ class _EditPageState extends State<EditPage> {
328328
content: TextField(
329329
controller: ctrl,
330330
autofocus: true,
331+
onSubmitted: (str) {
332+
Navigator.of(context).pop(str);
333+
},
331334
),
332335
actions: <Widget>[
333336
FlatButton(

lib/page/note_list.dart

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -667,6 +667,12 @@ class _NoteListPageState extends State<NoteListPage> {
667667
title: Text('Add Tag'),
668668
content: TextField(
669669
controller: ctrl,
670+
autofocus: true,
671+
onSubmitted: (str) {
672+
Navigator.of(
673+
context)
674+
.pop(str);
675+
},
670676
),
671677
actions: <Widget>[
672678
FlatButton(

0 commit comments

Comments
 (0)