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Q,CACJC,OAAQ,oBACRC,QAAS,KACTC,OAAQ,MAGpB,CACA,GAAAC,CAAI9C,EAAU+C,GACV,MAAME,EAAa6pB,EAAyB1sB,IAAI2C,GAChD,OAAKE,EAGEA,EAAWH,IAAI1F,KAAKmE,IAAI,GAFpBlC,QAAQC,aAAQmD,EAG/B,GAEJ,QAA2BqqB,EAAyBzb,GAAIyb,EAA0B,IAClF,QAAqBgB,IACrB,QAAqBC,E","sources":["file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/contentHoverStatusBar.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/getHover.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/hoverActionIds.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/hoverActions.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/markerHoverParticipant.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/hoverAccessibleViews.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/hoverContribution.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/resizableContentWidget.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/contentHoverWidget.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/hoverOperation.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/contentHoverComputer.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/contentHoverTypes.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/contentHoverController.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/marginHoverComputer.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/marginHoverWidget.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/hoverController.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/hoverTypes.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/hover/browser/markdownHoverParticipant.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/inPlaceReplace/browser/inPlaceReplaceCommand.js","file:////home/runner/work/platform/platform/common/temp/node_modules/.pnpm/monaco-editor@0.50.0/node_modules/monaco-editor/esm/vs/editor/contrib/inPlaceReplace/browser/inPlaceReplace.js"],"sourcesContent":["var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __param = (this && this.__param) || function (paramIndex, decorator) {\n return function (target, key) { decorator(target, key, paramIndex); }\n};\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 *--------------------------------------------------------------------------------------------*/\nimport * as dom from '../../../../base/browser/dom.js';\nimport { HoverAction } from '../../../../base/browser/ui/hover/hoverWidget.js';\nimport { Disposable } from '../../../../base/common/lifecycle.js';\nimport { IKeybindingService } from '../../../../platform/keybinding/common/keybinding.js';\nconst $ = dom.$;\nlet EditorHoverStatusBar = class EditorHoverStatusBar extends Disposable {\n get hasContent() {\n return this._hasContent;\n }\n constructor(_keybindingService) {\n super();\n this._keybindingService = _keybindingService;\n this._hasContent = false;\n this.hoverElement = $('div.hover-row.status-bar');\n this.hoverElement.tabIndex = 0;\n this.actionsElement = dom.append(this.hoverElement, $('div.actions'));\n }\n addAction(actionOptions) {\n const keybinding = this._keybindingService.lookupKeybinding(actionOptions.commandId);\n const keybindingLabel = keybinding ? keybinding.getLabel() : null;\n this._hasContent = true;\n return this._register(HoverAction.render(this.actionsElement, actionOptions, keybindingLabel));\n }\n append(element) {\n const result = dom.append(this.actionsElement, element);\n this._hasContent = true;\n return result;\n }\n};\nEditorHoverStatusBar = __decorate([\n __param(0, IKeybindingService)\n], EditorHoverStatusBar);\nexport { EditorHoverStatusBar };\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 *--------------------------------------------------------------------------------------------*/\nimport { AsyncIterableObject } from '../../../../base/common/async.js';\nimport { CancellationToken } from '../../../../base/common/cancellation.js';\nimport { onUnexpectedExternalError } from '../../../../base/common/errors.js';\nimport { registerModelAndPositionCommand } from '../../../browser/editorExtensions.js';\nimport { ILanguageFeaturesService } from '../../../common/services/languageFeatures.js';\nexport class HoverProviderResult {\n constructor(provider, hover, ordinal) {\n this.provider = provider;\n this.hover = hover;\n this.ordinal = ordinal;\n }\n}\n/**\n * Does not throw or return a rejected promise (returns undefined instead).\n */\nasync function executeProvider(provider, ordinal, model, position, token) {\n const result = await Promise\n .resolve(provider.provideHover(model, position, token))\n .catch(onUnexpectedExternalError);\n if (!result || !isValid(result)) {\n return undefined;\n }\n return new HoverProviderResult(provider, result, ordinal);\n}\nexport function getHoverProviderResultsAsAsyncIterable(registry, model, position, token) {\n const providers = registry.ordered(model);\n const promises = providers.map((provider, index) => executeProvider(provider, index, model, position, token));\n return AsyncIterableObject.fromPromises(promises).coalesce();\n}\nexport function getHoversPromise(registry, model, position, token) {\n return getHoverProviderResultsAsAsyncIterable(registry, model, position, token).map(item => item.hover).toPromise();\n}\nregisterModelAndPositionCommand('_executeHoverProvider', (accessor, model, position) => {\n const languageFeaturesService = accessor.get(ILanguageFeaturesService);\n return getHoversPromise(languageFeaturesService.hoverProvider, model, position, CancellationToken.None);\n});\nfunction isValid(result) {\n const hasRange = (typeof result.range !== 'undefined');\n const hasHtmlContent = typeof result.contents !== 'undefined' && result.contents && result.contents.length > 0;\n return hasRange && hasHtmlContent;\n}\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 *--------------------------------------------------------------------------------------------*/\nimport * as nls from '../../../../nls.js';\nexport const SHOW_OR_FOCUS_HOVER_ACTION_ID = 'editor.action.showHover';\nexport const SHOW_DEFINITION_PREVIEW_HOVER_ACTION_ID = 'editor.action.showDefinitionPreviewHover';\nexport const SCROLL_UP_HOVER_ACTION_ID = 'editor.action.scrollUpHover';\nexport const SCROLL_DOWN_HOVER_ACTION_ID = 'editor.action.scrollDownHover';\nexport const SCROLL_LEFT_HOVER_ACTION_ID = 'editor.action.scrollLeftHover';\nexport const SCROLL_RIGHT_HOVER_ACTION_ID = 'editor.action.scrollRightHover';\nexport const PAGE_UP_HOVER_ACTION_ID = 'editor.action.pageUpHover';\nexport const PAGE_DOWN_HOVER_ACTION_ID = 'editor.action.pageDownHover';\nexport const GO_TO_TOP_HOVER_ACTION_ID = 'editor.action.goToTopHover';\nexport const GO_TO_BOTTOM_HOVER_ACTION_ID = 'editor.action.goToBottomHover';\nexport const INCREASE_HOVER_VERBOSITY_ACTION_ID = 'editor.action.increaseHoverVerbosityLevel';\nexport const INCREASE_HOVER_VERBOSITY_ACTION_LABEL = nls.localize({ key: 'increaseHoverVerbosityLevel', comment: ['Label for action that will increase the hover verbosity level.'] }, \"Increase Hover Verbosity Level\");\nexport const DECREASE_HOVER_VERBOSITY_ACTION_ID = 'editor.action.decreaseHoverVerbosityLevel';\nexport const DECREASE_HOVER_VERBOSITY_ACTION_LABEL = nls.localize({ key: 'decreaseHoverVerbosityLevel', comment: ['Label for action that will decrease the hover verbosity level.'] }, \"Decrease Hover Verbosity Level\");\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 *--------------------------------------------------------------------------------------------*/\nimport { DECREASE_HOVER_VERBOSITY_ACTION_ID, DECREASE_HOVER_VERBOSITY_ACTION_LABEL, GO_TO_BOTTOM_HOVER_ACTION_ID, GO_TO_TOP_HOVER_ACTION_ID, INCREASE_HOVER_VERBOSITY_ACTION_ID, INCREASE_HOVER_VERBOSITY_ACTION_LABEL, PAGE_DOWN_HOVER_ACTION_ID, PAGE_UP_HOVER_ACTION_ID, SCROLL_DOWN_HOVER_ACTION_ID, SCROLL_LEFT_HOVER_ACTION_ID, SCROLL_RIGHT_HOVER_ACTION_ID, SCROLL_UP_HOVER_ACTION_ID, SHOW_DEFINITION_PREVIEW_HOVER_ACTION_ID, SHOW_OR_FOCUS_HOVER_ACTION_ID } from './hoverActionIds.js';\nimport { KeyChord } from '../../../../base/common/keyCodes.js';\nimport { EditorAction } from '../../../browser/editorExtensions.js';\nimport { Range } from '../../../common/core/range.js';\nimport { EditorContextKeys } from '../../../common/editorContextKeys.js';\nimport { GotoDefinitionAtPositionEditorContribution } from '../../gotoSymbol/browser/link/goToDefinitionAtPosition.js';\nimport { HoverController } from './hoverController.js';\nimport { HoverVerbosityAction } from '../../../common/languages.js';\nimport * as nls from '../../../../nls.js';\nimport './hover.css';\nvar HoverFocusBehavior;\n(function (HoverFocusBehavior) {\n HoverFocusBehavior[\"NoAutoFocus\"] = \"noAutoFocus\";\n HoverFocusBehavior[\"FocusIfVisible\"] = \"focusIfVisible\";\n HoverFocusBehavior[\"AutoFocusImmediately\"] = \"autoFocusImmediately\";\n})(HoverFocusBehavior || (HoverFocusBehavior = {}));\nexport class ShowOrFocusHoverAction extends EditorAction {\n constructor() {\n super({\n id: SHOW_OR_FOCUS_HOVER_ACTION_ID,\n label: nls.localize({\n key: 'showOrFocusHover',\n comment: [\n 'Label for action that will trigger the showing/focusing of a hover in the editor.',\n 'If the hover is not visible, it will show the hover.',\n 'This allows for users to show the hover without using the mouse.'\n ]\n }, \"Show or Focus Hover\"),\n metadata: {\n description: nls.localize2('showOrFocusHoverDescription', 'Show or focus the editor hover which shows documentation, references, and other content for a symbol at the current cursor position.'),\n args: [{\n name: 'args',\n schema: {\n type: 'object',\n properties: {\n 'focus': {\n description: 'Controls if and when the hover should take focus upon being triggered by this action.',\n enum: [HoverFocusBehavior.NoAutoFocus, HoverFocusBehavior.FocusIfVisible, HoverFocusBehavior.AutoFocusImmediately],\n enumDescriptions: [\n nls.localize('showOrFocusHover.focus.noAutoFocus', 'The hover will not automatically take focus.'),\n nls.localize('showOrFocusHover.focus.focusIfVisible', 'The hover will take focus only if it is already visible.'),\n nls.localize('showOrFocusHover.focus.autoFocusImmediately', 'The hover will automatically take focus when it appears.'),\n ],\n default: HoverFocusBehavior.FocusIfVisible,\n }\n },\n }\n }]\n },\n alias: 'Show or Focus Hover',\n precondition: undefined,\n kbOpts: {\n kbExpr: EditorContextKeys.editorTextFocus,\n primary: KeyChord(2048 /* KeyMod.CtrlCmd */ | 41 /* KeyCode.KeyK */, 2048 /* KeyMod.CtrlCmd */ | 39 /* KeyCode.KeyI */),\n weight: 100 /* KeybindingWeight.EditorContrib */\n }\n });\n }\n run(accessor, editor, args) {\n if (!editor.hasModel()) {\n return;\n }\n const controller = HoverController.get(editor);\n if (!controller) {\n return;\n }\n const focusArgument = args === null || args === void 0 ? void 0 : args.focus;\n let focusOption = HoverFocusBehavior.FocusIfVisible;\n if (Object.values(HoverFocusBehavior).includes(focusArgument)) {\n focusOption = focusArgument;\n }\n else if (typeof focusArgument === 'boolean' && focusArgument) {\n focusOption = HoverFocusBehavior.AutoFocusImmediately;\n }\n const showContentHover = (focus) => {\n const position = editor.getPosition();\n const range = new Range(position.lineNumber, position.column, position.lineNumber, position.column);\n controller.showContentHover(range, 1 /* HoverStartMode.Immediate */, 1 /* HoverStartSource.Keyboard */, focus);\n };\n const accessibilitySupportEnabled = editor.getOption(2 /* EditorOption.accessibilitySupport */) === 2 /* AccessibilitySupport.Enabled */;\n if (controller.isHoverVisible) {\n if (focusOption !== HoverFocusBehavior.NoAutoFocus) {\n controller.focus();\n }\n else {\n showContentHover(accessibilitySupportEnabled);\n }\n }\n else {\n showContentHover(accessibilitySupportEnabled || focusOption === HoverFocusBehavior.AutoFocusImmediately);\n }\n }\n}\nexport class ShowDefinitionPreviewHoverAction extends EditorAction {\n constructor() {\n super({\n id: SHOW_DEFINITION_PREVIEW_HOVER_ACTION_ID,\n label: nls.localize({\n key: 'showDefinitionPreviewHover',\n comment: [\n 'Label for action that will trigger the showing of definition preview hover in the editor.',\n 'This allows for users to show the definition preview hover without using the mouse.'\n ]\n }, \"Show Definition Preview Hover\"),\n alias: 'Show Definition Preview Hover',\n precondition: undefined,\n metadata: {\n description: nls.localize2('showDefinitionPreviewHoverDescription', 'Show the definition preview hover in the editor.'),\n },\n });\n }\n run(accessor, editor) {\n const controller = HoverController.get(editor);\n if (!controller) {\n return;\n }\n const position = editor.getPosition();\n if (!position) {\n return;\n }\n const range = new Range(position.lineNumber, position.column, position.lineNumber, position.column);\n const goto = GotoDefinitionAtPositionEditorContribution.get(editor);\n if (!goto) {\n return;\n }\n const promise = goto.startFindDefinitionFromCursor(position);\n promise.then(() => {\n controller.showContentHover(range, 1 /* HoverStartMode.Immediate */, 1 /* HoverStartSource.Keyboard */, true);\n });\n }\n}\nexport class ScrollUpHoverAction extends EditorAction {\n constructor() {\n super({\n id: SCROLL_UP_HOVER_ACTION_ID,\n label: nls.localize({\n key: 'scrollUpHover',\n comment: [\n 'Action that allows to scroll up in the hover widget with the up arrow when the hover widget is focused.'\n ]\n }, \"Scroll Up Hover\"),\n alias: 'Scroll Up Hover',\n precondition: EditorContextKeys.hoverFocused,\n kbOpts: {\n kbExpr: EditorContextKeys.hoverFocused,\n primary: 16 /* KeyCode.UpArrow */,\n weight: 100 /* KeybindingWeight.EditorContrib */\n },\n metadata: {\n description: nls.localize2('scrollUpHoverDescription', 'Scroll up the editor hover.')\n },\n });\n }\n run(accessor, editor) {\n const controller = HoverController.get(editor);\n if (!controller) {\n return;\n }\n controller.scrollUp();\n }\n}\nexport class ScrollDownHoverAction extends EditorAction {\n constructor() {\n super({\n id: SCROLL_DOWN_HOVER_ACTION_ID,\n label: nls.localize({\n key: 'scrollDownHover',\n comment: [\n 'Action that allows to scroll down in the hover widget with the up arrow when the hover widget is focused.'\n ]\n }, \"Scroll Down Hover\"),\n alias: 'Scroll Down Hover',\n precondition: EditorContextKeys.hoverFocused,\n kbOpts: {\n kbExpr: EditorContextKeys.hoverFocused,\n primary: 18 /* KeyCode.DownArrow */,\n weight: 100 /* KeybindingWeight.EditorContrib */\n },\n metadata: {\n description: nls.localize2('scrollDownHoverDescription', 'Scroll down the editor hover.'),\n },\n });\n }\n run(accessor, editor) {\n const controller = HoverController.get(editor);\n if (!controller) {\n return;\n }\n controller.scrollDown();\n }\n}\nexport class ScrollLeftHoverAction extends EditorAction {\n constructor() {\n super({\n id: SCROLL_LEFT_HOVER_ACTION_ID,\n label: nls.localize({\n key: 'scrollLeftHover',\n comment: [\n 'Action that allows to scroll left in the hover widget with the left arrow when the hover widget is focused.'\n ]\n }, \"Scroll Left Hover\"),\n alias: 'Scroll Left Hover',\n precondition: EditorContextKeys.hoverFocused,\n kbOpts: {\n kbExpr: EditorContextKeys.hoverFocused,\n primary: 15 /* KeyCode.LeftArrow */,\n weight: 100 /* KeybindingWeight.EditorContrib */\n },\n metadata: {\n description: nls.localize2('scrollLeftHoverDescription', 'Scroll left the editor hover.'),\n },\n });\n }\n run(accessor, editor) {\n const controller = HoverController.get(editor);\n if (!controller) {\n return;\n }\n controller.scrollLeft();\n }\n}\nexport class ScrollRightHoverAction extends EditorAction {\n constructor() {\n super({\n id: SCROLL_RIGHT_HOVER_ACTION_ID,\n label: nls.localize({\n key: 'scrollRightHover',\n comment: [\n 'Action that allows to scroll right in the hover widget with the right arrow when the hover widget is focused.'\n ]\n }, \"Scroll Right Hover\"),\n alias: 'Scroll Right Hover',\n precondition: EditorContextKeys.hoverFocused,\n kbOpts: {\n kbExpr: EditorContextKeys.hoverFocused,\n primary: 17 /* KeyCode.RightArrow */,\n weight: 100 /* KeybindingWeight.EditorContrib */\n },\n metadata: {\n description: nls.localize2('scrollRightHoverDescription', 'Scroll right the editor hover.')\n },\n });\n }\n run(accessor, editor) {\n const controller = HoverController.get(editor);\n if (!controller) {\n return;\n }\n controller.scrollRight();\n }\n}\nexport class PageUpHoverAction extends EditorAction {\n constructor() {\n super({\n id: PAGE_UP_HOVER_ACTION_ID,\n label: nls.localize({\n key: 'pageUpHover',\n comment: [\n 'Action that allows to page up in the hover widget with the page up command when the hover widget is focused.'\n ]\n }, \"Page Up Hover\"),\n alias: 'Page Up Hover',\n precondition: EditorContextKeys.hoverFocused,\n kbOpts: {\n kbExpr: EditorContextKeys.hoverFocused,\n primary: 11 /* KeyCode.PageUp */,\n secondary: [512 /* KeyMod.Alt */ | 16 /* KeyCode.UpArrow */],\n weight: 100 /* KeybindingWeight.EditorContrib */\n },\n metadata: {\n description: nls.localize2('pageUpHoverDescription', 'Page up the editor hover.'),\n },\n });\n }\n run(accessor, editor) {\n const controller = HoverController.get(editor);\n if (!controller) {\n return;\n }\n controller.pageUp();\n }\n}\nexport class PageDownHoverAction extends EditorAction {\n constructor() {\n super({\n id: PAGE_DOWN_HOVER_ACTION_ID,\n label: nls.localize({\n key: 'pageDownHover',\n comment: [\n 'Action that allows to page down in the hover widget with the page down command when the hover widget is focused.'\n ]\n }, \"Page Down Hover\"),\n alias: 'Page Down Hover',\n precondition: EditorContextKeys.hoverFocused,\n kbOpts: {\n kbExpr: EditorContextKeys.hoverFocused,\n primary: 12 /* KeyCode.PageDown */,\n secondary: [512 /* KeyMod.Alt */ | 18 /* KeyCode.DownArrow */],\n weight: 100 /* KeybindingWeight.EditorContrib */\n },\n metadata: {\n description: nls.localize2('pageDownHoverDescription', 'Page down the editor hover.'),\n },\n });\n }\n run(accessor, editor) {\n const controller = HoverController.get(editor);\n if (!controller) {\n return;\n }\n controller.pageDown();\n }\n}\nexport class GoToTopHoverAction extends EditorAction {\n constructor() {\n super({\n id: GO_TO_TOP_HOVER_ACTION_ID,\n label: nls.localize({\n key: 'goToTopHover',\n comment: [\n 'Action that allows to go to the top of the hover widget with the home command when the hover widget is focused.'\n ]\n }, \"Go To Top Hover\"),\n alias: 'Go To Bottom Hover',\n precondition: EditorContextKeys.hoverFocused,\n kbOpts: {\n kbExpr: EditorContextKeys.hoverFocused,\n primary: 14 /* KeyCode.Home */,\n secondary: [2048 /* KeyMod.CtrlCmd */ | 16 /* KeyCode.UpArrow */],\n weight: 100 /* KeybindingWeight.EditorContrib */\n },\n metadata: {\n description: nls.localize2('goToTopHoverDescription', 'Go to the top of the editor hover.'),\n },\n });\n }\n run(accessor, editor) {\n const controller = HoverController.get(editor);\n if (!controller) {\n return;\n }\n controller.goToTop();\n }\n}\nexport class GoToBottomHoverAction extends EditorAction {\n constructor() {\n super({\n id: GO_TO_BOTTOM_HOVER_ACTION_ID,\n label: nls.localize({\n key: 'goToBottomHover',\n comment: [\n 'Action that allows to go to the bottom in the hover widget with the end command when the hover widget is focused.'\n ]\n }, \"Go To Bottom Hover\"),\n alias: 'Go To Bottom Hover',\n precondition: EditorContextKeys.hoverFocused,\n kbOpts: {\n kbExpr: EditorContextKeys.hoverFocused,\n primary: 13 /* KeyCode.End */,\n secondary: [2048 /* KeyMod.CtrlCmd */ | 18 /* KeyCode.DownArrow */],\n weight: 100 /* KeybindingWeight.EditorContrib */\n },\n metadata: {\n description: nls.localize2('goToBottomHoverDescription', 'Go to the bottom of the editor hover.')\n },\n });\n }\n run(accessor, editor) {\n const controller = HoverController.get(editor);\n if (!controller) {\n return;\n }\n controller.goToBottom();\n }\n}\nexport class IncreaseHoverVerbosityLevel extends EditorAction {\n constructor() {\n super({\n id: INCREASE_HOVER_VERBOSITY_ACTION_ID,\n label: INCREASE_HOVER_VERBOSITY_ACTION_LABEL,\n alias: 'Increase Hover Verbosity Level',\n precondition: EditorContextKeys.hoverVisible\n });\n }\n run(accessor, editor, args) {\n var _a;\n (_a = HoverController.get(editor)) === null || _a === void 0 ? void 0 : _a.updateMarkdownHoverVerbosityLevel(HoverVerbosityAction.Increase, args === null || args === void 0 ? void 0 : args.index, args === null || args === void 0 ? void 0 : args.focus);\n }\n}\nexport class DecreaseHoverVerbosityLevel extends EditorAction {\n constructor() {\n super({\n id: DECREASE_HOVER_VERBOSITY_ACTION_ID,\n label: DECREASE_HOVER_VERBOSITY_ACTION_LABEL,\n alias: 'Decrease Hover Verbosity Level',\n precondition: EditorContextKeys.hoverVisible\n });\n }\n run(accessor, editor, args) {\n var _a;\n (_a = HoverController.get(editor)) === null || _a === void 0 ? void 0 : _a.updateMarkdownHoverVerbosityLevel(HoverVerbosityAction.Decrease, args === null || args === void 0 ? void 0 : args.index, args === null || args === void 0 ? void 0 : args.focus);\n }\n}\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 *--------------------------------------------------------------------------------------------*/\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __param = (this && this.__param) || function (paramIndex, decorator) {\n return function (target, key) { decorator(target, key, paramIndex); }\n};\nimport * as dom from '../../../../base/browser/dom.js';\nimport { isNonEmptyArray } from '../../../../base/common/arrays.js';\nimport { createCancelablePromise, disposableTimeout } from '../../../../base/common/async.js';\nimport { onUnexpectedError } from '../../../../base/common/errors.js';\nimport { Disposable, DisposableStore, toDisposable } from '../../../../base/common/lifecycle.js';\nimport { basename } from '../../../../base/common/resources.js';\nimport { Range } from '../../../common/core/range.js';\nimport { ILanguageFeaturesService } from '../../../common/services/languageFeatures.js';\nimport { IMarkerDecorationsService } from '../../../common/services/markerDecorations.js';\nimport { getCodeActions, quickFixCommandId } from '../../codeAction/browser/codeAction.js';\nimport { CodeActionController } from '../../codeAction/browser/codeActionController.js';\nimport { CodeActionKind, CodeActionTriggerSource } from '../../codeAction/common/types.js';\nimport { MarkerController, NextMarkerAction } from '../../gotoError/browser/gotoError.js';\nimport * as nls from '../../../../nls.js';\nimport { IMarkerData, MarkerSeverity } from '../../../../platform/markers/common/markers.js';\nimport { IOpenerService } from '../../../../platform/opener/common/opener.js';\nimport { Progress } from '../../../../platform/progress/common/progress.js';\nconst $ = dom.$;\nexport class MarkerHover {\n constructor(owner, range, marker) {\n this.owner = owner;\n this.range = range;\n this.marker = marker;\n }\n isValidForHoverAnchor(anchor) {\n return (anchor.type === 1 /* HoverAnchorType.Range */\n && this.range.startColumn <= anchor.range.startColumn\n && this.range.endColumn >= anchor.range.endColumn);\n }\n}\nconst markerCodeActionTrigger = {\n type: 1 /* CodeActionTriggerType.Invoke */,\n filter: { include: CodeActionKind.QuickFix },\n triggerAction: CodeActionTriggerSource.QuickFixHover\n};\nlet MarkerHoverParticipant = class MarkerHoverParticipant {\n constructor(_editor, _markerDecorationsService, _openerService, _languageFeaturesService) {\n this._editor = _editor;\n this._markerDecorationsService = _markerDecorationsService;\n this._openerService = _openerService;\n this._languageFeaturesService = _languageFeaturesService;\n this.hoverOrdinal = 1;\n this.recentMarkerCodeActionsInfo = undefined;\n }\n computeSync(anchor, lineDecorations) {\n if (!this._editor.hasModel() || anchor.type !== 1 /* HoverAnchorType.Range */ && !anchor.supportsMarkerHover) {\n return [];\n }\n const model = this._editor.getModel();\n const lineNumber = anchor.range.startLineNumber;\n const maxColumn = model.getLineMaxColumn(lineNumber);\n const result = [];\n for (const d of lineDecorations) {\n const startColumn = (d.range.startLineNumber === lineNumber) ? d.range.startColumn : 1;\n const endColumn = (d.range.endLineNumber === lineNumber) ? d.range.endColumn : maxColumn;\n const marker = this._markerDecorationsService.getMarker(model.uri, d);\n if (!marker) {\n continue;\n }\n const range = new Range(anchor.range.startLineNumber, startColumn, anchor.range.startLineNumber, endColumn);\n result.push(new MarkerHover(this, range, marker));\n }\n return result;\n }\n renderHoverParts(context, hoverParts) {\n if (!hoverParts.length) {\n return Disposable.None;\n }\n const disposables = new DisposableStore();\n hoverParts.forEach(msg => context.fragment.appendChild(this.renderMarkerHover(msg, disposables)));\n const markerHoverForStatusbar = hoverParts.length === 1 ? hoverParts[0] : hoverParts.sort((a, b) => MarkerSeverity.compare(a.marker.severity, b.marker.severity))[0];\n this.renderMarkerStatusbar(context, markerHoverForStatusbar, disposables);\n return disposables;\n }\n renderMarkerHover(markerHover, disposables) {\n const hoverElement = $('div.hover-row');\n hoverElement.tabIndex = 0;\n const markerElement = dom.append(hoverElement, $('div.marker.hover-contents'));\n const { source, message, code, relatedInformation } = markerHover.marker;\n this._editor.applyFontInfo(markerElement);\n const messageElement = dom.append(markerElement, $('span'));\n messageElement.style.whiteSpace = 'pre-wrap';\n messageElement.innerText = message;\n if (source || code) {\n // Code has link\n if (code && typeof code !== 'string') {\n const sourceAndCodeElement = $('span');\n if (source) {\n const sourceElement = dom.append(sourceAndCodeElement, $('span'));\n sourceElement.innerText = source;\n }\n const codeLink = dom.append(sourceAndCodeElement, $('a.code-link'));\n codeLink.setAttribute('href', code.target.toString());\n disposables.add(dom.addDisposableListener(codeLink, 'click', (e) => {\n this._openerService.open(code.target, { allowCommands: true });\n e.preventDefault();\n e.stopPropagation();\n }));\n const codeElement = dom.append(codeLink, $('span'));\n codeElement.innerText = code.value;\n const detailsElement = dom.append(markerElement, sourceAndCodeElement);\n detailsElement.style.opacity = '0.6';\n detailsElement.style.paddingLeft = '6px';\n }\n else {\n const detailsElement = dom.append(markerElement, $('span'));\n detailsElement.style.opacity = '0.6';\n detailsElement.style.paddingLeft = '6px';\n detailsElement.innerText = source && code ? `${source}(${code})` : source ? source : `(${code})`;\n }\n }\n if (isNonEmptyArray(relatedInformation)) {\n for (const { message, resource, startLineNumber, startColumn } of relatedInformation) {\n const relatedInfoContainer = dom.append(markerElement, $('div'));\n relatedInfoContainer.style.marginTop = '8px';\n const a = dom.append(relatedInfoContainer, $('a'));\n a.innerText = `${basename(resource)}(${startLineNumber}, ${startColumn}): `;\n a.style.cursor = 'pointer';\n disposables.add(dom.addDisposableListener(a, 'click', (e) => {\n e.stopPropagation();\n e.preventDefault();\n if (this._openerService) {\n this._openerService.open(resource, {\n fromUserGesture: true,\n editorOptions: { selection: { startLineNumber, startColumn } }\n }).catch(onUnexpectedError);\n }\n }));\n const messageElement = dom.append(relatedInfoContainer, $('span'));\n messageElement.innerText = message;\n this._editor.applyFontInfo(messageElement);\n }\n }\n return hoverElement;\n }\n renderMarkerStatusbar(context, markerHover, disposables) {\n if (markerHover.marker.severity === MarkerSeverity.Error || markerHover.marker.severity === MarkerSeverity.Warning || markerHover.marker.severity === MarkerSeverity.Info) {\n const markerController = MarkerController.get(this._editor);\n if (markerController) {\n context.statusBar.addAction({\n label: nls.localize('view problem', \"View Problem\"),\n commandId: NextMarkerAction.ID,\n run: () => {\n context.hide();\n markerController.showAtMarker(markerHover.marker);\n this._editor.focus();\n }\n });\n }\n }\n if (!this._editor.getOption(91 /* EditorOption.readOnly */)) {\n const quickfixPlaceholderElement = context.statusBar.append($('div'));\n if (this.recentMarkerCodeActionsInfo) {\n if (IMarkerData.makeKey(this.recentMarkerCodeActionsInfo.marker) === IMarkerData.makeKey(markerHover.marker)) {\n if (!this.recentMarkerCodeActionsInfo.hasCodeActions) {\n quickfixPlaceholderElement.textContent = nls.localize('noQuickFixes', \"No quick fixes available\");\n }\n }\n else {\n this.recentMarkerCodeActionsInfo = undefined;\n }\n }\n const updatePlaceholderDisposable = this.recentMarkerCodeActionsInfo && !this.recentMarkerCodeActionsInfo.hasCodeActions ? Disposable.None : disposableTimeout(() => quickfixPlaceholderElement.textContent = nls.localize('checkingForQuickFixes', \"Checking for quick fixes...\"), 200, disposables);\n if (!quickfixPlaceholderElement.textContent) {\n // Have some content in here to avoid flickering\n quickfixPlaceholderElement.textContent = String.fromCharCode(0xA0); //  \n }\n const codeActionsPromise = this.getCodeActions(markerHover.marker);\n disposables.add(toDisposable(() => codeActionsPromise.cancel()));\n codeActionsPromise.then(actions => {\n updatePlaceholderDisposable.dispose();\n this.recentMarkerCodeActionsInfo = { marker: markerHover.marker, hasCodeActions: actions.validActions.length > 0 };\n if (!this.recentMarkerCodeActionsInfo.hasCodeActions) {\n actions.dispose();\n quickfixPlaceholderElement.textContent = nls.localize('noQuickFixes', \"No quick fixes available\");\n return;\n }\n quickfixPlaceholderElement.style.display = 'none';\n let showing = false;\n disposables.add(toDisposable(() => {\n if (!showing) {\n actions.dispose();\n }\n }));\n context.statusBar.addAction({\n label: nls.localize('quick fixes', \"Quick Fix...\"),\n commandId: quickFixCommandId,\n run: (target) => {\n showing = true;\n const controller = CodeActionController.get(this._editor);\n const elementPosition = dom.getDomNodePagePosition(target);\n // Hide the hover pre-emptively, otherwise the editor can close the code actions\n // context menu as well when using keyboard navigation\n context.hide();\n controller === null || controller === void 0 ? void 0 : controller.showCodeActions(markerCodeActionTrigger, actions, {\n x: elementPosition.left,\n y: elementPosition.top,\n width: elementPosition.width,\n height: elementPosition.height\n });\n }\n });\n }, onUnexpectedError);\n }\n }\n getCodeActions(marker) {\n return createCancelablePromise(cancellationToken => {\n return getCodeActions(this._languageFeaturesService.codeActionProvider, this._editor.getModel(), new Range(marker.startLineNumber, marker.startColumn, marker.endLineNumber, marker.endColumn), markerCodeActionTrigger, Progress.None, cancellationToken);\n });\n }\n};\nMarkerHoverParticipant = __decorate([\n __param(1, IMarkerDecorationsService),\n __param(2, IOpenerService),\n __param(3, ILanguageFeaturesService)\n], MarkerHoverParticipant);\nexport { MarkerHoverParticipant };\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 *--------------------------------------------------------------------------------------------*/\nimport { localize } from '../../../../nls.js';\nimport { HoverVerbosityAction } from '../../../common/languages.js';\nimport { DECREASE_HOVER_VERBOSITY_ACTION_ID, INCREASE_HOVER_VERBOSITY_ACTION_ID } from './hoverActionIds.js';\nimport { Disposable } from '../../../../base/common/lifecycle.js';\nvar HoverAccessibilityHelpNLS;\n(function (HoverAccessibilityHelpNLS) {\n HoverAccessibilityHelpNLS.intro = localize('intro', \"Focus on the hover widget to cycle through the hover parts with the Tab key.\");\n HoverAccessibilityHelpNLS.increaseVerbosity = localize('increaseVerbosity', \"- The focused hover part verbosity level can be increased with the Increase Hover Verbosity command.\", INCREASE_HOVER_VERBOSITY_ACTION_ID);\n HoverAccessibilityHelpNLS.decreaseVerbosity = localize('decreaseVerbosity', \"- The focused hover part verbosity level can be decreased with the Decrease Hover Verbosity command.\", DECREASE_HOVER_VERBOSITY_ACTION_ID);\n HoverAccessibilityHelpNLS.hoverContent = localize('contentHover', \"The last focused hover content is the following.\");\n})(HoverAccessibilityHelpNLS || (HoverAccessibilityHelpNLS = {}));\nexport class HoverAccessibleView {\n dispose() {\n var _a;\n (_a = this._provider) === null || _a === void 0 ? void 0 : _a.dispose();\n }\n}\nexport class HoverAccessibilityHelp {\n dispose() {\n var _a;\n (_a = this._provider) === null || _a === void 0 ? void 0 : _a.dispose();\n }\n}\nclass BaseHoverAccessibleViewProvider extends Disposable {\n constructor(_hoverController) {\n super();\n this._hoverController = _hoverController;\n this._markdownHoverFocusedIndex = -1;\n }\n}\nexport class HoverAccessibilityHelpProvider extends BaseHoverAccessibleViewProvider {\n constructor(hoverController) {\n super(hoverController);\n this.options = { type: \"help\" /* AccessibleViewType.Help */ };\n }\n provideContentAtIndex(index) {\n const content = [];\n content.push(HoverAccessibilityHelpNLS.intro);\n content.push(...this._descriptionsOfVerbosityActionsForIndex(index));\n content.push(...this._descriptionOfFocusedMarkdownHoverAtIndex(index));\n return content.join('\\n');\n }\n _descriptionsOfVerbosityActionsForIndex(index) {\n const content = [];\n const descriptionForIncreaseAction = this._descriptionOfVerbosityActionForIndex(HoverVerbosityAction.Increase, index);\n if (descriptionForIncreaseAction !== undefined) {\n content.push(descriptionForIncreaseAction);\n }\n const descriptionForDecreaseAction = this._descriptionOfVerbosityActionForIndex(HoverVerbosityAction.Decrease, index);\n if (descriptionForDecreaseAction !== undefined) {\n content.push(descriptionForDecreaseAction);\n }\n return content;\n }\n _descriptionOfVerbosityActionForIndex(action, index) {\n const isActionSupported = this._hoverController.doesMarkdownHoverAtIndexSupportVerbosityAction(index, action);\n if (!isActionSupported) {\n return;\n }\n switch (action) {\n case HoverVerbosityAction.Increase:\n return HoverAccessibilityHelpNLS.increaseVerbosity;\n case HoverVerbosityAction.Decrease:\n return HoverAccessibilityHelpNLS.decreaseVerbosity;\n }\n }\n _descriptionOfFocusedMarkdownHoverAtIndex(index) {\n const content = [];\n const hoverContent = this._hoverController.markdownHoverContentAtIndex(index);\n if (hoverContent) {\n content.push('\\n' + HoverAccessibilityHelpNLS.hoverContent);\n content.push('\\n' + hoverContent);\n }\n return content;\n }\n}\nexport class HoverAccessibleViewProvider extends BaseHoverAccessibleViewProvider {\n constructor(_keybindingService, _editor, hoverController) {\n super(hoverController);\n this._keybindingService = _keybindingService;\n this._editor = _editor;\n this.options = { type: \"view\" /* AccessibleViewType.View */ };\n this._initializeOptions(this._editor, hoverController);\n }\n _initializeOptions(editor, hoverController) {\n var _a;\n const helpProvider = this._register(new HoverAccessibilityHelpProvider(hoverController));\n this.options.language = (_a = editor.getModel()) === null || _a === void 0 ? void 0 : _a.getLanguageId();\n this.options.customHelp = () => { return helpProvider.provideContentAtIndex(this._markdownHoverFocusedIndex); };\n }\n}\nexport class ExtHoverAccessibleView {\n dispose() { }\n}\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 *--------------------------------------------------------------------------------------------*/\nimport { DecreaseHoverVerbosityLevel, GoToBottomHoverAction, GoToTopHoverAction, IncreaseHoverVerbosityLevel, PageDownHoverAction, PageUpHoverAction, ScrollDownHoverAction, ScrollLeftHoverAction, ScrollRightHoverAction, ScrollUpHoverAction, ShowDefinitionPreviewHoverAction, ShowOrFocusHoverAction } from './hoverActions.js';\nimport { registerEditorAction, registerEditorContribution } from '../../../browser/editorExtensions.js';\nimport { editorHoverBorder } from '../../../../platform/theme/common/colorRegistry.js';\nimport { registerThemingParticipant } from '../../../../platform/theme/common/themeService.js';\nimport { HoverParticipantRegistry } from './hoverTypes.js';\nimport { MarkdownHoverParticipant } from './markdownHoverParticipant.js';\nimport { MarkerHoverParticipant } from './markerHoverParticipant.js';\nimport { HoverController } from './hoverController.js';\nimport './hover.css';\nimport { AccessibleViewRegistry } from '../../../../platform/accessibility/browser/accessibleViewRegistry.js';\nimport { ExtHoverAccessibleView, HoverAccessibilityHelp, HoverAccessibleView } from './hoverAccessibleViews.js';\nregisterEditorContribution(HoverController.ID, HoverController, 2 /* EditorContributionInstantiation.BeforeFirstInteraction */);\nregisterEditorAction(ShowOrFocusHoverAction);\nregisterEditorAction(ShowDefinitionPreviewHoverAction);\nregisterEditorAction(ScrollUpHoverAction);\nregisterEditorAction(ScrollDownHoverAction);\nregisterEditorAction(ScrollLeftHoverAction);\nregisterEditorAction(ScrollRightHoverAction);\nregisterEditorAction(PageUpHoverAction);\nregisterEditorAction(PageDownHoverAction);\nregisterEditorAction(GoToTopHoverAction);\nregisterEditorAction(GoToBottomHoverAction);\nregisterEditorAction(IncreaseHoverVerbosityLevel);\nregisterEditorAction(DecreaseHoverVerbosityLevel);\nHoverParticipantRegistry.register(MarkdownHoverParticipant);\nHoverParticipantRegistry.register(MarkerHoverParticipant);\n// theming\nregisterThemingParticipant((theme, collector) => {\n const hoverBorder = theme.getColor(editorHoverBorder);\n if (hoverBorder) {\n collector.addRule(`.monaco-editor .monaco-hover .hover-row:not(:first-child):not(:empty) { border-top: 1px solid ${hoverBorder.transparent(0.5)}; }`);\n collector.addRule(`.monaco-editor .monaco-hover hr { border-top: 1px solid ${hoverBorder.transparent(0.5)}; }`);\n collector.addRule(`.monaco-editor .monaco-hover hr { border-bottom: 0px solid ${hoverBorder.transparent(0.5)}; }`);\n }\n});\nAccessibleViewRegistry.register(new HoverAccessibleView());\nAccessibleViewRegistry.register(new HoverAccessibilityHelp());\nAccessibleViewRegistry.register(new ExtHoverAccessibleView());\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 *--------------------------------------------------------------------------------------------*/\nimport { ResizableHTMLElement } from '../../../../base/browser/ui/resizable/resizable.js';\nimport { Disposable } from '../../../../base/common/lifecycle.js';\nimport { Position } from '../../../common/core/position.js';\nimport * as dom from '../../../../base/browser/dom.js';\nconst TOP_HEIGHT = 30;\nconst BOTTOM_HEIGHT = 24;\nexport class ResizableContentWidget extends Disposable {\n constructor(_editor, minimumSize = new dom.Dimension(10, 10)) {\n super();\n this._editor = _editor;\n this.allowEditorOverflow = true;\n this.suppressMouseDown = false;\n this._resizableNode = this._register(new ResizableHTMLElement());\n this._contentPosition = null;\n this._isResizing = false;\n this._resizableNode.domNode.style.position = 'absolute';\n this._resizableNode.minSize = dom.Dimension.lift(minimumSize);\n this._resizableNode.layout(minimumSize.height, minimumSize.width);\n this._resizableNode.enableSashes(true, true, true, true);\n this._register(this._resizableNode.onDidResize(e => {\n this._resize(new dom.Dimension(e.dimension.width, e.dimension.height));\n if (e.done) {\n this._isResizing = false;\n }\n }));\n this._register(this._resizableNode.onDidWillResize(() => {\n this._isResizing = true;\n }));\n }\n get isResizing() {\n return this._isResizing;\n }\n getDomNode() {\n return this._resizableNode.domNode;\n }\n getPosition() {\n return this._contentPosition;\n }\n get position() {\n var _a;\n return ((_a = this._contentPosition) === null || _a === void 0 ? void 0 : _a.position) ? Position.lift(this._contentPosition.position) : undefined;\n }\n _availableVerticalSpaceAbove(position) {\n const editorDomNode = this._editor.getDomNode();\n const mouseBox = this._editor.getScrolledVisiblePosition(position);\n if (!editorDomNode || !mouseBox) {\n return;\n }\n const editorBox = dom.getDomNodePagePosition(editorDomNode);\n return editorBox.top + mouseBox.top - TOP_HEIGHT;\n }\n _availableVerticalSpaceBelow(position) {\n const editorDomNode = this._editor.getDomNode();\n const mouseBox = this._editor.getScrolledVisiblePosition(position);\n if (!editorDomNode || !mouseBox) {\n return;\n }\n const editorBox = dom.getDomNodePagePosition(editorDomNode);\n const bodyBox = dom.getClientArea(editorDomNode.ownerDocument.body);\n const mouseBottom = editorBox.top + mouseBox.top + mouseBox.height;\n return bodyBox.height - mouseBottom - BOTTOM_HEIGHT;\n }\n _findPositionPreference(widgetHeight, showAtPosition) {\n var _a, _b;\n const maxHeightBelow = Math.min((_a = this._availableVerticalSpaceBelow(showAtPosition)) !== null && _a !== void 0 ? _a : Infinity, widgetHeight);\n const maxHeightAbove = Math.min((_b = this._availableVerticalSpaceAbove(showAtPosition)) !== null && _b !== void 0 ? _b : Infinity, widgetHeight);\n const maxHeight = Math.min(Math.max(maxHeightAbove, maxHeightBelow), widgetHeight);\n const height = Math.min(widgetHeight, maxHeight);\n let renderingAbove;\n if (this._editor.getOption(60 /* EditorOption.hover */).above) {\n renderingAbove = height <= maxHeightAbove ? 1 /* ContentWidgetPositionPreference.ABOVE */ : 2 /* ContentWidgetPositionPreference.BELOW */;\n }\n else {\n renderingAbove = height <= maxHeightBelow ? 2 /* ContentWidgetPositionPreference.BELOW */ : 1 /* ContentWidgetPositionPreference.ABOVE */;\n }\n if (renderingAbove === 1 /* ContentWidgetPositionPreference.ABOVE */) {\n this._resizableNode.enableSashes(true, true, false, false);\n }\n else {\n this._resizableNode.enableSashes(false, true, true, false);\n }\n return renderingAbove;\n }\n _resize(dimension) {\n this._resizableNode.layout(dimension.height, dimension.width);\n }\n}\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 *--------------------------------------------------------------------------------------------*/\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __param = (this && this.__param) || function (paramIndex, decorator) {\n return function (target, key) { decorator(target, key, paramIndex); }\n};\nvar ContentHoverWidget_1;\nimport * as dom from '../../../../base/browser/dom.js';\nimport { IKeybindingService } from '../../../../platform/keybinding/common/keybinding.js';\nimport { ResizableContentWidget } from './resizableContentWidget.js';\nimport { IContextKeyService } from '../../../../platform/contextkey/common/contextkey.js';\nimport { IConfigurationService } from '../../../../platform/configuration/common/configuration.js';\nimport { IAccessibilityService } from '../../../../platform/accessibility/common/accessibility.js';\nimport { EditorContextKeys } from '../../../common/editorContextKeys.js';\nimport { getHoverAccessibleViewHint, HoverWidget } from '../../../../base/browser/ui/hover/hoverWidget.js';\nconst HORIZONTAL_SCROLLING_BY = 30;\nconst CONTAINER_HEIGHT_PADDING = 6;\nlet ContentHoverWidget = ContentHoverWidget_1 = class ContentHoverWidget extends ResizableContentWidget {\n get isColorPickerVisible() {\n var _a;\n return Boolean((_a = this._visibleData) === null || _a === void 0 ? void 0 : _a.colorPicker);\n }\n get isVisibleFromKeyboard() {\n var _a;\n return (((_a = this._visibleData) === null || _a === void 0 ? void 0 : _a.source) === 1 /* HoverStartSource.Keyboard */);\n }\n get isVisible() {\n var _a;\n return (_a = this._hoverVisibleKey.get()) !== null && _a !== void 0 ? _a : false;\n }\n get isFocused() {\n var _a;\n return (_a = this._hoverFocusedKey.get()) !== null && _a !== void 0 ? _a : false;\n }\n constructor(editor, contextKeyService, _configurationService, _accessibilityService, _keybindingService) {\n const minimumHeight = editor.getOption(67 /* EditorOption.lineHeight */) + 8;\n const minimumWidth = 150;\n const minimumSize = new dom.Dimension(minimumWidth, minimumHeight);\n super(editor, minimumSize);\n this._configurationService = _configurationService;\n this._accessibilityService = _accessibilityService;\n this._keybindingService = _keybindingService;\n this._hover = this._register(new HoverWidget());\n this._minimumSize = minimumSize;\n this._hoverVisibleKey = EditorContextKeys.hoverVisible.bindTo(contextKeyService);\n this._hoverFocusedKey = EditorContextKeys.hoverFocused.bindTo(contextKeyService);\n dom.append(this._resizableNode.domNode, this._hover.containerDomNode);\n this._resizableNode.domNode.style.zIndex = '50';\n this._register(this._editor.onDidLayoutChange(() => {\n if (this.isVisible) {\n this._updateMaxDimensions();\n }\n }));\n this._register(this._editor.onDidChangeConfiguration((e) => {\n if (e.hasChanged(50 /* EditorOption.fontInfo */)) {\n this._updateFont();\n }\n }));\n const focusTracker = this._register(dom.trackFocus(this._resizableNode.domNode));\n this._register(focusTracker.onDidFocus(() => {\n this._hoverFocusedKey.set(true);\n }));\n this._register(focusTracker.onDidBlur(() => {\n this._hoverFocusedKey.set(false);\n }));\n this._setHoverData(undefined);\n this._editor.addContentWidget(this);\n }\n dispose() {\n var _a;\n super.dispose();\n (_a = this._visibleData) === null || _a === void 0 ? void 0 : _a.disposables.dispose();\n this._editor.removeContentWidget(this);\n }\n getId() {\n return ContentHoverWidget_1.ID;\n }\n static _applyDimensions(container, width, height) {\n const transformedWidth = typeof width === 'number' ? `${width}px` : width;\n const transformedHeight = typeof height === 'number' ? `${height}px` : height;\n container.style.width = transformedWidth;\n container.style.height = transformedHeight;\n }\n _setContentsDomNodeDimensions(width, height) {\n const contentsDomNode = this._hover.contentsDomNode;\n return ContentHoverWidget_1._applyDimensions(contentsDomNode, width, height);\n }\n _setContainerDomNodeDimensions(width, height) {\n const containerDomNode = this._hover.containerDomNode;\n return ContentHoverWidget_1._applyDimensions(containerDomNode, width, height);\n }\n _setHoverWidgetDimensions(width, height) {\n this._setContentsDomNodeDimensions(width, height);\n this._setContainerDomNodeDimensions(width, height);\n this._layoutContentWidget();\n }\n static _applyMaxDimensions(container, width, height) {\n const transformedWidth = typeof width === 'number' ? `${width}px` : width;\n const transformedHeight = typeof height === 'number' ? `${height}px` : height;\n container.style.maxWidth = transformedWidth;\n container.style.maxHeight = transformedHeight;\n }\n _setHoverWidgetMaxDimensions(width, height) {\n ContentHoverWidget_1._applyMaxDimensions(this._hover.contentsDomNode, width, height);\n ContentHoverWidget_1._applyMaxDimensions(this._hover.containerDomNode, width, height);\n this._hover.containerDomNode.style.setProperty('--vscode-hover-maxWidth', typeof width === 'number' ? `${width}px` : width);\n this._layoutContentWidget();\n }\n _setAdjustedHoverWidgetDimensions(size) {\n this._setHoverWidgetMaxDimensions('none', 'none');\n const width = size.width;\n const height = size.height;\n this._setHoverWidgetDimensions(width, height);\n }\n _updateResizableNodeMaxDimensions() {\n var _a, _b;\n const maxRenderingWidth = (_a = this._findMaximumRenderingWidth()) !== null && _a !== void 0 ? _a : Infinity;\n const maxRenderingHeight = (_b = this._findMaximumRenderingHeight()) !== null && _b !== void 0 ? _b : Infinity;\n this._resizableNode.maxSize = new dom.Dimension(maxRenderingWidth, maxRenderingHeight);\n this._setHoverWidgetMaxDimensions(maxRenderingWidth, maxRenderingHeight);\n }\n _resize(size) {\n var _a, _b;\n ContentHoverWidget_1._lastDimensions = new dom.Dimension(size.width, size.height);\n this._setAdjustedHoverWidgetDimensions(size);\n this._resizableNode.layout(size.height, size.width);\n this._updateResizableNodeMaxDimensions();\n this._hover.scrollbar.scanDomNode();\n this._editor.layoutContentWidget(this);\n (_b = (_a = this._visibleData) === null || _a === void 0 ? void 0 : _a.colorPicker) === null || _b === void 0 ? void 0 : _b.layout();\n }\n _findAvailableSpaceVertically() {\n var _a;\n const position = (_a = this._visibleData) === null || _a === void 0 ? void 0 : _a.showAtPosition;\n if (!position) {\n return;\n }\n return this._positionPreference === 1 /* ContentWidgetPositionPreference.ABOVE */ ?\n this._availableVerticalSpaceAbove(position)\n : this._availableVerticalSpaceBelow(position);\n }\n _findMaximumRenderingHeight() {\n const availableSpace = this._findAvailableSpaceVertically();\n if (!availableSpace) {\n return;\n }\n // Padding needed in order to stop the resizing down to a smaller height\n let maximumHeight = CONTAINER_HEIGHT_PADDING;\n Array.from(this._hover.contentsDomNode.children).forEach((hoverPart) => {\n maximumHeight += hoverPart.clientHeight;\n });\n return Math.min(availableSpace, maximumHeight);\n }\n _isHoverTextOverflowing() {\n // To find out if the text is overflowing, we will disable wrapping, check the widths, and then re-enable wrapping\n this._hover.containerDomNode.style.setProperty('--vscode-hover-whiteSpace', 'nowrap');\n this._hover.containerDomNode.style.setProperty('--vscode-hover-sourceWhiteSpace', 'nowrap');\n const overflowing = Array.from(this._hover.contentsDomNode.children).some((hoverElement) => {\n return hoverElement.scrollWidth > hoverElement.clientWidth;\n });\n this._hover.containerDomNode.style.removeProperty('--vscode-hover-whiteSpace');\n this._hover.containerDomNode.style.removeProperty('--vscode-hover-sourceWhiteSpace');\n return overflowing;\n }\n _findMaximumRenderingWidth() {\n if (!this._editor || !this._editor.hasModel()) {\n return;\n }\n const overflowing = this._isHoverTextOverflowing();\n const initialWidth = (typeof this._contentWidth === 'undefined'\n ? 0\n : this._contentWidth - 2 // - 2 for the borders\n );\n if (overflowing || this._hover.containerDomNode.clientWidth < initialWidth) {\n const bodyBoxWidth = dom.getClientArea(this._hover.containerDomNode.ownerDocument.body).width;\n const horizontalPadding = 14;\n return bodyBoxWidth - horizontalPadding;\n }\n else {\n return this._hover.containerDomNode.clientWidth + 2;\n }\n }\n isMouseGettingCloser(posx, posy) {\n if (!this._visibleData) {\n return false;\n }\n if (typeof this._visibleData.initialMousePosX === 'undefined'\n || typeof this._visibleData.initialMousePosY === 'undefined') {\n this._visibleData.initialMousePosX = posx;\n this._visibleData.initialMousePosY = posy;\n return false;\n }\n const widgetRect = dom.getDomNodePagePosition(this.getDomNode());\n if (typeof this._visibleData.closestMouseDistance === 'undefined') {\n this._visibleData.closestMouseDistance = computeDistanceFromPointToRectangle(this._visibleData.initialMousePosX, this._visibleData.initialMousePosY, widgetRect.left, widgetRect.top, widgetRect.width, widgetRect.height);\n }\n const distance = computeDistanceFromPointToRectangle(posx, posy, widgetRect.left, widgetRect.top, widgetRect.width, widgetRect.height);\n if (distance > this._visibleData.closestMouseDistance + 4 /* tolerance of 4 pixels */) {\n // The mouse is getting farther away\n return false;\n }\n this._visibleData.closestMouseDistance = Math.min(this._visibleData.closestMouseDistance, distance);\n return true;\n }\n _setHoverData(hoverData) {\n var _a;\n (_a = this._visibleData) === null || _a === void 0 ? void 0 : _a.disposables.dispose();\n this._visibleData = hoverData;\n this._hoverVisibleKey.set(!!hoverData);\n this._hover.containerDomNode.classList.toggle('hidden', !hoverData);\n }\n _updateFont() {\n const { fontSize, lineHeight } = this._editor.getOption(50 /* EditorOption.fontInfo */);\n const contentsDomNode = this._hover.contentsDomNode;\n contentsDomNode.style.fontSize = `${fontSize}px`;\n contentsDomNode.style.lineHeight = `${lineHeight / fontSize}`;\n const codeClasses = Array.prototype.slice.call(this._hover.contentsDomNode.getElementsByClassName('code'));\n codeClasses.forEach(node => this._editor.applyFontInfo(node));\n }\n _updateContent(node) {\n const contentsDomNode = this._hover.contentsDomNode;\n contentsDomNode.style.paddingBottom = '';\n contentsDomNode.textContent = '';\n contentsDomNode.appendChild(node);\n }\n _layoutContentWidget() {\n this._editor.layoutContentWidget(this);\n this._hover.onContentsChanged();\n }\n _updateMaxDimensions() {\n const height = Math.max(this._editor.getLayoutInfo().height / 4, 250, ContentHoverWidget_1._lastDimensions.height);\n const width = Math.max(this._editor.getLayoutInfo().width * 0.66, 500, ContentHoverWidget_1._lastDimensions.width);\n this._setHoverWidgetMaxDimensions(width, height);\n }\n _render(node, hoverData) {\n this._setHoverData(hoverData);\n this._updateFont();\n this._updateContent(node);\n this._updateMaxDimensions();\n this.onContentsChanged();\n // Simply force a synchronous render on the editor\n // such that the widget does not really render with left = '0px'\n this._editor.render();\n }\n getPosition() {\n var _a;\n if (!this._visibleData) {\n return null;\n }\n return {\n position: this._visibleData.showAtPosition,\n secondaryPosition: this._visibleData.showAtSecondaryPosition,\n positionAffinity: this._visibleData.isBeforeContent ? 3 /* PositionAffinity.LeftOfInjectedText */ : undefined,\n preference: [(_a = this._positionPreference) !== null && _a !== void 0 ? _a : 1 /* ContentWidgetPositionPreference.ABOVE */]\n };\n }\n showAt(node, hoverData) {\n var _a, _b, _c, _d;\n if (!this._editor || !this._editor.hasModel()) {\n return;\n }\n this._render(node, hoverData);\n const widgetHeight = dom.getTotalHeight(this._hover.containerDomNode);\n const widgetPosition = hoverData.showAtPosition;\n this._positionPreference = (_a = this._findPositionPreference(widgetHeight, widgetPosition)) !== null && _a !== void 0 ? _a : 1 /* ContentWidgetPositionPreference.ABOVE */;\n // See https://github.com/microsoft/vscode/issues/140339\n // TODO: Doing a second layout of the hover after force rendering the editor\n this.onContentsChanged();\n if (hoverData.stoleFocus) {\n this._hover.containerDomNode.focus();\n }\n (_b = hoverData.colorPicker) === null || _b === void 0 ? void 0 : _b.layout();\n // The aria label overrides the label, so if we add to it, add the contents of the hover\n const hoverFocused = this._hover.containerDomNode.ownerDocument.activeElement === this._hover.containerDomNode;\n const accessibleViewHint = hoverFocused && getHoverAccessibleViewHint(this._configurationService.getValue('accessibility.verbosity.hover') === true && this._accessibilityService.isScreenReaderOptimized(), (_d = (_c = this._keybindingService.lookupKeybinding('editor.action.accessibleView')) === null || _c === void 0 ? void 0 : _c.getAriaLabel()) !== null && _d !== void 0 ? _d : '');\n if (accessibleViewHint) {\n this._hover.contentsDomNode.ariaLabel = this._hover.contentsDomNode.textContent + ', ' + accessibleViewHint;\n }\n }\n hide() {\n if (!this._visibleData) {\n return;\n }\n const stoleFocus = this._visibleData.stoleFocus || this._hoverFocusedKey.get();\n this._setHoverData(undefined);\n this._resizableNode.maxSize = new dom.Dimension(Infinity, Infinity);\n this._resizableNode.clearSashHoverState();\n this._hoverFocusedKey.set(false);\n this._editor.layoutContentWidget(this);\n if (stoleFocus) {\n this._editor.focus();\n }\n }\n _removeConstraintsRenderNormally() {\n // Added because otherwise the initial size of the hover content is smaller than should be\n const layoutInfo = this._editor.getLayoutInfo();\n this._resizableNode.layout(layoutInfo.height, layoutInfo.width);\n this._setHoverWidgetDimensions('auto', 'auto');\n }\n setMinimumDimensions(dimensions) {\n // We combine the new minimum dimensions with the previous ones\n this._minimumSize = new dom.Dimension(Math.max(this._minimumSize.width, dimensions.width), Math.max(this._minimumSize.height, dimensions.height));\n this._updateMinimumWidth();\n }\n _updateMinimumWidth() {\n const width = (typeof this._contentWidth === 'undefined'\n ? this._minimumSize.width\n : Math.min(this._contentWidth, this._minimumSize.width));\n // We want to avoid that the hover is artificially large, so we use the content width as minimum width\n this._resizableNode.minSize = new dom.Dimension(width, this._minimumSize.height);\n }\n onContentsChanged() {\n var _a;\n this._removeConstraintsRenderNormally();\n const containerDomNode = this._hover.containerDomNode;\n let height = dom.getTotalHeight(containerDomNode);\n let width = dom.getTotalWidth(containerDomNode);\n this._resizableNode.layout(height, width);\n this._setHoverWidgetDimensions(width, height);\n height = dom.getTotalHeight(containerDomNode);\n width = dom.getTotalWidth(containerDomNode);\n this._contentWidth = width;\n this._updateMinimumWidth();\n this._resizableNode.layout(height, width);\n if ((_a = this._visibleData) === null || _a === void 0 ? void 0 : _a.showAtPosition) {\n const widgetHeight = dom.getTotalHeight(this._hover.containerDomNode);\n this._positionPreference = this._findPositionPreference(widgetHeight, this._visibleData.showAtPosition);\n }\n this._layoutContentWidget();\n }\n focus() {\n this._hover.containerDomNode.focus();\n }\n scrollUp() {\n const scrollTop = this._hover.scrollbar.getScrollPosition().scrollTop;\n const fontInfo = this._editor.getOption(50 /* EditorOption.fontInfo */);\n this._hover.scrollbar.setScrollPosition({ scrollTop: scrollTop - fontInfo.lineHeight });\n }\n scrollDown() {\n const scrollTop = this._hover.scrollbar.getScrollPosition().scrollTop;\n const fontInfo = this._editor.getOption(50 /* EditorOption.fontInfo */);\n this._hover.scrollbar.setScrollPosition({ scrollTop: scrollTop + fontInfo.lineHeight });\n }\n scrollLeft() {\n const scrollLeft = this._hover.scrollbar.getScrollPosition().scrollLeft;\n this._hover.scrollbar.setScrollPosition({ scrollLeft: scrollLeft - HORIZONTAL_SCROLLING_BY });\n }\n scrollRight() {\n const scrollLeft = this._hover.scrollbar.getScrollPosition().scrollLeft;\n this._hover.scrollbar.setScrollPosition({ scrollLeft: scrollLeft + HORIZONTAL_SCROLLING_BY });\n }\n pageUp() {\n const scrollTop = this._hover.scrollbar.getScrollPosition().scrollTop;\n const scrollHeight = this._hover.scrollbar.getScrollDimensions().height;\n this._hover.scrollbar.setScrollPosition({ scrollTop: scrollTop - scrollHeight });\n }\n pageDown() {\n const scrollTop = this._hover.scrollbar.getScrollPosition().scrollTop;\n const scrollHeight = this._hover.scrollbar.getScrollDimensions().height;\n this._hover.scrollbar.setScrollPosition({ scrollTop: scrollTop + scrollHeight });\n }\n goToTop() {\n this._hover.scrollbar.setScrollPosition({ scrollTop: 0 });\n }\n goToBottom() {\n this._hover.scrollbar.setScrollPosition({ scrollTop: this._hover.scrollbar.getScrollDimensions().scrollHeight });\n }\n};\nContentHoverWidget.ID = 'editor.contrib.resizableContentHoverWidget';\nContentHoverWidget._lastDimensions = new dom.Dimension(0, 0);\nContentHoverWidget = ContentHoverWidget_1 = __decorate([\n __param(1, IContextKeyService),\n __param(2, IConfigurationService),\n __param(3, IAccessibilityService),\n __param(4, IKeybindingService)\n], ContentHoverWidget);\nexport { ContentHoverWidget };\nfunction computeDistanceFromPointToRectangle(pointX, pointY, left, top, width, height) {\n const x = (left + width / 2); // x center of rectangle\n const y = (top + height / 2); // y center of rectangle\n const dx = Math.max(Math.abs(pointX - x) - width / 2, 0);\n const dy = Math.max(Math.abs(pointY - y) - height / 2, 0);\n return Math.sqrt(dx * dx + dy * dy);\n}\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 *--------------------------------------------------------------------------------------------*/\nimport { createCancelableAsyncIterable, RunOnceScheduler } from '../../../../base/common/async.js';\nimport { onUnexpectedError } from '../../../../base/common/errors.js';\nimport { Emitter } from '../../../../base/common/event.js';\nimport { Disposable } from '../../../../base/common/lifecycle.js';\nexport class HoverResult {\n constructor(value, isComplete, hasLoadingMessage) {\n this.value = value;\n this.isComplete = isComplete;\n this.hasLoadingMessage = hasLoadingMessage;\n }\n}\n/**\n * Computing the hover is very fine tuned.\n *\n * Suppose the hover delay is 300ms (the default). Then, when resting the mouse at an anchor:\n * - at 150ms, the async computation is triggered (i.e. semantic hover)\n * - if async results already come in, they are not rendered yet.\n * - at 300ms, the sync computation is triggered (i.e. decorations, markers)\n * - if there are sync or async results, they are rendered.\n * - at 900ms, if the async computation hasn't finished, a \"Loading...\" result is added.\n */\nexport class HoverOperation extends Disposable {\n constructor(_editor, _computer) {\n super();\n this._editor = _editor;\n this._computer = _computer;\n this._onResult = this._register(new Emitter());\n this.onResult = this._onResult.event;\n this._firstWaitScheduler = this._register(new RunOnceScheduler(() => this._triggerAsyncComputation(), 0));\n this._secondWaitScheduler = this._register(new RunOnceScheduler(() => this._triggerSyncComputation(), 0));\n this._loadingMessageScheduler = this._register(new RunOnceScheduler(() => this._triggerLoadingMessage(), 0));\n this._state = 0 /* HoverOperationState.Idle */;\n this._asyncIterable = null;\n this._asyncIterableDone = false;\n this._result = [];\n }\n dispose() {\n if (this._asyncIterable) {\n this._asyncIterable.cancel();\n this._asyncIterable = null;\n }\n super.dispose();\n }\n get _hoverTime() {\n return this._editor.getOption(60 /* EditorOption.hover */).delay;\n }\n get _firstWaitTime() {\n return this._hoverTime / 2;\n }\n get _secondWaitTime() {\n return this._hoverTime - this._firstWaitTime;\n }\n get _loadingMessageTime() {\n return 3 * this._hoverTime;\n }\n _setState(state, fireResult = true) {\n this._state = state;\n if (fireResult) {\n this._fireResult();\n }\n }\n _triggerAsyncComputation() {\n this._setState(2 /* HoverOperationState.SecondWait */);\n this._secondWaitScheduler.schedule(this._secondWaitTime);\n if (this._computer.computeAsync) {\n this._asyncIterableDone = false;\n this._asyncIterable = createCancelableAsyncIterable(token => this._computer.computeAsync(token));\n (async () => {\n try {\n for await (const item of this._asyncIterable) {\n if (item) {\n this._result.push(item);\n this._fireResult();\n }\n }\n this._asyncIterableDone = true;\n if (this._state === 3 /* HoverOperationState.WaitingForAsync */ || this._state === 4 /* HoverOperationState.WaitingForAsyncShowingLoading */) {\n this._setState(0 /* HoverOperationState.Idle */);\n }\n }\n catch (e) {\n onUnexpectedError(e);\n }\n })();\n }\n else {\n this._asyncIterableDone = true;\n }\n }\n _triggerSyncComputation() {\n if (this._computer.computeSync) {\n this._result = this._result.concat(this._computer.computeSync());\n }\n this._setState(this._asyncIterableDone ? 0 /* HoverOperationState.Idle */ : 3 /* HoverOperationState.WaitingForAsync */);\n }\n _triggerLoadingMessage() {\n if (this._state === 3 /* HoverOperationState.WaitingForAsync */) {\n this._setState(4 /* HoverOperationState.WaitingForAsyncShowingLoading */);\n }\n }\n _fireResult() {\n if (this._state === 1 /* HoverOperationState.FirstWait */ || this._state === 2 /* HoverOperationState.SecondWait */) {\n // Do not send out results before the hover time\n return;\n }\n const isComplete = (this._state === 0 /* HoverOperationState.Idle */);\n const hasLoadingMessage = (this._state === 4 /* HoverOperationState.WaitingForAsyncShowingLoading */);\n this._onResult.fire(new HoverResult(this._result.slice(0), isComplete, hasLoadingMessage));\n }\n start(mode) {\n if (mode === 0 /* HoverStartMode.Delayed */) {\n if (this._state === 0 /* HoverOperationState.Idle */) {\n this._setState(1 /* HoverOperationState.FirstWait */);\n this._firstWaitScheduler.schedule(this._firstWaitTime);\n this._loadingMessageScheduler.schedule(this._loadingMessageTime);\n }\n }\n else {\n switch (this._state) {\n case 0 /* HoverOperationState.Idle */:\n this._triggerAsyncComputation();\n this._secondWaitScheduler.cancel();\n this._triggerSyncComputation();\n break;\n case 2 /* HoverOperationState.SecondWait */:\n this._secondWaitScheduler.cancel();\n this._triggerSyncComputation();\n break;\n }\n }\n }\n cancel() {\n this._firstWaitScheduler.cancel();\n this._secondWaitScheduler.cancel();\n this._loadingMessageScheduler.cancel();\n if (this._asyncIterable) {\n this._asyncIterable.cancel();\n this._asyncIterable = null;\n }\n this._result = [];\n this._setState(0 /* HoverOperationState.Idle */, false);\n }\n}\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 *--------------------------------------------------------------------------------------------*/\nimport { coalesce } from '../../../../base/common/arrays.js';\nimport { AsyncIterableObject } from '../../../../base/common/async.js';\nexport class ContentHoverComputer {\n get anchor() { return this._anchor; }\n set anchor(value) { this._anchor = value; }\n get shouldFocus() { return this._shouldFocus; }\n set shouldFocus(value) { this._shouldFocus = value; }\n get source() { return this._source; }\n set source(value) { this._source = value; }\n get insistOnKeepingHoverVisible() { return this._insistOnKeepingHoverVisible; }\n set insistOnKeepingHoverVisible(value) { this._insistOnKeepingHoverVisible = value; }\n constructor(_editor, _participants) {\n this._editor = _editor;\n this._participants = _participants;\n this._anchor = null;\n this._shouldFocus = false;\n this._source = 0 /* HoverStartSource.Mouse */;\n this._insistOnKeepingHoverVisible = false;\n }\n static _getLineDecorations(editor, anchor) {\n if (anchor.type !== 1 /* HoverAnchorType.Range */ && !anchor.supportsMarkerHover) {\n return [];\n }\n const model = editor.getModel();\n const lineNumber = anchor.range.startLineNumber;\n if (lineNumber > model.getLineCount()) {\n // invalid line\n return [];\n }\n const maxColumn = model.getLineMaxColumn(lineNumber);\n return editor.getLineDecorations(lineNumber).filter((d) => {\n if (d.options.isWholeLine) {\n return true;\n }\n const startColumn = (d.range.startLineNumber === lineNumber) ? d.range.startColumn : 1;\n const endColumn = (d.range.endLineNumber === lineNumber) ? d.range.endColumn : maxColumn;\n if (d.options.showIfCollapsed) {\n // Relax check around `showIfCollapsed` decorations to also include +/- 1 character\n if (startColumn > anchor.range.startColumn + 1 || anchor.range.endColumn - 1 > endColumn) {\n return false;\n }\n }\n else {\n if (startColumn > anchor.range.startColumn || anchor.range.endColumn > endColumn) {\n return false;\n }\n }\n return true;\n });\n }\n computeAsync(token) {\n const anchor = this._anchor;\n if (!this._editor.hasModel() || !anchor) {\n return AsyncIterableObject.EMPTY;\n }\n const lineDecorations = ContentHoverComputer._getLineDecorations(this._editor, anchor);\n return AsyncIterableObject.merge(this._participants.map((participant) => {\n if (!participant.computeAsync) {\n return AsyncIterableObject.EMPTY;\n }\n return participant.computeAsync(anchor, lineDecorations, token);\n }));\n }\n computeSync() {\n if (!this._editor.hasModel() || !this._anchor) {\n return [];\n }\n const lineDecorations = ContentHoverComputer._getLineDecorations(this._editor, this._anchor);\n let result = [];\n for (const participant of this._participants) {\n result = result.concat(participant.computeSync(this._anchor, lineDecorations));\n }\n return coalesce(result);\n }\n}\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 *--------------------------------------------------------------------------------------------*/\nexport class HoverResult {\n constructor(anchor, messages, isComplete) {\n this.anchor = anchor;\n this.messages = messages;\n this.isComplete = isComplete;\n }\n filter(anchor) {\n const filteredMessages = this.messages.filter((m) => m.isValidForHoverAnchor(anchor));\n if (filteredMessages.length === this.messages.length) {\n return this;\n }\n return new FilteredHoverResult(this, this.anchor, filteredMessages, this.isComplete);\n }\n}\nexport class FilteredHoverResult extends HoverResult {\n constructor(original, anchor, messages, isComplete) {\n super(anchor, messages, isComplete);\n this.original = original;\n }\n filter(anchor) {\n return this.original.filter(anchor);\n }\n}\nexport class ContentHoverVisibleData {\n constructor(initialMousePosX, initialMousePosY, colorPicker, showAtPosition, showAtSecondaryPosition, preferAbove, stoleFocus, source, isBeforeContent, disposables) {\n this.initialMousePosX = initialMousePosX;\n this.initialMousePosY = initialMousePosY;\n this.colorPicker = colorPicker;\n this.showAtPosition = showAtPosition;\n this.showAtSecondaryPosition = showAtSecondaryPosition;\n this.preferAbove = preferAbove;\n this.stoleFocus = stoleFocus;\n this.source = source;\n this.isBeforeContent = isBeforeContent;\n this.disposables = disposables;\n this.closestMouseDistance = undefined;\n }\n}\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 *--------------------------------------------------------------------------------------------*/\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __param = (this && this.__param) || function (paramIndex, decorator) {\n return function (target, key) { decorator(target, key, paramIndex); }\n};\nvar ContentHoverController_1;\nimport * as dom from '../../../../base/browser/dom.js';\nimport { Disposable, DisposableStore, toDisposable } from '../../../../base/common/lifecycle.js';\nimport { Position } from '../../../common/core/position.js';\nimport { Range } from '../../../common/core/range.js';\nimport { ModelDecorationOptions } from '../../../common/model/textModel.js';\nimport { TokenizationRegistry } from '../../../common/languages.js';\nimport { HoverOperation } from './hoverOperation.js';\nimport { HoverParticipantRegistry, HoverRangeAnchor } from './hoverTypes.js';\nimport { IInstantiationService } from '../../../../platform/instantiation/common/instantiation.js';\nimport { IKeybindingService } from '../../../../platform/keybinding/common/keybinding.js';\nimport { MarkdownHoverParticipant } from './markdownHoverParticipant.js';\nimport { InlayHintsHover } from '../../inlayHints/browser/inlayHintsHover.js';\nimport { ContentHoverWidget } from './contentHoverWidget.js';\nimport { ContentHoverComputer } from './contentHoverComputer.js';\nimport { ContentHoverVisibleData, HoverResult } from './contentHoverTypes.js';\nimport { EditorHoverStatusBar } from './contentHoverStatusBar.js';\nimport { Emitter } from '../../../../base/common/event.js';\nlet ContentHoverController = ContentHoverController_1 = class ContentHoverController extends Disposable {\n constructor(_editor, _instantiationService, _keybindingService) {\n super();\n this._editor = _editor;\n this._instantiationService = _instantiationService;\n this._keybindingService = _keybindingService;\n this._currentResult = null;\n this._onContentsChanged = this._register(new Emitter());\n this.onContentsChanged = this._onContentsChanged.event;\n this._widget = this._register(this._instantiationService.createInstance(ContentHoverWidget, this._editor));\n // Instantiate participants and sort them by `hoverOrdinal` which is relevant for rendering order.\n this._participants = [];\n for (const participant of HoverParticipantRegistry.getAll()) {\n const participantInstance = this._instantiationService.createInstance(participant, this._editor);\n if (participantInstance instanceof MarkdownHoverParticipant && !(participantInstance instanceof InlayHintsHover)) {\n this._markdownHoverParticipant = participantInstance;\n }\n this._participants.push(participantInstance);\n }\n this._participants.sort((p1, p2) => p1.hoverOrdinal - p2.hoverOrdinal);\n this._computer = new ContentHoverComputer(this._editor, this._participants);\n this._hoverOperation = this._register(new HoverOperation(this._editor, this._computer));\n this._register(this._hoverOperation.onResult((result) => {\n if (!this._computer.anchor) {\n // invalid state, ignore result\n return;\n }\n const messages = (result.hasLoadingMessage ? this._addLoadingMessage(result.value) : result.value);\n this._withResult(new HoverResult(this._computer.anchor, messages, result.isComplete));\n }));\n this._register(dom.addStandardDisposableListener(this._widget.getDomNode(), 'keydown', (e) => {\n if (e.equals(9 /* KeyCode.Escape */)) {\n this.hide();\n }\n }));\n this._register(TokenizationRegistry.onDidChange(() => {\n if (this._widget.position && this._currentResult) {\n this._setCurrentResult(this._currentResult); // render again\n }\n }));\n }\n /**\n * Returns true if the hover shows now or will show.\n */\n _startShowingOrUpdateHover(anchor, mode, source, focus, mouseEvent) {\n if (!this._widget.position || !this._currentResult) {\n // The hover is not visible\n if (anchor) {\n this._startHoverOperationIfNecessary(anchor, mode, source, focus, false);\n return true;\n }\n return false;\n }\n // The hover is currently visible\n const isHoverSticky = this._editor.getOption(60 /* EditorOption.hover */).sticky;\n const isGettingCloser = (isHoverSticky\n && mouseEvent\n && this._widget.isMouseGettingCloser(mouseEvent.event.posx, mouseEvent.event.posy));\n if (isGettingCloser) {\n // The mouse is getting closer to the hover, so we will keep the hover untouched\n // But we will kick off a hover update at the new anchor, insisting on keeping the hover visible.\n if (anchor) {\n this._startHoverOperationIfNecessary(anchor, mode, source, focus, true);\n }\n return true;\n }\n if (!anchor) {\n this._setCurrentResult(null);\n return false;\n }\n if (anchor && this._currentResult.anchor.equals(anchor)) {\n // The widget is currently showing results for the exact same anchor, so no update is needed\n return true;\n }\n if (!anchor.canAdoptVisibleHover(this._currentResult.anchor, this._widget.position)) {\n // The new anchor is not compatible with the previous anchor\n this._setCurrentResult(null);\n this._startHoverOperationIfNecessary(anchor, mode, source, focus, false);\n return true;\n }\n // We aren't getting any closer to the hover, so we will filter existing results\n // and keep those which also apply to the new anchor.\n this._setCurrentResult(this._currentResult.filter(anchor));\n this._startHoverOperationIfNecessary(anchor, mode, source, focus, false);\n return true;\n }\n _startHoverOperationIfNecessary(anchor, mode, source, focus, insistOnKeepingHoverVisible) {\n if (this._computer.anchor && this._computer.anchor.equals(anchor)) {\n // We have to start a hover operation at the exact same anchor as before, so no work is needed\n return;\n }\n this._hoverOperation.cancel();\n this._computer.anchor = anchor;\n this._computer.shouldFocus = focus;\n this._computer.source = source;\n this._computer.insistOnKeepingHoverVisible = insistOnKeepingHoverVisible;\n this._hoverOperation.start(mode);\n }\n _setCurrentResult(hoverResult) {\n if (this._currentResult === hoverResult) {\n // avoid updating the DOM to avoid resetting the user selection\n return;\n }\n if (hoverResult && hoverResult.messages.length === 0) {\n hoverResult = null;\n }\n this._currentResult = hoverResult;\n if (this._currentResult) {\n this._renderMessages(this._currentResult.anchor, this._currentResult.messages);\n }\n else {\n this._widget.hide();\n }\n }\n _addLoadingMessage(result) {\n if (this._computer.anchor) {\n for (const participant of this._participants) {\n if (participant.createLoadingMessage) {\n const loadingMessage = participant.createLoadingMessage(this._computer.anchor);\n if (loadingMessage) {\n return result.slice(0).concat([loadingMessage]);\n }\n }\n }\n }\n return result;\n }\n _withResult(hoverResult) {\n if (this._widget.position && this._currentResult && this._currentResult.isComplete) {\n // The hover is visible with a previous complete result.\n if (!hoverResult.isComplete) {\n // Instead of rendering the new partial result, we wait for the result to be complete.\n return;\n }\n if (this._computer.insistOnKeepingHoverVisible && hoverResult.messages.length === 0) {\n // The hover would now hide normally, so we'll keep the previous messages\n return;\n }\n }\n this._setCurrentResult(hoverResult);\n }\n _renderMessages(anchor, messages) {\n const { showAtPosition, showAtSecondaryPosition, highlightRange } = ContentHoverController_1.computeHoverRanges(this._editor, anchor.range, messages);\n const disposables = new DisposableStore();\n const statusBar = disposables.add(new EditorHoverStatusBar(this._keybindingService));\n const fragment = document.createDocumentFragment();\n let colorPicker = null;\n const context = {\n fragment,\n statusBar,\n setColorPicker: (widget) => colorPicker = widget,\n onContentsChanged: () => this._doOnContentsChanged(),\n setMinimumDimensions: (dimensions) => this._widget.setMinimumDimensions(dimensions),\n hide: () => this.hide()\n };\n for (const participant of this._participants) {\n const hoverParts = messages.filter(msg => msg.owner === participant);\n if (hoverParts.length > 0) {\n disposables.add(participant.renderHoverParts(context, hoverParts));\n }\n }\n const isBeforeContent = messages.some(m => m.isBeforeContent);\n if (statusBar.hasContent) {\n fragment.appendChild(statusBar.hoverElement);\n }\n if (fragment.hasChildNodes()) {\n if (highlightRange) {\n const highlightDecoration = this._editor.createDecorationsCollection();\n highlightDecoration.set([{\n range: highlightRange,\n options: ContentHoverController_1._DECORATION_OPTIONS\n }]);\n disposables.add(toDisposable(() => {\n highlightDecoration.clear();\n }));\n }\n this._widget.showAt(fragment, new ContentHoverVisibleData(anchor.initialMousePosX, anchor.initialMousePosY, colorPicker, showAtPosition, showAtSecondaryPosition, this._editor.getOption(60 /* EditorOption.hover */).above, this._computer.shouldFocus, this._computer.source, isBeforeContent, disposables));\n }\n else {\n disposables.dispose();\n }\n }\n _doOnContentsChanged() {\n this._onContentsChanged.fire();\n this._widget.onContentsChanged();\n }\n static computeHoverRanges(editor, anchorRange, messages) {\n let startColumnBoundary = 1;\n if (editor.hasModel()) {\n // Ensure the range is on the current view line\n const viewModel = editor._getViewModel();\n const coordinatesConverter = viewModel.coordinatesConverter;\n const anchorViewRange = coordinatesConverter.convertModelRangeToViewRange(anchorRange);\n const anchorViewRangeStart = new Position(anchorViewRange.startLineNumber, viewModel.getLineMinColumn(anchorViewRange.startLineNumber));\n startColumnBoundary = coordinatesConverter.convertViewPositionToModelPosition(anchorViewRangeStart).column;\n }\n // The anchor range is always on a single line\n const anchorLineNumber = anchorRange.startLineNumber;\n let renderStartColumn = anchorRange.startColumn;\n let highlightRange = messages[0].range;\n let forceShowAtRange = null;\n for (const msg of messages) {\n highlightRange = Range.plusRange(highlightRange, msg.range);\n if (msg.range.startLineNumber === anchorLineNumber && msg.range.endLineNumber === anchorLineNumber) {\n // this message has a range that is completely sitting on the line of the anchor\n renderStartColumn = Math.max(Math.min(renderStartColumn, msg.range.startColumn), startColumnBoundary);\n }\n if (msg.forceShowAtRange) {\n forceShowAtRange = msg.range;\n }\n }\n const showAtPosition = forceShowAtRange ? forceShowAtRange.getStartPosition() : new Position(anchorLineNumber, anchorRange.startColumn);\n const showAtSecondaryPosition = forceShowAtRange ? forceShowAtRange.getStartPosition() : new Position(anchorLineNumber, renderStartColumn);\n return {\n showAtPosition,\n showAtSecondaryPosition,\n highlightRange\n };\n }\n showsOrWillShow(mouseEvent) {\n if (this._widget.isResizing) {\n return true;\n }\n const anchorCandidates = [];\n for (const participant of this._participants) {\n if (participant.suggestHoverAnchor) {\n const anchor = participant.suggestHoverAnchor(mouseEvent);\n if (anchor) {\n anchorCandidates.push(anchor);\n }\n }\n }\n const target = mouseEvent.target;\n if (target.type === 6 /* MouseTargetType.CONTENT_TEXT */) {\n anchorCandidates.push(new HoverRangeAnchor(0, target.range, mouseEvent.event.posx, mouseEvent.event.posy));\n }\n if (target.type === 7 /* MouseTargetType.CONTENT_EMPTY */) {\n const epsilon = this._editor.getOption(50 /* EditorOption.fontInfo */).typicalHalfwidthCharacterWidth / 2;\n if (!target.detail.isAfterLines\n && typeof target.detail.horizontalDistanceToText === 'number'\n && target.detail.horizontalDistanceToText < epsilon) {\n // Let hover kick in even when the mouse is technically in the empty area after a line, given the distance is small enough\n anchorCandidates.push(new HoverRangeAnchor(0, target.range, mouseEvent.event.posx, mouseEvent.event.posy));\n }\n }\n if (anchorCandidates.length === 0) {\n return this._startShowingOrUpdateHover(null, 0 /* HoverStartMode.Delayed */, 0 /* HoverStartSource.Mouse */, false, mouseEvent);\n }\n anchorCandidates.sort((a, b) => b.priority - a.priority);\n return this._startShowingOrUpdateHover(anchorCandidates[0], 0 /* HoverStartMode.Delayed */, 0 /* HoverStartSource.Mouse */, false, mouseEvent);\n }\n startShowingAtRange(range, mode, source, focus) {\n this._startShowingOrUpdateHover(new HoverRangeAnchor(0, range, undefined, undefined), mode, source, focus, null);\n }\n async updateMarkdownHoverVerbosityLevel(action, index, focus) {\n var _a;\n (_a = this._markdownHoverParticipant) === null || _a === void 0 ? void 0 : _a.updateMarkdownHoverVerbosityLevel(action, index, focus);\n }\n markdownHoverContentAtIndex(index) {\n var _a, _b;\n return (_b = (_a = this._markdownHoverParticipant) === null || _a === void 0 ? void 0 : _a.markdownHoverContentAtIndex(index)) !== null && _b !== void 0 ? _b : '';\n }\n doesMarkdownHoverAtIndexSupportVerbosityAction(index, action) {\n var _a, _b;\n return (_b = (_a = this._markdownHoverParticipant) === null || _a === void 0 ? void 0 : _a.doesMarkdownHoverAtIndexSupportVerbosityAction(index, action)) !== null && _b !== void 0 ? _b : false;\n }\n containsNode(node) {\n return (node ? this._widget.getDomNode().contains(node) : false);\n }\n focus() {\n this._widget.focus();\n }\n scrollUp() {\n this._widget.scrollUp();\n }\n scrollDown() {\n this._widget.scrollDown();\n }\n scrollLeft() {\n this._widget.scrollLeft();\n }\n scrollRight() {\n this._widget.scrollRight();\n }\n pageUp() {\n this._widget.pageUp();\n }\n pageDown() {\n this._widget.pageDown();\n }\n goToTop() {\n this._widget.goToTop();\n }\n goToBottom() {\n this._widget.goToBottom();\n }\n hide() {\n this._computer.anchor = null;\n this._hoverOperation.cancel();\n this._setCurrentResult(null);\n }\n get isColorPickerVisible() {\n return this._widget.isColorPickerVisible;\n }\n get isVisibleFromKeyboard() {\n return this._widget.isVisibleFromKeyboard;\n }\n get isVisible() {\n return this._widget.isVisible;\n }\n get isFocused() {\n return this._widget.isFocused;\n }\n get isResizing() {\n return this._widget.isResizing;\n }\n get widget() {\n return this._widget;\n }\n};\nContentHoverController._DECORATION_OPTIONS = ModelDecorationOptions.register({\n description: 'content-hover-highlight',\n className: 'hoverHighlight'\n});\nContentHoverController = ContentHoverController_1 = __decorate([\n __param(1, IInstantiationService),\n __param(2, IKeybindingService)\n], ContentHoverController);\nexport { ContentHoverController };\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 *--------------------------------------------------------------------------------------------*/\nimport { asArray } from '../../../../base/common/arrays.js';\nimport { isEmptyMarkdownString } from '../../../../base/common/htmlContent.js';\nimport { GlyphMarginLane } from '../../../common/model.js';\nexport class MarginHoverComputer {\n get lineNumber() {\n return this._lineNumber;\n }\n set lineNumber(value) {\n this._lineNumber = value;\n }\n get lane() {\n return this._laneOrLine;\n }\n set lane(value) {\n this._laneOrLine = value;\n }\n constructor(_editor) {\n this._editor = _editor;\n this._lineNumber = -1;\n this._laneOrLine = GlyphMarginLane.Center;\n }\n computeSync() {\n var _a, _b;\n const toHoverMessage = (contents) => {\n return {\n value: contents\n };\n };\n const lineDecorations = this._editor.getLineDecorations(this._lineNumber);\n const result = [];\n const isLineHover = this._laneOrLine === 'lineNo';\n if (!lineDecorations) {\n return result;\n }\n for (const d of lineDecorations) {\n const lane = (_b = (_a = d.options.glyphMargin) === null || _a === void 0 ? void 0 : _a.position) !== null && _b !== void 0 ? _b : GlyphMarginLane.Center;\n if (!isLineHover && lane !== this._laneOrLine) {\n continue;\n }\n const hoverMessage = isLineHover ? d.options.lineNumberHoverMessage : d.options.glyphMarginHoverMessage;\n if (!hoverMessage || isEmptyMarkdownString(hoverMessage)) {\n continue;\n }\n result.push(...asArray(hoverMessage).map(toHoverMessage));\n }\n return result;\n }\n}\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 *--------------------------------------------------------------------------------------------*/\nimport * as dom from '../../../../base/browser/dom.js';\nimport { Disposable, DisposableStore } from '../../../../base/common/lifecycle.js';\nimport { MarkdownRenderer } from '../../../browser/widget/markdownRenderer/browser/markdownRenderer.js';\nimport { HoverOperation } from './hoverOperation.js';\nimport { HoverWidget } from '../../../../base/browser/ui/hover/hoverWidget.js';\nimport { MarginHoverComputer } from './marginHoverComputer.js';\nconst $ = dom.$;\nexport class MarginHoverWidget extends Disposable {\n constructor(editor, languageService, openerService) {\n super();\n this._renderDisposeables = this._register(new DisposableStore());\n this._editor = editor;\n this._isVisible = false;\n this._messages = [];\n this._hover = this._register(new HoverWidget());\n this._hover.containerDomNode.classList.toggle('hidden', !this._isVisible);\n this._markdownRenderer = this._register(new MarkdownRenderer({ editor: this._editor }, languageService, openerService));\n this._computer = new MarginHoverComputer(this._editor);\n this._hoverOperation = this._register(new HoverOperation(this._editor, this._computer));\n this._register(this._hoverOperation.onResult((result) => {\n this._withResult(result.value);\n }));\n this._register(this._editor.onDidChangeModelDecorations(() => this._onModelDecorationsChanged()));\n this._register(this._editor.onDidChangeConfiguration((e) => {\n if (e.hasChanged(50 /* EditorOption.fontInfo */)) {\n this._updateFont();\n }\n }));\n this._editor.addOverlayWidget(this);\n }\n dispose() {\n this._editor.removeOverlayWidget(this);\n super.dispose();\n }\n getId() {\n return MarginHoverWidget.ID;\n }\n getDomNode() {\n return this._hover.containerDomNode;\n }\n getPosition() {\n return null;\n }\n _updateFont() {\n const codeClasses = Array.prototype.slice.call(this._hover.contentsDomNode.getElementsByClassName('code'));\n codeClasses.forEach(node => this._editor.applyFontInfo(node));\n }\n _onModelDecorationsChanged() {\n if (this._isVisible) {\n // The decorations have changed and the hover is visible,\n // we need to recompute the displayed text\n this._hoverOperation.cancel();\n this._hoverOperation.start(0 /* HoverStartMode.Delayed */);\n }\n }\n showsOrWillShow(mouseEvent) {\n const target = mouseEvent.target;\n if (target.type === 2 /* MouseTargetType.GUTTER_GLYPH_MARGIN */ && target.detail.glyphMarginLane) {\n this._startShowingAt(target.position.lineNumber, target.detail.glyphMarginLane);\n return true;\n }\n if (target.type === 3 /* MouseTargetType.GUTTER_LINE_NUMBERS */) {\n this._startShowingAt(target.position.lineNumber, 'lineNo');\n return true;\n }\n return false;\n }\n _startShowingAt(lineNumber, laneOrLine) {\n if (this._computer.lineNumber === lineNumber && this._computer.lane === laneOrLine) {\n // We have to show the widget at the exact same line number as before, so no work is needed\n return;\n }\n this._hoverOperation.cancel();\n this.hide();\n this._computer.lineNumber = lineNumber;\n this._computer.lane = laneOrLine;\n this._hoverOperation.start(0 /* HoverStartMode.Delayed */);\n }\n hide() {\n this._computer.lineNumber = -1;\n this._hoverOperation.cancel();\n if (!this._isVisible) {\n return;\n }\n this._isVisible = false;\n this._hover.containerDomNode.classList.toggle('hidden', !this._isVisible);\n }\n _withResult(result) {\n this._messages = result;\n if (this._messages.length > 0) {\n this._renderMessages(this._computer.lineNumber, this._messages);\n }\n else {\n this.hide();\n }\n }\n _renderMessages(lineNumber, messages) {\n this._renderDisposeables.clear();\n const fragment = document.createDocumentFragment();\n for (const msg of messages) {\n const markdownHoverElement = $('div.hover-row.markdown-hover');\n const hoverContentsElement = dom.append(markdownHoverElement, $('div.hover-contents'));\n const renderedContents = this._renderDisposeables.add(this._markdownRenderer.render(msg.value));\n hoverContentsElement.appendChild(renderedContents.element);\n fragment.appendChild(markdownHoverElement);\n }\n this._updateContents(fragment);\n this._showAt(lineNumber);\n }\n _updateContents(node) {\n this._hover.contentsDomNode.textContent = '';\n this._hover.contentsDomNode.appendChild(node);\n this._updateFont();\n }\n _showAt(lineNumber) {\n if (!this._isVisible) {\n this._isVisible = true;\n this._hover.containerDomNode.classList.toggle('hidden', !this._isVisible);\n }\n const editorLayout = this._editor.getLayoutInfo();\n const topForLineNumber = this._editor.getTopForLineNumber(lineNumber);\n const editorScrollTop = this._editor.getScrollTop();\n const lineHeight = this._editor.getOption(67 /* EditorOption.lineHeight */);\n const nodeHeight = this._hover.containerDomNode.clientHeight;\n const top = topForLineNumber - editorScrollTop - ((nodeHeight - lineHeight) / 2);\n const left = editorLayout.glyphMarginLeft + editorLayout.glyphMarginWidth + (this._computer.lane === 'lineNo' ? editorLayout.lineNumbersWidth : 0);\n this._hover.containerDomNode.style.left = `${left}px`;\n this._hover.containerDomNode.style.top = `${Math.max(Math.round(top), 0)}px`;\n }\n}\nMarginHoverWidget.ID = 'editor.contrib.modesGlyphHoverWidget';\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 *--------------------------------------------------------------------------------------------*/\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __param = (this && this.__param) || function (paramIndex, decorator) {\n return function (target, key) { decorator(target, key, paramIndex); }\n};\nvar HoverController_1;\nimport { DECREASE_HOVER_VERBOSITY_ACTION_ID, INCREASE_HOVER_VERBOSITY_ACTION_ID, SHOW_OR_FOCUS_HOVER_ACTION_ID } from './hoverActionIds.js';\nimport { Disposable, DisposableStore } from '../../../../base/common/lifecycle.js';\nimport { IInstantiationService } from '../../../../platform/instantiation/common/instantiation.js';\nimport { InlineSuggestionHintsContentWidget } from '../../inlineCompletions/browser/inlineCompletionsHintsWidget.js';\nimport { IKeybindingService } from '../../../../platform/keybinding/common/keybinding.js';\nimport { RunOnceScheduler } from '../../../../base/common/async.js';\nimport { ContentHoverWidget } from './contentHoverWidget.js';\nimport { ContentHoverController } from './contentHoverController.js';\nimport './hover.css';\nimport { MarginHoverWidget } from './marginHoverWidget.js';\nimport { Emitter } from '../../../../base/common/event.js';\n// sticky hover widget which doesn't disappear on focus out and such\nconst _sticky = false;\nlet HoverController = HoverController_1 = class HoverController extends Disposable {\n constructor(_editor, _instantiationService, _keybindingService) {\n super();\n this._editor = _editor;\n this._instantiationService = _instantiationService;\n this._keybindingService = _keybindingService;\n this._onHoverContentsChanged = this._register(new Emitter());\n this.shouldKeepOpenOnEditorMouseMoveOrLeave = false;\n this._listenersStore = new DisposableStore();\n this._hoverState = {\n mouseDown: false,\n activatedByDecoratorClick: false\n };\n this._reactToEditorMouseMoveRunner = this._register(new RunOnceScheduler(() => this._reactToEditorMouseMove(this._mouseMoveEvent), 0));\n this._hookListeners();\n this._register(this._editor.onDidChangeConfiguration((e) => {\n if (e.hasChanged(60 /* EditorOption.hover */)) {\n this._unhookListeners();\n this._hookListeners();\n }\n }));\n }\n static get(editor) {\n return editor.getContribution(HoverController_1.ID);\n }\n _hookListeners() {\n const hoverOpts = this._editor.getOption(60 /* EditorOption.hover */);\n this._hoverSettings = {\n enabled: hoverOpts.enabled,\n sticky: hoverOpts.sticky,\n hidingDelay: hoverOpts.delay\n };\n if (hoverOpts.enabled) {\n this._listenersStore.add(this._editor.onMouseDown((e) => this._onEditorMouseDown(e)));\n this._listenersStore.add(this._editor.onMouseUp(() => this._onEditorMouseUp()));\n this._listenersStore.add(this._editor.onMouseMove((e) => this._onEditorMouseMove(e)));\n this._listenersStore.add(this._editor.onKeyDown((e) => this._onKeyDown(e)));\n }\n else {\n this._listenersStore.add(this._editor.onMouseMove((e) => this._onEditorMouseMove(e)));\n this._listenersStore.add(this._editor.onKeyDown((e) => this._onKeyDown(e)));\n }\n this._listenersStore.add(this._editor.onMouseLeave((e) => this._onEditorMouseLeave(e)));\n this._listenersStore.add(this._editor.onDidChangeModel(() => {\n this._cancelScheduler();\n this._hideWidgets();\n }));\n this._listenersStore.add(this._editor.onDidChangeModelContent(() => this._cancelScheduler()));\n this._listenersStore.add(this._editor.onDidScrollChange((e) => this._onEditorScrollChanged(e)));\n }\n _unhookListeners() {\n this._listenersStore.clear();\n }\n _cancelScheduler() {\n this._mouseMoveEvent = undefined;\n this._reactToEditorMouseMoveRunner.cancel();\n }\n _onEditorScrollChanged(e) {\n if (e.scrollTopChanged || e.scrollLeftChanged) {\n this._hideWidgets();\n }\n }\n _onEditorMouseDown(mouseEvent) {\n this._hoverState.mouseDown = true;\n const shouldNotHideCurrentHoverWidget = this._shouldNotHideCurrentHoverWidget(mouseEvent);\n if (shouldNotHideCurrentHoverWidget) {\n return;\n }\n this._hideWidgets();\n }\n _shouldNotHideCurrentHoverWidget(mouseEvent) {\n if (this._isMouseOnContentHoverWidget(mouseEvent)\n || this._isMouseOnMarginHoverWidget(mouseEvent)\n || this._isContentWidgetResizing()) {\n return true;\n }\n return false;\n }\n _isMouseOnMarginHoverWidget(mouseEvent) {\n const target = mouseEvent.target;\n if (!target) {\n return false;\n }\n return target.type === 12 /* MouseTargetType.OVERLAY_WIDGET */ && target.detail === MarginHoverWidget.ID;\n }\n _isMouseOnContentHoverWidget(mouseEvent) {\n const target = mouseEvent.target;\n if (!target) {\n return false;\n }\n return target.type === 9 /* MouseTargetType.CONTENT_WIDGET */ && target.detail === ContentHoverWidget.ID;\n }\n _onEditorMouseUp() {\n this._hoverState.mouseDown = false;\n }\n _onEditorMouseLeave(mouseEvent) {\n if (this.shouldKeepOpenOnEditorMouseMoveOrLeave) {\n return;\n }\n this._cancelScheduler();\n const shouldNotHideCurrentHoverWidget = this._shouldNotHideCurrentHoverWidget(mouseEvent);\n if (shouldNotHideCurrentHoverWidget) {\n return;\n }\n if (_sticky) {\n return;\n }\n this._hideWidgets();\n }\n _shouldNotRecomputeCurrentHoverWidget(mouseEvent) {\n const isHoverSticky = this._hoverSettings.sticky;\n const isMouseOnStickyMarginHoverWidget = (mouseEvent, isHoverSticky) => {\n const isMouseOnMarginHoverWidget = this._isMouseOnMarginHoverWidget(mouseEvent);\n return isHoverSticky && isMouseOnMarginHoverWidget;\n };\n const isMouseOnStickyContentHoverWidget = (mouseEvent, isHoverSticky) => {\n const isMouseOnContentHoverWidget = this._isMouseOnContentHoverWidget(mouseEvent);\n return isHoverSticky && isMouseOnContentHoverWidget;\n };\n const isMouseOnColorPicker = (mouseEvent) => {\n var _a;\n const isMouseOnContentHoverWidget = this._isMouseOnContentHoverWidget(mouseEvent);\n const isColorPickerVisible = (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.isColorPickerVisible;\n return isMouseOnContentHoverWidget && isColorPickerVisible;\n };\n // TODO@aiday-mar verify if the following is necessary code\n const isTextSelectedWithinContentHoverWidget = (mouseEvent, sticky) => {\n var _a, _b, _c, _d;\n return sticky\n && ((_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.containsNode((_b = mouseEvent.event.browserEvent.view) === null || _b === void 0 ? void 0 : _b.document.activeElement))\n && !((_d = (_c = mouseEvent.event.browserEvent.view) === null || _c === void 0 ? void 0 : _c.getSelection()) === null || _d === void 0 ? void 0 : _d.isCollapsed);\n };\n if (isMouseOnStickyMarginHoverWidget(mouseEvent, isHoverSticky)\n || isMouseOnStickyContentHoverWidget(mouseEvent, isHoverSticky)\n || isMouseOnColorPicker(mouseEvent)\n || isTextSelectedWithinContentHoverWidget(mouseEvent, isHoverSticky)) {\n return true;\n }\n return false;\n }\n _onEditorMouseMove(mouseEvent) {\n var _a, _b, _c, _d;\n if (this.shouldKeepOpenOnEditorMouseMoveOrLeave) {\n return;\n }\n this._mouseMoveEvent = mouseEvent;\n if (((_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.isFocused) || ((_b = this._contentWidget) === null || _b === void 0 ? void 0 : _b.isResizing)) {\n return;\n }\n const sticky = this._hoverSettings.sticky;\n if (sticky && ((_c = this._contentWidget) === null || _c === void 0 ? void 0 : _c.isVisibleFromKeyboard)) {\n // Sticky mode is on and the hover has been shown via keyboard\n // so moving the mouse has no effect\n return;\n }\n const shouldNotRecomputeCurrentHoverWidget = this._shouldNotRecomputeCurrentHoverWidget(mouseEvent);\n if (shouldNotRecomputeCurrentHoverWidget) {\n this._reactToEditorMouseMoveRunner.cancel();\n return;\n }\n const hidingDelay = this._hoverSettings.hidingDelay;\n const isContentHoverWidgetVisible = (_d = this._contentWidget) === null || _d === void 0 ? void 0 : _d.isVisible;\n // If the mouse is not over the widget, and if sticky is on,\n // then give it a grace period before reacting to the mouse event\n const shouldRescheduleHoverComputation = isContentHoverWidgetVisible && sticky && hidingDelay > 0;\n if (shouldRescheduleHoverComputation) {\n if (!this._reactToEditorMouseMoveRunner.isScheduled()) {\n this._reactToEditorMouseMoveRunner.schedule(hidingDelay);\n }\n return;\n }\n this._reactToEditorMouseMove(mouseEvent);\n }\n _reactToEditorMouseMove(mouseEvent) {\n var _a;\n if (!mouseEvent) {\n return;\n }\n const target = mouseEvent.target;\n const mouseOnDecorator = (_a = target.element) === null || _a === void 0 ? void 0 : _a.classList.contains('colorpicker-color-decoration');\n const decoratorActivatedOn = this._editor.getOption(148 /* EditorOption.colorDecoratorsActivatedOn */);\n const enabled = this._hoverSettings.enabled;\n const activatedByDecoratorClick = this._hoverState.activatedByDecoratorClick;\n if ((mouseOnDecorator && ((decoratorActivatedOn === 'click' && !activatedByDecoratorClick) ||\n (decoratorActivatedOn === 'hover' && !enabled && !_sticky) ||\n (decoratorActivatedOn === 'clickAndHover' && !enabled && !activatedByDecoratorClick))) || (!mouseOnDecorator && !enabled && !activatedByDecoratorClick)) {\n this._hideWidgets();\n return;\n }\n const contentHoverShowsOrWillShow = this._tryShowHoverWidget(mouseEvent, 0 /* HoverWidgetType.Content */);\n if (contentHoverShowsOrWillShow) {\n return;\n }\n const glyphWidgetShowsOrWillShow = this._tryShowHoverWidget(mouseEvent, 1 /* HoverWidgetType.Glyph */);\n if (glyphWidgetShowsOrWillShow) {\n return;\n }\n if (_sticky) {\n return;\n }\n this._hideWidgets();\n }\n _tryShowHoverWidget(mouseEvent, hoverWidgetType) {\n const contentWidget = this._getOrCreateContentWidget();\n const glyphWidget = this._getOrCreateGlyphWidget();\n let currentWidget;\n let otherWidget;\n switch (hoverWidgetType) {\n case 0 /* HoverWidgetType.Content */:\n currentWidget = contentWidget;\n otherWidget = glyphWidget;\n break;\n case 1 /* HoverWidgetType.Glyph */:\n currentWidget = glyphWidget;\n otherWidget = contentWidget;\n break;\n default:\n throw new Error(`HoverWidgetType ${hoverWidgetType} is unrecognized`);\n }\n const showsOrWillShow = currentWidget.showsOrWillShow(mouseEvent);\n if (showsOrWillShow) {\n otherWidget.hide();\n }\n return showsOrWillShow;\n }\n _onKeyDown(e) {\n var _a;\n if (!this._editor.hasModel()) {\n return;\n }\n const resolvedKeyboardEvent = this._keybindingService.softDispatch(e, this._editor.getDomNode());\n // If the beginning of a multi-chord keybinding is pressed,\n // or the command aims to focus the hover,\n // set the variable to true, otherwise false\n const shouldKeepHoverVisible = (resolvedKeyboardEvent.kind === 1 /* ResultKind.MoreChordsNeeded */ ||\n (resolvedKeyboardEvent.kind === 2 /* ResultKind.KbFound */\n && (resolvedKeyboardEvent.commandId === SHOW_OR_FOCUS_HOVER_ACTION_ID\n || resolvedKeyboardEvent.commandId === INCREASE_HOVER_VERBOSITY_ACTION_ID\n || resolvedKeyboardEvent.commandId === DECREASE_HOVER_VERBOSITY_ACTION_ID)\n && ((_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.isVisible)));\n if (e.keyCode === 5 /* KeyCode.Ctrl */\n || e.keyCode === 6 /* KeyCode.Alt */\n || e.keyCode === 57 /* KeyCode.Meta */\n || e.keyCode === 4 /* KeyCode.Shift */\n || shouldKeepHoverVisible) {\n // Do not hide hover when a modifier key is pressed\n return;\n }\n this._hideWidgets();\n }\n _hideWidgets() {\n var _a, _b, _c;\n if (_sticky) {\n return;\n }\n if ((this._hoverState.mouseDown\n && ((_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.isColorPickerVisible)) || InlineSuggestionHintsContentWidget.dropDownVisible) {\n return;\n }\n this._hoverState.activatedByDecoratorClick = false;\n (_b = this._glyphWidget) === null || _b === void 0 ? void 0 : _b.hide();\n (_c = this._contentWidget) === null || _c === void 0 ? void 0 : _c.hide();\n }\n _getOrCreateContentWidget() {\n if (!this._contentWidget) {\n this._contentWidget = this._instantiationService.createInstance(ContentHoverController, this._editor);\n this._listenersStore.add(this._contentWidget.onContentsChanged(() => this._onHoverContentsChanged.fire()));\n }\n return this._contentWidget;\n }\n _getOrCreateGlyphWidget() {\n if (!this._glyphWidget) {\n this._glyphWidget = this._instantiationService.createInstance(MarginHoverWidget, this._editor);\n }\n return this._glyphWidget;\n }\n showContentHover(range, mode, source, focus, activatedByColorDecoratorClick = false) {\n this._hoverState.activatedByDecoratorClick = activatedByColorDecoratorClick;\n this._getOrCreateContentWidget().startShowingAtRange(range, mode, source, focus);\n }\n _isContentWidgetResizing() {\n var _a;\n return ((_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.widget.isResizing) || false;\n }\n markdownHoverContentAtIndex(index) {\n return this._getOrCreateContentWidget().markdownHoverContentAtIndex(index);\n }\n doesMarkdownHoverAtIndexSupportVerbosityAction(index, action) {\n return this._getOrCreateContentWidget().doesMarkdownHoverAtIndexSupportVerbosityAction(index, action);\n }\n updateMarkdownHoverVerbosityLevel(action, index, focus) {\n this._getOrCreateContentWidget().updateMarkdownHoverVerbosityLevel(action, index, focus);\n }\n focus() {\n var _a;\n (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.focus();\n }\n scrollUp() {\n var _a;\n (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.scrollUp();\n }\n scrollDown() {\n var _a;\n (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.scrollDown();\n }\n scrollLeft() {\n var _a;\n (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.scrollLeft();\n }\n scrollRight() {\n var _a;\n (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.scrollRight();\n }\n pageUp() {\n var _a;\n (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.pageUp();\n }\n pageDown() {\n var _a;\n (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.pageDown();\n }\n goToTop() {\n var _a;\n (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.goToTop();\n }\n goToBottom() {\n var _a;\n (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.goToBottom();\n }\n get isColorPickerVisible() {\n var _a;\n return (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.isColorPickerVisible;\n }\n get isHoverVisible() {\n var _a;\n return (_a = this._contentWidget) === null || _a === void 0 ? void 0 : _a.isVisible;\n }\n dispose() {\n var _a, _b;\n super.dispose();\n this._unhookListeners();\n this._listenersStore.dispose();\n (_a = this._glyphWidget) === null || _a === void 0 ? void 0 : _a.dispose();\n (_b = this._contentWidget) === null || _b === void 0 ? void 0 : _b.dispose();\n }\n};\nHoverController.ID = 'editor.contrib.hover';\nHoverController = HoverController_1 = __decorate([\n __param(1, IInstantiationService),\n __param(2, IKeybindingService)\n], HoverController);\nexport { HoverController };\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 *--------------------------------------------------------------------------------------------*/\nexport class HoverRangeAnchor {\n constructor(priority, range, initialMousePosX, initialMousePosY) {\n this.priority = priority;\n this.range = range;\n this.initialMousePosX = initialMousePosX;\n this.initialMousePosY = initialMousePosY;\n this.type = 1 /* HoverAnchorType.Range */;\n }\n equals(other) {\n return (other.type === 1 /* HoverAnchorType.Range */ && this.range.equalsRange(other.range));\n }\n canAdoptVisibleHover(lastAnchor, showAtPosition) {\n return (lastAnchor.type === 1 /* HoverAnchorType.Range */ && showAtPosition.lineNumber === this.range.startLineNumber);\n }\n}\nexport class HoverForeignElementAnchor {\n constructor(priority, owner, range, initialMousePosX, initialMousePosY, supportsMarkerHover) {\n this.priority = priority;\n this.owner = owner;\n this.range = range;\n this.initialMousePosX = initialMousePosX;\n this.initialMousePosY = initialMousePosY;\n this.supportsMarkerHover = supportsMarkerHover;\n this.type = 2 /* HoverAnchorType.ForeignElement */;\n }\n equals(other) {\n return (other.type === 2 /* HoverAnchorType.ForeignElement */ && this.owner === other.owner);\n }\n canAdoptVisibleHover(lastAnchor, showAtPosition) {\n return (lastAnchor.type === 2 /* HoverAnchorType.ForeignElement */ && this.owner === lastAnchor.owner);\n }\n}\nexport const HoverParticipantRegistry = (new class HoverParticipantRegistry {\n constructor() {\n this._participants = [];\n }\n register(ctor) {\n this._participants.push(ctor);\n }\n getAll() {\n return this._participants;\n }\n}());\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 *--------------------------------------------------------------------------------------------*/\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __param = (this && this.__param) || function (paramIndex, decorator) {\n return function (target, key) { decorator(target, key, paramIndex); }\n};\nimport * as dom from '../../../../base/browser/dom.js';\nimport { asArray, compareBy, numberComparator } from '../../../../base/common/arrays.js';\nimport { CancellationTokenSource } from '../../../../base/common/cancellation.js';\nimport { isEmptyMarkdownString, MarkdownString } from '../../../../base/common/htmlContent.js';\nimport { Disposable, DisposableStore, toDisposable } from '../../../../base/common/lifecycle.js';\nimport { MarkdownRenderer } from '../../../browser/widget/markdownRenderer/browser/markdownRenderer.js';\nimport { DECREASE_HOVER_VERBOSITY_ACTION_ID, INCREASE_HOVER_VERBOSITY_ACTION_ID } from './hoverActionIds.js';\nimport { Range } from '../../../common/core/range.js';\nimport { ILanguageService } from '../../../common/languages/language.js';\nimport * as nls from '../../../../nls.js';\nimport { IConfigurationService } from '../../../../platform/configuration/common/configuration.js';\nimport { IOpenerService } from '../../../../platform/opener/common/opener.js';\nimport { ILanguageFeaturesService } from '../../../common/services/languageFeatures.js';\nimport { HoverVerbosityAction } from '../../../common/languages.js';\nimport { registerIcon } from '../../../../platform/theme/common/iconRegistry.js';\nimport { Codicon } from '../../../../base/common/codicons.js';\nimport { ThemeIcon } from '../../../../base/common/themables.js';\nimport { onUnexpectedExternalError } from '../../../../base/common/errors.js';\nimport { IKeybindingService } from '../../../../platform/keybinding/common/keybinding.js';\nimport { ClickAction, KeyDownAction } from '../../../../base/browser/ui/hover/hoverWidget.js';\nimport { IHoverService, WorkbenchHoverDelegate } from '../../../../platform/hover/browser/hover.js';\nimport { AsyncIterableObject } from '../../../../base/common/async.js';\nimport { getHoverProviderResultsAsAsyncIterable } from './getHover.js';\nconst $ = dom.$;\nconst increaseHoverVerbosityIcon = registerIcon('hover-increase-verbosity', Codicon.add, nls.localize('increaseHoverVerbosity', 'Icon for increaseing hover verbosity.'));\nconst decreaseHoverVerbosityIcon = registerIcon('hover-decrease-verbosity', Codicon.remove, nls.localize('decreaseHoverVerbosity', 'Icon for decreasing hover verbosity.'));\nexport class MarkdownHover {\n constructor(owner, range, contents, isBeforeContent, ordinal, source = undefined) {\n this.owner = owner;\n this.range = range;\n this.contents = contents;\n this.isBeforeContent = isBeforeContent;\n this.ordinal = ordinal;\n this.source = source;\n }\n isValidForHoverAnchor(anchor) {\n return (anchor.type === 1 /* HoverAnchorType.Range */\n && this.range.startColumn <= anchor.range.startColumn\n && this.range.endColumn >= anchor.range.endColumn);\n }\n}\nclass HoverSource {\n constructor(hover, hoverProvider, hoverPosition) {\n this.hover = hover;\n this.hoverProvider = hoverProvider;\n this.hoverPosition = hoverPosition;\n }\n supportsVerbosityAction(hoverVerbosityAction) {\n var _a, _b;\n switch (hoverVerbosityAction) {\n case HoverVerbosityAction.Increase:\n return (_a = this.hover.canIncreaseVerbosity) !== null && _a !== void 0 ? _a : false;\n case HoverVerbosityAction.Decrease:\n return (_b = this.hover.canDecreaseVerbosity) !== null && _b !== void 0 ? _b : false;\n }\n }\n}\nlet MarkdownHoverParticipant = class MarkdownHoverParticipant {\n constructor(_editor, _languageService, _openerService, _configurationService, _languageFeaturesService, _keybindingService, _hoverService) {\n this._editor = _editor;\n this._languageService = _languageService;\n this._openerService = _openerService;\n this._configurationService = _configurationService;\n this._languageFeaturesService = _languageFeaturesService;\n this._keybindingService = _keybindingService;\n this._hoverService = _hoverService;\n this.hoverOrdinal = 3;\n }\n createLoadingMessage(anchor) {\n return new MarkdownHover(this, anchor.range, [new MarkdownString().appendText(nls.localize('modesContentHover.loading', \"Loading...\"))], false, 2000);\n }\n computeSync(anchor, lineDecorations) {\n if (!this._editor.hasModel() || anchor.type !== 1 /* HoverAnchorType.Range */) {\n return [];\n }\n const model = this._editor.getModel();\n const lineNumber = anchor.range.startLineNumber;\n const maxColumn = model.getLineMaxColumn(lineNumber);\n const result = [];\n let index = 1000;\n const lineLength = model.getLineLength(lineNumber);\n const languageId = model.getLanguageIdAtPosition(anchor.range.startLineNumber, anchor.range.startColumn);\n const stopRenderingLineAfter = this._editor.getOption(117 /* EditorOption.stopRenderingLineAfter */);\n const maxTokenizationLineLength = this._configurationService.getValue('editor.maxTokenizationLineLength', {\n overrideIdentifier: languageId\n });\n let stopRenderingMessage = false;\n if (stopRenderingLineAfter >= 0 && lineLength > stopRenderingLineAfter && anchor.range.startColumn >= stopRenderingLineAfter) {\n stopRenderingMessage = true;\n result.push(new MarkdownHover(this, anchor.range, [{\n value: nls.localize('stopped rendering', \"Rendering paused for long line for performance reasons. This can be configured via `editor.stopRenderingLineAfter`.\")\n }], false, index++));\n }\n if (!stopRenderingMessage && typeof maxTokenizationLineLength === 'number' && lineLength >= maxTokenizationLineLength) {\n result.push(new MarkdownHover(this, anchor.range, [{\n value: nls.localize('too many characters', \"Tokenization is skipped for long lines for performance reasons. This can be configured via `editor.maxTokenizationLineLength`.\")\n }], false, index++));\n }\n let isBeforeContent = false;\n for (const d of lineDecorations) {\n const startColumn = (d.range.startLineNumber === lineNumber) ? d.range.startColumn : 1;\n const endColumn = (d.range.endLineNumber === lineNumber) ? d.range.endColumn : maxColumn;\n const hoverMessage = d.options.hoverMessage;\n if (!hoverMessage || isEmptyMarkdownString(hoverMessage)) {\n continue;\n }\n if (d.options.beforeContentClassName) {\n isBeforeContent = true;\n }\n const range = new Range(anchor.range.startLineNumber, startColumn, anchor.range.startLineNumber, endColumn);\n result.push(new MarkdownHover(this, range, asArray(hoverMessage), isBeforeContent, index++));\n }\n return result;\n }\n computeAsync(anchor, lineDecorations, token) {\n if (!this._editor.hasModel() || anchor.type !== 1 /* HoverAnchorType.Range */) {\n return AsyncIterableObject.EMPTY;\n }\n const model = this._editor.getModel();\n const hoverProviderRegistry = this._languageFeaturesService.hoverProvider;\n if (!hoverProviderRegistry.has(model)) {\n return AsyncIterableObject.EMPTY;\n }\n const markdownHovers = this._getMarkdownHovers(hoverProviderRegistry, model, anchor, token);\n return markdownHovers;\n }\n _getMarkdownHovers(hoverProviderRegistry, model, anchor, token) {\n const position = anchor.range.getStartPosition();\n const hoverProviderResults = getHoverProviderResultsAsAsyncIterable(hoverProviderRegistry, model, position, token);\n const markdownHovers = hoverProviderResults.filter(item => !isEmptyMarkdownString(item.hover.contents))\n .map(item => {\n const range = item.hover.range ? Range.lift(item.hover.range) : anchor.range;\n const hoverSource = new HoverSource(item.hover, item.provider, position);\n return new MarkdownHover(this, range, item.hover.contents, false, item.ordinal, hoverSource);\n });\n return markdownHovers;\n }\n renderHoverParts(context, hoverParts) {\n this._renderedHoverParts = new MarkdownRenderedHoverParts(hoverParts, context.fragment, this._editor, this._languageService, this._openerService, this._keybindingService, this._hoverService, this._configurationService, context.onContentsChanged);\n return this._renderedHoverParts;\n }\n markdownHoverContentAtIndex(index) {\n var _a, _b;\n return (_b = (_a = this._renderedHoverParts) === null || _a === void 0 ? void 0 : _a.markdownHoverContentAtIndex(index)) !== null && _b !== void 0 ? _b : '';\n }\n doesMarkdownHoverAtIndexSupportVerbosityAction(index, action) {\n var _a, _b;\n return (_b = (_a = this._renderedHoverParts) === null || _a === void 0 ? void 0 : _a.doesMarkdownHoverAtIndexSupportVerbosityAction(index, action)) !== null && _b !== void 0 ? _b : false;\n }\n updateMarkdownHoverVerbosityLevel(action, index, focus) {\n var _a;\n (_a = this._renderedHoverParts) === null || _a === void 0 ? void 0 : _a.updateMarkdownHoverPartVerbosityLevel(action, index, focus);\n }\n};\nMarkdownHoverParticipant = __decorate([\n __param(1, ILanguageService),\n __param(2, IOpenerService),\n __param(3, IConfigurationService),\n __param(4, ILanguageFeaturesService),\n __param(5, IKeybindingService),\n __param(6, IHoverService)\n], MarkdownHoverParticipant);\nexport { MarkdownHoverParticipant };\nclass MarkdownRenderedHoverParts extends Disposable {\n constructor(hoverParts, // we own!\n hoverPartsContainer, _editor, _languageService, _openerService, _keybindingService, _hoverService, _configurationService, _onFinishedRendering) {\n super();\n this._editor = _editor;\n this._languageService = _languageService;\n this._openerService = _openerService;\n this._keybindingService = _keybindingService;\n this._hoverService = _hoverService;\n this._configurationService = _configurationService;\n this._onFinishedRendering = _onFinishedRendering;\n this._focusedHoverPartIndex = -1;\n this._ongoingHoverOperations = new Map();\n this._renderedHoverParts = this._renderHoverParts(hoverParts, hoverPartsContainer, this._onFinishedRendering);\n this._register(toDisposable(() => {\n this._renderedHoverParts.forEach(renderedHoverPart => {\n renderedHoverPart.disposables.dispose();\n });\n }));\n this._register(toDisposable(() => {\n this._ongoingHoverOperations.forEach(operation => { operation.tokenSource.dispose(true); });\n }));\n }\n _renderHoverParts(hoverParts, hoverPartsContainer, onFinishedRendering) {\n hoverParts.sort(compareBy(hover => hover.ordinal, numberComparator));\n return hoverParts.map((hoverPart, hoverIndex) => {\n const renderedHoverPart = this._renderHoverPart(hoverIndex, hoverPart.contents, hoverPart.source, onFinishedRendering);\n hoverPartsContainer.appendChild(renderedHoverPart.renderedMarkdown);\n return renderedHoverPart;\n });\n }\n _renderHoverPart(hoverPartIndex, hoverContents, hoverSource, onFinishedRendering) {\n const { renderedMarkdown, disposables } = this._renderMarkdownContent(hoverContents, onFinishedRendering);\n if (!hoverSource) {\n return { renderedMarkdown, disposables };\n }\n const canIncreaseVerbosity = hoverSource.supportsVerbosityAction(HoverVerbosityAction.Increase);\n const canDecreaseVerbosity = hoverSource.supportsVerbosityAction(HoverVerbosityAction.Decrease);\n if (!canIncreaseVerbosity && !canDecreaseVerbosity) {\n return { renderedMarkdown, disposables, hoverSource };\n }\n const actionsContainer = $('div.verbosity-actions');\n renderedMarkdown.prepend(actionsContainer);\n disposables.add(this._renderHoverExpansionAction(actionsContainer, HoverVerbosityAction.Increase, canIncreaseVerbosity));\n disposables.add(this._renderHoverExpansionAction(actionsContainer, HoverVerbosityAction.Decrease, canDecreaseVerbosity));\n this._register(dom.addDisposableListener(renderedMarkdown, dom.EventType.FOCUS_IN, (event) => {\n event.stopPropagation();\n this._focusedHoverPartIndex = hoverPartIndex;\n }));\n this._register(dom.addDisposableListener(renderedMarkdown, dom.EventType.FOCUS_OUT, (event) => {\n event.stopPropagation();\n this._focusedHoverPartIndex = -1;\n }));\n return { renderedMarkdown, disposables, hoverSource };\n }\n _renderMarkdownContent(markdownContent, onFinishedRendering) {\n const renderedMarkdown = $('div.hover-row');\n renderedMarkdown.tabIndex = 0;\n const renderedMarkdownContents = $('div.hover-row-contents');\n renderedMarkdown.appendChild(renderedMarkdownContents);\n const disposables = new DisposableStore();\n disposables.add(renderMarkdownInContainer(this._editor, renderedMarkdownContents, markdownContent, this._languageService, this._openerService, onFinishedRendering));\n return { renderedMarkdown, disposables };\n }\n _renderHoverExpansionAction(container, action, actionEnabled) {\n const store = new DisposableStore();\n const isActionIncrease = action === HoverVerbosityAction.Increase;\n const actionElement = dom.append(container, $(ThemeIcon.asCSSSelector(isActionIncrease ? increaseHoverVerbosityIcon : decreaseHoverVerbosityIcon)));\n actionElement.tabIndex = 0;\n const hoverDelegate = new WorkbenchHoverDelegate('mouse', false, { target: container, position: { hoverPosition: 0 /* HoverPosition.LEFT */ } }, this._configurationService, this._hoverService);\n store.add(this._hoverService.setupUpdatableHover(hoverDelegate, actionElement, labelForHoverVerbosityAction(this._keybindingService, action)));\n if (!actionEnabled) {\n actionElement.classList.add('disabled');\n return store;\n }\n actionElement.classList.add('enabled');\n const actionFunction = () => this.updateMarkdownHoverPartVerbosityLevel(action);\n store.add(new ClickAction(actionElement, actionFunction));\n store.add(new KeyDownAction(actionElement, actionFunction, [3 /* KeyCode.Enter */, 10 /* KeyCode.Space */]));\n return store;\n }\n async updateMarkdownHoverPartVerbosityLevel(action, index = -1, focus = true) {\n var _a;\n const model = this._editor.getModel();\n if (!model) {\n return;\n }\n const indexOfInterest = index !== -1 ? index : this._focusedHoverPartIndex;\n const hoverRenderedPart = this._getRenderedHoverPartAtIndex(indexOfInterest);\n if (!hoverRenderedPart || !((_a = hoverRenderedPart.hoverSource) === null || _a === void 0 ? void 0 : _a.supportsVerbosityAction(action))) {\n return;\n }\n const hoverSource = hoverRenderedPart.hoverSource;\n const newHover = await this._fetchHover(hoverSource, model, action);\n if (!newHover) {\n return;\n }\n const newHoverSource = new HoverSource(newHover, hoverSource.hoverProvider, hoverSource.hoverPosition);\n const newHoverRenderedPart = this._renderHoverPart(indexOfInterest, newHover.contents, newHoverSource, this._onFinishedRendering);\n this._replaceRenderedHoverPartAtIndex(indexOfInterest, newHoverRenderedPart);\n if (focus) {\n this._focusOnHoverPartWithIndex(indexOfInterest);\n }\n this._onFinishedRendering();\n }\n markdownHoverContentAtIndex(index) {\n var _a;\n const hoverRenderedPart = this._getRenderedHoverPartAtIndex(index);\n return (_a = hoverRenderedPart === null || hoverRenderedPart === void 0 ? void 0 : hoverRenderedPart.renderedMarkdown.innerText) !== null && _a !== void 0 ? _a : '';\n }\n doesMarkdownHoverAtIndexSupportVerbosityAction(index, action) {\n var _a;\n const hoverRenderedPart = this._getRenderedHoverPartAtIndex(index);\n if (!hoverRenderedPart || !((_a = hoverRenderedPart.hoverSource) === null || _a === void 0 ? void 0 : _a.supportsVerbosityAction(action))) {\n return false;\n }\n return true;\n }\n async _fetchHover(hoverSource, model, action) {\n let verbosityDelta = action === HoverVerbosityAction.Increase ? 1 : -1;\n const provider = hoverSource.hoverProvider;\n const ongoingHoverOperation = this._ongoingHoverOperations.get(provider);\n if (ongoingHoverOperation) {\n ongoingHoverOperation.tokenSource.cancel();\n verbosityDelta += ongoingHoverOperation.verbosityDelta;\n }\n const tokenSource = new CancellationTokenSource();\n this._ongoingHoverOperations.set(provider, { verbosityDelta, tokenSource });\n const context = { verbosityRequest: { verbosityDelta, previousHover: hoverSource.hover } };\n let hover;\n try {\n hover = await Promise.resolve(provider.provideHover(model, hoverSource.hoverPosition, tokenSource.token, context));\n }\n catch (e) {\n onUnexpectedExternalError(e);\n }\n tokenSource.dispose();\n this._ongoingHoverOperations.delete(provider);\n return hover;\n }\n _replaceRenderedHoverPartAtIndex(index, renderedHoverPart) {\n if (index >= this._renderHoverParts.length || index < 0) {\n return;\n }\n const currentRenderedHoverPart = this._renderedHoverParts[index];\n const currentRenderedMarkdown = currentRenderedHoverPart.renderedMarkdown;\n currentRenderedMarkdown.replaceWith(renderedHoverPart.renderedMarkdown);\n currentRenderedHoverPart.disposables.dispose();\n this._renderedHoverParts[index] = renderedHoverPart;\n }\n _focusOnHoverPartWithIndex(index) {\n this._renderedHoverParts[index].renderedMarkdown.focus();\n }\n _getRenderedHoverPartAtIndex(index) {\n return this._renderedHoverParts[index];\n }\n}\nexport function renderMarkdownHovers(context, hoverParts, editor, languageService, openerService) {\n // Sort hover parts to keep them stable since they might come in async, out-of-order\n hoverParts.sort(compareBy(hover => hover.ordinal, numberComparator));\n const disposables = new DisposableStore();\n for (const hoverPart of hoverParts) {\n disposables.add(renderMarkdownInContainer(editor, context.fragment, hoverPart.contents, languageService, openerService, context.onContentsChanged));\n }\n return disposables;\n}\nfunction renderMarkdownInContainer(editor, container, markdownStrings, languageService, openerService, onFinishedRendering) {\n const store = new DisposableStore();\n for (const contents of markdownStrings) {\n if (isEmptyMarkdownString(contents)) {\n continue;\n }\n const markdownHoverElement = $('div.markdown-hover');\n const hoverContentsElement = dom.append(markdownHoverElement, $('div.hover-contents'));\n const renderer = store.add(new MarkdownRenderer({ editor }, languageService, openerService));\n store.add(renderer.onDidRenderAsync(() => {\n hoverContentsElement.className = 'hover-contents code-hover-contents';\n onFinishedRendering();\n }));\n const renderedContents = store.add(renderer.render(contents));\n hoverContentsElement.appendChild(renderedContents.element);\n container.appendChild(markdownHoverElement);\n }\n return store;\n}\nexport function labelForHoverVerbosityAction(keybindingService, action) {\n switch (action) {\n case HoverVerbosityAction.Increase: {\n const kb = keybindingService.lookupKeybinding(INCREASE_HOVER_VERBOSITY_ACTION_ID);\n return kb ?\n nls.localize('increaseVerbosityWithKb', \"Increase Hover Verbosity ({0})\", kb.getLabel()) :\n nls.localize('increaseVerbosity', \"Increase Hover Verbosity\");\n }\n case HoverVerbosityAction.Decrease: {\n const kb = keybindingService.lookupKeybinding(DECREASE_HOVER_VERBOSITY_ACTION_ID);\n return kb ?\n nls.localize('decreaseVerbosityWithKb', \"Decrease Hover Verbosity ({0})\", kb.getLabel()) :\n nls.localize('decreaseVerbosity', \"Decrease Hover Verbosity\");\n }\n }\n}\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 *--------------------------------------------------------------------------------------------*/\nimport { Selection } from '../../../common/core/selection.js';\nexport class InPlaceReplaceCommand {\n constructor(editRange, originalSelection, text) {\n this._editRange = editRange;\n this._originalSelection = originalSelection;\n this._text = text;\n }\n getEditOperations(model, builder) {\n builder.addTrackedEditOperation(this._editRange, this._text);\n }\n computeCursorState(model, helper) {\n const inverseEditOperations = helper.getInverseEditOperations();\n const srcRange = inverseEditOperations[0].range;\n if (!this._originalSelection.isEmpty()) {\n // Preserve selection and extends to typed text\n return new Selection(srcRange.endLineNumber, srcRange.endColumn - this._text.length, srcRange.endLineNumber, srcRange.endColumn);\n }\n return new Selection(srcRange.endLineNumber, Math.min(this._originalSelection.positionColumn, srcRange.endColumn), srcRange.endLineNumber, Math.min(this._originalSelection.positionColumn, srcRange.endColumn));\n }\n}\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 *--------------------------------------------------------------------------------------------*/\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\n return c > 3 && r && Object.defineProperty(target, key, r), r;\n};\nvar __param = (this && this.__param) || function (paramIndex, decorator) {\n return function (target, key) { decorator(target, key, paramIndex); }\n};\nvar InPlaceReplaceController_1;\nimport { createCancelablePromise, timeout } from '../../../../base/common/async.js';\nimport { onUnexpectedError } from '../../../../base/common/errors.js';\nimport { EditorState } from '../../editorState/browser/editorState.js';\nimport { EditorAction, registerEditorAction, registerEditorContribution } from '../../../browser/editorExtensions.js';\nimport { Range } from '../../../common/core/range.js';\nimport { Selection } from '../../../common/core/selection.js';\nimport { EditorContextKeys } from '../../../common/editorContextKeys.js';\nimport { ModelDecorationOptions } from '../../../common/model/textModel.js';\nimport { IEditorWorkerService } from '../../../common/services/editorWorker.js';\nimport * as nls from '../../../../nls.js';\nimport { InPlaceReplaceCommand } from './inPlaceReplaceCommand.js';\nimport './inPlaceReplace.css';\nlet InPlaceReplaceController = InPlaceReplaceController_1 = class InPlaceReplaceController {\n static get(editor) {\n return editor.getContribution(InPlaceReplaceController_1.ID);\n }\n constructor(editor, editorWorkerService) {\n this.editor = editor;\n this.editorWorkerService = editorWorkerService;\n this.decorations = this.editor.createDecorationsCollection();\n }\n dispose() {\n }\n run(source, up) {\n var _a;\n // cancel any pending request\n (_a = this.currentRequest) === null || _a === void 0 ? void 0 : _a.cancel();\n const editorSelection = this.editor.getSelection();\n const model = this.editor.getModel();\n if (!model || !editorSelection) {\n return undefined;\n }\n let selection = editorSelection;\n if (selection.startLineNumber !== selection.endLineNumber) {\n // Can't accept multiline selection\n return undefined;\n }\n const state = new EditorState(this.editor, 1 /* CodeEditorStateFlag.Value */ | 4 /* CodeEditorStateFlag.Position */);\n const modelURI = model.uri;\n if (!this.editorWorkerService.canNavigateValueSet(modelURI)) {\n return Promise.resolve(undefined);\n }\n this.currentRequest = createCancelablePromise(token => this.editorWorkerService.navigateValueSet(modelURI, selection, up));\n return this.currentRequest.then(result => {\n var _a;\n if (!result || !result.range || !result.value) {\n // No proper result\n return;\n }\n if (!state.validate(this.editor)) {\n // state has changed\n return;\n }\n // Selection\n const editRange = Range.lift(result.range);\n let highlightRange = result.range;\n const diff = result.value.length - (selection.endColumn - selection.startColumn);\n // highlight\n highlightRange = {\n startLineNumber: highlightRange.startLineNumber,\n startColumn: highlightRange.startColumn,\n endLineNumber: highlightRange.endLineNumber,\n endColumn: highlightRange.startColumn + result.value.length\n };\n if (diff > 1) {\n selection = new Selection(selection.startLineNumber, selection.startColumn, selection.endLineNumber, selection.endColumn + diff - 1);\n }\n // Insert new text\n const command = new InPlaceReplaceCommand(editRange, selection, result.value);\n this.editor.pushUndoStop();\n this.editor.executeCommand(source, command);\n this.editor.pushUndoStop();\n // add decoration\n this.decorations.set([{\n range: highlightRange,\n options: InPlaceReplaceController_1.DECORATION\n }]);\n // remove decoration after delay\n (_a = this.decorationRemover) === null || _a === void 0 ? void 0 : _a.cancel();\n this.decorationRemover = timeout(350);\n this.decorationRemover.then(() => this.decorations.clear()).catch(onUnexpectedError);\n }).catch(onUnexpectedError);\n }\n};\nInPlaceReplaceController.ID = 'editor.contrib.inPlaceReplaceController';\nInPlaceReplaceController.DECORATION = ModelDecorationOptions.register({\n description: 'in-place-replace',\n className: 'valueSetReplacement'\n});\nInPlaceReplaceController = InPlaceReplaceController_1 = __decorate([\n __param(1, IEditorWorkerService)\n], InPlaceReplaceController);\nclass InPlaceReplaceUp extends EditorAction {\n constructor() {\n super({\n id: 'editor.action.inPlaceReplace.up',\n label: nls.localize('InPlaceReplaceAction.previous.label', \"Replace with Previous Value\"),\n alias: 'Replace with Previous Value',\n precondition: EditorContextKeys.writable,\n kbOpts: {\n kbExpr: EditorContextKeys.editorTextFocus,\n primary: 2048 /* KeyMod.CtrlCmd */ | 1024 /* KeyMod.Shift */ | 87 /* KeyCode.Comma */,\n weight: 100 /* KeybindingWeight.EditorContrib */\n }\n });\n }\n run(accessor, editor) {\n const controller = InPlaceReplaceController.get(editor);\n if (!controller) {\n return Promise.resolve(undefined);\n }\n return controller.run(this.id, false);\n }\n}\nclass InPlaceReplaceDown extends EditorAction {\n constructor() {\n super({\n id: 'editor.action.inPlaceReplace.down',\n label: nls.localize('InPlaceReplaceAction.next.label', \"Replace with Next Value\"),\n alias: 'Replace with Next Value',\n precondition: EditorContextKeys.writable,\n kbOpts: {\n kbExpr: EditorContextKeys.editorTextFocus,\n primary: 2048 /* KeyMod.CtrlCmd */ | 1024 /* KeyMod.Shift */ | 89 /* KeyCode.Period */,\n weight: 100 /* KeybindingWeight.EditorContrib */\n }\n });\n }\n run(accessor, editor) {\n const controller = InPlaceReplaceController.get(editor);\n if (!controller) {\n return Promise.resolve(undefined);\n }\n return controller.run(this.id, true);\n }\n}\nregisterEditorContribution(InPlaceReplaceController.ID, InPlaceReplaceController, 4 /* EditorContributionInstantiation.Lazy */);\nregisterEditorAction(InPlaceReplaceUp);\nregisterEditorAction(InPlaceReplaceDown);\n"],"names":["__decorate","decorators","target","key","desc","d","c","arguments","length","r","Object","getOwnPropertyDescriptor","Reflect","decorate","i","defineProperty","__param","paramIndex","decorator","$","EditorHoverStatusBar","hasContent","this","_hasContent","constructor","_keybindingService","super","hoverElement","tabIndex","actionsElement","addAction","actionOptions","keybinding","lookupKeybinding","commandId","keybindingLabel","getLabel","_register","append","element","result","HoverProviderResult","provider","hover","ordinal","getHoverProviderResultsAsAsyncIterable","registry","model","position","token","promises","ordered","map","index","async","Promise","resolve","provideHover","catch","hasRange","range","hasHtmlContent","contents","isValid","executeProvider","coalesce","accessor","item","toPromise","getHoversPromise","get","hoverProvider","SHOW_OR_FOCUS_HOVER_ACTION_ID","SHOW_DEFINITION_PREVIEW_HOVER_ACTION_ID","SCROLL_UP_HOVER_ACTION_ID","SCROLL_DOWN_HOVER_ACTION_ID","SCROLL_LEFT_HOVER_ACTION_ID","SCROLL_RIGHT_HOVER_ACTION_ID","PAGE_UP_HOVER_ACTION_ID","PAGE_DOWN_HOVER_ACTION_ID","GO_TO_TOP_HOVER_ACTION_ID","GO_TO_BOTTOM_HOVER_ACTION_ID","INCREASE_HOVER_VERBOSITY_ACTION_ID","INCREASE_HOVER_VERBOSITY_ACTION_LABEL","comment","DECREASE_HOVER_VERBOSITY_ACTION_ID","DECREASE_HOVER_VERBOSITY_ACTION_LABEL","HoverFocusBehavior","ShowOrFocusHoverAction","id","label","nls","metadata","description","args","name","schema","type","properties","enum","NoAutoFocus","FocusIfVisible","AutoFocusImmediately","enumDescriptions","default","alias","precondition","undefined","kbOpts","kbExpr","primary","weight","run","editor","hasModel","controller","focusArgument","focus","focusOption","values","includes","showContentHover","getPosition","lineNumber","column","accessibilitySupportEnabled","getOption","isHoverVisible","ShowDefinitionPreviewHoverAction","goto","startFindDefinitionFromCursor","then","ScrollUpHoverAction","scrollUp","ScrollDownHoverAction","scrollDown","ScrollLeftHoverAction","scrollLeft","ScrollRightHoverAction","scrollRight","PageUpHoverAction","secondary","pageUp","PageDownHoverAction","pageDown","GoToTopHoverAction","goToTop","GoToBottomHoverAction","goToBottom","IncreaseHoverVerbosityLevel","_a","updateMarkdownHoverVerbosityLevel","DecreaseHoverVerbosityLevel","dom","MarkerHover","owner","marker","isValidForHoverAnchor","anchor","startColumn","endColumn","markerCodeActionTrigger","filter","include","triggerAction","MarkerHoverParticipant","_editor","_markerDecorationsService","_openerService","_languageFeaturesService","hoverOrdinal","recentMarkerCodeActionsInfo","computeSync","lineDecorations","supportsMarkerHover","getModel","startLineNumber","maxColumn","getLineMaxColumn","endLineNumber","getMarker","uri","push","renderHoverParts","context","hoverParts","disposables","forEach","msg","fragment","appendChild","renderMarkerHover","markerHoverForStatusbar","sort","a","b","severity","renderMarkerStatusbar","markerHover","markerElement","source","message","code","relatedInformation","applyFontInfo","messageElement","style","whiteSpace","innerText","sourceAndCodeElement","codeLink","setAttribute","toString","add","e","open","allowCommands","preventDefault","stopPropagation","value","detailsElement","opacity","paddingLeft","resource","relatedInfoContainer","marginTop","cursor","fromUserGesture","editorOptions","selection","markerController","statusBar","hide","showAtMarker","quickfixPlaceholderElement","hasCodeActions","textContent","updatePlaceholderDisposable","String","fromCharCode","codeActionsPromise","getCodeActions","cancel","actions","dispose","validActions","display","showing","elementPosition","showCodeActions","x","left","y","top","width","height","cancellationToken","codeActionProvider","HoverAccessibilityHelpNLS","intro","increaseVerbosity","decreaseVerbosity","hoverContent","theme","collector","hoverBorder","getColor","addRule","transparent","_provider","ResizableContentWidget","minimumSize","allowEditorOverflow","suppressMouseDown","_resizableNode","_contentPosition","_isResizing","domNode","minSize","layout","enableSashes","onDidResize","_resize","dimension","done","onDidWillResize","isResizing","getDomNode","_availableVerticalSpaceAbove","editorDomNode","mouseBox","getScrolledVisiblePosition","_availableVerticalSpaceBelow","editorBox","bodyBox","ownerDocument","body","mouseBottom","_findPositionPreference","widgetHeight","showAtPosition","_b","maxHeightBelow","Math","min","Infinity","maxHeightAbove","maxHeight","max","renderingAbove","above","ContentHoverWidget_1","ContentHoverWidget","isColorPickerVisible","Boolean","_visibleData","colorPicker","isVisibleFromKeyboard","isVisible","_hoverVisibleKey","isFocused","_hoverFocusedKey","contextKeyService","_configurationService","_accessibilityService","minimumHeight","_hover","_minimumSize","containerDomNode","zIndex","onDidLayoutChange","_updateMaxDimensions","onDidChangeConfiguration","hasChanged","_updateFont","focusTracker","onDidFocus","set","onDidBlur","_setHoverData","addContentWidget","removeContentWidget","getId","ID","_applyDimensions","container","transformedWidth","transformedHeight","_setContentsDomNodeDimensions","contentsDomNode","_setContainerDomNodeDimensions","_setHoverWidgetDimensions","_layoutContentWidget","_applyMaxDimensions","maxWidth","_setHoverWidgetMaxDimensions","setProperty","_setAdjustedHoverWidgetDimensions","size","_updateResizableNodeMaxDimensions","maxRenderingWidth","_findMaximumRenderingWidth","maxRenderingHeight","_findMaximumRenderingHeight","maxSize","_lastDimensions","scrollbar","scanDomNode","layoutContentWidget","_findAvailableSpaceVertically","_positionPreference","availableSpace","maximumHeight","Array","from","children","hoverPart","clientHeight","_isHoverTextOverflowing","overflowing","some","scrollWidth","clientWidth","removeProperty","initialWidth","_contentWidth","isMouseGettingCloser","posx","posy","initialMousePosX","initialMousePosY","widgetRect","closestMouseDistance","computeDistanceFromPointToRectangle","distance","hoverData","classList","toggle","fontSize","lineHeight","prototype","slice","call","getElementsByClassName","node","_updateContent","paddingBottom","onContentsChanged","getLayoutInfo","_render","render","secondaryPosition","showAtSecondaryPosition","positionAffinity","isBeforeContent","preference","showAt","_c","_d","widgetPosition","stoleFocus","accessibleViewHint","activeElement","getValue","isScreenReaderOptimized","getAriaLabel","ariaLabel","clearSashHoverState","_removeConstraintsRenderNormally","layoutInfo","setMinimumDimensions","dimensions","_updateMinimumWidth","scrollTop","getScrollPosition","fontInfo","setScrollPosition","scrollHeight","getScrollDimensions","pointX","pointY","dx","abs","dy","sqrt","HoverResult","isComplete","hasLoadingMessage","HoverOperation","_computer","_onResult","onResult","event","_firstWaitScheduler","_triggerAsyncComputation","_secondWaitScheduler","_triggerSyncComputation","_loadingMessageScheduler","_triggerLoadingMessage","_state","_asyncIterable","_asyncIterableDone","_result","_hoverTime","delay","_firstWaitTime","_secondWaitTime","_loadingMessageTime","_setState","state","fireResult","_fireResult","schedule","computeAsync","concat","fire","start","mode","ContentHoverComputer","_anchor","shouldFocus","_shouldFocus","_source","insistOnKeepingHoverVisible","_insistOnKeepingHoverVisible","_participants","_getLineDecorations","getLineCount","getLineDecorations","options","isWholeLine","showIfCollapsed","participant","messages","filteredMessages","m","FilteredHoverResult","original","ContentHoverVisibleData","preferAbove","ContentHoverController_1","ContentHoverController","_instantiationService","_currentResult","_onContentsChanged","_widget","createInstance","participantInstance","_markdownHoverParticipant","p1","p2","_hoverOperation","_addLoadingMessage","_withResult","equals","_setCurrentResult","_startShowingOrUpdateHover","mouseEvent","_startHoverOperationIfNecessary","sticky","canAdoptVisibleHover","hoverResult","_renderMessages","createLoadingMessage","loadingMessage","highlightRange","computeHoverRanges","document","createDocumentFragment","setColorPicker","widget","_doOnContentsChanged","hasChildNodes","highlightDecoration","createDecorationsCollection","_DECORATION_OPTIONS","clear","anchorRange","startColumnBoundary","viewModel","_getViewModel","coordinatesConverter","anchorViewRange","convertModelRangeToViewRange","anchorViewRangeStart","getLineMinColumn","convertViewPositionToModelPosition","anchorLineNumber","renderStartColumn","forceShowAtRange","getStartPosition","showsOrWillShow","anchorCandidates","suggestHoverAnchor","epsilon","typicalHalfwidthCharacterWidth","detail","isAfterLines","horizontalDistanceToText","priority","startShowingAtRange","action","markdownHoverContentAtIndex","doesMarkdownHoverAtIndexSupportVerbosityAction","containsNode","contains","className","MarginHoverComputer","_lineNumber","lane","_laneOrLine","toHoverMessage","isLineHover","glyphMargin","hoverMessage","lineNumberHoverMessage","glyphMarginHoverMessage","MarginHoverWidget","languageService","openerService","_renderDisposeables","_isVisible","_messages","_markdownRenderer","onDidChangeModelDecorations","_onModelDecorationsChanged","addOverlayWidget","removeOverlayWidget","glyphMarginLane","_startShowingAt","laneOrLine","markdownHoverElement","hoverContentsElement","renderedContents","_updateContents","_showAt","editorLayout","topForLineNumber","getTopForLineNumber","editorScrollTop","getScrollTop","glyphMarginLeft","glyphMarginWidth","lineNumbersWidth","round","HoverController_1","HoverController","_onHoverContentsChanged","shouldKeepOpenOnEditorMouseMoveOrLeave","_listenersStore","_hoverState","mouseDown","activatedByDecoratorClick","_reactToEditorMouseMoveRunner","_reactToEditorMouseMove","_mouseMoveEvent","_hookListeners","_unhookListeners","getContribution","hoverOpts","_hoverSettings","enabled","hidingDelay","onMouseDown","_onEditorMouseDown","onMouseUp","_onEditorMouseUp","onMouseMove","_onEditorMouseMove","onKeyDown","_onKeyDown","onMouseLeave","_onEditorMouseLeave","onDidChangeModel","_cancelScheduler","_hideWidgets","onDidChangeModelContent","onDidScrollChange","_onEditorScrollChanged","scrollTopChanged","scrollLeftChanged","_shouldNotHideCurrentHoverWidget","_isMouseOnContentHoverWidget","_isMouseOnMarginHoverWidget","_isContentWidgetResizing","_shouldNotRecomputeCurrentHoverWidget","isHoverSticky","isMouseOnMarginHoverWidget","isMouseOnStickyMarginHoverWidget","isMouseOnContentHoverWidget","isMouseOnStickyContentHoverWidget","_contentWidget","isMouseOnColorPicker","browserEvent","view","getSelection","isCollapsed","isTextSelectedWithinContentHoverWidget","isScheduled","mouseOnDecorator","decoratorActivatedOn","_tryShowHoverWidget","hoverWidgetType","contentWidget","_getOrCreateContentWidget","glyphWidget","_getOrCreateGlyphWidget","currentWidget","otherWidget","Error","resolvedKeyboardEvent","softDispatch","shouldKeepHoverVisible","kind","keyCode","_glyphWidget","activatedByColorDecoratorClick","HoverRangeAnchor","other","equalsRange","lastAnchor","HoverForeignElementAnchor","HoverParticipantRegistry","register","ctor","getAll","increaseHoverVerbosityIcon","decreaseHoverVerbosityIcon","MarkdownHover","HoverSource","hoverPosition","supportsVerbosityAction","hoverVerbosityAction","canIncreaseVerbosity","canDecreaseVerbosity","MarkdownHoverParticipant","_languageService","_hoverService","appendText","lineLength","getLineLength","languageId","getLanguageIdAtPosition","stopRenderingLineAfter","maxTokenizationLineLength","overrideIdentifier","stopRenderingMessage","beforeContentClassName","hoverProviderRegistry","has","_getMarkdownHovers","hoverSource","_renderedHoverParts","MarkdownRenderedHoverParts","updateMarkdownHoverPartVerbosityLevel","hoverPartsContainer","_onFinishedRendering","_focusedHoverPartIndex","_ongoingHoverOperations","Map","_renderHoverParts","renderedHoverPart","operation","tokenSource","onFinishedRendering","hoverIndex","_renderHoverPart","renderedMarkdown","hoverPartIndex","hoverContents","_renderMarkdownContent","actionsContainer","prepend","_renderHoverExpansionAction","markdownContent","renderedMarkdownContents","renderMarkdownInContainer","actionEnabled","store","isActionIncrease","actionElement","hoverDelegate","setupUpdatableHover","keybindingService","kb","labelForHoverVerbosityAction","actionFunction","indexOfInterest","hoverRenderedPart","_getRenderedHoverPartAtIndex","newHover","_fetchHover","newHoverSource","newHoverRenderedPart","_replaceRenderedHoverPartAtIndex","_focusOnHoverPartWithIndex","verbosityDelta","ongoingHoverOperation","verbosityRequest","previousHover","delete","currentRenderedHoverPart","replaceWith","renderMarkdownHovers","markdownStrings","renderer","onDidRenderAsync","InPlaceReplaceCommand","editRange","originalSelection","text","_editRange","_originalSelection","_text","getEditOperations","builder","addTrackedEditOperation","computeCursorState","helper","srcRange","getInverseEditOperations","isEmpty","positionColumn","InPlaceReplaceController_1","InPlaceReplaceController","editorWorkerService","decorations","up","currentRequest","editorSelection","modelURI","canNavigateValueSet","navigateValueSet","validate","diff","command","pushUndoStop","executeCommand","DECORATION","decorationRemover","InPlaceReplaceUp","InPlaceReplaceDown"],"sourceRoot":""}