@opensumi/ide-core-browser 2.12.1-next-079c1930

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 (851) hide show
  1. package/README.md +16 -0
  2. package/lib/application/application-state-service.d.ts +16 -0
  3. package/lib/application/application-state-service.d.ts.map +1 -0
  4. package/lib/application/application-state-service.js +47 -0
  5. package/lib/application/application-state-service.js.map +1 -0
  6. package/lib/application/application.service.d.ts +11 -0
  7. package/lib/application/application.service.d.ts.map +1 -0
  8. package/lib/application/application.service.js +41 -0
  9. package/lib/application/application.service.js.map +1 -0
  10. package/lib/application/index.d.ts +3 -0
  11. package/lib/application/index.d.ts.map +1 -0
  12. package/lib/application/index.js +6 -0
  13. package/lib/application/index.js.map +1 -0
  14. package/lib/authentication/authentication.contribution.d.ts +8 -0
  15. package/lib/authentication/authentication.contribution.d.ts.map +1 -0
  16. package/lib/authentication/authentication.contribution.js +32 -0
  17. package/lib/authentication/authentication.contribution.js.map +1 -0
  18. package/lib/authentication/authentication.service.d.ts +54 -0
  19. package/lib/authentication/authentication.service.d.ts.map +1 -0
  20. package/lib/authentication/authentication.service.js +413 -0
  21. package/lib/authentication/authentication.service.js.map +1 -0
  22. package/lib/bootstrap/app.d.ts +142 -0
  23. package/lib/bootstrap/app.d.ts.map +1 -0
  24. package/lib/bootstrap/app.js +516 -0
  25. package/lib/bootstrap/app.js.map +1 -0
  26. package/lib/bootstrap/app.view.d.ts +11 -0
  27. package/lib/bootstrap/app.view.d.ts.map +1 -0
  28. package/lib/bootstrap/app.view.js +72 -0
  29. package/lib/bootstrap/app.view.js.map +1 -0
  30. package/lib/bootstrap/connection.d.ts +7 -0
  31. package/lib/bootstrap/connection.d.ts.map +1 -0
  32. package/lib/bootstrap/connection.js +78 -0
  33. package/lib/bootstrap/connection.js.map +1 -0
  34. package/lib/bootstrap/index.d.ts +4 -0
  35. package/lib/bootstrap/index.d.ts.map +1 -0
  36. package/lib/bootstrap/index.js +7 -0
  37. package/lib/bootstrap/index.js.map +1 -0
  38. package/lib/bootstrap/inner-providers.d.ts +3 -0
  39. package/lib/bootstrap/inner-providers.d.ts.map +1 -0
  40. package/lib/bootstrap/inner-providers.js +231 -0
  41. package/lib/bootstrap/inner-providers.js.map +1 -0
  42. package/lib/browser-module.d.ts +20 -0
  43. package/lib/browser-module.d.ts.map +1 -0
  44. package/lib/browser-module.js +15 -0
  45. package/lib/browser-module.js.map +1 -0
  46. package/lib/common/common.command.d.ts +156 -0
  47. package/lib/common/common.command.d.ts.map +1 -0
  48. package/lib/common/common.command.js +611 -0
  49. package/lib/common/common.command.js.map +1 -0
  50. package/lib/common/common.contribution.d.ts +22 -0
  51. package/lib/common/common.contribution.d.ts.map +1 -0
  52. package/lib/common/common.contribution.js +241 -0
  53. package/lib/common/common.contribution.js.map +1 -0
  54. package/lib/common/common.define.d.ts +47 -0
  55. package/lib/common/common.define.d.ts.map +1 -0
  56. package/lib/common/common.define.js +5 -0
  57. package/lib/common/common.define.js.map +1 -0
  58. package/lib/common/common.module.d.ts +13 -0
  59. package/lib/common/common.module.d.ts.map +1 -0
  60. package/lib/common/common.module.js +41 -0
  61. package/lib/common/common.module.js.map +1 -0
  62. package/lib/common/common.storage.d.ts +9 -0
  63. package/lib/common/common.storage.d.ts.map +1 -0
  64. package/lib/common/common.storage.js +25 -0
  65. package/lib/common/common.storage.js.map +1 -0
  66. package/lib/common/index.d.ts +5 -0
  67. package/lib/common/index.d.ts.map +1 -0
  68. package/lib/common/index.js +8 -0
  69. package/lib/common/index.js.map +1 -0
  70. package/lib/components/actions/index.d.ts +77 -0
  71. package/lib/components/actions/index.d.ts.map +1 -0
  72. package/lib/components/actions/index.js +201 -0
  73. package/lib/components/actions/index.js.map +1 -0
  74. package/lib/components/actions/placements.d.ts +58 -0
  75. package/lib/components/actions/placements.d.ts.map +1 -0
  76. package/lib/components/actions/placements.js +48 -0
  77. package/lib/components/actions/placements.js.map +1 -0
  78. package/lib/components/actions/styles.module.less +128 -0
  79. package/lib/components/badge/index.d.ts +2 -0
  80. package/lib/components/badge/index.d.ts.map +1 -0
  81. package/lib/components/badge/index.js +6 -0
  82. package/lib/components/badge/index.js.map +1 -0
  83. package/lib/components/click-outside/index.d.ts +6 -0
  84. package/lib/components/click-outside/index.d.ts.map +1 -0
  85. package/lib/components/click-outside/index.js +27 -0
  86. package/lib/components/click-outside/index.js.map +1 -0
  87. package/lib/components/index.d.ts +25 -0
  88. package/lib/components/index.d.ts.map +1 -0
  89. package/lib/components/index.js +30 -0
  90. package/lib/components/index.js.map +1 -0
  91. package/lib/components/layout/box-panel.d.ts +18 -0
  92. package/lib/components/layout/box-panel.d.ts.map +1 -0
  93. package/lib/components/layout/box-panel.js +20 -0
  94. package/lib/components/layout/box-panel.js.map +1 -0
  95. package/lib/components/layout/default-layout.d.ts +15 -0
  96. package/lib/components/layout/default-layout.d.ts.map +1 -0
  97. package/lib/components/layout/default-layout.js +39 -0
  98. package/lib/components/layout/default-layout.js.map +1 -0
  99. package/lib/components/layout/index.d.ts +5 -0
  100. package/lib/components/layout/index.d.ts.map +1 -0
  101. package/lib/components/layout/index.js +8 -0
  102. package/lib/components/layout/index.js.map +1 -0
  103. package/lib/components/layout/layout.d.ts +13 -0
  104. package/lib/components/layout/layout.d.ts.map +1 -0
  105. package/lib/components/layout/layout.js +72 -0
  106. package/lib/components/layout/layout.js.map +1 -0
  107. package/lib/components/layout/split-panel.d.ts +38 -0
  108. package/lib/components/layout/split-panel.d.ts.map +1 -0
  109. package/lib/components/layout/split-panel.js +182 -0
  110. package/lib/components/layout/split-panel.js.map +1 -0
  111. package/lib/components/layout/split-panel.service.d.ts +16 -0
  112. package/lib/components/layout/split-panel.service.d.ts.map +1 -0
  113. package/lib/components/layout/split-panel.service.js +69 -0
  114. package/lib/components/layout/split-panel.service.js.map +1 -0
  115. package/lib/components/layout/styles.module.less +119 -0
  116. package/lib/components/loading/index.d.ts +2 -0
  117. package/lib/components/loading/index.d.ts.map +1 -0
  118. package/lib/components/loading/index.js +5 -0
  119. package/lib/components/loading/index.js.map +1 -0
  120. package/lib/components/loading/loading.less +14 -0
  121. package/lib/components/loading/loading.view.d.ts +4 -0
  122. package/lib/components/loading/loading.view.d.ts.map +1 -0
  123. package/lib/components/loading/loading.view.js +12 -0
  124. package/lib/components/loading/loading.view.js.map +1 -0
  125. package/lib/components/loading/media/loading-dark.svg +52 -0
  126. package/lib/components/loading/media/loading-hc.svg +52 -0
  127. package/lib/components/loading/media/loading.svg +52 -0
  128. package/lib/components/popover/styles.module.less +81 -0
  129. package/lib/components/portal/index.d.ts +6 -0
  130. package/lib/components/portal/index.d.ts.map +1 -0
  131. package/lib/components/portal/index.js +11 -0
  132. package/lib/components/portal/index.js.map +1 -0
  133. package/lib/components/progressbar/index.d.ts +5 -0
  134. package/lib/components/progressbar/index.d.ts.map +1 -0
  135. package/lib/components/progressbar/index.js +15 -0
  136. package/lib/components/progressbar/index.js.map +1 -0
  137. package/lib/components/progressbar/styles.module.less +31 -0
  138. package/lib/components/recycle-tree/index.d.ts +2 -0
  139. package/lib/components/recycle-tree/index.d.ts.map +1 -0
  140. package/lib/components/recycle-tree/index.js +5 -0
  141. package/lib/components/recycle-tree/index.js.map +1 -0
  142. package/lib/components/recycle-tree/recycle-tree.view.d.ts +82 -0
  143. package/lib/components/recycle-tree/recycle-tree.view.d.ts.map +1 -0
  144. package/lib/components/recycle-tree/recycle-tree.view.js +192 -0
  145. package/lib/components/recycle-tree/recycle-tree.view.js.map +1 -0
  146. package/lib/components/resize/resize.d.ts +39 -0
  147. package/lib/components/resize/resize.d.ts.map +1 -0
  148. package/lib/components/resize/resize.js +609 -0
  149. package/lib/components/resize/resize.js.map +1 -0
  150. package/lib/components/resize/resize.module.less +78 -0
  151. package/lib/components/scrollbar/index.d.ts +2 -0
  152. package/lib/components/scrollbar/index.d.ts.map +1 -0
  153. package/lib/components/scrollbar/index.js +5 -0
  154. package/lib/components/scrollbar/index.js.map +1 -0
  155. package/lib/components/scrollbar/scrollbar.less +36 -0
  156. package/lib/components/scrollbar/scrollbar.view.d.ts +7 -0
  157. package/lib/components/scrollbar/scrollbar.view.d.ts.map +1 -0
  158. package/lib/components/scrollbar/scrollbar.view.js +11 -0
  159. package/lib/components/scrollbar/scrollbar.view.js.map +1 -0
  160. package/lib/components/select/index.d.ts +4 -0
  161. package/lib/components/select/index.d.ts.map +1 -0
  162. package/lib/components/select/index.js +14 -0
  163. package/lib/components/select/index.js.map +1 -0
  164. package/lib/components/select/styles.less +8 -0
  165. package/lib/components/tree/index.d.ts +4 -0
  166. package/lib/components/tree/index.d.ts.map +1 -0
  167. package/lib/components/tree/index.js +7 -0
  168. package/lib/components/tree/index.js.map +1 -0
  169. package/lib/components/tree/tree-node.view.d.ts +26 -0
  170. package/lib/components/tree/tree-node.view.d.ts.map +1 -0
  171. package/lib/components/tree/tree-node.view.js +346 -0
  172. package/lib/components/tree/tree-node.view.js.map +1 -0
  173. package/lib/components/tree/tree.module.less +295 -0
  174. package/lib/components/tree/tree.view.d.ts +132 -0
  175. package/lib/components/tree/tree.view.d.ts.map +1 -0
  176. package/lib/components/tree/tree.view.js +246 -0
  177. package/lib/components/tree/tree.view.js.map +1 -0
  178. package/lib/context-key.d.ts +32 -0
  179. package/lib/context-key.d.ts.map +1 -0
  180. package/lib/context-key.js +9 -0
  181. package/lib/context-key.js.map +1 -0
  182. package/lib/contextkey/explorer.d.ts +16 -0
  183. package/lib/contextkey/explorer.d.ts.map +1 -0
  184. package/lib/contextkey/explorer.js +20 -0
  185. package/lib/contextkey/explorer.js.map +1 -0
  186. package/lib/contextkey/index.d.ts +6 -0
  187. package/lib/contextkey/index.d.ts.map +1 -0
  188. package/lib/contextkey/index.js +9 -0
  189. package/lib/contextkey/index.js.map +1 -0
  190. package/lib/contextkey/outline.d.ts +4 -0
  191. package/lib/contextkey/outline.d.ts.map +1 -0
  192. package/lib/contextkey/outline.js +7 -0
  193. package/lib/contextkey/outline.js.map +1 -0
  194. package/lib/contextkey/resource.d.ts +17 -0
  195. package/lib/contextkey/resource.d.ts.map +1 -0
  196. package/lib/contextkey/resource.js +45 -0
  197. package/lib/contextkey/resource.js.map +1 -0
  198. package/lib/contextkey/terminal.d.ts +7 -0
  199. package/lib/contextkey/terminal.d.ts.map +1 -0
  200. package/lib/contextkey/terminal.js +10 -0
  201. package/lib/contextkey/terminal.js.map +1 -0
  202. package/lib/contextkey/workspace.d.ts +7 -0
  203. package/lib/contextkey/workspace.d.ts.map +1 -0
  204. package/lib/contextkey/workspace.js +10 -0
  205. package/lib/contextkey/workspace.js.map +1 -0
  206. package/lib/core-preferences.d.ts +57 -0
  207. package/lib/core-preferences.d.ts.map +1 -0
  208. package/lib/core-preferences.js +328 -0
  209. package/lib/core-preferences.js.map +1 -0
  210. package/lib/dom/index.d.ts +68 -0
  211. package/lib/dom/index.d.ts.map +1 -0
  212. package/lib/dom/index.js +126 -0
  213. package/lib/dom/index.js.map +1 -0
  214. package/lib/encoding-registry.d.ts +31 -0
  215. package/lib/encoding-registry.d.ts.map +1 -0
  216. package/lib/encoding-registry.js +85 -0
  217. package/lib/encoding-registry.js.map +1 -0
  218. package/lib/fs/index.d.ts +12 -0
  219. package/lib/fs/index.d.ts.map +1 -0
  220. package/lib/fs/index.js +9 -0
  221. package/lib/fs/index.js.map +1 -0
  222. package/lib/hash-calculate/hash-calculate.contribution.d.ts +6 -0
  223. package/lib/hash-calculate/hash-calculate.contribution.d.ts.map +1 -0
  224. package/lib/hash-calculate/hash-calculate.contribution.js +27 -0
  225. package/lib/hash-calculate/hash-calculate.contribution.js.map +1 -0
  226. package/lib/index.d.ts +28 -0
  227. package/lib/index.d.ts.map +1 -0
  228. package/lib/index.js +34 -0
  229. package/lib/index.js.map +1 -0
  230. package/lib/keybinding/index.d.ts +2 -0
  231. package/lib/keybinding/index.d.ts.map +1 -0
  232. package/lib/keybinding/index.js +5 -0
  233. package/lib/keybinding/index.js.map +1 -0
  234. package/lib/keybinding/keybinding.d.ts +340 -0
  235. package/lib/keybinding/keybinding.d.ts.map +1 -0
  236. package/lib/keybinding/keybinding.js +720 -0
  237. package/lib/keybinding/keybinding.js.map +1 -0
  238. package/lib/keyboard/index.d.ts +4 -0
  239. package/lib/keyboard/index.d.ts.map +1 -0
  240. package/lib/keyboard/index.js +7 -0
  241. package/lib/keyboard/index.js.map +1 -0
  242. package/lib/keyboard/keyboard-layout-provider.d.ts +92 -0
  243. package/lib/keyboard/keyboard-layout-provider.d.ts.map +1 -0
  244. package/lib/keyboard/keyboard-layout-provider.js +344 -0
  245. package/lib/keyboard/keyboard-layout-provider.js.map +1 -0
  246. package/lib/keyboard/keyboard-layout-service.d.ts +65 -0
  247. package/lib/keyboard/keyboard-layout-service.d.ts.map +1 -0
  248. package/lib/keyboard/keyboard-layout-service.js +415 -0
  249. package/lib/keyboard/keyboard-layout-service.js.map +1 -0
  250. package/lib/keyboard/keys.d.ts +294 -0
  251. package/lib/keyboard/keys.d.ts.map +1 -0
  252. package/lib/keyboard/keys.js +699 -0
  253. package/lib/keyboard/keys.js.map +1 -0
  254. package/lib/keyboard/layouts/_.contribution.d.ts +9 -0
  255. package/lib/keyboard/layouts/_.contribution.d.ts.map +1 -0
  256. package/lib/keyboard/layouts/_.contribution.js +21 -0
  257. package/lib/keyboard/layouts/_.contribution.js.map +1 -0
  258. package/lib/keyboard/layouts/cz.win.d.ts +2 -0
  259. package/lib/keyboard/layouts/cz.win.d.ts.map +1 -0
  260. package/lib/keyboard/layouts/cz.win.js +169 -0
  261. package/lib/keyboard/layouts/cz.win.js.map +1 -0
  262. package/lib/keyboard/layouts/de-swiss.win.d.ts +2 -0
  263. package/lib/keyboard/layouts/de-swiss.win.d.ts.map +1 -0
  264. package/lib/keyboard/layouts/de-swiss.win.js +169 -0
  265. package/lib/keyboard/layouts/de-swiss.win.js.map +1 -0
  266. package/lib/keyboard/layouts/de.darwin.d.ts +2 -0
  267. package/lib/keyboard/layouts/de.darwin.d.ts.map +1 -0
  268. package/lib/keyboard/layouts/de.darwin.js +132 -0
  269. package/lib/keyboard/layouts/de.darwin.js.map +1 -0
  270. package/lib/keyboard/layouts/de.linux.d.ts +2 -0
  271. package/lib/keyboard/layouts/de.linux.d.ts.map +1 -0
  272. package/lib/keyboard/layouts/de.linux.js +187 -0
  273. package/lib/keyboard/layouts/de.linux.js.map +1 -0
  274. package/lib/keyboard/layouts/de.win.d.ts +2 -0
  275. package/lib/keyboard/layouts/de.win.d.ts.map +1 -0
  276. package/lib/keyboard/layouts/de.win.js +169 -0
  277. package/lib/keyboard/layouts/de.win.js.map +1 -0
  278. package/lib/keyboard/layouts/dk.win.d.ts +2 -0
  279. package/lib/keyboard/layouts/dk.win.d.ts.map +1 -0
  280. package/lib/keyboard/layouts/dk.win.js +169 -0
  281. package/lib/keyboard/layouts/dk.win.js.map +1 -0
  282. package/lib/keyboard/layouts/dvorak.darwin.d.ts +2 -0
  283. package/lib/keyboard/layouts/dvorak.darwin.d.ts.map +1 -0
  284. package/lib/keyboard/layouts/dvorak.darwin.js +132 -0
  285. package/lib/keyboard/layouts/dvorak.darwin.js.map +1 -0
  286. package/lib/keyboard/layouts/en-belgian.win.d.ts +2 -0
  287. package/lib/keyboard/layouts/en-belgian.win.d.ts.map +1 -0
  288. package/lib/keyboard/layouts/en-belgian.win.js +169 -0
  289. package/lib/keyboard/layouts/en-belgian.win.js.map +1 -0
  290. package/lib/keyboard/layouts/en-ext.darwin.d.ts +2 -0
  291. package/lib/keyboard/layouts/en-ext.darwin.d.ts.map +1 -0
  292. package/lib/keyboard/layouts/en-ext.darwin.js +132 -0
  293. package/lib/keyboard/layouts/en-ext.darwin.js.map +1 -0
  294. package/lib/keyboard/layouts/en-in.win.d.ts +2 -0
  295. package/lib/keyboard/layouts/en-in.win.d.ts.map +1 -0
  296. package/lib/keyboard/layouts/en-in.win.js +169 -0
  297. package/lib/keyboard/layouts/en-in.win.js.map +1 -0
  298. package/lib/keyboard/layouts/en-intl.darwin.d.ts +2 -0
  299. package/lib/keyboard/layouts/en-intl.darwin.d.ts.map +1 -0
  300. package/lib/keyboard/layouts/en-intl.darwin.js +132 -0
  301. package/lib/keyboard/layouts/en-intl.darwin.js.map +1 -0
  302. package/lib/keyboard/layouts/en-intl.win.d.ts +2 -0
  303. package/lib/keyboard/layouts/en-intl.win.d.ts.map +1 -0
  304. package/lib/keyboard/layouts/en-intl.win.js +169 -0
  305. package/lib/keyboard/layouts/en-intl.win.js.map +1 -0
  306. package/lib/keyboard/layouts/en-uk.darwin.d.ts +2 -0
  307. package/lib/keyboard/layouts/en-uk.darwin.d.ts.map +1 -0
  308. package/lib/keyboard/layouts/en-uk.darwin.js +132 -0
  309. package/lib/keyboard/layouts/en-uk.darwin.js.map +1 -0
  310. package/lib/keyboard/layouts/en-uk.win.d.ts +2 -0
  311. package/lib/keyboard/layouts/en-uk.win.d.ts.map +1 -0
  312. package/lib/keyboard/layouts/en-uk.win.js +169 -0
  313. package/lib/keyboard/layouts/en-uk.win.js.map +1 -0
  314. package/lib/keyboard/layouts/en.darwin.d.ts +2 -0
  315. package/lib/keyboard/layouts/en.darwin.d.ts.map +1 -0
  316. package/lib/keyboard/layouts/en.darwin.js +140 -0
  317. package/lib/keyboard/layouts/en.darwin.js.map +1 -0
  318. package/lib/keyboard/layouts/en.linux.d.ts +2 -0
  319. package/lib/keyboard/layouts/en.linux.d.ts.map +1 -0
  320. package/lib/keyboard/layouts/en.linux.js +189 -0
  321. package/lib/keyboard/layouts/en.linux.js.map +1 -0
  322. package/lib/keyboard/layouts/en.win.d.ts +2 -0
  323. package/lib/keyboard/layouts/en.win.d.ts.map +1 -0
  324. package/lib/keyboard/layouts/en.win.js +174 -0
  325. package/lib/keyboard/layouts/en.win.js.map +1 -0
  326. package/lib/keyboard/layouts/es-latin.win.d.ts +2 -0
  327. package/lib/keyboard/layouts/es-latin.win.d.ts.map +1 -0
  328. package/lib/keyboard/layouts/es-latin.win.js +169 -0
  329. package/lib/keyboard/layouts/es-latin.win.js.map +1 -0
  330. package/lib/keyboard/layouts/es.darwin.d.ts +2 -0
  331. package/lib/keyboard/layouts/es.darwin.d.ts.map +1 -0
  332. package/lib/keyboard/layouts/es.darwin.js +132 -0
  333. package/lib/keyboard/layouts/es.darwin.js.map +1 -0
  334. package/lib/keyboard/layouts/es.linux.d.ts +2 -0
  335. package/lib/keyboard/layouts/es.linux.d.ts.map +1 -0
  336. package/lib/keyboard/layouts/es.linux.js +187 -0
  337. package/lib/keyboard/layouts/es.linux.js.map +1 -0
  338. package/lib/keyboard/layouts/es.win.d.ts +2 -0
  339. package/lib/keyboard/layouts/es.win.d.ts.map +1 -0
  340. package/lib/keyboard/layouts/es.win.js +169 -0
  341. package/lib/keyboard/layouts/es.win.js.map +1 -0
  342. package/lib/keyboard/layouts/fr.darwin.d.ts +2 -0
  343. package/lib/keyboard/layouts/fr.darwin.d.ts.map +1 -0
  344. package/lib/keyboard/layouts/fr.darwin.js +132 -0
  345. package/lib/keyboard/layouts/fr.darwin.js.map +1 -0
  346. package/lib/keyboard/layouts/fr.linux.d.ts +2 -0
  347. package/lib/keyboard/layouts/fr.linux.d.ts.map +1 -0
  348. package/lib/keyboard/layouts/fr.linux.js +187 -0
  349. package/lib/keyboard/layouts/fr.linux.js.map +1 -0
  350. package/lib/keyboard/layouts/fr.win.d.ts +2 -0
  351. package/lib/keyboard/layouts/fr.win.d.ts.map +1 -0
  352. package/lib/keyboard/layouts/fr.win.js +169 -0
  353. package/lib/keyboard/layouts/fr.win.js.map +1 -0
  354. package/lib/keyboard/layouts/hu.win.d.ts +2 -0
  355. package/lib/keyboard/layouts/hu.win.d.ts.map +1 -0
  356. package/lib/keyboard/layouts/hu.win.js +169 -0
  357. package/lib/keyboard/layouts/hu.win.js.map +1 -0
  358. package/lib/keyboard/layouts/it.darwin.d.ts +2 -0
  359. package/lib/keyboard/layouts/it.darwin.d.ts.map +1 -0
  360. package/lib/keyboard/layouts/it.darwin.js +132 -0
  361. package/lib/keyboard/layouts/it.darwin.js.map +1 -0
  362. package/lib/keyboard/layouts/it.win.d.ts +2 -0
  363. package/lib/keyboard/layouts/it.win.d.ts.map +1 -0
  364. package/lib/keyboard/layouts/it.win.js +169 -0
  365. package/lib/keyboard/layouts/it.win.js.map +1 -0
  366. package/lib/keyboard/layouts/jp-roman.darwin.d.ts +2 -0
  367. package/lib/keyboard/layouts/jp-roman.darwin.d.ts.map +1 -0
  368. package/lib/keyboard/layouts/jp-roman.darwin.js +132 -0
  369. package/lib/keyboard/layouts/jp-roman.darwin.js.map +1 -0
  370. package/lib/keyboard/layouts/jp.darwin.d.ts +2 -0
  371. package/lib/keyboard/layouts/jp.darwin.d.ts.map +1 -0
  372. package/lib/keyboard/layouts/jp.darwin.js +132 -0
  373. package/lib/keyboard/layouts/jp.darwin.js.map +1 -0
  374. package/lib/keyboard/layouts/ko.darwin.d.ts +2 -0
  375. package/lib/keyboard/layouts/ko.darwin.d.ts.map +1 -0
  376. package/lib/keyboard/layouts/ko.darwin.js +132 -0
  377. package/lib/keyboard/layouts/ko.darwin.js.map +1 -0
  378. package/lib/keyboard/layouts/layout.contribution.d.ts +3 -0
  379. package/lib/keyboard/layouts/layout.contribution.d.ts.map +1 -0
  380. package/lib/keyboard/layouts/layout.contribution.darwin.d.ts +2 -0
  381. package/lib/keyboard/layouts/layout.contribution.darwin.d.ts.map +1 -0
  382. package/lib/keyboard/layouts/layout.contribution.darwin.js +27 -0
  383. package/lib/keyboard/layouts/layout.contribution.darwin.js.map +1 -0
  384. package/lib/keyboard/layouts/layout.contribution.js +11 -0
  385. package/lib/keyboard/layouts/layout.contribution.js.map +1 -0
  386. package/lib/keyboard/layouts/layout.contribution.linux.d.ts +2 -0
  387. package/lib/keyboard/layouts/layout.contribution.linux.d.ts.map +1 -0
  388. package/lib/keyboard/layouts/layout.contribution.linux.js +16 -0
  389. package/lib/keyboard/layouts/layout.contribution.linux.js.map +1 -0
  390. package/lib/keyboard/layouts/layout.contribution.win.d.ts +2 -0
  391. package/lib/keyboard/layouts/layout.contribution.win.d.ts.map +1 -0
  392. package/lib/keyboard/layouts/layout.contribution.win.js +33 -0
  393. package/lib/keyboard/layouts/layout.contribution.win.js.map +1 -0
  394. package/lib/keyboard/layouts/no.win.d.ts +2 -0
  395. package/lib/keyboard/layouts/no.win.d.ts.map +1 -0
  396. package/lib/keyboard/layouts/no.win.js +169 -0
  397. package/lib/keyboard/layouts/no.win.js.map +1 -0
  398. package/lib/keyboard/layouts/pl.darwin.d.ts +2 -0
  399. package/lib/keyboard/layouts/pl.darwin.d.ts.map +1 -0
  400. package/lib/keyboard/layouts/pl.darwin.js +132 -0
  401. package/lib/keyboard/layouts/pl.darwin.js.map +1 -0
  402. package/lib/keyboard/layouts/pl.win.d.ts +2 -0
  403. package/lib/keyboard/layouts/pl.win.d.ts.map +1 -0
  404. package/lib/keyboard/layouts/pl.win.js +169 -0
  405. package/lib/keyboard/layouts/pl.win.js.map +1 -0
  406. package/lib/keyboard/layouts/pt-br.win.d.ts +2 -0
  407. package/lib/keyboard/layouts/pt-br.win.d.ts.map +1 -0
  408. package/lib/keyboard/layouts/pt-br.win.js +169 -0
  409. package/lib/keyboard/layouts/pt-br.win.js.map +1 -0
  410. package/lib/keyboard/layouts/pt.darwin.d.ts +2 -0
  411. package/lib/keyboard/layouts/pt.darwin.d.ts.map +1 -0
  412. package/lib/keyboard/layouts/pt.darwin.js +132 -0
  413. package/lib/keyboard/layouts/pt.darwin.js.map +1 -0
  414. package/lib/keyboard/layouts/pt.win.d.ts +2 -0
  415. package/lib/keyboard/layouts/pt.win.d.ts.map +1 -0
  416. package/lib/keyboard/layouts/pt.win.js +169 -0
  417. package/lib/keyboard/layouts/pt.win.js.map +1 -0
  418. package/lib/keyboard/layouts/ru.darwin.d.ts +2 -0
  419. package/lib/keyboard/layouts/ru.darwin.d.ts.map +1 -0
  420. package/lib/keyboard/layouts/ru.darwin.js +132 -0
  421. package/lib/keyboard/layouts/ru.darwin.js.map +1 -0
  422. package/lib/keyboard/layouts/ru.linux.d.ts +2 -0
  423. package/lib/keyboard/layouts/ru.linux.d.ts.map +1 -0
  424. package/lib/keyboard/layouts/ru.linux.js +187 -0
  425. package/lib/keyboard/layouts/ru.linux.js.map +1 -0
  426. package/lib/keyboard/layouts/ru.win.d.ts +2 -0
  427. package/lib/keyboard/layouts/ru.win.d.ts.map +1 -0
  428. package/lib/keyboard/layouts/ru.win.js +169 -0
  429. package/lib/keyboard/layouts/ru.win.js.map +1 -0
  430. package/lib/keyboard/layouts/sv.darwin.d.ts +2 -0
  431. package/lib/keyboard/layouts/sv.darwin.d.ts.map +1 -0
  432. package/lib/keyboard/layouts/sv.darwin.js +132 -0
  433. package/lib/keyboard/layouts/sv.darwin.js.map +1 -0
  434. package/lib/keyboard/layouts/sv.win.d.ts +2 -0
  435. package/lib/keyboard/layouts/sv.win.d.ts.map +1 -0
  436. package/lib/keyboard/layouts/sv.win.js +171 -0
  437. package/lib/keyboard/layouts/sv.win.js.map +1 -0
  438. package/lib/keyboard/layouts/thai.win.d.ts +2 -0
  439. package/lib/keyboard/layouts/thai.win.d.ts.map +1 -0
  440. package/lib/keyboard/layouts/thai.win.js +169 -0
  441. package/lib/keyboard/layouts/thai.win.js.map +1 -0
  442. package/lib/keyboard/layouts/tr.win.d.ts +2 -0
  443. package/lib/keyboard/layouts/tr.win.d.ts.map +1 -0
  444. package/lib/keyboard/layouts/tr.win.js +169 -0
  445. package/lib/keyboard/layouts/tr.win.js.map +1 -0
  446. package/lib/keyboard/layouts/zh-hans.darwin.d.ts +2 -0
  447. package/lib/keyboard/layouts/zh-hans.darwin.d.ts.map +1 -0
  448. package/lib/keyboard/layouts/zh-hans.darwin.js +132 -0
  449. package/lib/keyboard/layouts/zh-hans.darwin.js.map +1 -0
  450. package/lib/layout/accordion/tab-bar-toolbar.d.ts +25 -0
  451. package/lib/layout/accordion/tab-bar-toolbar.d.ts.map +1 -0
  452. package/lib/layout/accordion/tab-bar-toolbar.js +37 -0
  453. package/lib/layout/accordion/tab-bar-toolbar.js.map +1 -0
  454. package/lib/layout/accordion/view-context-key.registry.d.ts +9 -0
  455. package/lib/layout/accordion/view-context-key.registry.d.ts.map +1 -0
  456. package/lib/layout/accordion/view-context-key.registry.js +38 -0
  457. package/lib/layout/accordion/view-context-key.registry.js.map +1 -0
  458. package/lib/layout/index.d.ts +103 -0
  459. package/lib/layout/index.d.ts.map +1 -0
  460. package/lib/layout/index.js +143 -0
  461. package/lib/layout/index.js.map +1 -0
  462. package/lib/layout/layout-state.d.ts +24 -0
  463. package/lib/layout/layout-state.d.ts.map +1 -0
  464. package/lib/layout/layout-state.js +99 -0
  465. package/lib/layout/layout-state.js.map +1 -0
  466. package/lib/logger/browser-logger.d.ts +17 -0
  467. package/lib/logger/browser-logger.d.ts.map +1 -0
  468. package/lib/logger/browser-logger.js +50 -0
  469. package/lib/logger/browser-logger.js.map +1 -0
  470. package/lib/logger/index.d.ts +2 -0
  471. package/lib/logger/index.d.ts.map +1 -0
  472. package/lib/logger/index.js +5 -0
  473. package/lib/logger/index.js.map +1 -0
  474. package/lib/menu/next/base.d.ts +242 -0
  475. package/lib/menu/next/base.d.ts.map +1 -0
  476. package/lib/menu/next/base.js +267 -0
  477. package/lib/menu/next/base.js.map +1 -0
  478. package/lib/menu/next/ctxmenu-service.d.ts +42 -0
  479. package/lib/menu/next/ctxmenu-service.d.ts.map +1 -0
  480. package/lib/menu/next/ctxmenu-service.js +151 -0
  481. package/lib/menu/next/ctxmenu-service.js.map +1 -0
  482. package/lib/menu/next/index.d.ts +11 -0
  483. package/lib/menu/next/index.d.ts.map +1 -0
  484. package/lib/menu/next/index.js +14 -0
  485. package/lib/menu/next/index.js.map +1 -0
  486. package/lib/menu/next/menu-id.d.ts +59 -0
  487. package/lib/menu/next/menu-id.d.ts.map +1 -0
  488. package/lib/menu/next/menu-id.js +73 -0
  489. package/lib/menu/next/menu-id.js.map +1 -0
  490. package/lib/menu/next/menu-service.d.ts +9 -0
  491. package/lib/menu/next/menu-service.d.ts.map +1 -0
  492. package/lib/menu/next/menu-service.js +205 -0
  493. package/lib/menu/next/menu-service.js.map +1 -0
  494. package/lib/menu/next/menu-util.d.ts +18 -0
  495. package/lib/menu/next/menu-util.d.ts.map +1 -0
  496. package/lib/menu/next/menu-util.js +64 -0
  497. package/lib/menu/next/menu-util.js.map +1 -0
  498. package/lib/menu/next/menu.contrib.interface.d.ts +22 -0
  499. package/lib/menu/next/menu.contrib.interface.d.ts.map +1 -0
  500. package/lib/menu/next/menu.contrib.interface.js +9 -0
  501. package/lib/menu/next/menu.contrib.interface.js.map +1 -0
  502. package/lib/menu/next/menu.interface.d.ts +100 -0
  503. package/lib/menu/next/menu.interface.d.ts.map +1 -0
  504. package/lib/menu/next/menu.interface.js +192 -0
  505. package/lib/menu/next/menu.interface.js.map +1 -0
  506. package/lib/menu/next/menubar-service.d.ts +53 -0
  507. package/lib/menu/next/menubar-service.d.ts.map +1 -0
  508. package/lib/menu/next/menubar-service.js +178 -0
  509. package/lib/menu/next/menubar-service.js.map +1 -0
  510. package/lib/menu/next/renderer/ctxmenu/base.d.ts +19 -0
  511. package/lib/menu/next/renderer/ctxmenu/base.d.ts.map +1 -0
  512. package/lib/menu/next/renderer/ctxmenu/base.js +7 -0
  513. package/lib/menu/next/renderer/ctxmenu/base.js.map +1 -0
  514. package/lib/menu/next/renderer/ctxmenu/browser.d.ts +19 -0
  515. package/lib/menu/next/renderer/ctxmenu/browser.d.ts.map +1 -0
  516. package/lib/menu/next/renderer/ctxmenu/browser.js +40 -0
  517. package/lib/menu/next/renderer/ctxmenu/browser.js.map +1 -0
  518. package/lib/menu/next/renderer/ctxmenu/electron.d.ts +34 -0
  519. package/lib/menu/next/renderer/ctxmenu/electron.d.ts.map +1 -0
  520. package/lib/menu/next/renderer/ctxmenu/electron.js +198 -0
  521. package/lib/menu/next/renderer/ctxmenu/electron.js.map +1 -0
  522. package/lib/menu/next/toolbar-action.service.d.ts +50 -0
  523. package/lib/menu/next/toolbar-action.service.d.ts.map +1 -0
  524. package/lib/menu/next/toolbar-action.service.js +93 -0
  525. package/lib/menu/next/toolbar-action.service.js.map +1 -0
  526. package/lib/monaco/index.d.ts +99 -0
  527. package/lib/monaco/index.d.ts.map +1 -0
  528. package/lib/monaco/index.js +32 -0
  529. package/lib/monaco/index.js.map +1 -0
  530. package/lib/opener/command-opener.d.ts +12 -0
  531. package/lib/opener/command-opener.d.ts.map +1 -0
  532. package/lib/opener/command-opener.js +49 -0
  533. package/lib/opener/command-opener.js.map +1 -0
  534. package/lib/opener/default-opener.d.ts +8 -0
  535. package/lib/opener/default-opener.d.ts.map +1 -0
  536. package/lib/opener/default-opener.js +32 -0
  537. package/lib/opener/default-opener.js.map +1 -0
  538. package/lib/opener/http-opener.d.ts +9 -0
  539. package/lib/opener/http-opener.d.ts.map +1 -0
  540. package/lib/opener/http-opener.js +33 -0
  541. package/lib/opener/http-opener.js.map +1 -0
  542. package/lib/opener/index.d.ts +16 -0
  543. package/lib/opener/index.d.ts.map +1 -0
  544. package/lib/opener/index.js +6 -0
  545. package/lib/opener/index.js.map +1 -0
  546. package/lib/opener/opener.contribution.d.ts +14 -0
  547. package/lib/opener/opener.contribution.d.ts.map +1 -0
  548. package/lib/opener/opener.contribution.js +63 -0
  549. package/lib/opener/opener.contribution.js.map +1 -0
  550. package/lib/opener/opener.service.d.ts +14 -0
  551. package/lib/opener/opener.service.d.ts.map +1 -0
  552. package/lib/opener/opener.service.js +67 -0
  553. package/lib/opener/opener.service.js.map +1 -0
  554. package/lib/preferences/early-preferences.d.ts +24 -0
  555. package/lib/preferences/early-preferences.d.ts.map +1 -0
  556. package/lib/preferences/early-preferences.js +96 -0
  557. package/lib/preferences/early-preferences.js.map +1 -0
  558. package/lib/preferences/index.d.ts +9 -0
  559. package/lib/preferences/index.d.ts.map +1 -0
  560. package/lib/preferences/index.js +12 -0
  561. package/lib/preferences/index.js.map +1 -0
  562. package/lib/preferences/preference-configurations.d.ts +22 -0
  563. package/lib/preferences/preference-configurations.d.ts.map +1 -0
  564. package/lib/preferences/preference-configurations.js +68 -0
  565. package/lib/preferences/preference-configurations.js.map +1 -0
  566. package/lib/preferences/preference-contribution.d.ts +82 -0
  567. package/lib/preferences/preference-contribution.d.ts.map +1 -0
  568. package/lib/preferences/preference-contribution.js +325 -0
  569. package/lib/preferences/preference-contribution.js.map +1 -0
  570. package/lib/preferences/preference-provider.d.ts +117 -0
  571. package/lib/preferences/preference-provider.d.ts.map +1 -0
  572. package/lib/preferences/preference-provider.js +275 -0
  573. package/lib/preferences/preference-provider.js.map +1 -0
  574. package/lib/preferences/preference-proxy.d.ts +45 -0
  575. package/lib/preferences/preference-proxy.d.ts.map +1 -0
  576. package/lib/preferences/preference-proxy.js +195 -0
  577. package/lib/preferences/preference-proxy.js.map +1 -0
  578. package/lib/preferences/preference-scope.d.ts +3 -0
  579. package/lib/preferences/preference-scope.d.ts.map +1 -0
  580. package/lib/preferences/preference-scope.js +6 -0
  581. package/lib/preferences/preference-scope.js.map +1 -0
  582. package/lib/preferences/preference-service.d.ts +194 -0
  583. package/lib/preferences/preference-service.d.ts.map +1 -0
  584. package/lib/preferences/preference-service.js +425 -0
  585. package/lib/preferences/preference-service.js.map +1 -0
  586. package/lib/preferences/settings.d.ts +41 -0
  587. package/lib/preferences/settings.d.ts.map +1 -0
  588. package/lib/preferences/settings.js +5 -0
  589. package/lib/preferences/settings.js.map +1 -0
  590. package/lib/progress/index.d.ts +36 -0
  591. package/lib/progress/index.d.ts.map +1 -0
  592. package/lib/progress/index.js +10 -0
  593. package/lib/progress/index.js.map +1 -0
  594. package/lib/progress/progress-bar.d.ts +7 -0
  595. package/lib/progress/progress-bar.d.ts.map +1 -0
  596. package/lib/progress/progress-bar.js +14 -0
  597. package/lib/progress/progress-bar.js.map +1 -0
  598. package/lib/progress/progress-indicator.d.ts +12 -0
  599. package/lib/progress/progress-indicator.d.ts.map +1 -0
  600. package/lib/progress/progress-indicator.js +106 -0
  601. package/lib/progress/progress-indicator.js.map +1 -0
  602. package/lib/progress/progress.module.less +40 -0
  603. package/lib/progress/progress.service.d.ts +19 -0
  604. package/lib/progress/progress.service.d.ts.map +1 -0
  605. package/lib/progress/progress.service.js +343 -0
  606. package/lib/progress/progress.service.js.map +1 -0
  607. package/lib/quick-open/index.d.ts +467 -0
  608. package/lib/quick-open/index.d.ts.map +1 -0
  609. package/lib/quick-open/index.js +145 -0
  610. package/lib/quick-open/index.js.map +1 -0
  611. package/lib/quick-open/recent-files.d.ts +11 -0
  612. package/lib/quick-open/recent-files.d.ts.map +1 -0
  613. package/lib/quick-open/recent-files.js +73 -0
  614. package/lib/quick-open/recent-files.js.map +1 -0
  615. package/lib/raw-context-key.d.ts +57 -0
  616. package/lib/raw-context-key.d.ts.map +1 -0
  617. package/lib/raw-context-key.js +96 -0
  618. package/lib/raw-context-key.js.map +1 -0
  619. package/lib/react-hooks/event.d.ts +11 -0
  620. package/lib/react-hooks/event.d.ts.map +1 -0
  621. package/lib/react-hooks/event.js +64 -0
  622. package/lib/react-hooks/event.js.map +1 -0
  623. package/lib/react-hooks/hot-key.d.ts +5 -0
  624. package/lib/react-hooks/hot-key.d.ts.map +1 -0
  625. package/lib/react-hooks/hot-key.js +48 -0
  626. package/lib/react-hooks/hot-key.js.map +1 -0
  627. package/lib/react-hooks/index.d.ts +4 -0
  628. package/lib/react-hooks/index.d.ts.map +1 -0
  629. package/lib/react-hooks/index.js +7 -0
  630. package/lib/react-hooks/index.js.map +1 -0
  631. package/lib/react-hooks/injectable-hooks.d.ts +3 -0
  632. package/lib/react-hooks/injectable-hooks.d.ts.map +1 -0
  633. package/lib/react-hooks/injectable-hooks.js +33 -0
  634. package/lib/react-hooks/injectable-hooks.js.map +1 -0
  635. package/lib/react-hooks/portal-hooks.d.ts +2 -0
  636. package/lib/react-hooks/portal-hooks.d.ts.map +1 -0
  637. package/lib/react-hooks/portal-hooks.js +36 -0
  638. package/lib/react-hooks/portal-hooks.js.map +1 -0
  639. package/lib/react-providers/config-provider.d.ts +182 -0
  640. package/lib/react-providers/config-provider.d.ts.map +1 -0
  641. package/lib/react-providers/config-provider.js +24 -0
  642. package/lib/react-providers/config-provider.js.map +1 -0
  643. package/lib/react-providers/index.d.ts +3 -0
  644. package/lib/react-providers/index.d.ts.map +1 -0
  645. package/lib/react-providers/index.js +6 -0
  646. package/lib/react-providers/index.js.map +1 -0
  647. package/lib/react-providers/slot.d.ts +73 -0
  648. package/lib/react-providers/slot.d.ts.map +1 -0
  649. package/lib/react-providers/slot.js +184 -0
  650. package/lib/react-providers/slot.js.map +1 -0
  651. package/lib/services/clipboard.service.d.ts +17 -0
  652. package/lib/services/clipboard.service.d.ts.map +1 -0
  653. package/lib/services/clipboard.service.js +57 -0
  654. package/lib/services/clipboard.service.js.map +1 -0
  655. package/lib/services/credentials-service.d.ts +36 -0
  656. package/lib/services/credentials-service.d.ts.map +1 -0
  657. package/lib/services/credentials-service.js +62 -0
  658. package/lib/services/credentials-service.js.map +1 -0
  659. package/lib/services/cryptr-service.d.ts +11 -0
  660. package/lib/services/cryptr-service.d.ts.map +1 -0
  661. package/lib/services/cryptr-service.js +24 -0
  662. package/lib/services/cryptr-service.js.map +1 -0
  663. package/lib/services/external-uri.service.d.ts +28 -0
  664. package/lib/services/external-uri.service.d.ts.map +1 -0
  665. package/lib/services/external-uri.service.js +58 -0
  666. package/lib/services/external-uri.service.js.map +1 -0
  667. package/lib/services/index.d.ts +8 -0
  668. package/lib/services/index.d.ts.map +1 -0
  669. package/lib/services/index.js +11 -0
  670. package/lib/services/index.js.map +1 -0
  671. package/lib/services/label-service.d.ts +74 -0
  672. package/lib/services/label-service.d.ts.map +1 -0
  673. package/lib/services/label-service.js +306 -0
  674. package/lib/services/label-service.js.map +1 -0
  675. package/lib/services/status-bar-service.d.ts +86 -0
  676. package/lib/services/status-bar-service.d.ts.map +1 -0
  677. package/lib/services/status-bar-service.js +25 -0
  678. package/lib/services/status-bar-service.js.map +1 -0
  679. package/lib/services/storage-service.d.ts +72 -0
  680. package/lib/services/storage-service.d.ts.map +1 -0
  681. package/lib/services/storage-service.js +128 -0
  682. package/lib/services/storage-service.js.map +1 -0
  683. package/lib/style/codicons/README.md +32 -0
  684. package/lib/style/codicons/codicon-animations.css +15 -0
  685. package/lib/style/entry.less +25 -0
  686. package/lib/style/icon/fileicons/file-default.svg +1 -0
  687. package/lib/style/icon/fileicons/folder-default.svg +1 -0
  688. package/lib/style/icon/fileicons.less +9 -0
  689. package/lib/style/icon/icon.d.ts +19 -0
  690. package/lib/style/icon/icon.d.ts.map +1 -0
  691. package/lib/style/icon/icon.js +64 -0
  692. package/lib/style/icon/icon.js.map +1 -0
  693. package/lib/style/icon/ide-iconfont.d.ts +5 -0
  694. package/lib/style/icon/ide-iconfont.d.ts.map +1 -0
  695. package/lib/style/icon/ide-iconfont.js +10 -0
  696. package/lib/style/icon/ide-iconfont.js.map +1 -0
  697. package/lib/style/icon/index.less +54 -0
  698. package/lib/style/icon/seti.woff +0 -0
  699. package/lib/style/icon/symbol-icons/boolean-dark.svg +3 -0
  700. package/lib/style/icon/symbol-icons/boolean-light.svg +3 -0
  701. package/lib/style/icon/symbol-icons/class-dark.svg +3 -0
  702. package/lib/style/icon/symbol-icons/class-light.svg +3 -0
  703. package/lib/style/icon/symbol-icons/constant-dark.svg +4 -0
  704. package/lib/style/icon/symbol-icons/constant-light.svg +4 -0
  705. package/lib/style/icon/symbol-icons/enumerator-dark.svg +3 -0
  706. package/lib/style/icon/symbol-icons/enumerator-item-dark.svg +3 -0
  707. package/lib/style/icon/symbol-icons/enumerator-item-light.svg +3 -0
  708. package/lib/style/icon/symbol-icons/enumerator-light.svg +3 -0
  709. package/lib/style/icon/symbol-icons/event-dark.svg +3 -0
  710. package/lib/style/icon/symbol-icons/event-light.svg +3 -0
  711. package/lib/style/icon/symbol-icons/field-dark.svg +3 -0
  712. package/lib/style/icon/symbol-icons/field-light.svg +3 -0
  713. package/lib/style/icon/symbol-icons/file-dark.svg +3 -0
  714. package/lib/style/icon/symbol-icons/file-light.svg +3 -0
  715. package/lib/style/icon/symbol-icons/indexer-dark.svg +3 -0
  716. package/lib/style/icon/symbol-icons/indexer-light.svg +3 -0
  717. package/lib/style/icon/symbol-icons/interface-dark.svg +3 -0
  718. package/lib/style/icon/symbol-icons/interface-light.svg +3 -0
  719. package/lib/style/icon/symbol-icons/keyword-dark.svg +3 -0
  720. package/lib/style/icon/symbol-icons/keyword-light.svg +3 -0
  721. package/lib/style/icon/symbol-icons/method-dark.svg +3 -0
  722. package/lib/style/icon/symbol-icons/method-light.svg +3 -0
  723. package/lib/style/icon/symbol-icons/namespace-dark.svg +3 -0
  724. package/lib/style/icon/symbol-icons/namespace-light.svg +3 -0
  725. package/lib/style/icon/symbol-icons/numeric-dark.svg +3 -0
  726. package/lib/style/icon/symbol-icons/numeric-light.svg +3 -0
  727. package/lib/style/icon/symbol-icons/operator-dark.svg +3 -0
  728. package/lib/style/icon/symbol-icons/operator-light.svg +3 -0
  729. package/lib/style/icon/symbol-icons/property-dark.svg +3 -0
  730. package/lib/style/icon/symbol-icons/property-light.svg +3 -0
  731. package/lib/style/icon/symbol-icons/snippet-dark.svg +3 -0
  732. package/lib/style/icon/symbol-icons/snippet-light.svg +3 -0
  733. package/lib/style/icon/symbol-icons/string-dark.svg +3 -0
  734. package/lib/style/icon/symbol-icons/string-light.svg +3 -0
  735. package/lib/style/icon/symbol-icons/structure-dark.svg +3 -0
  736. package/lib/style/icon/symbol-icons/structure-light.svg +3 -0
  737. package/lib/style/icon/symbol-icons/symbol-icons.css +284 -0
  738. package/lib/style/icon/symbol-icons/template-dark.svg +3 -0
  739. package/lib/style/icon/symbol-icons/template-light.svg +3 -0
  740. package/lib/style/icon/symbol-icons/variable-dark.svg +3 -0
  741. package/lib/style/icon/symbol-icons/variable-light.svg +3 -0
  742. package/lib/style/icon.less +8 -0
  743. package/lib/style/index.less +14 -0
  744. package/lib/style/monaco-override.less +86 -0
  745. package/lib/style/normalize.less +89 -0
  746. package/lib/style/octicons/octicons-cdn.css +269 -0
  747. package/lib/style/octicons/octicons.css +263 -0
  748. package/lib/style/octicons/octicons.html +1882 -0
  749. package/lib/style/octicons/octicons.svg +582 -0
  750. package/lib/style/octicons/octicons.ttf +0 -0
  751. package/lib/style/override.less +80 -0
  752. package/lib/style/toolbar.less +193 -0
  753. package/lib/style/utilities.less +18 -0
  754. package/lib/style/variable.less +16 -0
  755. package/lib/toolbar/components/auto-complete.d.ts +1 -0
  756. package/lib/toolbar/components/auto-complete.d.ts.map +1 -0
  757. package/lib/toolbar/components/auto-complete.js +2 -0
  758. package/lib/toolbar/components/auto-complete.js.map +1 -0
  759. package/lib/toolbar/components/button.d.ts +11 -0
  760. package/lib/toolbar/components/button.d.ts.map +1 -0
  761. package/lib/toolbar/components/button.js +324 -0
  762. package/lib/toolbar/components/button.js.map +1 -0
  763. package/lib/toolbar/components/index.d.ts +3 -0
  764. package/lib/toolbar/components/index.d.ts.map +1 -0
  765. package/lib/toolbar/components/index.js +6 -0
  766. package/lib/toolbar/components/index.js.map +1 -0
  767. package/lib/toolbar/components/select.d.ts +5 -0
  768. package/lib/toolbar/components/select.d.ts.map +1 -0
  769. package/lib/toolbar/components/select.js +161 -0
  770. package/lib/toolbar/components/select.js.map +1 -0
  771. package/lib/toolbar/index.d.ts +4 -0
  772. package/lib/toolbar/index.d.ts.map +1 -0
  773. package/lib/toolbar/index.js +9 -0
  774. package/lib/toolbar/index.js.map +1 -0
  775. package/lib/toolbar/toolbar.d.ts +17 -0
  776. package/lib/toolbar/toolbar.d.ts.map +1 -0
  777. package/lib/toolbar/toolbar.js +508 -0
  778. package/lib/toolbar/toolbar.js.map +1 -0
  779. package/lib/toolbar/toolbar.popover.registry.d.ts +11 -0
  780. package/lib/toolbar/toolbar.popover.registry.d.ts.map +1 -0
  781. package/lib/toolbar/toolbar.popover.registry.js +36 -0
  782. package/lib/toolbar/toolbar.popover.registry.js.map +1 -0
  783. package/lib/toolbar/toolbar.registry.d.ts +46 -0
  784. package/lib/toolbar/toolbar.registry.d.ts.map +1 -0
  785. package/lib/toolbar/toolbar.registry.js +283 -0
  786. package/lib/toolbar/toolbar.registry.js.map +1 -0
  787. package/lib/toolbar/types.d.ts +286 -0
  788. package/lib/toolbar/types.d.ts.map +1 -0
  789. package/lib/toolbar/types.js +18 -0
  790. package/lib/toolbar/types.js.map +1 -0
  791. package/lib/tree/index.d.ts +4 -0
  792. package/lib/tree/index.d.ts.map +1 -0
  793. package/lib/tree/index.js +7 -0
  794. package/lib/tree/index.js.map +1 -0
  795. package/lib/tree/tree-expansion.d.ts +16 -0
  796. package/lib/tree/tree-expansion.d.ts.map +1 -0
  797. package/lib/tree/tree-expansion.js +20 -0
  798. package/lib/tree/tree-expansion.js.map +1 -0
  799. package/lib/tree/tree-selection.d.ts +48 -0
  800. package/lib/tree/tree-selection.d.ts.map +1 -0
  801. package/lib/tree/tree-selection.js +64 -0
  802. package/lib/tree/tree-selection.js.map +1 -0
  803. package/lib/tree/tree.d.ts +195 -0
  804. package/lib/tree/tree.d.ts.map +1 -0
  805. package/lib/tree/tree.js +108 -0
  806. package/lib/tree/tree.js.map +1 -0
  807. package/lib/utils/create-overlay.d.ts +8 -0
  808. package/lib/utils/create-overlay.d.ts.map +1 -0
  809. package/lib/utils/create-overlay.js +50 -0
  810. package/lib/utils/create-overlay.js.map +1 -0
  811. package/lib/utils/electron.d.ts +23 -0
  812. package/lib/utils/electron.d.ts.map +1 -0
  813. package/lib/utils/electron.js +56 -0
  814. package/lib/utils/electron.js.map +1 -0
  815. package/lib/utils/env.d.ts +4 -0
  816. package/lib/utils/env.d.ts.map +1 -0
  817. package/lib/utils/env.js +31 -0
  818. package/lib/utils/env.js.map +1 -0
  819. package/lib/utils/icon.d.ts +7 -0
  820. package/lib/utils/icon.d.ts.map +1 -0
  821. package/lib/utils/icon.js +18 -0
  822. package/lib/utils/icon.js.map +1 -0
  823. package/lib/utils/index.d.ts +6 -0
  824. package/lib/utils/index.d.ts.map +1 -0
  825. package/lib/utils/index.js +9 -0
  826. package/lib/utils/index.js.map +1 -0
  827. package/lib/utils/parse.d.ts +25 -0
  828. package/lib/utils/parse.d.ts.map +1 -0
  829. package/lib/utils/parse.js +72 -0
  830. package/lib/utils/parse.js.map +1 -0
  831. package/lib/utils/react-hooks.d.ts +12 -0
  832. package/lib/utils/react-hooks.d.ts.map +1 -0
  833. package/lib/utils/react-hooks.js +84 -0
  834. package/lib/utils/react-hooks.js.map +1 -0
  835. package/lib/variable/index.d.ts +2 -0
  836. package/lib/variable/index.d.ts.map +1 -0
  837. package/lib/variable/index.js +5 -0
  838. package/lib/variable/index.js.map +1 -0
  839. package/lib/variable/variable.d.ts +49 -0
  840. package/lib/variable/variable.d.ts.map +1 -0
  841. package/lib/variable/variable.js +56 -0
  842. package/lib/variable/variable.js.map +1 -0
  843. package/lib/window/index.d.ts +25 -0
  844. package/lib/window/index.d.ts.map +1 -0
  845. package/lib/window/index.js +5 -0
  846. package/lib/window/index.js.map +1 -0
  847. package/lib/window/window.service.d.ts +14 -0
  848. package/lib/window/window.service.d.ts.map +1 -0
  849. package/lib/window/window.service.js +103 -0
  850. package/lib/window/window.service.js.map +1 -0
  851. package/package.json +55 -0
