Skip to content

Commit

Permalink
Merge pull request jupyter-widgets#3390 from jasongrout/inttext
Browse files Browse the repository at this point in the history
Backport jupyter-widgets#2975 to 7.x: fix return key submission of IntText widgets
  • Loading branch information
vidartf authored Feb 28, 2022
2 parents 421071e + 06ad08b commit 288ea22
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/controls/src/widget_int.ts
Original file line number Diff line number Diff line change
Expand Up @@ -567,7 +567,7 @@ class IntTextView extends DescriptionView {
* Handles key press
*/
handleKeypress(e: KeyboardEvent) {
if (/[e,.\s]/.test(String.fromCharCode(e.keyCode))) {
if (/[e,. ]/.test(String.fromCharCode(e.keyCode))) {
e.preventDefault();
}
}
Expand Down

0 comments on commit 288ea22

Please sign in to comment.