Wondering if you would accept a PR to alter the code below for Day to accept a prop to select a specific date vs defaulting to the first day of the month (tabIndex 0).
let tabIndex = -1;
// Focus on the first day of the month
if (this.props.onDayClick && !isOutside && day.getDate() === 1
// default to 1 but allow a prop to override
) {
tabIndex = this.props.tabIndex; // eslint-disable-line prefer-destructuring
}
In most cases the first day makes sense but, I have a use case where a month can have many disabled days. Users navigating with a screen reader end up navigating a lot of disabled days before finding an enabled date. In which case I would like to be able to set the first enabled day to tabIndex 0.
Wondering if you would accept a PR to alter the code below for Day to accept a prop to select a specific date vs defaulting to the first day of the month (tabIndex 0).
In most cases the first day makes sense but, I have a use case where a month can have many disabled days. Users navigating with a screen reader end up navigating a lot of disabled days before finding an enabled date. In which case I would like to be able to set the first enabled day to tabIndex 0.