@@ -0,0 +1,720 @@
1
+ "use strict";
2
+ var KeybindingRegistryImpl_1;
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.NO_KEYBINDING_NAME = exports.KeybindingRegistryImpl = exports.KeybindingService = exports.keybindingServicePath = exports.KeybindingRegistry = exports.KeybindingContribution = exports.KeybindingsResultCollection = exports.Keybinding = exports.KeybindingWeight = exports.KeybindingScope = void 0;
5
+ const tslib_1 = require("tslib");
6
+ const di_1 = require("@opensumi/di");
7
+ const ide_core_common_1 = require("@opensumi/ide-core-common");
8
+ const keys_1 = require("../keyboard/keys");
9
+ const keyboard_layout_service_1 = require("../keyboard/keyboard-layout-service");
10
+ const context_key_1 = require("../context-key");
11
+ const services_1 = require("../services");
12
+ var KeybindingScope;
13
+ (function (KeybindingScope) {
14
+ KeybindingScope[KeybindingScope["DEFAULT"] = 0] = "DEFAULT";
15
+ KeybindingScope[KeybindingScope["USER"] = 1] = "USER";
16
+ KeybindingScope[KeybindingScope["WORKSPACE"] = 2] = "WORKSPACE";
17
+ KeybindingScope[KeybindingScope["END"] = 3] = "END";
18
+ })(KeybindingScope = exports.KeybindingScope || (exports.KeybindingScope = {}));
19
+ // ref: https://github.com/Microsoft/vscode/blob/97fc588e65bedcb1113baeddd2f67237e52c8c63/src/vs/platform/keybinding/common/keybindingsRegistry.ts#L56
20
+ // 快捷键第一优先级,在开天中将对该值 * 100 作为快捷键的优先级参数 priority
21
+ var KeybindingWeight;
22
+ (function (KeybindingWeight) {
23
+ KeybindingWeight[KeybindingWeight["Default"] = 0] = "Default";
24
+ KeybindingWeight[KeybindingWeight["EditorCore"] = 1] = "EditorCore";
25
+ KeybindingWeight[KeybindingWeight["EditorContrib"] = 100] = "EditorContrib";
26
+ KeybindingWeight[KeybindingWeight["WorkbenchContrib"] = 200] = "WorkbenchContrib";
27
+ KeybindingWeight[KeybindingWeight["BuiltinExtension"] = 300] = "BuiltinExtension";
28
+ KeybindingWeight[KeybindingWeight["ExternalExtension"] = 400] = "ExternalExtension";
29
+ })(KeybindingWeight = exports.KeybindingWeight || (exports.KeybindingWeight = {}));
30
+ (function (KeybindingScope) {
31
+ KeybindingScope.length = KeybindingScope.END - KeybindingScope.DEFAULT;
32
+ })(KeybindingScope = exports.KeybindingScope || (exports.KeybindingScope = {}));
33
+ var Keybinding;
34
+ (function (Keybinding) {
35
+ /**
36
+ * 返回带有绑定的字符串表达式
37
+ * 仅序列化关键的快捷键及command
38
+ * 在快捷时被使用
39
+ *
40
+ * @param binding 按键绑定的字符串表达式.
41
+ */
42
+ function stringify(binding) {
43
+ const copy = {
44
+ command: binding.command,
45
+ keybinding: binding.keybinding,
46
+ };
47
+ return JSON.stringify(copy);
48
+ }
49
+ Keybinding.stringify = stringify;
50
+ // 判断一个对象是否为Keybinding对象
51
+ function is(arg) {
52
+ return !!arg && arg === Object(arg) && 'command' in arg && 'keybinding' in arg;
53
+ }
54
+ Keybinding.is = is;
55
+ })(Keybinding = exports.Keybinding || (exports.Keybinding = {}));
56
+ var KeybindingsResultCollection;
57
+ (function (KeybindingsResultCollection) {
58
+ class KeybindingsResult {
59
+ constructor() {
60
+ this.full = [];
61
+ this.partial = [];
62
+ this.shadow = [];
63
+ }
64
+ /**
65
+ * 合并KeybindingsResult至this
66
+ *
67
+ * @param other
68
+ * @return this
69
+ */
70
+ merge(other) {
71
+ this.full.push(...other.full);
72
+ this.partial.push(...other.partial);
73
+ this.shadow.push(...other.shadow);
74
+ return this;
75
+ }
76
+ /**
77
+ * 返回一个新的过滤后的 KeybindingsResult
78
+ *
79
+ * @param fn 过滤函数
80
+ * @return KeybindingsResult
81
+ */
82
+ filter(fn) {
83
+ const result = new KeybindingsResult();
84
+ result.full = this.full.filter(fn);
85
+ result.partial = this.partial.filter(fn);
86
+ result.shadow = this.shadow.filter(fn);
87
+ return result;
88
+ }
89
+ }
90
+ KeybindingsResultCollection.KeybindingsResult = KeybindingsResult;
91
+ })(KeybindingsResultCollection = exports.KeybindingsResultCollection || (exports.KeybindingsResultCollection = {}));
92
+ exports.KeybindingContribution = Symbol('KeybindingContribution');
93
+ exports.KeybindingRegistry = Symbol('KeybindingRegistry');
94
+ exports.keybindingServicePath = '/services/keybindings';
95
+ exports.KeybindingService = Symbol('KeybindingService');
96
+ let KeybindingRegistryImpl = KeybindingRegistryImpl_1 = class KeybindingRegistryImpl {
97
+ constructor() {
98
+ this.keymaps = [...Array(KeybindingScope.length)].map(() => []);
99
+ this.keySequence = [];
100
+ this.convertKeySequence = [];
101
+ this.modifierKeySequence = [];
102
+ this.keybindingsChanged = new ide_core_common_1.Emitter();
103
+ }
104
+ async initialize() {
105
+ await this.keyboardLayoutService.initialize();
106
+ this.keyboardLayoutService.onKeyboardLayoutChanged(() => {
107
+ this.clearResolvedKeybindings();
108
+ });
109
+ // 从模块中获取的KeybindingContribution
110
+ for (const contribution of this.keybindingContributionProvider.getContributions()) {
111
+ contribution.registerKeybindings(this);
112
+ }
113
+ }
114
+ /**
115
+ * 由于不同的键盘布局发生更改时触发的事件。
116
+ */
117
+ get onKeybindingsChanged() {
118
+ return this.keybindingsChanged.event;
119
+ }
120
+ /**
121
+ * 注册默认 Keybinding, 支持指定作用域
122
+ * @param binding
123
+ */
124
+ registerKeybinding(binding, scope = KeybindingScope.DEFAULT) {
125
+ return this.doRegisterKeybinding(binding, scope);
126
+ }
127
+ /**
128
+ * 注册默认 Keybindings, 支持指定作用域
129
+ * @param bindings
130
+ */
131
+ registerKeybindings(bindings, scope = KeybindingScope.DEFAULT) {
132
+ return this.doRegisterKeybindings(bindings, scope);
133
+ }
134
+ /**
135
+ * 用于转换monaco内置的RawContextKey
136
+ * @param when
137
+ */
138
+ convertMonacoWhen(when) {
139
+ if (!when) {
140
+ return '';
141
+ }
142
+ if (typeof when === 'string') {
143
+ return when;
144
+ }
145
+ return when.serialize();
146
+ }
147
+ unregisterKeybinding(keyOrBinding, scope = KeybindingScope.DEFAULT) {
148
+ const key = Keybinding.is(keyOrBinding) ? keyOrBinding.keybinding : keyOrBinding;
149
+ const keymap = this.keymaps[scope];
150
+ let bindings;
151
+ // 当传入的keybinding存在when条件时,严格匹配
152
+ if (Keybinding.is(keyOrBinding) && !!keyOrBinding.when) {
153
+ bindings = keymap.filter((el) => this.isKeybindingEqual(el.keybinding, keyOrBinding.keybinding) && this.isKeybindingWhenEqual(el.when, keyOrBinding.when));
154
+ }
155
+ else {
156
+ bindings = keymap.filter((el) => this.isKeybindingEqual(el.keybinding, key));
157
+ }
158
+ bindings.forEach((binding) => {
159
+ const idx = keymap.indexOf(binding);
160
+ if (idx >= 0) {
161
+ keymap.splice(idx, 1);
162
+ }
163
+ });
164
+ }
165
+ // 判断两个when是否相等
166
+ isKeybindingWhenEqual(when1, when2) {
167
+ return this.convertMonacoWhen(when1) === this.convertMonacoWhen(when2);
168
+ }
169
+ // 判断两个快捷键是否相等
170
+ // 如 ⌘ 默认等价于 cmd, ctrlcmd
171
+ isKeybindingEqual(preKeybinding, nextKeybinding) {
172
+ return this.acceleratorForSequenceKeyString(preKeybinding) === this.acceleratorForSequenceKeyString(nextKeybinding);
173
+ }
174
+ // 解析快捷键字符串为统一的结果
175
+ acceleratorForSequenceKeyString(key) {
176
+ const keyCodeStrings = key.split(' ');
177
+ const keySequence = keyCodeStrings.map((key) => keys_1.KeyCode.parse(key));
178
+ return this.acceleratorForSequence(keySequence, '+').join(' ');
179
+ }
180
+ /**
181
+ * 执行注册多个Keybinding
182
+ * @param bindings
183
+ * @param scope
184
+ */
185
+ doRegisterKeybindings(bindings, scope = KeybindingScope.DEFAULT) {
186
+ const toDispose = new ide_core_common_1.Disposable();
187
+ for (const binding of bindings) {
188
+ toDispose.addDispose(this.doRegisterKeybinding(binding, scope));
189
+ }
190
+ return toDispose;
191
+ }
192
+ /**
193
+ * 执行注册单个Keybinding
194
+ * @param binding
195
+ * @param scope
196
+ */
197
+ doRegisterKeybinding(binding, scope = KeybindingScope.DEFAULT) {
198
+ try {
199
+ this.resolveKeybinding(binding, true);
200
+ this.keymaps[scope].unshift(binding);
201
+ }
202
+ catch (error) {
203
+ this.logger.warn(`Could not register keybinding:\n ${Keybinding.stringify(binding)}\n${error}`);
204
+ }
205
+ this.keybindingsChanged.fire({ affectsCommands: [binding.command] });
206
+ return {
207
+ dispose: () => {
208
+ this.unregisterKeybinding(binding, scope);
209
+ },
210
+ };
211
+ }
212
+ /**
213
+ * 通过调用KeyboardLayoutService来设置给定的ResolvedKeybinding中的`resolved`属性。
214
+ * @param binding
215
+ */
216
+ resolveKeybinding(binding, disableCache) {
217
+ if (!binding.resolved || disableCache) {
218
+ const sequence = keys_1.KeySequence.parse(binding.keybinding);
219
+ binding.resolved = sequence.map((code) => this.keyboardLayoutService.resolveKeyCode(code));
220
+ }
221
+ return binding.resolved;
222
+ }
223
+ /**
224
+ * 清除已注册的Keybinding中所有`resolved`属性,以便调用KeyboardLayoutService再次为他们赋值
225
+ * 当用户的键盘布局发生变化时,执行该方法
226
+ */
227
+ clearResolvedKeybindings() {
228
+ for (let i = KeybindingScope.DEFAULT; i < KeybindingScope.END; i++) {
229
+ const bindings = this.keymaps[i];
230
+ for (const binding of bindings) {
231
+ const bd = binding;
232
+ bd.resolved = undefined;
233
+ }
234
+ }
235
+ }
236
+ /**
237
+ * 检查Keybindings列表中的keySequence冲突
238
+ * @param bindings
239
+ * @param binding
240
+ */
241
+ containsKeybinding(bindings, binding) {
242
+ const bindingKeySequence = this.resolveKeybinding(binding);
243
+ const collisions = this.getKeySequenceCollisions(bindings, bindingKeySequence)
244
+ .filter((b) => b.when === binding.when);
245
+ if (collisions.full.length > 0) {
246
+ this.logger.warn('Collided keybinding is ignored; ', Keybinding.stringify(binding), ' collided with ', collisions.full.map((b) => Keybinding.stringify(b)).join(', '));
247
+ return true;
248
+ }
249
+ if (collisions.partial.length > 0) {
250
+ this.logger.warn('Shadowing keybinding is ignored; ', Keybinding.stringify(binding), ' shadows ', collisions.partial.map((b) => Keybinding.stringify(b)).join(', '));
251
+ return true;
252
+ }
253
+ if (collisions.shadow.length > 0) {
254
+ this.logger.warn('Shadowed keybinding is ignored; ', Keybinding.stringify(binding), ' would be shadowed by ', collisions.shadow.map((b) => Keybinding.stringify(b)).join(', '));
255
+ return true;
256
+ }
257
+ return false;
258
+ }
259
+ /**
260
+ * 检查Keybindings列表中的keySequence冲突
261
+ * 直接返回错误信息,无错误则返回空字符串
262
+ * @param bindings
263
+ * @param binding
264
+ */
265
+ validateKeybinding(bindings, binding) {
266
+ const bindingKeySequence = this.resolveKeybinding(binding);
267
+ const collisions = this.getKeySequenceCollisions(bindings, bindingKeySequence)
268
+ .filter((b) => b.when === binding.when);
269
+ if (collisions.full.length > 0) {
270
+ const collision = collisions.full[0];
271
+ const command = this.commandRegistry.getCommand(collision.command);
272
+ return (0, ide_core_common_1.formatLocalize)('keymaps.keybinding.full.collide', `${command ? (command === null || command === void 0 ? void 0 : command.label) || command.id : collision.command}${collision.when ? `{${collision.when}}` : collision.when}`);
273
+ }
274
+ if (collisions.partial.length > 0) {
275
+ const collision = collisions.partial[0];
276
+ const command = this.commandRegistry.getCommand(collision.command);
277
+ return (0, ide_core_common_1.formatLocalize)('keymaps.keybinding.partial.collide', `${command ? (command === null || command === void 0 ? void 0 : command.label) || command.id : collision.command}${collision.when ? `{${collision.when}}` : collision.when}`);
278
+ }
279
+ if (collisions.shadow.length > 0) {
280
+ const collision = collisions.shadow[0];
281
+ const command = this.commandRegistry.getCommand(collision.command);
282
+ return (0, ide_core_common_1.formatLocalize)('keymaps.keybinding.shadow.collide', `${command ? (command === null || command === void 0 ? void 0 : command.label) || command.id : collision.command}${collision.when ? `{${collision.when}}` : collision.when}`);
283
+ }
284
+ return '';
285
+ }
286
+ /**
287
+ * 检查在特定Scope下是否包含该Keybinding
288
+ *
289
+ * @param binding
290
+ * @param scope
291
+ */
292
+ containsKeybindingInScope(binding, scope = KeybindingScope.USER) {
293
+ return this.containsKeybinding(this.keymaps[scope], binding);
294
+ }
295
+ /**
296
+ * 检查在特定Scope下是否包含该Keybinding
297
+ * 返回冲突信息
298
+ * 无冲突返回空字符串
299
+ * @param binding
300
+ * @param scope
301
+ */
302
+ validateKeybindingInScope(binding, scope = KeybindingScope.USER) {
303
+ return this.validateKeybinding(this.keymaps[scope], binding);
304
+ }
305
+ /**
306
+ * 返回用户可见的Keybinding数据
307
+ * @param keybinding
308
+ * @param separator
309
+ */
310
+ acceleratorFor(keybinding, separator = ' ') {
311
+ const bindingKeySequence = this.resolveKeybinding(keybinding);
312
+ return this.acceleratorForSequence(bindingKeySequence, separator);
313
+ }
314
+ /**
315
+ * 从KeySequence中返回用户可见的Keybinding
316
+ * @param keySequence
317
+ * @param separator
318
+ */
319
+ acceleratorForSequence(keySequence, separator = ' ') {
320
+ return keySequence.map((keyCode) => this.acceleratorForKeyCode(keyCode, separator));
321
+ }
322
+ acceleratorForKeyString(keyString, separator = ' ') {
323
+ const keyCode = keys_1.KeyCode.parse(keyString);
324
+ return this.acceleratorForKeyCode(keyCode, separator);
325
+ }
326
+ /**
327
+ * 将字符串转化为首字母大写
328
+ * @param str 字符串
329
+ */
330
+ capitalizeFirstLetter(str) {
331
+ return str.replace(/^\S/, function (s) { return s.toUpperCase(); });
332
+ }
333
+ /**
334
+ * 返回用户可读的组合按键指令文本 (带修饰符)
335
+ * @param keyCode
336
+ * @param separator
337
+ */
338
+ acceleratorForKeyCode(keyCode, separator = ' ') {
339
+ const keyCodeResult = [];
340
+ if (keyCode.ctrl) {
341
+ keyCodeResult.push(this.capitalizeFirstLetter(keys_1.SpecialCases.CTRL));
342
+ }
343
+ if (keyCode.alt) {
344
+ keyCodeResult.push(this.capitalizeFirstLetter(keys_1.SpecialCases.ALT));
345
+ }
346
+ if (keyCode.shift) {
347
+ keyCodeResult.push(this.capitalizeFirstLetter(keys_1.SpecialCases.SHIFT));
348
+ }
349
+ if (keyCode.meta) {
350
+ if (ide_core_common_1.isOSX) {
351
+ keyCodeResult.push(keys_1.SpecialCases.MACMETA);
352
+ }
353
+ else {
354
+ keyCodeResult.push(this.capitalizeFirstLetter(keys_1.SpecialCases.META));
355
+ }
356
+ }
357
+ if (keyCode.key) {
358
+ keyCodeResult.push(this.acceleratorForKey(keyCode.key));
359
+ }
360
+ return keyCodeResult.join(separator);
361
+ }
362
+ /**
363
+ * 根据Key返回可读文本
364
+ * @param key
365
+ */
366
+ acceleratorForKey(key) {
367
+ if (ide_core_common_1.isOSX) {
368
+ if (key === keys_1.Key.ARROW_LEFT) {
369
+ return keys_1.SpecialCases.ARROW_LEFT;
370
+ }
371
+ if (key === keys_1.Key.ARROW_RIGHT) {
372
+ return keys_1.SpecialCases.ARROW_RIGHT;
373
+ }
374
+ if (key === keys_1.Key.ARROW_UP) {
375
+ return keys_1.SpecialCases.ARROW_UP;
376
+ }
377
+ if (key === keys_1.Key.ARROW_DOWN) {
378
+ return keys_1.SpecialCases.ARROW_DOWN;
379
+ }
380
+ if (key === keys_1.Key.BACKSPACE) {
381
+ return keys_1.SpecialCases.BACKSPACE;
382
+ }
383
+ if (key === keys_1.Key.ENTER) {
384
+ return keys_1.SpecialCases.ENTER;
385
+ }
386
+ }
387
+ const keyString = this.keyboardLayoutService.getKeyboardCharacter(key);
388
+ if (key.keyCode >= keys_1.Key.KEY_A.keyCode && key.keyCode <= keys_1.Key.KEY_Z.keyCode ||
389
+ key.keyCode >= keys_1.Key.F1.keyCode && key.keyCode <= keys_1.Key.F24.keyCode) {
390
+ return keyString.toUpperCase();
391
+ }
392
+ else if (keyString.length > 1) {
393
+ return keyString.charAt(0).toUpperCase() + keyString.slice(1);
394
+ }
395
+ else if (keyString === ' ') {
396
+ // 空格需要额外使用特殊字符进行展示,否则直接输出 `' '` 会比较疑惑
397
+ return keys_1.SpecialCases.SPACE.charAt(0).toUpperCase() + keys_1.SpecialCases.SPACE.slice(1);
398
+ }
399
+ else {
400
+ return keyString;
401
+ }
402
+ }
403
+ /**
404
+ * 查找绑定列表中的键序列的冲突(无错误,是否冲突都会返回结果)
405
+ * @param bindings
406
+ * @param candidate
407
+ */
408
+ getKeySequenceCollisions(bindings, candidate) {
409
+ const result = new KeybindingsResultCollection.KeybindingsResult();
410
+ for (const binding of bindings) {
411
+ try {
412
+ const bindingKeySequence = this.resolveKeybinding(binding);
413
+ const compareResult = keys_1.KeySequence.compare(candidate, bindingKeySequence);
414
+ switch (compareResult) {
415
+ case keys_1.KeySequence.CompareResult.FULL: {
416
+ result.full.push(binding);
417
+ break;
418
+ }
419
+ case keys_1.KeySequence.CompareResult.PARTIAL: {
420
+ result.partial.push(binding);
421
+ break;
422
+ }
423
+ case keys_1.KeySequence.CompareResult.SHADOW: {
424
+ result.shadow.push(binding);
425
+ break;
426
+ }
427
+ }
428
+ }
429
+ catch (error) {
430
+ this.logger.warn(error);
431
+ }
432
+ }
433
+ return result;
434
+ }
435
+ /**
436
+ * 获取与KeySequence完全匹配或部分匹配的键绑定列表
437
+ * 列表按优先级排序 (见sortKeybindingsByPriority方法)
438
+ * @param keySequence
439
+ */
440
+ getKeybindingsForKeySequence(keySequence, event) {
441
+ const result = new KeybindingsResultCollection.KeybindingsResult();
442
+ for (let scope = KeybindingScope.END; --scope >= KeybindingScope.DEFAULT;) {
443
+ const matches = this.getKeySequenceCollisions(this.keymaps[scope], keySequence);
444
+ matches.full = matches.full
445
+ .sort(this.sortKeybindingsByPriority);
446
+ matches.partial = matches.partial
447
+ .sort(this.sortKeybindingsByPriority);
448
+ result.merge(matches);
449
+ }
450
+ // 如果组合键不可用,去掉组合键的功能
451
+ const partial = result.partial.filter((binding) => this.isEnabled(binding, event));
452
+ result.partial = partial;
453
+ return result;
454
+ }
455
+ /**
456
+ * 获取与commandId相关联的键绑定
457
+ * @param commandId
458
+ */
459
+ getKeybindingsForCommand(commandId) {
460
+ const result = [];
461
+ for (let scope = KeybindingScope.END - 1; scope >= KeybindingScope.DEFAULT; scope--) {
462
+ this.keymaps[scope].forEach((binding) => {
463
+ const command = this.commandRegistry.getCommand(binding.command);
464
+ if (command) {
465
+ if (command.id === commandId) {
466
+ result.push(Object.assign(Object.assign({}, binding), { scope }));
467
+ }
468
+ }
469
+ });
470
+ if (result.length > 0) {
471
+ return result;
472
+ }
473
+ }
474
+ return result;
475
+ }
476
+ /**
477
+ * 返回在特定Scope下与commandId关联的键值对列表
478
+ * @param scope
479
+ * @param commandId
480
+ */
481
+ getScopedKeybindingsForCommand(scope, commandId) {
482
+ const result = [];
483
+ if (scope >= KeybindingScope.END) {
484
+ return [];
485
+ }
486
+ this.keymaps[scope].forEach((binding) => {
487
+ const command = this.commandRegistry.getCommand(binding.command);
488
+ if (command && command.id === commandId) {
489
+ result.push(binding);
490
+ }
491
+ });
492
+ return result;
493
+ }
494
+ /**
495
+ * 按优先级顺序对键值绑定进行排序
496
+ *
497
+ * 具有When判定的键绑定比没有的优先级更高
498
+ * 当均具备 when 时,采用 priority 进行优先级判断
499
+ * @param keybindings
500
+ */
501
+ sortKeybindingsByPriority(a, b) {
502
+ if (a.when && !b.when) {
503
+ return -1;
504
+ }
505
+ if (!a.when && b.when) {
506
+ return 1;
507
+ }
508
+ const compA = (0, ide_core_common_1.isUndefined)(a.priority) ? KeybindingWeight.Default : a.priority;
509
+ const compB = (0, ide_core_common_1.isUndefined)(b.priority) ? KeybindingWeight.Default : b.priority;
510
+ return compB - compA;
511
+ }
512
+ isActive(binding) {
513
+ // passthrough命令始终处于活动状态 (无法在命令注册表中找到))
514
+ if (this.isPseudoCommand(binding.command)) {
515
+ return true;
516
+ }
517
+ const command = this.commandRegistry.getCommand(binding.command);
518
+ return !!command && !!this.commandRegistry.getActiveHandler(command.id);
519
+ }
520
+ /**
521
+ * 只有在没有上下文(全局上下文)或者我们处于该上下文中时才执行
522
+ * @param binding
523
+ * @param event
524
+ */
525
+ isEnabled(binding, event) {
526
+ if (binding.when && !this.whenContextService.match(binding.when, event && event.target)) {
527
+ return false;
528
+ }
529
+ return true;
530
+ }
531
+ /**
532
+ * 判断是否为PASSTHROUGH_PSEUDO_COMMAND
533
+ * @param commandId
534
+ */
535
+ isPseudoCommand(commandId) {
536
+ return commandId === KeybindingRegistryImpl_1.PASSTHROUGH_PSEUDO_COMMAND;
537
+ }
538
+ /**
539
+ * 重置所有Scope下的键绑定(仅保留映射的默认键绑定)
540
+ */
541
+ resetKeybindings() {
542
+ for (let i = KeybindingScope.DEFAULT + 1; i < KeybindingScope.END; i++) {
543
+ this.keymaps[i] = [];
544
+ }
545
+ }
546
+ /**
547
+ * 用于处理诸如 Shift + Shift, Ctrl + Ctrl, Alt + Alt 等快捷键
548
+ * 参考: https://github.com/microsoft/vscode/pull/115190
549
+ *
550
+ * @param event 键盘事件
551
+ */
552
+ resolveModifierKey(event) {
553
+ if (event.defaultPrevented) {
554
+ return;
555
+ }
556
+ if (this.modifierKeySequenceTimer) {
557
+ clearTimeout(this.modifierKeySequenceTimer);
558
+ }
559
+ const keyCode = keys_1.KeyCode.createKeyCode(event);
560
+ // 当传入的 KeyCode 不是修饰符时,不处理
561
+ if (!keyCode.isModifierOnly()) {
562
+ return;
563
+ }
564
+ this.modifierKeySequence.push(keyCode);
565
+ const bindings = this.getKeybindingsForKeySequence(this.modifierKeySequence, event);
566
+ if (this.tryKeybindingExecution(bindings.full, event)) {
567
+ this.modifierKeySequence = [];
568
+ }
569
+ else if (bindings.partial.length > 0) {
570
+ // 堆积 modifierKeySequence, 用于实现组合键
571
+ event.preventDefault();
572
+ event.stopPropagation();
573
+ this.modifierKeySequenceTimer = setTimeout(() => {
574
+ this.modifierKeySequence = [];
575
+ }, KeybindingRegistryImpl_1.MODIFIER_KEYSEQUENCE_TIMEOUT);
576
+ }
577
+ else {
578
+ this.modifierKeySequence = [];
579
+ }
580
+ }
581
+ /**
582
+ * 执行匹配键盘事件的命令
583
+ *
584
+ * @param event 键盘事件
585
+ */
586
+ run(event) {
587
+ if (event.defaultPrevented) {
588
+ return;
589
+ }
590
+ if (this.keySequenceTimer) {
591
+ clearTimeout(this.keySequenceTimer);
592
+ }
593
+ const keyCode = keys_1.KeyCode.createKeyCode(event);
594
+ // 当传入的 KeyCode 仅为修饰符,忽略,等待下次输入
595
+ if (keyCode.isModifierOnly()) {
596
+ return;
597
+ }
598
+ this.keyboardLayoutService.validateKeyCode(keyCode);
599
+ this.keySequence.push(keyCode);
600
+ const bindings = this.getKeybindingsForKeySequence(this.keySequence, event);
601
+ if (this.tryKeybindingExecution(bindings.full, event)) {
602
+ this.keySequence = [];
603
+ this.statusBar.removeElement('keybinding-status');
604
+ }
605
+ else if (bindings.partial.length > 0) {
606
+ // 堆积keySequence, 用于实现组合键
607
+ event.preventDefault();
608
+ event.stopPropagation();
609
+ this.statusBar.addElement('keybinding-status', {
610
+ text: (0, ide_core_common_1.formatLocalize)('keybinding.combination.tip', this.acceleratorForSequence(this.keySequence, '+')),
611
+ alignment: services_1.StatusBarAlignment.LEFT,
612
+ priority: 2,
613
+ });
614
+ this.keySequenceTimer = setTimeout(() => {
615
+ this.keySequence = [];
616
+ this.statusBar.removeElement('keybinding-status');
617
+ }, KeybindingRegistryImpl_1.KEYSEQUENCE_TIMEOUT);
618
+ }
619
+ else {
620
+ this.keySequence = [];
621
+ this.statusBar.removeElement('keybinding-status');
622
+ }
623
+ }
624
+ /**
625
+ * 返回快捷键文本
626
+ *
627
+ * @param event 键盘事件
628
+ */
629
+ convert(event, separator = ' ') {
630
+ const keyCode = keys_1.KeyCode.createKeyCode(event);
631
+ // 当传入的Keycode仅为修饰符,返回上次输出结果
632
+ if (keyCode.isModifierOnly()) {
633
+ return this.acceleratorForSequence(this.convertKeySequence, '+').join(separator);
634
+ }
635
+ this.keyboardLayoutService.validateKeyCode(keyCode);
636
+ if (this.convertKeySequence.length <= 1) {
637
+ this.convertKeySequence.push(keyCode);
638
+ }
639
+ else {
640
+ this.convertKeySequence = [keyCode];
641
+ }
642
+ return this.acceleratorForSequence(this.convertKeySequence, '+').join(separator);
643
+ }
644
+ /**
645
+ * 清空键盘事件队列
646
+ */
647
+ clearConvert() {
648
+ this.convertKeySequence = [];
649
+ }
650
+ /**
651
+ * 尝试执行Keybinding
652
+ * @param bindings
653
+ * @param event
654
+ * @return 命令执行成功时返回true,否则为false
655
+ */
656
+ tryKeybindingExecution(bindings, event) {
657
+ if (bindings.length === 0) {
658
+ return false;
659
+ }
660
+ for (const binding of bindings) {
661
+ if (this.isEnabled(binding, event)) {
662
+ if (this.isPseudoCommand(binding.command)) {
663
+ // 让事件冒泡
664
+ return true;
665
+ }
666
+ else {
667
+ const command = this.commandRegistry.getCommand(binding.command);
668
+ if (command) {
669
+ this.commandService.executeCommand(command.id, binding.args)
670
+ .catch((err) => this.logger.error('Failed to execute command:', err, binding.command));
671
+ /* 如果键绑定在上下文中但命令是可用状态下我们仍然在这里停止处理 */
672
+ event.preventDefault();
673
+ event.stopPropagation();
674
+ return true;
675
+ }
676
+ }
677
+ return false;
678
+ }
679
+ }
680
+ return false;
681
+ }
682
+ };
683
+ // 该伪命令用于让事件冒泡,使事件不被Keybinding消费掉
684
+ KeybindingRegistryImpl.PASSTHROUGH_PSEUDO_COMMAND = 'passthrough';
685
+ KeybindingRegistryImpl.KEYSEQUENCE_TIMEOUT = 5000;
686
+ KeybindingRegistryImpl.MODIFIER_KEYSEQUENCE_TIMEOUT = 300;
687
+ (0, tslib_1.__decorate)([
688
+ (0, di_1.Autowired)(keyboard_layout_service_1.KeyboardLayoutService),
689
+ (0, tslib_1.__metadata)("design:type", keyboard_layout_service_1.KeyboardLayoutService)
690
+ ], KeybindingRegistryImpl.prototype, "keyboardLayoutService", void 0);
691
+ (0, tslib_1.__decorate)([
692
+ (0, di_1.Autowired)(exports.KeybindingContribution),
693
+ (0, tslib_1.__metadata)("design:type", Object)
694
+ ], KeybindingRegistryImpl.prototype, "keybindingContributionProvider", void 0);
695
+ (0, tslib_1.__decorate)([
696
+ (0, di_1.Autowired)(ide_core_common_1.CommandRegistry),
697
+ (0, tslib_1.__metadata)("design:type", Object)
698
+ ], KeybindingRegistryImpl.prototype, "commandRegistry", void 0);
699
+ (0, tslib_1.__decorate)([
700
+ (0, di_1.Autowired)(ide_core_common_1.CommandService),
701
+ (0, tslib_1.__metadata)("design:type", Object)
702
+ ], KeybindingRegistryImpl.prototype, "commandService", void 0);
703
+ (0, tslib_1.__decorate)([
704
+ (0, di_1.Autowired)(ide_core_common_1.ILogger),
705
+ (0, tslib_1.__metadata)("design:type", Object)
706
+ ], KeybindingRegistryImpl.prototype, "logger", void 0);
707
+ (0, tslib_1.__decorate)([
708
+ (0, di_1.Autowired)(context_key_1.IContextKeyService),
709
+ (0, tslib_1.__metadata)("design:type", Object)
710
+ ], KeybindingRegistryImpl.prototype, "whenContextService", void 0);
711
+ (0, tslib_1.__decorate)([
712
+ (0, di_1.Autowired)(services_1.IStatusBarService),
713
+ (0, tslib_1.__metadata)("design:type", Object)
714
+ ], KeybindingRegistryImpl.prototype, "statusBar", void 0);
715
+ KeybindingRegistryImpl = KeybindingRegistryImpl_1 = (0, tslib_1.__decorate)([
716
+ (0, di_1.Injectable)()
717
+ ], KeybindingRegistryImpl);
718
+ exports.KeybindingRegistryImpl = KeybindingRegistryImpl;
719
+ exports.NO_KEYBINDING_NAME = 'no_keybinding';
720
+ //# sourceMappingURL=keybinding.js.map