monaco-editor-core 0.55.1 → 0.56.0-dev-20251121

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (415) hide show
  1. package/esm/nls.keys.json +1 -1
  2. package/esm/nls.messages.cs.js +2 -2
  3. package/esm/nls.messages.de.js +2 -2
  4. package/esm/nls.messages.es.js +2 -2
  5. package/esm/nls.messages.fr.js +2 -2
  6. package/esm/nls.messages.it.js +2 -2
  7. package/esm/nls.messages.ja.js +2 -2
  8. package/esm/nls.messages.js +1 -1
  9. package/esm/nls.messages.json +1 -1
  10. package/esm/nls.messages.ko.js +2 -2
  11. package/esm/nls.messages.pl.js +2 -2
  12. package/esm/nls.messages.pt-br.js +2 -2
  13. package/esm/nls.messages.ru.js +2 -2
  14. package/esm/nls.messages.tr.js +2 -2
  15. package/esm/nls.messages.zh-cn.js +2 -2
  16. package/esm/nls.messages.zh-tw.js +2 -2
  17. package/esm/nls.metadata.json +27 -8
  18. package/esm/vs/base/browser/dom.js +31 -34
  19. package/esm/vs/base/browser/dom.js.map +1 -1
  20. package/esm/vs/base/browser/dompurify/dompurify.js +0 -1
  21. package/esm/vs/base/browser/keyboardEvent.js +3 -3
  22. package/esm/vs/base/browser/keyboardEvent.js.map +1 -1
  23. package/esm/vs/base/browser/markdownRenderer.js +5 -2
  24. package/esm/vs/base/browser/markdownRenderer.js.map +1 -1
  25. package/esm/vs/base/browser/pixelRatio.js +5 -5
  26. package/esm/vs/base/browser/pixelRatio.js.map +1 -1
  27. package/esm/vs/base/browser/trustedTypes.js +1 -1
  28. package/esm/vs/base/browser/trustedTypes.js.map +1 -1
  29. package/esm/vs/base/browser/ui/actionbar/actionbar.js +3 -0
  30. package/esm/vs/base/browser/ui/actionbar/actionbar.js.map +1 -1
  31. package/esm/vs/base/browser/ui/codicons/codicon/codicon.ttf +0 -0
  32. package/esm/vs/base/browser/ui/dropdown/dropdownActionViewItem.js +7 -0
  33. package/esm/vs/base/browser/ui/dropdown/dropdownActionViewItem.js.map +1 -1
  34. package/esm/vs/base/browser/ui/hover/hoverWidget.css +0 -13
  35. package/esm/vs/base/browser/ui/inputbox/inputBox.js +7 -0
  36. package/esm/vs/base/browser/ui/inputbox/inputBox.js.map +1 -1
  37. package/esm/vs/base/browser/ui/keybindingLabel/keybindingLabel.css +4 -2
  38. package/esm/vs/base/browser/ui/list/listView.js +7 -2
  39. package/esm/vs/base/browser/ui/list/listView.js.map +1 -1
  40. package/esm/vs/base/browser/ui/selectBox/selectBox.js +4 -0
  41. package/esm/vs/base/browser/ui/selectBox/selectBox.js.map +1 -1
  42. package/esm/vs/base/browser/ui/selectBox/selectBoxCustom.css +12 -32
  43. package/esm/vs/base/browser/ui/selectBox/selectBoxCustom.js +8 -18
  44. package/esm/vs/base/browser/ui/selectBox/selectBoxCustom.js.map +1 -1
  45. package/esm/vs/base/browser/ui/toolbar/toolbar.js +41 -14
  46. package/esm/vs/base/browser/ui/toolbar/toolbar.js.map +1 -1
  47. package/esm/vs/base/browser/ui/tree/abstractTree.js +11 -0
  48. package/esm/vs/base/browser/ui/tree/abstractTree.js.map +1 -1
  49. package/esm/vs/base/browser/ui/tree/asyncDataTree.js +1 -0
  50. package/esm/vs/base/browser/ui/tree/asyncDataTree.js.map +1 -1
  51. package/esm/vs/base/browser/ui/tree/compressedObjectTreeModel.js.map +1 -1
  52. package/esm/vs/base/browser/ui/tree/dataTree.js.map +1 -1
  53. package/esm/vs/base/browser/ui/tree/indexTreeModel.js.map +1 -1
  54. package/esm/vs/base/browser/ui/tree/objectTree.js.map +1 -1
  55. package/esm/vs/base/browser/ui/tree/objectTreeModel.js.map +1 -1
  56. package/esm/vs/base/browser/ui/tree/tree.js.map +1 -1
  57. package/esm/vs/base/common/arrays.js +10 -0
  58. package/esm/vs/base/common/arrays.js.map +1 -1
  59. package/esm/vs/base/common/async.js +34 -0
  60. package/esm/vs/base/common/async.js.map +1 -1
  61. package/esm/vs/base/common/buffer.js +1 -1
  62. package/esm/vs/base/common/buffer.js.map +1 -1
  63. package/esm/vs/base/common/cancellation.js.map +1 -1
  64. package/esm/vs/base/common/codiconsLibrary.js +3 -0
  65. package/esm/vs/base/common/codiconsLibrary.js.map +1 -1
  66. package/esm/vs/base/common/collections.js.map +1 -1
  67. package/esm/vs/base/common/equals.js.map +1 -1
  68. package/esm/vs/base/common/event.js +32 -15
  69. package/esm/vs/base/common/event.js.map +1 -1
  70. package/esm/vs/base/common/filters.js +22 -3
  71. package/esm/vs/base/common/filters.js.map +1 -1
  72. package/esm/vs/base/common/hotReload.js +2 -2
  73. package/esm/vs/base/common/hotReload.js.map +1 -1
  74. package/esm/vs/base/common/iterator.js +1 -1
  75. package/esm/vs/base/common/iterator.js.map +1 -1
  76. package/esm/vs/base/common/keyCodes.js +7 -6
  77. package/esm/vs/base/common/keyCodes.js.map +1 -1
  78. package/esm/vs/base/common/linkedList.js.map +1 -1
  79. package/esm/vs/base/common/map.js.map +1 -1
  80. package/esm/vs/base/common/marked/marked.js +0 -1
  81. package/esm/vs/base/common/network.js +26 -1
  82. package/esm/vs/base/common/network.js.map +1 -1
  83. package/esm/vs/base/common/normalization.js +19 -6
  84. package/esm/vs/base/common/normalization.js.map +1 -1
  85. package/esm/vs/base/common/observableInternal/debugLocation.js +1 -2
  86. package/esm/vs/base/common/observableInternal/debugLocation.js.map +1 -1
  87. package/esm/vs/base/common/observableInternal/debugName.js +0 -1
  88. package/esm/vs/base/common/observableInternal/debugName.js.map +1 -1
  89. package/esm/vs/base/common/observableInternal/index.js +4 -4
  90. package/esm/vs/base/common/observableInternal/index.js.map +1 -1
  91. package/esm/vs/base/common/observableInternal/logging/debugGetDependencyGraph.js +38 -10
  92. package/esm/vs/base/common/observableInternal/logging/debugGetDependencyGraph.js.map +1 -1
  93. package/esm/vs/base/common/observableInternal/observables/baseObservable.js +3 -3
  94. package/esm/vs/base/common/observableInternal/observables/baseObservable.js.map +1 -1
  95. package/esm/vs/base/common/observableInternal/utils/utils.js +46 -5
  96. package/esm/vs/base/common/observableInternal/utils/utils.js.map +1 -1
  97. package/esm/vs/base/common/path.js +1 -0
  98. package/esm/vs/base/common/path.js.map +1 -1
  99. package/esm/vs/base/common/strings.js +27 -19
  100. package/esm/vs/base/common/strings.js.map +1 -1
  101. package/esm/vs/editor/browser/config/elementSizeObserver.js +5 -5
  102. package/esm/vs/editor/browser/config/elementSizeObserver.js.map +1 -1
  103. package/esm/vs/editor/browser/config/fontMeasurements.js.map +1 -1
  104. package/esm/vs/editor/browser/config/migrateOptions.js +6 -0
  105. package/esm/vs/editor/browser/config/migrateOptions.js.map +1 -1
  106. package/esm/vs/editor/browser/config/tabFocus.js +4 -2
  107. package/esm/vs/editor/browser/config/tabFocus.js.map +1 -1
  108. package/esm/vs/editor/browser/controller/editContext/native/nativeEditContext.js +8 -0
  109. package/esm/vs/editor/browser/controller/editContext/native/nativeEditContext.js.map +1 -1
  110. package/esm/vs/editor/browser/coreCommands.js +1 -2
  111. package/esm/vs/editor/browser/coreCommands.js.map +1 -1
  112. package/esm/vs/editor/browser/editorBrowser.js.map +1 -1
  113. package/esm/vs/editor/browser/observableCodeEditor.js +32 -1
  114. package/esm/vs/editor/browser/observableCodeEditor.js.map +1 -1
  115. package/esm/vs/editor/browser/services/contribution.js +9 -0
  116. package/esm/vs/editor/browser/services/contribution.js.map +1 -0
  117. package/esm/vs/editor/browser/services/editorWorkerService.js +27 -14
  118. package/esm/vs/editor/browser/services/editorWorkerService.js.map +1 -1
  119. package/esm/vs/editor/browser/services/openerService.js +5 -1
  120. package/esm/vs/editor/browser/services/openerService.js.map +1 -1
  121. package/esm/vs/editor/browser/view/domLineBreaksComputer.js +1 -1
  122. package/esm/vs/editor/browser/view/domLineBreaksComputer.js.map +1 -1
  123. package/esm/vs/editor/browser/view/renderingContext.js +1 -1
  124. package/esm/vs/editor/browser/view/renderingContext.js.map +1 -1
  125. package/esm/vs/editor/browser/viewParts/currentLineHighlight/currentLineHighlight.js +10 -3
  126. package/esm/vs/editor/browser/viewParts/currentLineHighlight/currentLineHighlight.js.map +1 -1
  127. package/esm/vs/editor/browser/viewParts/glyphMargin/glyphMargin.js +3 -4
  128. package/esm/vs/editor/browser/viewParts/glyphMargin/glyphMargin.js.map +1 -1
  129. package/esm/vs/editor/browser/viewParts/minimap/minimap.js +1 -1
  130. package/esm/vs/editor/browser/viewParts/minimap/minimap.js.map +1 -1
  131. package/esm/vs/editor/browser/viewParts/overlayWidgets/overlayWidgets.js +1 -1
  132. package/esm/vs/editor/browser/viewParts/overlayWidgets/overlayWidgets.js.map +1 -1
  133. package/esm/vs/editor/browser/viewParts/overviewRuler/overviewRuler.js +4 -2
  134. package/esm/vs/editor/browser/viewParts/overviewRuler/overviewRuler.js.map +1 -1
  135. package/esm/vs/editor/browser/viewParts/rulers/rulers.js +1 -3
  136. package/esm/vs/editor/browser/viewParts/rulers/rulers.js.map +1 -1
  137. package/esm/vs/editor/browser/viewParts/scrollDecoration/scrollDecoration.js +1 -1
  138. package/esm/vs/editor/browser/viewParts/scrollDecoration/scrollDecoration.js.map +1 -1
  139. package/esm/vs/editor/browser/viewParts/viewLines/domReadingContext.js +2 -1
  140. package/esm/vs/editor/browser/viewParts/viewLines/domReadingContext.js.map +1 -1
  141. package/esm/vs/editor/browser/viewParts/viewLines/viewLines.js +6 -18
  142. package/esm/vs/editor/browser/viewParts/viewLines/viewLines.js.map +1 -1
  143. package/esm/vs/editor/browser/viewParts/whitespace/whitespace.js +0 -7
  144. package/esm/vs/editor/browser/viewParts/whitespace/whitespace.js.map +1 -1
  145. package/esm/vs/editor/browser/widget/codeEditor/codeEditorWidget.js +7 -2
  146. package/esm/vs/editor/browser/widget/codeEditor/codeEditorWidget.js.map +1 -1
  147. package/esm/vs/editor/browser/widget/diffEditor/features/hideUnchangedRegionsFeature.js +1 -0
  148. package/esm/vs/editor/browser/widget/diffEditor/features/hideUnchangedRegionsFeature.js.map +1 -1
  149. package/esm/vs/editor/common/commands/replaceCommand.js +2 -2
  150. package/esm/vs/editor/common/commands/replaceCommand.js.map +1 -1
  151. package/esm/vs/editor/common/config/editorOptions.js +374 -360
  152. package/esm/vs/editor/common/config/editorOptions.js.map +1 -1
  153. package/esm/vs/editor/common/core/2d/rect.js +7 -0
  154. package/esm/vs/editor/common/core/2d/rect.js.map +1 -1
  155. package/esm/vs/editor/common/core/2d/size.js +20 -0
  156. package/esm/vs/editor/common/core/2d/size.js.map +1 -0
  157. package/esm/vs/editor/common/core/editorColorRegistry.js +69 -68
  158. package/esm/vs/editor/common/core/editorColorRegistry.js.map +1 -1
  159. package/esm/vs/editor/common/core/ranges/offsetRange.js +9 -0
  160. package/esm/vs/editor/common/core/ranges/offsetRange.js.map +1 -1
  161. package/esm/vs/editor/common/cursor/cursorMoveCommands.js +4 -4
  162. package/esm/vs/editor/common/cursor/cursorMoveCommands.js.map +1 -1
  163. package/esm/vs/editor/common/editorContextKeys.js +47 -47
  164. package/esm/vs/editor/common/languages/modesRegistry.js +1 -1
  165. package/esm/vs/editor/common/languages.js +56 -56
  166. package/esm/vs/editor/common/languages.js.map +1 -1
  167. package/esm/vs/editor/common/model/editStack.js +1 -1
  168. package/esm/vs/editor/common/services/languagesAssociations.js +6 -8
  169. package/esm/vs/editor/common/services/languagesAssociations.js.map +1 -1
  170. package/esm/vs/editor/common/standaloneStrings.js +11 -10
  171. package/esm/vs/editor/common/standaloneStrings.js.map +1 -1
  172. package/esm/vs/editor/common/textModelEditSource.js +1 -1
  173. package/esm/vs/editor/common/textModelEditSource.js.map +1 -1
  174. package/esm/vs/editor/common/viewLayout/viewLineRenderer.js +2 -2
  175. package/esm/vs/editor/contrib/anchorSelect/browser/anchorSelect.js +6 -6
  176. package/esm/vs/editor/contrib/bracketMatching/browser/bracketMatching.js +6 -6
  177. package/esm/vs/editor/contrib/caretOperations/browser/caretOperations.js +2 -2
  178. package/esm/vs/editor/contrib/caretOperations/browser/transpose.js +1 -1
  179. package/esm/vs/editor/contrib/clipboard/browser/clipboard.js +17 -17
  180. package/esm/vs/editor/contrib/codeAction/browser/codeAction.js +1 -1
  181. package/esm/vs/editor/contrib/codeAction/browser/codeActionCommands.js +29 -29
  182. package/esm/vs/editor/contrib/codeAction/browser/codeActionContributions.js +3 -3
  183. package/esm/vs/editor/contrib/codeAction/browser/codeActionController.js +3 -3
  184. package/esm/vs/editor/contrib/codeAction/browser/codeActionMenu.js +8 -8
  185. package/esm/vs/editor/contrib/codeAction/browser/lightBulbWidget.js +9 -9
  186. package/esm/vs/editor/contrib/codelens/browser/codelens.js.map +1 -1
  187. package/esm/vs/editor/contrib/codelens/browser/codelensController.js +2 -2
  188. package/esm/vs/editor/contrib/codelens/browser/codelensController.js.map +1 -1
  189. package/esm/vs/editor/contrib/colorPicker/browser/colorPickerParts/colorPickerCloseButton.js +1 -1
  190. package/esm/vs/editor/contrib/colorPicker/browser/colorPickerParts/colorPickerHeader.js +1 -1
  191. package/esm/vs/editor/contrib/colorPicker/browser/hoverColorPicker/hoverColorPickerParticipant.js +1 -1
  192. package/esm/vs/editor/contrib/colorPicker/browser/standaloneColorPicker/standaloneColorPickerActions.js +7 -7
  193. package/esm/vs/editor/contrib/comment/browser/comment.js +6 -6
  194. package/esm/vs/editor/contrib/contextmenu/browser/contextmenu.js +10 -10
  195. package/esm/vs/editor/contrib/cursorUndo/browser/cursorUndo.js +2 -2
  196. package/esm/vs/editor/contrib/diffEditorBreadcrumbs/browser/contribution.js +14 -0
  197. package/esm/vs/editor/contrib/diffEditorBreadcrumbs/browser/contribution.js.map +1 -1
  198. package/esm/vs/editor/contrib/dropOrPasteInto/browser/copyPasteContribution.js +4 -4
  199. package/esm/vs/editor/contrib/dropOrPasteInto/browser/copyPasteController.js +9 -9
  200. package/esm/vs/editor/contrib/dropOrPasteInto/browser/defaultProviders.js +8 -8
  201. package/esm/vs/editor/contrib/dropOrPasteInto/browser/dropIntoEditorController.js +3 -3
  202. package/esm/vs/editor/contrib/dropOrPasteInto/browser/postEditWidget.js +2 -2
  203. package/esm/vs/editor/contrib/editorState/browser/keybindingCancellation.js +1 -1
  204. package/esm/vs/editor/contrib/find/browser/findController.js +17 -17
  205. package/esm/vs/editor/contrib/find/browser/findController.js.map +1 -1
  206. package/esm/vs/editor/contrib/find/browser/findWidget.js +26 -26
  207. package/esm/vs/editor/contrib/floatingMenu/browser/floatingMenu.css +1 -1
  208. package/esm/vs/editor/contrib/folding/browser/folding.js +20 -20
  209. package/esm/vs/editor/contrib/folding/browser/folding.js.map +1 -1
  210. package/esm/vs/editor/contrib/folding/browser/foldingDecorations.js +9 -9
  211. package/esm/vs/editor/contrib/fontZoom/browser/fontZoom.js +3 -3
  212. package/esm/vs/editor/contrib/format/browser/format.js +21 -6
  213. package/esm/vs/editor/contrib/format/browser/format.js.map +1 -1
  214. package/esm/vs/editor/contrib/format/browser/formatActions.js +2 -2
  215. package/esm/vs/editor/contrib/gotoError/browser/gotoError.js +8 -8
  216. package/esm/vs/editor/contrib/gotoError/browser/gotoErrorWidget.js +14 -14
  217. package/esm/vs/editor/contrib/gotoSymbol/browser/goToCommands.js +39 -39
  218. package/esm/vs/editor/contrib/gotoSymbol/browser/link/goToDefinitionAtPosition.js +1 -1
  219. package/esm/vs/editor/contrib/gotoSymbol/browser/peek/referencesController.js +3 -3
  220. package/esm/vs/editor/contrib/gotoSymbol/browser/peek/referencesTree.js +3 -3
  221. package/esm/vs/editor/contrib/gotoSymbol/browser/peek/referencesWidget.js +3 -3
  222. package/esm/vs/editor/contrib/gotoSymbol/browser/referencesModel.js +8 -8
  223. package/esm/vs/editor/contrib/gotoSymbol/browser/symbolNavigation.js +3 -3
  224. package/esm/vs/editor/contrib/gpu/browser/gpuActions.js +4 -4
  225. package/esm/vs/editor/contrib/hover/browser/contentHoverController.js +5 -10
  226. package/esm/vs/editor/contrib/hover/browser/contentHoverController.js.map +1 -1
  227. package/esm/vs/editor/contrib/hover/browser/glyphHoverController.js +11 -6
  228. package/esm/vs/editor/contrib/hover/browser/glyphHoverController.js.map +1 -1
  229. package/esm/vs/editor/contrib/hover/browser/hoverActionIds.js +2 -2
  230. package/esm/vs/editor/contrib/hover/browser/hoverActions.js +24 -24
  231. package/esm/vs/editor/contrib/hover/browser/hoverCopyButton.js +2 -2
  232. package/esm/vs/editor/contrib/hover/browser/hoverUtils.js +24 -0
  233. package/esm/vs/editor/contrib/hover/browser/hoverUtils.js.map +1 -1
  234. package/esm/vs/editor/contrib/hover/browser/markdownHoverParticipant.js +9 -9
  235. package/esm/vs/editor/contrib/hover/browser/markerHoverParticipant.js +5 -5
  236. package/esm/vs/editor/contrib/inPlaceReplace/browser/inPlaceReplace.js +2 -2
  237. package/esm/vs/editor/contrib/indentation/browser/indentation.js +20 -20
  238. package/esm/vs/editor/contrib/inlayHints/browser/inlayHintsHover.js +8 -8
  239. package/esm/vs/editor/contrib/inlineCompletions/browser/controller/commands.js +20 -20
  240. package/esm/vs/editor/contrib/inlineCompletions/browser/controller/inlineCompletionContextKeys.js +12 -12
  241. package/esm/vs/editor/contrib/inlineCompletions/browser/controller/inlineCompletionsController.js +18 -16
  242. package/esm/vs/editor/contrib/inlineCompletions/browser/controller/inlineCompletionsController.js.map +1 -1
  243. package/esm/vs/editor/contrib/inlineCompletions/browser/hintsWidget/hoverParticipant.js +2 -2
  244. package/esm/vs/editor/contrib/inlineCompletions/browser/hintsWidget/inlineCompletionsHintsWidget.js +5 -5
  245. package/esm/vs/editor/contrib/inlineCompletions/browser/model/inlineCompletionsModel.js +42 -37
  246. package/esm/vs/editor/contrib/inlineCompletions/browser/model/inlineCompletionsModel.js.map +1 -1
  247. package/esm/vs/editor/contrib/inlineCompletions/browser/model/inlineEdit.js +3 -3
  248. package/esm/vs/editor/contrib/inlineCompletions/browser/model/inlineEdit.js.map +1 -1
  249. package/esm/vs/editor/contrib/inlineCompletions/browser/model/inlineSuggestionItem.js +8 -8
  250. package/esm/vs/editor/contrib/inlineCompletions/browser/model/inlineSuggestionItem.js.map +1 -1
  251. package/esm/vs/editor/contrib/inlineCompletions/browser/view/ghostText/ghostTextView.js +54 -43
  252. package/esm/vs/editor/contrib/inlineCompletions/browser/view/ghostText/ghostTextView.js.map +1 -1
  253. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/components/gutterIndicatorMenu.js +12 -12
  254. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/components/gutterIndicatorMenu.js.map +1 -1
  255. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/components/gutterIndicatorView.js +74 -48
  256. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/components/gutterIndicatorView.js.map +1 -1
  257. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsModel.js +8 -36
  258. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsModel.js.map +1 -1
  259. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsNewUsers.js +10 -11
  260. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsNewUsers.js.map +1 -1
  261. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsView.js +105 -119
  262. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsView.js.map +1 -1
  263. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsViewInterface.js.map +1 -1
  264. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsViewProducer.js +8 -36
  265. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsViewProducer.js.map +1 -1
  266. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsViews/debugVisualization.js +95 -0
  267. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsViews/debugVisualization.js.map +1 -0
  268. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsViews/inlineEditsInsertionView.js +17 -9
  269. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsViews/inlineEditsInsertionView.js.map +1 -1
  270. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsViews/longDistanceHint/inlineEditsLongDistanceHint.js +415 -0
  271. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsViews/longDistanceHint/inlineEditsLongDistanceHint.js.map +1 -0
  272. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsViews/longDistanceHint/longDistancePreviewEditor.js +253 -0
  273. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/inlineEditsViews/longDistanceHint/longDistancePreviewEditor.js.map +1 -0
  274. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/theme.js +20 -20
  275. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/utils/flexBoxLayout.js +103 -0
  276. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/utils/flexBoxLayout.js.map +1 -0
  277. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/utils/towersLayout.js +32 -0
  278. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/utils/towersLayout.js.map +1 -0
  279. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/utils/utils.js +44 -11
  280. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineEdits/utils/utils.js.map +1 -1
  281. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineSuggestionsView.js +181 -0
  282. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineSuggestionsView.js.map +1 -0
  283. package/esm/vs/editor/contrib/insertFinalNewLine/browser/insertFinalNewLine.js +1 -1
  284. package/esm/vs/editor/contrib/lineSelection/browser/lineSelection.js +1 -1
  285. package/esm/vs/editor/contrib/linesOperations/browser/linesOperations.js +32 -31
  286. package/esm/vs/editor/contrib/linesOperations/browser/linesOperations.js.map +1 -1
  287. package/esm/vs/editor/contrib/linkedEditing/browser/linkedEditing.js +2 -2
  288. package/esm/vs/editor/contrib/links/browser/links.js +10 -10
  289. package/esm/vs/editor/contrib/message/browser/messageController.js +1 -1
  290. package/esm/vs/editor/contrib/multicursor/browser/multicursor.js +22 -22
  291. package/esm/vs/editor/contrib/parameterHints/browser/parameterHints.js +1 -1
  292. package/esm/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.js +4 -4
  293. package/esm/vs/editor/contrib/peekView/browser/peekView.js +18 -18
  294. package/esm/vs/editor/contrib/placeholderText/browser/placeholderText.contribution.js +1 -1
  295. package/esm/vs/editor/contrib/quickAccess/browser/editorNavigationQuickAccess.js +2 -2
  296. package/esm/vs/editor/contrib/quickAccess/browser/editorNavigationQuickAccess.js.map +1 -1
  297. package/esm/vs/editor/contrib/quickAccess/browser/gotoLineQuickAccess.js +18 -13
  298. package/esm/vs/editor/contrib/quickAccess/browser/gotoLineQuickAccess.js.map +1 -1
  299. package/esm/vs/editor/contrib/quickAccess/browser/gotoSymbolQuickAccess.js +32 -32
  300. package/esm/vs/editor/contrib/readOnlyMessage/browser/contribution.js +2 -2
  301. package/esm/vs/editor/contrib/rename/browser/rename.js +12 -12
  302. package/esm/vs/editor/contrib/rename/browser/rename.js.map +1 -1
  303. package/esm/vs/editor/contrib/rename/browser/renameWidget.js +7 -7
  304. package/esm/vs/editor/contrib/smartSelect/browser/smartSelect.js +4 -4
  305. package/esm/vs/editor/contrib/snippet/browser/snippetController2.js +4 -4
  306. package/esm/vs/editor/contrib/snippet/browser/snippetVariables.js +4 -4
  307. package/esm/vs/editor/contrib/stickyScroll/browser/stickyScrollActions.js +11 -11
  308. package/esm/vs/editor/contrib/stickyScroll/browser/stickyScrollWidget.js +1 -1
  309. package/esm/vs/editor/contrib/stickyScroll/browser/stickyScrollWidget.js.map +1 -1
  310. package/esm/vs/editor/contrib/suggest/browser/suggest.js +8 -8
  311. package/esm/vs/editor/contrib/suggest/browser/suggestController.js +10 -10
  312. package/esm/vs/editor/contrib/suggest/browser/suggestWidget.js +17 -17
  313. package/esm/vs/editor/contrib/suggest/browser/suggestWidgetDetails.js +2 -2
  314. package/esm/vs/editor/contrib/suggest/browser/suggestWidgetRenderer.js +2 -2
  315. package/esm/vs/editor/contrib/suggest/browser/wordContextKey.js +1 -1
  316. package/esm/vs/editor/contrib/symbolIcons/browser/symbolIcons.js +33 -33
  317. package/esm/vs/editor/contrib/toggleTabFocusMode/browser/toggleTabFocusMode.js +4 -4
  318. package/esm/vs/editor/contrib/tokenization/browser/tokenization.js +1 -1
  319. package/esm/vs/editor/contrib/unicodeHighlighter/browser/bannerController.js +1 -1
  320. package/esm/vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter.js +29 -29
  321. package/esm/vs/editor/contrib/unicodeHighlighter/browser/unicodeHighlighter.js.map +1 -1
  322. package/esm/vs/editor/contrib/unusualLineTerminators/browser/unusualLineTerminators.js +5 -5
  323. package/esm/vs/editor/contrib/wordHighlighter/browser/highlightDecorations.js +9 -9
  324. package/esm/vs/editor/contrib/wordHighlighter/browser/wordHighlighter.js +4 -4
  325. package/esm/vs/editor/contrib/wordHighlighter/browser/wordHighlighter.js.map +1 -1
  326. package/esm/vs/editor/contrib/wordOperations/browser/wordOperations.js +1 -1
  327. package/esm/vs/editor/editor.all.js +1 -0
  328. package/esm/vs/editor/editor.all.js.map +1 -1
  329. package/esm/vs/editor/editor.api.d.ts +9 -5
  330. package/esm/vs/editor/standalone/browser/quickAccess/standaloneGotoLineQuickAccess.js +22 -2
  331. package/esm/vs/editor/standalone/browser/quickAccess/standaloneGotoLineQuickAccess.js.map +1 -1
  332. package/esm/vs/editor/standalone/browser/services/standaloneWebWorkerService.js +39 -0
  333. package/esm/vs/editor/standalone/browser/services/standaloneWebWorkerService.js.map +1 -0
  334. package/esm/vs/editor/standalone/browser/standaloneEditor.js +2 -1
  335. package/esm/vs/editor/standalone/browser/standaloneEditor.js.map +1 -1
  336. package/esm/vs/editor/standalone/browser/standaloneServices.js +3 -21
  337. package/esm/vs/editor/standalone/browser/standaloneServices.js.map +1 -1
  338. package/esm/vs/editor/standalone/browser/standaloneWebWorker.js +4 -4
  339. package/esm/vs/editor/standalone/browser/standaloneWebWorker.js.map +1 -1
  340. package/esm/vs/platform/accessibilitySignal/browser/accessibilitySignalService.js +62 -62
  341. package/esm/vs/platform/action/common/actionCommonCategories.js +6 -6
  342. package/esm/vs/platform/actionWidget/browser/actionList.js +4 -4
  343. package/esm/vs/platform/actionWidget/browser/actionWidget.js +7 -7
  344. package/esm/vs/platform/actions/browser/menuEntryActionViewItem.js +7 -9
  345. package/esm/vs/platform/actions/browser/menuEntryActionViewItem.js.map +1 -1
  346. package/esm/vs/platform/actions/browser/toolbar.js +2 -2
  347. package/esm/vs/platform/actions/common/actions.js +2 -0
  348. package/esm/vs/platform/actions/common/actions.js.map +1 -1
  349. package/esm/vs/platform/actions/common/menuService.js +2 -2
  350. package/esm/vs/platform/configuration/common/configuration.js +5 -4
  351. package/esm/vs/platform/configuration/common/configuration.js.map +1 -1
  352. package/esm/vs/platform/configuration/common/configurationModels.js +21 -10
  353. package/esm/vs/platform/configuration/common/configurationModels.js.map +1 -1
  354. package/esm/vs/platform/configuration/common/configurationRegistry.js +10 -10
  355. package/esm/vs/platform/configuration/common/configurationRegistry.js.map +1 -1
  356. package/esm/vs/platform/configuration/common/configurations.js.map +1 -1
  357. package/esm/vs/platform/contextkey/browser/contextKeyService.js +3 -3
  358. package/esm/vs/platform/contextkey/browser/contextKeyService.js.map +1 -1
  359. package/esm/vs/platform/contextkey/common/contextkey.js +9 -9
  360. package/esm/vs/platform/contextkey/common/contextkeys.js +9 -9
  361. package/esm/vs/platform/contextkey/common/scanner.js +5 -5
  362. package/esm/vs/platform/contextview/browser/contextViewService.js.map +1 -1
  363. package/esm/vs/platform/history/browser/contextScopedHistoryWidget.js +1 -1
  364. package/esm/vs/platform/hover/browser/hoverWidget.js +1 -1
  365. package/esm/vs/platform/hover/browser/updatableHoverWidget.js +1 -1
  366. package/esm/vs/platform/keybinding/common/abstractKeybindingService.js +4 -4
  367. package/esm/vs/platform/list/browser/listService.js +27 -27
  368. package/esm/vs/platform/list/browser/listService.js.map +1 -1
  369. package/esm/vs/platform/markers/common/markerService.js +2 -2
  370. package/esm/vs/platform/markers/common/markers.js +6 -6
  371. package/esm/vs/platform/quickinput/browser/commandsQuickAccess.js +11 -32
  372. package/esm/vs/platform/quickinput/browser/commandsQuickAccess.js.map +1 -1
  373. package/esm/vs/platform/quickinput/browser/helpQuickAccess.js +1 -1
  374. package/esm/vs/platform/quickinput/browser/media/quickInput.css +9 -3
  375. package/esm/vs/platform/quickinput/browser/quickInput.js +10 -10
  376. package/esm/vs/platform/quickinput/browser/quickInputActions.js +5 -5
  377. package/esm/vs/platform/quickinput/browser/quickInputController.js +35 -14
  378. package/esm/vs/platform/quickinput/browser/quickInputController.js.map +1 -1
  379. package/esm/vs/platform/quickinput/browser/quickInputList.js +4 -1
  380. package/esm/vs/platform/quickinput/browser/quickInputList.js.map +1 -1
  381. package/esm/vs/platform/quickinput/browser/quickInputUtils.js +1 -1
  382. package/esm/vs/platform/quickinput/browser/tree/quickInputTreeAccessibilityProvider.js +1 -1
  383. package/esm/vs/platform/quickinput/browser/tree/quickInputTreeController.js +71 -40
  384. package/esm/vs/platform/quickinput/browser/tree/quickInputTreeController.js.map +1 -1
  385. package/esm/vs/platform/quickinput/browser/tree/quickInputTreeRenderer.js +21 -8
  386. package/esm/vs/platform/quickinput/browser/tree/quickInputTreeRenderer.js.map +1 -1
  387. package/esm/vs/platform/telemetry/common/gdprTypings.js.map +1 -1
  388. package/esm/vs/platform/telemetry/common/telemetry.js.map +1 -1
  389. package/esm/vs/platform/theme/common/colorUtils.js +2 -2
  390. package/esm/vs/platform/theme/common/colors/baseColors.js +17 -17
  391. package/esm/vs/platform/theme/common/colors/chartsColors.js +8 -8
  392. package/esm/vs/platform/theme/common/colors/editorColors.js +95 -95
  393. package/esm/vs/platform/theme/common/colors/editorColors.js.map +1 -1
  394. package/esm/vs/platform/theme/common/colors/inputColors.js +47 -47
  395. package/esm/vs/platform/theme/common/colors/listColors.js +36 -36
  396. package/esm/vs/platform/theme/common/colors/menuColors.js +7 -7
  397. package/esm/vs/platform/theme/common/colors/minimapColors.js +11 -11
  398. package/esm/vs/platform/theme/common/colors/miscColors.js +16 -16
  399. package/esm/vs/platform/theme/common/colors/miscColors.js.map +1 -1
  400. package/esm/vs/platform/theme/common/colors/quickpickColors.js +9 -9
  401. package/esm/vs/platform/theme/common/colors/searchColors.js +3 -3
  402. package/esm/vs/platform/theme/common/iconRegistry.js +6 -6
  403. package/esm/vs/platform/undoRedo/common/undoRedoService.js +20 -20
  404. package/esm/vs/platform/webWorker/browser/webWorkerDescriptor.js +12 -0
  405. package/esm/vs/platform/webWorker/browser/webWorkerDescriptor.js.map +1 -0
  406. package/esm/vs/platform/webWorker/browser/webWorkerService.js +7 -0
  407. package/esm/vs/platform/webWorker/browser/webWorkerService.js.map +1 -0
  408. package/esm/vs/{base/browser/webWorkerFactory.js → platform/webWorker/browser/webWorkerServiceImpl.js} +47 -66
  409. package/esm/vs/platform/webWorker/browser/webWorkerServiceImpl.js.map +1 -0
  410. package/esm/vs/platform/workspace/common/workspace.js +1 -1
  411. package/monaco.d.ts +9 -5
  412. package/package.json +2 -2
  413. package/esm/vs/base/browser/webWorkerFactory.js.map +0 -1
  414. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineCompletionsView.js +0 -82
  415. package/esm/vs/editor/contrib/inlineCompletions/browser/view/inlineCompletionsView.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"sources":["file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src/vs/editor/browser/viewParts/glyphMargin/glyphMargin.ts","vs/editor/browser/viewParts/glyphMargin/glyphMargin.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAEhG,OAAO,EAAe,iBAAiB,EAAE,MAAM,yCAAyC,CAAC;AACzF,OAAO,EAAE,UAAU,EAAE,MAAM,mCAAmC,CAAC;AAC/D,OAAO,mBAAmB,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AClB,SAAiB,EACjB,MAAc,EACd,MAAmB;QAHnB,eAAU,GAAV,UAAU,CAAQ;QAClB,cAAS,GAAT,SAAS,CAAQ;QACjB,WAAM,GAAN,MAAM,CAAQ;QACd,WAAM,GAAN,MAAM,CAAa;QANpB,SAAI,yCAAiC;IAOjD,CAAC;CACL;AAID,MAAM,oBAAoB;IACzB,YACiB,UAAkB,EAClB,SAAiB,EACjB,iBAAyB;QAFzB,eAAU,GAAV,UAAU,CAAQ;QAClB,cAAS,GAAT,SAAS,CAAQ;QACjB,sBAAiB,GAAjB,iBAAiB,CAAQ;IACtC,CAAC;CACL","file":"glyphMargin.js","sourceRoot":"file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport { FastDomNode, createFastDomNode } from '../../../../base/browser/fastDomNode.js';\nimport { ArrayQueue } from '../../../../base/common/arrays.js';\nimport './glyphMargin.css';\nimport { IGlyphMarginWidget, IGlyphMarginWidgetPosition } from '../../editorBrowser.js';\nimport { DynamicViewOverlay } from '../../view/dynamicViewOverlay.js';\nimport { RenderingContext, RestrictedRenderingContext } from '../../view/renderingContext.js';\nimport { ViewPart } from '../../view/viewPart.js';\nimport { EditorOption } from '../../../common/config/editorOptions.js';\nimport { Position } from '../../../common/core/position.js';\nimport { Range } from '../../../common/core/range.js';\nimport { GlyphMarginLane } from '../../../common/model.js';\nimport * as viewEvents from '../../../common/viewEvents.js';\nimport { ViewContext } from '../../../common/viewModel/viewContext.js';\n\n/**\n * Represents a decoration that should be shown along the lines from `startLineNumber` to `endLineNumber`.\n * This can end up producing multiple `LineDecorationToRender`.\n */\nexport class DecorationToRender {\n\tpublic readonly _decorationToRenderBrand: void = undefined;\n\n\tpublic readonly zIndex: number;\n\n\tconstructor(\n\t\tpublic readonly startLineNumber: number,\n\t\tpublic readonly endLineNumber: number,\n\t\tpublic readonly className: string,\n\t\tpublic readonly tooltip: string | null,\n\t\tzIndex: number | undefined,\n\t) {\n\t\tthis.zIndex = zIndex ?? 0;\n\t}\n}\n\n/**\n * A decoration that should be shown along a line.\n */\nexport class LineDecorationToRender {\n\tconstructor(\n\t\tpublic readonly className: string,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly tooltip: string | null,\n\t) { }\n}\n\n/**\n * Decorations to render on a visible line.\n */\nexport class VisibleLineDecorationsToRender {\n\n\tprivate readonly decorations: LineDecorationToRender[] = [];\n\n\tpublic add(decoration: LineDecorationToRender) {\n\t\tthis.decorations.push(decoration);\n\t}\n\n\tpublic getDecorations(): LineDecorationToRender[] {\n\t\treturn this.decorations;\n\t}\n}\n\nexport abstract class DedupOverlay extends DynamicViewOverlay {\n\n\t/**\n\t * Returns an array with an element for each visible line number.\n\t */\n\tprotected _render(visibleStartLineNumber: number, visibleEndLineNumber: number, decorations: DecorationToRender[]): VisibleLineDecorationsToRender[] {\n\n\t\tconst output: VisibleLineDecorationsToRender[] = [];\n\t\tfor (let lineNumber = visibleStartLineNumber; lineNumber <= visibleEndLineNumber; lineNumber++) {\n\t\t\tconst lineIndex = lineNumber - visibleStartLineNumber;\n\t\t\toutput[lineIndex] = new VisibleLineDecorationsToRender();\n\t\t}\n\n\t\tif (decorations.length === 0) {\n\t\t\treturn output;\n\t\t}\n\n\t\t// Sort decorations by className, then by startLineNumber and then by endLineNumber\n\t\tdecorations.sort((a, b) => {\n\t\t\tif (a.className === b.className) {\n\t\t\t\tif (a.startLineNumber === b.startLineNumber) {\n\t\t\t\t\treturn a.endLineNumber - b.endLineNumber;\n\t\t\t\t}\n\t\t\t\treturn a.startLineNumber - b.startLineNumber;\n\t\t\t}\n\t\t\treturn (a.className < b.className ? -1 : 1);\n\t\t});\n\n\t\tlet prevClassName: string | null = null;\n\t\tlet prevEndLineIndex = 0;\n\t\tfor (let i = 0, len = decorations.length; i < len; i++) {\n\t\t\tconst d = decorations[i];\n\t\t\tconst className = d.className;\n\t\t\tconst zIndex = d.zIndex;\n\t\t\tlet startLineIndex = Math.max(d.startLineNumber, visibleStartLineNumber) - visibleStartLineNumber;\n\t\t\tconst endLineIndex = Math.min(d.endLineNumber, visibleEndLineNumber) - visibleStartLineNumber;\n\n\t\t\tif (prevClassName === className) {\n\t\t\t\t// Here we avoid rendering the same className multiple times on the same line\n\t\t\t\tstartLineIndex = Math.max(prevEndLineIndex + 1, startLineIndex);\n\t\t\t\tprevEndLineIndex = Math.max(prevEndLineIndex, endLineIndex);\n\t\t\t} else {\n\t\t\t\tprevClassName = className;\n\t\t\t\tprevEndLineIndex = endLineIndex;\n\t\t\t}\n\n\t\t\tfor (let i = startLineIndex; i <= prevEndLineIndex; i++) {\n\t\t\t\toutput[i].add(new LineDecorationToRender(className, zIndex, d.tooltip));\n\t\t\t}\n\t\t}\n\n\t\treturn output;\n\t}\n}\n\nexport class GlyphMarginWidgets extends ViewPart {\n\n\tpublic domNode: FastDomNode<HTMLElement>;\n\n\tprivate _lineHeight: number;\n\tprivate _glyphMargin: boolean;\n\tprivate _glyphMarginLeft: number;\n\tprivate _glyphMarginWidth: number;\n\tprivate _glyphMarginDecorationLaneCount: number;\n\n\tprivate _managedDomNodes: FastDomNode<HTMLElement>[];\n\tprivate _decorationGlyphsToRender: DecorationBasedGlyph[];\n\n\tprivate _widgets: { [key: string]: IWidgetData } = {};\n\n\tconstructor(context: ViewContext) {\n\t\tsuper(context);\n\t\tthis._context = context;\n\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis.domNode = createFastDomNode(document.createElement('div'));\n\t\tthis.domNode.setClassName('glyph-margin-widgets');\n\t\tthis.domNode.setPosition('absolute');\n\t\tthis.domNode.setTop(0);\n\n\t\tthis._lineHeight = options.get(EditorOption.lineHeight);\n\t\tthis._glyphMargin = options.get(EditorOption.glyphMargin);\n\t\tthis._glyphMarginLeft = layoutInfo.glyphMarginLeft;\n\t\tthis._glyphMarginWidth = layoutInfo.glyphMarginWidth;\n\t\tthis._glyphMarginDecorationLaneCount = layoutInfo.glyphMarginDecorationLaneCount;\n\t\tthis._managedDomNodes = [];\n\t\tthis._decorationGlyphsToRender = [];\n\t}\n\n\tpublic override dispose(): void {\n\t\tthis._managedDomNodes = [];\n\t\tthis._decorationGlyphsToRender = [];\n\t\tthis._widgets = {};\n\t\tsuper.dispose();\n\t}\n\n\tpublic getWidgets(): IWidgetData[] {\n\t\treturn Object.values(this._widgets);\n\t}\n\n\t// --- begin event handlers\n\tpublic override onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean {\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis._lineHeight = options.get(EditorOption.lineHeight);\n\t\tthis._glyphMargin = options.get(EditorOption.glyphMargin);\n\t\tthis._glyphMarginLeft = layoutInfo.glyphMarginLeft;\n\t\tthis._glyphMarginWidth = layoutInfo.glyphMarginWidth;\n\t\tthis._glyphMarginDecorationLaneCount = layoutInfo.glyphMarginDecorationLaneCount;\n\t\treturn true;\n\t}\n\tpublic override onDecorationsChanged(e: viewEvents.ViewDecorationsChangedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onFlushed(e: viewEvents.ViewFlushedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesChanged(e: viewEvents.ViewLinesChangedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesDeleted(e: viewEvents.ViewLinesDeletedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesInserted(e: viewEvents.ViewLinesInsertedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onScrollChanged(e: viewEvents.ViewScrollChangedEvent): boolean {\n\t\treturn e.scrollTopChanged;\n\t}\n\tpublic override onZonesChanged(e: viewEvents.ViewZonesChangedEvent): boolean {\n\t\treturn true;\n\t}\n\n\t// --- end event handlers\n\n\t// --- begin widget management\n\n\tpublic addWidget(widget: IGlyphMarginWidget): void {\n\t\tconst domNode = createFastDomNode(widget.getDomNode());\n\n\t\tthis._widgets[widget.getId()] = {\n\t\t\twidget: widget,\n\t\t\tpreference: widget.getPosition(),\n\t\t\tdomNode: domNode,\n\t\t\trenderInfo: null\n\t\t};\n\n\t\tdomNode.setPosition('absolute');\n\t\tdomNode.setDisplay('none');\n\t\tdomNode.setAttribute('widgetId', widget.getId());\n\t\tthis.domNode.appendChild(domNode);\n\n\t\tthis.setShouldRender();\n\t}\n\n\tpublic setWidgetPosition(widget: IGlyphMarginWidget, preference: IGlyphMarginWidgetPosition): boolean {\n\t\tconst myWidget = this._widgets[widget.getId()];\n\t\tif (myWidget.preference.lane === preference.lane\n\t\t\t&& myWidget.preference.zIndex === preference.zIndex\n\t\t\t&& Range.equalsRange(myWidget.preference.range, preference.range)) {\n\t\t\treturn false;\n\t\t}\n\n\t\tmyWidget.preference = preference;\n\t\tthis.setShouldRender();\n\n\t\treturn true;\n\t}\n\n\tpublic removeWidget(widget: IGlyphMarginWidget): void {\n\t\tconst widgetId = widget.getId();\n\t\tif (this._widgets[widgetId]) {\n\t\t\tconst widgetData = this._widgets[widgetId];\n\t\t\tconst domNode = widgetData.domNode.domNode;\n\t\t\tdelete this._widgets[widgetId];\n\n\t\t\tdomNode.remove();\n\t\t\tthis.setShouldRender();\n\t\t}\n\t}\n\n\t// --- end widget management\n\n\tprivate _collectDecorationBasedGlyphRenderRequest(ctx: RenderingContext, requests: GlyphRenderRequest[]): void {\n\t\tconst visibleStartLineNumber = ctx.visibleRange.startLineNumber;\n\t\tconst visibleEndLineNumber = ctx.visibleRange.endLineNumber;\n\t\tconst decorations = ctx.getDecorationsInViewport();\n\n\t\tfor (const d of decorations) {\n\t\t\tconst glyphMarginClassName = d.options.glyphMarginClassName;\n\t\t\tif (!glyphMarginClassName) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tconst startLineNumber = Math.max(d.range.startLineNumber, visibleStartLineNumber);\n\t\t\tconst endLineNumber = Math.min(d.range.endLineNumber, visibleEndLineNumber);\n\t\t\tconst lane = d.options.glyphMargin?.position ?? GlyphMarginLane.Center;\n\t\t\tconst zIndex = d.options.zIndex ?? 0;\n\n\t\t\tfor (let lineNumber = startLineNumber; lineNumber <= endLineNumber; lineNumber++) {\n\t\t\t\tconst modelPosition = this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Position(lineNumber, 0));\n\t\t\t\tconst laneIndex = this._context.viewModel.glyphLanes.getLanesAtLine(modelPosition.lineNumber).indexOf(lane);\n\t\t\t\trequests.push(new DecorationBasedGlyphRenderRequest(lineNumber, laneIndex, zIndex, glyphMarginClassName));\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate _collectWidgetBasedGlyphRenderRequest(ctx: RenderingContext, requests: GlyphRenderRequest[]): void {\n\t\tconst visibleStartLineNumber = ctx.visibleRange.startLineNumber;\n\t\tconst visibleEndLineNumber = ctx.visibleRange.endLineNumber;\n\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\tconst range = widget.preference.range;\n\t\t\tconst { startLineNumber, endLineNumber } = this._context.viewModel.coordinatesConverter.convertModelRangeToViewRange(Range.lift(range));\n\t\t\tif (!startLineNumber || !endLineNumber || endLineNumber < visibleStartLineNumber || startLineNumber > visibleEndLineNumber) {\n\t\t\t\t// The widget is not in the viewport\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t// The widget is in the viewport, find a good line for it\n\t\t\tconst widgetLineNumber = Math.max(startLineNumber, visibleStartLineNumber);\n\t\t\tconst modelPosition = this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Position(widgetLineNumber, 0));\n\t\t\tconst laneIndex = this._context.viewModel.glyphLanes.getLanesAtLine(modelPosition.lineNumber).indexOf(widget.preference.lane);\n\t\t\trequests.push(new WidgetBasedGlyphRenderRequest(widgetLineNumber, laneIndex, widget.preference.zIndex, widget));\n\t\t}\n\t}\n\n\tprivate _collectSortedGlyphRenderRequests(ctx: RenderingContext): GlyphRenderRequest[] {\n\n\t\tconst requests: GlyphRenderRequest[] = [];\n\n\t\tthis._collectDecorationBasedGlyphRenderRequest(ctx, requests);\n\t\tthis._collectWidgetBasedGlyphRenderRequest(ctx, requests);\n\n\t\t// sort requests by lineNumber ASC, lane ASC, zIndex DESC, type DESC (widgets first), className ASC\n\t\t// don't change this sort unless you understand `prepareRender` below.\n\t\trequests.sort((a, b) => {\n\t\t\tif (a.lineNumber === b.lineNumber) {\n\t\t\t\tif (a.laneIndex === b.laneIndex) {\n\t\t\t\t\tif (a.zIndex === b.zIndex) {\n\t\t\t\t\t\tif (b.type === a.type) {\n\t\t\t\t\t\t\tif (a.type === GlyphRenderRequestType.Decoration && b.type === GlyphRenderRequestType.Decoration) {\n\t\t\t\t\t\t\t\treturn (a.className < b.className ? -1 : 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\treturn 0;\n\t\t\t\t\t\t}\n\t\t\t\t\t\treturn b.type - a.type;\n\t\t\t\t\t}\n\t\t\t\t\treturn b.zIndex - a.zIndex;\n\t\t\t\t}\n\t\t\t\treturn a.laneIndex - b.laneIndex;\n\t\t\t}\n\t\t\treturn a.lineNumber - b.lineNumber;\n\t\t});\n\n\t\treturn requests;\n\t}\n\n\t/**\n\t * Will store render information in each widget's renderInfo and in `_decorationGlyphsToRender`.\n\t */\n\tpublic prepareRender(ctx: RenderingContext): void {\n\t\tif (!this._glyphMargin) {\n\t\t\tthis._decorationGlyphsToRender = [];\n\t\t\treturn;\n\t\t}\n\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\twidget.renderInfo = null;\n\t\t}\n\n\t\tconst requests = new ArrayQueue<GlyphRenderRequest>(this._collectSortedGlyphRenderRequests(ctx));\n\t\tconst decorationGlyphsToRender: DecorationBasedGlyph[] = [];\n\t\twhile (requests.length > 0) {\n\t\t\tconst first = requests.peek();\n\t\t\tif (!first) {\n\t\t\t\t// not possible\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// Requests are sorted by lineNumber and lane, so we read all requests for this particular location\n\t\t\tconst requestsAtLocation = requests.takeWhile((el) => el.lineNumber === first.lineNumber && el.laneIndex === first.laneIndex);\n\t\t\tif (!requestsAtLocation || requestsAtLocation.length === 0) {\n\t\t\t\t// not possible\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst winner = requestsAtLocation[0];\n\t\t\tif (winner.type === GlyphRenderRequestType.Decoration) {\n\t\t\t\t// combine all decorations with the same z-index\n\n\t\t\t\tconst classNames: string[] = [];\n\t\t\t\t// requests are sorted by zIndex, type, and className so we can dedup className by looking at the previous one\n\t\t\t\tfor (const request of requestsAtLocation) {\n\t\t\t\t\tif (request.zIndex !== winner.zIndex || request.type !== winner.type) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tif (classNames.length === 0 || classNames[classNames.length - 1] !== request.className) {\n\t\t\t\t\t\tclassNames.push(request.className);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tdecorationGlyphsToRender.push(winner.accept(classNames.join(' '))); // TODO@joyceerhl Implement overflow for remaining decorations\n\t\t\t} else {\n\t\t\t\t// widgets cannot be combined\n\t\t\t\twinner.widget.renderInfo = {\n\t\t\t\t\tlineNumber: winner.lineNumber,\n\t\t\t\t\tlaneIndex: winner.laneIndex,\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t\tthis._decorationGlyphsToRender = decorationGlyphsToRender;\n\t}\n\n\tpublic render(ctx: RestrictedRenderingContext): void {\n\t\tif (!this._glyphMargin) {\n\t\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\t\twidget.domNode.setDisplay('none');\n\t\t\t}\n\t\t\twhile (this._managedDomNodes.length > 0) {\n\t\t\t\tconst domNode = this._managedDomNodes.pop();\n\t\t\t\tdomNode?.domNode.remove();\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\n\t\tconst width = (Math.round(this._glyphMarginWidth / this._glyphMarginDecorationLaneCount));\n\n\t\t// Render widgets\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\tif (!widget.renderInfo) {\n\t\t\t\t// this widget is not visible\n\t\t\t\twidget.domNode.setDisplay('none');\n\t\t\t} else {\n\t\t\t\tconst top = ctx.viewportData.relativeVerticalOffset[widget.renderInfo.lineNumber - ctx.viewportData.startLineNumber];\n\t\t\t\tconst left = this._glyphMarginLeft + widget.renderInfo.laneIndex * this._lineHeight;\n\n\t\t\t\twidget.domNode.setDisplay('block');\n\t\t\t\twidget.domNode.setTop(top);\n\t\t\t\twidget.domNode.setLeft(left);\n\t\t\t\twidget.domNode.setWidth(width);\n\t\t\t\twidget.domNode.setHeight(this._lineHeight);\n\t\t\t}\n\t\t}\n\n\t\t// Render decorations, reusing previous dom nodes as possible\n\t\tfor (let i = 0; i < this._decorationGlyphsToRender.length; i++) {\n\t\t\tconst dec = this._decorationGlyphsToRender[i];\n\t\t\tconst decLineNumber = dec.lineNumber;\n\t\t\tconst top = ctx.viewportData.relativeVerticalOffset[decLineNumber - ctx.viewportData.startLineNumber];\n\t\t\tconst left = this._glyphMarginLeft + dec.laneIndex * this._lineHeight;\n\n\t\t\tlet domNode: FastDomNode<HTMLElement>;\n\t\t\tif (i < this._managedDomNodes.length) {\n\t\t\t\tdomNode = this._managedDomNodes[i];\n\t\t\t} else {\n\t\t\t\tdomNode = createFastDomNode(document.createElement('div'));\n\t\t\t\tthis._managedDomNodes.push(domNode);\n\t\t\t\tthis.domNode.appendChild(domNode);\n\t\t\t}\n\t\t\tconst lineHeight = this._context.viewLayout.getLineHeightForLineNumber(decLineNumber);\n\n\t\t\tdomNode.setClassName(`cgmr codicon ` + dec.combinedClassName);\n\t\t\tdomNode.setPosition(`absolute`);\n\t\t\tdomNode.setTop(top);\n\t\t\tdomNode.setLeft(left);\n\t\t\tdomNode.setWidth(width);\n\t\t\tdomNode.setHeight(lineHeight);\n\t\t}\n\n\t\t// remove extra dom nodes\n\t\twhile (this._managedDomNodes.length > this._decorationGlyphsToRender.length) {\n\t\t\tconst domNode = this._managedDomNodes.pop();\n\t\t\tdomNode?.domNode.remove();\n\t\t}\n\t}\n}\n\nexport interface IWidgetData {\n\twidget: IGlyphMarginWidget;\n\tpreference: IGlyphMarginWidgetPosition;\n\tdomNode: FastDomNode<HTMLElement>;\n\t/**\n\t * it will contain the location where to render the widget\n\t * or null if the widget is not visible\n\t */\n\trenderInfo: IRenderInfo | null;\n}\n\nexport interface IRenderInfo {\n\tlineNumber: number;\n\tlaneIndex: number;\n}\n\nconst enum GlyphRenderRequestType {\n\tDecoration = 0,\n\tWidget = 1\n}\n\n/**\n * A request to render a decoration in the glyph margin at a certain location.\n */\nclass DecorationBasedGlyphRenderRequest {\n\tpublic readonly type = GlyphRenderRequestType.Decoration;\n\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly className: string,\n\t) { }\n\n\taccept(combinedClassName: string): DecorationBasedGlyph {\n\t\treturn new DecorationBasedGlyph(this.lineNumber, this.laneIndex, combinedClassName);\n\t}\n}\n\n/**\n * A request to render a widget in the glyph margin at a certain location.\n */\nclass WidgetBasedGlyphRenderRequest {\n\tpublic readonly type = GlyphRenderRequestType.Widget;\n\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly widget: IWidgetData,\n\t) { }\n}\n\ntype GlyphRenderRequest = DecorationBasedGlyphRenderRequest | WidgetBasedGlyphRenderRequest;\n\nclass DecorationBasedGlyph {\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly combinedClassName: string\n\t) { }\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 *--------------------------------------------------------------------------------------------*/\n\nimport { FastDomNode, createFastDomNode } from '../../../../base/browser/fastDomNode.js';\nimport { ArrayQueue } from '../../../../base/common/arrays.js';\nimport './glyphMargin.css';\nimport { IGlyphMarginWidget, IGlyphMarginWidgetPosition } from '../../editorBrowser.js';\nimport { DynamicViewOverlay } from '../../view/dynamicViewOverlay.js';\nimport { RenderingContext, RestrictedRenderingContext } from '../../view/renderingContext.js';\nimport { ViewPart } from '../../view/viewPart.js';\nimport { EditorOption } from '../../../common/config/editorOptions.js';\nimport { Position } from '../../../common/core/position.js';\nimport { Range } from '../../../common/core/range.js';\nimport { GlyphMarginLane } from '../../../common/model.js';\nimport * as viewEvents from '../../../common/viewEvents.js';\nimport { ViewContext } from '../../../common/viewModel/viewContext.js';\n\n/**\n * Represents a decoration that should be shown along the lines from `startLineNumber` to `endLineNumber`.\n * This can end up producing multiple `LineDecorationToRender`.\n */\nexport class DecorationToRender {\n\tpublic readonly _decorationToRenderBrand: void = undefined;\n\n\tpublic readonly zIndex: number;\n\n\tconstructor(\n\t\tpublic readonly startLineNumber: number,\n\t\tpublic readonly endLineNumber: number,\n\t\tpublic readonly className: string,\n\t\tpublic readonly tooltip: string | null,\n\t\tzIndex: number | undefined,\n\t) {\n\t\tthis.zIndex = zIndex ?? 0;\n\t}\n}\n\n/**\n * A decoration that should be shown along a line.\n */\nexport class LineDecorationToRender {\n\tconstructor(\n\t\tpublic readonly className: string,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly tooltip: string | null,\n\t) { }\n}\n\n/**\n * Decorations to render on a visible line.\n */\nexport class VisibleLineDecorationsToRender {\n\n\tprivate readonly decorations: LineDecorationToRender[] = [];\n\n\tpublic add(decoration: LineDecorationToRender) {\n\t\tthis.decorations.push(decoration);\n\t}\n\n\tpublic getDecorations(): LineDecorationToRender[] {\n\t\treturn this.decorations;\n\t}\n}\n\nexport abstract class DedupOverlay extends DynamicViewOverlay {\n\n\t/**\n\t * Returns an array with an element for each visible line number.\n\t */\n\tprotected _render(visibleStartLineNumber: number, visibleEndLineNumber: number, decorations: DecorationToRender[]): VisibleLineDecorationsToRender[] {\n\n\t\tconst output: VisibleLineDecorationsToRender[] = [];\n\t\tfor (let lineNumber = visibleStartLineNumber; lineNumber <= visibleEndLineNumber; lineNumber++) {\n\t\t\tconst lineIndex = lineNumber - visibleStartLineNumber;\n\t\t\toutput[lineIndex] = new VisibleLineDecorationsToRender();\n\t\t}\n\n\t\tif (decorations.length === 0) {\n\t\t\treturn output;\n\t\t}\n\n\t\t// Sort decorations by className, then by startLineNumber and then by endLineNumber\n\t\tdecorations.sort((a, b) => {\n\t\t\tif (a.className === b.className) {\n\t\t\t\tif (a.startLineNumber === b.startLineNumber) {\n\t\t\t\t\treturn a.endLineNumber - b.endLineNumber;\n\t\t\t\t}\n\t\t\t\treturn a.startLineNumber - b.startLineNumber;\n\t\t\t}\n\t\t\treturn (a.className < b.className ? -1 : 1);\n\t\t});\n\n\t\tlet prevClassName: string | null = null;\n\t\tlet prevEndLineIndex = 0;\n\t\tfor (let i = 0, len = decorations.length; i < len; i++) {\n\t\t\tconst d = decorations[i];\n\t\t\tconst className = d.className;\n\t\t\tconst zIndex = d.zIndex;\n\t\t\tlet startLineIndex = Math.max(d.startLineNumber, visibleStartLineNumber) - visibleStartLineNumber;\n\t\t\tconst endLineIndex = Math.min(d.endLineNumber, visibleEndLineNumber) - visibleStartLineNumber;\n\n\t\t\tif (prevClassName === className) {\n\t\t\t\t// Here we avoid rendering the same className multiple times on the same line\n\t\t\t\tstartLineIndex = Math.max(prevEndLineIndex + 1, startLineIndex);\n\t\t\t\tprevEndLineIndex = Math.max(prevEndLineIndex, endLineIndex);\n\t\t\t} else {\n\t\t\t\tprevClassName = className;\n\t\t\t\tprevEndLineIndex = endLineIndex;\n\t\t\t}\n\n\t\t\tfor (let i = startLineIndex; i <= prevEndLineIndex; i++) {\n\t\t\t\toutput[i].add(new LineDecorationToRender(className, zIndex, d.tooltip));\n\t\t\t}\n\t\t}\n\n\t\treturn output;\n\t}\n}\n\nexport class GlyphMarginWidgets extends ViewPart {\n\n\tpublic domNode: FastDomNode<HTMLElement>;\n\n\tprivate _lineHeight: number;\n\tprivate _glyphMargin: boolean;\n\tprivate _glyphMarginLeft: number;\n\tprivate _glyphMarginWidth: number;\n\tprivate _glyphMarginDecorationLaneCount: number;\n\n\tprivate _managedDomNodes: FastDomNode<HTMLElement>[];\n\tprivate _decorationGlyphsToRender: DecorationBasedGlyph[];\n\n\tprivate _widgets: { [key: string]: IWidgetData } = {};\n\n\tconstructor(context: ViewContext) {\n\t\tsuper(context);\n\t\tthis._context = context;\n\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis.domNode = createFastDomNode(document.createElement('div'));\n\t\tthis.domNode.setClassName('glyph-margin-widgets');\n\t\tthis.domNode.setPosition('absolute');\n\t\tthis.domNode.setTop(0);\n\n\t\tthis._lineHeight = options.get(EditorOption.lineHeight);\n\t\tthis._glyphMargin = options.get(EditorOption.glyphMargin);\n\t\tthis._glyphMarginLeft = layoutInfo.glyphMarginLeft;\n\t\tthis._glyphMarginWidth = layoutInfo.glyphMarginWidth;\n\t\tthis._glyphMarginDecorationLaneCount = layoutInfo.glyphMarginDecorationLaneCount;\n\t\tthis._managedDomNodes = [];\n\t\tthis._decorationGlyphsToRender = [];\n\t}\n\n\tpublic override dispose(): void {\n\t\tthis._managedDomNodes = [];\n\t\tthis._decorationGlyphsToRender = [];\n\t\tthis._widgets = {};\n\t\tsuper.dispose();\n\t}\n\n\tpublic getWidgets(): IWidgetData[] {\n\t\treturn Object.values(this._widgets);\n\t}\n\n\t// --- begin event handlers\n\tpublic override onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean {\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis._lineHeight = options.get(EditorOption.lineHeight);\n\t\tthis._glyphMargin = options.get(EditorOption.glyphMargin);\n\t\tthis._glyphMarginLeft = layoutInfo.glyphMarginLeft;\n\t\tthis._glyphMarginWidth = layoutInfo.glyphMarginWidth;\n\t\tthis._glyphMarginDecorationLaneCount = layoutInfo.glyphMarginDecorationLaneCount;\n\t\treturn true;\n\t}\n\tpublic override onDecorationsChanged(e: viewEvents.ViewDecorationsChangedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onFlushed(e: viewEvents.ViewFlushedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesChanged(e: viewEvents.ViewLinesChangedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesDeleted(e: viewEvents.ViewLinesDeletedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesInserted(e: viewEvents.ViewLinesInsertedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onScrollChanged(e: viewEvents.ViewScrollChangedEvent): boolean {\n\t\treturn e.scrollTopChanged;\n\t}\n\tpublic override onZonesChanged(e: viewEvents.ViewZonesChangedEvent): boolean {\n\t\treturn true;\n\t}\n\n\t// --- end event handlers\n\n\t// --- begin widget management\n\n\tpublic addWidget(widget: IGlyphMarginWidget): void {\n\t\tconst domNode = createFastDomNode(widget.getDomNode());\n\n\t\tthis._widgets[widget.getId()] = {\n\t\t\twidget: widget,\n\t\t\tpreference: widget.getPosition(),\n\t\t\tdomNode: domNode,\n\t\t\trenderInfo: null\n\t\t};\n\n\t\tdomNode.setPosition('absolute');\n\t\tdomNode.setDisplay('none');\n\t\tdomNode.setAttribute('widgetId', widget.getId());\n\t\tthis.domNode.appendChild(domNode);\n\n\t\tthis.setShouldRender();\n\t}\n\n\tpublic setWidgetPosition(widget: IGlyphMarginWidget, preference: IGlyphMarginWidgetPosition): boolean {\n\t\tconst myWidget = this._widgets[widget.getId()];\n\t\tif (myWidget.preference.lane === preference.lane\n\t\t\t&& myWidget.preference.zIndex === preference.zIndex\n\t\t\t&& Range.equalsRange(myWidget.preference.range, preference.range)) {\n\t\t\treturn false;\n\t\t}\n\n\t\tmyWidget.preference = preference;\n\t\tthis.setShouldRender();\n\n\t\treturn true;\n\t}\n\n\tpublic removeWidget(widget: IGlyphMarginWidget): void {\n\t\tconst widgetId = widget.getId();\n\t\tif (this._widgets[widgetId]) {\n\t\t\tconst widgetData = this._widgets[widgetId];\n\t\t\tconst domNode = widgetData.domNode.domNode;\n\t\t\tdelete this._widgets[widgetId];\n\n\t\t\tdomNode.remove();\n\t\t\tthis.setShouldRender();\n\t\t}\n\t}\n\n\t// --- end widget management\n\n\tprivate _collectDecorationBasedGlyphRenderRequest(ctx: RenderingContext, requests: GlyphRenderRequest[]): void {\n\t\tconst visibleStartLineNumber = ctx.visibleRange.startLineNumber;\n\t\tconst visibleEndLineNumber = ctx.visibleRange.endLineNumber;\n\t\tconst decorations = ctx.getDecorationsInViewport();\n\n\t\tfor (const d of decorations) {\n\t\t\tconst glyphMarginClassName = d.options.glyphMarginClassName;\n\t\t\tif (!glyphMarginClassName) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tconst startLineNumber = Math.max(d.range.startLineNumber, visibleStartLineNumber);\n\t\t\tconst endLineNumber = Math.min(d.range.endLineNumber, visibleEndLineNumber);\n\t\t\tconst lane = d.options.glyphMargin?.position ?? GlyphMarginLane.Center;\n\t\t\tconst zIndex = d.options.zIndex ?? 0;\n\n\t\t\tfor (let lineNumber = startLineNumber; lineNumber <= endLineNumber; lineNumber++) {\n\t\t\t\tconst modelPosition = this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Position(lineNumber, 0));\n\t\t\t\tconst laneIndex = this._context.viewModel.glyphLanes.getLanesAtLine(modelPosition.lineNumber).indexOf(lane);\n\t\t\t\trequests.push(new DecorationBasedGlyphRenderRequest(lineNumber, laneIndex, zIndex, glyphMarginClassName));\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate _collectWidgetBasedGlyphRenderRequest(ctx: RenderingContext, requests: GlyphRenderRequest[]): void {\n\t\tconst visibleStartLineNumber = ctx.visibleRange.startLineNumber;\n\t\tconst visibleEndLineNumber = ctx.visibleRange.endLineNumber;\n\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\tconst range = widget.preference.range;\n\t\t\tconst { startLineNumber, endLineNumber } = this._context.viewModel.coordinatesConverter.convertModelRangeToViewRange(Range.lift(range));\n\t\t\tif (!startLineNumber || !endLineNumber || endLineNumber < visibleStartLineNumber || startLineNumber > visibleEndLineNumber) {\n\t\t\t\t// The widget is not in the viewport\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t// The widget is in the viewport, find a good line for it\n\t\t\tconst widgetLineNumber = Math.max(startLineNumber, visibleStartLineNumber);\n\t\t\tconst modelPosition = this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Position(widgetLineNumber, 0));\n\t\t\tconst laneIndex = this._context.viewModel.glyphLanes.getLanesAtLine(modelPosition.lineNumber).indexOf(widget.preference.lane);\n\t\t\trequests.push(new WidgetBasedGlyphRenderRequest(widgetLineNumber, laneIndex, widget.preference.zIndex, widget));\n\t\t}\n\t}\n\n\tprivate _collectSortedGlyphRenderRequests(ctx: RenderingContext): GlyphRenderRequest[] {\n\n\t\tconst requests: GlyphRenderRequest[] = [];\n\n\t\tthis._collectDecorationBasedGlyphRenderRequest(ctx, requests);\n\t\tthis._collectWidgetBasedGlyphRenderRequest(ctx, requests);\n\n\t\t// sort requests by lineNumber ASC, lane ASC, zIndex DESC, type DESC (widgets first), className ASC\n\t\t// don't change this sort unless you understand `prepareRender` below.\n\t\trequests.sort((a, b) => {\n\t\t\tif (a.lineNumber === b.lineNumber) {\n\t\t\t\tif (a.laneIndex === b.laneIndex) {\n\t\t\t\t\tif (a.zIndex === b.zIndex) {\n\t\t\t\t\t\tif (b.type === a.type) {\n\t\t\t\t\t\t\tif (a.type === GlyphRenderRequestType.Decoration && b.type === GlyphRenderRequestType.Decoration) {\n\t\t\t\t\t\t\t\treturn (a.className < b.className ? -1 : 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\treturn 0;\n\t\t\t\t\t\t}\n\t\t\t\t\t\treturn b.type - a.type;\n\t\t\t\t\t}\n\t\t\t\t\treturn b.zIndex - a.zIndex;\n\t\t\t\t}\n\t\t\t\treturn a.laneIndex - b.laneIndex;\n\t\t\t}\n\t\t\treturn a.lineNumber - b.lineNumber;\n\t\t});\n\n\t\treturn requests;\n\t}\n\n\t/**\n\t * Will store render information in each widget's renderInfo and in `_decorationGlyphsToRender`.\n\t */\n\tpublic prepareRender(ctx: RenderingContext): void {\n\t\tif (!this._glyphMargin) {\n\t\t\tthis._decorationGlyphsToRender = [];\n\t\t\treturn;\n\t\t}\n\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\twidget.renderInfo = null;\n\t\t}\n\n\t\tconst requests = new ArrayQueue<GlyphRenderRequest>(this._collectSortedGlyphRenderRequests(ctx));\n\t\tconst decorationGlyphsToRender: DecorationBasedGlyph[] = [];\n\t\twhile (requests.length > 0) {\n\t\t\tconst first = requests.peek();\n\t\t\tif (!first) {\n\t\t\t\t// not possible\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// Requests are sorted by lineNumber and lane, so we read all requests for this particular location\n\t\t\tconst requestsAtLocation = requests.takeWhile((el) => el.lineNumber === first.lineNumber && el.laneIndex === first.laneIndex);\n\t\t\tif (!requestsAtLocation || requestsAtLocation.length === 0) {\n\t\t\t\t// not possible\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst winner = requestsAtLocation[0];\n\t\t\tif (winner.type === GlyphRenderRequestType.Decoration) {\n\t\t\t\t// combine all decorations with the same z-index\n\n\t\t\t\tconst classNames: string[] = [];\n\t\t\t\t// requests are sorted by zIndex, type, and className so we can dedup className by looking at the previous one\n\t\t\t\tfor (const request of requestsAtLocation) {\n\t\t\t\t\tif (request.zIndex !== winner.zIndex || request.type !== winner.type) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tif (classNames.length === 0 || classNames[classNames.length - 1] !== request.className) {\n\t\t\t\t\t\tclassNames.push(request.className);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tdecorationGlyphsToRender.push(winner.accept(classNames.join(' '))); // TODO@joyceerhl Implement overflow for remaining decorations\n\t\t\t} else {\n\t\t\t\t// widgets cannot be combined\n\t\t\t\twinner.widget.renderInfo = {\n\t\t\t\t\tlineNumber: winner.lineNumber,\n\t\t\t\t\tlaneIndex: winner.laneIndex,\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t\tthis._decorationGlyphsToRender = decorationGlyphsToRender;\n\t}\n\n\tpublic render(ctx: RestrictedRenderingContext): void {\n\t\tif (!this._glyphMargin) {\n\t\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\t\twidget.domNode.setDisplay('none');\n\t\t\t}\n\t\t\twhile (this._managedDomNodes.length > 0) {\n\t\t\t\tconst domNode = this._managedDomNodes.pop();\n\t\t\t\tdomNode?.domNode.remove();\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\n\t\tconst width = (Math.round(this._glyphMarginWidth / this._glyphMarginDecorationLaneCount));\n\n\t\t// Render widgets\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\tif (!widget.renderInfo) {\n\t\t\t\t// this widget is not visible\n\t\t\t\twidget.domNode.setDisplay('none');\n\t\t\t} else {\n\t\t\t\tconst top = ctx.viewportData.relativeVerticalOffset[widget.renderInfo.lineNumber - ctx.viewportData.startLineNumber];\n\t\t\t\tconst left = this._glyphMarginLeft + widget.renderInfo.laneIndex * this._lineHeight;\n\n\t\t\t\twidget.domNode.setDisplay('block');\n\t\t\t\twidget.domNode.setTop(top);\n\t\t\t\twidget.domNode.setLeft(left);\n\t\t\t\twidget.domNode.setWidth(width);\n\t\t\t\twidget.domNode.setHeight(this._lineHeight);\n\t\t\t}\n\t\t}\n\n\t\t// Render decorations, reusing previous dom nodes as possible\n\t\tfor (let i = 0; i < this._decorationGlyphsToRender.length; i++) {\n\t\t\tconst dec = this._decorationGlyphsToRender[i];\n\t\t\tconst decLineNumber = dec.lineNumber;\n\t\t\tconst top = ctx.viewportData.relativeVerticalOffset[decLineNumber - ctx.viewportData.startLineNumber];\n\t\t\tconst left = this._glyphMarginLeft + dec.laneIndex * this._lineHeight;\n\n\t\t\tlet domNode: FastDomNode<HTMLElement>;\n\t\t\tif (i < this._managedDomNodes.length) {\n\t\t\t\tdomNode = this._managedDomNodes[i];\n\t\t\t} else {\n\t\t\t\tdomNode = createFastDomNode(document.createElement('div'));\n\t\t\t\tthis._managedDomNodes.push(domNode);\n\t\t\t\tthis.domNode.appendChild(domNode);\n\t\t\t}\n\t\t\tconst lineHeight = this._context.viewLayout.getLineHeightForLineNumber(decLineNumber);\n\n\t\t\tdomNode.setClassName(`cgmr codicon ` + dec.combinedClassName);\n\t\t\tdomNode.setPosition(`absolute`);\n\t\t\tdomNode.setTop(top);\n\t\t\tdomNode.setLeft(left);\n\t\t\tdomNode.setWidth(width);\n\t\t\tdomNode.setHeight(lineHeight);\n\t\t}\n\n\t\t// remove extra dom nodes\n\t\twhile (this._managedDomNodes.length > this._decorationGlyphsToRender.length) {\n\t\t\tconst domNode = this._managedDomNodes.pop();\n\t\t\tdomNode?.domNode.remove();\n\t\t}\n\t}\n}\n\nexport interface IWidgetData {\n\twidget: IGlyphMarginWidget;\n\tpreference: IGlyphMarginWidgetPosition;\n\tdomNode: FastDomNode<HTMLElement>;\n\t/**\n\t * it will contain the location where to render the widget\n\t * or null if the widget is not visible\n\t */\n\trenderInfo: IRenderInfo | null;\n}\n\nexport interface IRenderInfo {\n\tlineNumber: number;\n\tlaneIndex: number;\n}\n\nconst enum GlyphRenderRequestType {\n\tDecoration = 0,\n\tWidget = 1\n}\n\n/**\n * A request to render a decoration in the glyph margin at a certain location.\n */\nclass DecorationBasedGlyphRenderRequest {\n\tpublic readonly type = GlyphRenderRequestType.Decoration;\n\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly className: string,\n\t) { }\n\n\taccept(combinedClassName: string): DecorationBasedGlyph {\n\t\treturn new DecorationBasedGlyph(this.lineNumber, this.laneIndex, combinedClassName);\n\t}\n}\n\n/**\n * A request to render a widget in the glyph margin at a certain location.\n */\nclass WidgetBasedGlyphRenderRequest {\n\tpublic readonly type = GlyphRenderRequestType.Widget;\n\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly widget: IWidgetData,\n\t) { }\n}\n\ntype GlyphRenderRequest = DecorationBasedGlyphRenderRequest | WidgetBasedGlyphRenderRequest;\n\nclass DecorationBasedGlyph {\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly combinedClassName: string\n\t) { }\n}\n"]}
1
+ {"version":3,"sources":["file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src/vs/editor/browser/viewParts/glyphMargin/glyphMargin.ts","vs/editor/browser/viewParts/glyphMargin/glyphMargin.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAEhG,OAAO,EAAe,iBAAiB,EAAE,MAAM,yCAAyC,CAAC;AACzF,OAAO,EAAE,UAAU,EAAE,MAAM,mCAAmC,CAAC;AAC/D,OAAO,mBAAmB,CAAC;AAE3B,OAAO,EAAE,kBAAkB,EAAE,MAAM,kCAAkC,CAAC;AAEtE,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAElD,OAAO,EAAE,QAAQ,EAAE,MAAM,kCAAkC,CAAC;AAC5D,OAAO,EAAE,KAAK,EAAE,MAAM,+BAA+B,CAAC;AACtD,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAI3D;;;GAGG;AACH,MAAM,OAAO,kBAAkB;IAK9B,YACiB,eAAuB,EACvB,aAAqB,EACrB,SAAiB,EACjB,OAAsB,EACtC,MAA0B;QAJV,oBAAe,GAAf,eAAe,CAAQ;QACvB,kBAAa,GAAb,aAAa,CAAQ;QACrB,cAAS,GAAT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I,CAAC,yBAAyB,CAAC,MAAM,EAAE,CAAC;YAC7E,MAAM,OAAO,GAAG,IAAI,CAAC,gBAAgB,CAAC,GAAG,EAAE,CAAC;YAC5C,OAAO,EAAE,OAAO,CAAC,MAAM,EAAE,CAAC;QAC3B,CAAC;IACF,CAAC;CACD;AAuBD;;GAEG;AACH,MAAM,iCAAiC;IAGtC,YACiB,UAAkB,EAClB,SAAiB,EACjB,MAAc,EACd,SAAiB;QAHjB,eAAU,GAAV,UAAU,CAAQ;QAClB,cAAS,GAAT,SAAS,CAAQ;QACjB,WAAM,GAAN,MAAM,CAAQ;QACd,cAAS,GAAT,SAAS,CAAQ;QANlB,SAAI,6CAAqC;IAOrD,CAAC;IAEL,MAAM,CAAC,iBAAyB;QAC/B,OAAO,IAAI,oBAAoB,CAAC,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,SAAS,EAAE,iBAAiB,CAAC,CAAC;IACrF,CAAC;CACD;AAED;;GAEG;AACH,MAAM,6BAA6B;IAGlC,YACiB,UAAkB,EAClB,SAAiB,EACjB,MAAc,EACd,MAAmB;QAHnB,eAAU,GAAV,UAAU,CAAQ;QAClB,cAAS,GAAT,SAAS,CAAQ;QACjB,WAAM,GAAN,MAAM,CAAQ;QACd,WAAM,GAAN,MAAM,CAAa;QANpB,SAAI,yCAAiC;IAOjD,CAAC;CACL;AAID,MAAM,oBAAoB;IACzB,YACiB,UAAkB,EAClB,SAAiB,EACjB,iBAAyB;QAFzB,eAAU,GAAV,UAAU,CAAQ;QAClB,cAAS,GAAT,SAAS,CAAQ;QACjB,sBAAiB,GAAjB,iBAAiB,CAAQ;IACtC,CAAC;CACL","file":"glyphMargin.js","sourceRoot":"file:///mnt/vss/_work/1/s/dependencies/vscode/out-editor-src","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for license information.\n *--------------------------------------------------------------------------------------------*/\n\nimport { FastDomNode, createFastDomNode } from '../../../../base/browser/fastDomNode.js';\nimport { ArrayQueue } from '../../../../base/common/arrays.js';\nimport './glyphMargin.css';\nimport { IGlyphMarginWidget, IGlyphMarginWidgetPosition } from '../../editorBrowser.js';\nimport { DynamicViewOverlay } from '../../view/dynamicViewOverlay.js';\nimport { RenderingContext, RestrictedRenderingContext } from '../../view/renderingContext.js';\nimport { ViewPart } from '../../view/viewPart.js';\nimport { EditorOption } from '../../../common/config/editorOptions.js';\nimport { Position } from '../../../common/core/position.js';\nimport { Range } from '../../../common/core/range.js';\nimport { GlyphMarginLane } from '../../../common/model.js';\nimport * as viewEvents from '../../../common/viewEvents.js';\nimport { ViewContext } from '../../../common/viewModel/viewContext.js';\n\n/**\n * Represents a decoration that should be shown along the lines from `startLineNumber` to `endLineNumber`.\n * This can end up producing multiple `LineDecorationToRender`.\n */\nexport class DecorationToRender {\n\tpublic readonly _decorationToRenderBrand: void = undefined;\n\n\tpublic readonly zIndex: number;\n\n\tconstructor(\n\t\tpublic readonly startLineNumber: number,\n\t\tpublic readonly endLineNumber: number,\n\t\tpublic readonly className: string,\n\t\tpublic readonly tooltip: string | null,\n\t\tzIndex: number | undefined,\n\t) {\n\t\tthis.zIndex = zIndex ?? 0;\n\t}\n}\n\n/**\n * A decoration that should be shown along a line.\n */\nexport class LineDecorationToRender {\n\tconstructor(\n\t\tpublic readonly className: string,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly tooltip: string | null,\n\t) { }\n}\n\n/**\n * Decorations to render on a visible line.\n */\nexport class VisibleLineDecorationsToRender {\n\n\tprivate readonly decorations: LineDecorationToRender[] = [];\n\n\tpublic add(decoration: LineDecorationToRender) {\n\t\tthis.decorations.push(decoration);\n\t}\n\n\tpublic getDecorations(): LineDecorationToRender[] {\n\t\treturn this.decorations;\n\t}\n}\n\nexport abstract class DedupOverlay extends DynamicViewOverlay {\n\n\t/**\n\t * Returns an array with an element for each visible line number.\n\t */\n\tprotected _render(visibleStartLineNumber: number, visibleEndLineNumber: number, decorations: DecorationToRender[]): VisibleLineDecorationsToRender[] {\n\n\t\tconst output: VisibleLineDecorationsToRender[] = [];\n\t\tfor (let lineNumber = visibleStartLineNumber; lineNumber <= visibleEndLineNumber; lineNumber++) {\n\t\t\tconst lineIndex = lineNumber - visibleStartLineNumber;\n\t\t\toutput[lineIndex] = new VisibleLineDecorationsToRender();\n\t\t}\n\n\t\tif (decorations.length === 0) {\n\t\t\treturn output;\n\t\t}\n\n\t\t// Sort decorations by className, then by startLineNumber and then by endLineNumber\n\t\tdecorations.sort((a, b) => {\n\t\t\tif (a.className === b.className) {\n\t\t\t\tif (a.startLineNumber === b.startLineNumber) {\n\t\t\t\t\treturn a.endLineNumber - b.endLineNumber;\n\t\t\t\t}\n\t\t\t\treturn a.startLineNumber - b.startLineNumber;\n\t\t\t}\n\t\t\treturn (a.className < b.className ? -1 : 1);\n\t\t});\n\n\t\tlet prevClassName: string | null = null;\n\t\tlet prevEndLineIndex = 0;\n\t\tfor (const d of decorations) {\n\t\t\tconst className = d.className;\n\t\t\tconst zIndex = d.zIndex;\n\t\t\tlet startLineIndex = Math.max(d.startLineNumber, visibleStartLineNumber) - visibleStartLineNumber;\n\t\t\tconst endLineIndex = Math.min(d.endLineNumber, visibleEndLineNumber) - visibleStartLineNumber;\n\n\t\t\tif (prevClassName === className) {\n\t\t\t\t// Here we avoid rendering the same className multiple times on the same line\n\t\t\t\tstartLineIndex = Math.max(prevEndLineIndex + 1, startLineIndex);\n\t\t\t\tprevEndLineIndex = Math.max(prevEndLineIndex, endLineIndex);\n\t\t\t} else {\n\t\t\t\tprevClassName = className;\n\t\t\t\tprevEndLineIndex = endLineIndex;\n\t\t\t}\n\n\t\t\tfor (let lineIndex = startLineIndex; lineIndex <= prevEndLineIndex; lineIndex++) {\n\t\t\t\toutput[lineIndex].add(new LineDecorationToRender(className, zIndex, d.tooltip));\n\t\t\t}\n\t\t}\n\n\t\treturn output;\n\t}\n}\n\nexport class GlyphMarginWidgets extends ViewPart {\n\n\tpublic domNode: FastDomNode<HTMLElement>;\n\n\tprivate _lineHeight: number;\n\tprivate _glyphMargin: boolean;\n\tprivate _glyphMarginLeft: number;\n\tprivate _glyphMarginWidth: number;\n\tprivate _glyphMarginDecorationLaneCount: number;\n\n\tprivate _managedDomNodes: FastDomNode<HTMLElement>[];\n\tprivate _decorationGlyphsToRender: DecorationBasedGlyph[];\n\n\tprivate _widgets: { [key: string]: IWidgetData } = {};\n\n\tconstructor(context: ViewContext) {\n\t\tsuper(context);\n\t\tthis._context = context;\n\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis.domNode = createFastDomNode(document.createElement('div'));\n\t\tthis.domNode.setClassName('glyph-margin-widgets');\n\t\tthis.domNode.setPosition('absolute');\n\t\tthis.domNode.setTop(0);\n\n\t\tthis._lineHeight = options.get(EditorOption.lineHeight);\n\t\tthis._glyphMargin = options.get(EditorOption.glyphMargin);\n\t\tthis._glyphMarginLeft = layoutInfo.glyphMarginLeft;\n\t\tthis._glyphMarginWidth = layoutInfo.glyphMarginWidth;\n\t\tthis._glyphMarginDecorationLaneCount = layoutInfo.glyphMarginDecorationLaneCount;\n\t\tthis._managedDomNodes = [];\n\t\tthis._decorationGlyphsToRender = [];\n\t}\n\n\tpublic override dispose(): void {\n\t\tthis._managedDomNodes = [];\n\t\tthis._decorationGlyphsToRender = [];\n\t\tthis._widgets = {};\n\t\tsuper.dispose();\n\t}\n\n\tpublic getWidgets(): IWidgetData[] {\n\t\treturn Object.values(this._widgets);\n\t}\n\n\t// --- begin event handlers\n\tpublic override onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean {\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis._lineHeight = options.get(EditorOption.lineHeight);\n\t\tthis._glyphMargin = options.get(EditorOption.glyphMargin);\n\t\tthis._glyphMarginLeft = layoutInfo.glyphMarginLeft;\n\t\tthis._glyphMarginWidth = layoutInfo.glyphMarginWidth;\n\t\tthis._glyphMarginDecorationLaneCount = layoutInfo.glyphMarginDecorationLaneCount;\n\t\treturn true;\n\t}\n\tpublic override onDecorationsChanged(e: viewEvents.ViewDecorationsChangedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onFlushed(e: viewEvents.ViewFlushedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesChanged(e: viewEvents.ViewLinesChangedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesDeleted(e: viewEvents.ViewLinesDeletedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesInserted(e: viewEvents.ViewLinesInsertedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onScrollChanged(e: viewEvents.ViewScrollChangedEvent): boolean {\n\t\treturn e.scrollTopChanged;\n\t}\n\tpublic override onZonesChanged(e: viewEvents.ViewZonesChangedEvent): boolean {\n\t\treturn true;\n\t}\n\n\t// --- end event handlers\n\n\t// --- begin widget management\n\n\tpublic addWidget(widget: IGlyphMarginWidget): void {\n\t\tconst domNode = createFastDomNode(widget.getDomNode());\n\n\t\tthis._widgets[widget.getId()] = {\n\t\t\twidget: widget,\n\t\t\tpreference: widget.getPosition(),\n\t\t\tdomNode: domNode,\n\t\t\trenderInfo: null\n\t\t};\n\n\t\tdomNode.setPosition('absolute');\n\t\tdomNode.setDisplay('none');\n\t\tdomNode.setAttribute('widgetId', widget.getId());\n\t\tthis.domNode.appendChild(domNode);\n\n\t\tthis.setShouldRender();\n\t}\n\n\tpublic setWidgetPosition(widget: IGlyphMarginWidget, preference: IGlyphMarginWidgetPosition): boolean {\n\t\tconst myWidget = this._widgets[widget.getId()];\n\t\tif (myWidget.preference.lane === preference.lane\n\t\t\t&& myWidget.preference.zIndex === preference.zIndex\n\t\t\t&& Range.equalsRange(myWidget.preference.range, preference.range)) {\n\t\t\treturn false;\n\t\t}\n\n\t\tmyWidget.preference = preference;\n\t\tthis.setShouldRender();\n\n\t\treturn true;\n\t}\n\n\tpublic removeWidget(widget: IGlyphMarginWidget): void {\n\t\tconst widgetId = widget.getId();\n\t\tif (this._widgets[widgetId]) {\n\t\t\tconst widgetData = this._widgets[widgetId];\n\t\t\tconst domNode = widgetData.domNode.domNode;\n\t\t\tdelete this._widgets[widgetId];\n\n\t\t\tdomNode.remove();\n\t\t\tthis.setShouldRender();\n\t\t}\n\t}\n\n\t// --- end widget management\n\n\tprivate _collectDecorationBasedGlyphRenderRequest(ctx: RenderingContext, requests: GlyphRenderRequest[]): void {\n\t\tconst visibleStartLineNumber = ctx.visibleRange.startLineNumber;\n\t\tconst visibleEndLineNumber = ctx.visibleRange.endLineNumber;\n\t\tconst decorations = ctx.getDecorationsInViewport();\n\n\t\tfor (const d of decorations) {\n\t\t\tconst glyphMarginClassName = d.options.glyphMarginClassName;\n\t\t\tif (!glyphMarginClassName) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tconst startLineNumber = Math.max(d.range.startLineNumber, visibleStartLineNumber);\n\t\t\tconst endLineNumber = Math.min(d.range.endLineNumber, visibleEndLineNumber);\n\t\t\tconst lane = d.options.glyphMargin?.position ?? GlyphMarginLane.Center;\n\t\t\tconst zIndex = d.options.zIndex ?? 0;\n\n\t\t\tfor (let lineNumber = startLineNumber; lineNumber <= endLineNumber; lineNumber++) {\n\t\t\t\tconst modelPosition = this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Position(lineNumber, 0));\n\t\t\t\tconst laneIndex = this._context.viewModel.glyphLanes.getLanesAtLine(modelPosition.lineNumber).indexOf(lane);\n\t\t\t\trequests.push(new DecorationBasedGlyphRenderRequest(lineNumber, laneIndex, zIndex, glyphMarginClassName));\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate _collectWidgetBasedGlyphRenderRequest(ctx: RenderingContext, requests: GlyphRenderRequest[]): void {\n\t\tconst visibleStartLineNumber = ctx.visibleRange.startLineNumber;\n\t\tconst visibleEndLineNumber = ctx.visibleRange.endLineNumber;\n\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\tconst range = widget.preference.range;\n\t\t\tconst { startLineNumber, endLineNumber } = this._context.viewModel.coordinatesConverter.convertModelRangeToViewRange(Range.lift(range));\n\t\t\tif (!startLineNumber || !endLineNumber || endLineNumber < visibleStartLineNumber || startLineNumber > visibleEndLineNumber) {\n\t\t\t\t// The widget is not in the viewport\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t// The widget is in the viewport, find a good line for it\n\t\t\tconst widgetLineNumber = Math.max(startLineNumber, visibleStartLineNumber);\n\t\t\tconst modelPosition = this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Position(widgetLineNumber, 0));\n\t\t\tconst laneIndex = this._context.viewModel.glyphLanes.getLanesAtLine(modelPosition.lineNumber).indexOf(widget.preference.lane);\n\t\t\trequests.push(new WidgetBasedGlyphRenderRequest(widgetLineNumber, laneIndex, widget.preference.zIndex, widget));\n\t\t}\n\t}\n\n\tprivate _collectSortedGlyphRenderRequests(ctx: RenderingContext): GlyphRenderRequest[] {\n\n\t\tconst requests: GlyphRenderRequest[] = [];\n\n\t\tthis._collectDecorationBasedGlyphRenderRequest(ctx, requests);\n\t\tthis._collectWidgetBasedGlyphRenderRequest(ctx, requests);\n\n\t\t// sort requests by lineNumber ASC, lane ASC, zIndex DESC, type DESC (widgets first), className ASC\n\t\t// don't change this sort unless you understand `prepareRender` below.\n\t\trequests.sort((a, b) => {\n\t\t\tif (a.lineNumber === b.lineNumber) {\n\t\t\t\tif (a.laneIndex === b.laneIndex) {\n\t\t\t\t\tif (a.zIndex === b.zIndex) {\n\t\t\t\t\t\tif (b.type === a.type) {\n\t\t\t\t\t\t\tif (a.type === GlyphRenderRequestType.Decoration && b.type === GlyphRenderRequestType.Decoration) {\n\t\t\t\t\t\t\t\treturn (a.className < b.className ? -1 : 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\treturn 0;\n\t\t\t\t\t\t}\n\t\t\t\t\t\treturn b.type - a.type;\n\t\t\t\t\t}\n\t\t\t\t\treturn b.zIndex - a.zIndex;\n\t\t\t\t}\n\t\t\t\treturn a.laneIndex - b.laneIndex;\n\t\t\t}\n\t\t\treturn a.lineNumber - b.lineNumber;\n\t\t});\n\n\t\treturn requests;\n\t}\n\n\t/**\n\t * Will store render information in each widget's renderInfo and in `_decorationGlyphsToRender`.\n\t */\n\tpublic prepareRender(ctx: RenderingContext): void {\n\t\tif (!this._glyphMargin) {\n\t\t\tthis._decorationGlyphsToRender = [];\n\t\t\treturn;\n\t\t}\n\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\twidget.renderInfo = null;\n\t\t}\n\n\t\tconst requests = new ArrayQueue<GlyphRenderRequest>(this._collectSortedGlyphRenderRequests(ctx));\n\t\tconst decorationGlyphsToRender: DecorationBasedGlyph[] = [];\n\t\twhile (requests.length > 0) {\n\t\t\tconst first = requests.peek();\n\t\t\tif (!first) {\n\t\t\t\t// not possible\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// Requests are sorted by lineNumber and lane, so we read all requests for this particular location\n\t\t\tconst requestsAtLocation = requests.takeWhile((el) => el.lineNumber === first.lineNumber && el.laneIndex === first.laneIndex);\n\t\t\tif (!requestsAtLocation || requestsAtLocation.length === 0) {\n\t\t\t\t// not possible\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst winner = requestsAtLocation[0];\n\t\t\tif (winner.type === GlyphRenderRequestType.Decoration) {\n\t\t\t\t// combine all decorations with the same z-index\n\n\t\t\t\tconst classNames: string[] = [];\n\t\t\t\t// requests are sorted by zIndex, type, and className so we can dedup className by looking at the previous one\n\t\t\t\tfor (const request of requestsAtLocation) {\n\t\t\t\t\tif (request.zIndex !== winner.zIndex || request.type !== winner.type) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tif (classNames.length === 0 || classNames[classNames.length - 1] !== request.className) {\n\t\t\t\t\t\tclassNames.push(request.className);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tdecorationGlyphsToRender.push(winner.accept(classNames.join(' '))); // TODO@joyceerhl Implement overflow for remaining decorations\n\t\t\t} else {\n\t\t\t\t// widgets cannot be combined\n\t\t\t\twinner.widget.renderInfo = {\n\t\t\t\t\tlineNumber: winner.lineNumber,\n\t\t\t\t\tlaneIndex: winner.laneIndex,\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t\tthis._decorationGlyphsToRender = decorationGlyphsToRender;\n\t}\n\n\tpublic render(ctx: RestrictedRenderingContext): void {\n\t\tif (!this._glyphMargin) {\n\t\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\t\twidget.domNode.setDisplay('none');\n\t\t\t}\n\t\t\twhile (this._managedDomNodes.length > 0) {\n\t\t\t\tconst domNode = this._managedDomNodes.pop();\n\t\t\t\tdomNode?.domNode.remove();\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\n\t\tconst width = (Math.round(this._glyphMarginWidth / this._glyphMarginDecorationLaneCount));\n\n\t\t// Render widgets\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\tif (!widget.renderInfo) {\n\t\t\t\t// this widget is not visible\n\t\t\t\twidget.domNode.setDisplay('none');\n\t\t\t} else {\n\t\t\t\tconst top = ctx.viewportData.relativeVerticalOffset[widget.renderInfo.lineNumber - ctx.viewportData.startLineNumber];\n\t\t\t\tconst left = this._glyphMarginLeft + widget.renderInfo.laneIndex * this._lineHeight;\n\n\t\t\t\twidget.domNode.setDisplay('block');\n\t\t\t\twidget.domNode.setTop(top);\n\t\t\t\twidget.domNode.setLeft(left);\n\t\t\t\twidget.domNode.setWidth(width);\n\t\t\t\twidget.domNode.setHeight(this._lineHeight);\n\t\t\t}\n\t\t}\n\n\t\t// Render decorations, reusing previous dom nodes as possible\n\t\tfor (let i = 0; i < this._decorationGlyphsToRender.length; i++) {\n\t\t\tconst dec = this._decorationGlyphsToRender[i];\n\t\t\tconst decLineNumber = dec.lineNumber;\n\t\t\tconst top = ctx.viewportData.relativeVerticalOffset[decLineNumber - ctx.viewportData.startLineNumber];\n\t\t\tconst left = this._glyphMarginLeft + dec.laneIndex * this._lineHeight;\n\n\t\t\tlet domNode: FastDomNode<HTMLElement>;\n\t\t\tif (i < this._managedDomNodes.length) {\n\t\t\t\tdomNode = this._managedDomNodes[i];\n\t\t\t} else {\n\t\t\t\tdomNode = createFastDomNode(document.createElement('div'));\n\t\t\t\tthis._managedDomNodes.push(domNode);\n\t\t\t\tthis.domNode.appendChild(domNode);\n\t\t\t}\n\t\t\tconst lineHeight = this._context.viewLayout.getLineHeightForLineNumber(decLineNumber);\n\n\t\t\tdomNode.setClassName(`cgmr codicon ` + dec.combinedClassName);\n\t\t\tdomNode.setPosition(`absolute`);\n\t\t\tdomNode.setTop(top);\n\t\t\tdomNode.setLeft(left);\n\t\t\tdomNode.setWidth(width);\n\t\t\tdomNode.setHeight(lineHeight);\n\t\t}\n\n\t\t// remove extra dom nodes\n\t\twhile (this._managedDomNodes.length > this._decorationGlyphsToRender.length) {\n\t\t\tconst domNode = this._managedDomNodes.pop();\n\t\t\tdomNode?.domNode.remove();\n\t\t}\n\t}\n}\n\nexport interface IWidgetData {\n\twidget: IGlyphMarginWidget;\n\tpreference: IGlyphMarginWidgetPosition;\n\tdomNode: FastDomNode<HTMLElement>;\n\t/**\n\t * it will contain the location where to render the widget\n\t * or null if the widget is not visible\n\t */\n\trenderInfo: IRenderInfo | null;\n}\n\nexport interface IRenderInfo {\n\tlineNumber: number;\n\tlaneIndex: number;\n}\n\nconst enum GlyphRenderRequestType {\n\tDecoration = 0,\n\tWidget = 1\n}\n\n/**\n * A request to render a decoration in the glyph margin at a certain location.\n */\nclass DecorationBasedGlyphRenderRequest {\n\tpublic readonly type = GlyphRenderRequestType.Decoration;\n\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly className: string,\n\t) { }\n\n\taccept(combinedClassName: string): DecorationBasedGlyph {\n\t\treturn new DecorationBasedGlyph(this.lineNumber, this.laneIndex, combinedClassName);\n\t}\n}\n\n/**\n * A request to render a widget in the glyph margin at a certain location.\n */\nclass WidgetBasedGlyphRenderRequest {\n\tpublic readonly type = GlyphRenderRequestType.Widget;\n\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly widget: IWidgetData,\n\t) { }\n}\n\ntype GlyphRenderRequest = DecorationBasedGlyphRenderRequest | WidgetBasedGlyphRenderRequest;\n\nclass DecorationBasedGlyph {\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly combinedClassName: string\n\t) { }\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 *--------------------------------------------------------------------------------------------*/\n\nimport { FastDomNode, createFastDomNode } from '../../../../base/browser/fastDomNode.js';\nimport { ArrayQueue } from '../../../../base/common/arrays.js';\nimport './glyphMargin.css';\nimport { IGlyphMarginWidget, IGlyphMarginWidgetPosition } from '../../editorBrowser.js';\nimport { DynamicViewOverlay } from '../../view/dynamicViewOverlay.js';\nimport { RenderingContext, RestrictedRenderingContext } from '../../view/renderingContext.js';\nimport { ViewPart } from '../../view/viewPart.js';\nimport { EditorOption } from '../../../common/config/editorOptions.js';\nimport { Position } from '../../../common/core/position.js';\nimport { Range } from '../../../common/core/range.js';\nimport { GlyphMarginLane } from '../../../common/model.js';\nimport * as viewEvents from '../../../common/viewEvents.js';\nimport { ViewContext } from '../../../common/viewModel/viewContext.js';\n\n/**\n * Represents a decoration that should be shown along the lines from `startLineNumber` to `endLineNumber`.\n * This can end up producing multiple `LineDecorationToRender`.\n */\nexport class DecorationToRender {\n\tpublic readonly _decorationToRenderBrand: void = undefined;\n\n\tpublic readonly zIndex: number;\n\n\tconstructor(\n\t\tpublic readonly startLineNumber: number,\n\t\tpublic readonly endLineNumber: number,\n\t\tpublic readonly className: string,\n\t\tpublic readonly tooltip: string | null,\n\t\tzIndex: number | undefined,\n\t) {\n\t\tthis.zIndex = zIndex ?? 0;\n\t}\n}\n\n/**\n * A decoration that should be shown along a line.\n */\nexport class LineDecorationToRender {\n\tconstructor(\n\t\tpublic readonly className: string,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly tooltip: string | null,\n\t) { }\n}\n\n/**\n * Decorations to render on a visible line.\n */\nexport class VisibleLineDecorationsToRender {\n\n\tprivate readonly decorations: LineDecorationToRender[] = [];\n\n\tpublic add(decoration: LineDecorationToRender) {\n\t\tthis.decorations.push(decoration);\n\t}\n\n\tpublic getDecorations(): LineDecorationToRender[] {\n\t\treturn this.decorations;\n\t}\n}\n\nexport abstract class DedupOverlay extends DynamicViewOverlay {\n\n\t/**\n\t * Returns an array with an element for each visible line number.\n\t */\n\tprotected _render(visibleStartLineNumber: number, visibleEndLineNumber: number, decorations: DecorationToRender[]): VisibleLineDecorationsToRender[] {\n\n\t\tconst output: VisibleLineDecorationsToRender[] = [];\n\t\tfor (let lineNumber = visibleStartLineNumber; lineNumber <= visibleEndLineNumber; lineNumber++) {\n\t\t\tconst lineIndex = lineNumber - visibleStartLineNumber;\n\t\t\toutput[lineIndex] = new VisibleLineDecorationsToRender();\n\t\t}\n\n\t\tif (decorations.length === 0) {\n\t\t\treturn output;\n\t\t}\n\n\t\t// Sort decorations by className, then by startLineNumber and then by endLineNumber\n\t\tdecorations.sort((a, b) => {\n\t\t\tif (a.className === b.className) {\n\t\t\t\tif (a.startLineNumber === b.startLineNumber) {\n\t\t\t\t\treturn a.endLineNumber - b.endLineNumber;\n\t\t\t\t}\n\t\t\t\treturn a.startLineNumber - b.startLineNumber;\n\t\t\t}\n\t\t\treturn (a.className < b.className ? -1 : 1);\n\t\t});\n\n\t\tlet prevClassName: string | null = null;\n\t\tlet prevEndLineIndex = 0;\n\t\tfor (const d of decorations) {\n\t\t\tconst className = d.className;\n\t\t\tconst zIndex = d.zIndex;\n\t\t\tlet startLineIndex = Math.max(d.startLineNumber, visibleStartLineNumber) - visibleStartLineNumber;\n\t\t\tconst endLineIndex = Math.min(d.endLineNumber, visibleEndLineNumber) - visibleStartLineNumber;\n\n\t\t\tif (prevClassName === className) {\n\t\t\t\t// Here we avoid rendering the same className multiple times on the same line\n\t\t\t\tstartLineIndex = Math.max(prevEndLineIndex + 1, startLineIndex);\n\t\t\t\tprevEndLineIndex = Math.max(prevEndLineIndex, endLineIndex);\n\t\t\t} else {\n\t\t\t\tprevClassName = className;\n\t\t\t\tprevEndLineIndex = endLineIndex;\n\t\t\t}\n\n\t\t\tfor (let lineIndex = startLineIndex; lineIndex <= prevEndLineIndex; lineIndex++) {\n\t\t\t\toutput[lineIndex].add(new LineDecorationToRender(className, zIndex, d.tooltip));\n\t\t\t}\n\t\t}\n\n\t\treturn output;\n\t}\n}\n\nexport class GlyphMarginWidgets extends ViewPart {\n\n\tpublic domNode: FastDomNode<HTMLElement>;\n\n\tprivate _lineHeight: number;\n\tprivate _glyphMargin: boolean;\n\tprivate _glyphMarginLeft: number;\n\tprivate _glyphMarginWidth: number;\n\tprivate _glyphMarginDecorationLaneCount: number;\n\n\tprivate _managedDomNodes: FastDomNode<HTMLElement>[];\n\tprivate _decorationGlyphsToRender: DecorationBasedGlyph[];\n\n\tprivate _widgets: { [key: string]: IWidgetData } = {};\n\n\tconstructor(context: ViewContext) {\n\t\tsuper(context);\n\t\tthis._context = context;\n\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis.domNode = createFastDomNode(document.createElement('div'));\n\t\tthis.domNode.setClassName('glyph-margin-widgets');\n\t\tthis.domNode.setPosition('absolute');\n\t\tthis.domNode.setTop(0);\n\n\t\tthis._lineHeight = options.get(EditorOption.lineHeight);\n\t\tthis._glyphMargin = options.get(EditorOption.glyphMargin);\n\t\tthis._glyphMarginLeft = layoutInfo.glyphMarginLeft;\n\t\tthis._glyphMarginWidth = layoutInfo.glyphMarginWidth;\n\t\tthis._glyphMarginDecorationLaneCount = layoutInfo.glyphMarginDecorationLaneCount;\n\t\tthis._managedDomNodes = [];\n\t\tthis._decorationGlyphsToRender = [];\n\t}\n\n\tpublic override dispose(): void {\n\t\tthis._managedDomNodes = [];\n\t\tthis._decorationGlyphsToRender = [];\n\t\tthis._widgets = {};\n\t\tsuper.dispose();\n\t}\n\n\tpublic getWidgets(): IWidgetData[] {\n\t\treturn Object.values(this._widgets);\n\t}\n\n\t// --- begin event handlers\n\tpublic override onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean {\n\t\tconst options = this._context.configuration.options;\n\t\tconst layoutInfo = options.get(EditorOption.layoutInfo);\n\n\t\tthis._lineHeight = options.get(EditorOption.lineHeight);\n\t\tthis._glyphMargin = options.get(EditorOption.glyphMargin);\n\t\tthis._glyphMarginLeft = layoutInfo.glyphMarginLeft;\n\t\tthis._glyphMarginWidth = layoutInfo.glyphMarginWidth;\n\t\tthis._glyphMarginDecorationLaneCount = layoutInfo.glyphMarginDecorationLaneCount;\n\t\treturn true;\n\t}\n\tpublic override onDecorationsChanged(e: viewEvents.ViewDecorationsChangedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onFlushed(e: viewEvents.ViewFlushedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesChanged(e: viewEvents.ViewLinesChangedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesDeleted(e: viewEvents.ViewLinesDeletedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onLinesInserted(e: viewEvents.ViewLinesInsertedEvent): boolean {\n\t\treturn true;\n\t}\n\tpublic override onScrollChanged(e: viewEvents.ViewScrollChangedEvent): boolean {\n\t\treturn e.scrollTopChanged;\n\t}\n\tpublic override onZonesChanged(e: viewEvents.ViewZonesChangedEvent): boolean {\n\t\treturn true;\n\t}\n\n\t// --- end event handlers\n\n\t// --- begin widget management\n\n\tpublic addWidget(widget: IGlyphMarginWidget): void {\n\t\tconst domNode = createFastDomNode(widget.getDomNode());\n\n\t\tthis._widgets[widget.getId()] = {\n\t\t\twidget: widget,\n\t\t\tpreference: widget.getPosition(),\n\t\t\tdomNode: domNode,\n\t\t\trenderInfo: null\n\t\t};\n\n\t\tdomNode.setPosition('absolute');\n\t\tdomNode.setDisplay('none');\n\t\tdomNode.setAttribute('widgetId', widget.getId());\n\t\tthis.domNode.appendChild(domNode);\n\n\t\tthis.setShouldRender();\n\t}\n\n\tpublic setWidgetPosition(widget: IGlyphMarginWidget, preference: IGlyphMarginWidgetPosition): boolean {\n\t\tconst myWidget = this._widgets[widget.getId()];\n\t\tif (myWidget.preference.lane === preference.lane\n\t\t\t&& myWidget.preference.zIndex === preference.zIndex\n\t\t\t&& Range.equalsRange(myWidget.preference.range, preference.range)) {\n\t\t\treturn false;\n\t\t}\n\n\t\tmyWidget.preference = preference;\n\t\tthis.setShouldRender();\n\n\t\treturn true;\n\t}\n\n\tpublic removeWidget(widget: IGlyphMarginWidget): void {\n\t\tconst widgetId = widget.getId();\n\t\tif (this._widgets[widgetId]) {\n\t\t\tconst widgetData = this._widgets[widgetId];\n\t\t\tconst domNode = widgetData.domNode.domNode;\n\t\t\tdelete this._widgets[widgetId];\n\n\t\t\tdomNode.remove();\n\t\t\tthis.setShouldRender();\n\t\t}\n\t}\n\n\t// --- end widget management\n\n\tprivate _collectDecorationBasedGlyphRenderRequest(ctx: RenderingContext, requests: GlyphRenderRequest[]): void {\n\t\tconst visibleStartLineNumber = ctx.visibleRange.startLineNumber;\n\t\tconst visibleEndLineNumber = ctx.visibleRange.endLineNumber;\n\t\tconst decorations = ctx.getDecorationsInViewport();\n\n\t\tfor (const d of decorations) {\n\t\t\tconst glyphMarginClassName = d.options.glyphMarginClassName;\n\t\t\tif (!glyphMarginClassName) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tconst startLineNumber = Math.max(d.range.startLineNumber, visibleStartLineNumber);\n\t\t\tconst endLineNumber = Math.min(d.range.endLineNumber, visibleEndLineNumber);\n\t\t\tconst lane = d.options.glyphMargin?.position ?? GlyphMarginLane.Center;\n\t\t\tconst zIndex = d.options.zIndex ?? 0;\n\n\t\t\tfor (let lineNumber = startLineNumber; lineNumber <= endLineNumber; lineNumber++) {\n\t\t\t\tconst modelPosition = this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Position(lineNumber, 0));\n\t\t\t\tconst laneIndex = this._context.viewModel.glyphLanes.getLanesAtLine(modelPosition.lineNumber).indexOf(lane);\n\t\t\t\trequests.push(new DecorationBasedGlyphRenderRequest(lineNumber, laneIndex, zIndex, glyphMarginClassName));\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate _collectWidgetBasedGlyphRenderRequest(ctx: RenderingContext, requests: GlyphRenderRequest[]): void {\n\t\tconst visibleStartLineNumber = ctx.visibleRange.startLineNumber;\n\t\tconst visibleEndLineNumber = ctx.visibleRange.endLineNumber;\n\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\tconst range = widget.preference.range;\n\t\t\tconst { startLineNumber, endLineNumber } = this._context.viewModel.coordinatesConverter.convertModelRangeToViewRange(Range.lift(range));\n\t\t\tif (!startLineNumber || !endLineNumber || endLineNumber < visibleStartLineNumber || startLineNumber > visibleEndLineNumber) {\n\t\t\t\t// The widget is not in the viewport\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t// The widget is in the viewport, find a good line for it\n\t\t\tconst widgetLineNumber = Math.max(startLineNumber, visibleStartLineNumber);\n\t\t\tconst modelPosition = this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new Position(widgetLineNumber, 0));\n\t\t\tconst laneIndex = this._context.viewModel.glyphLanes.getLanesAtLine(modelPosition.lineNumber).indexOf(widget.preference.lane);\n\t\t\trequests.push(new WidgetBasedGlyphRenderRequest(widgetLineNumber, laneIndex, widget.preference.zIndex, widget));\n\t\t}\n\t}\n\n\tprivate _collectSortedGlyphRenderRequests(ctx: RenderingContext): GlyphRenderRequest[] {\n\n\t\tconst requests: GlyphRenderRequest[] = [];\n\n\t\tthis._collectDecorationBasedGlyphRenderRequest(ctx, requests);\n\t\tthis._collectWidgetBasedGlyphRenderRequest(ctx, requests);\n\n\t\t// sort requests by lineNumber ASC, lane ASC, zIndex DESC, type DESC (widgets first), className ASC\n\t\t// don't change this sort unless you understand `prepareRender` below.\n\t\trequests.sort((a, b) => {\n\t\t\tif (a.lineNumber === b.lineNumber) {\n\t\t\t\tif (a.laneIndex === b.laneIndex) {\n\t\t\t\t\tif (a.zIndex === b.zIndex) {\n\t\t\t\t\t\tif (b.type === a.type) {\n\t\t\t\t\t\t\tif (a.type === GlyphRenderRequestType.Decoration && b.type === GlyphRenderRequestType.Decoration) {\n\t\t\t\t\t\t\t\treturn (a.className < b.className ? -1 : 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\treturn 0;\n\t\t\t\t\t\t}\n\t\t\t\t\t\treturn b.type - a.type;\n\t\t\t\t\t}\n\t\t\t\t\treturn b.zIndex - a.zIndex;\n\t\t\t\t}\n\t\t\t\treturn a.laneIndex - b.laneIndex;\n\t\t\t}\n\t\t\treturn a.lineNumber - b.lineNumber;\n\t\t});\n\n\t\treturn requests;\n\t}\n\n\t/**\n\t * Will store render information in each widget's renderInfo and in `_decorationGlyphsToRender`.\n\t */\n\tpublic prepareRender(ctx: RenderingContext): void {\n\t\tif (!this._glyphMargin) {\n\t\t\tthis._decorationGlyphsToRender = [];\n\t\t\treturn;\n\t\t}\n\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\twidget.renderInfo = null;\n\t\t}\n\n\t\tconst requests = new ArrayQueue<GlyphRenderRequest>(this._collectSortedGlyphRenderRequests(ctx));\n\t\tconst decorationGlyphsToRender: DecorationBasedGlyph[] = [];\n\t\twhile (requests.length > 0) {\n\t\t\tconst first = requests.peek();\n\t\t\tif (!first) {\n\t\t\t\t// not possible\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// Requests are sorted by lineNumber and lane, so we read all requests for this particular location\n\t\t\tconst requestsAtLocation = requests.takeWhile((el) => el.lineNumber === first.lineNumber && el.laneIndex === first.laneIndex);\n\t\t\tif (!requestsAtLocation || requestsAtLocation.length === 0) {\n\t\t\t\t// not possible\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst winner = requestsAtLocation[0];\n\t\t\tif (winner.type === GlyphRenderRequestType.Decoration) {\n\t\t\t\t// combine all decorations with the same z-index\n\n\t\t\t\tconst classNames: string[] = [];\n\t\t\t\t// requests are sorted by zIndex, type, and className so we can dedup className by looking at the previous one\n\t\t\t\tfor (const request of requestsAtLocation) {\n\t\t\t\t\tif (request.zIndex !== winner.zIndex || request.type !== winner.type) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tif (classNames.length === 0 || classNames[classNames.length - 1] !== request.className) {\n\t\t\t\t\t\tclassNames.push(request.className);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tdecorationGlyphsToRender.push(winner.accept(classNames.join(' '))); // TODO@joyceerhl Implement overflow for remaining decorations\n\t\t\t} else {\n\t\t\t\t// widgets cannot be combined\n\t\t\t\twinner.widget.renderInfo = {\n\t\t\t\t\tlineNumber: winner.lineNumber,\n\t\t\t\t\tlaneIndex: winner.laneIndex,\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t\tthis._decorationGlyphsToRender = decorationGlyphsToRender;\n\t}\n\n\tpublic render(ctx: RestrictedRenderingContext): void {\n\t\tif (!this._glyphMargin) {\n\t\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\t\twidget.domNode.setDisplay('none');\n\t\t\t}\n\t\t\twhile (this._managedDomNodes.length > 0) {\n\t\t\t\tconst domNode = this._managedDomNodes.pop();\n\t\t\t\tdomNode?.domNode.remove();\n\t\t\t}\n\t\t\treturn;\n\t\t}\n\n\t\tconst width = (Math.round(this._glyphMarginWidth / this._glyphMarginDecorationLaneCount));\n\n\t\t// Render widgets\n\t\tfor (const widget of Object.values(this._widgets)) {\n\t\t\tif (!widget.renderInfo) {\n\t\t\t\t// this widget is not visible\n\t\t\t\twidget.domNode.setDisplay('none');\n\t\t\t} else {\n\t\t\t\tconst top = ctx.viewportData.relativeVerticalOffset[widget.renderInfo.lineNumber - ctx.viewportData.startLineNumber];\n\t\t\t\tconst left = this._glyphMarginLeft + widget.renderInfo.laneIndex * this._lineHeight;\n\n\t\t\t\twidget.domNode.setDisplay('block');\n\t\t\t\twidget.domNode.setTop(top);\n\t\t\t\twidget.domNode.setLeft(left);\n\t\t\t\twidget.domNode.setWidth(width);\n\t\t\t\twidget.domNode.setHeight(this._lineHeight);\n\t\t\t}\n\t\t}\n\n\t\t// Render decorations, reusing previous dom nodes as possible\n\t\tfor (let i = 0; i < this._decorationGlyphsToRender.length; i++) {\n\t\t\tconst dec = this._decorationGlyphsToRender[i];\n\t\t\tconst decLineNumber = dec.lineNumber;\n\t\t\tconst top = ctx.viewportData.relativeVerticalOffset[decLineNumber - ctx.viewportData.startLineNumber];\n\t\t\tconst left = this._glyphMarginLeft + dec.laneIndex * this._lineHeight;\n\n\t\t\tlet domNode: FastDomNode<HTMLElement>;\n\t\t\tif (i < this._managedDomNodes.length) {\n\t\t\t\tdomNode = this._managedDomNodes[i];\n\t\t\t} else {\n\t\t\t\tdomNode = createFastDomNode(document.createElement('div'));\n\t\t\t\tthis._managedDomNodes.push(domNode);\n\t\t\t\tthis.domNode.appendChild(domNode);\n\t\t\t}\n\t\t\tconst lineHeight = this._context.viewLayout.getLineHeightForLineNumber(decLineNumber);\n\n\t\t\tdomNode.setClassName(`cgmr codicon ` + dec.combinedClassName);\n\t\t\tdomNode.setPosition(`absolute`);\n\t\t\tdomNode.setTop(top);\n\t\t\tdomNode.setLeft(left);\n\t\t\tdomNode.setWidth(width);\n\t\t\tdomNode.setHeight(lineHeight);\n\t\t}\n\n\t\t// remove extra dom nodes\n\t\twhile (this._managedDomNodes.length > this._decorationGlyphsToRender.length) {\n\t\t\tconst domNode = this._managedDomNodes.pop();\n\t\t\tdomNode?.domNode.remove();\n\t\t}\n\t}\n}\n\nexport interface IWidgetData {\n\twidget: IGlyphMarginWidget;\n\tpreference: IGlyphMarginWidgetPosition;\n\tdomNode: FastDomNode<HTMLElement>;\n\t/**\n\t * it will contain the location where to render the widget\n\t * or null if the widget is not visible\n\t */\n\trenderInfo: IRenderInfo | null;\n}\n\nexport interface IRenderInfo {\n\tlineNumber: number;\n\tlaneIndex: number;\n}\n\nconst enum GlyphRenderRequestType {\n\tDecoration = 0,\n\tWidget = 1\n}\n\n/**\n * A request to render a decoration in the glyph margin at a certain location.\n */\nclass DecorationBasedGlyphRenderRequest {\n\tpublic readonly type = GlyphRenderRequestType.Decoration;\n\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly className: string,\n\t) { }\n\n\taccept(combinedClassName: string): DecorationBasedGlyph {\n\t\treturn new DecorationBasedGlyph(this.lineNumber, this.laneIndex, combinedClassName);\n\t}\n}\n\n/**\n * A request to render a widget in the glyph margin at a certain location.\n */\nclass WidgetBasedGlyphRenderRequest {\n\tpublic readonly type = GlyphRenderRequestType.Widget;\n\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly zIndex: number,\n\t\tpublic readonly widget: IWidgetData,\n\t) { }\n}\n\ntype GlyphRenderRequest = DecorationBasedGlyphRenderRequest | WidgetBasedGlyphRenderRequest;\n\nclass DecorationBasedGlyph {\n\tconstructor(\n\t\tpublic readonly lineNumber: number,\n\t\tpublic readonly laneIndex: number,\n\t\tpublic readonly combinedClassName: string\n\t) { }\n}\n"]}
@@ -1270,7 +1270,7 @@ class InnerMinimap extends Disposable {
1270
1270
  continue;
1271
1271
  }
1272
1272
  highlightedLines.set(line, true);
1273
- const y = layout.getYForLineNumber(startLineNumber, minimapLineHeight);
1273
+ const y = layout.getYForLineNumber(line, minimapLineHeight);
1274
1274
  canvasContext.fillRect(MINIMAP_GUTTER_WIDTH, y, canvasContext.canvas.width, minimapLineHeight);
1275
1275
  }
1276
1276
  }