@codingame/monaco-editor-wrapper 3.8.2 → 3.9.1
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/README.md +7 -5
- package/dist/configuration/index.d.ts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/keybindings/index.d.ts +1 -1
- package/dist/main.js +3 -3
- package/package.json +12 -12
- package/stats.html +1 -1
package/README.md
CHANGED
|
@@ -73,9 +73,11 @@ Default Monaco theme shouldn't be used.
|
|
|
73
73
|
##### User configuration
|
|
74
74
|
|
|
75
75
|
This library exposed some functions to manage the user global configuration:
|
|
76
|
-
- `registerDefaultConfigurations`
|
|
76
|
+
- `registerDefaultConfigurations` Allows registering default values for some configuration keys which can be overridden
|
|
77
77
|
- `updateUserConfiguration` Update the user configuration, overrides the default configuration, uses the same syntax as VS Code configuration
|
|
78
|
-
- `
|
|
79
|
-
- `
|
|
80
|
-
- `
|
|
81
|
-
- `
|
|
78
|
+
- `getUserConfiguartion` Get back the current user configuration
|
|
79
|
+
- `onUserConfigurationChange` Get notified when the user configuration change (either after calling updateUserConfiguration or from internal configuration update)
|
|
80
|
+
- `getConfiguration` Allows to get a given configuration key in a given language
|
|
81
|
+
- `onConfigurationChanged` Listen to configuration change
|
|
82
|
+
- `updateKeybindings` aAlows to update the editor keybindings with the same syntax as in VS Code
|
|
83
|
+
- `updateEditorKeybindingsMode` Switch between `vim`, `emacs` or `classic` keybindings
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as monaco from 'monaco-editor';
|
|
2
2
|
import { IConfigurationChangeEvent } from 'vscode/services';
|
|
3
3
|
import * as vscode from 'vscode';
|
|
4
|
-
import { updateUserConfiguration, getUserConfiguration, IConfigurationNode, IConfigurationDefaults } from 'vscode/service-override/configuration';
|
|
4
|
+
import { updateUserConfiguration, getUserConfiguration, onUserConfigurationChange, IConfigurationNode, IConfigurationDefaults } from 'vscode/service-override/configuration';
|
|
5
5
|
import './files';
|
|
6
6
|
export declare function onConfigurationChanged(listener: (e: IConfigurationChangeEvent) => void): vscode.Disposable;
|
|
7
7
|
export declare function getConfiguration<C = Partial<monaco.editor.IEditorOptions>>(language?: string, section?: string): C | undefined;
|
|
8
|
-
export { updateUserConfiguration, getUserConfiguration };
|
|
8
|
+
export { updateUserConfiguration, getUserConfiguration, onUserConfigurationChange };
|
|
9
9
|
export declare function registerConfigurations(configurations: IConfigurationNode[], validate?: boolean): void;
|
|
10
10
|
export declare function registerDefaultConfigurations(defaultConfigurations: IConfigurationDefaults['overrides'][]): void;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as monaco from 'monaco-editor';
|
|
2
2
|
import { createEditor, registerEditorOpenHandler, registerTextModelContentProvider } from './monaco';
|
|
3
3
|
import { defineVSCodeTheme } from './theme';
|
|
4
|
-
import { updateUserConfiguration, registerConfigurations, registerDefaultConfigurations, onConfigurationChanged, getConfiguration, getUserConfiguration } from './configuration';
|
|
4
|
+
import { updateUserConfiguration, registerConfigurations, registerDefaultConfigurations, onConfigurationChanged, getConfiguration, getUserConfiguration, onUserConfigurationChange } from './configuration';
|
|
5
5
|
import { getMonacoLanguage, loadLanguage } from './languages';
|
|
6
6
|
import { updateKeybindings, updateEditorKeybindingsMode } from './keybindings';
|
|
7
7
|
import './style';
|
|
8
8
|
export * from './tools';
|
|
9
|
-
export { monaco, createEditor, defineVSCodeTheme, registerConfigurations, registerDefaultConfigurations, updateUserConfiguration, getUserConfiguration, getConfiguration, onConfigurationChanged, updateEditorKeybindingsMode, updateKeybindings, getMonacoLanguage, registerTextModelContentProvider, registerEditorOpenHandler, loadLanguage };
|
|
9
|
+
export { monaco, createEditor, defineVSCodeTheme, registerConfigurations, registerDefaultConfigurations, updateUserConfiguration, getUserConfiguration, onUserConfigurationChange, getConfiguration, onConfigurationChanged, updateEditorKeybindingsMode, updateKeybindings, getMonacoLanguage, registerTextModelContentProvider, registerEditorOpenHandler, loadLanguage };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import * as monaco from 'monaco-editor';
|
|
2
|
-
export declare function updateKeybindings(bindingsJson: string): void
|
|
2
|
+
export declare function updateKeybindings(bindingsJson: string): Promise<void>;
|
|
3
3
|
export declare function updateEditorKeybindingsMode(editor: monaco.editor.IStandaloneCodeEditor, keyBindingsMode: "vim" | "classic" | "emacs" | undefined, statusBarElement: Element): monaco.IDisposable;
|
package/dist/main.js
CHANGED
|
@@ -14,7 +14,7 @@ import { registerColor, FoldingController, setCollapseStateForMatchingLines, err
|
|
|
14
14
|
import getModelEditorServiceOverride from 'vscode/service-override/modelEditor';
|
|
15
15
|
import getDialogServiceOverride from 'vscode/service-override/dialogs';
|
|
16
16
|
import getConfigurationServiceOverride from 'vscode/service-override/configuration';
|
|
17
|
-
export { getUserConfiguration, updateUserConfiguration } from 'vscode/service-override/configuration';
|
|
17
|
+
export { getUserConfiguration, onUserConfigurationChange, updateUserConfiguration } from 'vscode/service-override/configuration';
|
|
18
18
|
import getKeybindingsServiceOverride, { updateUserKeybindings } from 'vscode/service-override/keybindings';
|
|
19
19
|
import './worker.js';
|
|
20
20
|
import onigFile from 'vscode-oniguruma/release/onig.wasm';
|
|
@@ -3250,8 +3250,8 @@ function registerEditorOpenHandler(handler) {
|
|
|
3250
3250
|
return editorOpenHandlerRegistry.registerEditorOpenHandler(handler);
|
|
3251
3251
|
}
|
|
3252
3252
|
|
|
3253
|
-
function updateKeybindings(bindingsJson) {
|
|
3254
|
-
updateUserKeybindings(bindingsJson);
|
|
3253
|
+
async function updateKeybindings(bindingsJson) {
|
|
3254
|
+
await updateUserKeybindings(bindingsJson);
|
|
3255
3255
|
}
|
|
3256
3256
|
class PromiseDisposable {
|
|
3257
3257
|
constructor(promise) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-editor-wrapper",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.9.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Enhanced Monaco editor with TextMate grammars and more",
|
|
6
6
|
"scripts": {
|
|
@@ -67,22 +67,22 @@
|
|
|
67
67
|
],
|
|
68
68
|
"dependencies": {
|
|
69
69
|
"monaco-editor": "^0.34.0",
|
|
70
|
-
"vscode": "npm:@codingame/monaco-vscode-api@~1.69.
|
|
70
|
+
"vscode": "npm:@codingame/monaco-vscode-api@~1.69.21",
|
|
71
71
|
"vscode-oniguruma": "^1.6.2",
|
|
72
72
|
"vscode-textmate": "^7.0.4"
|
|
73
73
|
},
|
|
74
74
|
"devDependencies": {
|
|
75
|
-
"@babel/core": "7.
|
|
75
|
+
"@babel/core": "7.21.0",
|
|
76
76
|
"@babel/plugin-proposal-class-properties": "7.18.6",
|
|
77
|
-
"@babel/plugin-proposal-optional-chaining": "7.
|
|
77
|
+
"@babel/plugin-proposal-optional-chaining": "7.21.0",
|
|
78
78
|
"@babel/preset-env": "7.20.2",
|
|
79
|
-
"@babel/preset-typescript": "7.
|
|
80
|
-
"@babel/runtime": "7.
|
|
79
|
+
"@babel/preset-typescript": "7.21.0",
|
|
80
|
+
"@babel/runtime": "7.21.0",
|
|
81
81
|
"@codingame/commitlint-config-codingame": "^1.0.5",
|
|
82
82
|
"@codingame/eslint-config": "^1.1.6",
|
|
83
|
-
"@codingame/semantic-release-
|
|
83
|
+
"@codingame/semantic-release-config": "^1.2.0",
|
|
84
84
|
"@codingame/tsconfig": "^1.1.1",
|
|
85
|
-
"@commitlint/cli": "^17.4.
|
|
85
|
+
"@commitlint/cli": "^17.4.4",
|
|
86
86
|
"@rollup/plugin-alias": "4.0.3",
|
|
87
87
|
"@rollup/plugin-babel": "6.0.3",
|
|
88
88
|
"@rollup/plugin-commonjs": "24.0.1",
|
|
@@ -94,8 +94,8 @@
|
|
|
94
94
|
"@types/node": "18.11.18",
|
|
95
95
|
"@types/rollup-plugin-node-builtins": "^2.1.2",
|
|
96
96
|
"@types/vscode": "~1.69.1",
|
|
97
|
-
"@typescript-eslint/eslint-plugin": "5.
|
|
98
|
-
"@typescript-eslint/parser": "5.
|
|
97
|
+
"@typescript-eslint/eslint-plugin": "5.53.0",
|
|
98
|
+
"@typescript-eslint/parser": "5.53.0",
|
|
99
99
|
"conventional-changelog-conventionalcommits": "^5.0.0",
|
|
100
100
|
"cson-parser": "4.0.9",
|
|
101
101
|
"deep-equal": "2.2.0",
|
|
@@ -112,7 +112,7 @@
|
|
|
112
112
|
"monaco-emacs": "^0.3.0",
|
|
113
113
|
"monaco-vim": "^0.3.5",
|
|
114
114
|
"postcss": "8.4.21",
|
|
115
|
-
"rollup": "3.
|
|
115
|
+
"rollup": "3.17.2",
|
|
116
116
|
"rollup-plugin-json5": "1.0.0",
|
|
117
117
|
"rollup-plugin-node-builtins": "^2.1.2",
|
|
118
118
|
"rollup-plugin-string": "^3.0.0",
|
|
@@ -136,6 +136,6 @@
|
|
|
136
136
|
"npm": "9.4.1"
|
|
137
137
|
},
|
|
138
138
|
"overrides": {
|
|
139
|
-
"rollup": "3.
|
|
139
|
+
"rollup": "3.17.2"
|
|
140
140
|
}
|
|
141
141
|
}
|