Skip to content
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

fix(DatePicker): support focus into a day with min/max #4793

Merged

Conversation

asudoh
Copy link
Contributor

@asudoh asudoh commented Nov 28, 2019

This change allows user to focus a date into down-arrow key when min/max dates are enabled. When min/max dates are enabled, there can be no selected date in the calendar dropdown or calendar dropdown may not show today, so we need to look for another date to focus on. This change uses the first focusable date.

Fixes #4207.

Changelog

New

  • Code to focus on the first focusable date in calendar dropdown if calendar dropdown is not showing the selected date or today.

Testing / Reviewing

Testing should make sure React date picker is not broken.

This change allows user to focus a date into down-arrow key when
min/max dates are enabled. When min/max dates are enabled, there can be
no selected date in the calendar dropdown or calendar dropdown may not
show today, so we need to look for another date to focus on. This
change uses the first focusable date.

Fixes carbon-design-system#4207.
@asudoh asudoh requested review from emyarod, abbeyhrt and a team November 28, 2019 06:09
@asudoh asudoh requested a review from a team as a code owner November 28, 2019 06:09
@ghost ghost requested review from aagonzales and removed request for aagonzales and a team November 28, 2019 06:09
@netlify
Copy link

netlify bot commented Nov 28, 2019

Deploy preview for the-carbon-components ready!

Built with commit 079b0eb

https://deploy-preview-4793--the-carbon-components.netlify.com

@netlify
Copy link

netlify bot commented Nov 28, 2019

Deploy preview for carbon-components-react failed.

Built with commit 079b0eb

https://app.netlify.com/sites/carbon-components-react/deploys/5deeb1361d4c41000af6f6f8

@netlify
Copy link

netlify bot commented Nov 28, 2019

Deploy preview for carbon-elements ready!

Built with commit 079b0eb

https://deploy-preview-4793--carbon-elements.netlify.com

Copy link
Contributor

@abbeyhrt abbeyhrt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

@asudoh asudoh requested a review from a team December 2, 2019 21:52
@ghost ghost requested review from laurenmrice and removed request for a team December 2, 2019 21:52
Copy link
Member

@emyarod emyarod left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

 

@emyarod emyarod requested review from emyarod and removed request for emyarod December 3, 2019 09:16
@joshblack joshblack requested a review from dakahn December 5, 2019 19:48
@asudoh asudoh merged commit e90f5d4 into carbon-design-system:master Dec 9, 2019
@asudoh asudoh deleted the date-picker-foucs-day-minmax branch December 9, 2019 20:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Date Picker - Keyboard navigation issues
6 participants