Skip to content

tabindex on MatDatepickerToggle #12456

@mattmcardle

Description

@mattmcardle

Bug, feature request, or proposal:

Feature Request

What is the expected behavior?

When specifying a tabindex of -1 on the datepicker toggle, and focus is on the datepickers associated input element,when tab is pressed the focus should skip the datepicker toggle and focus on the next focusable element. (As per https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/tabindex)

What is the current behavior?

When specifying a tabindex of -1 on the datepicker toggle, and focus is on the datepickers associated input element, when tab is pressed the focus goes to the datepicker toggle, ignoring the tabindex of -1.

What are the steps to reproduce?

https://stackblitz.com/edit/angular-material2-issue-xzdzcf

What is the use-case or motivation for changing an existing behavior?

Reducing keypresses required from user to move through the form

Which versions of Angular, Material, OS, TypeScript, browsers are affected?

Latest stable - tested in chrome.

Is there anything else we should know?

Metadata

Metadata

Assignees

Labels

P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgent

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions