Skip to content

Commit b91964a

Browse files
devversiontinayuangao
authored andcommitted
fix(checkbox): rename tabindex to tabIndex (#2953)
* Renames the checkbox `tabindex` input to the `tabIndex` input. This is consistent with other API's like for the slide-toggle and also with native inputs.
1 parent 902edd0 commit b91964a

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

src/lib/checkbox/checkbox.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
[checked]="checked"
88
[disabled]="disabled"
99
[name]="name"
10-
[tabIndex]="tabindex"
10+
[tabIndex]="tabIndex"
1111
[indeterminate]="indeterminate"
1212
[attr.aria-label]="ariaLabel"
1313
[attr.aria-labelledby]="ariaLabelledby"

src/lib/checkbox/checkbox.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -727,7 +727,7 @@ class MultipleCheckboxes { }
727727
@Component({
728728
template: `
729729
<md-checkbox
730-
[tabindex]="customTabIndex"
730+
[tabIndex]="customTabIndex"
731731
[disabled]="isDisabled"
732732
[disableRipple]="disableRipple">
733733
</md-checkbox>`,

src/lib/checkbox/checkbox.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -139,8 +139,8 @@ export class MdCheckbox implements ControlValueAccessor {
139139
get disabled(): boolean { return this._disabled; }
140140
set disabled(value) { this._disabled = coerceBooleanProperty(value); }
141141

142-
/** @docs-private */
143-
@Input() tabindex: number = 0;
142+
/** Tabindex value that is passed to the underlying input element. */
143+
@Input() tabIndex: number = 0;
144144

145145
/** Name value will be applied to the input element if present */
146146
@Input() name: string = null;

0 commit comments

Comments
 (0)