提交 2575c108 编写于 作者: S Sandeep Somavarapu

Fix #36979

上级 e6a76e4b
......@@ -723,16 +723,21 @@ class CommandColumn extends Column {
const commandDefaultLabelMatched = !!keybindingItemEntry.commandDefaultLabelMatches;
DOM.toggleClass(this.commandColumn, 'vertical-align-column', commandIdMatched || commandDefaultLabelMatched);
this.commandColumn.setAttribute('aria-label', this.getAriaLabel(keybindingItemEntry));
let commandLabel: HighlightedLabel;
if (keybindingItem.commandLabel) {
const commandLabel = new HighlightedLabel(this.commandColumn);
commandLabel = new HighlightedLabel(this.commandColumn);
commandLabel.set(keybindingItem.commandLabel, keybindingItemEntry.commandLabelMatches);
commandLabel.element.title = keybindingItem.command;
}
if (keybindingItemEntry.commandDefaultLabelMatches) {
new HighlightedLabel(DOM.append(this.commandColumn, $('.command-default-label'))).set(keybindingItem.commandDefaultLabel, keybindingItemEntry.commandDefaultLabelMatches);
commandLabel = new HighlightedLabel(DOM.append(this.commandColumn, $('.command-default-label')));
commandLabel.set(keybindingItem.commandDefaultLabel, keybindingItemEntry.commandDefaultLabelMatches);
}
if (keybindingItemEntry.commandIdMatches || !keybindingItem.commandLabel) {
new HighlightedLabel(DOM.append(this.commandColumn, $('.code'))).set(keybindingItem.command, keybindingItemEntry.commandIdMatches);
commandLabel = new HighlightedLabel(DOM.append(this.commandColumn, $('.code')));
commandLabel.set(keybindingItem.command, keybindingItemEntry.commandIdMatches);
}
if (commandLabel) {
commandLabel.element.title = keybindingItem.command;
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册