Allow customizing tabindex for <cr-button>
This adds a Polymer property to the <cr-button> element that allows the host to specify the custom value of the "tabindex" attribute. Before this CL, the <cr-button> element was handling this attribute itself: it was forcing it to "-1" when the button is disabled and to "0" when the button is re-enabled. Also a few already existing examples in the code base are configuring the "tabindex" directly at the <cr-button> element, but it's fragile (and buggy in some cases), because this value gets overwritten as soon as the "disabled" property gets changed. After this CL, the more robust alternative appears: <cr-button custom-tab-index=...> Bug: 1043194 Test: add element '<cr-button custom-tab-index="-1">' to a Polymer page, verify that it's not tabbable Change-Id: Id5e79737f2bc9ac049ea1f2372ec160aac36d9c0 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2069144 Commit-Queue: Maksim Ivanov <emaxx@chromium.org> Reviewed-by:Steven Bennetts <stevenjb@chromium.org> Cr-Commit-Position: refs/heads/master@{#744278}
Showing
Please register or sign in to comment