monaco-editor-core 0.56.0-dev-20260203 → 0.56.0-dev-20260204

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -1,6 +1,6 @@
1
1
  /*!-----------------------------------------------------------
2
2
  * Copyright (c) Microsoft Corporation. All rights reserved.
3
- * Version: 0.56.0-dev-20260203(e740ab4da3fac226afe362703507aba5af3f0ba9)
3
+ * Version: 0.56.0-dev-20260204(613524bdf43891f71ce0bf1f99584b666d70c95a)
4
4
  * Released under the MIT license
5
5
  * https://github.com/microsoft/vscode/blob/main/LICENSE.txt
6
6
  *-----------------------------------------------------------*/
@@ -327,6 +327,7 @@ let DropdownWithDefaultActionViewItem = class DropdownWithDefaultActionViewItem
327
327
  this._storageService = _storageService;
328
328
  this._defaultActionDisposables = this._register(new DisposableStore());
329
329
  this._container = null;
330
+ this._primaryActionListener = this._register(new MutableDisposable());
330
331
  this._options = options;
331
332
  this._storageKey = `${submenuAction.item.submenu.id}_lastActionId`;
332
333
  // determine default action
@@ -348,13 +349,16 @@ let DropdownWithDefaultActionViewItem = class DropdownWithDefaultActionViewItem
348
349
  };
349
350
  this._dropdown = this._register(new DropdownMenuActionViewItem(submenuAction, submenuAction.actions, this._contextMenuService, dropdownOptions));
350
351
  if (options?.togglePrimaryAction) {
351
- this._register(this._dropdown.actionRunner.onDidRun((e) => {
352
- if (e.action instanceof MenuItemAction) {
353
- this.update(e.action);
354
- }
355
- }));
352
+ this.registerTogglePrimaryActionListener();
356
353
  }
357
354
  }
