Commit 57508200 authored by Yuheng Huang's avatar Yuheng Huang Committed by Commit Bot

Tab Search: Fix TabSearchApp.ariaLabel_() typo

Bug: 1099917
Change-Id: Ie97e2092b0b60d28e00c31e0f7c5c32b92d8de28
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2510357Reviewed-by: default avatarThomas Lukaszewicz <tluk@chromium.org>
Commit-Queue: Yuheng Huang <yuhengh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#822774}
parent 06e231d6
......@@ -393,7 +393,8 @@ export class TabSearchAppElement extends PolymerElement {
// For some reasons setting combobox/aria-activedescendant on tab-search-search-field
// has no effect, so manually announce a11y message here.
this.announceA11y_(this.ariaLabel_(this.getSelectedTab_()));
this.announceA11y_(
this.ariaLabel_(this.filteredOpenTabs_[this.getSelectedIndex()]));
} else if (e.key === 'Enter') {
this.apiProxy_.switchToTab(
{tabId: this.getSelectedTab_().tabId}, !!this.searchText_);
......@@ -409,11 +410,12 @@ export class TabSearchAppElement extends PolymerElement {
}
/**
* @param {!TabData} tabData
* @return {string}
* @private
*/
ariaLabel_(item) {
return `${item.title} ${item.hostname}`;
ariaLabel_(tabData) {
return `${tabData.tab.title} ${tabData.hostname}`;
}
/**
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment