diff --git a/common/changes/office-ui-fabric-react/jspurlin-ComboBoxFixSubmitPendingValue_2018-05-31-16-16.json b/common/changes/office-ui-fabric-react/jspurlin-ComboBoxFixSubmitPendingValue_2018-05-31-16-16.json new file mode 100644 index 0000000000000..a9b24f69a6f5f --- /dev/null +++ b/common/changes/office-ui-fabric-react/jspurlin-ComboBoxFixSubmitPendingValue_2018-05-31-16-16.json @@ -0,0 +1,11 @@ +{ + "changes": [ + { + "packageName": "office-ui-fabric-react", + "comment": "ComboBox: Fix the value that is checked when submitting a pending value to take into account if the aria-label is used as text. This line was missed in the initial change", + "type": "patch" + } + ], + "packageName": "office-ui-fabric-react", + "email": "jspurlin@microsoft.com" +} \ No newline at end of file diff --git a/packages/office-ui-fabric-react/src/components/ComboBox/ComboBox.tsx b/packages/office-ui-fabric-react/src/components/ComboBox/ComboBox.tsx index 8d9274319fba0..ab2aa8f12c68a 100644 --- a/packages/office-ui-fabric-react/src/components/ComboBox/ComboBox.tsx +++ b/packages/office-ui-fabric-react/src/components/ComboBox/ComboBox.tsx @@ -942,7 +942,7 @@ export class ComboBox extends BaseComponent { // Check to see if the user typed an exact match if (this._indexWithinBounds(currentOptions, currentPendingValueValidIndex)) { - const pendingOptionText: string = currentOptions[currentPendingValueValidIndex].text.toLocaleLowerCase(); + const pendingOptionText: string = this._getPreviewText(currentOptions[currentPendingValueValidIndex]).toLocaleLowerCase(); // By exact match, that means: our pending value is the same as the the pending option text OR // the pending option starts with the pending value and we have an "autoComplete" selection