-
Notifications
You must be signed in to change notification settings - Fork 87
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ffe-datepicker-react: pressing Enter while focusing the input field with a valid date should close the calendar #14
Labels
💎 enhancement
Suggested improvements to the design system
Comments
henrikhermansen
pushed a commit
that referenced
this issue
Feb 28, 2018
This commit makes a simple improvement to keyboard navigation of the datepicker by allowing the calendar to be closed by pressing Enter while the date input field has focus. This solution is slightly different from the suggested solution. While the suggestions solution said the calendar would only close if the date is valid, this solution closes the calendar regardless and triggers validation. This allows us to show an error message to the user, rather than keeping them stuck in the calendar. This commit also removes the `onKeyPress` listener from Input. The reason for doing so is that the dual key listeners conflicted with the initial changes of this commit. I did extensive testing to assure this is a safe change to make. I am also reassured by the fact that we don't use this listener anywhere else in our code, while we use the `onKeyDown` listener extensively. This fixes #14
henrikhermansen
pushed a commit
that referenced
this issue
Feb 28, 2018
This commit makes a simple improvement to keyboard navigation of the datepicker by allowing the calendar to be closed by pressing Enter while the date input field has focus. This solution is slightly different from the suggested solution. While the suggestions solution said the calendar would only close if the date is valid, this solution closes the calendar regardless and triggers validation. This allows us to show an error message to the user, rather than keeping them stuck in the calendar. This commit also removes the `onKeyPress` listener from Input. The reason for doing so is that the dual key listeners conflicted with the initial changes of this commit. I did extensive testing to assure this is a safe change to make. I am also reassured by the fact that we don't use this listener anywhere else in our code, while we use the `onKeyDown` listener extensively. This fixes #14
henrikhermansen
pushed a commit
that referenced
this issue
Feb 28, 2018
This commit makes a simple improvement to keyboard navigation of the datepicker by allowing the calendar to be closed by pressing Enter while the date input field has focus. This solution is slightly different from the suggested solution. While the suggestions solution said the calendar would only close if the date is valid, this solution closes the calendar regardless and triggers validation. This allows us to show an error message to the user, rather than keeping them stuck in the calendar. This commit also removes the `onKeyPress` listener from Input. The reason for doing so is that the dual key listeners conflicted with the initial changes of this commit. I did extensive testing to assure this is a safe change to make. I am also reassured by the fact that we don't use this listener anywhere else in our code, while we use the `onKeyDown` listener extensively. This fixes #14
kwltrs
pushed a commit
that referenced
this issue
Mar 7, 2018
This commit makes a simple improvement to keyboard navigation of the datepicker by allowing the calendar to be closed by pressing Enter while the date input field has focus. This solution is slightly different from the suggested solution. While the suggestions solution said the calendar would only close if the date is valid, this solution closes the calendar regardless and triggers validation. This allows us to show an error message to the user, rather than keeping them stuck in the calendar. This commit also removes the `onKeyPress` listener from Input. The reason for doing so is that the dual key listeners conflicted with the initial changes of this commit. I did extensive testing to assure this is a safe change to make. I am also reassured by the fact that we don't use this listener anywhere else in our code, while we use the `onKeyDown` listener extensively. This fixes #14
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If I edit a date in the input field with my keyboard and hit Enter I expect the calendar to close so I can tab to the next input field, given the date is valid.
The text was updated successfully, but these errors were encountered: