@codingame/monaco-editor-wrapper 4.0.0-next.1 → 4.0.0-next.2

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 (403) hide show
  1. package/dist/_virtual/Angular.ng-template-15.2.1.vsix_package.json.vsjson.js +3 -0
  2. package/dist/_virtual/C2Hs-configuration.json.raw.js +3 -0
  3. package/dist/_virtual/Dart-Code.dart-code-3.63.20230419.vsix_package.json.vsjson.js +3 -0
  4. package/dist/_virtual/Hsc2Hs-configuration.json.raw.js +3 -0
  5. package/dist/_virtual/IMCTradingBV.svlangserver-0.4.1.vsix_package.json.vsjson.js +3 -0
  6. package/dist/_virtual/JakeBecker.elixir-ls-0.14.5.vsix_package.json.vsjson.js +3 -0
  7. package/dist/_virtual/JuanBlanco.solidity-0.0.152.vsix_package.json.vsjson.js +3 -0
  8. package/dist/_virtual/META.json.raw2.js +3 -0
  9. package/dist/_virtual/REditorSupport.r-2.7.2.vsix_package.json.vsjson.js +3 -0
  10. package/dist/_virtual/Rlogo.svg.raw.js +3 -0
  11. package/dist/{_commonjsHelpers.js → _virtual/_commonjsHelpers.js} +1 -1
  12. package/dist/_virtual/_monaco-editor.js +6 -0
  13. package/dist/_virtual/_rollup-plugin-web-worker-loader__helper__browser__createBase64WorkerFactory.js +31 -0
  14. package/dist/_virtual/actions.js +3 -0
  15. package/dist/_virtual/alefragnani.pascal-9.6.0.vsix_package.json.vsjson.js +3 -0
  16. package/dist/_virtual/angular-template-language-configuration.json.raw.js +3 -0
  17. package/dist/_virtual/basicInput.js +3 -0
  18. package/dist/_virtual/batisteo.vscode-django-1.10.0.vsix_package.json.vsjson.js +3 -0
  19. package/dist/_virtual/bitwisecook.tcl-0.4.3.vsix_package.json.vsjson.js +3 -0
  20. package/dist/_virtual/book-dark.svg.raw.js +3 -0
  21. package/dist/_virtual/book-light.svg.raw.js +3 -0
  22. package/dist/_virtual/broadcomMFD.cobol-language-support-1.2.1.vsix_package.json.vsjson.js +3 -0
  23. package/dist/_virtual/cabal-configuration.json.raw.js +3 -0
  24. package/dist/_virtual/castwide.solargraph-0.24.0.vsix_package.json.vsjson.js +3 -0
  25. package/dist/_virtual/ckolkman.vscode-postgres-1.4.2.vsix_package.json.vsjson.js +3 -0
  26. package/dist/_virtual/cm_adapter.js +3 -0
  27. package/dist/_virtual/commands.js +3 -0
  28. package/dist/_virtual/conda-environment.json.raw.js +3 -0
  29. package/dist/_virtual/conda-meta.json.raw.js +3 -0
  30. package/dist/_virtual/condarc.json.raw.js +3 -0
  31. package/dist/{css.worker.js → _virtual/css.worker.js} +1 -1
  32. package/dist/_virtual/d.json.raw2.js +3 -0
  33. package/dist/_virtual/dart-language-configuration.json.raw.js +3 -0
  34. package/dist/_virtual/dcf-configuration.json.raw.js +3 -0
  35. package/dist/_virtual/diet.json.raw3.js +3 -0
  36. package/dist/_virtual/dub.schema.json.raw.js +3 -0
  37. package/dist/_virtual/dune.json.raw3.js +3 -0
  38. package/dist/_virtual/editor.api.js +6 -0
  39. package/dist/_virtual/editor.worker.js +6 -0
  40. package/dist/_virtual/eex-language-configuration.json.raw.js +3 -0
  41. package/dist/_virtual/elixir-language-configuration.json.raw.js +3 -0
  42. package/dist/_virtual/erlang.configuration.json.raw.js +3 -0
  43. package/dist/_virtual/file_type_java.svg.raw.js +3 -0
  44. package/dist/_virtual/file_type_scala.svg.raw.js +3 -0
  45. package/dist/_virtual/flutter_activity_bar.svg.raw.js +3 -0
  46. package/dist/_virtual/general.json.raw.js +3 -0
  47. package/dist/_virtual/go.mod.language-configuration.json.raw.js +3 -0
  48. package/dist/_virtual/golang.Go-0.38.0.vsix_package.json.vsjson.js +3 -0
  49. package/dist/_virtual/haskell-configuration.json.raw.js +3 -0
  50. package/dist/{html.worker.js → _virtual/html.worker.js} +1 -1
  51. package/dist/_virtual/index.js +3 -0
  52. package/dist/_virtual/index2.js +3 -0
  53. package/dist/_virtual/index3.js +3 -0
  54. package/dist/_virtual/java-properties-configuration.json.raw.js +3 -0
  55. package/dist/_virtual/johnsoncodehk.vscode-angular-1.0.22.vsix_package.json.vsjson.js +3 -0
  56. package/dist/{json.worker.js → _virtual/json.worker.js} +1 -1
  57. package/dist/_virtual/justusadam.language-haskell-3.6.0.vsix_package.json.vsjson.js +3 -0
  58. package/dist/_virtual/keymap_vim.js +3 -0
  59. package/dist/_virtual/kotlin.configuration.json.raw.js +3 -0
  60. package/dist/_virtual/lang-config.json.raw.js +3 -0
  61. package/dist/_virtual/language-configuration.json.raw.js +3 -0
  62. package/dist/_virtual/language-configuration.json.raw2.js +3 -0
  63. package/dist/_virtual/language-configuration.json.raw3.js +3 -0
  64. package/dist/_virtual/language-configuration.json.raw4.js +3 -0
  65. package/dist/_virtual/language-configuration.json.raw5.js +3 -0
  66. package/dist/_virtual/language-configuration.json.raw6.js +3 -0
  67. package/dist/_virtual/language-configuration.json.raw7.js +3 -0
  68. package/dist/_virtual/language-configuration.json.raw8.js +3 -0
  69. package/dist/_virtual/literate-haskell-configuration.json.raw.js +3 -0
  70. package/dist/_virtual/logo.svg.raw.js +3 -0
  71. package/dist/_virtual/mathiasfrohlich.Kotlin-1.7.1.vsix_package.json.vsjson.js +3 -0
  72. package/dist/_virtual/menhir.json.raw2.js +3 -0
  73. package/dist/_virtual/ms-dotnettools.csharp-1.25.4.vsix_package.json.vsjson.js +3 -0
  74. package/dist/_virtual/ms-python.python-2023.7.11111009.vsix_package.json.vsjson.js +3 -0
  75. package/dist/_virtual/ms-vscode.cpptools-1.15.2.vsix_package.json.vsjson.js +3 -0
  76. package/dist/_virtual/oasis.json.raw2.js +3 -0
  77. package/dist/_virtual/ocaml.json.raw3.js +3 -0
  78. package/dist/_virtual/ocamlbuild.json.raw2.js +3 -0
  79. package/dist/_virtual/ocamlformat.json.raw2.js +3 -0
  80. package/dist/_virtual/ocamllabs.ocaml-platform-1.12.2.vsix_package.json.vsjson.js +3 -0
  81. package/dist/_virtual/ocamllex.json.raw3.js +3 -0
  82. package/dist/_virtual/opam-install.json.raw2.js +3 -0
  83. package/dist/_virtual/opam.json.raw2.js +3 -0
  84. package/dist/_virtual/package-json-schema.json.raw.js +3 -0
  85. package/dist/_virtual/package.schema.json.raw.js +3 -0
  86. package/dist/_virtual/pascal.configuration.json.raw.js +3 -0
  87. package/dist/_virtual/pgourlain.erlang-0.8.8.vsix_package.json.vsjson.js +3 -0
  88. package/dist/_virtual/pip-requirements.json.raw.js +3 -0
  89. package/dist/_virtual/postgres-explorer.svg.raw.js +3 -0
  90. package/dist/_virtual/prettier-options-schema.json.raw.js +3 -0
  91. package/dist/_virtual/r-configuration.json.raw.js +3 -0
  92. package/dist/_virtual/rbuildignore-configuration.json.raw.js +3 -0
  93. package/dist/_virtual/rd-configuration.json.raw.js +3 -0
  94. package/dist/{reason.json2.js → _virtual/reason.json.raw2.js} +2 -2
  95. package/dist/_virtual/redhat.java-1.18.2023042204.vsix_package.json.vsjson.js +3 -0
  96. package/dist/_virtual/rmd-configuration.json.raw.js +3 -0
  97. package/dist/_virtual/rnamespace-configuration.json.raw.js +3 -0
  98. package/dist/_virtual/scala-lang.scala-0.5.6.vsix_package.json.vsjson.js +3 -0
  99. package/dist/_virtual/scalameta-logo.png.raw.js +3 -0
  100. package/dist/_virtual/scalameta.metals-1.23.0.vsix_package.json.vsjson.js +3 -0
  101. package/dist/_virtual/scalameta.svg.raw.js +3 -0
  102. package/dist/_virtual/schema.json.raw.js +3 -0
  103. package/dist/_virtual/shiftCommand.js +6 -0
  104. package/dist/_virtual/solidity.configuration.json.raw.js +3 -0
  105. package/dist/_virtual/state.js +3 -0
  106. package/dist/_virtual/statusbar.js +3 -0
  107. package/dist/_virtual/sumneko.lua-3.6.18.vsix_package.json.vsjson.js +3 -0
  108. package/dist/_virtual/svelte.svelte-vscode-107.3.0.vsix_package.json.vsjson.js +3 -0
  109. package/dist/_virtual/tasks.schema.json.raw.js +3 -0
  110. package/dist/{ts.worker.js → _virtual/ts.worker.js} +1 -1
  111. package/dist/_virtual/util.js +3 -0
  112. package/dist/_virtual/webfreak.code-d-0.23.2.vsix_package.json.vsjson.js +3 -0
  113. package/dist/configuration/index.js +45 -0
  114. package/dist/editor/autofold.js +24 -0
  115. package/dist/editor/cobol.js +67 -0
  116. package/dist/editor/index.js +9 -0
  117. package/dist/extensions/Angular.ng-template-15.2.1.vsix.js +15 -0
  118. package/dist/extensions/Dart-Code.dart-code-3.63.20230419.vsix.js +14 -0
  119. package/dist/extensions/IMCTradingBV.svlangserver-0.4.1.vsix.js +18 -0
  120. package/dist/extensions/JakeBecker.elixir-ls-0.14.5.vsix.js +18 -0
  121. package/dist/extensions/JuanBlanco.solidity-0.0.152.vsix.js +13 -0
  122. package/dist/extensions/REditorSupport.r-2.7.2.vsix.js +47 -0
  123. package/dist/extensions/alefragnani.pascal-9.6.0.vsix.js +13 -0
  124. package/dist/extensions/batisteo.vscode-django-1.10.0.vsix.js +17 -0
  125. package/dist/extensions/bitwisecook.tcl-0.4.3.vsix.js +13 -0
  126. package/dist/extensions/broadcomMFD.cobol-language-support-1.2.1.vsix.js +11 -0
  127. package/dist/extensions/castwide.solargraph-0.24.0.vsix.js +8 -0
  128. package/dist/extensions/ckolkman.vscode-postgres-1.4.2.vsix.js +14 -0
  129. package/dist/extensions/golang.Go-0.38.0.vsix.js +17 -0
  130. package/dist/extensions/johnsoncodehk.vscode-angular-1.0.22.vsix.js +13 -0
  131. package/dist/extensions/justusadam.language-haskell-3.6.0.vsix.js +41 -0
  132. package/dist/extensions/mathiasfrohlich.Kotlin-1.7.1.vsix.js +15 -0
  133. package/dist/extensions/ms-dotnettools.csharp-1.25.4.vsix.js +17 -0
  134. package/dist/extensions/ms-python.python-2023.7.11111009.vsix.js +20 -0
  135. package/dist/extensions/ms-vscode.cpptools-1.15.2.vsix.js +8 -0
  136. package/dist/extensions/ocamllabs.ocaml-platform-1.12.2.vsix.js +92 -0
  137. package/dist/extensions/pgourlain.erlang-0.8.8.vsix.js +13 -0
  138. package/dist/extensions/redhat.java-1.18.2023042204.vsix.js +19 -0
  139. package/dist/extensions/scala-lang.scala-0.5.6.vsix.js +11 -0
  140. package/dist/extensions/scalameta.metals-1.23.0.vsix.js +34 -0
  141. package/dist/extensions/sumneko.lua-3.6.18.vsix.js +10 -0
  142. package/dist/extensions/svelte.svelte-vscode-107.3.0.vsix.js +37 -0
  143. package/dist/extensions/webfreak.code-d-0.23.2.vsix.js +28 -0
  144. package/dist/extensions.d.ts +3 -2
  145. package/dist/features/cssContribution.js +4 -5
  146. package/dist/features/debug.d.ts +1 -0
  147. package/dist/features/debug.js +7 -0
  148. package/dist/features/htmlContribution.js +79 -88
  149. package/dist/features/jsonContribution.js +10 -12
  150. package/dist/features/search.d.ts +1 -0
  151. package/dist/features/search.js +7 -0
  152. package/dist/features/typescriptContribution.js +27 -15
  153. package/dist/features/viewPanels.d.ts +1 -0
  154. package/dist/features/viewPanels.js +9 -0
  155. package/dist/features/views.d.ts +4 -0
  156. package/dist/features/views.js +17 -0
  157. package/dist/keybindings/index.js +36 -0
  158. package/dist/keybindings/vim.js +82 -0
  159. package/dist/languages/index.js +40 -0
  160. package/dist/main.js +6 -1286
  161. package/dist/monaco.d.ts +0 -1
  162. package/dist/monaco.js +90 -0
  163. package/dist/node_modules/@types/node/console.d.js +3 -0
  164. package/dist/node_modules/@types/node/globals.d.js +3 -0
  165. package/dist/node_modules/@types/node/process.d.js +3 -0
  166. package/dist/node_modules/lodash.kebabcase/index.js +439 -0
  167. package/dist/node_modules/lodash.throttle/index.js +443 -0
  168. package/dist/node_modules/monaco-emacs/lib/emacs/actions.js +596 -0
  169. package/dist/node_modules/monaco-emacs/lib/emacs/basicInput.js +113 -0
  170. package/dist/node_modules/monaco-emacs/lib/emacs/commands.js +184 -0
  171. package/dist/node_modules/monaco-emacs/lib/emacs/index.js +186 -0
  172. package/dist/node_modules/monaco-emacs/lib/emacs/state.js +116 -0
  173. package/dist/node_modules/monaco-emacs/lib/emacs/util.js +112 -0
  174. package/dist/node_modules/monaco-emacs/lib/index.js +31 -0
  175. package/dist/{vim.js → node_modules/monaco-vim/lib/cm/keymap_vim.js} +3 -1790
  176. package/dist/node_modules/monaco-vim/lib/cm_adapter.js +1393 -0
  177. package/dist/node_modules/monaco-vim/lib/index.js +71 -0
  178. package/dist/node_modules/monaco-vim/lib/statusbar.js +239 -0
  179. package/dist/node_modules/tslib/tslib.es6.js +77 -0
  180. package/dist/services.d.ts +2 -0
  181. package/dist/services.js +50 -0
  182. package/dist/style.js +12 -0
  183. package/dist/theme/index.js +21 -0
  184. package/dist/tools/EditorOpenHandlerRegistry.js +108 -0
  185. package/dist/tools.js +235 -0
  186. package/dist/worker.d.ts +1 -10
  187. package/dist/worker.js +9 -58
  188. package/package.json +28 -37
  189. package/stats.html +1 -1
  190. package/dist/C2Hs-configuration.json.js +0 -3
  191. package/dist/Hsc2Hs-configuration.json.js +0 -3
  192. package/dist/META.json2.js +0 -3
  193. package/dist/_monaco-editor_commonjs-external.js +0 -39
  194. package/dist/_rollupPluginBabelHelpers.js +0 -51
  195. package/dist/add.svg.js +0 -3
  196. package/dist/add.svg2.js +0 -3
  197. package/dist/adddep-dark.svg.js +0 -3
  198. package/dist/adddep-light.svg.js +0 -3
  199. package/dist/angular-template-language-configuration.json.js +0 -3
  200. package/dist/arrow-circle-up-dark.svg.js +0 -3
  201. package/dist/arrow-circle-up-light.svg.js +0 -3
  202. package/dist/book-dark.svg.js +0 -3
  203. package/dist/book-light.svg.js +0 -3
  204. package/dist/book-open-dark.svg.js +0 -3
  205. package/dist/book-open-light.svg.js +0 -3
  206. package/dist/cabal-configuration.json.js +0 -3
  207. package/dist/d.json2.js +0 -3
  208. package/dist/dart-language-configuration.json.js +0 -3
  209. package/dist/dcf-configuration.json.js +0 -3
  210. package/dist/diet.json3.js +0 -3
  211. package/dist/document-search-dark.svg.js +0 -3
  212. package/dist/document-search-light.svg.js +0 -3
  213. package/dist/documentation-inverse.svg.js +0 -3
  214. package/dist/documentation.svg.js +0 -3
  215. package/dist/dub-convert-inverse.svg.js +0 -3
  216. package/dist/dub-convert.svg.js +0 -3
  217. package/dist/dune.json3.js +0 -3
  218. package/dist/edit-dub-inverse.svg.js +0 -3
  219. package/dist/edit-dub.svg.js +0 -3
  220. package/dist/edit-source-inverse.svg.js +0 -3
  221. package/dist/edit-source.svg.js +0 -3
  222. package/dist/eex-language-configuration.json.js +0 -3
  223. package/dist/elixir-language-configuration.json.js +0 -3
  224. package/dist/erlang.configuration.json.js +0 -3
  225. package/dist/extension-web.js.js +0 -3
  226. package/dist/extension-web.js2.js +0 -3
  227. package/dist/extension.browser.js.js +0 -3
  228. package/dist/file_type_java.svg.js +0 -3
  229. package/dist/file_type_scala.svg.js +0 -3
  230. package/dist/focus-dark.svg.js +0 -3
  231. package/dist/focus-light.svg.js +0 -3
  232. package/dist/general.json.js +0 -3
  233. package/dist/get-inverse.svg.js +0 -3
  234. package/dist/get.svg.js +0 -3
  235. package/dist/go.mod.language-configuration.json.js +0 -3
  236. package/dist/haskell-configuration.json.js +0 -3
  237. package/dist/hot-reload-tb.png.js +0 -3
  238. package/dist/hot-reload.svg.js +0 -3
  239. package/dist/index.js +0 -2210
  240. package/dist/index2.js +0 -49
  241. package/dist/inspector.svg.js +0 -3
  242. package/dist/java-properties-configuration.json.js +0 -3
  243. package/dist/kotlin.configuration.json.js +0 -3
  244. package/dist/lang-config.json.js +0 -3
  245. package/dist/language-configuration.json.js +0 -3
  246. package/dist/language-configuration.json2.js +0 -3
  247. package/dist/language-configuration.json3.js +0 -3
  248. package/dist/language-configuration.json4.js +0 -3
  249. package/dist/language-configuration.json5.js +0 -3
  250. package/dist/language-configuration.json6.js +0 -3
  251. package/dist/language-configuration.json7.js +0 -3
  252. package/dist/language-configuration.json8.js +0 -3
  253. package/dist/literate-haskell-configuration.json.js +0 -3
  254. package/dist/menhir.json2.js +0 -3
  255. package/dist/oasis.json2.js +0 -3
  256. package/dist/ocaml.json3.js +0 -3
  257. package/dist/ocamlbuild.json2.js +0 -3
  258. package/dist/ocamlformat.json2.js +0 -3
  259. package/dist/ocamllex.json3.js +0 -3
  260. package/dist/opam-install.json2.js +0 -3
  261. package/dist/opam.json2.js +0 -3
  262. package/dist/outdated-inverse.svg.js +0 -3
  263. package/dist/outdated.svg.js +0 -3
  264. package/dist/pascal.configuration.json.js +0 -3
  265. package/dist/performance.svg.js +0 -3
  266. package/dist/pip-requirements.json.js +0 -3
  267. package/dist/plus-dark.svg.js +0 -3
  268. package/dist/plus-light.svg.js +0 -3
  269. package/dist/preview-right-dark.svg.js +0 -3
  270. package/dist/preview-right-light.svg.js +0 -3
  271. package/dist/r-configuration.json.js +0 -3
  272. package/dist/rbuildignore-configuration.json.js +0 -3
  273. package/dist/rd-configuration.json.js +0 -3
  274. package/dist/ref-group-by-type-dark.svg.js +0 -3
  275. package/dist/ref-group-by-type-light.svg.js +0 -3
  276. package/dist/ref-ungroup-by-type-dark.svg.js +0 -3
  277. package/dist/ref-ungroup-by-type-light.svg.js +0 -3
  278. package/dist/refresh-dark.svg.js +0 -3
  279. package/dist/refresh-dark.svg2.js +0 -3
  280. package/dist/refresh-light.svg.js +0 -3
  281. package/dist/refresh-light.svg2.js +0 -3
  282. package/dist/repl.svg.js +0 -3
  283. package/dist/repl.svg2.js +0 -3
  284. package/dist/rmd-configuration.json.js +0 -3
  285. package/dist/rnamespace-configuration.json.js +0 -3
  286. package/dist/save.svg.js +0 -3
  287. package/dist/save.svg2.js +0 -3
  288. package/dist/scalameta-logo.png.js +0 -3
  289. package/dist/solidity.configuration.json.js +0 -3
  290. package/dist/switch-impl-intf.dark.svg.js +0 -3
  291. package/dist/switch-impl-intf.light.svg.js +0 -3
  292. package/dist/upgrade-inverse.svg.js +0 -3
  293. package/dist/upgrade.svg.js +0 -3
  294. package/dist/x-dark.svg.js +0 -3
  295. package/dist/x-light.svg.js +0 -3
  296. /package/dist/{C2Hs.json.js → _virtual/C2Hs.json.raw.js} +0 -0
  297. /package/dist/{COBOL.tmLanguage.json.js → _virtual/COBOL.tmLanguage.json.raw.js} +0 -0
  298. /package/dist/{Erlang.plist.js → _virtual/Erlang.plist.raw.js} +0 -0
  299. /package/dist/{Hsc2Hs.json.js → _virtual/Hsc2Hs.json.raw.js} +0 -0
  300. /package/dist/{JavaProperties.tmLanguage.json.js → _virtual/JavaProperties.tmLanguage.json.raw.js} +0 -0
  301. /package/dist/{Kotlin.tmLanguage.js → _virtual/Kotlin.tmLanguage.raw.js} +0 -0
  302. /package/dist/{META.json.js → _virtual/META.json.raw.js} +0 -0
  303. /package/dist/{Markdown Redcarpet.json.js → _virtual/Markdown Redcarpet.json.raw.js} +0 -0
  304. /package/dist/{RMarkdown.json.js → _virtual/RMarkdown.json.raw.js} +0 -0
  305. /package/dist/{Rcpp.json.js → _virtual/Rcpp.json.raw.js} +0 -0
  306. /package/dist/{Rd (R Documentation).json.js → _virtual/Rd (R Documentation).json.raw.js} +0 -0
  307. /package/dist/{Scala.tmLanguage.json.js → _virtual/Scala.tmLanguage.json.raw.js} +0 -0
  308. /package/dist/{alex.json.js → _virtual/alex.json.raw.js} +0 -0
  309. /package/dist/{angular-directives.json.js → _virtual/angular-directives.json.raw.js} +0 -0
  310. /package/dist/{angular-interpolations.json.js → _virtual/angular-interpolations.json.raw.js} +0 -0
  311. /package/dist/{aspnetcorerazor.tmLanguage.json.js → _virtual/aspnetcorerazor.tmLanguage.json.raw.js} +0 -0
  312. /package/dist/{atd.json.js → _virtual/atd.json.raw.js} +0 -0
  313. /package/dist/{buildtarget.json.js → _virtual/buildtarget.json.raw.js} +0 -0
  314. /package/dist/{cabal.json.js → _virtual/cabal.json.raw.js} +0 -0
  315. /package/dist/{codeblock-cabal.json.js → _virtual/codeblock-cabal.json.raw.js} +0 -0
  316. /package/dist/{codeblock-haskell.json.js → _virtual/codeblock-haskell.json.raw.js} +0 -0
  317. /package/dist/{codeblock-literate-haskell.json.js → _virtual/codeblock-literate-haskell.json.raw.js} +0 -0
  318. /package/dist/{codeblock.json.js → _virtual/codeblock.json.raw.js} +0 -0
  319. /package/dist/{codeblock.json2.js → _virtual/codeblock.json.raw2.js} +0 -0
  320. /package/dist/{cram.json.js → _virtual/cram.json.raw.js} +0 -0
  321. /package/dist/{csharp.json.js → _virtual/csharp.json.raw.js} +0 -0
  322. /package/dist/{d.json.js → _virtual/d.json.raw.js} +0 -0
  323. /package/dist/{dart.json.js → _virtual/dart.json.raw.js} +0 -0
  324. /package/dist/{dcf.json.js → _virtual/dcf.json.raw.js} +0 -0
  325. /package/dist/{diet.json.js → _virtual/diet.json.raw.js} +0 -0
  326. /package/dist/{diet.json2.js → _virtual/diet.json.raw2.js} +0 -0
  327. /package/dist/{django-html.tmLanguage.json.js → _virtual/django-html.tmLanguage.json.raw.js} +0 -0
  328. /package/dist/{django-txt.tmLanguage.json.js → _virtual/django-txt.tmLanguage.json.raw.js} +0 -0
  329. /package/dist/{dml.json.js → _virtual/dml.json.raw.js} +0 -0
  330. /package/dist/{dune-project.json.js → _virtual/dune-project.json.raw.js} +0 -0
  331. /package/dist/{dune-project.json2.js → _virtual/dune-project.json.raw2.js} +0 -0
  332. /package/dist/{dune-workspace.json.js → _virtual/dune-workspace.json.raw.js} +0 -0
  333. /package/dist/{dune.json.js → _virtual/dune.json.raw.js} +0 -0
  334. /package/dist/{dune.json2.js → _virtual/dune.json.raw2.js} +0 -0
  335. /package/dist/{eex.json.js → _virtual/eex.json.raw.js} +0 -0
  336. /package/dist/{elixir.json.js → _virtual/elixir.json.raw.js} +0 -0
  337. /package/dist/{erlang.json.js → _virtual/erlang.json.raw.js} +0 -0
  338. /package/dist/{expression.json.js → _virtual/expression.json.raw.js} +0 -0
  339. /package/dist/{filters.json.js → _virtual/filters.json.raw.js} +0 -0
  340. /package/dist/{go.json.js → _virtual/go.json.raw.js} +0 -0
  341. /package/dist/{go.mod.tmGrammar.json.js → _virtual/go.mod.tmGrammar.json.raw.js} +0 -0
  342. /package/dist/{go.sum.tmGrammar.json.js → _virtual/go.sum.tmGrammar.json.raw.js} +0 -0
  343. /package/dist/{govulncheck.tmGrammar.json.js → _virtual/govulncheck.tmGrammar.json.raw.js} +0 -0
  344. /package/dist/{happy.json.js → _virtual/happy.json.raw.js} +0 -0
  345. /package/dist/{haskell.json.js → _virtual/haskell.json.raw.js} +0 -0
  346. /package/dist/{html-eex.json.js → _virtual/html-eex.json.raw.js} +0 -0
  347. /package/dist/{inline-styles.json.js → _virtual/inline-styles.json.raw.js} +0 -0
  348. /package/dist/{inline-template.json.js → _virtual/inline-template.json.raw.js} +0 -0
  349. /package/dist/{java.json.js → _virtual/java.json.raw.js} +0 -0
  350. /package/dist/{javascript.json.js → _virtual/javascript.json.raw.js} +0 -0
  351. /package/dist/{jvm-bytecode-verbose.json.js → _virtual/jvm-bytecode-verbose.json.raw.js} +0 -0
  352. /package/dist/{jvm-bytecode.json.js → _virtual/jvm-bytecode.json.raw.js} +0 -0
  353. /package/dist/{kotlin.json.js → _virtual/kotlin.json.raw.js} +0 -0
  354. /package/dist/{literateHaskell.json.js → _virtual/literateHaskell.json.raw.js} +0 -0
  355. /package/dist/{markdown-svelte-css.json.js → _virtual/markdown-svelte-css.json.raw.js} +0 -0
  356. /package/dist/{markdown-svelte-js.json.js → _virtual/markdown-svelte-js.json.raw.js} +0 -0
  357. /package/dist/{markdown-svelte.json.js → _virtual/markdown-svelte.json.raw.js} +0 -0
  358. /package/dist/{menhir-action.json.js → _virtual/menhir-action.json.raw.js} +0 -0
  359. /package/dist/{menhir.json.js → _virtual/menhir.json.raw.js} +0 -0
  360. /package/dist/{merlin.json.js → _virtual/merlin.json.raw.js} +0 -0
  361. /package/dist/{oasis.json.js → _virtual/oasis.json.raw.js} +0 -0
  362. /package/dist/{ocaml-markdown-codeblock.json.js → _virtual/ocaml-markdown-codeblock.json.raw.js} +0 -0
  363. /package/dist/{ocaml.interface.json.js → _virtual/ocaml.interface.json.raw.js} +0 -0
  364. /package/dist/{ocaml.json.js → _virtual/ocaml.json.raw.js} +0 -0
  365. /package/dist/{ocaml.json2.js → _virtual/ocaml.json.raw2.js} +0 -0
  366. /package/dist/{ocamlbuild.json.js → _virtual/ocamlbuild.json.raw.js} +0 -0
  367. /package/dist/{ocamldoc.json.js → _virtual/ocamldoc.json.raw.js} +0 -0
  368. /package/dist/{ocamlformat.json.js → _virtual/ocamlformat.json.raw.js} +0 -0
  369. /package/dist/{ocamllex.json.js → _virtual/ocamllex.json.raw.js} +0 -0
  370. /package/dist/{ocamllex.json2.js → _virtual/ocamllex.json.raw2.js} +0 -0
  371. /package/dist/{opam-install.json.js → _virtual/opam-install.json.raw.js} +0 -0
  372. /package/dist/{opam.json.js → _virtual/opam.json.raw.js} +0 -0
  373. /package/dist/{pascal.json.js → _virtual/pascal.json.raw.js} +0 -0
  374. /package/dist/{pascal.tmLanguage.js → _virtual/pascal.tmLanguage.raw.js} +0 -0
  375. /package/dist/{pgsql.tmLanguage.js → _virtual/pgsql.tmLanguage.raw.js} +0 -0
  376. /package/dist/{pip-requirements.tmLanguage.json.js → _virtual/pip-requirements.tmLanguage.json.raw.js} +0 -0
  377. /package/dist/{postcss.json.js → _virtual/postcss.json.raw.js} +0 -0
  378. /package/dist/{pug-svelte-dotblock.json.js → _virtual/pug-svelte-dotblock.json.raw.js} +0 -0
  379. /package/dist/{pug-svelte-tags.json.js → _virtual/pug-svelte-tags.json.raw.js} +0 -0
  380. /package/dist/{pug-svelte.json.js → _virtual/pug-svelte.json.raw.js} +0 -0
  381. /package/dist/{r-snippets.json.js → _virtual/r-snippets.json.raw.js} +0 -0
  382. /package/dist/{r.json.js → _virtual/r.json.raw.js} +0 -0
  383. /package/dist/{rbuildignore.json.js → _virtual/rbuildignore.json.raw.js} +0 -0
  384. /package/dist/{reason-markdown-codeblock.json.js → _virtual/reason-markdown-codeblock.json.raw.js} +0 -0
  385. /package/dist/{reason.json.js → _virtual/reason.json.raw.js} +0 -0
  386. /package/dist/{rmarkdown.json2.js → _virtual/rmarkdown.json.raw2.js} +0 -0
  387. /package/dist/{rnamespace.json.js → _virtual/rnamespace.json.raw.js} +0 -0
  388. /package/dist/{sdl.json.js → _virtual/sdl.json.raw.js} +0 -0
  389. /package/dist/{semanticdb.json.js → _virtual/semanticdb.json.raw.js} +0 -0
  390. /package/dist/{solidity.json.js → _virtual/solidity.json.raw.js} +0 -0
  391. /package/dist/{solidity.json2.js → _virtual/solidity.json.raw2.js} +0 -0
  392. /package/dist/{svelte.json.js → _virtual/svelte.json.raw.js} +0 -0
  393. /package/dist/{svelte.tmLanguage.json.js → _virtual/svelte.tmLanguage.json.raw.js} +0 -0
  394. /package/dist/{systemverilog.json.js → _virtual/systemverilog.json.raw.js} +0 -0
  395. /package/dist/{systemverilog.tmLanguage.json.js → _virtual/systemverilog.tmLanguage.json.raw.js} +0 -0
  396. /package/dist/{tags.json.js → _virtual/tags.json.raw.js} +0 -0
  397. /package/dist/{tasty.json.js → _virtual/tasty.json.raw.js} +0 -0
  398. /package/dist/{tcl.json.js → _virtual/tcl.json.raw.js} +0 -0
  399. /package/dist/{tcl.json2.js → _virtual/tcl.json.raw2.js} +0 -0
  400. /package/dist/{template.json.js → _virtual/template.json.raw.js} +0 -0
  401. /package/dist/{typescript.json.js → _virtual/typescript.json.raw.js} +0 -0
  402. /package/dist/{vs2019_dark.json.js → _virtual/vs2019_dark.json.raw.js} +0 -0
  403. /package/dist/{vs2019_light.json.js → _virtual/vs2019_light.json.raw.js} +0 -0
package/dist/index.js DELETED
@@ -1,2210 +0,0 @@
1
- import { g as getAugmentedNamespace, c as commonjsGlobal, a as getDefaultExportFromCjs } from './_commonjsHelpers.js';
2
- import * as monaco$2 from 'monaco-editor/esm/vs/editor/editor.api';
3
-
4
- function _mergeNamespaces(n, m) {
5
- m.forEach(function (e) {
6
- e && typeof e !== 'string' && !Array.isArray(e) && Object.keys(e).forEach(function (k) {
7
- if (k !== 'default' && !(k in n)) {
8
- var d = Object.getOwnPropertyDescriptor(e, k);
9
- Object.defineProperty(n, k, d.get ? d : {
10
- enumerable: true,
11
- get: function () { return e[k]; }
12
- });
13
- }
14
- });
15
- });
16
- return Object.freeze(n);
17
- }
18
-
19
- var lib = {};
20
-
21
- var emacs = {};
22
-
23
- var require$$0 = /*@__PURE__*/getAugmentedNamespace(monaco$2);
24
-
25
- /**
26
- * lodash (Custom Build) <https://lodash.com/>
27
- * Build: `lodash modularize exports="npm" -o ./`
28
- * Copyright jQuery Foundation and other contributors <https://jquery.org/>
29
- * Released under MIT license <https://lodash.com/license>
30
- * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
31
- * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
32
- */
33
-
34
- /** Used as the `TypeError` message for "Functions" methods. */
35
- var FUNC_ERROR_TEXT = 'Expected a function';
36
-
37
- /** Used as references for various `Number` constants. */
38
- var NAN = 0 / 0;
39
-
40
- /** `Object#toString` result references. */
41
- var symbolTag$1 = '[object Symbol]';
42
-
43
- /** Used to match leading and trailing whitespace. */
44
- var reTrim = /^\s+|\s+$/g;
45
-
46
- /** Used to detect bad signed hexadecimal string values. */
47
- var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
48
-
49
- /** Used to detect binary string values. */
50
- var reIsBinary = /^0b[01]+$/i;
51
-
52
- /** Used to detect octal string values. */
53
- var reIsOctal = /^0o[0-7]+$/i;
54
-
55
- /** Built-in method references without a dependency on `root`. */
56
- var freeParseInt = parseInt;
57
-
58
- /** Detect free variable `global` from Node.js. */
59
- var freeGlobal$1 = typeof commonjsGlobal == 'object' && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
60
-
61
- /** Detect free variable `self`. */
62
- var freeSelf$1 = typeof self == 'object' && self && self.Object === Object && self;
63
-
64
- /** Used as a reference to the global object. */
65
- var root$1 = freeGlobal$1 || freeSelf$1 || Function('return this')();
66
-
67
- /** Used for built-in method references. */
68
- var objectProto$1 = Object.prototype;
69
-
70
- /**
71
- * Used to resolve the
72
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
73
- * of values.
74
- */
75
- var objectToString$1 = objectProto$1.toString;
76
-
77
- /* Built-in method references for those with the same name as other `lodash` methods. */
78
- var nativeMax = Math.max,
79
- nativeMin = Math.min;
80
-
81
- /**
82
- * Gets the timestamp of the number of milliseconds that have elapsed since
83
- * the Unix epoch (1 January 1970 00:00:00 UTC).
84
- *
85
- * @static
86
- * @memberOf _
87
- * @since 2.4.0
88
- * @category Date
89
- * @returns {number} Returns the timestamp.
90
- * @example
91
- *
92
- * _.defer(function(stamp) {
93
- * console.log(_.now() - stamp);
94
- * }, _.now());
95
- * // => Logs the number of milliseconds it took for the deferred invocation.
96
- */
97
- var now = function() {
98
- return root$1.Date.now();
99
- };
100
-
101
- /**
102
- * Creates a debounced function that delays invoking `func` until after `wait`
103
- * milliseconds have elapsed since the last time the debounced function was
104
- * invoked. The debounced function comes with a `cancel` method to cancel
105
- * delayed `func` invocations and a `flush` method to immediately invoke them.
106
- * Provide `options` to indicate whether `func` should be invoked on the
107
- * leading and/or trailing edge of the `wait` timeout. The `func` is invoked
108
- * with the last arguments provided to the debounced function. Subsequent
109
- * calls to the debounced function return the result of the last `func`
110
- * invocation.
111
- *
112
- * **Note:** If `leading` and `trailing` options are `true`, `func` is
113
- * invoked on the trailing edge of the timeout only if the debounced function
114
- * is invoked more than once during the `wait` timeout.
115
- *
116
- * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred
117
- * until to the next tick, similar to `setTimeout` with a timeout of `0`.
118
- *
119
- * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)
120
- * for details over the differences between `_.debounce` and `_.throttle`.
121
- *
122
- * @static
123
- * @memberOf _
124
- * @since 0.1.0
125
- * @category Function
126
- * @param {Function} func The function to debounce.
127
- * @param {number} [wait=0] The number of milliseconds to delay.
128
- * @param {Object} [options={}] The options object.
129
- * @param {boolean} [options.leading=false]
130
- * Specify invoking on the leading edge of the timeout.
131
- * @param {number} [options.maxWait]
132
- * The maximum time `func` is allowed to be delayed before it's invoked.
133
- * @param {boolean} [options.trailing=true]
134
- * Specify invoking on the trailing edge of the timeout.
135
- * @returns {Function} Returns the new debounced function.
136
- * @example
137
- *
138
- * // Avoid costly calculations while the window size is in flux.
139
- * jQuery(window).on('resize', _.debounce(calculateLayout, 150));
140
- *
141
- * // Invoke `sendMail` when clicked, debouncing subsequent calls.
142
- * jQuery(element).on('click', _.debounce(sendMail, 300, {
143
- * 'leading': true,
144
- * 'trailing': false
145
- * }));
146
- *
147
- * // Ensure `batchLog` is invoked once after 1 second of debounced calls.
148
- * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 });
149
- * var source = new EventSource('/stream');
150
- * jQuery(source).on('message', debounced);
151
- *
152
- * // Cancel the trailing debounced invocation.
153
- * jQuery(window).on('popstate', debounced.cancel);
154
- */
155
- function debounce(func, wait, options) {
156
- var lastArgs,
157
- lastThis,
158
- maxWait,
159
- result,
160
- timerId,
161
- lastCallTime,
162
- lastInvokeTime = 0,
163
- leading = false,
164
- maxing = false,
165
- trailing = true;
166
-
167
- if (typeof func != 'function') {
168
- throw new TypeError(FUNC_ERROR_TEXT);
169
- }
170
- wait = toNumber(wait) || 0;
171
- if (isObject(options)) {
172
- leading = !!options.leading;
173
- maxing = 'maxWait' in options;
174
- maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;
175
- trailing = 'trailing' in options ? !!options.trailing : trailing;
176
- }
177
-
178
- function invokeFunc(time) {
179
- var args = lastArgs,
180
- thisArg = lastThis;
181
-
182
- lastArgs = lastThis = undefined;
183
- lastInvokeTime = time;
184
- result = func.apply(thisArg, args);
185
- return result;
186
- }
187
-
188
- function leadingEdge(time) {
189
- // Reset any `maxWait` timer.
190
- lastInvokeTime = time;
191
- // Start the timer for the trailing edge.
192
- timerId = setTimeout(timerExpired, wait);
193
- // Invoke the leading edge.
194
- return leading ? invokeFunc(time) : result;
195
- }
196
-
197
- function remainingWait(time) {
198
- var timeSinceLastCall = time - lastCallTime,
199
- timeSinceLastInvoke = time - lastInvokeTime,
200
- result = wait - timeSinceLastCall;
201
-
202
- return maxing ? nativeMin(result, maxWait - timeSinceLastInvoke) : result;
203
- }
204
-
205
- function shouldInvoke(time) {
206
- var timeSinceLastCall = time - lastCallTime,
207
- timeSinceLastInvoke = time - lastInvokeTime;
208
-
209
- // Either this is the first call, activity has stopped and we're at the
210
- // trailing edge, the system time has gone backwards and we're treating
211
- // it as the trailing edge, or we've hit the `maxWait` limit.
212
- return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||
213
- (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));
214
- }
215
-
216
- function timerExpired() {
217
- var time = now();
218
- if (shouldInvoke(time)) {
219
- return trailingEdge(time);
220
- }
221
- // Restart the timer.
222
- timerId = setTimeout(timerExpired, remainingWait(time));
223
- }
224
-
225
- function trailingEdge(time) {
226
- timerId = undefined;
227
-
228
- // Only invoke if we have `lastArgs` which means `func` has been
229
- // debounced at least once.
230
- if (trailing && lastArgs) {
231
- return invokeFunc(time);
232
- }
233
- lastArgs = lastThis = undefined;
234
- return result;
235
- }
236
-
237
- function cancel() {
238
- if (timerId !== undefined) {
239
- clearTimeout(timerId);
240
- }
241
- lastInvokeTime = 0;
242
- lastArgs = lastCallTime = lastThis = timerId = undefined;
243
- }
244
-
245
- function flush() {
246
- return timerId === undefined ? result : trailingEdge(now());
247
- }
248
-
249
- function debounced() {
250
- var time = now(),
251
- isInvoking = shouldInvoke(time);
252
-
253
- lastArgs = arguments;
254
- lastThis = this;
255
- lastCallTime = time;
256
-
257
- if (isInvoking) {
258
- if (timerId === undefined) {
259
- return leadingEdge(lastCallTime);
260
- }
261
- if (maxing) {
262
- // Handle invocations in a tight loop.
263
- timerId = setTimeout(timerExpired, wait);
264
- return invokeFunc(lastCallTime);
265
- }
266
- }
267
- if (timerId === undefined) {
268
- timerId = setTimeout(timerExpired, wait);
269
- }
270
- return result;
271
- }
272
- debounced.cancel = cancel;
273
- debounced.flush = flush;
274
- return debounced;
275
- }
276
-
277
- /**
278
- * Creates a throttled function that only invokes `func` at most once per
279
- * every `wait` milliseconds. The throttled function comes with a `cancel`
280
- * method to cancel delayed `func` invocations and a `flush` method to
281
- * immediately invoke them. Provide `options` to indicate whether `func`
282
- * should be invoked on the leading and/or trailing edge of the `wait`
283
- * timeout. The `func` is invoked with the last arguments provided to the
284
- * throttled function. Subsequent calls to the throttled function return the
285
- * result of the last `func` invocation.
286
- *
287
- * **Note:** If `leading` and `trailing` options are `true`, `func` is
288
- * invoked on the trailing edge of the timeout only if the throttled function
289
- * is invoked more than once during the `wait` timeout.
290
- *
291
- * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred
292
- * until to the next tick, similar to `setTimeout` with a timeout of `0`.
293
- *
294
- * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)
295
- * for details over the differences between `_.throttle` and `_.debounce`.
296
- *
297
- * @static
298
- * @memberOf _
299
- * @since 0.1.0
300
- * @category Function
301
- * @param {Function} func The function to throttle.
302
- * @param {number} [wait=0] The number of milliseconds to throttle invocations to.
303
- * @param {Object} [options={}] The options object.
304
- * @param {boolean} [options.leading=true]
305
- * Specify invoking on the leading edge of the timeout.
306
- * @param {boolean} [options.trailing=true]
307
- * Specify invoking on the trailing edge of the timeout.
308
- * @returns {Function} Returns the new throttled function.
309
- * @example
310
- *
311
- * // Avoid excessively updating the position while scrolling.
312
- * jQuery(window).on('scroll', _.throttle(updatePosition, 100));
313
- *
314
- * // Invoke `renewToken` when the click event is fired, but not more than once every 5 minutes.
315
- * var throttled = _.throttle(renewToken, 300000, { 'trailing': false });
316
- * jQuery(element).on('click', throttled);
317
- *
318
- * // Cancel the trailing throttled invocation.
319
- * jQuery(window).on('popstate', throttled.cancel);
320
- */
321
- function throttle$1(func, wait, options) {
322
- var leading = true,
323
- trailing = true;
324
-
325
- if (typeof func != 'function') {
326
- throw new TypeError(FUNC_ERROR_TEXT);
327
- }
328
- if (isObject(options)) {
329
- leading = 'leading' in options ? !!options.leading : leading;
330
- trailing = 'trailing' in options ? !!options.trailing : trailing;
331
- }
332
- return debounce(func, wait, {
333
- 'leading': leading,
334
- 'maxWait': wait,
335
- 'trailing': trailing
336
- });
337
- }
338
-
339
- /**
340
- * Checks if `value` is the
341
- * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
342
- * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
343
- *
344
- * @static
345
- * @memberOf _
346
- * @since 0.1.0
347
- * @category Lang
348
- * @param {*} value The value to check.
349
- * @returns {boolean} Returns `true` if `value` is an object, else `false`.
350
- * @example
351
- *
352
- * _.isObject({});
353
- * // => true
354
- *
355
- * _.isObject([1, 2, 3]);
356
- * // => true
357
- *
358
- * _.isObject(_.noop);
359
- * // => true
360
- *
361
- * _.isObject(null);
362
- * // => false
363
- */
364
- function isObject(value) {
365
- var type = typeof value;
366
- return !!value && (type == 'object' || type == 'function');
367
- }
368
-
369
- /**
370
- * Checks if `value` is object-like. A value is object-like if it's not `null`
371
- * and has a `typeof` result of "object".
372
- *
373
- * @static
374
- * @memberOf _
375
- * @since 4.0.0
376
- * @category Lang
377
- * @param {*} value The value to check.
378
- * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
379
- * @example
380
- *
381
- * _.isObjectLike({});
382
- * // => true
383
- *
384
- * _.isObjectLike([1, 2, 3]);
385
- * // => true
386
- *
387
- * _.isObjectLike(_.noop);
388
- * // => false
389
- *
390
- * _.isObjectLike(null);
391
- * // => false
392
- */
393
- function isObjectLike$1(value) {
394
- return !!value && typeof value == 'object';
395
- }
396
-
397
- /**
398
- * Checks if `value` is classified as a `Symbol` primitive or object.
399
- *
400
- * @static
401
- * @memberOf _
402
- * @since 4.0.0
403
- * @category Lang
404
- * @param {*} value The value to check.
405
- * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.
406
- * @example
407
- *
408
- * _.isSymbol(Symbol.iterator);
409
- * // => true
410
- *
411
- * _.isSymbol('abc');
412
- * // => false
413
- */
414
- function isSymbol$1(value) {
415
- return typeof value == 'symbol' ||
416
- (isObjectLike$1(value) && objectToString$1.call(value) == symbolTag$1);
417
- }
418
-
419
- /**
420
- * Converts `value` to a number.
421
- *
422
- * @static
423
- * @memberOf _
424
- * @since 4.0.0
425
- * @category Lang
426
- * @param {*} value The value to process.
427
- * @returns {number} Returns the number.
428
- * @example
429
- *
430
- * _.toNumber(3.2);
431
- * // => 3.2
432
- *
433
- * _.toNumber(Number.MIN_VALUE);
434
- * // => 5e-324
435
- *
436
- * _.toNumber(Infinity);
437
- * // => Infinity
438
- *
439
- * _.toNumber('3.2');
440
- * // => 3.2
441
- */
442
- function toNumber(value) {
443
- if (typeof value == 'number') {
444
- return value;
445
- }
446
- if (isSymbol$1(value)) {
447
- return NAN;
448
- }
449
- if (isObject(value)) {
450
- var other = typeof value.valueOf == 'function' ? value.valueOf() : value;
451
- value = isObject(other) ? (other + '') : other;
452
- }
453
- if (typeof value != 'string') {
454
- return value === 0 ? value : +value;
455
- }
456
- value = value.replace(reTrim, '');
457
- var isBinary = reIsBinary.test(value);
458
- return (isBinary || reIsOctal.test(value))
459
- ? freeParseInt(value.slice(2), isBinary ? 2 : 8)
460
- : (reIsBadHex.test(value) ? NAN : +value);
461
- }
462
-
463
- var lodash_throttle = throttle$1;
464
-
465
- /**
466
- * lodash (Custom Build) <https://lodash.com/>
467
- * Build: `lodash modularize exports="npm" -o ./`
468
- * Copyright jQuery Foundation and other contributors <https://jquery.org/>
469
- * Released under MIT license <https://lodash.com/license>
470
- * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
471
- * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
472
- */
473
-
474
- /** Used as references for various `Number` constants. */
475
- var INFINITY = 1 / 0;
476
-
477
- /** `Object#toString` result references. */
478
- var symbolTag = '[object Symbol]';
479
-
480
- /** Used to match words composed of alphanumeric characters. */
481
- var reAsciiWord = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;
482
-
483
- /** Used to match Latin Unicode letters (excluding mathematical operators). */
484
- var reLatin = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g;
485
-
486
- /** Used to compose unicode character classes. */
487
- var rsAstralRange = '\\ud800-\\udfff',
488
- rsComboMarksRange = '\\u0300-\\u036f\\ufe20-\\ufe23',
489
- rsComboSymbolsRange = '\\u20d0-\\u20f0',
490
- rsDingbatRange = '\\u2700-\\u27bf',
491
- rsLowerRange = 'a-z\\xdf-\\xf6\\xf8-\\xff',
492
- rsMathOpRange = '\\xac\\xb1\\xd7\\xf7',
493
- rsNonCharRange = '\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf',
494
- rsPunctuationRange = '\\u2000-\\u206f',
495
- rsSpaceRange = ' \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000',
496
- rsUpperRange = 'A-Z\\xc0-\\xd6\\xd8-\\xde',
497
- rsVarRange = '\\ufe0e\\ufe0f',
498
- rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;
499
-
500
- /** Used to compose unicode capture groups. */
501
- var rsApos = "['\u2019]",
502
- rsBreak = '[' + rsBreakRange + ']',
503
- rsCombo = '[' + rsComboMarksRange + rsComboSymbolsRange + ']',
504
- rsDigits = '\\d+',
505
- rsDingbat = '[' + rsDingbatRange + ']',
506
- rsLower = '[' + rsLowerRange + ']',
507
- rsMisc = '[^' + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + ']',
508
- rsFitz = '\\ud83c[\\udffb-\\udfff]',
509
- rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',
510
- rsNonAstral = '[^' + rsAstralRange + ']',
511
- rsRegional = '(?:\\ud83c[\\udde6-\\uddff]){2}',
512
- rsSurrPair = '[\\ud800-\\udbff][\\udc00-\\udfff]',
513
- rsUpper = '[' + rsUpperRange + ']',
514
- rsZWJ = '\\u200d';
515
-
516
- /** Used to compose unicode regexes. */
517
- var rsLowerMisc = '(?:' + rsLower + '|' + rsMisc + ')',
518
- rsUpperMisc = '(?:' + rsUpper + '|' + rsMisc + ')',
519
- rsOptLowerContr = '(?:' + rsApos + '(?:d|ll|m|re|s|t|ve))?',
520
- rsOptUpperContr = '(?:' + rsApos + '(?:D|LL|M|RE|S|T|VE))?',
521
- reOptMod = rsModifier + '?',
522
- rsOptVar = '[' + rsVarRange + ']?',
523
- rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',
524
- rsSeq = rsOptVar + reOptMod + rsOptJoin,
525
- rsEmoji = '(?:' + [rsDingbat, rsRegional, rsSurrPair].join('|') + ')' + rsSeq;
526
-
527
- /** Used to match apostrophes. */
528
- var reApos = RegExp(rsApos, 'g');
529
-
530
- /**
531
- * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and
532
- * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols).
533
- */
534
- var reComboMark = RegExp(rsCombo, 'g');
535
-
536
- /** Used to match complex or compound words. */
537
- var reUnicodeWord = RegExp([
538
- rsUpper + '?' + rsLower + '+' + rsOptLowerContr + '(?=' + [rsBreak, rsUpper, '$'].join('|') + ')',
539
- rsUpperMisc + '+' + rsOptUpperContr + '(?=' + [rsBreak, rsUpper + rsLowerMisc, '$'].join('|') + ')',
540
- rsUpper + '?' + rsLowerMisc + '+' + rsOptLowerContr,
541
- rsUpper + '+' + rsOptUpperContr,
542
- rsDigits,
543
- rsEmoji
544
- ].join('|'), 'g');
545
-
546
- /** Used to detect strings that need a more robust regexp to match words. */
547
- var reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2,}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;
548
-
549
- /** Used to map Latin Unicode letters to basic Latin letters. */
550
- var deburredLetters = {
551
- // Latin-1 Supplement block.
552
- '\xc0': 'A', '\xc1': 'A', '\xc2': 'A', '\xc3': 'A', '\xc4': 'A', '\xc5': 'A',
553
- '\xe0': 'a', '\xe1': 'a', '\xe2': 'a', '\xe3': 'a', '\xe4': 'a', '\xe5': 'a',
554
- '\xc7': 'C', '\xe7': 'c',
555
- '\xd0': 'D', '\xf0': 'd',
556
- '\xc8': 'E', '\xc9': 'E', '\xca': 'E', '\xcb': 'E',
557
- '\xe8': 'e', '\xe9': 'e', '\xea': 'e', '\xeb': 'e',
558
- '\xcc': 'I', '\xcd': 'I', '\xce': 'I', '\xcf': 'I',
559
- '\xec': 'i', '\xed': 'i', '\xee': 'i', '\xef': 'i',
560
- '\xd1': 'N', '\xf1': 'n',
561
- '\xd2': 'O', '\xd3': 'O', '\xd4': 'O', '\xd5': 'O', '\xd6': 'O', '\xd8': 'O',
562
- '\xf2': 'o', '\xf3': 'o', '\xf4': 'o', '\xf5': 'o', '\xf6': 'o', '\xf8': 'o',
563
- '\xd9': 'U', '\xda': 'U', '\xdb': 'U', '\xdc': 'U',
564
- '\xf9': 'u', '\xfa': 'u', '\xfb': 'u', '\xfc': 'u',
565
- '\xdd': 'Y', '\xfd': 'y', '\xff': 'y',
566
- '\xc6': 'Ae', '\xe6': 'ae',
567
- '\xde': 'Th', '\xfe': 'th',
568
- '\xdf': 'ss',
569
- // Latin Extended-A block.
570
- '\u0100': 'A', '\u0102': 'A', '\u0104': 'A',
571
- '\u0101': 'a', '\u0103': 'a', '\u0105': 'a',
572
- '\u0106': 'C', '\u0108': 'C', '\u010a': 'C', '\u010c': 'C',
573
- '\u0107': 'c', '\u0109': 'c', '\u010b': 'c', '\u010d': 'c',
574
- '\u010e': 'D', '\u0110': 'D', '\u010f': 'd', '\u0111': 'd',
575
- '\u0112': 'E', '\u0114': 'E', '\u0116': 'E', '\u0118': 'E', '\u011a': 'E',
576
- '\u0113': 'e', '\u0115': 'e', '\u0117': 'e', '\u0119': 'e', '\u011b': 'e',
577
- '\u011c': 'G', '\u011e': 'G', '\u0120': 'G', '\u0122': 'G',
578
- '\u011d': 'g', '\u011f': 'g', '\u0121': 'g', '\u0123': 'g',
579
- '\u0124': 'H', '\u0126': 'H', '\u0125': 'h', '\u0127': 'h',
580
- '\u0128': 'I', '\u012a': 'I', '\u012c': 'I', '\u012e': 'I', '\u0130': 'I',
581
- '\u0129': 'i', '\u012b': 'i', '\u012d': 'i', '\u012f': 'i', '\u0131': 'i',
582
- '\u0134': 'J', '\u0135': 'j',
583
- '\u0136': 'K', '\u0137': 'k', '\u0138': 'k',
584
- '\u0139': 'L', '\u013b': 'L', '\u013d': 'L', '\u013f': 'L', '\u0141': 'L',
585
- '\u013a': 'l', '\u013c': 'l', '\u013e': 'l', '\u0140': 'l', '\u0142': 'l',
586
- '\u0143': 'N', '\u0145': 'N', '\u0147': 'N', '\u014a': 'N',
587
- '\u0144': 'n', '\u0146': 'n', '\u0148': 'n', '\u014b': 'n',
588
- '\u014c': 'O', '\u014e': 'O', '\u0150': 'O',
589
- '\u014d': 'o', '\u014f': 'o', '\u0151': 'o',
590
- '\u0154': 'R', '\u0156': 'R', '\u0158': 'R',
591
- '\u0155': 'r', '\u0157': 'r', '\u0159': 'r',
592
- '\u015a': 'S', '\u015c': 'S', '\u015e': 'S', '\u0160': 'S',
593
- '\u015b': 's', '\u015d': 's', '\u015f': 's', '\u0161': 's',
594
- '\u0162': 'T', '\u0164': 'T', '\u0166': 'T',
595
- '\u0163': 't', '\u0165': 't', '\u0167': 't',
596
- '\u0168': 'U', '\u016a': 'U', '\u016c': 'U', '\u016e': 'U', '\u0170': 'U', '\u0172': 'U',
597
- '\u0169': 'u', '\u016b': 'u', '\u016d': 'u', '\u016f': 'u', '\u0171': 'u', '\u0173': 'u',
598
- '\u0174': 'W', '\u0175': 'w',
599
- '\u0176': 'Y', '\u0177': 'y', '\u0178': 'Y',
600
- '\u0179': 'Z', '\u017b': 'Z', '\u017d': 'Z',
601
- '\u017a': 'z', '\u017c': 'z', '\u017e': 'z',
602
- '\u0132': 'IJ', '\u0133': 'ij',
603
- '\u0152': 'Oe', '\u0153': 'oe',
604
- '\u0149': "'n", '\u017f': 'ss'
605
- };
606
-
607
- /** Detect free variable `global` from Node.js. */
608
- var freeGlobal = typeof commonjsGlobal == 'object' && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
609
-
610
- /** Detect free variable `self`. */
611
- var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
612
-
613
- /** Used as a reference to the global object. */
614
- var root = freeGlobal || freeSelf || Function('return this')();
615
-
616
- /**
617
- * A specialized version of `_.reduce` for arrays without support for
618
- * iteratee shorthands.
619
- *
620
- * @private
621
- * @param {Array} [array] The array to iterate over.
622
- * @param {Function} iteratee The function invoked per iteration.
623
- * @param {*} [accumulator] The initial value.
624
- * @param {boolean} [initAccum] Specify using the first element of `array` as
625
- * the initial value.
626
- * @returns {*} Returns the accumulated value.
627
- */
628
- function arrayReduce(array, iteratee, accumulator, initAccum) {
629
- var index = -1,
630
- length = array ? array.length : 0;
631
-
632
- if (initAccum && length) {
633
- accumulator = array[++index];
634
- }
635
- while (++index < length) {
636
- accumulator = iteratee(accumulator, array[index], index, array);
637
- }
638
- return accumulator;
639
- }
640
-
641
- /**
642
- * Splits an ASCII `string` into an array of its words.
643
- *
644
- * @private
645
- * @param {string} The string to inspect.
646
- * @returns {Array} Returns the words of `string`.
647
- */
648
- function asciiWords(string) {
649
- return string.match(reAsciiWord) || [];
650
- }
651
-
652
- /**
653
- * The base implementation of `_.propertyOf` without support for deep paths.
654
- *
655
- * @private
656
- * @param {Object} object The object to query.
657
- * @returns {Function} Returns the new accessor function.
658
- */
659
- function basePropertyOf(object) {
660
- return function(key) {
661
- return object == null ? undefined : object[key];
662
- };
663
- }
664
-
665
- /**
666
- * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A
667
- * letters to basic Latin letters.
668
- *
669
- * @private
670
- * @param {string} letter The matched letter to deburr.
671
- * @returns {string} Returns the deburred letter.
672
- */
673
- var deburrLetter = basePropertyOf(deburredLetters);
674
-
675
- /**
676
- * Checks if `string` contains a word composed of Unicode symbols.
677
- *
678
- * @private
679
- * @param {string} string The string to inspect.
680
- * @returns {boolean} Returns `true` if a word is found, else `false`.
681
- */
682
- function hasUnicodeWord(string) {
683
- return reHasUnicodeWord.test(string);
684
- }
685
-
686
- /**
687
- * Splits a Unicode `string` into an array of its words.
688
- *
689
- * @private
690
- * @param {string} The string to inspect.
691
- * @returns {Array} Returns the words of `string`.
692
- */
693
- function unicodeWords(string) {
694
- return string.match(reUnicodeWord) || [];
695
- }
696
-
697
- /** Used for built-in method references. */
698
- var objectProto = Object.prototype;
699
-
700
- /**
701
- * Used to resolve the
702
- * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
703
- * of values.
704
- */
705
- var objectToString = objectProto.toString;
706
-
707
- /** Built-in value references. */
708
- var Symbol = root.Symbol;
709
-
710
- /** Used to convert symbols to primitives and strings. */
711
- var symbolProto = Symbol ? Symbol.prototype : undefined,
712
- symbolToString = symbolProto ? symbolProto.toString : undefined;
713
-
714
- /**
715
- * The base implementation of `_.toString` which doesn't convert nullish
716
- * values to empty strings.
717
- *
718
- * @private
719
- * @param {*} value The value to process.
720
- * @returns {string} Returns the string.
721
- */
722
- function baseToString(value) {
723
- // Exit early for strings to avoid a performance hit in some environments.
724
- if (typeof value == 'string') {
725
- return value;
726
- }
727
- if (isSymbol(value)) {
728
- return symbolToString ? symbolToString.call(value) : '';
729
- }
730
- var result = (value + '');
731
- return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;
732
- }
733
-
734
- /**
735
- * Creates a function like `_.camelCase`.
736
- *
737
- * @private
738
- * @param {Function} callback The function to combine each word.
739
- * @returns {Function} Returns the new compounder function.
740
- */
741
- function createCompounder(callback) {
742
- return function(string) {
743
- return arrayReduce(words(deburr(string).replace(reApos, '')), callback, '');
744
- };
745
- }
746
-
747
- /**
748
- * Checks if `value` is object-like. A value is object-like if it's not `null`
749
- * and has a `typeof` result of "object".
750
- *
751
- * @static
752
- * @memberOf _
753
- * @since 4.0.0
754
- * @category Lang
755
- * @param {*} value The value to check.
756
- * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
757
- * @example
758
- *
759
- * _.isObjectLike({});
760
- * // => true
761
- *
762
- * _.isObjectLike([1, 2, 3]);
763
- * // => true
764
- *
765
- * _.isObjectLike(_.noop);
766
- * // => false
767
- *
768
- * _.isObjectLike(null);
769
- * // => false
770
- */
771
- function isObjectLike(value) {
772
- return !!value && typeof value == 'object';
773
- }
774
-
775
- /**
776
- * Checks if `value` is classified as a `Symbol` primitive or object.
777
- *
778
- * @static
779
- * @memberOf _
780
- * @since 4.0.0
781
- * @category Lang
782
- * @param {*} value The value to check.
783
- * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.
784
- * @example
785
- *
786
- * _.isSymbol(Symbol.iterator);
787
- * // => true
788
- *
789
- * _.isSymbol('abc');
790
- * // => false
791
- */
792
- function isSymbol(value) {
793
- return typeof value == 'symbol' ||
794
- (isObjectLike(value) && objectToString.call(value) == symbolTag);
795
- }
796
-
797
- /**
798
- * Converts `value` to a string. An empty string is returned for `null`
799
- * and `undefined` values. The sign of `-0` is preserved.
800
- *
801
- * @static
802
- * @memberOf _
803
- * @since 4.0.0
804
- * @category Lang
805
- * @param {*} value The value to process.
806
- * @returns {string} Returns the string.
807
- * @example
808
- *
809
- * _.toString(null);
810
- * // => ''
811
- *
812
- * _.toString(-0);
813
- * // => '-0'
814
- *
815
- * _.toString([1, 2, 3]);
816
- * // => '1,2,3'
817
- */
818
- function toString(value) {
819
- return value == null ? '' : baseToString(value);
820
- }
821
-
822
- /**
823
- * Deburrs `string` by converting
824
- * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table)
825
- * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A)
826
- * letters to basic Latin letters and removing
827
- * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks).
828
- *
829
- * @static
830
- * @memberOf _
831
- * @since 3.0.0
832
- * @category String
833
- * @param {string} [string=''] The string to deburr.
834
- * @returns {string} Returns the deburred string.
835
- * @example
836
- *
837
- * _.deburr('déjà vu');
838
- * // => 'deja vu'
839
- */
840
- function deburr(string) {
841
- string = toString(string);
842
- return string && string.replace(reLatin, deburrLetter).replace(reComboMark, '');
843
- }
844
-
845
- /**
846
- * Converts `string` to
847
- * [kebab case](https://en.wikipedia.org/wiki/Letter_case#Special_case_styles).
848
- *
849
- * @static
850
- * @memberOf _
851
- * @since 3.0.0
852
- * @category String
853
- * @param {string} [string=''] The string to convert.
854
- * @returns {string} Returns the kebab cased string.
855
- * @example
856
- *
857
- * _.kebabCase('Foo Bar');
858
- * // => 'foo-bar'
859
- *
860
- * _.kebabCase('fooBar');
861
- * // => 'foo-bar'
862
- *
863
- * _.kebabCase('__FOO_BAR__');
864
- * // => 'foo-bar'
865
- */
866
- var kebabCase$1 = createCompounder(function(result, word, index) {
867
- return result + (index ? '-' : '') + word.toLowerCase();
868
- });
869
-
870
- /**
871
- * Splits `string` into an array of its words.
872
- *
873
- * @static
874
- * @memberOf _
875
- * @since 3.0.0
876
- * @category String
877
- * @param {string} [string=''] The string to inspect.
878
- * @param {RegExp|string} [pattern] The pattern to match words.
879
- * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
880
- * @returns {Array} Returns the words of `string`.
881
- * @example
882
- *
883
- * _.words('fred, barney, & pebbles');
884
- * // => ['fred', 'barney', 'pebbles']
885
- *
886
- * _.words('fred, barney, & pebbles', /[^, ]+/g);
887
- * // => ['fred', 'barney', '&', 'pebbles']
888
- */
889
- function words(string, pattern, guard) {
890
- string = toString(string);
891
- pattern = guard ? undefined : pattern;
892
-
893
- if (pattern === undefined) {
894
- return hasUnicodeWord(string) ? unicodeWords(string) : asciiWords(string);
895
- }
896
- return string.match(pattern) || [];
897
- }
898
-
899
- var lodash_kebabcase = kebabCase$1;
900
-
901
- var commands = {};
902
-
903
- var actions = {};
904
-
905
- (function (exports) {
906
- var __extends = (commonjsGlobal && commonjsGlobal.__extends) || (function () {
907
- var extendStatics = function (d, b) {
908
- extendStatics = Object.setPrototypeOf ||
909
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
910
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
911
- return extendStatics(d, b);
912
- };
913
- return function (d, b) {
914
- if (typeof b !== "function" && b !== null)
915
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
916
- extendStatics(d, b);
917
- function __() { this.constructor = d; }
918
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
919
- };
920
- })();
921
- Object.defineProperty(exports, "__esModule", { value: true });
922
- exports.DeleteLines = exports.SearchReplace = exports.Search = exports.InvertSelection = exports.GotoLine = exports.RotateCursorOnScreen = exports.InsertTabs = exports.RevealToBottomAction = exports.RevealToCenterAction = exports.RevealToTopAction = exports.RevealEditorAction = exports.YankRotate = exports.YankSelectionToRing = exports.Yank = exports.RedoAction = exports.UndoAction = exports.KeyBoardQuit = exports.MoveCursorTop = exports.MoveCursorBottom = exports.MoveCursorWordLeft = exports.MoveCursorWordRight = exports.MoveCursorToLineStart = exports.MoveCursorToLineEnd = exports.MoveCursorRight = exports.MoveCursorLeft = exports.MoveCursorDown = exports.MoveCursorUp = exports.SetMark = exports.InsertLineAfter = exports.InsertLineBelow = exports.KillLines = exports.KillSelection = exports.BaseAction = exports.SOURCE = void 0;
923
- var monaco = require$$0;
924
- exports.SOURCE = 'extension.emacs';
925
- function moveCursor(editor, hasSelection, direction, unit, repeat) {
926
- if (repeat === void 0) { repeat = 1; }
927
- var action = "cursor".concat(unit === 'word' ? 'Word' : '').concat(direction).concat(hasSelection ? 'Select' : '');
928
- for (var i = 0; i < repeat; i++) {
929
- editor.trigger(exports.SOURCE, action, null);
930
- }
931
- }
932
- var BaseAction = (function () {
933
- function BaseAction() {
934
- this.description = '';
935
- }
936
- return BaseAction;
937
- }());
938
- exports.BaseAction = BaseAction;
939
- var TriggerAction = (function (_super) {
940
- __extends(TriggerAction, _super);
941
- function TriggerAction(trigger) {
942
- var _this = _super.call(this) || this;
943
- _this.trigger = trigger;
944
- return _this;
945
- }
946
- TriggerAction.prototype.run = function (editor) {
947
- editor.trigger(exports.SOURCE, this.trigger, {});
948
- };
949
- return TriggerAction;
950
- }(BaseAction));
951
- var KillSelection = (function (_super) {
952
- __extends(KillSelection, _super);
953
- function KillSelection() {
954
- return _super !== null && _super.apply(this, arguments) || this;
955
- }
956
- KillSelection.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
957
- var selections = editor.getSelections();
958
- if (!selections.length) {
959
- return;
960
- }
961
- selections.forEach(function (sel) {
962
- var text = editor.getModel().getValueInRange(sel);
963
- ext.state.addToRing(text);
964
- editor.executeEdits(exports.SOURCE, [{
965
- range: sel,
966
- text: '',
967
- }]);
968
- });
969
- };
970
- return KillSelection;
971
- }(BaseAction));
972
- exports.KillSelection = KillSelection;
973
- var KillLines = (function (_super) {
974
- __extends(KillLines, _super);
975
- function KillLines() {
976
- return _super !== null && _super.apply(this, arguments) || this;
977
- }
978
- KillLines.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
979
- ext.selectionMode = false;
980
- var model = editor.getModel();
981
- var pos = ext.getCursorAnchor();
982
- var endPos;
983
- if (repeat === 1) {
984
- var lineLength = model.getLineLength(pos.lineNumber);
985
- var isAtEnd = pos.column === lineLength + 1;
986
- if (!lineLength || isAtEnd) {
987
- if (repeatedTrigger) {
988
- ext.state.growRingTop(model.getEOL());
989
- }
990
- else {
991
- ext.state.addToRing(model.getEOL());
992
- }
993
- editor.trigger(exports.SOURCE, 'deleteAllRight', null);
994
- return;
995
- }
996
- else {
997
- endPos = new monaco.Position(pos.lineNumber, model.getLineLength(pos.lineNumber) + 1);
998
- }
999
- }
1000
- else {
1001
- var totalLines = model.getLineCount();
1002
- var endLine = (pos.lineNumber + repeat) > totalLines ? totalLines : (pos.lineNumber + repeat);
1003
- endPos = new monaco.Position(endLine, model.getLineLength(endLine) + 1);
1004
- }
1005
- var range = monaco.Range.fromPositions(pos, endPos);
1006
- if (repeatedTrigger) {
1007
- ext.state.growRingTop(model.getValueInRange(range));
1008
- }
1009
- else {
1010
- ext.state.addToRing(model.getValueInRange(range));
1011
- }
1012
- editor.executeEdits(exports.SOURCE, [{
1013
- range: range,
1014
- text: '',
1015
- }]);
1016
- editor.setSelection(monaco.Selection.fromPositions(pos, pos));
1017
- };
1018
- return KillLines;
1019
- }(BaseAction));
1020
- exports.KillLines = KillLines;
1021
- var InsertLineBelow = (function (_super) {
1022
- __extends(InsertLineBelow, _super);
1023
- function InsertLineBelow() {
1024
- return _super !== null && _super.apply(this, arguments) || this;
1025
- }
1026
- InsertLineBelow.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1027
- var pos = editor.getPosition();
1028
- editor.trigger(exports.SOURCE, 'editor.action.insertLineAfter', null);
1029
- editor.setPosition(pos);
1030
- };
1031
- return InsertLineBelow;
1032
- }(BaseAction));
1033
- exports.InsertLineBelow = InsertLineBelow;
1034
- var InsertLineAfter = (function (_super) {
1035
- __extends(InsertLineAfter, _super);
1036
- function InsertLineAfter() {
1037
- return _super !== null && _super.apply(this, arguments) || this;
1038
- }
1039
- InsertLineAfter.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1040
- var text = '';
1041
- for (var i = 0; i < repeat; i++) {
1042
- text += editor.getModel().getEOL();
1043
- }
1044
- ext.selectionMode = false;
1045
- var pos = ext.getCursorAnchor();
1046
- editor.executeEdits(exports.SOURCE, [{
1047
- range: monaco.Range.fromPositions(pos),
1048
- text: text,
1049
- forceMoveMarkers: true,
1050
- }]);
1051
- };
1052
- return InsertLineAfter;
1053
- }(BaseAction));
1054
- exports.InsertLineAfter = InsertLineAfter;
1055
- var SetMark = (function (_super) {
1056
- __extends(SetMark, _super);
1057
- function SetMark() {
1058
- return _super !== null && _super.apply(this, arguments) || this;
1059
- }
1060
- SetMark.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1061
- ext.selectionMode;
1062
- var sel = editor.getSelection();
1063
- var selEmpty = sel.isEmpty();
1064
- if (!selEmpty) {
1065
- var dir = sel.getDirection();
1066
- if (dir === monaco.SelectionDirection.LTR) {
1067
- editor.setSelection(monaco.Selection.fromPositions(sel.getEndPosition(), sel.getEndPosition()));
1068
- }
1069
- else {
1070
- editor.setSelection(monaco.Selection.fromPositions(sel.getStartPosition(), sel.getStartPosition()));
1071
- }
1072
- }
1073
- if (selEmpty && ext.selectionMode) {
1074
- ext.selectionMode = false;
1075
- }
1076
- else {
1077
- ext.selectionMode = true;
1078
- }
1079
- };
1080
- return SetMark;
1081
- }(BaseAction));
1082
- exports.SetMark = SetMark;
1083
- var MoveCursorAction = (function (_super) {
1084
- __extends(MoveCursorAction, _super);
1085
- function MoveCursorAction() {
1086
- var _this = _super !== null && _super.apply(this, arguments) || this;
1087
- _this.unit = 'char';
1088
- return _this;
1089
- }
1090
- MoveCursorAction.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1091
- moveCursor(editor, ext.selectionMode, this.direction, this.unit, repeat);
1092
- };
1093
- return MoveCursorAction;
1094
- }(BaseAction));
1095
- var MoveCursorUp = (function (_super) {
1096
- __extends(MoveCursorUp, _super);
1097
- function MoveCursorUp() {
1098
- var _this = _super !== null && _super.apply(this, arguments) || this;
1099
- _this.direction = 'Up';
1100
- return _this;
1101
- }
1102
- return MoveCursorUp;
1103
- }(MoveCursorAction));
1104
- exports.MoveCursorUp = MoveCursorUp;
1105
- var MoveCursorDown = (function (_super) {
1106
- __extends(MoveCursorDown, _super);
1107
- function MoveCursorDown() {
1108
- var _this = _super !== null && _super.apply(this, arguments) || this;
1109
- _this.direction = 'Down';
1110
- return _this;
1111
- }
1112
- return MoveCursorDown;
1113
- }(MoveCursorAction));
1114
- exports.MoveCursorDown = MoveCursorDown;
1115
- var MoveCursorLeft = (function (_super) {
1116
- __extends(MoveCursorLeft, _super);
1117
- function MoveCursorLeft() {
1118
- var _this = _super !== null && _super.apply(this, arguments) || this;
1119
- _this.direction = 'Left';
1120
- return _this;
1121
- }
1122
- return MoveCursorLeft;
1123
- }(MoveCursorAction));
1124
- exports.MoveCursorLeft = MoveCursorLeft;
1125
- var MoveCursorRight = (function (_super) {
1126
- __extends(MoveCursorRight, _super);
1127
- function MoveCursorRight() {
1128
- var _this = _super !== null && _super.apply(this, arguments) || this;
1129
- _this.direction = 'Right';
1130
- return _this;
1131
- }
1132
- return MoveCursorRight;
1133
- }(MoveCursorAction));
1134
- exports.MoveCursorRight = MoveCursorRight;
1135
- var MoveCursorToLineEnd = (function (_super) {
1136
- __extends(MoveCursorToLineEnd, _super);
1137
- function MoveCursorToLineEnd() {
1138
- var _this = _super !== null && _super.apply(this, arguments) || this;
1139
- _this.direction = 'End';
1140
- return _this;
1141
- }
1142
- return MoveCursorToLineEnd;
1143
- }(MoveCursorAction));
1144
- exports.MoveCursorToLineEnd = MoveCursorToLineEnd;
1145
- var MoveCursorToLineStart = (function (_super) {
1146
- __extends(MoveCursorToLineStart, _super);
1147
- function MoveCursorToLineStart() {
1148
- var _this = _super !== null && _super.apply(this, arguments) || this;
1149
- _this.direction = 'Home';
1150
- return _this;
1151
- }
1152
- return MoveCursorToLineStart;
1153
- }(MoveCursorAction));
1154
- exports.MoveCursorToLineStart = MoveCursorToLineStart;
1155
- var MoveCursorWordRight = (function (_super) {
1156
- __extends(MoveCursorWordRight, _super);
1157
- function MoveCursorWordRight() {
1158
- var _this = _super !== null && _super.apply(this, arguments) || this;
1159
- _this.unit = 'word';
1160
- return _this;
1161
- }
1162
- return MoveCursorWordRight;
1163
- }(MoveCursorRight));
1164
- exports.MoveCursorWordRight = MoveCursorWordRight;
1165
- var MoveCursorWordLeft = (function (_super) {
1166
- __extends(MoveCursorWordLeft, _super);
1167
- function MoveCursorWordLeft() {
1168
- var _this = _super !== null && _super.apply(this, arguments) || this;
1169
- _this.unit = 'word';
1170
- return _this;
1171
- }
1172
- return MoveCursorWordLeft;
1173
- }(MoveCursorLeft));
1174
- exports.MoveCursorWordLeft = MoveCursorWordLeft;
1175
- var MoveCursorBottom = (function (_super) {
1176
- __extends(MoveCursorBottom, _super);
1177
- function MoveCursorBottom() {
1178
- var _this = _super !== null && _super.apply(this, arguments) || this;
1179
- _this.direction = 'Bottom';
1180
- return _this;
1181
- }
1182
- return MoveCursorBottom;
1183
- }(MoveCursorAction));
1184
- exports.MoveCursorBottom = MoveCursorBottom;
1185
- var MoveCursorTop = (function (_super) {
1186
- __extends(MoveCursorTop, _super);
1187
- function MoveCursorTop() {
1188
- var _this = _super !== null && _super.apply(this, arguments) || this;
1189
- _this.direction = 'Top';
1190
- return _this;
1191
- }
1192
- return MoveCursorTop;
1193
- }(MoveCursorAction));
1194
- exports.MoveCursorTop = MoveCursorTop;
1195
- var KeyBoardQuit = (function (_super) {
1196
- __extends(KeyBoardQuit, _super);
1197
- function KeyBoardQuit() {
1198
- return _super !== null && _super.apply(this, arguments) || this;
1199
- }
1200
- KeyBoardQuit.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1201
- ext.selectionMode = false;
1202
- ext.clearState();
1203
- editor.setPosition(editor.getPosition());
1204
- };
1205
- return KeyBoardQuit;
1206
- }(BaseAction));
1207
- exports.KeyBoardQuit = KeyBoardQuit;
1208
- var HistoryAction = (function (_super) {
1209
- __extends(HistoryAction, _super);
1210
- function HistoryAction() {
1211
- return _super !== null && _super.apply(this, arguments) || this;
1212
- }
1213
- HistoryAction.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1214
- for (var i = 0; i < repeat; i++) {
1215
- editor.trigger(exports.SOURCE, this.action, null);
1216
- }
1217
- };
1218
- return HistoryAction;
1219
- }(BaseAction));
1220
- var UndoAction = (function (_super) {
1221
- __extends(UndoAction, _super);
1222
- function UndoAction() {
1223
- var _this = _super !== null && _super.apply(this, arguments) || this;
1224
- _this.action = 'undo';
1225
- return _this;
1226
- }
1227
- return UndoAction;
1228
- }(HistoryAction));
1229
- exports.UndoAction = UndoAction;
1230
- var RedoAction = (function (_super) {
1231
- __extends(RedoAction, _super);
1232
- function RedoAction() {
1233
- var _this = _super !== null && _super.apply(this, arguments) || this;
1234
- _this.action = 'redo';
1235
- return _this;
1236
- }
1237
- return RedoAction;
1238
- }(HistoryAction));
1239
- exports.RedoAction = RedoAction;
1240
- var Yank = (function (_super) {
1241
- __extends(Yank, _super);
1242
- function Yank() {
1243
- return _super !== null && _super.apply(this, arguments) || this;
1244
- }
1245
- Yank.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1246
- var text = ext.state.getFromRing(repeat);
1247
- if (!text) {
1248
- return;
1249
- }
1250
- var pos = editor.getPosition();
1251
- editor.executeEdits(exports.SOURCE, [{
1252
- range: monaco.Range.fromPositions(pos, pos),
1253
- text: text,
1254
- forceMoveMarkers: true,
1255
- }]);
1256
- };
1257
- return Yank;
1258
- }(BaseAction));
1259
- exports.Yank = Yank;
1260
- var YankSelectionToRing = (function (_super) {
1261
- __extends(YankSelectionToRing, _super);
1262
- function YankSelectionToRing() {
1263
- return _super !== null && _super.apply(this, arguments) || this;
1264
- }
1265
- YankSelectionToRing.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1266
- var sel = editor.getSelection();
1267
- if (sel.isEmpty()) {
1268
- return;
1269
- }
1270
- ext.state.addToRing(editor.getModel().getValueInRange(sel));
1271
- ext.selectionMode = false;
1272
- var pos = ext.getCursorAnchor();
1273
- editor.setSelection(monaco.Selection.fromPositions(pos, pos));
1274
- };
1275
- return YankSelectionToRing;
1276
- }(BaseAction));
1277
- exports.YankSelectionToRing = YankSelectionToRing;
1278
- var YankRotate = (function (_super) {
1279
- __extends(YankRotate, _super);
1280
- function YankRotate() {
1281
- return _super !== null && _super.apply(this, arguments) || this;
1282
- }
1283
- YankRotate.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1284
- var text = ext.state.popFromRing();
1285
- if (!text) {
1286
- return;
1287
- }
1288
- var pos = ext.getCursorAnchor();
1289
- editor.executeEdits(exports.SOURCE, [{
1290
- range: monaco.Range.fromPositions(pos),
1291
- text: text,
1292
- forceMoveMarkers: true,
1293
- }]);
1294
- };
1295
- return YankRotate;
1296
- }(BaseAction));
1297
- exports.YankRotate = YankRotate;
1298
- var RevealEditorAction = (function (_super) {
1299
- __extends(RevealEditorAction, _super);
1300
- function RevealEditorAction() {
1301
- return _super !== null && _super.apply(this, arguments) || this;
1302
- }
1303
- RevealEditorAction.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1304
- var sel = editor.getSelection();
1305
- if (this.revealFunction === 'up') {
1306
- editor.trigger(exports.SOURCE, 'scrollPageUp', null);
1307
- }
1308
- else {
1309
- editor[this.revealFunction](sel);
1310
- }
1311
- };
1312
- return RevealEditorAction;
1313
- }(BaseAction));
1314
- exports.RevealEditorAction = RevealEditorAction;
1315
- var RevealToTopAction = (function (_super) {
1316
- __extends(RevealToTopAction, _super);
1317
- function RevealToTopAction() {
1318
- var _this = _super !== null && _super.apply(this, arguments) || this;
1319
- _this.revealFunction = 'revealRangeAtTop';
1320
- return _this;
1321
- }
1322
- return RevealToTopAction;
1323
- }(RevealEditorAction));
1324
- exports.RevealToTopAction = RevealToTopAction;
1325
- var RevealToCenterAction = (function (_super) {
1326
- __extends(RevealToCenterAction, _super);
1327
- function RevealToCenterAction() {
1328
- var _this = _super !== null && _super.apply(this, arguments) || this;
1329
- _this.revealFunction = 'revealRangeInCenter';
1330
- return _this;
1331
- }
1332
- return RevealToCenterAction;
1333
- }(RevealEditorAction));
1334
- exports.RevealToCenterAction = RevealToCenterAction;
1335
- var RevealToBottomAction = (function (_super) {
1336
- __extends(RevealToBottomAction, _super);
1337
- function RevealToBottomAction() {
1338
- var _this = _super !== null && _super.apply(this, arguments) || this;
1339
- _this.revealFunction = 'up';
1340
- return _this;
1341
- }
1342
- return RevealToBottomAction;
1343
- }(RevealEditorAction));
1344
- exports.RevealToBottomAction = RevealToBottomAction;
1345
- var InsertTabs = (function (_super) {
1346
- __extends(InsertTabs, _super);
1347
- function InsertTabs() {
1348
- return _super !== null && _super.apply(this, arguments) || this;
1349
- }
1350
- InsertTabs.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1351
- var model = editor.getModel();
1352
- var _a = model.getOptions(), tabSize = _a.tabSize, insertSpaces = _a.insertSpaces;
1353
- var text = '';
1354
- for (var i = 0; i < repeat; i++) {
1355
- var spaces = '';
1356
- for (var j = 0; j < tabSize; j++) {
1357
- spaces += ' ';
1358
- }
1359
- text += (insertSpaces ? spaces : '\t');
1360
- }
1361
- editor.executeEdits(exports.SOURCE, [{
1362
- range: editor.getSelection(),
1363
- text: text,
1364
- forceMoveMarkers: true,
1365
- }]);
1366
- };
1367
- return InsertTabs;
1368
- }(BaseAction));
1369
- exports.InsertTabs = InsertTabs;
1370
- var RotateCursorOnScreen = (function (_super) {
1371
- __extends(RotateCursorOnScreen, _super);
1372
- function RotateCursorOnScreen() {
1373
- return _super !== null && _super.apply(this, arguments) || this;
1374
- }
1375
- RotateCursorOnScreen.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1376
- var ranges = editor.getVisibleRanges();
1377
- if (!ranges.length) {
1378
- return;
1379
- }
1380
- var lineMapping = [];
1381
- for (var i = 0; i < ranges.length; i++) {
1382
- var range = ranges[i];
1383
- for (var j = range.startLineNumber; j <= range.endLineNumber; j++) {
1384
- lineMapping.push(j);
1385
- }
1386
- }
1387
- var pos = editor.getPosition();
1388
- var expectedCenter = Math.ceil(lineMapping.length / 2);
1389
- var toMovePos;
1390
- if (pos.lineNumber === lineMapping[expectedCenter]) {
1391
- toMovePos = new monaco.Position(lineMapping[0], 1);
1392
- }
1393
- else if (pos.lineNumber === lineMapping[0]) {
1394
- toMovePos = new monaco.Position(lineMapping[lineMapping.length - 1], 1);
1395
- }
1396
- else {
1397
- toMovePos = new monaco.Position(lineMapping[expectedCenter], 1);
1398
- }
1399
- editor.setPosition(toMovePos);
1400
- };
1401
- return RotateCursorOnScreen;
1402
- }(BaseAction));
1403
- exports.RotateCursorOnScreen = RotateCursorOnScreen;
1404
- var GotoLine = (function (_super) {
1405
- __extends(GotoLine, _super);
1406
- function GotoLine() {
1407
- return _super !== null && _super.apply(this, arguments) || this;
1408
- }
1409
- GotoLine.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1410
- ext.getBasicInput('Goto Line: ').then(function (val) {
1411
- var line = parseInt(val) || 0;
1412
- var model = editor.getModel();
1413
- var totalLines = model.getLineCount();
1414
- editor.focus();
1415
- if (!line) {
1416
- line = 1;
1417
- }
1418
- else if (line > totalLines) {
1419
- line = totalLines;
1420
- }
1421
- var pos = new monaco.Position(line, 1);
1422
- var range;
1423
- if (!ext.selectionMode) {
1424
- range = monaco.Selection.fromPositions(pos);
1425
- }
1426
- else {
1427
- var sel = editor.getSelection();
1428
- if (sel.getDirection() === monaco.SelectionDirection.LTR) {
1429
- range = monaco.Selection.fromPositions(sel.getStartPosition(), pos);
1430
- }
1431
- else {
1432
- range = monaco.Selection.fromPositions(sel.getEndPosition(), pos);
1433
- }
1434
- }
1435
- editor.setSelection(range);
1436
- editor.revealRangeInCenter(range);
1437
- }).catch(function () {
1438
- editor.focus();
1439
- });
1440
- };
1441
- return GotoLine;
1442
- }(BaseAction));
1443
- exports.GotoLine = GotoLine;
1444
- var InvertSelection = (function (_super) {
1445
- __extends(InvertSelection, _super);
1446
- function InvertSelection() {
1447
- return _super !== null && _super.apply(this, arguments) || this;
1448
- }
1449
- InvertSelection.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1450
- var sel = editor.getSelection();
1451
- if (sel.isEmpty()) {
1452
- return;
1453
- }
1454
- var newSel;
1455
- if (sel.getDirection() === monaco.SelectionDirection.LTR) {
1456
- newSel = monaco.Selection.fromPositions(sel.getEndPosition(), sel.getStartPosition());
1457
- }
1458
- else {
1459
- newSel = monaco.Selection.fromPositions(sel.getStartPosition(), sel.getEndPosition());
1460
- }
1461
- editor.setSelection(newSel);
1462
- };
1463
- return InvertSelection;
1464
- }(BaseAction));
1465
- exports.InvertSelection = InvertSelection;
1466
- var Search = (function (_super) {
1467
- __extends(Search, _super);
1468
- function Search() {
1469
- return _super.call(this, 'editor.actions.findWithArgs') || this;
1470
- }
1471
- return Search;
1472
- }(TriggerAction));
1473
- exports.Search = Search;
1474
- var SearchReplace = (function (_super) {
1475
- __extends(SearchReplace, _super);
1476
- function SearchReplace() {
1477
- return _super.call(this, 'editor.action.startFindReplaceAction') || this;
1478
- }
1479
- return SearchReplace;
1480
- }(TriggerAction));
1481
- exports.SearchReplace = SearchReplace;
1482
- var DeleteLines = (function (_super) {
1483
- __extends(DeleteLines, _super);
1484
- function DeleteLines() {
1485
- return _super !== null && _super.apply(this, arguments) || this;
1486
- }
1487
- DeleteLines.prototype.run = function (editor, ext, repeat, repeatedTrigger) {
1488
- ext.selectionMode = false;
1489
- for (var i = 0; i < repeat; i++) {
1490
- editor.trigger(exports.SOURCE, 'editor.action.deleteLines', null);
1491
- }
1492
- };
1493
- return DeleteLines;
1494
- }(BaseAction));
1495
- exports.DeleteLines = DeleteLines;
1496
- } (actions));
1497
-
1498
- (function (exports) {
1499
- Object.defineProperty(exports, "__esModule", { value: true });
1500
- exports.getAllMappings = exports.unregisterKey = exports.registerGlobalCommand = exports.executeCommand = exports.COMMANDS = exports.prefixPreservingKeys = void 0;
1501
- var Actions = actions;
1502
- exports.prefixPreservingKeys = {
1503
- "M-g": true,
1504
- "C-x": true,
1505
- "C-q": true,
1506
- "C-u": true,
1507
- };
1508
- var setMarkAction = new Actions.SetMark();
1509
- var undoAction = new Actions.UndoAction();
1510
- var moveCursorDown = new Actions.MoveCursorDown();
1511
- var moveCursorUp = new Actions.MoveCursorUp();
1512
- var moveCursorRight = new Actions.MoveCursorRight();
1513
- var moveCursorLeft = new Actions.MoveCursorLeft();
1514
- exports.COMMANDS = {
1515
- 'M-/': {
1516
- description: '',
1517
- action: 'editor.action.triggerSuggest',
1518
- },
1519
- 'C-\'': {
1520
- description: '',
1521
- action: 'editor.action.triggerSuggest',
1522
- },
1523
- 'M-;': {
1524
- description: '',
1525
- action: 'editor.action.commentLine',
1526
- },
1527
- 'C-t': {
1528
- description: '',
1529
- action: 'editor.action.transposeLetters',
1530
- },
1531
- 'C-x C-p': {
1532
- description: '',
1533
- action: 'editor.action.selectAll',
1534
- },
1535
- 'Tab': {
1536
- description: '',
1537
- action: 'editor.action.formatDocument',
1538
- },
1539
- 'C-Backspace': {
1540
- description: '',
1541
- action: 'deleteWordLeft',
1542
- },
1543
- 'C-d': {
1544
- description: '',
1545
- action: 'deleteRight',
1546
- },
1547
- 'M-Backspace': {
1548
- description: '',
1549
- action: 'deleteWordLeft',
1550
- },
1551
- 'M-Delete': {
1552
- description: '',
1553
- action: 'deleteWordLeft',
1554
- },
1555
- 'C-x C-u': {
1556
- description: '',
1557
- action: 'editor.action.transformToUppercase',
1558
- },
1559
- 'C-x C-l': {
1560
- description: '',
1561
- action: 'editor.action.transformToLowercase',
1562
- },
1563
- 'C-v': {
1564
- description: '',
1565
- action: 'cursorPageDown',
1566
- },
1567
- 'PageDown': {
1568
- description: '',
1569
- action: 'cursorPageDown',
1570
- },
1571
- 'M-v': {
1572
- description: '',
1573
- action: 'cursorPageUp',
1574
- },
1575
- 'PageUp': {
1576
- description: '',
1577
- action: 'cursorPageUp',
1578
- },
1579
- 'M-g n': {
1580
- description: '',
1581
- action: 'editor.action.marker.next',
1582
- },
1583
- 'M-g p': {
1584
- description: '',
1585
- action: 'editor.action.marker.prev',
1586
- },
1587
- 'M-C-n': {
1588
- description: '',
1589
- action: 'editor.action.addSelectionToNextFindMatch',
1590
- },
1591
- 'C-h': {
1592
- description: '',
1593
- action: 'deleteLeft',
1594
- },
1595
- 'M-d': {
1596
- description: '',
1597
- action: 'deleteWordRight',
1598
- },
1599
- 'S-C-': {
1600
- description: '',
1601
- action: 'editor.action.triggerParameterHints',
1602
- },
1603
- 'C-SPC': setMarkAction,
1604
- 'S-C-2': setMarkAction,
1605
- 'C-/': undoAction,
1606
- 'S-C--': undoAction,
1607
- 'C-z': undoAction,
1608
- 'C-x u': undoAction,
1609
- 'C-n': moveCursorDown,
1610
- 'C-p': moveCursorUp,
1611
- 'C-f': moveCursorRight,
1612
- 'C-b': moveCursorLeft,
1613
- 'S-C-Backspace': new Actions.DeleteLines(),
1614
- 'M-f': new Actions.MoveCursorWordRight(),
1615
- 'M-b': new Actions.MoveCursorWordLeft(),
1616
- 'C-k': new Actions.KillLines(),
1617
- 'C-m': new Actions.InsertLineAfter(),
1618
- 'C-w': new Actions.KillSelection(),
1619
- 'C-o': new Actions.InsertLineBelow(),
1620
- 'C-g': new Actions.KeyBoardQuit(),
1621
- 'C-e': new Actions.MoveCursorToLineEnd(),
1622
- 'C-a': new Actions.MoveCursorToLineStart(),
1623
- 'C-y': new Actions.Yank(),
1624
- 'M-w': new Actions.YankSelectionToRing(),
1625
- 'M-y': new Actions.YankRotate(),
1626
- 'C-l': new Actions.RevealToCenterAction(),
1627
- 'C-q Tab': new Actions.InsertTabs(),
1628
- 'M-r': new Actions.RotateCursorOnScreen(),
1629
- 'M-g g': new Actions.GotoLine(),
1630
- 'M-g M-g': new Actions.GotoLine(),
1631
- 'C-x C-x': new Actions.InvertSelection(),
1632
- 'S-M-.': new Actions.MoveCursorBottom(),
1633
- 'S-M-,': new Actions.MoveCursorTop(),
1634
- 'C-s': new Actions.Search(),
1635
- 'C-r': new Actions.Search(),
1636
- 'S-M-5': new Actions.SearchReplace(),
1637
- };
1638
- function executeCommand(ext, command, inputBuffer, repeatedTrigger) {
1639
- var editor = ext.getEditor();
1640
- var repeat = parseInt(inputBuffer) || 1;
1641
- if (command.run) {
1642
- command.run(editor, ext, repeat, repeatedTrigger);
1643
- return;
1644
- }
1645
- if (typeof command.action === 'string') {
1646
- for (var i = 0; i < repeat; i++) {
1647
- editor.trigger(Actions.SOURCE, command.action, null);
1648
- }
1649
- }
1650
- else if (Array.isArray(command.action)) {
1651
- for (var i = 0; i < repeat; i++) {
1652
- command.action.forEach(function (cmd) {
1653
- editor.trigger(Actions.SOURCE, cmd, null);
1654
- });
1655
- }
1656
- }
1657
- }
1658
- exports.executeCommand = executeCommand;
1659
- function registerGlobalCommand(key, command) {
1660
- exports.COMMANDS[key] = command;
1661
- }
1662
- exports.registerGlobalCommand = registerGlobalCommand;
1663
- function unregisterKey(key) {
1664
- if (exports.COMMANDS[key]) {
1665
- delete exports.COMMANDS[key];
1666
- }
1667
- }
1668
- exports.unregisterKey = unregisterKey;
1669
- function getAllMappings() {
1670
- var result = {};
1671
- Object.keys(exports.COMMANDS).forEach(function (key) {
1672
- result[key] = exports.COMMANDS[key].description;
1673
- });
1674
- return result;
1675
- }
1676
- exports.getAllMappings = getAllMappings;
1677
- } (commands));
1678
-
1679
- var util = {};
1680
-
1681
- (function (exports) {
1682
- Object.defineProperty(exports, "__esModule", { value: true });
1683
- exports.Emitter = exports.Event = exports.monacoToEmacsKey = exports.modifierKeys = void 0;
1684
- var monaco = require$$0;
1685
- exports.modifierKeys = {
1686
- Alt: 'M',
1687
- Control: 'C',
1688
- Ctrl: 'C',
1689
- Meta: 'CMD',
1690
- Shift: 'S',
1691
- };
1692
- var specialKeys = {
1693
- Enter: 'Return',
1694
- Space: 'SPC',
1695
- Backslash: '\\',
1696
- Slash: '/',
1697
- Backquote: '`',
1698
- BracketRight: ']',
1699
- BracketLeft: '[',
1700
- Comma: ',',
1701
- Period: '.',
1702
- Equal: '=',
1703
- Minus: '-',
1704
- Quote: '\'',
1705
- Semicolon: ';',
1706
- };
1707
- var oneCharKeyPrefixes = ['Key', 'Numpad'];
1708
- var arrowSuffix = 'Arrow';
1709
- function monacoToEmacsKey(ev) {
1710
- var keyName = monaco.KeyCode[ev.keyCode];
1711
- if (exports.modifierKeys[keyName]) {
1712
- return '';
1713
- }
1714
- var key = oneCharKeyPrefixes.some(function (prefix) { return keyName.startsWith(prefix); }) ? keyName[keyName.length - 1] : keyName;
1715
- if (keyName.endsWith(arrowSuffix)) {
1716
- key = keyName.substring(0, keyName.length - arrowSuffix.length);
1717
- }
1718
- else if (specialKeys[keyName]) {
1719
- key = specialKeys[key];
1720
- }
1721
- if (key.length === 1) {
1722
- key = key.toLowerCase();
1723
- }
1724
- if (ev.altKey) {
1725
- key = "".concat(exports.modifierKeys.Alt, "-").concat(key);
1726
- }
1727
- if (ev.ctrlKey) {
1728
- key = "".concat(exports.modifierKeys.Ctrl, "-").concat(key);
1729
- }
1730
- if (ev.metaKey) {
1731
- key = "".concat(exports.modifierKeys.Meta, "-").concat(key);
1732
- }
1733
- if (ev.shiftKey) {
1734
- key = "".concat(exports.modifierKeys.Shift, "-").concat(key);
1735
- }
1736
- return key;
1737
- }
1738
- exports.monacoToEmacsKey = monacoToEmacsKey;
1739
- (function (Event) {
1740
- var _disposable = { dispose: function () { } };
1741
- Event.None = function () { return _disposable; };
1742
- })(exports.Event || (exports.Event = {}));
1743
- var Emitter = (function () {
1744
- function Emitter() {
1745
- this._listeners = [];
1746
- }
1747
- Object.defineProperty(Emitter.prototype, "event", {
1748
- get: function () {
1749
- var _this = this;
1750
- if (!this._event) {
1751
- this._event = function (listener) {
1752
- _this._listeners.push(listener);
1753
- var result = {
1754
- dispose: function () {
1755
- if (_this._disposed) {
1756
- return;
1757
- }
1758
- var index = _this._listeners.indexOf(listener);
1759
- if (index < 0) {
1760
- return;
1761
- }
1762
- _this._listeners.splice(index, 1);
1763
- }
1764
- };
1765
- return result;
1766
- };
1767
- }
1768
- return this._event;
1769
- },
1770
- enumerable: false,
1771
- configurable: true
1772
- });
1773
- Emitter.prototype.fire = function (ev) {
1774
- if (!this._listeners.length) {
1775
- return;
1776
- }
1777
- this._listeners.forEach(function (l) { return l(ev); });
1778
- };
1779
- Emitter.prototype.dispose = function () {
1780
- if (this._disposed) {
1781
- return;
1782
- }
1783
- this._listeners = undefined;
1784
- this._disposed = true;
1785
- };
1786
- return Emitter;
1787
- }());
1788
- exports.Emitter = Emitter;
1789
- } (util));
1790
-
1791
- var basicInput = {};
1792
-
1793
- Object.defineProperty(basicInput, "__esModule", { value: true });
1794
- basicInput.BasicInputWidget = void 0;
1795
- var monaco$1 = require$$0;
1796
- var BASE_CLASS = 'ext-emacs-basic-input';
1797
- function generateCss() {
1798
- return "\n .".concat(BASE_CLASS, " {\n color: #d4d4d4;\n transition: top 200ms linear;\n visibility: hidden;\n width: 200px;\n display: flex;\n align-items: center;\n padding: 5px;\n }\n\n .").concat(BASE_CLASS, ".").concat(BASE_CLASS, "-visible {\n visibility: visible;\n }\n\n .").concat(BASE_CLASS, " input {\n color: rgb(97, 97, 97);\n background-color: transparent;\n display: inline-block;\n box-sizing: border-box;\n height: 100%;\n line-height: inherit;\n border: none;\n font-family: inherit;\n font-size: inherit;\n resize: none;\n padding-top: 2px;\n padding-bottom: 2px;\n margin-left: 5px;\n max-width: 50px;\n }\n\n .").concat(BASE_CLASS, " input:focus {\n outline: none;\n }\n\n .vs .").concat(BASE_CLASS, " {\n color: rgb(97, 97, 97);\n background-color: #efeff2;\n box-shadow: 0 2px 8px #a8a8a8;\n }\n\n .vs-dark .").concat(BASE_CLASS, " {\n background-color: #2d2d30;\n box-shadow: 0 2px 8px #000000;\n }\n\n .vs-dark .").concat(BASE_CLASS, " input {\n color: rgb(204, 204, 204);\n }\n\n .hc-black .").concat(BASE_CLASS, " {\n border: 2px solid #6fc3df;\n background-color: #0c141f;\n color: #ffffff;\n }\n\n .hc-black .").concat(BASE_CLASS, " input {\n color: #ffffff;\n }\n");
1799
- }
1800
- var BasicInputWidget = (function () {
1801
- function BasicInputWidget() {
1802
- var _this = this;
1803
- this._pendingPromise = null;
1804
- this.onKeyDown = function (ev) {
1805
- if (ev.altKey || ev.ctrlKey || ev.metaKey) {
1806
- ev.preventDefault();
1807
- ev.stopPropagation();
1808
- }
1809
- if (ev.which === 13) {
1810
- if (_this._pendingPromise) {
1811
- ev.preventDefault();
1812
- _this._pendingPromise.resolve(ev.target.value);
1813
- _this._pendingPromise = null;
1814
- }
1815
- }
1816
- else if (ev.which === 27) {
1817
- if (_this._pendingPromise) {
1818
- _this._pendingPromise.reject();
1819
- _this._pendingPromise = null;
1820
- }
1821
- }
1822
- };
1823
- this.onBlur = function () {
1824
- if (_this._pendingPromise) {
1825
- _this._pendingPromise.reject();
1826
- _this._pendingPromise = null;
1827
- }
1828
- };
1829
- this._dom = document.createElement('div');
1830
- this._messageDom = document.createElement('div');
1831
- var medDom = document.createElement('div');
1832
- this._dom.setAttribute('class', BASE_CLASS);
1833
- this._dom.setAttribute('aria-hidden', 'true');
1834
- this._input = document.createElement('input');
1835
- this._dom.appendChild(this._messageDom);
1836
- medDom.appendChild(this._input);
1837
- this._dom.appendChild(medDom);
1838
- this.addListeners();
1839
- this._style = document.createElement('style');
1840
- this._style.type = 'text/css';
1841
- this._style.textContent = generateCss();
1842
- (document.head || document.body).appendChild(this._style);
1843
- }
1844
- BasicInputWidget.prototype.getDomNode = function () {
1845
- return this._dom;
1846
- };
1847
- BasicInputWidget.prototype.getId = function () {
1848
- return 'extension.emacs.basicinput';
1849
- };
1850
- BasicInputWidget.prototype.getPosition = function () {
1851
- return {
1852
- preference: monaco$1.editor.OverlayWidgetPositionPreference.TOP_RIGHT_CORNER,
1853
- };
1854
- };
1855
- BasicInputWidget.prototype.addListeners = function () {
1856
- this._input.addEventListener('keydown', this.onKeyDown);
1857
- this._input.addEventListener('blur', this.onBlur);
1858
- };
1859
- BasicInputWidget.prototype.showWidgetAndFocus = function (message) {
1860
- this._dom.classList.add("".concat(BASE_CLASS, "-visible"));
1861
- this._dom.setAttribute('aria-hidden', 'false');
1862
- this._messageDom.textContent = message;
1863
- this._input.focus();
1864
- };
1865
- BasicInputWidget.prototype.cleanup = function () {
1866
- this._dom.classList.remove("".concat(BASE_CLASS, "-visible"));
1867
- this._dom.setAttribute('aria-hidden', 'true');
1868
- this._messageDom.textContent = '';
1869
- this._input.placeholder = '';
1870
- this._input.value = '';
1871
- };
1872
- BasicInputWidget.prototype.getInput = function (message) {
1873
- var _this = this;
1874
- if (this._pendingPromise) {
1875
- this._pendingPromise.reject();
1876
- this._pendingPromise = null;
1877
- }
1878
- return new Promise(function (resolve, reject) {
1879
- _this._pendingPromise = {
1880
- resolve: function (val) {
1881
- resolve(val);
1882
- _this.cleanup();
1883
- },
1884
- reject: function () {
1885
- reject();
1886
- _this.cleanup();
1887
- },
1888
- };
1889
- _this.showWidgetAndFocus(message);
1890
- });
1891
- };
1892
- BasicInputWidget.prototype.dispose = function () {
1893
- this.cleanup();
1894
- this._input.removeEventListener('keydown', this.onKeyDown);
1895
- this._input.removeEventListener('blur', this.onBlur);
1896
- (document.head || document.body).removeChild(this._style);
1897
- };
1898
- return BasicInputWidget;
1899
- }());
1900
- basicInput.BasicInputWidget = BasicInputWidget;
1901
-
1902
- var state = {};
1903
-
1904
- (function (exports) {
1905
- Object.defineProperty(exports, "__esModule", { value: true });
1906
- exports.State = exports.EAT_UP_KEY = void 0;
1907
- var commands_1 = commands;
1908
- exports.EAT_UP_KEY = '==-==';
1909
- var State = (function () {
1910
- function State() {
1911
- this._inargumentMode = false;
1912
- this._killRing = [];
1913
- }
1914
- State.prototype.updateAndGetKey = function (key) {
1915
- if (key === 'C-g' && (this._inargumentMode || this._prefixKey)) {
1916
- this.resetState();
1917
- return exports.EAT_UP_KEY;
1918
- }
1919
- if (this.updateCuMode(key)) {
1920
- return exports.EAT_UP_KEY;
1921
- }
1922
- if (!this._prefixKey) {
1923
- if (commands_1.prefixPreservingKeys[key]) {
1924
- this._prefixKey = key;
1925
- return exports.EAT_UP_KEY;
1926
- }
1927
- return key;
1928
- }
1929
- else {
1930
- return "".concat(this._prefixKey, " ").concat(key);
1931
- }
1932
- };
1933
- State.prototype.setLastCommandKey = function (lastCommandKey) {
1934
- this._lastCommandKey = lastCommandKey;
1935
- };
1936
- State.prototype.isLastCommandKey = function (lastCommandKey) {
1937
- return this._lastCommandKey == lastCommandKey;
1938
- };
1939
- State.prototype.resetState = function (setLastInput) {
1940
- if (setLastInput === void 0) { setLastInput = false; }
1941
- this._inargumentMode = setLastInput;
1942
- this._prefixKey = null;
1943
- if (setLastInput) {
1944
- this._lastInputBuffer = this._inputBuffer;
1945
- }
1946
- else {
1947
- this._lastInputBuffer = null;
1948
- }
1949
- this._inputBuffer = null;
1950
- };
1951
- State.prototype.updateCuMode = function (key) {
1952
- if (this._inargumentMode) {
1953
- if (typeof key === 'string' && (/^\d$/.test(key))) {
1954
- this._inputBuffer = (this._inputBuffer || '') + key;
1955
- return true;
1956
- }
1957
- else if (commands_1.prefixPreservingKeys[key]) {
1958
- this.resetState(true);
1959
- return false;
1960
- }
1961
- }
1962
- else if (!this._prefixKey && key === 'C-u') {
1963
- this._inargumentMode = true;
1964
- this._inputBuffer = null;
1965
- this._lastInputBuffer = null;
1966
- return true;
1967
- }
1968
- };
1969
- State.prototype.updateStateOnExecution = function (reset) {
1970
- if (reset === void 0) { reset = false; }
1971
- this.resetState(reset);
1972
- };
1973
- State.prototype.getInputBuffer = function () {
1974
- return this._lastInputBuffer || this._inputBuffer;
1975
- };
1976
- State.prototype.addToRing = function (str) {
1977
- this._killRing.push(str);
1978
- if (this._killRing.length > 50)
1979
- this._killRing.shift();
1980
- };
1981
- State.prototype.growRingTop = function (str) {
1982
- if (!this._killRing.length) {
1983
- this.addToRing(str);
1984
- }
1985
- this._killRing[this._killRing.length - 1] += str;
1986
- };
1987
- State.prototype.getFromRing = function (n) {
1988
- return this._killRing[this._killRing.length - (n ? Math.min(n, 1) : 1)] || '';
1989
- };
1990
- State.prototype.popFromRing = function () {
1991
- if (this._killRing.length > 1) {
1992
- return this._killRing.pop();
1993
- }
1994
- return this.getFromRing();
1995
- };
1996
- State.prototype.getReadableState = function () {
1997
- var str = '';
1998
- if (this._inargumentMode) {
1999
- str += 'C-u';
2000
- if (this._inputBuffer) {
2001
- str += " ".concat(this._inputBuffer);
2002
- }
2003
- else if (this._lastInputBuffer) {
2004
- str += " ".concat(this._lastInputBuffer);
2005
- }
2006
- }
2007
- if (this._prefixKey) {
2008
- str += " ".concat(this._prefixKey);
2009
- }
2010
- return str;
2011
- };
2012
- return State;
2013
- }());
2014
- exports.State = State;
2015
- } (state));
2016
-
2017
- Object.defineProperty(emacs, "__esModule", { value: true });
2018
- emacs.getConfiguration = emacs.EmacsExtension = void 0;
2019
- var monaco = require$$0;
2020
- var throttle = lodash_throttle;
2021
- var kebabCase = lodash_kebabcase;
2022
- var commands_1 = commands;
2023
- var util_1 = util;
2024
- var basicInput_1 = basicInput;
2025
- var state_1 = state;
2026
- var _a = monaco.editor, TextEditorCursorBlinkingStyle = _a.TextEditorCursorBlinkingStyle, TextEditorCursorStyle = _a.TextEditorCursorStyle;
2027
- var EmacsExtension = (function () {
2028
- function EmacsExtension(editor) {
2029
- this._disposables = [];
2030
- this._inSelectionMode = false;
2031
- this._changeDisposable = null;
2032
- this._state = new state_1.State();
2033
- this._onDidMarkChange = new util_1.Emitter();
2034
- this.onDidMarkChange = this._onDidMarkChange.event;
2035
- this._onDidChangeKey = new util_1.Emitter();
2036
- this.onDidChangeKey = this._onDidChangeKey.event;
2037
- this._editor = editor;
2038
- var config = getConfiguration(editor);
2039
- this._intialCursorType = config.cursorStyle;
2040
- this._intialCursorBlinking = config.cursorBlinking;
2041
- this._basicInputWidget = new basicInput_1.BasicInputWidget();
2042
- }
2043
- EmacsExtension.prototype.start = function () {
2044
- if (this._disposables.length) {
2045
- return;
2046
- }
2047
- this.addListeners();
2048
- this._editor.updateOptions({
2049
- cursorStyle: kebabCase(TextEditorCursorStyle[TextEditorCursorStyle.Block]),
2050
- cursorBlinking: kebabCase(TextEditorCursorBlinkingStyle[TextEditorCursorBlinkingStyle.Blink]),
2051
- });
2052
- this._editor.addOverlayWidget(this._basicInputWidget);
2053
- };
2054
- Object.defineProperty(EmacsExtension.prototype, "state", {
2055
- get: function () {
2056
- return this._state;
2057
- },
2058
- enumerable: false,
2059
- configurable: true
2060
- });
2061
- EmacsExtension.prototype.getEditor = function () {
2062
- return this._editor;
2063
- };
2064
- EmacsExtension.prototype.addListeners = function () {
2065
- this._disposables.push(this._editor.onKeyDown(this.onKeyDown.bind(this)));
2066
- this._throttledScroll = throttle(this.onEditorScroll.bind(this), 500);
2067
- this._disposables.push(this._editor.onDidScrollChange(this._throttledScroll));
2068
- };
2069
- EmacsExtension.prototype.cancelKey = function (ev) {
2070
- ev.preventDefault();
2071
- ev.stopPropagation();
2072
- };
2073
- EmacsExtension.prototype.onKeyDown = function (ev) {
2074
- if (ev.browserEvent.defaultPrevented) {
2075
- return;
2076
- }
2077
- var key = (0, util_1.monacoToEmacsKey)(ev);
2078
- if (!key) {
2079
- return;
2080
- }
2081
- key = this._state.updateAndGetKey(key);
2082
- this._onDidChangeKey.fire(this._state.getReadableState());
2083
- if (key === state_1.EAT_UP_KEY) {
2084
- this._onDidChangeKey.fire(this._state.getReadableState());
2085
- this.cancelKey(ev);
2086
- return;
2087
- }
2088
- var command = commands_1.COMMANDS[key];
2089
- if (!command) {
2090
- this._onDidChangeKey.fire(this._state.getReadableState());
2091
- this._state.setLastCommandKey(key);
2092
- return;
2093
- }
2094
- this.cancelKey(ev);
2095
- var repeatedTrigger = this._state.isLastCommandKey(key);
2096
- (0, commands_1.executeCommand)(this, command, this._state.getInputBuffer(), repeatedTrigger);
2097
- this._state.setLastCommandKey(key);
2098
- this._state.updateStateOnExecution();
2099
- };
2100
- EmacsExtension.prototype.onEditorScroll = function () {
2101
- var height = this._editor.getLayoutInfo().height;
2102
- var layout = this._editor.getScrolledVisiblePosition(this._editor.getPosition());
2103
- if (layout.top >= 0 && layout.top <= height) {
2104
- return;
2105
- }
2106
- var ranges = this._editor.getVisibleRanges();
2107
- if (!ranges.length) {
2108
- return;
2109
- }
2110
- var newPos;
2111
- var sel = this._editor.getSelection();
2112
- if (layout.top < 0) {
2113
- newPos = new monaco.Position(ranges[0].getStartPosition().lineNumber, 1);
2114
- }
2115
- else if (layout.top > height) {
2116
- newPos = new monaco.Position(ranges[ranges.length - 1].getEndPosition().lineNumber, 1);
2117
- }
2118
- if (this._inSelectionMode) {
2119
- this._editor.setSelection(monaco.Selection.fromPositions(sel.getStartPosition(), newPos));
2120
- }
2121
- else {
2122
- this._editor.setPosition(newPos);
2123
- }
2124
- };
2125
- EmacsExtension.prototype.onContentChange = function () {
2126
- this.selectionMode = false;
2127
- };
2128
- EmacsExtension.prototype.clearState = function () {
2129
- this._state.updateStateOnExecution();
2130
- };
2131
- Object.defineProperty(EmacsExtension.prototype, "selectionMode", {
2132
- get: function () {
2133
- return this._inSelectionMode;
2134
- },
2135
- set: function (mode) {
2136
- if (mode === this._inSelectionMode) {
2137
- return;
2138
- }
2139
- this._inSelectionMode = mode;
2140
- if (mode) {
2141
- this._changeDisposable = this._editor.onDidChangeModelContent(this.onContentChange.bind(this));
2142
- }
2143
- else if (this._changeDisposable) {
2144
- this._changeDisposable.dispose();
2145
- this._changeDisposable = null;
2146
- }
2147
- this._onDidMarkChange.fire(mode);
2148
- },
2149
- enumerable: false,
2150
- configurable: true
2151
- });
2152
- EmacsExtension.prototype.getCursorAnchor = function () {
2153
- var sel = this._editor.getSelection();
2154
- var dir = sel.getDirection();
2155
- return dir === monaco.SelectionDirection.LTR ? sel.getEndPosition() : sel.getStartPosition();
2156
- };
2157
- EmacsExtension.prototype.getBasicInput = function (message) {
2158
- return this._basicInputWidget.getInput(message);
2159
- };
2160
- EmacsExtension.prototype.dispose = function () {
2161
- this._disposables.forEach(function (d) { return d.dispose(); });
2162
- this._disposables = undefined;
2163
- if (this._changeDisposable) {
2164
- this._changeDisposable.dispose();
2165
- this._changeDisposable = null;
2166
- }
2167
- this._editor.updateOptions({
2168
- cursorStyle: this._intialCursorType,
2169
- cursorBlinking: this._intialCursorBlinking,
2170
- });
2171
- this._editor.removeOverlayWidget(this._basicInputWidget);
2172
- this._basicInputWidget.dispose();
2173
- this._throttledScroll.cancel();
2174
- this._state = null;
2175
- };
2176
- return EmacsExtension;
2177
- }());
2178
- emacs.EmacsExtension = EmacsExtension;
2179
- function getConfiguration(editor) {
2180
- var cursorStyle = editor.getOption(monaco.editor.EditorOption.cursorStyle);
2181
- var cursorBlinking = editor.getOption(monaco.editor.EditorOption.cursorBlinking);
2182
- return {
2183
- cursorStyle: kebabCase(TextEditorCursorStyle[cursorStyle]),
2184
- cursorBlinking: kebabCase(TextEditorCursorBlinkingStyle[cursorBlinking]),
2185
- };
2186
- }
2187
- emacs.getConfiguration = getConfiguration;
2188
-
2189
- (function (exports) {
2190
- Object.defineProperty(exports, "__esModule", { value: true });
2191
- exports.Actions = exports.EmacsExtension = exports.unregisterKey = exports.getAllMappings = exports.registerGlobalCommand = void 0;
2192
- var emacs_1 = emacs;
2193
- Object.defineProperty(exports, "EmacsExtension", { enumerable: true, get: function () { return emacs_1.EmacsExtension; } });
2194
- var commands_1 = commands;
2195
- Object.defineProperty(exports, "registerGlobalCommand", { enumerable: true, get: function () { return commands_1.registerGlobalCommand; } });
2196
- Object.defineProperty(exports, "getAllMappings", { enumerable: true, get: function () { return commands_1.getAllMappings; } });
2197
- Object.defineProperty(exports, "unregisterKey", { enumerable: true, get: function () { return commands_1.unregisterKey; } });
2198
- var Actions = actions;
2199
- exports.Actions = Actions;
2200
- exports.default = emacs_1.EmacsExtension;
2201
- } (lib));
2202
-
2203
- var index = /*@__PURE__*/getDefaultExportFromCjs(lib);
2204
-
2205
- var index$1 = /*#__PURE__*/_mergeNamespaces({
2206
- __proto__: null,
2207
- default: index
2208
- }, [lib]);
2209
-
2210
- export { index$1 as i };