@theia/monaco 1.77.0-next.0 → 1.77.0-next.101
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.
- package/lib/browser/content-hover-widget-patcher.js +6 -9
- package/lib/browser/content-hover-widget-patcher.js.map +1 -1
- package/lib/browser/default-content-hover-widget-patcher.d.ts +1 -1
- package/lib/browser/default-content-hover-widget-patcher.d.ts.map +1 -1
- package/lib/browser/default-content-hover-widget-patcher.js +7 -10
- package/lib/browser/default-content-hover-widget-patcher.js.map +1 -1
- package/lib/browser/index.d.ts +2 -2
- package/lib/browser/index.d.ts.map +1 -1
- package/lib/browser/index.js +2 -5
- package/lib/browser/index.js.map +1 -1
- package/lib/browser/markdown-renderer/monaco-markdown-renderer.d.ts +4 -4
- package/lib/browser/markdown-renderer/monaco-markdown-renderer.d.ts.map +1 -1
- package/lib/browser/markdown-renderer/monaco-markdown-renderer.js +29 -37
- package/lib/browser/markdown-renderer/monaco-markdown-renderer.js.map +1 -1
- package/lib/browser/monaco-bulk-edit-service.d.ts +4 -4
- package/lib/browser/monaco-bulk-edit-service.d.ts.map +1 -1
- package/lib/browser/monaco-bulk-edit-service.js +10 -14
- package/lib/browser/monaco-bulk-edit-service.js.map +1 -1
- package/lib/browser/monaco-code-action-save-participant.d.ts +3 -3
- package/lib/browser/monaco-code-action-save-participant.d.ts.map +1 -1
- package/lib/browser/monaco-code-action-save-participant.js +12 -16
- package/lib/browser/monaco-code-action-save-participant.js.map +1 -1
- package/lib/browser/monaco-code-action-service.d.ts +2 -2
- package/lib/browser/monaco-code-action-service.d.ts.map +1 -1
- package/lib/browser/monaco-code-action-service.js +25 -29
- package/lib/browser/monaco-code-action-service.js.map +1 -1
- package/lib/browser/monaco-color-registry.d.ts +4 -4
- package/lib/browser/monaco-color-registry.d.ts.map +1 -1
- package/lib/browser/monaco-color-registry.js +23 -26
- package/lib/browser/monaco-color-registry.js.map +1 -1
- package/lib/browser/monaco-command-registry.d.ts +2 -2
- package/lib/browser/monaco-command-registry.d.ts.map +1 -1
- package/lib/browser/monaco-command-registry.js +15 -21
- package/lib/browser/monaco-command-registry.js.map +1 -1
- package/lib/browser/monaco-command-service.d.ts +2 -2
- package/lib/browser/monaco-command-service.d.ts.map +1 -1
- package/lib/browser/monaco-command-service.js +17 -24
- package/lib/browser/monaco-command-service.js.map +1 -1
- package/lib/browser/monaco-command.d.ts +3 -3
- package/lib/browser/monaco-command.d.ts.map +1 -1
- package/lib/browser/monaco-command.js +62 -71
- package/lib/browser/monaco-command.js.map +1 -1
- package/lib/browser/monaco-context-key-service.d.ts +3 -3
- package/lib/browser/monaco-context-key-service.d.ts.map +1 -1
- package/lib/browser/monaco-context-key-service.js +17 -23
- package/lib/browser/monaco-context-key-service.js.map +1 -1
- package/lib/browser/monaco-context-menu.d.ts +5 -5
- package/lib/browser/monaco-context-menu.d.ts.map +1 -1
- package/lib/browser/monaco-context-menu.js +26 -30
- package/lib/browser/monaco-context-menu.js.map +1 -1
- package/lib/browser/monaco-diff-computer.js +10 -13
- package/lib/browser/monaco-diff-computer.js.map +1 -1
- package/lib/browser/monaco-diff-editor.d.ts +7 -7
- package/lib/browser/monaco-diff-editor.d.ts.map +1 -1
- package/lib/browser/monaco-diff-editor.js +15 -19
- package/lib/browser/monaco-diff-editor.js.map +1 -1
- package/lib/browser/monaco-diff-navigator-factory.d.ts +1 -1
- package/lib/browser/monaco-diff-navigator-factory.d.ts.map +1 -1
- package/lib/browser/monaco-diff-navigator-factory.js +5 -8
- package/lib/browser/monaco-diff-navigator-factory.js.map +1 -1
- package/lib/browser/monaco-editor-content-menu.d.ts +2 -2
- package/lib/browser/monaco-editor-content-menu.d.ts.map +1 -1
- package/lib/browser/monaco-editor-content-menu.js +36 -43
- package/lib/browser/monaco-editor-content-menu.js.map +1 -1
- package/lib/browser/monaco-editor-model.d.ts +4 -4
- package/lib/browser/monaco-editor-model.d.ts.map +1 -1
- package/lib/browser/monaco-editor-model.js +46 -50
- package/lib/browser/monaco-editor-model.js.map +1 -1
- package/lib/browser/monaco-editor-overlay-button.d.ts +1 -1
- package/lib/browser/monaco-editor-overlay-button.d.ts.map +1 -1
- package/lib/browser/monaco-editor-overlay-button.js +11 -15
- package/lib/browser/monaco-editor-overlay-button.js.map +1 -1
- package/lib/browser/monaco-editor-peek-view-widget.d.ts +2 -2
- package/lib/browser/monaco-editor-peek-view-widget.d.ts.map +1 -1
- package/lib/browser/monaco-editor-peek-view-widget.js +17 -25
- package/lib/browser/monaco-editor-peek-view-widget.js.map +1 -1
- package/lib/browser/monaco-editor-provider.d.ts +10 -10
- package/lib/browser/monaco-editor-provider.d.ts.map +1 -1
- package/lib/browser/monaco-editor-provider.js +92 -108
- package/lib/browser/monaco-editor-provider.js.map +1 -1
- package/lib/browser/monaco-editor-service.d.ts +6 -6
- package/lib/browser/monaco-editor-service.d.ts.map +1 -1
- package/lib/browser/monaco-editor-service.js +47 -59
- package/lib/browser/monaco-editor-service.js.map +1 -1
- package/lib/browser/monaco-editor-zone-widget.js +10 -14
- package/lib/browser/monaco-editor-zone-widget.js.map +1 -1
- package/lib/browser/monaco-editor.d.ts +10 -7
- package/lib/browser/monaco-editor.d.ts.map +1 -1
- package/lib/browser/monaco-editor.js +102 -94
- package/lib/browser/monaco-editor.js.map +1 -1
- package/lib/browser/monaco-editor.spec.d.ts +2 -0
- package/lib/browser/monaco-editor.spec.d.ts.map +1 -0
- package/lib/browser/monaco-editor.spec.js +202 -0
- package/lib/browser/monaco-editor.spec.js.map +1 -0
- package/lib/browser/monaco-formatter-service.d.ts +3 -3
- package/lib/browser/monaco-formatter-service.d.ts.map +1 -1
- package/lib/browser/monaco-formatter-service.js +28 -37
- package/lib/browser/monaco-formatter-service.js.map +1 -1
- package/lib/browser/monaco-formatting-conflicts.d.ts +2 -2
- package/lib/browser/monaco-formatting-conflicts.d.ts.map +1 -1
- package/lib/browser/monaco-formatting-conflicts.js +19 -25
- package/lib/browser/monaco-formatting-conflicts.js.map +1 -1
- package/lib/browser/monaco-frontend-application-contribution.d.ts +4 -4
- package/lib/browser/monaco-frontend-application-contribution.d.ts.map +1 -1
- package/lib/browser/monaco-frontend-application-contribution.js +43 -56
- package/lib/browser/monaco-frontend-application-contribution.js.map +1 -1
- package/lib/browser/monaco-frontend-module.js +163 -167
- package/lib/browser/monaco-frontend-module.js.map +1 -1
- package/lib/browser/monaco-gotoline-quick-access.d.ts +2 -2
- package/lib/browser/monaco-gotoline-quick-access.d.ts.map +1 -1
- package/lib/browser/monaco-gotoline-quick-access.js +16 -20
- package/lib/browser/monaco-gotoline-quick-access.js.map +1 -1
- package/lib/browser/monaco-gotosymbol-quick-access.d.ts +5 -5
- package/lib/browser/monaco-gotosymbol-quick-access.d.ts.map +1 -1
- package/lib/browser/monaco-gotosymbol-quick-access.js +18 -22
- package/lib/browser/monaco-gotosymbol-quick-access.js.map +1 -1
- package/lib/browser/monaco-icon-registry.d.ts +1 -1
- package/lib/browser/monaco-icon-registry.d.ts.map +1 -1
- package/lib/browser/monaco-icon-registry.js +7 -10
- package/lib/browser/monaco-icon-registry.js.map +1 -1
- package/lib/browser/monaco-indexed-db.d.ts +1 -1
- package/lib/browser/monaco-indexed-db.d.ts.map +1 -1
- package/lib/browser/monaco-indexed-db.js +28 -35
- package/lib/browser/monaco-indexed-db.js.map +1 -1
- package/lib/browser/monaco-init.d.ts +1 -1
- package/lib/browser/monaco-init.d.ts.map +1 -1
- package/lib/browser/monaco-init.js +75 -95
- package/lib/browser/monaco-init.js.map +1 -1
- package/lib/browser/monaco-init.spec.js +45 -20
- package/lib/browser/monaco-init.spec.js.map +1 -1
- package/lib/browser/monaco-keybinding.d.ts +3 -2
- package/lib/browser/monaco-keybinding.d.ts.map +1 -1
- package/lib/browser/monaco-keybinding.js +47 -51
- package/lib/browser/monaco-keybinding.js.map +1 -1
- package/lib/browser/monaco-keybinding.spec.d.ts +2 -0
- package/lib/browser/monaco-keybinding.spec.d.ts.map +1 -0
- package/lib/browser/monaco-keybinding.spec.js +94 -0
- package/lib/browser/monaco-keybinding.spec.js.map +1 -0
- package/lib/browser/monaco-keycode-map.d.ts +1 -1
- package/lib/browser/monaco-keycode-map.d.ts.map +1 -1
- package/lib/browser/monaco-keycode-map.js +122 -125
- package/lib/browser/monaco-keycode-map.js.map +1 -1
- package/lib/browser/monaco-languages.d.ts +2 -2
- package/lib/browser/monaco-languages.d.ts.map +1 -1
- package/lib/browser/monaco-languages.js +33 -41
- package/lib/browser/monaco-languages.js.map +1 -1
- package/lib/browser/monaco-marker-collection.d.ts +1 -1
- package/lib/browser/monaco-marker-collection.d.ts.map +1 -1
- package/lib/browser/monaco-marker-collection.js +2 -6
- package/lib/browser/monaco-marker-collection.js.map +1 -1
- package/lib/browser/monaco-menu.d.ts +2 -2
- package/lib/browser/monaco-menu.d.ts.map +1 -1
- package/lib/browser/monaco-menu.js +44 -48
- package/lib/browser/monaco-menu.js.map +1 -1
- package/lib/browser/monaco-mime-service.js +16 -20
- package/lib/browser/monaco-mime-service.js.map +1 -1
- package/lib/browser/monaco-nls.d.ts +1 -1
- package/lib/browser/monaco-nls.d.ts.map +1 -1
- package/lib/browser/monaco-nls.js +9 -16
- package/lib/browser/monaco-nls.js.map +1 -1
- package/lib/browser/monaco-outline-contribution.d.ts +5 -2
- package/lib/browser/monaco-outline-contribution.d.ts.map +1 -1
- package/lib/browser/monaco-outline-contribution.js +35 -36
- package/lib/browser/monaco-outline-contribution.js.map +1 -1
- package/lib/browser/monaco-outline-decorator.d.ts +1 -1
- package/lib/browser/monaco-outline-decorator.d.ts.map +1 -1
- package/lib/browser/monaco-outline-decorator.js +18 -18
- package/lib/browser/monaco-outline-decorator.js.map +1 -1
- package/lib/browser/monaco-outline-decorator.spec.d.ts +2 -0
- package/lib/browser/monaco-outline-decorator.spec.d.ts.map +1 -0
- package/lib/browser/monaco-outline-decorator.spec.js +76 -0
- package/lib/browser/monaco-outline-decorator.spec.js.map +1 -0
- package/lib/browser/monaco-quick-access-registry.js +17 -21
- package/lib/browser/monaco-quick-access-registry.js.map +1 -1
- package/lib/browser/monaco-quick-input-service.d.ts +40 -8
- package/lib/browser/monaco-quick-input-service.d.ts.map +1 -1
- package/lib/browser/monaco-quick-input-service.js +169 -74
- package/lib/browser/monaco-quick-input-service.js.map +1 -1
- package/lib/browser/monaco-quick-input-service.spec.js +9 -11
- package/lib/browser/monaco-quick-input-service.spec.js.map +1 -1
- package/lib/browser/monaco-resolved-keybinding.d.ts +1 -1
- package/lib/browser/monaco-resolved-keybinding.d.ts.map +1 -1
- package/lib/browser/monaco-resolved-keybinding.js +35 -36
- package/lib/browser/monaco-resolved-keybinding.js.map +1 -1
- package/lib/browser/monaco-snippet-suggest-provider.js +31 -37
- package/lib/browser/monaco-snippet-suggest-provider.js.map +1 -1
- package/lib/browser/monaco-standalone-theme-service.d.ts +2 -2
- package/lib/browser/monaco-standalone-theme-service.d.ts.map +1 -1
- package/lib/browser/monaco-standalone-theme-service.js +2 -6
- package/lib/browser/monaco-standalone-theme-service.js.map +1 -1
- package/lib/browser/monaco-status-bar-contribution.js +26 -29
- package/lib/browser/monaco-status-bar-contribution.js.map +1 -1
- package/lib/browser/monaco-text-model-service.d.ts +6 -6
- package/lib/browser/monaco-text-model-service.d.ts.map +1 -1
- package/lib/browser/monaco-text-model-service.js +44 -58
- package/lib/browser/monaco-text-model-service.js.map +1 -1
- package/lib/browser/monaco-theming-service.d.ts +2 -2
- package/lib/browser/monaco-theming-service.d.ts.map +1 -1
- package/lib/browser/monaco-theming-service.js +30 -37
- package/lib/browser/monaco-theming-service.js.map +1 -1
- package/lib/browser/monaco-to-protocol-converter.js +8 -11
- package/lib/browser/monaco-to-protocol-converter.js.map +1 -1
- package/lib/browser/monaco-undo-redo-handler.d.ts +2 -2
- package/lib/browser/monaco-undo-redo-handler.d.ts.map +1 -1
- package/lib/browser/monaco-undo-redo-handler.js +15 -18
- package/lib/browser/monaco-undo-redo-handler.js.map +1 -1
- package/lib/browser/monaco-utilities.d.ts +1 -1
- package/lib/browser/monaco-utilities.d.ts.map +1 -1
- package/lib/browser/monaco-utilities.js +1 -4
- package/lib/browser/monaco-utilities.js.map +1 -1
- package/lib/browser/monaco-workspace-context-service.d.ts +7 -7
- package/lib/browser/monaco-workspace-context-service.d.ts.map +1 -1
- package/lib/browser/monaco-workspace-context-service.js +12 -15
- package/lib/browser/monaco-workspace-context-service.js.map +1 -1
- package/lib/browser/monaco-workspace.d.ts +5 -5
- package/lib/browser/monaco-workspace.d.ts.map +1 -1
- package/lib/browser/monaco-workspace.js +78 -92
- package/lib/browser/monaco-workspace.js.map +1 -1
- package/lib/browser/protocol-to-monaco-converter.js +6 -9
- package/lib/browser/protocol-to-monaco-converter.js.map +1 -1
- package/lib/browser/simple-monaco-editor.d.ts +4 -4
- package/lib/browser/simple-monaco-editor.d.ts.map +1 -1
- package/lib/browser/simple-monaco-editor.js +25 -29
- package/lib/browser/simple-monaco-editor.js.map +1 -1
- package/lib/browser/textmate/index.d.ts +4 -4
- package/lib/browser/textmate/index.d.ts.map +1 -1
- package/lib/browser/textmate/index.js +4 -7
- package/lib/browser/textmate/index.js.map +1 -1
- package/lib/browser/textmate/monaco-textmate-frontend-bindings.d.ts +2 -2
- package/lib/browser/textmate/monaco-textmate-frontend-bindings.d.ts.map +1 -1
- package/lib/browser/textmate/monaco-textmate-frontend-bindings.js +33 -37
- package/lib/browser/textmate/monaco-textmate-frontend-bindings.js.map +1 -1
- package/lib/browser/textmate/monaco-textmate-service.d.ts +5 -5
- package/lib/browser/textmate/monaco-textmate-service.d.ts.map +1 -1
- package/lib/browser/textmate/monaco-textmate-service.js +52 -63
- package/lib/browser/textmate/monaco-textmate-service.js.map +1 -1
- package/lib/browser/textmate/monaco-theme-registry.d.ts +2 -2
- package/lib/browser/textmate/monaco-theme-registry.d.ts.map +1 -1
- package/lib/browser/textmate/monaco-theme-registry.js +40 -35
- package/lib/browser/textmate/monaco-theme-registry.js.map +1 -1
- package/lib/browser/textmate/monaco-theme-types.d.ts +1 -1
- package/lib/browser/textmate/monaco-theme-types.d.ts.map +1 -1
- package/lib/browser/textmate/monaco-theme-types.js +4 -7
- package/lib/browser/textmate/monaco-theme-types.js.map +1 -1
- package/lib/browser/textmate/monaco-theme-types.spec.js +12 -14
- package/lib/browser/textmate/monaco-theme-types.spec.js.map +1 -1
- package/lib/browser/textmate/textmate-contribution.d.ts +1 -1
- package/lib/browser/textmate/textmate-contribution.d.ts.map +1 -1
- package/lib/browser/textmate/textmate-contribution.js +3 -7
- package/lib/browser/textmate/textmate-contribution.js.map +1 -1
- package/lib/browser/textmate/textmate-registry.d.ts +1 -1
- package/lib/browser/textmate/textmate-registry.d.ts.map +1 -1
- package/lib/browser/textmate/textmate-registry.js +13 -17
- package/lib/browser/textmate/textmate-registry.js.map +1 -1
- package/lib/browser/textmate/textmate-snippet-completion-provider.js +4 -8
- package/lib/browser/textmate/textmate-snippet-completion-provider.js.map +1 -1
- package/lib/browser/textmate/textmate-tokenizer.d.ts +1 -1
- package/lib/browser/textmate/textmate-tokenizer.d.ts.map +1 -1
- package/lib/browser/textmate/textmate-tokenizer.js +5 -9
- package/lib/browser/textmate/textmate-tokenizer.js.map +1 -1
- package/lib/browser/textmate/textmate-tokenizer.spec.js +10 -12
- package/lib/browser/textmate/textmate-tokenizer.spec.js.map +1 -1
- package/lib/browser/workspace-symbol-command.d.ts +1 -1
- package/lib/browser/workspace-symbol-command.d.ts.map +1 -1
- package/lib/browser/workspace-symbol-command.js +35 -44
- package/lib/browser/workspace-symbol-command.js.map +1 -1
- package/lib/package.spec.d.ts +1 -0
- package/lib/package.spec.js +1 -0
- package/package.json +18 -8
- package/src/browser/content-hover-widget-patcher.ts +2 -2
- package/src/browser/default-content-hover-widget-patcher.ts +2 -2
- package/src/browser/index.ts +2 -2
- package/src/browser/markdown-renderer/monaco-markdown-renderer.ts +5 -5
- package/src/browser/monaco-bulk-edit-service.ts +4 -4
- package/src/browser/monaco-code-action-save-participant.ts +3 -3
- package/src/browser/monaco-code-action-service.ts +9 -9
- package/src/browser/monaco-color-registry.ts +5 -5
- package/src/browser/monaco-command-registry.ts +2 -2
- package/src/browser/monaco-command-service.ts +3 -3
- package/src/browser/monaco-command.ts +9 -9
- package/src/browser/monaco-context-key-service.ts +4 -4
- package/src/browser/monaco-context-menu.ts +6 -6
- package/src/browser/monaco-diff-computer.ts +2 -2
- package/src/browser/monaco-diff-editor.ts +16 -16
- package/src/browser/monaco-diff-navigator-factory.ts +1 -1
- package/src/browser/monaco-editor-content-menu.ts +5 -5
- package/src/browser/monaco-editor-model.ts +8 -8
- package/src/browser/monaco-editor-overlay-button.ts +1 -1
- package/src/browser/monaco-editor-peek-view-widget.ts +10 -10
- package/src/browser/monaco-editor-provider.ts +21 -21
- package/src/browser/monaco-editor-service.ts +9 -9
- package/src/browser/monaco-editor.spec.ts +227 -0
- package/src/browser/monaco-editor.ts +52 -32
- package/src/browser/monaco-formatter-service.ts +6 -6
- package/src/browser/monaco-formatting-conflicts.ts +5 -5
- package/src/browser/monaco-frontend-application-contribution.ts +10 -10
- package/src/browser/monaco-frontend-module.ts +46 -46
- package/src/browser/monaco-gotoline-quick-access.ts +6 -6
- package/src/browser/monaco-gotosymbol-quick-access.ts +7 -7
- package/src/browser/monaco-icon-registry.ts +1 -1
- package/src/browser/monaco-indexed-db.ts +1 -1
- package/src/browser/monaco-init.spec.ts +32 -5
- package/src/browser/monaco-init.ts +32 -32
- package/src/browser/monaco-keybinding.spec.ts +121 -0
- package/src/browser/monaco-keybinding.ts +21 -11
- package/src/browser/monaco-keycode-map.ts +2 -2
- package/src/browser/monaco-languages.ts +4 -4
- package/src/browser/monaco-marker-collection.ts +1 -1
- package/src/browser/monaco-menu.ts +3 -3
- package/src/browser/monaco-mime-service.ts +5 -5
- package/src/browser/monaco-nls.ts +1 -1
- package/src/browser/monaco-outline-contribution.ts +13 -6
- package/src/browser/monaco-outline-decorator.spec.ts +96 -0
- package/src/browser/monaco-outline-decorator.ts +9 -6
- package/src/browser/monaco-quick-access-registry.ts +5 -5
- package/src/browser/monaco-quick-input-service.spec.ts +2 -2
- package/src/browser/monaco-quick-input-service.ts +148 -25
- package/src/browser/monaco-resolved-keybinding.ts +12 -9
- package/src/browser/monaco-snippet-suggest-provider.ts +1 -1
- package/src/browser/monaco-standalone-theme-service.ts +2 -2
- package/src/browser/monaco-status-bar-contribution.ts +1 -1
- package/src/browser/monaco-text-model-service.ts +8 -8
- package/src/browser/monaco-theming-service.ts +2 -2
- package/src/browser/monaco-undo-redo-handler.ts +3 -3
- package/src/browser/monaco-utilities.ts +1 -1
- package/src/browser/monaco-workspace-context-service.ts +3 -3
- package/src/browser/monaco-workspace.ts +10 -10
- package/src/browser/simple-monaco-editor.ts +8 -8
- package/src/browser/style/index.css +1 -5
- package/src/browser/textmate/index.ts +4 -4
- package/src/browser/textmate/monaco-textmate-frontend-bindings.ts +17 -15
- package/src/browser/textmate/monaco-textmate-service.ts +11 -11
- package/src/browser/textmate/monaco-theme-registry.ts +25 -15
- package/src/browser/textmate/monaco-theme-types.spec.ts +1 -1
- package/src/browser/textmate/monaco-theme-types.ts +1 -1
- package/src/browser/textmate/textmate-contribution.ts +1 -1
- package/src/browser/textmate/textmate-registry.ts +1 -1
- package/src/browser/textmate/textmate-snippet-completion-provider.ts +1 -1
- package/src/browser/textmate/textmate-tokenizer.spec.ts +1 -1
- package/src/browser/textmate/textmate-tokenizer.ts +3 -2
- package/src/browser/workspace-symbol-command.ts +1 -1
- package/src/typings/wasm.d.ts +21 -0
|
@@ -19,12 +19,12 @@ import { Emitter, Event, PreferenceInspection, PreferenceLanguageOverrideService
|
|
|
19
19
|
import { WorkspaceService } from '@theia/workspace/lib/browser';
|
|
20
20
|
import { FormatterInfo, FormatterService, FormatterSettingScope, FormatterStatus } from '@theia/editor/lib/browser/editor-formatter-service';
|
|
21
21
|
import { TextEditor } from '@theia/editor/lib/browser';
|
|
22
|
-
import { StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices';
|
|
23
|
-
import { ILanguageFeaturesService } from '@theia/monaco-editor-core/esm/vs/editor/common/services/languageFeatures';
|
|
24
|
-
import { DocumentFormattingEditProvider, DocumentRangeFormattingEditProvider } from '@theia/monaco-editor-core/esm/vs/editor/common/languages';
|
|
25
|
-
import { ExtensionIdentifier } from '@theia/monaco-editor-core/esm/vs/platform/extensions/common/extensions';
|
|
26
|
-
import { ITextModel } from '@theia/monaco-editor-core/esm/vs/editor/common/model';
|
|
27
|
-
import { MonacoEditor } from './monaco-editor';
|
|
22
|
+
import { StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices.js';
|
|
23
|
+
import { ILanguageFeaturesService } from '@theia/monaco-editor-core/esm/vs/editor/common/services/languageFeatures.js';
|
|
24
|
+
import { DocumentFormattingEditProvider, DocumentRangeFormattingEditProvider } from '@theia/monaco-editor-core/esm/vs/editor/common/languages.js';
|
|
25
|
+
import { ExtensionIdentifier } from '@theia/monaco-editor-core/esm/vs/platform/extensions/common/extensions.js';
|
|
26
|
+
import { ITextModel } from '@theia/monaco-editor-core/esm/vs/editor/common/model.js';
|
|
27
|
+
import { MonacoEditor } from './monaco-editor.js';
|
|
28
28
|
|
|
29
29
|
/**
|
|
30
30
|
* Extended formatter provider interface that includes extension metadata.
|
|
@@ -17,13 +17,13 @@
|
|
|
17
17
|
import { injectable, inject } from '@theia/core/shared/inversify';
|
|
18
18
|
import { FrontendApplicationContribution } from '@theia/core/lib/browser';
|
|
19
19
|
import { EditorManager } from '@theia/editor/lib/browser';
|
|
20
|
-
import { MonacoQuickInputService } from './monaco-quick-input-service';
|
|
20
|
+
import { MonacoQuickInputService } from './monaco-quick-input-service.js';
|
|
21
21
|
import * as monaco from '@theia/monaco-editor-core';
|
|
22
|
-
import { FormattingConflicts, FormattingMode } from '@theia/monaco-editor-core/esm/vs/editor/contrib/format/browser/format';
|
|
23
|
-
import { DocumentFormattingEditProvider, DocumentRangeFormattingEditProvider } from '@theia/monaco-editor-core/esm/vs/editor/common/languages';
|
|
24
|
-
import { ITextModel } from '@theia/monaco-editor-core/esm/vs/editor/common/model';
|
|
22
|
+
import { FormattingConflicts, FormattingMode } from '@theia/monaco-editor-core/esm/vs/editor/contrib/format/browser/format.js';
|
|
23
|
+
import { DocumentFormattingEditProvider, DocumentRangeFormattingEditProvider } from '@theia/monaco-editor-core/esm/vs/editor/common/languages.js';
|
|
24
|
+
import { ITextModel } from '@theia/monaco-editor-core/esm/vs/editor/common/model.js';
|
|
25
25
|
import { nls, PreferenceScope } from '@theia/core';
|
|
26
|
-
import { MonacoFormatterService } from './monaco-formatter-service';
|
|
26
|
+
import { MonacoFormatterService } from './monaco-formatter-service.js';
|
|
27
27
|
|
|
28
28
|
type FormattingEditProvider = DocumentFormattingEditProvider | DocumentRangeFormattingEditProvider;
|
|
29
29
|
|
|
@@ -16,22 +16,22 @@
|
|
|
16
16
|
|
|
17
17
|
import { injectable, inject, postConstruct } from '@theia/core/shared/inversify';
|
|
18
18
|
import { ColorTheme, CssStyleCollector, FrontendApplicationContribution, QuickAccessRegistry, StylingParticipant } from '@theia/core/lib/browser';
|
|
19
|
-
import { MonacoSnippetSuggestProvider } from './monaco-snippet-suggest-provider';
|
|
19
|
+
import { MonacoSnippetSuggestProvider } from './monaco-snippet-suggest-provider.js';
|
|
20
20
|
import * as monaco from '@theia/monaco-editor-core';
|
|
21
|
-
import { setSnippetSuggestSupport } from '@theia/monaco-editor-core/esm/vs/editor/contrib/suggest/browser/suggest';
|
|
22
|
-
import { CompletionItemProvider } from '@theia/monaco-editor-core/esm/vs/editor/common/languages';
|
|
23
|
-
import { MonacoTextModelService } from './monaco-text-model-service';
|
|
24
|
-
import { MonacoThemingService } from './monaco-theming-service';
|
|
21
|
+
import { setSnippetSuggestSupport } from '@theia/monaco-editor-core/esm/vs/editor/contrib/suggest/browser/suggest.js';
|
|
22
|
+
import { CompletionItemProvider } from '@theia/monaco-editor-core/esm/vs/editor/common/languages.js';
|
|
23
|
+
import { MonacoTextModelService } from './monaco-text-model-service.js';
|
|
24
|
+
import { MonacoThemingService } from './monaco-theming-service.js';
|
|
25
25
|
import { isHighContrast } from '@theia/core/lib/common/theme';
|
|
26
|
-
import { editorOptionsRegistry, IEditorOption } from '@theia/monaco-editor-core/esm/vs/editor/common/config/editorOptions';
|
|
26
|
+
import { editorOptionsRegistry, IEditorOption } from '@theia/monaco-editor-core/esm/vs/editor/common/config/editorOptions.js';
|
|
27
27
|
import { DisposableCollection, MAX_SAFE_INTEGER, PreferenceSchemaService } from '@theia/core';
|
|
28
28
|
import { editorGeneratedPreferenceProperties } from '@theia/editor/lib/common/editor-generated-preference-schema';
|
|
29
29
|
import { WorkspaceFileService } from '@theia/workspace/lib/common/workspace-file-service';
|
|
30
|
-
import { StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices';
|
|
31
|
-
import { IStandaloneThemeService } from '@theia/monaco-editor-core/esm/vs/editor/standalone/common/standaloneTheme';
|
|
32
|
-
import { MonacoStandaloneThemeService } from './monaco-standalone-theme-service';
|
|
30
|
+
import { StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices.js';
|
|
31
|
+
import { IStandaloneThemeService } from '@theia/monaco-editor-core/esm/vs/editor/standalone/common/standaloneTheme.js';
|
|
32
|
+
import { MonacoStandaloneThemeService } from './monaco-standalone-theme-service.js';
|
|
33
33
|
import { SecondaryWindowService } from '@theia/core/lib/browser/window/secondary-window-service';
|
|
34
|
-
import { registerWindow } from '@theia/monaco-editor-core/esm/vs/base/browser/dom';
|
|
34
|
+
import { registerWindow } from '@theia/monaco-editor-core/esm/vs/base/browser/dom.js';
|
|
35
35
|
|
|
36
36
|
type CodeWindow = Window & typeof globalThis & {
|
|
37
37
|
vscodeWindowId: number;
|
|
@@ -25,67 +25,67 @@ import {
|
|
|
25
25
|
FrontendApplicationContribution, KeybindingContribution, QuickInputService, StylingParticipant, WebSocketConnectionProvider, UndoRedoHandler, WidgetStatusBarContribution
|
|
26
26
|
} from '@theia/core/lib/browser';
|
|
27
27
|
import { TextEditorProvider, DiffNavigatorProvider, TextEditor, FormatterService } from '@theia/editor/lib/browser';
|
|
28
|
-
import { MonacoEditorProvider, MonacoEditorFactory, SaveParticipant } from './monaco-editor-provider';
|
|
29
|
-
import { MonacoEditorMenuContribution } from './monaco-menu';
|
|
30
|
-
import { MonacoEditorCommandHandlers } from './monaco-command';
|
|
31
|
-
import { MonacoKeybindingContribution } from './monaco-keybinding';
|
|
32
|
-
import { MonacoLanguages } from './monaco-languages';
|
|
33
|
-
import { MonacoWorkspace } from './monaco-workspace';
|
|
34
|
-
import { ActiveMonacoEditorContribution, MonacoEditorService, MonacoEditorServiceFactory, VSCodeContextKeyService, VSCodeThemeService } from './monaco-editor-service';
|
|
35
|
-
import { ICodeEditorService } from '@theia/monaco-editor-core/esm/vs/editor/browser/services/codeEditorService';
|
|
36
|
-
import { MonacoTextModelService, MonacoEditorModelFactory, MonacoEditorModelFilter } from './monaco-text-model-service';
|
|
37
|
-
import { MonacoContextMenuService } from './monaco-context-menu';
|
|
38
|
-
import { MonacoOutlineContribution } from './monaco-outline-contribution';
|
|
39
|
-
import { MonacoStatusBarContribution } from './monaco-status-bar-contribution';
|
|
40
|
-
import { MonacoCommandService } from './monaco-command-service';
|
|
41
|
-
import { MonacoCommandRegistry } from './monaco-command-registry';
|
|
42
|
-
import { MonacoDiffNavigatorFactory } from './monaco-diff-navigator-factory';
|
|
43
|
-
import { MonacoFrontendApplicationContribution } from './monaco-frontend-application-contribution';
|
|
44
|
-
import MonacoTextmateModuleBinder from './textmate/monaco-textmate-frontend-bindings';
|
|
45
|
-
import { MonacoBulkEditService } from './monaco-bulk-edit-service';
|
|
46
|
-
import { MonacoOutlineDecorator } from './monaco-outline-decorator';
|
|
28
|
+
import { MonacoEditorProvider, MonacoEditorFactory, SaveParticipant } from './monaco-editor-provider.js';
|
|
29
|
+
import { MonacoEditorMenuContribution } from './monaco-menu.js';
|
|
30
|
+
import { MonacoEditorCommandHandlers } from './monaco-command.js';
|
|
31
|
+
import { MonacoKeybindingContribution } from './monaco-keybinding.js';
|
|
32
|
+
import { MonacoLanguages } from './monaco-languages.js';
|
|
33
|
+
import { MonacoWorkspace } from './monaco-workspace.js';
|
|
34
|
+
import { ActiveMonacoEditorContribution, MonacoEditorService, MonacoEditorServiceFactory, VSCodeContextKeyService, VSCodeThemeService } from './monaco-editor-service.js';
|
|
35
|
+
import { ICodeEditorService } from '@theia/monaco-editor-core/esm/vs/editor/browser/services/codeEditorService.js';
|
|
36
|
+
import { MonacoTextModelService, MonacoEditorModelFactory, MonacoEditorModelFilter } from './monaco-text-model-service.js';
|
|
37
|
+
import { MonacoContextMenuService } from './monaco-context-menu.js';
|
|
38
|
+
import { MonacoOutlineContribution } from './monaco-outline-contribution.js';
|
|
39
|
+
import { MonacoStatusBarContribution } from './monaco-status-bar-contribution.js';
|
|
40
|
+
import { MonacoCommandService } from './monaco-command-service.js';
|
|
41
|
+
import { MonacoCommandRegistry } from './monaco-command-registry.js';
|
|
42
|
+
import { MonacoDiffNavigatorFactory } from './monaco-diff-navigator-factory.js';
|
|
43
|
+
import { MonacoFrontendApplicationContribution } from './monaco-frontend-application-contribution.js';
|
|
44
|
+
import MonacoTextmateModuleBinder from './textmate/monaco-textmate-frontend-bindings.js';
|
|
45
|
+
import { MonacoBulkEditService } from './monaco-bulk-edit-service.js';
|
|
46
|
+
import { MonacoOutlineDecorator } from './monaco-outline-decorator.js';
|
|
47
47
|
import { OutlineTreeDecorator } from '@theia/outline-view/lib/browser/outline-decorator-service';
|
|
48
|
-
import { MonacoSnippetSuggestProvider } from './monaco-snippet-suggest-provider';
|
|
48
|
+
import { MonacoSnippetSuggestProvider } from './monaco-snippet-suggest-provider.js';
|
|
49
49
|
import { ContextKeyService } from '@theia/core/lib/browser/context-key-service';
|
|
50
|
-
import { MonacoContextKeyService } from './monaco-context-key-service';
|
|
51
|
-
import { MonacoMimeService } from './monaco-mime-service';
|
|
50
|
+
import { MonacoContextKeyService } from './monaco-context-key-service.js';
|
|
51
|
+
import { MonacoMimeService } from './monaco-mime-service.js';
|
|
52
52
|
import { MimeService } from '@theia/core/lib/browser/mime-service';
|
|
53
|
-
import { MonacoEditorServices } from './monaco-editor';
|
|
54
|
-
import { MonacoColorRegistry } from './monaco-color-registry';
|
|
53
|
+
import { MonacoEditorServices } from './monaco-editor.js';
|
|
54
|
+
import { MonacoColorRegistry } from './monaco-color-registry.js';
|
|
55
55
|
import { ColorRegistry } from '@theia/core/lib/browser/color-registry';
|
|
56
|
-
import { MonacoIconRegistry } from './monaco-icon-registry';
|
|
56
|
+
import { MonacoIconRegistry } from './monaco-icon-registry.js';
|
|
57
57
|
import { IconRegistry } from '@theia/core/lib/browser/icon-registry';
|
|
58
|
-
import { MonacoThemingService } from './monaco-theming-service';
|
|
58
|
+
import { MonacoThemingService } from './monaco-theming-service.js';
|
|
59
59
|
import { bindRootContributionProvider } from '@theia/core';
|
|
60
|
-
import { WorkspaceSymbolCommand } from './workspace-symbol-command';
|
|
60
|
+
import { WorkspaceSymbolCommand } from './workspace-symbol-command.js';
|
|
61
61
|
import { LanguageService } from '@theia/core/lib/browser/language-service';
|
|
62
|
-
import { MonacoToProtocolConverter } from './monaco-to-protocol-converter';
|
|
63
|
-
import { ProtocolToMonacoConverter } from './protocol-to-monaco-converter';
|
|
64
|
-
import { MonacoFormattingConflictsContribution } from './monaco-formatting-conflicts';
|
|
65
|
-
import { MonacoFormatterService } from './monaco-formatter-service';
|
|
66
|
-
import { MonacoQuickInputImplementation, MonacoQuickInputService } from './monaco-quick-input-service';
|
|
67
|
-
import { GotoLineQuickAccessContribution } from './monaco-gotoline-quick-access';
|
|
68
|
-
import { GotoSymbolQuickAccessContribution } from './monaco-gotosymbol-quick-access';
|
|
62
|
+
import { MonacoToProtocolConverter } from './monaco-to-protocol-converter.js';
|
|
63
|
+
import { ProtocolToMonacoConverter } from './protocol-to-monaco-converter.js';
|
|
64
|
+
import { MonacoFormattingConflictsContribution } from './monaco-formatting-conflicts.js';
|
|
65
|
+
import { MonacoFormatterService } from './monaco-formatter-service.js';
|
|
66
|
+
import { MonacoQuickInputImplementation, MonacoQuickInputService } from './monaco-quick-input-service.js';
|
|
67
|
+
import { GotoLineQuickAccessContribution } from './monaco-gotoline-quick-access.js';
|
|
68
|
+
import { GotoSymbolQuickAccessContribution } from './monaco-gotosymbol-quick-access.js';
|
|
69
69
|
import { QuickAccessContribution, QuickAccessRegistry } from '@theia/core/lib/browser/quick-input/quick-access';
|
|
70
|
-
import { MonacoQuickAccessRegistry } from './monaco-quick-access-registry';
|
|
70
|
+
import { MonacoQuickAccessRegistry } from './monaco-quick-access-registry.js';
|
|
71
71
|
import { ConfigurationTarget, IConfigurationChangeEvent, IConfigurationService } from '@theia/monaco-editor-core/esm/vs/platform/configuration/common/configuration.js';
|
|
72
|
-
import { StandaloneConfigurationService, StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices';
|
|
72
|
+
import { StandaloneConfigurationService, StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices.js';
|
|
73
73
|
import { Configuration } from '@theia/monaco-editor-core/esm/vs/platform/configuration/common/configurationModels.js';
|
|
74
74
|
import { MarkdownRenderer } from '@theia/core/lib/browser/markdown-rendering/markdown-renderer';
|
|
75
|
-
import { MonacoMarkdownRenderer } from './markdown-renderer/monaco-markdown-renderer';
|
|
75
|
+
import { MonacoMarkdownRenderer } from './markdown-renderer/monaco-markdown-renderer.js';
|
|
76
76
|
import { ThemeService } from '@theia/core/lib/browser/theming';
|
|
77
|
-
import { ThemeServiceWithDB } from './monaco-indexed-db';
|
|
77
|
+
import { ThemeServiceWithDB } from './monaco-indexed-db.js';
|
|
78
78
|
import { IContextKeyService } from '@theia/monaco-editor-core/esm/vs/platform/contextkey/common/contextkey.js';
|
|
79
79
|
import { IThemeService } from '@theia/monaco-editor-core/esm/vs/platform/theme/common/themeService.js';
|
|
80
|
-
import { ActiveMonacoUndoRedoHandler, FocusedMonacoUndoRedoHandler } from './monaco-undo-redo-handler';
|
|
81
|
-
import { ILogService } from '@theia/monaco-editor-core/esm/vs/platform/log/common/log';
|
|
82
|
-
import { DefaultContentHoverWidgetPatcher } from './default-content-hover-widget-patcher';
|
|
83
|
-
import { MonacoWorkspaceContextService } from './monaco-workspace-context-service';
|
|
84
|
-
import { MonacoCodeActionSaveParticipant } from './monaco-code-action-save-participant';
|
|
85
|
-
import { MonacoCodeActionService, MonacoCodeActionServiceImpl } from './monaco-code-action-service';
|
|
86
|
-
import { MonacoDiffComputer } from './monaco-diff-computer';
|
|
80
|
+
import { ActiveMonacoUndoRedoHandler, FocusedMonacoUndoRedoHandler } from './monaco-undo-redo-handler.js';
|
|
81
|
+
import { ILogService } from '@theia/monaco-editor-core/esm/vs/platform/log/common/log.js';
|
|
82
|
+
import { DefaultContentHoverWidgetPatcher } from './default-content-hover-widget-patcher.js';
|
|
83
|
+
import { MonacoWorkspaceContextService } from './monaco-workspace-context-service.js';
|
|
84
|
+
import { MonacoCodeActionSaveParticipant } from './monaco-code-action-save-participant.js';
|
|
85
|
+
import { MonacoCodeActionService, MonacoCodeActionServiceImpl } from './monaco-code-action-service.js';
|
|
86
|
+
import { MonacoDiffComputer } from './monaco-diff-computer.js';
|
|
87
87
|
import { DiffComputer } from '@theia/core/lib/common/diff';
|
|
88
|
-
import { MonacoEditorContentMenuContribution } from './monaco-editor-content-menu';
|
|
88
|
+
import { MonacoEditorContentMenuContribution } from './monaco-editor-content-menu.js';
|
|
89
89
|
|
|
90
90
|
export default new ContainerModule((bind, unbind, isBound, rebind) => {
|
|
91
91
|
bind(MonacoThemingService).toSelf().inSingletonScope();
|
|
@@ -16,12 +16,12 @@
|
|
|
16
16
|
|
|
17
17
|
import { QuickAccessContribution } from '@theia/core/lib/browser/quick-input';
|
|
18
18
|
import { injectable } from '@theia/core/shared/inversify';
|
|
19
|
-
import { ICodeEditor } from '@theia/monaco-editor-core/esm/vs/editor/browser/editorBrowser';
|
|
20
|
-
import { ICodeEditorService } from '@theia/monaco-editor-core/esm/vs/editor/browser/services/codeEditorService';
|
|
21
|
-
import { StandaloneGotoLineQuickAccessProvider } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/quickAccess/standaloneGotoLineQuickAccess';
|
|
22
|
-
import { IQuickAccessRegistry, Extensions } from '@theia/monaco-editor-core/esm/vs/platform/quickinput/common/quickAccess';
|
|
23
|
-
import { Registry } from '@theia/monaco-editor-core/esm/vs/platform/registry/common/platform';
|
|
24
|
-
import { IStorageService } from '@theia/monaco-editor-core/esm/vs/platform/storage/common/storage';
|
|
19
|
+
import { ICodeEditor } from '@theia/monaco-editor-core/esm/vs/editor/browser/editorBrowser.js';
|
|
20
|
+
import { ICodeEditorService } from '@theia/monaco-editor-core/esm/vs/editor/browser/services/codeEditorService.js';
|
|
21
|
+
import { StandaloneGotoLineQuickAccessProvider } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/quickAccess/standaloneGotoLineQuickAccess.js';
|
|
22
|
+
import { IQuickAccessRegistry, Extensions } from '@theia/monaco-editor-core/esm/vs/platform/quickinput/common/quickAccess.js';
|
|
23
|
+
import { Registry } from '@theia/monaco-editor-core/esm/vs/platform/registry/common/platform.js';
|
|
24
|
+
import { IStorageService } from '@theia/monaco-editor-core/esm/vs/platform/storage/common/storage.js';
|
|
25
25
|
|
|
26
26
|
export class GotoLineQuickAccess extends StandaloneGotoLineQuickAccessProvider {
|
|
27
27
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
@@ -16,13 +16,13 @@
|
|
|
16
16
|
|
|
17
17
|
import { QuickAccessContribution } from '@theia/core/lib/browser/quick-input';
|
|
18
18
|
import { injectable } from '@theia/core/shared/inversify';
|
|
19
|
-
import { ICodeEditor } from '@theia/monaco-editor-core/esm/vs/editor/browser/editorBrowser';
|
|
20
|
-
import { ICodeEditorService } from '@theia/monaco-editor-core/esm/vs/editor/browser/services/codeEditorService';
|
|
21
|
-
import { ILanguageFeaturesService } from '@theia/monaco-editor-core/esm/vs/editor/common/services/languageFeatures';
|
|
22
|
-
import { IOutlineModelService } from '@theia/monaco-editor-core/esm/vs/editor/contrib/documentSymbols/browser/outlineModel';
|
|
23
|
-
import { StandaloneGotoSymbolQuickAccessProvider } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/quickAccess/standaloneGotoSymbolQuickAccess';
|
|
24
|
-
import { IQuickAccessRegistry, Extensions } from '@theia/monaco-editor-core/esm/vs/platform/quickinput/common/quickAccess';
|
|
25
|
-
import { Registry } from '@theia/monaco-editor-core/esm/vs/platform/registry/common/platform';
|
|
19
|
+
import { ICodeEditor } from '@theia/monaco-editor-core/esm/vs/editor/browser/editorBrowser.js';
|
|
20
|
+
import { ICodeEditorService } from '@theia/monaco-editor-core/esm/vs/editor/browser/services/codeEditorService.js';
|
|
21
|
+
import { ILanguageFeaturesService } from '@theia/monaco-editor-core/esm/vs/editor/common/services/languageFeatures.js';
|
|
22
|
+
import { IOutlineModelService } from '@theia/monaco-editor-core/esm/vs/editor/contrib/documentSymbols/browser/outlineModel.js';
|
|
23
|
+
import { StandaloneGotoSymbolQuickAccessProvider } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/quickAccess/standaloneGotoSymbolQuickAccess.js';
|
|
24
|
+
import { IQuickAccessRegistry, Extensions } from '@theia/monaco-editor-core/esm/vs/platform/quickinput/common/quickAccess.js';
|
|
25
|
+
import { Registry } from '@theia/monaco-editor-core/esm/vs/platform/registry/common/platform.js';
|
|
26
26
|
|
|
27
27
|
export class GotoSymbolQuickAccess extends StandaloneGotoSymbolQuickAccessProvider {
|
|
28
28
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
|
|
17
17
|
import { injectable } from '@theia/core/shared/inversify';
|
|
18
18
|
import { IconRegistry } from '@theia/core/lib/browser/icon-registry';
|
|
19
|
-
import { getIconRegistry } from '@theia/monaco-editor-core/esm/vs/platform/theme/common/iconRegistry';
|
|
19
|
+
import { getIconRegistry } from '@theia/monaco-editor-core/esm/vs/platform/theme/common/iconRegistry.js';
|
|
20
20
|
import { IconDefinition, IconFontDefinition, ThemeIcon } from '@theia/core/lib/common/theme';
|
|
21
21
|
|
|
22
22
|
@injectable()
|
|
@@ -19,7 +19,7 @@ import { Disposable, DisposableCollection } from '@theia/core/lib/common/disposa
|
|
|
19
19
|
import { ThemeService } from '@theia/core/lib/browser/theming';
|
|
20
20
|
import * as monaco from '@theia/monaco-editor-core';
|
|
21
21
|
import { injectable } from '@theia/core/shared/inversify';
|
|
22
|
-
import type { ThemeMix } from './textmate/monaco-theme-types';
|
|
22
|
+
import type { ThemeMix } from './textmate/monaco-theme-types.js';
|
|
23
23
|
import { Theme } from '@theia/core/lib/common/theme';
|
|
24
24
|
import { Emitter, Event, isObject } from '@theia/core';
|
|
25
25
|
|
|
@@ -16,13 +16,27 @@
|
|
|
16
16
|
|
|
17
17
|
import { enableJSDOM } from '@theia/core/lib/browser/test/jsdom';
|
|
18
18
|
let disableJSDOM = enableJSDOM();
|
|
19
|
+
if (typeof CSS === 'undefined') {
|
|
20
|
+
Object.assign(globalThis, { CSS: { escape: (value: string) => value } });
|
|
21
|
+
}
|
|
22
|
+
window.matchMedia = () => ({
|
|
23
|
+
matches: false,
|
|
24
|
+
media: '',
|
|
25
|
+
// eslint-disable-next-line no-null/no-null
|
|
26
|
+
onchange: null,
|
|
27
|
+
addListener: () => undefined,
|
|
28
|
+
removeListener: () => undefined,
|
|
29
|
+
addEventListener: () => undefined,
|
|
30
|
+
removeEventListener: () => undefined,
|
|
31
|
+
dispatchEvent: () => false
|
|
32
|
+
});
|
|
19
33
|
|
|
20
34
|
import { expect } from 'chai';
|
|
21
35
|
import { Disposable } from '@theia/core';
|
|
22
|
-
import { StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices';
|
|
23
|
-
import { IInstantiationService } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/instantiation';
|
|
24
|
-
import { InstantiationService } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/instantiationService';
|
|
25
|
-
import { ServiceCollection } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/serviceCollection';
|
|
36
|
+
import { StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices.js';
|
|
37
|
+
import { IInstantiationService } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/instantiation.js';
|
|
38
|
+
import { InstantiationService } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/instantiationService.js';
|
|
39
|
+
import { ServiceCollection } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/serviceCollection.js';
|
|
26
40
|
|
|
27
41
|
disableJSDOM();
|
|
28
42
|
|
|
@@ -44,7 +58,20 @@ disableJSDOM();
|
|
|
44
58
|
*/
|
|
45
59
|
describe('Monaco InstantiationService internals', () => {
|
|
46
60
|
|
|
47
|
-
before(() =>
|
|
61
|
+
before(() => {
|
|
62
|
+
disableJSDOM = enableJSDOM();
|
|
63
|
+
window.matchMedia = () => ({
|
|
64
|
+
matches: false,
|
|
65
|
+
media: '',
|
|
66
|
+
// eslint-disable-next-line no-null/no-null
|
|
67
|
+
onchange: null,
|
|
68
|
+
addListener: () => undefined,
|
|
69
|
+
removeListener: () => undefined,
|
|
70
|
+
addEventListener: () => undefined,
|
|
71
|
+
removeEventListener: () => undefined,
|
|
72
|
+
dispatchEvent: () => false
|
|
73
|
+
});
|
|
74
|
+
});
|
|
48
75
|
after(() => disableJSDOM());
|
|
49
76
|
|
|
50
77
|
it('StandaloneServices.get(IInstantiationService) should be an instance of InstantiationService', () => {
|
|
@@ -32,38 +32,38 @@
|
|
|
32
32
|
// packages/monaco/src/browser/monaco-nls.ts.
|
|
33
33
|
|
|
34
34
|
import { Container } from '@theia/core/shared/inversify';
|
|
35
|
-
import { ICodeEditorService } from '@theia/monaco-editor-core/esm/vs/editor/browser/services/codeEditorService';
|
|
36
|
-
import { StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices';
|
|
37
|
-
import { SyncDescriptor } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/descriptors';
|
|
38
|
-
import { IInstantiationService, createDecorator } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/instantiation';
|
|
39
|
-
import { InstantiationService } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/instantiationService';
|
|
40
|
-
import { ServiceCollection } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/serviceCollection';
|
|
41
|
-
import { MonacoEditorServiceFactory, MonacoEditorServiceFactoryType } from './monaco-editor-service';
|
|
42
|
-
import { IConfigurationService } from '@theia/monaco-editor-core/esm/vs/platform/configuration/common/configuration';
|
|
43
|
-
import { ITextModelService } from '@theia/monaco-editor-core/esm/vs/editor/common/services/resolverService';
|
|
44
|
-
import { MonacoConfigurationService } from './monaco-frontend-module';
|
|
45
|
-
import { MonacoTextModelService } from './monaco-text-model-service';
|
|
46
|
-
import { MonacoContextMenuService } from './monaco-context-menu';
|
|
47
|
-
import { IContextMenuService } from '@theia/monaco-editor-core/esm/vs/platform/contextview/browser/contextView';
|
|
48
|
-
import { IContextKeyService } from '@theia/monaco-editor-core/esm/vs/platform/contextkey/common/contextkey';
|
|
49
|
-
import { IThemeService } from '@theia/monaco-editor-core/esm/vs/platform/theme/common/themeService';
|
|
50
|
-
import { MonacoBulkEditService } from './monaco-bulk-edit-service';
|
|
51
|
-
import { MonacoCommandService } from './monaco-command-service';
|
|
52
|
-
import { IBulkEditService } from '@theia/monaco-editor-core/esm/vs/editor/browser/services/bulkEditService';
|
|
53
|
-
import { ICommandService } from '@theia/monaco-editor-core/esm/vs/platform/commands/common/commands';
|
|
54
|
-
import { MonacoQuickInputImplementation } from './monaco-quick-input-service';
|
|
55
|
-
import { IQuickInputService } from '@theia/monaco-editor-core/esm/vs/platform/quickinput/common/quickInput';
|
|
56
|
-
import { IStandaloneThemeService } from '@theia/monaco-editor-core/esm/vs/editor/standalone/common/standaloneTheme';
|
|
57
|
-
import { MonacoStandaloneThemeService } from './monaco-standalone-theme-service';
|
|
58
|
-
import { createContentHoverWidgetPatcher } from './content-hover-widget-patcher';
|
|
59
|
-
import { IHoverService } from '@theia/monaco-editor-core/esm/vs/platform/hover/browser/hover';
|
|
60
|
-
import { setBaseLayerHoverDelegate } from '@theia/monaco-editor-core/esm/vs/base/browser/ui/hover/hoverDelegate2';
|
|
61
|
-
import { IWorkspaceContextService } from '@theia/monaco-editor-core/esm/vs/platform/workspace/common/workspace';
|
|
62
|
-
import { MonacoWorkspaceContextService } from './monaco-workspace-context-service';
|
|
63
|
-
import { ILayoutService } from '@theia/monaco-editor-core/esm/vs/platform/layout/browser/layoutService';
|
|
64
|
-
import { Event } from '@theia/monaco-editor-core/esm/vs/base/common/event';
|
|
65
|
-
import * as dom from '@theia/monaco-editor-core/esm/vs/base/browser/dom';
|
|
66
|
-
import { mainWindow } from '@theia/monaco-editor-core/esm/vs/base/browser/window';
|
|
35
|
+
import { ICodeEditorService } from '@theia/monaco-editor-core/esm/vs/editor/browser/services/codeEditorService.js';
|
|
36
|
+
import { StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices.js';
|
|
37
|
+
import { SyncDescriptor } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/descriptors.js';
|
|
38
|
+
import { IInstantiationService, createDecorator } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/instantiation.js';
|
|
39
|
+
import { InstantiationService } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/instantiationService.js';
|
|
40
|
+
import { ServiceCollection } from '@theia/monaco-editor-core/esm/vs/platform/instantiation/common/serviceCollection.js';
|
|
41
|
+
import { MonacoEditorServiceFactory, MonacoEditorServiceFactoryType } from './monaco-editor-service.js';
|
|
42
|
+
import { IConfigurationService } from '@theia/monaco-editor-core/esm/vs/platform/configuration/common/configuration.js';
|
|
43
|
+
import { ITextModelService } from '@theia/monaco-editor-core/esm/vs/editor/common/services/resolverService.js';
|
|
44
|
+
import { MonacoConfigurationService } from './monaco-frontend-module.js';
|
|
45
|
+
import { MonacoTextModelService } from './monaco-text-model-service.js';
|
|
46
|
+
import { MonacoContextMenuService } from './monaco-context-menu.js';
|
|
47
|
+
import { IContextMenuService } from '@theia/monaco-editor-core/esm/vs/platform/contextview/browser/contextView.js';
|
|
48
|
+
import { IContextKeyService } from '@theia/monaco-editor-core/esm/vs/platform/contextkey/common/contextkey.js';
|
|
49
|
+
import { IThemeService } from '@theia/monaco-editor-core/esm/vs/platform/theme/common/themeService.js';
|
|
50
|
+
import { MonacoBulkEditService } from './monaco-bulk-edit-service.js';
|
|
51
|
+
import { MonacoCommandService } from './monaco-command-service.js';
|
|
52
|
+
import { IBulkEditService } from '@theia/monaco-editor-core/esm/vs/editor/browser/services/bulkEditService.js';
|
|
53
|
+
import { ICommandService } from '@theia/monaco-editor-core/esm/vs/platform/commands/common/commands.js';
|
|
54
|
+
import { MonacoQuickInputImplementation } from './monaco-quick-input-service.js';
|
|
55
|
+
import { IQuickInputService } from '@theia/monaco-editor-core/esm/vs/platform/quickinput/common/quickInput.js';
|
|
56
|
+
import { IStandaloneThemeService } from '@theia/monaco-editor-core/esm/vs/editor/standalone/common/standaloneTheme.js';
|
|
57
|
+
import { MonacoStandaloneThemeService } from './monaco-standalone-theme-service.js';
|
|
58
|
+
import { createContentHoverWidgetPatcher } from './content-hover-widget-patcher.js';
|
|
59
|
+
import { IHoverService } from '@theia/monaco-editor-core/esm/vs/platform/hover/browser/hover.js';
|
|
60
|
+
import { setBaseLayerHoverDelegate } from '@theia/monaco-editor-core/esm/vs/base/browser/ui/hover/hoverDelegate2.js';
|
|
61
|
+
import { IWorkspaceContextService } from '@theia/monaco-editor-core/esm/vs/platform/workspace/common/workspace.js';
|
|
62
|
+
import { MonacoWorkspaceContextService } from './monaco-workspace-context-service.js';
|
|
63
|
+
import { ILayoutService } from '@theia/monaco-editor-core/esm/vs/platform/layout/browser/layoutService.js';
|
|
64
|
+
import { Event } from '@theia/monaco-editor-core/esm/vs/base/common/event.js';
|
|
65
|
+
import * as dom from '@theia/monaco-editor-core/esm/vs/base/browser/dom.js';
|
|
66
|
+
import { mainWindow } from '@theia/monaco-editor-core/esm/vs/base/browser/window.js';
|
|
67
67
|
import { Disposable } from '@theia/core';
|
|
68
68
|
|
|
69
69
|
export const contentHoverWidgetPatcher = createContentHoverWidgetPatcher();
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
// *****************************************************************************
|
|
2
|
+
// Copyright (C) 2026 EclipseSource and others.
|
|
3
|
+
//
|
|
4
|
+
// This program and the accompanying materials are made available under the
|
|
5
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
//
|
|
8
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
9
|
+
// *****************************************************************************
|
|
10
|
+
|
|
11
|
+
import { enableJSDOM } from '@theia/core/lib/browser/test/jsdom';
|
|
12
|
+
let disableJSDOM = enableJSDOM();
|
|
13
|
+
|
|
14
|
+
import { expect } from 'chai';
|
|
15
|
+
import { Key, KeybindingRegistry, KeyCode } from '@theia/core/lib/browser';
|
|
16
|
+
import * as monaco from '@theia/monaco-editor-core';
|
|
17
|
+
import * as MonacoPlatform from '@theia/monaco-editor-core/esm/vs/base/common/platform.js';
|
|
18
|
+
import { KeyCode as MonacoKeyCode } from '@theia/monaco-editor-core/esm/vs/base/common/keyCodes.js';
|
|
19
|
+
import { KeyCodeChord } from '@theia/monaco-editor-core/esm/vs/base/common/keybindings.js';
|
|
20
|
+
import { USLayoutResolvedKeybinding } from '@theia/monaco-editor-core/esm/vs/platform/keybinding/common/usLayoutResolvedKeybinding.js';
|
|
21
|
+
import { OSStub, stubOS } from '@theia/core/lib/common/test/stub-os';
|
|
22
|
+
import { MonacoKeybindingContribution } from './monaco-keybinding.js';
|
|
23
|
+
import { MonacoResolvedKeybinding } from './monaco-resolved-keybinding.js';
|
|
24
|
+
|
|
25
|
+
class TestMonacoKeybindingContribution extends MonacoKeybindingContribution {
|
|
26
|
+
encode(code: KeyCode): number {
|
|
27
|
+
return this.toSingleMonacoKeybindingNumber(code);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
representable(codes: KeyCode[]): boolean {
|
|
31
|
+
return this.isMonacoRepresentable(codes);
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
disableJSDOM();
|
|
36
|
+
|
|
37
|
+
describe('Monaco keybinding adapter', () => {
|
|
38
|
+
let contribution: TestMonacoKeybindingContribution;
|
|
39
|
+
|
|
40
|
+
before(() => disableJSDOM = enableJSDOM());
|
|
41
|
+
after(() => disableJSDOM());
|
|
42
|
+
|
|
43
|
+
beforeEach(() => contribution = new TestMonacoKeybindingContribution());
|
|
44
|
+
|
|
45
|
+
let platform: OSStub | undefined;
|
|
46
|
+
|
|
47
|
+
afterEach(() => {
|
|
48
|
+
platform?.restore();
|
|
49
|
+
platform = undefined;
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
it('encodes non-macOS Ctrl as Monaco CtrlCmd', () => {
|
|
53
|
+
platform = stubOS('isOSX', false);
|
|
54
|
+
|
|
55
|
+
const encoded = contribution.encode(new KeyCode({ key: Key.KEY_A, ctrl: true }));
|
|
56
|
+
|
|
57
|
+
expect(encoded & monaco.KeyMod.CtrlCmd).to.equal(monaco.KeyMod.CtrlCmd);
|
|
58
|
+
expect(encoded & monaco.KeyMod.WinCtrl).to.equal(0);
|
|
59
|
+
});
|
|
60
|
+
|
|
61
|
+
it('preserves macOS Ctrl and Command encoding', () => {
|
|
62
|
+
platform = stubOS('isOSX', true);
|
|
63
|
+
|
|
64
|
+
const encoded = contribution.encode(new KeyCode({ key: Key.KEY_A, ctrl: true, meta: true }));
|
|
65
|
+
|
|
66
|
+
expect(encoded & monaco.KeyMod.WinCtrl).to.equal(monaco.KeyMod.WinCtrl);
|
|
67
|
+
expect(encoded & monaco.KeyMod.CtrlCmd).to.equal(monaco.KeyMod.CtrlCmd);
|
|
68
|
+
});
|
|
69
|
+
|
|
70
|
+
it('accepts layout Shift but rejects layout AltGraph and unmapped keys', () => {
|
|
71
|
+
expect(contribution.representable([
|
|
72
|
+
new KeyCode({ key: Key.DIGIT7, layoutModifiers: 'shift' })
|
|
73
|
+
])).to.be.true;
|
|
74
|
+
expect(contribution.representable([
|
|
75
|
+
new KeyCode({ key: Key.DIGIT8, layoutModifiers: 'altGraph' })
|
|
76
|
+
])).to.be.false;
|
|
77
|
+
expect(contribution.representable([new KeyCode({ key: Key.F20 })])).to.be.false;
|
|
78
|
+
});
|
|
79
|
+
|
|
80
|
+
it('uses formatted logical characters in resolved labels', () => {
|
|
81
|
+
const registry = Object.create(KeybindingRegistry.prototype) as KeybindingRegistry;
|
|
82
|
+
const bracket = new MonacoResolvedKeybinding([
|
|
83
|
+
new KeyCode({ key: Key.DIGIT8, ctrl: true, character: '[', layoutModifiers: 'altGraph' })
|
|
84
|
+
], registry);
|
|
85
|
+
const letter = new MonacoResolvedKeybinding([
|
|
86
|
+
new KeyCode({ key: Key.KEY_P, ctrl: true, character: 'p' })
|
|
87
|
+
], registry);
|
|
88
|
+
|
|
89
|
+
const controlLabel = MonacoPlatform.OS === MonacoPlatform.OperatingSystem.Macintosh ? '⌃' : 'Ctrl+';
|
|
90
|
+
expect(bracket.getLabel()).to.equal(`${controlLabel}[`);
|
|
91
|
+
expect(letter.getLabel()).to.equal(`${controlLabel}P`);
|
|
92
|
+
});
|
|
93
|
+
|
|
94
|
+
it('includes layout Shift in dispatch chords but not in labels', () => {
|
|
95
|
+
const registry = Object.create(KeybindingRegistry.prototype) as KeybindingRegistry;
|
|
96
|
+
const resolved = new MonacoResolvedKeybinding([
|
|
97
|
+
new KeyCode({ key: Key.DIGIT7, ctrl: true, character: '/', layoutModifiers: 'shift' })
|
|
98
|
+
], registry);
|
|
99
|
+
const expectedDispatch = USLayoutResolvedKeybinding.getDispatchStr(
|
|
100
|
+
new KeyCodeChord(true, true, false, false, MonacoKeyCode.Digit7)
|
|
101
|
+
);
|
|
102
|
+
const controlLabel = MonacoPlatform.OS === MonacoPlatform.OperatingSystem.Macintosh ? '⌃' : 'Ctrl+';
|
|
103
|
+
|
|
104
|
+
expect(resolved.getDispatchChords()).to.deep.equal([expectedDispatch]);
|
|
105
|
+
expect(resolved.getLabel()).to.equal(`${controlLabel}/`);
|
|
106
|
+
});
|
|
107
|
+
|
|
108
|
+
it('shows layout Shift in labels when it produces an uppercase letter', () => {
|
|
109
|
+
const registry = Object.create(KeybindingRegistry.prototype) as KeybindingRegistry;
|
|
110
|
+
const resolved = new MonacoResolvedKeybinding([
|
|
111
|
+
new KeyCode({ key: Key.KEY_P, ctrl: true, character: 'P', layoutModifiers: 'shift' })
|
|
112
|
+
], registry);
|
|
113
|
+
const expectedDispatch = USLayoutResolvedKeybinding.getDispatchStr(
|
|
114
|
+
new KeyCodeChord(true, true, false, false, MonacoKeyCode.KeyP)
|
|
115
|
+
);
|
|
116
|
+
const isMac = MonacoPlatform.OS === MonacoPlatform.OperatingSystem.Macintosh;
|
|
117
|
+
|
|
118
|
+
expect(resolved.getDispatchChords()).to.deep.equal([expectedDispatch]);
|
|
119
|
+
expect(resolved.getLabel()).to.equal(isMac ? '⌃⇧P' : 'Ctrl+Shift+P');
|
|
120
|
+
});
|
|
121
|
+
});
|
|
@@ -15,16 +15,18 @@
|
|
|
15
15
|
// *****************************************************************************
|
|
16
16
|
|
|
17
17
|
import { injectable, inject, postConstruct, named } from '@theia/core/shared/inversify';
|
|
18
|
-
import {
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
import {
|
|
19
|
+
KeybindingContribution, KeybindingRegistry, KeybindingScope, KeyCode, layoutModifiersIncludeAltGraph, layoutModifiersIncludeShift
|
|
20
|
+
} from '@theia/core/lib/browser';
|
|
21
|
+
import { MonacoCommands } from './monaco-command.js';
|
|
22
|
+
import { MonacoCommandRegistry } from './monaco-command-registry.js';
|
|
21
23
|
import { CommandRegistry, DisposableCollection, environment, isOSX, ILogger } from '@theia/core';
|
|
22
|
-
import { MonacoResolvedKeybinding } from './monaco-resolved-keybinding';
|
|
23
|
-
import { KeybindingsRegistry } from '@theia/monaco-editor-core/esm/vs/platform/keybinding/common/keybindingsRegistry';
|
|
24
|
-
import { StandaloneKeybindingService, StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices';
|
|
25
|
-
import { IKeybindingService } from '@theia/monaco-editor-core/esm/vs/platform/keybinding/common/keybinding';
|
|
26
|
-
import { MonacoContextKeyService } from './monaco-context-key-service';
|
|
27
|
-
import { KEY_CODE_MAP } from './monaco-keycode-map';
|
|
24
|
+
import { MonacoResolvedKeybinding } from './monaco-resolved-keybinding.js';
|
|
25
|
+
import { KeybindingsRegistry } from '@theia/monaco-editor-core/esm/vs/platform/keybinding/common/keybindingsRegistry.js';
|
|
26
|
+
import { StandaloneKeybindingService, StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices.js';
|
|
27
|
+
import { IKeybindingService } from '@theia/monaco-editor-core/esm/vs/platform/keybinding/common/keybinding.js';
|
|
28
|
+
import { MonacoContextKeyService } from './monaco-context-key-service.js';
|
|
29
|
+
import { KEY_CODE_MAP } from './monaco-keycode-map.js';
|
|
28
30
|
import * as monaco from '@theia/monaco-editor-core';
|
|
29
31
|
|
|
30
32
|
@injectable()
|
|
@@ -68,6 +70,9 @@ export class MonacoKeybindingContribution implements KeybindingContribution {
|
|
|
68
70
|
this.toDisposeOnKeybindingChange.dispose();
|
|
69
71
|
for (const binding of this.keybindings.getKeybindingsByScope(KeybindingScope.USER).concat(this.keybindings.getKeybindingsByScope(KeybindingScope.WORKSPACE))) {
|
|
70
72
|
const resolved = this.keybindings.resolveKeybinding(binding);
|
|
73
|
+
if (this.keybindings.isKeybindingInactive(binding) || !this.isMonacoRepresentable(resolved)) {
|
|
74
|
+
continue;
|
|
75
|
+
}
|
|
71
76
|
const command = binding.command;
|
|
72
77
|
const when = binding.when
|
|
73
78
|
? this.contextKeyService.parse(binding.when)
|
|
@@ -84,6 +89,11 @@ export class MonacoKeybindingContribution implements KeybindingContribution {
|
|
|
84
89
|
}
|
|
85
90
|
}
|
|
86
91
|
|
|
92
|
+
protected isMonacoRepresentable(codes: KeyCode[]): boolean {
|
|
93
|
+
return codes.length <= 2 && codes.every(code => code.key && KEY_CODE_MAP[code.key.keyCode] !== undefined
|
|
94
|
+
&& !layoutModifiersIncludeAltGraph(code.layoutModifiers));
|
|
95
|
+
}
|
|
96
|
+
|
|
87
97
|
protected toMonacoKeybindingNumber(codes: KeyCode[]): number {
|
|
88
98
|
const [firstPart, secondPart] = codes;
|
|
89
99
|
if (codes.length > 2) {
|
|
@@ -100,11 +110,11 @@ export class MonacoKeybindingContribution implements KeybindingContribution {
|
|
|
100
110
|
if (code.alt) {
|
|
101
111
|
encoded |= monaco.KeyMod.Alt;
|
|
102
112
|
}
|
|
103
|
-
if (code.shift) {
|
|
113
|
+
if (code.shift || layoutModifiersIncludeShift(code.layoutModifiers)) {
|
|
104
114
|
encoded |= monaco.KeyMod.Shift;
|
|
105
115
|
}
|
|
106
116
|
if (code.ctrl) {
|
|
107
|
-
encoded |= monaco.KeyMod.WinCtrl;
|
|
117
|
+
encoded |= isOSX ? monaco.KeyMod.WinCtrl : monaco.KeyMod.CtrlCmd;
|
|
108
118
|
}
|
|
109
119
|
if (code.meta && isOSX) {
|
|
110
120
|
encoded |= monaco.KeyMod.CtrlCmd;
|
|
@@ -20,8 +20,8 @@
|
|
|
20
20
|
|
|
21
21
|
import * as browser from '@theia/core/lib/browser';
|
|
22
22
|
// This is exported as part of the public API, but we use it with private API's so we need to refer to the private version.
|
|
23
|
-
import { KeyCode } from '@theia/monaco-editor-core/esm/vs/base/common/keyCodes';
|
|
24
|
-
import * as MonacoPlatform from '@theia/monaco-editor-core/esm/vs/base/common/platform';
|
|
23
|
+
import { KeyCode } from '@theia/monaco-editor-core/esm/vs/base/common/keyCodes.js';
|
|
24
|
+
import * as MonacoPlatform from '@theia/monaco-editor-core/esm/vs/base/common/platform.js';
|
|
25
25
|
|
|
26
26
|
export const KEY_CODE_MAP: KeyCode[] = [];
|
|
27
27
|
(function (): void {
|
|
@@ -22,13 +22,13 @@ import { MaybePromise, Mutable } from '@theia/core/lib/common/types';
|
|
|
22
22
|
import { Disposable } from '@theia/core/lib/common/disposable';
|
|
23
23
|
import { CancellationToken } from '@theia/core/lib/common/cancellation';
|
|
24
24
|
import { Language, LanguageService } from '@theia/core/lib/browser/language-service';
|
|
25
|
-
import { MonacoMarkerCollection } from './monaco-marker-collection';
|
|
26
|
-
import { ProtocolToMonacoConverter } from './protocol-to-monaco-converter';
|
|
25
|
+
import { MonacoMarkerCollection } from './monaco-marker-collection.js';
|
|
26
|
+
import { ProtocolToMonacoConverter } from './protocol-to-monaco-converter.js';
|
|
27
27
|
import * as monaco from '@theia/monaco-editor-core';
|
|
28
28
|
import { FileStat } from '@theia/filesystem/lib/common/files';
|
|
29
29
|
import { FileStatNode } from '@theia/filesystem/lib/browser';
|
|
30
|
-
import { ILanguageService } from '@theia/monaco-editor-core/esm/vs/editor/common/languages/language';
|
|
31
|
-
import { StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices';
|
|
30
|
+
import { ILanguageService } from '@theia/monaco-editor-core/esm/vs/editor/common/languages/language.js';
|
|
31
|
+
import { StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices.js';
|
|
32
32
|
|
|
33
33
|
export interface WorkspaceSymbolProvider {
|
|
34
34
|
provideWorkspaceSymbols(params: WorkspaceSymbolParams, token: CancellationToken): MaybePromise<SymbolInformation[] | undefined>;
|