未验证 提交 6cb1d954 编写于 作者: J Jackson Kearl 提交者: GitHub

Create new search input model for each instance of a settings editor (#56496)

* Create new search input model for each instance of a settings editor

* Move increment to render stage
上级 20395b9a
......@@ -50,6 +50,7 @@ const $ = DOM.$;
export class SettingsEditor2 extends BaseEditor {
public static readonly ID: string = 'workbench.editor.settings2';
private static NUM_INSTANCES: number = 0;
private static readonly SUGGESTIONS: string[] = [
'@modified', '@tag:usesOnlineServices', '@tag:new'
......@@ -217,7 +218,7 @@ export class SettingsEditor2 extends BaseEditor {
provideResults: (query: string) => {
return SettingsEditor2.SUGGESTIONS.filter(tag => query.indexOf(tag) === -1).map(tag => tag + ' ');
}
}, searchBoxLabel, 'settingseditor:searchinput', {
}, searchBoxLabel, 'settingseditor:searchinput' + SettingsEditor2.NUM_INSTANCES++, {
placeholderText: searchBoxLabel,
focusContextKey: this.searchFocusContextKey,
// TODO: Aria-live
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册