355
+ registerTogglePrimaryActionListener() {
356
+ this._primaryActionListener.value = this._dropdown.actionRunner.onDidRun((e) => {
357
+ if (e.action instanceof MenuItemAction) {
358
+ this.update(e.action);
359
+ }
360
+ });
361
+ }
358
362
  update(lastAction) {
359
363
  if (this._options?.togglePrimaryAction) {
360
364
  this._storageService.store(this._storageKey, lastAction.id, 1 /* StorageScope.WORKSPACE */, 1 /* StorageTarget.MACHINE */);
@@ -389,6 +393,9 @@ let DropdownWithDefaultActionViewItem = class DropdownWithDefaultActionViewItem
389
393
  super.actionRunner = actionRunner;
390
394
  this._defaultAction.actionRunner = actionRunner;
391
395
  this._dropdown.actionRunner = actionRunner;
396
+ if (this._primaryActionListener.value) {
397
+ this.registerTogglePrimaryActionListener();
398
+ }
392
399
  }
393
400
  get actionRunner() {
394
401
  return super.actionRunner;
@@ -1 +1 @@
1
- {"version":3,"sources":["vs/platform/actions/browser/menuEntryActionViewItem.ts"],"names":[],"mappings":"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M,CAAC,IAAI,CAAC,aAAa,CAAC,mBAAmB,CAAC,CAAC,CAAC,KAAK;aAC3H,CAAC,CAAC;QACJ,CAAC;aAAM,CAAC;YACP,OAAO,YAAY,CAAC,cAAc,CAAC,0BAA0B,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC;QACjF,CAAC;IACF,CAAC;SAAM,CAAC;QACP,OAAO,SAAS,CAAC;IAClB,CAAC;AACF,CAAC","file":"menuEntryActionViewItem.js","sourceRoot":"file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport { asCSSUrl } from '../../../base/browser/cssValue.js';\nimport { $, addDisposableListener, append, EventType, ModifierKeyEmitter, prepend } from '../../../base/browser/dom.js';\nimport { StandardKeyboardEvent } from '../../../base/browser/keyboardEvent.js';\nimport { ActionViewItem, BaseActionViewItem, SelectActionViewItem } from '../../../base/browser/ui/actionbar/actionViewItems.js';\nimport { DropdownMenuActionViewItem, IDropdownMenuActionViewItemOptions } from '../../../base/browser/ui/dropdown/dropdownActionViewItem.js';\nimport { IHoverDelegate } from '../../../base/browser/ui/hover/hoverDelegate.js';\nimport { SeparatorSelectOption } from '../../../base/browser/ui/selectBox/selectBox.js';\nimport { ActionRunner, IAction, IActionRunner, IRunEvent, Separator, SubmenuAction } from '../../../base/common/actions.js';\nimport { UILabelProvider } from '../../../base/common/keybindingLabels.js';\nimport { ResolvedKeybinding } from '../../../base/common/keybindings.js';\nimport { KeyCode } from '../../../base/common/keyCodes.js';\nimport { combinedDisposable, DisposableStore, MutableDisposable, toDisposable } from '../../../base/common/lifecycle.js';\nimport { isLinux, isWindows, OS } from '../../../base/common/platform.js';\nimport { ThemeIcon } from '../../../base/common/themables.js';\nimport { assertType } from '../../../base/common/types.js';\nimport { localize } from '../../../nls.js';\nimport { IAccessibilityService } from '../../accessibility/common/accessibility.js';\nimport { ICommandAction, isICommandActionToggleInfo } from '../../action/common/action.js';\nimport { IConfigurationService } from '../../configuration/common/configuration.js';\nimport { IContextKeyService } from '../../contextkey/common/contextkey.js';\nimport { IContextMenuService, IContextViewService } from '../../contextview/browser/contextView.js';\nimport { IInstantiationService } from '../../instantiation/common/instantiation.js';\nimport { IKeybindingService } from '../../keybinding/common/keybinding.js';\nimport { INotificationService } from '../../notification/common/notification.js';\nimport { IStorageService, StorageScope, StorageTarget } from '../../storage/common/storage.js';\nimport { defaultSelectBoxStyles } from '../../theme/browser/defaultStyles.js';\nimport { asCssVariable, selectBorder } from '../../theme/common/colorRegistry.js';\nimport { isDark } from '../../theme/common/theme.js';\nimport { IThemeService } from '../../theme/common/themeService.js';\nimport { hasNativeContextMenu } from '../../window/common/window.js';\nimport { IMenuService, MenuItemAction, SubmenuItemAction } from '../common/actions.js';\nimport './menuEntryActionViewItem.css';\n\nexport interface PrimaryAndSecondaryActions {\n\tprimary: IAction[];\n\tsecondary: IAction[];\n}\n\nexport function getFlatContextMenuActions(\n\tgroups: ReadonlyArray<[string, ReadonlyArray<MenuItemAction | SubmenuItemAction>]>,\n\tprimaryGroup?: string\n): IAction[] {\n\tconst target: IAction[] = [];\n\tgetContextMenuActionsImpl(groups, target, primaryGroup);\n\treturn target;\n}\n\nfunction getContextMenuActionsImpl(\n\tgroups: ReadonlyArray<[string, ReadonlyArray<MenuItemAction | SubmenuItemAction>]>,\n\ttarget: IAction[] | PrimaryAndSecondaryActions,\n\tprimaryGroup?: string\n) {\n\tconst modifierKeyEmitter = ModifierKeyEmitter.getInstance();\n\tconst useAlternativeActions = modifierKeyEmitter.keyStatus.altKey || ((isWindows || isLinux) && modifierKeyEmitter.keyStatus.shiftKey);\n\tfillInActions(groups, target, useAlternativeActions, primaryGroup ? actionGroup => actionGroup === primaryGroup : actionGroup => actionGroup === 'navigation');\n}\n\n\nexport function getActionBarActions(\n\tgroups: [string, Array<MenuItemAction | SubmenuItemAction>][],\n\tprimaryGroup?: string | ((actionGroup: string) => boolean),\n\tshouldInlineSubmenu?: (action: SubmenuAction, group: string, groupSize: number) => boolean,\n\tuseSeparatorsInPrimaryActions?: boolean\n): PrimaryAndSecondaryActions {\n\tconst target: PrimaryAndSecondaryActions = { primary: [], secondary: [] };\n\tfillInActionBarActions(groups, target, primaryGroup, shouldInlineSubmenu, useSeparatorsInPrimaryActions);\n\treturn target;\n}\n\nexport function getFlatActionBarActions(\n\tgroups: [string, Array<MenuItemAction | SubmenuItemAction>][],\n\tprimaryGroup?: string | ((actionGroup: string) => boolean),\n\tshouldInlineSubmenu?: (action: SubmenuAction, group: string, groupSize: number) => boolean,\n\tuseSeparatorsInPrimaryActions?: boolean\n): IAction[] {\n\tconst target: IAction[] = [];\n\tfillInActionBarActions(groups, target, primaryGroup, shouldInlineSubmenu, useSeparatorsInPrimaryActions);\n\treturn target;\n}\n\nexport function fillInActionBarActions(\n\tgroups: [string, Array<MenuItemAction | SubmenuItemAction>][],\n\ttarget: IAction[] | PrimaryAndSecondaryActions,\n\tprimaryGroup?: string | ((actionGroup: string) => boolean),\n\tshouldInlineSubmenu?: (action: SubmenuAction, group: string, groupSize: number) => boolean,\n\tuseSeparatorsInPrimaryActions?: boolean\n): void {\n\tconst isPrimaryAction = typeof primaryGroup === 'string' ? (actionGroup: string) => actionGroup === primaryGroup : primaryGroup;\n\n\t// Action bars handle alternative actions on their own so the alternative actions should be ignored\n\tfillInActions(groups, target, false, isPrimaryAction, shouldInlineSubmenu, useSeparatorsInPrimaryActions);\n}\n\nfunction fillInActions(\n\tgroups: ReadonlyArray<[string, ReadonlyArray<MenuItemAction | SubmenuItemAction>]>,\n\ttarget: IAction[] | PrimaryAndSecondaryActions,\n\tuseAlternativeActions: boolean,\n\tisPrimaryAction: (actionGroup: string) => boolean = actionGroup => actionGroup === 'navigation',\n\tshouldInlineSubmenu: (action: SubmenuAction, group: string, groupSize: number) => boolean = () => false,\n\tuseSeparatorsInPrimaryActions: boolean = false\n): void {\n\n\tlet primaryBucket: IAction[];\n\tlet secondaryBucket: IAction[];\n\tif (Array.isArray(target)) {\n\t\tprimaryBucket = target;\n\t\tsecondaryBucket = target;\n\t} else {\n\t\tprimaryBucket = target.primary;\n\t\tsecondaryBucket = target.secondary;\n\t}\n\n\tconst submenuInfo = new Set<{ group: string; action: SubmenuAction; index: number }>();\n\n\tfor (const [group, actions] of groups) {\n\n\t\tlet target: IAction[];\n\t\tif (isPrimaryAction(group)) {\n\t\t\ttarget = primaryBucket;\n\t\t\tif (target.length > 0 && useSeparatorsInPrimaryActions) {\n\t\t\t\ttarget.push(new Separator());\n\t\t\t}\n\t\t} else {\n\t\t\ttarget = secondaryBucket;\n\t\t\tif (target.length > 0) {\n\t\t\t\ttarget.push(new Separator());\n\t\t\t}\n\t\t}\n\n\t\tfor (let action of actions) {\n\t\t\tif (useAlternativeActions) {\n\t\t\t\taction = action instanceof MenuItemAction && action.alt ? action.alt : action;\n\t\t\t}\n\t\t\tconst newLen = target.push(action);\n\t\t\t// keep submenu info for later inlining\n\t\t\tif (action instanceof SubmenuAction) {\n\t\t\t\tsubmenuInfo.add({ group, action, index: newLen - 1 });\n\t\t\t}\n\t\t}\n\t}\n\n\t// ask the outside if submenu should be inlined or not. only ask when\n\t// there would be enough space\n\tfor (const { group, action, index } of submenuInfo) {\n\t\tconst target = isPrimaryAction(group) ? primaryBucket : secondaryBucket;\n\n\t\t// inlining submenus with length 0 or 1 is easy,\n\t\t// larger submenus need to be checked with the overall limit\n\t\tconst submenuActions = action.actions;\n\t\tif (shouldInlineSubmenu(action, group, target.length)) {\n\t\t\ttarget.splice(index, 1, ...submenuActions);\n\t\t}\n\t}\n}\n\nexport interface IMenuEntryActionViewItemOptions {\n\treadonly draggable?: boolean;\n\treadonly keybinding?: string | null;\n\treadonly hoverDelegate?: IHoverDelegate;\n\treadonly keybindingNotRenderedWithLabel?: boolean;\n}\n\nexport class MenuEntryActionViewItem<T extends IMenuEntryActionViewItemOptions = IMenuEntryActionViewItemOptions> extends ActionViewItem {\n\n\tprivate _wantsAltCommand: boolean = false;\n\tprivate readonly _itemClassDispose = this._register(new MutableDisposable());\n\tprivate readonly _altKey: ModifierKeyEmitter;\n\n\tconstructor(\n\t\taction: MenuItemAction,\n\t\tprotected readonly _options: T | undefined,\n\t\t@IKeybindingService protected readonly _keybindingService: IKeybindingService,\n\t\t@INotificationService protected readonly _notificationService: INotificationService,\n\t\t@IContextKeyService protected readonly _contextKeyService: IContextKeyService,\n\t\t@IThemeService protected readonly _themeService: IThemeService,\n\t\t@IContextMenuService protected readonly _contextMenuService: IContextMenuService,\n\t\t@IAccessibilityService private readonly _accessibilityService: IAccessibilityService\n\t) {\n\t\tsuper(undefined, action, { icon: !!(action.class || action.item.icon), label: !action.class && !action.item.icon, draggable: _options?.draggable, keybinding: _options?.keybinding, hoverDelegate: _options?.hoverDelegate, keybindingNotRenderedWithLabel: _options?.keybindingNotRenderedWithLabel });\n\t\tthis._altKey = ModifierKeyEmitter.getInstance();\n\t}\n\n\tprotected get _menuItemAction(): MenuItemAction {\n\t\treturn <MenuItemAction>this._action;\n\t}\n\n\tprotected get _commandAction(): MenuItemAction {\n\t\treturn this._wantsAltCommand && this._menuItemAction.alt || this._menuItemAction;\n\t}\n\n\toverride async onClick(event: MouseEvent): Promise<void> {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\n\t\ttry {\n\t\t\tawait this.actionRunner.run(this._commandAction, this._context);\n\t\t} catch (err) {\n\t\t\tthis._notificationService.error(err);\n\t\t}\n\t}\n\n\toverride render(container: HTMLElement): void {\n\t\tsuper.render(container);\n\t\tcontainer.classList.add('menu-entry');\n\n\t\tif (this.options.icon) {\n\t\t\tthis._updateItemClass(this._menuItemAction.item);\n\t\t}\n\n\t\tif (this._menuItemAction.alt) {\n\t\t\tlet isMouseOver = false;\n\n\t\t\tconst updateAltState = () => {\n\t\t\t\tconst wantsAltCommand = !!this._menuItemAction.alt?.enabled &&\n\t\t\t\t\t(!this._accessibilityService.isMotionReduced() || isMouseOver) && (\n\t\t\t\t\t\tthis._altKey.keyStatus.altKey ||\n\t\t\t\t\t\t(this._altKey.keyStatus.shiftKey && isMouseOver)\n\t\t\t\t\t);\n\n\t\t\t\tif (wantsAltCommand !== this._wantsAltCommand) {\n\t\t\t\t\tthis._wantsAltCommand = wantsAltCommand;\n\t\t\t\t\tthis.updateLabel();\n\t\t\t\t\tthis.updateTooltip();\n\t\t\t\t\tthis.updateClass();\n\t\t\t\t}\n\t\t\t};\n\n\t\t\tthis._register(this._altKey.event(updateAltState));\n\n\t\t\tthis._register(addDisposableListener(container, 'mouseleave', _ => {\n\t\t\t\tisMouseOver = false;\n\t\t\t\tupdateAltState();\n\t\t\t}));\n\n\t\t\tthis._register(addDisposableListener(container, 'mouseenter', _ => {\n\t\t\t\tisMouseOver = true;\n\t\t\t\tupdateAltState();\n\t\t\t}));\n\n\t\t\tupdateAltState();\n\t\t}\n\t}\n\n\tprotected override updateLabel(): void {\n\t\tif (this.options.label && this.label) {\n\t\t\tthis.label.textContent = this._commandAction.label;\n\t\t}\n\t}\n\n\tprotected override getTooltip() {\n\t\tconst tooltip = this._commandAction.tooltip || this._commandAction.label;\n\t\tlet title = this._keybindingService.appendKeybinding(tooltip, this._commandAction.id, this._contextKeyService);\n\t\tif (!this._wantsAltCommand && this._menuItemAction.alt?.enabled) {\n\t\t\tconst altTooltip = this._menuItemAction.alt.tooltip || this._menuItemAction.alt.label;\n\t\t\tconst altTitleSection = this._keybindingService.appendKeybinding(altTooltip, this._menuItemAction.alt.id, this._contextKeyService);\n\n\t\t\ttitle = localize('titleAndKbAndAlt', \"{0}\\n[{1}] {2}\", title, UILabelProvider.modifierLabels[OS].altKey, altTitleSection);\n\t\t}\n\t\treturn title;\n\t}\n\n\tprotected override updateClass(): void {\n\t\tif (this.options.icon) {\n\t\t\tif (this._commandAction !== this._menuItemAction) {\n\t\t\t\tif (this._menuItemAction.alt) {\n\t\t\t\t\tthis._updateItemClass(this._menuItemAction.alt.item);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tthis._updateItemClass(this._menuItemAction.item);\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate _updateItemClass(item: ICommandAction): void {\n\t\tthis._itemClassDispose.value = undefined;\n\n\t\tconst { element, label } = this;\n\t\tif (!element || !label) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst icon = this._commandAction.checked && isICommandActionToggleInfo(item.toggled) && item.toggled.icon ? item.toggled.icon : item.icon;\n\n\t\tif (!icon) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (ThemeIcon.isThemeIcon(icon)) {\n\t\t\t// theme icons\n\t\t\tconst iconClasses = ThemeIcon.asClassNameArray(icon);\n\t\t\tlabel.classList.add(...iconClasses);\n\t\t\tthis._itemClassDispose.value = toDisposable(() => {\n\t\t\t\tlabel.classList.remove(...iconClasses);\n\t\t\t});\n\n\t\t} else {\n\t\t\t// icon path/url\n\t\t\tlabel.style.backgroundImage = (\n\t\t\t\tisDark(this._themeService.getColorTheme().type)\n\t\t\t\t\t? asCSSUrl(icon.dark)\n\t\t\t\t\t: asCSSUrl(icon.light)\n\t\t\t);\n\t\t\tlabel.classList.add('icon');\n\t\t\tthis._itemClassDispose.value = combinedDisposable(\n\t\t\t\ttoDisposable(() => {\n\t\t\t\t\tlabel.style.backgroundImage = '';\n\t\t\t\t\tlabel.classList.remove('icon');\n\t\t\t\t}),\n\t\t\t\tthis._themeService.onDidColorThemeChange(() => {\n\t\t\t\t\t// refresh when the theme changes in case we go between dark <-> light\n\t\t\t\t\tthis.updateClass();\n\t\t\t\t})\n\t\t\t);\n\t\t}\n\t}\n}\n\nexport interface ITextOnlyMenuEntryActionViewItemOptions extends IMenuEntryActionViewItemOptions {\n\treadonly conversational?: boolean;\n\treadonly useComma?: boolean;\n}\n\nexport class TextOnlyMenuEntryActionViewItem extends MenuEntryActionViewItem<ITextOnlyMenuEntryActionViewItemOptions> {\n\n\toverride render(container: HTMLElement): void {\n\t\tthis.options.label = true;\n\t\tthis.options.icon = false;\n\t\tsuper.render(container);\n\t\tcontainer.classList.add('text-only');\n\t\tcontainer.classList.toggle('use-comma', this._options?.useComma ?? false);\n\t}\n\n\tprotected override updateLabel() {\n\t\tconst kb = this._keybindingService.lookupKeybinding(this._action.id, this._contextKeyService);\n\t\tif (!kb) {\n\t\t\treturn super.updateLabel();\n\t\t}\n\t\tif (this.label) {\n\t\t\tconst kb2 = TextOnlyMenuEntryActionViewItem._symbolPrintEnter(kb);\n\n\t\t\tif (this._options?.conversational) {\n\t\t\t\tthis.label.textContent = localize({ key: 'content2', comment: ['A label with keybindg like \"ESC to dismiss\"'] }, '{1} to {0}', this._action.label, kb2);\n\n\t\t\t} else {\n\t\t\t\tthis.label.textContent = localize({ key: 'content', comment: ['A label', 'A keybinding'] }, '{0} ({1})', this._action.label, kb2);\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate static _symbolPrintEnter(kb: ResolvedKeybinding) {\n\t\treturn kb.getLabel()\n\t\t\t?.replace(/\\benter\\b/gi, '\\u23CE')\n\t\t\t.replace(/\\bEscape\\b/gi, 'Esc');\n\t}\n}\n\nexport class SubmenuEntryActionViewItem extends DropdownMenuActionViewItem {\n\n\tconstructor(\n\t\taction: SubmenuItemAction,\n\t\toptions: IDropdownMenuActionViewItemOptions | undefined,\n\t\t@IKeybindingService protected _keybindingService: IKeybindingService,\n\t\t@IContextMenuService protected _contextMenuService: IContextMenuService,\n\t\t@IThemeService protected _themeService: IThemeService\n\t) {\n\t\tconst dropdownOptions: IDropdownMenuActionViewItemOptions = {\n\t\t\t...options,\n\t\t\tmenuAsChild: options?.menuAsChild ?? false,\n\t\t\tclassNames: options?.classNames ?? (ThemeIcon.isThemeIcon(action.item.icon) ? ThemeIcon.asClassName(action.item.icon) : undefined),\n\t\t\tkeybindingProvider: options?.keybindingProvider ?? (action => _keybindingService.lookupKeybinding(action.id))\n\t\t};\n\n\t\tsuper(action, { getActions: () => action.actions }, _contextMenuService, dropdownOptions);\n\t}\n\n\toverride render(container: HTMLElement): void {\n\t\tsuper.render(container);\n\t\tassertType(this.element);\n\n\t\tcontainer.classList.add('menu-entry');\n\t\tconst action = <SubmenuItemAction>this._action;\n\t\tconst { icon } = action.item;\n\t\tif (icon && !ThemeIcon.isThemeIcon(icon)) {\n\t\t\tthis.element.classList.add('icon');\n\t\t\tconst setBackgroundImage = () => {\n\t\t\t\tif (this.element) {\n\t\t\t\t\tthis.element.style.backgroundImage = (\n\t\t\t\t\t\tisDark(this._themeService.getColorTheme().type)\n\t\t\t\t\t\t\t? asCSSUrl(icon.dark)\n\t\t\t\t\t\t\t: asCSSUrl(icon.light)\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t};\n\t\t\tsetBackgroundImage();\n\t\t\tthis._register(this._themeService.onDidColorThemeChange(() => {\n\t\t\t\t// refresh when the theme changes in case we go between dark <-> light\n\t\t\t\tsetBackgroundImage();\n\t\t\t}));\n\t\t}\n\t}\n}\n\nexport interface IDropdownWithDefaultActionViewItemOptions extends IDropdownMenuActionViewItemOptions {\n\trenderKeybindingWithDefaultActionLabel?: boolean;\n\ttogglePrimaryAction?: boolean;\n}\n\nexport class DropdownWithDefaultActionViewItem extends BaseActionViewItem {\n\tprivate readonly _options: IDropdownWithDefaultActionViewItemOptions | undefined;\n\tprivate _defaultAction: ActionViewItem;\n\tprivate readonly _defaultActionDisposables = this._register(new DisposableStore());\n\tprivate readonly _dropdown: DropdownMenuActionViewItem;\n\tprivate _container: HTMLElement | null = null;\n\tprivate readonly _storageKey: string;\n\n\tconstructor(\n\t\tsubmenuAction: SubmenuItemAction,\n\t\toptions: IDropdownWithDefaultActionViewItemOptions | undefined,\n\t\t@IKeybindingService protected readonly _keybindingService: IKeybindingService,\n\t\t@INotificationService protected _notificationService: INotificationService,\n\t\t@IContextMenuService protected _contextMenuService: IContextMenuService,\n\t\t@IMenuService protected _menuService: IMenuService,\n\t\t@IInstantiationService protected _instaService: IInstantiationService,\n\t\t@IStorageService protected _storageService: IStorageService\n\t) {\n\t\tsuper(null, submenuAction);\n\t\tthis._options = options;\n\t\tthis._storageKey = `${submenuAction.item.submenu.id}_lastActionId`;\n\n\t\t// determine default action\n\t\tlet defaultAction: IAction | undefined;\n\t\tconst defaultActionId = options?.togglePrimaryAction ? _storageService.get(this._storageKey, StorageScope.WORKSPACE) : undefined;\n\t\tif (defaultActionId) {\n\t\t\tdefaultAction = submenuAction.actions.find(a => defaultActionId === a.id);\n\t\t}\n\t\tif (!defaultAction) {\n\t\t\tdefaultAction = submenuAction.actions[0];\n\t\t}\n\n\t\tthis._defaultAction = this._defaultActionDisposables.add(this._instaService.createInstance(MenuEntryActionViewItem, <MenuItemAction>defaultAction, { keybinding: this._getDefaultActionKeybindingLabel(defaultAction) }));\n\n\t\tconst dropdownOptions: IDropdownMenuActionViewItemOptions = {\n\t\t\tkeybindingProvider: action => this._keybindingService.lookupKeybinding(action.id),\n\t\t\t...options,\n\t\t\tmenuAsChild: options?.menuAsChild ?? true,\n\t\t\tclassNames: options?.classNames ?? ['codicon', 'codicon-chevron-down'],\n\t\t\tactionRunner: options?.actionRunner ?? this._register(new ActionRunner()),\n\t\t};\n\n\t\tthis._dropdown = this._register(new DropdownMenuActionViewItem(submenuAction, submenuAction.actions, this._contextMenuService, dropdownOptions));\n\t\tif (options?.togglePrimaryAction) {\n\t\t\tthis._register(this._dropdown.actionRunner.onDidRun((e: IRunEvent) => {\n\t\t\t\tif (e.action instanceof MenuItemAction) {\n\t\t\t\t\tthis.update(e.action);\n\t\t\t\t}\n\t\t\t}));\n\t\t}\n\t}\n\n\tprivate update(lastAction: MenuItemAction): void {\n\t\tif (this._options?.togglePrimaryAction) {\n\t\t\tthis._storageService.store(this._storageKey, lastAction.id, StorageScope.WORKSPACE, StorageTarget.MACHINE);\n\t\t}\n\n\t\tthis._defaultActionDisposables.clear();\n\t\tthis._defaultAction = this._defaultActionDisposables.add(this._instaService.createInstance(MenuEntryActionViewItem, lastAction, { keybinding: this._getDefaultActionKeybindingLabel(lastAction) }));\n\t\tthis._defaultAction.actionRunner = this._defaultActionDisposables.add(new class extends ActionRunner {\n\t\t\tprotected override async runAction(action: IAction, context?: unknown): Promise<void> {\n\t\t\t\tawait action.run(undefined);\n\t\t\t}\n\t\t}());\n\n\t\tif (this._container) {\n\t\t\tthis._defaultAction.render(prepend(this._container, $('.action-container')));\n\t\t}\n\t}\n\n\tprivate _getDefaultActionKeybindingLabel(defaultAction: IAction) {\n\t\tlet defaultActionKeybinding: string | undefined;\n\t\tif (this._options?.renderKeybindingWithDefaultActionLabel) {\n\t\t\tconst kb = this._keybindingService.lookupKeybinding(defaultAction.id);\n\t\t\tif (kb) {\n\t\t\t\tdefaultActionKeybinding = `(${kb.getLabel()})`;\n\t\t\t}\n\t\t}\n\t\treturn defaultActionKeybinding;\n\t}\n\n\toverride setActionContext(newContext: unknown): void {\n\t\tsuper.setActionContext(newContext);\n\t\tthis._defaultAction.setActionContext(newContext);\n\t\tthis._dropdown.setActionContext(newContext);\n\t}\n\n\toverride set actionRunner(actionRunner: IActionRunner) {\n\t\tsuper.actionRunner = actionRunner;\n\n\t\tthis._defaultAction.actionRunner = actionRunner;\n\t\tthis._dropdown.actionRunner = actionRunner;\n\t}\n\n\toverride get actionRunner(): IActionRunner {\n\t\treturn super.actionRunner;\n\t}\n\n\toverride render(container: HTMLElement): void {\n\t\tthis._container = container;\n\t\tsuper.render(this._container);\n\n\t\tthis._container.classList.add('monaco-dropdown-with-default');\n\n\t\tconst primaryContainer = $('.action-container');\n\t\tthis._defaultAction.render(append(this._container, primaryContainer));\n\t\tthis._register(addDisposableListener(primaryContainer, EventType.KEY_DOWN, (e: KeyboardEvent) => {\n\t\t\tconst event = new StandardKeyboardEvent(e);\n\t\t\tif (event.equals(KeyCode.RightArrow)) {\n\t\t\t\tthis._defaultAction.element!.tabIndex = -1;\n\t\t\t\tthis._dropdown.focus();\n\t\t\t\tevent.stopPropagation();\n\t\t\t}\n\t\t}));\n\n\t\tconst dropdownContainer = $('.dropdown-action-container');\n\t\tthis._dropdown.render(append(this._container, dropdownContainer));\n\t\tthis._register(addDisposableListener(dropdownContainer, EventType.KEY_DOWN, (e: KeyboardEvent) => {\n\t\t\tconst event = new StandardKeyboardEvent(e);\n\t\t\tif (event.equals(KeyCode.LeftArrow)) {\n\t\t\t\tthis._defaultAction.element!.tabIndex = 0;\n\t\t\t\tthis._dropdown.setFocusable(false);\n\t\t\t\tthis._defaultAction.element?.focus();\n\t\t\t\tevent.stopPropagation();\n\t\t\t}\n\t\t}));\n\t}\n\n\toverride focus(fromRight?: boolean): void {\n\t\tif (fromRight) {\n\t\t\tthis._dropdown.focus();\n\t\t} else {\n\t\t\tthis._defaultAction.element!.tabIndex = 0;\n\t\t\tthis._defaultAction.element!.focus();\n\t\t}\n\t}\n\n\toverride blur(): void {\n\t\tthis._defaultAction.element!.tabIndex = -1;\n\t\tthis._dropdown.blur();\n\t\tthis._container!.blur();\n\t}\n\n\toverride setFocusable(focusable: boolean): void {\n\t\tif (focusable) {\n\t\t\tthis._defaultAction.element!.tabIndex = 0;\n\t\t} else {\n\t\t\tthis._defaultAction.element!.tabIndex = -1;\n\t\t\tthis._dropdown.setFocusable(false);\n\t\t}\n\t}\n}\n\nclass SubmenuEntrySelectActionViewItem extends SelectActionViewItem {\n\n\tconstructor(\n\t\taction: SubmenuItemAction,\n\t\t@IContextViewService contextViewService: IContextViewService,\n\t\t@IConfigurationService configurationService: IConfigurationService,\n\t) {\n\t\tsuper(null, action, action.actions.map(a => (a.id === Separator.ID ? SeparatorSelectOption : { text: a.label, isDisabled: !a.enabled, })), 0, contextViewService, defaultSelectBoxStyles, { ariaLabel: action.tooltip || action.label, optionsAsChildren: true, useCustomDrawn: !hasNativeContextMenu(configurationService) });\n\t\tthis.select(Math.max(0, action.actions.findIndex(a => a.checked)));\n\t}\n\n\toverride render(container: HTMLElement): void {\n\t\tsuper.render(container);\n\t\tcontainer.style.borderColor = asCssVariable(selectBorder);\n\t}\n\n\tprotected override runAction(option: string, index: number): void {\n\t\tconst action = (this.action as SubmenuItemAction).actions[index];\n\t\tif (action) {\n\t\t\tthis.actionRunner.run(action);\n\t\t}\n\t}\n\n}\n\n/**\n * Creates action view items for menu actions or submenu actions.\n */\nexport function createActionViewItem(instaService: IInstantiationService, action: IAction, options: IDropdownMenuActionViewItemOptions | IMenuEntryActionViewItemOptions | undefined): undefined | MenuEntryActionViewItem | SubmenuEntryActionViewItem | BaseActionViewItem {\n\tif (action instanceof MenuItemAction) {\n\t\treturn instaService.createInstance(MenuEntryActionViewItem, action, options);\n\t} else if (action instanceof SubmenuItemAction) {\n\t\tif (action.item.isSelection) {\n\t\t\treturn instaService.createInstance(SubmenuEntrySelectActionViewItem, action);\n\t\t} else if (action.item.isSplitButton) {\n\t\t\treturn instaService.createInstance(DropdownWithDefaultActionViewItem, action, {\n\t\t\t\t...options,\n\t\t\t\ttogglePrimaryAction: typeof action.item.isSplitButton !== 'boolean' ? action.item.isSplitButton.togglePrimaryAction : false,\n\t\t\t});\n\t\t} else {\n\t\t\treturn instaService.createInstance(SubmenuEntryActionViewItem, action, options);\n\t\t}\n\t} else {\n\t\treturn undefined;\n\t}\n}\n"]}
1
+ {"version":3,"sources":["vs/platform/actions/browser/menuEntryActionViewItem.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;;;;;;;;;;AAEhG,OAAO,EAAE,QAAQ,EAAE,MAAM,mCAAmC,CAAC;AAC7D,OAAO,EAAE,CAAC,EAAE,qBAAqB,EAAE,MAAM,EAAE,SAAS,EAAE,kBAAkB,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AACxH,OAAO,EAAE,qBAAqB,EAAE,MAAM,wCAAwC,CAAC;AAC/E,OAAO,EAAE,cAAc,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,MAAM,uDAAuD,CAAC;AACjI,OAAO,EAAE,0BAA0B,EAAsC,MAAM,6DAA6D,CAAC;AAE7I,OAAO,EAAE,qBAAqB,EAAE,MAAM,iDAAiD,CAAC;AAC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C;QACjF,CAAC;IACF,CAAC;SAAM,CAAC;QACP,OAAO,SAAS,CAAC;IAClB,CAAC;AACF,CAAC","file":"menuEntryActionViewItem.js","sourceRoot":"file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport { asCSSUrl } from '../../../base/browser/cssValue.js';\nimport { $, addDisposableListener, append, EventType, ModifierKeyEmitter, prepend } from '../../../base/browser/dom.js';\nimport { StandardKeyboardEvent } from '../../../base/browser/keyboardEvent.js';\nimport { ActionViewItem, BaseActionViewItem, SelectActionViewItem } from '../../../base/browser/ui/actionbar/actionViewItems.js';\nimport { DropdownMenuActionViewItem, IDropdownMenuActionViewItemOptions } from '../../../base/browser/ui/dropdown/dropdownActionViewItem.js';\nimport { IHoverDelegate } from '../../../base/browser/ui/hover/hoverDelegate.js';\nimport { SeparatorSelectOption } from '../../../base/browser/ui/selectBox/selectBox.js';\nimport { ActionRunner, IAction, IActionRunner, IRunEvent, Separator, SubmenuAction } from '../../../base/common/actions.js';\nimport { UILabelProvider } from '../../../base/common/keybindingLabels.js';\nimport { ResolvedKeybinding } from '../../../base/common/keybindings.js';\nimport { KeyCode } from '../../../base/common/keyCodes.js';\nimport { combinedDisposable, DisposableStore, MutableDisposable, toDisposable } from '../../../base/common/lifecycle.js';\nimport { isLinux, isWindows, OS } from '../../../base/common/platform.js';\nimport { ThemeIcon } from '../../../base/common/themables.js';\nimport { assertType } from '../../../base/common/types.js';\nimport { localize } from '../../../nls.js';\nimport { IAccessibilityService } from '../../accessibility/common/accessibility.js';\nimport { ICommandAction, isICommandActionToggleInfo } from '../../action/common/action.js';\nimport { IConfigurationService } from '../../configuration/common/configuration.js';\nimport { IContextKeyService } from '../../contextkey/common/contextkey.js';\nimport { IContextMenuService, IContextViewService } from '../../contextview/browser/contextView.js';\nimport { IInstantiationService } from '../../instantiation/common/instantiation.js';\nimport { IKeybindingService } from '../../keybinding/common/keybinding.js';\nimport { INotificationService } from '../../notification/common/notification.js';\nimport { IStorageService, StorageScope, StorageTarget } from '../../storage/common/storage.js';\nimport { defaultSelectBoxStyles } from '../../theme/browser/defaultStyles.js';\nimport { asCssVariable, selectBorder } from '../../theme/common/colorRegistry.js';\nimport { isDark } from '../../theme/common/theme.js';\nimport { IThemeService } from '../../theme/common/themeService.js';\nimport { hasNativeContextMenu } from '../../window/common/window.js';\nimport { IMenuService, MenuItemAction, SubmenuItemAction } from '../common/actions.js';\nimport './menuEntryActionViewItem.css';\n\nexport interface PrimaryAndSecondaryActions {\n\tprimary: IAction[];\n\tsecondary: IAction[];\n}\n\nexport function getFlatContextMenuActions(\n\tgroups: ReadonlyArray<[string, ReadonlyArray<MenuItemAction | SubmenuItemAction>]>,\n\tprimaryGroup?: string\n): IAction[] {\n\tconst target: IAction[] = [];\n\tgetContextMenuActionsImpl(groups, target, primaryGroup);\n\treturn target;\n}\n\nfunction getContextMenuActionsImpl(\n\tgroups: ReadonlyArray<[string, ReadonlyArray<MenuItemAction | SubmenuItemAction>]>,\n\ttarget: IAction[] | PrimaryAndSecondaryActions,\n\tprimaryGroup?: string\n) {\n\tconst modifierKeyEmitter = ModifierKeyEmitter.getInstance();\n\tconst useAlternativeActions = modifierKeyEmitter.keyStatus.altKey || ((isWindows || isLinux) && modifierKeyEmitter.keyStatus.shiftKey);\n\tfillInActions(groups, target, useAlternativeActions, primaryGroup ? actionGroup => actionGroup === primaryGroup : actionGroup => actionGroup === 'navigation');\n}\n\n\nexport function getActionBarActions(\n\tgroups: [string, Array<MenuItemAction | SubmenuItemAction>][],\n\tprimaryGroup?: string | ((actionGroup: string) => boolean),\n\tshouldInlineSubmenu?: (action: SubmenuAction, group: string, groupSize: number) => boolean,\n\tuseSeparatorsInPrimaryActions?: boolean\n): PrimaryAndSecondaryActions {\n\tconst target: PrimaryAndSecondaryActions = { primary: [], secondary: [] };\n\tfillInActionBarActions(groups, target, primaryGroup, shouldInlineSubmenu, useSeparatorsInPrimaryActions);\n\treturn target;\n}\n\nexport function getFlatActionBarActions(\n\tgroups: [string, Array<MenuItemAction | SubmenuItemAction>][],\n\tprimaryGroup?: string | ((actionGroup: string) => boolean),\n\tshouldInlineSubmenu?: (action: SubmenuAction, group: string, groupSize: number) => boolean,\n\tuseSeparatorsInPrimaryActions?: boolean\n): IAction[] {\n\tconst target: IAction[] = [];\n\tfillInActionBarActions(groups, target, primaryGroup, shouldInlineSubmenu, useSeparatorsInPrimaryActions);\n\treturn target;\n}\n\nexport function fillInActionBarActions(\n\tgroups: [string, Array<MenuItemAction | SubmenuItemAction>][],\n\ttarget: IAction[] | PrimaryAndSecondaryActions,\n\tprimaryGroup?: string | ((actionGroup: string) => boolean),\n\tshouldInlineSubmenu?: (action: SubmenuAction, group: string, groupSize: number) => boolean,\n\tuseSeparatorsInPrimaryActions?: boolean\n): void {\n\tconst isPrimaryAction = typeof primaryGroup === 'string' ? (actionGroup: string) => actionGroup === primaryGroup : primaryGroup;\n\n\t// Action bars handle alternative actions on their own so the alternative actions should be ignored\n\tfillInActions(groups, target, false, isPrimaryAction, shouldInlineSubmenu, useSeparatorsInPrimaryActions);\n}\n\nfunction fillInActions(\n\tgroups: ReadonlyArray<[string, ReadonlyArray<MenuItemAction | SubmenuItemAction>]>,\n\ttarget: IAction[] | PrimaryAndSecondaryActions,\n\tuseAlternativeActions: boolean,\n\tisPrimaryAction: (actionGroup: string) => boolean = actionGroup => actionGroup === 'navigation',\n\tshouldInlineSubmenu: (action: SubmenuAction, group: string, groupSize: number) => boolean = () => false,\n\tuseSeparatorsInPrimaryActions: boolean = false\n): void {\n\n\tlet primaryBucket: IAction[];\n\tlet secondaryBucket: IAction[];\n\tif (Array.isArray(target)) {\n\t\tprimaryBucket = target;\n\t\tsecondaryBucket = target;\n\t} else {\n\t\tprimaryBucket = target.primary;\n\t\tsecondaryBucket = target.secondary;\n\t}\n\n\tconst submenuInfo = new Set<{ group: string; action: SubmenuAction; index: number }>();\n\n\tfor (const [group, actions] of groups) {\n\n\t\tlet target: IAction[];\n\t\tif (isPrimaryAction(group)) {\n\t\t\ttarget = primaryBucket;\n\t\t\tif (target.length > 0 && useSeparatorsInPrimaryActions) {\n\t\t\t\ttarget.push(new Separator());\n\t\t\t}\n\t\t} else {\n\t\t\ttarget = secondaryBucket;\n\t\t\tif (target.length > 0) {\n\t\t\t\ttarget.push(new Separator());\n\t\t\t}\n\t\t}\n\n\t\tfor (let action of actions) {\n\t\t\tif (useAlternativeActions) {\n\t\t\t\taction = action instanceof MenuItemAction && action.alt ? action.alt : action;\n\t\t\t}\n\t\t\tconst newLen = target.push(action);\n\t\t\t// keep submenu info for later inlining\n\t\t\tif (action instanceof SubmenuAction) {\n\t\t\t\tsubmenuInfo.add({ group, action, index: newLen - 1 });\n\t\t\t}\n\t\t}\n\t}\n\n\t// ask the outside if submenu should be inlined or not. only ask when\n\t// there would be enough space\n\tfor (const { group, action, index } of submenuInfo) {\n\t\tconst target = isPrimaryAction(group) ? primaryBucket : secondaryBucket;\n\n\t\t// inlining submenus with length 0 or 1 is easy,\n\t\t// larger submenus need to be checked with the overall limit\n\t\tconst submenuActions = action.actions;\n\t\tif (shouldInlineSubmenu(action, group, target.length)) {\n\t\t\ttarget.splice(index, 1, ...submenuActions);\n\t\t}\n\t}\n}\n\nexport interface IMenuEntryActionViewItemOptions {\n\treadonly draggable?: boolean;\n\treadonly keybinding?: string | null;\n\treadonly hoverDelegate?: IHoverDelegate;\n\treadonly keybindingNotRenderedWithLabel?: boolean;\n}\n\nexport class MenuEntryActionViewItem<T extends IMenuEntryActionViewItemOptions = IMenuEntryActionViewItemOptions> extends ActionViewItem {\n\n\tprivate _wantsAltCommand: boolean = false;\n\tprivate readonly _itemClassDispose = this._register(new MutableDisposable());\n\tprivate readonly _altKey: ModifierKeyEmitter;\n\n\tconstructor(\n\t\taction: MenuItemAction,\n\t\tprotected readonly _options: T | undefined,\n\t\t@IKeybindingService protected readonly _keybindingService: IKeybindingService,\n\t\t@INotificationService protected readonly _notificationService: INotificationService,\n\t\t@IContextKeyService protected readonly _contextKeyService: IContextKeyService,\n\t\t@IThemeService protected readonly _themeService: IThemeService,\n\t\t@IContextMenuService protected readonly _contextMenuService: IContextMenuService,\n\t\t@IAccessibilityService private readonly _accessibilityService: IAccessibilityService\n\t) {\n\t\tsuper(undefined, action, { icon: !!(action.class || action.item.icon), label: !action.class && !action.item.icon, draggable: _options?.draggable, keybinding: _options?.keybinding, hoverDelegate: _options?.hoverDelegate, keybindingNotRenderedWithLabel: _options?.keybindingNotRenderedWithLabel });\n\t\tthis._altKey = ModifierKeyEmitter.getInstance();\n\t}\n\n\tprotected get _menuItemAction(): MenuItemAction {\n\t\treturn <MenuItemAction>this._action;\n\t}\n\n\tprotected get _commandAction(): MenuItemAction {\n\t\treturn this._wantsAltCommand && this._menuItemAction.alt || this._menuItemAction;\n\t}\n\n\toverride async onClick(event: MouseEvent): Promise<void> {\n\t\tevent.preventDefault();\n\t\tevent.stopPropagation();\n\n\t\ttry {\n\t\t\tawait this.actionRunner.run(this._commandAction, this._context);\n\t\t} catch (err) {\n\t\t\tthis._notificationService.error(err);\n\t\t}\n\t}\n\n\toverride render(container: HTMLElement): void {\n\t\tsuper.render(container);\n\t\tcontainer.classList.add('menu-entry');\n\n\t\tif (this.options.icon) {\n\t\t\tthis._updateItemClass(this._menuItemAction.item);\n\t\t}\n\n\t\tif (this._menuItemAction.alt) {\n\t\t\tlet isMouseOver = false;\n\n\t\t\tconst updateAltState = () => {\n\t\t\t\tconst wantsAltCommand = !!this._menuItemAction.alt?.enabled &&\n\t\t\t\t\t(!this._accessibilityService.isMotionReduced() || isMouseOver) && (\n\t\t\t\t\t\tthis._altKey.keyStatus.altKey ||\n\t\t\t\t\t\t(this._altKey.keyStatus.shiftKey && isMouseOver)\n\t\t\t\t\t);\n\n\t\t\t\tif (wantsAltCommand !== this._wantsAltCommand) {\n\t\t\t\t\tthis._wantsAltCommand = wantsAltCommand;\n\t\t\t\t\tthis.updateLabel();\n\t\t\t\t\tthis.updateTooltip();\n\t\t\t\t\tthis.updateClass();\n\t\t\t\t}\n\t\t\t};\n\n\t\t\tthis._register(this._altKey.event(updateAltState));\n\n\t\t\tthis._register(addDisposableListener(container, 'mouseleave', _ => {\n\t\t\t\tisMouseOver = false;\n\t\t\t\tupdateAltState();\n\t\t\t}));\n\n\t\t\tthis._register(addDisposableListener(container, 'mouseenter', _ => {\n\t\t\t\tisMouseOver = true;\n\t\t\t\tupdateAltState();\n\t\t\t}));\n\n\t\t\tupdateAltState();\n\t\t}\n\t}\n\n\tprotected override updateLabel(): void {\n\t\tif (this.options.label && this.label) {\n\t\t\tthis.label.textContent = this._commandAction.label;\n\t\t}\n\t}\n\n\tprotected override getTooltip() {\n\t\tconst tooltip = this._commandAction.tooltip || this._commandAction.label;\n\t\tlet title = this._keybindingService.appendKeybinding(tooltip, this._commandAction.id, this._contextKeyService);\n\t\tif (!this._wantsAltCommand && this._menuItemAction.alt?.enabled) {\n\t\t\tconst altTooltip = this._menuItemAction.alt.tooltip || this._menuItemAction.alt.label;\n\t\t\tconst altTitleSection = this._keybindingService.appendKeybinding(altTooltip, this._menuItemAction.alt.id, this._contextKeyService);\n\n\t\t\ttitle = localize('titleAndKbAndAlt', \"{0}\\n[{1}] {2}\", title, UILabelProvider.modifierLabels[OS].altKey, altTitleSection);\n\t\t}\n\t\treturn title;\n\t}\n\n\tprotected override updateClass(): void {\n\t\tif (this.options.icon) {\n\t\t\tif (this._commandAction !== this._menuItemAction) {\n\t\t\t\tif (this._menuItemAction.alt) {\n\t\t\t\t\tthis._updateItemClass(this._menuItemAction.alt.item);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tthis._updateItemClass(this._menuItemAction.item);\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate _updateItemClass(item: ICommandAction): void {\n\t\tthis._itemClassDispose.value = undefined;\n\n\t\tconst { element, label } = this;\n\t\tif (!element || !label) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst icon = this._commandAction.checked && isICommandActionToggleInfo(item.toggled) && item.toggled.icon ? item.toggled.icon : item.icon;\n\n\t\tif (!icon) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (ThemeIcon.isThemeIcon(icon)) {\n\t\t\t// theme icons\n\t\t\tconst iconClasses = ThemeIcon.asClassNameArray(icon);\n\t\t\tlabel.classList.add(...iconClasses);\n\t\t\tthis._itemClassDispose.value = toDisposable(() => {\n\t\t\t\tlabel.classList.remove(...iconClasses);\n\t\t\t});\n\n\t\t} else {\n\t\t\t// icon path/url\n\t\t\tlabel.style.backgroundImage = (\n\t\t\t\tisDark(this._themeService.getColorTheme().type)\n\t\t\t\t\t? asCSSUrl(icon.dark)\n\t\t\t\t\t: asCSSUrl(icon.light)\n\t\t\t);\n\t\t\tlabel.classList.add('icon');\n\t\t\tthis._itemClassDispose.value = combinedDisposable(\n\t\t\t\ttoDisposable(() => {\n\t\t\t\t\tlabel.style.backgroundImage = '';\n\t\t\t\t\tlabel.classList.remove('icon');\n\t\t\t\t}),\n\t\t\t\tthis._themeService.onDidColorThemeChange(() => {\n\t\t\t\t\t// refresh when the theme changes in case we go between dark <-> light\n\t\t\t\t\tthis.updateClass();\n\t\t\t\t})\n\t\t\t);\n\t\t}\n\t}\n}\n\nexport interface ITextOnlyMenuEntryActionViewItemOptions extends IMenuEntryActionViewItemOptions {\n\treadonly conversational?: boolean;\n\treadonly useComma?: boolean;\n}\n\nexport class TextOnlyMenuEntryActionViewItem extends MenuEntryActionViewItem<ITextOnlyMenuEntryActionViewItemOptions> {\n\n\toverride render(container: HTMLElement): void {\n\t\tthis.options.label = true;\n\t\tthis.options.icon = false;\n\t\tsuper.render(container);\n\t\tcontainer.classList.add('text-only');\n\t\tcontainer.classList.toggle('use-comma', this._options?.useComma ?? false);\n\t}\n\n\tprotected override updateLabel() {\n\t\tconst kb = this._keybindingService.lookupKeybinding(this._action.id, this._contextKeyService);\n\t\tif (!kb) {\n\t\t\treturn super.updateLabel();\n\t\t}\n\t\tif (this.label) {\n\t\t\tconst kb2 = TextOnlyMenuEntryActionViewItem._symbolPrintEnter(kb);\n\n\t\t\tif (this._options?.conversational) {\n\t\t\t\tthis.label.textContent = localize({ key: 'content2', comment: ['A label with keybindg like \"ESC to dismiss\"'] }, '{1} to {0}', this._action.label, kb2);\n\n\t\t\t} else {\n\t\t\t\tthis.label.textContent = localize({ key: 'content', comment: ['A label', 'A keybinding'] }, '{0} ({1})', this._action.label, kb2);\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate static _symbolPrintEnter(kb: ResolvedKeybinding) {\n\t\treturn kb.getLabel()\n\t\t\t?.replace(/\\benter\\b/gi, '\\u23CE')\n\t\t\t.replace(/\\bEscape\\b/gi, 'Esc');\n\t}\n}\n\nexport class SubmenuEntryActionViewItem extends DropdownMenuActionViewItem {\n\n\tconstructor(\n\t\taction: SubmenuItemAction,\n\t\toptions: IDropdownMenuActionViewItemOptions | undefined,\n\t\t@IKeybindingService protected _keybindingService: IKeybindingService,\n\t\t@IContextMenuService protected _contextMenuService: IContextMenuService,\n\t\t@IThemeService protected _themeService: IThemeService\n\t) {\n\t\tconst dropdownOptions: IDropdownMenuActionViewItemOptions = {\n\t\t\t...options,\n\t\t\tmenuAsChild: options?.menuAsChild ?? false,\n\t\t\tclassNames: options?.classNames ?? (ThemeIcon.isThemeIcon(action.item.icon) ? ThemeIcon.asClassName(action.item.icon) : undefined),\n\t\t\tkeybindingProvider: options?.keybindingProvider ?? (action => _keybindingService.lookupKeybinding(action.id))\n\t\t};\n\n\t\tsuper(action, { getActions: () => action.actions }, _contextMenuService, dropdownOptions);\n\t}\n\n\toverride render(container: HTMLElement): void {\n\t\tsuper.render(container);\n\t\tassertType(this.element);\n\n\t\tcontainer.classList.add('menu-entry');\n\t\tconst action = <SubmenuItemAction>this._action;\n\t\tconst { icon } = action.item;\n\t\tif (icon && !ThemeIcon.isThemeIcon(icon)) {\n\t\t\tthis.element.classList.add('icon');\n\t\t\tconst setBackgroundImage = () => {\n\t\t\t\tif (this.element) {\n\t\t\t\t\tthis.element.style.backgroundImage = (\n\t\t\t\t\t\tisDark(this._themeService.getColorTheme().type)\n\t\t\t\t\t\t\t? asCSSUrl(icon.dark)\n\t\t\t\t\t\t\t: asCSSUrl(icon.light)\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t};\n\t\t\tsetBackgroundImage();\n\t\t\tthis._register(this._themeService.onDidColorThemeChange(() => {\n\t\t\t\t// refresh when the theme changes in case we go between dark <-> light\n\t\t\t\tsetBackgroundImage();\n\t\t\t}));\n\t\t}\n\t}\n}\n\nexport interface IDropdownWithDefaultActionViewItemOptions extends IDropdownMenuActionViewItemOptions {\n\trenderKeybindingWithDefaultActionLabel?: boolean;\n\ttogglePrimaryAction?: boolean;\n}\n\nexport class DropdownWithDefaultActionViewItem extends BaseActionViewItem {\n\tprivate readonly _options: IDropdownWithDefaultActionViewItemOptions | undefined;\n\tprivate _defaultAction: ActionViewItem;\n\tprivate readonly _defaultActionDisposables = this._register(new DisposableStore());\n\tprivate readonly _dropdown: DropdownMenuActionViewItem;\n\tprivate _container: HTMLElement | null = null;\n\tprivate readonly _storageKey: string;\n\tprivate readonly _primaryActionListener = this._register(new MutableDisposable());\n\n\tconstructor(\n\t\tsubmenuAction: SubmenuItemAction,\n\t\toptions: IDropdownWithDefaultActionViewItemOptions | undefined,\n\t\t@IKeybindingService protected readonly _keybindingService: IKeybindingService,\n\t\t@INotificationService protected _notificationService: INotificationService,\n\t\t@IContextMenuService protected _contextMenuService: IContextMenuService,\n\t\t@IMenuService protected _menuService: IMenuService,\n\t\t@IInstantiationService protected _instaService: IInstantiationService,\n\t\t@IStorageService protected _storageService: IStorageService\n\t) {\n\t\tsuper(null, submenuAction);\n\t\tthis._options = options;\n\t\tthis._storageKey = `${submenuAction.item.submenu.id}_lastActionId`;\n\n\t\t// determine default action\n\t\tlet defaultAction: IAction | undefined;\n\t\tconst defaultActionId = options?.togglePrimaryAction ? _storageService.get(this._storageKey, StorageScope.WORKSPACE) : undefined;\n\t\tif (defaultActionId) {\n\t\t\tdefaultAction = submenuAction.actions.find(a => defaultActionId === a.id);\n\t\t}\n\t\tif (!defaultAction) {\n\t\t\tdefaultAction = submenuAction.actions[0];\n\t\t}\n\n\t\tthis._defaultAction = this._defaultActionDisposables.add(this._instaService.createInstance(MenuEntryActionViewItem, <MenuItemAction>defaultAction, { keybinding: this._getDefaultActionKeybindingLabel(defaultAction) }));\n\n\t\tconst dropdownOptions: IDropdownMenuActionViewItemOptions = {\n\t\t\tkeybindingProvider: action => this._keybindingService.lookupKeybinding(action.id),\n\t\t\t...options,\n\t\t\tmenuAsChild: options?.menuAsChild ?? true,\n\t\t\tclassNames: options?.classNames ?? ['codicon', 'codicon-chevron-down'],\n\t\t\tactionRunner: options?.actionRunner ?? this._register(new ActionRunner()),\n\t\t};\n\n\t\tthis._dropdown = this._register(new DropdownMenuActionViewItem(submenuAction, submenuAction.actions, this._contextMenuService, dropdownOptions));\n\t\tif (options?.togglePrimaryAction) {\n\t\t\tthis.registerTogglePrimaryActionListener();\n\t\t}\n\t}\n\n\tprivate registerTogglePrimaryActionListener(): void {\n\t\tthis._primaryActionListener.value = this._dropdown.actionRunner.onDidRun((e: IRunEvent) => {\n\t\t\tif (e.action instanceof MenuItemAction) {\n\t\t\t\tthis.update(e.action);\n\t\t\t}\n\t\t});\n\t}\n\n\tprivate update(lastAction: MenuItemAction): void {\n\t\tif (this._options?.togglePrimaryAction) {\n\t\t\tthis._storageService.store(this._storageKey, lastAction.id, StorageScope.WORKSPACE, StorageTarget.MACHINE);\n\t\t}\n\n\t\tthis._defaultActionDisposables.clear();\n\t\tthis._defaultAction = this._defaultActionDisposables.add(this._instaService.createInstance(MenuEntryActionViewItem, lastAction, { keybinding: this._getDefaultActionKeybindingLabel(lastAction) }));\n\t\tthis._defaultAction.actionRunner = this._defaultActionDisposables.add(new class extends ActionRunner {\n\t\t\tprotected override async runAction(action: IAction, context?: unknown): Promise<void> {\n\t\t\t\tawait action.run(undefined);\n\t\t\t}\n\t\t}());\n\n\t\tif (this._container) {\n\t\t\tthis._defaultAction.render(prepend(this._container, $('.action-container')));\n\t\t}\n\t}\n\n\tprivate _getDefaultActionKeybindingLabel(defaultAction: IAction) {\n\t\tlet defaultActionKeybinding: string | undefined;\n\t\tif (this._options?.renderKeybindingWithDefaultActionLabel) {\n\t\t\tconst kb = this._keybindingService.lookupKeybinding(defaultAction.id);\n\t\t\tif (kb) {\n\t\t\t\tdefaultActionKeybinding = `(${kb.getLabel()})`;\n\t\t\t}\n\t\t}\n\t\treturn defaultActionKeybinding;\n\t}\n\n\toverride setActionContext(newContext: unknown): void {\n\t\tsuper.setActionContext(newContext);\n\t\tthis._defaultAction.setActionContext(newContext);\n\t\tthis._dropdown.setActionContext(newContext);\n\t}\n\n\toverride set actionRunner(actionRunner: IActionRunner) {\n\t\tsuper.actionRunner = actionRunner;\n\n\t\tthis._defaultAction.actionRunner = actionRunner;\n\t\tthis._dropdown.actionRunner = actionRunner;\n\t\tif (this._primaryActionListener.value) {\n\t\t\tthis.registerTogglePrimaryActionListener();\n\t\t}\n\t}\n\n\toverride get actionRunner(): IActionRunner {\n\t\treturn super.actionRunner;\n\t}\n\n\toverride render(container: HTMLElement): void {\n\t\tthis._container = container;\n\t\tsuper.render(this._container);\n\n\t\tthis._container.classList.add('monaco-dropdown-with-default');\n\n\t\tconst primaryContainer = $('.action-container');\n\t\tthis._defaultAction.render(append(this._container, primaryContainer));\n\t\tthis._register(addDisposableListener(primaryContainer, EventType.KEY_DOWN, (e: KeyboardEvent) => {\n\t\t\tconst event = new StandardKeyboardEvent(e);\n\t\t\tif (event.equals(KeyCode.RightArrow)) {\n\t\t\t\tthis._defaultAction.element!.tabIndex = -1;\n\t\t\t\tthis._dropdown.focus();\n\t\t\t\tevent.stopPropagation();\n\t\t\t}\n\t\t}));\n\n\t\tconst dropdownContainer = $('.dropdown-action-container');\n\t\tthis._dropdown.render(append(this._container, dropdownContainer));\n\t\tthis._register(addDisposableListener(dropdownContainer, EventType.KEY_DOWN, (e: KeyboardEvent) => {\n\t\t\tconst event = new StandardKeyboardEvent(e);\n\t\t\tif (event.equals(KeyCode.LeftArrow)) {\n\t\t\t\tthis._defaultAction.element!.tabIndex = 0;\n\t\t\t\tthis._dropdown.setFocusable(false);\n\t\t\t\tthis._defaultAction.element?.focus();\n\t\t\t\tevent.stopPropagation();\n\t\t\t}\n\t\t}));\n\t}\n\n\toverride focus(fromRight?: boolean): void {\n\t\tif (fromRight) {\n\t\t\tthis._dropdown.focus();\n\t\t} else {\n\t\t\tthis._defaultAction.element!.tabIndex = 0;\n\t\t\tthis._defaultAction.element!.focus();\n\t\t}\n\t}\n\n\toverride blur(): void {\n\t\tthis._defaultAction.element!.tabIndex = -1;\n\t\tthis._dropdown.blur();\n\t\tthis._container!.blur();\n\t}\n\n\toverride setFocusable(focusable: boolean): void {\n\t\tif (focusable) {\n\t\t\tthis._defaultAction.element!.tabIndex = 0;\n\t\t} else {\n\t\t\tthis._defaultAction.element!.tabIndex = -1;\n\t\t\tthis._dropdown.setFocusable(false);\n\t\t}\n\t}\n}\n\nclass SubmenuEntrySelectActionViewItem extends SelectActionViewItem {\n\n\tconstructor(\n\t\taction: SubmenuItemAction,\n\t\t@IContextViewService contextViewService: IContextViewService,\n\t\t@IConfigurationService configurationService: IConfigurationService,\n\t) {\n\t\tsuper(null, action, action.actions.map(a => (a.id === Separator.ID ? SeparatorSelectOption : { text: a.label, isDisabled: !a.enabled, })), 0, contextViewService, defaultSelectBoxStyles, { ariaLabel: action.tooltip || action.label, optionsAsChildren: true, useCustomDrawn: !hasNativeContextMenu(configurationService) });\n\t\tthis.select(Math.max(0, action.actions.findIndex(a => a.checked)));\n\t}\n\n\toverride render(container: HTMLElement): void {\n\t\tsuper.render(container);\n\t\tcontainer.style.borderColor = asCssVariable(selectBorder);\n\t}\n\n\tprotected override runAction(option: string, index: number): void {\n\t\tconst action = (this.action as SubmenuItemAction).actions[index];\n\t\tif (action) {\n\t\t\tthis.actionRunner.run(action);\n\t\t}\n\t}\n\n}\n\n/**\n * Creates action view items for menu actions or submenu actions.\n */\nexport function createActionViewItem(instaService: IInstantiationService, action: IAction, options: IDropdownMenuActionViewItemOptions | IMenuEntryActionViewItemOptions | undefined): undefined | MenuEntryActionViewItem | SubmenuEntryActionViewItem | BaseActionViewItem {\n\tif (action instanceof MenuItemAction) {\n\t\treturn instaService.createInstance(MenuEntryActionViewItem, action, options);\n\t} else if (action instanceof SubmenuItemAction) {\n\t\tif (action.item.isSelection) {\n\t\t\treturn instaService.createInstance(SubmenuEntrySelectActionViewItem, action);\n\t\t} else if (action.item.isSplitButton) {\n\t\t\treturn instaService.createInstance(DropdownWithDefaultActionViewItem, action, {\n\t\t\t\t...options,\n\t\t\t\ttogglePrimaryAction: typeof action.item.isSplitButton !== 'boolean' ? action.item.isSplitButton.togglePrimaryAction : false,\n\t\t\t});\n\t\t} else {\n\t\t\treturn instaService.createInstance(SubmenuEntryActionViewItem, action, options);\n\t\t}\n\t} else {\n\t\treturn undefined;\n\t}\n}\n"]}
@@ -214,6 +214,7 @@ export class MenuId {
214
214
  static { this.ChatWelcomeContext = new MenuId('ChatWelcomeContext'); }
215
215
  static { this.ChatMessageFooter = new MenuId('ChatMessageFooter'); }
216
216
  static { this.ChatExecute = new MenuId('ChatExecute'); }
217
+ static { this.ChatExecuteQueue = new MenuId('ChatExecuteQueue'); }
217
218
  static { this.ChatInput = new MenuId('ChatInput'); }
218
219
  static { this.ChatInputSide = new MenuId('ChatInputSide'); }
219
220
  static { this.ChatModePicker = new MenuId('ChatModePicker'); }
@@ -425,7 +426,10 @@ let MenuItemAction = MenuItemAction_1 = class MenuItemAction {
425
426
  }
426
427
  run(...args) {
427
428
  let runArgs = [];
428
- if (this._options?.arg) {
429
+ if (this._options?.args) {
430
+ runArgs = [...runArgs, ...this._options.args];
431
+ }
432
+ else if (this._options?.arg) {
429
433
  runArgs = [...runArgs, this._options.arg];
430
434
  }
431
435
  if (this._options?.shouldForwardArgs) {
@@ -1 +1 @@
1
- {"version":3,"sources":["file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src/vs/platform/actions/common/actions.ts","vs/platform/actions/common/actions.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;;;;;;;;;;;AAEhG,OAAO,EAAW,aAAa,EAAE,MAAM,iCAAiC,CAAC;AACzE,OAAO,EAAS,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AACxE,OAAO,EAAE,eAAe,EAAE,OAAO,EAAe,eAAe,EAAE,YAAY,EAAE,MAAM,mCAAmC,CAAC;AACzH,OAAO,EAAE,UAAU,EAAE,MAAM,oCAAoC,CAAC;AAChE,OAAO,EAAE,SAAS,EAAE,MAAM,mCAAmC,CAAC;AAG9D,OAAO,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AACtF,OAAO,EAAE,cAAc,EAAwB,kBAAkB,EAAE,MAAM,uCAAuC,CAAC;AACjH,OAAO,EAAE,eAAe,EAAoB,MAAM,6CAA6C,CAAC;AAChG,OAAO,EAAmB,mBAAmB,EAAE,MAAM,gDAAgD,CAAC;AAyCtG,MAAM,UAAU,WAAW,CAAC,IAAa;IACxC,OAAQ,IAAkB,CAAC,OAAO,KAAK,SAAS,CAAC;AAClD,CAAC;AAED,MAAM,UAAU,cAAc,CAAC,IAAa;IAC3C,OAAQ,IAAqB,CAAC,OAAO,KAAK,SAAS,CAAC;AACrD,CAAC;AAED,MAAM,OAAO,MAAM;aAEM,eAAU,GAAG,IAAI,GAAG,EAAkB,CAAC;aAE/C,mBAAc,GAAG,IAAI,MAAM,CAAC,gBAAgB,CAAC,CAAC;aAC9C,4BAAuB,GAAG,IAAI,MAAM,CAAC,yBAAyB,CAAC,CAAC;aAChE,0BAAqB,GAAG,IAAI,MAAM,CAAC,uBAAuB,CAAC,CAAC;aAC5D,wBAAmB,GAAG,IAAI,MAAM,CAAC,qB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E,CAAC;QAC/B,KAAK,MAAM,IAAI,IAAI,UAAU,EAAE,CAAC;YAC/B,WAAW,CAAC,IAAI,CAAC,mBAAmB,CAAC,sBAAsB,CAAC;gBAC3D,GAAG,IAAI;gBACP,EAAE,EAAE,OAAO,CAAC,EAAE;gBACd,IAAI,EAAE,OAAO,CAAC,YAAY,CAAC,CAAC,CAAC,cAAc,CAAC,GAAG,CAAC,OAAO,CAAC,YAAY,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI;aAC5F,CAAC,CAAC,CAAC;QACL,CAAC;IACF,CAAC;SAAM,IAAI,UAAU,EAAE,CAAC;QACvB,WAAW,CAAC,IAAI,CAAC,mBAAmB,CAAC,sBAAsB,CAAC;YAC3D,GAAG,UAAU;YACb,EAAE,EAAE,OAAO,CAAC,EAAE;YACd,IAAI,EAAE,OAAO,CAAC,YAAY,CAAC,CAAC,CAAC,cAAc,CAAC,GAAG,CAAC,OAAO,CAAC,YAAY,EAAE,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,IAAI;SACxG,CAAC,CAAC,CAAC;IACL,CAAC;IAED,OAAO;QACN,OAAO;YACN,OAAO,CAAC,WAAW,CAAC,CAAC;QACtB,CAAC;KACD,CAAC;AACH,CAAC;AACD,YAAY","file":"actions.js","sourceRoot":"file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport { IAction, SubmenuAction } from '../../../base/common/actions.js';\nimport { Event, MicrotaskEmitter } from '../../../base/common/event.js';\nimport { DisposableStore, dispose, IDisposable, markAsSingleton, toDisposable } from '../../../base/common/lifecycle.js';\nimport { LinkedList } from '../../../base/common/linkedList.js';\nimport { ThemeIcon } from '../../../base/common/themables.js';\nimport { ICommandAction, ICommandActionTitle, Icon, ILocalizedString } from '../../action/common/action.js';\nimport { Categories } from '../../action/common/actionCommonCategories.js';\nimport { CommandsRegistry, ICommandService } from '../../commands/common/commands.js';\nimport { ContextKeyExpr, ContextKeyExpression, IContextKeyService } from '../../contextkey/common/contextkey.js';\nimport { createDecorator, ServicesAccessor } from '../../instantiation/common/instantiation.js';\nimport { IKeybindingRule, KeybindingsRegistry } from '../../keybinding/common/keybindingsRegistry.js';\n\nexport interface IMenuItem {\n\tcommand: ICommandAction;\n\talt?: ICommandAction;\n\t/**\n\t * Menu item is hidden if this expression returns false.\n\t */\n\twhen?: ContextKeyExpression;\n\tgroup?: 'navigation' | string;\n\torder?: number;\n\tisHiddenByDefault?: boolean;\n}\n\nexport interface ISubmenuItem {\n\ttitle: string | ICommandActionTitle;\n\tsubmenu: MenuId;\n\ticon?: Icon;\n\twhen?: ContextKeyExpression;\n\tgroup?: 'navigation' | string;\n\torder?: number;\n\tisSelection?: boolean;\n\t/**\n\t * A split button shows the first action\n\t * as primary action and the rest of the\n\t * actions in a dropdown.\n\t *\n\t * Use `togglePrimaryAction` to promote\n\t * the action that was last used to be\n\t * the primary action and remember that\n\t * choice.\n\t */\n\tisSplitButton?: boolean | {\n\t\t/**\n\t\t * Will update the primary action based\n\t\t * on the action that was last run.\n\t\t */\n\t\ttogglePrimaryAction: true;\n\t};\n}\n\nexport function isIMenuItem(item: unknown): item is IMenuItem {\n\treturn (item as IMenuItem).command !== undefined;\n}\n\nexport function isISubmenuItem(item: unknown): item is ISubmenuItem {\n\treturn (item as ISubmenuItem).submenu !== undefined;\n}\n\nexport class MenuId {\n\n\tprivate static readonly _instances = new Map<string, MenuId>();\n\n\tstatic readonly CommandPalette = new MenuId('CommandPalette');\n\tstatic readonly DebugBreakpointsContext = new MenuId('DebugBreakpointsContext');\n\tstatic readonly DebugCallStackContext = new MenuId('DebugCallStackContext');\n\tstatic readonly DebugConsoleContext = new MenuId('DebugConsoleContext');\n\tstatic readonly DebugVariablesContext = new MenuId('DebugVariablesContext');\n\tstatic readonly NotebookVariablesContext = new MenuId('NotebookVariablesContext');\n\tstatic readonly DebugHoverContext = new MenuId('DebugHoverContext');\n\tstatic readonly DebugWatchContext = new MenuId('DebugWatchContext');\n\tstatic readonly DebugToolBar = new MenuId('DebugToolBar');\n\tstatic readonly DebugToolBarStop = new MenuId('DebugToolBarStop');\n\tstatic readonly DebugDisassemblyContext = new MenuId('DebugDisassemblyContext');\n\tstatic readonly DebugCallStackToolbar = new MenuId('DebugCallStackToolbar');\n\tstatic readonly DebugCreateConfiguration = new MenuId('DebugCreateConfiguration');\n\tstatic readonly DebugScopesContext = new MenuId('DebugScopesContext');\n\tstatic readonly EditorContext = new MenuId('EditorContext');\n\tstatic readonly SimpleEditorContext = new MenuId('SimpleEditorContext');\n\tstatic readonly EditorContent = new MenuId('EditorContent');\n\tstatic readonly EditorLineNumberContext = new MenuId('EditorLineNumberContext');\n\tstatic readonly EditorContextCopy = new MenuId('EditorContextCopy');\n\tstatic readonly EditorContextPeek = new MenuId('EditorContextPeek');\n\tstatic readonly EditorContextShare = new MenuId('EditorContextShare');\n\tstatic readonly EditorTitle = new MenuId('EditorTitle');\n\tstatic readonly CompactWindowEditorTitle = new MenuId('CompactWindowEditorTitle');\n\tstatic readonly EditorTitleRun = new MenuId('EditorTitleRun');\n\tstatic readonly EditorTitleContext = new MenuId('EditorTitleContext');\n\tstatic readonly EditorTitleContextShare = new MenuId('EditorTitleContextShare');\n\tstatic readonly EmptyEditorGroup = new MenuId('EmptyEditorGroup');\n\tstatic readonly EmptyEditorGroupContext = new MenuId('EmptyEditorGroupContext');\n\tstatic readonly EditorTabsBarContext = new MenuId('EditorTabsBarContext');\n\tstatic readonly EditorTabsBarShowTabsSubmenu = new MenuId('EditorTabsBarShowTabsSubmenu');\n\tstatic readonly EditorTabsBarShowTabsZenModeSubmenu = new MenuId('EditorTabsBarShowTabsZenModeSubmenu');\n\tstatic readonly EditorActionsPositionSubmenu = new MenuId('EditorActionsPositionSubmenu');\n\tstatic readonly EditorSplitMoveSubmenu = new MenuId('EditorSplitMoveSubmenu');\n\tstatic readonly ExplorerContext = new MenuId('ExplorerContext');\n\tstatic readonly ExplorerContextShare = new MenuId('ExplorerContextShare');\n\tstatic readonly ExtensionContext = new MenuId('ExtensionContext');\n\tstatic readonly ExtensionEditorContextMenu = new MenuId('ExtensionEditorContextMenu');\n\tstatic readonly GlobalActivity = new MenuId('GlobalActivity');\n\tstatic readonly CommandCenter = new MenuId('CommandCenter');\n\tstatic readonly CommandCenterCenter = new MenuId('CommandCenterCenter');\n\tstatic readonly LayoutControlMenuSubmenu = new MenuId('LayoutControlMenuSubmenu');\n\tstatic readonly LayoutControlMenu = new MenuId('LayoutControlMenu');\n\tstatic readonly MenubarMainMenu = new MenuId('MenubarMainMenu');\n\tstatic readonly MenubarAppearanceMenu = new MenuId('MenubarAppearanceMenu');\n\tstatic readonly MenubarDebugMenu = new MenuId('MenubarDebugMenu');\n\tstatic readonly MenubarEditMenu = new MenuId('MenubarEditMenu');\n\tstatic readonly MenubarCopy = new MenuId('MenubarCopy');\n\tstatic readonly MenubarFileMenu = new MenuId('MenubarFileMenu');\n\tstatic readonly MenubarGoMenu = new MenuId('MenubarGoMenu');\n\tstatic readonly MenubarHelpMenu = new MenuId('MenubarHelpMenu');\n\tstatic readonly MenubarLayoutMenu = new MenuId('MenubarLayoutMenu');\n\tstatic readonly MenubarNewBreakpointMenu = new MenuId('MenubarNewBreakpointMenu');\n\tstatic readonly PanelAlignmentMenu = new MenuId('PanelAlignmentMenu');\n\tstatic readonly PanelPositionMenu = new MenuId('PanelPositionMenu');\n\tstatic readonly ActivityBarPositionMenu = new MenuId('ActivityBarPositionMenu');\n\tstatic readonly MenubarPreferencesMenu = new MenuId('MenubarPreferencesMenu');\n\tstatic readonly MenubarRecentMenu = new MenuId('MenubarRecentMenu');\n\tstatic readonly MenubarSelectionMenu = new MenuId('MenubarSelectionMenu');\n\tstatic readonly MenubarShare = new MenuId('MenubarShare');\n\tstatic readonly MenubarSwitchEditorMenu = new MenuId('MenubarSwitchEditorMenu');\n\tstatic readonly MenubarSwitchGroupMenu = new MenuId('MenubarSwitchGroupMenu');\n\tstatic readonly MenubarTerminalMenu = new MenuId('MenubarTerminalMenu');\n\tstatic readonly MenubarTerminalSuggestStatusMenu = new MenuId('MenubarTerminalSuggestStatusMenu');\n\tstatic readonly MenubarViewMenu = new MenuId('MenubarViewMenu');\n\tstatic readonly MenubarHomeMenu = new MenuId('MenubarHomeMenu');\n\tstatic readonly OpenEditorsContext = new MenuId('OpenEditorsContext');\n\tstatic readonly OpenEditorsContextShare = new MenuId('OpenEditorsContextShare');\n\tstatic readonly ProblemsPanelContext = new MenuId('ProblemsPanelContext');\n\tstatic readonly SCMInputBox = new MenuId('SCMInputBox');\n\tstatic readonly SCMChangeContext = new MenuId('SCMChangeContext');\n\tstatic readonly SCMResourceContext = new MenuId('SCMResourceContext');\n\tstatic readonly SCMResourceContextShare = new MenuId('SCMResourceContextShare');\n\tstatic readonly SCMResourceFolderContext = new MenuId('SCMResourceFolderContext');\n\tstatic readonly SCMResourceGroupContext = new MenuId('SCMResourceGroupContext');\n\tstatic readonly SCMSourceControl = new MenuId('SCMSourceControl');\n\tstatic readonly SCMSourceControlInline = new MenuId('SCMSourceControlInline');\n\tstatic readonly SCMSourceControlTitle = new MenuId('SCMSourceControlTitle');\n\tstatic readonly SCMHistoryTitle = new MenuId('SCMHistoryTitle');\n\tstatic readonly SCMHistoryItemContext = new MenuId('SCMHistoryItemContext');\n\tstatic readonly SCMHistoryItemChangeContext = new MenuId('SCMHistoryItemChangeContext');\n\tstatic readonly SCMHistoryItemRefContext = new MenuId('SCMHistoryItemRefContext');\n\tstatic readonly SCMArtifactGroupContext = new MenuId('SCMArtifactGroupContext');\n\tstatic readonly SCMArtifactContext = new MenuId('SCMArtifactContext');\n\tstatic readonly SCMQuickDiffDecorations = new MenuId('SCMQuickDiffDecorations');\n\tstatic readonly SCMTitle = new MenuId('SCMTitle');\n\tstatic readonly SearchContext = new MenuId('SearchContext');\n\tstatic readonly SearchActionMenu = new MenuId('SearchActionContext');\n\tstatic readonly StatusBarWindowIndicatorMenu = new MenuId('StatusBarWindowIndicatorMenu');\n\tstatic readonly StatusBarRemoteIndicatorMenu = new MenuId('StatusBarRemoteIndicatorMenu');\n\tstatic readonly StickyScrollContext = new MenuId('StickyScrollContext');\n\tstatic readonly TestItem = new MenuId('TestItem');\n\tstatic readonly TestItemGutter = new MenuId('TestItemGutter');\n\tstatic readonly TestProfilesContext = new MenuId('TestProfilesContext');\n\tstatic readonly TestMessageContext = new MenuId('TestMessageContext');\n\tstatic readonly TestMessageContent = new MenuId('TestMessageContent');\n\tstatic readonly TestPeekElement = new MenuId('TestPeekElement');\n\tstatic readonly TestPeekTitle = new MenuId('TestPeekTitle');\n\tstatic readonly TestCallStack = new MenuId('TestCallStack');\n\tstatic readonly TestCoverageFilterItem = new MenuId('TestCoverageFilterItem');\n\tstatic readonly TouchBarContext = new MenuId('TouchBarContext');\n\tstatic readonly TitleBar = new MenuId('TitleBar');\n\tstatic readonly TitleBarContext = new MenuId('TitleBarContext');\n\tstatic readonly TitleBarTitleContext = new MenuId('TitleBarTitleContext');\n\tstatic readonly TunnelContext = new MenuId('TunnelContext');\n\tstatic readonly TunnelPrivacy = new MenuId('TunnelPrivacy');\n\tstatic readonly TunnelProtocol = new MenuId('TunnelProtocol');\n\tstatic readonly TunnelPortInline = new MenuId('TunnelInline');\n\tstatic readonly TunnelTitle = new MenuId('TunnelTitle');\n\tstatic readonly TunnelLocalAddressInline = new MenuId('TunnelLocalAddressInline');\n\tstatic readonly TunnelOriginInline = new MenuId('TunnelOriginInline');\n\tstatic readonly ViewItemContext = new MenuId('ViewItemContext');\n\tstatic readonly ViewContainerTitle = new MenuId('ViewContainerTitle');\n\tstatic readonly ViewContainerTitleContext = new MenuId('ViewContainerTitleContext');\n\tstatic readonly ViewTitle = new MenuId('ViewTitle');\n\tstatic readonly ViewTitleContext = new MenuId('ViewTitleContext');\n\tstatic readonly CommentEditorActions = new MenuId('CommentEditorActions');\n\tstatic readonly CommentThreadTitle = new MenuId('CommentThreadTitle');\n\tstatic readonly CommentThreadActions = new MenuId('CommentThreadActions');\n\tstatic readonly CommentThreadAdditionalActions = new MenuId('CommentThreadAdditionalActions');\n\tstatic readonly CommentThreadTitleContext = new MenuId('CommentThreadTitleContext');\n\tstatic readonly CommentThreadCommentContext = new MenuId('CommentThreadCommentContext');\n\tstatic readonly CommentTitle = new MenuId('CommentTitle');\n\tstatic readonly CommentActions = new MenuId('CommentActions');\n\tstatic readonly CommentsViewThreadActions = new MenuId('CommentsViewThreadActions');\n\tstatic readonly InteractiveToolbar = new MenuId('InteractiveToolbar');\n\tstatic readonly InteractiveCellTitle = new MenuId('InteractiveCellTitle');\n\tstatic readonly InteractiveCellDelete = new MenuId('InteractiveCellDelete');\n\tstatic readonly InteractiveCellExecute = new MenuId('InteractiveCellExecute');\n\tstatic readonly InteractiveInputExecute = new MenuId('InteractiveInputExecute');\n\tstatic readonly InteractiveInputConfig = new MenuId('InteractiveInputConfig');\n\tstatic readonly ReplInputExecute = new MenuId('ReplInputExecute');\n\tstatic readonly IssueReporter = new MenuId('IssueReporter');\n\tstatic readonly NotebookToolbar = new MenuId('NotebookToolbar');\n\tstatic readonly NotebookToolbarContext = new MenuId('NotebookToolbarContext');\n\tstatic readonly NotebookStickyScrollContext = new MenuId('NotebookStickyScrollContext');\n\tstatic readonly NotebookCellTitle = new MenuId('NotebookCellTitle');\n\tstatic readonly NotebookCellDelete = new MenuId('NotebookCellDelete');\n\tstatic readonly NotebookCellInsert = new MenuId('NotebookCellInsert');\n\tstatic readonly NotebookCellBetween = new MenuId('NotebookCellBetween');\n\tstatic readonly NotebookCellListTop = new MenuId('NotebookCellTop');\n\tstatic readonly NotebookCellExecute = new MenuId('NotebookCellExecute');\n\tstatic readonly NotebookCellExecuteGoTo = new MenuId('NotebookCellExecuteGoTo');\n\tstatic readonly NotebookCellExecutePrimary = new MenuId('NotebookCellExecutePrimary');\n\tstatic readonly NotebookDiffCellInputTitle = new MenuId('NotebookDiffCellInputTitle');\n\tstatic readonly NotebookDiffDocumentMetadata = new MenuId('NotebookDiffDocumentMetadata');\n\tstatic readonly NotebookDiffCellMetadataTitle = new MenuId('NotebookDiffCellMetadataTitle');\n\tstatic readonly NotebookDiffCellOutputsTitle = new MenuId('NotebookDiffCellOutputsTitle');\n\tstatic readonly NotebookOutputToolbar = new MenuId('NotebookOutputToolbar');\n\tstatic readonly NotebookOutlineFilter = new MenuId('NotebookOutlineFilter');\n\tstatic readonly NotebookOutlineActionMenu = new MenuId('NotebookOutlineActionMenu');\n\tstatic readonly NotebookEditorLayoutConfigure = new MenuId('NotebookEditorLayoutConfigure');\n\tstatic readonly NotebookKernelSource = new MenuId('NotebookKernelSource');\n\tstatic readonly BulkEditTitle = new MenuId('BulkEditTitle');\n\tstatic readonly BulkEditContext = new MenuId('BulkEditContext');\n\tstatic readonly TimelineItemContext = new MenuId('TimelineItemContext');\n\tstatic readonly TimelineTitle = new MenuId('TimelineTitle');\n\tstatic readonly TimelineTitleContext = new MenuId('TimelineTitleContext');\n\tstatic readonly TimelineFilterSubMenu = new MenuId('TimelineFilterSubMenu');\n\tstatic readonly AccountsContext = new MenuId('AccountsContext');\n\tstatic readonly SidebarTitle = new MenuId('SidebarTitle');\n\tstatic readonly PanelTitle = new MenuId('PanelTitle');\n\tstatic readonly AuxiliaryBarTitle = new MenuId('AuxiliaryBarTitle');\n\tstatic readonly TerminalInstanceContext = new MenuId('TerminalInstanceContext');\n\tstatic readonly TerminalEditorInstanceContext = new MenuId('TerminalEditorInstanceContext');\n\tstatic readonly TerminalNewDropdownContext = new MenuId('TerminalNewDropdownContext');\n\tstatic readonly TerminalTabContext = new MenuId('TerminalTabContext');\n\tstatic readonly TerminalTabEmptyAreaContext = new MenuId('TerminalTabEmptyAreaContext');\n\tstatic readonly TerminalStickyScrollContext = new MenuId('TerminalStickyScrollContext');\n\tstatic readonly WebviewContext = new MenuId('WebviewContext');\n\tstatic readonly InlineCompletionsActions = new MenuId('InlineCompletionsActions');\n\tstatic readonly InlineEditsActions = new MenuId('InlineEditsActions');\n\tstatic readonly NewFile = new MenuId('NewFile');\n\tstatic readonly MergeInput1Toolbar = new MenuId('MergeToolbar1Toolbar');\n\tstatic readonly MergeInput2Toolbar = new MenuId('MergeToolbar2Toolbar');\n\tstatic readonly MergeBaseToolbar = new MenuId('MergeBaseToolbar');\n\tstatic readonly MergeInputResultToolbar = new MenuId('MergeToolbarResultToolbar');\n\tstatic readonly InlineSuggestionToolbar = new MenuId('InlineSuggestionToolbar');\n\tstatic readonly InlineEditToolbar = new MenuId('InlineEditToolbar');\n\tstatic readonly ChatContext = new MenuId('ChatContext');\n\tstatic readonly ChatCodeBlock = new MenuId('ChatCodeblock');\n\tstatic readonly ChatCompareBlock = new MenuId('ChatCompareBlock');\n\tstatic readonly ChatMessageTitle = new MenuId('ChatMessageTitle');\n\tstatic readonly ChatWelcomeContext = new MenuId('ChatWelcomeContext');\n\tstatic readonly ChatMessageFooter = new MenuId('ChatMessageFooter');\n\tstatic readonly ChatExecute = new MenuId('ChatExecute');\n\tstatic readonly ChatInput = new MenuId('ChatInput');\n\tstatic readonly ChatInputSide = new MenuId('ChatInputSide');\n\tstatic readonly ChatModePicker = new MenuId('ChatModePicker');\n\tstatic readonly ChatEditingWidgetToolbar = new MenuId('ChatEditingWidgetToolbar');\n\tstatic readonly ChatEditingSessionChangesToolbar = new MenuId('ChatEditingSessionChangesToolbar');\n\tstatic readonly ChatEditingEditorContent = new MenuId('ChatEditingEditorContent');\n\tstatic readonly ChatEditingEditorHunk = new MenuId('ChatEditingEditorHunk');\n\tstatic readonly ChatEditingDeletedNotebookCell = new MenuId('ChatEditingDeletedNotebookCell');\n\tstatic readonly ChatInputAttachmentToolbar = new MenuId('ChatInputAttachmentToolbar');\n\tstatic readonly ChatEditingWidgetModifiedFilesToolbar = new MenuId('ChatEditingWidgetModifiedFilesToolbar');\n\tstatic readonly ChatInputResourceAttachmentContext = new MenuId('ChatInputResourceAttachmentContext');\n\tstatic readonly ChatInputSymbolAttachmentContext = new MenuId('ChatInputSymbolAttachmentContext');\n\tstatic readonly ChatInlineResourceAnchorContext = new MenuId('ChatInlineResourceAnchorContext');\n\tstatic readonly ChatInlineSymbolAnchorContext = new MenuId('ChatInlineSymbolAnchorContext');\n\tstatic readonly ChatMessageCheckpoint: MenuId = new MenuId('ChatMessageCheckpoint');\n\tstatic readonly ChatMessageRestoreCheckpoint: MenuId = new MenuId('ChatMessageRestoreCheckpoint');\n\tstatic readonly ChatNewMenu = new MenuId('ChatNewMenu');\n\tstatic readonly ChatEditingCodeBlockContext = new MenuId('ChatEditingCodeBlockContext');\n\tstatic readonly ChatTitleBarMenu = new MenuId('ChatTitleBarMenu');\n\tstatic readonly ChatAttachmentsContext = new MenuId('ChatAttachmentsContext');\n\tstatic readonly ChatToolOutputResourceToolbar = new MenuId('ChatToolOutputResourceToolbar');\n\tstatic readonly ChatTextEditorMenu = new MenuId('ChatTextEditorMenu');\n\tstatic readonly ChatToolOutputResourceContext = new MenuId('ChatToolOutputResourceContext');\n\tstatic readonly ChatMultiDiffContext = new MenuId('ChatMultiDiffContext');\n\tstatic readonly ChatConfirmationMenu = new MenuId('ChatConfirmationMenu');\n\tstatic readonly ChatEditorInlineGutter = new MenuId('ChatEditorInlineGutter');\n\tstatic readonly ChatEditorInlineExecute = new MenuId('ChatEditorInputExecute');\n\tstatic readonly ChatEditorInlineInputSide = new MenuId('ChatEditorInputSide');\n\tstatic readonly InlineChatEditorAffordance = new MenuId('InlineChatEditorAffordance');\n\tstatic readonly AccessibleView = new MenuId('AccessibleView');\n\tstatic readonly MultiDiffEditorContent = new MenuId('MultiDiffEditorContent');\n\tstatic readonly MultiDiffEditorFileToolbar = new MenuId('MultiDiffEditorFileToolbar');\n\tstatic readonly DiffEditorHunkToolbar = new MenuId('DiffEditorHunkToolbar');\n\tstatic readonly DiffEditorSelectionToolbar = new MenuId('DiffEditorSelectionToolbar');\n\tstatic readonly BrowserNavigationToolbar = new MenuId('BrowserNavigationToolbar');\n\tstatic readonly BrowserActionsToolbar = new MenuId('BrowserActionsToolbar');\n\tstatic readonly AgentSessionsViewerFilterSubMenu = new MenuId('AgentSessionsViewerFilterSubMenu');\n\tstatic readonly AgentSessionsContext = new MenuId('AgentSessionsContext');\n\tstatic readonly AgentSessionSectionContext = new MenuId('AgentSessionSectionContext');\n\tstatic readonly AgentSessionsCreateSubMenu = new MenuId('AgentSessionsCreateSubMenu');\n\tstatic readonly AgentSessionsToolbar = new MenuId('AgentSessionsToolbar');\n\tstatic readonly AgentSessionItemToolbar = new MenuId('AgentSessionItemToolbar');\n\tstatic readonly AgentSessionSectionToolbar = new MenuId('AgentSessionSectionToolbar');\n\tstatic readonly AgentsTitleBarControlMenu = new MenuId('AgentsTitleBarControlMenu');\n\tstatic readonly ChatViewSessionTitleNavigationToolbar = new MenuId('ChatViewSessionTitleNavigationToolbar');\n\tstatic readonly ChatViewSessionTitleToolbar = new MenuId('ChatViewSessionTitleToolbar');\n\tstatic readonly ChatContextUsageActions = new MenuId('ChatContextUsageActions');\n\n\treadonly id: string;\n\n\t/**\n\t * Create a new `MenuId` with the unique identifier. Will throw if a menu\n\t * with the identifier already exists, use `MenuId.for(ident)` or a unique\n\t * identifier\n\t */\n\tconstructor(identifier: string) {\n\t\tif (MenuId._instances.has(identifier)) {\n\t\t\tthrow new TypeError(`MenuId with identifier '${identifier}' already exists. Use MenuId.for(ident) or a unique identifier`);\n\t\t}\n\t\tMenuId._instances.set(identifier, this);\n\t\tthis.id = identifier;\n\t}\n}\n\nexport interface IMenuActionOptions {\n\targ?: unknown;\n\tshouldForwardArgs?: boolean;\n\trenderShortTitle?: boolean;\n}\n\nexport interface IMenuChangeEvent {\n\treadonly menu: IMenu;\n\treadonly isStructuralChange: boolean;\n\treadonly isToggleChange: boolean;\n\treadonly isEnablementChange: boolean;\n}\n\nexport interface IMenu extends IDisposable {\n\treadonly onDidChange: Event<IMenuChangeEvent>;\n\tgetActions(options?: IMenuActionOptions): [string, Array<MenuItemAction | SubmenuItemAction>][];\n}\n\nexport const IMenuService = createDecorator<IMenuService>('menuService');\n\nexport interface IMenuCreateOptions {\n\temitEventsForSubmenuChanges?: boolean;\n\teventDebounceDelay?: number;\n}\n\nexport interface IMenuService {\n\n\treadonly _serviceBrand: undefined;\n\n\t/**\n\t * Consider using getMenuActions if you don't need to listen to events.\n\t *\n\t * Create a new menu for the given menu identifier. A menu sends events when it's entries\n\t * have changed (placement, enablement, checked-state). By default it does not send events for\n\t * submenu entries. That is more expensive and must be explicitly enabled with the\n\t * `emitEventsForSubmenuChanges` flag.\n\t */\n\tcreateMenu(id: MenuId, contextKeyService: IContextKeyService, options?: IMenuCreateOptions): IMenu;\n\n\t/**\n\t * Creates a new menu, gets the actions, and then disposes of the menu.\n\t */\n\tgetMenuActions(id: MenuId, contextKeyService: IContextKeyService, options?: IMenuActionOptions): [string, Array<MenuItemAction | SubmenuItemAction>][];\n\n\t/**\n\t * Reset **all** menu item hidden states.\n\t */\n\tresetHiddenStates(): void;\n\n\t/**\n\t * Reset the menu's hidden states.\n\t */\n\tresetHiddenStates(menuIds: readonly MenuId[] | undefined): void;\n}\n\ntype ICommandsMap = Map<string, ICommandAction>;\n\nexport interface IMenuRegistryChangeEvent {\n\thas(id: MenuId): boolean;\n}\n\nclass MenuRegistryChangeEvent {\n\n\tprivate static _all = new Map<MenuId, MenuRegistryChangeEvent>();\n\n\tstatic for(id: MenuId): MenuRegistryChangeEvent {\n\t\tlet value = this._all.get(id);\n\t\tif (!value) {\n\t\t\tvalue = new MenuRegistryChangeEvent(id);\n\t\t\tthis._all.set(id, value);\n\t\t}\n\t\treturn value;\n\t}\n\n\tstatic merge(events: IMenuRegistryChangeEvent[]): IMenuRegistryChangeEvent {\n\t\tconst ids = new Set<MenuId>();\n\t\tfor (const item of events) {\n\t\t\tif (item instanceof MenuRegistryChangeEvent) {\n\t\t\t\tids.add(item.id);\n\t\t\t}\n\t\t}\n\t\treturn ids;\n\t}\n\n\treadonly has: (id: MenuId) => boolean;\n\n\tprivate constructor(private readonly id: MenuId) {\n\t\tthis.has = candidate => candidate === id;\n\t}\n}\n\nexport interface IMenuRegistry {\n\treadonly onDidChangeMenu: Event<IMenuRegistryChangeEvent>;\n\taddCommand(userCommand: ICommandAction): IDisposable;\n\tappendMenuItem(menu: MenuId, item: IMenuItem | ISubmenuItem): IDisposable;\n\tgetMenuItems(loc: MenuId): Array<IMenuItem | ISubmenuItem>;\n}\n\nexport const MenuRegistry: IMenuRegistry = new class implements IMenuRegistry {\n\n\tprivate readonly _commands = new Map<string, ICommandAction>();\n\tprivate readonly _menuItems = new Map<MenuId, LinkedList<IMenuItem | ISubmenuItem>>();\n\tprivate readonly _onDidChangeMenu = new MicrotaskEmitter<IMenuRegistryChangeEvent>({\n\t\tmerge: MenuRegistryChangeEvent.merge\n\t});\n\n\treadonly onDidChangeMenu: Event<IMenuRegistryChangeEvent> = this._onDidChangeMenu.event;\n\n\taddCommand(command: ICommandAction): IDisposable {\n\t\tthis._commands.set(command.id, command);\n\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(MenuId.CommandPalette));\n\n\t\treturn markAsSingleton(toDisposable(() => {\n\t\t\tif (this._commands.delete(command.id)) {\n\t\t\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(MenuId.CommandPalette));\n\t\t\t}\n\t\t}));\n\t}\n\n\tgetCommand(id: string): ICommandAction | undefined {\n\t\treturn this._commands.get(id);\n\t}\n\n\tgetCommands(): ICommandsMap {\n\t\tconst map = new Map<string, ICommandAction>();\n\t\tthis._commands.forEach((value, key) => map.set(key, value));\n\t\treturn map;\n\t}\n\n\tappendMenuItem(id: MenuId, item: IMenuItem | ISubmenuItem): IDisposable {\n\t\tlet list = this._menuItems.get(id);\n\t\tif (!list) {\n\t\t\tlist = new LinkedList();\n\t\t\tthis._menuItems.set(id, list);\n\t\t}\n\t\tconst rm = list.push(item);\n\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(id));\n\t\treturn markAsSingleton(toDisposable(() => {\n\t\t\trm();\n\t\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(id));\n\t\t}));\n\t}\n\n\tappendMenuItems(items: Iterable<{ id: MenuId; item: IMenuItem | ISubmenuItem }>): IDisposable {\n\t\tconst result = new DisposableStore();\n\t\tfor (const { id, item } of items) {\n\t\t\tresult.add(this.appendMenuItem(id, item));\n\t\t}\n\t\treturn result;\n\t}\n\n\tgetMenuItems(id: MenuId): Array<IMenuItem | ISubmenuItem> {\n\t\tlet result: Array<IMenuItem | ISubmenuItem>;\n\t\tif (this._menuItems.has(id)) {\n\t\t\tresult = [...this._menuItems.get(id)!];\n\t\t} else {\n\t\t\tresult = [];\n\t\t}\n\t\tif (id === MenuId.CommandPalette) {\n\t\t\t// CommandPalette is special because it shows\n\t\t\t// all commands by default\n\t\t\tthis._appendImplicitItems(result);\n\t\t}\n\t\treturn result;\n\t}\n\n\tprivate _appendImplicitItems(result: Array<IMenuItem | ISubmenuItem>) {\n\t\tconst set = new Set<string>();\n\n\t\tfor (const item of result) {\n\t\t\tif (isIMenuItem(item)) {\n\t\t\t\tset.add(item.command.id);\n\t\t\t\tif (item.alt) {\n\t\t\t\t\tset.add(item.alt.id);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tthis._commands.forEach((command, id) => {\n\t\t\tif (!set.has(id)) {\n\t\t\t\tresult.push({ command });\n\t\t\t}\n\t\t});\n\t}\n};\n\nexport class SubmenuItemAction extends SubmenuAction {\n\n\tconstructor(\n\t\treadonly item: ISubmenuItem,\n\t\treadonly hideActions: IMenuItemHide | undefined,\n\t\tactions: readonly IAction[],\n\t) {\n\t\tsuper(`submenuitem.${item.submenu.id}`, typeof item.title === 'string' ? item.title : item.title.value, actions, 'submenu');\n\t}\n}\n\nexport interface IMenuItemHide {\n\treadonly isHidden: boolean;\n\treadonly hide: IAction;\n\treadonly toggle: IAction;\n}\n\n// implements IAction, does NOT extend Action, so that no one\n// subscribes to events of Action or modified properties\nexport class MenuItemAction implements IAction {\n\n\tstatic label(action: ICommandAction, options?: IMenuActionOptions): string {\n\t\treturn options?.renderShortTitle && action.shortTitle\n\t\t\t? (typeof action.shortTitle === 'string' ? action.shortTitle : action.shortTitle.value)\n\t\t\t: (typeof action.title === 'string' ? action.title : action.title.value);\n\t}\n\n\treadonly item: ICommandAction;\n\treadonly alt: MenuItemAction | undefined;\n\n\tprivate readonly _options: IMenuActionOptions | undefined;\n\n\treadonly id: string;\n\treadonly label: string;\n\treadonly tooltip: string;\n\treadonly class: string | undefined;\n\treadonly enabled: boolean;\n\treadonly checked?: boolean;\n\n\tconstructor(\n\t\titem: ICommandAction,\n\t\talt: ICommandAction | undefined,\n\t\toptions: IMenuActionOptions | undefined,\n\t\treadonly hideActions: IMenuItemHide | undefined,\n\t\treadonly menuKeybinding: IAction | undefined,\n\t\t@IContextKeyService contextKeyService: IContextKeyService,\n\t\t@ICommandService private _commandService: ICommandService\n\t) {\n\t\tthis.id = item.id;\n\t\tthis.label = MenuItemAction.label(item, options);\n\t\tthis.tooltip = (typeof item.tooltip === 'string' ? item.tooltip : item.tooltip?.value) ?? '';\n\t\tthis.enabled = !item.precondition || contextKeyService.contextMatchesRules(item.precondition);\n\t\tthis.checked = undefined;\n\n\t\tlet icon: ThemeIcon | undefined;\n\n\t\tif (item.toggled) {\n\t\t\tconst toggled = ((item.toggled as { condition: ContextKeyExpression }).condition ? item.toggled : { condition: item.toggled }) as {\n\t\t\t\tcondition: ContextKeyExpression; icon?: Icon; tooltip?: string | ILocalizedString; title?: string | ILocalizedString;\n\t\t\t};\n\t\t\tthis.checked = contextKeyService.contextMatchesRules(toggled.condition);\n\t\t\tif (this.checked && toggled.tooltip) {\n\t\t\t\tthis.tooltip = typeof toggled.tooltip === 'string' ? toggled.tooltip : toggled.tooltip.value;\n\t\t\t}\n\n\t\t\tif (this.checked && ThemeIcon.isThemeIcon(toggled.icon)) {\n\t\t\t\ticon = toggled.icon;\n\t\t\t}\n\n\t\t\tif (this.checked && toggled.title) {\n\t\t\t\tthis.label = typeof toggled.title === 'string' ? toggled.title : toggled.title.value;\n\t\t\t}\n\t\t}\n\n\t\tif (!icon) {\n\t\t\ticon = ThemeIcon.isThemeIcon(item.icon) ? item.icon : undefined;\n\t\t}\n\n\t\tthis.item = item;\n\t\tthis.alt = alt ? new MenuItemAction(alt, undefined, options, hideActions, undefined, contextKeyService, _commandService) : undefined;\n\t\tthis._options = options;\n\t\tthis.class = icon && ThemeIcon.asClassName(icon);\n\n\t}\n\n\trun(...args: unknown[]): Promise<void> {\n\t\tlet runArgs: unknown[] = [];\n\n\t\tif (this._options?.arg) {\n\t\t\trunArgs = [...runArgs, this._options.arg];\n\t\t}\n\n\t\tif (this._options?.shouldForwardArgs) {\n\t\t\trunArgs = [...runArgs, ...args];\n\t\t}\n\n\t\treturn this._commandService.executeCommand(this.id, ...runArgs);\n\t}\n}\n\n//#region --- IAction2\n\ntype OneOrN<T> = T | T[];\n\ninterface IAction2CommonOptions extends ICommandAction {\n\t/**\n\t * One or many menu items.\n\t */\n\tmenu?: OneOrN<{ id: MenuId; precondition?: null } & Omit<IMenuItem, 'command'>>;\n\n\t/**\n\t * One keybinding.\n\t */\n\tkeybinding?: OneOrN<Omit<IKeybindingRule, 'id'>>;\n}\n\ninterface IBaseAction2Options extends IAction2CommonOptions {\n\n\t/**\n\t * This type is used when an action is not going to show up in the command palette.\n\t * In that case, it's able to use a string for the `title` and `category` properties.\n\t */\n\tf1?: false;\n}\n\nexport interface ICommandPaletteOptions extends IAction2CommonOptions {\n\n\t/**\n\t * The title of the command that will be displayed in the command palette after the category.\n\t * This overrides {@link ICommandAction.title} to ensure a string isn't used so that the title\n\t * includes the localized value and the original value for users using language packs.\n\t */\n\ttitle: ICommandActionTitle;\n\n\t/**\n\t * The category of the command that will be displayed in the command palette before the title suffixed.\n\t * with a colon This overrides {@link ICommandAction.title} to ensure a string isn't used so that\n\t * the title includes the localized value and the original value for users using language packs.\n\t */\n\tcategory?: keyof typeof Categories | ILocalizedString;\n\n\t/**\n\t * Shorthand to add this command to the command palette. Note: this is not the only way to declare that\n\t * a command should be in the command palette... however, enforcing ILocalizedString in the other scenarios\n\t * is much more challenging and this gets us most of the way there.\n\t */\n\tf1: true;\n}\n\nexport type IAction2Options = ICommandPaletteOptions | IBaseAction2Options;\n\nexport interface IAction2F1RequiredOptions {\n\ttitle: ICommandActionTitle;\n}\n\nexport abstract class Action2 {\n\tconstructor(readonly desc: Readonly<IAction2Options>) { }\n\tabstract run(accessor: ServicesAccessor, ...args: unknown[]): void;\n}\n\nexport function registerAction2(ctor: { new(): Action2 }): IDisposable {\n\tconst disposables: IDisposable[] = []; // not using `DisposableStore` to reduce startup perf cost\n\tconst action = new ctor();\n\n\tconst { f1, menu, keybinding, ...command } = action.desc;\n\n\tif (CommandsRegistry.getCommand(command.id)) {\n\t\tthrow new Error(`Cannot register two commands with the same id: ${command.id}`);\n\t}\n\n\t// command\n\tdisposables.push(CommandsRegistry.registerCommand({\n\t\tid: command.id,\n\t\thandler: (accessor, ...args) => action.run(accessor, ...args),\n\t\tmetadata: command.metadata ?? { description: action.desc.title }\n\t}));\n\n\t// menu\n\tif (Array.isArray(menu)) {\n\t\tfor (const item of menu) {\n\t\t\tdisposables.push(MenuRegistry.appendMenuItem(item.id, { command: { ...command, precondition: item.precondition === null ? undefined : command.precondition }, ...item }));\n\t\t}\n\n\t} else if (menu) {\n\t\tdisposables.push(MenuRegistry.appendMenuItem(menu.id, { command: { ...command, precondition: menu.precondition === null ? undefined : command.precondition }, ...menu }));\n\t}\n\tif (f1) {\n\t\tdisposables.push(MenuRegistry.appendMenuItem(MenuId.CommandPalette, { command, when: command.precondition }));\n\t\tdisposables.push(MenuRegistry.addCommand(command));\n\t}\n\n\t// keybinding\n\tif (Array.isArray(keybinding)) {\n\t\tfor (const item of keybinding) {\n\t\t\tdisposables.push(KeybindingsRegistry.registerKeybindingRule({\n\t\t\t\t...item,\n\t\t\t\tid: command.id,\n\t\t\t\twhen: command.precondition ? ContextKeyExpr.and(command.precondition, item.when) : item.when\n\t\t\t}));\n\t\t}\n\t} else if (keybinding) {\n\t\tdisposables.push(KeybindingsRegistry.registerKeybindingRule({\n\t\t\t...keybinding,\n\t\t\tid: command.id,\n\t\t\twhen: command.precondition ? ContextKeyExpr.and(command.precondition, keybinding.when) : keybinding.when\n\t\t}));\n\t}\n\n\treturn {\n\t\tdispose() {\n\t\t\tdispose(disposables);\n\t\t}\n\t};\n}\n//#endregion\n","/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport { IAction, SubmenuAction } from '../../../base/common/actions.js';\nimport { Event, MicrotaskEmitter } from '../../../base/common/event.js';\nimport { DisposableStore, dispose, IDisposable, markAsSingleton, toDisposable } from '../../../base/common/lifecycle.js';\nimport { LinkedList } from '../../../base/common/linkedList.js';\nimport { ThemeIcon } from '../../../base/common/themables.js';\nimport { ICommandAction, ICommandActionTitle, Icon, ILocalizedString } from '../../action/common/action.js';\nimport { Categories } from '../../action/common/actionCommonCategories.js';\nimport { CommandsRegistry, ICommandService } from '../../commands/common/commands.js';\nimport { ContextKeyExpr, ContextKeyExpression, IContextKeyService } from '../../contextkey/common/contextkey.js';\nimport { createDecorator, ServicesAccessor } from '../../instantiation/common/instantiation.js';\nimport { IKeybindingRule, KeybindingsRegistry } from '../../keybinding/common/keybindingsRegistry.js';\n\nexport interface IMenuItem {\n\tcommand: ICommandAction;\n\talt?: ICommandAction;\n\t/**\n\t * Menu item is hidden if this expression returns false.\n\t */\n\twhen?: ContextKeyExpression;\n\tgroup?: 'navigation' | string;\n\torder?: number;\n\tisHiddenByDefault?: boolean;\n}\n\nexport interface ISubmenuItem {\n\ttitle: string | ICommandActionTitle;\n\tsubmenu: MenuId;\n\ticon?: Icon;\n\twhen?: ContextKeyExpression;\n\tgroup?: 'navigation' | string;\n\torder?: number;\n\tisSelection?: boolean;\n\t/**\n\t * A split button shows the first action\n\t * as primary action and the rest of the\n\t * actions in a dropdown.\n\t *\n\t * Use `togglePrimaryAction` to promote\n\t * the action that was last used to be\n\t * the primary action and remember that\n\t * choice.\n\t */\n\tisSplitButton?: boolean | {\n\t\t/**\n\t\t * Will update the primary action based\n\t\t * on the action that was last run.\n\t\t */\n\t\ttogglePrimaryAction: true;\n\t};\n}\n\nexport function isIMenuItem(item: unknown): item is IMenuItem {\n\treturn (item as IMenuItem).command !== undefined;\n}\n\nexport function isISubmenuItem(item: unknown): item is ISubmenuItem {\n\treturn (item as ISubmenuItem).submenu !== undefined;\n}\n\nexport class MenuId {\n\n\tprivate static readonly _instances = new Map<string, MenuId>();\n\n\tstatic readonly CommandPalette = new MenuId('CommandPalette');\n\tstatic readonly DebugBreakpointsContext = new MenuId('DebugBreakpointsContext');\n\tstatic readonly DebugCallStackContext = new MenuId('DebugCallStackContext');\n\tstatic readonly DebugConsoleContext = new MenuId('DebugConsoleContext');\n\tstatic readonly DebugVariablesContext = new MenuId('DebugVariablesContext');\n\tstatic readonly NotebookVariablesContext = new MenuId('NotebookVariablesContext');\n\tstatic readonly DebugHoverContext = new MenuId('DebugHoverContext');\n\tstatic readonly DebugWatchContext = new MenuId('DebugWatchContext');\n\tstatic readonly DebugToolBar = new MenuId('DebugToolBar');\n\tstatic readonly DebugToolBarStop = new MenuId('DebugToolBarStop');\n\tstatic readonly DebugDisassemblyContext = new MenuId('DebugDisassemblyContext');\n\tstatic readonly DebugCallStackToolbar = new MenuId('DebugCallStackToolbar');\n\tstatic readonly DebugCreateConfiguration = new MenuId('DebugCreateConfiguration');\n\tstatic readonly DebugScopesContext = new MenuId('DebugScopesContext');\n\tstatic readonly EditorContext = new MenuId('EditorContext');\n\tstatic readonly SimpleEditorContext = new MenuId('SimpleEditorContext');\n\tstatic readonly EditorContent = new MenuId('EditorContent');\n\tstatic readonly EditorLineNumberContext = new MenuId('EditorLineNumberContext');\n\tstatic readonly EditorContextCopy = new MenuId('EditorContextCopy');\n\tstatic readonly EditorContextPeek = new MenuId('EditorContextPeek');\n\tstatic readonly EditorContextShare = new MenuId('EditorContextShare');\n\tstatic readonly EditorTitle = new MenuId('EditorTitle');\n\tstatic readonly CompactWindowEditorTitle = new MenuId('CompactWindowEditorTitle');\n\tstatic readonly EditorTitleRun = new MenuId('EditorTitleRun');\n\tstatic readonly EditorTitleContext = new MenuId('EditorTitleContext');\n\tstatic readonly EditorTitleContextShare = new MenuId('EditorTitleContextShare');\n\tstatic readonly EmptyEditorGroup = new MenuId('EmptyEditorGroup');\n\tstatic readonly EmptyEditorGroupContext = new MenuId('EmptyEditorGroupContext');\n\tstatic readonly EditorTabsBarContext = new MenuId('EditorTabsBarContext');\n\tstatic readonly EditorTabsBarShowTabsSubmenu = new MenuId('EditorTabsBarShowTabsSubmenu');\n\tstatic readonly EditorTabsBarShowTabsZenModeSubmenu = new MenuId('EditorTabsBarShowTabsZenModeSubmenu');\n\tstatic readonly EditorActionsPositionSubmenu = new MenuId('EditorActionsPositionSubmenu');\n\tstatic readonly EditorSplitMoveSubmenu = new MenuId('EditorSplitMoveSubmenu');\n\tstatic readonly ExplorerContext = new MenuId('ExplorerContext');\n\tstatic readonly ExplorerContextShare = new MenuId('ExplorerContextShare');\n\tstatic readonly ExtensionContext = new MenuId('ExtensionContext');\n\tstatic readonly ExtensionEditorContextMenu = new MenuId('ExtensionEditorContextMenu');\n\tstatic readonly GlobalActivity = new MenuId('GlobalActivity');\n\tstatic readonly CommandCenter = new MenuId('CommandCenter');\n\tstatic readonly CommandCenterCenter = new MenuId('CommandCenterCenter');\n\tstatic readonly LayoutControlMenuSubmenu = new MenuId('LayoutControlMenuSubmenu');\n\tstatic readonly LayoutControlMenu = new MenuId('LayoutControlMenu');\n\tstatic readonly MenubarMainMenu = new MenuId('MenubarMainMenu');\n\tstatic readonly MenubarAppearanceMenu = new MenuId('MenubarAppearanceMenu');\n\tstatic readonly MenubarDebugMenu = new MenuId('MenubarDebugMenu');\n\tstatic readonly MenubarEditMenu = new MenuId('MenubarEditMenu');\n\tstatic readonly MenubarCopy = new MenuId('MenubarCopy');\n\tstatic readonly MenubarFileMenu = new MenuId('MenubarFileMenu');\n\tstatic readonly MenubarGoMenu = new MenuId('MenubarGoMenu');\n\tstatic readonly MenubarHelpMenu = new MenuId('MenubarHelpMenu');\n\tstatic readonly MenubarLayoutMenu = new MenuId('MenubarLayoutMenu');\n\tstatic readonly MenubarNewBreakpointMenu = new MenuId('MenubarNewBreakpointMenu');\n\tstatic readonly PanelAlignmentMenu = new MenuId('PanelAlignmentMenu');\n\tstatic readonly PanelPositionMenu = new MenuId('PanelPositionMenu');\n\tstatic readonly ActivityBarPositionMenu = new MenuId('ActivityBarPositionMenu');\n\tstatic readonly MenubarPreferencesMenu = new MenuId('MenubarPreferencesMenu');\n\tstatic readonly MenubarRecentMenu = new MenuId('MenubarRecentMenu');\n\tstatic readonly MenubarSelectionMenu = new MenuId('MenubarSelectionMenu');\n\tstatic readonly MenubarShare = new MenuId('MenubarShare');\n\tstatic readonly MenubarSwitchEditorMenu = new MenuId('MenubarSwitchEditorMenu');\n\tstatic readonly MenubarSwitchGroupMenu = new MenuId('MenubarSwitchGroupMenu');\n\tstatic readonly MenubarTerminalMenu = new MenuId('MenubarTerminalMenu');\n\tstatic readonly MenubarTerminalSuggestStatusMenu = new MenuId('MenubarTerminalSuggestStatusMenu');\n\tstatic readonly MenubarViewMenu = new MenuId('MenubarViewMenu');\n\tstatic readonly MenubarHomeMenu = new MenuId('MenubarHomeMenu');\n\tstatic readonly OpenEditorsContext = new MenuId('OpenEditorsContext');\n\tstatic readonly OpenEditorsContextShare = new MenuId('OpenEditorsContextShare');\n\tstatic readonly ProblemsPanelContext = new MenuId('ProblemsPanelContext');\n\tstatic readonly SCMInputBox = new MenuId('SCMInputBox');\n\tstatic readonly SCMChangeContext = new MenuId('SCMChangeContext');\n\tstatic readonly SCMResourceContext = new MenuId('SCMResourceContext');\n\tstatic readonly SCMResourceContextShare = new MenuId('SCMResourceContextShare');\n\tstatic readonly SCMResourceFolderContext = new MenuId('SCMResourceFolderContext');\n\tstatic readonly SCMResourceGroupContext = new MenuId('SCMResourceGroupContext');\n\tstatic readonly SCMSourceControl = new MenuId('SCMSourceControl');\n\tstatic readonly SCMSourceControlInline = new MenuId('SCMSourceControlInline');\n\tstatic readonly SCMSourceControlTitle = new MenuId('SCMSourceControlTitle');\n\tstatic readonly SCMHistoryTitle = new MenuId('SCMHistoryTitle');\n\tstatic readonly SCMHistoryItemContext = new MenuId('SCMHistoryItemContext');\n\tstatic readonly SCMHistoryItemChangeContext = new MenuId('SCMHistoryItemChangeContext');\n\tstatic readonly SCMHistoryItemRefContext = new MenuId('SCMHistoryItemRefContext');\n\tstatic readonly SCMArtifactGroupContext = new MenuId('SCMArtifactGroupContext');\n\tstatic readonly SCMArtifactContext = new MenuId('SCMArtifactContext');\n\tstatic readonly SCMQuickDiffDecorations = new MenuId('SCMQuickDiffDecorations');\n\tstatic readonly SCMTitle = new MenuId('SCMTitle');\n\tstatic readonly SearchContext = new MenuId('SearchContext');\n\tstatic readonly SearchActionMenu = new MenuId('SearchActionContext');\n\tstatic readonly StatusBarWindowIndicatorMenu = new MenuId('StatusBarWindowIndicatorMenu');\n\tstatic readonly StatusBarRemoteIndicatorMenu = new MenuId('StatusBarRemoteIndicatorMenu');\n\tstatic readonly StickyScrollContext = new MenuId('StickyScrollContext');\n\tstatic readonly TestItem = new MenuId('TestItem');\n\tstatic readonly TestItemGutter = new MenuId('TestItemGutter');\n\tstatic readonly TestProfilesContext = new MenuId('TestProfilesContext');\n\tstatic readonly TestMessageContext = new MenuId('TestMessageContext');\n\tstatic readonly TestMessageContent = new MenuId('TestMessageContent');\n\tstatic readonly TestPeekElement = new MenuId('TestPeekElement');\n\tstatic readonly TestPeekTitle = new MenuId('TestPeekTitle');\n\tstatic readonly TestCallStack = new MenuId('TestCallStack');\n\tstatic readonly TestCoverageFilterItem = new MenuId('TestCoverageFilterItem');\n\tstatic readonly TouchBarContext = new MenuId('TouchBarContext');\n\tstatic readonly TitleBar = new MenuId('TitleBar');\n\tstatic readonly TitleBarContext = new MenuId('TitleBarContext');\n\tstatic readonly TitleBarTitleContext = new MenuId('TitleBarTitleContext');\n\tstatic readonly TunnelContext = new MenuId('TunnelContext');\n\tstatic readonly TunnelPrivacy = new MenuId('TunnelPrivacy');\n\tstatic readonly TunnelProtocol = new MenuId('TunnelProtocol');\n\tstatic readonly TunnelPortInline = new MenuId('TunnelInline');\n\tstatic readonly TunnelTitle = new MenuId('TunnelTitle');\n\tstatic readonly TunnelLocalAddressInline = new MenuId('TunnelLocalAddressInline');\n\tstatic readonly TunnelOriginInline = new MenuId('TunnelOriginInline');\n\tstatic readonly ViewItemContext = new MenuId('ViewItemContext');\n\tstatic readonly ViewContainerTitle = new MenuId('ViewContainerTitle');\n\tstatic readonly ViewContainerTitleContext = new MenuId('ViewContainerTitleContext');\n\tstatic readonly ViewTitle = new MenuId('ViewTitle');\n\tstatic readonly ViewTitleContext = new MenuId('ViewTitleContext');\n\tstatic readonly CommentEditorActions = new MenuId('CommentEditorActions');\n\tstatic readonly CommentThreadTitle = new MenuId('CommentThreadTitle');\n\tstatic readonly CommentThreadActions = new MenuId('CommentThreadActions');\n\tstatic readonly CommentThreadAdditionalActions = new MenuId('CommentThreadAdditionalActions');\n\tstatic readonly CommentThreadTitleContext = new MenuId('CommentThreadTitleContext');\n\tstatic readonly CommentThreadCommentContext = new MenuId('CommentThreadCommentContext');\n\tstatic readonly CommentTitle = new MenuId('CommentTitle');\n\tstatic readonly CommentActions = new MenuId('CommentActions');\n\tstatic readonly CommentsViewThreadActions = new MenuId('CommentsViewThreadActions');\n\tstatic readonly InteractiveToolbar = new MenuId('InteractiveToolbar');\n\tstatic readonly InteractiveCellTitle = new MenuId('InteractiveCellTitle');\n\tstatic readonly InteractiveCellDelete = new MenuId('InteractiveCellDelete');\n\tstatic readonly InteractiveCellExecute = new MenuId('InteractiveCellExecute');\n\tstatic readonly InteractiveInputExecute = new MenuId('InteractiveInputExecute');\n\tstatic readonly InteractiveInputConfig = new MenuId('InteractiveInputConfig');\n\tstatic readonly ReplInputExecute = new MenuId('ReplInputExecute');\n\tstatic readonly IssueReporter = new MenuId('IssueReporter');\n\tstatic readonly NotebookToolbar = new MenuId('NotebookToolbar');\n\tstatic readonly NotebookToolbarContext = new MenuId('NotebookToolbarContext');\n\tstatic readonly NotebookStickyScrollContext = new MenuId('NotebookStickyScrollContext');\n\tstatic readonly NotebookCellTitle = new MenuId('NotebookCellTitle');\n\tstatic readonly NotebookCellDelete = new MenuId('NotebookCellDelete');\n\tstatic readonly NotebookCellInsert = new MenuId('NotebookCellInsert');\n\tstatic readonly NotebookCellBetween = new MenuId('NotebookCellBetween');\n\tstatic readonly NotebookCellListTop = new MenuId('NotebookCellTop');\n\tstatic readonly NotebookCellExecute = new MenuId('NotebookCellExecute');\n\tstatic readonly NotebookCellExecuteGoTo = new MenuId('NotebookCellExecuteGoTo');\n\tstatic readonly NotebookCellExecutePrimary = new MenuId('NotebookCellExecutePrimary');\n\tstatic readonly NotebookDiffCellInputTitle = new MenuId('NotebookDiffCellInputTitle');\n\tstatic readonly NotebookDiffDocumentMetadata = new MenuId('NotebookDiffDocumentMetadata');\n\tstatic readonly NotebookDiffCellMetadataTitle = new MenuId('NotebookDiffCellMetadataTitle');\n\tstatic readonly NotebookDiffCellOutputsTitle = new MenuId('NotebookDiffCellOutputsTitle');\n\tstatic readonly NotebookOutputToolbar = new MenuId('NotebookOutputToolbar');\n\tstatic readonly NotebookOutlineFilter = new MenuId('NotebookOutlineFilter');\n\tstatic readonly NotebookOutlineActionMenu = new MenuId('NotebookOutlineActionMenu');\n\tstatic readonly NotebookEditorLayoutConfigure = new MenuId('NotebookEditorLayoutConfigure');\n\tstatic readonly NotebookKernelSource = new MenuId('NotebookKernelSource');\n\tstatic readonly BulkEditTitle = new MenuId('BulkEditTitle');\n\tstatic readonly BulkEditContext = new MenuId('BulkEditContext');\n\tstatic readonly TimelineItemContext = new MenuId('TimelineItemContext');\n\tstatic readonly TimelineTitle = new MenuId('TimelineTitle');\n\tstatic readonly TimelineTitleContext = new MenuId('TimelineTitleContext');\n\tstatic readonly TimelineFilterSubMenu = new MenuId('TimelineFilterSubMenu');\n\tstatic readonly AccountsContext = new MenuId('AccountsContext');\n\tstatic readonly SidebarTitle = new MenuId('SidebarTitle');\n\tstatic readonly PanelTitle = new MenuId('PanelTitle');\n\tstatic readonly AuxiliaryBarTitle = new MenuId('AuxiliaryBarTitle');\n\tstatic readonly TerminalInstanceContext = new MenuId('TerminalInstanceContext');\n\tstatic readonly TerminalEditorInstanceContext = new MenuId('TerminalEditorInstanceContext');\n\tstatic readonly TerminalNewDropdownContext = new MenuId('TerminalNewDropdownContext');\n\tstatic readonly TerminalTabContext = new MenuId('TerminalTabContext');\n\tstatic readonly TerminalTabEmptyAreaContext = new MenuId('TerminalTabEmptyAreaContext');\n\tstatic readonly TerminalStickyScrollContext = new MenuId('TerminalStickyScrollContext');\n\tstatic readonly WebviewContext = new MenuId('WebviewContext');\n\tstatic readonly InlineCompletionsActions = new MenuId('InlineCompletionsActions');\n\tstatic readonly InlineEditsActions = new MenuId('InlineEditsActions');\n\tstatic readonly NewFile = new MenuId('NewFile');\n\tstatic readonly MergeInput1Toolbar = new MenuId('MergeToolbar1Toolbar');\n\tstatic readonly MergeInput2Toolbar = new MenuId('MergeToolbar2Toolbar');\n\tstatic readonly MergeBaseToolbar = new MenuId('MergeBaseToolbar');\n\tstatic readonly MergeInputResultToolbar = new MenuId('MergeToolbarResultToolbar');\n\tstatic readonly InlineSuggestionToolbar = new MenuId('InlineSuggestionToolbar');\n\tstatic readonly InlineEditToolbar = new MenuId('InlineEditToolbar');\n\tstatic readonly ChatContext = new MenuId('ChatContext');\n\tstatic readonly ChatCodeBlock = new MenuId('ChatCodeblock');\n\tstatic readonly ChatCompareBlock = new MenuId('ChatCompareBlock');\n\tstatic readonly ChatMessageTitle = new MenuId('ChatMessageTitle');\n\tstatic readonly ChatWelcomeContext = new MenuId('ChatWelcomeContext');\n\tstatic readonly ChatMessageFooter = new MenuId('ChatMessageFooter');\n\tstatic readonly ChatExecute = new MenuId('ChatExecute');\n\tstatic readonly ChatInput = new MenuId('ChatInput');\n\tstatic readonly ChatInputSide = new MenuId('ChatInputSide');\n\tstatic readonly ChatModePicker = new MenuId('ChatModePicker');\n\tstatic readonly ChatEditingWidgetToolbar = new MenuId('ChatEditingWidgetToolbar');\n\tstatic readonly ChatEditingSessionChangesToolbar = new MenuId('ChatEditingSessionChangesToolbar');\n\tstatic readonly ChatEditingEditorContent = new MenuId('ChatEditingEditorContent');\n\tstatic readonly ChatEditingEditorHunk = new MenuId('ChatEditingEditorHunk');\n\tstatic readonly ChatEditingDeletedNotebookCell = new MenuId('ChatEditingDeletedNotebookCell');\n\tstatic readonly ChatInputAttachmentToolbar = new MenuId('ChatInputAttachmentToolbar');\n\tstatic readonly ChatEditingWidgetModifiedFilesToolbar = new MenuId('ChatEditingWidgetModifiedFilesToolbar');\n\tstatic readonly ChatInputResourceAttachmentContext = new MenuId('ChatInputResourceAttachmentContext');\n\tstatic readonly ChatInputSymbolAttachmentContext = new MenuId('ChatInputSymbolAttachmentContext');\n\tstatic readonly ChatInlineResourceAnchorContext = new MenuId('ChatInlineResourceAnchorContext');\n\tstatic readonly ChatInlineSymbolAnchorContext = new MenuId('ChatInlineSymbolAnchorContext');\n\tstatic readonly ChatMessageCheckpoint: MenuId = new MenuId('ChatMessageCheckpoint');\n\tstatic readonly ChatMessageRestoreCheckpoint: MenuId = new MenuId('ChatMessageRestoreCheckpoint');\n\tstatic readonly ChatNewMenu = new MenuId('ChatNewMenu');\n\tstatic readonly ChatEditingCodeBlockContext = new MenuId('ChatEditingCodeBlockContext');\n\tstatic readonly ChatTitleBarMenu = new MenuId('ChatTitleBarMenu');\n\tstatic readonly ChatAttachmentsContext = new MenuId('ChatAttachmentsContext');\n\tstatic readonly ChatToolOutputResourceToolbar = new MenuId('ChatToolOutputResourceToolbar');\n\tstatic readonly ChatTextEditorMenu = new MenuId('ChatTextEditorMenu');\n\tstatic readonly ChatToolOutputResourceContext = new MenuId('ChatToolOutputResourceContext');\n\tstatic readonly ChatMultiDiffContext = new MenuId('ChatMultiDiffContext');\n\tstatic readonly ChatConfirmationMenu = new MenuId('ChatConfirmationMenu');\n\tstatic readonly ChatEditorInlineGutter = new MenuId('ChatEditorInlineGutter');\n\tstatic readonly ChatEditorInlineExecute = new MenuId('ChatEditorInputExecute');\n\tstatic readonly ChatEditorInlineInputSide = new MenuId('ChatEditorInputSide');\n\tstatic readonly InlineChatEditorAffordance = new MenuId('InlineChatEditorAffordance');\n\tstatic readonly AccessibleView = new MenuId('AccessibleView');\n\tstatic readonly MultiDiffEditorContent = new MenuId('MultiDiffEditorContent');\n\tstatic readonly MultiDiffEditorFileToolbar = new MenuId('MultiDiffEditorFileToolbar');\n\tstatic readonly DiffEditorHunkToolbar = new MenuId('DiffEditorHunkToolbar');\n\tstatic readonly DiffEditorSelectionToolbar = new MenuId('DiffEditorSelectionToolbar');\n\tstatic readonly BrowserNavigationToolbar = new MenuId('BrowserNavigationToolbar');\n\tstatic readonly BrowserActionsToolbar = new MenuId('BrowserActionsToolbar');\n\tstatic readonly AgentSessionsViewerFilterSubMenu = new MenuId('AgentSessionsViewerFilterSubMenu');\n\tstatic readonly AgentSessionsContext = new MenuId('AgentSessionsContext');\n\tstatic readonly AgentSessionSectionContext = new MenuId('AgentSessionSectionContext');\n\tstatic readonly AgentSessionsCreateSubMenu = new MenuId('AgentSessionsCreateSubMenu');\n\tstatic readonly AgentSessionsToolbar = new MenuId('AgentSessionsToolbar');\n\tstatic readonly AgentSessionItemToolbar = new MenuId('AgentSessionItemToolbar');\n\tstatic readonly AgentSessionSectionToolbar = new MenuId('AgentSessionSectionToolbar');\n\tstatic readonly AgentsTitleBarControlMenu = new MenuId('AgentsTitleBarControlMenu');\n\tstatic readonly ChatViewSessionTitleNavigationToolbar = new MenuId('ChatViewSessionTitleNavigationToolbar');\n\tstatic readonly ChatViewSessionTitleToolbar = new MenuId('ChatViewSessionTitleToolbar');\n\tstatic readonly ChatContextUsageActions = new MenuId('ChatContextUsageActions');\n\n\treadonly id: string;\n\n\t/**\n\t * Create a new `MenuId` with the unique identifier. Will throw if a menu\n\t * with the identifier already exists, use `MenuId.for(ident)` or a unique\n\t * identifier\n\t */\n\tconstructor(identifier: string) {\n\t\tif (MenuId._instances.has(identifier)) {\n\t\t\tthrow new TypeError(`MenuId with identifier '${identifier}' already exists. Use MenuId.for(ident) or a unique identifier`);\n\t\t}\n\t\tMenuId._instances.set(identifier, this);\n\t\tthis.id = identifier;\n\t}\n}\n\nexport interface IMenuActionOptions {\n\targ?: unknown;\n\tshouldForwardArgs?: boolean;\n\trenderShortTitle?: boolean;\n}\n\nexport interface IMenuChangeEvent {\n\treadonly menu: IMenu;\n\treadonly isStructuralChange: boolean;\n\treadonly isToggleChange: boolean;\n\treadonly isEnablementChange: boolean;\n}\n\nexport interface IMenu extends IDisposable {\n\treadonly onDidChange: Event<IMenuChangeEvent>;\n\tgetActions(options?: IMenuActionOptions): [string, Array<MenuItemAction | SubmenuItemAction>][];\n}\n\nexport const IMenuService = createDecorator<IMenuService>('menuService');\n\nexport interface IMenuCreateOptions {\n\temitEventsForSubmenuChanges?: boolean;\n\teventDebounceDelay?: number;\n}\n\nexport interface IMenuService {\n\n\treadonly _serviceBrand: undefined;\n\n\t/**\n\t * Consider using getMenuActions if you don't need to listen to events.\n\t *\n\t * Create a new menu for the given menu identifier. A menu sends events when it's entries\n\t * have changed (placement, enablement, checked-state). By default it does not send events for\n\t * submenu entries. That is more expensive and must be explicitly enabled with the\n\t * `emitEventsForSubmenuChanges` flag.\n\t */\n\tcreateMenu(id: MenuId, contextKeyService: IContextKeyService, options?: IMenuCreateOptions): IMenu;\n\n\t/**\n\t * Creates a new menu, gets the actions, and then disposes of the menu.\n\t */\n\tgetMenuActions(id: MenuId, contextKeyService: IContextKeyService, options?: IMenuActionOptions): [string, Array<MenuItemAction | SubmenuItemAction>][];\n\n\t/**\n\t * Reset **all** menu item hidden states.\n\t */\n\tresetHiddenStates(): void;\n\n\t/**\n\t * Reset the menu's hidden states.\n\t */\n\tresetHiddenStates(menuIds: readonly MenuId[] | undefined): void;\n}\n\ntype ICommandsMap = Map<string, ICommandAction>;\n\nexport interface IMenuRegistryChangeEvent {\n\thas(id: MenuId): boolean;\n}\n\nclass MenuRegistryChangeEvent {\n\n\tprivate static _all = new Map<MenuId, MenuRegistryChangeEvent>();\n\n\tstatic for(id: MenuId): MenuRegistryChangeEvent {\n\t\tlet value = this._all.get(id);\n\t\tif (!value) {\n\t\t\tvalue = new MenuRegistryChangeEvent(id);\n\t\t\tthis._all.set(id, value);\n\t\t}\n\t\treturn value;\n\t}\n\n\tstatic merge(events: IMenuRegistryChangeEvent[]): IMenuRegistryChangeEvent {\n\t\tconst ids = new Set<MenuId>();\n\t\tfor (const item of events) {\n\t\t\tif (item instanceof MenuRegistryChangeEvent) {\n\t\t\t\tids.add(item.id);\n\t\t\t}\n\t\t}\n\t\treturn ids;\n\t}\n\n\treadonly has: (id: MenuId) => boolean;\n\n\tprivate constructor(private readonly id: MenuId) {\n\t\tthis.has = candidate => candidate === id;\n\t}\n}\n\nexport interface IMenuRegistry {\n\treadonly onDidChangeMenu: Event<IMenuRegistryChangeEvent>;\n\taddCommand(userCommand: ICommandAction): IDisposable;\n\tappendMenuItem(menu: MenuId, item: IMenuItem | ISubmenuItem): IDisposable;\n\tgetMenuItems(loc: MenuId): Array<IMenuItem | ISubmenuItem>;\n}\n\nexport const MenuRegistry: IMenuRegistry = new class implements IMenuRegistry {\n\n\tprivate readonly _commands = new Map<string, ICommandAction>();\n\tprivate readonly _menuItems = new Map<MenuId, LinkedList<IMenuItem | ISubmenuItem>>();\n\tprivate readonly _onDidChangeMenu = new MicrotaskEmitter<IMenuRegistryChangeEvent>({\n\t\tmerge: MenuRegistryChangeEvent.merge\n\t});\n\n\treadonly onDidChangeMenu: Event<IMenuRegistryChangeEvent> = this._onDidChangeMenu.event;\n\n\taddCommand(command: ICommandAction): IDisposable {\n\t\tthis._commands.set(command.id, command);\n\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(MenuId.CommandPalette));\n\n\t\treturn markAsSingleton(toDisposable(() => {\n\t\t\tif (this._commands.delete(command.id)) {\n\t\t\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(MenuId.CommandPalette));\n\t\t\t}\n\t\t}));\n\t}\n\n\tgetCommand(id: string): ICommandAction | undefined {\n\t\treturn this._commands.get(id);\n\t}\n\n\tgetCommands(): ICommandsMap {\n\t\tconst map = new Map<string, ICommandAction>();\n\t\tthis._commands.forEach((value, key) => map.set(key, value));\n\t\treturn map;\n\t}\n\n\tappendMenuItem(id: MenuId, item: IMenuItem | ISubmenuItem): IDisposable {\n\t\tlet list = this._menuItems.get(id);\n\t\tif (!list) {\n\t\t\tlist = new LinkedList();\n\t\t\tthis._menuItems.set(id, list);\n\t\t}\n\t\tconst rm = list.push(item);\n\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(id));\n\t\treturn markAsSingleton(toDisposable(() => {\n\t\t\trm();\n\t\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(id));\n\t\t}));\n\t}\n\n\tappendMenuItems(items: Iterable<{ id: MenuId; item: IMenuItem | ISubmenuItem }>): IDisposable {\n\t\tconst result = new DisposableStore();\n\t\tfor (const { id, item } of items) {\n\t\t\tresult.add(this.appendMenuItem(id, item));\n\t\t}\n\t\treturn result;\n\t}\n\n\tgetMenuItems(id: MenuId): Array<IMenuItem | ISubmenuItem> {\n\t\tlet result: Array<IMenuItem | ISubmenuItem>;\n\t\tif (this._menuItems.has(id)) {\n\t\t\tresult = [...this._menuItems.get(id)!];\n\t\t} else {\n\t\t\tresult = [];\n\t\t}\n\t\tif (id === MenuId.CommandPalette) {\n\t\t\t// CommandPalette is special because it shows\n\t\t\t// all commands by default\n\t\t\tthis._appendImplicitItems(result);\n\t\t}\n\t\treturn result;\n\t}\n\n\tprivate _appendImplicitItems(result: Array<IMenuItem | ISubmenuItem>) {\n\t\tconst set = new Set<string>();\n\n\t\tfor (const item of result) {\n\t\t\tif (isIMenuItem(item)) {\n\t\t\t\tset.add(item.command.id);\n\t\t\t\tif (item.alt) {\n\t\t\t\t\tset.add(item.alt.id);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tthis._commands.forEach((command, id) => {\n\t\t\tif (!set.has(id)) {\n\t\t\t\tresult.push({ command });\n\t\t\t}\n\t\t});\n\t}\n};\n\nexport class SubmenuItemAction extends SubmenuAction {\n\n\tconstructor(\n\t\treadonly item: ISubmenuItem,\n\t\treadonly hideActions: IMenuItemHide | undefined,\n\t\tactions: readonly IAction[],\n\t) {\n\t\tsuper(`submenuitem.${item.submenu.id}`, typeof item.title === 'string' ? item.title : item.title.value, actions, 'submenu');\n\t}\n}\n\nexport interface IMenuItemHide {\n\treadonly isHidden: boolean;\n\treadonly hide: IAction;\n\treadonly toggle: IAction;\n}\n\n// implements IAction, does NOT extend Action, so that no one\n// subscribes to events of Action or modified properties\nexport class MenuItemAction implements IAction {\n\n\tstatic label(action: ICommandAction, options?: IMenuActionOptions): string {\n\t\treturn options?.renderShortTitle && action.shortTitle\n\t\t\t? (typeof action.shortTitle === 'string' ? action.shortTitle : action.shortTitle.value)\n\t\t\t: (typeof action.title === 'string' ? action.title : action.title.value);\n\t}\n\n\treadonly item: ICommandAction;\n\treadonly alt: MenuItemAction | undefined;\n\n\tprivate readonly _options: IMenuActionOptions | undefined;\n\n\treadonly id: string;\n\treadonly label: string;\n\treadonly tooltip: string;\n\treadonly class: string | undefined;\n\treadonly enabled: boolean;\n\treadonly checked?: boolean;\n\n\tconstructor(\n\t\titem: ICommandAction,\n\t\talt: ICommandAction | undefined,\n\t\toptions: IMenuActionOptions | undefined,\n\t\treadonly hideActions: IMenuItemHide | undefined,\n\t\treadonly menuKeybinding: IAction | undefined,\n\t\t@IContextKeyService contextKeyService: IContextKeyService,\n\t\t@ICommandService private _commandService: ICommandService\n\t) {\n\t\tthis.id = item.id;\n\t\tthis.label = MenuItemAction.label(item, options);\n\t\tthis.tooltip = (typeof item.tooltip === 'string' ? item.tooltip : item.tooltip?.value) ?? '';\n\t\tthis.enabled = !item.precondition || contextKeyService.contextMatchesRules(item.precondition);\n\t\tthis.checked = undefined;\n\n\t\tlet icon: ThemeIcon | undefined;\n\n\t\tif (item.toggled) {\n\t\t\tconst toggled = ((item.toggled as { condition: ContextKeyExpression }).condition ? item.toggled : { condition: item.toggled }) as {\n\t\t\t\tcondition: ContextKeyExpression; icon?: Icon; tooltip?: string | ILocalizedString; title?: string | ILocalizedString;\n\t\t\t};\n\t\t\tthis.checked = contextKeyService.contextMatchesRules(toggled.condition);\n\t\t\tif (this.checked && toggled.tooltip) {\n\t\t\t\tthis.tooltip = typeof toggled.tooltip === 'string' ? toggled.tooltip : toggled.tooltip.value;\n\t\t\t}\n\n\t\t\tif (this.checked && ThemeIcon.isThemeIcon(toggled.icon)) {\n\t\t\t\ticon = toggled.icon;\n\t\t\t}\n\n\t\t\tif (this.checked && toggled.title) {\n\t\t\t\tthis.label = typeof toggled.title === 'string' ? toggled.title : toggled.title.value;\n\t\t\t}\n\t\t}\n\n\t\tif (!icon) {\n\t\t\ticon = ThemeIcon.isThemeIcon(item.icon) ? item.icon : undefined;\n\t\t}\n\n\t\tthis.item = item;\n\t\tthis.alt = alt ? new MenuItemAction(alt, undefined, options, hideActions, undefined, contextKeyService, _commandService) : undefined;\n\t\tthis._options = options;\n\t\tthis.class = icon && ThemeIcon.asClassName(icon);\n\n\t}\n\n\trun(...args: unknown[]): Promise<void> {\n\t\tlet runArgs: unknown[] = [];\n\n\t\tif (this._options?.arg) {\n\t\t\trunArgs = [...runArgs, this._options.arg];\n\t\t}\n\n\t\tif (this._options?.shouldForwardArgs) {\n\t\t\trunArgs = [...runArgs, ...args];\n\t\t}\n\n\t\treturn this._commandService.executeCommand(this.id, ...runArgs);\n\t}\n}\n\n//#region --- IAction2\n\ntype OneOrN<T> = T | T[];\n\ninterface IAction2CommonOptions extends ICommandAction {\n\t/**\n\t * One or many menu items.\n\t */\n\tmenu?: OneOrN<{ id: MenuId; precondition?: null } & Omit<IMenuItem, 'command'>>;\n\n\t/**\n\t * One keybinding.\n\t */\n\tkeybinding?: OneOrN<Omit<IKeybindingRule, 'id'>>;\n}\n\ninterface IBaseAction2Options extends IAction2CommonOptions {\n\n\t/**\n\t * This type is used when an action is not going to show up in the command palette.\n\t * In that case, it's able to use a string for the `title` and `category` properties.\n\t */\n\tf1?: false;\n}\n\nexport interface ICommandPaletteOptions extends IAction2CommonOptions {\n\n\t/**\n\t * The title of the command that will be displayed in the command palette after the category.\n\t * This overrides {@link ICommandAction.title} to ensure a string isn't used so that the title\n\t * includes the localized value and the original value for users using language packs.\n\t */\n\ttitle: ICommandActionTitle;\n\n\t/**\n\t * The category of the command that will be displayed in the command palette before the title suffixed.\n\t * with a colon This overrides {@link ICommandAction.title} to ensure a string isn't used so that\n\t * the title includes the localized value and the original value for users using language packs.\n\t */\n\tcategory?: keyof typeof Categories | ILocalizedString;\n\n\t/**\n\t * Shorthand to add this command to the command palette. Note: this is not the only way to declare that\n\t * a command should be in the command palette... however, enforcing ILocalizedString in the other scenarios\n\t * is much more challenging and this gets us most of the way there.\n\t */\n\tf1: true;\n}\n\nexport type IAction2Options = ICommandPaletteOptions | IBaseAction2Options;\n\nexport interface IAction2F1RequiredOptions {\n\ttitle: ICommandActionTitle;\n}\n\nexport abstract class Action2 {\n\tconstructor(readonly desc: Readonly<IAction2Options>) { }\n\tabstract run(accessor: ServicesAccessor, ...args: unknown[]): void;\n}\n\nexport function registerAction2(ctor: { new(): Action2 }): IDisposable {\n\tconst disposables: IDisposable[] = []; // not using `DisposableStore` to reduce startup perf cost\n\tconst action = new ctor();\n\n\tconst { f1, menu, keybinding, ...command } = action.desc;\n\n\tif (CommandsRegistry.getCommand(command.id)) {\n\t\tthrow new Error(`Cannot register two commands with the same id: ${command.id}`);\n\t}\n\n\t// command\n\tdisposables.push(CommandsRegistry.registerCommand({\n\t\tid: command.id,\n\t\thandler: (accessor, ...args) => action.run(accessor, ...args),\n\t\tmetadata: command.metadata ?? { description: action.desc.title }\n\t}));\n\n\t// menu\n\tif (Array.isArray(menu)) {\n\t\tfor (const item of menu) {\n\t\t\tdisposables.push(MenuRegistry.appendMenuItem(item.id, { command: { ...command, precondition: item.precondition === null ? undefined : command.precondition }, ...item }));\n\t\t}\n\n\t} else if (menu) {\n\t\tdisposables.push(MenuRegistry.appendMenuItem(menu.id, { command: { ...command, precondition: menu.precondition === null ? undefined : command.precondition }, ...menu }));\n\t}\n\tif (f1) {\n\t\tdisposables.push(MenuRegistry.appendMenuItem(MenuId.CommandPalette, { command, when: command.precondition }));\n\t\tdisposables.push(MenuRegistry.addCommand(command));\n\t}\n\n\t// keybinding\n\tif (Array.isArray(keybinding)) {\n\t\tfor (const item of keybinding) {\n\t\t\tdisposables.push(KeybindingsRegistry.registerKeybindingRule({\n\t\t\t\t...item,\n\t\t\t\tid: command.id,\n\t\t\t\twhen: command.precondition ? ContextKeyExpr.and(command.precondition, item.when) : item.when\n\t\t\t}));\n\t\t}\n\t} else if (keybinding) {\n\t\tdisposables.push(KeybindingsRegistry.registerKeybindingRule({\n\t\t\t...keybinding,\n\t\t\tid: command.id,\n\t\t\twhen: command.precondition ? ContextKeyExpr.and(command.precondition, keybinding.when) : keybinding.when\n\t\t}));\n\t}\n\n\treturn {\n\t\tdispose() {\n\t\t\tdispose(disposables);\n\t\t}\n\t};\n}\n//#endregion\n"]}
1
+ {"version":3,"sources":["file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src/vs/platform/actions/common/actions.ts","vs/platform/actions/common/actions.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;;;;;;;;;;;AAEhG,OAAO,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QAC/B,KAAK,MAAM,IAAI,IAAI,UAAU,EAAE,CAAC;YAC/B,WAAW,CAAC,IAAI,CAAC,mBAAmB,CAAC,sBAAsB,CAAC;gBAC3D,GAAG,IAAI;gBACP,EAAE,EAAE,OAAO,CAAC,EAAE;gBACd,IAAI,EAAE,OAAO,CAAC,YAAY,CAAC,CAAC,CAAC,cAAc,CAAC,GAAG,CAAC,OAAO,CAAC,YAAY,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI;aAC5F,CAAC,CAAC,CAAC;QACL,CAAC;IACF,CAAC;SAAM,IAAI,UAAU,EAAE,CAAC;QACvB,WAAW,CAAC,IAAI,CAAC,mBAAmB,CAAC,sBAAsB,CAAC;YAC3D,GAAG,UAAU;YACb,EAAE,EAAE,OAAO,CAAC,EAAE;YACd,IAAI,EAAE,OAAO,CAAC,YAAY,CAAC,CAAC,CAAC,cAAc,CAAC,GAAG,CAAC,OAAO,CAAC,YAAY,EAAE,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,IAAI;SACxG,CAAC,CAAC,CAAC;IACL,CAAC;IAED,OAAO;QACN,OAAO;YACN,OAAO,CAAC,WAAW,CAAC,CAAC;QACtB,CAAC;KACD,CAAC;AACH,CAAC;AACD,YAAY","file":"actions.js","sourceRoot":"file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport { IAction, SubmenuAction } from '../../../base/common/actions.js';\nimport { Event, MicrotaskEmitter } from '../../../base/common/event.js';\nimport { DisposableStore, dispose, IDisposable, markAsSingleton, toDisposable } from '../../../base/common/lifecycle.js';\nimport { LinkedList } from '../../../base/common/linkedList.js';\nimport { ThemeIcon } from '../../../base/common/themables.js';\nimport { ICommandAction, ICommandActionTitle, Icon, ILocalizedString } from '../../action/common/action.js';\nimport { Categories } from '../../action/common/actionCommonCategories.js';\nimport { CommandsRegistry, ICommandService } from '../../commands/common/commands.js';\nimport { ContextKeyExpr, ContextKeyExpression, IContextKeyService } from '../../contextkey/common/contextkey.js';\nimport { createDecorator, ServicesAccessor } from '../../instantiation/common/instantiation.js';\nimport { IKeybindingRule, KeybindingsRegistry } from '../../keybinding/common/keybindingsRegistry.js';\n\nexport interface IMenuItem {\n\tcommand: ICommandAction;\n\talt?: ICommandAction;\n\t/**\n\t * Menu item is hidden if this expression returns false.\n\t */\n\twhen?: ContextKeyExpression;\n\tgroup?: 'navigation' | string;\n\torder?: number;\n\tisHiddenByDefault?: boolean;\n}\n\nexport interface ISubmenuItem {\n\ttitle: string | ICommandActionTitle;\n\tsubmenu: MenuId;\n\ticon?: Icon;\n\twhen?: ContextKeyExpression;\n\tgroup?: 'navigation' | string;\n\torder?: number;\n\tisSelection?: boolean;\n\t/**\n\t * A split button shows the first action\n\t * as primary action and the rest of the\n\t * actions in a dropdown.\n\t *\n\t * Use `togglePrimaryAction` to promote\n\t * the action that was last used to be\n\t * the primary action and remember that\n\t * choice.\n\t */\n\tisSplitButton?: boolean | {\n\t\t/**\n\t\t * Will update the primary action based\n\t\t * on the action that was last run.\n\t\t */\n\t\ttogglePrimaryAction: true;\n\t};\n}\n\nexport function isIMenuItem(item: unknown): item is IMenuItem {\n\treturn (item as IMenuItem).command !== undefined;\n}\n\nexport function isISubmenuItem(item: unknown): item is ISubmenuItem {\n\treturn (item as ISubmenuItem).submenu !== undefined;\n}\n\nexport class MenuId {\n\n\tprivate static readonly _instances = new Map<string, MenuId>();\n\n\tstatic readonly CommandPalette = new MenuId('CommandPalette');\n\tstatic readonly DebugBreakpointsContext = new MenuId('DebugBreakpointsContext');\n\tstatic readonly DebugCallStackContext = new MenuId('DebugCallStackContext');\n\tstatic readonly DebugConsoleContext = new MenuId('DebugConsoleContext');\n\tstatic readonly DebugVariablesContext = new MenuId('DebugVariablesContext');\n\tstatic readonly NotebookVariablesContext = new MenuId('NotebookVariablesContext');\n\tstatic readonly DebugHoverContext = new MenuId('DebugHoverContext');\n\tstatic readonly DebugWatchContext = new MenuId('DebugWatchContext');\n\tstatic readonly DebugToolBar = new MenuId('DebugToolBar');\n\tstatic readonly DebugToolBarStop = new MenuId('DebugToolBarStop');\n\tstatic readonly DebugDisassemblyContext = new MenuId('DebugDisassemblyContext');\n\tstatic readonly DebugCallStackToolbar = new MenuId('DebugCallStackToolbar');\n\tstatic readonly DebugCreateConfiguration = new MenuId('DebugCreateConfiguration');\n\tstatic readonly DebugScopesContext = new MenuId('DebugScopesContext');\n\tstatic readonly EditorContext = new MenuId('EditorContext');\n\tstatic readonly SimpleEditorContext = new MenuId('SimpleEditorContext');\n\tstatic readonly EditorContent = new MenuId('EditorContent');\n\tstatic readonly EditorLineNumberContext = new MenuId('EditorLineNumberContext');\n\tstatic readonly EditorContextCopy = new MenuId('EditorContextCopy');\n\tstatic readonly EditorContextPeek = new MenuId('EditorContextPeek');\n\tstatic readonly EditorContextShare = new MenuId('EditorContextShare');\n\tstatic readonly EditorTitle = new MenuId('EditorTitle');\n\tstatic readonly CompactWindowEditorTitle = new MenuId('CompactWindowEditorTitle');\n\tstatic readonly EditorTitleRun = new MenuId('EditorTitleRun');\n\tstatic readonly EditorTitleContext = new MenuId('EditorTitleContext');\n\tstatic readonly EditorTitleContextShare = new MenuId('EditorTitleContextShare');\n\tstatic readonly EmptyEditorGroup = new MenuId('EmptyEditorGroup');\n\tstatic readonly EmptyEditorGroupContext = new MenuId('EmptyEditorGroupContext');\n\tstatic readonly EditorTabsBarContext = new MenuId('EditorTabsBarContext');\n\tstatic readonly EditorTabsBarShowTabsSubmenu = new MenuId('EditorTabsBarShowTabsSubmenu');\n\tstatic readonly EditorTabsBarShowTabsZenModeSubmenu = new MenuId('EditorTabsBarShowTabsZenModeSubmenu');\n\tstatic readonly EditorActionsPositionSubmenu = new MenuId('EditorActionsPositionSubmenu');\n\tstatic readonly EditorSplitMoveSubmenu = new MenuId('EditorSplitMoveSubmenu');\n\tstatic readonly ExplorerContext = new MenuId('ExplorerContext');\n\tstatic readonly ExplorerContextShare = new MenuId('ExplorerContextShare');\n\tstatic readonly ExtensionContext = new MenuId('ExtensionContext');\n\tstatic readonly ExtensionEditorContextMenu = new MenuId('ExtensionEditorContextMenu');\n\tstatic readonly GlobalActivity = new MenuId('GlobalActivity');\n\tstatic readonly CommandCenter = new MenuId('CommandCenter');\n\tstatic readonly CommandCenterCenter = new MenuId('CommandCenterCenter');\n\tstatic readonly LayoutControlMenuSubmenu = new MenuId('LayoutControlMenuSubmenu');\n\tstatic readonly LayoutControlMenu = new MenuId('LayoutControlMenu');\n\tstatic readonly MenubarMainMenu = new MenuId('MenubarMainMenu');\n\tstatic readonly MenubarAppearanceMenu = new MenuId('MenubarAppearanceMenu');\n\tstatic readonly MenubarDebugMenu = new MenuId('MenubarDebugMenu');\n\tstatic readonly MenubarEditMenu = new MenuId('MenubarEditMenu');\n\tstatic readonly MenubarCopy = new MenuId('MenubarCopy');\n\tstatic readonly MenubarFileMenu = new MenuId('MenubarFileMenu');\n\tstatic readonly MenubarGoMenu = new MenuId('MenubarGoMenu');\n\tstatic readonly MenubarHelpMenu = new MenuId('MenubarHelpMenu');\n\tstatic readonly MenubarLayoutMenu = new MenuId('MenubarLayoutMenu');\n\tstatic readonly MenubarNewBreakpointMenu = new MenuId('MenubarNewBreakpointMenu');\n\tstatic readonly PanelAlignmentMenu = new MenuId('PanelAlignmentMenu');\n\tstatic readonly PanelPositionMenu = new MenuId('PanelPositionMenu');\n\tstatic readonly ActivityBarPositionMenu = new MenuId('ActivityBarPositionMenu');\n\tstatic readonly MenubarPreferencesMenu = new MenuId('MenubarPreferencesMenu');\n\tstatic readonly MenubarRecentMenu = new MenuId('MenubarRecentMenu');\n\tstatic readonly MenubarSelectionMenu = new MenuId('MenubarSelectionMenu');\n\tstatic readonly MenubarShare = new MenuId('MenubarShare');\n\tstatic readonly MenubarSwitchEditorMenu = new MenuId('MenubarSwitchEditorMenu');\n\tstatic readonly MenubarSwitchGroupMenu = new MenuId('MenubarSwitchGroupMenu');\n\tstatic readonly MenubarTerminalMenu = new MenuId('MenubarTerminalMenu');\n\tstatic readonly MenubarTerminalSuggestStatusMenu = new MenuId('MenubarTerminalSuggestStatusMenu');\n\tstatic readonly MenubarViewMenu = new MenuId('MenubarViewMenu');\n\tstatic readonly MenubarHomeMenu = new MenuId('MenubarHomeMenu');\n\tstatic readonly OpenEditorsContext = new MenuId('OpenEditorsContext');\n\tstatic readonly OpenEditorsContextShare = new MenuId('OpenEditorsContextShare');\n\tstatic readonly ProblemsPanelContext = new MenuId('ProblemsPanelContext');\n\tstatic readonly SCMInputBox = new MenuId('SCMInputBox');\n\tstatic readonly SCMChangeContext = new MenuId('SCMChangeContext');\n\tstatic readonly SCMResourceContext = new MenuId('SCMResourceContext');\n\tstatic readonly SCMResourceContextShare = new MenuId('SCMResourceContextShare');\n\tstatic readonly SCMResourceFolderContext = new MenuId('SCMResourceFolderContext');\n\tstatic readonly SCMResourceGroupContext = new MenuId('SCMResourceGroupContext');\n\tstatic readonly SCMSourceControl = new MenuId('SCMSourceControl');\n\tstatic readonly SCMSourceControlInline = new MenuId('SCMSourceControlInline');\n\tstatic readonly SCMSourceControlTitle = new MenuId('SCMSourceControlTitle');\n\tstatic readonly SCMHistoryTitle = new MenuId('SCMHistoryTitle');\n\tstatic readonly SCMHistoryItemContext = new MenuId('SCMHistoryItemContext');\n\tstatic readonly SCMHistoryItemChangeContext = new MenuId('SCMHistoryItemChangeContext');\n\tstatic readonly SCMHistoryItemRefContext = new MenuId('SCMHistoryItemRefContext');\n\tstatic readonly SCMArtifactGroupContext = new MenuId('SCMArtifactGroupContext');\n\tstatic readonly SCMArtifactContext = new MenuId('SCMArtifactContext');\n\tstatic readonly SCMQuickDiffDecorations = new MenuId('SCMQuickDiffDecorations');\n\tstatic readonly SCMTitle = new MenuId('SCMTitle');\n\tstatic readonly SearchContext = new MenuId('SearchContext');\n\tstatic readonly SearchActionMenu = new MenuId('SearchActionContext');\n\tstatic readonly StatusBarWindowIndicatorMenu = new MenuId('StatusBarWindowIndicatorMenu');\n\tstatic readonly StatusBarRemoteIndicatorMenu = new MenuId('StatusBarRemoteIndicatorMenu');\n\tstatic readonly StickyScrollContext = new MenuId('StickyScrollContext');\n\tstatic readonly TestItem = new MenuId('TestItem');\n\tstatic readonly TestItemGutter = new MenuId('TestItemGutter');\n\tstatic readonly TestProfilesContext = new MenuId('TestProfilesContext');\n\tstatic readonly TestMessageContext = new MenuId('TestMessageContext');\n\tstatic readonly TestMessageContent = new MenuId('TestMessageContent');\n\tstatic readonly TestPeekElement = new MenuId('TestPeekElement');\n\tstatic readonly TestPeekTitle = new MenuId('TestPeekTitle');\n\tstatic readonly TestCallStack = new MenuId('TestCallStack');\n\tstatic readonly TestCoverageFilterItem = new MenuId('TestCoverageFilterItem');\n\tstatic readonly TouchBarContext = new MenuId('TouchBarContext');\n\tstatic readonly TitleBar = new MenuId('TitleBar');\n\tstatic readonly TitleBarContext = new MenuId('TitleBarContext');\n\tstatic readonly TitleBarTitleContext = new MenuId('TitleBarTitleContext');\n\tstatic readonly TunnelContext = new MenuId('TunnelContext');\n\tstatic readonly TunnelPrivacy = new MenuId('TunnelPrivacy');\n\tstatic readonly TunnelProtocol = new MenuId('TunnelProtocol');\n\tstatic readonly TunnelPortInline = new MenuId('TunnelInline');\n\tstatic readonly TunnelTitle = new MenuId('TunnelTitle');\n\tstatic readonly TunnelLocalAddressInline = new MenuId('TunnelLocalAddressInline');\n\tstatic readonly TunnelOriginInline = new MenuId('TunnelOriginInline');\n\tstatic readonly ViewItemContext = new MenuId('ViewItemContext');\n\tstatic readonly ViewContainerTitle = new MenuId('ViewContainerTitle');\n\tstatic readonly ViewContainerTitleContext = new MenuId('ViewContainerTitleContext');\n\tstatic readonly ViewTitle = new MenuId('ViewTitle');\n\tstatic readonly ViewTitleContext = new MenuId('ViewTitleContext');\n\tstatic readonly CommentEditorActions = new MenuId('CommentEditorActions');\n\tstatic readonly CommentThreadTitle = new MenuId('CommentThreadTitle');\n\tstatic readonly CommentThreadActions = new MenuId('CommentThreadActions');\n\tstatic readonly CommentThreadAdditionalActions = new MenuId('CommentThreadAdditionalActions');\n\tstatic readonly CommentThreadTitleContext = new MenuId('CommentThreadTitleContext');\n\tstatic readonly CommentThreadCommentContext = new MenuId('CommentThreadCommentContext');\n\tstatic readonly CommentTitle = new MenuId('CommentTitle');\n\tstatic readonly CommentActions = new MenuId('CommentActions');\n\tstatic readonly CommentsViewThreadActions = new MenuId('CommentsViewThreadActions');\n\tstatic readonly InteractiveToolbar = new MenuId('InteractiveToolbar');\n\tstatic readonly InteractiveCellTitle = new MenuId('InteractiveCellTitle');\n\tstatic readonly InteractiveCellDelete = new MenuId('InteractiveCellDelete');\n\tstatic readonly InteractiveCellExecute = new MenuId('InteractiveCellExecute');\n\tstatic readonly InteractiveInputExecute = new MenuId('InteractiveInputExecute');\n\tstatic readonly InteractiveInputConfig = new MenuId('InteractiveInputConfig');\n\tstatic readonly ReplInputExecute = new MenuId('ReplInputExecute');\n\tstatic readonly IssueReporter = new MenuId('IssueReporter');\n\tstatic readonly NotebookToolbar = new MenuId('NotebookToolbar');\n\tstatic readonly NotebookToolbarContext = new MenuId('NotebookToolbarContext');\n\tstatic readonly NotebookStickyScrollContext = new MenuId('NotebookStickyScrollContext');\n\tstatic readonly NotebookCellTitle = new MenuId('NotebookCellTitle');\n\tstatic readonly NotebookCellDelete = new MenuId('NotebookCellDelete');\n\tstatic readonly NotebookCellInsert = new MenuId('NotebookCellInsert');\n\tstatic readonly NotebookCellBetween = new MenuId('NotebookCellBetween');\n\tstatic readonly NotebookCellListTop = new MenuId('NotebookCellTop');\n\tstatic readonly NotebookCellExecute = new MenuId('NotebookCellExecute');\n\tstatic readonly NotebookCellExecuteGoTo = new MenuId('NotebookCellExecuteGoTo');\n\tstatic readonly NotebookCellExecutePrimary = new MenuId('NotebookCellExecutePrimary');\n\tstatic readonly NotebookDiffCellInputTitle = new MenuId('NotebookDiffCellInputTitle');\n\tstatic readonly NotebookDiffDocumentMetadata = new MenuId('NotebookDiffDocumentMetadata');\n\tstatic readonly NotebookDiffCellMetadataTitle = new MenuId('NotebookDiffCellMetadataTitle');\n\tstatic readonly NotebookDiffCellOutputsTitle = new MenuId('NotebookDiffCellOutputsTitle');\n\tstatic readonly NotebookOutputToolbar = new MenuId('NotebookOutputToolbar');\n\tstatic readonly NotebookOutlineFilter = new MenuId('NotebookOutlineFilter');\n\tstatic readonly NotebookOutlineActionMenu = new MenuId('NotebookOutlineActionMenu');\n\tstatic readonly NotebookEditorLayoutConfigure = new MenuId('NotebookEditorLayoutConfigure');\n\tstatic readonly NotebookKernelSource = new MenuId('NotebookKernelSource');\n\tstatic readonly BulkEditTitle = new MenuId('BulkEditTitle');\n\tstatic readonly BulkEditContext = new MenuId('BulkEditContext');\n\tstatic readonly TimelineItemContext = new MenuId('TimelineItemContext');\n\tstatic readonly TimelineTitle = new MenuId('TimelineTitle');\n\tstatic readonly TimelineTitleContext = new MenuId('TimelineTitleContext');\n\tstatic readonly TimelineFilterSubMenu = new MenuId('TimelineFilterSubMenu');\n\tstatic readonly AccountsContext = new MenuId('AccountsContext');\n\tstatic readonly SidebarTitle = new MenuId('SidebarTitle');\n\tstatic readonly PanelTitle = new MenuId('PanelTitle');\n\tstatic readonly AuxiliaryBarTitle = new MenuId('AuxiliaryBarTitle');\n\tstatic readonly TerminalInstanceContext = new MenuId('TerminalInstanceContext');\n\tstatic readonly TerminalEditorInstanceContext = new MenuId('TerminalEditorInstanceContext');\n\tstatic readonly TerminalNewDropdownContext = new MenuId('TerminalNewDropdownContext');\n\tstatic readonly TerminalTabContext = new MenuId('TerminalTabContext');\n\tstatic readonly TerminalTabEmptyAreaContext = new MenuId('TerminalTabEmptyAreaContext');\n\tstatic readonly TerminalStickyScrollContext = new MenuId('TerminalStickyScrollContext');\n\tstatic readonly WebviewContext = new MenuId('WebviewContext');\n\tstatic readonly InlineCompletionsActions = new MenuId('InlineCompletionsActions');\n\tstatic readonly InlineEditsActions = new MenuId('InlineEditsActions');\n\tstatic readonly NewFile = new MenuId('NewFile');\n\tstatic readonly MergeInput1Toolbar = new MenuId('MergeToolbar1Toolbar');\n\tstatic readonly MergeInput2Toolbar = new MenuId('MergeToolbar2Toolbar');\n\tstatic readonly MergeBaseToolbar = new MenuId('MergeBaseToolbar');\n\tstatic readonly MergeInputResultToolbar = new MenuId('MergeToolbarResultToolbar');\n\tstatic readonly InlineSuggestionToolbar = new MenuId('InlineSuggestionToolbar');\n\tstatic readonly InlineEditToolbar = new MenuId('InlineEditToolbar');\n\tstatic readonly ChatContext = new MenuId('ChatContext');\n\tstatic readonly ChatCodeBlock = new MenuId('ChatCodeblock');\n\tstatic readonly ChatCompareBlock = new MenuId('ChatCompareBlock');\n\tstatic readonly ChatMessageTitle = new MenuId('ChatMessageTitle');\n\tstatic readonly ChatWelcomeContext = new MenuId('ChatWelcomeContext');\n\tstatic readonly ChatMessageFooter = new MenuId('ChatMessageFooter');\n\tstatic readonly ChatExecute = new MenuId('ChatExecute');\n\tstatic readonly ChatExecuteQueue = new MenuId('ChatExecuteQueue');\n\tstatic readonly ChatInput = new MenuId('ChatInput');\n\tstatic readonly ChatInputSide = new MenuId('ChatInputSide');\n\tstatic readonly ChatModePicker = new MenuId('ChatModePicker');\n\tstatic readonly ChatEditingWidgetToolbar = new MenuId('ChatEditingWidgetToolbar');\n\tstatic readonly ChatEditingSessionChangesToolbar = new MenuId('ChatEditingSessionChangesToolbar');\n\tstatic readonly ChatEditingEditorContent = new MenuId('ChatEditingEditorContent');\n\tstatic readonly ChatEditingEditorHunk = new MenuId('ChatEditingEditorHunk');\n\tstatic readonly ChatEditingDeletedNotebookCell = new MenuId('ChatEditingDeletedNotebookCell');\n\tstatic readonly ChatInputAttachmentToolbar = new MenuId('ChatInputAttachmentToolbar');\n\tstatic readonly ChatEditingWidgetModifiedFilesToolbar = new MenuId('ChatEditingWidgetModifiedFilesToolbar');\n\tstatic readonly ChatInputResourceAttachmentContext = new MenuId('ChatInputResourceAttachmentContext');\n\tstatic readonly ChatInputSymbolAttachmentContext = new MenuId('ChatInputSymbolAttachmentContext');\n\tstatic readonly ChatInlineResourceAnchorContext = new MenuId('ChatInlineResourceAnchorContext');\n\tstatic readonly ChatInlineSymbolAnchorContext = new MenuId('ChatInlineSymbolAnchorContext');\n\tstatic readonly ChatMessageCheckpoint: MenuId = new MenuId('ChatMessageCheckpoint');\n\tstatic readonly ChatMessageRestoreCheckpoint: MenuId = new MenuId('ChatMessageRestoreCheckpoint');\n\tstatic readonly ChatNewMenu = new MenuId('ChatNewMenu');\n\tstatic readonly ChatEditingCodeBlockContext = new MenuId('ChatEditingCodeBlockContext');\n\tstatic readonly ChatTitleBarMenu = new MenuId('ChatTitleBarMenu');\n\tstatic readonly ChatAttachmentsContext = new MenuId('ChatAttachmentsContext');\n\tstatic readonly ChatToolOutputResourceToolbar = new MenuId('ChatToolOutputResourceToolbar');\n\tstatic readonly ChatTextEditorMenu = new MenuId('ChatTextEditorMenu');\n\tstatic readonly ChatToolOutputResourceContext = new MenuId('ChatToolOutputResourceContext');\n\tstatic readonly ChatMultiDiffContext = new MenuId('ChatMultiDiffContext');\n\tstatic readonly ChatConfirmationMenu = new MenuId('ChatConfirmationMenu');\n\tstatic readonly ChatEditorInlineGutter = new MenuId('ChatEditorInlineGutter');\n\tstatic readonly ChatEditorInlineExecute = new MenuId('ChatEditorInputExecute');\n\tstatic readonly ChatEditorInlineInputSide = new MenuId('ChatEditorInputSide');\n\tstatic readonly InlineChatEditorAffordance = new MenuId('InlineChatEditorAffordance');\n\tstatic readonly AccessibleView = new MenuId('AccessibleView');\n\tstatic readonly MultiDiffEditorContent = new MenuId('MultiDiffEditorContent');\n\tstatic readonly MultiDiffEditorFileToolbar = new MenuId('MultiDiffEditorFileToolbar');\n\tstatic readonly DiffEditorHunkToolbar = new MenuId('DiffEditorHunkToolbar');\n\tstatic readonly DiffEditorSelectionToolbar = new MenuId('DiffEditorSelectionToolbar');\n\tstatic readonly BrowserNavigationToolbar = new MenuId('BrowserNavigationToolbar');\n\tstatic readonly BrowserActionsToolbar = new MenuId('BrowserActionsToolbar');\n\tstatic readonly AgentSessionsViewerFilterSubMenu = new MenuId('AgentSessionsViewerFilterSubMenu');\n\tstatic readonly AgentSessionsContext = new MenuId('AgentSessionsContext');\n\tstatic readonly AgentSessionSectionContext = new MenuId('AgentSessionSectionContext');\n\tstatic readonly AgentSessionsCreateSubMenu = new MenuId('AgentSessionsCreateSubMenu');\n\tstatic readonly AgentSessionsToolbar = new MenuId('AgentSessionsToolbar');\n\tstatic readonly AgentSessionItemToolbar = new MenuId('AgentSessionItemToolbar');\n\tstatic readonly AgentSessionSectionToolbar = new MenuId('AgentSessionSectionToolbar');\n\tstatic readonly AgentsTitleBarControlMenu = new MenuId('AgentsTitleBarControlMenu');\n\tstatic readonly ChatViewSessionTitleNavigationToolbar = new MenuId('ChatViewSessionTitleNavigationToolbar');\n\tstatic readonly ChatViewSessionTitleToolbar = new MenuId('ChatViewSessionTitleToolbar');\n\tstatic readonly ChatContextUsageActions = new MenuId('ChatContextUsageActions');\n\n\treadonly id: string;\n\n\t/**\n\t * Create a new `MenuId` with the unique identifier. Will throw if a menu\n\t * with the identifier already exists, use `MenuId.for(ident)` or a unique\n\t * identifier\n\t */\n\tconstructor(identifier: string) {\n\t\tif (MenuId._instances.has(identifier)) {\n\t\t\tthrow new TypeError(`MenuId with identifier '${identifier}' already exists. Use MenuId.for(ident) or a unique identifier`);\n\t\t}\n\t\tMenuId._instances.set(identifier, this);\n\t\tthis.id = identifier;\n\t}\n}\n\nexport interface IMenuActionOptions {\n\targ?: unknown;\n\targs?: unknown[];\n\tshouldForwardArgs?: boolean;\n\trenderShortTitle?: boolean;\n}\n\nexport interface IMenuChangeEvent {\n\treadonly menu: IMenu;\n\treadonly isStructuralChange: boolean;\n\treadonly isToggleChange: boolean;\n\treadonly isEnablementChange: boolean;\n}\n\nexport interface IMenu extends IDisposable {\n\treadonly onDidChange: Event<IMenuChangeEvent>;\n\tgetActions(options?: IMenuActionOptions): [string, Array<MenuItemAction | SubmenuItemAction>][];\n}\n\nexport const IMenuService = createDecorator<IMenuService>('menuService');\n\nexport interface IMenuCreateOptions {\n\temitEventsForSubmenuChanges?: boolean;\n\teventDebounceDelay?: number;\n}\n\nexport interface IMenuService {\n\n\treadonly _serviceBrand: undefined;\n\n\t/**\n\t * Consider using getMenuActions if you don't need to listen to events.\n\t *\n\t * Create a new menu for the given menu identifier. A menu sends events when it's entries\n\t * have changed (placement, enablement, checked-state). By default it does not send events for\n\t * submenu entries. That is more expensive and must be explicitly enabled with the\n\t * `emitEventsForSubmenuChanges` flag.\n\t */\n\tcreateMenu(id: MenuId, contextKeyService: IContextKeyService, options?: IMenuCreateOptions): IMenu;\n\n\t/**\n\t * Creates a new menu, gets the actions, and then disposes of the menu.\n\t */\n\tgetMenuActions(id: MenuId, contextKeyService: IContextKeyService, options?: IMenuActionOptions): [string, Array<MenuItemAction | SubmenuItemAction>][];\n\n\t/**\n\t * Reset **all** menu item hidden states.\n\t */\n\tresetHiddenStates(): void;\n\n\t/**\n\t * Reset the menu's hidden states.\n\t */\n\tresetHiddenStates(menuIds: readonly MenuId[] | undefined): void;\n}\n\ntype ICommandsMap = Map<string, ICommandAction>;\n\nexport interface IMenuRegistryChangeEvent {\n\thas(id: MenuId): boolean;\n}\n\nclass MenuRegistryChangeEvent {\n\n\tprivate static _all = new Map<MenuId, MenuRegistryChangeEvent>();\n\n\tstatic for(id: MenuId): MenuRegistryChangeEvent {\n\t\tlet value = this._all.get(id);\n\t\tif (!value) {\n\t\t\tvalue = new MenuRegistryChangeEvent(id);\n\t\t\tthis._all.set(id, value);\n\t\t}\n\t\treturn value;\n\t}\n\n\tstatic merge(events: IMenuRegistryChangeEvent[]): IMenuRegistryChangeEvent {\n\t\tconst ids = new Set<MenuId>();\n\t\tfor (const item of events) {\n\t\t\tif (item instanceof MenuRegistryChangeEvent) {\n\t\t\t\tids.add(item.id);\n\t\t\t}\n\t\t}\n\t\treturn ids;\n\t}\n\n\treadonly has: (id: MenuId) => boolean;\n\n\tprivate constructor(private readonly id: MenuId) {\n\t\tthis.has = candidate => candidate === id;\n\t}\n}\n\nexport interface IMenuRegistry {\n\treadonly onDidChangeMenu: Event<IMenuRegistryChangeEvent>;\n\taddCommand(userCommand: ICommandAction): IDisposable;\n\tappendMenuItem(menu: MenuId, item: IMenuItem | ISubmenuItem): IDisposable;\n\tgetMenuItems(loc: MenuId): Array<IMenuItem | ISubmenuItem>;\n}\n\nexport const MenuRegistry: IMenuRegistry = new class implements IMenuRegistry {\n\n\tprivate readonly _commands = new Map<string, ICommandAction>();\n\tprivate readonly _menuItems = new Map<MenuId, LinkedList<IMenuItem | ISubmenuItem>>();\n\tprivate readonly _onDidChangeMenu = new MicrotaskEmitter<IMenuRegistryChangeEvent>({\n\t\tmerge: MenuRegistryChangeEvent.merge\n\t});\n\n\treadonly onDidChangeMenu: Event<IMenuRegistryChangeEvent> = this._onDidChangeMenu.event;\n\n\taddCommand(command: ICommandAction): IDisposable {\n\t\tthis._commands.set(command.id, command);\n\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(MenuId.CommandPalette));\n\n\t\treturn markAsSingleton(toDisposable(() => {\n\t\t\tif (this._commands.delete(command.id)) {\n\t\t\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(MenuId.CommandPalette));\n\t\t\t}\n\t\t}));\n\t}\n\n\tgetCommand(id: string): ICommandAction | undefined {\n\t\treturn this._commands.get(id);\n\t}\n\n\tgetCommands(): ICommandsMap {\n\t\tconst map = new Map<string, ICommandAction>();\n\t\tthis._commands.forEach((value, key) => map.set(key, value));\n\t\treturn map;\n\t}\n\n\tappendMenuItem(id: MenuId, item: IMenuItem | ISubmenuItem): IDisposable {\n\t\tlet list = this._menuItems.get(id);\n\t\tif (!list) {\n\t\t\tlist = new LinkedList();\n\t\t\tthis._menuItems.set(id, list);\n\t\t}\n\t\tconst rm = list.push(item);\n\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(id));\n\t\treturn markAsSingleton(toDisposable(() => {\n\t\t\trm();\n\t\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(id));\n\t\t}));\n\t}\n\n\tappendMenuItems(items: Iterable<{ id: MenuId; item: IMenuItem | ISubmenuItem }>): IDisposable {\n\t\tconst result = new DisposableStore();\n\t\tfor (const { id, item } of items) {\n\t\t\tresult.add(this.appendMenuItem(id, item));\n\t\t}\n\t\treturn result;\n\t}\n\n\tgetMenuItems(id: MenuId): Array<IMenuItem | ISubmenuItem> {\n\t\tlet result: Array<IMenuItem | ISubmenuItem>;\n\t\tif (this._menuItems.has(id)) {\n\t\t\tresult = [...this._menuItems.get(id)!];\n\t\t} else {\n\t\t\tresult = [];\n\t\t}\n\t\tif (id === MenuId.CommandPalette) {\n\t\t\t// CommandPalette is special because it shows\n\t\t\t// all commands by default\n\t\t\tthis._appendImplicitItems(result);\n\t\t}\n\t\treturn result;\n\t}\n\n\tprivate _appendImplicitItems(result: Array<IMenuItem | ISubmenuItem>) {\n\t\tconst set = new Set<string>();\n\n\t\tfor (const item of result) {\n\t\t\tif (isIMenuItem(item)) {\n\t\t\t\tset.add(item.command.id);\n\t\t\t\tif (item.alt) {\n\t\t\t\t\tset.add(item.alt.id);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tthis._commands.forEach((command, id) => {\n\t\t\tif (!set.has(id)) {\n\t\t\t\tresult.push({ command });\n\t\t\t}\n\t\t});\n\t}\n};\n\nexport class SubmenuItemAction extends SubmenuAction {\n\n\tconstructor(\n\t\treadonly item: ISubmenuItem,\n\t\treadonly hideActions: IMenuItemHide | undefined,\n\t\tactions: readonly IAction[],\n\t) {\n\t\tsuper(`submenuitem.${item.submenu.id}`, typeof item.title === 'string' ? item.title : item.title.value, actions, 'submenu');\n\t}\n}\n\nexport interface IMenuItemHide {\n\treadonly isHidden: boolean;\n\treadonly hide: IAction;\n\treadonly toggle: IAction;\n}\n\n// implements IAction, does NOT extend Action, so that no one\n// subscribes to events of Action or modified properties\nexport class MenuItemAction implements IAction {\n\n\tstatic label(action: ICommandAction, options?: IMenuActionOptions): string {\n\t\treturn options?.renderShortTitle && action.shortTitle\n\t\t\t? (typeof action.shortTitle === 'string' ? action.shortTitle : action.shortTitle.value)\n\t\t\t: (typeof action.title === 'string' ? action.title : action.title.value);\n\t}\n\n\treadonly item: ICommandAction;\n\treadonly alt: MenuItemAction | undefined;\n\n\tprivate readonly _options: IMenuActionOptions | undefined;\n\n\treadonly id: string;\n\treadonly label: string;\n\treadonly tooltip: string;\n\treadonly class: string | undefined;\n\treadonly enabled: boolean;\n\treadonly checked?: boolean;\n\n\tconstructor(\n\t\titem: ICommandAction,\n\t\talt: ICommandAction | undefined,\n\t\toptions: IMenuActionOptions | undefined,\n\t\treadonly hideActions: IMenuItemHide | undefined,\n\t\treadonly menuKeybinding: IAction | undefined,\n\t\t@IContextKeyService contextKeyService: IContextKeyService,\n\t\t@ICommandService private _commandService: ICommandService\n\t) {\n\t\tthis.id = item.id;\n\t\tthis.label = MenuItemAction.label(item, options);\n\t\tthis.tooltip = (typeof item.tooltip === 'string' ? item.tooltip : item.tooltip?.value) ?? '';\n\t\tthis.enabled = !item.precondition || contextKeyService.contextMatchesRules(item.precondition);\n\t\tthis.checked = undefined;\n\n\t\tlet icon: ThemeIcon | undefined;\n\n\t\tif (item.toggled) {\n\t\t\tconst toggled = ((item.toggled as { condition: ContextKeyExpression }).condition ? item.toggled : { condition: item.toggled }) as {\n\t\t\t\tcondition: ContextKeyExpression; icon?: Icon; tooltip?: string | ILocalizedString; title?: string | ILocalizedString;\n\t\t\t};\n\t\t\tthis.checked = contextKeyService.contextMatchesRules(toggled.condition);\n\t\t\tif (this.checked && toggled.tooltip) {\n\t\t\t\tthis.tooltip = typeof toggled.tooltip === 'string' ? toggled.tooltip : toggled.tooltip.value;\n\t\t\t}\n\n\t\t\tif (this.checked && ThemeIcon.isThemeIcon(toggled.icon)) {\n\t\t\t\ticon = toggled.icon;\n\t\t\t}\n\n\t\t\tif (this.checked && toggled.title) {\n\t\t\t\tthis.label = typeof toggled.title === 'string' ? toggled.title : toggled.title.value;\n\t\t\t}\n\t\t}\n\n\t\tif (!icon) {\n\t\t\ticon = ThemeIcon.isThemeIcon(item.icon) ? item.icon : undefined;\n\t\t}\n\n\t\tthis.item = item;\n\t\tthis.alt = alt ? new MenuItemAction(alt, undefined, options, hideActions, undefined, contextKeyService, _commandService) : undefined;\n\t\tthis._options = options;\n\t\tthis.class = icon && ThemeIcon.asClassName(icon);\n\n\t}\n\n\trun(...args: unknown[]): Promise<void> {\n\t\tlet runArgs: unknown[] = [];\n\n\t\tif (this._options?.args) {\n\t\t\trunArgs = [...runArgs, ...this._options.args];\n\t\t} else if (this._options?.arg) {\n\t\t\trunArgs = [...runArgs, this._options.arg];\n\t\t}\n\n\t\tif (this._options?.shouldForwardArgs) {\n\t\t\trunArgs = [...runArgs, ...args];\n\t\t}\n\n\t\treturn this._commandService.executeCommand(this.id, ...runArgs);\n\t}\n}\n\n//#region --- IAction2\n\ntype OneOrN<T> = T | T[];\n\ninterface IAction2CommonOptions extends ICommandAction {\n\t/**\n\t * One or many menu items.\n\t */\n\tmenu?: OneOrN<{ id: MenuId; precondition?: null } & Omit<IMenuItem, 'command'>>;\n\n\t/**\n\t * One keybinding.\n\t */\n\tkeybinding?: OneOrN<Omit<IKeybindingRule, 'id'>>;\n}\n\ninterface IBaseAction2Options extends IAction2CommonOptions {\n\n\t/**\n\t * This type is used when an action is not going to show up in the command palette.\n\t * In that case, it's able to use a string for the `title` and `category` properties.\n\t */\n\tf1?: false;\n}\n\nexport interface ICommandPaletteOptions extends IAction2CommonOptions {\n\n\t/**\n\t * The title of the command that will be displayed in the command palette after the category.\n\t * This overrides {@link ICommandAction.title} to ensure a string isn't used so that the title\n\t * includes the localized value and the original value for users using language packs.\n\t */\n\ttitle: ICommandActionTitle;\n\n\t/**\n\t * The category of the command that will be displayed in the command palette before the title suffixed.\n\t * with a colon This overrides {@link ICommandAction.title} to ensure a string isn't used so that\n\t * the title includes the localized value and the original value for users using language packs.\n\t */\n\tcategory?: keyof typeof Categories | ILocalizedString;\n\n\t/**\n\t * Shorthand to add this command to the command palette. Note: this is not the only way to declare that\n\t * a command should be in the command palette... however, enforcing ILocalizedString in the other scenarios\n\t * is much more challenging and this gets us most of the way there.\n\t */\n\tf1: true;\n}\n\nexport type IAction2Options = ICommandPaletteOptions | IBaseAction2Options;\n\nexport interface IAction2F1RequiredOptions {\n\ttitle: ICommandActionTitle;\n}\n\nexport abstract class Action2 {\n\tconstructor(readonly desc: Readonly<IAction2Options>) { }\n\tabstract run(accessor: ServicesAccessor, ...args: unknown[]): void;\n}\n\nexport function registerAction2(ctor: { new(): Action2 }): IDisposable {\n\tconst disposables: IDisposable[] = []; // not using `DisposableStore` to reduce startup perf cost\n\tconst action = new ctor();\n\n\tconst { f1, menu, keybinding, ...command } = action.desc;\n\n\tif (CommandsRegistry.getCommand(command.id)) {\n\t\tthrow new Error(`Cannot register two commands with the same id: ${command.id}`);\n\t}\n\n\t// command\n\tdisposables.push(CommandsRegistry.registerCommand({\n\t\tid: command.id,\n\t\thandler: (accessor, ...args) => action.run(accessor, ...args),\n\t\tmetadata: command.metadata ?? { description: action.desc.title }\n\t}));\n\n\t// menu\n\tif (Array.isArray(menu)) {\n\t\tfor (const item of menu) {\n\t\t\tdisposables.push(MenuRegistry.appendMenuItem(item.id, { command: { ...command, precondition: item.precondition === null ? undefined : command.precondition }, ...item }));\n\t\t}\n\n\t} else if (menu) {\n\t\tdisposables.push(MenuRegistry.appendMenuItem(menu.id, { command: { ...command, precondition: menu.precondition === null ? undefined : command.precondition }, ...menu }));\n\t}\n\tif (f1) {\n\t\tdisposables.push(MenuRegistry.appendMenuItem(MenuId.CommandPalette, { command, when: command.precondition }));\n\t\tdisposables.push(MenuRegistry.addCommand(command));\n\t}\n\n\t// keybinding\n\tif (Array.isArray(keybinding)) {\n\t\tfor (const item of keybinding) {\n\t\t\tdisposables.push(KeybindingsRegistry.registerKeybindingRule({\n\t\t\t\t...item,\n\t\t\t\tid: command.id,\n\t\t\t\twhen: command.precondition ? ContextKeyExpr.and(command.precondition, item.when) : item.when\n\t\t\t}));\n\t\t}\n\t} else if (keybinding) {\n\t\tdisposables.push(KeybindingsRegistry.registerKeybindingRule({\n\t\t\t...keybinding,\n\t\t\tid: command.id,\n\t\t\twhen: command.precondition ? ContextKeyExpr.and(command.precondition, keybinding.when) : keybinding.when\n\t\t}));\n\t}\n\n\treturn {\n\t\tdispose() {\n\t\t\tdispose(disposables);\n\t\t}\n\t};\n}\n//#endregion\n","/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport { IAction, SubmenuAction } from '../../../base/common/actions.js';\nimport { Event, MicrotaskEmitter } from '../../../base/common/event.js';\nimport { DisposableStore, dispose, IDisposable, markAsSingleton, toDisposable } from '../../../base/common/lifecycle.js';\nimport { LinkedList } from '../../../base/common/linkedList.js';\nimport { ThemeIcon } from '../../../base/common/themables.js';\nimport { ICommandAction, ICommandActionTitle, Icon, ILocalizedString } from '../../action/common/action.js';\nimport { Categories } from '../../action/common/actionCommonCategories.js';\nimport { CommandsRegistry, ICommandService } from '../../commands/common/commands.js';\nimport { ContextKeyExpr, ContextKeyExpression, IContextKeyService } from '../../contextkey/common/contextkey.js';\nimport { createDecorator, ServicesAccessor } from '../../instantiation/common/instantiation.js';\nimport { IKeybindingRule, KeybindingsRegistry } from '../../keybinding/common/keybindingsRegistry.js';\n\nexport interface IMenuItem {\n\tcommand: ICommandAction;\n\talt?: ICommandAction;\n\t/**\n\t * Menu item is hidden if this expression returns false.\n\t */\n\twhen?: ContextKeyExpression;\n\tgroup?: 'navigation' | string;\n\torder?: number;\n\tisHiddenByDefault?: boolean;\n}\n\nexport interface ISubmenuItem {\n\ttitle: string | ICommandActionTitle;\n\tsubmenu: MenuId;\n\ticon?: Icon;\n\twhen?: ContextKeyExpression;\n\tgroup?: 'navigation' | string;\n\torder?: number;\n\tisSelection?: boolean;\n\t/**\n\t * A split button shows the first action\n\t * as primary action and the rest of the\n\t * actions in a dropdown.\n\t *\n\t * Use `togglePrimaryAction` to promote\n\t * the action that was last used to be\n\t * the primary action and remember that\n\t * choice.\n\t */\n\tisSplitButton?: boolean | {\n\t\t/**\n\t\t * Will update the primary action based\n\t\t * on the action that was last run.\n\t\t */\n\t\ttogglePrimaryAction: true;\n\t};\n}\n\nexport function isIMenuItem(item: unknown): item is IMenuItem {\n\treturn (item as IMenuItem).command !== undefined;\n}\n\nexport function isISubmenuItem(item: unknown): item is ISubmenuItem {\n\treturn (item as ISubmenuItem).submenu !== undefined;\n}\n\nexport class MenuId {\n\n\tprivate static readonly _instances = new Map<string, MenuId>();\n\n\tstatic readonly CommandPalette = new MenuId('CommandPalette');\n\tstatic readonly DebugBreakpointsContext = new MenuId('DebugBreakpointsContext');\n\tstatic readonly DebugCallStackContext = new MenuId('DebugCallStackContext');\n\tstatic readonly DebugConsoleContext = new MenuId('DebugConsoleContext');\n\tstatic readonly DebugVariablesContext = new MenuId('DebugVariablesContext');\n\tstatic readonly NotebookVariablesContext = new MenuId('NotebookVariablesContext');\n\tstatic readonly DebugHoverContext = new MenuId('DebugHoverContext');\n\tstatic readonly DebugWatchContext = new MenuId('DebugWatchContext');\n\tstatic readonly DebugToolBar = new MenuId('DebugToolBar');\n\tstatic readonly DebugToolBarStop = new MenuId('DebugToolBarStop');\n\tstatic readonly DebugDisassemblyContext = new MenuId('DebugDisassemblyContext');\n\tstatic readonly DebugCallStackToolbar = new MenuId('DebugCallStackToolbar');\n\tstatic readonly DebugCreateConfiguration = new MenuId('DebugCreateConfiguration');\n\tstatic readonly DebugScopesContext = new MenuId('DebugScopesContext');\n\tstatic readonly EditorContext = new MenuId('EditorContext');\n\tstatic readonly SimpleEditorContext = new MenuId('SimpleEditorContext');\n\tstatic readonly EditorContent = new MenuId('EditorContent');\n\tstatic readonly EditorLineNumberContext = new MenuId('EditorLineNumberContext');\n\tstatic readonly EditorContextCopy = new MenuId('EditorContextCopy');\n\tstatic readonly EditorContextPeek = new MenuId('EditorContextPeek');\n\tstatic readonly EditorContextShare = new MenuId('EditorContextShare');\n\tstatic readonly EditorTitle = new MenuId('EditorTitle');\n\tstatic readonly CompactWindowEditorTitle = new MenuId('CompactWindowEditorTitle');\n\tstatic readonly EditorTitleRun = new MenuId('EditorTitleRun');\n\tstatic readonly EditorTitleContext = new MenuId('EditorTitleContext');\n\tstatic readonly EditorTitleContextShare = new MenuId('EditorTitleContextShare');\n\tstatic readonly EmptyEditorGroup = new MenuId('EmptyEditorGroup');\n\tstatic readonly EmptyEditorGroupContext = new MenuId('EmptyEditorGroupContext');\n\tstatic readonly EditorTabsBarContext = new MenuId('EditorTabsBarContext');\n\tstatic readonly EditorTabsBarShowTabsSubmenu = new MenuId('EditorTabsBarShowTabsSubmenu');\n\tstatic readonly EditorTabsBarShowTabsZenModeSubmenu = new MenuId('EditorTabsBarShowTabsZenModeSubmenu');\n\tstatic readonly EditorActionsPositionSubmenu = new MenuId('EditorActionsPositionSubmenu');\n\tstatic readonly EditorSplitMoveSubmenu = new MenuId('EditorSplitMoveSubmenu');\n\tstatic readonly ExplorerContext = new MenuId('ExplorerContext');\n\tstatic readonly ExplorerContextShare = new MenuId('ExplorerContextShare');\n\tstatic readonly ExtensionContext = new MenuId('ExtensionContext');\n\tstatic readonly ExtensionEditorContextMenu = new MenuId('ExtensionEditorContextMenu');\n\tstatic readonly GlobalActivity = new MenuId('GlobalActivity');\n\tstatic readonly CommandCenter = new MenuId('CommandCenter');\n\tstatic readonly CommandCenterCenter = new MenuId('CommandCenterCenter');\n\tstatic readonly LayoutControlMenuSubmenu = new MenuId('LayoutControlMenuSubmenu');\n\tstatic readonly LayoutControlMenu = new MenuId('LayoutControlMenu');\n\tstatic readonly MenubarMainMenu = new MenuId('MenubarMainMenu');\n\tstatic readonly MenubarAppearanceMenu = new MenuId('MenubarAppearanceMenu');\n\tstatic readonly MenubarDebugMenu = new MenuId('MenubarDebugMenu');\n\tstatic readonly MenubarEditMenu = new MenuId('MenubarEditMenu');\n\tstatic readonly MenubarCopy = new MenuId('MenubarCopy');\n\tstatic readonly MenubarFileMenu = new MenuId('MenubarFileMenu');\n\tstatic readonly MenubarGoMenu = new MenuId('MenubarGoMenu');\n\tstatic readonly MenubarHelpMenu = new MenuId('MenubarHelpMenu');\n\tstatic readonly MenubarLayoutMenu = new MenuId('MenubarLayoutMenu');\n\tstatic readonly MenubarNewBreakpointMenu = new MenuId('MenubarNewBreakpointMenu');\n\tstatic readonly PanelAlignmentMenu = new MenuId('PanelAlignmentMenu');\n\tstatic readonly PanelPositionMenu = new MenuId('PanelPositionMenu');\n\tstatic readonly ActivityBarPositionMenu = new MenuId('ActivityBarPositionMenu');\n\tstatic readonly MenubarPreferencesMenu = new MenuId('MenubarPreferencesMenu');\n\tstatic readonly MenubarRecentMenu = new MenuId('MenubarRecentMenu');\n\tstatic readonly MenubarSelectionMenu = new MenuId('MenubarSelectionMenu');\n\tstatic readonly MenubarShare = new MenuId('MenubarShare');\n\tstatic readonly MenubarSwitchEditorMenu = new MenuId('MenubarSwitchEditorMenu');\n\tstatic readonly MenubarSwitchGroupMenu = new MenuId('MenubarSwitchGroupMenu');\n\tstatic readonly MenubarTerminalMenu = new MenuId('MenubarTerminalMenu');\n\tstatic readonly MenubarTerminalSuggestStatusMenu = new MenuId('MenubarTerminalSuggestStatusMenu');\n\tstatic readonly MenubarViewMenu = new MenuId('MenubarViewMenu');\n\tstatic readonly MenubarHomeMenu = new MenuId('MenubarHomeMenu');\n\tstatic readonly OpenEditorsContext = new MenuId('OpenEditorsContext');\n\tstatic readonly OpenEditorsContextShare = new MenuId('OpenEditorsContextShare');\n\tstatic readonly ProblemsPanelContext = new MenuId('ProblemsPanelContext');\n\tstatic readonly SCMInputBox = new MenuId('SCMInputBox');\n\tstatic readonly SCMChangeContext = new MenuId('SCMChangeContext');\n\tstatic readonly SCMResourceContext = new MenuId('SCMResourceContext');\n\tstatic readonly SCMResourceContextShare = new MenuId('SCMResourceContextShare');\n\tstatic readonly SCMResourceFolderContext = new MenuId('SCMResourceFolderContext');\n\tstatic readonly SCMResourceGroupContext = new MenuId('SCMResourceGroupContext');\n\tstatic readonly SCMSourceControl = new MenuId('SCMSourceControl');\n\tstatic readonly SCMSourceControlInline = new MenuId('SCMSourceControlInline');\n\tstatic readonly SCMSourceControlTitle = new MenuId('SCMSourceControlTitle');\n\tstatic readonly SCMHistoryTitle = new MenuId('SCMHistoryTitle');\n\tstatic readonly SCMHistoryItemContext = new MenuId('SCMHistoryItemContext');\n\tstatic readonly SCMHistoryItemChangeContext = new MenuId('SCMHistoryItemChangeContext');\n\tstatic readonly SCMHistoryItemRefContext = new MenuId('SCMHistoryItemRefContext');\n\tstatic readonly SCMArtifactGroupContext = new MenuId('SCMArtifactGroupContext');\n\tstatic readonly SCMArtifactContext = new MenuId('SCMArtifactContext');\n\tstatic readonly SCMQuickDiffDecorations = new MenuId('SCMQuickDiffDecorations');\n\tstatic readonly SCMTitle = new MenuId('SCMTitle');\n\tstatic readonly SearchContext = new MenuId('SearchContext');\n\tstatic readonly SearchActionMenu = new MenuId('SearchActionContext');\n\tstatic readonly StatusBarWindowIndicatorMenu = new MenuId('StatusBarWindowIndicatorMenu');\n\tstatic readonly StatusBarRemoteIndicatorMenu = new MenuId('StatusBarRemoteIndicatorMenu');\n\tstatic readonly StickyScrollContext = new MenuId('StickyScrollContext');\n\tstatic readonly TestItem = new MenuId('TestItem');\n\tstatic readonly TestItemGutter = new MenuId('TestItemGutter');\n\tstatic readonly TestProfilesContext = new MenuId('TestProfilesContext');\n\tstatic readonly TestMessageContext = new MenuId('TestMessageContext');\n\tstatic readonly TestMessageContent = new MenuId('TestMessageContent');\n\tstatic readonly TestPeekElement = new MenuId('TestPeekElement');\n\tstatic readonly TestPeekTitle = new MenuId('TestPeekTitle');\n\tstatic readonly TestCallStack = new MenuId('TestCallStack');\n\tstatic readonly TestCoverageFilterItem = new MenuId('TestCoverageFilterItem');\n\tstatic readonly TouchBarContext = new MenuId('TouchBarContext');\n\tstatic readonly TitleBar = new MenuId('TitleBar');\n\tstatic readonly TitleBarContext = new MenuId('TitleBarContext');\n\tstatic readonly TitleBarTitleContext = new MenuId('TitleBarTitleContext');\n\tstatic readonly TunnelContext = new MenuId('TunnelContext');\n\tstatic readonly TunnelPrivacy = new MenuId('TunnelPrivacy');\n\tstatic readonly TunnelProtocol = new MenuId('TunnelProtocol');\n\tstatic readonly TunnelPortInline = new MenuId('TunnelInline');\n\tstatic readonly TunnelTitle = new MenuId('TunnelTitle');\n\tstatic readonly TunnelLocalAddressInline = new MenuId('TunnelLocalAddressInline');\n\tstatic readonly TunnelOriginInline = new MenuId('TunnelOriginInline');\n\tstatic readonly ViewItemContext = new MenuId('ViewItemContext');\n\tstatic readonly ViewContainerTitle = new MenuId('ViewContainerTitle');\n\tstatic readonly ViewContainerTitleContext = new MenuId('ViewContainerTitleContext');\n\tstatic readonly ViewTitle = new MenuId('ViewTitle');\n\tstatic readonly ViewTitleContext = new MenuId('ViewTitleContext');\n\tstatic readonly CommentEditorActions = new MenuId('CommentEditorActions');\n\tstatic readonly CommentThreadTitle = new MenuId('CommentThreadTitle');\n\tstatic readonly CommentThreadActions = new MenuId('CommentThreadActions');\n\tstatic readonly CommentThreadAdditionalActions = new MenuId('CommentThreadAdditionalActions');\n\tstatic readonly CommentThreadTitleContext = new MenuId('CommentThreadTitleContext');\n\tstatic readonly CommentThreadCommentContext = new MenuId('CommentThreadCommentContext');\n\tstatic readonly CommentTitle = new MenuId('CommentTitle');\n\tstatic readonly CommentActions = new MenuId('CommentActions');\n\tstatic readonly CommentsViewThreadActions = new MenuId('CommentsViewThreadActions');\n\tstatic readonly InteractiveToolbar = new MenuId('InteractiveToolbar');\n\tstatic readonly InteractiveCellTitle = new MenuId('InteractiveCellTitle');\n\tstatic readonly InteractiveCellDelete = new MenuId('InteractiveCellDelete');\n\tstatic readonly InteractiveCellExecute = new MenuId('InteractiveCellExecute');\n\tstatic readonly InteractiveInputExecute = new MenuId('InteractiveInputExecute');\n\tstatic readonly InteractiveInputConfig = new MenuId('InteractiveInputConfig');\n\tstatic readonly ReplInputExecute = new MenuId('ReplInputExecute');\n\tstatic readonly IssueReporter = new MenuId('IssueReporter');\n\tstatic readonly NotebookToolbar = new MenuId('NotebookToolbar');\n\tstatic readonly NotebookToolbarContext = new MenuId('NotebookToolbarContext');\n\tstatic readonly NotebookStickyScrollContext = new MenuId('NotebookStickyScrollContext');\n\tstatic readonly NotebookCellTitle = new MenuId('NotebookCellTitle');\n\tstatic readonly NotebookCellDelete = new MenuId('NotebookCellDelete');\n\tstatic readonly NotebookCellInsert = new MenuId('NotebookCellInsert');\n\tstatic readonly NotebookCellBetween = new MenuId('NotebookCellBetween');\n\tstatic readonly NotebookCellListTop = new MenuId('NotebookCellTop');\n\tstatic readonly NotebookCellExecute = new MenuId('NotebookCellExecute');\n\tstatic readonly NotebookCellExecuteGoTo = new MenuId('NotebookCellExecuteGoTo');\n\tstatic readonly NotebookCellExecutePrimary = new MenuId('NotebookCellExecutePrimary');\n\tstatic readonly NotebookDiffCellInputTitle = new MenuId('NotebookDiffCellInputTitle');\n\tstatic readonly NotebookDiffDocumentMetadata = new MenuId('NotebookDiffDocumentMetadata');\n\tstatic readonly NotebookDiffCellMetadataTitle = new MenuId('NotebookDiffCellMetadataTitle');\n\tstatic readonly NotebookDiffCellOutputsTitle = new MenuId('NotebookDiffCellOutputsTitle');\n\tstatic readonly NotebookOutputToolbar = new MenuId('NotebookOutputToolbar');\n\tstatic readonly NotebookOutlineFilter = new MenuId('NotebookOutlineFilter');\n\tstatic readonly NotebookOutlineActionMenu = new MenuId('NotebookOutlineActionMenu');\n\tstatic readonly NotebookEditorLayoutConfigure = new MenuId('NotebookEditorLayoutConfigure');\n\tstatic readonly NotebookKernelSource = new MenuId('NotebookKernelSource');\n\tstatic readonly BulkEditTitle = new MenuId('BulkEditTitle');\n\tstatic readonly BulkEditContext = new MenuId('BulkEditContext');\n\tstatic readonly TimelineItemContext = new MenuId('TimelineItemContext');\n\tstatic readonly TimelineTitle = new MenuId('TimelineTitle');\n\tstatic readonly TimelineTitleContext = new MenuId('TimelineTitleContext');\n\tstatic readonly TimelineFilterSubMenu = new MenuId('TimelineFilterSubMenu');\n\tstatic readonly AccountsContext = new MenuId('AccountsContext');\n\tstatic readonly SidebarTitle = new MenuId('SidebarTitle');\n\tstatic readonly PanelTitle = new MenuId('PanelTitle');\n\tstatic readonly AuxiliaryBarTitle = new MenuId('AuxiliaryBarTitle');\n\tstatic readonly TerminalInstanceContext = new MenuId('TerminalInstanceContext');\n\tstatic readonly TerminalEditorInstanceContext = new MenuId('TerminalEditorInstanceContext');\n\tstatic readonly TerminalNewDropdownContext = new MenuId('TerminalNewDropdownContext');\n\tstatic readonly TerminalTabContext = new MenuId('TerminalTabContext');\n\tstatic readonly TerminalTabEmptyAreaContext = new MenuId('TerminalTabEmptyAreaContext');\n\tstatic readonly TerminalStickyScrollContext = new MenuId('TerminalStickyScrollContext');\n\tstatic readonly WebviewContext = new MenuId('WebviewContext');\n\tstatic readonly InlineCompletionsActions = new MenuId('InlineCompletionsActions');\n\tstatic readonly InlineEditsActions = new MenuId('InlineEditsActions');\n\tstatic readonly NewFile = new MenuId('NewFile');\n\tstatic readonly MergeInput1Toolbar = new MenuId('MergeToolbar1Toolbar');\n\tstatic readonly MergeInput2Toolbar = new MenuId('MergeToolbar2Toolbar');\n\tstatic readonly MergeBaseToolbar = new MenuId('MergeBaseToolbar');\n\tstatic readonly MergeInputResultToolbar = new MenuId('MergeToolbarResultToolbar');\n\tstatic readonly InlineSuggestionToolbar = new MenuId('InlineSuggestionToolbar');\n\tstatic readonly InlineEditToolbar = new MenuId('InlineEditToolbar');\n\tstatic readonly ChatContext = new MenuId('ChatContext');\n\tstatic readonly ChatCodeBlock = new MenuId('ChatCodeblock');\n\tstatic readonly ChatCompareBlock = new MenuId('ChatCompareBlock');\n\tstatic readonly ChatMessageTitle = new MenuId('ChatMessageTitle');\n\tstatic readonly ChatWelcomeContext = new MenuId('ChatWelcomeContext');\n\tstatic readonly ChatMessageFooter = new MenuId('ChatMessageFooter');\n\tstatic readonly ChatExecute = new MenuId('ChatExecute');\n\tstatic readonly ChatExecuteQueue = new MenuId('ChatExecuteQueue');\n\tstatic readonly ChatInput = new MenuId('ChatInput');\n\tstatic readonly ChatInputSide = new MenuId('ChatInputSide');\n\tstatic readonly ChatModePicker = new MenuId('ChatModePicker');\n\tstatic readonly ChatEditingWidgetToolbar = new MenuId('ChatEditingWidgetToolbar');\n\tstatic readonly ChatEditingSessionChangesToolbar = new MenuId('ChatEditingSessionChangesToolbar');\n\tstatic readonly ChatEditingEditorContent = new MenuId('ChatEditingEditorContent');\n\tstatic readonly ChatEditingEditorHunk = new MenuId('ChatEditingEditorHunk');\n\tstatic readonly ChatEditingDeletedNotebookCell = new MenuId('ChatEditingDeletedNotebookCell');\n\tstatic readonly ChatInputAttachmentToolbar = new MenuId('ChatInputAttachmentToolbar');\n\tstatic readonly ChatEditingWidgetModifiedFilesToolbar = new MenuId('ChatEditingWidgetModifiedFilesToolbar');\n\tstatic readonly ChatInputResourceAttachmentContext = new MenuId('ChatInputResourceAttachmentContext');\n\tstatic readonly ChatInputSymbolAttachmentContext = new MenuId('ChatInputSymbolAttachmentContext');\n\tstatic readonly ChatInlineResourceAnchorContext = new MenuId('ChatInlineResourceAnchorContext');\n\tstatic readonly ChatInlineSymbolAnchorContext = new MenuId('ChatInlineSymbolAnchorContext');\n\tstatic readonly ChatMessageCheckpoint: MenuId = new MenuId('ChatMessageCheckpoint');\n\tstatic readonly ChatMessageRestoreCheckpoint: MenuId = new MenuId('ChatMessageRestoreCheckpoint');\n\tstatic readonly ChatNewMenu = new MenuId('ChatNewMenu');\n\tstatic readonly ChatEditingCodeBlockContext = new MenuId('ChatEditingCodeBlockContext');\n\tstatic readonly ChatTitleBarMenu = new MenuId('ChatTitleBarMenu');\n\tstatic readonly ChatAttachmentsContext = new MenuId('ChatAttachmentsContext');\n\tstatic readonly ChatToolOutputResourceToolbar = new MenuId('ChatToolOutputResourceToolbar');\n\tstatic readonly ChatTextEditorMenu = new MenuId('ChatTextEditorMenu');\n\tstatic readonly ChatToolOutputResourceContext = new MenuId('ChatToolOutputResourceContext');\n\tstatic readonly ChatMultiDiffContext = new MenuId('ChatMultiDiffContext');\n\tstatic readonly ChatConfirmationMenu = new MenuId('ChatConfirmationMenu');\n\tstatic readonly ChatEditorInlineGutter = new MenuId('ChatEditorInlineGutter');\n\tstatic readonly ChatEditorInlineExecute = new MenuId('ChatEditorInputExecute');\n\tstatic readonly ChatEditorInlineInputSide = new MenuId('ChatEditorInputSide');\n\tstatic readonly InlineChatEditorAffordance = new MenuId('InlineChatEditorAffordance');\n\tstatic readonly AccessibleView = new MenuId('AccessibleView');\n\tstatic readonly MultiDiffEditorContent = new MenuId('MultiDiffEditorContent');\n\tstatic readonly MultiDiffEditorFileToolbar = new MenuId('MultiDiffEditorFileToolbar');\n\tstatic readonly DiffEditorHunkToolbar = new MenuId('DiffEditorHunkToolbar');\n\tstatic readonly DiffEditorSelectionToolbar = new MenuId('DiffEditorSelectionToolbar');\n\tstatic readonly BrowserNavigationToolbar = new MenuId('BrowserNavigationToolbar');\n\tstatic readonly BrowserActionsToolbar = new MenuId('BrowserActionsToolbar');\n\tstatic readonly AgentSessionsViewerFilterSubMenu = new MenuId('AgentSessionsViewerFilterSubMenu');\n\tstatic readonly AgentSessionsContext = new MenuId('AgentSessionsContext');\n\tstatic readonly AgentSessionSectionContext = new MenuId('AgentSessionSectionContext');\n\tstatic readonly AgentSessionsCreateSubMenu = new MenuId('AgentSessionsCreateSubMenu');\n\tstatic readonly AgentSessionsToolbar = new MenuId('AgentSessionsToolbar');\n\tstatic readonly AgentSessionItemToolbar = new MenuId('AgentSessionItemToolbar');\n\tstatic readonly AgentSessionSectionToolbar = new MenuId('AgentSessionSectionToolbar');\n\tstatic readonly AgentsTitleBarControlMenu = new MenuId('AgentsTitleBarControlMenu');\n\tstatic readonly ChatViewSessionTitleNavigationToolbar = new MenuId('ChatViewSessionTitleNavigationToolbar');\n\tstatic readonly ChatViewSessionTitleToolbar = new MenuId('ChatViewSessionTitleToolbar');\n\tstatic readonly ChatContextUsageActions = new MenuId('ChatContextUsageActions');\n\n\treadonly id: string;\n\n\t/**\n\t * Create a new `MenuId` with the unique identifier. Will throw if a menu\n\t * with the identifier already exists, use `MenuId.for(ident)` or a unique\n\t * identifier\n\t */\n\tconstructor(identifier: string) {\n\t\tif (MenuId._instances.has(identifier)) {\n\t\t\tthrow new TypeError(`MenuId with identifier '${identifier}' already exists. Use MenuId.for(ident) or a unique identifier`);\n\t\t}\n\t\tMenuId._instances.set(identifier, this);\n\t\tthis.id = identifier;\n\t}\n}\n\nexport interface IMenuActionOptions {\n\targ?: unknown;\n\targs?: unknown[];\n\tshouldForwardArgs?: boolean;\n\trenderShortTitle?: boolean;\n}\n\nexport interface IMenuChangeEvent {\n\treadonly menu: IMenu;\n\treadonly isStructuralChange: boolean;\n\treadonly isToggleChange: boolean;\n\treadonly isEnablementChange: boolean;\n}\n\nexport interface IMenu extends IDisposable {\n\treadonly onDidChange: Event<IMenuChangeEvent>;\n\tgetActions(options?: IMenuActionOptions): [string, Array<MenuItemAction | SubmenuItemAction>][];\n}\n\nexport const IMenuService = createDecorator<IMenuService>('menuService');\n\nexport interface IMenuCreateOptions {\n\temitEventsForSubmenuChanges?: boolean;\n\teventDebounceDelay?: number;\n}\n\nexport interface IMenuService {\n\n\treadonly _serviceBrand: undefined;\n\n\t/**\n\t * Consider using getMenuActions if you don't need to listen to events.\n\t *\n\t * Create a new menu for the given menu identifier. A menu sends events when it's entries\n\t * have changed (placement, enablement, checked-state). By default it does not send events for\n\t * submenu entries. That is more expensive and must be explicitly enabled with the\n\t * `emitEventsForSubmenuChanges` flag.\n\t */\n\tcreateMenu(id: MenuId, contextKeyService: IContextKeyService, options?: IMenuCreateOptions): IMenu;\n\n\t/**\n\t * Creates a new menu, gets the actions, and then disposes of the menu.\n\t */\n\tgetMenuActions(id: MenuId, contextKeyService: IContextKeyService, options?: IMenuActionOptions): [string, Array<MenuItemAction | SubmenuItemAction>][];\n\n\t/**\n\t * Reset **all** menu item hidden states.\n\t */\n\tresetHiddenStates(): void;\n\n\t/**\n\t * Reset the menu's hidden states.\n\t */\n\tresetHiddenStates(menuIds: readonly MenuId[] | undefined): void;\n}\n\ntype ICommandsMap = Map<string, ICommandAction>;\n\nexport interface IMenuRegistryChangeEvent {\n\thas(id: MenuId): boolean;\n}\n\nclass MenuRegistryChangeEvent {\n\n\tprivate static _all = new Map<MenuId, MenuRegistryChangeEvent>();\n\n\tstatic for(id: MenuId): MenuRegistryChangeEvent {\n\t\tlet value = this._all.get(id);\n\t\tif (!value) {\n\t\t\tvalue = new MenuRegistryChangeEvent(id);\n\t\t\tthis._all.set(id, value);\n\t\t}\n\t\treturn value;\n\t}\n\n\tstatic merge(events: IMenuRegistryChangeEvent[]): IMenuRegistryChangeEvent {\n\t\tconst ids = new Set<MenuId>();\n\t\tfor (const item of events) {\n\t\t\tif (item instanceof MenuRegistryChangeEvent) {\n\t\t\t\tids.add(item.id);\n\t\t\t}\n\t\t}\n\t\treturn ids;\n\t}\n\n\treadonly has: (id: MenuId) => boolean;\n\n\tprivate constructor(private readonly id: MenuId) {\n\t\tthis.has = candidate => candidate === id;\n\t}\n}\n\nexport interface IMenuRegistry {\n\treadonly onDidChangeMenu: Event<IMenuRegistryChangeEvent>;\n\taddCommand(userCommand: ICommandAction): IDisposable;\n\tappendMenuItem(menu: MenuId, item: IMenuItem | ISubmenuItem): IDisposable;\n\tgetMenuItems(loc: MenuId): Array<IMenuItem | ISubmenuItem>;\n}\n\nexport const MenuRegistry: IMenuRegistry = new class implements IMenuRegistry {\n\n\tprivate readonly _commands = new Map<string, ICommandAction>();\n\tprivate readonly _menuItems = new Map<MenuId, LinkedList<IMenuItem | ISubmenuItem>>();\n\tprivate readonly _onDidChangeMenu = new MicrotaskEmitter<IMenuRegistryChangeEvent>({\n\t\tmerge: MenuRegistryChangeEvent.merge\n\t});\n\n\treadonly onDidChangeMenu: Event<IMenuRegistryChangeEvent> = this._onDidChangeMenu.event;\n\n\taddCommand(command: ICommandAction): IDisposable {\n\t\tthis._commands.set(command.id, command);\n\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(MenuId.CommandPalette));\n\n\t\treturn markAsSingleton(toDisposable(() => {\n\t\t\tif (this._commands.delete(command.id)) {\n\t\t\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(MenuId.CommandPalette));\n\t\t\t}\n\t\t}));\n\t}\n\n\tgetCommand(id: string): ICommandAction | undefined {\n\t\treturn this._commands.get(id);\n\t}\n\n\tgetCommands(): ICommandsMap {\n\t\tconst map = new Map<string, ICommandAction>();\n\t\tthis._commands.forEach((value, key) => map.set(key, value));\n\t\treturn map;\n\t}\n\n\tappendMenuItem(id: MenuId, item: IMenuItem | ISubmenuItem): IDisposable {\n\t\tlet list = this._menuItems.get(id);\n\t\tif (!list) {\n\t\t\tlist = new LinkedList();\n\t\t\tthis._menuItems.set(id, list);\n\t\t}\n\t\tconst rm = list.push(item);\n\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(id));\n\t\treturn markAsSingleton(toDisposable(() => {\n\t\t\trm();\n\t\t\tthis._onDidChangeMenu.fire(MenuRegistryChangeEvent.for(id));\n\t\t}));\n\t}\n\n\tappendMenuItems(items: Iterable<{ id: MenuId; item: IMenuItem | ISubmenuItem }>): IDisposable {\n\t\tconst result = new DisposableStore();\n\t\tfor (const { id, item } of items) {\n\t\t\tresult.add(this.appendMenuItem(id, item));\n\t\t}\n\t\treturn result;\n\t}\n\n\tgetMenuItems(id: MenuId): Array<IMenuItem | ISubmenuItem> {\n\t\tlet result: Array<IMenuItem | ISubmenuItem>;\n\t\tif (this._menuItems.has(id)) {\n\t\t\tresult = [...this._menuItems.get(id)!];\n\t\t} else {\n\t\t\tresult = [];\n\t\t}\n\t\tif (id === MenuId.CommandPalette) {\n\t\t\t// CommandPalette is special because it shows\n\t\t\t// all commands by default\n\t\t\tthis._appendImplicitItems(result);\n\t\t}\n\t\treturn result;\n\t}\n\n\tprivate _appendImplicitItems(result: Array<IMenuItem | ISubmenuItem>) {\n\t\tconst set = new Set<string>();\n\n\t\tfor (const item of result) {\n\t\t\tif (isIMenuItem(item)) {\n\t\t\t\tset.add(item.command.id);\n\t\t\t\tif (item.alt) {\n\t\t\t\t\tset.add(item.alt.id);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tthis._commands.forEach((command, id) => {\n\t\t\tif (!set.has(id)) {\n\t\t\t\tresult.push({ command });\n\t\t\t}\n\t\t});\n\t}\n};\n\nexport class SubmenuItemAction extends SubmenuAction {\n\n\tconstructor(\n\t\treadonly item: ISubmenuItem,\n\t\treadonly hideActions: IMenuItemHide | undefined,\n\t\tactions: readonly IAction[],\n\t) {\n\t\tsuper(`submenuitem.${item.submenu.id}`, typeof item.title === 'string' ? item.title : item.title.value, actions, 'submenu');\n\t}\n}\n\nexport interface IMenuItemHide {\n\treadonly isHidden: boolean;\n\treadonly hide: IAction;\n\treadonly toggle: IAction;\n}\n\n// implements IAction, does NOT extend Action, so that no one\n// subscribes to events of Action or modified properties\nexport class MenuItemAction implements IAction {\n\n\tstatic label(action: ICommandAction, options?: IMenuActionOptions): string {\n\t\treturn options?.renderShortTitle && action.shortTitle\n\t\t\t? (typeof action.shortTitle === 'string' ? action.shortTitle : action.shortTitle.value)\n\t\t\t: (typeof action.title === 'string' ? action.title : action.title.value);\n\t}\n\n\treadonly item: ICommandAction;\n\treadonly alt: MenuItemAction | undefined;\n\n\tprivate readonly _options: IMenuActionOptions | undefined;\n\n\treadonly id: string;\n\treadonly label: string;\n\treadonly tooltip: string;\n\treadonly class: string | undefined;\n\treadonly enabled: boolean;\n\treadonly checked?: boolean;\n\n\tconstructor(\n\t\titem: ICommandAction,\n\t\talt: ICommandAction | undefined,\n\t\toptions: IMenuActionOptions | undefined,\n\t\treadonly hideActions: IMenuItemHide | undefined,\n\t\treadonly menuKeybinding: IAction | undefined,\n\t\t@IContextKeyService contextKeyService: IContextKeyService,\n\t\t@ICommandService private _commandService: ICommandService\n\t) {\n\t\tthis.id = item.id;\n\t\tthis.label = MenuItemAction.label(item, options);\n\t\tthis.tooltip = (typeof item.tooltip === 'string' ? item.tooltip : item.tooltip?.value) ?? '';\n\t\tthis.enabled = !item.precondition || contextKeyService.contextMatchesRules(item.precondition);\n\t\tthis.checked = undefined;\n\n\t\tlet icon: ThemeIcon | undefined;\n\n\t\tif (item.toggled) {\n\t\t\tconst toggled = ((item.toggled as { condition: ContextKeyExpression }).condition ? item.toggled : { condition: item.toggled }) as {\n\t\t\t\tcondition: ContextKeyExpression; icon?: Icon; tooltip?: string | ILocalizedString; title?: string | ILocalizedString;\n\t\t\t};\n\t\t\tthis.checked = contextKeyService.contextMatchesRules(toggled.condition);\n\t\t\tif (this.checked && toggled.tooltip) {\n\t\t\t\tthis.tooltip = typeof toggled.tooltip === 'string' ? toggled.tooltip : toggled.tooltip.value;\n\t\t\t}\n\n\t\t\tif (this.checked && ThemeIcon.isThemeIcon(toggled.icon)) {\n\t\t\t\ticon = toggled.icon;\n\t\t\t}\n\n\t\t\tif (this.checked && toggled.title) {\n\t\t\t\tthis.label = typeof toggled.title === 'string' ? toggled.title : toggled.title.value;\n\t\t\t}\n\t\t}\n\n\t\tif (!icon) {\n\t\t\ticon = ThemeIcon.isThemeIcon(item.icon) ? item.icon : undefined;\n\t\t}\n\n\t\tthis.item = item;\n\t\tthis.alt = alt ? new MenuItemAction(alt, undefined, options, hideActions, undefined, contextKeyService, _commandService) : undefined;\n\t\tthis._options = options;\n\t\tthis.class = icon && ThemeIcon.asClassName(icon);\n\n\t}\n\n\trun(...args: unknown[]): Promise<void> {\n\t\tlet runArgs: unknown[] = [];\n\n\t\tif (this._options?.args) {\n\t\t\trunArgs = [...runArgs, ...this._options.args];\n\t\t} else if (this._options?.arg) {\n\t\t\trunArgs = [...runArgs, this._options.arg];\n\t\t}\n\n\t\tif (this._options?.shouldForwardArgs) {\n\t\t\trunArgs = [...runArgs, ...args];\n\t\t}\n\n\t\treturn this._commandService.executeCommand(this.id, ...runArgs);\n\t}\n}\n\n//#region --- IAction2\n\ntype OneOrN<T> = T | T[];\n\ninterface IAction2CommonOptions extends ICommandAction {\n\t/**\n\t * One or many menu items.\n\t */\n\tmenu?: OneOrN<{ id: MenuId; precondition?: null } & Omit<IMenuItem, 'command'>>;\n\n\t/**\n\t * One keybinding.\n\t */\n\tkeybinding?: OneOrN<Omit<IKeybindingRule, 'id'>>;\n}\n\ninterface IBaseAction2Options extends IAction2CommonOptions {\n\n\t/**\n\t * This type is used when an action is not going to show up in the command palette.\n\t * In that case, it's able to use a string for the `title` and `category` properties.\n\t */\n\tf1?: false;\n}\n\nexport interface ICommandPaletteOptions extends IAction2CommonOptions {\n\n\t/**\n\t * The title of the command that will be displayed in the command palette after the category.\n\t * This overrides {@link ICommandAction.title} to ensure a string isn't used so that the title\n\t * includes the localized value and the original value for users using language packs.\n\t */\n\ttitle: ICommandActionTitle;\n\n\t/**\n\t * The category of the command that will be displayed in the command palette before the title suffixed.\n\t * with a colon This overrides {@link ICommandAction.title} to ensure a string isn't used so that\n\t * the title includes the localized value and the original value for users using language packs.\n\t */\n\tcategory?: keyof typeof Categories | ILocalizedString;\n\n\t/**\n\t * Shorthand to add this command to the command palette. Note: this is not the only way to declare that\n\t * a command should be in the command palette... however, enforcing ILocalizedString in the other scenarios\n\t * is much more challenging and this gets us most of the way there.\n\t */\n\tf1: true;\n}\n\nexport type IAction2Options = ICommandPaletteOptions | IBaseAction2Options;\n\nexport interface IAction2F1RequiredOptions {\n\ttitle: ICommandActionTitle;\n}\n\nexport abstract class Action2 {\n\tconstructor(readonly desc: Readonly<IAction2Options>) { }\n\tabstract run(accessor: ServicesAccessor, ...args: unknown[]): void;\n}\n\nexport function registerAction2(ctor: { new(): Action2 }): IDisposable {\n\tconst disposables: IDisposable[] = []; // not using `DisposableStore` to reduce startup perf cost\n\tconst action = new ctor();\n\n\tconst { f1, menu, keybinding, ...command } = action.desc;\n\n\tif (CommandsRegistry.getCommand(command.id)) {\n\t\tthrow new Error(`Cannot register two commands with the same id: ${command.id}`);\n\t}\n\n\t// command\n\tdisposables.push(CommandsRegistry.registerCommand({\n\t\tid: command.id,\n\t\thandler: (accessor, ...args) => action.run(accessor, ...args),\n\t\tmetadata: command.metadata ?? { description: action.desc.title }\n\t}));\n\n\t// menu\n\tif (Array.isArray(menu)) {\n\t\tfor (const item of menu) {\n\t\t\tdisposables.push(MenuRegistry.appendMenuItem(item.id, { command: { ...command, precondition: item.precondition === null ? undefined : command.precondition }, ...item }));\n\t\t}\n\n\t} else if (menu) {\n\t\tdisposables.push(MenuRegistry.appendMenuItem(menu.id, { command: { ...command, precondition: menu.precondition === null ? undefined : command.precondition }, ...menu }));\n\t}\n\tif (f1) {\n\t\tdisposables.push(MenuRegistry.appendMenuItem(MenuId.CommandPalette, { command, when: command.precondition }));\n\t\tdisposables.push(MenuRegistry.addCommand(command));\n\t}\n\n\t// keybinding\n\tif (Array.isArray(keybinding)) {\n\t\tfor (const item of keybinding) {\n\t\t\tdisposables.push(KeybindingsRegistry.registerKeybindingRule({\n\t\t\t\t...item,\n\t\t\t\tid: command.id,\n\t\t\t\twhen: command.precondition ? ContextKeyExpr.and(command.precondition, item.when) : item.when\n\t\t\t}));\n\t\t}\n\t} else if (keybinding) {\n\t\tdisposables.push(KeybindingsRegistry.registerKeybindingRule({\n\t\t\t...keybinding,\n\t\t\tid: command.id,\n\t\t\twhen: command.precondition ? ContextKeyExpr.and(command.precondition, keybinding.when) : keybinding.when\n\t\t}));\n\t}\n\n\treturn {\n\t\tdispose() {\n\t\t\tdispose(disposables);\n\t\t}\n\t};\n}\n//#endregion\n"]}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "monaco-editor-core",
3
3
  "private": false,
4
- "version": "0.56.0-dev-20260203",
4
+ "version": "0.56.0-dev-20260204",
5
5
  "description": "A browser based code editor",
6
6
  "author": "Microsoft Corporation",
7
7
  "license": "MIT",
@@ -14,7 +14,7 @@
14
14
  "bugs": {
15
15
  "url": "https://github.com/microsoft/vscode/issues"
16
16
  },
17
- "vscodeCommitId": "8d864503e1d96ad37e2c4b001b330a75b03261cb",
17
+ "vscodeCommitId": "d3dbc037c04a68ab8866928b7c6f9ecfe6eedb0f",
18
18
  "dependencies": {
19
19
  "marked": "14.0.0",
20
20
  "dompurify": "3.2.7"
package/version.txt CHANGED
@@ -1 +1 @@
1
- monaco-editor-core: https://github.com/microsoft/vscode/tree/e740ab4da3fac226afe362703507aba5af3f0ba9
1
+ monaco-editor-core: https://github.com/microsoft/vscode/tree/613524bdf43891f71ce0bf1f99584b666d70c95a