Skip to content

Commit bae2cfc

Browse files
committed
Add preventDefault() to prompt.dart
1 parent b935945 commit bae2cfc

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

lib/dialogs/prompt.dart

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ Future<String> prompt([String message = "", String value = ""]) async {
5454
c.complete(null);
5555
promptDialog.closeDialog();
5656
} else if (e is KeyboardEvent && e.keyCode == KeyCode.ENTER) {
57+
e.preventDefault();
5758
c.complete(input.value);
5859
promptDialog.closeDialog();
5960
}

pubspec.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
name: dialog
2-
version: 0.4.0+2
2+
version: 0.4.1
33
description: Modern alert, confirm and prompt dialog implementation
44
author: Pavel Dvořák <[email protected]>
55
homepage: https://github.com/dvorapa/dialog-dart
6-
documentation: http://www.dartdocs.org/documentation/dialog/latest/index.html#dialog
6+
documentation:
77
environment:
88
sdk: ">=1.11.1 <2.0.0"
99
dependencies:

web/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<Meta Name="author" Content="Pavel Dvořák">
66
<Meta Name="description" Content="Modern alert, confirm and prompt dialog implementation">
77
<Meta Name="keywords" Content="dialog,dart,alert,confirm,prompt,package,dvorapa">
8-
<Meta Name="version" Content="0.4.0+2">
8+
<Meta Name="version" Content="0.4.1">
99
<Link Type="text/css" Rel="stylesheet" Href="style.css">
1010
<Title>Dialog.dart</Title>
1111
</Head>

0 commit comments

Comments
 (0)